vue-data-ui 2.4.57 → 2.4.59

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 (202) hide show
  1. package/README.md +82 -51
  2. package/dist/{Arrow-BhwhLRcU.cjs → Arrow-Dudbi6k5.cjs} +1 -1
  3. package/dist/{Arrow-DelnKkT1.js → Arrow-DzS4HIXj.js} +1 -1
  4. package/dist/{BaseIcon-9gdEHMWK.js → BaseIcon-BbU81zOd.js} +1 -1
  5. package/dist/{BaseIcon-DujPvdJ_.cjs → BaseIcon-DD3GLrhS.cjs} +1 -1
  6. package/dist/{DataTable-BUflha5V.cjs → DataTable-BHCbVv8x.cjs} +1 -1
  7. package/dist/{DataTable-DgbrnD__.js → DataTable-CFUKU8PU.js} +2 -2
  8. package/dist/{Legend-V3K-4ipN.cjs → Legend-BYngLoV6.cjs} +1 -1
  9. package/dist/{Legend-HooNAKB_.js → Legend-f52bnttJ.js} +1 -1
  10. package/dist/{PackageVersion-S3SzpuwC.js → PackageVersion-C_FFs0BP.js} +1 -1
  11. package/dist/{PackageVersion-dQYEsTLp.cjs → PackageVersion-nr7f_VNw.cjs} +1 -1
  12. package/dist/{PenAndPaper-1h87IVla.cjs → PenAndPaper-C9v0NXEg.cjs} +1 -1
  13. package/dist/{PenAndPaper-v846FwcH.js → PenAndPaper-Dx24BtRW.js} +3 -3
  14. package/dist/{Shape-D7aacHaz.js → Shape-Ct2x6qZx.js} +1 -1
  15. package/dist/{Shape-DV5sH0dX.cjs → Shape-Dkt-vkTl.cjs} +1 -1
  16. package/dist/{Slicer-BRxR5OYL.cjs → Slicer-C0cvEMOy.cjs} +1 -1
  17. package/dist/{Slicer-BXCORSCz.js → Slicer-Duke9qno.js} +2 -2
  18. package/dist/{Title-B-EsW0Q2.cjs → Title-CpfNWbUc.cjs} +1 -1
  19. package/dist/{Title-DLjHHdyq.js → Title-zZtEcB9F.js} +1 -1
  20. package/dist/{Tooltip-BDaa-67h.js → Tooltip-DDJ2Wvjy.js} +1 -1
  21. package/dist/{Tooltip-B7gYRLGN.cjs → Tooltip-DZuVxmLc.cjs} +1 -1
  22. package/dist/documentation/installation.md +48 -48
  23. package/dist/{index-CI-N9klv.js → index-B9RAElpI.js} +2 -2
  24. package/dist/index-DaDv7p0W.cjs +9 -0
  25. package/dist/style.css +1 -1
  26. package/dist/{useNestedProp-D-zaZbSR.cjs → useNestedProp-DkpuL8Iv.cjs} +1 -1
  27. package/dist/{useNestedProp-D1eJ0dvv.js → useNestedProp-DuruL3Nt.js} +1 -1
  28. package/dist/{usePrinter-H2UFIe6n.cjs → usePrinter-BIHu0O5X.cjs} +1 -1
  29. package/dist/{usePrinter-CXc8xCKk.js → usePrinter-CwTAwqtF.js} +1 -1
  30. package/dist/{vue-data-ui-CvfX2D1d.cjs → vue-data-ui-BXCJgMfu.cjs} +1 -1
  31. package/dist/{vue-data-ui-DuXblXhF.js → vue-data-ui-yknmkfFy.js} +60 -60
  32. package/dist/vue-data-ui.cjs +1 -1
  33. package/dist/vue-data-ui.js +1 -1
  34. package/dist/{vue-ui-3d-bar-fvTVGk8O.js → vue-ui-3d-bar-BkbLoUhP.js} +170 -158
  35. package/dist/vue-ui-3d-bar-CHnh8ZH_.cjs +19 -0
  36. package/dist/{vue-ui-accordion-paZXh-GD.cjs → vue-ui-accordion-6Clt339w.cjs} +1 -1
  37. package/dist/{vue-ui-accordion-CYLks1fW.js → vue-ui-accordion-rNA598L6.js} +3 -3
  38. package/dist/{vue-ui-age-pyramid-Ch3nY1Dx.js → vue-ui-age-pyramid-C3o5HfRK.js} +176 -164
  39. package/dist/vue-ui-age-pyramid-CKDDaRj_.cjs +1 -0
  40. package/dist/{vue-ui-annotator-BXbLcJ1L.cjs → vue-ui-annotator-BLilhXfT.cjs} +1 -1
  41. package/dist/{vue-ui-annotator-DGupSF-o.js → vue-ui-annotator-huMOA-QF.js} +1 -1
  42. package/dist/{vue-ui-bullet-BSRXabBe.js → vue-ui-bullet-DxYdog9c.js} +155 -143
  43. package/dist/vue-ui-bullet-yTpejKsw.cjs +34 -0
  44. package/dist/{vue-ui-candlestick-Dww4XHwQ.js → vue-ui-candlestick-3lCgRxr0.js} +96 -84
  45. package/dist/vue-ui-candlestick-CmD40PpS.cjs +2 -0
  46. package/dist/vue-ui-carousel-table-BU8oAq6b.cjs +1 -0
  47. package/dist/{vue-ui-carousel-table-BZs-sxxu.js → vue-ui-carousel-table-D3JIrHMF.js} +97 -95
  48. package/dist/vue-ui-chestnut-BWRUxwWm.cjs +6 -0
  49. package/dist/{vue-ui-chestnut-CnupXXAM.js → vue-ui-chestnut-cWFqbqSU.js} +160 -148
  50. package/dist/{vue-ui-cursor-oqfOA98Q.js → vue-ui-cursor-DjWkFQEI.js} +2 -2
  51. package/dist/{vue-ui-cursor-smlBNiGG.cjs → vue-ui-cursor-DzJmB5h9.cjs} +1 -1
  52. package/dist/{vue-ui-dashboard-BNu7yNYm.js → vue-ui-dashboard-1dycrMNM.js} +2 -2
  53. package/dist/{vue-ui-dashboard-Dw_90R29.cjs → vue-ui-dashboard-BOjdgUEm.cjs} +1 -1
  54. package/dist/{vue-ui-digits-_8FbgFrI.cjs → vue-ui-digits-B8TVsqsB.cjs} +1 -1
  55. package/dist/{vue-ui-digits-qztPrOEN.js → vue-ui-digits-C4NWhIjg.js} +2 -2
  56. package/dist/vue-ui-donut-BPz8gXi5.cjs +1 -0
  57. package/dist/{vue-ui-donut-CK9dINFS.js → vue-ui-donut-CXBxDUoh.js} +291 -279
  58. package/dist/{vue-ui-donut-evolution-DpDpYw3f.js → vue-ui-donut-evolution-BgD7rCFk.js} +285 -273
  59. package/dist/vue-ui-donut-evolution-h3ZgYI48.cjs +1 -0
  60. package/dist/vue-ui-dumbbell-BCyFd1Lf.cjs +9 -0
  61. package/dist/{vue-ui-dumbbell-Dx1I89N9.js → vue-ui-dumbbell-DMp-Waih.js} +159 -147
  62. package/dist/{vue-ui-flow-DJNqydD1.js → vue-ui-flow-D-XBMcpC.js} +162 -150
  63. package/dist/vue-ui-flow-DB3_5wEr.cjs +1 -0
  64. package/dist/vue-ui-funnel-DJVmn_pN.cjs +1 -0
  65. package/dist/{vue-ui-funnel-mP8ftcS5.js → vue-ui-funnel-Dxb6o97C.js} +229 -215
  66. package/dist/{vue-ui-galaxy-3cOLS6lh.js → vue-ui-galaxy-C2eHqbLw.js} +148 -136
  67. package/dist/vue-ui-galaxy-CIBBO623.cjs +1 -0
  68. package/dist/{vue-ui-gauge-CN_zo833.js → vue-ui-gauge-B9M8ICMX.js} +199 -185
  69. package/dist/vue-ui-gauge-C_JArbcd.cjs +1 -0
  70. package/dist/vue-ui-gizmo-ETKRu3P5.cjs +1 -0
  71. package/dist/{vue-ui-gizmo-akkNcCWf.js → vue-ui-gizmo-OGIvFCA4.js} +45 -43
  72. package/dist/{vue-ui-heatmap-B3ClLioV.js → vue-ui-heatmap-C2BobYAF.js} +138 -126
  73. package/dist/vue-ui-heatmap-mPZepJ4V.cjs +1 -0
  74. package/dist/{vue-ui-history-plot-C-EqVFW-.js → vue-ui-history-plot-BtBDW5ha.js} +127 -115
  75. package/dist/vue-ui-history-plot-DgEFbRv3.cjs +1 -0
  76. package/dist/{vue-ui-kpi-C-axCKZx.js → vue-ui-kpi-BCwmp6i5.js} +36 -33
  77. package/dist/vue-ui-kpi-DZGoUp6y.cjs +1 -0
  78. package/dist/{vue-ui-mini-loader-Cal5W_q6.cjs → vue-ui-mini-loader-B_I1k10C.cjs} +1 -1
  79. package/dist/{vue-ui-mini-loader-CsZ1zxJz.js → vue-ui-mini-loader-DWQfo-Ey.js} +2 -2
  80. package/dist/{vue-ui-molecule-BvNh7REY.js → vue-ui-molecule-CpWWvLlc.js} +212 -200
  81. package/dist/vue-ui-molecule-CqHsa4N7.cjs +1 -0
  82. package/dist/{vue-ui-mood-radar-C7v4dBNw.js → vue-ui-mood-radar-B4-AQAyE.js} +123 -111
  83. package/dist/vue-ui-mood-radar-Dx6ICJkv.cjs +1 -0
  84. package/dist/{vue-ui-nested-donuts-C08kpvMd.js → vue-ui-nested-donuts-C-afzEvx.js} +156 -144
  85. package/dist/vue-ui-nested-donuts-C8LG5ony.cjs +17 -0
  86. package/dist/vue-ui-onion-KC_zqQyz.cjs +5 -0
  87. package/dist/{vue-ui-onion-CTLBemDj.js → vue-ui-onion-wBz5dln6.js} +125 -113
  88. package/dist/vue-ui-parallel-coordinate-plot-BK1sUOyd.cjs +8 -0
  89. package/dist/{vue-ui-parallel-coordinate-plot-H1FdP6AE.js → vue-ui-parallel-coordinate-plot-BoiKoaod.js} +159 -147
  90. package/dist/vue-ui-quadrant-BJ3gSVgF.cjs +1 -0
  91. package/dist/{vue-ui-quadrant-Dd-LDy4T.js → vue-ui-quadrant-DY6yUyOl.js} +211 -199
  92. package/dist/{vue-ui-quick-chart-BeNivWrg.js → vue-ui-quick-chart-DBH9CgBI.js} +576 -540
  93. package/dist/vue-ui-quick-chart-OHwPApk1.cjs +15 -0
  94. package/dist/{vue-ui-radar-D9U_vOad.js → vue-ui-radar-DYnmlHtt.js} +183 -171
  95. package/dist/vue-ui-radar-nhy4Pqtc.cjs +1 -0
  96. package/dist/{vue-ui-rating-B7AlAqCY.js → vue-ui-rating-3LUgui--.js} +102 -98
  97. package/dist/vue-ui-rating-wl5jkxb5.cjs +1 -0
  98. package/dist/vue-ui-relation-circle-CGkAsJl8.cjs +1 -0
  99. package/dist/{vue-ui-relation-circle-CT23BNcW.js → vue-ui-relation-circle-Da09K_Ce.js} +129 -117
  100. package/dist/{vue-ui-rings-BZ7FYYxr.js → vue-ui-rings-BuVPBXNc.js} +150 -138
  101. package/dist/vue-ui-rings-DZfhibc4.cjs +2 -0
  102. package/dist/{vue-ui-scatter-DMr8OrC3.js → vue-ui-scatter-Bee79rib.js} +320 -308
  103. package/dist/vue-ui-scatter-ChYAlXb_.cjs +1 -0
  104. package/dist/{vue-ui-screenshot-BFV1qEsF.cjs → vue-ui-screenshot-Blz4fiO2.cjs} +1 -1
  105. package/dist/{vue-ui-screenshot-DHiX35pR.js → vue-ui-screenshot-CCnAaGB3.js} +1 -1
  106. package/dist/{vue-ui-skeleton-BIWgLDDf.cjs → vue-ui-skeleton-B24XJJ2p.cjs} +1 -1
  107. package/dist/{vue-ui-skeleton-owIhXtQF.js → vue-ui-skeleton-DVYD_VSe.js} +3 -3
  108. package/dist/vue-ui-smiley-CXOuAdIj.cjs +2 -0
  109. package/dist/{vue-ui-smiley-CCOQ6zjo.js → vue-ui-smiley-CdrTI5Rh.js} +208 -206
  110. package/dist/vue-ui-spark-trend-B08HYMm5.cjs +1 -0
  111. package/dist/{vue-ui-spark-trend-B56DI3Mc.js → vue-ui-spark-trend-Pd3JNy4G.js} +124 -112
  112. package/dist/{vue-ui-sparkbar-CMkozDkx.js → vue-ui-sparkbar-CTDWiUid.js} +100 -96
  113. package/dist/vue-ui-sparkbar-Dq1hwL7i.cjs +1 -0
  114. package/dist/{vue-ui-sparkgauge-De06LRPj.js → vue-ui-sparkgauge-g0C7wuIH.js} +60 -48
  115. package/dist/vue-ui-sparkgauge-il4rmDdv.cjs +1 -0
  116. package/dist/vue-ui-sparkhistogram-CoRPiLpB.cjs +1 -0
  117. package/dist/{vue-ui-sparkhistogram-CBDd7jIn.js → vue-ui-sparkhistogram-Dk8IYZGB.js} +116 -104
  118. package/dist/vue-ui-sparkline-B_1J2ft2.cjs +1 -0
  119. package/dist/{vue-ui-sparkline-BJejWvTN.js → vue-ui-sparkline-Ca1ai-Mq.js} +124 -112
  120. package/dist/{vue-ui-sparkstackbar-DlnmPom2.js → vue-ui-sparkstackbar-CRGrf5y2.js} +85 -81
  121. package/dist/vue-ui-sparkstackbar-tkiKbZHo.cjs +1 -0
  122. package/dist/{vue-ui-stackbar-19XdLQXB.js → vue-ui-stackbar-QaavE5-F.js} +219 -207
  123. package/dist/vue-ui-stackbar-zk1K5gP3.cjs +6 -0
  124. package/dist/vue-ui-strip-plot-8Ksp5AzD.cjs +1 -0
  125. package/dist/{vue-ui-strip-plot-Bly8GoNP.js → vue-ui-strip-plot-gm_lr5A9.js} +113 -101
  126. package/dist/{vue-ui-table-BisPh85-.cjs → vue-ui-table-CPLd7hXM.cjs} +1 -1
  127. package/dist/{vue-ui-table-BUF6Pyfp.js → vue-ui-table-ceYZ6Wzd.js} +1 -1
  128. package/dist/vue-ui-table-heatmap-CSsYOFf7.cjs +1 -0
  129. package/dist/{vue-ui-table-heatmap-By-MmFiq.js → vue-ui-table-heatmap-CWQIOR58.js} +82 -78
  130. package/dist/{vue-ui-table-sparkline-DG70UNkU.js → vue-ui-table-sparkline-BHkqm0Sf.js} +78 -74
  131. package/dist/vue-ui-table-sparkline-hyL_92AC.cjs +1 -0
  132. package/dist/vue-ui-thermometer-CKiohIHn.cjs +1 -0
  133. package/dist/{vue-ui-thermometer-Vr2IP_p0.js → vue-ui-thermometer-Dvk3S7jR.js} +132 -120
  134. package/dist/vue-ui-timer-BUuk2p4C.cjs +64 -0
  135. package/dist/{vue-ui-timer-CD7gFOjN.js → vue-ui-timer-D0tGj6hK.js} +94 -82
  136. package/dist/{vue-ui-tiremarks-44pO3jx1.js → vue-ui-tiremarks-C2G0Sem6.js} +104 -94
  137. package/dist/vue-ui-tiremarks-Csng3xWI.cjs +1 -0
  138. package/dist/{vue-ui-treemap-CyOUM3-P.js → vue-ui-treemap-3iutCx61.js} +336 -332
  139. package/dist/vue-ui-treemap-CJjATl47.cjs +1 -0
  140. package/dist/{vue-ui-vertical-bar-wngOp0Zc.js → vue-ui-vertical-bar-DZz_tUTV.js} +188 -176
  141. package/dist/vue-ui-vertical-bar-DtuEIajX.cjs +4 -0
  142. package/dist/vue-ui-waffle-B-Uf38ml.cjs +1 -0
  143. package/dist/{vue-ui-waffle-CuN7i0ci.js → vue-ui-waffle-Cr4FGNwb.js} +140 -136
  144. package/dist/vue-ui-wheel-Bijmdum9.cjs +1 -0
  145. package/dist/{vue-ui-wheel-B_gLugLx.js → vue-ui-wheel-Da4DH062.js} +100 -88
  146. package/dist/{vue-ui-word-cloud-DKHGS0my.js → vue-ui-word-cloud-C3o4JBD2.js} +132 -120
  147. package/dist/vue-ui-word-cloud-Cjyh1I0J.cjs +1 -0
  148. package/dist/{vue-ui-xy-BK9R8MrJ.js → vue-ui-xy-BX_3ddck.js} +139 -127
  149. package/dist/{vue-ui-xy-canvas-DaT4HoWD.js → vue-ui-xy-canvas-DqzVCtbZ.js} +231 -227
  150. package/dist/{vue-ui-xy-canvas-gDaRsnBI.cjs → vue-ui-xy-canvas-ObtOgMlV.cjs} +2 -2
  151. package/dist/vue-ui-xy-gClSSwyU.cjs +3 -0
  152. package/package.json +1 -1
  153. package/dist/index-o6tXRhOr.cjs +0 -9
  154. package/dist/vue-ui-3d-bar-zKUnnMOY.cjs +0 -19
  155. package/dist/vue-ui-age-pyramid-Bg8Bexac.cjs +0 -1
  156. package/dist/vue-ui-bullet-DqM9h81O.cjs +0 -34
  157. package/dist/vue-ui-candlestick-C0PkovyK.cjs +0 -2
  158. package/dist/vue-ui-carousel-table-DbXCpYUm.cjs +0 -1
  159. package/dist/vue-ui-chestnut-Be4Lagdr.cjs +0 -6
  160. package/dist/vue-ui-donut-B7orj3vV.cjs +0 -1
  161. package/dist/vue-ui-donut-evolution-BmTzjKlH.cjs +0 -1
  162. package/dist/vue-ui-dumbbell-5yfcA-Of.cjs +0 -9
  163. package/dist/vue-ui-flow-Bar7LG9t.cjs +0 -1
  164. package/dist/vue-ui-funnel-lxHehCUr.cjs +0 -1
  165. package/dist/vue-ui-galaxy-B8zbGikp.cjs +0 -1
  166. package/dist/vue-ui-gauge-Bz1nzveF.cjs +0 -1
  167. package/dist/vue-ui-gizmo-C9XQ-7Sj.cjs +0 -1
  168. package/dist/vue-ui-heatmap-BW6dmp8j.cjs +0 -1
  169. package/dist/vue-ui-history-plot-Mp0zDeR-.cjs +0 -1
  170. package/dist/vue-ui-kpi-D8hh3p8f.cjs +0 -1
  171. package/dist/vue-ui-molecule-RkdIX-iW.cjs +0 -1
  172. package/dist/vue-ui-mood-radar-DLpDoq0G.cjs +0 -1
  173. package/dist/vue-ui-nested-donuts-BO249_PV.cjs +0 -17
  174. package/dist/vue-ui-onion-BjNQgHPX.cjs +0 -5
  175. package/dist/vue-ui-parallel-coordinate-plot-CoeVi-98.cjs +0 -8
  176. package/dist/vue-ui-quadrant-D701bdNz.cjs +0 -1
  177. package/dist/vue-ui-quick-chart-CRNEkxoM.cjs +0 -15
  178. package/dist/vue-ui-radar-3W9NRklj.cjs +0 -1
  179. package/dist/vue-ui-rating-DeuaL_cU.cjs +0 -1
  180. package/dist/vue-ui-relation-circle-B8JtK-JM.cjs +0 -1
  181. package/dist/vue-ui-rings-CZCTLghE.cjs +0 -2
  182. package/dist/vue-ui-scatter-DlA0xU5U.cjs +0 -1
  183. package/dist/vue-ui-smiley-BISneB7t.cjs +0 -2
  184. package/dist/vue-ui-spark-trend-lMzod-5S.cjs +0 -1
  185. package/dist/vue-ui-sparkbar-DcdDLl8l.cjs +0 -1
  186. package/dist/vue-ui-sparkgauge-BhwNRzrD.cjs +0 -1
  187. package/dist/vue-ui-sparkhistogram-D00ahrgs.cjs +0 -1
  188. package/dist/vue-ui-sparkline-CY92qVz0.cjs +0 -1
  189. package/dist/vue-ui-sparkstackbar-BjKL_6dq.cjs +0 -1
  190. package/dist/vue-ui-stackbar-T4VBFpDo.cjs +0 -6
  191. package/dist/vue-ui-strip-plot-CtjbMamo.cjs +0 -1
  192. package/dist/vue-ui-table-heatmap-CPn-jC0n.cjs +0 -1
  193. package/dist/vue-ui-table-sparkline-CIDuWZZs.cjs +0 -1
  194. package/dist/vue-ui-thermometer-CMvk1D7J.cjs +0 -1
  195. package/dist/vue-ui-timer-CUHgN89f.cjs +0 -64
  196. package/dist/vue-ui-tiremarks-w_gxHFeB.cjs +0 -1
  197. package/dist/vue-ui-treemap-CFhTEaxa.cjs +0 -1
  198. package/dist/vue-ui-vertical-bar-C51RKLB8.cjs +0 -4
  199. package/dist/vue-ui-waffle-CXZc4t27.cjs +0 -1
  200. package/dist/vue-ui-wheel-u9Vc7ZTZ.cjs +0 -1
  201. package/dist/vue-ui-word-cloud-tSXyXvd6.cjs +0 -1
  202. package/dist/vue-ui-xy-bX3g4COC.cjs +0 -3
@@ -1,13 +1,13 @@
1
- import { computed as g, ref as x, watch as z, onMounted as q, nextTick as H, openBlock as n, createElementBlock as v, normalizeStyle as f, unref as s, renderSlot as b, normalizeProps as L, mergeProps as X, createCommentVNode as c, createElementVNode as d, toDisplayString as p, Fragment as O, renderList as R, guardReactiveProps as J, createVNode as K, createBlock as Q } from "vue";
2
- import { u as Y, c as Z, t as ee, a as te, p as k, b as le, o as ae, e as T, g as oe, d as se, s as $, i as w, f as _, X as ue, w as ne } from "./index-CI-N9klv.js";
3
- import { u as V } from "./useNestedProp-D1eJ0dvv.js";
4
- import ie from "./vue-ui-skeleton-owIhXtQF.js";
5
- import { _ as re } from "./PackageVersion-S3SzpuwC.js";
6
- const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"], pe = ["stop-color"], ye = ["stop-color"], me = ["height", "width", "fill", "rx"], ge = ["height", "width", "fill", "rx"], he = ["height", "width", "fill", "rx"], xe = {
1
+ import { useSlots as X, onMounted as z, computed as g, ref as x, watch as L, nextTick as R, openBlock as n, createElementBlock as c, normalizeStyle as p, unref as s, renderSlot as C, normalizeProps as O, mergeProps as J, createCommentVNode as v, createElementVNode as d, toDisplayString as f, Fragment as T, renderList as K, guardReactiveProps as Q, createVNode as Y, createBlock as Z } from "vue";
2
+ import { u as ee, c as te, t as le, a as ae, p as k, b as oe, o as se, e as V, g as ue, d as ne, s as $, i as b, f as w, X as re, w as ie } from "./index-B9RAElpI.js";
3
+ import { u as E } from "./useNestedProp-DuruL3Nt.js";
4
+ import ce from "./vue-ui-skeleton-DVYD_VSe.js";
5
+ import { _ as ve } from "./PackageVersion-C_FFs0BP.js";
6
+ const de = ["onClick"], pe = { key: 1 }, fe = ["xmlns", "viewBox"], ye = ["id"], me = ["stop-color"], ge = ["stop-color"], he = ["height", "width", "fill", "rx"], xe = ["height", "width", "fill", "rx"], ke = ["height", "width", "fill", "rx"], be = {
7
7
  key: 2,
8
8
  ref: "source",
9
9
  dir: "auto"
10
- }, $e = {
10
+ }, Ae = {
11
11
  __name: "vue-ui-sparkbar",
12
12
  props: {
13
13
  config: {
@@ -31,34 +31,38 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
31
31
  }
32
32
  },
33
33
  emits: ["selectDatapoint"],
34
- setup(C, { emit: E }) {
35
- const a = C, { vue_ui_sparkbar: B } = Y(), S = g(() => !!a.dataset && a.dataset.length), A = x(Z()), e = g({
34
+ setup(_, { emit: B }) {
35
+ const a = _, { vue_ui_sparkbar: M } = ee(), U = X();
36
+ z(() => {
37
+ U["chart-background"] && console.warn("VueUiSparkbar does not support the #chart-background slot.");
38
+ });
39
+ const S = g(() => !!a.dataset && a.dataset.length), A = x(te()), e = g({
36
40
  get: () => N(),
37
41
  set: (t) => t
38
42
  });
39
43
  function N() {
40
- const t = V({
44
+ const t = E({
41
45
  userConfig: a.config,
42
- defaultConfig: B
46
+ defaultConfig: M
43
47
  });
44
48
  return t.theme ? {
45
- ...V({
46
- userConfig: ee.vue_ui_sparkbar[t.theme] || a.config,
49
+ ...E({
50
+ userConfig: le.vue_ui_sparkbar[t.theme] || a.config,
47
51
  defaultConfig: t
48
52
  }),
49
- customPalette: te[t.theme] || k
53
+ customPalette: ae[t.theme] || k
50
54
  } : t;
51
55
  }
52
- z(() => a.config, (t) => {
56
+ L(() => a.config, (t) => {
53
57
  e.value = N();
54
58
  }, { deep: !0 });
55
- const M = g(() => le(e.value.customPalette)), y = x(a.dataset.map((t) => ({
59
+ const j = g(() => oe(e.value.customPalette)), y = x(a.dataset.map((t) => ({
56
60
  ...t,
57
61
  value: e.value.style.animation.show ? 0 : t.value || 0,
58
62
  formatter: t.formatter || null
59
63
  }))), D = x(null);
60
- q(async () => {
61
- ae(a.dataset) && T({
64
+ z(async () => {
65
+ se(a.dataset) && V({
62
66
  componentName: "VueUiSparkbar",
63
67
  type: "dataset"
64
68
  }), F();
@@ -66,7 +70,7 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
66
70
  function F() {
67
71
  if (e.value.style.animation.show) {
68
72
  let P = function() {
69
- r += l / t, r < l ? (y.value = y.value.map((u, h) => ({
73
+ i += l / t, i < l ? (y.value = y.value.map((u, h) => ({
70
74
  ...u,
71
75
  value: u.value += o[h]
72
76
  })), D.value = requestAnimationFrame(P)) : y.value = a.dataset.map((u) => ({
@@ -76,26 +80,26 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
76
80
  }));
77
81
  };
78
82
  const t = e.value.style.animation.animationFrames, o = a.dataset.map((u, h) => u.value / t), l = a.dataset.map((u) => u.value || 0).reduce((u, h) => u + h, 0);
79
- let r = 0;
83
+ let i = 0;
80
84
  P();
81
85
  }
82
86
  }
83
- z(() => a.dataset, async (t) => {
87
+ L(() => a.dataset, async (t) => {
84
88
  cancelAnimationFrame(D.value), y.value = a.dataset.map((o) => ({
85
89
  ...o,
86
90
  value: e.value.style.animation.show ? 0 : o.value || 0,
87
91
  formatter: o.formatter || null
88
- })), H(F);
92
+ })), R(F);
89
93
  }, { deep: !0 });
90
- const i = x({
94
+ const r = x({
91
95
  width: 500,
92
96
  height: 16
93
- }), U = g(() => Math.max(...a.dataset.map((t) => t.value))), j = g(() => (a.dataset.forEach((t, o) => {
94
- oe({
97
+ }), G = g(() => Math.max(...a.dataset.map((t) => t.value))), W = g(() => (a.dataset.forEach((t, o) => {
98
+ ue({
95
99
  datasetObject: t,
96
100
  requiredAttributes: ["name", "value"]
97
101
  }).forEach((l) => {
98
- T({
102
+ V({
99
103
  componentName: "VueUiSparkbar",
100
104
  type: "datasetSerieAttribute",
101
105
  property: l,
@@ -105,32 +109,32 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
105
109
  }), y.value.map((t, o) => ({
106
110
  ...t,
107
111
  value: t.value || 0,
108
- color: se(t.color) || M.value[o] || k[o] || k[o % k.length]
112
+ color: ne(t.color) || j.value[o] || k[o] || k[o % k.length]
109
113
  }))));
110
- function G(t) {
111
- return t / U.value;
114
+ function q(t) {
115
+ return t / G.value;
112
116
  }
113
117
  function I(t) {
114
- return e.value.style.layout.independant ? t.target ? t.value / t.target : e.value.style.layout.percentage ? t.value > 100 ? 1 : t.value / 100 : e.value.style.layout.target === 0 ? 1 : t.value / e.value.style.layout.target : G(t.value);
118
+ return e.value.style.layout.independant ? t.target ? t.value / t.target : e.value.style.layout.percentage ? t.value > 100 ? 1 : t.value / 100 : e.value.style.layout.target === 0 ? 1 : t.value / e.value.style.layout.target : q(t.value);
115
119
  }
116
120
  function m(t) {
117
121
  return e.value.style.layout.independant && t.target || e.value.style.layout.target;
118
122
  }
119
- function W(t, o) {
120
- E("selectDatapoint", { datapoint: t, index: o });
123
+ function H(t, o) {
124
+ B("selectDatapoint", { datapoint: t, index: o });
121
125
  }
122
- return (t, o) => (n(), v("div", {
123
- style: f({
126
+ return (t, o) => (n(), c("div", {
127
+ style: p({
124
128
  width: "100%",
125
129
  fontFamily: e.value.style.fontFamily,
126
130
  background: a.backgroundOpacity !== null ? s($)(e.value.style.backgroundColor, a.backgroundOpacity) : e.value.style.backgroundColor
127
131
  })
128
132
  }, [
129
- t.$slots.title ? b(t.$slots, "title", L(X({ key: 0 }, { title: { ...t.title, title: e.value.style.title.text, subtitle: e.value.style.title.subtitle.text } }))) : c("", !0),
130
- !t.$slots.title && e.value.style.title.text ? (n(), v("div", {
133
+ t.$slots.title ? C(t.$slots, "title", O(J({ key: 0 }, { title: { ...t.title, title: e.value.style.title.text, subtitle: e.value.style.title.subtitle.text } }))) : v("", !0),
134
+ !t.$slots.title && e.value.style.title.text ? (n(), c("div", {
131
135
  key: 1,
132
136
  class: "vue-ui-sparkbar-title-container",
133
- style: f({
137
+ style: p({
134
138
  background: e.value.style.title.backgroundColor,
135
139
  margin: e.value.style.title.margin,
136
140
  textAlign: e.value.style.title.textAlign
@@ -138,57 +142,57 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
138
142
  }, [
139
143
  d("div", {
140
144
  class: "vue-ui-sparkbar-title",
141
- style: f({
145
+ style: p({
142
146
  fontSize: e.value.style.title.fontSize + "px",
143
147
  color: e.value.style.title.color,
144
148
  fontWeight: e.value.style.title.bold ? "bold" : "normal"
145
149
  })
146
- }, p(e.value.style.title.text), 5),
147
- e.value.style.title.subtitle.text ? (n(), v("div", {
150
+ }, f(e.value.style.title.text), 5),
151
+ e.value.style.title.subtitle.text ? (n(), c("div", {
148
152
  key: 0,
149
153
  class: "vue-ui-sparkbar-subtitle",
150
- style: f({
154
+ style: p({
151
155
  fontSize: e.value.style.title.subtitle.fontSize + "px",
152
156
  color: e.value.style.title.subtitle.color,
153
157
  fontWeight: e.value.style.title.subtitle.bold ? "bold" : "normal"
154
158
  })
155
- }, p(e.value.style.title.subtitle.text), 5)) : c("", !0)
156
- ], 4)) : c("", !0),
157
- (n(!0), v(O, null, R(j.value, (l, r) => (n(), v(O, null, [
158
- S.value ? (n(), v("div", {
159
+ }, f(e.value.style.title.subtitle.text), 5)) : v("", !0)
160
+ ], 4)) : v("", !0),
161
+ (n(!0), c(T, null, K(W.value, (l, i) => (n(), c(T, null, [
162
+ S.value ? (n(), c("div", {
159
163
  key: 0,
160
- style: f(`display:flex !important;${["left", "right"].includes(e.value.style.labels.name.position) ? `flex-direction: ${e.value.style.labels.name.position === "right" ? "row-reverse" : "row"} !important` : "flex-direction:column !important"};gap:${e.value.style.gap}px !important;align-items:center;${C.dataset.length > 0 && r !== C.dataset.length - 1 ? "margin-bottom:6px" : ""}`),
161
- onClick: () => W(l, r)
164
+ style: p(`display:flex !important;${["left", "right"].includes(e.value.style.labels.name.position) ? `flex-direction: ${e.value.style.labels.name.position === "right" ? "row-reverse" : "row"} !important` : "flex-direction:column !important"};gap:${e.value.style.gap}px !important;align-items:center;${_.dataset.length > 0 && i !== _.dataset.length - 1 ? "margin-bottom:6px" : ""}`),
165
+ onClick: () => H(l, i)
162
166
  }, [
163
- b(t.$slots, "data-label", L(J({ bar: {
167
+ C(t.$slots, "data-label", O(Q({ bar: {
164
168
  ...l,
165
169
  target: m(l),
166
- valueLabel: s(w)(
170
+ valueLabel: s(b)(
167
171
  l.formatter,
168
172
  l.value,
169
- s(_)({
173
+ s(w)({
170
174
  p: l.prefix || "",
171
175
  v: l.value,
172
176
  s: l.suffix || "",
173
177
  r: l.rounding || 0
174
178
  }),
175
- { datapoint: l, seriesIndex: r }
179
+ { datapoint: l, seriesIndex: i }
176
180
  ),
177
- targetLabel: s(w)(
181
+ targetLabel: s(b)(
178
182
  l.formatter,
179
183
  m(l),
180
- s(_)({
184
+ s(w)({
181
185
  p: l.prefix || "",
182
186
  v: m(l),
183
187
  s: l.suffix || "",
184
188
  r: l.rounding || 0
185
189
  }),
186
- { datapoint: l, seriesIndex: r }
190
+ { datapoint: l, seriesIndex: i }
187
191
  )
188
192
  } }))),
189
- t.$slots["data-label"] ? c("", !0) : (n(), v("div", {
193
+ t.$slots["data-label"] ? v("", !0) : (n(), c("div", {
190
194
  key: 0,
191
- style: f({
195
+ style: p({
192
196
  width: e.value.style.labels.name.width,
193
197
  color: e.value.style.labels.name.color,
194
198
  fontSize: e.value.style.labels.fontSize + "px",
@@ -196,88 +200,88 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
196
200
  textAlign: ["left", "right"].includes(e.value.style.labels.name.position) || ["top", "top-left"].includes(e.value.style.labels.name.position) ? "left" : e.value.style.labels.name.position === "top-center" ? "center" : "right"
197
201
  })
198
202
  }, [
199
- d("span", null, p(l.name), 1),
200
- e.value.style.labels.value.show ? (n(), v("span", {
203
+ d("span", null, f(l.name), 1),
204
+ e.value.style.labels.value.show ? (n(), c("span", {
201
205
  key: 0,
202
- style: f(`font-weight:${e.value.style.labels.value.bold ? "bold" : "normal"}`)
203
- }, ": " + p(s(w)(
206
+ style: p(`font-weight:${e.value.style.labels.value.bold ? "bold" : "normal"}`)
207
+ }, ": " + f(s(b)(
204
208
  l.formatter,
205
209
  l.value,
206
- s(_)({
210
+ s(w)({
207
211
  p: l.prefix || "",
208
212
  v: l.value,
209
213
  s: l.suffix || "",
210
214
  r: l.rounding || 0
211
215
  }),
212
- { datapoint: l, seriesIndex: r }
213
- )), 5)) : c("", !0),
214
- e.value.style.layout.showTargetValue ? (n(), v("span", ce, p(" " + e.value.style.layout.targetValueText) + " " + p(s(w)(
216
+ { datapoint: l, seriesIndex: i }
217
+ )), 5)) : v("", !0),
218
+ e.value.style.layout.showTargetValue ? (n(), c("span", pe, f(" " + e.value.style.layout.targetValueText) + " " + f(s(b)(
215
219
  l.formatter,
216
220
  m(l),
217
- s(_)({
221
+ s(w)({
218
222
  p: l.prefix || "",
219
223
  v: m(l),
220
224
  s: l.suffix || "",
221
225
  r: l.rounding || 0
222
226
  }),
223
- { datapoint: l, seriesIndex: r }
224
- )), 1)) : c("", !0)
227
+ { datapoint: l, seriesIndex: i }
228
+ )), 1)) : v("", !0)
225
229
  ], 4)),
226
- (n(), v("svg", {
227
- xmlns: s(ue),
228
- viewBox: `0 0 ${i.value.width} ${i.value.height}`,
230
+ (n(), c("svg", {
231
+ xmlns: s(re),
232
+ viewBox: `0 0 ${r.value.width} ${r.value.height}`,
229
233
  width: "100%"
230
234
  }, [
231
- K(re),
235
+ Y(ve),
232
236
  d("defs", null, [
233
237
  d("linearGradient", {
234
238
  x1: "0%",
235
239
  y1: "0%",
236
240
  x2: "100%",
237
241
  y2: "0%",
238
- id: `sparkbar_gradient_${r}_${A.value}`
242
+ id: `sparkbar_gradient_${i}_${A.value}`
239
243
  }, [
240
244
  d("stop", {
241
245
  offset: "0%",
242
- "stop-color": s($)(s(ne)(l.color, 0.03), 100 - e.value.style.bar.gradient.intensity)
243
- }, null, 8, pe),
246
+ "stop-color": s($)(s(ie)(l.color, 0.03), 100 - e.value.style.bar.gradient.intensity)
247
+ }, null, 8, me),
244
248
  d("stop", {
245
249
  offset: "100%",
246
250
  "stop-color": l.color
247
- }, null, 8, ye)
248
- ], 8, fe)
251
+ }, null, 8, ge)
252
+ ], 8, ye)
249
253
  ]),
250
254
  d("rect", {
251
- height: i.value.height,
252
- width: i.value.width,
255
+ height: r.value.height,
256
+ width: r.value.width,
253
257
  x: 0,
254
258
  y: 0,
255
259
  fill: s($)(e.value.style.gutter.backgroundColor, e.value.style.gutter.opacity),
256
- rx: i.value.height / 2
257
- }, null, 8, me),
260
+ rx: r.value.height / 2
261
+ }, null, 8, he),
258
262
  d("rect", {
259
- height: i.value.height,
260
- width: i.value.width * I(l),
263
+ height: r.value.height,
264
+ width: r.value.width * I(l),
261
265
  x: 0,
262
266
  y: 0,
263
267
  fill: e.value.style.bar.gradient.underlayerColor,
264
- rx: i.value.height / 2
265
- }, null, 8, ge),
268
+ rx: r.value.height / 2
269
+ }, null, 8, xe),
266
270
  d("rect", {
267
- height: i.value.height,
268
- width: i.value.width * I(l),
271
+ height: r.value.height,
272
+ width: r.value.width * I(l),
269
273
  x: 0,
270
274
  y: 0,
271
- fill: e.value.style.bar.gradient.show ? `url(#sparkbar_gradient_${r}_${A.value})` : l.color,
272
- rx: i.value.height / 2
273
- }, null, 8, he)
274
- ], 8, de))
275
- ], 12, ve)) : c("", !0)
275
+ fill: e.value.style.bar.gradient.show ? `url(#sparkbar_gradient_${i}_${A.value})` : l.color,
276
+ rx: r.value.height / 2
277
+ }, null, 8, ke)
278
+ ], 8, fe))
279
+ ], 12, de)) : v("", !0)
276
280
  ], 64))), 256)),
277
- t.$slots.source ? (n(), v("div", xe, [
278
- b(t.$slots, "source")
279
- ], 512)) : c("", !0),
280
- S.value ? c("", !0) : (n(), Q(ie, {
281
+ t.$slots.source ? (n(), c("div", be, [
282
+ C(t.$slots, "source")
283
+ ], 512)) : v("", !0),
284
+ S.value ? v("", !0) : (n(), Z(ce, {
281
285
  key: 3,
282
286
  config: {
283
287
  type: "sparkbar",
@@ -293,5 +297,5 @@ const ve = ["onClick"], ce = { key: 1 }, de = ["xmlns", "viewBox"], fe = ["id"],
293
297
  }
294
298
  };
295
299
  export {
296
- $e as default
300
+ Ae as default
297
301
  };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-DaDv7p0W.cjs"),b=require("./useNestedProp-DkpuL8Iv.cjs"),D=require("./vue-ui-skeleton-B24XJJ2p.cjs"),$=require("./PackageVersion-nr7f_VNw.cjs"),z=["onClick"],L={key:1},P=["xmlns","viewBox"],A=["id"],F=["stop-color"],O=["stop-color"],I=["height","width","fill","rx"],T=["height","width","fill","rx"],q=["height","width","fill","rx"],M={key:2,ref:"source",dir:"auto"},U={__name:"vue-ui-sparkbar",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}},backgroundOpacity:{type:Number,default:null}},emits:["selectDatapoint"],setup(p,{emit:C}){const n=p,{vue_ui_sparkbar:S}=o.useConfig(),w=e.useSlots();e.onMounted(()=>{w["chart-background"]&&console.warn("VueUiSparkbar does not support the #chart-background slot.")});const v=e.computed(()=>!!n.dataset&&n.dataset.length),y=e.ref(o.createUid()),t=e.computed({get:()=>f(),set:l=>l});function f(){const l=b.useNestedProp({userConfig:n.config,defaultConfig:S});return l.theme?{...b.useNestedProp({userConfig:o.themes.vue_ui_sparkbar[l.theme]||n.config,defaultConfig:l}),customPalette:o.themePalettes[l.theme]||o.palette}:l}e.watch(()=>n.config,l=>{t.value=f()},{deep:!0});const N=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),c=e.ref(n.dataset.map(l=>({...l,value:t.value.style.animation.show?0:l.value||0,formatter:l.formatter||null}))),g=e.ref(null);e.onMounted(async()=>{o.objectIsEmpty(n.dataset)&&o.error({componentName:"VueUiSparkbar",type:"dataset"}),h()});function h(){if(t.value.style.animation.show){let x=function(){i+=a/l,i<a?(c.value=c.value.map((u,m)=>({...u,value:u.value+=r[m]})),g.value=requestAnimationFrame(x)):c.value=n.dataset.map(u=>({...u,value:u.value||0,formatter:u.formatter||null}))};const l=t.value.style.animation.animationFrames,r=n.dataset.map((u,m)=>u.value/l),a=n.dataset.map(u=>u.value||0).reduce((u,m)=>u+m,0);let i=0;x()}}e.watch(()=>n.dataset,async l=>{cancelAnimationFrame(g.value),c.value=n.dataset.map(r=>({...r,value:t.value.style.animation.show?0:r.value||0,formatter:r.formatter||null})),e.nextTick(h)},{deep:!0});const s=e.ref({width:500,height:16}),_=e.computed(()=>Math.max(...n.dataset.map(l=>l.value))),B=e.computed(()=>(n.dataset.forEach((l,r)=>{o.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","value"]}).forEach(a=>{o.error({componentName:"VueUiSparkbar",type:"datasetSerieAttribute",property:a,index:r})})}),c.value.map((l,r)=>({...l,value:l.value||0,color:o.convertColorToHex(l.color)||N.value[r]||o.palette[r]||o.palette[r%o.palette.length]}))));function V(l){return l/_.value}function k(l){return t.value.style.layout.independant?l.target?l.value/l.target:t.value.style.layout.percentage?l.value>100?1:l.value/100:t.value.style.layout.target===0?1:l.value/t.value.style.layout.target:V(l.value)}function d(l){return t.value.style.layout.independant&&l.target||t.value.style.layout.target}function E(l,r){C("selectDatapoint",{datapoint:l,index:r})}return(l,r)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({width:"100%",fontFamily:t.value.style.fontFamily,background:n.backgroundOpacity!==null?e.unref(o.setOpacity)(t.value.style.backgroundColor,n.backgroundOpacity):t.value.style.backgroundColor})},[l.$slots.title?e.renderSlot(l.$slots,"title",e.normalizeProps(e.mergeProps({key:0},{title:{...l.title,title:t.value.style.title.text,subtitle:t.value.style.title.subtitle.text}}))):e.createCommentVNode("",!0),!l.$slots.title&&t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",{key:1,class:"vue-ui-sparkbar-title-container",style:e.normalizeStyle({background:t.value.style.title.backgroundColor,margin:t.value.style.title.margin,textAlign:t.value.style.title.textAlign})},[e.createElementVNode("div",{class:"vue-ui-sparkbar-title",style:e.normalizeStyle({fontSize:t.value.style.title.fontSize+"px",color:t.value.style.title.color,fontWeight:t.value.style.title.bold?"bold":"normal"})},e.toDisplayString(t.value.style.title.text),5),t.value.style.title.subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,class:"vue-ui-sparkbar-subtitle",style:e.normalizeStyle({fontSize:t.value.style.title.subtitle.fontSize+"px",color:t.value.style.title.subtitle.color,fontWeight:t.value.style.title.subtitle.bold?"bold":"normal"})},e.toDisplayString(t.value.style.title.subtitle.text),5)):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(a,i)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[v.value?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`display:flex !important;${["left","right"].includes(t.value.style.labels.name.position)?`flex-direction: ${t.value.style.labels.name.position==="right"?"row-reverse":"row"} !important`:"flex-direction:column !important"};gap:${t.value.style.gap}px !important;align-items:center;${p.dataset.length>0&&i!==p.dataset.length-1?"margin-bottom:6px":""}`),onClick:()=>E(a,i)},[e.renderSlot(l.$slots,"data-label",e.normalizeProps(e.guardReactiveProps({bar:{...a,target:d(a),valueLabel:e.unref(o.applyDataLabel)(a.formatter,a.value,e.unref(o.dataLabel)({p:a.prefix||"",v:a.value,s:a.suffix||"",r:a.rounding||0}),{datapoint:a,seriesIndex:i}),targetLabel:e.unref(o.applyDataLabel)(a.formatter,d(a),e.unref(o.dataLabel)({p:a.prefix||"",v:d(a),s:a.suffix||"",r:a.rounding||0}),{datapoint:a,seriesIndex:i})}}))),l.$slots["data-label"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({width:t.value.style.labels.name.width,color:t.value.style.labels.name.color,fontSize:t.value.style.labels.fontSize+"px",fontWeight:t.value.style.labels.name.bold?"bold":"normal",textAlign:["left","right"].includes(t.value.style.labels.name.position)||["top","top-left"].includes(t.value.style.labels.name.position)?"left":t.value.style.labels.name.position==="top-center"?"center":"right"})},[e.createElementVNode("span",null,e.toDisplayString(a.name),1),t.value.style.labels.value.show?(e.openBlock(),e.createElementBlock("span",{key:0,style:e.normalizeStyle(`font-weight:${t.value.style.labels.value.bold?"bold":"normal"}`)},": "+e.toDisplayString(e.unref(o.applyDataLabel)(a.formatter,a.value,e.unref(o.dataLabel)({p:a.prefix||"",v:a.value,s:a.suffix||"",r:a.rounding||0}),{datapoint:a,seriesIndex:i})),5)):e.createCommentVNode("",!0),t.value.style.layout.showTargetValue?(e.openBlock(),e.createElementBlock("span",L,e.toDisplayString(" "+t.value.style.layout.targetValueText)+" "+e.toDisplayString(e.unref(o.applyDataLabel)(a.formatter,d(a),e.unref(o.dataLabel)({p:a.prefix||"",v:d(a),s:a.suffix||"",r:a.rounding||0}),{datapoint:a,seriesIndex:i})),1)):e.createCommentVNode("",!0)],4)),(e.openBlock(),e.createElementBlock("svg",{xmlns:e.unref(o.XMLNS),viewBox:`0 0 ${s.value.width} ${s.value.height}`,width:"100%"},[e.createVNode($._sfc_main),e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`sparkbar_gradient_${i}_${y.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(a.color,.03),100-t.value.style.bar.gradient.intensity)},null,8,F),e.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,O)],8,A)]),e.createElementVNode("rect",{height:s.value.height,width:s.value.width,x:0,y:0,fill:e.unref(o.setOpacity)(t.value.style.gutter.backgroundColor,t.value.style.gutter.opacity),rx:s.value.height/2},null,8,I),e.createElementVNode("rect",{height:s.value.height,width:s.value.width*k(a),x:0,y:0,fill:t.value.style.bar.gradient.underlayerColor,rx:s.value.height/2},null,8,T),e.createElementVNode("rect",{height:s.value.height,width:s.value.width*k(a),x:0,y:0,fill:t.value.style.bar.gradient.show?`url(#sparkbar_gradient_${i}_${y.value})`:a.color,rx:s.value.height/2},null,8,q)],8,P))],12,z)):e.createCommentVNode("",!0)],64))),256)),l.$slots.source?(e.openBlock(),e.createElementBlock("div",M,[e.renderSlot(l.$slots,"source")],512)):e.createCommentVNode("",!0),v.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(D.default,{key:3,config:{type:"sparkbar",style:{backgroundColor:t.value.style.backgroundColor,sparkbar:{color:"#CCCCCC"}}}},null,8,["config"]))],4))}};exports.default=U;
@@ -1,13 +1,13 @@
1
- import { computed as s, onMounted as N, ref as A, watch as M, openBlock as n, createElementBlock as i, normalizeStyle as m, toDisplayString as y, createCommentVNode as v, unref as c, createVNode as D, createElementVNode as d, normalizeClass as E, createBlock as G, renderSlot as I } from "vue";
2
- import { u as U, o as q, e as S, g as P, c as R, t as T, N as X, X as H, i as V, v as p, f as Y } from "./index-CI-N9klv.js";
3
- import { u as z } from "./useNestedProp-D1eJ0dvv.js";
4
- import J from "./vue-ui-skeleton-owIhXtQF.js";
5
- import { _ as K } from "./PackageVersion-S3SzpuwC.js";
6
- const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-color"], te = ["d", "stroke", "stroke-linecap"], ae = ["d", "stroke", "stroke-linecap", "stroke-dashoffset"], le = ["x", "y", "font-size", "fill", "font-weight"], oe = {
1
+ import { computed as s, onMounted as N, ref as A, watch as M, openBlock as n, createElementBlock as i, normalizeStyle as m, toDisplayString as y, createCommentVNode as r, unref as c, createVNode as D, renderSlot as S, createElementVNode as d, normalizeClass as G, createBlock as I } from "vue";
2
+ import { u as U, o as q, e as z, g as P, c as R, t as T, N as X, X as H, i as V, v as g, f as Y } from "./index-B9RAElpI.js";
3
+ import { u as O } from "./useNestedProp-DuruL3Nt.js";
4
+ import J from "./vue-ui-skeleton-DVYD_VSe.js";
5
+ import { _ as K } from "./PackageVersion-C_FFs0BP.js";
6
+ const Q = ["xmlns", "viewBox"], W = ["width", "height"], Z = ["id"], ee = ["stop-color"], te = ["stop-color"], ae = ["d", "stroke", "stroke-linecap"], le = ["d", "stroke", "stroke-linecap", "stroke-dashoffset"], oe = ["x", "y", "font-size", "fill", "font-weight"], se = {
7
7
  key: 4,
8
8
  ref: "source",
9
9
  dir: "auto"
10
- }, ve = {
10
+ }, ce = {
11
11
  __name: "vue-ui-sparkgauge",
12
12
  props: {
13
13
  config: {
@@ -23,20 +23,20 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
23
23
  }
24
24
  }
25
25
  },
26
- setup(F) {
27
- const l = F, { vue_ui_sparkgauge: O } = U(), g = s(() => !!l.dataset && Object.keys(l.dataset).length);
26
+ setup(j) {
27
+ const l = j, { vue_ui_sparkgauge: E } = U(), p = s(() => !!l.dataset && Object.keys(l.dataset).length);
28
28
  N(() => {
29
29
  h();
30
30
  });
31
31
  function h() {
32
- q(l.dataset) ? S({
32
+ q(l.dataset) ? z({
33
33
  componentName: "VueUiSparkgauge",
34
34
  type: "dataset"
35
35
  }) : P({
36
36
  datasetObject: l.dataset,
37
37
  requiredAttributes: ["value", "min", "max"]
38
38
  }).forEach((t) => {
39
- S({
39
+ z({
40
40
  componentName: "VueUiSparkgauge",
41
41
  type: "datasetAttribute",
42
42
  property: t
@@ -48,12 +48,12 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
48
48
  set: (t) => t
49
49
  });
50
50
  function k() {
51
- const t = z({
51
+ const t = O({
52
52
  userConfig: l.config,
53
- defaultConfig: O
53
+ defaultConfig: E
54
54
  });
55
55
  return t.theme ? {
56
- ...z({
56
+ ...O({
57
57
  userConfig: T.vue_ui_sparkgauge[t.theme] || l.config,
58
58
  defaultConfig: t
59
59
  })
@@ -67,42 +67,54 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
67
67
  width: 128,
68
68
  base: e.value.style.basePosition
69
69
  })), o = s(() => {
70
- const t = l.dataset.min ?? 0, r = l.dataset.max ?? 0, B = r - t;
70
+ const t = l.dataset.min ?? 0, v = l.dataset.max ?? 0, B = v - t;
71
71
  return {
72
72
  min: t,
73
- max: r,
73
+ max: v,
74
74
  diff: B
75
75
  };
76
76
  }), a = A(e.value.style.animation.show ? o.value.min : l.dataset.value);
77
77
  M(() => l.dataset.value, () => {
78
- $(l.dataset.value || 0);
78
+ x(l.dataset.value || 0);
79
79
  });
80
- const _ = s(() => a.value > o.value.max ? o.value.max : a.value < o.value.min ? o.value.min : a.value), x = s(() => o.value.diff / e.value.style.animation.speedMs);
80
+ const _ = s(() => a.value > o.value.max ? o.value.max : a.value < o.value.min ? o.value.min : a.value), $ = s(() => o.value.diff / e.value.style.animation.speedMs);
81
81
  N(() => {
82
- $(l.dataset.value || 0);
82
+ x(l.dataset.value || 0);
83
83
  });
84
- function $(t) {
85
- function r() {
86
- a.value < t ? a.value = Math.min(a.value + x.value, t) : a.value > t && (a.value = Math.max(a.value - x.value, t)), a.value !== t && requestAnimationFrame(r);
84
+ function x(t) {
85
+ function v() {
86
+ a.value < t ? a.value = Math.min(a.value + $.value, t) : a.value > t && (a.value = Math.max(a.value - $.value, t)), a.value !== t && requestAnimationFrame(v);
87
87
  }
88
- r();
88
+ v();
89
89
  }
90
- const f = s(() => l.dataset.title ?? ""), C = s(() => a.value >= 0 ? (_.value - o.value.min) / o.value.diff : (Math.abs(o.value.min) - Math.abs(_.value)) / o.value.diff), w = s(() => X(e.value.style.colors.min, e.value.style.colors.max, o.value.min, o.value.max, a.value)), L = s(() => e.value.style.dataLabel.autoColor ? w.value : e.value.style.dataLabel.color), j = s(() => e.value.style.track.autoColor ? w.value : e.value.style.track.color);
91
- return (t, r) => (n(), i("div", {
90
+ const f = s(() => l.dataset.title ?? ""), w = s(() => a.value >= 0 ? (_.value - o.value.min) / o.value.diff : (Math.abs(o.value.min) - Math.abs(_.value)) / o.value.diff), C = s(() => X(e.value.style.colors.min, e.value.style.colors.max, o.value.min, o.value.max, a.value)), L = s(() => e.value.style.dataLabel.autoColor ? C.value : e.value.style.dataLabel.color), F = s(() => e.value.style.track.autoColor ? C.value : e.value.style.track.color);
91
+ return (t, v) => (n(), i("div", {
92
92
  style: m(`font-family:${e.value.style.fontFamily};width: 100%; background:${e.value.style.background}`)
93
93
  }, [
94
94
  e.value.style.title.show && f.value && e.value.style.title.position === "top" ? (n(), i("div", {
95
95
  key: 0,
96
96
  class: "vue-data-ui-sparkgauge-label",
97
97
  style: m(`font-size:${e.value.style.title.fontSize}px;text-align:${e.value.style.title.textAlign};font-weight:${e.value.style.title.bold ? "bold" : "normal"};color:${e.value.style.title.color}`)
98
- }, y(f.value), 5)) : v("", !0),
99
- g.value ? (n(), i("svg", {
98
+ }, y(f.value), 5)) : r("", !0),
99
+ p.value ? (n(), i("svg", {
100
100
  key: 1,
101
101
  xmlns: c(H),
102
102
  viewBox: `0 0 ${u.value.width} ${u.value.height}`,
103
103
  style: "overflow: visible; background:transparent; width:100%;"
104
104
  }, [
105
105
  D(K),
106
+ t.$slots["chart-background"] ? (n(), i("foreignObject", {
107
+ key: 0,
108
+ x: 0,
109
+ y: 0,
110
+ width: u.value.width,
111
+ height: u.value.height,
112
+ style: {
113
+ pointerEvents: "none"
114
+ }
115
+ }, [
116
+ S(t.$slots, "chart-background")
117
+ ], 8, W)) : r("", !0),
106
118
  d("defs", null, [
107
119
  d("linearGradient", {
108
120
  id: `gradient_${b.value}`,
@@ -114,12 +126,12 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
114
126
  d("stop", {
115
127
  offset: "0%",
116
128
  "stop-color": e.value.style.colors.min
117
- }, null, 8, Z),
129
+ }, null, 8, ee),
118
130
  d("stop", {
119
131
  offset: "100%",
120
132
  "stop-color": e.value.style.colors.max
121
- }, null, 8, ee)
122
- ], 8, W)
133
+ }, null, 8, te)
134
+ ], 8, Z)
123
135
  ]),
124
136
  d("path", {
125
137
  d: `M10 ${u.value.base} A 1 1 0 1 1 118 ${u.value.base}`,
@@ -127,19 +139,19 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
127
139
  "stroke-width": 8,
128
140
  "stroke-linecap": e.value.style.gutter.strokeLinecap,
129
141
  fill: "none"
130
- }, null, 8, te),
131
- C.value !== 0 ? (n(), i("path", {
132
- key: 0,
142
+ }, null, 8, ae),
143
+ w.value !== 0 ? (n(), i("path", {
144
+ key: 1,
133
145
  d: `M10 ${u.value.base} A 1 1 0 1 1 118 ${u.value.base}`,
134
- stroke: e.value.style.colors.showGradient ? `url(#gradient_${b.value})` : j.value,
146
+ stroke: e.value.style.colors.showGradient ? `url(#gradient_${b.value})` : F.value,
135
147
  "stroke-width": 8,
136
148
  "stroke-linecap": e.value.style.track.strokeLinecap,
137
149
  fill: "none",
138
150
  "stroke-dasharray": 169.5,
139
- "stroke-dashoffset": 169.5 - 169.5 * C.value,
140
- class: E({ "vue-ui-sparkgauge-track": e.value.style.animation.show }),
151
+ "stroke-dashoffset": 169.5 - 169.5 * w.value,
152
+ class: G({ "vue-ui-sparkgauge-track": e.value.style.animation.show }),
141
153
  style: m(e.value.style.animation.show ? `animation: vue-ui-sparkgauge-animation ${e.value.style.animation.speedMs}ms ease-in;` : "")
142
- }, null, 14, ae)) : v("", !0),
154
+ }, null, 14, le)) : r("", !0),
143
155
  d("text", {
144
156
  "text-anchor": "middle",
145
157
  x: u.value.width / 2,
@@ -149,17 +161,17 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
149
161
  "font-weight": e.value.style.dataLabel.bold ? "bold" : "normal"
150
162
  }, y(c(V)(
151
163
  e.value.style.dataLabel.formatter,
152
- c(p)(a.value),
164
+ c(g)(a.value),
153
165
  c(Y)({
154
166
  p: e.value.style.dataLabel.prefix,
155
- v: c(p)(a.value),
167
+ v: c(g)(a.value),
156
168
  s: e.value.style.dataLabel.suffix,
157
169
  r: e.value.style.dataLabel.rounding
158
170
  }),
159
- { datapoint: c(p)(a.value), color: L.value }
160
- )), 9, le)
161
- ], 8, Q)) : v("", !0),
162
- g.value ? v("", !0) : (n(), G(J, {
171
+ { datapoint: c(g)(a.value), color: L.value }
172
+ )), 9, oe)
173
+ ], 8, Q)) : r("", !0),
174
+ p.value ? r("", !0) : (n(), I(J, {
163
175
  key: 2,
164
176
  config: {
165
177
  type: "gauge",
@@ -175,13 +187,13 @@ const Q = ["xmlns", "viewBox"], W = ["id"], Z = ["stop-color"], ee = ["stop-colo
175
187
  key: 3,
176
188
  class: "vue-data-ui-sparkgauge-label",
177
189
  style: m(`font-size:${e.value.style.title.fontSize}px;text-align:${e.value.style.title.textAlign};font-weight:${e.value.style.title.bold ? "bold" : "normal"};font-weight:${e.value.style.title.bold ? "bold" : "normal"};color:${e.value.style.title.color}`)
178
- }, y(f.value), 5)) : v("", !0),
179
- t.$slots.source ? (n(), i("div", oe, [
180
- I(t.$slots, "source")
181
- ], 512)) : v("", !0)
190
+ }, y(f.value), 5)) : r("", !0),
191
+ t.$slots.source ? (n(), i("div", se, [
192
+ S(t.$slots, "source")
193
+ ], 512)) : r("", !0)
182
194
  ], 4));
183
195
  }
184
196
  };
185
197
  export {
186
- ve as default
198
+ ce as default
187
199
  };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),n=require("./index-DaDv7p0W.cjs"),b=require("./useNestedProp-DkpuL8Iv.cjs"),w=require("./vue-ui-skeleton-B24XJJ2p.cjs"),x=require("./PackageVersion-nr7f_VNw.cjs"),S=["xmlns","viewBox"],B=["width","height"],E=["id"],L=["stop-color"],M=["stop-color"],V=["d","stroke","stroke-linecap"],z=["d","stroke","stroke-linecap","stroke-dashoffset"],A=["x","y","font-size","fill","font-weight"],O={key:4,ref:"source",dir:"auto"},j={__name:"vue-ui-sparkgauge",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(C){const o=C,{vue_ui_sparkgauge:_}=n.useConfig(),c=e.computed(()=>!!o.dataset&&Object.keys(o.dataset).length);e.onMounted(()=>{d()});function d(){n.objectIsEmpty(o.dataset)?n.error({componentName:"VueUiSparkgauge",type:"dataset"}):n.getMissingDatasetAttributes({datasetObject:o.dataset,requiredAttributes:["value","min","max"]}).forEach(a=>{n.error({componentName:"VueUiSparkgauge",type:"datasetAttribute",property:a})})}const v=e.ref(n.createUid()),t=e.computed({get:()=>m(),set:a=>a});function m(){const a=b.useNestedProp({userConfig:o.config,defaultConfig:_});return a.theme?{...b.useNestedProp({userConfig:n.themes.vue_ui_sparkgauge[a.theme]||o.config,defaultConfig:a})}:a}e.watch(()=>o.config,a=>{t.value=m(),d()},{deep:!0});const u=e.computed(()=>({height:t.value.style.height,width:128,base:t.value.style.basePosition})),s=e.computed(()=>{const a=o.dataset.min??0,r=o.dataset.max??0,$=r-a;return{min:a,max:r,diff:$}}),l=e.ref(t.value.style.animation.show?s.value.min:o.dataset.value);e.watch(()=>o.dataset.value,()=>{y(o.dataset.value||0)});const f=e.computed(()=>l.value>s.value.max?s.value.max:l.value<s.value.min?s.value.min:l.value),p=e.computed(()=>s.value.diff/t.value.style.animation.speedMs);e.onMounted(()=>{y(o.dataset.value||0)});function y(a){function r(){l.value<a?l.value=Math.min(l.value+p.value,a):l.value>a&&(l.value=Math.max(l.value-p.value,a)),l.value!==a&&requestAnimationFrame(r)}r()}const i=e.computed(()=>o.dataset.title??""),g=e.computed(()=>l.value>=0?(f.value-s.value.min)/s.value.diff:(Math.abs(s.value.min)-Math.abs(f.value))/s.value.diff),h=e.computed(()=>n.interpolateColorHex(t.value.style.colors.min,t.value.style.colors.max,s.value.min,s.value.max,l.value)),k=e.computed(()=>t.value.style.dataLabel.autoColor?h.value:t.value.style.dataLabel.color),N=e.computed(()=>t.value.style.track.autoColor?h.value:t.value.style.track.color);return(a,r)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width: 100%; background:${t.value.style.background}`)},[t.value.style.title.show&&i.value&&t.value.style.title.position==="top"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"vue-data-ui-sparkgauge-label",style:e.normalizeStyle(`font-size:${t.value.style.title.fontSize}px;text-align:${t.value.style.title.textAlign};font-weight:${t.value.style.title.bold?"bold":"normal"};color:${t.value.style.title.color}`)},e.toDisplayString(i.value),5)):e.createCommentVNode("",!0),c.value?(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(n.XMLNS),viewBox:`0 0 ${u.value.width} ${u.value.height}`,style:"overflow: visible; background:transparent; width:100%;"},[e.createVNode(x._sfc_main),a.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:u.value.width,height:u.value.height,style:{pointerEvents:"none"}},[e.renderSlot(a.$slots,"chart-background")],8,B)):e.createCommentVNode("",!0),e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`gradient_${v.value}`,x1:"-10%",y1:"100%",x2:"110%",y2:"100%"},[e.createElementVNode("stop",{offset:"0%","stop-color":t.value.style.colors.min},null,8,L),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.colors.max},null,8,M)],8,E)]),e.createElementVNode("path",{d:`M10 ${u.value.base} A 1 1 0 1 1 118 ${u.value.base}`,stroke:t.value.style.gutter.color,"stroke-width":8,"stroke-linecap":t.value.style.gutter.strokeLinecap,fill:"none"},null,8,V),g.value!==0?(e.openBlock(),e.createElementBlock("path",{key:1,d:`M10 ${u.value.base} A 1 1 0 1 1 118 ${u.value.base}`,stroke:t.value.style.colors.showGradient?`url(#gradient_${v.value})`:N.value,"stroke-width":8,"stroke-linecap":t.value.style.track.strokeLinecap,fill:"none","stroke-dasharray":169.5,"stroke-dashoffset":169.5-169.5*g.value,class:e.normalizeClass({"vue-ui-sparkgauge-track":t.value.style.animation.show}),style:e.normalizeStyle(t.value.style.animation.show?`animation: vue-ui-sparkgauge-animation ${t.value.style.animation.speedMs}ms ease-in;`:"")},null,14,z)):e.createCommentVNode("",!0),e.createElementVNode("text",{"text-anchor":"middle",x:u.value.width/2,y:u.value.base+6+t.value.style.dataLabel.offsetY,"font-size":t.value.style.dataLabel.fontSize,fill:k.value,"font-weight":t.value.style.dataLabel.bold?"bold":"normal"},e.toDisplayString(e.unref(n.applyDataLabel)(t.value.style.dataLabel.formatter,e.unref(n.checkNaN)(l.value),e.unref(n.dataLabel)({p:t.value.style.dataLabel.prefix,v:e.unref(n.checkNaN)(l.value),s:t.value.style.dataLabel.suffix,r:t.value.style.dataLabel.rounding}),{datapoint:e.unref(n.checkNaN)(l.value),color:k.value})),9,A)],8,S)):e.createCommentVNode("",!0),c.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(w.default,{key:2,config:{type:"gauge",style:{backgroundColor:t.value.style.background,gauge:{color:"#CCCCCC"}}}},null,8,["config"])),t.value.style.title.show&&i.value&&t.value.style.title.position==="bottom"?(e.openBlock(),e.createElementBlock("div",{key:3,class:"vue-data-ui-sparkgauge-label",style:e.normalizeStyle(`font-size:${t.value.style.title.fontSize}px;text-align:${t.value.style.title.textAlign};font-weight:${t.value.style.title.bold?"bold":"normal"};font-weight:${t.value.style.title.bold?"bold":"normal"};color:${t.value.style.title.color}`)},e.toDisplayString(i.value),5)):e.createCommentVNode("",!0),a.$slots.source?(e.openBlock(),e.createElementBlock("div",O,[e.renderSlot(a.$slots,"source")],512)):e.createCommentVNode("",!0)],4))}};exports.default=j;