vue-data-ui 2.3.55 → 2.3.57

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 (147) hide show
  1. package/dist/{Arrow-CD86_mVa.cjs → Arrow-DzUipdZc.cjs} +1 -1
  2. package/dist/{Arrow-j_jJLrPl.js → Arrow-ycy3_Slf.js} +1 -1
  3. package/dist/{BaseIcon-CcjRNNRk.cjs → BaseIcon-BkQhR5to.cjs} +1 -1
  4. package/dist/{BaseIcon-C_LL9N2v.js → BaseIcon-DuWxvGrs.js} +1 -1
  5. package/dist/{DataTable-CLSUMM1T.cjs → DataTable-BRux41DB.cjs} +1 -1
  6. package/dist/{DataTable-DtweC2aX.js → DataTable-Cp8-9z9I.js} +2 -2
  7. package/dist/{Legend-DH7m-lj4.cjs → Legend-Bkl0mNRU.cjs} +1 -1
  8. package/dist/{Legend-Devie0wc.js → Legend-Dxg4fgms.js} +1 -1
  9. package/dist/{Shape-BKiHavCD.js → Shape-9atoPZLR.js} +1 -1
  10. package/dist/{Shape-DycB5ypz.cjs → Shape-BqcaWTo1.cjs} +1 -1
  11. package/dist/Slicer-DJ_rlsfN.cjs +1 -0
  12. package/dist/Slicer-DWXMDMkg.js +328 -0
  13. package/dist/{Title-BiRQNRBF.js → Title-Bft_Qodf.js} +1 -1
  14. package/dist/{Title-BMtEHCuW.cjs → Title-JorKJ3kW.cjs} +1 -1
  15. package/dist/{Tooltip-hQEVvasg.js → Tooltip-DsJ_DDEa.js} +1 -1
  16. package/dist/{Tooltip-BVKVDhCS.cjs → Tooltip-DuhcODsb.cjs} +1 -1
  17. package/dist/{index-eNesjhZj.js → index-ByARe6xk.js} +3 -2
  18. package/dist/index-vvhNQFio.cjs +4 -0
  19. package/dist/style.css +1 -1
  20. package/dist/types/vue-data-ui.d.cts +1 -0
  21. package/dist/types/vue-data-ui.d.ts +1 -0
  22. package/dist/{useNestedProp-DSlX2vrv.cjs → useNestedProp-BUoCZrmY.cjs} +1 -1
  23. package/dist/{useNestedProp-DNCWRjjz.js → useNestedProp-DcnyJpjm.js} +1 -1
  24. package/dist/{usePrinter-DaXfYVdD.js → usePrinter-BUBRC6GE.js} +1 -1
  25. package/dist/{usePrinter-BVn9S-ka.cjs → usePrinter-D5ewpTd3.cjs} +1 -1
  26. package/dist/{vue-data-ui--p36x8k7.js → vue-data-ui-67aBhtaH.js} +57 -57
  27. package/dist/{vue-data-ui-BYBOgoKC.cjs → vue-data-ui-BzsqnKj2.cjs} +1 -1
  28. package/dist/vue-data-ui.cjs +1 -1
  29. package/dist/vue-data-ui.js +1 -1
  30. package/dist/{vue-ui-3d-bar-BeggJQ0W.js → vue-ui-3d-bar-CQ656C3D.js} +7 -7
  31. package/dist/{vue-ui-3d-bar-B5e8tv2X.cjs → vue-ui-3d-bar-NcBKcawL.cjs} +1 -1
  32. package/dist/{vue-ui-accordion-VlrY4-LO.js → vue-ui-accordion-B7sGXK-8.js} +3 -3
  33. package/dist/{vue-ui-accordion-CdmnbFHu.cjs → vue-ui-accordion-CSnFq9e7.cjs} +1 -1
  34. package/dist/{vue-ui-age-pyramid-DcbWuta0.cjs → vue-ui-age-pyramid-B8KDJTmK.cjs} +1 -1
  35. package/dist/{vue-ui-age-pyramid-CThQ5oD4.js → vue-ui-age-pyramid-DcN9DXL7.js} +8 -8
  36. package/dist/{vue-ui-annotator-BGVVVERK.cjs → vue-ui-annotator-BcKsg71t.cjs} +1 -1
  37. package/dist/{vue-ui-annotator-gGB1f-3H.js → vue-ui-annotator-DINvjGdW.js} +1 -1
  38. package/dist/{vue-ui-candlestick-CxG51AUA.cjs → vue-ui-candlestick-DokpJUMI.cjs} +1 -1
  39. package/dist/{vue-ui-candlestick-CURxw_2F.js → vue-ui-candlestick-dE7VZ9c2.js} +9 -9
  40. package/dist/{vue-ui-carousel-table-GvzEfAj-.cjs → vue-ui-carousel-table-CfkAq3aZ.cjs} +1 -1
  41. package/dist/{vue-ui-carousel-table-DtVbpA4F.js → vue-ui-carousel-table-CyvXkNVJ.js} +4 -4
  42. package/dist/{vue-ui-chestnut-B53QBPHa.js → vue-ui-chestnut-BtbUx2K6.js} +6 -6
  43. package/dist/{vue-ui-chestnut-CxbMdgbi.cjs → vue-ui-chestnut-C7UoeDnX.cjs} +1 -1
  44. package/dist/{vue-ui-cursor-CFRx7l4I.cjs → vue-ui-cursor-CdZf-yX5.cjs} +1 -1
  45. package/dist/{vue-ui-cursor-0KF83snm.js → vue-ui-cursor-a04KGiW0.js} +2 -2
  46. package/dist/{vue-ui-dashboard-BTFd6IHn.cjs → vue-ui-dashboard-BVfWXpf8.cjs} +1 -1
  47. package/dist/{vue-ui-dashboard-BFhtmTsR.js → vue-ui-dashboard-C16uiqyH.js} +2 -2
  48. package/dist/{vue-ui-digits-CEAhosYg.cjs → vue-ui-digits-Ct2vS1BN.cjs} +1 -1
  49. package/dist/{vue-ui-digits-CUHy2QNQ.js → vue-ui-digits-DrK1MsGL.js} +2 -2
  50. package/dist/{vue-ui-donut-D9F8gKom.cjs → vue-ui-donut-DCw94nm5.cjs} +1 -1
  51. package/dist/{vue-ui-donut-evolution-CE1SJTOj.js → vue-ui-donut-evolution-ci4AbPDx.js} +9 -9
  52. package/dist/{vue-ui-donut-evolution-BiV5pBw6.cjs → vue-ui-donut-evolution-w2VBVy8J.cjs} +1 -1
  53. package/dist/{vue-ui-donut-C2Vuv-vU.js → vue-ui-donut-gBfPKxL5.js} +9 -9
  54. package/dist/{vue-ui-dumbbell-DhaGVvA5.js → vue-ui-dumbbell-CfRDGglI.js} +8 -8
  55. package/dist/{vue-ui-dumbbell-BH4UGMbP.cjs → vue-ui-dumbbell-DSeY7g70.cjs} +1 -1
  56. package/dist/{vue-ui-flow-D676Q8fC.cjs → vue-ui-flow-CCRXuD2w.cjs} +1 -1
  57. package/dist/{vue-ui-flow-DAicoErr.js → vue-ui-flow-sxRGOd3v.js} +7 -7
  58. package/dist/{vue-ui-galaxy-Br5PK1te.cjs → vue-ui-galaxy-7uOmICFQ.cjs} +1 -1
  59. package/dist/{vue-ui-galaxy-D32lxS42.js → vue-ui-galaxy-BtRwEK-N.js} +9 -9
  60. package/dist/{vue-ui-gauge-Dp_zTgAO.cjs → vue-ui-gauge-CcGerm6-.cjs} +1 -1
  61. package/dist/{vue-ui-gauge-B1hyvKU2.js → vue-ui-gauge-DF5cMUZq.js} +5 -5
  62. package/dist/{vue-ui-gizmo-DmKQDIfq.js → vue-ui-gizmo-BxSR6Npw.js} +2 -2
  63. package/dist/{vue-ui-gizmo-CJwEKsok.cjs → vue-ui-gizmo-DOdbL7oJ.cjs} +1 -1
  64. package/dist/{vue-ui-heatmap-CNvG1HAM.js → vue-ui-heatmap-BFebVyoq.js} +8 -8
  65. package/dist/{vue-ui-heatmap-sRauIpaW.cjs → vue-ui-heatmap-bCvQEgv4.cjs} +1 -1
  66. package/dist/{vue-ui-kpi-DBYcY_R-.cjs → vue-ui-kpi-Bh3EQVzo.cjs} +1 -1
  67. package/dist/{vue-ui-kpi-MOnNvoBO.js → vue-ui-kpi-kz6LxY4z.js} +3 -3
  68. package/dist/{vue-ui-mini-loader-DUYTaVw7.cjs → vue-ui-mini-loader-BUmmuBm2.cjs} +1 -1
  69. package/dist/{vue-ui-mini-loader-Bn7YWlkS.js → vue-ui-mini-loader-XvpXZ4Lu.js} +2 -2
  70. package/dist/{vue-ui-molecule-vwyKHWGg.js → vue-ui-molecule-CV9jYVPn.js} +9 -9
  71. package/dist/{vue-ui-molecule-BGQM0K4M.cjs → vue-ui-molecule-DAqPp6P1.cjs} +1 -1
  72. package/dist/{vue-ui-mood-radar-BdIaEaVr.js → vue-ui-mood-radar-BXksXL9W.js} +9 -9
  73. package/dist/{vue-ui-mood-radar-DaeMz9Us.cjs → vue-ui-mood-radar-Rpgf2fO4.cjs} +1 -1
  74. package/dist/{vue-ui-nested-donuts-BtU-8L6A.cjs → vue-ui-nested-donuts-Bi9o-a5M.cjs} +1 -1
  75. package/dist/{vue-ui-nested-donuts-D1iRNyTz.js → vue-ui-nested-donuts-DP44vR6_.js} +9 -9
  76. package/dist/{vue-ui-onion-DmqDceEH.cjs → vue-ui-onion-BdQtE7OR.cjs} +1 -1
  77. package/dist/{vue-ui-onion-CUnrIzkf.js → vue-ui-onion-C-hnaK6-.js} +9 -9
  78. package/dist/{vue-ui-parallel-coordinate-plot-DvElubUh.js → vue-ui-parallel-coordinate-plot-CRfWMtfW.js} +10 -10
  79. package/dist/{vue-ui-parallel-coordinate-plot-Cvrg8_if.cjs → vue-ui-parallel-coordinate-plot-Cl7HwAhr.cjs} +1 -1
  80. package/dist/{vue-ui-quadrant-D07nnoMo.cjs → vue-ui-quadrant-2jWkCnCZ.cjs} +1 -1
  81. package/dist/{vue-ui-quadrant-BMdmAU9p.js → vue-ui-quadrant-BvmZuTNr.js} +10 -10
  82. package/dist/vue-ui-quick-chart-Cf2bonoP.js +1396 -0
  83. package/dist/vue-ui-quick-chart-Dljdowyo.cjs +15 -0
  84. package/dist/{vue-ui-radar-CUoik8yo.js → vue-ui-radar-D8WUIeAJ.js} +10 -10
  85. package/dist/{vue-ui-radar-CbAWxhkp.cjs → vue-ui-radar-DWQT59Y3.cjs} +1 -1
  86. package/dist/{vue-ui-rating-DN441TfA.cjs → vue-ui-rating-C6EdVOFi.cjs} +1 -1
  87. package/dist/{vue-ui-rating-B8Hi4txH.js → vue-ui-rating-DA5yVA82.js} +2 -2
  88. package/dist/{vue-ui-relation-circle-IbwhL6lE.cjs → vue-ui-relation-circle-D1Dfp3vd.cjs} +1 -1
  89. package/dist/{vue-ui-relation-circle-Cda40p-y.js → vue-ui-relation-circle-D1HV7sEy.js} +5 -5
  90. package/dist/{vue-ui-rings-HiXpboul.js → vue-ui-rings-9KX262V6.js} +9 -9
  91. package/dist/{vue-ui-rings-CQS3OVzz.cjs → vue-ui-rings-D7ZSknfw.cjs} +1 -1
  92. package/dist/{vue-ui-scatter-5nZwBAqv.js → vue-ui-scatter-BS4fuY2e.js} +10 -10
  93. package/dist/{vue-ui-scatter-B08HrPfk.cjs → vue-ui-scatter-BkE4TBcf.cjs} +1 -1
  94. package/dist/{vue-ui-screenshot-_NCDixjk.cjs → vue-ui-screenshot-BNsuh29D.cjs} +1 -1
  95. package/dist/{vue-ui-screenshot-DHnJwDbF.js → vue-ui-screenshot-ChhpX9vN.js} +1 -1
  96. package/dist/{vue-ui-skeleton-Byeyr5yc.js → vue-ui-skeleton-C2W5etGt.js} +2 -2
  97. package/dist/{vue-ui-skeleton-CJFwlN1Y.cjs → vue-ui-skeleton-H7E3SBMd.cjs} +1 -1
  98. package/dist/{vue-ui-smiley-hLP0hcpu.cjs → vue-ui-smiley-CSVsepz-.cjs} +1 -1
  99. package/dist/{vue-ui-smiley-s1fmwFhU.js → vue-ui-smiley-DmvbdKQH.js} +2 -2
  100. package/dist/{vue-ui-spark-trend-CZGRub2F.cjs → vue-ui-spark-trend-B_jzBm-L.cjs} +1 -1
  101. package/dist/{vue-ui-spark-trend-Bud2AN77.js → vue-ui-spark-trend-CIRMNMBi.js} +4 -4
  102. package/dist/{vue-ui-sparkbar-ALMWp788.cjs → vue-ui-sparkbar-Bc0UGC0I.cjs} +1 -1
  103. package/dist/{vue-ui-sparkbar-D9wohnoj.js → vue-ui-sparkbar-CsPU3f7E.js} +3 -3
  104. package/dist/{vue-ui-sparkgauge-jwr_cm8h.cjs → vue-ui-sparkgauge-B9Z7UC0c.cjs} +1 -1
  105. package/dist/{vue-ui-sparkgauge-kT8RG3yQ.js → vue-ui-sparkgauge-sf5NkOzU.js} +3 -3
  106. package/dist/{vue-ui-sparkhistogram-nOduxo5t.cjs → vue-ui-sparkhistogram-BcbNk4hY.cjs} +1 -1
  107. package/dist/{vue-ui-sparkhistogram-DrILTu0Q.js → vue-ui-sparkhistogram-C9q2fgqW.js} +4 -4
  108. package/dist/{vue-ui-sparkline-DzS4gqIh.js → vue-ui-sparkline-BW3H6hsT.js} +3 -3
  109. package/dist/{vue-ui-sparkline-CoTk45lg.cjs → vue-ui-sparkline-Cc-z4lug.cjs} +1 -1
  110. package/dist/{vue-ui-sparkstackbar-BtKp_Dfa.cjs → vue-ui-sparkstackbar-DRUOzvw_.cjs} +1 -1
  111. package/dist/{vue-ui-sparkstackbar-C4jS4TNR.js → vue-ui-sparkstackbar-DtdKmv0C.js} +3 -3
  112. package/dist/{vue-ui-stackbar-ucQWROqo.js → vue-ui-stackbar-C3hiDzB9.js} +10 -10
  113. package/dist/{vue-ui-stackbar-CIQZW-0L.cjs → vue-ui-stackbar-CJSxzmsC.cjs} +1 -1
  114. package/dist/{vue-ui-strip-plot-brWREfBk.js → vue-ui-strip-plot-D6RdcG4r.js} +9 -9
  115. package/dist/{vue-ui-strip-plot-0uVl0VSh.cjs → vue-ui-strip-plot-Dea20UQo.cjs} +1 -1
  116. package/dist/{vue-ui-table-77C-7fRv.js → vue-ui-table-Cl83ltew.js} +1 -1
  117. package/dist/{vue-ui-table-BB88mYgD.cjs → vue-ui-table-DThpCd--.cjs} +1 -1
  118. package/dist/{vue-ui-table-heatmap-xq1pGUbR.cjs → vue-ui-table-heatmap-C9znKJA2.cjs} +1 -1
  119. package/dist/{vue-ui-table-heatmap--E-YEtYc.js → vue-ui-table-heatmap-P1qoQg4L.js} +4 -4
  120. package/dist/{vue-ui-table-sparkline-DzCQFe4i.cjs → vue-ui-table-sparkline-B56XlhbD.cjs} +1 -1
  121. package/dist/{vue-ui-table-sparkline-CcBcClIO.js → vue-ui-table-sparkline-ByBzCnhr.js} +5 -5
  122. package/dist/{vue-ui-thermometer-BccFBxQh.js → vue-ui-thermometer-CEtqGDhU.js} +5 -5
  123. package/dist/{vue-ui-thermometer-2NqZXrMO.cjs → vue-ui-thermometer-D1BIwe-x.cjs} +1 -1
  124. package/dist/{vue-ui-timer-WKdFohnS.cjs → vue-ui-timer-CZv_iq9A.cjs} +1 -1
  125. package/dist/{vue-ui-timer-BAAmZQJp.js → vue-ui-timer-_OXWxSrR.js} +4 -4
  126. package/dist/{vue-ui-tiremarks-C9E5yMJN.cjs → vue-ui-tiremarks-Crjj6lAQ.cjs} +1 -1
  127. package/dist/{vue-ui-tiremarks-CwweiaMR.js → vue-ui-tiremarks-Vln9izs8.js} +5 -5
  128. package/dist/{vue-ui-treemap-DjnaMe13.js → vue-ui-treemap-CVSmQvg5.js} +9 -9
  129. package/dist/{vue-ui-treemap-D2GptOs9.cjs → vue-ui-treemap-CvZ_PXHg.cjs} +1 -1
  130. package/dist/{vue-ui-vertical-bar-D_HjUjJ7.cjs → vue-ui-vertical-bar-B6gMyH90.cjs} +1 -1
  131. package/dist/{vue-ui-vertical-bar-S-6ipP_C.js → vue-ui-vertical-bar-DW83JGF2.js} +9 -9
  132. package/dist/{vue-ui-waffle-HGO5Kh1L.js → vue-ui-waffle-C9SFbGDx.js} +9 -9
  133. package/dist/{vue-ui-waffle-s8wpAnH2.cjs → vue-ui-waffle-Ck6_fLgH.cjs} +1 -1
  134. package/dist/{vue-ui-wheel-BHUcVCX2.js → vue-ui-wheel-DaA4af-u.js} +5 -5
  135. package/dist/{vue-ui-wheel-DChpCFum.cjs → vue-ui-wheel-DvxUmFh9.cjs} +1 -1
  136. package/dist/{vue-ui-word-cloud-BFqRbPvp.cjs → vue-ui-word-cloud-B_3r5g7T.cjs} +1 -1
  137. package/dist/{vue-ui-word-cloud-X-0R5LUL.js → vue-ui-word-cloud-X1mDRHqA.js} +7 -7
  138. package/dist/{vue-ui-xy-BFwP2Go1.js → vue-ui-xy-CID8ZHKi.js} +12 -12
  139. package/dist/{vue-ui-xy-CyXVOTaL.cjs → vue-ui-xy-CQGKoYPl.cjs} +1 -1
  140. package/dist/{vue-ui-xy-canvas-CYpzz7dD.js → vue-ui-xy-canvas-BNAlSGC5.js} +10 -10
  141. package/dist/{vue-ui-xy-canvas-BYe5nz7y.cjs → vue-ui-xy-canvas-BiqWum4l.cjs} +1 -1
  142. package/package.json +1 -1
  143. package/dist/Slicer-BAW_Pyc1.js +0 -304
  144. package/dist/Slicer-DpNCNuHC.cjs +0 -1
  145. package/dist/index-JLHc-Z-t.cjs +0 -4
  146. package/dist/vue-ui-quick-chart-BbY97Eh1.cjs +0 -15
  147. package/dist/vue-ui-quick-chart-DtnbNLPH.js +0 -1374
@@ -1,1374 +0,0 @@
1
- import { ref as T, computed as G, onMounted as et, onBeforeUnmount as tt, openBlock as a, createElementBlock as l, normalizeClass as oe, normalizeStyle as F, createBlock as Ue, unref as m, createSlots as at, withCtx as Q, renderSlot as D, normalizeProps as X, guardReactiveProps as ce, createCommentVNode as x, toDisplayString as E, createElementVNode as w, Fragment as g, renderList as A, mergeProps as ze, createVNode as he, pushScopeId as lt, popScopeId as ot } from "vue";
2
- import { u as ut, c as it, t as nt, a as rt, p as U, b as st, d as $e, m as vt, A as De, X as dt, j as ct, k as fe, n as Ce, i as H, f as M, M as Ve, w as Se, x as Pe } from "./index-eNesjhZj.js";
3
- import { t as ht, u as ft } from "./useResponsive-NZB-WLRF.js";
4
- import we from "./BaseIcon-C_LL9N2v.js";
5
- import { _ as gt } from "./Tooltip-hQEVvasg.js";
6
- import { u as xt, U as yt } from "./usePrinter-DaXfYVdD.js";
7
- import { S as pt } from "./Slicer-BAW_Pyc1.js";
8
- import { u as qe } from "./useNestedProp-DNCWRjjz.js";
9
- import { _ as mt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
10
- const L = {
11
- LINE: "LINE",
12
- BAR: "BAR",
13
- DONUT: "DONUT"
14
- }, kt = ["SERIE", "SERIES", "DATA", "VALUE", "VALUES", "NUM"];
15
- function bt({ dataset: n, barLineSwitch: z = 6 }) {
16
- let f = null, R = null, V = 0;
17
- if ((typeof n == "number" || typeof n == "string") && console.warn(`The provided dataset (${n}) is not sufficient to build a chart`), ge(n) && (ue(n) && (n.length < z ? f = L.BAR : f = L.LINE, R = n, V = n.length), Te(n))) {
18
- if (!wt(n))
19
- return console.warn("The objects in the dataset array have a different data structure. Either keys or value types are different."), !1;
20
- const te = Object.keys(n[0]), ie = Object.values(n[0]);
21
- if (!te.some((C) => _t(C)))
22
- return console.warn("The data type of the dataset objects in the array must contain one of the following keys: DATA, SERIES, VALUE, VALUES, NUM. Casing is not important."), !1;
23
- We(ie, (C) => typeof C == "number") && (f = L.DONUT, R = n), We(ie, (C) => Array.isArray(C) && ue(C)) && (je(n) > z ? f = L.LINE : f = L.BAR, V = je(n), R = n.map((C) => ({
24
- ...C,
25
- data: At(C, (j) => ue(j))
26
- }))), n = n.map((C) => Ge(C)), R = R.map((C) => Ge(C));
27
- }
28
- return ge(n) && [...new Set(n.flatMap((te) => Array.isArray(te)))][0], {
29
- dataset: n,
30
- type: f,
31
- usableDataset: R,
32
- maxSeriesLength: V
33
- };
34
- }
35
- function He(n) {
36
- return !n || ge(n) && !n.length;
37
- }
38
- function ge(n) {
39
- return Array.isArray(n);
40
- }
41
- function ue(n) {
42
- if (!ge(n) || He(n)) return !1;
43
- const z = n.map((f) => Number(f));
44
- return ![...new Set(z.flatMap((f) => typeof f == "number" && !isNaN(f)))].includes(!1);
45
- }
46
- function Te(n) {
47
- return !ge(n) || He(n) || !![...new Set(n.flatMap((f) => typeof f == "object" && !Array.isArray(f)))].includes(!1) ? !1 : !n.map((f) => Object.keys(f).length > 0).includes(!1);
48
- }
49
- function St(n, z) {
50
- const f = Object.keys(n).sort(), R = Object.keys(z).sort();
51
- if (f.length !== R.length)
52
- return !1;
53
- for (let V = 0; V < f.length; V += 1) {
54
- const W = f[V], ee = R[V];
55
- if (W !== ee || typeof n[W] != typeof z[ee])
56
- return !1;
57
- }
58
- return !0;
59
- }
60
- function wt(n) {
61
- if (n.length <= 1) return !0;
62
- for (let z = 0; z < n.length; z += 1)
63
- for (let f = z + 1; f < n.length; f += 1)
64
- if (!St(n[z], n[f]))
65
- return !1;
66
- return !0;
67
- }
68
- function _t(n) {
69
- return kt.includes(n.toUpperCase());
70
- }
71
- function We(n, z) {
72
- let f = [];
73
- for (let R = 0; R < n.length; R += 1)
74
- f.push(z(n[R]));
75
- return f.includes(!0);
76
- }
77
- function je(n) {
78
- return Math.max(...[...n].flatMap((z) => Object.values(z).filter((f) => ue(f)).map((f) => f.length)));
79
- }
80
- function At(n, z) {
81
- return Object.values(n).filter((f) => z(f))[0];
82
- }
83
- function Ge(n) {
84
- const z = {};
85
- for (let f in n)
86
- n.hasOwnProperty(f) && (z[f.toUpperCase()] = n[f]);
87
- return z;
88
- }
89
- const Xe = (n) => (lt("data-v-8c2953ad"), n = n(), ot(), n), Lt = ["id"], zt = ["xmlns", "viewBox"], $t = ["id"], Ct = ["id"], Pt = /* @__PURE__ */ Xe(() => /* @__PURE__ */ w("feColorMatrix", {
90
- type: "saturate",
91
- values: "0"
92
- }, null, -1)), Tt = ["id"], Et = ["flood-color"], It = {
93
- key: 0,
94
- class: "donut-label-connectors"
95
- }, Rt = ["d", "stroke", "stroke-width", "filter"], Ft = ["cx", "cy", "r", "fill"], Ot = ["cx", "cy", "r", "fill", "filter"], Nt = { class: "donut" }, Mt = ["d", "fill", "stroke", "stroke-width", "filter"], Bt = ["d", "onMouseenter", "onClick"], Ut = {
96
- key: 1,
97
- class: "donut-labels quick-animation"
98
- }, Dt = ["cx", "cy", "fill", "filter"], Vt = ["text-anchor", "x", "y", "fill", "font-size", "filter"], qt = ["text-anchor", "x", "y", "fill", "font-size", "filter"], Wt = {
99
- key: 2,
100
- class: "donut-hollow quick-animation"
101
- }, jt = ["x", "y", "font-size", "fill"], Gt = ["x", "y", "font-size", "fill"], Ht = {
102
- key: 0,
103
- class: "line-grid"
104
- }, Xt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Yt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Zt = {
105
- key: 1,
106
- class: "line-axis"
107
- }, Jt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Kt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Qt = {
108
- key: 2,
109
- class: "yLabels"
110
- }, ea = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], ta = ["x", "y", "font-size", "fill"], aa = {
111
- key: 3,
112
- class: "periodLabels"
113
- }, la = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], oa = ["font-size", "text-anchor", "fill", "transform"], ua = { class: "plots" }, ia = { class: "line-plot-series" }, na = ["d", "stroke", "stroke-width"], ra = ["d", "stroke", "stroke-width"], sa = ["d", "stroke", "stroke-width"], va = ["d", "stroke", "stroke-width"], da = ["cx", "cy", "fill", "stroke"], ca = {
114
- key: 4,
115
- class: "dataLabels"
116
- }, ha = ["font-size", "fill", "x", "y"], fa = { class: "tooltip-traps" }, ga = ["x", "y", "height", "width", "fill", "onMouseenter", "onClick"], xa = {
117
- key: 0,
118
- class: "line-grid"
119
- }, ya = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], pa = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], ma = {
120
- key: 1,
121
- class: "line-axis"
122
- }, ka = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], ba = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Sa = {
123
- key: 2,
124
- class: "yLabels"
125
- }, wa = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], _a = ["x", "y", "font-size", "fill"], Aa = {
126
- key: 3,
127
- class: "periodLabels"
128
- }, La = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], za = ["font-size", "text-anchor", "transform", "fill"], $a = { class: "plots" }, Ca = ["x", "width", "height", "y", "fill", "stroke", "stroke-width"], Pa = ["to"], Ta = ["from", "to"], Ea = {
129
- key: 4,
130
- class: "dataLabels"
131
- }, Ia = ["x", "y", "font-size", "fill"], Ra = { class: "tooltip-traps" }, Fa = ["x", "y", "height", "width", "fill", "onMouseenter", "onClick"], Oa = {
132
- key: 3,
133
- class: "axis-labels"
134
- }, Na = { key: 0 }, Ma = ["font-size", "fill", "x", "y"], Ba = { key: 1 }, Ua = ["font-size", "fill", "x", "y"], Da = { key: 2 }, Va = ["font-size", "fill", "transform"], qa = { key: 3 }, Wa = ["font-size", "fill", "transform"], ja = {
135
- key: 2,
136
- class: "vue-data-ui-watermark"
137
- }, Ga = ["onClick"], Ha = ["onClick"], Xa = ["onClick"], Ya = {
138
- key: 1,
139
- class: "vue-ui-quick-chart-not-processable"
140
- }, Za = /* @__PURE__ */ Xe(() => /* @__PURE__ */ w("span", null, "Dataset is not processable", -1)), Ja = {
141
- __name: "vue-ui-quick-chart",
142
- props: {
143
- config: {
144
- type: Object,
145
- default() {
146
- return {};
147
- }
148
- },
149
- dataset: {
150
- type: [Array, Object, String, Number],
151
- default() {
152
- return null;
153
- }
154
- }
155
- },
156
- emits: ["selectDatapoint", "selectLegend"],
157
- setup(n, { expose: z, emit: f }) {
158
- const R = n, { vue_ui_quick_chart: V } = ut(), W = T(null), ee = T(null), te = T(null), ie = T(null), C = T(it()), j = T(!1), ne = T(null), Y = T(""), q = T(null), S = T([]), Ee = T(0), _e = T(0), e = G(() => {
159
- const r = qe({
160
- userConfig: R.config,
161
- defaultConfig: V
162
- });
163
- return r.theme ? {
164
- ...qe({
165
- userConfig: nt.vue_ui_quick_chart[r.theme] || R.config,
166
- defaultConfig: r
167
- }),
168
- customPalette: rt[r.theme] || U
169
- } : r;
170
- }), re = G(() => st(e.value.customPalette)), xe = G(() => {
171
- const r = bt({ dataset: R.dataset, barLineSwitch: e.value.chartIsBarUnderDatasetLength });
172
- return r || console.error("VueUiQuickChart : Dataset is not processable"), r;
173
- }), _ = T(xe.value), Ye = G(() => !!_.value), I = G(() => _.value ? _.value.type : null), { isPrinting: ye, isImaging: pe, generatePdf: Ie, generateImage: Re } = xt({
174
- elementId: `${I.value}_${C.value}`,
175
- fileName: e.value.title || I.value
176
- }), k = T({
177
- width: e.value.width,
178
- height: e.value.height
179
- }), me = T({
180
- showTooltip: e.value.showTooltip
181
- }), ke = T(null);
182
- et(() => {
183
- if (e.value.responsive) {
184
- const r = ht(() => {
185
- const { width: c, height: t } = ft({
186
- chart: W.value,
187
- title: e.value.title ? ee.value : null,
188
- legend: e.value.showLegend ? te.value : null,
189
- slicer: [L.BAR, L.LINE].includes(I.value) && e.value.zoomXy && _.value.maxSeriesLength > 1 ? ie.value : null
190
- });
191
- k.value.width = c, k.value.height = t;
192
- });
193
- ke.value = new ResizeObserver(r), ke.value.observe(W.value.parentNode);
194
- }
195
- }), tt(() => {
196
- ke.value && ke.value.disconnect();
197
- });
198
- const Ze = G(() => {
199
- switch (I.value) {
200
- case L.LINE:
201
- return `0 0 ${k.value.width <= 0 ? 10 : k.value.width} ${k.value.height <= 0 ? 10 : k.value.height}`;
202
- case L.BAR:
203
- return `0 0 ${k.value.width <= 0 ? 10 : k.value.width} ${k.value.height <= 0 ? 10 : k.value.height}`;
204
- case L.DONUT:
205
- return `0 0 ${k.value.width <= 0 ? 10 : k.value.width} ${k.value.height <= 0 ? 10 : k.value.height}`;
206
- default:
207
- return `0 0 ${k.value.width <= 0 ? 10 : k.value.width} ${k.value.height <= 0 ? 10 : k.value.height}`;
208
- }
209
- });
210
- function Fe(r) {
211
- return [...r].map((c) => c.value).reduce((c, t) => c + t, 0);
212
- }
213
- function se(r) {
214
- return e.value.blurOnHover && ![null, void 0].includes(q.value) && q.value !== r ? `url(#blur_${C.value})` : "";
215
- }
216
- function Oe(r, c) {
217
- S.value.includes(r) ? S.value = S.value.filter((t) => t !== r) : S.value.length < c && S.value.push(r);
218
- }
219
- const Ne = T(null), Me = T(null), be = T(!1);
220
- function Je(r, c) {
221
- be.value = !0;
222
- let t = r.value;
223
- if (S.value.includes(r.id)) {
224
- let s = function() {
225
- t > i ? (be.value = !1, cancelAnimationFrame(Me.value), _.value = {
226
- ..._.value,
227
- dataset: _.value.dataset.map((h, N) => r.id === `donut_${N}` ? {
228
- ...h,
229
- value: i,
230
- VALUE: i
231
- } : h)
232
- }) : (t += i * 0.025, _.value = {
233
- ..._.value,
234
- dataset: _.value.dataset.map((h, N) => r.id === `donut_${N}` ? {
235
- ...h,
236
- value: t,
237
- VALUE: t
238
- } : h)
239
- }, Me.value = requestAnimationFrame(s));
240
- };
241
- S.value = S.value.filter((h) => h !== r.id);
242
- const i = xe.value.dataset.find((h, N) => r.id === `donut_${N}`).VALUE;
243
- s();
244
- } else if (c.length > 1) {
245
- let i = function() {
246
- t < 0.1 ? (be.value = !1, cancelAnimationFrame(Ne.value), S.value.push(r.id), _.value = {
247
- ..._.value,
248
- dataset: _.value.dataset.map((s, h) => r.id === `donut_${h}` ? {
249
- ...s,
250
- value: 0,
251
- VALUE: 0
252
- } : s)
253
- }) : (t /= 1.1, _.value = {
254
- ..._.value,
255
- dataset: _.value.dataset.map((s, h) => r.id === `donut_${h}` ? {
256
- ...s,
257
- value: t,
258
- VALUE: t
259
- } : s)
260
- }, Ne.value = requestAnimationFrame(i));
261
- };
262
- i();
263
- }
264
- }
265
- const $ = G(() => {
266
- if (I.value !== L.DONUT) return null;
267
- const r = _.value.dataset.map((o, u) => ({
268
- ...o,
269
- value: o.VALUE || o.DATA || o.SERIE || o.VALUES || o.NUM || 0,
270
- name: o.NAME || o.DESCRIPTION || o.TITLE || o.LABEL || `Serie ${u}`,
271
- id: `donut_${u}`
272
- })).map((o, u) => ({
273
- ...o,
274
- color: o.COLOR ? $e(o.COLOR) : re.value[u + e.value.paletteStartIndex] || U[u + e.value.paletteStartIndex] || U[(u + e.value.paletteStartIndex) % U.length],
275
- immutableValue: o.value
276
- }));
277
- function c(o, u) {
278
- return M({
279
- v: isNaN(o.value / Fe(u)) ? 0 : o.value / Fe(u) * 100,
280
- s: "%",
281
- r: e.value.dataLabelRoundingPercentage
282
- });
283
- }
284
- function t(o) {
285
- return o.proportion * 100 > e.value.donutHideLabelUnderPercentage;
286
- }
287
- function i(o, u) {
288
- const p = xe.value.dataset.find((P, O) => `donut_${O}` === o).VALUE;
289
- return Math.abs(String(Number(p.toFixed(0))).length - String(Number(u.toFixed(0))).length);
290
- }
291
- function s({ datapoint: o, seriesIndex: u }) {
292
- ne.value = { datapoint: o, seriesIndex: u, config: e.value, dataset: r }, q.value = o.id;
293
- const p = e.value.tooltipCustomFormat;
294
- if (Se(p) && Pe(() => p({
295
- datapoint: o,
296
- seriesIndex: u,
297
- series: r,
298
- config: e.value
299
- })))
300
- Y.value = p({
301
- datapoint: o,
302
- seriesIndex: u,
303
- series: r,
304
- config: e.value
305
- });
306
- else {
307
- let y = "";
308
- y += `<div style="width:100%;text-align:center;border-bottom:1px solid ${e.value.tooltipBorderColor};padding-bottom:6px;margin-bottom:3px;">${o.name}</div>`, y += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${o.color}"/></svg>`, y += `<b>${H(
309
- e.value.formatter,
310
- o.value,
311
- M({
312
- p: e.value.valuePrefix,
313
- v: o.value,
314
- s: e.value.valueSuffix,
315
- r: e.value.dataLabelRoundingValue
316
- }),
317
- { datapoint: o, seriesIndex: u }
318
- )}</b>`, y += `<span>(${M({ v: o.proportion * 100, s: "%", r: e.value.dataLabelRoundingPercentage })})</span></div>`, Y.value = `<div>${y}</div>`;
319
- }
320
- j.value = !0;
321
- }
322
- function h() {
323
- j.value = !1, q.value = null;
324
- }
325
- const N = {
326
- centerX: k.value.width / 2,
327
- centerY: k.value.height / 2
328
- }, B = r.filter((o) => !S.value.includes(o.id)).map((o) => o.value || 0).reduce((o, u) => o + u, 0), ae = r.map((o, u) => ({
329
- ...o,
330
- proportion: (o.value || 0) / B,
331
- value: o.value || 0,
332
- absoluteValue: xe.value.dataset.find((p, y) => `donut_${y}` === o.id).VALUE
333
- })), Z = k.value.width / 2, le = k.value.height / 2, J = k.value.height * e.value.donutRadiusRatio;
334
- return {
335
- dataset: ae.filter((o) => !S.value.includes(o.id)),
336
- legend: ae,
337
- drawingArea: N,
338
- displayArcPercentage: c,
339
- isArcBigEnough: t,
340
- useTooltip: s,
341
- killTooltip: h,
342
- getSpaces: i,
343
- total: B,
344
- cx: Z,
345
- cy: le,
346
- radius: J,
347
- chart: vt(
348
- { series: r.filter((o) => !S.value.includes(o.id)) },
349
- Z,
350
- le,
351
- J,
352
- J,
353
- 1.99999,
354
- 2,
355
- 1,
356
- 360,
357
- 105.25,
358
- k.value.height * e.value.donutThicknessRatio
359
- )
360
- };
361
- }), b = T({
362
- start: 0,
363
- end: _.value.maxSeriesLength
364
- });
365
- function Ke() {
366
- b.value = {
367
- start: 0,
368
- end: _.value.maxSeriesLength
369
- }, _e.value += 1;
370
- }
371
- const d = G(() => {
372
- if (I.value !== L.LINE) return null;
373
- const r = {
374
- height: k.value.height,
375
- width: k.value.width
376
- }, c = {
377
- left: e.value.xyPaddingLeft,
378
- top: e.value.xyPaddingTop,
379
- right: r.width - e.value.xyPaddingRight,
380
- bottom: r.height - e.value.xyPaddingBottom,
381
- width: r.width - e.value.xyPaddingLeft - e.value.xyPaddingRight,
382
- height: r.height - e.value.xyPaddingTop - e.value.xyPaddingBottom
383
- };
384
- let t = [];
385
- ue(_.value.dataset) && (t = [
386
- {
387
- values: _.value.dataset.slice(b.value.start, b.value.end),
388
- absoluteIndices: _.value.dataset.map((o, u) => u).slice(b.value.start, b.value.end),
389
- name: e.value.title,
390
- color: re.value[e.value.paletteStartIndex] || U[e.value.paletteStartIndex],
391
- id: "line_0"
392
- }
393
- ]), Te(_.value.dataset) && (t = _.value.dataset.map((o, u) => ({
394
- ...o,
395
- values: o.VALUE || o.DATA || o.SERIE || o.VALUES || o.NUM || 0,
396
- name: o.NAME || o.DESCRIPTION || o.TITLE || o.LABEL || `Serie ${u}`,
397
- id: `line_${u}`
398
- })).map((o, u) => ({
399
- ...o,
400
- color: o.COLOR ? $e(o.COLOR) : re.value[u + e.value.paletteStartIndex] || U[u + e.value.paletteStartIndex] || U[(u + e.value.paletteStartIndex) % U.length],
401
- values: o.values.slice(b.value.start, b.value.end),
402
- absoluteIndices: o.values.map((p, y) => y).slice(b.value.start, b.value.end)
403
- })));
404
- const i = {
405
- max: Math.max(...t.filter((o) => !S.value.includes(o.id)).flatMap((o) => o.values)),
406
- min: Math.min(...t.filter((o) => !S.value.includes(o.id)).flatMap((o) => o.values)),
407
- maxSeries: Math.max(...t.map((o) => o.values.length))
408
- }, s = De(i.min < 0 ? i.min : 0, i.max < 0 ? 0 : i.max, e.value.xyScaleSegments), h = i.min < 0 ? Math.abs(i.min) : 0, N = i.max < 0 ? c.top : c.bottom - h / (s.max + h) * c.height, B = c.width / i.maxSeries, ae = s.ticks.map((o) => ({
409
- y: c.bottom - c.height * ((o + h) / (s.max + h)),
410
- x: c.left - 8,
411
- value: o
412
- })), Z = t.map((o, u) => ({
413
- ...o,
414
- coordinates: o.values.map((p, y) => ({
415
- x: c.left + B * (y + 1) - B / 2,
416
- y: c.bottom - (p + h) / (s.max + h) * c.height,
417
- value: p
418
- }))
419
- })).map((o) => {
420
- let u = [];
421
- return o.coordinates.forEach((p) => {
422
- u.push(`${p.x},${p.y} `);
423
- }), {
424
- ...o,
425
- linePath: u.join(" ")
426
- };
427
- });
428
- function le(o) {
429
- q.value = o;
430
- const u = t.map((y) => ({
431
- ...y,
432
- value: y.values[o],
433
- absoluteIndex: y.absoluteIndices[o]
434
- })).filter((y) => !S.value.includes(y.id));
435
- ne.value = { datapoint: u, seriesIndex: o, config: e.value, dataset: t };
436
- const p = e.value.tooltipCustomFormat;
437
- if (Se(p) && Pe(() => p({
438
- datapoint: u,
439
- seriesIndex: o,
440
- series: t,
441
- config: e.value
442
- })))
443
- Y.value = p({
444
- datapoint: u,
445
- seriesIndex: o,
446
- series: t,
447
- config: e.value
448
- });
449
- else {
450
- let y = "";
451
- e.value.xyPeriods[u[0].absoluteIndex] && (y += `<div style="border-bottom:1px solid ${e.value.tooltipBorderColor};padding-bottom:6px;margin-bottom:3px;">${e.value.xyPeriods[u[0].absoluteIndex]}</div>`), u.forEach((P, O) => {
452
- y += `
453
- <div style="display:flex; flex-wrap: wrap; align-items:center; gap:3px;">
454
- <svg viewBox="0 0 12 12" height="14" width="12"><circle cx="6" cy="6" r="6" stroke="none" fill="${P.color}"/></svg>
455
- <span>${P.name}:</span>
456
- <b>${H(
457
- e.value.formatter,
458
- P.value,
459
- M({
460
- p: e.value.valuePrefix,
461
- v: P.value,
462
- s: e.value.valueSuffix,
463
- r: e.value.dataLabelRoundingValue
464
- }),
465
- { datapoint: P, seriesIndex: O }
466
- )}
467
- </b>
468
- </div>
469
- `;
470
- }), Y.value = y;
471
- }
472
- j.value = !0;
473
- }
474
- function J() {
475
- q.value = null, j.value = !1;
476
- }
477
- return {
478
- absoluteZero: N,
479
- dataset: Z.filter((o) => !S.value.includes(o.id)),
480
- legend: Z,
481
- drawingArea: c,
482
- extremes: i,
483
- slotSize: B,
484
- yLabels: ae,
485
- useTooltip: le,
486
- killTooltip: J
487
- };
488
- }), v = G(() => {
489
- if (I.value !== L.BAR) return null;
490
- const r = {
491
- height: k.value.height,
492
- width: k.value.width
493
- }, c = {
494
- left: e.value.xyPaddingLeft,
495
- top: e.value.xyPaddingTop,
496
- right: r.width - e.value.xyPaddingRight,
497
- bottom: r.height - e.value.xyPaddingBottom,
498
- width: r.width - e.value.xyPaddingLeft - e.value.xyPaddingRight,
499
- height: r.height - e.value.xyPaddingTop - e.value.xyPaddingBottom
500
- };
501
- let t = [];
502
- ue(_.value.dataset) && (t = [
503
- {
504
- values: _.value.dataset.slice(b.value.start, b.value.end),
505
- absoluteIndices: _.value.dataset.map((u, p) => p).slice(b.value.start, b.value.end),
506
- name: e.value.title,
507
- color: re.value[e.value.paletteStartIndex] || U[e.value.paletteStartIndex],
508
- id: "bar_0"
509
- }
510
- ]), Te(_.value.dataset) && (t = _.value.dataset.map((u, p) => ({
511
- ...u,
512
- values: u.VALUE || u.DATA || u.SERIE || u.VALUES || u.NUM || 0,
513
- name: u.NAME || u.DESCRIPTION || u.TITLE || u.LABEL || `Serie ${p}`,
514
- id: `bar_${p}`
515
- })).map((u, p) => ({
516
- ...u,
517
- color: u.COLOR ? $e(u.COLOR) : re.value[p + e.value.paletteStartIndex] || U[p + e.value.paletteStartIndex] || U[(p + e.value.paletteStartIndex) % U.length],
518
- values: u.values.slice(b.value.start, b.value.end),
519
- absoluteIndices: u.values.map((y, P) => P).slice(b.value.start, b.value.end)
520
- })));
521
- const i = {
522
- max: Math.max(...t.filter((u) => !S.value.includes(u.id)).flatMap((u) => u.values)) < 0 ? 0 : Math.max(...t.filter((u) => !S.value.includes(u.id)).flatMap((u) => u.values)),
523
- min: Math.min(...t.filter((u) => !S.value.includes(u.id)).flatMap((u) => u.values)),
524
- maxSeries: Math.max(...t.filter((u) => !S.value.includes(u.id)).map((u) => u.values.length))
525
- }, s = De(i.min < 0 ? i.min : 0, i.max, e.value.xyScaleSegments), h = s.min < 0 ? Math.abs(s.min) : 0, N = c.bottom - h / (s.max + h) * c.height, B = c.width / i.maxSeries, ae = s.ticks.map((u) => ({
526
- y: c.bottom - c.height * ((u + h) / (s.max + h)),
527
- x: c.left - 8,
528
- value: u
529
- })), Z = t.map((u, p) => ({
530
- ...u,
531
- coordinates: u.values.map((y, P) => {
532
- const O = (y + h) / (i.max + h) * c.height, ve = Math.abs(y) / Math.abs(i.min) * (c.height - N), Le = h / (i.max + h) * c.height, de = B / t.filter((K) => !S.value.includes(K.id)).length - e.value.barGap / t.filter((K) => !S.value.includes(K.id)).length;
533
- return {
534
- x: c.left + B * P + de * p + e.value.barGap / 2,
535
- y: y > 0 ? c.bottom - O : N,
536
- height: y > 0 ? O - Le : ve,
537
- value: y,
538
- width: de
539
- };
540
- })
541
- })), le = t.filter((u) => !S.value.includes(u.id)).map((u, p) => ({
542
- ...u,
543
- coordinates: u.values.map((y, P) => {
544
- const O = (y + h) / (i.max + h) * c.height, ve = Math.abs(y) / (i.max + h) * c.height, Le = h / (i.max + h) * c.height, de = B / t.filter((K) => !S.value.includes(K.id)).length - e.value.barGap / t.filter((K) => !S.value.includes(K.id)).length;
545
- return {
546
- x: c.left + B * P + de * p + e.value.barGap / 2,
547
- y: y > 0 ? c.bottom - O : N,
548
- height: y > 0 ? O - Le : ve,
549
- value: y,
550
- width: de
551
- };
552
- })
553
- }));
554
- function J(u) {
555
- q.value = u;
556
- const p = t.map((P) => ({
557
- ...P,
558
- value: P.values[u],
559
- absoluteIndex: P.absoluteIndices[u]
560
- })).filter((P) => !S.value.includes(P.id));
561
- ne.value = { datapoint: p, seriesIndex: u, config: e.value, dataset: t };
562
- const y = e.value.tooltipCustomFormat;
563
- if (Se(y) && Pe(() => y({
564
- datapoint: p,
565
- seriesIndex: u,
566
- series: t,
567
- config: e.value
568
- })))
569
- Y.value = y({
570
- point: p,
571
- seriesIndex: u,
572
- series: t,
573
- config: e.value
574
- });
575
- else {
576
- let P = "";
577
- e.value.xyPeriods[p[0].absoluteIndex] && (P += `<div style="border-bottom:1px solid ${e.value.tooltipBorderColor};padding-bottom:6px;margin-bottom:3px;">${e.value.xyPeriods[p[0].absoluteIndex]}</div>`), p.forEach((O, ve) => {
578
- P += `
579
- <div style="display:flex; flex-wrap: wrap; align-items:center; gap:3px;">
580
- <svg viewBox="0 0 12 12" height="14" width="12"><rect x=0 y="0" width="12" height="12" rx="1" stroke="none" fill="${O.color}"/></svg>
581
- <span>${O.name}:</span>
582
- <b>${H(
583
- e.value.formatter,
584
- O.value,
585
- M({
586
- p: e.value.valuePrefix,
587
- v: O.value,
588
- s: e.value.valueSuffix,
589
- r: e.value.dataLabelRoundingValue
590
- }),
591
- { datapoint: O, seriesIndex: ve }
592
- )}
593
- </b>
594
- </div>
595
- `;
596
- }), Y.value = P;
597
- }
598
- j.value = !0;
599
- }
600
- function o() {
601
- j.value = !1, q.value = null;
602
- }
603
- return {
604
- absoluteZero: N,
605
- dataset: le.filter((u) => !S.value.includes(u.id)),
606
- legend: Z,
607
- drawingArea: c,
608
- extremes: i,
609
- slotSize: B,
610
- yLabels: ae,
611
- useTooltip: J,
612
- killTooltip: o
613
- };
614
- }), Ae = T(!1);
615
- function Qe(r) {
616
- Ae.value = r, Ee.value += 1;
617
- }
618
- function Be() {
619
- me.value.showTooltip = !me.value.showTooltip;
620
- }
621
- return z({
622
- generatePdf: Ie,
623
- generateImage: Re,
624
- toggleTooltip: Be
625
- }), (r, c) => Ye.value ? (a(), l("div", {
626
- key: 0,
627
- id: `${I.value}_${C.value}`,
628
- ref_key: "quickChart",
629
- ref: W,
630
- class: oe({ "vue-ui-quick-chart": !0, "vue-data-ui-wrapper-fullscreen": Ae.value }),
631
- style: F(`background:${e.value.backgroundColor};color:${e.value.color};font-family:${e.value.fontFamily}; position: relative; ${e.value.responsive ? "height: 100%" : ""}`)
632
- }, [
633
- e.value.showUserOptions ? (a(), Ue(yt, {
634
- ref: "details",
635
- key: `user_option_${Ee.value}`,
636
- backgroundColor: e.value.backgroundColor,
637
- color: e.value.color,
638
- isPrinting: m(ye),
639
- isImaging: m(pe),
640
- uid: C.value,
641
- hasTooltip: e.value.userOptionsButtons.tooltip && e.value.showTooltip,
642
- hasPdf: e.value.userOptionsButtons.pdf,
643
- hasImg: e.value.userOptionsButtons.img,
644
- hasFullscreen: e.value.userOptionsButtons.fullscreen,
645
- hasXls: !1,
646
- isTooltip: me.value.showTooltip,
647
- isFullscreen: Ae.value,
648
- titles: { ...e.value.userOptionsButtonTitles },
649
- chartElement: W.value,
650
- onToggleFullscreen: Qe,
651
- onGeneratePdf: m(Ie),
652
- onGenerateImage: m(Re),
653
- onToggleTooltip: Be
654
- }, at({ _: 2 }, [
655
- r.$slots.optionTooltip ? {
656
- name: "optionTooltip",
657
- fn: Q(() => [
658
- D(r.$slots, "optionTooltip", {}, void 0, !0)
659
- ]),
660
- key: "0"
661
- } : void 0,
662
- r.$slots.optionPdf ? {
663
- name: "optionPdf",
664
- fn: Q(() => [
665
- D(r.$slots, "optionPdf", {}, void 0, !0)
666
- ]),
667
- key: "1"
668
- } : void 0,
669
- r.$slots.optionImg ? {
670
- name: "optionImg",
671
- fn: Q(() => [
672
- D(r.$slots, "optionImg", {}, void 0, !0)
673
- ]),
674
- key: "2"
675
- } : void 0,
676
- r.$slots.optionFullscreen ? {
677
- name: "optionFullscreen",
678
- fn: Q(({ toggleFullscreen: t, isFullscreen: i }) => [
679
- D(r.$slots, "optionFullscreen", X(ce({ toggleFullscreen: t, isFullscreen: i })), void 0, !0)
680
- ]),
681
- key: "3"
682
- } : void 0
683
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasImg", "hasFullscreen", "isTooltip", "isFullscreen", "titles", "chartElement", "onGeneratePdf", "onGenerateImage"])) : x("", !0),
684
- e.value.title ? (a(), l("div", {
685
- key: 1,
686
- ref_key: "quickChartTitle",
687
- ref: ee,
688
- class: "vue-ui-quick-chart-title",
689
- style: F(`background:${e.value.backgroundColor};color:${e.value.color};font-size:${e.value.titleFontSize}px;font-weight:${e.value.titleBold ? "bold" : "normal"};text-align:${e.value.titleTextAlign}`)
690
- }, E(e.value.title), 5)) : x("", !0),
691
- (a(), l("svg", {
692
- xmlns: m(dt),
693
- viewBox: Ze.value,
694
- style: F(`max-width:100%;overflow:visible;background:${e.value.backgroundColor};color:${e.value.color}`)
695
- }, [
696
- w("defs", null, [
697
- w("filter", {
698
- id: `blur_${C.value}`,
699
- x: "-50%",
700
- y: "-50%",
701
- width: "200%",
702
- height: "200%"
703
- }, [
704
- w("feGaussianBlur", {
705
- in: "SourceGraphic",
706
- stdDeviation: 2,
707
- id: `blur_std_${C.value}`
708
- }, null, 8, Ct),
709
- Pt
710
- ], 8, $t),
711
- w("filter", {
712
- id: `shadow_${C.value}`,
713
- "color-interpolation-filters": "sRGB"
714
- }, [
715
- w("feDropShadow", {
716
- dx: "0",
717
- dy: "0",
718
- stdDeviation: "10",
719
- "flood-opacity": "0.5",
720
- "flood-color": e.value.donutShadowColor
721
- }, null, 8, Et)
722
- ], 8, Tt)
723
- ]),
724
- I.value === L.DONUT ? (a(), l(g, { key: 0 }, [
725
- e.value.showDataLabels ? (a(), l("g", It, [
726
- (a(!0), l(g, null, A($.value.chart, (t, i) => (a(), l(g, null, [
727
- $.value.isArcBigEnough(t) ? (a(), l("path", {
728
- key: 0,
729
- d: m(ct)(t, { x: (e.value.width || k.value.width) / 2, y: (e.value.height || k.value.height) / 2 }, 16, 16, !1, !1, e.value.donutLabelMarkerStrokeWidth),
730
- stroke: t.color,
731
- "stroke-width": e.value.donutLabelMarkerStrokeWidth,
732
- "stroke-linecap": "round",
733
- "stroke-linejoin": "round",
734
- fill: "none",
735
- filter: se(t.id)
736
- }, null, 8, Rt)) : x("", !0)
737
- ], 64))), 256))
738
- ])) : x("", !0),
739
- w("circle", {
740
- class: "donut-hollow",
741
- cx: (e.value.width || k.value.width) / 2,
742
- cy: (e.value.height || k.value.height) / 2,
743
- r: (e.value.height || k.value.height) * e.value.donutRadiusRatio,
744
- fill: e.value.backgroundColor
745
- }, null, 8, Ft),
746
- w("circle", {
747
- cx: $.value.cx,
748
- cy: $.value.cy,
749
- r: $.value.radius,
750
- fill: e.value.backgroundColor,
751
- filter: e.value.donutUseShadow ? `url(#shadow_${C.value})` : ""
752
- }, null, 8, Ot),
753
- w("g", Nt, [
754
- (a(!0), l(g, null, A($.value.chart, (t, i) => (a(), l("path", {
755
- d: t.arcSlice,
756
- fill: t.color,
757
- stroke: e.value.backgroundColor,
758
- "stroke-width": e.value.donutStrokeWidth,
759
- filter: se(t.id)
760
- }, null, 8, Mt))), 256)),
761
- (a(!0), l(g, null, A($.value.chart, (t, i) => (a(), l("path", {
762
- d: t.arcSlice,
763
- fill: "transparent",
764
- onMouseenter: (s) => $.value.useTooltip({ datapoint: t, seriesIndex: i }),
765
- onMouseout: c[0] || (c[0] = (s) => $.value.killTooltip()),
766
- onClick: (s) => f("selectDatapoint", t)
767
- }, null, 40, Bt))), 256))
768
- ]),
769
- e.value.showDataLabels ? (a(), l("g", Ut, [
770
- (a(!0), l(g, null, A($.value.chart, (t, i) => (a(), l(g, null, [
771
- $.value.isArcBigEnough(t) ? (a(), l("circle", {
772
- key: 0,
773
- cx: m(fe)(t).x,
774
- cy: m(Ce)(t) - 3.7,
775
- fill: t.color,
776
- r: 3,
777
- filter: se(t.id)
778
- }, null, 8, Dt)) : x("", !0),
779
- $.value.isArcBigEnough(t) ? (a(), l("text", {
780
- key: 1,
781
- "text-anchor": m(fe)(t, !0, 20).anchor,
782
- x: m(fe)(t, !0).x,
783
- y: m(Ce)(t),
784
- fill: e.value.color,
785
- "font-size": e.value.dataLabelFontSize,
786
- filter: se(t.id)
787
- }, E($.value.displayArcPercentage(t, $.value.chart)) + " (" + E(m(H)(
788
- e.value.formatter,
789
- t.value,
790
- m(M)({
791
- p: e.value.valuePrefix,
792
- v: t.value,
793
- s: e.value.valueSuffix,
794
- r: e.value.dataLabelRoundingValue
795
- }),
796
- { datapoint: t, seriesIndex: i }
797
- )) + ") ", 9, Vt)) : x("", !0),
798
- $.value.isArcBigEnough(t, !0, 20) ? (a(), l("text", {
799
- key: 2,
800
- "text-anchor": m(fe)(t).anchor,
801
- x: m(fe)(t, !0).x,
802
- y: m(Ce)(t) + e.value.dataLabelFontSize,
803
- fill: e.value.color,
804
- "font-size": e.value.dataLabelFontSize,
805
- filter: se(t.id)
806
- }, E(t.name), 9, qt)) : x("", !0)
807
- ], 64))), 256))
808
- ])) : x("", !0),
809
- e.value.donutShowTotal ? (a(), l("g", Wt, [
810
- w("text", {
811
- "text-anchor": "middle",
812
- x: $.value.drawingArea.centerX,
813
- y: $.value.drawingArea.centerY - e.value.donutTotalLabelFontSize / 2,
814
- "font-size": e.value.donutTotalLabelFontSize,
815
- fill: e.value.color
816
- }, E(e.value.donutTotalLabelText), 9, jt),
817
- w("text", {
818
- "text-anchor": "middle",
819
- x: $.value.drawingArea.centerX,
820
- y: $.value.drawingArea.centerY + e.value.donutTotalLabelFontSize,
821
- "font-size": e.value.donutTotalLabelFontSize,
822
- fill: e.value.color
823
- }, E(m(M)({
824
- p: e.value.valuePrefix,
825
- v: $.value.total,
826
- s: e.value.valueSuffix,
827
- r: e.value.dataLabelRoundingValue
828
- })), 9, Gt)
829
- ])) : x("", !0)
830
- ], 64)) : x("", !0),
831
- I.value === L.LINE ? (a(), l(g, { key: 1 }, [
832
- e.value.xyShowGrid ? (a(), l("g", Ht, [
833
- (a(!0), l(g, null, A(d.value.yLabels, (t) => (a(), l(g, null, [
834
- t.y <= d.value.drawingArea.bottom ? (a(), l("line", {
835
- key: 0,
836
- x1: d.value.drawingArea.left,
837
- x2: d.value.drawingArea.right,
838
- y1: t.y,
839
- y2: t.y,
840
- stroke: e.value.xyGridStroke,
841
- "stroke-width": e.value.xyGridStrokeWidth,
842
- "stroke-linecap": "round"
843
- }, null, 8, Xt)) : x("", !0)
844
- ], 64))), 256)),
845
- (a(!0), l(g, null, A(d.value.extremes.maxSeries + 1, (t, i) => (a(), l("line", {
846
- x1: d.value.drawingArea.left + d.value.slotSize * i,
847
- x2: d.value.drawingArea.left + d.value.slotSize * i,
848
- y1: d.value.drawingArea.top,
849
- y2: d.value.drawingArea.bottom,
850
- stroke: e.value.xyGridStroke,
851
- "stroke-width": e.value.xyGridStrokeWidth,
852
- "stroke-linecap": "round"
853
- }, null, 8, Yt))), 256))
854
- ])) : x("", !0),
855
- e.value.xyShowAxis ? (a(), l("g", Zt, [
856
- w("line", {
857
- x1: d.value.drawingArea.left,
858
- x2: d.value.drawingArea.left,
859
- y1: d.value.drawingArea.top,
860
- y2: d.value.drawingArea.bottom,
861
- stroke: e.value.xyAxisStroke,
862
- "stroke-width": e.value.xyAxisStrokeWidth,
863
- "stroke-linecap": "round"
864
- }, null, 8, Jt),
865
- w("line", {
866
- x1: d.value.drawingArea.left,
867
- x2: d.value.drawingArea.right,
868
- y1: d.value.absoluteZero,
869
- y2: d.value.absoluteZero,
870
- stroke: e.value.xyAxisStroke,
871
- "stroke-width": e.value.xyAxisStrokeWidth,
872
- "stroke-linecap": "round"
873
- }, null, 8, Kt)
874
- ])) : x("", !0),
875
- e.value.xyShowScale ? (a(), l("g", Qt, [
876
- (a(!0), l(g, null, A(d.value.yLabels, (t, i) => (a(), l(g, null, [
877
- t.y <= d.value.drawingArea.bottom ? (a(), l("line", {
878
- key: 0,
879
- x1: t.x + 4,
880
- x2: d.value.drawingArea.left,
881
- y1: t.y,
882
- y2: t.y,
883
- stroke: e.value.xyAxisStroke,
884
- "stroke-width": e.value.xyAxisStrokeWidth,
885
- "stroke-linecap": "round"
886
- }, null, 8, ea)) : x("", !0),
887
- t.y <= d.value.drawingArea.bottom ? (a(), l("text", {
888
- key: 1,
889
- x: t.x,
890
- y: t.y + e.value.xyLabelsYFontSize / 3,
891
- "text-anchor": "end",
892
- "font-size": e.value.xyLabelsYFontSize,
893
- fill: e.value.color
894
- }, E(m(H)(
895
- e.value.formatter,
896
- t.value,
897
- m(M)({
898
- p: e.value.valuePrefix,
899
- v: t.value,
900
- s: e.value.valueSuffix,
901
- r: e.value.dataLabelRoundingValue
902
- }),
903
- { datapoint: t, seriesIndex: i }
904
- )), 9, ta)) : x("", !0)
905
- ], 64))), 256))
906
- ])) : x("", !0),
907
- e.value.xyShowScale && e.value.xyPeriods.length ? (a(), l("g", aa, [
908
- (a(!0), l(g, null, A(e.value.xyPeriods.slice(b.value.start, b.value.end), (t, i) => (a(), l("line", {
909
- x1: d.value.drawingArea.left + d.value.slotSize * (i + 1) - d.value.slotSize / 2,
910
- x2: d.value.drawingArea.left + d.value.slotSize * (i + 1) - d.value.slotSize / 2,
911
- y1: d.value.drawingArea.bottom,
912
- y2: d.value.drawingArea.bottom + 4,
913
- stroke: e.value.xyAxisStroke,
914
- "stroke-width": e.value.xyAxisStrokeWidth,
915
- "stroke-linecap": "round"
916
- }, null, 8, la))), 256)),
917
- (a(!0), l(g, null, A(e.value.xyPeriods.slice(b.value.start, b.value.end), (t, i) => (a(), l("text", {
918
- "font-size": e.value.xyLabelsXFontSize,
919
- "text-anchor": e.value.xyPeriodLabelsRotation > 0 ? "start" : e.value.xyPeriodLabelsRotation < 0 ? "end" : "middle",
920
- fill: e.value.color,
921
- transform: `translate(${d.value.drawingArea.left + d.value.slotSize * (i + 1) - d.value.slotSize / 2}, ${d.value.drawingArea.bottom + e.value.xyLabelsXFontSize + 6}), rotate(${e.value.xyPeriodLabelsRotation})`
922
- }, E(t), 9, oa))), 256))
923
- ])) : x("", !0),
924
- w("g", ua, [
925
- (a(!0), l(g, null, A(d.value.dataset, (t, i) => (a(), l("g", ia, [
926
- e.value.lineSmooth ? (a(), l(g, { key: 0 }, [
927
- w("path", {
928
- d: `M ${m(Ve)(t.coordinates)}`,
929
- stroke: e.value.backgroundColor,
930
- "stroke-width": e.value.lineStrokeWidth + 1,
931
- "stroke-linecap": "round",
932
- fill: "none",
933
- class: oe({ "quick-animation": !0, "vue-data-ui-line-animated": e.value.lineAnimated }),
934
- style: { transition: "all 0.3s ease-in-out" }
935
- }, null, 10, na),
936
- w("path", {
937
- d: `M ${m(Ve)(t.coordinates)}`,
938
- stroke: t.color,
939
- "stroke-width": e.value.lineStrokeWidth,
940
- "stroke-linecap": "round",
941
- fill: "none",
942
- class: oe({ "quick-animation": !0, "vue-data-ui-line-animated": e.value.lineAnimated }),
943
- style: { transition: "all 0.3s ease-in-out" }
944
- }, null, 10, ra)
945
- ], 64)) : (a(), l(g, { key: 1 }, [
946
- w("path", {
947
- d: `M ${t.linePath}`,
948
- stroke: e.value.backgroundColor,
949
- "stroke-width": e.value.lineStrokeWidth + 1,
950
- "stroke-linecap": "round",
951
- fill: "none",
952
- class: oe({ "quick-animation": !0, "vue-data-ui-line-animated": e.value.lineAnimated }),
953
- style: { transition: "all 0.3s ease-in-out" }
954
- }, null, 10, sa),
955
- w("path", {
956
- d: `M ${t.linePath}`,
957
- stroke: t.color,
958
- "stroke-width": e.value.lineStrokeWidth,
959
- "stroke-linecap": "round",
960
- fill: "none",
961
- class: oe({ "quick-animation": !0, "vue-data-ui-line-animated": e.value.lineAnimated }),
962
- style: { transition: "all 0.3s ease-in-out" }
963
- }, null, 10, va)
964
- ], 64)),
965
- (a(!0), l(g, null, A(t.coordinates, (s, h) => (a(), l("circle", {
966
- cx: s.x,
967
- cy: s.y,
968
- r: 3,
969
- fill: t.color,
970
- stroke: e.value.backgroundColor,
971
- "stroke-width": "0.5",
972
- class: "quick-animation",
973
- style: { transition: "all 0.3s ease-in-out" }
974
- }, null, 8, da))), 256))
975
- ]))), 256))
976
- ]),
977
- e.value.showDataLabels ? (a(), l("g", ca, [
978
- (a(!0), l(g, null, A(d.value.dataset, (t, i) => (a(), l(g, null, [
979
- (a(!0), l(g, null, A(t.coordinates, (s, h) => (a(), l("text", {
980
- "text-anchor": "middle",
981
- "font-size": e.value.dataLabelFontSize,
982
- fill: t.color,
983
- x: s.x,
984
- y: s.y - e.value.dataLabelFontSize / 2,
985
- class: "quick-animation",
986
- style: { transition: "all 0.3s ease-in-out" }
987
- }, E(m(H)(
988
- e.value.formatter,
989
- s.value,
990
- m(M)({
991
- p: e.value.valuePrefix,
992
- v: s.value,
993
- s: e.value.valueSuffix,
994
- r: e.value.dataLabelRoundingValue
995
- }),
996
- { datapoint: s, seriesIndex: h }
997
- )), 9, ha))), 256))
998
- ], 64))), 256))
999
- ])) : x("", !0),
1000
- w("g", fa, [
1001
- (a(!0), l(g, null, A(d.value.extremes.maxSeries, (t, i) => (a(), l("rect", {
1002
- x: d.value.drawingArea.left + i * d.value.slotSize,
1003
- y: d.value.drawingArea.top,
1004
- height: d.value.drawingArea.height <= 0 ? 1e-5 : d.value.drawingArea.height,
1005
- width: d.value.slotSize <= 0 ? 1e-5 : d.value.slotSize,
1006
- fill: q.value === i ? e.value.xyHighlighterColor : "transparent",
1007
- style: F(`opacity:${e.value.xyHighlighterOpacity}`),
1008
- onMouseenter: (s) => d.value.useTooltip(i),
1009
- onMouseleave: c[1] || (c[1] = (s) => d.value.killTooltip()),
1010
- onClick: (s) => f("selectDatapoint", d.value.dataset.map((h) => ({
1011
- ...h,
1012
- value: h.values[i]
1013
- })))
1014
- }, null, 44, ga))), 256))
1015
- ])
1016
- ], 64)) : x("", !0),
1017
- I.value === L.BAR ? (a(), l(g, { key: 2 }, [
1018
- e.value.xyShowGrid ? (a(), l("g", xa, [
1019
- (a(!0), l(g, null, A(v.value.yLabels, (t) => (a(), l(g, null, [
1020
- t.y <= v.value.drawingArea.bottom ? (a(), l("line", {
1021
- key: 0,
1022
- x1: v.value.drawingArea.left,
1023
- x2: v.value.drawingArea.right,
1024
- y1: t.y,
1025
- y2: t.y,
1026
- stroke: e.value.xyGridStroke,
1027
- "stroke-width": e.value.xyGridStrokeWidth,
1028
- "stroke-linecap": "round"
1029
- }, null, 8, ya)) : x("", !0)
1030
- ], 64))), 256)),
1031
- (a(!0), l(g, null, A(v.value.extremes.maxSeries + 1, (t, i) => (a(), l("line", {
1032
- x1: v.value.drawingArea.left + v.value.slotSize * i,
1033
- x2: v.value.drawingArea.left + v.value.slotSize * i,
1034
- y1: v.value.drawingArea.top,
1035
- y2: v.value.drawingArea.bottom,
1036
- stroke: e.value.xyGridStroke,
1037
- "stroke-width": e.value.xyGridStrokeWidth,
1038
- "stroke-linecap": "round"
1039
- }, null, 8, pa))), 256))
1040
- ])) : x("", !0),
1041
- e.value.xyShowAxis ? (a(), l("g", ma, [
1042
- w("line", {
1043
- x1: v.value.drawingArea.left,
1044
- x2: v.value.drawingArea.left,
1045
- y1: v.value.drawingArea.top,
1046
- y2: v.value.drawingArea.bottom,
1047
- stroke: e.value.xyAxisStroke,
1048
- "stroke-width": e.value.xyAxisStrokeWidth,
1049
- "stroke-linecap": "round"
1050
- }, null, 8, ka),
1051
- w("line", {
1052
- x1: v.value.drawingArea.left,
1053
- x2: v.value.drawingArea.right,
1054
- y1: v.value.absoluteZero,
1055
- y2: v.value.absoluteZero,
1056
- stroke: e.value.xyAxisStroke,
1057
- "stroke-width": e.value.xyAxisStrokeWidth,
1058
- "stroke-linecap": "round"
1059
- }, null, 8, ba)
1060
- ])) : x("", !0),
1061
- e.value.xyShowScale ? (a(), l("g", Sa, [
1062
- (a(!0), l(g, null, A(v.value.yLabels, (t, i) => (a(), l(g, null, [
1063
- t.y <= v.value.drawingArea.bottom ? (a(), l("line", {
1064
- key: 0,
1065
- x1: t.x + 4,
1066
- x2: v.value.drawingArea.left,
1067
- y1: t.y,
1068
- y2: t.y,
1069
- stroke: e.value.xyAxisStroke,
1070
- "stroke-width": e.value.xyAxisStrokeWidth,
1071
- "stroke-linecap": "round"
1072
- }, null, 8, wa)) : x("", !0),
1073
- t.y <= v.value.drawingArea.bottom ? (a(), l("text", {
1074
- key: 1,
1075
- x: t.x,
1076
- y: t.y + e.value.xyLabelsYFontSize / 3,
1077
- "text-anchor": "end",
1078
- "font-size": e.value.xyLabelsYFontSize,
1079
- fill: e.value.color
1080
- }, E(m(H)(
1081
- e.value.formatter,
1082
- t.value,
1083
- m(M)({
1084
- p: e.value.valuePrefix,
1085
- v: t.value,
1086
- s: e.value.valueSuffix,
1087
- r: e.value.dataLabelRoundingValue
1088
- }),
1089
- { datapoint: t, seriesIndex: i }
1090
- )), 9, _a)) : x("", !0)
1091
- ], 64))), 256))
1092
- ])) : x("", !0),
1093
- e.value.xyShowScale && e.value.xyPeriods.length ? (a(), l("g", Aa, [
1094
- (a(!0), l(g, null, A(e.value.xyPeriods.slice(b.value.start, b.value.end), (t, i) => (a(), l("line", {
1095
- x1: v.value.drawingArea.left + v.value.slotSize * (i + 1) - v.value.slotSize / 2,
1096
- x2: v.value.drawingArea.left + v.value.slotSize * (i + 1) - v.value.slotSize / 2,
1097
- y1: v.value.drawingArea.bottom,
1098
- y2: v.value.drawingArea.bottom + 4,
1099
- stroke: e.value.xyAxisStroke,
1100
- "stroke-width": e.value.xyAxisStrokeWidth,
1101
- "stroke-linecap": "round"
1102
- }, null, 8, La))), 256)),
1103
- (a(!0), l(g, null, A(e.value.xyPeriods.slice(b.value.start, b.value.end), (t, i) => (a(), l("text", {
1104
- "font-size": e.value.xyLabelsXFontSize,
1105
- "text-anchor": e.value.xyPeriodLabelsRotation > 0 ? "start" : e.value.xyPeriodLabelsRotation < 0 ? "end" : "middle",
1106
- transform: `translate(${v.value.drawingArea.left + v.value.slotSize * (i + 1) - v.value.slotSize / 2}, ${v.value.drawingArea.bottom + e.value.xyLabelsXFontSize + 6}) rotate(${e.value.xyPeriodLabelsRotation})`,
1107
- fill: e.value.color
1108
- }, E(t), 9, za))), 256))
1109
- ])) : x("", !0),
1110
- w("g", $a, [
1111
- (a(!0), l(g, null, A(v.value.dataset, (t, i) => (a(), l(g, null, [
1112
- (a(!0), l(g, null, A(t.coordinates, (s, h) => (a(), l("rect", {
1113
- x: s.x,
1114
- width: s.width <= 0 ? 1e-5 : s.width,
1115
- height: s.height <= 0 ? 1e-5 : s.height,
1116
- y: s.y,
1117
- fill: t.color,
1118
- stroke: e.value.backgroundColor,
1119
- "stroke-width": e.value.barStrokeWidth,
1120
- "stroke-linecap": "round",
1121
- class: oe({ "vue-data-ui-bar-animated": e.value.barAnimated && s.value < 0 })
1122
- }, [
1123
- e.value.barAnimated && s.value > 0 && !m(ye) && !m(pe) ? (a(), l("animate", {
1124
- key: 0,
1125
- attributeName: "height",
1126
- from: 0,
1127
- to: s.height,
1128
- dur: "0.5s"
1129
- }, null, 8, Pa)) : x("", !0),
1130
- e.value.barAnimated && s.value > 0 && !m(ye) && !m(pe) ? (a(), l("animate", {
1131
- key: 1,
1132
- attributeName: "y",
1133
- from: v.value.absoluteZero,
1134
- to: v.value.absoluteZero - s.height,
1135
- dur: "0.5s"
1136
- }, null, 8, Ta)) : x("", !0)
1137
- ], 10, Ca))), 256))
1138
- ], 64))), 256))
1139
- ]),
1140
- e.value.showDataLabels ? (a(), l("g", Ea, [
1141
- (a(!0), l(g, null, A(v.value.dataset, (t, i) => (a(), l(g, null, [
1142
- (a(!0), l(g, null, A(t.coordinates, (s, h) => (a(), l("text", {
1143
- x: s.x + s.width / 2,
1144
- y: s.y - e.value.dataLabelFontSize / 2,
1145
- "text-anchor": "middle",
1146
- "font-size": e.value.dataLabelFontSize,
1147
- fill: t.color,
1148
- class: "quick-animation"
1149
- }, E(m(H)(
1150
- e.value.formatter,
1151
- s.value,
1152
- m(M)({
1153
- p: e.value.valuePrefix,
1154
- v: s.value,
1155
- s: e.value.valueSuffix,
1156
- r: e.value.dataLabelRoundingValue
1157
- }),
1158
- { datapoint: s, seriesIndex: h }
1159
- )), 9, Ia))), 256))
1160
- ], 64))), 256))
1161
- ])) : x("", !0),
1162
- w("g", Ra, [
1163
- (a(!0), l(g, null, A(v.value.extremes.maxSeries, (t, i) => (a(), l("rect", {
1164
- x: v.value.drawingArea.left + i * v.value.slotSize,
1165
- y: v.value.drawingArea.top,
1166
- height: v.value.drawingArea.height <= 0 ? 1e-5 : v.value.drawingArea.height,
1167
- width: v.value.slotSize <= 0 ? 1e-5 : v.value.slotSize,
1168
- fill: q.value === i ? e.value.xyHighlighterColor : "transparent",
1169
- style: F(`opacity:${e.value.xyHighlighterOpacity}`),
1170
- onMouseenter: (s) => v.value.useTooltip(i),
1171
- onMouseleave: c[2] || (c[2] = (s) => v.value.killTooltip()),
1172
- onClick: (s) => f("selectDatapoint", v.value.dataset.map((h) => ({
1173
- ...h,
1174
- value: h.values[i]
1175
- })))
1176
- }, null, 44, Fa))), 256))
1177
- ])
1178
- ], 64)) : x("", !0),
1179
- [L.LINE, L.BAR].includes(I.value) ? (a(), l("g", Oa, [
1180
- e.value.xAxisLabel && I.value === L.LINE ? (a(), l("g", Na, [
1181
- w("text", {
1182
- "font-size": e.value.axisLabelsFontSize,
1183
- fill: e.value.color,
1184
- "text-anchor": "middle",
1185
- x: d.value.drawingArea.left + d.value.drawingArea.width / 2,
1186
- y: k.value.height - e.value.axisLabelsFontSize / 3
1187
- }, E(e.value.xAxisLabel), 9, Ma)
1188
- ])) : x("", !0),
1189
- e.value.xAxisLabel && I.value === L.BAR ? (a(), l("g", Ba, [
1190
- w("text", {
1191
- "font-size": e.value.axisLabelsFontSize,
1192
- fill: e.value.color,
1193
- "text-anchor": "middle",
1194
- x: v.value.drawingArea.left + v.value.drawingArea.width / 2,
1195
- y: k.value.height - e.value.axisLabelsFontSize / 3
1196
- }, E(e.value.xAxisLabel), 9, Ua)
1197
- ])) : x("", !0),
1198
- e.value.yAxisLabel && I.value === L.LINE ? (a(), l("g", Da, [
1199
- w("text", {
1200
- "font-size": e.value.axisLabelsFontSize,
1201
- fill: e.value.color,
1202
- transform: `translate(${e.value.axisLabelsFontSize}, ${d.value.drawingArea.top + d.value.drawingArea.height / 2}) rotate(-90)`,
1203
- "text-anchor": "middle"
1204
- }, E(e.value.yAxisLabel), 9, Va)
1205
- ])) : x("", !0),
1206
- e.value.yAxisLabel && I.value === L.BAR ? (a(), l("g", qa, [
1207
- w("text", {
1208
- "font-size": e.value.axisLabelsFontSize,
1209
- fill: e.value.color,
1210
- transform: `translate(${e.value.axisLabelsFontSize}, ${v.value.drawingArea.top + v.value.drawingArea.height / 2}) rotate(-90)`,
1211
- "text-anchor": "middle"
1212
- }, E(e.value.yAxisLabel), 9, Wa)
1213
- ])) : x("", !0)
1214
- ])) : x("", !0)
1215
- ], 12, zt)),
1216
- r.$slots.watermark ? (a(), l("div", ja, [
1217
- D(r.$slots, "watermark", X(ce({ isPrinting: m(ye) || m(pe) })), void 0, !0)
1218
- ])) : x("", !0),
1219
- [L.BAR, L.LINE].includes(I.value) && e.value.zoomXy && _.value.maxSeriesLength > 1 ? (a(), l("div", {
1220
- key: `slicer_${_e.value}`,
1221
- ref_key: "quickChartSlicer",
1222
- ref: ie
1223
- }, [
1224
- (a(), Ue(pt, {
1225
- key: `slicer_${_e.value}`,
1226
- background: e.value.zoomColor,
1227
- borderColor: e.value.backgroundColor,
1228
- fontSize: e.value.zoomFontSize,
1229
- useResetSlot: e.value.zoomUseResetSlot,
1230
- labelLeft: e.value.xyPeriods[b.value.start] ? e.value.xyPeriods[b.value.start] : "",
1231
- labelRight: e.value.xyPeriods[b.value.end - 1] ? e.value.xyPeriods[b.value.end - 1] : "",
1232
- textColor: e.value.color,
1233
- inputColor: e.value.zoomColor,
1234
- selectColor: e.value.zoomHighlightColor,
1235
- max: _.value.maxSeriesLength,
1236
- min: 0,
1237
- valueStart: b.value.start,
1238
- valueEnd: b.value.end,
1239
- start: b.value.start,
1240
- "onUpdate:start": c[3] || (c[3] = (t) => b.value.start = t),
1241
- end: b.value.end,
1242
- "onUpdate:end": c[4] || (c[4] = (t) => b.value.end = t),
1243
- onReset: Ke
1244
- }, {
1245
- "reset-action": Q(({ reset: t }) => [
1246
- D(r.$slots, "reset-action", X(ce({ reset: t })), void 0, !0)
1247
- ]),
1248
- _: 3
1249
- }, 8, ["background", "borderColor", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "max", "valueStart", "valueEnd", "start", "end"]))
1250
- ])) : x("", !0),
1251
- e.value.showLegend ? (a(), l("div", {
1252
- key: 4,
1253
- ref_key: "quickChartLegend",
1254
- ref: te,
1255
- class: "vue-ui-quick-chart-legend",
1256
- style: F(`background:${e.value.backgroundColor};color:${e.value.color}`)
1257
- }, [
1258
- I.value === L.DONUT ? (a(!0), l(g, { key: 0 }, A($.value.legend, (t, i) => (a(), l("div", {
1259
- class: "vue-ui-quick-chart-legend-item",
1260
- onClick: (s) => {
1261
- Je(t, $.value.dataset), f("selectLegend", t);
1262
- },
1263
- style: F(`cursor: ${$.value.legend.length > 1 ? "pointer" : "default"}; opacity:${S.value.includes(t.id) ? "0.5" : "1"}`)
1264
- }, [
1265
- e.value.useCustomLegend ? D(r.$slots, "legend", X(ze({ key: 0 }, { legend: t })), void 0, !0) : (a(), l(g, { key: 1 }, [
1266
- he(we, {
1267
- name: e.value.legendIcon,
1268
- stroke: t.color,
1269
- size: e.value.legendIconSize
1270
- }, null, 8, ["name", "stroke", "size"]),
1271
- w("span", {
1272
- style: F(`font-size:${e.value.legendFontSize}px`)
1273
- }, E(t.name), 5),
1274
- w("span", {
1275
- style: F(`font-size:${e.value.legendFontSize}px;font-variant-numeric:tabular-nums`)
1276
- }, E(S.value.includes(t.id) ? "-" : m(H)(
1277
- e.value.formatter,
1278
- t.absoluteValue,
1279
- m(M)({
1280
- p: e.value.valuePrefix,
1281
- v: t.absoluteValue,
1282
- s: e.value.valueSuffix,
1283
- r: e.value.dataLabelRoundingValue
1284
- }),
1285
- { datapoint: t, seriesIndex: i }
1286
- )), 5),
1287
- S.value.includes(t.id) ? (a(), l("span", {
1288
- key: 0,
1289
- style: F(`font-size:${e.value.legendFontSize}px`)
1290
- }, " ( - % ) ", 4)) : be.value ? (a(), l("span", {
1291
- key: 1,
1292
- style: F(`font-size:${e.value.legendFontSize}px; font-variant-numeric: tabular-nums;`)
1293
- }, " ( - % ) ", 4)) : (a(), l("span", {
1294
- key: 2,
1295
- style: F(`font-size:${e.value.legendFontSize}px; font-variant-numeric: tabular-nums;`)
1296
- }, " (" + E(m(M)({
1297
- v: t.value / $.value.total * 100,
1298
- s: "%",
1299
- r: e.value.dataLabelRoundingPercentage
1300
- })) + ") ", 5))
1301
- ], 64))
1302
- ], 12, Ga))), 256)) : x("", !0),
1303
- I.value === L.LINE ? (a(!0), l(g, { key: 1 }, A(d.value.legend, (t, i) => (a(), l("div", {
1304
- class: "vue-ui-quick-chart-legend-item",
1305
- onClick: (s) => {
1306
- Oe(t.id, d.value.legend.length - 1), f("selectLegend", t);
1307
- },
1308
- style: F(`cursor: ${d.value.legend.length > 1 ? "pointer" : "default"}; opacity:${S.value.includes(t.id) ? "0.5" : "1"}`)
1309
- }, [
1310
- e.value.useCustomLegend ? D(r.$slots, "legend", X(ze({ key: 0 }, { legend: t })), void 0, !0) : (a(), l(g, { key: 1 }, [
1311
- he(we, {
1312
- name: e.value.legendIcon,
1313
- stroke: t.color,
1314
- size: e.value.legendIconSize
1315
- }, null, 8, ["name", "stroke", "size"]),
1316
- w("span", {
1317
- style: F(`font-size:${e.value.legendFontSize}px`)
1318
- }, E(t.name), 5)
1319
- ], 64))
1320
- ], 12, Ha))), 256)) : x("", !0),
1321
- I.value === L.BAR ? (a(!0), l(g, { key: 2 }, A(v.value.legend, (t, i) => (a(), l("div", {
1322
- class: "vue-ui-quick-chart-legend-item",
1323
- onClick: (s) => {
1324
- Oe(t.id, v.value.legend.length - 1), f("selectLegend", t);
1325
- },
1326
- style: F(`cursor: ${v.value.legend.length > 1 ? "pointer" : "default"}; opacity:${S.value.includes(t.id) ? "0.5" : "1"}`)
1327
- }, [
1328
- e.value.useCustomLegend ? D(r.$slots, "legend", X(ze({ key: 0 }, { legend: t })), void 0, !0) : (a(), l(g, { key: 1 }, [
1329
- he(we, {
1330
- name: e.value.legendIcon,
1331
- stroke: t.color,
1332
- size: e.value.legendIconSize
1333
- }, null, 8, ["name", "stroke", "size"]),
1334
- w("span", {
1335
- style: F(`font-size:${e.value.legendFontSize}px`)
1336
- }, E(t.name), 5)
1337
- ], 64))
1338
- ], 12, Xa))), 256)) : x("", !0)
1339
- ], 4)) : x("", !0),
1340
- he(gt, {
1341
- show: me.value.showTooltip && j.value,
1342
- backgroundColor: e.value.backgroundColor,
1343
- color: e.value.color,
1344
- borderRadius: e.value.tooltipBorderRadius,
1345
- borderColor: e.value.tooltipBorderColor,
1346
- borderWidth: e.value.tooltipBorderWidth,
1347
- fontSize: e.value.tooltipFontSize,
1348
- backgroundOpacity: e.value.tooltipBackgroundOpacity,
1349
- position: e.value.tooltipPosition,
1350
- offsetY: e.value.tooltipOffsetY,
1351
- parent: W.value,
1352
- content: Y.value,
1353
- isCustom: m(Se)(e.value.tooltipCustomFormat)
1354
- }, {
1355
- "tooltip-before": Q(() => [
1356
- D(r.$slots, "tooltip-before", X(ce({ ...ne.value })), void 0, !0)
1357
- ]),
1358
- "tooltip-after": Q(() => [
1359
- D(r.$slots, "tooltip-after", X(ce({ ...ne.value })), void 0, !0)
1360
- ]),
1361
- _: 3
1362
- }, 8, ["show", "backgroundColor", "color", "borderRadius", "borderColor", "borderWidth", "fontSize", "backgroundOpacity", "position", "offsetY", "parent", "content", "isCustom"])
1363
- ], 14, Lt)) : (a(), l("div", Ya, [
1364
- he(we, {
1365
- name: "circleCancel",
1366
- stroke: "red"
1367
- }),
1368
- Za
1369
- ]));
1370
- }
1371
- }, nl = /* @__PURE__ */ mt(Ja, [["__scopeId", "data-v-8c2953ad"]]);
1372
- export {
1373
- nl as default
1374
- };