vue-data-ui 2.3.76 → 2.3.77

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 (161) hide show
  1. package/dist/{Arrow-DY9RKUmG.js → Arrow-Dj2zuGLq.js} +1 -1
  2. package/dist/{Arrow-D7M4-bW7.cjs → Arrow-VCEIU9wi.cjs} +1 -1
  3. package/dist/{BaseIcon-DB7Apwv_.cjs → BaseIcon-CP535rdy.cjs} +1 -1
  4. package/dist/{BaseIcon-rwm-10Hu.js → BaseIcon-Cbr8np30.js} +1 -1
  5. package/dist/{DataTable-CsNozyz7.cjs → DataTable-CeHw-cqZ.cjs} +1 -1
  6. package/dist/{DataTable-e2fnfjXV.js → DataTable-OAUXdIYA.js} +2 -2
  7. package/dist/{Legend-5cQ0xZjK.js → Legend-BVByqGqZ.js} +1 -1
  8. package/dist/{Legend-DgFd-O0m.cjs → Legend-DfU44fjz.cjs} +1 -1
  9. package/dist/{Shape-yPECDLiP.cjs → Shape-B6cEKeIN.cjs} +1 -1
  10. package/dist/{Shape-CiTElr_0.js → Shape-Clmb3iTX.js} +1 -1
  11. package/dist/{Slicer-DwBBu3kB.js → Slicer-BlRQsQu0.js} +12 -12
  12. package/dist/{Slicer-DaZgCKV7.cjs → Slicer-Dt9iqvAA.cjs} +1 -1
  13. package/dist/{Title-3EduyW4p.cjs → Title-D9lSjLTg.cjs} +1 -1
  14. package/dist/{Title-gUz6GDA3.js → Title-gvR5aS6q.js} +1 -1
  15. package/dist/{Tooltip-DfSM1mNP.js → Tooltip-BGmkuAK4.js} +23 -23
  16. package/dist/Tooltip-C0PSN8vf.cjs +1 -0
  17. package/dist/{index-CaV1s-yZ.js → index-0KN57HdM.js} +1147 -1145
  18. package/dist/index-TabZg_HV.cjs +4 -0
  19. package/dist/style.css +1 -1
  20. package/dist/{useNestedProp-CisbRRo_.cjs → useNestedProp-CoLyVvV9.cjs} +1 -1
  21. package/dist/{useNestedProp-tWCzZrLx.js → useNestedProp-NeGalTYk.js} +1 -1
  22. package/dist/{usePrinter-DzTaA1eh.cjs → usePrinter--7sLxlpn.cjs} +1 -1
  23. package/dist/{usePrinter-rvJyT65A.js → usePrinter-BvKYEc1z.js} +1 -1
  24. package/dist/{vue-data-ui-BGkWRPUY.cjs → vue-data-ui-CNZP_Hk4.cjs} +1 -1
  25. package/dist/{vue-data-ui-BO89gTtq.js → vue-data-ui-Du0OReJH.js} +57 -57
  26. package/dist/vue-data-ui.cjs +1 -1
  27. package/dist/vue-data-ui.js +9 -9
  28. package/dist/vue-ui-3d-bar-AUSKibZS.cjs +19 -0
  29. package/dist/{vue-ui-3d-bar-CcTMIHiB.js → vue-ui-3d-bar-Dasj0J9j.js} +342 -342
  30. package/dist/{vue-ui-accordion-7e4Myhcg.cjs → vue-ui-accordion-0uSZBHsp.cjs} +1 -1
  31. package/dist/{vue-ui-accordion-CpzGQ63y.js → vue-ui-accordion-CczyfFaC.js} +3 -3
  32. package/dist/vue-ui-age-pyramid-CjBr4CXC.cjs +1 -0
  33. package/dist/{vue-ui-age-pyramid-D71ZLkVV.js → vue-ui-age-pyramid-DZ7vnojR.js} +22 -22
  34. package/dist/{vue-ui-annotator-B8Iu6cYt.js → vue-ui-annotator-BWwxpp_v.js} +39 -39
  35. package/dist/{vue-ui-annotator-BKQrweqm.cjs → vue-ui-annotator-CyYSiELS.cjs} +2 -2
  36. package/dist/{vue-ui-candlestick-DAc1FQ-i.cjs → vue-ui-candlestick-B9oSgBPN.cjs} +2 -2
  37. package/dist/{vue-ui-candlestick-Bx4QVkY0.js → vue-ui-candlestick-Dr9aS-Ku.js} +34 -34
  38. package/dist/{vue-ui-carousel-table-uFRqkghO.cjs → vue-ui-carousel-table-CjDze14W.cjs} +1 -1
  39. package/dist/{vue-ui-carousel-table-xuQG6bcH.js → vue-ui-carousel-table-D2LK5a9p.js} +31 -31
  40. package/dist/{vue-ui-chestnut-Bo6rDcU7.js → vue-ui-chestnut-DIqR-vZo.js} +291 -288
  41. package/dist/vue-ui-chestnut-RhZaDeRG.cjs +6 -0
  42. package/dist/vue-ui-cursor-7QhVReKN.cjs +1 -0
  43. package/dist/{vue-ui-cursor-C0KOqEOq.js → vue-ui-cursor-BxHK0bB7.js} +20 -20
  44. package/dist/{vue-ui-dashboard-0Hsjx-bO.cjs → vue-ui-dashboard-DO-zVgDu.cjs} +1 -1
  45. package/dist/{vue-ui-dashboard-BT71xS7P.js → vue-ui-dashboard-fYKECIc7.js} +2 -2
  46. package/dist/{vue-ui-digits-BRqpKYvD.js → vue-ui-digits-B8hAl2RW.js} +2 -2
  47. package/dist/{vue-ui-digits-C2ReH6w0.cjs → vue-ui-digits-CSsB4Zlr.cjs} +1 -1
  48. package/dist/{vue-ui-donut-NQW-3prf.js → vue-ui-donut-D5DTvWXB.js} +60 -60
  49. package/dist/vue-ui-donut-D8evqk7g.cjs +1 -0
  50. package/dist/vue-ui-donut-evolution-BUdWXb-N.cjs +1 -0
  51. package/dist/{vue-ui-donut-evolution-jbXQQGTc.js → vue-ui-donut-evolution-CPTiiUY6.js} +106 -106
  52. package/dist/{vue-ui-dumbbell-Dyz8xdtC.js → vue-ui-dumbbell-CfeTfNTU.js} +17 -17
  53. package/dist/{vue-ui-dumbbell-DXQSg6wa.cjs → vue-ui-dumbbell-Fm-Bqc5W.cjs} +1 -1
  54. package/dist/{vue-ui-flow-UqSNwH9d.cjs → vue-ui-flow-24WIcZVL.cjs} +1 -1
  55. package/dist/{vue-ui-flow-BL3JWW1m.js → vue-ui-flow-B2WWQo6P.js} +28 -28
  56. package/dist/{vue-ui-galaxy-DTQWGvRH.cjs → vue-ui-galaxy-DkRizJxm.cjs} +1 -1
  57. package/dist/{vue-ui-galaxy-Dx9nsOuM.js → vue-ui-galaxy-yfpv7Hky.js} +22 -22
  58. package/dist/vue-ui-gauge-BkB7BlNM.cjs +1 -0
  59. package/dist/{vue-ui-gauge-CLaKGi0-.js → vue-ui-gauge-CRVB3wlV.js} +99 -108
  60. package/dist/{vue-ui-gizmo-of-4s5HG.js → vue-ui-gizmo-DJYOx_YH.js} +2 -2
  61. package/dist/{vue-ui-gizmo-Kitfqu0J.cjs → vue-ui-gizmo-Zyo15xm3.cjs} +1 -1
  62. package/dist/{vue-ui-heatmap-BIzjOMXO.js → vue-ui-heatmap-C6fDCc7O.js} +17 -17
  63. package/dist/{vue-ui-heatmap-DUw2350O.cjs → vue-ui-heatmap-uynT8kN9.cjs} +1 -1
  64. package/dist/{vue-ui-kpi-By3YPwgo.js → vue-ui-kpi-CGC4h9uF.js} +3 -3
  65. package/dist/{vue-ui-kpi-DyL2Hcz-.cjs → vue-ui-kpi-CqEEFb04.cjs} +1 -1
  66. package/dist/{vue-ui-mini-loader-DnK3V2z2.js → vue-ui-mini-loader-2A0YUUIB.js} +2 -2
  67. package/dist/{vue-ui-mini-loader-C048-8Kd.cjs → vue-ui-mini-loader-ku9X16tx.cjs} +1 -1
  68. package/dist/{vue-ui-molecule-D-ahly6R.cjs → vue-ui-molecule-Bv1IBx1L.cjs} +1 -1
  69. package/dist/{vue-ui-molecule-BfhbIqa5.js → vue-ui-molecule-CwcUmg-k.js} +33 -33
  70. package/dist/vue-ui-mood-radar-Bf5g118s.cjs +1 -0
  71. package/dist/{vue-ui-mood-radar-DXxEKr3x.js → vue-ui-mood-radar-V04waMIM.js} +129 -132
  72. package/dist/{vue-ui-nested-donuts-C7qM_FRw.cjs → vue-ui-nested-donuts-DgVrAToy.cjs} +2 -2
  73. package/dist/{vue-ui-nested-donuts-BdUdHFd-.js → vue-ui-nested-donuts-DoFALZtp.js} +98 -98
  74. package/dist/{vue-ui-onion-DX3gofXZ.cjs → vue-ui-onion-BdZC2qt8.cjs} +1 -1
  75. package/dist/{vue-ui-onion-D0vF5jBt.js → vue-ui-onion-_GaJ78t_.js} +9 -9
  76. package/dist/{vue-ui-parallel-coordinate-plot-DEx5kFYd.cjs → vue-ui-parallel-coordinate-plot-BHYr1iqZ.cjs} +1 -1
  77. package/dist/{vue-ui-parallel-coordinate-plot-CTZY-pY8.js → vue-ui-parallel-coordinate-plot-Eh0gXDVG.js} +24 -24
  78. package/dist/vue-ui-quadrant-BEhnCog2.cjs +1 -0
  79. package/dist/{vue-ui-quadrant-ByY8GP3y.js → vue-ui-quadrant-C4LHosyR.js} +35 -35
  80. package/dist/{vue-ui-quick-chart-DTxJ__7j.js → vue-ui-quick-chart-IqY67olA.js} +69 -69
  81. package/dist/{vue-ui-quick-chart-DWZEgUJF.cjs → vue-ui-quick-chart-YFEmJP_6.cjs} +1 -1
  82. package/dist/{vue-ui-radar-5UBmAU6W.js → vue-ui-radar-BSsDvnVt.js} +39 -39
  83. package/dist/{vue-ui-radar-DEED0rTz.cjs → vue-ui-radar-Cel3ZnfN.cjs} +1 -1
  84. package/dist/{vue-ui-rating-Dr6jquxh.js → vue-ui-rating-Bb1xXC_r.js} +6 -6
  85. package/dist/{vue-ui-rating-Ce_Ewqtl.cjs → vue-ui-rating-D-qBEM1w.cjs} +1 -1
  86. package/dist/{vue-ui-relation-circle-BU8i2miI.js → vue-ui-relation-circle-CSqi6DqF.js} +29 -29
  87. package/dist/vue-ui-relation-circle-fb8g1ms8.cjs +1 -0
  88. package/dist/{vue-ui-rings-OQ8a1Ruw.cjs → vue-ui-rings-Bgb538Wa.cjs} +2 -2
  89. package/dist/{vue-ui-rings-Ctl3Jywh.js → vue-ui-rings-ezoy9PIq.js} +31 -31
  90. package/dist/vue-ui-scatter-B7z6AOLU.cjs +1 -0
  91. package/dist/{vue-ui-scatter-BwJ_koWT.js → vue-ui-scatter-Ci5l--xS.js} +95 -95
  92. package/dist/{vue-ui-screenshot-BS3L5vhN.js → vue-ui-screenshot-C2X1am1d.js} +4 -4
  93. package/dist/{vue-ui-screenshot-bAVk3EPl.cjs → vue-ui-screenshot-DLXQWgeo.cjs} +1 -1
  94. package/dist/vue-ui-skeleton-CYeXVNFu.cjs +41 -0
  95. package/dist/{vue-ui-skeleton-CvFX_ExX.js → vue-ui-skeleton-dgMXr8k9.js} +96 -96
  96. package/dist/{vue-ui-smiley-sF8QIso1.cjs → vue-ui-smiley-CDhXPYa7.cjs} +1 -1
  97. package/dist/{vue-ui-smiley-CGYZpNt9.js → vue-ui-smiley-DXb5VqXk.js} +2 -2
  98. package/dist/vue-ui-spark-trend-1hcgCu8H.cjs +1 -0
  99. package/dist/{vue-ui-spark-trend-B4XSSKl9.js → vue-ui-spark-trend-Bv1-LLRs.js} +21 -21
  100. package/dist/vue-ui-sparkbar-CWdFQTkx.cjs +1 -0
  101. package/dist/{vue-ui-sparkbar-BbsJGDMZ.js → vue-ui-sparkbar-CbmzVXcW.js} +10 -10
  102. package/dist/{vue-ui-sparkgauge-D4w_i_QJ.js → vue-ui-sparkgauge-CHODK9jn.js} +8 -8
  103. package/dist/{vue-ui-sparkgauge-BKyQoI7C.cjs → vue-ui-sparkgauge-r7VEpPtv.cjs} +1 -1
  104. package/dist/{vue-ui-sparkhistogram-CYybrW-6.js → vue-ui-sparkhistogram-CKiO1LGI.js} +111 -101
  105. package/dist/vue-ui-sparkhistogram-Do5qTT2U.cjs +1 -0
  106. package/dist/vue-ui-sparkline-Bw3dw-vW.cjs +1 -0
  107. package/dist/{vue-ui-sparkline-DjN1SVdO.js → vue-ui-sparkline-DLU7hK0K.js} +34 -34
  108. package/dist/{vue-ui-sparkstackbar-BLMhJxaN.js → vue-ui-sparkstackbar-B3TQVHlU.js} +5 -5
  109. package/dist/{vue-ui-sparkstackbar-BZ2bESBi.cjs → vue-ui-sparkstackbar-CD-HZ4Rq.cjs} +1 -1
  110. package/dist/{vue-ui-stackbar-DRHaJFR8.cjs → vue-ui-stackbar-2WJh-QtY.cjs} +2 -2
  111. package/dist/{vue-ui-stackbar-BTKOHUYc.js → vue-ui-stackbar-BnIeIS12.js} +202 -200
  112. package/dist/{vue-ui-strip-plot-o6GTsGAT.js → vue-ui-strip-plot-CddHmHSX.js} +26 -26
  113. package/dist/{vue-ui-strip-plot-DxQxFbWg.cjs → vue-ui-strip-plot-DyL8FH29.cjs} +1 -1
  114. package/dist/{vue-ui-table-CnquiTpr.js → vue-ui-table-BZ6yonvx.js} +1 -1
  115. package/dist/{vue-ui-table-BFIj1Rgh.cjs → vue-ui-table-_Sxgp6iC.cjs} +1 -1
  116. package/dist/{vue-ui-table-heatmap-CZRIwv-Q.js → vue-ui-table-heatmap-CYOgunS2.js} +24 -24
  117. package/dist/{vue-ui-table-heatmap-CCGK12Fa.cjs → vue-ui-table-heatmap-DGWhBhp0.cjs} +1 -1
  118. package/dist/{vue-ui-table-sparkline-B3zEeq6Z.js → vue-ui-table-sparkline-D33NLyyx.js} +26 -26
  119. package/dist/{vue-ui-table-sparkline-DYmgfHz4.cjs → vue-ui-table-sparkline-IVMQG6tp.cjs} +1 -1
  120. package/dist/{vue-ui-thermometer-CzPRBt6c.cjs → vue-ui-thermometer-8XDaKLt5.cjs} +1 -1
  121. package/dist/{vue-ui-thermometer-BopiohUh.js → vue-ui-thermometer-DMwZ2O16.js} +40 -40
  122. package/dist/{vue-ui-timer-Bonw69Lt.cjs → vue-ui-timer-B3_-DhDj.cjs} +1 -1
  123. package/dist/{vue-ui-timer-C7WkW8hK.js → vue-ui-timer-D59VSia6.js} +8 -8
  124. package/dist/{vue-ui-tiremarks-BurRtFv4.js → vue-ui-tiremarks-Bczw28td.js} +18 -18
  125. package/dist/{vue-ui-tiremarks-DkIGfq8t.cjs → vue-ui-tiremarks-Br_jF9bH.cjs} +1 -1
  126. package/dist/{vue-ui-treemap-DWy4voIr.js → vue-ui-treemap-DGJNw2WX.js} +29 -29
  127. package/dist/{vue-ui-treemap-CalhJmnp.cjs → vue-ui-treemap-DLHdaXss.cjs} +1 -1
  128. package/dist/vue-ui-vertical-bar-BGYrmyAK.cjs +4 -0
  129. package/dist/{vue-ui-vertical-bar-CJW1YhtY.js → vue-ui-vertical-bar-De0N4Ggo.js} +14 -14
  130. package/dist/{vue-ui-waffle-faQMBYNx.cjs → vue-ui-waffle-CJPVEDgC.cjs} +1 -1
  131. package/dist/{vue-ui-waffle-DB7X6nTS.js → vue-ui-waffle-CnXLf5xd.js} +84 -84
  132. package/dist/{vue-ui-wheel-CryKap2E.js → vue-ui-wheel-Bciq0JM9.js} +24 -24
  133. package/dist/{vue-ui-wheel-BzjbGP6a.cjs → vue-ui-wheel-CAKYmn0b.cjs} +1 -1
  134. package/dist/{vue-ui-word-cloud-DJN9I4q4.cjs → vue-ui-word-cloud-4ooTRM2O.cjs} +1 -1
  135. package/dist/{vue-ui-word-cloud-COqUkvei.js → vue-ui-word-cloud-CWm6r9Zf.js} +19 -19
  136. package/dist/{vue-ui-xy-b1Z_HPsx.js → vue-ui-xy-B5nBhYgd.js} +351 -350
  137. package/dist/vue-ui-xy-Ch5hDEec.cjs +3 -0
  138. package/dist/{vue-ui-xy-canvas-BgbLnY5B.js → vue-ui-xy-canvas-CzLTSmDS.js} +18 -18
  139. package/dist/vue-ui-xy-canvas-d-EE9_dN.cjs +9 -0
  140. package/package.json +1 -1
  141. package/dist/Tooltip-DScSrYXJ.cjs +0 -1
  142. package/dist/index-BTgtr0F8.cjs +0 -4
  143. package/dist/vue-ui-3d-bar-DzmcGuqh.cjs +0 -19
  144. package/dist/vue-ui-age-pyramid-C7qr9EwB.cjs +0 -1
  145. package/dist/vue-ui-chestnut-DJkm72oD.cjs +0 -6
  146. package/dist/vue-ui-cursor-BQbeuW-k.cjs +0 -1
  147. package/dist/vue-ui-donut-evolution-DOe-cwLi.cjs +0 -1
  148. package/dist/vue-ui-donut-v81suIOX.cjs +0 -1
  149. package/dist/vue-ui-gauge-BUB7H0qA.cjs +0 -1
  150. package/dist/vue-ui-mood-radar-DD8R9BpJ.cjs +0 -1
  151. package/dist/vue-ui-quadrant-CgApzie6.cjs +0 -1
  152. package/dist/vue-ui-relation-circle-CRcQ6Zcy.cjs +0 -1
  153. package/dist/vue-ui-scatter-B8StSjt8.cjs +0 -1
  154. package/dist/vue-ui-skeleton-CMQzFTs9.cjs +0 -41
  155. package/dist/vue-ui-spark-trend-CdIoxaqb.cjs +0 -1
  156. package/dist/vue-ui-sparkbar-C3i1K7hi.cjs +0 -1
  157. package/dist/vue-ui-sparkhistogram-CvTYEmbz.cjs +0 -1
  158. package/dist/vue-ui-sparkline-CDowaDRS.cjs +0 -1
  159. package/dist/vue-ui-vertical-bar-rwWp-sai.cjs +0 -4
  160. package/dist/vue-ui-xy-BmA0tspd.cjs +0 -3
  161. package/dist/vue-ui-xy-canvas-DOM2Kq_s.cjs +0 -9
@@ -1,14 +1,14 @@
1
- import { useCssVars as ve, ref as d, computed as g, watch as Q, onMounted as ce, openBlock as s, createElementBlock as v, normalizeClass as D, createElementVNode as c, normalizeStyle as r, toDisplayString as p, createCommentVNode as h, Fragment as T, renderList as M, createBlock as V, unref as i, createSlots as fe, withCtx as w, renderSlot as A, normalizeProps as pe, guardReactiveProps as be, nextTick as me } from "vue";
2
- import { u as ge, c as he, t as ye, a as _e, p as $, b as ke, o as xe, e as Y, g as Ce, d as Ie, U as Se, i as P, f as z, q as we, r as Ae } from "./index-CaV1s-yZ.js";
3
- import { u as Z } from "./useNestedProp-tWCzZrLx.js";
4
- import $e from "./vue-ui-sparkline-DjN1SVdO.js";
5
- import Pe from "./BaseIcon-rwm-10Hu.js";
6
- import { u as ze, U as Fe } from "./usePrinter-rvJyT65A.js";
1
+ import { useCssVars as ve, ref as d, computed as g, watch as Q, onMounted as ce, openBlock as s, createElementBlock as v, normalizeClass as D, createElementVNode as c, normalizeStyle as r, toDisplayString as p, createCommentVNode as h, Fragment as T, renderList as V, createBlock as M, unref as i, createSlots as fe, withCtx as w, renderSlot as A, normalizeProps as pe, guardReactiveProps as be, nextTick as me } from "vue";
2
+ import { u as ge, c as he, t as ye, a as _e, p as $, b as ke, o as xe, e as Y, g as Ce, d as Ie, V as Se, i as P, f as z, q as we, r as Ae } from "./index-0KN57HdM.js";
3
+ import { u as Z } from "./useNestedProp-NeGalTYk.js";
4
+ import $e from "./vue-ui-sparkline-DLU7hK0K.js";
5
+ import Pe from "./BaseIcon-Cbr8np30.js";
6
+ import { u as ze, U as Fe } from "./usePrinter-BvKYEc1z.js";
7
7
  import { _ as Oe } from "./_plugin-vue_export-helper-CHgC5LLL.js";
8
- const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } }, De = ["onClick"], Te = { style: { display: "flex", "flex-direction": "row", gap: "3px", "align-items": "center" } }, Me = ["data-cell"], Ve = {
8
+ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } }, De = ["onClick"], Te = { style: { display: "flex", "flex-direction": "row", gap: "3px", "align-items": "center" } }, Ve = ["data-cell"], Me = {
9
9
  dir: "auto",
10
10
  style: { display: "flex", "flex-direction": "row", "align-items": "center", gap: "6px" }
11
- }, Ee = ["data-cell", "onPointerenter"], Ge = ["data-cell"], Le = ["data-cell"], Ue = ["data-cell"], Be = ["data-cell"], Re = {
11
+ }, Ee = ["data-cell", "onPointerenter"], Ge = ["data-cell"], Le = ["data-cell"], Be = ["data-cell"], Re = ["data-cell"], Ue = {
12
12
  __name: "vue-ui-table-sparkline",
13
13
  props: {
14
14
  config: {
@@ -51,7 +51,7 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
51
51
  }, { deep: !0 }), Q(() => b.dataset, (t) => {
52
52
  x.value = y.value, C.value += 1;
53
53
  }, { deep: !0 });
54
- const { isPrinting: L, isImaging: U, generatePdf: B, generateImage: R } = ze({
54
+ const { isPrinting: L, isImaging: B, generatePdf: R, generateImage: U } = ze({
55
55
  elementId: `table_${F.value}`,
56
56
  fileName: e.value.title.text || "vue-ui-table-sparkline"
57
57
  }), ae = g(() => ke(e.value.customPalette)), I = d(null), H = d(!1), le = g(() => e.value.responsiveBreakpoint);
@@ -156,8 +156,8 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
156
156
  });
157
157
  }
158
158
  return ee({
159
- generatePdf: B,
160
- generateImage: R,
159
+ generatePdf: R,
160
+ generateImage: U,
161
161
  generateCsv: K,
162
162
  restoreOrder: ue
163
163
  }), (t, u) => (s(), v("div", {
@@ -218,7 +218,7 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
218
218
  }),
219
219
  class: "sticky-col-first"
220
220
  }, p(e.value.translations.serie), 5),
221
- (s(!0), v(T, null, M(k.value, (a, o) => (s(), v("th", {
221
+ (s(!0), v(T, null, V(k.value, (a, o) => (s(), v("th", {
222
222
  role: "cell",
223
223
  style: r({
224
224
  background: e.value.thead.backgroundColor,
@@ -233,21 +233,21 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
233
233
  }, [
234
234
  c("div", Te, [
235
235
  c("span", null, p(a), 1),
236
- O.value && o === N.value && y.value[0].values[o] !== void 0 ? (s(), V(Pe, {
236
+ O.value && o === N.value && y.value[0].values[o] !== void 0 ? (s(), M(Pe, {
237
237
  key: 0,
238
238
  size: 18,
239
239
  name: W.value === 1 ? "sort" : "sortReverse",
240
240
  stroke: e.value.thead.color
241
241
  }, null, 8, ["name", "stroke"])) : h("", !0)
242
242
  ]),
243
- e.value.userOptions.show && o === k.value.length - 1 ? (s(), V(Fe, {
243
+ e.value.userOptions.show && o === k.value.length - 1 ? (s(), M(Fe, {
244
244
  ref_for: !0,
245
245
  ref: "details",
246
246
  key: `user_option_${E.value}`,
247
247
  backgroundColor: e.value.thead.backgroundColor,
248
248
  color: e.value.thead.color,
249
249
  isPrinting: i(L),
250
- isImaging: i(U),
250
+ isImaging: i(B),
251
251
  uid: F.value,
252
252
  hasPdf: e.value.userOptions.buttons.pdf,
253
253
  hasXls: e.value.userOptions.buttons.csv,
@@ -257,8 +257,8 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
257
257
  titles: { ...e.value.userOptions.buttonTitles },
258
258
  chartElement: I.value,
259
259
  onToggleFullscreen: de,
260
- onGeneratePdf: i(B),
261
- onGenerateImage: i(R),
260
+ onGeneratePdf: i(R),
261
+ onGenerateImage: i(U),
262
262
  onGenerateCsv: K
263
263
  }, fe({ _: 2 }, [
264
264
  t.$slots.optionPdf ? {
@@ -294,7 +294,7 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
294
294
  ], 4)
295
295
  ]),
296
296
  c("tbody", null, [
297
- (s(!0), v(T, null, M(x.value, (a, o) => (s(), v("tr", {
297
+ (s(!0), v(T, null, V(x.value, (a, o) => (s(), v("tr", {
298
298
  role: "row",
299
299
  style: r({
300
300
  backgroundColor: e.value.tbody.backgroundColor,
@@ -314,14 +314,14 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
314
314
  "data-cell": e.value.translations.serie,
315
315
  class: "vue-ui-data-table__tbody__td sticky-col-first"
316
316
  }, [
317
- c("div", Ve, [
317
+ c("div", Me, [
318
318
  c("span", {
319
319
  style: r({ color: a.color })
320
320
  }, "⬤", 4),
321
321
  c("span", null, p(a.name ?? "-"), 1)
322
322
  ])
323
- ], 12, Me),
324
- (s(!0), v(T, null, M(ne.value, (n, l) => (s(), v("td", {
323
+ ], 12, Ve),
324
+ (s(!0), v(T, null, V(ne.value, (n, l) => (s(), v("td", {
325
325
  dir: "auto",
326
326
  role: "cell",
327
327
  style: r({
@@ -416,7 +416,7 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
416
416
  r: e.value.roundingMedian
417
417
  }),
418
418
  { datapoint: a.median, seriesIndex: o }
419
- )), 13, Ue)) : h("", !0),
419
+ )), 13, Be)) : h("", !0),
420
420
  e.value.showSparklines ? (s(), v("td", {
421
421
  key: 3,
422
422
  role: "cell",
@@ -429,7 +429,7 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
429
429
  }),
430
430
  class: "vue-ui-data-table__tbody__td sticky-col"
431
431
  }, [
432
- (s(), V($e, {
432
+ (s(), M($e, {
433
433
  key: `sparkline_${o}_${C.value}`,
434
434
  onHoverIndex: ({ index: n }) => ie({ dataIndex: n, serieIndex: o }),
435
435
  dataset: a.sparklineDataset,
@@ -440,7 +440,7 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
440
440
  style: {
441
441
  backgroundColor: e.value.tbody.backgroundColor,
442
442
  animation: {
443
- show: e.value.sparkline.animation.show && !i(L) && !i(U),
443
+ show: e.value.sparkline.animation.show && !i(L) && !i(B),
444
444
  animationFrames: e.value.sparkline.animation.animationFrames
445
445
  },
446
446
  line: {
@@ -467,14 +467,14 @@ const Ne = ["id"], We = { style: { "z-index": "1", "padding-right": "24px" } },
467
467
  }
468
468
  }
469
469
  }, null, 8, ["onHoverIndex", "dataset", "selectedIndex", "config"]))
470
- ], 12, Be)) : h("", !0)
470
+ ], 12, Re)) : h("", !0)
471
471
  ], 6))), 256))
472
472
  ])
473
473
  ], 4)
474
474
  ], 32)
475
475
  ], 10, Ne));
476
476
  }
477
- }, Ze = /* @__PURE__ */ Oe(Re, [["__scopeId", "data-v-7094f9b2"]]);
477
+ }, Ze = /* @__PURE__ */ Oe(Ue, [["__scopeId", "data-v-7094f9b2"]]);
478
478
  export {
479
479
  Ze as default
480
480
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-BTgtr0F8.cjs"),$=require("./useNestedProp-CisbRRo_.cjs"),J=require("./vue-ui-sparkline-CDowaDRS.cjs"),K=require("./BaseIcon-DB7Apwv_.cjs"),D=require("./usePrinter-DzTaA1eh.cjs"),Q=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Y=["id"],Z={style:{"z-index":"1","padding-right":"24px"}},j=["onClick"],ee={style:{display:"flex","flex-direction":"row",gap:"3px","align-items":"center"}},te=["data-cell"],le={dir:"auto",style:{display:"flex","flex-direction":"row","align-items":"center",gap:"6px"}},ae=["data-cell","onPointerenter"],oe=["data-cell"],ne=["data-cell"],re=["data-cell"],ue=["data-cell"],se={__name:"vue-ui-table-sparkline",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},setup(F,{expose:O}){const d=F;e.useCssVars(l=>({"470f7d5c":l.tdo}));const{vue_ui_table_sparkline:W}=u.useConfig(),h=e.ref(u.createUid()),S=e.ref(0),b=e.ref(0),t=e.computed({get:()=>C(),set:l=>l});function C(){const l=$.useNestedProp({userConfig:d.config,defaultConfig:W});return l.theme?{...$.useNestedProp({userConfig:u.themes.vue_ui_table_sparkline[l.theme]||d.config,defaultConfig:l}),customPalette:u.themePalettes[l.theme]||u.palette}:l}e.watch(()=>d.config,l=>{t.value=C(),A(),b.value+=1},{deep:!0}),e.watch(()=>d.dataset,l=>{f.value=v.value,b.value+=1},{deep:!0});const{isPrinting:w,isImaging:z,generatePdf:I,generateImage:N}=D.usePrinter({elementId:`table_${h.value}`,fileName:t.value.title.text||"vue-ui-table-sparkline"}),L=e.computed(()=>u.convertCustomPalette(t.value.customPalette)),g=e.ref(null),B=e.ref(!1),T=e.computed(()=>t.value.responsiveBreakpoint);e.onMounted(()=>{A()});function A(){u.objectIsEmpty(d.dataset)&&u.error({componentName:"VueUiTableSparkline",type:"dataset"});const l=new ResizeObserver(s=>{s.forEach(a=>{B.value=a.contentRect.width<T.value})});g.value&&l.observe(g.value)}const E=e.computed(()=>(d.dataset.forEach((l,s)=>{u.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","values"]}).forEach(a=>{u.error({componentName:"VueUiTableSparkline",type:"datasetSerieAttribute",property:a,index:s})})}),d.dataset.map((l,s)=>{const a=(l.values||[]).map(r=>isNaN(r)?0:r??0),n=a.reduce((r,o)=>r+o,0);return{...l,values:l.values||[],color:u.convertColorToHex(l.color)||L.value[s]||u.palette[s]||u.palette[s%u.palette.length],sum:n,average:n/a.length,median:u.calcMedian(a),sparklineDataset:a.map((r,o)=>({period:t.value.colNames[o]||`col ${o}`,value:r||0}))}})));function M(l){const a=(l[0].values||[]).map((r,o)=>l.map(i=>i.values[o]||[])).map(r=>r.map((o,i)=>[o,i]).sort((o,i)=>i[0]-o[0]).map(o=>o[1]));return l.map((r,o)=>({...r,values:r.values||[],orders:a[o]}))}const v=e.computed(()=>M(E.value)),f=e.ref(v.value),G=e.computed(()=>Math.max(...f.value.map(l=>(l.values||[]).length))),y=e.ref(void 0),k=e.ref(!1),_=e.ref(void 0),x=e.ref(-1);function q(){k.value=!1,_.value=void 0,x.value=-1,f.value=v.value}function R(l){k.value=!0,_.value=l;const s=v.value.map(o=>o.values[l]||[]),a=y.value===l?1:-1;x.value=a,l===y.value?y.value=void 0:y.value=l;const r=s.map((o,i)=>[i,o]).sort((o,i)=>a*(i[1]-o[1])).map(o=>o[0]).map(o=>v.value[o]);f.value=r,b.value+=1}const U=e.computed(()=>Math.max(...d.dataset.map(l=>(l.values||[]).length))),m=e.computed(()=>{let l=t.value.colNames;if(!l.length)for(let a=0;a<U.value;a+=1)l.push(`col ${a+1}`);t.value.showTotal&&(l=[...l,t.value.translations.total]);let s;return t.value.showAverage&&t.value.showMedian?s=[...l,t.value.translations.average,t.value.translations.median]:t.value.showAverage&&!t.value.showMedian?s=[...l,t.value.translations.average]:!t.value.showAverage&&t.value.showMedian?s=[...l,t.value.translations.median]:s=l,t.value.showSparklines?[...s,t.value.translations.chart]:s}),c=e.ref(void 0),p=e.ref(void 0);function H({dataIndex:l,serieIndex:s}){c.value=l,p.value=s}const V=e.ref(!1);function X(l){V.value=l,S.value+=1}function P(){e.nextTick(()=>{const l=[t.value.translations.serie].concat(m.value),s=E.value.map((r,o)=>[[r.name],r.values,[r.sum],[r.average],[r.median]]),a=[l].concat(s),n=u.createCsvContent(a);u.downloadCsv({csvContent:n,title:t.value.title.text||"vue-ui-table-sparkline"})})}return O({generatePdf:I,generateImage:N,generateCsv:P,restoreOrder:q}),(l,s)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"tableContainer",ref:g,class:e.normalizeClass({"vue-ui-responsive":B.value}),style:{overflow:"hidden"},id:`table_${h.value}`},[e.createElementVNode("div",{style:{overflow:"auto"},onPointerleave:s[0]||(s[0]=a=>{p.value=void 0,c.value=void 0})},[e.createElementVNode("table",{class:"vue-ui-data-table",style:e.normalizeStyle({fontFamily:t.value.fontFamily,position:"relative"})},[t.value.title.text?(e.openBlock(),e.createElementBlock("caption",{key:0,style:e.normalizeStyle({backgroundColor:t.value.title.backgroundColor})},[e.createElementVNode("div",{style:e.normalizeStyle({fontSize:`${t.value.title.fontSize}px`,fontWeight:t.value.title.bold?"bold":"normal",color:t.value.title.color,textAlign:t.value.title.textAlign})},e.toDisplayString(t.value.title.text),5),t.value.title.subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({fontSize:`${t.value.title.subtitle.fontSize}px`,fontWeight:t.value.title.subtitle.bold?"bold":"normal",color:t.value.title.subtitle.color,textAlign:t.value.title.textAlign})},e.toDisplayString(t.value.title.subtitle.text),5)):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0),e.createElementVNode("thead",Z,[e.createElementVNode("tr",{role:"row",class:"vue-ui-data-table__thead-row",style:e.normalizeStyle({backgroundColor:t.value.thead.backgroundColor,color:t.value.thead.color})},[e.createElementVNode("th",{role:"cell",style:e.normalizeStyle({backgroundColor:t.value.thead.backgroundColor,outline:t.value.thead.outline,textAlign:t.value.thead.textAlign,fontWeight:t.value.thead.bold?"bold":"normal"}),class:"sticky-col-first"},e.toDisplayString(t.value.translations.serie),5),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(a,n)=>(e.openBlock(),e.createElementBlock("th",{role:"cell",style:e.normalizeStyle({background:t.value.thead.backgroundColor,outline:t.value.thead.outline,textAlign:t.value.thead.textAlign,fontWeight:t.value.thead.bold?"bold":"normal",minWidth:n===m.value.length-1?"150px":"",cursor:v.value[0].values[n]!==void 0?"pointer":"default"}),onClick:()=>R(n),class:e.normalizeClass({"sticky-col":n===m.value.length-1&&t.value.showSparklines})},[e.createElementVNode("div",ee,[e.createElementVNode("span",null,e.toDisplayString(a),1),k.value&&n===_.value&&v.value[0].values[n]!==void 0?(e.openBlock(),e.createBlock(K.default,{key:0,size:18,name:x.value===1?"sort":"sortReverse",stroke:t.value.thead.color},null,8,["name","stroke"])):e.createCommentVNode("",!0)]),t.value.userOptions.show&&n===m.value.length-1?(e.openBlock(),e.createBlock(D.UserOptions,{ref_for:!0,ref:"details",key:`user_option_${S.value}`,backgroundColor:t.value.thead.backgroundColor,color:t.value.thead.color,isPrinting:e.unref(w),isImaging:e.unref(z),uid:h.value,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:V.value,titles:{...t.value.userOptions.buttonTitles},chartElement:g.value,onToggleFullscreen:X,onGeneratePdf:e.unref(I),onGenerateImage:e.unref(N),onGenerateCsv:P},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:r,isFullscreen:o})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:r,isFullscreen:o})),void 0,!0)]),key:"3"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasXls","hasImg","hasFullscreen","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0)],14,j))),256))],4)]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(a,n)=>(e.openBlock(),e.createElementBlock("tr",{role:"row",style:e.normalizeStyle({backgroundColor:t.value.tbody.backgroundColor,color:t.value.tbody.color}),class:e.normalizeClass({"vue-ui-data-table__tbody__row":!0,"vue-ui-data-table__tbody__row-even":n%2===0,"vue-ui-data-table__tbody__row-odd":n%2!==0})},[e.createElementVNode("td",{role:"cell",style:e.normalizeStyle({backgroundColor:t.value.tbody.backgroundColor,outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.serie,class:"vue-ui-data-table__tbody__td sticky-col-first"},[e.createElementVNode("div",le,[e.createElementVNode("span",{style:e.normalizeStyle({color:a.color})},"⬤",4),e.createElementVNode("span",null,e.toDisplayString(a.name??"-"),1)])],12,te),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G.value,(r,o)=>(e.openBlock(),e.createElementBlock("td",{dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign,backgroundColor:c.value!==void 0&&p.value!==void 0&&o===c.value&&p.value===n?`${a.color}33`:"",borderRadius:c.value!==void 0&&p.value!==void 0&&o===c.value&&p.value===n?"3px":""}),"data-cell":m.value[o],class:"vue-ui-data-table__tbody__td",onPointerenter:i=>{p.value=n,c.value=o}},e.toDisplayString([null,void 0].includes(a.values[o])?"-":e.unref(u.applyDataLabel)(t.value.formatter,Number(a.values[o]),e.unref(u.dataLabel)({p:t.value.prefix,v:Number(a.values[o]),s:t.value.suffix,r:t.value.roundingValues}),{datapoint:a,seriesIndex:n,datapointIndex:o})),45,ae))),256)),t.value.showTotal?(e.openBlock(),e.createElementBlock("td",{key:0,dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.total,class:"vue-ui-data-table__tbody__td"},e.toDisplayString(e.unref(u.applyDataLabel)(t.value.formatter,a.sum,e.unref(u.dataLabel)({p:t.value.prefix,v:a.sum,s:t.value.suffix,r:t.value.roundingTotal}),{datapoint:a.sum,seriesIndex:n})),13,oe)):e.createCommentVNode("",!0),t.value.showAverage?(e.openBlock(),e.createElementBlock("td",{key:1,dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.average,class:"vue-ui-data-table__tbody__td"},e.toDisplayString(e.unref(u.applyDataLabel)(t.value.formatter,a.average,e.unref(u.dataLabel)({p:t.value.prefix,v:a.average,s:t.value.suffix,r:t.value.roundingAverage}),{datapoint:a.average,seriesIndex:n})),13,ne)):e.createCommentVNode("",!0),t.value.showMedian?(e.openBlock(),e.createElementBlock("td",{key:2,dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.median,class:"vue-ui-data-table__tbody__td"},e.toDisplayString(e.unref(u.applyDataLabel)(t.value.formatter,a.median,e.unref(u.dataLabel)({p:t.value.prefix,v:a.median,s:t.value.suffix,r:t.value.roundingMedian}),{datapoint:a.median,seriesIndex:n})),13,re)):e.createCommentVNode("",!0),t.value.showSparklines?(e.openBlock(),e.createElementBlock("td",{key:3,role:"cell","data-cell":t.value.translations.chart,style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),class:"vue-ui-data-table__tbody__td sticky-col"},[(e.openBlock(),e.createBlock(J.default,{key:`sparkline_${n}_${b.value}`,onHoverIndex:({index:r})=>H({dataIndex:r,serieIndex:n}),dataset:a.sparklineDataset,showInfo:!1,selectedIndex:c.value,config:{type:t.value.sparkline.type,style:{backgroundColor:t.value.tbody.backgroundColor,animation:{show:t.value.sparkline.animation.show&&!e.unref(w)&&!e.unref(z),animationFrames:t.value.sparkline.animation.animationFrames},line:{color:a.color,smooth:t.value.sparkline.smooth,strokeWidth:t.value.sparkline.strokeWidth},bar:{color:a.color},area:{color:a.color,opacity:t.value.sparkline.showArea?16:0,useGradient:t.value.sparkline.useGradient},verticalIndicator:{color:a.color},plot:{radius:9,stroke:t.value.tbody.backgroundColor,strokeWidth:3}}}},null,8,["onHoverIndex","dataset","selectedIndex","config"]))],12,ue)):e.createCommentVNode("",!0)],6))),256))])],4)],32)],10,Y))}},ie=Q._export_sfc(se,[["__scopeId","data-v-7094f9b2"]]);exports.default=ie;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-TabZg_HV.cjs"),$=require("./useNestedProp-CoLyVvV9.cjs"),J=require("./vue-ui-sparkline-Bw3dw-vW.cjs"),K=require("./BaseIcon-CP535rdy.cjs"),D=require("./usePrinter--7sLxlpn.cjs"),Q=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Y=["id"],Z={style:{"z-index":"1","padding-right":"24px"}},j=["onClick"],ee={style:{display:"flex","flex-direction":"row",gap:"3px","align-items":"center"}},te=["data-cell"],le={dir:"auto",style:{display:"flex","flex-direction":"row","align-items":"center",gap:"6px"}},ae=["data-cell","onPointerenter"],oe=["data-cell"],ne=["data-cell"],re=["data-cell"],ue=["data-cell"],se={__name:"vue-ui-table-sparkline",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},setup(F,{expose:O}){const d=F;e.useCssVars(l=>({"470f7d5c":l.tdo}));const{vue_ui_table_sparkline:W}=u.useConfig(),h=e.ref(u.createUid()),S=e.ref(0),b=e.ref(0),t=e.computed({get:()=>C(),set:l=>l});function C(){const l=$.useNestedProp({userConfig:d.config,defaultConfig:W});return l.theme?{...$.useNestedProp({userConfig:u.themes.vue_ui_table_sparkline[l.theme]||d.config,defaultConfig:l}),customPalette:u.themePalettes[l.theme]||u.palette}:l}e.watch(()=>d.config,l=>{t.value=C(),A(),b.value+=1},{deep:!0}),e.watch(()=>d.dataset,l=>{f.value=v.value,b.value+=1},{deep:!0});const{isPrinting:w,isImaging:z,generatePdf:I,generateImage:N}=D.usePrinter({elementId:`table_${h.value}`,fileName:t.value.title.text||"vue-ui-table-sparkline"}),L=e.computed(()=>u.convertCustomPalette(t.value.customPalette)),g=e.ref(null),B=e.ref(!1),T=e.computed(()=>t.value.responsiveBreakpoint);e.onMounted(()=>{A()});function A(){u.objectIsEmpty(d.dataset)&&u.error({componentName:"VueUiTableSparkline",type:"dataset"});const l=new ResizeObserver(s=>{s.forEach(a=>{B.value=a.contentRect.width<T.value})});g.value&&l.observe(g.value)}const E=e.computed(()=>(d.dataset.forEach((l,s)=>{u.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","values"]}).forEach(a=>{u.error({componentName:"VueUiTableSparkline",type:"datasetSerieAttribute",property:a,index:s})})}),d.dataset.map((l,s)=>{const a=(l.values||[]).map(r=>isNaN(r)?0:r??0),n=a.reduce((r,o)=>r+o,0);return{...l,values:l.values||[],color:u.convertColorToHex(l.color)||L.value[s]||u.palette[s]||u.palette[s%u.palette.length],sum:n,average:n/a.length,median:u.calcMedian(a),sparklineDataset:a.map((r,o)=>({period:t.value.colNames[o]||`col ${o}`,value:r||0}))}})));function M(l){const a=(l[0].values||[]).map((r,o)=>l.map(i=>i.values[o]||[])).map(r=>r.map((o,i)=>[o,i]).sort((o,i)=>i[0]-o[0]).map(o=>o[1]));return l.map((r,o)=>({...r,values:r.values||[],orders:a[o]}))}const v=e.computed(()=>M(E.value)),f=e.ref(v.value),G=e.computed(()=>Math.max(...f.value.map(l=>(l.values||[]).length))),y=e.ref(void 0),k=e.ref(!1),_=e.ref(void 0),x=e.ref(-1);function q(){k.value=!1,_.value=void 0,x.value=-1,f.value=v.value}function R(l){k.value=!0,_.value=l;const s=v.value.map(o=>o.values[l]||[]),a=y.value===l?1:-1;x.value=a,l===y.value?y.value=void 0:y.value=l;const r=s.map((o,i)=>[i,o]).sort((o,i)=>a*(i[1]-o[1])).map(o=>o[0]).map(o=>v.value[o]);f.value=r,b.value+=1}const U=e.computed(()=>Math.max(...d.dataset.map(l=>(l.values||[]).length))),m=e.computed(()=>{let l=t.value.colNames;if(!l.length)for(let a=0;a<U.value;a+=1)l.push(`col ${a+1}`);t.value.showTotal&&(l=[...l,t.value.translations.total]);let s;return t.value.showAverage&&t.value.showMedian?s=[...l,t.value.translations.average,t.value.translations.median]:t.value.showAverage&&!t.value.showMedian?s=[...l,t.value.translations.average]:!t.value.showAverage&&t.value.showMedian?s=[...l,t.value.translations.median]:s=l,t.value.showSparklines?[...s,t.value.translations.chart]:s}),c=e.ref(void 0),p=e.ref(void 0);function H({dataIndex:l,serieIndex:s}){c.value=l,p.value=s}const V=e.ref(!1);function X(l){V.value=l,S.value+=1}function P(){e.nextTick(()=>{const l=[t.value.translations.serie].concat(m.value),s=E.value.map((r,o)=>[[r.name],r.values,[r.sum],[r.average],[r.median]]),a=[l].concat(s),n=u.createCsvContent(a);u.downloadCsv({csvContent:n,title:t.value.title.text||"vue-ui-table-sparkline"})})}return O({generatePdf:I,generateImage:N,generateCsv:P,restoreOrder:q}),(l,s)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"tableContainer",ref:g,class:e.normalizeClass({"vue-ui-responsive":B.value}),style:{overflow:"hidden"},id:`table_${h.value}`},[e.createElementVNode("div",{style:{overflow:"auto"},onPointerleave:s[0]||(s[0]=a=>{p.value=void 0,c.value=void 0})},[e.createElementVNode("table",{class:"vue-ui-data-table",style:e.normalizeStyle({fontFamily:t.value.fontFamily,position:"relative"})},[t.value.title.text?(e.openBlock(),e.createElementBlock("caption",{key:0,style:e.normalizeStyle({backgroundColor:t.value.title.backgroundColor})},[e.createElementVNode("div",{style:e.normalizeStyle({fontSize:`${t.value.title.fontSize}px`,fontWeight:t.value.title.bold?"bold":"normal",color:t.value.title.color,textAlign:t.value.title.textAlign})},e.toDisplayString(t.value.title.text),5),t.value.title.subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({fontSize:`${t.value.title.subtitle.fontSize}px`,fontWeight:t.value.title.subtitle.bold?"bold":"normal",color:t.value.title.subtitle.color,textAlign:t.value.title.textAlign})},e.toDisplayString(t.value.title.subtitle.text),5)):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0),e.createElementVNode("thead",Z,[e.createElementVNode("tr",{role:"row",class:"vue-ui-data-table__thead-row",style:e.normalizeStyle({backgroundColor:t.value.thead.backgroundColor,color:t.value.thead.color})},[e.createElementVNode("th",{role:"cell",style:e.normalizeStyle({backgroundColor:t.value.thead.backgroundColor,outline:t.value.thead.outline,textAlign:t.value.thead.textAlign,fontWeight:t.value.thead.bold?"bold":"normal"}),class:"sticky-col-first"},e.toDisplayString(t.value.translations.serie),5),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(a,n)=>(e.openBlock(),e.createElementBlock("th",{role:"cell",style:e.normalizeStyle({background:t.value.thead.backgroundColor,outline:t.value.thead.outline,textAlign:t.value.thead.textAlign,fontWeight:t.value.thead.bold?"bold":"normal",minWidth:n===m.value.length-1?"150px":"",cursor:v.value[0].values[n]!==void 0?"pointer":"default"}),onClick:()=>R(n),class:e.normalizeClass({"sticky-col":n===m.value.length-1&&t.value.showSparklines})},[e.createElementVNode("div",ee,[e.createElementVNode("span",null,e.toDisplayString(a),1),k.value&&n===_.value&&v.value[0].values[n]!==void 0?(e.openBlock(),e.createBlock(K.default,{key:0,size:18,name:x.value===1?"sort":"sortReverse",stroke:t.value.thead.color},null,8,["name","stroke"])):e.createCommentVNode("",!0)]),t.value.userOptions.show&&n===m.value.length-1?(e.openBlock(),e.createBlock(D.UserOptions,{ref_for:!0,ref:"details",key:`user_option_${S.value}`,backgroundColor:t.value.thead.backgroundColor,color:t.value.thead.color,isPrinting:e.unref(w),isImaging:e.unref(z),uid:h.value,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:V.value,titles:{...t.value.userOptions.buttonTitles},chartElement:g.value,onToggleFullscreen:X,onGeneratePdf:e.unref(I),onGenerateImage:e.unref(N),onGenerateCsv:P},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:r,isFullscreen:o})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:r,isFullscreen:o})),void 0,!0)]),key:"3"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasXls","hasImg","hasFullscreen","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0)],14,j))),256))],4)]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(a,n)=>(e.openBlock(),e.createElementBlock("tr",{role:"row",style:e.normalizeStyle({backgroundColor:t.value.tbody.backgroundColor,color:t.value.tbody.color}),class:e.normalizeClass({"vue-ui-data-table__tbody__row":!0,"vue-ui-data-table__tbody__row-even":n%2===0,"vue-ui-data-table__tbody__row-odd":n%2!==0})},[e.createElementVNode("td",{role:"cell",style:e.normalizeStyle({backgroundColor:t.value.tbody.backgroundColor,outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.serie,class:"vue-ui-data-table__tbody__td sticky-col-first"},[e.createElementVNode("div",le,[e.createElementVNode("span",{style:e.normalizeStyle({color:a.color})},"⬤",4),e.createElementVNode("span",null,e.toDisplayString(a.name??"-"),1)])],12,te),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G.value,(r,o)=>(e.openBlock(),e.createElementBlock("td",{dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign,backgroundColor:c.value!==void 0&&p.value!==void 0&&o===c.value&&p.value===n?`${a.color}33`:"",borderRadius:c.value!==void 0&&p.value!==void 0&&o===c.value&&p.value===n?"3px":""}),"data-cell":m.value[o],class:"vue-ui-data-table__tbody__td",onPointerenter:i=>{p.value=n,c.value=o}},e.toDisplayString([null,void 0].includes(a.values[o])?"-":e.unref(u.applyDataLabel)(t.value.formatter,Number(a.values[o]),e.unref(u.dataLabel)({p:t.value.prefix,v:Number(a.values[o]),s:t.value.suffix,r:t.value.roundingValues}),{datapoint:a,seriesIndex:n,datapointIndex:o})),45,ae))),256)),t.value.showTotal?(e.openBlock(),e.createElementBlock("td",{key:0,dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.total,class:"vue-ui-data-table__tbody__td"},e.toDisplayString(e.unref(u.applyDataLabel)(t.value.formatter,a.sum,e.unref(u.dataLabel)({p:t.value.prefix,v:a.sum,s:t.value.suffix,r:t.value.roundingTotal}),{datapoint:a.sum,seriesIndex:n})),13,oe)):e.createCommentVNode("",!0),t.value.showAverage?(e.openBlock(),e.createElementBlock("td",{key:1,dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.average,class:"vue-ui-data-table__tbody__td"},e.toDisplayString(e.unref(u.applyDataLabel)(t.value.formatter,a.average,e.unref(u.dataLabel)({p:t.value.prefix,v:a.average,s:t.value.suffix,r:t.value.roundingAverage}),{datapoint:a.average,seriesIndex:n})),13,ne)):e.createCommentVNode("",!0),t.value.showMedian?(e.openBlock(),e.createElementBlock("td",{key:2,dir:"auto",role:"cell",style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),"data-cell":t.value.translations.median,class:"vue-ui-data-table__tbody__td"},e.toDisplayString(e.unref(u.applyDataLabel)(t.value.formatter,a.median,e.unref(u.dataLabel)({p:t.value.prefix,v:a.median,s:t.value.suffix,r:t.value.roundingMedian}),{datapoint:a.median,seriesIndex:n})),13,re)):e.createCommentVNode("",!0),t.value.showSparklines?(e.openBlock(),e.createElementBlock("td",{key:3,role:"cell","data-cell":t.value.translations.chart,style:e.normalizeStyle({outline:t.value.tbody.outline,fontSize:`${t.value.tbody.fontSize}px`,fontWeight:t.value.tbody.bold?"bold":"normal",textAlign:t.value.tbody.textAlign}),class:"vue-ui-data-table__tbody__td sticky-col"},[(e.openBlock(),e.createBlock(J.default,{key:`sparkline_${n}_${b.value}`,onHoverIndex:({index:r})=>H({dataIndex:r,serieIndex:n}),dataset:a.sparklineDataset,showInfo:!1,selectedIndex:c.value,config:{type:t.value.sparkline.type,style:{backgroundColor:t.value.tbody.backgroundColor,animation:{show:t.value.sparkline.animation.show&&!e.unref(w)&&!e.unref(z),animationFrames:t.value.sparkline.animation.animationFrames},line:{color:a.color,smooth:t.value.sparkline.smooth,strokeWidth:t.value.sparkline.strokeWidth},bar:{color:a.color},area:{color:a.color,opacity:t.value.sparkline.showArea?16:0,useGradient:t.value.sparkline.useGradient},verticalIndicator:{color:a.color},plot:{radius:9,stroke:t.value.tbody.backgroundColor,strokeWidth:3}}}},null,8,["onHoverIndex","dataset","selectedIndex","config"]))],12,ue)):e.createCommentVNode("",!0)],6))),256))])],4)],32)],10,Y))}},ie=Q._export_sfc(se,[["__scopeId","data-v-7094f9b2"]]);exports.default=ie;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-BTgtr0F8.cjs"),X=require("./Title-3EduyW4p.cjs"),q=require("./usePrinter-DzTaA1eh.cjs"),J=require("./vue-ui-skeleton-CMQzFTs9.cjs"),T=require("./useNestedProp-CisbRRo_.cjs"),K=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Q=["id"],Z={key:0,style:"width:100%"},ee=["xmlns","viewBox"],te={id:"vueUiPill",clipPathUnits:"objectBoundingBox"},oe=["fill"],le=["id"],re=["stop-color"],ae=["stop-color"],se=["stop-color"],ne={"clip-path":"url(#vueUiPill)"},ue=["x","y","height","width"],ce=["x","y","height","width","fill"],ie=["x1","x2","y1","y2","stroke-width","stroke"],de=["x1","x2","y1","y2","stroke-width","stroke"],he=["x1","x2","y1","y2","stroke-width","stroke"],ve=["x1","x2","y1","y2","stroke-width","stroke"],me=["x1","x2","y1","y2","stroke-width","stroke"],ye=["x1","x2","y1","y2","stroke-width","stroke"],pe=["x1","x2","y1","y2","stroke-width","stroke"],fe=["x1","x2","y1","y2","stroke-width","stroke"],ge=["x","y","height","width"],ke=["y","x","fill","font-size","font-weight"],xe={key:3,class:"vue-data-ui-watermark"},be={__name:"vue-ui-thermometer",props:{dataset:{type:Object,default(){return{}}},config:{type:Object,default(){return{}}}},setup(m,{expose:Y}){const s=m;e.useCssVars(l=>({"0a35d02c":G.value,"2925bde2":U.value,"636d634f":L.value}));const{vue_ui_thermometer:M}=r.useConfig(),f=e.computed(()=>!!s.dataset&&Object.keys(s.dataset).length);e.onMounted(()=>{w()});function w(){r.objectIsEmpty(s.dataset)?r.error({componentName:"VueUiThermometer",type:"dataset"}):r.getMissingDatasetAttributes({datasetObject:s.dataset,requiredAttributes:["value","from","to"]}).forEach(l=>{r.error({componentName:"VueUiThermometer",type:"datasetAttribute",property:l})})}const d=e.ref(r.createUid()),C=e.ref(null),N=e.ref(0),B=e.ref(0),t=e.computed({get:()=>E(),set:l=>l});function E(){const l=T.useNestedProp({userConfig:s.config,defaultConfig:M});return l.theme?{...T.useNestedProp({userConfig:r.themes.vue_ui_thermometer[l.theme]||s.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>s.config,l=>{t.value=E(),w(),B.value+=1},{deep:!0});const{isPrinting:V,isImaging:$,generatePdf:P,generateImage:F}=q.usePrinter({elementId:`thermometer__${d.value}`,fileName:t.value.style.title.text||"vue-ui-thermometer"}),y=e.computed(()=>r.convertCustomPalette(t.value.customPalette)),O=e.computed(()=>t.value.style.chart.thermometer.width),i=e.computed(()=>s.dataset.steps||10),c=e.ref({top:t.value.style.chart.padding.top,left:t.value.style.chart.padding.left,right:t.value.style.chart.padding.right,bottom:t.value.style.chart.padding.bottom});function p(l,n,o){const u=[],b=I(l),_=I(n);for(let v=0;v<o;v++){const j=g(b.red,_.red,v,o),A=g(b.green,_.green,v,o),D=g(b.blue,_.blue,v,o),R=`#${k(j)}${k(A)}${k(D)}`;u.push(R)}return u}function I(l){const n=l.slice(1);return{red:parseInt(n.slice(0,2),16),green:parseInt(n.slice(2,4),16),blue:parseInt(n.slice(4,6),16)}}function g(l,n,o,u){return Math.round(l+(n-l)*o/u)}function k(l){return l.toString(16).padStart(2,"0")}const a=e.computed(()=>{const l=O.value+c.value.left+c.value.right,n=t.value.style.chart.height;return{width:l,left:c.value.left,right:l-c.value.right,top:c.value.top,bottom:n-c.value.bottom,height:n}}),z=e.computed(()=>a.value),x=e.computed(()=>{const l=r.checkNaN(s.dataset.from)<0?Math.abs(r.checkNaN(s.dataset.from)):r.checkNaN(s.dataset.from),n=r.checkNaN(s.dataset.to)<0?Math.abs(r.checkNaN(s.dataset.to)):r.checkNaN(s.dataset.to);let o=0;return r.checkNaN(s.dataset.to)>0?o=l+n:l>n?o=l-n:o=n-l,(1-(Math.abs(r.checkNaN(s.dataset.from))+r.checkNaN(s.dataset.value))/o)*(a.value.height-c.value.top-c.value.bottom)}),L=e.computed(()=>`${x.value}px`),U=e.computed(()=>`${a.value.height-t.value.style.chart.padding.bottom-c.value.top}px`),G=e.computed(()=>`${t.value.style.chart.animation.speedMs}ms`),W=e.computed(()=>{if(s.dataset.colors){if(!s.dataset.colors.from)return p(y.value[0]||r.palette[0],r.convertColorToHex(s.dataset.colors.to),i.value||10);if(!s.dataset.colors.to)return p(r.convertColorToHex(s.dataset.colors.from),y.value[1]||r.palette[1],i.value||10)}else return p(y.value[1]||r.palette[1],y.value[0]||r.palette[0],i.value||10);return p(r.convertColorToHex(s.dataset.colors.from),r.convertColorToHex(s.dataset.colors.to),i.value||10)}),S=e.computed(()=>{const l=[];let n=0;const o=a.value.height-c.value.top-c.value.bottom;for(let u=0;u<o-1;u+=o/i.value)l.push({x:a.value.left,y:a.value.top+u,qYLess:a.value.top+u+o/i.value/4,halfY:a.value.top+u+o/i.value/2,qYMore:a.value.top+u+o/i.value/4*3,color:W.value[n],height:o/i.value}),n+=1;return l}),h=e.ref(!1);function H(l){h.value=l,N.value+=1}return Y({generatePdf:P,generateImage:F}),(l,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"thermoChart",ref:C,class:e.normalizeClass(`vue-ui-thermometer ${h.value?"vue-data-ui-wrapper-fullscreen":""}`),style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};color:${t.value.style.chart.color};font-family:${t.value.style.fontFamily}`),id:`thermometer__${d.value}`},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",Z,[(e.openBlock(),e.createBlock(X._sfc_main,{key:`title_${B.value}`,config:{title:{cy:"thermometer-div-title",...t.value.style.title},subtitle:{cy:"thermometer-div-subtitle",...t.value.style.title.subtitle}}},null,8,["config"]))])):e.createCommentVNode("",!0),t.value.userOptions.show&&f.value?(e.openBlock(),e.createBlock(q.UserOptions,{ref:"details",key:`user_options_${N.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref($),isPrinting:e.unref(V),uid:d.value,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasFullscreen:t.value.userOptions.buttons.fullscreen,hasXls:!1,isFullscreen:h.value,titles:{...t.value.userOptions.buttonTitles},chartElement:C.value,onToggleFullscreen:H,onGeneratePdf:e.unref(P),onGenerateImage:e.unref(F)},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:o,isFullscreen:u})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:u})),void 0,!0)]),key:"2"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasFullscreen","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),f.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(r.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":h.value,"vue-data-ui-fulscreen--off":!h.value}),width:"100%",viewBox:`0 0 ${a.value.width} ${a.value.height}`,style:e.normalizeStyle(`background:${t.value.style.chart.backgroundColor}`)},[e.createElementVNode("defs",null,[e.createElementVNode("clipPath",te,[e.createElementVNode("rect",{x:"0",y:"0",width:"1",height:"1",rx:"0.5",ry:"0.07",fill:t.value.style.chart.backgroundColor},null,8,oe)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(o,u)=>(e.openBlock(),e.createElementBlock("linearGradient",{id:`vueUiThermometerGradient_${u}_${d.value}`,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[e.createElementVNode("stop",{offset:"0%","stop-color":o.color},null,8,re),e.createElementVNode("stop",{offset:"50%","stop-color":`${o.color}${e.unref(r.opacity)[100-t.value.style.chart.graduations.gradient.intensity]}`},null,8,ae),e.createElementVNode("stop",{offset:"100%","stop-color":o.color},null,8,se)],8,le))),256))]),e.createElementVNode("g",ne,[e.createElementVNode("rect",{x:a.value.left,y:a.value.top,height:a.value.height-c.value.top-c.value.bottom,width:a.value.width-c.value.left-c.value.right,fill:"#FFFFFF"},null,8,ue),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(o,u)=>(e.openBlock(),e.createElementBlock("g",{key:`graduation_${u}`},[e.createElementVNode("rect",{x:o.x,y:o.y,height:o.height,width:a.value.width-t.value.style.chart.padding.left-t.value.style.chart.padding.right,fill:t.value.style.chart.graduations.gradient.show?`url(#vueUiThermometerGradient_${u}_${d.value})`:o.color,"shape-rendering":"crispEdges"},null,8,ce),t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:0,x1:o.x,x2:o.x+10,y1:o.y,y2:o.y,"stroke-width":t.value.style.chart.graduations.strokeWidth,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,ie)):e.createCommentVNode("",!0),t.value.style.chart.graduations.showIntermediate?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:0,x1:o.x,x2:o.x+5,y1:o.halfY,y2:o.halfY,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,de)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:1,x1:o.x,x2:o.x+2.5,y1:o.qYLess,y2:o.qYLess,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,he)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:o.x,x2:o.x+2.5,y1:o.qYMore,y2:o.qYMore,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,ve)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:a.value.right,x2:a.value.right-10,y1:o.y,y2:o.y,"stroke-width":t.value.style.chart.graduations.strokeWidth,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,me)):e.createCommentVNode("",!0),t.value.style.chart.graduations.showIntermediate?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:0,x1:a.value.right,x2:a.value.right-5,y1:o.halfY,y2:o.halfY,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,ye)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:1,x1:a.value.right,x2:a.value.right-2.5,y1:o.qYLess,y2:o.qYLess,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,pe)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:a.value.right,x2:a.value.right-2.5,y1:o.qYMore,y2:o.qYMore,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,fe)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)]))),128)),e.createElementVNode("rect",{class:e.normalizeClass({"vue-ui-thermometer-temperature":t.value.style.chart.animation.use}),x:a.value.left,y:a.value.top,height:x.value,width:a.value.width-t.value.style.chart.padding.left-t.value.style.chart.padding.right,fill:"#FFFFFF66"},null,10,ge)]),e.createElementVNode("text",{class:e.normalizeClass({"vue-ui-thermometer-temperature-value":t.value.style.chart.animation.use}),y:x.value+a.value.top+t.value.style.chart.label.fontSize/3,x:a.value.left-10,"text-anchor":"end",fill:t.value.style.chart.label.color,"font-size":t.value.style.chart.label.fontSize,"font-weight":t.value.style.chart.label.bold?"bold":"normal"},e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.label.formatter,m.dataset.value,e.unref(r.dataLabel)({p:t.value.style.chart.label.prefix,v:m.dataset.value,s:t.value.style.chart.label.suffix,r:t.value.style.chart.label.rounding}),{datapoint:m.dataset})),11,ke),e.renderSlot(l.$slots,"svg",{svg:z.value},void 0,!0)],14,ee)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",xe,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(V)||e.unref($)})),void 0,!0)])):e.createCommentVNode("",!0),f.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(J.default,{key:4,config:{type:"thermometer",style:{backgroundColor:t.value.style.chart.backgroundColor,thermometer:{color:"#CCCCCC"}}}},null,8,["config"]))],14,Q))}},_e=K._export_sfc(be,[["__scopeId","data-v-900932c6"]]);exports.default=_e;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-TabZg_HV.cjs"),X=require("./Title-D9lSjLTg.cjs"),q=require("./usePrinter--7sLxlpn.cjs"),J=require("./vue-ui-skeleton-CYeXVNFu.cjs"),T=require("./useNestedProp-CoLyVvV9.cjs"),K=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Q=["id"],Z={key:0,style:"width:100%"},ee=["xmlns","viewBox"],te={id:"vueUiPill",clipPathUnits:"objectBoundingBox"},oe=["fill"],le=["id"],re=["stop-color"],ae=["stop-color"],se=["stop-color"],ne={"clip-path":"url(#vueUiPill)"},ue=["x","y","height","width"],ce=["x","y","height","width","fill"],ie=["x1","x2","y1","y2","stroke-width","stroke"],de=["x1","x2","y1","y2","stroke-width","stroke"],he=["x1","x2","y1","y2","stroke-width","stroke"],ve=["x1","x2","y1","y2","stroke-width","stroke"],me=["x1","x2","y1","y2","stroke-width","stroke"],ye=["x1","x2","y1","y2","stroke-width","stroke"],pe=["x1","x2","y1","y2","stroke-width","stroke"],fe=["x1","x2","y1","y2","stroke-width","stroke"],ge=["x","y","height","width"],ke=["y","x","fill","font-size","font-weight"],xe={key:3,class:"vue-data-ui-watermark"},be={__name:"vue-ui-thermometer",props:{dataset:{type:Object,default(){return{}}},config:{type:Object,default(){return{}}}},setup(m,{expose:Y}){const s=m;e.useCssVars(l=>({"5d70f0a2":G.value,"3d4eac2c":U.value,"8e9d47ce":L.value}));const{vue_ui_thermometer:M}=r.useConfig(),f=e.computed(()=>!!s.dataset&&Object.keys(s.dataset).length);e.onMounted(()=>{w()});function w(){r.objectIsEmpty(s.dataset)?r.error({componentName:"VueUiThermometer",type:"dataset"}):r.getMissingDatasetAttributes({datasetObject:s.dataset,requiredAttributes:["value","from","to"]}).forEach(l=>{r.error({componentName:"VueUiThermometer",type:"datasetAttribute",property:l})})}const d=e.ref(r.createUid()),C=e.ref(null),N=e.ref(0),B=e.ref(0),t=e.computed({get:()=>E(),set:l=>l});function E(){const l=T.useNestedProp({userConfig:s.config,defaultConfig:M});return l.theme?{...T.useNestedProp({userConfig:r.themes.vue_ui_thermometer[l.theme]||s.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>s.config,l=>{t.value=E(),w(),B.value+=1},{deep:!0});const{isPrinting:V,isImaging:P,generatePdf:F,generateImage:$}=q.usePrinter({elementId:`thermometer__${d.value}`,fileName:t.value.style.title.text||"vue-ui-thermometer"}),y=e.computed(()=>r.convertCustomPalette(t.value.customPalette)),O=e.computed(()=>t.value.style.chart.thermometer.width),i=e.computed(()=>s.dataset.steps||10),c=e.ref({top:t.value.style.chart.padding.top,left:t.value.style.chart.padding.left,right:t.value.style.chart.padding.right,bottom:t.value.style.chart.padding.bottom});function p(l,n,o){const u=[],b=I(l),_=I(n);for(let v=0;v<o;v++){const j=g(b.red,_.red,v,o),A=g(b.green,_.green,v,o),D=g(b.blue,_.blue,v,o),R=`#${k(j)}${k(A)}${k(D)}`;u.push(R)}return u}function I(l){const n=l.slice(1);return{red:parseInt(n.slice(0,2),16),green:parseInt(n.slice(2,4),16),blue:parseInt(n.slice(4,6),16)}}function g(l,n,o,u){return Math.round(l+(n-l)*o/u)}function k(l){return l.toString(16).padStart(2,"0")}const a=e.computed(()=>{const l=O.value+c.value.left+c.value.right,n=t.value.style.chart.height;return{width:l,left:c.value.left,right:l-c.value.right,top:c.value.top,bottom:n-c.value.bottom,height:n}}),z=e.computed(()=>a.value),x=e.computed(()=>{const l=r.checkNaN(s.dataset.from)<0?Math.abs(r.checkNaN(s.dataset.from)):r.checkNaN(s.dataset.from),n=r.checkNaN(s.dataset.to)<0?Math.abs(r.checkNaN(s.dataset.to)):r.checkNaN(s.dataset.to);let o=0;return r.checkNaN(s.dataset.to)>0?o=l+n:l>n?o=l-n:o=n-l,(1-(Math.abs(r.checkNaN(s.dataset.from))+r.checkNaN(s.dataset.value))/o)*(a.value.height-c.value.top-c.value.bottom)}),L=e.computed(()=>`${x.value}px`),U=e.computed(()=>`${a.value.height-t.value.style.chart.padding.bottom-c.value.top}px`),G=e.computed(()=>`${t.value.style.chart.animation.speedMs}ms`),W=e.computed(()=>{if(s.dataset.colors){if(!s.dataset.colors.from)return p(y.value[0]||r.palette[0],r.convertColorToHex(s.dataset.colors.to),i.value||10);if(!s.dataset.colors.to)return p(r.convertColorToHex(s.dataset.colors.from),y.value[1]||r.palette[1],i.value||10)}else return p(y.value[1]||r.palette[1],y.value[0]||r.palette[0],i.value||10);return p(r.convertColorToHex(s.dataset.colors.from),r.convertColorToHex(s.dataset.colors.to),i.value||10)}),S=e.computed(()=>{const l=[];let n=0;const o=a.value.height-c.value.top-c.value.bottom;for(let u=0;u<o-1;u+=o/i.value)l.push({x:a.value.left,y:a.value.top+u,qYLess:a.value.top+u+o/i.value/4,halfY:a.value.top+u+o/i.value/2,qYMore:a.value.top+u+o/i.value/4*3,color:W.value[n],height:o/i.value}),n+=1;return l}),h=e.ref(!1);function H(l){h.value=l,N.value+=1}return Y({generatePdf:F,generateImage:$}),(l,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"thermoChart",ref:C,class:e.normalizeClass(`vue-ui-thermometer ${h.value?"vue-data-ui-wrapper-fullscreen":""}`),style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};color:${t.value.style.chart.color};font-family:${t.value.style.fontFamily}`),id:`thermometer__${d.value}`},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",Z,[(e.openBlock(),e.createBlock(X._sfc_main,{key:`title_${B.value}`,config:{title:{cy:"thermometer-div-title",...t.value.style.title},subtitle:{cy:"thermometer-div-subtitle",...t.value.style.title.subtitle}}},null,8,["config"]))])):e.createCommentVNode("",!0),t.value.userOptions.show&&f.value?(e.openBlock(),e.createBlock(q.UserOptions,{ref:"details",key:`user_options_${N.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(P),isPrinting:e.unref(V),uid:d.value,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasFullscreen:t.value.userOptions.buttons.fullscreen,hasXls:!1,isFullscreen:h.value,titles:{...t.value.userOptions.buttonTitles},chartElement:C.value,onToggleFullscreen:H,onGeneratePdf:e.unref(F),onGenerateImage:e.unref($)},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:o,isFullscreen:u})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:u})),void 0,!0)]),key:"2"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasFullscreen","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),f.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(r.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":h.value,"vue-data-ui-fulscreen--off":!h.value}),width:"100%",viewBox:`0 0 ${a.value.width} ${a.value.height}`,style:e.normalizeStyle(`background:${t.value.style.chart.backgroundColor}`)},[e.createElementVNode("defs",null,[e.createElementVNode("clipPath",te,[e.createElementVNode("rect",{x:"0",y:"0",width:"1",height:"1",rx:"0.5",ry:"0.07",fill:t.value.style.chart.backgroundColor},null,8,oe)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(o,u)=>(e.openBlock(),e.createElementBlock("linearGradient",{id:`vueUiThermometerGradient_${u}_${d.value}`,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[e.createElementVNode("stop",{offset:"0%","stop-color":o.color},null,8,re),e.createElementVNode("stop",{offset:"50%","stop-color":e.unref(r.setOpacity)(o.color,100-t.value.style.chart.graduations.gradient.intensity)},null,8,ae),e.createElementVNode("stop",{offset:"100%","stop-color":o.color},null,8,se)],8,le))),256))]),e.createElementVNode("g",ne,[e.createElementVNode("rect",{x:a.value.left,y:a.value.top,height:a.value.height-c.value.top-c.value.bottom,width:a.value.width-c.value.left-c.value.right,fill:"#FFFFFF"},null,8,ue),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(o,u)=>(e.openBlock(),e.createElementBlock("g",{key:`graduation_${u}`},[e.createElementVNode("rect",{x:o.x,y:o.y,height:o.height,width:a.value.width-t.value.style.chart.padding.left-t.value.style.chart.padding.right,fill:t.value.style.chart.graduations.gradient.show?`url(#vueUiThermometerGradient_${u}_${d.value})`:o.color,"shape-rendering":"crispEdges"},null,8,ce),t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:0,x1:o.x,x2:o.x+10,y1:o.y,y2:o.y,"stroke-width":t.value.style.chart.graduations.strokeWidth,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,ie)):e.createCommentVNode("",!0),t.value.style.chart.graduations.showIntermediate?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:0,x1:o.x,x2:o.x+5,y1:o.halfY,y2:o.halfY,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,de)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:1,x1:o.x,x2:o.x+2.5,y1:o.qYLess,y2:o.qYLess,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,he)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","left"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:o.x,x2:o.x+2.5,y1:o.qYMore,y2:o.qYMore,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,ve)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:a.value.right,x2:a.value.right-10,y1:o.y,y2:o.y,"stroke-width":t.value.style.chart.graduations.strokeWidth,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,me)):e.createCommentVNode("",!0),t.value.style.chart.graduations.showIntermediate?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:0,x1:a.value.right,x2:a.value.right-5,y1:o.halfY,y2:o.halfY,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,ye)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:1,x1:a.value.right,x2:a.value.right-2.5,y1:o.qYLess,y2:o.qYLess,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,pe)):e.createCommentVNode("",!0),t.value.style.chart.graduations.show&&["both","right"].includes(t.value.style.chart.graduations.sides)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:a.value.right,x2:a.value.right-2.5,y1:o.qYMore,y2:o.qYMore,"stroke-width":t.value.style.chart.graduations.strokeWidth/2,stroke:t.value.style.chart.graduations.stroke,"stroke-linecap":"round"},null,8,fe)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)]))),128)),e.createElementVNode("rect",{class:e.normalizeClass({"vue-ui-thermometer-temperature":t.value.style.chart.animation.use}),x:a.value.left,y:a.value.top,height:x.value,width:a.value.width-t.value.style.chart.padding.left-t.value.style.chart.padding.right,fill:"#FFFFFF66"},null,10,ge)]),e.createElementVNode("text",{class:e.normalizeClass({"vue-ui-thermometer-temperature-value":t.value.style.chart.animation.use}),y:x.value+a.value.top+t.value.style.chart.label.fontSize/3,x:a.value.left-10,"text-anchor":"end",fill:t.value.style.chart.label.color,"font-size":t.value.style.chart.label.fontSize,"font-weight":t.value.style.chart.label.bold?"bold":"normal"},e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.label.formatter,m.dataset.value,e.unref(r.dataLabel)({p:t.value.style.chart.label.prefix,v:m.dataset.value,s:t.value.style.chart.label.suffix,r:t.value.style.chart.label.rounding}),{datapoint:m.dataset})),11,ke),e.renderSlot(l.$slots,"svg",{svg:z.value},void 0,!0)],14,ee)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",xe,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(V)||e.unref(P)})),void 0,!0)])):e.createCommentVNode("",!0),f.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(J.default,{key:4,config:{type:"thermometer",style:{backgroundColor:t.value.style.chart.backgroundColor,thermometer:{color:"#CCCCCC"}}}},null,8,["config"]))],14,Q))}},_e=K._export_sfc(be,[["__scopeId","data-v-5bd662f3"]]);exports.default=_e;
@@ -1,10 +1,10 @@
1
- import { useCssVars as de, computed as c, onMounted as ve, ref as g, watch as ye, openBlock as o, createElementBlock as n, normalizeClass as $, normalizeStyle as H, createBlock as U, createCommentVNode as h, unref as v, createSlots as fe, withCtx as q, renderSlot as x, normalizeProps as X, guardReactiveProps as R, createElementVNode as d, Fragment as F, renderList as J, toDisplayString as ge } from "vue";
2
- import { u as me, o as pe, e as K, g as ke, c as xe, t as _e, a as be, p as _, b as we, s as f, d as P, X as Ce, w as $e, i as Fe, f as Pe } from "./index-CaV1s-yZ.js";
3
- import { _ as Ie } from "./Title-gUz6GDA3.js";
4
- import { u as Ye, U as Me } from "./usePrinter-rvJyT65A.js";
5
- import Ne from "./vue-ui-skeleton-CvFX_ExX.js";
6
- import { u as Q } from "./useNestedProp-tWCzZrLx.js";
7
- import { _ as Oe } from "./_plugin-vue_export-helper-CHgC5LLL.js";
1
+ import { useCssVars as de, computed as h, onMounted as ve, ref as g, watch as ye, openBlock as o, createElementBlock as n, normalizeClass as $, normalizeStyle as H, createBlock as U, createCommentVNode as c, unref as v, createSlots as fe, withCtx as q, renderSlot as x, normalizeProps as X, guardReactiveProps as R, createElementVNode as d, Fragment as F, renderList as J, toDisplayString as ge } from "vue";
2
+ import { u as me, o as pe, e as K, g as ke, c as xe, t as _e, a as be, p as _, b as we, v as f, d as P, X as Ce, s as $e, i as Fe, f as Pe } from "./index-0KN57HdM.js";
3
+ import { _ as Ie } from "./Title-gvR5aS6q.js";
4
+ import { u as Ye, U as Me } from "./usePrinter-BvKYEc1z.js";
5
+ import Oe from "./vue-ui-skeleton-dgMXr8k9.js";
6
+ import { u as Q } from "./useNestedProp-NeGalTYk.js";
7
+ import { _ as Ne } from "./_plugin-vue_export-helper-CHgC5LLL.js";
8
8
  const Se = ["id"], Ue = {
9
9
  key: 0,
10
10
  style: "width:100%"
@@ -33,11 +33,11 @@ const Se = ["id"], Ue = {
33
33
  setup(b, { expose: Z }) {
34
34
  const a = b;
35
35
  de((s) => ({
36
- "0a35d02c": oe.value,
37
- "2925bde2": ae.value,
38
- "636d634f": le.value
36
+ "5d70f0a2": oe.value,
37
+ "3d4eac2c": ae.value,
38
+ "8e9d47ce": le.value
39
39
  }));
40
- const { vue_ui_thermometer: ee } = me(), I = c(() => !!a.dataset && Object.keys(a.dataset).length);
40
+ const { vue_ui_thermometer: ee } = me(), I = h(() => !!a.dataset && Object.keys(a.dataset).length);
41
41
  ve(() => {
42
42
  L();
43
43
  });
@@ -56,7 +56,7 @@ const Se = ["id"], Ue = {
56
56
  });
57
57
  });
58
58
  }
59
- const m = g(xe()), T = g(null), G = g(0), W = g(0), e = c({
59
+ const m = g(xe()), T = g(null), G = g(0), W = g(0), e = h({
60
60
  get: () => E(),
61
61
  set: (s) => s
62
62
  });
@@ -79,17 +79,17 @@ const Se = ["id"], Ue = {
79
79
  const { isPrinting: V, isImaging: z, generatePdf: B, generateImage: j } = Ye({
80
80
  elementId: `thermometer__${m.value}`,
81
81
  fileName: e.value.style.title.text || "vue-ui-thermometer"
82
- }), w = c(() => we(e.value.customPalette)), te = c(() => e.value.style.chart.thermometer.width), y = c(() => a.dataset.steps || 10), i = g({
82
+ }), w = h(() => we(e.value.customPalette)), te = h(() => e.value.style.chart.thermometer.width), y = h(() => a.dataset.steps || 10), i = g({
83
83
  top: e.value.style.chart.padding.top,
84
84
  left: e.value.style.chart.padding.left,
85
85
  right: e.value.style.chart.padding.right,
86
86
  bottom: e.value.style.chart.padding.bottom
87
87
  });
88
88
  function C(s, r, t) {
89
- const u = [], O = A(s), S = A(r);
89
+ const u = [], N = A(s), S = A(r);
90
90
  for (let k = 0; k < t; k++) {
91
- const ne = Y(O.red, S.red, k, t), ie = Y(O.green, S.green, k, t), he = Y(O.blue, S.blue, k, t), ce = `#${M(ne)}${M(ie)}${M(he)}`;
92
- u.push(ce);
91
+ const ne = Y(N.red, S.red, k, t), ie = Y(N.green, S.green, k, t), ce = Y(N.blue, S.blue, k, t), he = `#${M(ne)}${M(ie)}${M(ce)}`;
92
+ u.push(he);
93
93
  }
94
94
  return u;
95
95
  }
@@ -107,7 +107,7 @@ const Se = ["id"], Ue = {
107
107
  function M(s) {
108
108
  return s.toString(16).padStart(2, "0");
109
109
  }
110
- const l = c(() => {
110
+ const l = h(() => {
111
111
  const s = te.value + i.value.left + i.value.right, r = e.value.style.chart.height;
112
112
  return {
113
113
  width: s,
@@ -117,11 +117,11 @@ const Se = ["id"], Ue = {
117
117
  bottom: r - i.value.bottom,
118
118
  height: r
119
119
  };
120
- }), se = c(() => l.value), N = c(() => {
120
+ }), se = h(() => l.value), O = h(() => {
121
121
  const s = f(a.dataset.from) < 0 ? Math.abs(f(a.dataset.from)) : f(a.dataset.from), r = f(a.dataset.to) < 0 ? Math.abs(f(a.dataset.to)) : f(a.dataset.to);
122
122
  let t = 0;
123
123
  return f(a.dataset.to) > 0 ? t = s + r : s > r ? t = s - r : t = r - s, (1 - (Math.abs(f(a.dataset.from)) + f(a.dataset.value)) / t) * (l.value.height - i.value.top - i.value.bottom);
124
- }), le = c(() => `${N.value}px`), ae = c(() => `${l.value.height - e.value.style.chart.padding.bottom - i.value.top}px`), oe = c(() => `${e.value.style.chart.animation.speedMs}ms`), re = c(() => {
124
+ }), le = h(() => `${O.value}px`), ae = h(() => `${l.value.height - e.value.style.chart.padding.bottom - i.value.top}px`), oe = h(() => `${e.value.style.chart.animation.speedMs}ms`), re = h(() => {
125
125
  if (a.dataset.colors) {
126
126
  if (!a.dataset.colors.from)
127
127
  return C(w.value[0] || _[0], P(a.dataset.colors.to), y.value || 10);
@@ -130,7 +130,7 @@ const Se = ["id"], Ue = {
130
130
  } else
131
131
  return C(w.value[1] || _[1], w.value[0] || _[0], y.value || 10);
132
132
  return C(P(a.dataset.colors.from), P(a.dataset.colors.to), y.value || 10);
133
- }), D = c(() => {
133
+ }), D = h(() => {
134
134
  const s = [];
135
135
  let r = 0;
136
136
  const t = l.value.height - i.value.top - i.value.bottom;
@@ -173,7 +173,7 @@ const Se = ["id"], Ue = {
173
173
  }
174
174
  }
175
175
  }, null, 8, ["config"]))
176
- ])) : h("", !0),
176
+ ])) : c("", !0),
177
177
  e.value.userOptions.show && I.value ? (o(), U(Me, {
178
178
  ref: "details",
179
179
  key: `user_options_${G.value}`,
@@ -214,7 +214,7 @@ const Se = ["id"], Ue = {
214
214
  ]),
215
215
  key: "2"
216
216
  } : void 0
217
- ]), 1032, ["backgroundColor", "color", "isImaging", "isPrinting", "uid", "hasPdf", "hasImg", "hasFullscreen", "isFullscreen", "titles", "chartElement", "onGeneratePdf", "onGenerateImage"])) : h("", !0),
217
+ ]), 1032, ["backgroundColor", "color", "isImaging", "isPrinting", "uid", "hasPdf", "hasImg", "hasFullscreen", "isFullscreen", "titles", "chartElement", "onGeneratePdf", "onGenerateImage"])) : c("", !0),
218
218
  I.value ? (o(), n("svg", {
219
219
  key: 2,
220
220
  xmlns: v(Ce),
@@ -248,7 +248,7 @@ const Se = ["id"], Ue = {
248
248
  }, null, 8, We),
249
249
  d("stop", {
250
250
  offset: "50%",
251
- "stop-color": `${t.color}${v($e)[100 - e.value.style.chart.graduations.gradient.intensity]}`
251
+ "stop-color": v($e)(t.color, 100 - e.value.style.chart.graduations.gradient.intensity)
252
252
  }, null, 8, Ee),
253
253
  d("stop", {
254
254
  offset: "100%",
@@ -284,7 +284,7 @@ const Se = ["id"], Ue = {
284
284
  "stroke-width": e.value.style.chart.graduations.strokeWidth,
285
285
  stroke: e.value.style.chart.graduations.stroke,
286
286
  "stroke-linecap": "round"
287
- }, null, 8, Ae)) : h("", !0),
287
+ }, null, 8, Ae)) : c("", !0),
288
288
  e.value.style.chart.graduations.showIntermediate ? (o(), n(F, { key: 1 }, [
289
289
  e.value.style.chart.graduations.show && ["both", "left"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
290
290
  key: 0,
@@ -295,7 +295,7 @@ const Se = ["id"], Ue = {
295
295
  "stroke-width": e.value.style.chart.graduations.strokeWidth / 2,
296
296
  stroke: e.value.style.chart.graduations.stroke,
297
297
  "stroke-linecap": "round"
298
- }, null, 8, De)) : h("", !0),
298
+ }, null, 8, De)) : c("", !0),
299
299
  e.value.style.chart.graduations.show && ["both", "left"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
300
300
  key: 1,
301
301
  x1: t.x,
@@ -305,7 +305,7 @@ const Se = ["id"], Ue = {
305
305
  "stroke-width": e.value.style.chart.graduations.strokeWidth / 2,
306
306
  stroke: e.value.style.chart.graduations.stroke,
307
307
  "stroke-linecap": "round"
308
- }, null, 8, He)) : h("", !0),
308
+ }, null, 8, He)) : c("", !0),
309
309
  e.value.style.chart.graduations.show && ["both", "left"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
310
310
  key: 2,
311
311
  x1: t.x,
@@ -315,8 +315,8 @@ const Se = ["id"], Ue = {
315
315
  "stroke-width": e.value.style.chart.graduations.strokeWidth / 2,
316
316
  stroke: e.value.style.chart.graduations.stroke,
317
317
  "stroke-linecap": "round"
318
- }, null, 8, Xe)) : h("", !0)
319
- ], 64)) : h("", !0),
318
+ }, null, 8, Xe)) : c("", !0)
319
+ ], 64)) : c("", !0),
320
320
  e.value.style.chart.graduations.show && ["both", "right"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
321
321
  key: 2,
322
322
  x1: l.value.right,
@@ -326,7 +326,7 @@ const Se = ["id"], Ue = {
326
326
  "stroke-width": e.value.style.chart.graduations.strokeWidth,
327
327
  stroke: e.value.style.chart.graduations.stroke,
328
328
  "stroke-linecap": "round"
329
- }, null, 8, Re)) : h("", !0),
329
+ }, null, 8, Re)) : c("", !0),
330
330
  e.value.style.chart.graduations.showIntermediate ? (o(), n(F, { key: 3 }, [
331
331
  e.value.style.chart.graduations.show && ["both", "right"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
332
332
  key: 0,
@@ -337,7 +337,7 @@ const Se = ["id"], Ue = {
337
337
  "stroke-width": e.value.style.chart.graduations.strokeWidth / 2,
338
338
  stroke: e.value.style.chart.graduations.stroke,
339
339
  "stroke-linecap": "round"
340
- }, null, 8, Je)) : h("", !0),
340
+ }, null, 8, Je)) : c("", !0),
341
341
  e.value.style.chart.graduations.show && ["both", "right"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
342
342
  key: 1,
343
343
  x1: l.value.right,
@@ -347,7 +347,7 @@ const Se = ["id"], Ue = {
347
347
  "stroke-width": e.value.style.chart.graduations.strokeWidth / 2,
348
348
  stroke: e.value.style.chart.graduations.stroke,
349
349
  "stroke-linecap": "round"
350
- }, null, 8, Ke)) : h("", !0),
350
+ }, null, 8, Ke)) : c("", !0),
351
351
  e.value.style.chart.graduations.show && ["both", "right"].includes(e.value.style.chart.graduations.sides) ? (o(), n("line", {
352
352
  key: 2,
353
353
  x1: l.value.right,
@@ -357,21 +357,21 @@ const Se = ["id"], Ue = {
357
357
  "stroke-width": e.value.style.chart.graduations.strokeWidth / 2,
358
358
  stroke: e.value.style.chart.graduations.stroke,
359
359
  "stroke-linecap": "round"
360
- }, null, 8, Qe)) : h("", !0)
361
- ], 64)) : h("", !0)
360
+ }, null, 8, Qe)) : c("", !0)
361
+ ], 64)) : c("", !0)
362
362
  ]))), 128)),
363
363
  d("rect", {
364
364
  class: $({ "vue-ui-thermometer-temperature": e.value.style.chart.animation.use }),
365
365
  x: l.value.left,
366
366
  y: l.value.top,
367
- height: N.value,
367
+ height: O.value,
368
368
  width: l.value.width - e.value.style.chart.padding.left - e.value.style.chart.padding.right,
369
369
  fill: "#FFFFFF66"
370
370
  }, null, 10, Ze)
371
371
  ]),
372
372
  d("text", {
373
373
  class: $({ "vue-ui-thermometer-temperature-value": e.value.style.chart.animation.use }),
374
- y: N.value + l.value.top + e.value.style.chart.label.fontSize / 3,
374
+ y: O.value + l.value.top + e.value.style.chart.label.fontSize / 3,
375
375
  x: l.value.left - 10,
376
376
  "text-anchor": "end",
377
377
  fill: e.value.style.chart.label.color,
@@ -389,11 +389,11 @@ const Se = ["id"], Ue = {
389
389
  { datapoint: b.dataset }
390
390
  )), 11, et),
391
391
  x(s.$slots, "svg", { svg: se.value }, void 0, !0)
392
- ], 14, qe)) : h("", !0),
392
+ ], 14, qe)) : c("", !0),
393
393
  s.$slots.watermark ? (o(), n("div", tt, [
394
394
  x(s.$slots, "watermark", X(R({ isPrinting: v(V) || v(z) })), void 0, !0)
395
- ])) : h("", !0),
396
- I.value ? h("", !0) : (o(), U(Ne, {
395
+ ])) : c("", !0),
396
+ I.value ? c("", !0) : (o(), U(Oe, {
397
397
  key: 4,
398
398
  config: {
399
399
  type: "thermometer",
@@ -407,7 +407,7 @@ const Se = ["id"], Ue = {
407
407
  }, null, 8, ["config"]))
408
408
  ], 14, Se));
409
409
  }
410
- }, ht = /* @__PURE__ */ Oe(st, [["__scopeId", "data-v-900932c6"]]);
410
+ }, ct = /* @__PURE__ */ Ne(st, [["__scopeId", "data-v-5bd662f3"]]);
411
411
  export {
412
- ht as default
412
+ ct as default
413
413
  };
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),L=require("./useNestedProp-CisbRRo_.cjs"),g=require("./index-BTgtr0F8.cjs"),$=require("./useResponsive-B3TrDDIG.cjs"),B=require("./BaseIcon-DB7Apwv_.cjs"),j=require("./Title-3EduyW4p.cjs"),O=require("./_plugin-vue_export-helper-BHFhmbuH.cjs");class q{constructor(P,v,y,E=!0,b=!0){this.interval=v,this.elapsed=0,this.isPaused=!1;const S=`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),L=require("./useNestedProp-CoLyVvV9.cjs"),g=require("./index-TabZg_HV.cjs"),$=require("./useResponsive-B3TrDDIG.cjs"),B=require("./BaseIcon-CP535rdy.cjs"),j=require("./Title-D9lSjLTg.cjs"),O=require("./_plugin-vue_export-helper-BHFhmbuH.cjs");class q{constructor(P,v,y,E=!0,b=!0){this.interval=v,this.elapsed=0,this.isPaused=!1;const S=`
2
2
  let interval;
3
3
  let elapsed = 0;
4
4
  let paused = false;
@@ -1,9 +1,9 @@
1
- import { ref as n, onMounted as Q, onBeforeUnmount as Y, computed as z, watch as Z, openBlock as l, createElementBlock as r, normalizeStyle as f, createBlock as ee, createCommentVNode as v, unref as te, createElementVNode as M, mergeProps as V, renderSlot as O, normalizeProps as U, guardReactiveProps as E, toDisplayString as ae, createVNode as $ } from "vue";
2
- import { u as se } from "./useNestedProp-tWCzZrLx.js";
3
- import { u as le, c as oe, X as re, D as W } from "./index-CaV1s-yZ.js";
1
+ import { ref as n, onMounted as Q, onBeforeUnmount as Y, computed as z, watch as Z, openBlock as l, createElementBlock as r, normalizeStyle as f, createBlock as ee, createCommentVNode as v, unref as te, createElementVNode as M, mergeProps as V, renderSlot as E, normalizeProps as O, guardReactiveProps as U, toDisplayString as ae, createVNode as $ } from "vue";
2
+ import { u as se } from "./useNestedProp-NeGalTYk.js";
3
+ import { u as le, c as oe, X as re, E as W } from "./index-0KN57HdM.js";
4
4
  import { t as ue, u as ie } from "./useResponsive-NZB-WLRF.js";
5
- import P from "./BaseIcon-rwm-10Hu.js";
6
- import { _ as ne } from "./Title-gUz6GDA3.js";
5
+ import P from "./BaseIcon-Cbr8np30.js";
6
+ import { _ as ne } from "./Title-gvR5aS6q.js";
7
7
  import { _ as ce } from "./_plugin-vue_export-helper-CHgC5LLL.js";
8
8
  class de {
9
9
  constructor(A, k, C, H = !0, T = !0) {
@@ -347,7 +347,7 @@ const he = ["xmlns", "viewBox"], ve = { key: 0 }, pe = ["id"], fe = ["stop-color
347
347
  width: "0.1",
348
348
  style: { overflow: "visible" }
349
349
  }, [
350
- O(a.$slots, "time", U(E({ ...d.value })), void 0, !0)
350
+ E(a.$slots, "time", O(U({ ...d.value })), void 0, !0)
351
351
  ], 8, be)) : (l(), r("text", {
352
352
  key: 4,
353
353
  x: t.value.width / 2,
@@ -441,7 +441,7 @@ const he = ["xmlns", "viewBox"], ve = { key: 0 }, pe = ["id"], fe = ["stop-color
441
441
  }, null, 8, ["stroke"])
442
442
  ], 12, $e)) : v("", !0)
443
443
  ])),
444
- O(a.$slots, "controls", U(E({
444
+ E(a.$slots, "controls", O(U({
445
445
  start: L,
446
446
  pause: B,
447
447
  reset: N,
@@ -452,7 +452,7 @@ const he = ["xmlns", "viewBox"], ve = { key: 0 }, pe = ["id"], fe = ["stop-color
452
452
  isPaused: p.value,
453
453
  ...d.value
454
454
  })), void 0, !0),
455
- O(a.$slots, "laps", U(E({
455
+ E(a.$slots, "laps", O(U({
456
456
  laps: b.value,
457
457
  lap: F,
458
458
  isRunning: s.value,