vue-data-ui 2.3.3 → 2.3.4

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 (148) hide show
  1. package/dist/Arrow-B6gJebT9.js +101 -0
  2. package/dist/Arrow-C5yj6zwY.cjs +1 -0
  3. package/dist/BaseIcon-7_g11dRj.js +174 -0
  4. package/dist/BaseIcon-JtWoVorZ.cjs +1 -0
  5. package/dist/DataTable-CwaOlAsy.js +127 -0
  6. package/dist/DataTable-Rm9II-m2.cjs +1 -0
  7. package/dist/Legend-CxvJTjEm.js +62 -0
  8. package/dist/Legend-D59FIuMs.cjs +1 -0
  9. package/dist/Shape-CVItL3vh.cjs +1 -0
  10. package/dist/Shape-CjLV0scA.js +107 -0
  11. package/dist/Slicer-Bxg5niHl.js +156 -0
  12. package/dist/Slicer-Cdss5Rus.cjs +1 -0
  13. package/dist/Title-2iks1ziC.js +46 -0
  14. package/dist/Title-Bb-A5OSV.cjs +1 -0
  15. package/dist/Tooltip-C3phqKuU.js +94 -0
  16. package/dist/Tooltip-C_UE6y-E.cjs +1 -0
  17. package/dist/_plugin-vue_export-helper-BHFhmbuH.cjs +1 -0
  18. package/dist/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
  19. package/dist/html2canvas.esm-BA_v9SIU.cjs +22 -0
  20. package/dist/html2canvas.esm-d2sM-0Wm.js +4870 -0
  21. package/dist/index-p5gfZSvB.cjs +4 -0
  22. package/dist/index-uOtklCCx.js +10268 -0
  23. package/dist/{index.es-ypwniJN8.js → index.es-YufTdp0y.js} +1 -1
  24. package/dist/{index.es-Dnua3tHc.cjs → index.es-uyeSCnWE.cjs} +1 -1
  25. package/dist/jspdf.es.min-C660YX78.js +8038 -0
  26. package/dist/jspdf.es.min-DLYY9DTT.cjs +243 -0
  27. package/dist/pdf-97UbtKC2.js +44 -0
  28. package/dist/pdf-Cz3729tZ.cjs +1 -0
  29. package/dist/style.css +1 -1
  30. package/dist/useNestedProp-2kIU-7On.cjs +1 -0
  31. package/dist/useNestedProp-BgWkUab_.js +13 -0
  32. package/dist/usePrinter-B6xQCyL-.js +464 -0
  33. package/dist/usePrinter-fZlsJid8.cjs +1 -0
  34. package/dist/useResponsive-B3TrDDIG.cjs +1 -0
  35. package/dist/useResponsive-NZB-WLRF.js +187 -0
  36. package/dist/vue-data-ui-Be0rgmbA.cjs +9 -0
  37. package/dist/vue-data-ui-Ccy6rBZN.js +246 -0
  38. package/dist/vue-data-ui.cjs +1 -1
  39. package/dist/vue-data-ui.js +62 -61
  40. package/dist/vue-ui-3d-bar-BKMPFDi2.js +1085 -0
  41. package/dist/vue-ui-3d-bar-CKa4UXq4.cjs +19 -0
  42. package/dist/vue-ui-accordion-C_pwrAJl.cjs +1 -0
  43. package/dist/vue-ui-accordion-HJPf7My0.js +77 -0
  44. package/dist/vue-ui-age-pyramid-CE1xnA-8.cjs +1 -0
  45. package/dist/vue-ui-age-pyramid-DB_CL-gu.js +596 -0
  46. package/dist/vue-ui-annotator-BAMZcPlH.cjs +371 -0
  47. package/dist/vue-ui-annotator-DQsAL-nZ.js +2177 -0
  48. package/dist/vue-ui-candlestick-DCl8fpNu.js +657 -0
  49. package/dist/vue-ui-candlestick-Duv6oG79.cjs +2 -0
  50. package/dist/vue-ui-chestnut-BYHA6MT4.js +1051 -0
  51. package/dist/vue-ui-chestnut-mIZ4-ZEM.cjs +6 -0
  52. package/dist/vue-ui-cursor-C96IChA3.js +229 -0
  53. package/dist/vue-ui-cursor-De7dy4Mo.cjs +1 -0
  54. package/dist/vue-ui-dashboard-B2Yz41yO.js +232 -0
  55. package/dist/vue-ui-dashboard-BMGwKr0K.cjs +1 -0
  56. package/dist/vue-ui-digits-BnxLp7zQ.js +153 -0
  57. package/dist/vue-ui-digits-DSWyL-5K.cjs +1 -0
  58. package/dist/vue-ui-donut-1kei9ws5.cjs +1 -0
  59. package/dist/vue-ui-donut-B9iXisHK.js +743 -0
  60. package/dist/vue-ui-donut-evolution-B7Sun8sw.js +799 -0
  61. package/dist/vue-ui-donut-evolution-yv17DnGy.cjs +1 -0
  62. package/dist/vue-ui-dumbbell-BJEf_JEq.cjs +9 -0
  63. package/dist/vue-ui-dumbbell-DIsDnD1d.js +624 -0
  64. package/dist/vue-ui-flow-BTivYoGd.js +454 -0
  65. package/dist/vue-ui-flow-DOxJa8di.cjs +1 -0
  66. package/dist/vue-ui-galaxy-BEmywfFB.js +485 -0
  67. package/dist/vue-ui-galaxy-CHGOwCwM.cjs +1 -0
  68. package/dist/vue-ui-gauge-QAfMl-8t.cjs +1 -0
  69. package/dist/vue-ui-gauge-o4rDOqF3.js +466 -0
  70. package/dist/vue-ui-heatmap-BS4EzedX.cjs +1 -0
  71. package/dist/vue-ui-heatmap-DwqQqEsk.js +598 -0
  72. package/dist/vue-ui-kpi-F4qkJ_U-.cjs +1 -0
  73. package/dist/vue-ui-kpi-h8elYTcA.js +54 -0
  74. package/dist/vue-ui-mini-loader-C_8B2Pm6.cjs +1 -0
  75. package/dist/vue-ui-mini-loader-Cgoi9rhH.js +131 -0
  76. package/dist/vue-ui-molecule-Bmv76SWz.js +750 -0
  77. package/dist/vue-ui-molecule-C5CY_YYc.cjs +1 -0
  78. package/dist/vue-ui-mood-radar-BN0dzlfp.cjs +1 -0
  79. package/dist/vue-ui-mood-radar-DeMouUIe.js +548 -0
  80. package/dist/vue-ui-nested-donuts-ZyFoV-Zn.cjs +16 -0
  81. package/dist/vue-ui-nested-donuts-wOUkSVyZ.js +771 -0
  82. package/dist/vue-ui-onion-DCOKG2wG.js +554 -0
  83. package/dist/vue-ui-onion-VmTUo7TR.cjs +1 -0
  84. package/dist/vue-ui-parallel-coordinate-plot-BGtO2P4a.js +651 -0
  85. package/dist/vue-ui-parallel-coordinate-plot-BziXRF8E.cjs +8 -0
  86. package/dist/vue-ui-quadrant--JOTjPZh.js +1178 -0
  87. package/dist/vue-ui-quadrant-DawUUrur.cjs +1 -0
  88. package/dist/vue-ui-quick-chart-LXKfaJgS.js +1310 -0
  89. package/dist/vue-ui-quick-chart-jFlFtiNV.cjs +13 -0
  90. package/dist/vue-ui-radar-CWNIqvcA.js +614 -0
  91. package/dist/vue-ui-radar-VGH-lhaT.cjs +1 -0
  92. package/dist/vue-ui-rating-BNrIoJHN.js +271 -0
  93. package/dist/vue-ui-rating-Dtu6pwGx.cjs +1 -0
  94. package/dist/vue-ui-relation-circle-B3NKudOy.js +304 -0
  95. package/dist/vue-ui-relation-circle-Dwpx9o18.cjs +1 -0
  96. package/dist/vue-ui-rings-CsUngX_F.js +510 -0
  97. package/dist/vue-ui-rings-D9_OG--0.cjs +1 -0
  98. package/dist/vue-ui-scatter-DUsuh7bd.cjs +1 -0
  99. package/dist/vue-ui-scatter-DgxTz4Jx.js +874 -0
  100. package/dist/vue-ui-screenshot-51H_VrYY.js +160 -0
  101. package/dist/vue-ui-screenshot-C2Dz7CAe.cjs +3 -0
  102. package/dist/vue-ui-skeleton-BM9rwmxY.js +2064 -0
  103. package/dist/vue-ui-skeleton-sjfOtCZr.cjs +41 -0
  104. package/dist/vue-ui-smiley-DNnBtHht.cjs +2 -0
  105. package/dist/vue-ui-smiley-H5rSN-1B.js +763 -0
  106. package/dist/vue-ui-spark-trend-CLXZDYlk.js +246 -0
  107. package/dist/vue-ui-spark-trend-R4JJvfry.cjs +1 -0
  108. package/dist/vue-ui-sparkbar-C0k4ah-7.js +242 -0
  109. package/dist/vue-ui-sparkbar-CEUDIw0A.cjs +1 -0
  110. package/dist/vue-ui-sparkgauge-BHj00A07.js +157 -0
  111. package/dist/vue-ui-sparkgauge-CaEw6nmI.cjs +1 -0
  112. package/dist/vue-ui-sparkhistogram-B6GuavEu.cjs +1 -0
  113. package/dist/vue-ui-sparkhistogram-DbMLYKqE.js +244 -0
  114. package/dist/vue-ui-sparkline-CJydanLS.cjs +1 -0
  115. package/dist/vue-ui-sparkline-CYova9x3.js +333 -0
  116. package/dist/vue-ui-sparkstackbar-Df__yM5b.cjs +1 -0
  117. package/dist/vue-ui-sparkstackbar-N5rVBM2h.js +244 -0
  118. package/dist/vue-ui-strip-plot-DJJ1vEWz.js +618 -0
  119. package/dist/vue-ui-strip-plot-b5lhB35d.cjs +1 -0
  120. package/dist/vue-ui-table-NHhOVDbs.cjs +14 -0
  121. package/dist/vue-ui-table-heatmap-Cro2etCY.js +237 -0
  122. package/dist/vue-ui-table-heatmap-DlL2nCqz.cjs +1 -0
  123. package/dist/vue-ui-table-sparkline-Bw2Gc_ur.cjs +1 -0
  124. package/dist/vue-ui-table-sparkline-DppMitqF.js +420 -0
  125. package/dist/vue-ui-table-xSvwJIa7.js +1430 -0
  126. package/dist/vue-ui-thermometer-M2kdp1x5.js +385 -0
  127. package/dist/vue-ui-thermometer-Q_3PX2V3.cjs +1 -0
  128. package/dist/vue-ui-timer-BtSDeIRp.cjs +64 -0
  129. package/dist/vue-ui-timer-CAaQ-QD6.js +453 -0
  130. package/dist/vue-ui-tiremarks-CbGOSEvD.cjs +1 -0
  131. package/dist/vue-ui-tiremarks-JFv4JLP0.js +249 -0
  132. package/dist/vue-ui-treemap-BqDX-bPf.cjs +1 -0
  133. package/dist/vue-ui-treemap-DCnv-xYr.js +722 -0
  134. package/dist/vue-ui-vertical-bar-CEbApJZl.js +737 -0
  135. package/dist/vue-ui-vertical-bar-CJB_KXyr.cjs +4 -0
  136. package/dist/vue-ui-waffle-CTS6C7gu.js +638 -0
  137. package/dist/vue-ui-waffle-IMEbGe-b.cjs +1 -0
  138. package/dist/vue-ui-wheel-CuOmEWMQ.cjs +1 -0
  139. package/dist/vue-ui-wheel-_zyCdFiI.js +227 -0
  140. package/dist/vue-ui-word-cloud-RDlXBEAN.js +346 -0
  141. package/dist/vue-ui-word-cloud-Y7Yk7uUJ.cjs +1 -0
  142. package/dist/vue-ui-xy-BZJQBKnU.cjs +3 -0
  143. package/dist/vue-ui-xy-DsvN9EIQ.js +2064 -0
  144. package/dist/vue-ui-xy-canvas-D_dnbyFS.cjs +9 -0
  145. package/dist/vue-ui-xy-canvas-Dbcw8-9Q.js +1006 -0
  146. package/package.json +1 -1
  147. package/dist/index-BcMihqI4.cjs +0 -843
  148. package/dist/index-C7FeCQ7K.js +0 -57303
@@ -0,0 +1,743 @@
1
+ import { computed as g, ref as c, onMounted as Be, onBeforeUnmount as Me, watch as Ge, openBlock as n, createElementBlock as r, normalizeClass as ae, normalizeStyle as C, renderSlot as b, createVNode as oe, createCommentVNode as d, createBlock as Y, unref as u, createSlots as Ue, withCtx as m, normalizeProps as q, guardReactiveProps as J, createElementVNode as f, Fragment as E, renderList as R, toDisplayString as k, createTextVNode as xe, nextTick as Ee, pushScopeId as Re, popScopeId as je } from "vue";
2
+ import { u as We, o as He, e as Ce, g as Xe, c as Ye, t as qe, a as Je, p as O, b as Ke, d as K, m as Qe, f as N, X as Ze, r as el, i as ll, j as h, k as j, v as $e, w as tl, n as al, q as ol } from "./index-uOtklCCx.js";
3
+ import { t as ul, u as sl } from "./useResponsive-NZB-WLRF.js";
4
+ import { _ as nl } from "./Title-2iks1ziC.js";
5
+ import { u as rl, U as il } from "./usePrinter-B6xQCyL-.js";
6
+ import { D as vl } from "./DataTable-CwaOlAsy.js";
7
+ import { _ as cl } from "./Tooltip-C3phqKuU.js";
8
+ import { L as dl } from "./Legend-CxvJTjEm.js";
9
+ import hl from "./vue-ui-skeleton-BM9rwmxY.js";
10
+ import yl from "./vue-ui-accordion-HJPf7My0.js";
11
+ import { u as Se } from "./useNestedProp-BgWkUab_.js";
12
+ import { _ as fl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
13
+ const gl = (V) => (Re("data-v-a76ecc28"), V = V(), je(), V), bl = ["id"], pl = ["xmlns", "viewBox"], ml = ["id"], wl = ["stop-color"], kl = ["stop-color"], _l = ["stop-color"], xl = ["id"], Cl = ["id"], $l = /* @__PURE__ */ gl(() => /* @__PURE__ */ f("feColorMatrix", {
14
+ type: "saturate",
15
+ values: "0"
16
+ }, null, -1)), Sl = ["id"], Tl = ["flood-color"], Ll = ["d", "stroke", "filter"], Fl = ["cx", "cy", "r", "fill", "filter"], zl = ["stroke", "d"], Nl = ["d", "fill", "stroke", "stroke-width", "filter"], Pl = ["cx", "cy", "r", "fill"], Ol = ["d", "fill", "onMouseenter", "onClick"], Il = ["cx", "cy", "r", "fill"], Al = ["x", "y", "fill", "font-size"], Dl = ["x", "y", "fill", "font-size"], Vl = ["x", "y", "fill", "font-size"], Bl = ["x", "y", "fill", "font-size"], Ml = ["filter"], Gl = { key: 0 }, Ul = ["x", "y"], El = { key: 1 }, Rl = ["cx", "cy", "fill", "filter", "onClick"], jl = ["text-anchor", "x", "y", "fill", "font-size", "onClick"], Wl = ["text-anchor", "x", "y", "fill", "font-size", "onClick"], Hl = { key: 2 }, Xl = ["x", "y", "width"], Yl = ["onClick"], ql = {
17
+ key: 0,
18
+ style: { "font-variant-numeric": "tabular-nums" }
19
+ }, Jl = { key: 1 }, Kl = ["innerHTML"], Ql = {
20
+ __name: "vue-ui-donut",
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", "selectDatapoint"],
36
+ setup(V, { expose: Te, emit: ue }) {
37
+ const $ = V, { vue_ui_donut: Le } = We(), B = g({
38
+ get() {
39
+ return !!$.dataset && $.dataset.length;
40
+ },
41
+ set(l) {
42
+ return l;
43
+ }
44
+ }), M = c(null), se = c(null), ne = c(null), W = c(null);
45
+ Be(() => {
46
+ if (He($.dataset) ? Ce({
47
+ componentName: "VueUiDonut",
48
+ type: "dataset"
49
+ }) : $.dataset.forEach((l, a) => {
50
+ Xe({
51
+ datasetObject: l,
52
+ requiredAttributes: ["name", "values"]
53
+ }).forEach((t) => {
54
+ B.value = !1, Ce({
55
+ componentName: "VueUiDonut",
56
+ type: "datasetSerieAttribute",
57
+ property: t,
58
+ index: a
59
+ });
60
+ });
61
+ }), e.value.responsive) {
62
+ const l = ul(() => {
63
+ const { width: a, height: t } = sl({
64
+ chart: M.value,
65
+ title: e.value.style.chart.title.text ? se.value : null,
66
+ legend: e.value.style.chart.legend.show ? ne.value : null
67
+ });
68
+ i.value.width = a, i.value.height = t;
69
+ });
70
+ W.value = new ResizeObserver(l), W.value.observe(M.value.parentNode);
71
+ }
72
+ }), Me(() => {
73
+ W.value && W.value.disconnect();
74
+ });
75
+ const _ = c(Ye()), Fe = c(null), Q = c(!1), Z = c(""), S = c(null), re = c(0), e = g(() => {
76
+ const l = Se({
77
+ userConfig: $.config,
78
+ defaultConfig: Le
79
+ });
80
+ return l.theme ? {
81
+ ...Se({
82
+ userConfig: qe.vue_ui_donut[l.theme] || $.config,
83
+ defaultConfig: l
84
+ }),
85
+ customPalette: Je[l.theme] || O
86
+ } : l;
87
+ }), { isPrinting: ze, isImaging: Ne, generatePdf: ie, generateImage: ve } = rl({
88
+ elementId: `donut__${_.value}`,
89
+ fileName: e.value.style.chart.title.text || "vue-ui-donut"
90
+ }), ce = g(() => Ke(e.value.customPalette)), y = c({
91
+ dataLabels: {
92
+ show: e.value.style.chart.layout.labels.dataLabels.show
93
+ },
94
+ showTable: e.value.table.show,
95
+ showTooltip: e.value.style.chart.tooltip.show
96
+ }), i = c({
97
+ height: 360,
98
+ width: 512
99
+ }), G = g(() => {
100
+ const l = e.value.style.chart.layout.donut.strokeWidth / 512, a = i.value.width * l;
101
+ return a > e.value.style.chart.layout.donut.strokeWidth ? e.value.style.chart.layout.donut.strokeWidth : a;
102
+ }), L = g(() => $.dataset.map((l, a) => ({
103
+ name: l.name,
104
+ color: K(l.color) || ce.value[a] || O[a] || O[a % O.length],
105
+ value: l.values.reduce((t, o) => t + o, 0),
106
+ absoluteValues: l.values,
107
+ comment: l.comment || ""
108
+ }))), w = c(L.value);
109
+ Ge(() => L.value, (l) => w.value = l);
110
+ function Pe() {
111
+ return L.value.map((l) => ({
112
+ name: l.name,
113
+ color: l.color,
114
+ value: l.value
115
+ }));
116
+ }
117
+ const x = c([]), de = c(null), he = c(null), I = c(!1);
118
+ function ye(l) {
119
+ const a = L.value.find((s, v) => v === l);
120
+ let o = w.value.find((s, v) => v === l).value;
121
+ if (x.value.includes(l)) {
122
+ let v = function() {
123
+ o > s ? (cancelAnimationFrame(de.value), w.value = w.value.map((p, te) => l === te ? {
124
+ ...p,
125
+ value: s
126
+ } : p), I.value = !1) : (I.value = !0, o += s * 0.025, w.value = w.value.map((p, te) => l === te ? {
127
+ ...p,
128
+ value: o
129
+ } : p), de.value = requestAnimationFrame(v));
130
+ };
131
+ x.value = x.value.filter((p) => p !== l);
132
+ const s = a.value;
133
+ v();
134
+ } else if (x.value.length < L.value.length - 1) {
135
+ let s = function() {
136
+ o < 0.1 ? (cancelAnimationFrame(he.value), x.value.push(l), w.value = w.value.map((v, p) => l === p ? {
137
+ ...v,
138
+ value: 0
139
+ } : v), I.value = !1) : (I.value = !0, o /= 1.1, w.value = w.value.map((v, p) => l === p ? {
140
+ ...v,
141
+ value: o
142
+ } : v), he.value = requestAnimationFrame(s));
143
+ };
144
+ s();
145
+ }
146
+ ue("selectLegend", A.value.map((s) => ({
147
+ name: s.name,
148
+ color: s.color,
149
+ value: s.value
150
+ })));
151
+ }
152
+ const A = g(() => (w.value.forEach((l, a) => {
153
+ if ([null, void 0].includes(l.values))
154
+ return {
155
+ ...l,
156
+ values: []
157
+ };
158
+ }), w.value.map((l, a) => ({
159
+ ...l,
160
+ seriesIndex: a
161
+ })).filter((l, a) => !x.value.includes(a)))), fe = g(() => $.dataset.map((l, a) => ({
162
+ name: l.name,
163
+ color: K(l.color) || ce.value[a] || O[a] || O[a % O.length],
164
+ value: (l.values || []).reduce((t, o) => t + o, 0),
165
+ shape: "circle"
166
+ })).map((l, a) => ({
167
+ ...l,
168
+ proportion: l.value / $.dataset.map((t) => (t.values || []).reduce((o, s) => o + s, 0)).reduce((t, o) => t + o, 0),
169
+ opacity: x.value.includes(a) ? 0.5 : 1,
170
+ segregate: () => ye(a),
171
+ isSegregated: x.value.includes(a)
172
+ }))), Oe = g(() => ({
173
+ cy: "donut-div-legend",
174
+ backgroundColor: e.value.style.chart.legend.backgroundColor,
175
+ color: e.value.style.chart.legend.color,
176
+ fontSize: e.value.style.chart.legend.fontSize,
177
+ paddingBottom: 12,
178
+ fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
179
+ })), F = g(() => {
180
+ const l = Math.min(i.value.width / 3, i.value.height / 3);
181
+ return l < 55 ? 55 : l;
182
+ }), P = g(() => Qe({ series: A.value }, i.value.width / 2, i.value.height / 2, F.value, F.value, 1.99999, 2, 1, 360, 105.25, G.value));
183
+ function D(l) {
184
+ return l.proportion * 100 > e.value.style.chart.layout.labels.dataLabels.hideUnderValue;
185
+ }
186
+ function ge(l, a) {
187
+ return isNaN(l.value / be(a)) ? 0 : (l.value / be(a) * 100).toFixed(0) + "%";
188
+ }
189
+ function be(l) {
190
+ return [...l].map((a) => a.value).reduce((a, t) => a + t, 0);
191
+ }
192
+ const T = g(() => A.value.map((l) => l.value).reduce((l, a) => l + a, 0)), Ie = g(() => T.value / A.value.length), ee = c(null);
193
+ function Ae({ datapoint: l, relativeIndex: a, seriesIndex: t, show: o = !1 }) {
194
+ ee.value = { datapoint: l, seriesIndex: t, config: e.value, series: L.value }, Q.value = o, S.value = a;
195
+ let s = "";
196
+ const v = e.value.style.chart.tooltip.customFormat;
197
+ $e(v) && tl(() => v({
198
+ seriesIndex: t,
199
+ datapoint: l,
200
+ series: L.value,
201
+ config: e.value
202
+ })) ? Z.value = v({
203
+ seriesIndex: t,
204
+ datapoint: l,
205
+ series: L.value,
206
+ config: e.value
207
+ }) : (s += `<div style="width:100%;text-align:center;border-bottom:1px solid ${e.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${l.name}</div>`, s += `<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="${l.color}"/></svg>`, e.value.style.chart.tooltip.showValue && (s += `<b>${N({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: l.value, s: e.value.style.chart.layout.labels.dataLabels.suffix, r: e.value.style.chart.tooltip.roundingValue })}</b>`), e.value.style.chart.tooltip.showPercentage && (e.value.style.chart.tooltip.showValue ? s += `<span>(${(l.proportion * 100).toFixed(e.value.style.chart.tooltip.roundingPercentage)}%)</span></div>` : s += `<b>${(l.proportion * 100).toFixed(e.value.style.chart.tooltip.roundingPercentage)}%</b></div>`), e.value.style.chart.comments.showInTooltip && l.comment && (s += `<div class="vue-data-ui-tooltip-comment" style="background:${l.color}20; padding: 6px; margin-bottom: 6px; margin-top:6px; border-left: 1px solid ${l.color}">${l.comment}</div>`), Z.value = `<div>${s}</div>`);
208
+ }
209
+ function le(l) {
210
+ return e.value.useBlurOnHover && ![null, void 0].includes(S.value) && S.value !== l ? `url(#blur_${_.value})` : "";
211
+ }
212
+ const z = g(() => {
213
+ const l = A.value.map((t) => ({
214
+ name: t.name,
215
+ color: t.color
216
+ })), a = A.value.map((t) => t.value);
217
+ return { head: l, body: a };
218
+ });
219
+ function pe() {
220
+ Ee(() => {
221
+ const l = z.value.head.map((o, s) => [[
222
+ o.name
223
+ ], [z.value.body[s]], [isNaN(z.value.body[s] / T.value) ? "-" : z.value.body[s] / T.value * 100]]), a = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], ["val"], ["%"]]].concat(l), t = al(a);
224
+ ol({ csvContent: t, title: e.value.style.chart.title.text || "vue-ui-donut" });
225
+ });
226
+ }
227
+ const H = g(() => {
228
+ const l = [
229
+ ' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>',
230
+ N({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: T.value, s: e.value.style.chart.layout.labels.dataLabels.suffix, r: e.value.table.td.roundingValue }),
231
+ "100%"
232
+ ], a = z.value.head.map((s, v) => {
233
+ const p = N({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: z.value.body[v], s: e.value.style.chart.layout.labels.dataLabels.suffix, r: e.value.table.td.roundingValue });
234
+ return [
235
+ {
236
+ color: s.color,
237
+ name: s.name
238
+ },
239
+ p,
240
+ isNaN(z.value.body[v] / T.value) ? "-" : (z.value.body[v] / T.value * 100).toFixed(e.value.table.td.roundingPercentage) + "%"
241
+ ];
242
+ }), t = {
243
+ th: {
244
+ backgroundColor: e.value.table.th.backgroundColor,
245
+ color: e.value.table.th.color,
246
+ outline: e.value.table.th.outline
247
+ },
248
+ td: {
249
+ backgroundColor: e.value.table.td.backgroundColor,
250
+ color: e.value.table.td.color,
251
+ outline: e.value.table.td.outline
252
+ },
253
+ breakpoint: e.value.table.responsiveBreakpoint
254
+ };
255
+ return {
256
+ colNames: [
257
+ e.value.table.columnNames.series,
258
+ e.value.table.columnNames.value,
259
+ e.value.table.columnNames.percentage
260
+ ],
261
+ head: l,
262
+ body: a,
263
+ config: t
264
+ };
265
+ }), U = c(!1);
266
+ function De(l) {
267
+ U.value = l, re.value += 1;
268
+ }
269
+ const me = g(() => /^((?!chrome|android).)*safari/i.test(navigator.userAgent));
270
+ function Ve(l) {
271
+ return l.toFixed(e.value.style.chart.legend.roundingPercentage).split("").map((a) => "-").join("");
272
+ }
273
+ function X(l, a) {
274
+ ue("selectDatapoint", { datapoint: l, index: a });
275
+ }
276
+ function we() {
277
+ y.value.showTable = !y.value.showTable;
278
+ }
279
+ function ke() {
280
+ y.value.dataLabels.show = !y.value.dataLabels.show;
281
+ }
282
+ function _e() {
283
+ y.value.showTooltip = !y.value.showTooltip;
284
+ }
285
+ return Te({
286
+ getData: Pe,
287
+ generatePdf: ie,
288
+ generateCsv: pe,
289
+ generateImage: ve,
290
+ toggleTable: we,
291
+ toggleLabels: ke,
292
+ toggleTooltip: _e
293
+ }), (l, a) => (n(), r("div", {
294
+ ref_key: "donutChart",
295
+ ref: M,
296
+ class: ae(`vue-ui-donut ${U.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
297
+ style: C(`font-family:${e.value.style.fontFamily};width:100%; ${e.value.responsive ? "height:100%;" : ""} text-align:center;${e.value.style.chart.title.text ? "" : "padding-top:36px"};background:${e.value.style.chart.backgroundColor}`),
298
+ id: `donut__${_.value}`
299
+ }, [
300
+ b(l.$slots, "userConfig", {}, void 0, !0),
301
+ e.value.style.chart.title.text ? (n(), r("div", {
302
+ key: 0,
303
+ ref_key: "chartTitle",
304
+ ref: se,
305
+ style: C(`width:100%;background:${e.value.style.chart.backgroundColor};padding-bottom:24px`)
306
+ }, [
307
+ oe(nl, {
308
+ config: {
309
+ title: {
310
+ cy: "donut-div-title",
311
+ ...e.value.style.chart.title
312
+ },
313
+ subtitle: {
314
+ cy: "donut-div-subtitle",
315
+ ...e.value.style.chart.title.subtitle
316
+ }
317
+ }
318
+ }, null, 8, ["config"])
319
+ ], 4)) : d("", !0),
320
+ e.value.userOptions.show && B.value ? (n(), Y(il, {
321
+ ref_key: "details",
322
+ ref: Fe,
323
+ key: `user_option_${re.value}`,
324
+ backgroundColor: e.value.style.chart.backgroundColor,
325
+ color: e.value.style.chart.color,
326
+ isPrinting: u(ze),
327
+ isImaging: u(Ne),
328
+ uid: _.value,
329
+ hasTooltip: e.value.style.chart.tooltip.show && e.value.userOptions.buttons.tooltip,
330
+ hasPdf: e.value.userOptions.buttons.pdf,
331
+ hasImg: e.value.userOptions.buttons.img,
332
+ hasXls: e.value.userOptions.buttons.csv,
333
+ hasTable: e.value.userOptions.buttons.table,
334
+ hasLabel: e.value.userOptions.buttons.labels,
335
+ hasFullscreen: e.value.userOptions.buttons.fullscreen,
336
+ isFullscreen: U.value,
337
+ chartElement: M.value,
338
+ isTooltip: y.value.showTooltip,
339
+ titles: { ...e.value.userOptions.buttonTitles },
340
+ onToggleFullscreen: De,
341
+ onGeneratePdf: u(ie),
342
+ onGenerateCsv: pe,
343
+ onGenerateImage: u(ve),
344
+ onToggleTable: we,
345
+ onToggleLabels: ke,
346
+ onToggleTooltip: _e
347
+ }, Ue({ _: 2 }, [
348
+ l.$slots.optionTooltip ? {
349
+ name: "optionTooltip",
350
+ fn: m(() => [
351
+ b(l.$slots, "optionTooltip", {}, void 0, !0)
352
+ ]),
353
+ key: "0"
354
+ } : void 0,
355
+ l.$slots.optionPdf ? {
356
+ name: "optionPdf",
357
+ fn: m(() => [
358
+ b(l.$slots, "optionPdf", {}, void 0, !0)
359
+ ]),
360
+ key: "1"
361
+ } : void 0,
362
+ l.$slots.optionCsv ? {
363
+ name: "optionCsv",
364
+ fn: m(() => [
365
+ b(l.$slots, "optionCsv", {}, void 0, !0)
366
+ ]),
367
+ key: "2"
368
+ } : void 0,
369
+ l.$slots.optionImg ? {
370
+ name: "optionImg",
371
+ fn: m(() => [
372
+ b(l.$slots, "optionImg", {}, void 0, !0)
373
+ ]),
374
+ key: "3"
375
+ } : void 0,
376
+ l.$slots.optionTable ? {
377
+ name: "optionTable",
378
+ fn: m(() => [
379
+ b(l.$slots, "optionTable", {}, void 0, !0)
380
+ ]),
381
+ key: "4"
382
+ } : void 0,
383
+ l.$slots.optionLabels ? {
384
+ name: "optionLabels",
385
+ fn: m(() => [
386
+ b(l.$slots, "optionLabels", {}, void 0, !0)
387
+ ]),
388
+ key: "5"
389
+ } : void 0,
390
+ l.$slots.optionFullscreen ? {
391
+ name: "optionFullscreen",
392
+ fn: m(({ toggleFullscreen: t, isFullscreen: o }) => [
393
+ b(l.$slots, "optionFullscreen", q(J({ toggleFullscreen: t, isFullscreen: o })), void 0, !0)
394
+ ]),
395
+ key: "6"
396
+ } : void 0
397
+ ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasTable", "hasLabel", "hasFullscreen", "isFullscreen", "chartElement", "isTooltip", "titles", "onGeneratePdf", "onGenerateImage"])) : d("", !0),
398
+ B.value ? (n(), r("svg", {
399
+ key: 2,
400
+ xmlns: u(Ze),
401
+ class: ae({ "vue-data-ui-fullscreen--on": U.value, "vue-data-ui-fulscreen--off": !U.value }),
402
+ viewBox: `0 0 ${i.value.width <= 0 ? 10 : i.value.width} ${i.value.height <= 0 ? 10 : i.value.height}`,
403
+ style: C(`max-width:100%; overflow: visible; background:${e.value.style.chart.backgroundColor};color:${e.value.style.chart.color}`)
404
+ }, [
405
+ f("defs", null, [
406
+ e.value.style.chart.useGradient ? (n(), r("radialGradient", {
407
+ key: 0,
408
+ id: `gradient_${_.value}`
409
+ }, [
410
+ f("stop", {
411
+ offset: "0%",
412
+ "stop-color": `${u(K)(e.value.style.chart.backgroundColor)}00`
413
+ }, null, 8, wl),
414
+ f("stop", {
415
+ offset: "77%",
416
+ "stop-color": "#FFFFFF" + u(el)[e.value.style.chart.gradientIntensity]
417
+ }, null, 8, kl),
418
+ f("stop", {
419
+ offset: "100%",
420
+ "stop-color": `${u(K)(e.value.style.chart.backgroundColor)}00`
421
+ }, null, 8, _l)
422
+ ], 8, ml)) : d("", !0)
423
+ ]),
424
+ f("defs", null, [
425
+ f("filter", {
426
+ id: `blur_${_.value}`,
427
+ x: "-50%",
428
+ y: "-50%",
429
+ width: "200%",
430
+ height: "200%"
431
+ }, [
432
+ f("feGaussianBlur", {
433
+ in: "SourceGraphic",
434
+ stdDeviation: 2,
435
+ id: `blur_std_${_.value}`
436
+ }, null, 8, Cl),
437
+ $l
438
+ ], 8, xl),
439
+ f("filter", {
440
+ id: `shadow_${_.value}`,
441
+ "color-interpolation-filters": "sRGB"
442
+ }, [
443
+ f("feDropShadow", {
444
+ dx: "0",
445
+ dy: "0",
446
+ stdDeviation: "10",
447
+ "flood-opacity": "0.5",
448
+ "flood-color": e.value.style.chart.layout.donut.shadowColor
449
+ }, null, 8, Tl)
450
+ ], 8, Sl)
451
+ ]),
452
+ (n(!0), r(E, null, R(P.value, (t, o) => (n(), r("g", null, [
453
+ D(t) && y.value.dataLabels.show ? (n(), r("path", {
454
+ key: 0,
455
+ d: u(ll)(t, { x: i.value.width / 2, y: i.value.height / 2 }, 16, 16, !1, !1, G.value),
456
+ stroke: t.color,
457
+ "stroke-width": "1",
458
+ "stroke-linecap": "round",
459
+ "stroke-linejoin": "round",
460
+ fill: "none",
461
+ filter: le(o)
462
+ }, null, 8, Ll)) : d("", !0)
463
+ ]))), 256)),
464
+ f("circle", {
465
+ cx: i.value.width / 2,
466
+ cy: i.value.height / 2,
467
+ r: F.value <= 0 ? 10 : F.value,
468
+ fill: e.value.style.chart.backgroundColor,
469
+ filter: e.value.style.chart.layout.donut.useShadow ? `url(#shadow_${_.value})` : ""
470
+ }, null, 8, Fl),
471
+ (n(!0), r(E, null, R(P.value, (t, o) => (n(), r("path", {
472
+ stroke: e.value.style.chart.backgroundColor,
473
+ d: t.arcSlice,
474
+ fill: "#FFFFFF"
475
+ }, null, 8, zl))), 256)),
476
+ (n(!0), r(E, null, R(P.value, (t, o) => (n(), r("path", {
477
+ class: "vue-ui-donut-arc-path",
478
+ d: t.arcSlice,
479
+ fill: `${t.color}CC`,
480
+ stroke: e.value.style.chart.backgroundColor,
481
+ "stroke-width": e.value.style.chart.layout.donut.borderWidth,
482
+ filter: le(o)
483
+ }, null, 8, Nl))), 256)),
484
+ e.value.style.chart.useGradient ? (n(), r("circle", {
485
+ key: 0,
486
+ cx: i.value.width / 2,
487
+ cy: i.value.height / 2,
488
+ r: (
489
+ /* This might require adjustments */
490
+ F.value <= 0 ? 10 : F.value
491
+ ),
492
+ fill: `url(#gradient_${_.value})`
493
+ }, null, 8, Pl)) : d("", !0),
494
+ (n(!0), r(E, null, R(P.value, (t, o) => (n(), r("path", {
495
+ "data-cy-donut-trap": "",
496
+ d: t.arcSlice,
497
+ fill: S.value === o ? "rgba(0,0,0,0.1)" : "transparent",
498
+ onMouseenter: (s) => Ae({
499
+ datapoint: t,
500
+ relativeIndex: o,
501
+ seriesIndex: t.seriesIndex,
502
+ show: !0
503
+ }),
504
+ onMouseleave: a[0] || (a[0] = (s) => {
505
+ Q.value = !1, S.value = null;
506
+ }),
507
+ onClick: (s) => X(t, o)
508
+ }, null, 40, Ol))), 256)),
509
+ e.value.style.chart.layout.labels.hollow.show ? (n(), r("circle", {
510
+ key: 1,
511
+ cx: i.value.width / 2,
512
+ cy: i.value.height / 2,
513
+ r: (
514
+ /* This might require adjustments */
515
+ F.value - G.value <= 0 ? 10 : F.value - G.value
516
+ ),
517
+ fill: e.value.style.chart.backgroundColor
518
+ }, null, 8, Il)) : d("", !0),
519
+ e.value.style.chart.layout.labels.hollow.total.show ? (n(), r("text", {
520
+ key: 2,
521
+ "text-anchor": "middle",
522
+ x: i.value.width / 2,
523
+ y: i.value.height / 2 - (e.value.style.chart.layout.labels.hollow.average.show ? e.value.style.chart.layout.labels.hollow.total.fontSize : 0) + e.value.style.chart.layout.labels.hollow.total.offsetY,
524
+ fill: e.value.style.chart.layout.labels.hollow.total.color,
525
+ "font-size": e.value.style.chart.layout.labels.hollow.total.fontSize,
526
+ style: C(`font-weight:${e.value.style.chart.layout.labels.hollow.total.bold ? "bold" : ""}`)
527
+ }, k(e.value.style.chart.layout.labels.hollow.total.text), 13, Al)) : d("", !0),
528
+ e.value.style.chart.layout.labels.hollow.total.show ? (n(), r("text", {
529
+ key: 3,
530
+ "text-anchor": "middle",
531
+ x: i.value.width / 2,
532
+ y: i.value.height / 2 + e.value.style.chart.layout.labels.hollow.total.fontSize - (e.value.style.chart.layout.labels.hollow.average.show ? e.value.style.chart.layout.labels.hollow.total.fontSize : 0) + e.value.style.chart.layout.labels.hollow.total.value.offsetY,
533
+ fill: e.value.style.chart.layout.labels.hollow.total.value.color,
534
+ "font-size": e.value.style.chart.layout.labels.hollow.total.value.fontSize,
535
+ style: C(`font-weight:${e.value.style.chart.layout.labels.hollow.total.value.bold ? "bold" : ""}`)
536
+ }, k(u(N)({
537
+ p: e.value.style.chart.layout.labels.hollow.total.value.prefix,
538
+ v: T.value,
539
+ s: e.value.style.chart.layout.labels.hollow.total.value.suffix
540
+ })), 13, Dl)) : d("", !0),
541
+ e.value.style.chart.layout.labels.hollow.average.show ? (n(), r("text", {
542
+ key: 4,
543
+ "text-anchor": "middle",
544
+ x: i.value.width / 2,
545
+ y: i.value.height / 2 + (e.value.style.chart.layout.labels.hollow.total.show ? e.value.style.chart.layout.labels.hollow.average.fontSize : 0) + e.value.style.chart.layout.labels.hollow.average.offsetY,
546
+ fill: e.value.style.chart.layout.labels.hollow.average.color,
547
+ "font-size": e.value.style.chart.layout.labels.hollow.average.fontSize,
548
+ style: C(`font-weight:${e.value.style.chart.layout.labels.hollow.average.bold ? "bold" : ""}`)
549
+ }, k(e.value.style.chart.layout.labels.hollow.average.text), 13, Vl)) : d("", !0),
550
+ e.value.style.chart.layout.labels.hollow.average.show ? (n(), r("text", {
551
+ key: 5,
552
+ "text-anchor": "middle",
553
+ x: i.value.width / 2,
554
+ y: i.value.height / 2 + (e.value.style.chart.layout.labels.hollow.total.show ? e.value.style.chart.layout.labels.hollow.average.fontSize : 0) + e.value.style.chart.layout.labels.hollow.average.fontSize + e.value.style.chart.layout.labels.hollow.average.value.offsetY,
555
+ fill: e.value.style.chart.layout.labels.hollow.average.value.color,
556
+ "font-size": e.value.style.chart.layout.labels.hollow.average.value.fontSize,
557
+ style: C(`font-weight:${e.value.style.chart.layout.labels.hollow.average.value.bold ? "bold" : ""}`)
558
+ }, k(I.value ? "--" : u(N)({
559
+ p: e.value.style.chart.layout.labels.hollow.average.value.prefix,
560
+ v: Ie.value,
561
+ s: e.value.style.chart.layout.labels.hollow.average.value.suffix,
562
+ r: e.value.style.chart.layout.labels.hollow.average.value.rounding
563
+ })), 13, Bl)) : d("", !0),
564
+ (n(!0), r(E, null, R(P.value, (t, o) => (n(), r("g", {
565
+ filter: le(o),
566
+ class: ae({ animated: e.value.useCssAnimation })
567
+ }, [
568
+ e.value.style.chart.layout.labels.dataLabels.useLabelSlots ? (n(), r("g", Gl, [
569
+ (n(), r("foreignObject", {
570
+ x: u(h)(t, !0).anchor === "end" ? u(h)(t).x - 120 : u(h)(t, !0).anchor === "middle" ? u(h)(t).x - 60 : u(h)(t).x,
571
+ y: u(j)(t) - (me.value ? 20 : 0),
572
+ width: "120",
573
+ height: "60",
574
+ style: { overflow: "visible" }
575
+ }, [
576
+ f("div", null, [
577
+ b(l.$slots, "dataLabel", q(J({
578
+ datapoint: t,
579
+ isBlur: !e.value.useBlurOnHover || [null, void 0].includes(S.value) || S.value === o,
580
+ isSafari: me.value,
581
+ isVisible: D(t) && y.value.dataLabels.show,
582
+ textAlign: u(h)(t, !0, 16, !0).anchor,
583
+ flexAlign: u(h)(t, !0, 16).anchor,
584
+ percentage: ge(t, P.value)
585
+ })), void 0, !0)
586
+ ])
587
+ ], 8, Ul))
588
+ ])) : (n(), r("g", El, [
589
+ D(t) && y.value.dataLabels.show ? (n(), r("circle", {
590
+ key: 0,
591
+ cx: u(h)(t).x,
592
+ cy: u(j)(t) - 3.5,
593
+ fill: t.color,
594
+ r: 3,
595
+ filter: !e.value.useBlurOnHover || [null, void 0].includes(S.value) || S.value === o ? "" : `url(#blur_${_.value})`,
596
+ onClick: (s) => X(t, o)
597
+ }, null, 8, Rl)) : d("", !0),
598
+ D(t) && y.value.dataLabels.show ? (n(), r("text", {
599
+ key: 1,
600
+ "text-anchor": u(h)(t, !0, 12).anchor,
601
+ x: u(h)(t, !0, 12).x,
602
+ y: u(j)(t),
603
+ fill: e.value.style.chart.layout.labels.percentage.color,
604
+ "font-size": e.value.style.chart.layout.labels.percentage.fontSize,
605
+ style: C(`font-weight:${e.value.style.chart.layout.labels.percentage.bold ? "bold" : ""}`),
606
+ onClick: (s) => X(t, o)
607
+ }, k(ge(t, P.value)) + " " + k(e.value.style.chart.layout.labels.value.show ? `(${u(N)({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: t.value, s: e.value.style.chart.layout.labels.dataLabels.suffix, rounding: e.value.style.chart.layout.labels.value.rounding })})` : ""), 13, jl)) : d("", !0),
608
+ D(t) && y.value.dataLabels.show ? (n(), r("text", {
609
+ key: 2,
610
+ "text-anchor": u(h)(t).anchor,
611
+ x: u(h)(t, !0, 12).x,
612
+ y: u(j)(t) + e.value.style.chart.layout.labels.percentage.fontSize,
613
+ fill: e.value.style.chart.layout.labels.name.color,
614
+ "font-size": e.value.style.chart.layout.labels.name.fontSize,
615
+ style: C(`font-weight:${e.value.style.chart.layout.labels.name.bold ? "bold" : ""}`),
616
+ onClick: (s) => X(t, o)
617
+ }, k(t.name), 13, Wl)) : d("", !0)
618
+ ])),
619
+ y.value.dataLabels.show && e.value.style.chart.comments.show && t.comment ? (n(), r("g", Hl, [
620
+ D(t) ? (n(), r("foreignObject", {
621
+ key: 0,
622
+ x: e.value.style.chart.comments.offsetX + (u(h)(t, !0).anchor === "end" ? u(h)(t).x - e.value.style.chart.comments.width : u(h)(t, !0).anchor === "middle" ? u(h)(t).x - e.value.style.chart.comments.width / 2 : u(h)(t).x),
623
+ y: u(j)(t) + 24 + e.value.style.chart.comments.offsetY,
624
+ width: e.value.style.chart.comments.width,
625
+ height: "200",
626
+ style: { overflow: "visible", "pointer-events": "none" }
627
+ }, [
628
+ f("div", null, [
629
+ b(l.$slots, "plot-comment", {
630
+ plot: { ...t, textAlign: u(h)(t, !0, 16, !0).anchor, flexAlign: u(h)(t, !0, 16).anchor }
631
+ }, void 0, !0)
632
+ ])
633
+ ], 8, Xl)) : d("", !0)
634
+ ])) : d("", !0)
635
+ ], 10, Ml))), 256)),
636
+ b(l.$slots, "svg", { svg: i.value }, void 0, !0)
637
+ ], 14, pl)) : d("", !0),
638
+ B.value ? d("", !0) : (n(), Y(hl, {
639
+ key: 3,
640
+ config: {
641
+ type: "donut",
642
+ style: {
643
+ backgroundColor: e.value.style.chart.backgroundColor,
644
+ donut: {
645
+ color: "#CCCCCC",
646
+ strokeWidth: G.value * 0.8
647
+ }
648
+ }
649
+ }
650
+ }, null, 8, ["config"])),
651
+ f("div", {
652
+ ref_key: "chartLegend",
653
+ ref: ne
654
+ }, [
655
+ e.value.style.chart.legend.show ? (n(), Y(dl, {
656
+ key: 0,
657
+ legendSet: fe.value,
658
+ config: Oe.value,
659
+ onClickMarker: a[1] || (a[1] = ({ i: t }) => ye(t))
660
+ }, {
661
+ item: m(({ legend: t, index: o }) => [
662
+ f("div", {
663
+ onClick: (s) => t.segregate(),
664
+ style: C(`opacity:${x.value.includes(o) ? 0.5 : 1}`)
665
+ }, [
666
+ xe(k(t.name) + ": " + k(u(N)({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: t.value, s: e.value.style.chart.layout.labels.dataLabels.suffix, r: e.value.style.chart.legend.roundingValue })) + " ", 1),
667
+ x.value.includes(o) ? (n(), r("span", Jl, " ( " + k(Ve(t.proportion * 100)) + " % ) ", 1)) : (n(), r("span", ql, " (" + k(isNaN(t.value / T.value) ? "-" : u(N)({
668
+ v: I.value ? t.proportion * 100 : t.value / T.value * 100,
669
+ s: "%",
670
+ r: e.value.style.chart.legend.roundingPercentage
671
+ })) + ") ", 1))
672
+ ], 12, Yl)
673
+ ]),
674
+ _: 1
675
+ }, 8, ["legendSet", "config"])) : d("", !0),
676
+ b(l.$slots, "legend", { legend: fe.value }, void 0, !0)
677
+ ], 512),
678
+ oe(cl, {
679
+ show: y.value.showTooltip && Q.value,
680
+ backgroundColor: e.value.style.chart.tooltip.backgroundColor,
681
+ color: e.value.style.chart.tooltip.color,
682
+ fontSize: e.value.style.chart.tooltip.fontSize,
683
+ borderRadius: e.value.style.chart.tooltip.borderRadius,
684
+ borderColor: e.value.style.chart.tooltip.borderColor,
685
+ borderWidth: e.value.style.chart.tooltip.borderWidth,
686
+ backgroundOpacity: e.value.style.chart.tooltip.backgroundOpacity,
687
+ parent: M.value,
688
+ content: Z.value,
689
+ isCustom: u($e)(e.value.style.chart.tooltip.customFormat)
690
+ }, {
691
+ "tooltip-before": m(() => [
692
+ b(l.$slots, "tooltip-before", q(J({ ...ee.value })), void 0, !0)
693
+ ]),
694
+ "tooltip-after": m(() => [
695
+ b(l.$slots, "tooltip-after", q(J({ ...ee.value })), void 0, !0)
696
+ ]),
697
+ _: 3
698
+ }, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "parent", "content", "isCustom"]),
699
+ B.value ? (n(), Y(yl, {
700
+ key: 4,
701
+ hideDetails: "",
702
+ config: {
703
+ open: y.value.showTable,
704
+ maxHeight: 1e4,
705
+ body: {
706
+ backgroundColor: e.value.style.chart.backgroundColor,
707
+ color: e.value.style.chart.color
708
+ },
709
+ head: {
710
+ backgroundColor: e.value.style.chart.backgroundColor,
711
+ color: e.value.style.chart.color
712
+ }
713
+ }
714
+ }, {
715
+ content: m(() => [
716
+ oe(vl, {
717
+ colNames: H.value.colNames,
718
+ head: H.value.head,
719
+ body: H.value.body,
720
+ config: H.value.config,
721
+ title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
722
+ onClose: a[2] || (a[2] = (t) => y.value.showTable = !1)
723
+ }, {
724
+ th: m(({ th: t }) => [
725
+ f("div", {
726
+ innerHTML: t,
727
+ style: { display: "flex", "align-items": "center" }
728
+ }, null, 8, Kl)
729
+ ]),
730
+ td: m(({ td: t }) => [
731
+ xe(k(t.name || t), 1)
732
+ ]),
733
+ _: 1
734
+ }, 8, ["colNames", "head", "body", "config", "title"])
735
+ ]),
736
+ _: 1
737
+ }, 8, ["config"])) : d("", !0)
738
+ ], 14, bl));
739
+ }
740
+ }, ct = /* @__PURE__ */ fl(Ql, [["__scopeId", "data-v-a76ecc28"]]);
741
+ export {
742
+ ct as default
743
+ };