vue-data-ui 2.4.1 → 2.4.2

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 (201) hide show
  1. package/README.md +44 -44
  2. package/dist/{Arrow-DpMf3yPs.cjs → Arrow-DLTRnzcG.cjs} +1 -1
  3. package/dist/{Arrow-BIs_9yK8.js → Arrow-JuK2z9IB.js} +1 -1
  4. package/dist/BaseIcon-BGExhz6v.cjs +1 -0
  5. package/dist/{BaseIcon-CXDdkPfN.js → BaseIcon-rRli6Sfv.js} +7 -4
  6. package/dist/{DataTable-BTgMVOwp.cjs → DataTable-DJzhv96s.cjs} +1 -1
  7. package/dist/{DataTable-DL2agEJ3.js → DataTable-DTk7C4Pr.js} +2 -2
  8. package/dist/{Legend-DXLiSLHd.js → Legend-CYF2gpXG.js} +1 -1
  9. package/dist/{Legend-Dj9KiaLv.cjs → Legend-YZ7Hz3o1.cjs} +1 -1
  10. package/dist/{PackageVersion-DtnhR89q.js → PackageVersion-CvCRsT5_.js} +1 -1
  11. package/dist/{PackageVersion-D4D0WicU.cjs → PackageVersion-DVZtsuy4.cjs} +1 -1
  12. package/dist/PenAndPaper-CyXm-yVL.cjs +1 -0
  13. package/dist/PenAndPaper-Jb0pLt3G.js +269 -0
  14. package/dist/{Shape-CO_Ak9Zm.js → Shape-BpPn4eWR.js} +1 -1
  15. package/dist/{Shape-7EC2UKDK.cjs → Shape-X2F-QV_B.cjs} +1 -1
  16. package/dist/{Slicer-CLAVjSQP.cjs → Slicer-CL0tP5a5.cjs} +1 -1
  17. package/dist/{Slicer-BZfUZr1J.js → Slicer-CU7dRZR0.js} +2 -2
  18. package/dist/{Title-DYNLqCCT.js → Title-5VmBwT4i.js} +1 -1
  19. package/dist/{Title-C-lm3Mkl.cjs → Title-Co5jI5ed.cjs} +1 -1
  20. package/dist/{Tooltip-t-3mVhcz.cjs → Tooltip-Bl6W8Zn7.cjs} +1 -1
  21. package/dist/{Tooltip-CICAYyQj.js → Tooltip-Cj4EF7v1.js} +1 -1
  22. package/dist/{index-DDXisDKy.js → index-DnVHQ2xI.js} +880 -842
  23. package/dist/index-FfZRtJ6A.cjs +9 -0
  24. package/dist/style.css +1 -1
  25. package/dist/types/vue-data-ui.d.cts +18 -16
  26. package/dist/types/vue-data-ui.d.ts +18 -16
  27. package/dist/{useNestedProp-S1UXxUgm.js → useNestedProp-Cox0K0Y5.js} +1 -1
  28. package/dist/{useNestedProp-CC9zGr7C.cjs → useNestedProp-q7byAAIJ.cjs} +1 -1
  29. package/dist/usePrinter-BCAFeO_J.cjs +1 -0
  30. package/dist/{usePrinter-8ofTb2MJ.js → usePrinter-BEeNAqS5.js} +230 -185
  31. package/dist/vue-data-ui-CRLLZpt0.cjs +9 -0
  32. package/dist/vue-data-ui-W7nnqn0v.js +261 -0
  33. package/dist/vue-data-ui.cjs +1 -1
  34. package/dist/vue-data-ui.js +1 -1
  35. package/dist/{vue-ui-3d-bar-DcF1nyGW.js → vue-ui-3d-bar-BwBrUabe.js} +414 -390
  36. package/dist/vue-ui-3d-bar-bD_n6qL_.cjs +19 -0
  37. package/dist/{vue-ui-accordion-D_1fE5EF.js → vue-ui-accordion-DspS4q3f.js} +3 -3
  38. package/dist/{vue-ui-accordion-Cc9958th.cjs → vue-ui-accordion-xXgqfR2l.cjs} +1 -1
  39. package/dist/vue-ui-age-pyramid-BZcAwcVQ.cjs +1 -0
  40. package/dist/{vue-ui-age-pyramid-Oe_yHDL0.js → vue-ui-age-pyramid-CxBvm3uM.js} +218 -194
  41. package/dist/{vue-ui-annotator-Dix6_Gm6.js → vue-ui-annotator-BOofWpzv.js} +1 -1
  42. package/dist/{vue-ui-annotator-Dbp6cWMr.cjs → vue-ui-annotator-C6T5_7ZV.cjs} +1 -1
  43. package/dist/vue-ui-bullet-ChaEgXvR.cjs +23 -0
  44. package/dist/vue-ui-bullet-DraC-oFu.js +433 -0
  45. package/dist/vue-ui-candlestick--hPCfMFH.cjs +2 -0
  46. package/dist/{vue-ui-candlestick-CRwzWF6j.js → vue-ui-candlestick-DQZ5eT1f.js} +267 -243
  47. package/dist/{vue-ui-carousel-table-C0GDDSW9.cjs → vue-ui-carousel-table-DpRQklDZ.cjs} +1 -1
  48. package/dist/{vue-ui-carousel-table-BHeEbRKY.js → vue-ui-carousel-table-PdLjpH1p.js} +4 -4
  49. package/dist/{vue-ui-chestnut-CRk0RCB9.js → vue-ui-chestnut-ByI_O5hB.js} +293 -269
  50. package/dist/vue-ui-chestnut-ae6x87wl.cjs +6 -0
  51. package/dist/{vue-ui-cursor-y0kdr0uA.js → vue-ui-cursor-BM74l93B.js} +2 -2
  52. package/dist/{vue-ui-cursor-lU1rts1B.cjs → vue-ui-cursor-BvadpA2m.cjs} +1 -1
  53. package/dist/{vue-ui-dashboard-OyihaKdu.js → vue-ui-dashboard-CoANBhAM.js} +2 -2
  54. package/dist/{vue-ui-dashboard-BfC0jS-X.cjs → vue-ui-dashboard-OP51Gs8I.cjs} +1 -1
  55. package/dist/{vue-ui-digits-BJfcAiq_.cjs → vue-ui-digits-C7jJJg9k.cjs} +1 -1
  56. package/dist/{vue-ui-digits-IKt4qT2-.js → vue-ui-digits-DioaBnkB.js} +2 -2
  57. package/dist/vue-ui-donut-CplNylps.cjs +1 -0
  58. package/dist/vue-ui-donut-evolution-CQpr-6IS.cjs +1 -0
  59. package/dist/{vue-ui-donut-evolution-Dd4o37RP.js → vue-ui-donut-evolution-DAb1xzNd.js} +330 -306
  60. package/dist/{vue-ui-donut-DFaGk4fI.js → vue-ui-donut-ldqSm_JV.js} +345 -321
  61. package/dist/{vue-ui-dumbbell-B7j1_JoQ.js → vue-ui-dumbbell-Dg7PkiKJ.js} +265 -241
  62. package/dist/vue-ui-dumbbell-_ijaYr8W.cjs +9 -0
  63. package/dist/vue-ui-flow-BPt35d5K.cjs +1 -0
  64. package/dist/vue-ui-flow-DKT7ZEnr.js +508 -0
  65. package/dist/vue-ui-galaxy-e06PkTmp.cjs +1 -0
  66. package/dist/{vue-ui-galaxy-CH1BDtWl.js → vue-ui-galaxy-qAA9be3S.js} +193 -169
  67. package/dist/vue-ui-gauge-D8yVTIgP.js +518 -0
  68. package/dist/vue-ui-gauge-DiZVIU0D.cjs +1 -0
  69. package/dist/{vue-ui-gizmo-CKQcbe_7.js → vue-ui-gizmo-DC0uUwI3.js} +3 -3
  70. package/dist/{vue-ui-gizmo-DVwQaEH1.cjs → vue-ui-gizmo-W6bTkg59.cjs} +1 -1
  71. package/dist/vue-ui-heatmap-CbZcv_2I.cjs +1 -0
  72. package/dist/{vue-ui-heatmap-B-zWMk0Y.js → vue-ui-heatmap-u1raIzBQ.js} +252 -228
  73. package/dist/{vue-ui-kpi-CghbfSdM.js → vue-ui-kpi-C-iTxMD2.js} +3 -3
  74. package/dist/{vue-ui-kpi-CuY3xlVq.cjs → vue-ui-kpi-DY_2WF7U.cjs} +1 -1
  75. package/dist/{vue-ui-mini-loader-CH_PfeDc.cjs → vue-ui-mini-loader-Bfq2MNWu.cjs} +1 -1
  76. package/dist/{vue-ui-mini-loader-C7roqZ4p.js → vue-ui-mini-loader-C7x7S0hi.js} +2 -2
  77. package/dist/vue-ui-molecule-BFnOIxxs.js +798 -0
  78. package/dist/vue-ui-molecule-CbKMLrDT.cjs +1 -0
  79. package/dist/vue-ui-mood-radar-6LmFXuiw.cjs +1 -0
  80. package/dist/{vue-ui-mood-radar-DSznHxLS.js → vue-ui-mood-radar-CR1v5v2x.js} +263 -239
  81. package/dist/{vue-ui-nested-donuts-CiE4DdEQ.js → vue-ui-nested-donuts-DEiloQzq.js} +342 -318
  82. package/dist/vue-ui-nested-donuts-DS0fjiLi.cjs +17 -0
  83. package/dist/vue-ui-onion-CLvvu4Ku.cjs +5 -0
  84. package/dist/{vue-ui-onion-D9o6Rcgu.js → vue-ui-onion-LsEhBe4x.js} +226 -202
  85. package/dist/vue-ui-parallel-coordinate-plot-BWg8OFqH.cjs +8 -0
  86. package/dist/{vue-ui-parallel-coordinate-plot-BcYrYXhG.js → vue-ui-parallel-coordinate-plot-CTlIjJqG.js} +243 -219
  87. package/dist/{vue-ui-quadrant-Cs3A77us.js → vue-ui-quadrant-DKVVFufb.js} +350 -326
  88. package/dist/vue-ui-quadrant-OM5J1mG3.cjs +1 -0
  89. package/dist/{vue-ui-quick-chart-CiiSUexi.js → vue-ui-quick-chart-8vJikiGH.js} +505 -481
  90. package/dist/vue-ui-quick-chart-gG5Ar8-i.cjs +15 -0
  91. package/dist/{vue-ui-radar-CNSpiNrM.js → vue-ui-radar-20QhOUer.js} +255 -231
  92. package/dist/vue-ui-radar-CAaHjDO7.cjs +1 -0
  93. package/dist/{vue-ui-rating-GoUNDOdZ.cjs → vue-ui-rating-Bbzm5nUK.cjs} +1 -1
  94. package/dist/{vue-ui-rating-b_iYZWF8.js → vue-ui-rating-DRWJsve1.js} +2 -2
  95. package/dist/vue-ui-relation-circle-BoGAFXuS.cjs +1 -0
  96. package/dist/vue-ui-relation-circle-I45_Sk5l.js +349 -0
  97. package/dist/vue-ui-rings-B9WQ7S5m.cjs +2 -0
  98. package/dist/vue-ui-rings-DG8GCi3y.js +593 -0
  99. package/dist/vue-ui-scatter-BZfg1YIN.cjs +1 -0
  100. package/dist/{vue-ui-scatter-CVuoW-cD.js → vue-ui-scatter-Hqu5-F2H.js} +369 -345
  101. package/dist/{vue-ui-screenshot-Co2o48d6.cjs → vue-ui-screenshot-D8nxd5RV.cjs} +1 -1
  102. package/dist/{vue-ui-screenshot-Csc0dQL9.js → vue-ui-screenshot-cjiqbtLK.js} +1 -1
  103. package/dist/{vue-ui-skeleton-CGV1dEUD.cjs → vue-ui-skeleton-Djv08J67.cjs} +1 -1
  104. package/dist/{vue-ui-skeleton-B2sRnIXX.js → vue-ui-skeleton-aZmkNzAe.js} +3 -3
  105. package/dist/{vue-ui-smiley-Ci3uMgVh.cjs → vue-ui-smiley-B1TA19Hv.cjs} +1 -1
  106. package/dist/{vue-ui-smiley-D4s-AdIE.js → vue-ui-smiley-ChNvxygm.js} +2 -2
  107. package/dist/{vue-ui-spark-trend-BfoEoJEy.cjs → vue-ui-spark-trend-BqrPr63O.cjs} +1 -1
  108. package/dist/{vue-ui-spark-trend-CHKQGMLs.js → vue-ui-spark-trend-CQxELQcf.js} +5 -5
  109. package/dist/{vue-ui-sparkbar-Bb1fq2GR.js → vue-ui-sparkbar-0ixbKZzf.js} +4 -4
  110. package/dist/{vue-ui-sparkbar-DB2DeXti.cjs → vue-ui-sparkbar-CrTEPTU5.cjs} +1 -1
  111. package/dist/{vue-ui-sparkgauge-CJepIY2u.cjs → vue-ui-sparkgauge-BYxpe_WV.cjs} +1 -1
  112. package/dist/{vue-ui-sparkgauge-DWuaAQbo.js → vue-ui-sparkgauge-pdYb7OwH.js} +4 -4
  113. package/dist/{vue-ui-sparkhistogram-B7B36LLT.cjs → vue-ui-sparkhistogram-D21XDUH2.cjs} +1 -1
  114. package/dist/{vue-ui-sparkhistogram-CjeJ3ch1.js → vue-ui-sparkhistogram-N69h2q0U.js} +5 -5
  115. package/dist/{vue-ui-sparkline-DGJDBArr.js → vue-ui-sparkline-2BKYZMOb.js} +4 -4
  116. package/dist/{vue-ui-sparkline-BcqmwDAb.cjs → vue-ui-sparkline-Cf4m-Fxo.cjs} +1 -1
  117. package/dist/{vue-ui-sparkstackbar-DT3aKNeV.cjs → vue-ui-sparkstackbar-dAS8XoJs.cjs} +1 -1
  118. package/dist/{vue-ui-sparkstackbar-B3ul3qUZ.js → vue-ui-sparkstackbar-sh03cuOU.js} +4 -4
  119. package/dist/vue-ui-stackbar-B1si-1RM.js +938 -0
  120. package/dist/vue-ui-stackbar-Dy_saeSe.cjs +6 -0
  121. package/dist/{vue-ui-strip-plot-CIb2LSV8.js → vue-ui-strip-plot-BYn-QrTQ.js} +274 -250
  122. package/dist/vue-ui-strip-plot-D53LABpZ.cjs +1 -0
  123. package/dist/{vue-ui-table-B_sFrAO9.cjs → vue-ui-table-Ce4waJaj.cjs} +1 -1
  124. package/dist/{vue-ui-table-CmVi0nv2.js → vue-ui-table-DQORPCDJ.js} +1 -1
  125. package/dist/{vue-ui-table-heatmap-CgFr38QT.js → vue-ui-table-heatmap-Csp7Tx8N.js} +4 -4
  126. package/dist/{vue-ui-table-heatmap-Chvdf2Gi.cjs → vue-ui-table-heatmap-EqHt-O7Y.cjs} +1 -1
  127. package/dist/{vue-ui-table-sparkline-DUUYQ5dH.cjs → vue-ui-table-sparkline-DONmVOMh.cjs} +1 -1
  128. package/dist/{vue-ui-table-sparkline-eg2Qd8ws.js → vue-ui-table-sparkline-DdwVrfUj.js} +5 -5
  129. package/dist/vue-ui-thermometer-I6ZnlfAv.js +440 -0
  130. package/dist/vue-ui-thermometer-hQBkMa7u.cjs +1 -0
  131. package/dist/{vue-ui-timer-DM1IStj1.cjs → vue-ui-timer-COOXcn14.cjs} +1 -1
  132. package/dist/{vue-ui-timer-COSI3Q5T.js → vue-ui-timer-pi1SazTU.js} +5 -5
  133. package/dist/vue-ui-tiremarks-hdNqoGyd.cjs +1 -0
  134. package/dist/vue-ui-tiremarks-vdPQYiDp.js +303 -0
  135. package/dist/vue-ui-treemap-3FNUlKxL.js +816 -0
  136. package/dist/vue-ui-treemap-Cv0TSFQa.cjs +1 -0
  137. package/dist/vue-ui-vertical-bar-C--Ma0Dw.cjs +4 -0
  138. package/dist/{vue-ui-vertical-bar-CieqHVD5.js → vue-ui-vertical-bar-DwxpB46q.js} +312 -288
  139. package/dist/vue-ui-waffle-CKM0QyJN.cjs +1 -0
  140. package/dist/vue-ui-waffle-XecHJIc-.js +782 -0
  141. package/dist/vue-ui-wheel-Bbih5sSL.js +282 -0
  142. package/dist/vue-ui-wheel-C0dJrzOJ.cjs +1 -0
  143. package/dist/vue-ui-word-cloud-Cfd2wxsT.cjs +1 -0
  144. package/dist/vue-ui-word-cloud-DnhXUn5x.js +598 -0
  145. package/dist/vue-ui-xy-BDpqVzAq.cjs +3 -0
  146. package/dist/{vue-ui-xy-x8KEsGV-.js → vue-ui-xy-CqlRuFMc.js} +775 -751
  147. package/dist/{vue-ui-xy-canvas-BYdTxzi6.js → vue-ui-xy-canvas-C8c2X5fk.js} +409 -385
  148. package/dist/vue-ui-xy-canvas-Cansjd3L.cjs +9 -0
  149. package/package.json +1 -1
  150. package/dist/BaseIcon-E7FmzMcY.cjs +0 -1
  151. package/dist/index-C7_6YjWN.cjs +0 -9
  152. package/dist/usePrinter-8EP4iaGm.cjs +0 -1
  153. package/dist/vue-data-ui-4Yd255Ia.cjs +0 -9
  154. package/dist/vue-data-ui-Cp7bO_tj.js +0 -258
  155. package/dist/vue-ui-3d-bar-BeR2aBgQ.cjs +0 -19
  156. package/dist/vue-ui-age-pyramid-R-C4P4mI.cjs +0 -1
  157. package/dist/vue-ui-bullet-CQKaC4wG.js +0 -409
  158. package/dist/vue-ui-bullet-DSZox236.cjs +0 -23
  159. package/dist/vue-ui-candlestick-Dilozp3V.cjs +0 -2
  160. package/dist/vue-ui-chestnut-DdEcEI04.cjs +0 -6
  161. package/dist/vue-ui-donut-DTSVlGMg.cjs +0 -1
  162. package/dist/vue-ui-donut-evolution-BuUafabD.cjs +0 -1
  163. package/dist/vue-ui-dumbbell-CVfgnyKi.cjs +0 -9
  164. package/dist/vue-ui-flow-C45dODaB.cjs +0 -1
  165. package/dist/vue-ui-flow-DkPTzNv9.js +0 -484
  166. package/dist/vue-ui-galaxy-DlPavMK0.cjs +0 -1
  167. package/dist/vue-ui-gauge-BXiy515T.js +0 -494
  168. package/dist/vue-ui-gauge-vMFUYHYH.cjs +0 -1
  169. package/dist/vue-ui-heatmap-CMQqQnxc.cjs +0 -1
  170. package/dist/vue-ui-molecule-BwmkMEVN.js +0 -774
  171. package/dist/vue-ui-molecule-nOuD0hR5.cjs +0 -1
  172. package/dist/vue-ui-mood-radar-Bof_C9Ae.cjs +0 -1
  173. package/dist/vue-ui-nested-donuts-DIb6YyWv.cjs +0 -17
  174. package/dist/vue-ui-onion-N3tRNc4u.cjs +0 -5
  175. package/dist/vue-ui-parallel-coordinate-plot-qKGk2bX6.cjs +0 -8
  176. package/dist/vue-ui-quadrant-Do48rGrX.cjs +0 -1
  177. package/dist/vue-ui-quick-chart-BxU4d-sJ.cjs +0 -15
  178. package/dist/vue-ui-radar-CooAvwPA.cjs +0 -1
  179. package/dist/vue-ui-relation-circle-nRf1pvD0.js +0 -325
  180. package/dist/vue-ui-relation-circle-uNgJni4x.cjs +0 -1
  181. package/dist/vue-ui-rings-BgRc1o4_.js +0 -569
  182. package/dist/vue-ui-rings-iIgQI9Ws.cjs +0 -2
  183. package/dist/vue-ui-scatter-CkrpmLxP.cjs +0 -1
  184. package/dist/vue-ui-stackbar-CRcUugkl.cjs +0 -6
  185. package/dist/vue-ui-stackbar-DNROvZII.js +0 -915
  186. package/dist/vue-ui-strip-plot-Ck9Fmt_b.cjs +0 -1
  187. package/dist/vue-ui-thermometer-BFfN4aat.cjs +0 -1
  188. package/dist/vue-ui-thermometer-BePmFiwy.js +0 -416
  189. package/dist/vue-ui-tiremarks-BkYXzU3R.cjs +0 -1
  190. package/dist/vue-ui-tiremarks-d6TmSHY7.js +0 -279
  191. package/dist/vue-ui-treemap-BgeZnbl3.cjs +0 -1
  192. package/dist/vue-ui-treemap-Qg0858o6.js +0 -792
  193. package/dist/vue-ui-vertical-bar-D3atbdvl.cjs +0 -4
  194. package/dist/vue-ui-waffle-CD7C9Lu4.cjs +0 -1
  195. package/dist/vue-ui-waffle-CjNhM-mV.js +0 -758
  196. package/dist/vue-ui-wheel-B8mbO6ht.js +0 -258
  197. package/dist/vue-ui-wheel-CYmM7J61.cjs +0 -1
  198. package/dist/vue-ui-word-cloud-DMXrUmX5.js +0 -574
  199. package/dist/vue-ui-word-cloud-Dm9yZ1zQ.cjs +0 -1
  200. package/dist/vue-ui-xy-DoWnidom.cjs +0 -3
  201. package/dist/vue-ui-xy-canvas-DHs5sb3t.cjs +0 -9
@@ -1,279 +0,0 @@
1
- import { computed as h, ref as p, watch as H, onMounted as le, openBlock as n, createElementBlock as c, normalizeClass as O, normalizeStyle as R, createBlock as S, createCommentVNode as _, unref as d, createSlots as oe, withCtx as A, renderSlot as x, normalizeProps as Y, guardReactiveProps as q, createVNode as re, Fragment as J, renderList as K, toDisplayString as se } from "vue";
2
- import { u as Q } from "./useNestedProp-S1UXxUgm.js";
3
- import { u as ne, c as ue, t as ie, v as ce, o as ve, e as he, w as V, X as de, i as me, f as fe } from "./index-DDXisDKy.js";
4
- import { _ as ge } from "./Title-DYNLqCCT.js";
5
- import { u as ye, U as pe } from "./usePrinter-8ofTb2MJ.js";
6
- import ke from "./vue-ui-skeleton-B2sRnIXX.js";
7
- import { _ as _e } from "./PackageVersion-DtnhR89q.js";
8
- import { _ as be } from "./_plugin-vue_export-helper-CHgC5LLL.js";
9
- const Ce = ["id"], $e = {
10
- key: 0,
11
- style: "width:100%;background:transparent;padding-bottom:12px"
12
- }, we = ["xmlns", "viewBox"], xe = { key: 0 }, Pe = ["d", "stroke-width", "stroke"], Ie = { key: 1 }, Fe = ["x1", "y1", "x2", "y2", "stroke-width", "stroke"], ze = ["x", "y", "font-size", "fill", "font-weight", "text-anchor"], Oe = {
13
- key: 3,
14
- class: "vue-data-ui-watermark"
15
- }, Se = {
16
- __name: "vue-ui-tiremarks",
17
- props: {
18
- config: {
19
- type: Object,
20
- default() {
21
- return {};
22
- }
23
- },
24
- dataset: {
25
- type: Object,
26
- default() {
27
- return {};
28
- }
29
- }
30
- },
31
- setup(W, { expose: Z }) {
32
- const v = W, { vue_ui_tiremarks: ee } = ne(), F = h(() => !!v.dataset && Object.keys(v.dataset).length), z = p(ue()), N = p(null), G = p(0), L = p(0), e = h({
33
- get: () => M(),
34
- set: (t) => t
35
- });
36
- function M() {
37
- const t = Q({
38
- userConfig: v.config,
39
- defaultConfig: ee
40
- });
41
- return t.theme ? {
42
- ...Q({
43
- userConfig: ie.vue_ui_tiremarks[t.theme] || v.config,
44
- defaultConfig: t
45
- })
46
- } : t;
47
- }
48
- H(() => v.config, (t) => {
49
- e.value = M(), X(), L.value += 1;
50
- }, { deep: !0 });
51
- const { isPrinting: U, isImaging: j, generatePdf: B, generateImage: E } = ye({
52
- elementId: z.value,
53
- fileName: e.value.style.chart.title.text || "vue-ui-tiremarks"
54
- }), r = p(e.value.style.chart.animation.use ? 0 : ce(v.dataset.percentage));
55
- H(() => v.dataset, (t) => {
56
- e.value.style.chart.animation.use ? T(t.percentage) : r.value = t.percentage || 0;
57
- }, { deep: !0 }), le(() => {
58
- X();
59
- });
60
- function T(t) {
61
- let u = e.value.style.chart.animation.speed;
62
- const a = Math.abs(t - r.value) / (u * 120);
63
- function o() {
64
- r.value < t ? r.value = Math.min(r.value + a, t) : r.value > t && (r.value = Math.max(r.value - a, t)), r.value !== t && requestAnimationFrame(o);
65
- }
66
- o();
67
- }
68
- function X() {
69
- ve(v.dataset) && he({
70
- componentName: "VueUiTiremarks",
71
- type: "dataset"
72
- }), T(v.dataset.percentage || 0);
73
- }
74
- const k = h(() => e.value.style.chart.layout.display === "vertical"), s = h(() => {
75
- const t = {
76
- top: 48,
77
- left: 64,
78
- right: 64,
79
- bottom: 48
80
- };
81
- return k.value ? {
82
- top: e.value.style.chart.percentage.verticalPosition === "top" ? t.top : 3,
83
- left: 3,
84
- right: 3,
85
- bottom: e.value.style.chart.percentage.verticalPosition === "bottom" ? t.bottom : 3
86
- } : {
87
- top: 0,
88
- bottom: 0,
89
- left: e.value.style.chart.percentage.horizontalPosition === "left" ? t.left : 3,
90
- right: e.value.style.chart.percentage.horizontalPosition === "right" ? t.right : 10
91
- };
92
- }), P = h(() => Object.values(s.value).reduce((t, u) => t + u, 0)), l = h(() => ({
93
- height: k.value ? 312 : 56,
94
- width: k.value ? 56 : 312
95
- })), te = p(100);
96
- h(() => v.dataset.percentage / te.value);
97
- const i = h(() => k.value ? {
98
- mark: (l.value.height - P.value) / 100 * 0.5,
99
- space: (l.value.height - P.value) / 100 * 0.5
100
- } : {
101
- mark: (l.value.width - P.value) / 100 * 0.5,
102
- space: (l.value.width - P.value) / 100 * 0.5
103
- }), D = h(() => {
104
- const t = [];
105
- for (let a = 0; a < 100; a += 1) {
106
- const o = e.value.style.chart.layout.ticks.gradient.show ? V(e.value.style.chart.layout.activeColor, a / 100 * (e.value.style.chart.layout.ticks.gradient.shiftHueIntensity / 100)) : e.value.style.chart.layout.activeColor;
107
- if (k.value) {
108
- const C = e.value.style.chart.layout.crescendo ? (100 - a) * (l.value.width - s.value.left - s.value.right) / 100 / 3 : 0, m = s.value.left + 4 + C, f = l.value.width - s.value.right - 4 - C, g = l.value.height - s.value.bottom - a * i.value.mark - a * i.value.space - i.value.mark, y = l.value.height - s.value.bottom - a * i.value.mark - a * i.value.space - i.value.mark, $ = (f - m) / e.value.style.chart.layout.curveAngleX, w = e.value.style.chart.layout.curveAngleY * ((1 + a) / 100);
109
- t.push({
110
- x1: m,
111
- x2: f,
112
- y1: g,
113
- y2: y,
114
- curve: `M ${m} ${g} C ${m + $} ${g - w}, ${f - $} ${y - w}, ${f} ${y}`,
115
- color: o
116
- });
117
- } else {
118
- const C = e.value.style.chart.layout.crescendo ? (100 - a) * (l.value.height - s.value.top - s.value.bottom) / 100 / 3 : 0, m = s.value.left + a * i.value.mark + a * i.value.space - i.value.mark, f = m, g = s.value.top + 4 + C, y = l.value.height - s.value.bottom - 4 - C, $ = e.value.style.chart.layout.curveAngleY * ((1 + a) / 100), w = (y - g) / e.value.style.chart.layout.curveAngleX;
119
- t.push({
120
- x1: m,
121
- x2: f,
122
- y1: g,
123
- y2: y,
124
- curve: `M ${m} ${g} C ${m + $} ${g + w}, ${f + $} ${y - w}, ${f} ${y}`,
125
- color: o
126
- });
127
- }
128
- }
129
- return t;
130
- }), b = h(() => {
131
- let t, u, a;
132
- const o = e.value.style.chart.percentage.fontSize / 3;
133
- return k.value ? e.value.style.chart.percentage.verticalPosition === "top" ? (t = l.value.width / 2, u = s.value.top / 2, a = "middle") : e.value.style.chart.percentage.verticalPosition === "bottom" && (t = l.value.width / 2, u = l.value.height - s.value.bottom / 2 + o, a = "middle") : e.value.style.chart.percentage.horizontalPosition === "left" ? (t = 4, u = l.value.height / 2 + o, a = "start") : e.value.style.chart.percentage.horizontalPosition === "right" && (t = l.value.width - s.value.right + 8, u = l.value.height / 2 + o, a = "start"), {
134
- x: t,
135
- y: u,
136
- textAnchor: a,
137
- bold: e.value.style.chart.percentage.bold,
138
- fontSize: e.value.style.chart.percentage.fontSize,
139
- fill: e.value.style.chart.percentage.color
140
- };
141
- }), I = p(!1);
142
- function ae(t) {
143
- I.value = t, G.value += 1;
144
- }
145
- return Z({
146
- generatePdf: B,
147
- generateImage: E
148
- }), (t, u) => (n(), c("div", {
149
- ref_key: "tiremarksChart",
150
- ref: N,
151
- class: O(`vue-ui-tiremarks ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
152
- style: R(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;${e.value.style.chart.title.text ? "" : "padding-top:36px"};background:${e.value.style.chart.backgroundColor}`),
153
- id: z.value
154
- }, [
155
- e.value.style.chart.title.text ? (n(), c("div", $e, [
156
- (n(), S(ge, {
157
- key: `title_${L.value}`,
158
- config: {
159
- title: {
160
- cy: "wheel-title",
161
- ...e.value.style.chart.title
162
- },
163
- subtitle: {
164
- cy: "wheel-subtitle",
165
- ...e.value.style.chart.title.subtitle
166
- }
167
- }
168
- }, null, 8, ["config"]))
169
- ])) : _("", !0),
170
- e.value.userOptions.show && F.value ? (n(), S(pe, {
171
- ref: "details",
172
- key: `user_options_${G.value}`,
173
- backgroundColor: e.value.style.chart.backgroundColor,
174
- color: e.value.style.chart.color,
175
- isPrinting: d(U),
176
- isImaging: d(j),
177
- uid: z.value,
178
- hasPdf: e.value.userOptions.buttons.pdf,
179
- hasImg: e.value.userOptions.buttons.img,
180
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
181
- hasXls: !1,
182
- isFullscreen: I.value,
183
- titles: { ...e.value.userOptions.buttonTitles },
184
- chartElement: N.value,
185
- position: e.value.userOptions.position,
186
- onToggleFullscreen: ae,
187
- onGeneratePdf: d(B),
188
- onGenerateImage: d(E)
189
- }, oe({ _: 2 }, [
190
- t.$slots.optionPdf ? {
191
- name: "optionPdf",
192
- fn: A(() => [
193
- x(t.$slots, "optionPdf", {}, void 0, !0)
194
- ]),
195
- key: "0"
196
- } : void 0,
197
- t.$slots.optionImg ? {
198
- name: "optionImg",
199
- fn: A(() => [
200
- x(t.$slots, "optionImg", {}, void 0, !0)
201
- ]),
202
- key: "1"
203
- } : void 0,
204
- t.$slots.optionFullscreen ? {
205
- name: "optionFullscreen",
206
- fn: A(({ toggleFullscreen: a, isFullscreen: o }) => [
207
- x(t.$slots, "optionFullscreen", Y(q({ toggleFullscreen: a, isFullscreen: o })), void 0, !0)
208
- ]),
209
- key: "2"
210
- } : void 0
211
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasImg", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "onGeneratePdf", "onGenerateImage"])) : _("", !0),
212
- F.value ? (n(), c("svg", {
213
- key: 2,
214
- xmlns: d(de),
215
- class: O({ "vue-data-ui-fullscreen--on": I.value, "vue-data-ui-fulscreen--off": !I.value }),
216
- viewBox: `0 0 ${l.value.width} ${l.value.height}`,
217
- style: R(`max-width:100%; overflow: visible; background:transparent;color:${e.value.style.chart.color}`)
218
- }, [
219
- re(_e),
220
- e.value.style.chart.layout.curved ? (n(), c("g", xe, [
221
- (n(!0), c(J, null, K(D.value, (a, o) => (n(), c("path", {
222
- d: a.curve,
223
- "stroke-width": i.value.mark,
224
- stroke: r.value >= o ? a.color : e.value.style.chart.layout.inactiveColor,
225
- "stroke-linecap": "round",
226
- fill: "none",
227
- class: O({ "vue-ui-tick-animated": e.value.style.chart.animation.use && o <= r.value })
228
- }, null, 10, Pe))), 256))
229
- ])) : (n(), c("g", Ie, [
230
- (n(!0), c(J, null, K(D.value, (a, o) => (n(), c("line", {
231
- x1: a.x1,
232
- y1: a.y1,
233
- x2: a.x2,
234
- y2: a.y2,
235
- "stroke-width": i.value.mark,
236
- stroke: r.value >= o ? a.color : e.value.style.chart.layout.inactiveColor,
237
- "stroke-linecap": "round"
238
- }, null, 8, Fe))), 256))
239
- ])),
240
- e.value.style.chart.percentage.show ? (n(), c("text", {
241
- key: 2,
242
- x: b.value.x,
243
- y: b.value.y,
244
- "font-size": b.value.fontSize,
245
- fill: e.value.style.chart.layout.ticks.gradient.show && e.value.style.chart.percentage.useGradientColor ? d(V)(e.value.style.chart.layout.activeColor, r.value / 100 * (e.value.style.chart.layout.ticks.gradient.shiftHueIntensity / 100)) : e.value.style.chart.percentage.color,
246
- "font-weight": b.value.bold ? "bold" : "normal",
247
- "text-anchor": b.value.textAnchor
248
- }, se(d(me)(
249
- e.value.style.chart.percentage.formatter,
250
- r.value,
251
- d(fe)({
252
- v: r.value,
253
- s: "%",
254
- r: e.value.style.chart.percentage.rounding
255
- })
256
- )), 9, ze)) : _("", !0),
257
- x(t.$slots, "svg", { svg: l.value }, void 0, !0)
258
- ], 14, we)) : _("", !0),
259
- t.$slots.watermark ? (n(), c("div", Oe, [
260
- x(t.$slots, "watermark", Y(q({ isPrinting: d(U) || d(j) })), void 0, !0)
261
- ])) : _("", !0),
262
- F.value ? _("", !0) : (n(), S(ke, {
263
- key: 4,
264
- config: {
265
- type: "tiremarks",
266
- style: {
267
- backgroundColor: e.value.style.chart.backgroundColor,
268
- tiremarks: {
269
- color: "#CCCCCC"
270
- }
271
- }
272
- }
273
- }, null, 8, ["config"]))
274
- ], 14, Ce));
275
- }
276
- }, Ee = /* @__PURE__ */ be(Se, [["__scopeId", "data-v-9130298e"]]);
277
- export {
278
- Ee as default
279
- };
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-C7_6YjWN.cjs"),$e=require("./Title-C-lm3Mkl.cjs"),ce=require("./usePrinter-8EP4iaGm.cjs"),Se=require("./Tooltip-t-3mVhcz.cjs"),Ne=require("./Legend-Dj9KiaLv.cjs"),_e=require("./vue-ui-skeleton-CGV1dEUD.cjs"),Be=require("./DataTable-BTgMVOwp.cjs"),ze=require("./vue-ui-accordion-Cc9958th.cjs"),de=require("./useResponsive-B3TrDDIG.cjs"),ve=require("./useNestedProp-CC9zGr7C.cjs"),Pe=require("./PackageVersion-D4D0WicU.cjs"),Oe=require("./_plugin-vue_export-helper-BHFhmbuH.cjs");function he(n,d){const s=n.length;if(s===0)throw new Error(`Max aspect ratio cannot be computed: ${n} is an empty array`);{let u=1/0,i=-1/0,v=0;for(let f=0;f<s;f+=1){const p=n[f].normalizedValue;p<u&&(u=p),p>i&&(i=p),v+=p}return Math.max(d**2*i/v**2,v**2/(d**2*u))}}function pe(n){const{xOffset:d,yOffset:s,width:u,height:i}=n;return{x0:d,y0:s,x1:d+u,y1:s+i}}function Ve(n,d,s){if(n.length===0)return!0;{const u=n.concat(d),i=he(n,s),v=he(u,s);return i>=v}}function Ee(n){const d=[],s=n.length;for(let u=0;u<s;u+=1){const i=n[u],v=i.length;for(let h=0;h<v;h+=1)d.push(i[h])}return d}function Le(n,d){const s={...d,children:n};return ge(s)}function Re(n){return(n.x1-n.x0)*(n.y1-n.y0)}function fe(n,d){const{width:s,height:u,xOffset:i,yOffset:v}=G(d),h=n.length,f=n.map(m=>m.normalizedValue||0).reduce((m,k)=>m+k,0),p=f/u,C=f/s;let b=i,w=v;const g=[];if(s>=u){for(let m=0;m<h;m+=1){const k=n[m],x=w+k.normalizedValue/p,_={x0:b,y0:w,x1:b+p,y1:x},T=Object.assign({},k,_);w=x,g.push(T)}return g}else{for(let m=0;m<h;m+=1){const k=n[m],x=b+k.normalizedValue/C,_={x0:b,y0:w,x1:x,y1:w+C},T=Object.assign({},k,_);b=x,g.push(T)}return g}}function Fe(n){const d=G(n),s=d.width,u=d.height;return Math.min(s,u)}function Ie(n,d){const s=n.length,u=n.map(p=>p.value??0).reduce((p,C)=>p+C,0),i=d/u,v=[];let h,f;for(let p=0;p<s;p+=1)f=n[p],h=Object.assign({},f,{normalizedValue:f.value*(i||0)}),v.push(h);return v}function G(n){const{x0:d,y0:s,x1:u,y1:i}=n;return{xOffset:d,yOffset:s,width:u-d,height:i-s}}function De(n,d,s,u){let i=n,v=d,h=s,f=u;for(;;){const p=i.length;if(p===0){const g=fe(v,h);return f.concat(g)}const C=Fe(h),b=i[0],w=i.slice(1,p);if(Ve(v,b,C)){const g=v.concat(b);i=w,v=g,h=h,f=f}else{const g=v.length;let m=0;for(let T=0;T<g;T+=1)m+=v[T].normalizedValue;const k=qe(h,m),x=fe(v,h),_=f.concat(x);i=i,v=[],h=k,f=_}}}function ge(n){if(typeof n.children>"u"||!n.children.length)return[n];{const d=Ie(n.children,Re(n)),s=De(d,[],n,[]),u=s.length,i=[];for(let h=0;h<u;h+=1)i.push(ge(s[h]));return Ee(i)}}function qe(n,d){const{width:s,height:u,xOffset:i,yOffset:v}=G(n);if(s>=u){const h=d/u,f=s-h,p={xOffset:i+h,yOffset:v,width:f,height:u};return pe(p)}else{const h=d/s,f=u-h,p={xOffset:i,yOffset:v+h,width:s,height:f};return pe(p)}}const Ae=n=>(e.pushScopeId("data-v-f7f2df00"),n=n(),e.popScopeId(),n),He=["id"],Me=["xmlns","viewBox"],We={key:0},Ue=["id"],Ge=["stop-color"],je=["stop-color"],Xe=["x","y","height","width","fill","rx","stroke","stroke-width","onClick","onMouseenter"],Ye=["x","y","height","width"],Ze={style:{width:"100%",height:"100%"},class:"vue-ui-treemap-cell"},Je=Ae(()=>e.createElementVNode("br",null,null,-1)),Ke={key:3,class:"vue-data-ui-watermark"},Qe=["onClick"],et={key:0},tt={key:1},lt=["innerHTML"],ot={__name:"vue-ui-treemap",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(n,{expose:d,emit:s}){const u=n,{vue_ui_treemap:i}=r.useConfig(),v=e.computed(()=>!!u.dataset&&u.dataset.length),h=e.computed(()=>/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),f=e.ref(r.createUid()),p=e.ref(!1),C=e.ref(""),b=e.ref(!1),w=e.ref(0),g=e.ref([]),m=e.ref(null),k=e.ref(null),x=e.ref(null),_=e.ref(0),T=e.ref(0),j=e.ref(0),t=e.computed({get:()=>X(),set:l=>l});function X(){const l=ve.useNestedProp({userConfig:u.config,defaultConfig:i});return l.theme?{...ve.useNestedProp({userConfig:r.themes.vue_ui_treemap[l.theme]||u.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>u.config,l=>{t.value=X(),_.value+=1,T.value+=1,j.value+=1},{deep:!0});const{isPrinting:Y,isImaging:Z,generatePdf:J,generateImage:K}=ce.usePrinter({elementId:`treemap_${f.value}`,fileName:t.value.style.chart.title.text||"vue-ui-treemap"}),D=e.computed(()=>r.convertCustomPalette(t.value.customPalette)),B=e.ref({showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),z=e.ref({height:t.value.style.chart.height,width:t.value.style.chart.width}),O=e.computed(()=>({bottom:z.value.height-t.value.style.chart.padding.bottom,height:z.value.height-t.value.style.chart.padding.top-t.value.style.chart.padding.bottom,left:t.value.style.chart.padding.left,right:z.value.width-t.value.style.chart.padding.right,top:t.value.style.chart.padding.top,vbHeight:z.value.height,vbWidth:z.value.width,width:z.value.width-t.value.style.chart.padding.left-t.value.style.chart.padding.right}));function Q(l){l.forEach((a,o)=>{a.id=r.createUid(),a.color=r.convertColorToHex(a.color)||D.value[o]||r.palette[o]||r.palette[o%r.palette.length],a.children&&(a.children.forEach(c=>{c.parentId=a.id,c.color=a.color}),Q(a.children))})}const V=e.ref(u.dataset),q=e.ref(null);e.onMounted(()=>{me()});function me(){if(r.objectIsEmpty(u.dataset)&&r.error({componentName:"VueUiTreemap",type:"dataset"}),Q(V.value),t.value.responsive){const l=de.throttle(()=>{const{width:a,height:o}=de.useResponsive({chart:m.value,title:t.value.style.chart.title.text?k.value:null,legend:t.value.style.chart.legend.show?x.value:null});z.value.width=a,z.value.height=o});q.value=new ResizeObserver(l),q.value.observe(m.value.parentNode)}}e.onBeforeUnmount(()=>{q.value&&q.value.disconnect()});const M=e.ref(V.value),F=e.computed(()=>M.value.map((l,a)=>({...l,color:r.convertColorToHex(l.color)||D.value[a]||r.palette[a]||r.palette[a%r.palette.length]})).filter(l=>!g.value.includes(l.id))),L=e.computed(()=>V.value.filter(l=>!g.value.includes(l.id)).map(l=>l.value||0).reduce((l,a)=>l+a,0)),ee=e.computed({get(){let l=[...F.value];return t.value.style.chart.layout.sorted&&(l=[...F.value].sort((a,o)=>o.value-a.value)),l.map(a=>({...a}))},set(l){return l}});function te(l,a){return l.value/a}function ye(l,a,o){const c=t.value.style.chart.layout.rects.colorRatio-te(a,o);return r.lightenHexColor(l,c<0?0:c)}function le(l,a,o,c){return l.map((y,P)=>{const H=ye(r.convertColorToHex(a)||D.value[P]||r.palette[P]||r.palette[P%r.palette.length],y,c),Te=te(y,c);return{...y,color:H,proportion:Te,parentName:o,children:y.children?le(y.children,H,y.name,c):void 0}})}const I=e.computed(()=>Le(ee.value.map((l,a)=>{const o=l.children?l.children.reduce((c,y)=>c+y.value,0):l.value;return{value:l.value,id:l.id,children:l.children?le(l.children.sort((c,y)=>y.value-c.value),l.color,l.name,o):void 0,color:l.color,name:l.name}}),{x0:O.value.left*2,y0:O.value.top,x1:O.value.width,y1:O.value.height}));function oe({y0:l,y1:a}){return a-l<=0?1e-4:a-l}function ae({x0:l,x1:a}){return a-l<=0?1e-4:a-l}function E(l){const a=t.value.style.chart.layout.labels.fontSize*(l.proportion*2>1?1:l.proportion*2);return a<t.value.style.chart.layout.labels.minFontSize?t.value.style.chart.layout.labels.minFontSize:a}function be(l){b.value=l,w.value+=1}const R=e.computed(()=>({startX:0,startY:0,width:O.value.vbWidth,height:O.value.vbHeight})),$=e.ref(!1);function W(l,a=V.value){for(const o of a){if(o.id===l)return o;if(o.children){const c=W(l,o.children);if(c)return c}}return null}function ke(l){if($.value)s("selectDatapoint",void 0),M.value=V.value;else{if(s("selectDatapoint",l),!W(l.parentId))return;M.value=[W(l.parentId)]}$.value=!$.value}const S=e.ref(null),ne=e.computed(()=>V.value.map((l,a)=>({...l,color:r.convertColorToHex(l.color)||D.value[a]||r.palette[a]||r.palette[a%r.palette.length],shape:"square"})).sort((l,a)=>a.value-l.value).map((l,a)=>({...l,proportion:l.value/V.value.map(o=>o.value).reduce((o,c)=>o+c,0),opacity:g.value.includes(l.id)?.5:1}))),Ce=e.computed(()=>({cy:"treemap-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":""}));function re(l){$.value=!1,S.value=null,g.value.includes(l.id)?g.value=g.value.filter(a=>a!==l.id):g.value.length<u.dataset.length-1&&g.value.push(l.id),s("selectLegend",ee.value)}const U=e.ref(null);function we({datapoint:l,seriesIndex:a}){S.value=l,U.value={datapoint:l,seriesIndex:a,config:t.value,series:F.value};const o=t.value.style.chart.tooltip.customFormat;if(r.isFunction(o)&&r.functionReturnsString(()=>o({seriesIndex:a,datapoint:l,series:F.value,config:t.value})))C.value=o({seriesIndex:a,datapoint:l,series:F.value,config:t.value});else{let c="";c+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${l.name}</div>`,c+=`<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><rect x="0" y="0" height="12" width="12" stroke="none" fill="${l.color}"/></svg>`,c+=`<b>${r.applyDataLabel(t.value.style.chart.layout.labels.formatter,l.value,r.dataLabel({p:t.value.style.chart.layout.labels.prefix,v:l.value,s:t.value.style.chart.layout.labels.suffix,r:t.value.style.chart.tooltip.roundingValue}),{datapoint:l,seriesIndex:a})}</b>`,C.value=`<div>${c}</div>`}p.value=!0}const N=e.computed(()=>{const l=I.value.map(o=>({name:o.name,color:o.color})),a=I.value.map(o=>o.value);return{head:l,body:a}});function ue(){e.nextTick(()=>{const l=N.value.head.map((c,y)=>[[c.name],[N.value.body[y]],[isNaN(N.value.body[y]/L.value)?"-":N.value.body[y]/L.value*100]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],["val"],["%"]]].concat(l),o=r.createCsvContent(a);r.downloadCsv({csvContent:o,title:t.value.style.chart.title.text||"vue-ui-treemap"})})}const A=e.computed(()=>{const l=[t.value.table.columnNames.series,t.value.table.columnNames.value,t.value.table.columnNames.percentage],a=N.value.head.map((y,P)=>{const H=r.applyDataLabel(t.value.style.chart.layout.labels.formatter,N.value.body[P],r.dataLabel({p:t.value.style.chart.layout.labels.prefix,v:N.value.body[P],s:t.value.style.chart.layout.labels.suffix,r:t.value.table.td.roundingValue}));return[{color:y.color,name:y.name,shape:"square"},H,isNaN(N.value.body[P]/L.value)?"-":r.dataLabel({v:N.value.body[P]/L.value*100,s:"%",r:t.value.table.td.roundingPercentage})]}),o={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};return{colNames:[t.value.table.columnNames.series,t.value.table.columnNames.value],head:l,body:a,config:o}});function xe(){return I.value}function se(){B.value.showTable=!B.value.showTable}function ie(){B.value.showTooltip=!B.value.showTooltip}return d({getData:xe,generateCsv:ue,generateImage:K,generatePdf:J,toggleTable:se,toggleTooltip:ie}),(l,a)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"treemapChart",ref:m,class:e.normalizeClass(`vue-ui-treemap ${b.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; ${t.value.responsive?"height: 100%;":""} text-align:center;${t.value.style.chart.title.text?"":"padding-top:36px"};background:${t.value.style.chart.backgroundColor}`),id:`treemap_${f.value}`},[t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:k,style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:6px`)},[(e.openBlock(),e.createBlock($e._sfc_main,{key:`title_${_.value}`,config:{title:{cy:"treemap-div-title",...t.value.style.chart.title},subtitle:{cy:"treemap-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],4)):e.createCommentVNode("",!0),t.value.userOptions.show&&v.value?(e.openBlock(),e.createBlock(ce.UserOptions,{ref:"details",key:`user_option_${w.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(Y),isImaging:e.unref(Z),uid:f.value,hasTooltip:t.value.userOptions.buttons.tooltip&&t.value.style.chart.tooltip.show,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:b.value,isTooltip:B.value.showTooltip,titles:{...t.value.userOptions.buttonTitles},chartElement:m.value,position:t.value.userOptions.position,onToggleFullscreen:be,onGeneratePdf:e.unref(J),onGenerateCsv:ue,onGenerateImage:e.unref(K),onToggleTable:se,onToggleTooltip:ie},e.createSlots({_:2},[l.$slots.optionTooltip?{name:"optionTooltip",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:o,isFullscreen:c})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:c})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","isFullscreen","isTooltip","titles","chartElement","position","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),v.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(r.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":b.value,"vue-data-ui-fulscreen--off":!b.value,"vue-data-ui-zoom-plus":!$.value,"vue-data-ui-zoom-minus":$.value}),viewBox:`${R.value.startX} ${R.value.startY} ${R.value.width<=0?10:R.value.width} ${R.value.height<=0?10:R.value.height}`,style:e.normalizeStyle(`max-width:100%; overflow: hidden; background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(Pe._sfc_main),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(o,c)=>(e.openBlock(),e.createElementBlock("g",null,[t.value.style.chart.layout.rects.gradient.show?(e.openBlock(),e.createElementBlock("defs",We,[e.createElementVNode("radialGradient",{id:`tgrad_${o.id}`,gradientTransform:"translate(-1, -1.000001) scale(2, 2)"},[e.createElementVNode("stop",{offset:"18%","stop-color":o.color},null,8,Ge),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(r.lightenHexColor)(o.color,t.value.style.chart.layout.rects.gradient.intensity/100)},null,8,je)],8,Ue)])):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(o,c)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("rect",{x:o.x0,y:o.y0,height:oe(o),width:ae(o),fill:h.value?o.color:t.value.style.chart.layout.rects.gradient.show?`url(#tgrad_${o.id})`:o.color,rx:t.value.style.chart.layout.rects.borderRadius,stroke:S.value&&S.value.id===o.id?t.value.style.chart.layout.rects.selected.stroke:t.value.style.chart.layout.rects.stroke,"stroke-width":S.value&&S.value.id===o.id?t.value.style.chart.layout.rects.selected.strokeWidth:t.value.style.chart.layout.rects.strokeWidth,onClick:y=>ke(o),onMouseenter:()=>we({datapoint:o,seriesIndex:c}),onMouseleave:a[0]||(a[0]=y=>{S.value=null,p.value=!1}),style:e.normalizeStyle(`opacity:${S.value?S.value.id===o.id?1:t.value.style.chart.layout.rects.selected.unselectedOpacity:1}`),class:"vue-ui-treemap-rect"},null,44,Xe),(e.openBlock(),e.createElementBlock("foreignObject",{x:o.x0,y:o.y0,height:oe(o),width:ae(o),class:"vue-ui-treemap-cell-foreignObject"},[e.createElementVNode("div",Ze,[t.value.style.chart.layout.labels.showDefaultLabels&&(o.proportion>t.value.style.chart.layout.labels.hideUnderProportion||$.value)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"vue-ui-treemap-cell-default",style:e.normalizeStyle(`width:calc(100% - ${E(o)/1.5}px);text-align:left;line-height:${E(o)<14?14:E(o)}px;padding:${E(o)/3}px; color:${e.unref(r.adaptColorToBackground)(o.color)}`)},[e.createElementVNode("span",{style:e.normalizeStyle(`width:100%;font-size:${E(o)}px;`)},e.toDisplayString(o.name),5),Je,e.createElementVNode("span",{style:e.normalizeStyle(`width:100%;font-size:${E(o)}px;`)},e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.labels.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.labels.prefix,v:o.value,s:t.value.style.chart.layout.labels.suffix,r:t.value.style.chart.layout.labels.rounding}),{datapoint:o})),5)],4)):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"rect",e.normalizeProps(e.guardReactiveProps({rect:o,shouldShow:o.proportion>t.value.style.chart.layout.labels.hideUnderProportion||$.value,fontSize:E(o),isZoom:$.value,textColor:e.unref(r.adaptColorToBackground)(o.color)})),void 0,!0)])],8,Ye))]))),256)),e.renderSlot(l.$slots,"svg",e.normalizeProps(e.guardReactiveProps({svg:O.value,isZoom:$.value,rect:S.value,config:t.value})),void 0,!0)],14,Me)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Ke,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(Y)||e.unref(Z)})),void 0,!0)])):e.createCommentVNode("",!0),v.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(_e.default,{key:4,config:{type:"treemap",style:{backgroundColor:t.value.style.chart.backgroundColor,treemap:{color:"#CCCCCC"}}}},null,8,["config"])),e.createElementVNode("div",{ref_key:"chartLegend",ref:x},[t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(Ne.Legend,{key:`legend_${j.value}`,legendSet:ne.value,config:Ce.value,id:`treemap_legend_${f.value}`,onClickMarker:a[1]||(a[1]=({legend:o})=>re(o))},{item:e.withCtx(({legend:o,index:c})=>[e.createElementVNode("div",{onClick:y=>re(o),style:e.normalizeStyle(`opacity:${g.value.includes(o.id)?.5:1}`)},[e.createTextVNode(e.toDisplayString(o.name)+": "+e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.labels.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.labels.prefix,v:o.value,s:t.value.style.chart.layout.labels.suffix,r:t.value.style.chart.legend.roundingValue}),{datapoint:o}))+" ",1),g.value.includes(o.id)?(e.openBlock(),e.createElementBlock("span",tt," ( - % ) ")):(e.openBlock(),e.createElementBlock("span",et," ("+e.toDisplayString(isNaN(o.value/L.value)?"-":(o.value/L.value*100).toFixed(t.value.style.chart.legend.roundingPercentage))+"%) ",1))],12,Qe)]),_:1},8,["legendSet","config","id"])):e.renderSlot(l.$slots,"legend",{key:1,legend:ne.value},void 0,!0)],512),e.createVNode(Se._sfc_main,{show:B.value.showTooltip&&p.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,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,position:t.value.style.chart.tooltip.position,offsetY:t.value.style.chart.tooltip.offsetY,parent:m.value,content:C.value,isCustom:e.unref(r.isFunction)(t.value.style.chart.tooltip.customFormat)},{"tooltip-before":e.withCtx(()=>[e.renderSlot(l.$slots,"tooltip-before",e.normalizeProps(e.guardReactiveProps({...U.value})),void 0,!0)]),"tooltip-after":e.withCtx(()=>[e.renderSlot(l.$slots,"tooltip-after",e.normalizeProps(e.guardReactiveProps({...U.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","fontSize","borderRadius","borderColor","borderWidth","backgroundOpacity","position","offsetY","parent","content","isCustom"]),v.value?(e.openBlock(),e.createBlock(ze.default,{key:5,hideDetails:"",config:{open:B.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:e.withCtx(()=>[(e.openBlock(),e.createBlock(Be.DataTable,{key:`table_${T.value}`,colNames:A.value.colNames,head:A.value.head,body:A.value.body,config:A.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[2]||(a[2]=o=>B.value.showTable=!1)},{th:e.withCtx(({th:o})=>[e.createElementVNode("div",{innerHTML:o,style:{display:"flex","align-items":"center"}},null,8,lt)]),td:e.withCtx(({td:o})=>[e.createTextVNode(e.toDisplayString(o.name||o),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],14,He))}},at=Oe._export_sfc(ot,[["__scopeId","data-v-f7f2df00"]]);exports.default=at;