vue-data-ui 3.0.0-next.6 → 3.0.0-next.60

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 (125) hide show
  1. package/dist/{Arrow-Ul64M9UV.js → Arrow-Dt0ZxTK2.js} +1 -1
  2. package/dist/{BaseDraggableDialog-Q2ajCztp.js → BaseDraggableDialog-Bl-2tw3H.js} +2 -2
  3. package/dist/{BaseIcon-BKR7AGeP.js → BaseIcon-C3ljqn8J.js} +1 -1
  4. package/dist/{ColorPicker-BagIs8-K.js → ColorPicker-0d0whOB3.js} +2 -2
  5. package/dist/{DataTable-CDwApkI_.js → DataTable-C_tJHvMd.js} +2 -2
  6. package/dist/{Legend-BSLj7tYc.js → Legend-VD0VB7l7.js} +2 -2
  7. package/dist/{NonSvgPenAndPaper-DjJe5fXu.js → NonSvgPenAndPaper-DQsHc_AG.js} +3 -3
  8. package/dist/{PackageVersion-BsKpz6KS.js → PackageVersion-5S8ajCUS.js} +1 -1
  9. package/dist/{PenAndPaper-BYRk8xrS.js → PenAndPaper-D6wazxlT.js} +3 -3
  10. package/dist/{Shape-DK7zYTKa.js → Shape-DDSX29LV.js} +43 -37
  11. package/dist/Slicer-D3SbIarX.js +602 -0
  12. package/dist/{SparkTooltip-Dy2sVTb_.js → SparkTooltip-BCdP3VDl.js} +1 -1
  13. package/dist/{Title-Cednydse.js → Title-DEKAfzRX.js} +1 -1
  14. package/dist/{Tooltip-DJlwW-XP.js → Tooltip-DJlC-n25.js} +23 -19
  15. package/dist/{UserOptions-DxIzWere.js → UserOptions-D2G7II3G.js} +2 -2
  16. package/dist/{dom-to-png-lZcM-YfK.js → dom-to-png-Y0tASTWQ.js} +1 -1
  17. package/dist/{img-DqlIAUF6.js → img-ChLGv8nO.js} +1 -1
  18. package/dist/{index-BQcLOx39.js → index-BLtc1AIS.js} +1707 -1131
  19. package/dist/{pdf-CjIXhsyg.js → pdf-DNiq-xsc.js} +1 -1
  20. package/dist/style.css +1 -1
  21. package/dist/types/vue-data-ui.d.cts +481 -21
  22. package/dist/types/vue-data-ui.d.ts +481 -21
  23. package/dist/useAutoSizeLabelsInsideViewbox-BJDcwsoB.js +41 -0
  24. package/dist/useNestedProp-DExlTpuj.js +13 -0
  25. package/dist/usePanZoom-BVca3eMk.js +122 -0
  26. package/dist/{usePrinter-BRY5saEA.js → usePrinter-fqbzwh0l.js} +2 -2
  27. package/dist/useTimeLabelCollider-CIsgDrl9.js +78 -0
  28. package/dist/{useTimeLabels-Mrr0jrpL.js → useTimeLabels-DkzmKfZn.js} +211 -152
  29. package/dist/{vue-data-ui-CWRlSsiN.js → vue-data-ui-B8bRwUEL.js} +105 -100
  30. package/dist/vue-data-ui.js +23 -22
  31. package/dist/vue-ui-3d-bar-Dddx5kJW.js +1323 -0
  32. package/dist/{vue-ui-accordion-Df-5BRRg.js → vue-ui-accordion-EMAj3Ykx.js} +3 -3
  33. package/dist/vue-ui-age-pyramid-CMzKOGfv.js +834 -0
  34. package/dist/{vue-ui-annotator-BxC5dcIv.js → vue-ui-annotator-BQxXVdZW.js} +2 -2
  35. package/dist/vue-ui-bullet-DIie_6-T.js +571 -0
  36. package/dist/vue-ui-candlestick-DU796IGE.js +999 -0
  37. package/dist/{vue-ui-carousel-table-NTDzafWQ.js → vue-ui-carousel-table-xDItqzuw.js} +29 -29
  38. package/dist/{vue-ui-chestnut-k21Qqjjq.js → vue-ui-chestnut-DnQ494SU.js} +5 -5
  39. package/dist/{vue-ui-chord-BVoA6nfI.js → vue-ui-chord-DTs9gQ-R.js} +8 -8
  40. package/dist/{vue-ui-circle-pack-CEBgImRX.js → vue-ui-circle-pack-D73gxFJW.js} +24 -24
  41. package/dist/{vue-ui-cursor-BQcz8xw2.js → vue-ui-cursor-CNXTFeSs.js} +2 -2
  42. package/dist/{vue-ui-dashboard-CyzEpJoI.js → vue-ui-dashboard-Duph5Yta.js} +62 -62
  43. package/dist/{vue-ui-digits-Dafw1UsT.js → vue-ui-digits-D7qOSGZ-.js} +2 -2
  44. package/dist/{vue-ui-donut-DKfux8XT.js → vue-ui-donut-EfxITdHJ.js} +320 -308
  45. package/dist/vue-ui-donut-evolution-H6nfW_kx.js +1075 -0
  46. package/dist/vue-ui-dumbbell-DCUR8kl_.js +1119 -0
  47. package/dist/vue-ui-flow-DUENWmgc.js +841 -0
  48. package/dist/{vue-ui-funnel-CuN8HWwP.js → vue-ui-funnel-BSGUxWhW.js} +16 -16
  49. package/dist/{vue-ui-galaxy-BHCLFlmy.js → vue-ui-galaxy-D8PBQfbb.js} +60 -58
  50. package/dist/vue-ui-gauge-C8v8wKJO.js +791 -0
  51. package/dist/{vue-ui-gizmo-DHEEfdp9.js → vue-ui-gizmo-DmguslRh.js} +3 -3
  52. package/dist/vue-ui-heatmap-BM5Gfdzz.js +1078 -0
  53. package/dist/vue-ui-history-plot-CF6SlpwK.js +1073 -0
  54. package/dist/{vue-ui-kpi-C4i2w_Yd.js → vue-ui-kpi-BCyX-Zu-.js} +7 -7
  55. package/dist/{vue-ui-mini-loader-BeetGv_m.js → vue-ui-mini-loader-ByMff4PK.js} +2 -2
  56. package/dist/{vue-ui-molecule-F_gDXjJr.js → vue-ui-molecule-Cxnf2xDy.js} +53 -51
  57. package/dist/{vue-ui-mood-radar-BJMOEqlu.js → vue-ui-mood-radar-DEfJWXE7.js} +15 -15
  58. package/dist/vue-ui-nested-donuts-Bt7Pw9l0.js +1286 -0
  59. package/dist/vue-ui-onion-Bk3KL1Nk.js +776 -0
  60. package/dist/vue-ui-parallel-coordinate-plot-BpKRlOYy.js +915 -0
  61. package/dist/{vue-ui-quadrant-DTyRC1_v.js → vue-ui-quadrant-D1dgOAp2.js} +59 -57
  62. package/dist/vue-ui-quick-chart-_I6OrH-J.js +1761 -0
  63. package/dist/{vue-ui-radar-De2iznwo.js → vue-ui-radar-BWnhxayf.js} +30 -28
  64. package/dist/{vue-ui-rating-CarXXyD-.js → vue-ui-rating-I08lL1Nb.js} +2 -2
  65. package/dist/{vue-ui-relation-circle-CKkK9D4E.js → vue-ui-relation-circle-CMF5FSha.js} +6 -6
  66. package/dist/vue-ui-ridgeline-prYrXNYF.js +1153 -0
  67. package/dist/vue-ui-rings-DmbUIw9S.js +728 -0
  68. package/dist/vue-ui-scatter-srTVLcUK.js +1178 -0
  69. package/dist/{vue-ui-skeleton-C7maR60-.js → vue-ui-skeleton-FanSnKr8.js} +3 -3
  70. package/dist/{vue-ui-smiley-DzCCn5Oc.js → vue-ui-smiley-CWA0Y6wM.js} +26 -26
  71. package/dist/{vue-ui-spark-trend-Db-Fnp8C.js → vue-ui-spark-trend-EiEzMoPj.js} +3 -3
  72. package/dist/vue-ui-sparkbar-CCe0U_o0.js +351 -0
  73. package/dist/{vue-ui-sparkgauge-DAQ4zozy.js → vue-ui-sparkgauge-Cdcirik_.js} +3 -3
  74. package/dist/{vue-ui-sparkhistogram-CMEaO0CW.js → vue-ui-sparkhistogram-CEj9qz9m.js} +4 -4
  75. package/dist/vue-ui-sparkline-B2-YztKx.js +489 -0
  76. package/dist/vue-ui-sparkstackbar-BGMtc_HC.js +421 -0
  77. package/dist/vue-ui-stackbar-DrKaioRS.js +1370 -0
  78. package/dist/vue-ui-strip-plot-C4qWoDEh.js +915 -0
  79. package/dist/{vue-ui-table-Dck8Pyg9.js → vue-ui-table-CXqyTj_Z.js} +11 -11
  80. package/dist/{vue-ui-table-heatmap-DknIGf9_.js → vue-ui-table-heatmap-BZTn3qnM.js} +5 -5
  81. package/dist/{vue-ui-table-sparkline-G4HAzUt6.js → vue-ui-table-sparkline-CIBdN_KF.js} +14 -14
  82. package/dist/vue-ui-thermometer-DPIpWKUI.js +541 -0
  83. package/dist/{vue-ui-timer-Dmr-HCSc.js → vue-ui-timer-Cha-Gb1x.js} +5 -5
  84. package/dist/vue-ui-tiremarks-B4SjQyS7.js +406 -0
  85. package/dist/vue-ui-treemap-1twI_ag-.js +1035 -0
  86. package/dist/{vue-ui-vertical-bar--QFtoFje.js → vue-ui-vertical-bar-C31Jqkbw.js} +318 -302
  87. package/dist/vue-ui-waffle-DkZykFPK.js +910 -0
  88. package/dist/vue-ui-wheel-CYOrBHBD.js +379 -0
  89. package/dist/vue-ui-word-cloud-Clyg0CRZ.js +765 -0
  90. package/dist/{vue-ui-world-BcK_brDq.js → vue-ui-world-BYgMbS-e.js} +11 -9
  91. package/dist/vue-ui-xy-BMszd4wZ.js +3760 -0
  92. package/dist/{vue-ui-xy-canvas--88oKdGN.js → vue-ui-xy-canvas-DwXvZ311.js} +265 -264
  93. package/package.json +1 -1
  94. package/dist/Slicer-B_Hb6qSk.js +0 -577
  95. package/dist/useNestedProp-DefBVltl.js +0 -13
  96. package/dist/usePanZoom-BQMvRXEQ.js +0 -115
  97. package/dist/vue-ui-3d-bar-CJMZqDo1.js +0 -1227
  98. package/dist/vue-ui-age-pyramid-B6WAMtPk.js +0 -746
  99. package/dist/vue-ui-bullet-NmtltFbU.js +0 -513
  100. package/dist/vue-ui-candlestick-BzqQtynP.js +0 -873
  101. package/dist/vue-ui-donut-evolution-D7cNk_6l.js +0 -903
  102. package/dist/vue-ui-dumbbell--H80zebk.js +0 -753
  103. package/dist/vue-ui-flow-lk_HU5NB.js +0 -765
  104. package/dist/vue-ui-gauge-DWlCh2_B.js +0 -738
  105. package/dist/vue-ui-heatmap-BK6BNOY_.js +0 -877
  106. package/dist/vue-ui-history-plot-CGF6lE-7.js +0 -924
  107. package/dist/vue-ui-nested-donuts-BX0Z0rb1.js +0 -1177
  108. package/dist/vue-ui-onion-BhjUET_W.js +0 -701
  109. package/dist/vue-ui-parallel-coordinate-plot-n7QPVLrW.js +0 -807
  110. package/dist/vue-ui-quick-chart-5xX-yBIY.js +0 -1612
  111. package/dist/vue-ui-ridgeline-DQ8RQf3E.js +0 -969
  112. package/dist/vue-ui-rings-Cze6OsmO.js +0 -685
  113. package/dist/vue-ui-scatter-CwI3_Dn7.js +0 -1045
  114. package/dist/vue-ui-sparkbar-C6wsNMMO.js +0 -301
  115. package/dist/vue-ui-sparkline-R7pfxRWN.js +0 -459
  116. package/dist/vue-ui-sparkstackbar-DV_XqJQ2.js +0 -381
  117. package/dist/vue-ui-stackbar-gReSujA_.js +0 -1207
  118. package/dist/vue-ui-strip-plot-8fsm3nn2.js +0 -761
  119. package/dist/vue-ui-thermometer-BIkXa4hY.js +0 -495
  120. package/dist/vue-ui-tiremarks-YWbRk0dm.js +0 -358
  121. package/dist/vue-ui-treemap-D2OnG3Fh.js +0 -965
  122. package/dist/vue-ui-waffle-BdaCXuWc.js +0 -863
  123. package/dist/vue-ui-wheel-Bw3XSa8N.js +0 -352
  124. package/dist/vue-ui-word-cloud-BH8UZH_J.js +0 -659
  125. package/dist/vue-ui-xy-Be--zwe9.js +0 -2980
@@ -0,0 +1,1075 @@
1
+ import { defineAsyncComponent as V, ref as c, shallowRef as vt, computed as f, onMounted as jt, toRefs as qt, nextTick as Ce, watch as Le, watchEffect as Jt, onBeforeUnmount as Kt, createElementBlock as n, openBlock as u, unref as i, normalizeStyle as J, normalizeClass as N, createBlock as T, createCommentVNode as v, createElementVNode as p, createSlots as Qt, withCtx as _, renderSlot as S, normalizeProps as K, guardReactiveProps as Q, createVNode as Zt, Fragment as z, renderList as $, toDisplayString as m, createTextVNode as dt } from "vue";
2
+ import { u as el, c as ht, o as yt, f as se, g as tl, t as ll, a as al, p as ne, b as ol, C as ft, d as ul, e as _e, G as sl, D as gt, m as Ae, X as nl, s as Z, H as rl, k as Se, i as re, I as il, n as cl, q as vl, r as mt, v as dl, w as hl, J as bt, K as yl } from "./index-BLtc1AIS.js";
3
+ import { u as fl } from "./useChartAccessibility-9icAAmYg.js";
4
+ import { u as xt } from "./useNestedProp-DExlTpuj.js";
5
+ import { u as gl } from "./usePrinter-fqbzwh0l.js";
6
+ import { u as ml } from "./useTimeLabels-DkzmKfZn.js";
7
+ import { u as bl } from "./useUserOptionState-BIvW1Kz7.js";
8
+ import { u as xl } from "./useTimeLabelCollider-CIsgDrl9.js";
9
+ import pl from "./Legend-VD0VB7l7.js";
10
+ import { S as kl } from "./Slicer-D3SbIarX.js";
11
+ import wl from "./Title-DEKAfzRX.js";
12
+ import Cl from "./img-ChLGv8nO.js";
13
+ import { t as pt, u as Ll } from "./useResponsive-DfdjqQps.js";
14
+ import { u as _l, B as Al } from "./useLoading-Bt5Doa8m.js";
15
+ import { _ as Sl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
16
+ const zl = ["id"], $l = ["xmlns", "viewBox"], Il = ["x", "y", "width", "height"], Nl = ["id"], Tl = ["stop-color"], Ol = ["stop-color"], Pl = ["id"], Dl = ["stop-color"], Fl = ["stop-color"], El = ["stop-color"], Rl = { key: 1 }, Vl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Ml = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Hl = { key: 0 }, Bl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Ul = ["font-size", "fill", "transform"], Xl = ["x", "y", "font-size", "fill"], Gl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Wl = ["x", "y", "font-size", "fill", "font-weight"], Yl = { key: 0 }, jl = ["text-anchor", "font-size", "fill", "transform"], ql = ["text-anchor", "font-size", "fill", "transform", "innerHTML"], Jl = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], Kl = { key: 1 }, Ql = ["cx", "cy", "r", "fill"], Zl = { key: 0 }, ea = { key: 0 }, ta = ["d", "stroke"], la = ["text-anchor", "x", "y", "fill"], aa = ["cx", "cy", "r", "fill"], oa = { key: 0 }, ua = ["cx", "cy", "fill"], sa = { key: 1 }, na = ["d", "fill", "stroke"], ra = { key: 2 }, ia = ["d", "fill", "stroke"], ca = ["x", "y", "font-size", "fill"], va = ["x", "y", "width", "height", "fill"], da = ["x", "y", "width", "height", "onMouseenter", "onMouseleave", "onClick"], ha = {
17
+ key: 4,
18
+ class: "vue-data-ui-watermark"
19
+ }, ya = ["onClick"], fa = { key: 0 }, ga = { key: 1 }, ma = {
20
+ __name: "vue-ui-donut-evolution",
21
+ props: {
22
+ config: {
23
+ type: Object,
24
+ default() {
25
+ return {};
26
+ }
27
+ },
28
+ dataset: {
29
+ type: Array,
30
+ default() {
31
+ return [];
32
+ }
33
+ }
34
+ },
35
+ emits: ["selectLegend"],
36
+ setup(kt, { expose: wt, emit: Ct }) {
37
+ const Lt = V(() => import("./vue-ui-accordion-EMAj3Ykx.js")), _t = V(() => import("./BaseDraggableDialog-Bl-2tw3H.js")), At = V(() => import("./DataTable-C_tJHvMd.js")), St = V(() => import("./PackageVersion-5S8ajCUS.js")), zt = V(() => import("./PenAndPaper-D6wazxlT.js")), $t = V(() => import("./UserOptions-D2G7II3G.js")), It = V(() => import("./vue-ui-donut-EfxITdHJ.js")), { vue_ui_donut_evolution: Nt } = el(), b = kt, M = c(ht()), w = c([]), g = c(null), ee = c(null), ie = c(!1), E = c(null), P = c(null), Tt = c(null), ze = c(0), $e = c(0), Ie = c(0), Ne = c(0), Te = c(0), ce = c(null), te = c(null), ve = c(null), de = c(null), Oe = c(null), Pe = c(null), De = c(null), Fe = c(null), Ee = c(null), he = c(!1), Y = vt(null), le = vt(null), Re = c(null), Ve = Ct, Me = f(() => !!b.dataset && b.dataset.length);
38
+ jt(() => {
39
+ He();
40
+ });
41
+ const ae = f(() => !!e.value.debug);
42
+ function He() {
43
+ if (yt(b.dataset) ? (se({
44
+ componentName: "VueUiDonutEvolution",
45
+ type: "dataset",
46
+ debug: ae.value
47
+ }), oe.value = !0) : b.dataset.length && b.dataset.forEach((t, a) => {
48
+ tl({
49
+ datasetObject: t,
50
+ requiredAttributes: ["name", "values"]
51
+ }).forEach((l) => {
52
+ se({
53
+ componentName: "VueUiDonutEvolution",
54
+ type: "datasetSerieAttribute",
55
+ property: l,
56
+ index: a,
57
+ debug: ae.value
58
+ }), oe.value = !0;
59
+ });
60
+ }), yt(b.dataset) || (oe.value = e.value.loading), setTimeout(() => {
61
+ he.value = !0;
62
+ }, 10), fe(), e.value.responsive) {
63
+ const t = pt(() => {
64
+ he.value = !1;
65
+ const { width: a, height: l } = Ll({
66
+ chart: P.value,
67
+ title: e.value.style.chart.title.text ? Oe.value : null,
68
+ legend: e.value.style.chart.legend.show ? Pe.value : null,
69
+ slicer: e.value.style.chart.zoom.show && Ue.value > 1 ? Ee.value : null,
70
+ source: De.value
71
+ });
72
+ requestAnimationFrame(() => {
73
+ H.value.width = a, H.value.height = l - 12, clearTimeout(Re.value), Re.value = setTimeout(() => {
74
+ he.value = !0;
75
+ }, 10);
76
+ });
77
+ });
78
+ Y.value && (le.value && Y.value.unobserve(le.value), Y.value.disconnect()), Y.value = new ResizeObserver(t), le.value = P.value.parentNode, Y.value.observe(le.value);
79
+ }
80
+ }
81
+ const e = c(me()), { loading: Be, FINAL_DATASET: ye, manualLoading: oe } = _l({
82
+ ...qt(b),
83
+ FINAL_CONFIG: e,
84
+ prepareConfig: me,
85
+ callback: () => {
86
+ Promise.resolve().then(async () => {
87
+ await fe();
88
+ });
89
+ },
90
+ skeletonDataset: [
91
+ {
92
+ name: "",
93
+ values: [1, 2, 3, 5, 8, 13],
94
+ color: "#AAAAAA"
95
+ },
96
+ {
97
+ name: "",
98
+ values: [1, 2, 3, 5, 8, 13],
99
+ color: "#BABABA"
100
+ },
101
+ {
102
+ name: "",
103
+ values: [1, 2, 3, 5, 8, 13],
104
+ color: "#CACACA"
105
+ }
106
+ ],
107
+ skeletonConfig: ll({
108
+ defaultConfig: e.value,
109
+ userConfig: {
110
+ useCssAnimation: !1,
111
+ table: { show: !1 },
112
+ userOptions: { show: !1 },
113
+ style: {
114
+ chart: {
115
+ backgroundColor: "#99999930",
116
+ layout: {
117
+ dataLabels: { show: !1 },
118
+ grid: {
119
+ stroke: "#6A6A6A",
120
+ axis: {
121
+ yLabel: "",
122
+ xLabel: ""
123
+ },
124
+ yAxis: {
125
+ dataLabels: { show: !1 }
126
+ },
127
+ xAxis: {
128
+ dataLabels: { show: !1 }
129
+ }
130
+ },
131
+ line: {
132
+ stroke: "#CACACA60"
133
+ }
134
+ },
135
+ legend: {
136
+ backgroundColor: "transparent",
137
+ showValue: !1,
138
+ showPercentage: !1
139
+ },
140
+ zoom: {
141
+ show: !1,
142
+ startIndex: null,
143
+ endIndex: null
144
+ }
145
+ }
146
+ }
147
+ }
148
+ })
149
+ }), H = c({
150
+ width: e.value.style.chart.layout.width,
151
+ height: e.value.style.chart.layout.height
152
+ }), Ue = f(() => Math.max(...ye.value.map((t) => t.values.length))), h = c({
153
+ start: 0,
154
+ end: Ue.value
155
+ });
156
+ function Xe() {
157
+ fe();
158
+ }
159
+ async function fe() {
160
+ await Ce(), await Ce();
161
+ const { startIndex: t, endIndex: a } = e.value.style.chart.zoom, l = Fe.value;
162
+ (t != null || a != null) && l ? (t != null && l.setStartValue(t), a != null && l.setEndValue(Ot(a + 1))) : (h.value = {
163
+ start: 0,
164
+ end: D.value
165
+ }, $e.value += 1);
166
+ }
167
+ function Ot(t) {
168
+ const a = D.value;
169
+ return t > a ? a : t < 0 || e.value.style.chart.zoom.startIndex !== null && t < e.value.style.chart.zoom.startIndex ? e.value.style.chart.zoom.startIndex !== null ? e.value.style.chart.zoom.startIndex + 1 : 1 : t;
170
+ }
171
+ const { userOptionsVisible: ge, setUserOptionsVisibility: Ge, keepUserOptionState: We } = bl({ config: e.value }), { svgRef: Ye } = fl({ config: e.value.style.chart.title });
172
+ function me() {
173
+ const t = xt({
174
+ userConfig: b.config,
175
+ defaultConfig: Nt
176
+ });
177
+ let a = {};
178
+ return t.theme ? a = {
179
+ ...xt({
180
+ userConfig: ol.vue_ui_donut_evolution[t.theme] || b.config,
181
+ defaultConfig: t
182
+ }),
183
+ customPalette: al[t.theme] || ne
184
+ } : a = t, b.config && ft(b.config, "style.chart.zoom.startIndex") ? a.style.chart.zoom.startIndex = b.config.style.chart.zoom.startIndex : a.style.chart.zoom.startIndex = null, b.config && ft(b.config, "style.chart.zoom.endIndex") ? a.style.chart.zoom.endIndex = b.config.style.chart.zoom.endIndex : a.style.chart.zoom.endIndex = null, a;
185
+ }
186
+ Le(() => b.config, (t) => {
187
+ Be.value || (e.value = me()), ge.value = !e.value.userOptions.showOnChartHover, He(), Ie.value += 1, Ne.value += 1, Te.value += 1, B.value.showTable = e.value.table.show;
188
+ }, { deep: !0 }), Le(() => b.dataset, (t) => {
189
+ Array.isArray(t) && t.length > 0 && (oe.value = !1), Xe();
190
+ }, { deep: !0 });
191
+ const { isPrinting: je, isImaging: qe, generatePdf: Je, generateImage: Ke } = gl({
192
+ elementId: M.value,
193
+ fileName: e.value.style.chart.title.text || "vue-ui-donut-evolution",
194
+ options: e.value.userOptions.print
195
+ }), Pt = f(() => e.value.userOptions.show && !e.value.style.chart.title.text), Dt = f(() => ul(e.value.customPalette)), B = c({
196
+ showTable: e.value.table.show
197
+ });
198
+ Le(e, () => {
199
+ B.value = {
200
+ showTable: e.value.table.show
201
+ };
202
+ }, { immediate: !0 });
203
+ const R = f(() => ({
204
+ top: e.value.style.chart.layout.padding.top,
205
+ right: e.value.style.chart.layout.padding.right,
206
+ bottom: e.value.style.chart.layout.padding.bottom,
207
+ left: e.value.style.chart.layout.padding.left
208
+ }));
209
+ function Ft() {
210
+ let t = 0;
211
+ ce.value && (t = Array.from(ce.value.querySelectorAll("text")).reduce((o, y) => {
212
+ const d = y.getComputedTextLength();
213
+ return (d > o ? d : o) + e.value.style.chart.layout.grid.axis.yLabelOffsetX;
214
+ }, 0));
215
+ const a = de.value ? de.value.getBoundingClientRect().width + e.value.style.chart.layout.grid.axis.yLabelOffsetX + e.value.style.chart.layout.grid.axis.fontSize : 0;
216
+ return t + a + 5;
217
+ }
218
+ const be = c(0), Et = pt((t) => {
219
+ be.value = t;
220
+ }, 100);
221
+ Jt((t) => {
222
+ const a = te.value;
223
+ if (!a) return;
224
+ const l = new ResizeObserver((s) => {
225
+ Et(s[0].contentRect.height);
226
+ });
227
+ l.observe(a), t(() => l.disconnect());
228
+ }), Kt(() => {
229
+ be.value = 0;
230
+ });
231
+ const Qe = f(() => {
232
+ let t = 0;
233
+ ve.value && (t = ve.value.getBBox().height);
234
+ let a = 0;
235
+ return te.value && (a = be.value), t + a + e.value.style.chart.layout.grid.axis.fontSize + e.value.style.chart.layout.grid.xAxis.dataLabels.offsetY;
236
+ }), r = f(() => {
237
+ const t = Ft(), a = e.value.style.chart.layout.dataLabels.fontSize * 3, l = H.value.width, s = H.value.height, o = R.value.left + t, y = l - R.value.right, d = l - o - R.value.right, x = s - R.value.top - R.value.bottom - a - Qe.value, W = R.value.top + a, F = s - R.value.bottom - Qe.value;
238
+ return {
239
+ top: W,
240
+ left: o,
241
+ right: y,
242
+ bottom: F,
243
+ absoluteHeight: s,
244
+ absoluteWidth: l,
245
+ centerX: o + Math.max(10, d) / 2,
246
+ centerY: W + Math.max(10, x) / 2,
247
+ width: Math.max(10, d),
248
+ height: Math.max(10, x)
249
+ };
250
+ }), O = f(() => (ye.value.forEach((t, a) => {
251
+ [null, void 0].includes(t.name) && se({
252
+ componentName: "VueUiDonutEvolution",
253
+ type: "datasetSerieAttribute",
254
+ property: "name",
255
+ index: a,
256
+ debug: ae.value
257
+ }), [null, void 0].includes(t.values) && se({
258
+ componentName: "VueUiDonutEvolution",
259
+ type: "datasetSerieAttribute",
260
+ property: "values",
261
+ index: a,
262
+ debug: ae.value
263
+ });
264
+ }), ye.value.map((t, a) => ({
265
+ ...t,
266
+ values: sl(t.values),
267
+ color: _e(t.color) || Dt.value[a] || ne[a] || ne[a % ne.length],
268
+ length: (t.values || []).length,
269
+ uid: ht()
270
+ })))), j = f(() => O.value.filter((t) => !w.value.includes(t.uid)).map((t) => ({
271
+ ...t,
272
+ values: t.values.filter((a, l) => l >= h.value.start && l <= h.value.end)
273
+ }))), D = f(() => Math.max(...j.value.map((t) => t.length))), C = f(() => ml({
274
+ values: e.value.style.chart.layout.grid.xAxis.dataLabels.values,
275
+ maxDatapoints: D.value,
276
+ formatter: e.value.style.chart.layout.grid.xAxis.dataLabels.datetimeFormatter,
277
+ start: h.value.start,
278
+ end: h.value.end
279
+ })), k = f(() => r.value.width / (h.value.end - h.value.start)), L = f(() => {
280
+ const t = [];
281
+ for (let o = 0; o < h.value.end - h.value.start; o += 1) {
282
+ const y = j.value.map((I) => I.values[o] ?? null), d = y.filter((I) => [void 0, null].includes(I)).length === y.length, x = y.reduce((I, A) => I + A, 0), W = y.map((I) => I / x), F = r.value.left + k.value * o + k.value / 2;
283
+ t.push({
284
+ index: o,
285
+ percentages: W,
286
+ subtotal: d || x < 0 ? null : x,
287
+ values: y,
288
+ x: F
289
+ });
290
+ }
291
+ const a = 0, l = Math.max(...t.map((o) => o.subtotal)), s = t.length === 1 ? l * 2 : l;
292
+ return t.map((o, y) => {
293
+ const d = Math.min(r.value.width / 24, k.value / 2 * 0.7), x = d > r.value.width / 16 ? r.value.width / 16 : d, W = g.value === o.index ? r.value.width / 16 : x, F = t.length > 4 ? d * 2 : d * 2 > k.value / 2 * 0.7 ? k.value / 2 * 0.7 : d * 2, I = r.value.bottom - r.value.height * o.subtotal / gt(a, s, e.value.style.chart.layout.grid.yAxis.dataLabels.steps).max;
294
+ return {
295
+ ...o,
296
+ y: I,
297
+ radius: x,
298
+ activeRadius: W,
299
+ hoverRadius: F,
300
+ donut: Ae({
301
+ series: j.value.map((A, ct) => ({
302
+ color: A.color,
303
+ name: A.name,
304
+ value: A.values[y] ?? 0
305
+ }))
306
+ }, o.x, I, x, x, 1.99999, 2, 1, 360, 105.25, x / 2),
307
+ donutHover: Ae({
308
+ series: j.value.map((A, ct) => ({
309
+ color: A.color,
310
+ name: A.name,
311
+ value: A.values[y] ?? 0
312
+ }))
313
+ }, o.x, I, F, F, 1.99999, 2, 1, 360, 105.25, F / 2),
314
+ donutFocus: Ae({
315
+ series: j.value.map((A, ct) => ({
316
+ color: A.color,
317
+ name: A.name,
318
+ value: A.values[y] ?? 0
319
+ }))
320
+ }, r.value.centerX, r.value.centerY, r.value.height / 3.6, r.value.height / 3.6, 1.99999, 2, 1, 360, 105.25, r.value.height / 6)
321
+ };
322
+ });
323
+ });
324
+ function Ze(t, a, l) {
325
+ return Se(
326
+ e.value.style.chart.layout.dataLabels.formatter,
327
+ t,
328
+ re({
329
+ p: e.value.style.chart.layout.dataLabels.prefix,
330
+ v: t,
331
+ s: e.value.style.chart.layout.dataLabels.suffix,
332
+ r: e.value.style.chart.layout.dataLabels.rounding
333
+ }),
334
+ { datapoint: a, index: l }
335
+ );
336
+ }
337
+ const xe = f(() => ({
338
+ max: Math.max(...L.value.map((t) => t.subtotal)),
339
+ min: 0
340
+ })), U = f(() => {
341
+ const t = L.value.length === 1 ? xe.value.max * 2 : xe.value.max;
342
+ return gt(xe.value.min, t, e.value.style.chart.layout.grid.yAxis.dataLabels.steps);
343
+ });
344
+ function Rt(t) {
345
+ return t / U.value.max;
346
+ }
347
+ const Vt = f(() => U.value.ticks.map((t) => ({
348
+ y: r.value.bottom - r.value.height * Rt(t),
349
+ value: t
350
+ })));
351
+ function Mt(t, a) {
352
+ return isNaN(t.value / bt(a, "value")) ? 0 : (t.value / bt(a, "value") * 100).toFixed(0) + "%";
353
+ }
354
+ function et(t) {
355
+ g.value = null, ee.value = null, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: t.seriesIndex + h.value.start });
356
+ }
357
+ function Ht(t) {
358
+ e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: t.index + h.value.start }), g.value = t.index, ee.value = t;
359
+ }
360
+ const q = c(null);
361
+ function tt(t, a) {
362
+ e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: t.index + h.value.start }), !(!t.subtotal || !e.value.style.chart.dialog.show) && (ee.value = null, g.value = null, ie.value = !0, E.value = t, Xt(t), [null, void 0].includes(a) || (q.value = a));
363
+ }
364
+ const lt = f(() => O.value.map((t, a) => ({
365
+ name: t.name,
366
+ value: t.values.slice(h.value.start, h.value.end).reduce((l, s) => l + s, 0),
367
+ shape: "circle",
368
+ uid: t.uid,
369
+ color: t.color
370
+ })).sort((t, a) => a.value - t.value).map((t) => ({
371
+ ...t,
372
+ opacity: w.value.includes(t.uid) ? 0.5 : 1,
373
+ segregate: () => pe(t.uid),
374
+ isSegregated: w.value.includes(t.uid)
375
+ }))), at = f(() => L.value.map((t) => t.subtotal).reduce((t, a) => t + a, 0)), Bt = f(() => ({
376
+ cy: "donut-div-legend",
377
+ backgroundColor: e.value.style.chart.legend.backgroundColor,
378
+ color: e.value.style.chart.legend.color,
379
+ fontSize: e.value.style.chart.legend.fontSize,
380
+ paddingBottom: 12,
381
+ fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
382
+ }));
383
+ function pe(t) {
384
+ if (w.value.includes(t))
385
+ w.value = w.value.filter((a) => a !== t), Ve("selectLegend", null);
386
+ else {
387
+ if (w.value.length === O.value.length - 1) return;
388
+ w.value.push(t), Ve("selectLegend", O.value.find((a) => a.uid === t));
389
+ }
390
+ E.value && tt(L.value.find((a, l) => l === q.value));
391
+ }
392
+ const X = f(() => {
393
+ const t = [""].concat(O.value.filter((o) => !w.value.includes(o.uid)).map((o) => ({
394
+ name: o.name,
395
+ color: o.color
396
+ }))).concat(["Σ"]);
397
+ let a = [];
398
+ for (let o = 0; o < D.value; o += 1) {
399
+ const y = O.value.filter((d) => !w.value.includes(d.uid)).map((d) => d.values[o] ?? 0).reduce((d, x) => d + x, 0);
400
+ a.push([C[o] ? C[o].text : "-"].concat(O.value.filter((d) => !w.value.includes(d.uid)).map((d) => ({
401
+ value: d.values[o] ?? 0,
402
+ percentage: d.values[o] ? d.values[o] / y * 100 : 0
403
+ }))).concat([`${e.value.style.chart.layout.dataLabels.prefix}${Number(y.toFixed(e.value.table.td.roundingValue))}${e.value.style.chart.layout.dataLabels.suffix}`]));
404
+ }
405
+ const l = {
406
+ th: {
407
+ backgroundColor: e.value.table.th.backgroundColor,
408
+ color: e.value.table.th.color,
409
+ outline: e.value.table.th.outline
410
+ },
411
+ td: {
412
+ backgroundColor: e.value.table.td.backgroundColor,
413
+ color: e.value.table.td.color,
414
+ outline: e.value.table.td.outline
415
+ },
416
+ breakpoint: e.value.table.responsiveBreakpoint
417
+ }, s = [
418
+ e.value.table.columnNames.period
419
+ ].concat(O.value.filter((o) => !w.value.includes(o.uid)).map((o) => o.name)).concat(e.value.table.columnNames.total);
420
+ return { head: t, body: a, config: l, colNames: s };
421
+ });
422
+ function Ut() {
423
+ return O.value;
424
+ }
425
+ function ot(t = null) {
426
+ Ce(() => {
427
+ const a = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [""]], l = [...X.value.head.map((d) => d.name ?? d)], s = [...X.value.body.map((d) => d.map((x) => x.value ?? x))], o = a.concat([l]).concat(s), y = dl(o);
428
+ t ? t(y) : hl({ csvContent: y, title: e.value.style.chart.title.text || "vue-ui-donut-evolution" });
429
+ });
430
+ }
431
+ const G = c(!1);
432
+ function ut(t) {
433
+ G.value = t, ze.value += 1;
434
+ }
435
+ function st() {
436
+ B.value.showTable = !B.value.showTable;
437
+ }
438
+ const ue = c(!1);
439
+ function ke() {
440
+ ue.value = !ue.value;
441
+ }
442
+ function nt(t) {
443
+ return t.proportion * 100 > e.value.style.chart.donuts.hover.hideLabelsUnderValue;
444
+ }
445
+ const rt = c([]), it = c({}), we = c(null);
446
+ function Xt(t) {
447
+ rt.value = t.donut.map((a) => ({
448
+ name: a.name,
449
+ values: [a.value],
450
+ color: a.color
451
+ })), it.value = yl({
452
+ ...e.value.style.chart.dialog.donutChart,
453
+ responsive: !0,
454
+ theme: e.value.theme
455
+ }), we.value && we.value.open();
456
+ }
457
+ async function Gt({ scale: t = 2 } = {}) {
458
+ if (!P.value) return;
459
+ const { width: a, height: l } = P.value.getBoundingClientRect(), s = a / l, { imageUri: o, base64: y } = await Cl({ domElement: P.value, base64: !0, img: !0, scale: t });
460
+ return {
461
+ imageUri: o,
462
+ base64: y,
463
+ title: e.value.style.chart.title.text,
464
+ width: a,
465
+ height: l,
466
+ aspectRatio: s
467
+ };
468
+ }
469
+ const Wt = f(() => H.value.width), Yt = f(() => H.value.height);
470
+ return xl({
471
+ timeLabelsEls: te,
472
+ timeLabels: C,
473
+ slicer: h,
474
+ configRef: e,
475
+ rotationPath: ["style", "chart", "layout", "grid", "xAxis", "dataLabels", "rotation"],
476
+ autoRotatePath: ["style", "chart", "layout", "grid", "xAxis", "dataLabels", "autoRotate"],
477
+ isAutoSize: !1,
478
+ width: Wt,
479
+ height: Yt
480
+ }), wt({
481
+ getData: Ut,
482
+ getImage: Gt,
483
+ generatePdf: Je,
484
+ generateCsv: ot,
485
+ generateImage: Ke,
486
+ toggleTable: st,
487
+ toggleAnnotator: ke,
488
+ toggleFullscreen: ut
489
+ }), (t, a) => (u(), n("div", {
490
+ ref_key: "donutEvolutionChart",
491
+ ref: P,
492
+ class: N(`vue-ui-donut-evolution ${G.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
493
+ style: J(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;background:${e.value.style.chart.backgroundColor}`),
494
+ id: M.value,
495
+ onMouseenter: a[5] || (a[5] = () => i(Ge)(!0)),
496
+ onMouseleave: a[6] || (a[6] = () => i(Ge)(!1))
497
+ }, [
498
+ e.value.userOptions.buttons.annotator ? (u(), T(i(zt), {
499
+ key: 0,
500
+ svgRef: i(Ye),
501
+ backgroundColor: e.value.style.chart.backgroundColor,
502
+ color: e.value.style.chart.color,
503
+ active: ue.value,
504
+ onClose: ke
505
+ }, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : v("", !0),
506
+ Pt.value ? (u(), n("div", {
507
+ key: 1,
508
+ ref_key: "noTitle",
509
+ ref: Tt,
510
+ class: "vue-data-ui-no-title-space",
511
+ style: "height:36px; width: 100%;background:transparent"
512
+ }, null, 512)) : v("", !0),
513
+ e.value.style.chart.title.text ? (u(), n("div", {
514
+ key: 2,
515
+ ref_key: "chartTitle",
516
+ ref: Oe,
517
+ style: "width:100%;background:transparent;padding-bottom:24px",
518
+ onMouseleave: et
519
+ }, [
520
+ (u(), T(wl, {
521
+ key: `title_${Ie.value}`,
522
+ config: {
523
+ title: {
524
+ cy: "donut-evolution-div-title",
525
+ ...e.value.style.chart.title
526
+ },
527
+ subtitle: {
528
+ cy: "donut-evolution-div-subtitle",
529
+ ...e.value.style.chart.title.subtitle
530
+ }
531
+ }
532
+ }, null, 8, ["config"]))
533
+ ], 544)) : v("", !0),
534
+ e.value.userOptions.show && Me.value && (i(We) || i(ge)) ? (u(), T(i($t), {
535
+ ref: "details",
536
+ key: `user_options_${ze.value}`,
537
+ backgroundColor: e.value.style.chart.backgroundColor,
538
+ color: e.value.style.chart.color,
539
+ isPrinting: i(je),
540
+ isImaging: i(qe),
541
+ uid: M.value,
542
+ hasPdf: e.value.userOptions.buttons.pdf,
543
+ hasImg: e.value.userOptions.buttons.img,
544
+ hasXls: e.value.userOptions.buttons.csv,
545
+ hasTable: e.value.userOptions.buttons.table,
546
+ hasFullscreen: e.value.userOptions.buttons.fullscreen,
547
+ isFullscreen: G.value,
548
+ titles: { ...e.value.userOptions.buttonTitles },
549
+ chartElement: P.value,
550
+ position: e.value.userOptions.position,
551
+ hasAnnotator: e.value.userOptions.buttons.annotator,
552
+ isAnnotation: ue.value,
553
+ callbacks: e.value.userOptions.callbacks,
554
+ printScale: e.value.userOptions.print.scale,
555
+ onToggleFullscreen: ut,
556
+ onGeneratePdf: i(Je),
557
+ onGenerateCsv: ot,
558
+ onGenerateImage: i(Ke),
559
+ onToggleTable: st,
560
+ onToggleAnnotator: ke,
561
+ style: J({
562
+ visibility: i(We) ? i(ge) ? "visible" : "hidden" : "visible"
563
+ })
564
+ }, Qt({ _: 2 }, [
565
+ t.$slots.menuIcon ? {
566
+ name: "menuIcon",
567
+ fn: _(({ isOpen: l, color: s }) => [
568
+ S(t.$slots, "menuIcon", K(Q({ isOpen: l, color: s })), void 0, !0)
569
+ ]),
570
+ key: "0"
571
+ } : void 0,
572
+ t.$slots.optionPdf ? {
573
+ name: "optionPdf",
574
+ fn: _(() => [
575
+ S(t.$slots, "optionPdf", {}, void 0, !0)
576
+ ]),
577
+ key: "1"
578
+ } : void 0,
579
+ t.$slots.optionCsv ? {
580
+ name: "optionCsv",
581
+ fn: _(() => [
582
+ S(t.$slots, "optionCsv", {}, void 0, !0)
583
+ ]),
584
+ key: "2"
585
+ } : void 0,
586
+ t.$slots.optionImg ? {
587
+ name: "optionImg",
588
+ fn: _(() => [
589
+ S(t.$slots, "optionImg", {}, void 0, !0)
590
+ ]),
591
+ key: "3"
592
+ } : void 0,
593
+ t.$slots.optionTable ? {
594
+ name: "optionTable",
595
+ fn: _(() => [
596
+ S(t.$slots, "optionTable", {}, void 0, !0)
597
+ ]),
598
+ key: "4"
599
+ } : void 0,
600
+ t.$slots.optionFullscreen ? {
601
+ name: "optionFullscreen",
602
+ fn: _(({ toggleFullscreen: l, isFullscreen: s }) => [
603
+ S(t.$slots, "optionFullscreen", K(Q({ toggleFullscreen: l, isFullscreen: s })), void 0, !0)
604
+ ]),
605
+ key: "5"
606
+ } : void 0,
607
+ t.$slots.optionAnnotator ? {
608
+ name: "optionAnnotator",
609
+ fn: _(({ toggleAnnotator: l, isAnnotator: s }) => [
610
+ S(t.$slots, "optionAnnotator", K(Q({ toggleAnnotator: l, isAnnotator: s })), void 0, !0)
611
+ ]),
612
+ key: "6"
613
+ } : void 0
614
+ ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : v("", !0),
615
+ (u(), n("svg", {
616
+ ref_key: "svgRef",
617
+ ref: Ye,
618
+ xmlns: i(nl),
619
+ class: N({ "vue-data-ui-fullscreen--on": G.value, "vue-data-ui-fulscreen--off": !G.value }),
620
+ viewBox: `0 0 ${r.value.absoluteWidth} ${r.value.absoluteHeight}`,
621
+ style: J(`max-width:100%; overflow: visible; background:transparent;color:${e.value.style.chart.color};`)
622
+ }, [
623
+ Zt(i(St)),
624
+ t.$slots["chart-background"] ? (u(), n("foreignObject", {
625
+ key: 0,
626
+ x: r.value.left,
627
+ y: r.value.top,
628
+ width: r.value.width,
629
+ height: r.value.height,
630
+ style: {
631
+ pointerEvents: "none"
632
+ }
633
+ }, [
634
+ S(t.$slots, "chart-background", {}, void 0, !0)
635
+ ], 8, Il)) : v("", !0),
636
+ p("defs", null, [
637
+ p("linearGradient", {
638
+ id: `hover_${M.value}`,
639
+ x1: "0%",
640
+ y1: "0%",
641
+ x2: "0%",
642
+ y2: "100%"
643
+ }, [
644
+ p("stop", {
645
+ offset: "0%",
646
+ "stop-color": i(Z)(e.value.style.chart.backgroundColor, e.value.style.chart.layout.highlighter.opacity)
647
+ }, null, 8, Tl),
648
+ p("stop", {
649
+ offset: "100%",
650
+ "stop-color": i(Z)(e.value.style.chart.layout.highlighter.color, e.value.style.chart.layout.highlighter.opacity)
651
+ }, null, 8, Ol)
652
+ ], 8, Nl),
653
+ p("radialGradient", {
654
+ id: `focus_${M.value}`
655
+ }, [
656
+ p("stop", {
657
+ offset: "0%",
658
+ "stop-color": i(Z)(i(_e)(e.value.style.chart.backgroundColor), 0)
659
+ }, null, 8, Dl),
660
+ p("stop", {
661
+ offset: "77%",
662
+ "stop-color": i(Z)("#FFFFFF", 30)
663
+ }, null, 8, Fl),
664
+ p("stop", {
665
+ offset: "100%",
666
+ "stop-color": i(Z)(i(_e)(e.value.style.chart.backgroundColor), 0)
667
+ }, null, 8, El)
668
+ ], 8, Pl)
669
+ ]),
670
+ e.value.style.chart.layout.grid.show ? (u(), n("g", Rl, [
671
+ p("line", {
672
+ x1: r.value.left,
673
+ x2: r.value.left,
674
+ y1: r.value.top,
675
+ y2: r.value.top + r.value.height,
676
+ stroke: e.value.style.chart.layout.grid.stroke,
677
+ "stroke-width": e.value.style.chart.layout.grid.strokeWidth,
678
+ "stroke-linecap": "round"
679
+ }, null, 8, Vl),
680
+ p("line", {
681
+ x1: r.value.left,
682
+ x2: r.value.right,
683
+ y1: r.value.bottom,
684
+ y2: r.value.bottom,
685
+ stroke: e.value.style.chart.layout.grid.stroke,
686
+ "stroke-width": e.value.style.chart.layout.grid.strokeWidth,
687
+ "stroke-linecap": "round"
688
+ }, null, 8, Ml),
689
+ e.value.style.chart.layout.grid.showVerticalLines ? (u(), n("g", Hl, [
690
+ (u(!0), n(z, null, $(h.value.end - h.value.start, (l, s) => (u(), n("line", {
691
+ x1: r.value.left + (s + 1) * k.value,
692
+ x2: r.value.left + (s + 1) * k.value,
693
+ y1: r.value.top,
694
+ y2: r.value.bottom,
695
+ stroke: e.value.style.chart.layout.grid.stroke,
696
+ "stroke-width": e.value.style.chart.layout.grid.strokeWidth,
697
+ "stroke-linecap": "round"
698
+ }, null, 8, Bl))), 256))
699
+ ])) : v("", !0)
700
+ ])) : v("", !0),
701
+ p("g", null, [
702
+ e.value.style.chart.layout.grid.axis.yLabel ? (u(), n("text", {
703
+ key: 0,
704
+ ref_key: "yAxisLabel",
705
+ ref: de,
706
+ "font-size": e.value.style.chart.layout.grid.axis.fontSize,
707
+ fill: e.value.style.chart.layout.grid.axis.color,
708
+ transform: `translate(${e.value.style.chart.layout.grid.axis.fontSize}, ${r.value.top + r.value.height / 2}) rotate(-90)`,
709
+ "text-anchor": "middle",
710
+ style: { transition: "none" }
711
+ }, m(e.value.style.chart.layout.grid.axis.yLabel), 9, Ul)) : v("", !0),
712
+ e.value.style.chart.layout.grid.axis.xLabel ? (u(), n("text", {
713
+ key: 1,
714
+ ref_key: "xAxisLabel",
715
+ ref: ve,
716
+ "text-anchor": "middle",
717
+ x: r.value.absoluteWidth / 2,
718
+ y: r.value.absoluteHeight - 3,
719
+ "font-size": e.value.style.chart.layout.grid.axis.fontSize,
720
+ fill: e.value.style.chart.layout.grid.axis.color
721
+ }, m(e.value.style.chart.layout.grid.axis.xLabel), 9, Xl)) : v("", !0)
722
+ ]),
723
+ e.value.style.chart.layout.grid.yAxis.dataLabels.show ? (u(), n("g", {
724
+ key: 2,
725
+ ref_key: "scaleLabels",
726
+ ref: ce,
727
+ class: N({ "donut-opacity": !0, "donut-behind": g.value !== null })
728
+ }, [
729
+ (u(!0), n(z, null, $(Vt.value, (l, s) => (u(), n("g", null, [
730
+ l.value >= U.value.min && l.value <= U.value.max ? (u(), n("line", {
731
+ key: 0,
732
+ x1: r.value.left,
733
+ x2: r.value.left - 5,
734
+ y1: l.y,
735
+ y2: l.y,
736
+ stroke: e.value.style.chart.layout.grid.stroke,
737
+ "stroke-width": e.value.style.chart.layout.grid.strokeWidth
738
+ }, null, 8, Gl)) : v("", !0),
739
+ l.value >= U.value.min && l.value <= U.value.max ? (u(), n("text", {
740
+ key: 1,
741
+ x: r.value.left,
742
+ y: l.y + e.value.style.chart.layout.grid.yAxis.dataLabels.fontSize / 3,
743
+ "font-size": e.value.style.chart.layout.grid.yAxis.dataLabels.fontSize,
744
+ "text-anchor": "end",
745
+ fill: e.value.style.chart.layout.grid.yAxis.dataLabels.color,
746
+ "font-weight": e.value.style.chart.layout.grid.yAxis.dataLabels.bold ? "bold" : "normal"
747
+ }, m(i(rl)(l.value) ? i(Se)(
748
+ e.value.style.chart.layout.dataLabels.formatter,
749
+ l.value,
750
+ i(re)({
751
+ p: e.value.style.chart.layout.dataLabels.prefix,
752
+ v: l.value,
753
+ s: e.value.style.chart.layout.dataLabels.suffix,
754
+ r: e.value.style.chart.layout.grid.yAxis.dataLabels.roundingValue
755
+ }),
756
+ { datapoint: l, seriesIndex: s }
757
+ ) : ""), 9, Wl)) : v("", !0)
758
+ ]))), 256))
759
+ ], 2)) : v("", !0),
760
+ e.value.style.chart.layout.grid.xAxis.dataLabels.show ? (u(), n("g", {
761
+ key: 3,
762
+ ref_key: "timeLabelsEls",
763
+ ref: te,
764
+ class: N({ "donut-opacity": !0 })
765
+ }, [
766
+ (u(!0), n(z, null, $(h.value.end - h.value.start, (l, s) => (u(), n("g", null, [
767
+ (e.value.style.chart.layout.grid.xAxis.dataLabels.showOnlyFirstAndLast && (s === 0 || s === D.value - 1) || !e.value.style.chart.layout.grid.xAxis.dataLabels.showOnlyFirstAndLast) && C.value[s] && C.value[s].text ? (u(), n("g", Yl, [
768
+ String(C.value[s].text).includes(`
769
+ `) ? (u(), n("text", {
770
+ key: 1,
771
+ class: "vue-data-ui-time-label",
772
+ "text-anchor": e.value.style.chart.layout.grid.xAxis.dataLabels.rotation > 0 ? "start" : e.value.style.chart.layout.grid.xAxis.dataLabels.rotation < 0 ? "end" : "middle",
773
+ "font-size": e.value.style.chart.layout.grid.xAxis.dataLabels.fontSize,
774
+ fill: e.value.style.chart.layout.grid.xAxis.dataLabels.color,
775
+ transform: `translate(${r.value.left + k.value * s + k.value / 2}, ${r.value.bottom + e.value.style.chart.layout.grid.xAxis.dataLabels.fontSize + e.value.style.chart.layout.grid.xAxis.dataLabels.offsetY}), rotate(${e.value.style.chart.layout.grid.xAxis.dataLabels.rotation})`,
776
+ innerHTML: i(il)({
777
+ content: String(C.value[s].text),
778
+ fontSize: e.value.style.chart.layout.grid.xAxis.dataLabels.fontSize,
779
+ fill: e.value.style.chart.layout.grid.xAxis.dataLabels.color,
780
+ x: 0,
781
+ y: 0
782
+ })
783
+ }, null, 8, ql)) : (u(), n("text", {
784
+ key: 0,
785
+ class: "vue-data-ui-time-label",
786
+ "text-anchor": e.value.style.chart.layout.grid.xAxis.dataLabels.rotation > 0 ? "start" : e.value.style.chart.layout.grid.xAxis.dataLabels.rotation < 0 ? "end" : "middle",
787
+ "font-size": e.value.style.chart.layout.grid.xAxis.dataLabels.fontSize,
788
+ fill: e.value.style.chart.layout.grid.xAxis.dataLabels.color,
789
+ transform: `translate(${r.value.left + k.value * s + k.value / 2}, ${r.value.bottom + e.value.style.chart.layout.grid.xAxis.dataLabels.fontSize + e.value.style.chart.layout.grid.xAxis.dataLabels.offsetY}), rotate(${e.value.style.chart.layout.grid.xAxis.dataLabels.rotation})`
790
+ }, m(C.value[s].text || ""), 9, jl))
791
+ ])) : v("", !0)
792
+ ]))), 256))
793
+ ], 512)) : v("", !0),
794
+ (u(!0), n(z, null, $(L.value, (l, s) => (u(), n("g", null, [
795
+ e.value.style.chart.layout.line.show && s < L.value.length - 1 && ![l.subtotal, L.value[s + 1].subtotal].includes(null) ? (u(), n("line", {
796
+ key: 0,
797
+ class: N({ "donut-opacity": !0, "donut-behind": g.value !== null }),
798
+ x1: l.x,
799
+ y1: l.y,
800
+ x2: L.value[s + 1].x,
801
+ y2: L.value[s + 1].y,
802
+ stroke: e.value.style.chart.layout.line.stroke,
803
+ "stroke-width": e.value.style.chart.layout.line.strokeWidth,
804
+ "stroke-linecap": "round",
805
+ "stroke-linejoin": "round"
806
+ }, null, 10, Jl)) : v("", !0),
807
+ l.subtotal !== null ? (u(), n("g", Kl, [
808
+ l.subtotal ? (u(), n("circle", {
809
+ key: 0,
810
+ cx: l.x,
811
+ cy: l.y,
812
+ r: l.activeRadius,
813
+ fill: e.value.style.chart.backgroundColor
814
+ }, null, 8, Ql)) : v("", !0)
815
+ ])) : v("", !0)
816
+ ]))), 256)),
817
+ (u(!0), n(z, null, $(L.value, (l, s) => (u(), n("g", {
818
+ class: N({ "donut-opacity": !0, "donut-behind": s !== g.value && g.value !== null })
819
+ }, [
820
+ l.subtotal ? (u(), n("g", Zl, [
821
+ g.value !== null && g.value === s ? (u(), n("g", ea, [
822
+ (u(!0), n(z, null, $(l.donutHover, (o) => (u(), n("g", null, [
823
+ nt(o) ? (u(), n("path", {
824
+ key: 0,
825
+ d: i(cl)(o, { x: o.center.endX, y: o.center.endY }, 12, 12, { x: l.x, y: l.y }, !1, 20),
826
+ stroke: o.color,
827
+ "stroke-width": "1",
828
+ "stroke-linecap": "round",
829
+ "stroke-linejoin": "round",
830
+ fill: "none"
831
+ }, null, 8, ta)) : v("", !0)
832
+ ]))), 256)),
833
+ (u(!0), n(z, null, $(l.donutHover, (o, y) => (u(), n("g", null, [
834
+ nt(o) ? (u(), n("text", {
835
+ key: 0,
836
+ "data-cy-hover-label": "",
837
+ "text-anchor": i(mt)(o, !0, 0).anchor,
838
+ x: i(mt)(o, !0, 9).x,
839
+ y: i(vl)(o, 14, 10),
840
+ fill: e.value.style.chart.layout.grid.yAxis.dataLabels.color,
841
+ "font-size": 8,
842
+ "font-weight": "bold"
843
+ }, m(o.name) + ": " + m(Mt(o, l.donut)) + " (" + m(o.value === null ? "-" : Ze(o.value, o, y)) + ") ", 9, la)) : v("", !0)
844
+ ]))), 256)),
845
+ p("g", null, [
846
+ p("circle", {
847
+ cx: l.x,
848
+ cy: l.y,
849
+ r: l.hoverRadius,
850
+ fill: e.value.style.chart.backgroundColor
851
+ }, null, 8, aa)
852
+ ])
853
+ ])) : v("", !0)
854
+ ])) : v("", !0)
855
+ ], 2))), 256)),
856
+ (u(!0), n(z, null, $(L.value, (l, s) => (u(), n("g", {
857
+ class: N({ "donut-opacity": !0, "donut-behind": s !== g.value && g.value !== null })
858
+ }, [
859
+ l.subtotal !== null ? (u(), n("g", oa, [
860
+ l.subtotal === 0 ? (u(), n("circle", {
861
+ key: 0,
862
+ cx: l.x,
863
+ cy: l.y,
864
+ r: 3,
865
+ fill: e.value.style.chart.color
866
+ }, null, 8, ua)) : g.value !== null && g.value === s ? (u(), n("g", sa, [
867
+ (u(!0), n(z, null, $(l.donutHover, (o, y) => (u(), n("path", {
868
+ d: o.arcSlice,
869
+ fill: `${o.color}`,
870
+ "stroke-width": 1,
871
+ stroke: e.value.style.chart.backgroundColor
872
+ }, null, 8, na))), 256))
873
+ ])) : (u(), n("g", ra, [
874
+ (u(!0), n(z, null, $(l.donut, (o, y) => (u(), n("path", {
875
+ d: o.arcSlice,
876
+ fill: `${o.color}`,
877
+ "stroke-width": 0.5,
878
+ stroke: e.value.style.chart.backgroundColor
879
+ }, null, 8, ia))), 256))
880
+ ]))
881
+ ])) : v("", !0)
882
+ ], 2))), 256)),
883
+ (u(!0), n(z, null, $(L.value, (l, s) => (u(), n("g", {
884
+ class: N({ "donut-opacity": !0, "donut-behind": s !== g.value && g.value !== null || ie.value && s !== E.value.index })
885
+ }, [
886
+ l.subtotal !== null && e.value.style.chart.layout.dataLabels.show ? (u(), n("text", {
887
+ key: 0,
888
+ "text-anchor": "middle",
889
+ x: l.x,
890
+ y: g.value === l.index && l.subtotal ? l.y + e.value.style.chart.layout.dataLabels.fontSize / 3 : l.y - l.radius - e.value.style.chart.layout.dataLabels.fontSize + e.value.style.chart.layout.dataLabels.offsetY,
891
+ "font-size": e.value.style.chart.layout.dataLabels.fontSize,
892
+ "font-weight": "bold",
893
+ fill: e.value.style.chart.layout.dataLabels.color
894
+ }, m(Ze(l.subtotal, l, s)), 9, ca)) : v("", !0)
895
+ ], 2))), 256)),
896
+ (u(!0), n(z, null, $(L.value, (l, s) => (u(), n("rect", {
897
+ x: r.value.left + s * k.value,
898
+ y: r.value.top,
899
+ width: k.value,
900
+ height: r.value.height,
901
+ fill: [g.value, q.value].includes(l.index) ? `url(#hover_${M.value})` : "transparent",
902
+ class: N({ "donut-hover": l.subtotal && [g.value, q.value].includes(l.index) }),
903
+ style: {
904
+ pointerEvents: "none"
905
+ }
906
+ }, null, 10, va))), 256)),
907
+ (u(!0), n(z, null, $(L.value, (l, s) => (u(), n("rect", {
908
+ "data-cy-trap": "",
909
+ x: r.value.left + s * k.value,
910
+ y: r.value.top,
911
+ width: k.value,
912
+ height: r.value.height,
913
+ fill: "transparent",
914
+ onMouseenter: (o) => Ht(l),
915
+ onMouseleave: (o) => et(l),
916
+ onClick: (o) => tt(l, s),
917
+ class: N({ "donut-hover": g.value === l.index && l.subtotal })
918
+ }, null, 42, da))), 256)),
919
+ S(t.$slots, "svg", { svg: r.value }, void 0, !0)
920
+ ], 14, $l)),
921
+ t.$slots.watermark ? (u(), n("div", ha, [
922
+ S(t.$slots, "watermark", K(Q({ isPrinting: i(je) || i(qe) })), void 0, !0)
923
+ ])) : v("", !0),
924
+ p("div", {
925
+ ref_key: "chartSlicer",
926
+ ref: Ee,
927
+ style: J(`width:100%;background:${e.value.style.chart.backgroundColor}`),
928
+ "data-dom-to-png-ignore": ""
929
+ }, [
930
+ D.value > 1 && e.value.style.chart.zoom.show ? (u(), T(kl, {
931
+ ref_key: "slicerComponent",
932
+ ref: Fe,
933
+ key: `slicer_${$e.value}`,
934
+ background: e.value.style.chart.zoom.color,
935
+ borderColor: e.value.style.chart.backgroundColor,
936
+ fontSize: e.value.style.chart.zoom.fontSize,
937
+ useResetSlot: e.value.style.chart.zoom.useResetSlot,
938
+ labelLeft: C.value[0] ? C.value[0].text : "",
939
+ labelRight: C.value.at(-1) ? C.value.at(-1).text : "",
940
+ textColor: e.value.style.chart.color,
941
+ inputColor: e.value.style.chart.zoom.color,
942
+ selectColor: e.value.style.chart.zoom.highlightColor,
943
+ max: D.value,
944
+ min: 0,
945
+ valueStart: h.value.start,
946
+ valueEnd: h.value.end,
947
+ start: h.value.start,
948
+ "onUpdate:start": a[0] || (a[0] = (l) => h.value.start = l),
949
+ end: h.value.end,
950
+ "onUpdate:end": a[1] || (a[1] = (l) => h.value.end = l),
951
+ refreshStartPoint: e.value.style.chart.zoom.startIndex !== null ? e.value.style.chart.zoom.startIndex : 0,
952
+ refreshEndPoint: e.value.style.chart.zoom.endIndex !== null ? e.value.style.chart.zoom.endIndex + 1 : D.value,
953
+ enableRangeHandles: e.value.style.chart.zoom.enableRangeHandles,
954
+ enableSelectionDrag: e.value.style.chart.zoom.enableSelectionDrag,
955
+ onReset: Xe
956
+ }, {
957
+ "reset-action": _(({ reset: l }) => [
958
+ S(t.$slots, "reset-action", K(Q({ reset: l })), void 0, !0)
959
+ ]),
960
+ _: 3
961
+ }, 8, ["background", "borderColor", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "max", "valueStart", "valueEnd", "start", "end", "refreshStartPoint", "refreshEndPoint", "enableRangeHandles", "enableSelectionDrag"])) : v("", !0)
962
+ ], 4),
963
+ p("div", {
964
+ ref_key: "chartLegend",
965
+ ref: Pe
966
+ }, [
967
+ e.value.style.chart.legend.show ? (u(), T(pl, {
968
+ key: `legend_${Te.value}`,
969
+ legendSet: lt.value,
970
+ config: Bt.value,
971
+ onClickMarker: a[2] || (a[2] = ({ legend: l }) => pe(l.uid))
972
+ }, {
973
+ item: _(({ legend: l, index: s }) => [
974
+ p("div", {
975
+ onClick: (o) => pe(l.uid),
976
+ style: J(`opacity:${w.value.includes(l.uid) ? 0.5 : 1}`)
977
+ }, m(l.name) + m(e.value.style.chart.legend.showPercentage || e.value.style.chart.legend.showValue ? ":" : "") + " " + m(e.value.style.chart.legend.showValue ? i(Se)(
978
+ e.value.style.chart.layout.dataLabels.formatter,
979
+ l.value,
980
+ i(re)({
981
+ p: e.value.style.chart.layout.dataLabels.prefix,
982
+ v: l.value,
983
+ s: e.value.style.chart.layout.dataLabels.suffix,
984
+ r: e.value.style.chart.legend.roundingValue
985
+ }),
986
+ { datapoint: l, seriesIndex: s }
987
+ ) : "") + " " + m(e.value.style.chart.legend.showPercentage ? w.value.includes(l.uid) ? `${e.value.style.chart.legend.showValue ? "(" : ""}- %${e.value.style.chart.legend.showValue ? ")" : ""}` : `${e.value.style.chart.legend.showValue ? "(" : ""}${isNaN(l.value / at.value) ? "-" : i(re)({
988
+ v: l.value / at.value * 100,
989
+ s: "%",
990
+ r: e.value.style.chart.legend.roundingPercentage
991
+ })}${e.value.style.chart.legend.showValue ? ")" : ""}` : ""), 13, ya)
992
+ ]),
993
+ _: 1
994
+ }, 8, ["legendSet", "config"])) : v("", !0),
995
+ S(t.$slots, "legend", { legend: lt.value }, void 0, !0)
996
+ ], 512),
997
+ t.$slots.source ? (u(), n("div", {
998
+ key: 5,
999
+ ref_key: "source",
1000
+ ref: De,
1001
+ dir: "auto"
1002
+ }, [
1003
+ S(t.$slots, "source", {}, void 0, !0)
1004
+ ], 512)) : v("", !0),
1005
+ Me.value ? (u(), T(i(Lt), {
1006
+ key: 6,
1007
+ hideDetails: "",
1008
+ config: {
1009
+ open: B.value.showTable,
1010
+ maxHeight: 1e4,
1011
+ body: {
1012
+ backgroundColor: e.value.style.chart.backgroundColor,
1013
+ color: e.value.style.chart.color
1014
+ },
1015
+ head: {
1016
+ backgroundColor: e.value.style.chart.backgroundColor,
1017
+ color: e.value.style.chart.color
1018
+ }
1019
+ }
1020
+ }, {
1021
+ content: _(() => [
1022
+ (u(), T(i(At), {
1023
+ key: `table_${Ne.value}`,
1024
+ colNames: X.value.colNames,
1025
+ head: X.value.head,
1026
+ body: X.value.body,
1027
+ config: X.value.config,
1028
+ title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
1029
+ onClose: a[3] || (a[3] = (l) => B.value.showTable = !1)
1030
+ }, {
1031
+ th: _(({ th: l }) => [
1032
+ dt(m(l.name ?? l), 1)
1033
+ ]),
1034
+ td: _(({ td: l }) => [
1035
+ l.value === null ? (u(), n("span", fa, "-")) : (u(), n("b", ga, m(isNaN(l.value) ? "" : e.value.style.chart.layout.dataLabels.prefix) + m(!isNaN(l.value) && l.value !== null ? Number(l.value.toFixed(e.value.table.td.roundingValue)).toLocaleString() : l) + m(isNaN(l.value) ? "" : e.value.style.chart.layout.dataLabels.suffix), 1)),
1036
+ p("span", null, m(l.percentage && !isNaN(l.percentage) ? `(${Number(l.percentage.toFixed(e.value.table.td.roundingPercentage)).toLocaleString()}%)` : ""), 1)
1037
+ ]),
1038
+ _: 1
1039
+ }, 8, ["colNames", "head", "body", "config", "title"]))
1040
+ ]),
1041
+ _: 1
1042
+ }, 8, ["config"])) : v("", !0),
1043
+ e.value.style.chart.dialog.show ? (u(), T(i(_t), {
1044
+ key: 7,
1045
+ ref_key: "dialog",
1046
+ ref: we,
1047
+ onClose: a[4] || (a[4] = (l) => {
1048
+ E.value = null, ie.value = !1, ee.value = null, g.value = null, q.value = null;
1049
+ }),
1050
+ backgroundColor: e.value.style.chart.dialog.backgroundColor,
1051
+ color: e.value.style.chart.dialog.color,
1052
+ headerBg: e.value.style.chart.dialog.header.backgroundColor,
1053
+ headerColor: e.value.style.chart.dialog.header.color,
1054
+ isFullscreen: G.value,
1055
+ fullscreenParent: P.value
1056
+ }, {
1057
+ title: _(() => [
1058
+ dt(m(C.value[Number(E.value.index)] ? C.value[Number(E.value.index)].text : ""), 1)
1059
+ ]),
1060
+ default: _(() => [
1061
+ E.value ? (u(), T(i(It), {
1062
+ key: 0,
1063
+ config: it.value,
1064
+ dataset: rt.value
1065
+ }, null, 8, ["config", "dataset"])) : v("", !0)
1066
+ ]),
1067
+ _: 1
1068
+ }, 8, ["backgroundColor", "color", "headerBg", "headerColor", "isFullscreen", "fullscreenParent"])) : v("", !0),
1069
+ i(Be) ? (u(), T(Al, { key: 8 })) : v("", !0)
1070
+ ], 46, zl));
1071
+ }
1072
+ }, Oa = /* @__PURE__ */ Sl(ma, [["__scopeId", "data-v-b059689d"]]);
1073
+ export {
1074
+ Oa as default
1075
+ };