vue-data-ui 3.0.6 → 3.0.7

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 (89) hide show
  1. package/dist/{Arrow-eH6zr7jY.js → Arrow-BZRmraR1.js} +1 -1
  2. package/dist/{BaseDraggableDialog-COBKT377.js → BaseDraggableDialog-BdrogsDa.js} +2 -2
  3. package/dist/{BaseIcon-BP55sAS4.js → BaseIcon-BkcnpqIi.js} +1 -1
  4. package/dist/{ColorPicker-rtpGZvge.js → ColorPicker-BpkLwvQo.js} +2 -2
  5. package/dist/{DataTable-BsZNCCiq.js → DataTable-C6tKzvDk.js} +2 -2
  6. package/dist/{Legend-DvgvB-wU.js → Legend-SO9DUwca.js} +2 -2
  7. package/dist/{NonSvgPenAndPaper-CmTVzs9z.js → NonSvgPenAndPaper-ydwZCvBB.js} +3 -3
  8. package/dist/{PackageVersion-CceJ5BO0.js → PackageVersion-CvDEwhqw.js} +1 -1
  9. package/dist/{PenAndPaper-CEyTp4aY.js → PenAndPaper-CK0i-_WG.js} +3 -3
  10. package/dist/{Shape-DfDVJHIa.js → Shape-DNSjpQA9.js} +1 -1
  11. package/dist/{Slicer-CPxX7TxR.js → Slicer-BCwIdbth.js} +2 -2
  12. package/dist/{SparkTooltip-BIBtUxe0.js → SparkTooltip--GJjZ38c.js} +1 -1
  13. package/dist/{Title-CP-52fsT.js → Title-pwfhlClh.js} +1 -1
  14. package/dist/{Tooltip-CvVNyNmi.js → Tooltip-DLU3yWUJ.js} +1 -1
  15. package/dist/{UserOptions-Dpg2ZAMi.js → UserOptions-hQcfD5wC.js} +2 -2
  16. package/dist/{dom-to-png-BHK8mbAk.js → dom-to-png-C9CPYmoW.js} +1 -1
  17. package/dist/{img-B2EzIOH4.js → img-CPlo7hfi.js} +1 -1
  18. package/dist/{index-CEtY3Y6T.js → index-X9QjRsk0.js} +1 -1
  19. package/dist/{pdf-Dif2Rumm.js → pdf-TMCTkZTN.js} +1 -1
  20. package/dist/style.css +1 -1
  21. package/dist/{useAutoSizeLabelsInsideViewbox-CxfMGWAl.js → useAutoSizeLabelsInsideViewbox-Dd2F3rJF.js} +1 -1
  22. package/dist/{useNestedProp-Ii3lZlzP.js → useNestedProp-BlGOG6Rv.js} +1 -1
  23. package/dist/{usePrinter-Ct_ga1BV.js → usePrinter-UBjM9siG.js} +2 -2
  24. package/dist/{vue-data-ui-DOxUijlC.js → vue-data-ui-CCY7uFJq.js} +64 -64
  25. package/dist/vue-data-ui.js +1 -1
  26. package/dist/{vue-ui-3d-bar-CXBcUwwa.js → vue-ui-3d-bar-8gsivSLU.js} +6 -6
  27. package/dist/{vue-ui-accordion-Dd45N8sR.js → vue-ui-accordion-CAB71G5L.js} +3 -3
  28. package/dist/{vue-ui-age-pyramid-5z3bXquO.js → vue-ui-age-pyramid-CSkZ6Ua7.js} +6 -6
  29. package/dist/{vue-ui-annotator-CGVAEYVg.js → vue-ui-annotator-QoSiZY9-.js} +2 -2
  30. package/dist/{vue-ui-bullet-2JkdnFzw.js → vue-ui-bullet-BBnNRqVS.js} +7 -7
  31. package/dist/{vue-ui-candlestick-B2vUnWpp.js → vue-ui-candlestick-pEmkavlN.js} +7 -7
  32. package/dist/{vue-ui-carousel-table-Bo_zripj.js → vue-ui-carousel-table-BMSJwhTI.js} +4 -4
  33. package/dist/{vue-ui-chestnut-Czd_DM6l.js → vue-ui-chestnut-DOEN_lW9.js} +5 -5
  34. package/dist/{vue-ui-chord-Cc01LLih.js → vue-ui-chord-DP6ejN3_.js} +8 -8
  35. package/dist/{vue-ui-circle-pack-DKLt8ose.js → vue-ui-circle-pack-D7o9RWUg.js} +6 -6
  36. package/dist/{vue-ui-cursor-jknHE5vU.js → vue-ui-cursor-BGCO9EXx.js} +2 -2
  37. package/dist/{vue-ui-dashboard-B33lfAUU.js → vue-ui-dashboard-B8jJfBT8.js} +62 -62
  38. package/dist/{vue-ui-digits-BMeVQa49.js → vue-ui-digits-CNzQjtvo.js} +2 -2
  39. package/dist/{vue-ui-donut-CqTEpXzh.js → vue-ui-donut-B5W9UNxG.js} +8 -8
  40. package/dist/{vue-ui-donut-evolution-Nd1QRPT4.js → vue-ui-donut-evolution-C9VWqv0X.js} +8 -8
  41. package/dist/{vue-ui-dumbbell-Ce-OIdYx.js → vue-ui-dumbbell-CjAjuZOC.js} +7 -7
  42. package/dist/{vue-ui-flow-CGVrdlGQ.js → vue-ui-flow-DPL2-zGO.js} +7 -7
  43. package/dist/{vue-ui-funnel-Duha39HH.js → vue-ui-funnel-CazDK5_K.js} +6 -6
  44. package/dist/{vue-ui-galaxy-DHB0-OzZ.js → vue-ui-galaxy-DzHIe_GL.js} +5 -5
  45. package/dist/{vue-ui-gauge-BfdfKC8k.js → vue-ui-gauge-D-FH7KFb.js} +7 -7
  46. package/dist/{vue-ui-gizmo-6cvygvrc.js → vue-ui-gizmo-CiWDSmw3.js} +3 -3
  47. package/dist/{vue-ui-heatmap-DADmzQtU.js → vue-ui-heatmap-BRjd34ZG.js} +7 -7
  48. package/dist/{vue-ui-history-plot-C3vI04Oa.js → vue-ui-history-plot-D2U7a7h5.js} +7 -7
  49. package/dist/{vue-ui-kpi-BxzL6n29.js → vue-ui-kpi-5Gsv9ny8.js} +3 -3
  50. package/dist/{vue-ui-mini-loader-DCxaFsu5.js → vue-ui-mini-loader-3cTXDL4W.js} +2 -2
  51. package/dist/{vue-ui-molecule-d5w-FfYZ.js → vue-ui-molecule-ZFYcriLZ.js} +5 -5
  52. package/dist/{vue-ui-mood-radar-C4Lf_qiv.js → vue-ui-mood-radar-B2_06p65.js} +7 -7
  53. package/dist/{vue-ui-nested-donuts-DOsvyspN.js → vue-ui-nested-donuts-DzDl68ll.js} +7 -7
  54. package/dist/{vue-ui-onion-DxYequON.js → vue-ui-onion-BFLjpr5J.js} +8 -8
  55. package/dist/{vue-ui-parallel-coordinate-plot-C1o_ksGH.js → vue-ui-parallel-coordinate-plot-C4TZzF54.js} +8 -8
  56. package/dist/{vue-ui-quadrant-Sjwp-p_C.js → vue-ui-quadrant-4PhgLNCs.js} +8 -8
  57. package/dist/{vue-ui-quick-chart-BTeSWjue.js → vue-ui-quick-chart-B32psfnY.js} +6 -6
  58. package/dist/{vue-ui-radar-Ch90-xXN.js → vue-ui-radar-DUUNLml-.js} +8 -8
  59. package/dist/{vue-ui-rating-8O36Avyg.js → vue-ui-rating-BAVqgA09.js} +2 -2
  60. package/dist/{vue-ui-relation-circle-ACSD26Ko.js → vue-ui-relation-circle-ke3sj18W.js} +7 -7
  61. package/dist/{vue-ui-ridgeline-DgsBpi6c.js → vue-ui-ridgeline-DaGjIQqX.js} +8 -8
  62. package/dist/{vue-ui-rings-B30B7Rk9.js → vue-ui-rings-mJVJ-F7L.js} +8 -8
  63. package/dist/{vue-ui-scatter-BYs-Mwmm.js → vue-ui-scatter-BJC6eHcD.js} +8 -8
  64. package/dist/{vue-ui-skeleton-DtfU9Y-p.js → vue-ui-skeleton-BSXjLnfB.js} +3 -3
  65. package/dist/{vue-ui-smiley-z_Un5JJa.js → vue-ui-smiley-bDakIWEZ.js} +2 -2
  66. package/dist/{vue-ui-spark-trend-2MlSpWd0.js → vue-ui-spark-trend-ChIma8EU.js} +3 -3
  67. package/dist/{vue-ui-sparkbar-2cdzKOzM.js → vue-ui-sparkbar-CxrCU2R9.js} +3 -3
  68. package/dist/{vue-ui-sparkgauge-D7RfFrjJ.js → vue-ui-sparkgauge-Dq9AE7z6.js} +3 -3
  69. package/dist/{vue-ui-sparkhistogram-CBg8GDrZ.js → vue-ui-sparkhistogram-BYe8Ugtg.js} +4 -4
  70. package/dist/{vue-ui-sparkline-C2umA4Q6.js → vue-ui-sparkline-BIShtqVB.js} +3 -3
  71. package/dist/{vue-ui-sparkstackbar-BVADf3Tk.js → vue-ui-sparkstackbar-BwlNPK-F.js} +3 -3
  72. package/dist/{vue-ui-stackbar-DMPlvwcH.js → vue-ui-stackbar-DP8xLhDL.js} +9 -9
  73. package/dist/{vue-ui-strip-plot-BUDIS-ii.js → vue-ui-strip-plot-BaLfhaq2.js} +7 -7
  74. package/dist/{vue-ui-table-DFHkKJkK.js → vue-ui-table-DVgHFZen.js} +3 -3
  75. package/dist/{vue-ui-table-heatmap-Es8n714c.js → vue-ui-table-heatmap-CUvoaF7m.js} +5 -5
  76. package/dist/{vue-ui-table-sparkline-D8kLXwZc.js → vue-ui-table-sparkline-CgODT4oZ.js} +4 -4
  77. package/dist/{vue-ui-thermometer-BTVzQ73I.js → vue-ui-thermometer-Cneb68tl.js} +7 -7
  78. package/dist/{vue-ui-timer-BnLRbn1q.js → vue-ui-timer-DtbJrKKv.js} +5 -5
  79. package/dist/{vue-ui-tiremarks-C1Kvt5oV.js → vue-ui-tiremarks-Ci0IPa1a.js} +6 -6
  80. package/dist/{vue-ui-treemap-DXN635ri.js → vue-ui-treemap-Cr30jnpe.js} +8 -8
  81. package/dist/{vue-ui-vertical-bar-CAqZZ_jh.js → vue-ui-vertical-bar-B0iGUN2i.js} +9 -9
  82. package/dist/{vue-ui-waffle-BTi4u658.js → vue-ui-waffle-BiEWuwjg.js} +8 -8
  83. package/dist/{vue-ui-wheel-BbN4D8MA.js → vue-ui-wheel-WVGrA4A6.js} +6 -6
  84. package/dist/{vue-ui-word-cloud-QkDzSzu9.js → vue-ui-word-cloud-DZSVMHcA.js} +6 -6
  85. package/dist/{vue-ui-world-R-fy7YWW.js → vue-ui-world-CJmuqZE1.js} +6 -6
  86. package/dist/vue-ui-xy-CjDYvhnu.js +3920 -0
  87. package/dist/{vue-ui-xy-canvas-1MwhA5v2.js → vue-ui-xy-canvas-D0kxBtNF.js} +8 -8
  88. package/package.json +1 -1
  89. package/dist/vue-ui-xy-DN1PKeQk.js +0 -3905
@@ -0,0 +1,3920 @@
1
+ import { useCssVars as co, computed as b, ref as p, onMounted as bl, onBeforeUnmount as pl, watch as vt, nextTick as ll, onUpdated as vo, createElementBlock as i, openBlock as n, createElementVNode as x, createCommentVNode as f, renderSlot as J, normalizeStyle as L, createVNode as tl, withDirectives as Zl, unref as v, Fragment as g, renderList as C, normalizeClass as Be, withKeys as Aa, vModelText as za, toDisplayString as ae, defineAsyncComponent as Lt, useSlots as ho, getCurrentInstance as fo, toRefs as mo, watchEffect as go, createBlock as Ge, createSlots as xo, withCtx as ge, normalizeProps as bt, guardReactiveProps as Mt, mergeProps as zl, Teleport as bo, vModelCheckbox as po, createTextVNode as yo } from "vue";
2
+ import { c as Rl, V as Pl, U as Ol, X as ko, F as et, u as wo, f as Gl, t as So, a4 as Qe, d as $o, D as xl, ac as Et, e as _o, p as Lo, ad as Tl, a9 as X, ae as Mo, h as B, af as Ta, ag as Ia, ah as Co, ai as Na, aj as Ra, k as Se, ak as Ao, y as Pa, z as zo, _ as Oa, R as ct, i as Ue, x as Ft, s as je, a7 as j, L as To, al as Il, I as Io, am as Ct, C as Ze, a as No, b as Ro, o as Ha, v as Po, w as Oo, E as el } from "./index-X9QjRsk0.js";
3
+ import { t as ql, u as Ho } from "./useResponsive-DfdjqQps.js";
4
+ import { u as Vo } from "./usePrinter-UBjM9siG.js";
5
+ import { u as Bo, B as Eo } from "./useLoading-D7YHNtLX.js";
6
+ import { u as Ul } from "./useNestedProp-BlGOG6Rv.js";
7
+ import { u as Va } from "./useTimeLabels-DkzmKfZn.js";
8
+ import { u as Fo } from "./useTimeLabelCollider-CIsgDrl9.js";
9
+ import Wo from "./img-CPlo7hfi.js";
10
+ import Do from "./Title-pwfhlClh.js";
11
+ import { S as Yo } from "./Slicer-BCwIdbth.js";
12
+ import { _ as Nl } from "./Shape-DNSjpQA9.js";
13
+ import Xo from "./BaseIcon-BkcnpqIi.js";
14
+ import { _ as Ba } from "./_plugin-vue_export-helper-CHgC5LLL.js";
15
+ const Go = {
16
+ class: "vue-data-ui-slicer-labels",
17
+ style: { position: "relative", "z-index": "1", "pointer-events": "none" }
18
+ }, Uo = {
19
+ key: 0,
20
+ style: { width: "100%", position: "relative" }
21
+ }, Zo = {
22
+ key: 0,
23
+ class: "minimap",
24
+ style: { width: "100%" }
25
+ }, qo = ["xmlns", "viewBox"], Ko = ["id"], Jo = ["stop-color"], Qo = ["d", "stroke"], jo = ["x", "width", "height", "fill", "rx"], en = ["d", "fill"], tn = ["x", "width", "height", "rx", "fill"], ln = ["x", "width", "height", "fill", "rx"], an = ["d", "fill"], on = ["d", "stroke"], nn = ["cx", "cy", "stroke", "fill"], un = ["cx", "cy", "stroke", "fill"], sn = ["x1", "x2", "y2", "stroke"], rn = ["x", "height", "width", "onMouseenter"], cn = ["min", "max"], vn = ["min", "max"], dn = {
26
+ __name: "SlicerPreview",
27
+ props: {
28
+ background: {
29
+ type: String,
30
+ default: "#FFFFFF"
31
+ },
32
+ borderColor: {
33
+ type: String,
34
+ default: "#FFFFFF"
35
+ },
36
+ fontSize: {
37
+ type: Number,
38
+ default: 14
39
+ },
40
+ labelLeft: {
41
+ type: [String, Number],
42
+ default: ""
43
+ },
44
+ labelRight: {
45
+ type: [String, Number],
46
+ default: ""
47
+ },
48
+ textColor: {
49
+ type: String,
50
+ default: "#1A1A1A"
51
+ },
52
+ inputColor: {
53
+ type: String,
54
+ default: "#1A1A1A"
55
+ },
56
+ max: {
57
+ type: Number,
58
+ default: 0
59
+ },
60
+ min: {
61
+ type: Number,
62
+ default: 0
63
+ },
64
+ selectColor: {
65
+ type: String,
66
+ default: "#4A4A4A"
67
+ },
68
+ useResetSlot: {
69
+ type: Boolean,
70
+ default: !1
71
+ },
72
+ valueStart: {
73
+ type: [Number, String],
74
+ default: 0
75
+ },
76
+ valueEnd: {
77
+ type: [Number, String],
78
+ default: 0
79
+ },
80
+ minimap: {
81
+ type: Array,
82
+ default: []
83
+ },
84
+ smoothMinimap: {
85
+ type: Boolean,
86
+ default: !1
87
+ },
88
+ minimapSelectedColor: {
89
+ type: String,
90
+ default: "#1f77b4"
91
+ },
92
+ minimapSelectionRadius: {
93
+ type: Number,
94
+ default: 12
95
+ },
96
+ minimapLineColor: {
97
+ type: String,
98
+ default: "#2D353C"
99
+ },
100
+ minimapSelectedColorOpacity: {
101
+ type: Number,
102
+ default: 0.2
103
+ },
104
+ minimapSelectedIndex: {
105
+ type: Number,
106
+ default: null
107
+ },
108
+ minimapIndicatorColor: {
109
+ type: String,
110
+ default: "#2D353C"
111
+ },
112
+ refreshStartPoint: {
113
+ type: Number,
114
+ default: 0
115
+ },
116
+ refreshEndPoint: {
117
+ type: Number,
118
+ default: null
119
+ },
120
+ enableRangeHandles: {
121
+ type: Boolean,
122
+ default: !1
123
+ },
124
+ enableSelectionDrag: {
125
+ type: Boolean,
126
+ default: !0
127
+ },
128
+ verticalHandles: {
129
+ type: Boolean,
130
+ default: !1
131
+ },
132
+ timeLabels: {
133
+ type: Array
134
+ },
135
+ isPreview: {
136
+ type: Boolean,
137
+ default: !1
138
+ }
139
+ },
140
+ emits: ["futureStart", "futureEnd", "update:start", "update:end", "reset", "trapMouse"],
141
+ setup(R, { expose: Hl, emit: Vl }) {
142
+ co((m) => ({
143
+ "21832f94": zt.value,
144
+ f1981eac: Fe.value,
145
+ "1f35d69b": Bl.value,
146
+ "676931da": R.selectColor,
147
+ "409d1f68": Tt.value
148
+ }));
149
+ const d = R, Ee = p(null), xe = p(d.min), be = p(d.max), At = b(() => !!d.minimap.length), al = p(Rl()), Wt = p(!1), Dt = p(0), pt = b({
150
+ get() {
151
+ return xe.value;
152
+ },
153
+ set(m) {
154
+ const h = Math.min(m, be.value - 1);
155
+ xe.value = h, G.value && (G.value.value = String(h)), fe("futureStart", h);
156
+ }
157
+ }), tt = b({
158
+ get() {
159
+ return be.value;
160
+ },
161
+ set(m) {
162
+ const h = Math.max(m, xe.value + 1);
163
+ be.value = h, Gt.value && (Gt.value.value = String(h)), fe("futureEnd", h);
164
+ }
165
+ });
166
+ bl(() => {
167
+ const m = () => {
168
+ Ee.value && (Dt.value = Ee.value.getBoundingClientRect().width);
169
+ };
170
+ m();
171
+ const h = ql(m, 50);
172
+ window.addEventListener("resize", h), pl(() => {
173
+ window.removeEventListener("resize", h);
174
+ });
175
+ });
176
+ let ol = null;
177
+ function qe() {
178
+ clearTimeout(ol), fe("update:start", Number(xe.value)), fe("update:end", Number(be.value)), Wt.value = !1;
179
+ }
180
+ const nl = b(() => d.refreshEndPoint === null ? d.max : d.refreshEndPoint), fe = Vl, pe = b(() => {
181
+ const m = d.max - d.min, h = (xe.value - d.min) / m * 100, $ = (be.value - d.min) / m * 100, q = (h + $) / 2, Le = lt.value ? `calc(${q}% - ${wt.value.width}px)` : Ne.value ? `calc(${q}%)` : `calc(${q}% - ${wt.value.width / 2}px)`;
182
+ return {
183
+ left: `${h}%`,
184
+ width: `${$ - h}%`,
185
+ background: d.selectColor,
186
+ tooltipLeft: `calc(${h}% - ${Ne.value ? 0 : mt.value / 2}px)`,
187
+ tooltipRight: `calc(${$}% - ${lt.value ? ue.value : ue.value / 2}px)`,
188
+ tooltipCenter: Le,
189
+ arrowLeft: !Ne.value,
190
+ arrowRight: !lt.value
191
+ };
192
+ }), Ne = b(() => Ee.value ? Ee.value.getBoundingClientRect().width * ((xe.value - d.min) / (d.max - d.min)) - mt.value / 2 < 0 : !1), lt = b(() => Ee.value ? Ee.value.getBoundingClientRect().width * ((be.value - d.min) / (d.max - d.min)) + ue.value / 2 > Ee.value.getBoundingClientRect().width : !1), zt = b(() => d.inputColor), Tt = b(() => d.background), Bl = b(() => `${d.selectColor}33`), Fe = b(() => d.borderColor), Yt = b(() => {
193
+ let m = [];
194
+ for (let h = 0; h < d.minimap.length; h += 1)
195
+ m.push(h);
196
+ return m;
197
+ });
198
+ function dt() {
199
+ fe("reset");
200
+ }
201
+ vt(
202
+ () => d.min,
203
+ (m) => {
204
+ Number(xe.value) < Number(m) && (xe.value = Number(m)), Number(be.value) < Number(m) && (be.value = Number(m));
205
+ }
206
+ ), vt(
207
+ () => d.max,
208
+ (m) => {
209
+ Number(xe.value) > Number(m) && (xe.value = Number(m)), Number(be.value) > Number(m) && (be.value = Number(m));
210
+ }
211
+ );
212
+ const It = p(null), U = p({
213
+ width: 1,
214
+ height: 1
215
+ }), at = p(null);
216
+ bl(() => {
217
+ if (At.value) {
218
+ const m = ql(() => {
219
+ const { width: h, height: $ } = Ho({
220
+ chart: It.value
221
+ });
222
+ U.value.width = h, U.value.height = $ - 47;
223
+ });
224
+ at.value = new ResizeObserver(m), at.value.observe(It.value);
225
+ }
226
+ }), pl(() => {
227
+ at.value && at.value.disconnect();
228
+ });
229
+ const Xt = b(() => Math.max(1, d.max - d.min)), P = b(() => Math.max(1, d.minimap.length)), ul = b(() => P.value / Xt.value);
230
+ function me(m) {
231
+ const h = Math.floor((m - d.min) * ul.value);
232
+ return Math.min(Math.max(0, h), P.value);
233
+ }
234
+ function oe(m) {
235
+ const h = Math.ceil((m - d.min) * ul.value);
236
+ return Math.min(Math.max(0, h), P.value);
237
+ }
238
+ const ot = b(() => me(xe.value)), Nt = b(() => oe(be.value)), ne = b(() => d.minimap.length ? U.value.width / d.minimap.length : 0), ye = b(() => {
239
+ if (!d.minimap.length) return [];
240
+ const m = Math.max(...d.minimap), h = Math.min(...d.minimap) - 10, $ = m - (h > 0 ? 0 : h), q = d.minimap.map((Pe, Ot) => ({
241
+ x: U.value.width / d.minimap.length * Ot + ne.value / 2,
242
+ y: U.value.height - (Pe - h) / $ * (U.value.height * 0.9)
243
+ })), Le = ot.value, qt = Math.max(Le + 1, Nt.value), kl = d.smoothMinimap ? Pl(q) : Ol(q), St = q.slice(Le, qt), Kt = d.smoothMinimap ? Pl(St) : Ol(St);
244
+ return {
245
+ fullSet: kl,
246
+ selectionSet: Kt,
247
+ sliced: St,
248
+ firstPlot: q[Le],
249
+ lastPlot: q[Math.max(0, qt - 1)]
250
+ };
251
+ }), ke = b(() => {
252
+ const m = ot.value, h = Math.max(m + 1, Nt.value);
253
+ return {
254
+ x: ne.value * m + ne.value / 2,
255
+ width: ne.value * (h - m) - ne.value
256
+ };
257
+ }), ht = p(d.minimapSelectedIndex);
258
+ vt(() => d.minimapSelectedIndex, (m) => {
259
+ if ([null, void 0].includes(m)) {
260
+ ht.value = null;
261
+ return;
262
+ }
263
+ ht.value = me(d.valueStart) + m;
264
+ }, { immediate: !0 });
265
+ function ft(m) {
266
+ ht.value = m;
267
+ const h = ot.value, $ = Nt.value;
268
+ m >= h && m < $ && fe("trapMouse", m - h);
269
+ }
270
+ const re = p(0), G = p(null), Gt = p(null);
271
+ function il(m) {
272
+ if (typeof m == "object" && m && "target" in m) {
273
+ const $ = m.target, q = "valueAsNumber" in $ ? $.valueAsNumber : +$.value;
274
+ return Number.isFinite(q) ? q : NaN;
275
+ }
276
+ const h = +m;
277
+ return Number.isFinite(h) ? h : NaN;
278
+ }
279
+ function sl(m) {
280
+ Wt.value = !0;
281
+ const h = il(m);
282
+ Number.isFinite(h) && (pt.value = h);
283
+ }
284
+ function yt(m) {
285
+ Wt.value = !0;
286
+ const h = il(m);
287
+ Number.isFinite(h) && (tt.value = h);
288
+ }
289
+ const Rt = b(() => d.valueEnd - d.valueStart), O = p(!1);
290
+ let Ut = p(null);
291
+ const rl = b(() => (Dt.value - 48) / (d.max - d.min)), Zt = b(() => (Dt.value - 48) / (d.max - d.min) * Rt.value), $e = p(2.5), We = b(() => {
292
+ const m = Dt.value - 48;
293
+ return Math.ceil(
294
+ (d.max - d.min) / ((m - Zt.value) / $e.value)
295
+ );
296
+ });
297
+ let Re = null, Ke = null, S = null, nt = null;
298
+ const cl = (m) => {
299
+ if (ie.value = !0, !d.enableSelectionDrag) return;
300
+ const h = m.type === "touchstart", $ = h && m.targetTouches && m.targetTouches[0] ? m.targetTouches[0] : null, q = h ? $ ? $.target : null : m.target;
301
+ !q || !(q instanceof Element) || q.classList && q.classList.contains("range-handle") || (O.value = !0, Ut.value = h ? $ ? $.clientX : 0 : m.clientX, Re = h ? "touchmove" : "mousemove", Ke = h ? "touchend" : "mouseup", S = h ? yl : vl, nt = h ? _ : dl, window.addEventListener(Re, S, { passive: !1 }), window.addEventListener(Ke, nt));
302
+ };
303
+ function vl(m) {
304
+ O.value && y(m.clientX);
305
+ }
306
+ function yl(m) {
307
+ if (!O.value || !Ee.value) return;
308
+ const h = m.target;
309
+ if (!(h instanceof Element) || !Ee.value.contains(h) || h.classList && h.classList.contains("range-handle")) return;
310
+ m.preventDefault();
311
+ const $ = m.targetTouches && m.targetTouches[0] ? m.targetTouches[0] : null;
312
+ $ && y($.clientX);
313
+ }
314
+ function y(m) {
315
+ if (!O.value) return;
316
+ const h = m - Ut.value;
317
+ if (Math.abs(h) > rl.value) {
318
+ if (h > 0) {
319
+ const $ = Math.min(d.max, be.value + We.value);
320
+ tt.value = $, pt.value = $ - Rt.value;
321
+ } else {
322
+ const $ = Math.max(d.min, xe.value - We.value);
323
+ pt.value = $, tt.value = $ + Rt.value;
324
+ }
325
+ Ut.value = m;
326
+ }
327
+ }
328
+ function dl() {
329
+ ze();
330
+ }
331
+ function _() {
332
+ ze();
333
+ }
334
+ function ze() {
335
+ O.value = !1, Re && S && window.removeEventListener(Re, S), Ke && nt && window.removeEventListener(Ke, nt), Re = Ke = null, S = nt = null, qe();
336
+ }
337
+ const ut = p(!1), it = p(null), t = p(null), mt = p(1), ue = p(1), ie = p(!1);
338
+ function Pt() {
339
+ it.value && (mt.value = it.value.getBoundingClientRect().width);
340
+ }
341
+ function _e() {
342
+ t.value && (ue.value = t.value.getBoundingClientRect().width);
343
+ }
344
+ const w = p(0);
345
+ function De(m) {
346
+ w.value = m === "start" ? 1 : 0;
347
+ }
348
+ const kt = p(!1), wt = p({
349
+ width: 0,
350
+ left: 0
351
+ });
352
+ vt([xe, be], async () => {
353
+ if (await ll(), !it.value || !t.value) {
354
+ kt.value = !1, wt.value = { width: 0, left: 0 };
355
+ return;
356
+ }
357
+ const m = it.value.getBoundingClientRect(), h = t.value.getBoundingClientRect();
358
+ kt.value = m.x + m.width > h.x;
359
+ const $ = m.x + m.width / 2, q = h.x + h.width / 2, Le = m.width + h.width, qt = ($ + q) / 2;
360
+ wt.value = {
361
+ width: Le,
362
+ left: qt - Le / 2
363
+ };
364
+ }), vo(() => {
365
+ Pt(), _e();
366
+ }), vt(() => d.labelLeft, () => {
367
+ ll(Pt);
368
+ }, { deep: !0 }), vt(() => d.labelRight, () => {
369
+ ll(_e);
370
+ }, { deep: !0 });
371
+ const te = b(() => {
372
+ const m = d.timeLabels.find(($) => $.absoluteIndex === xe.value), h = d.timeLabels.find(($) => $.absoluteIndex === be.value - 1);
373
+ return {
374
+ left: m ? m.text : "",
375
+ right: h ? h.text : ""
376
+ };
377
+ });
378
+ return pl(() => {
379
+ at.value && at.value.disconnect(), Re && S && window.removeEventListener(Re, S), Ke && nt && window.removeEventListener(Ke, nt), Re = Ke = null, S = nt = null, clearTimeout(ol);
380
+ }), Hl({
381
+ setStartValue: sl,
382
+ setEndValue: yt
383
+ }), (m, h) => (n(), i("div", {
384
+ "data-dom-to-png-ignore": "",
385
+ style: { padding: "0 24px" },
386
+ class: "vue-data-ui-zoom",
387
+ ref_key: "zoomWrapper",
388
+ ref: Ee,
389
+ onMousedown: cl,
390
+ onTouchstart: cl
391
+ }, [
392
+ x("div", Go, [
393
+ R.valueStart !== R.refreshStartPoint || R.valueEnd !== nl.value ? (n(), i("div", Uo, [
394
+ R.useResetSlot ? J(m.$slots, "reset-action", {
395
+ key: 1,
396
+ reset: dt
397
+ }, void 0, !0) : (n(), i("button", {
398
+ key: 0,
399
+ tabindex: "0",
400
+ role: "button",
401
+ class: "vue-data-ui-refresh-button",
402
+ style: L({
403
+ top: At.value ? "36px" : "-16px",
404
+ pointerEvents: "all !important"
405
+ }),
406
+ onClick: dt
407
+ }, [
408
+ tl(Xo, {
409
+ name: "refresh",
410
+ stroke: R.textColor
411
+ }, null, 8, ["stroke"])
412
+ ], 4))
413
+ ])) : f("", !0)
414
+ ]),
415
+ x("div", {
416
+ class: "double-range-slider",
417
+ ref_key: "minimapWrapper",
418
+ ref: It,
419
+ style: { "z-index": "0" },
420
+ onMouseenter: h[13] || (h[13] = ($) => ie.value = !0),
421
+ onMouseleave: h[14] || (h[14] = ($) => ie.value = !1)
422
+ }, [
423
+ At.value ? (n(), i("div", Zo, [
424
+ (n(), i("svg", {
425
+ xmlns: v(ko),
426
+ viewBox: `0 0 ${U.value.width < 0 ? 0 : U.value.width} ${U.value.height < 0 ? 0 : U.value.height}`
427
+ }, [
428
+ x("defs", null, [
429
+ x("linearGradient", {
430
+ id: al.value,
431
+ x1: "0%",
432
+ y1: "0%",
433
+ x2: "0%",
434
+ y2: "100%"
435
+ }, [
436
+ x("stop", {
437
+ offset: "0%",
438
+ "stop-color": `${R.minimapLineColor}50`
439
+ }, null, 8, Jo),
440
+ h[15] || (h[15] = x("stop", {
441
+ offset: "100%",
442
+ "stop-color": "transparent"
443
+ }, null, -1))
444
+ ], 8, Ko)
445
+ ]),
446
+ x("path", {
447
+ d: `M${ye.value.fullSet}`,
448
+ stroke: `${R.minimapLineColor}`,
449
+ fill: "none",
450
+ "stroke-width": "1",
451
+ "stroke-linecap": "round",
452
+ "stroke-linejoin": "round",
453
+ style: { opacity: "1" }
454
+ }, null, 8, Qo),
455
+ x("rect", {
456
+ x: ke.value.x,
457
+ width: ke.value.width < 0 ? 0 : ke.value.width,
458
+ height: Math.max(U.value.height, 0),
459
+ y: 0,
460
+ fill: Fe.value,
461
+ rx: R.minimapSelectionRadius,
462
+ stroke: "none"
463
+ }, null, 8, jo),
464
+ x("path", {
465
+ d: `M${ne.value / 2},${Math.max(U.value.height, 0)} ${ye.value.fullSet} L${U.value.width - ne.value / 2},${Math.max(U.value.height, 0)}Z`,
466
+ fill: `url(#${al.value})`,
467
+ stroke: "none",
468
+ style: { opacity: "1" }
469
+ }, null, 8, en),
470
+ x("rect", {
471
+ x: ke.value.x,
472
+ width: ke.value.width < 0 ? 0 : ke.value.width,
473
+ height: Math.max(U.value.height, 0),
474
+ y: 0,
475
+ rx: R.minimapSelectionRadius,
476
+ fill: Fe.value,
477
+ style: L({
478
+ opacity: O.value || Wt.value ? 0 : 1
479
+ })
480
+ }, null, 12, tn),
481
+ x("rect", {
482
+ x: ke.value.x,
483
+ width: ke.value.width < 0 ? 0 : ke.value.width,
484
+ height: Math.max(U.value.height, 0),
485
+ y: 0,
486
+ fill: R.minimapSelectedColor,
487
+ rx: R.minimapSelectionRadius,
488
+ style: L({
489
+ opacity: R.minimapSelectedColorOpacity
490
+ })
491
+ }, null, 12, ln),
492
+ x("path", {
493
+ d: `M${ye.value.sliced[0].x},${Math.max(U.value.height, 0)} ${ye.value.selectionSet} L${ye.value.sliced.at(-1).x},${Math.max(U.value.height, 0)}Z`,
494
+ fill: `url(#${al.value})`,
495
+ stroke: "none",
496
+ style: { opacity: "1" }
497
+ }, null, 8, an),
498
+ x("path", {
499
+ d: `M ${ye.value.selectionSet}`,
500
+ stroke: `${R.minimapLineColor}`,
501
+ fill: "transparent",
502
+ "stroke-width": "2",
503
+ "stroke-linecap": "round",
504
+ "stroke-linejoin": "round"
505
+ }, null, 8, on),
506
+ x("circle", {
507
+ cx: ye.value.firstPlot.x,
508
+ cy: ye.value.firstPlot.y,
509
+ "stroke-width": "0.5",
510
+ stroke: Fe.value,
511
+ r: "3",
512
+ fill: R.minimapLineColor
513
+ }, null, 8, nn),
514
+ x("circle", {
515
+ cx: ye.value.lastPlot.x,
516
+ cy: ye.value.lastPlot.y,
517
+ "stroke-width": "0.5",
518
+ stroke: Fe.value,
519
+ r: "3",
520
+ fill: R.minimapLineColor
521
+ }, null, 8, un),
522
+ ht.value !== null ? (n(!0), i(g, { key: 0 }, C(Yt.value, ($, q) => (n(), i("g", null, [
523
+ ht.value === $ && $ >= ot.value && $ < Nt.value ? (n(), i("line", {
524
+ key: 0,
525
+ x1: ne.value * q + ne.value / 2,
526
+ x2: ne.value * q + ne.value / 2,
527
+ y1: 0,
528
+ y2: Math.max(U.value.height, 0),
529
+ stroke: R.minimapIndicatorColor,
530
+ "stroke-linecap": "round",
531
+ "stroke-dasharray": "2",
532
+ "stroke-width": "1"
533
+ }, null, 8, sn)) : f("", !0)
534
+ ]))), 256)) : f("", !0),
535
+ (n(!0), i(g, null, C(Yt.value, ($, q) => (n(), i("rect", {
536
+ x: ne.value * q,
537
+ y: 0,
538
+ height: Math.max(U.value.height, 0),
539
+ width: ne.value < 0 ? 0 : ne.value,
540
+ fill: "transparent",
541
+ style: L([{ "pointer-events": "all !important" }, {
542
+ cursor: $ >= ot.value && $ < Nt.value && R.enableSelectionDrag ? ut.value ? "grabbing" : "grab" : "default"
543
+ }]),
544
+ onMousedown: h[0] || (h[0] = (Le) => ut.value = !0),
545
+ onMouseup: h[1] || (h[1] = (Le) => ut.value = !1),
546
+ onMouseenter: (Le) => ft($),
547
+ onMouseleave: h[2] || (h[2] = (Le) => {
548
+ ht.value = null, fe("trapMouse", null);
549
+ })
550
+ }, null, 44, rn))), 256))
551
+ ], 8, qo))
552
+ ])) : f("", !0),
553
+ h[16] || (h[16] = x("div", { class: "slider-track" }, null, -1)),
554
+ x("div", {
555
+ class: Be({
556
+ "range-highlight": !0,
557
+ move: R.enableSelectionDrag
558
+ }),
559
+ onMousedown: h[3] || (h[3] = ($) => ut.value = !0),
560
+ onMouseup: h[4] || (h[4] = ($) => ut.value = !1),
561
+ style: L({
562
+ ...pe.value,
563
+ cursor: ut.value ? "grabbing" : "grab"
564
+ })
565
+ }, null, 38),
566
+ R.enableRangeHandles ? Zl((n(), i("input", {
567
+ ref_key: "rangeStart",
568
+ ref: G,
569
+ key: `range-min${re.value}`,
570
+ type: "range",
571
+ class: Be({ "range-left": !0, "range-handle": !0, "range-minimap": At.value && R.verticalHandles }),
572
+ min: R.min,
573
+ max: R.max,
574
+ "onUpdate:modelValue": h[5] || (h[5] = ($) => pt.value = $),
575
+ onInput: h[6] || (h[6] = ($) => sl($)),
576
+ onChange: qe,
577
+ onKeyup: Aa(qe, ["enter"]),
578
+ onBlur: qe,
579
+ onMouseenter: h[7] || (h[7] = ($) => De("start")),
580
+ onPointermove: h[8] || (h[8] = ($) => pt.value = +$.target.value),
581
+ onPointerup: qe
582
+ }, null, 42, cn)), [
583
+ [
584
+ za,
585
+ pt.value,
586
+ void 0,
587
+ { number: !0 }
588
+ ]
589
+ ]) : f("", !0),
590
+ R.enableRangeHandles ? Zl((n(), i("input", {
591
+ key: 2,
592
+ ref_key: "rangeEnd",
593
+ ref: Gt,
594
+ type: "range",
595
+ class: Be({ "range-right": !0, "range-handle": !0, "range-minimap": At.value && R.verticalHandles }),
596
+ min: R.min,
597
+ max: R.max,
598
+ "onUpdate:modelValue": h[9] || (h[9] = ($) => tt.value = $),
599
+ onInput: h[10] || (h[10] = ($) => yt($)),
600
+ onChange: qe,
601
+ onKeyup: Aa(qe, ["enter"]),
602
+ onBlur: qe,
603
+ onMouseenter: h[11] || (h[11] = ($) => De("end")),
604
+ onPointermove: h[12] || (h[12] = ($) => tt.value = +$.target.value),
605
+ onPointerup: qe
606
+ }, null, 42, vn)), [
607
+ [
608
+ za,
609
+ tt.value,
610
+ void 0,
611
+ { number: !0 }
612
+ ]
613
+ ]) : f("", !0),
614
+ te.value.left ? (n(), i("div", {
615
+ key: 3,
616
+ ref_key: "tooltipLeft",
617
+ ref: it,
618
+ class: Be({
619
+ "range-tooltip": !0,
620
+ "range-tooltip-visible": ie.value,
621
+ "range-tooltip-arrow": pe.value.arrowLeft && !R.verticalHandles,
622
+ "range-tooltip-arrow-left": !pe.value.arrowLeft && !R.verticalHandles
623
+ }),
624
+ style: L({
625
+ left: pe.value.tooltipLeft,
626
+ color: v(et)(R.selectColor),
627
+ backgroundColor: R.selectColor,
628
+ border: `1px solid ${Fe.value}`,
629
+ zIndex: `${w.value + 4}`,
630
+ visibility: kt.value || te.value.left === te.value.right ? "hidden" : "visible"
631
+ })
632
+ }, ae(te.value.left), 7)) : f("", !0),
633
+ (kt.value || te.value.left === te.value.right) && (te.value.left || te.value.right) ? (n(), i("div", {
634
+ key: 4,
635
+ ref: "tooltipMerge",
636
+ class: Be({
637
+ "range-tooltip": !0,
638
+ "range-tooltip-visible": ie.value,
639
+ "range-tooltip-arrow": !0,
640
+ "range-tooltip-arrow-left": !pe.value.arrowLeft && !R.verticalHandles,
641
+ "range-tooltip-arrow-right": !pe.value.arrowRight && !R.verticalHandles
642
+ }),
643
+ style: L({
644
+ left: pe.value.tooltipCenter,
645
+ width: wt.value.width + "px",
646
+ color: v(et)(R.selectColor),
647
+ backgroundColor: R.selectColor,
648
+ border: `1px solid ${Fe.value}`,
649
+ zIndex: "4"
650
+ })
651
+ }, ae(te.value.left === te.value.right ? te.value.left : `${te.value.left} - ${te.value.right}`), 7)) : f("", !0),
652
+ te.value.right ? (n(), i("div", {
653
+ key: 5,
654
+ ref_key: "tooltipRight",
655
+ ref: t,
656
+ class: Be({
657
+ "range-tooltip": !0,
658
+ "range-tooltip-visible": ie.value,
659
+ "range-tooltip-arrow": pe.value.arrowRight && !R.verticalHandles,
660
+ "range-tooltip-arrow-right": !pe.value.arrowRight && !R.verticalHandles
661
+ }),
662
+ style: L({
663
+ left: pe.value.tooltipRight,
664
+ color: v(et)(R.selectColor),
665
+ backgroundColor: R.selectColor,
666
+ border: `1px solid ${Fe.value}`,
667
+ zIndex: "4",
668
+ visibility: kt.value || te.value.left === te.value.right ? "hidden" : "visible"
669
+ })
670
+ }, ae(te.value.right), 7)) : f("", !0)
671
+ ], 544)
672
+ ], 544));
673
+ }
674
+ }, hn = /* @__PURE__ */ Ba(dn, [["__scopeId", "data-v-a5d614c1"]]), fn = ["id"], mn = ["id"], gn = ["viewBox", "aria-label"], xn = ["x", "y", "width", "height"], bn = { key: 1 }, pn = { class: "vue-ui-xy-grid" }, yn = ["stroke", "x1", "x2", "y1", "y2"], kn = ["stroke", "x1", "x2", "y1", "y2"], wn = { key: 1 }, Sn = ["x1", "x2", "y1", "y2", "stroke"], $n = ["x1", "x2", "y1", "y2", "stroke"], _n = ["x1", "x2", "y1", "y2", "stroke"], Ln = { key: 3 }, Mn = ["d", "stroke"], Cn = { key: 4 }, An = ["d", "stroke"], zn = ["id"], Tn = ["stop-color"], In = ["stop-color"], Nn = ["stop-color"], Rn = ["id"], Pn = ["stop-color"], On = ["stop-color"], Hn = ["stop-color"], Vn = ["id"], Bn = ["stop-color"], En = ["stop-color"], Fn = ["id"], Wn = ["stop-color"], Dn = ["stop-color"], Yn = ["id"], Xn = ["stop-color"], Gn = ["stop-color"], Un = ["x", "y", "height", "width", "fill"], Zn = ["x", "y", "width"], qn = { key: 0 }, Kn = ["x", "y", "height", "width", "fill"], Jn = ["x", "y", "height", "width", "rx", "fill", "stroke", "stroke-width"], Qn = ["x", "y", "height", "width", "rx", "fill", "stroke", "stroke-width"], jn = ["width", "x", "y"], eu = { key: 0 }, tu = ["id"], lu = ["fill"], au = ["x1", "x2", "y1", "y2", "stroke", "marker-end"], ou = ["x", "y", "font-size", "fill"], nu = ["stroke", "x1", "x2", "y1", "y2"], uu = { key: 3 }, iu = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], su = ["x", "y", "width", "height", "stroke", "stroke-width", "stroke-linecap", "stroke-linejoin", "stroke-dasharray"], ru = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], cu = ["fill", "font-size", "transform"], vu = ["x1", "x2", "y1", "y2", "stroke"], du = ["x", "y", "font-size", "fill"], hu = ["x1", "x2", "y1", "y2", "stroke"], fu = ["x", "y", "font-size", "fill"], mu = ["width", "x", "y"], gu = { style: { width: "100%" } }, xu = { key: 0 }, bu = ["id"], pu = ["fill"], yu = ["x1", "x2", "y1", "y2", "stroke", "marker-end"], ku = ["x", "y", "font-size", "fill"], wu = ["d", "stroke", "stroke-width", "stroke-dasharray"], Su = ["d", "stroke", "stroke-width", "stroke-dasharray"], $u = { key: 6 }, _u = { key: 7 }, Lu = ["d", "fill", "fill-opacity"], Mu = { key: 0 }, Cu = ["d", "fill"], Au = ["d", "fill"], zu = ["d", "fill"], Tu = ["d", "fill"], Iu = ["d", "stroke", "stroke-width", "stroke-dasharray"], Nu = ["d", "stroke", "stroke-width", "stroke-dasharray"], Ru = ["width", "x", "y"], Pu = { style: { width: "100%" } }, Ou = { key: 3 }, Hu = ["id"], Vu = ["fill"], Bu = ["x1", "x2", "y1", "y2", "stroke", "marker-end"], Eu = ["x", "y", "font-size", "fill"], Fu = { key: 8 }, Wu = ["x", "y", "font-size", "fill"], Du = ["x", "y", "font-size", "fill", "font-weight"], Yu = { key: 9 }, Xu = ["x", "y", "font-size", "fill"], Gu = { key: 10 }, Uu = ["x", "y"], Zu = ["innerHTML"], qu = ["x", "y"], Ku = ["innerHTML"], Ju = ["x1", "x2", "y1", "y2", "stroke"], Qu = { key: 11 }, ju = ["x", "y", "font-size", "fill"], ei = { key: 12 }, ti = ["x", "y"], li = ["innerHTML"], ai = ["x", "y"], oi = ["innerHTML"], ni = ["x1", "x2", "y1", "y2", "stroke"], ui = ["x", "y", "font-size", "fill", "innerHTML"], ii = ["x", "y", "font-size", "fill", "innerHTML"], si = ["x", "y", "font-size", "fill", "innerHTML"], ri = ["x", "y", "font-size", "fill", "innerHTML"], ci = ["id"], vi = ["stop-color"], di = ["stop-color"], hi = ["x", "y", "width", "height", "fill", "onMouseenter"], fi = ["font-size", "fill", "transform"], mi = ["x", "y", "font-size", "fill"], gi = ["text-anchor", "font-size", "fill", "transform", "onClick"], xi = ["text-anchor", "font-size", "fill", "transform", "innerHTML", "onClick"], bi = { key: 15 }, pi = ["x1", "y1", "x2", "y2", "stroke", "stroke-width", "stroke-dasharray"], yi = ["x1", "y1", "x2", "y2", "stroke", "stroke-width", "stroke-dasharray"], ki = ["y", "x", "width", "height", "fill"], wi = ["id", "x", "y", "font-size", "fill", "text-anchor"], Si = {
675
+ key: 16,
676
+ style: { "pointer-events": "none" }
677
+ }, $i = ["x", "y"], _i = ["innerHTML"], Li = ["cx", "cy", "r", "fill"], Mi = {
678
+ key: 4,
679
+ class: "vue-data-ui-watermark"
680
+ }, Ci = {
681
+ class: "vue-ui-xy-tag-arrow",
682
+ height: "20",
683
+ viewBox: "0 0 10 20",
684
+ style: { position: "absolute", right: "100%", top: "50%", transform: "translateY(-50%)" }
685
+ }, Ai = ["fill"], zi = ["innerHTML"], Ti = {
686
+ class: "vue-ui-xy-tag-arrow",
687
+ height: "100%",
688
+ viewBox: "0 0 10 20",
689
+ style: { position: "absolute", left: "100%", top: "50%", transform: "translateY(-50%)" }
690
+ }, Ii = ["fill"], Ni = ["innerHTML"], Ri = {
691
+ class: "vue-ui-xy-tag-arrow",
692
+ height: "20",
693
+ viewBox: "0 0 10 20",
694
+ style: { position: "absolute", right: "100%", top: "50%", transform: "translateY(-50%)" }
695
+ }, Pi = ["fill"], Oi = ["innerHTML"], Hi = {
696
+ class: "vue-ui-xy-tag-arrow",
697
+ height: "100%",
698
+ viewBox: "0 0 10 20",
699
+ style: { position: "absolute", left: "100%", top: "50%", transform: "translateY(-50%)" }
700
+ }, Vi = ["fill"], Bi = ["innerHTML"], Ei = ["id"], Fi = ["onClick"], Wi = {
701
+ key: 0,
702
+ viewBox: "0 0 20 12",
703
+ height: "14",
704
+ width: "20"
705
+ }, Di = ["stroke", "fill"], Yi = {
706
+ key: 1,
707
+ viewBox: "0 0 40 40",
708
+ height: "14",
709
+ width: "14"
710
+ }, Xi = ["fill"], Gi = ["fill"], Ui = {
711
+ key: 2,
712
+ viewBox: "0 0 12 12",
713
+ height: "14",
714
+ width: "14"
715
+ }, Zi = {
716
+ style: { display: "flex", "flex-direction": "row", gap: "6px", "align-items": "center", "padding-left": "6px" },
717
+ "data-dom-to-png-ignore": ""
718
+ }, qi = ["innerHTML"], Ki = {
719
+ __name: "vue-ui-xy",
720
+ props: {
721
+ config: {
722
+ type: Object,
723
+ default() {
724
+ return {};
725
+ }
726
+ },
727
+ dataset: {
728
+ type: Array,
729
+ default() {
730
+ return [];
731
+ }
732
+ },
733
+ selectedXIndex: {
734
+ type: Number,
735
+ default: void 0
736
+ }
737
+ },
738
+ emits: ["selectTimeLabel", "selectX", "selectLegend"],
739
+ setup(R, { expose: Hl, emit: Vl }) {
740
+ const d = R, Ee = Lt(() => import("./DataTable-C6tKzvDk.js")), xe = Lt(() => import("./Tooltip-DLU3yWUJ.js")), be = Lt(() => import("./UserOptions-hQcfD5wC.js")), At = Lt(() => import("./BaseIcon-BkcnpqIi.js")), al = Lt(() => import("./vue-ui-table-sparkline-CgODT4oZ.js")), Wt = Lt(() => import("./vue-ui-accordion-CAB71G5L.js")), Dt = Lt(() => import("./PackageVersion-CvDEwhqw.js")), pt = Lt(() => import("./PenAndPaper-CK0i-_WG.js")), tt = Vl, ol = ho(), qe = fo(), { vue_ui_xy: nl } = wo(), fe = p(null), pe = p(null), Ne = p(null), lt = p(null), zt = p(null), Tt = p(null), Bl = p(null), Fe = p(null), Yt = p(null), dt = p(null), It = p(null), U = p(null), at = p(null), Xt = p(0), P = p(null), ul = p(!0), me = p(600), oe = p(1e3), ot = p("0 0 1000 600"), Nt = p({ x: 0, y: 0 }), ne = p({ line: "line", bar: "bar", plot: "plot" }), ye = p(!1), ke = p(!1), ht = p(!1), ft = p(null), re = p([]), G = p(Rl()), Gt = p(0), il = p(0), sl = p(0), yt = p(!0), Rt = p(0), O = p(null), Ut = p(!1), rl = p(!0), Zt = p(!0), $e = p(null), We = p({}), Re = p(null), Ke = p(!1), S = p(null), nt = b(() => ({
741
+ height: me.value,
742
+ width: oe.value
743
+ }));
744
+ function cl(l) {
745
+ return Number.isFinite(l) ? Math.max(0, Math.floor(l)) : 0;
746
+ }
747
+ function vl(l, r, e = 0) {
748
+ return Number.isFinite(l) && Number.isFinite(r) && Math.abs(r) > 1e-9 ? l / r : e;
749
+ }
750
+ const yl = p(!1), y = p({
751
+ dataLabels: { show: !0 },
752
+ showTooltip: !0,
753
+ showTable: !1,
754
+ isStacked: !1,
755
+ useIndividualScale: !1
756
+ });
757
+ function dl() {
758
+ yl.value ? (y.value.isStacked = t.value.chart.grid.labels.yAxis.stacked, y.value.useIndividualScale == null && (y.value.useIndividualScale = t.value.chart.grid.labels.yAxis.useIndividualScale)) : (y.value = {
759
+ dataLabels: { show: !0 },
760
+ showTooltip: t.value.chart.tooltip.show === !0,
761
+ showTable: t.value.showTable === !0,
762
+ isStacked: t.value.chart.grid.labels.yAxis.stacked,
763
+ useIndividualScale: t.value.chart.grid.labels.yAxis.useIndividualScale
764
+ }, yl.value = !0);
765
+ }
766
+ const _ = p({
767
+ xAxis: 18,
768
+ yAxis: 12,
769
+ dataLabels: 20,
770
+ plotLabels: 10
771
+ }), ze = p({ plot: 3, line: 3 });
772
+ bl(() => {
773
+ Ke.value = !0, d.dataset.length && d.dataset.forEach((l, r) => {
774
+ [null, void 0].includes(l.series) && Gl({
775
+ componentName: "VueUiXy",
776
+ type: "datasetSerieAttribute",
777
+ property: "series (number[])",
778
+ index: r,
779
+ debug: mt.value
780
+ });
781
+ });
782
+ });
783
+ function ut() {
784
+ if (!Object.keys(d.config || {}).length)
785
+ return nl;
786
+ const l = Ul({
787
+ userConfig: d.config,
788
+ defaultConfig: nl
789
+ });
790
+ return d.config && Ze(d.config, "chart.highlightArea") && (Array.isArray(d.config.chart.highlightArea) ? l.chart.highlightArea = d.config.chart.highlightArea : l.chart.highlightArea = [d.config.chart.highlightArea]), d.config && Ze(d.config, "chart.grid.labels.yAxis.scaleMin") ? l.chart.grid.labels.yAxis.scaleMin = d.config.chart.grid.labels.yAxis.scaleMin : l.chart.grid.labels.yAxis.scaleMin = null, d.config && Ze(d.config, "chart.grid.labels.yAxis.scaleMax") ? l.chart.grid.labels.yAxis.scaleMax = d.config.chart.grid.labels.yAxis.scaleMax : l.chart.grid.labels.yAxis.scaleMax = null, d.config && Ze(d.config, "chart.zoom.startIndex") ? l.chart.zoom.startIndex = d.config.chart.zoom.startIndex : l.chart.zoom.startIndex = null, d.config && Ze(d.config, "chart.zoom.endIndex") ? l.chart.zoom.endIndex = d.config.chart.zoom.endIndex : l.chart.zoom.endIndex = null, d.config && Ze(d.config, "chart.grid.labels.yAxis.groupColor") ? l.chart.grid.labels.yAxis.groupColor = d.config.chart.grid.labels.yAxis.groupColor : l.chart.grid.labels.yAxis.groupColor = null, d.config && d.config.chart.annotations && Array.isArray(d.config.chart.annotations) && d.config.chart.annotations.length ? l.chart.annotations = d.config.chart.annotations.map((r) => Ul({
791
+ defaultConfig: nl.chart.annotations[0],
792
+ userConfig: r
793
+ })) : l.chart.annotations = [], d.config && Ze(d.config, "chart.grid.position") && d.config.chart.grid.position === "start" && d.dataset.length && d.dataset.some((r) => r.type === "bar") && (l.chart.grid.position = "middle", Ze(d.config, "debug") && console.warn("Vue Data UI - VueUiXy - config.chart.grid.position was overriden to `middle` because your dataset contains a bar")), d.config && Ze(d.config, "chart.grid.labels.yAxis.serieNameFormatter") ? l.chart.grid.labels.yAxis.serieNameFormatter = d.config.chart.grid.labels.yAxis.serieNameFormatter : l.chart.grid.labels.yAxis.serieNameFormatter = null, d.config && Ze(d.config, "events.datapointEnter") ? l.events.datapointEnter = d.config.events.datapointEnter : l.events.datapointEnter = null, d.config && Ze(d.config, "events.datapointLeave") ? l.events.datapointLeave = d.config.events.datapointLeave : l.events.datapointLeave = null, d.config && Ze(d.config, "events.datapointClick") ? l.events.datapointClick = d.config.events.datapointClick : l.events.datapointClick = null, l.theme ? {
794
+ ...Ul({
795
+ userConfig: Ro.vue_ui_xy[l.theme] || d.config,
796
+ defaultConfig: l
797
+ }),
798
+ customPalette: No[l.theme] || d.palette
799
+ } : l;
800
+ }
801
+ const it = b({
802
+ get() {
803
+ return !!d.dataset && d.dataset.length;
804
+ },
805
+ set(l) {
806
+ return l;
807
+ }
808
+ }), t = p(ut()), mt = b(() => !!t.value.debug), { loading: ue, FINAL_DATASET: ie, manualLoading: Pt } = Bo({
809
+ ...mo(d),
810
+ FINAL_CONFIG: t,
811
+ prepareConfig: ut,
812
+ callback: () => {
813
+ Promise.resolve().then(async () => {
814
+ await Sl();
815
+ });
816
+ },
817
+ skeletonDataset: [
818
+ {
819
+ name: "",
820
+ series: [0, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 134],
821
+ type: "line",
822
+ smooth: !0,
823
+ color: "#BABABA"
824
+ },
825
+ {
826
+ name: "",
827
+ series: [0, 0.5, 1, 1.5, 2.5, 4, 6.5, 10.5, 17, 27.5, 44.5, 67],
828
+ type: "bar",
829
+ color: "#CACACA"
830
+ }
831
+ ],
832
+ skeletonConfig: So({
833
+ defaultConfig: t.value,
834
+ userConfig: {
835
+ useCssAnimation: !1,
836
+ showTable: !1,
837
+ chart: {
838
+ annotations: [],
839
+ highlightArea: [],
840
+ backgroundColor: "#99999930",
841
+ grid: {
842
+ stroke: "#6A6A6A",
843
+ labels: {
844
+ show: !1,
845
+ axis: {
846
+ yLabel: "",
847
+ xLabel: ""
848
+ },
849
+ xAxisLabels: { show: !1 },
850
+ yAxis: {
851
+ commonScaleSteps: 10,
852
+ useNiceScale: !0,
853
+ scaleMin: 0,
854
+ scaleMax: 134
855
+ },
856
+ zeroLine: { show: !0 }
857
+ }
858
+ },
859
+ padding: {
860
+ top: 12,
861
+ bottom: 24,
862
+ left: 24,
863
+ right: 24
864
+ },
865
+ userOptions: { show: !1 },
866
+ zoom: {
867
+ show: !1,
868
+ startIndex: null,
869
+ endIndex: null
870
+ }
871
+ },
872
+ bar: {
873
+ serieName: { show: !1 },
874
+ labels: { show: !1 },
875
+ border: {
876
+ useSerieColor: !1,
877
+ stroke: "#999999"
878
+ }
879
+ },
880
+ line: {
881
+ dot: {
882
+ useSerieColor: !1,
883
+ fill: "#8A8A8A"
884
+ },
885
+ labels: { show: !1 }
886
+ }
887
+ }
888
+ })
889
+ }), _e = b({
890
+ get: () => Math.max(...ie.value.map((l) => Qe({ data: l.series, threshold: t.value.downsample.threshold }).length)),
891
+ set: (l) => l
892
+ }), w = p({ start: 0, end: _e.value }), De = p({ start: 0, end: _e.value }), kt = b(() => t.value.chart.zoom.preview.enable && (De.value.start !== w.value.start || De.value.end !== w.value.end));
893
+ function wt(l, r) {
894
+ De.value[l] = r;
895
+ }
896
+ function te() {
897
+ const l = Math.max(
898
+ 1,
899
+ ...ie.value.map((u) => Qe({
900
+ data: u.series,
901
+ threshold: t.value.downsample.threshold
902
+ }).length)
903
+ );
904
+ let r = Math.max(0, Math.min(w.value.start ?? 0, l - 1)), e = Math.max(r + 1, Math.min(w.value.end ?? l, l));
905
+ (!Number.isFinite(r) || !Number.isFinite(e) || e <= r) && (r = 0, e = l), w.value = { start: r, end: e }, De.value.start = r, De.value.end = e;
906
+ }
907
+ const m = b(() => {
908
+ const { left: l, top: r, width: e, height: u } = c.value, a = w.value.start, o = w.value.end - a, I = e / o, E = De.value.start - a, F = De.value.end - a, M = Math.max(0, Math.min(o, E)), H = Math.max(0, Math.min(o, F));
909
+ return {
910
+ x: l + M * I,
911
+ y: r,
912
+ width: (H - M) * I,
913
+ height: u,
914
+ fill: t.value.chart.zoom.preview.fill,
915
+ stroke: t.value.chart.zoom.preview.stroke,
916
+ "stroke-width": t.value.chart.zoom.preview.strokeWidth,
917
+ "stroke-dasharray": t.value.chart.zoom.preview.strokeDasharray,
918
+ "stroke-linecap": "round",
919
+ "stroke-linejoin": "round",
920
+ style: {
921
+ pointerEvents: "none",
922
+ transition: "all 0.1s ease-in-out",
923
+ animation: "none !important"
924
+ }
925
+ };
926
+ });
927
+ vt(() => d.selectedXIndex, (l) => {
928
+ if ([null, void 0].includes(d.selectedXIndex)) {
929
+ S.value = null;
930
+ return;
931
+ }
932
+ const r = l - w.value.start;
933
+ r < 0 || l >= w.value.end ? S.value = null : S.value = r ?? null;
934
+ }, { immediate: !0 });
935
+ const { isPrinting: h, isImaging: $, generatePdf: q, generateImage: Le } = Vo({
936
+ elementId: `vue-ui-xy_${G.value}`,
937
+ fileName: t.value.chart.title.text || "vue-ui-xy",
938
+ options: t.value.chart.userOptions.print
939
+ }), qt = p(!1), kl = b(() => $o(t.value.customPalette)), St = b(() => {
940
+ if (t.value.chart.grid.labels.yAxis.scaleMin !== null)
941
+ return t.value.chart.grid.labels.yAxis.scaleMin;
942
+ const l = Math.min(...gt.value.filter((r) => !re.value.includes(r.id)).map((r) => Math.min(...r.series)));
943
+ return l > 0 ? 0 : l;
944
+ }), Kt = b(() => {
945
+ if (t.value.chart.grid.labels.yAxis.scaleMax)
946
+ return t.value.chart.grid.labels.yAxis.scaleMax;
947
+ const l = Math.max(...gt.value.filter((r) => !re.value.includes(r.id)).map((r) => Math.max(...r.series)));
948
+ return St.value === l ? l + 1 : l;
949
+ }), Pe = b(() => t.value.chart.grid.labels.yAxis.useNiceScale ? xl(St.value, Kt.value < 0 ? 0 : Kt.value, t.value.chart.grid.labels.yAxis.commonScaleSteps) : Et(St.value, Kt.value < 0 ? 0 : Kt.value, t.value.chart.grid.labels.yAxis.commonScaleSteps)), Ot = b(() => [null, void 0].includes(t.value.chart.grid.labels.yAxis.scaleMin) ? Pe.value.min >= 0 ? 0 : Math.abs(Pe.value.min) : -Pe.value.min), gt = b(() => ul.value ? ie.value.map((l, r) => {
950
+ const e = Qe({
951
+ data: l.series,
952
+ threshold: t.value.downsample.threshold
953
+ }), u = `uniqueId_${r}`;
954
+ return {
955
+ ...l,
956
+ slotAbsoluteIndex: r,
957
+ series: e.map((a) => Tl(a) ? a : null).slice(w.value.start, w.value.end),
958
+ color: _o(l.color ? l.color : kl.value[r] ? kl.value[r] : Lo[r]),
959
+ id: u,
960
+ scaleLabel: l.scaleLabel || u
961
+ };
962
+ }) : ie.value), st = b(() => gt.value.map((l, r) => ({
963
+ absoluteIndex: r,
964
+ ...l,
965
+ series: l.series.map((e) => e + Ot.value),
966
+ absoluteValues: l.series,
967
+ segregate: () => da(l),
968
+ isSegregated: re.value.includes(l.id)
969
+ }))), Ye = b(() => gt.value.map((l, r) => ({
970
+ ...l,
971
+ series: l.series.map((e) => e + Ot.value),
972
+ absoluteValues: l.series
973
+ })).filter((l) => !re.value.includes(l.id)));
974
+ function Ea() {
975
+ let l = 0;
976
+ It.value && (l = Array.from(It.value.querySelectorAll("text")).reduce((a, s) => {
977
+ const o = s.getComputedTextLength();
978
+ return (o > a ? o : a) + t.value.chart.grid.labels.yAxis.scaleValueOffsetX;
979
+ }, 0));
980
+ const r = Yt.value ? Yt.value.getBoundingClientRect().width + t.value.chart.grid.labels.axis.yLabelOffsetX + _.value.yAxis : 0, e = t.value.chart.grid.labels.yAxis.crosshairSize;
981
+ return l + r + e;
982
+ }
983
+ const El = p(0), Fa = ql((l) => {
984
+ El.value = l;
985
+ }, 100);
986
+ go((l) => {
987
+ const r = dt.value;
988
+ if (!r) return;
989
+ const e = new ResizeObserver((u) => {
990
+ Fa(u[0].contentRect.height);
991
+ });
992
+ e.observe(r), l(() => e.disconnect());
993
+ }), pl(() => {
994
+ El.value = 0;
995
+ });
996
+ const Kl = b(() => {
997
+ let l = 0;
998
+ Fe.value && (l = Fe.value.getBBox().height);
999
+ let r = 0;
1000
+ return dt.value && (r = El.value), l + r + _.value.xAxis;
1001
+ }), Wa = b(() => ie.value.some((l) => l.useProgression)), c = b(() => {
1002
+ let l = 0;
1003
+ const r = 36;
1004
+ t.value.chart.grid.labels.show && (y.value.useIndividualScale && !y.value.isStacked ? l = (ie.value.length - re.value.length) * (t.value.chart.grid.labels.yAxis.labelWidth + r) : y.value.useIndividualScale && y.value.isStacked ? l = t.value.chart.grid.labels.yAxis.labelWidth + r : l = Ea());
1005
+ const e = t.value.chart.labels.fontSize * 1.1, u = Wa.value ? 24 : 6;
1006
+ if (dt.value) {
1007
+ const o = dt.value.getBBox().x;
1008
+ o < 0 && (l += Math.abs(o));
1009
+ }
1010
+ const a = oe.value - l - t.value.chart.grid.labels.yAxis.crosshairSize - u - t.value.chart.padding.left - t.value.chart.padding.right, s = t.value.chart.grid.position === "middle" ? 0 : a / T.value / 2;
1011
+ return {
1012
+ top: t.value.chart.padding.top + e,
1013
+ right: oe.value - u - t.value.chart.padding.right,
1014
+ bottom: me.value - Kl.value - t.value.chart.padding.bottom - t.value.chart.grid.labels.axis.xLabelOffsetY,
1015
+ left: l + t.value.chart.grid.labels.yAxis.crosshairSize - s + t.value.chart.padding.left,
1016
+ height: me.value - Kl.value - t.value.chart.padding.top - t.value.chart.padding.bottom - e - t.value.chart.grid.labels.axis.xLabelOffsetY,
1017
+ width: a,
1018
+ scaleLabelX: l,
1019
+ individualOffsetX: r
1020
+ };
1021
+ }), Da = b(() => {
1022
+ const l = t.value.chart.grid.position === "middle" ? 1 : 0, r = T.value + l, e = X(c.value.top), u = X(c.value.bottom);
1023
+ return Array.from({ length: r }).map((a, s) => {
1024
+ const o = c.value.width / T.value * s + c.value.left + Q.value;
1025
+ return `M${o},${e} L${o},${u}`;
1026
+ }).join(" ");
1027
+ }), Ya = b(() => {
1028
+ if (!t.value.chart.grid.labels.xAxis.showCrosshairs) return "";
1029
+ const l = c.value.width / T.value, r = t.value.chart.grid.labels.xAxis.crosshairSize, e = t.value.chart.grid.labels.xAxis.crosshairsAlwaysAtZero;
1030
+ return Wl.value.map((u, a) => {
1031
+ if (!u || !u.text) return null;
1032
+ const s = c.value.left + l * a + l / 2, o = e ? Me.value - (Me.value === c.value.bottom ? 0 : r / 2) : c.value.bottom, I = e ? Me.value + r / (Me.value === c.value.bottom ? 1 : 2) : c.value.bottom + r;
1033
+ return `M${s},${o} L${s},${I}`;
1034
+ }).filter(Boolean).join(" ");
1035
+ });
1036
+ function Jl() {
1037
+ return !!qe?.vnode.props?.onSelectTimeLabel;
1038
+ }
1039
+ function Xa(l, r, e) {
1040
+ if (!Re.value) {
1041
+ const u = document.createElement("canvas");
1042
+ Re.value = u.getContext("2d");
1043
+ }
1044
+ return Re.value.font = `normal ${l}px sans-serif`, Re.value;
1045
+ }
1046
+ function Ql() {
1047
+ const l = fe.value.querySelectorAll(".vue-ui-xy-tag");
1048
+ l.length && Array.from(l).forEach((r) => r.style.opacity = "0");
1049
+ }
1050
+ function wl(l, r, e, u, a) {
1051
+ e && (We.value[`${l}_${r}_${u}_${a}`] = e);
1052
+ }
1053
+ const jl = p(!1);
1054
+ async function ea(l = !1) {
1055
+ await ll(), jl.value = l, Ut.value && (Zt.value = l);
1056
+ }
1057
+ function Fl() {
1058
+ ye.value = !ye.value;
1059
+ }
1060
+ const he = b(() => {
1061
+ const l = Math.max(...ie.value.map((r) => Qe({ data: r.series, threshold: t.value.downsample.threshold }).length));
1062
+ return Va({
1063
+ values: t.value.chart.grid.labels.xAxisLabels.values,
1064
+ maxDatapoints: l,
1065
+ formatter: t.value.chart.grid.labels.xAxisLabels.datetimeFormatter,
1066
+ start: w.value.start,
1067
+ end: w.value.end
1068
+ });
1069
+ }), ta = b(() => {
1070
+ const l = Math.max(...ie.value.map((r) => Qe({ data: r.series, threshold: t.value.downsample.threshold }).length));
1071
+ return Va({
1072
+ values: t.value.chart.grid.labels.xAxisLabels.values,
1073
+ maxDatapoints: l,
1074
+ formatter: t.value.chart.grid.labels.xAxisLabels.datetimeFormatter,
1075
+ start: 0,
1076
+ end: _e.value
1077
+ });
1078
+ }), Ga = b(() => {
1079
+ const l = t.value.chart.grid.labels.xAxisLabels.modulo;
1080
+ return he.value.length ? Math.min(l, [...new Set(he.value.map((r) => r.text))].length) : l;
1081
+ }), Wl = b(() => {
1082
+ const l = t.value.chart.grid.labels.xAxisLabels, r = he.value || [];
1083
+ if (l.showOnlyFirstAndLast) {
1084
+ if (r.length <= 2) return r;
1085
+ const k = S.value;
1086
+ return r.map(
1087
+ (N, A) => A === 0 || A === r.length - 1 || k != null && A === k ? N : { ...N, text: "" }
1088
+ );
1089
+ }
1090
+ if (!l.showOnlyAtModulo) return r;
1091
+ const e = Math.max(1, Ga.value || 1);
1092
+ if (T.value <= e) return r;
1093
+ const u = e, a = ta.value || [], s = w.value.start ?? 0, o = [];
1094
+ for (let k = 0; k < r.length; k += 1) {
1095
+ const N = r[k]?.text ?? "";
1096
+ if (!N) continue;
1097
+ const A = s + k - 1 >= 0 ? a[s + k - 1]?.text ?? "" : null;
1098
+ N !== A && o.push(k);
1099
+ }
1100
+ if (!o.length) return r.map((k) => ({ ...k, text: "" }));
1101
+ const I = o.length, E = Math.max(2, Math.min(u - 3, I)), F = Math.min(I, u + 3);
1102
+ let M = Math.min(u, I), H = 1 / 0;
1103
+ for (let k = E; k <= F; k += 1) {
1104
+ const N = (I - 1) % (k - 1), A = Math.abs(k - u), se = N * 10 + A;
1105
+ se < H && (H = se, M = k);
1106
+ }
1107
+ const Z = /* @__PURE__ */ new Set();
1108
+ if (M <= 1)
1109
+ Z.add(o[Math.round((I - 1) / 2)]);
1110
+ else {
1111
+ const k = (I - 1) / (M - 1);
1112
+ for (let N = 0; N < M; N += 1)
1113
+ Z.add(o[Math.round(N * k)]);
1114
+ }
1115
+ return r.map((k, N) => Z.has(N) ? k : { ...k, text: "" });
1116
+ });
1117
+ function la(l, r) {
1118
+ const e = Ye.value.map((u) => ({
1119
+ shape: u.shape || null,
1120
+ name: u.name,
1121
+ color: u.color,
1122
+ type: u.type,
1123
+ value: u.absoluteValues.find((a, s) => s === r),
1124
+ comments: u.comments || [],
1125
+ prefix: u.prefix || t.value.chart.labels.prefix,
1126
+ suffix: u.suffix || t.value.chart.labels.suffix
1127
+ }));
1128
+ tt("selectTimeLabel", {
1129
+ datapoint: e,
1130
+ absoluteIndex: l.absoluteIndex,
1131
+ label: l.text
1132
+ });
1133
+ }
1134
+ const T = b(() => {
1135
+ const l = cl((w.value.end ?? 0) - (w.value.start ?? 0));
1136
+ return Math.max(1, l);
1137
+ });
1138
+ function aa(l) {
1139
+ O.value = l;
1140
+ }
1141
+ function oa() {
1142
+ y.value.isStacked = !y.value.isStacked, y.value.isStacked ? y.value.useIndividualScale = !0 : y.value.useIndividualScale = t.value.chart.grid.labels.yAxis.useIndividualScale;
1143
+ }
1144
+ function Dl(l) {
1145
+ mt.value && l.autoScaling && (t.value.chart.grid.labels.yAxis.useIndividualScale || console.warn(`VueUiXy (datapoint: ${l.name}) : autoScaling only works when config.chart.grid.labels.yAxis.useIndividualScale is set to true`), t.value.chart.grid.labels.yAxis.stacked || console.warn(`VueUiXy (datapoint: ${l.name}) : autoScaling only works when config.chart.grid.labels.yAxis.stacked is set to true`));
1146
+ }
1147
+ function Ua(l, r) {
1148
+ const e = cl(l), u = Array(e).fill(0);
1149
+ for (let a = 0; a < r.length && a < e; a += 1) u[a] = r[a] ?? 0;
1150
+ return u;
1151
+ }
1152
+ function Za(l) {
1153
+ const r = Math.max(...ie.value.map((e) => Qe({ data: e.series, threshold: t.value.downsample.threshold }).length));
1154
+ return l > r ? r : l < 0 || t.value.chart.zoom.startIndex !== null && l < t.value.chart.zoom.startIndex ? t.value.chart.zoom.startIndex !== null ? t.value.chart.zoom.startIndex + 1 : 1 : l;
1155
+ }
1156
+ async function Sl() {
1157
+ await ll(), await ll();
1158
+ const { startIndex: l, endIndex: r } = t.value.chart.zoom, e = Ne.value, u = Math.max(
1159
+ ...ie.value.map(
1160
+ (a) => Qe({
1161
+ data: a.series,
1162
+ threshold: t.value.downsample.threshold
1163
+ }).length
1164
+ )
1165
+ );
1166
+ (l != null || r != null) && e ? (l != null && (w.value.start = l, e.setStartValue(l)), r != null && (w.value.end = r + 1, e.setEndValue(Za(r + 1)))) : (w.value = { start: 0, end: u }, Xt.value += 1), De.value.start = w.value.start, De.value.end = w.value.end, te();
1167
+ }
1168
+ async function na() {
1169
+ await Sl();
1170
+ }
1171
+ function Oe(l) {
1172
+ return ![null, void 0, NaN, 1 / 0, -1 / 0].includes(l);
1173
+ }
1174
+ const ua = b(() => Pe.value.max + Ot.value);
1175
+ function Ht(l) {
1176
+ return l / (Oe(ua.value) ? ua.value : 1);
1177
+ }
1178
+ const Me = b(() => isNaN(Ht(Ot.value)) ? c.value.bottom : c.value.bottom - c.value.height * Ht(Ot.value));
1179
+ function ia(l) {
1180
+ const r = ![null, void 0].includes(t.value.chart.grid.labels.yAxis.scaleMin) && t.value.chart.grid.labels.yAxis.scaleMin > 0 && St.value >= 0 ? c.value.bottom : Me.value;
1181
+ return l.value >= 0 ? B(r - l.y <= 0 ? 1e-5 : r - l.y) : B(l.y - Me.value <= 0 ? 1e-5 : l.y - Me.value);
1182
+ }
1183
+ function sa(l) {
1184
+ return l.value >= 0 ? B(l.zeroPosition - l.y <= 0 ? 1e-5 : l.zeroPosition - l.y) : B(l.y - l.zeroPosition <= 0 ? 1e-5 : l.zeroPosition - l.y);
1185
+ }
1186
+ const le = b(() => {
1187
+ const l = Math.max(1, T.value), r = Math.max(1, c.value.width), e = Math.max(1, gt.value.filter((u) => u.type === "bar" && !re.value.includes(u.id)).length);
1188
+ return {
1189
+ bar: vl(r, l * e, 1),
1190
+ plot: vl(r, l, 1),
1191
+ line: vl(r, l, 1)
1192
+ };
1193
+ });
1194
+ function Jt() {
1195
+ return y.value.useIndividualScale && y.value.isStacked ? le.value.line - c.value.width / T.value * 0.1 : le.value.bar;
1196
+ }
1197
+ function $l(l) {
1198
+ return y.value.useIndividualScale && y.value.isStacked ? l.x + c.value.width / T.value * 0.05 : l.x + le.value.bar / 2;
1199
+ }
1200
+ function ra(l) {
1201
+ return l.value >= 0 ? l.y : [null, void 0, NaN, 1 / 0, -1 / 0].includes(Me.value) ? c.bottom.value : Me.value;
1202
+ }
1203
+ function ca(l) {
1204
+ return l.value >= 0 ? l.y : [null, void 0, NaN, 1 / 0, -1 / 0].includes(l.zeroPosition) ? 0 : l.zeroPosition;
1205
+ }
1206
+ const hl = p(null);
1207
+ function qa(l) {
1208
+ if (ye.value) return;
1209
+ const r = $e.value.getBoundingClientRect(), u = $e.value.viewBox.baseVal.width / r.width, s = (l.clientX - r.left) * u - c.value.left, o = c.value.width / T.value, I = Math.floor(s / o);
1210
+ I >= 0 && I < T.value ? hl.value !== I && (hl.value = I, wa(!0, I)) : va();
1211
+ }
1212
+ function va() {
1213
+ hl.value = null, wa(!1, null);
1214
+ }
1215
+ function Ka() {
1216
+ hl.value != null && Ja(hl.value);
1217
+ }
1218
+ function Ja(l) {
1219
+ const r = Ye.value.map((e) => ({
1220
+ name: e.name,
1221
+ value: [null, void 0, NaN].includes(e.absoluteValues[l]) ? null : e.absoluteValues[l],
1222
+ color: e.color,
1223
+ type: e.type
1224
+ }));
1225
+ tt(
1226
+ "selectX",
1227
+ {
1228
+ dataset: r,
1229
+ index: l,
1230
+ indexLabel: t.value.chart.grid.labels.xAxisLabels.values[l]
1231
+ }
1232
+ ), t.value.events.datapointClick && t.value.events.datapointClick({ datapoint: r, seriesIndex: l + w.value.start });
1233
+ }
1234
+ function Qa() {
1235
+ return st.value.map((l) => ({
1236
+ values: l.absoluteValues,
1237
+ color: l.color,
1238
+ name: l.name,
1239
+ type: l.type
1240
+ }));
1241
+ }
1242
+ async function ja({ scale: l = 2 } = {}) {
1243
+ if (!fe.value) return;
1244
+ const { width: r, height: e } = fe.value.getBoundingClientRect(), u = r / e, { imageUri: a, base64: s } = await Wo({ domElement: fe.value, base64: !0, img: !0, scale: l });
1245
+ return {
1246
+ imageUri: a,
1247
+ base64: s,
1248
+ title: t.value.chart.title.text,
1249
+ width: r,
1250
+ height: e,
1251
+ aspectRatio: u
1252
+ };
1253
+ }
1254
+ function da(l) {
1255
+ if (re.value.includes(l.id))
1256
+ re.value = re.value.filter((r) => r !== l.id);
1257
+ else {
1258
+ if (re.value.length + 1 === gt.value.length) return;
1259
+ re.value.push(l.id);
1260
+ }
1261
+ tt("selectLegend", Ye.value.map((r) => ({
1262
+ name: r.name,
1263
+ values: r.absoluteValues,
1264
+ color: r.color,
1265
+ type: r.type
1266
+ }))), Rt.value += 1;
1267
+ }
1268
+ const eo = b(() => {
1269
+ const l = t.value.chart.title.text || "Chart visualization", r = t.value.chart.title.subtitle.text || "";
1270
+ return `${l}. ${r}`;
1271
+ }), ha = b(() => ({
1272
+ linePlot: T.value > t.value.line.dot.hideAboveMaxSerieLength
1273
+ })), to = b(() => t.value.chart.userOptions.show && (!t.value.chart.title.show || !t.value.chart.title.text)), lo = b(() => {
1274
+ if (Array.isArray(t.value.chart.highlightArea))
1275
+ return t.value.chart.highlightArea.map((r) => {
1276
+ const e = Math.min(r.to, _e.value - 1);
1277
+ return {
1278
+ ...r,
1279
+ span: r.from === e ? 1 : e < r.from ? 0 : e - r.from + 1
1280
+ };
1281
+ });
1282
+ const l = {
1283
+ ...t.value.chart.highlightArea,
1284
+ to: Math.min(t.value.chart.highlightArea.to, _e.value - 1)
1285
+ };
1286
+ return [{ ...l, span: l.from === l.to ? 1 : l.to < l.from ? 0 : l.to - l.from + 1 }];
1287
+ }), ao = b(() => ul.value ? ie.value.map((l, r) => ({
1288
+ ...l,
1289
+ series: Qe({
1290
+ data: l.series,
1291
+ threshold: t.value.downsample.threshold
1292
+ }),
1293
+ id: `uniqueId_${r}`
1294
+ })) : ie.value), oo = b(() => Ye.value.map((l) => {
1295
+ const r = l.absoluteValues.map((e) => [void 0, null].includes(e) ? 0 : e);
1296
+ return {
1297
+ id: l.id,
1298
+ name: l.name,
1299
+ color: l.color,
1300
+ values: Ua(T.value, r)
1301
+ };
1302
+ })), no = b(() => ({
1303
+ responsiveBreakpoint: t.value.table.responsiveBreakpoint,
1304
+ roundingValues: t.value.table.rounding,
1305
+ showAverage: !1,
1306
+ showMedian: !1,
1307
+ showTotal: !1,
1308
+ fontFamily: t.value.chart.fontFamily,
1309
+ prefix: t.value.chart.labels.prefix,
1310
+ suffix: t.value.chart.labels.suffix,
1311
+ colNames: he.value.map((l) => l.text),
1312
+ thead: {
1313
+ backgroundColor: t.value.table.th.backgroundColor,
1314
+ color: t.value.table.th.color,
1315
+ outline: t.value.table.th.outline
1316
+ },
1317
+ tbody: {
1318
+ backgroundColor: t.value.table.td.backgroundColor,
1319
+ color: t.value.table.td.color,
1320
+ outline: t.value.table.td.outline
1321
+ },
1322
+ userOptions: {
1323
+ show: !1
1324
+ }
1325
+ })), Q = b(() => t.value.chart.grid.position === "middle" ? 0 : c.value.width / T.value / 2), Vt = b(() => Mo(st.value.filter((l) => !re.value.includes(l.id)))), z = b(() => {
1326
+ const l = Object.groupBy(Vt.value, (e) => e.scaleLabel), r = {};
1327
+ for (const [e, u] of Object.entries(l)) {
1328
+ const a = u.flatMap((s) => s.absoluteValues);
1329
+ r[e] = {
1330
+ min: Math.min(...a) || 0,
1331
+ max: Math.max(...a) || 1,
1332
+ groupId: `scale_group_${Rl()}`
1333
+ };
1334
+ }
1335
+ return r;
1336
+ }), uo = b(() => {
1337
+ const l = gt.value.filter((r) => r.type === "bar").filter((r) => !re.value.includes(r.id)).length;
1338
+ return c.value.width / T.value / l - _l.value * l;
1339
+ }), _l = b(() => le.value.line * t.value.bar.periodGap), Ll = b(() => Math.max(1e-5, Jt() - (y.value.useIndividualScale && y.value.isStacked ? 0 : _l.value))), Ml = b(() => Ll.value * Math.min(Math.abs(t.value.bar.innerGap), 0.95)), fa = b(() => {
1340
+ if (!t.value.chart.zoom.minimap.show) return [];
1341
+ const l = ao.value.filter((a) => !re.value.includes(a.id)), r = Math.max(...l.map((a) => a.series.length)), e = [];
1342
+ for (let a = 0; a < r; a += 1)
1343
+ e.push(l.map((s) => s.series[a] || 0).reduce((s, o) => (s || 0) + (o || 0), 0));
1344
+ const u = Math.min(...e);
1345
+ return e.map((a) => a + (u < 0 ? Math.abs(u) : 0));
1346
+ }), Qt = b(() => Ye.value.map((l) => ({
1347
+ slotAbsoluteIndex: l.slotAbsoluteIndex,
1348
+ shape: l.shape || null,
1349
+ name: l.name,
1350
+ color: l.color,
1351
+ type: l.type,
1352
+ value: l.absoluteValues.find((r, e) => e === S.value),
1353
+ comments: l.comments || [],
1354
+ prefix: l.prefix || t.value.chart.labels.prefix,
1355
+ suffix: l.suffix || t.value.chart.labels.suffix
1356
+ }))), ma = b(() => Pe.value.ticks.map((l) => ({
1357
+ y: l >= 0 ? Me.value - c.value.height * Ht(l) : Me.value + c.value.height * Ht(Math.abs(l)),
1358
+ value: l,
1359
+ prefix: t.value.chart.labels.prefix,
1360
+ suffix: t.value.chart.labels.suffix
1361
+ }))), ga = b(() => {
1362
+ const l = t.value.chart.annotations;
1363
+ if (!l || !Array.isArray(l) || l.every((M) => !M.show)) return [];
1364
+ const r = l.filter(
1365
+ (M) => M.show && (M.yAxis.yTop != null || M.yAxis.yBottom != null)
1366
+ );
1367
+ if (!r.length) return [];
1368
+ const { left: e, right: u } = c.value, a = Me.value, s = c.value.height, o = Pe.value.min, E = Pe.value.max - o, F = (M) => {
1369
+ const H = (M - 0) / E;
1370
+ return a - H * s;
1371
+ };
1372
+ return r.map((M) => {
1373
+ const { yAxis: { yTop: H, yBottom: Z, label: k } } = M, N = H != null && Z != null && H !== Z, A = H == null ? null : F(H), se = Z == null ? null : F(Z), Ce = Xa(k.fontSize);
1374
+ Ce.font = `${k.fontSize}px sans-serif`;
1375
+ const ee = Ce.measureText(k.text).width, Xe = k.fontSize, rt = (k.position === "start" ? e + k.padding.left : u - k.padding.right) + k.offsetX, He = (A != null && se != null ? Math.min(A, se) : A ?? se) - k.fontSize / 3 + k.offsetY - k.padding.top;
1376
+ let D;
1377
+ k.textAnchor === "middle" ? D = rt - ee / 2 - k.padding.left : k.textAnchor === "end" ? D = rt - ee - k.padding.right : D = rt - k.padding.left;
1378
+ const Y = He - Xe * 0.75 - k.padding.top;
1379
+ return {
1380
+ show: ![A, se, Y].includes(NaN),
1381
+ id: `annotation_y_${Rl()}`,
1382
+ hasArea: N,
1383
+ areaHeight: N ? Math.abs(A - se) : 0,
1384
+ yTop: A,
1385
+ yBottom: se,
1386
+ config: M.yAxis,
1387
+ x1: e,
1388
+ x2: u,
1389
+ _text: { x: rt, y: He },
1390
+ _box: {
1391
+ x: D,
1392
+ y: Y,
1393
+ width: ee + k.padding.left + k.padding.right,
1394
+ height: Xe + k.padding.top + k.padding.bottom,
1395
+ fill: k.backgroundColor,
1396
+ stroke: k.border.stroke,
1397
+ rx: k.border.rx,
1398
+ ry: k.border.ry,
1399
+ strokeWidth: k.border.strokeWidth
1400
+ }
1401
+ };
1402
+ });
1403
+ });
1404
+ function xa(l, r) {
1405
+ const e = l[r - 1], u = l[r + 1];
1406
+ let a = !!e && !!u && e.value == null && u.value == null || !e && !!u && u.value == null || !!e && !u && e.value == null;
1407
+ return Oe(l[r].value) && a && t.value.line.cutNullValues;
1408
+ }
1409
+ const xt = b(() => {
1410
+ const l = Vt.value.filter((o) => ["bar", "line", "plot"].includes(o.type)), r = l.length, e = t.value.chart.grid.labels.yAxis.gap, u = y.value.isStacked, a = u ? e * (r - 1) : 0, s = c.value.height - a;
1411
+ return l.filter((o) => o.type === "bar").map((o, I) => {
1412
+ Dl(o);
1413
+ const E = z.value[o.scaleLabel].min, F = z.value[o.scaleLabel].max;
1414
+ o.absoluteValues.filter((W) => ![null, void 0].includes(W)).map((W) => (W - E) / (F - E));
1415
+ const M = {
1416
+ valueMin: E,
1417
+ valueMax: F < 0 ? 0 : F
1418
+ }, H = {
1419
+ max: o.scaleMax || Math.max(...o.absoluteValues) || 1,
1420
+ min: o.scaleMin || Math.min(...o.absoluteValues.filter((W) => ![void 0, null].includes(W))) > 0 ? 0 : Math.min(...o.absoluteValues.filter((W) => ![null, void 0].includes(W)))
1421
+ }, Z = o.scaleSteps || t.value.chart.grid.labels.yAxis.commonScaleSteps, k = 1.0000001, N = t.value.chart.grid.labels.yAxis.useNiceScale ? xl(H.min, H.max === H.min ? H.max * k : H.max, Z) : Et(H.min, H.max === H.min ? H.max * k : H.max, Z), A = t.value.chart.grid.labels.yAxis.useNiceScale ? xl(M.valueMin, M.valueMax === M.valueMin ? M.valueMax * k : M.valueMax, Z) : Et(M.valueMin, M.valueMax === M.valueMin ? M.valueMax * k : M.valueMax, Z), se = N.min >= 0 ? 0 : Math.abs(N.min), Ce = 0, ee = N.max + se, Xe = A.max + Math.abs(Ce), rt = o.stackIndex, jt = r - 1 - rt, He = u ? 1 - o.cumulatedStackRatio : 0, D = u ? s * He + e * jt : 0, Y = u ? s * o.stackRatio : c.value.height, ce = c.value.bottom - D - Y * se / ee, Ve = c.value.bottom - D - Y * Ce / Xe, Ae = st.value.filter((W) => W.type === "bar").filter((W) => !re.value.includes(W.id)).length, ml = o.series.map((W, de) => {
1422
+ const _t = y.value.useIndividualScale ? (o.absoluteValues[de] + se) / ee : Ht(W), Bt = y.value.useIndividualScale && y.value.isStacked ? c.value.left + c.value.width / T.value * de : c.value.left + le.value.bar * I + le.value.bar * de * Ae - uo.value / 2 - I * _l.value;
1423
+ return {
1424
+ yOffset: B(D),
1425
+ individualHeight: B(Y),
1426
+ x: B(Bt),
1427
+ y: c.value.bottom - D - Y * _t,
1428
+ value: o.absoluteValues[de],
1429
+ zeroPosition: B(ce),
1430
+ individualMax: B(ee),
1431
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[de] || ""
1432
+ };
1433
+ }), Ie = o.absoluteValues.map((W) => A.min >= 0 ? (W - Math.abs(A.min)) / (A.max - Math.abs(A.min)) : (W + Math.abs(A.min)) / (A.max + Math.abs(A.min))), $t = o.series.map((W, de) => {
1434
+ const _t = y.value.useIndividualScale && y.value.isStacked ? c.value.left + c.value.width / T.value * de : c.value.left - le.value.bar / 2 + le.value.bar * I + le.value.bar * de * st.value.filter((Bt) => Bt.type === "bar").filter((Bt) => !re.value.includes(Bt.id)).length;
1435
+ return {
1436
+ yOffset: B(D),
1437
+ individualHeight: B(Y),
1438
+ x: B(_t),
1439
+ y: B(c.value.bottom - B(D) - (B(Y) * Ie[de] || 0)),
1440
+ value: o.absoluteValues[de],
1441
+ zeroPosition: B(ce),
1442
+ individualMax: B(ee),
1443
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[de] || ""
1444
+ };
1445
+ }), K = N.ticks.map((W) => ({
1446
+ y: W >= 0 ? ce - Y * (W / ee) : ce + Y * Math.abs(W) / ee,
1447
+ value: W,
1448
+ prefix: o.prefix || t.value.chart.labels.prefix,
1449
+ suffix: o.suffix || t.value.chart.labels.suffix,
1450
+ datapoint: o
1451
+ })), ve = A.ticks.map((W) => {
1452
+ const de = (W - A.min) / (A.max - A.min);
1453
+ return {
1454
+ y: W >= 0 ? Ve - Y * de : Ve + Y * de,
1455
+ value: W,
1456
+ prefix: o.prefix || t.value.chart.labels.prefix,
1457
+ suffix: o.suffix || t.value.chart.labels.suffix,
1458
+ datapoint: o
1459
+ };
1460
+ });
1461
+ return z.value[o.scaleLabel].name = o.name, z.value[o.scaleLabel].groupName = o.scaleLabel, z.value[o.scaleLabel].groupColor = t.value.chart.grid.labels.yAxis.groupColor || o.color, z.value[o.scaleLabel].color = o.color, z.value[o.scaleLabel].scaleYLabels = o.autoScaling ? ve : K, z.value[o.scaleLabel].zeroPosition = o.autoScaling ? Ve : ce, z.value[o.scaleLabel].individualMax = o.autoScaling ? Xe : ee, z.value[o.scaleLabel].scaleLabel = o.scaleLabel, z.value[o.scaleLabel].id = o.id, z.value[o.scaleLabel].yOffset = D, z.value[o.scaleLabel].individualHeight = Y, z.value[o.scaleLabel].autoScaleYLabels = ve, z.value[o.scaleLabel].unique = Vt.value.filter((W) => W.scaleLabel === o.scaleLabel).length === 1, {
1462
+ ...o,
1463
+ yOffset: D,
1464
+ autoScaleYLabels: ve,
1465
+ individualHeight: Y,
1466
+ scaleYLabels: o.autoScaling ? ve : K,
1467
+ individualScale: o.autoScaling ? A : N,
1468
+ individualMax: o.autoScaling ? Xe : ee,
1469
+ zeroPosition: o.autoScaling ? Ve : ce,
1470
+ plots: o.autoScaling ? $t : ml,
1471
+ groupId: z.value[o.scaleLabel].groupId
1472
+ };
1473
+ });
1474
+ }), Te = b(() => {
1475
+ const l = Vt.value.filter((o) => ["bar", "line", "plot"].includes(o.type)), r = l.length, e = t.value.chart.grid.labels.yAxis.gap, u = y.value.isStacked, a = u ? e * (r - 1) : 0, s = c.value.height - a;
1476
+ return l.filter((o) => o.type === "line").map((o, I) => {
1477
+ Dl(o);
1478
+ const E = z.value[o.scaleLabel].min, F = z.value[o.scaleLabel].max;
1479
+ o.absoluteValues.filter((V) => ![null, void 0].includes(V)).map((V) => (V - E) / (F - E));
1480
+ const M = {
1481
+ valueMin: E,
1482
+ valueMax: F
1483
+ }, H = {
1484
+ max: o.scaleMax || Math.max(...o.absoluteValues) || 1,
1485
+ min: o.scaleMin || (Math.min(...o.absoluteValues) > 0 ? 0 : Math.min(...o.absoluteValues))
1486
+ }, Z = o.scaleSteps || t.value.chart.grid.labels.yAxis.commonScaleSteps, k = 1.0000001, N = t.value.chart.grid.labels.yAxis.useNiceScale ? xl(H.min, H.max === H.min ? H.max * k : H.max, Z) : Et(H.min, H.max === H.min ? H.max * k : H.max, Z), A = t.value.chart.grid.labels.yAxis.useNiceScale ? xl(M.valueMin, M.valueMax === M.valueMin ? M.valueMax * k : M.valueMax, Z) : Et(M.valueMin, M.valueMax === M.valueMin ? M.valueMax * k : M.valueMax, Z), se = N.min >= 0 ? 0 : Math.abs(N.min), Ce = 0, ee = N.max + Math.abs(se), Xe = A.max + Math.abs(Ce), rt = o.stackIndex, jt = r - 1 - rt, He = u ? 1 - o.cumulatedStackRatio : 0, D = u ? s * He + e * jt : 0, Y = u ? s * o.stackRatio : c.value.height, ce = c.value.bottom - D - Y * se / ee, Ve = c.value.bottom - D - Y * Ce / Xe, Ae = o.series.map((V, we) => {
1487
+ const ro = y.value.useIndividualScale ? (o.absoluteValues[we] + Math.abs(se)) / ee : Ht(V);
1488
+ return {
1489
+ x: B(c.value.left + le.value.line / 2 + le.value.line * we),
1490
+ y: B(c.value.bottom - D - Y * ro),
1491
+ value: o.absoluteValues[we],
1492
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[we] || ""
1493
+ };
1494
+ }), ml = o.absoluteValues.map((V) => A.min >= 0 ? (V - Math.abs(A.min)) / (A.max - Math.abs(A.min)) : (V + Math.abs(A.min)) / (A.max + Math.abs(A.min))), Ie = o.series.map((V, we) => [void 0, null].includes(o.absoluteValues[we]) ? {
1495
+ x: B(c.value.left + le.value.line / 2 + le.value.line * we),
1496
+ y: ce,
1497
+ value: o.absoluteValues[we],
1498
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[we] || ""
1499
+ } : {
1500
+ x: B(c.value.left + le.value.line / 2 + le.value.line * we),
1501
+ y: B(c.value.bottom - D - (Y * ml[we] || 0)),
1502
+ value: o.absoluteValues[we],
1503
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[we] || ""
1504
+ }), $t = t.value.line.cutNullValues ? Ta(Ae) : Pl(Ae.filter((V) => V.value !== null)), K = t.value.line.cutNullValues ? Ta(Ie) : Pl(Ie.filter((V) => V.value !== null)), ve = t.value.line.cutNullValues ? Ia(Ae) : Ol(Ae.filter((V) => V.value !== null)), W = t.value.line.cutNullValues ? Ia(Ie) : Ol(Ie.filter((V) => V.value !== null)), de = N.ticks.map((V) => ({
1505
+ y: V >= 0 ? ce - Y * (V / ee) : ce + Y * Math.abs(V) / ee,
1506
+ value: V,
1507
+ prefix: o.prefix || t.value.chart.labels.prefix,
1508
+ suffix: o.suffix || t.value.chart.labels.suffix,
1509
+ datapoint: o
1510
+ })), _t = A.ticks.map((V) => {
1511
+ const we = (V - A.min) / (A.max - A.min);
1512
+ return {
1513
+ y: V >= 0 ? Ve - Y * we : Ve + Y * we,
1514
+ value: V,
1515
+ prefix: o.prefix || t.value.chart.labels.prefix,
1516
+ suffix: o.suffix || t.value.chart.labels.suffix,
1517
+ datapoint: o
1518
+ };
1519
+ });
1520
+ z.value[o.scaleLabel].name = o.name, z.value[o.scaleLabel].groupName = o.scaleLabel, z.value[o.scaleLabel].groupColor = t.value.chart.grid.labels.yAxis.groupColor || o.color, z.value[o.scaleLabel].color = o.color, z.value[o.scaleLabel].scaleYLabels = o.autoScaling ? _t : de, z.value[o.scaleLabel].zeroPosition = o.autoScaling ? Ve : ce, z.value[o.scaleLabel].individualMax = o.autoScaling ? Xe : ee, z.value[o.scaleLabel].scaleLabel = o.scaleLabel, z.value[o.scaleLabel].id = o.id, z.value[o.scaleLabel].yOffset = D, z.value[o.scaleLabel].individualHeight = Y, z.value[o.scaleLabel].autoScaleYLabels = _t, z.value[o.scaleLabel].unique = Vt.value.filter((V) => V.scaleLabel === o.scaleLabel).length === 1;
1521
+ const Bt = y.value.useIndividualScale ? o.autoScaling ? Ve : ce : Me.value, gl = Math.max(Math.max(o.autoScaling ? Ve : de.at(-1) ? de.at(-1).y : 0, c.value.top), Bt);
1522
+ return {
1523
+ ...o,
1524
+ yOffset: D,
1525
+ autoScaleYLabels: _t,
1526
+ individualHeight: Y,
1527
+ scaleYLabels: o.autoScaling ? _t : de,
1528
+ individualScale: o.autoScaling ? A : N,
1529
+ individualMax: o.autoScaling ? Xe : ee,
1530
+ zeroPosition: o.autoScaling ? Ve : ce,
1531
+ curve: o.autoScaling ? K : $t,
1532
+ plots: o.autoScaling ? Ie : Ae,
1533
+ area: o.useArea ? y.value.useIndividualScale ? t.value.line.cutNullValues ? Na(
1534
+ o.autoScaling ? Ie : Ae,
1535
+ gl
1536
+ ) : Ra(
1537
+ o.autoScaling ? Ie.filter((V) => V.value !== null) : Ae.filter((V) => V.value !== null),
1538
+ gl
1539
+ ) : t.value.line.cutNullValues ? Na(Ae, gl) : Ra(Ae.filter((V) => V.value !== null), gl) : "",
1540
+ curveAreas: o.useArea ? Co(
1541
+ o.autoScaling ? t.value.line.cutNullValues ? Ie : Ie.filter((V) => V.value !== null) : t.value.line.cutNullValues ? Ae : Ae.filter((V) => V.value !== null),
1542
+ gl,
1543
+ t.value.line.cutNullValues
1544
+ ) : [],
1545
+ straight: o.autoScaling ? W : ve,
1546
+ groupId: z.value[o.scaleLabel].groupId
1547
+ };
1548
+ });
1549
+ }), Je = b(() => {
1550
+ const l = Vt.value.filter((o) => ["bar", "line", "plot"].includes(o.type)), r = l.length, e = t.value.chart.grid.labels.yAxis.gap, u = y.value.isStacked, a = u ? e * (r - 1) : 0, s = c.value.height - a;
1551
+ return l.filter((o) => o.type === "plot").map((o) => {
1552
+ Dl(o);
1553
+ const I = z.value[o.scaleLabel].min, E = z.value[o.scaleLabel].max;
1554
+ o.absoluteValues.filter((K) => ![null, void 0].includes(K)).map((K) => (K - I) / (E - I));
1555
+ const F = {
1556
+ valueMin: I,
1557
+ valueMax: E
1558
+ }, M = {
1559
+ max: o.scaleMax || Math.max(...o.absoluteValues) || 1,
1560
+ min: o.scaleMin || Math.min(...o.absoluteValues) > 0 ? 0 : Math.min(...o.absoluteValues)
1561
+ }, H = o.scaleSteps || t.value.chart.grid.labels.yAxis.commonScaleSteps, Z = 1.0000001, k = Et(M.min, M.max === M.min ? M.max * Z : M.max, H), N = Et(F.valueMin, F.valueMax === F.valueMin ? F.valueMax * Z : F.valueMax, H), A = k.min >= 0 ? 0 : Math.abs(k.min), se = 0, Ce = k.max + A, ee = N.max + Math.abs(se), Xe = o.stackIndex, rt = r - 1 - Xe, jt = u ? 1 - o.cumulatedStackRatio : 0, He = u ? s * jt + e * rt : 0, D = u ? s * o.stackRatio : c.value.height, Y = c.value.bottom - He - D * A / Ce, ce = c.value.bottom - He - D * se / ee, Ve = o.series.map((K, ve) => {
1562
+ const W = y.value.useIndividualScale ? (o.absoluteValues[ve] + Math.abs(A)) / Ce : Ht(K);
1563
+ return {
1564
+ x: B(c.value.left + le.value.plot / 2 + le.value.plot * ve),
1565
+ y: B(c.value.bottom - He - D * W),
1566
+ value: o.absoluteValues[ve],
1567
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[ve] || ""
1568
+ };
1569
+ }), Ae = o.absoluteValues.map((K) => N.min >= 0 ? (K - Math.abs(N.min)) / (N.max - Math.abs(N.min)) : (K + Math.abs(N.min)) / (N.max + Math.abs(N.min))), ml = o.series.map((K, ve) => ({
1570
+ x: B(c.value.left + le.value.plot / 2 + le.value.plot * ve),
1571
+ y: B(c.value.bottom - He - (D * Ae[ve] || 0)),
1572
+ value: o.absoluteValues[ve],
1573
+ comment: o.comments && o.comments.slice(w.value.start, w.value.end)[ve] || ""
1574
+ })), Ie = k.ticks.map((K) => ({
1575
+ y: K >= 0 ? Y - D * (K / Ce) : Y + D * Math.abs(K) / Ce,
1576
+ value: K,
1577
+ prefix: o.prefix || t.value.chart.labels.prefix,
1578
+ suffix: o.suffix || t.value.chart.labels.suffix,
1579
+ datapoint: o
1580
+ })), $t = N.ticks.map((K) => {
1581
+ const ve = (K - N.min) / (N.max - N.min);
1582
+ return {
1583
+ y: K >= 0 ? ce - D * ve : ce + D * ve,
1584
+ value: K,
1585
+ prefix: o.prefix || t.value.chart.labels.prefix,
1586
+ suffix: o.suffix || t.value.chart.labels.suffix,
1587
+ datapoint: o
1588
+ };
1589
+ });
1590
+ return z.value[o.scaleLabel].name = o.name, z.value[o.scaleLabel].groupName = o.scaleLabel, z.value[o.scaleLabel].groupColor = t.value.chart.grid.labels.yAxis.groupColor || o.color, z.value[o.scaleLabel].color = o.color, z.value[o.scaleLabel].scaleYLabels = o.autoScaling ? $t : Ie, z.value[o.scaleLabel].zeroPosition = o.autoScaling ? ce : Y, z.value[o.scaleLabel].individualMax = o.autoScaling ? ee : Ce, z.value[o.scaleLabel].scaleLabel = o.scaleLabel, z.value[o.scaleLabel].id = o.id, z.value[o.scaleLabel].yOffset = He, z.value[o.scaleLabel].individualHeight = D, z.value[o.scaleLabel].autoScaleYLabels = $t, z.value[o.scaleLabel].unique = Vt.value.filter((K) => K.scaleLabel === o.scaleLabel).length === 1, {
1591
+ ...o,
1592
+ yOffset: He,
1593
+ autoScaleYLabels: $t,
1594
+ individualHeight: D,
1595
+ scaleYLabels: o.autoScaling ? $t : Ie,
1596
+ individualScale: o.autoScaling ? N : k,
1597
+ individualMax: o.autoScaling ? ee : Ce,
1598
+ zeroPosition: o.autoScaling ? ce : Y,
1599
+ plots: o.autoScaling ? ml : Ve,
1600
+ groupId: z.value[o.scaleLabel].groupId
1601
+ };
1602
+ });
1603
+ }), fl = b(() => {
1604
+ const l = Te.value.map((s) => ({
1605
+ name: s.name,
1606
+ color: s.color,
1607
+ scale: s.individualScale,
1608
+ scaleYLabels: s.scaleYLabels,
1609
+ zero: s.zeroPosition,
1610
+ max: s.individualMax,
1611
+ scaleLabel: s.scaleLabel || "",
1612
+ id: s.id,
1613
+ yOffset: s.yOffset || 0,
1614
+ individualHeight: s.individualHeight || c.value.height,
1615
+ autoScaleYLabels: s.autoScaleYLabels
1616
+ })), r = xt.value.map((s) => ({
1617
+ name: s.name,
1618
+ color: s.color,
1619
+ scale: s.individualScale,
1620
+ scaleYLabels: s.scaleYLabels,
1621
+ zero: s.zeroPosition,
1622
+ max: s.individualMax,
1623
+ scaleLabel: s.scaleLabel || "",
1624
+ id: s.id,
1625
+ yOffset: s.yOffset || 0,
1626
+ individualHeight: s.individualHeight || c.value.height
1627
+ })), e = Je.value.map((s) => ({
1628
+ name: s.name,
1629
+ color: s.color,
1630
+ scale: s.individualScale,
1631
+ scaleYLabels: s.scaleYLabels,
1632
+ // FIX
1633
+ zero: s.zeroPosition,
1634
+ max: s.individualMax,
1635
+ scaleLabel: s.scaleLabel || "",
1636
+ id: s.id,
1637
+ yOffset: s.yOffset || 0,
1638
+ individualHeight: s.individualHeight || c.value.height
1639
+ })), u = y.value.useIndividualScale && !y.value.isStacked ? Object.values(z.value) : [...l, ...r, ...e], a = u.flatMap((s) => s).length;
1640
+ return u.flatMap((s, o) => {
1641
+ let I = 0;
1642
+ I = y.value.isStacked ? c.value.left : c.value.left / a * (o + 1);
1643
+ const E = y.value.useIndividualScale && !y.value.isStacked ? s.unique ? s.name : s.groupName : s.name;
1644
+ return {
1645
+ unique: s.unique,
1646
+ id: s.id,
1647
+ groupId: s.groupId,
1648
+ scaleLabel: s.scaleLabel,
1649
+ name: Se(
1650
+ t.value.chart.grid.labels.yAxis.serieNameFormatter,
1651
+ E,
1652
+ E,
1653
+ s
1654
+ ),
1655
+ color: y.value.useIndividualScale && !y.value.isStacked ? s.unique ? s.color : s.groupColor : s.color,
1656
+ scale: s.scale,
1657
+ yOffset: s.yOffset,
1658
+ individualHeight: s.individualHeight,
1659
+ x: I,
1660
+ yLabels: s.scaleYLabels || s.scale.ticks.map((F) => ({
1661
+ y: F >= 0 ? s.zero - s.individualHeight * (F / s.max) : s.zero + s.individualHeight * Math.abs(F) / s.max,
1662
+ value: F
1663
+ }))
1664
+ };
1665
+ });
1666
+ }), ba = b(() => {
1667
+ const l = t.value.line.interLine || {}, r = l.pairs || [], e = l.colors || [];
1668
+ if (!r.length) return [];
1669
+ const u = [];
1670
+ return r.forEach((a, s) => {
1671
+ const [o, I] = Array.isArray(a) ? a : [a.a, a.b];
1672
+ if (!o || !I) return;
1673
+ const E = Te.value.find((k) => k.name === o), F = Te.value.find((k) => k.name === I);
1674
+ if (!E || !F || E.type !== "line" || F.type !== "line") return;
1675
+ const M = e?.[s]?.[0] ?? E.color, H = e?.[s]?.[1] ?? F.color;
1676
+ Ao({
1677
+ lineA: E.plots,
1678
+ lineB: F.plots,
1679
+ smoothA: !!E.smooth,
1680
+ smoothB: !!F.smooth,
1681
+ colorLineA: M,
1682
+ colorLineB: H,
1683
+ sampleStepPx: 2,
1684
+ cutNullValues: t.value.line.cutNullValues
1685
+ }).forEach((k, N) => {
1686
+ u.push({ ...k, key: `inter_${o}_${I}_${s}_${N}` });
1687
+ });
1688
+ }), u;
1689
+ }), pa = b(() => ({
1690
+ datapoint: Qt.value,
1691
+ seriesIndex: S.value,
1692
+ series: st.value,
1693
+ bars: xt.value,
1694
+ lines: Te.value,
1695
+ plots: Je.value,
1696
+ config: t.value
1697
+ })), io = b(() => {
1698
+ let l = "", r = Qt.value.map((a) => a.value).filter((a) => Tl(a) && a !== null).reduce((a, s) => Math.abs(a) + Math.abs(s), 0);
1699
+ const e = he.value[S.value], u = t.value.chart.tooltip.customFormat;
1700
+ return Pa(u) && zo(() => u({
1701
+ absoluteIndex: S.value + w.value.start,
1702
+ seriesIndex: S.value,
1703
+ datapoint: Qt.value,
1704
+ series: st.value,
1705
+ bars: xt.value,
1706
+ lines: Te.value,
1707
+ plots: Je.value,
1708
+ config: t.value
1709
+ })) ? u({
1710
+ absoluteIndex: S.value + w.value.start,
1711
+ seriesIndex: S.value,
1712
+ datapoint: Qt.value,
1713
+ series: st.value,
1714
+ bars: xt.value,
1715
+ lines: Te.value,
1716
+ plots: Je.value,
1717
+ config: t.value
1718
+ }) : (e && e.text && t.value.chart.tooltip.showTimeLabel && (l += `<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${t.value.chart.tooltip.borderColor}; width:100%">${e.text}</div>`), Qt.value.forEach((a) => {
1719
+ if (Tl(a.value)) {
1720
+ let s = "", o = "";
1721
+ switch (ne.value[a.type]) {
1722
+ case "bar":
1723
+ s = `<svg viewBox="0 0 40 40" height="14" width="14">${ol.pattern ? `<rect x="0" y="0" rx="1" stroke="none" height="40" width="40" fill="${a.color}" />` : ""}<rect x="0" y="0" rx="1" stroke="none" height="40" width="40" fill="${ol.pattern ? `url(#pattern_${G.value}_${a.slotAbsoluteIndex}` : a.color}" /></svg>`;
1724
+ break;
1725
+ case "line":
1726
+ !a.shape || !["star", "triangle", "square", "diamond", "pentagon", "hexagon"].includes(a.shape) ? o = `<circle cx="10" cy="8" r="4" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" fill="${a.color}" />` : a.shape === "triangle" ? o = `<path d="${ct({ plot: { x: 10, y: 8 }, radius: 4, sides: 3, rotation: 0.52 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" />` : a.shape === "square" ? o = `<path d="${ct({ plot: { x: 10, y: 8 }, radius: 4, sides: 4, rotation: 0.8 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" />` : a.shape === "diamond" ? o = `<path d="${ct({ plot: { x: 10, y: 8 }, radius: 4, sides: 4, rotation: 0 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" />` : a.shape === "pentagon" ? o = `<path d="${ct({ plot: { x: 10, y: 8 }, radius: 4, sides: 5, rotation: 0.95 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" />` : a.shape === "hexagon" ? o = `<path d="${ct({ plot: { x: 10, y: 8 }, radius: 4, sides: 6, rotation: 0 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" />` : a.shape === "star" && (o = `<polygon stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" fill="${a.color}" points="${Oa({ plot: { x: 10, y: 8 }, radius: 4 })}" />`), s = `<svg viewBox="0 0 20 12" height="14" width="20"><rect rx="1.5" x="0" y="6.5" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="0.5" height="3" width="20" fill="${a.color}" />${o}</svg>`;
1727
+ break;
1728
+ case "plot":
1729
+ if (!a.shape || !["star", "triangle", "square", "diamond", "pentagon", "hexagon"].includes(a.shape)) {
1730
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" fill="${a.color}" /></svg>`;
1731
+ break;
1732
+ }
1733
+ if (a.shape === "star") {
1734
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><polygon stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" fill="${a.color}" points="${Oa({ plot: { x: 6, y: 6 }, radius: 5 })}" /></svg>`;
1735
+ break;
1736
+ }
1737
+ if (a.shape === "triangle") {
1738
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${ct({ plot: { x: 6, y: 6 }, radius: 6, sides: 3, rotation: 0.52 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
1739
+ break;
1740
+ }
1741
+ if (a.shape === "square") {
1742
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${ct({ plot: { x: 6, y: 6 }, radius: 6, sides: 4, rotation: 0.8 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
1743
+ break;
1744
+ }
1745
+ if (a.shape === "diamond") {
1746
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${ct({ plot: { x: 6, y: 6 }, radius: 5, sides: 4, rotation: 0 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
1747
+ break;
1748
+ }
1749
+ if (a.shape === "pentagon") {
1750
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${ct({ plot: { x: 6, y: 6 }, radius: 5, sides: 5, rotation: 0.95 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
1751
+ break;
1752
+ }
1753
+ if (a.shape === "hexagon") {
1754
+ s = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${ct({ plot: { x: 6, y: 6 }, radius: 5, sides: 6, rotation: 0 }).path}" fill="${a.color}" stroke="${t.value.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
1755
+ break;
1756
+ }
1757
+ }
1758
+ l += `<div style="display:flex;flex-direction:row; align-items:center;gap:3px;"><div style="width:20px">${s}</div> ${a.name}: <b>${t.value.chart.tooltip.showValue ? Se(
1759
+ a.type === "line" ? t.value.line.labels.formatter : a.type === "bar" ? t.value.bar.labels.formatter : t.value.plot.labels.formatter,
1760
+ a.value,
1761
+ Ue({
1762
+ p: a.prefix,
1763
+ v: a.value,
1764
+ s: a.suffix,
1765
+ r: t.value.chart.tooltip.roundingValue
1766
+ }),
1767
+ { datapoint: a }
1768
+ ) : ""}</b> ${t.value.chart.tooltip.showPercentage ? `(${Ue({
1769
+ v: B(Math.abs(a.value) / r * 100),
1770
+ s: "%",
1771
+ r: t.value.chart.tooltip.roundingPercentage
1772
+ })})` : ""}</div>`, t.value.chart.comments.showInTooltip && a.comments.length && a.comments.slice(w.value.start, w.value.end)[S.value] && (l += `<div class="vue-data-ui-tooltip-comment" style="background:${a.color}20; padding: 6px; margin-bottom: 6px; border-left: 1px solid ${a.color}">${a.comments.slice(w.value.start, w.value.end)[S.value]}</div>`);
1773
+ }
1774
+ }), `<div style="border-radius:4px;padding:12px;font-variant-numeric: tabular-nums;color:${t.value.chart.tooltip.color}">${l}</div>`);
1775
+ }), ya = b(() => {
1776
+ if (gt.value.length === 0) return { head: [], body: [], config: {}, columnNames: [] };
1777
+ const l = Ye.value.map((e) => ({
1778
+ label: e.name,
1779
+ color: e.color,
1780
+ type: e.type
1781
+ })), r = [];
1782
+ return he.value.forEach((e, u) => {
1783
+ const a = [e.text];
1784
+ Ye.value.forEach((s) => {
1785
+ a.push(Oe(s.absoluteValues[u]) ? Number(s.absoluteValues[u].toFixed(t.value.table.rounding)) : "");
1786
+ }), r.push(a);
1787
+ }), { head: l, body: r };
1788
+ }), Cl = b(() => {
1789
+ const l = t.value.table.showSum;
1790
+ let r = [""].concat(Ye.value.map((s) => s.name));
1791
+ l && (r = r.concat(' <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>'));
1792
+ let e = [];
1793
+ for (let s = 0; s < T.value; s += 1) {
1794
+ const o = Ye.value.map((I) => I.absoluteValues[s] ?? 0).reduce((I, E) => I + E, 0);
1795
+ e.push(
1796
+ [
1797
+ he.value[s].text ?? "-"
1798
+ ].concat(Ye.value.map(
1799
+ (I) => Se(
1800
+ I.type === "line" ? t.value.line.labels.formatter : I.type === "bar" ? t.value.bar.labels.formatter : t.value.plot.labels.formatter,
1801
+ I.absoluteValues[s] ?? 0,
1802
+ Ue({
1803
+ p: I.prefix || t.value.chart.labels.prefix,
1804
+ v: I.absoluteValues[s] ?? 0,
1805
+ s: I.suffix || t.value.chart.labels.suffix,
1806
+ r: t.value.table.rounding
1807
+ })
1808
+ )
1809
+ )).concat(l ? (o ?? 0).toFixed(t.value.table.rounding) : [])
1810
+ );
1811
+ }
1812
+ const u = {
1813
+ th: {
1814
+ backgroundColor: t.value.table.th.backgroundColor,
1815
+ color: t.value.table.th.color,
1816
+ outline: t.value.table.th.outline
1817
+ },
1818
+ td: {
1819
+ backgroundColor: t.value.table.td.backgroundColor,
1820
+ color: t.value.table.td.color,
1821
+ outline: t.value.table.td.outline
1822
+ },
1823
+ breakpoint: t.value.table.responsiveBreakpoint
1824
+ }, a = [t.value.table.columnNames.period].concat(Ye.value.map((s) => s.name)).concat(t.value.table.columnNames.total);
1825
+ return { head: r, body: e, config: u, colNames: a };
1826
+ });
1827
+ function ka(l = null) {
1828
+ const r = [[t.value.chart.title.text], [t.value.chart.title.subtitle.text], [""]], e = ["", ...ya.value.head.map((o) => o.label)], u = ya.value.body, a = r.concat([e]).concat(u), s = Po(a);
1829
+ l ? l(s) : Oo({ csvContent: s, title: t.value.chart.title.text || "vue-ui-xy" });
1830
+ }
1831
+ function wa(l, r = null) {
1832
+ ht.value = l;
1833
+ const e = Ye.value.map((u) => ({
1834
+ name: u.name,
1835
+ value: [null, void 0, NaN].includes(u.absoluteValues[r]) ? null : u.absoluteValues[r],
1836
+ color: u.color,
1837
+ type: u.type
1838
+ }));
1839
+ l ? (S.value = r, t.value.events.datapointEnter && t.value.events.datapointEnter({ datapoint: e, seriesIndex: r + w.value.start })) : (S.value = null, t.value.events.datapointLeave && t.value.events.datapointLeave({ datapoint: e, seriesIndex: r + w.value.start }));
1840
+ }
1841
+ function Sa() {
1842
+ y.value.showTable = !y.value.showTable;
1843
+ }
1844
+ function $a() {
1845
+ y.value.dataLabels.show = !y.value.dataLabels.show;
1846
+ }
1847
+ function _a() {
1848
+ y.value.showTooltip = !y.value.showTooltip;
1849
+ }
1850
+ function La(l) {
1851
+ ke.value = l, Gt.value += 1;
1852
+ }
1853
+ function Ma() {
1854
+ if (!t.value.responsiveProportionalSizing) {
1855
+ _.value.dataLabels = t.value.chart.grid.labels.fontSize, _.value.yAxis = t.value.chart.grid.labels.axis.fontSize, _.value.xAxis = t.value.chart.grid.labels.xAxisLabels.fontSize, _.value.plotLabels = t.value.chart.labels.fontSize, ze.value.plot = t.value.plot.radius, ze.value.line = t.value.line.radius;
1856
+ return;
1857
+ }
1858
+ _.value.dataLabels = el({
1859
+ relator: me.value,
1860
+ adjuster: 400,
1861
+ source: t.value.chart.grid.labels.fontSize,
1862
+ threshold: 10,
1863
+ fallback: 10
1864
+ }), _.value.yAxis = el({
1865
+ relator: oe.value,
1866
+ adjuster: 1e3,
1867
+ source: t.value.chart.grid.labels.axis.fontSize,
1868
+ threshold: 10,
1869
+ fallback: 10
1870
+ }), _.value.xAxis = el({
1871
+ relator: oe.value,
1872
+ adjuster: 1e3,
1873
+ source: t.value.chart.grid.labels.xAxisLabels.fontSize,
1874
+ threshold: 10,
1875
+ fallback: 10
1876
+ }), _.value.plotLabels = el({
1877
+ relator: oe.value,
1878
+ adjuster: 800,
1879
+ source: t.value.chart.labels.fontSize,
1880
+ threshold: 10,
1881
+ fallback: 10
1882
+ }), ze.value.plot = el({
1883
+ relator: oe.value,
1884
+ adjuster: 800,
1885
+ source: t.value.plot.radius,
1886
+ threshold: 1,
1887
+ fallback: 1
1888
+ }), ze.value.line = el({
1889
+ relator: oe.value,
1890
+ adjuster: 800,
1891
+ source: t.value.line.radius,
1892
+ threshold: 1,
1893
+ fallback: 1
1894
+ });
1895
+ }
1896
+ function Yl() {
1897
+ Ha(d.dataset) ? (Gl({
1898
+ componentName: "VueUiXy",
1899
+ type: "dataset",
1900
+ debug: mt.value
1901
+ }), Pt.value = !0) : d.dataset.forEach((r, e) => {
1902
+ [null, void 0].includes(r.name) && (Gl({
1903
+ componentName: "VueUiXy",
1904
+ type: "datasetSerieAttribute",
1905
+ property: "name (string)",
1906
+ index: e,
1907
+ debug: mt.value
1908
+ }), Pt.value = !0);
1909
+ }), mt.value && d.dataset.forEach((r) => {
1910
+ r.series.forEach((e, u) => {
1911
+ Tl(e) || console.warn(`VueUiXy has detected an unsafe value in your dataset:
1912
+ -----> The serie '${r.name}' contains the value '${e}' at index ${u}.
1913
+ '${e}' was converted to null to allow the chart to display.`);
1914
+ });
1915
+ }), Ha(d.dataset) || (Pt.value = t.value.loading), Ut.value = t.value.chart.userOptions.showOnChartHover, rl.value = t.value.chart.userOptions.keepStateOnChartLeave, Zt.value = !t.value.chart.userOptions.showOnChartHover, dl();
1916
+ const l = 12;
1917
+ if (t.value.responsive) {
1918
+ const e = fe.value.parentNode;
1919
+ U.value && (U.value.unobserve(at.value), U.value.disconnect());
1920
+ const { height: u, width: a } = e.getBoundingClientRect();
1921
+ let s = null, o = 0;
1922
+ t.value.chart.title.show && pe.value && (s = pe.value, o = s.getBoundingClientRect().height);
1923
+ let I = null, E = 0;
1924
+ t.value.chart.zoom.show && _e.value > 6 && it.value && Ne.value && Ne.value.$el && (I = Ne.value.$el, E = I.getBoundingClientRect().height);
1925
+ let F = null, M = 0;
1926
+ t.value.chart.legend.show && lt.value && (F = lt.value, M = F.getBoundingClientRect().height);
1927
+ let H = 0;
1928
+ zt.value && (H = zt.value.getBoundingClientRect().height);
1929
+ let Z = 0;
1930
+ Tt.value && (Z = Tt.value.getBoundingClientRect().height), me.value = u - o - M - E - H - Z - l, oe.value = a, ot.value = `0 0 ${oe.value < 0 ? 10 : oe.value} ${me.value < 0 ? 10 : me.value}`, Ma();
1931
+ const k = new ResizeObserver((N) => {
1932
+ for (const A of N)
1933
+ t.value.chart.title.show && pe.value ? o = pe.value.getBoundingClientRect().height : o = 0, Ne.value && Ne.value.$el ? E = Ne.value.$el.getBoundingClientRect().height : E = 0, lt.value ? M = lt.value.getBoundingClientRect().height : M = 0, zt.value ? H = zt.value.getBoundingClientRect().height : H = 0, Tt.value ? Z = Tt.value.getBoundingClientRect().height : Z = 0, requestAnimationFrame(() => {
1934
+ me.value = A.contentRect.height - o - M - E - H - Z - l, oe.value = A.contentBoxSize[0].inlineSize, ot.value = `0 0 ${oe.value < 0 ? 10 : oe.value} ${me.value < 0 ? 10 : me.value}`, Ma();
1935
+ });
1936
+ });
1937
+ U.value = k, at.value = e, k.observe(e);
1938
+ } else
1939
+ me.value = t.value.chart.height, oe.value = t.value.chart.width, _.value.dataLabels = t.value.chart.grid.labels.fontSize, _.value.yAxis = t.value.chart.grid.labels.axis.fontSize, _.value.xAxis = t.value.chart.grid.labels.xAxisLabels.fontSize, _.value.plotLabels = t.value.chart.labels.fontSize, ze.value.plot = t.value.plot.radius, ze.value.line = t.value.line.radius, ot.value = `0 0 ${oe.value} ${me.value}`;
1940
+ }
1941
+ bl(() => {
1942
+ Yl(), Sl(), document.addEventListener("mousemove", (l) => {
1943
+ Nt.value = {
1944
+ x: l.clientX,
1945
+ y: l.clientY
1946
+ };
1947
+ }), document.addEventListener("scroll", Ql);
1948
+ }), pl(() => {
1949
+ document.removeEventListener("scroll", Ql), U.value && (U.value.unobserve(at.value), U.value.disconnect());
1950
+ }), Fo({
1951
+ timeLabelsEls: dt,
1952
+ timeLabels: he,
1953
+ slicer: w,
1954
+ configRef: t,
1955
+ rotationPath: ["chart", "grid", "labels", "xAxisLabels", "rotation"],
1956
+ autoRotatePath: ["chart", "grid", "labels", "xAxisLabels", "autoRotate", "enable"],
1957
+ isAutoSize: qt,
1958
+ height: me,
1959
+ width: oe,
1960
+ rotation: t.value.chart.grid.labels.xAxisLabels.autoRotate.angle
1961
+ });
1962
+ const Al = p(!1), so = b(() => {
1963
+ if ([null, void 0].includes(S.value) && [null, void 0].includes(O.value)) return "";
1964
+ const l = (S.value != null ? S.value : 0) || (O.value != null ? O.value : 0), r = t.value.chart.timeTag.customFormat;
1965
+ if (Al.value = !1, Pa(r))
1966
+ try {
1967
+ const e = r({
1968
+ absoluteIndex: l + w.value.start,
1969
+ seriesIndex: l,
1970
+ datapoint: Qt.value,
1971
+ bars: xt.value,
1972
+ lines: Te.value,
1973
+ plots: Je.value,
1974
+ config: t.value
1975
+ });
1976
+ if (typeof e == "string")
1977
+ return Al.value = !0, e;
1978
+ } catch {
1979
+ console.warn("Custom format cannot be applied on timeTag."), Al.value = !1;
1980
+ }
1981
+ if (!Al.value)
1982
+ return [null, void 0].includes(he.value[l]) ? "" : he.value[l].text;
1983
+ });
1984
+ vt(() => d.dataset, (l) => {
1985
+ Array.isArray(l) && l.length > 0 && (Pt.value = !1), _e.value = Math.max(...ie.value.map((r) => Qe({
1986
+ data: r.series,
1987
+ threshold: t.value.downsample.threshold
1988
+ }).length)), w.value = {
1989
+ start: 0,
1990
+ end: _e.value
1991
+ }, Xt.value += 1, Rt.value += 1, te();
1992
+ }, { deep: !0 }), vt(() => d.config, (l) => {
1993
+ ue.value || (t.value = ut()), Yl(), sl.value += 1, il.value += 1, dl(), te();
1994
+ }, { deep: !0 });
1995
+ const Xl = p(!1);
1996
+ function Ca() {
1997
+ const l = fe.value?.parentNode;
1998
+ if (!l) {
1999
+ Xl.value = !1;
2000
+ return;
2001
+ }
2002
+ const r = l.getBoundingClientRect();
2003
+ Xl.value = r.width > 2 && r.height > 2;
2004
+ }
2005
+ return bl(() => {
2006
+ Ca();
2007
+ const l = new ResizeObserver(() => {
2008
+ Ca(), Xl.value && (Yl(), te(), Sl());
2009
+ });
2010
+ fe.value?.parentNode && l.observe(fe.value.parentNode);
2011
+ }), vt(t, () => {
2012
+ dl();
2013
+ }, { immediate: !0 }), Hl({
2014
+ getData: Qa,
2015
+ getImage: ja,
2016
+ generatePdf: q,
2017
+ generateImage: Le,
2018
+ generateCsv: ka,
2019
+ toggleStack: oa,
2020
+ toggleTable: Sa,
2021
+ toggleLabels: $a,
2022
+ toggleTooltip: _a,
2023
+ toggleAnnotator: Fl,
2024
+ toggleFullscreen: La
2025
+ }), (l, r) => (n(), i("div", {
2026
+ id: `vue-ui-xy_${G.value}`,
2027
+ class: Be(`vue-ui-xy ${ke.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${t.value.useCssAnimation ? "" : "vue-ui-dna"}`),
2028
+ ref_key: "chart",
2029
+ ref: fe,
2030
+ style: L(`background:${t.value.chart.backgroundColor}; color:${t.value.chart.color};width:100%;font-family:${t.value.chart.fontFamily};${t.value.responsive ? "height: 100%" : ""}`),
2031
+ onMouseenter: r[10] || (r[10] = () => ea(!0)),
2032
+ onMouseleave: r[11] || (r[11] = () => ea(!1))
2033
+ }, [
2034
+ t.value.chart.userOptions.buttons.annotator && $e.value ? (n(), Ge(v(pt), {
2035
+ key: 0,
2036
+ svgRef: $e.value,
2037
+ backgroundColor: t.value.chart.backgroundColor,
2038
+ color: t.value.chart.color,
2039
+ active: ye.value,
2040
+ onClose: Fl
2041
+ }, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : f("", !0),
2042
+ to.value ? (n(), i("div", {
2043
+ key: 1,
2044
+ ref_key: "noTitle",
2045
+ ref: Tt,
2046
+ class: "vue-data-ui-no-title-space",
2047
+ style: "height:36px; width: 100%; background:transparent"
2048
+ }, null, 512)) : f("", !0),
2049
+ t.value.chart.title.show ? (n(), i("div", {
2050
+ key: 2,
2051
+ ref_key: "chartTitle",
2052
+ ref: pe,
2053
+ class: "vue-ui-xy-title",
2054
+ style: L(`font-family:${t.value.chart.fontFamily}`)
2055
+ }, [
2056
+ (n(), Ge(Do, {
2057
+ key: `title_${sl.value}`,
2058
+ config: {
2059
+ title: {
2060
+ cy: "xy-div-title",
2061
+ ...t.value.chart.title
2062
+ },
2063
+ subtitle: {
2064
+ cy: "xy-div-subtitle",
2065
+ ...t.value.chart.title.subtitle
2066
+ }
2067
+ }
2068
+ }, null, 8, ["config"]))
2069
+ ], 4)) : f("", !0),
2070
+ x("div", {
2071
+ id: `legend-top-${G.value}`
2072
+ }, null, 8, mn),
2073
+ t.value.chart.userOptions.show && (rl.value || Zt.value) ? (n(), Ge(v(be), {
2074
+ ref: "defails",
2075
+ key: `user_options_${Gt.value}`,
2076
+ backgroundColor: t.value.chart.backgroundColor,
2077
+ color: t.value.chart.color,
2078
+ isPrinting: v(h),
2079
+ isImaging: v($),
2080
+ uid: G.value,
2081
+ hasTooltip: t.value.chart.userOptions.buttons.tooltip && t.value.chart.tooltip.show,
2082
+ hasPdf: t.value.chart.userOptions.buttons.pdf,
2083
+ hasXls: t.value.chart.userOptions.buttons.csv,
2084
+ hasImg: t.value.chart.userOptions.buttons.img,
2085
+ hasLabel: t.value.chart.userOptions.buttons.labels,
2086
+ hasTable: t.value.chart.userOptions.buttons.table,
2087
+ hasStack: R.dataset.length > 1 && t.value.chart.userOptions.buttons.stack,
2088
+ hasFullscreen: t.value.chart.userOptions.buttons.fullscreen,
2089
+ isStacked: y.value.isStacked,
2090
+ isFullscreen: ke.value,
2091
+ chartElement: l.$refs.chart,
2092
+ position: t.value.chart.userOptions.position,
2093
+ isTooltip: y.value.showTooltip,
2094
+ titles: { ...t.value.chart.userOptions.buttonTitles },
2095
+ hasAnnotator: t.value.chart.userOptions.buttons.annotator,
2096
+ isAnnotation: ye.value,
2097
+ callbacks: t.value.chart.userOptions.callbacks,
2098
+ printScale: t.value.chart.userOptions.print.scale,
2099
+ onToggleFullscreen: La,
2100
+ onGeneratePdf: v(q),
2101
+ onGenerateCsv: ka,
2102
+ onGenerateImage: v(Le),
2103
+ onToggleTable: Sa,
2104
+ onToggleLabels: $a,
2105
+ onToggleStack: oa,
2106
+ onToggleTooltip: _a,
2107
+ onToggleAnnotator: Fl,
2108
+ style: L({
2109
+ visibility: rl.value ? Zt.value ? "visible" : "hidden" : "visible"
2110
+ })
2111
+ }, xo({ _: 2 }, [
2112
+ l.$slots.menuIcon ? {
2113
+ name: "menuIcon",
2114
+ fn: ge(({ isOpen: e, color: u }) => [
2115
+ J(l.$slots, "menuIcon", bt(Mt({ isOpen: e, color: u })), void 0, !0)
2116
+ ]),
2117
+ key: "0"
2118
+ } : void 0,
2119
+ l.$slots.optionTooltip ? {
2120
+ name: "optionTooltip",
2121
+ fn: ge(() => [
2122
+ J(l.$slots, "optionTooltip", {}, void 0, !0)
2123
+ ]),
2124
+ key: "1"
2125
+ } : void 0,
2126
+ l.$slots.optionPdf ? {
2127
+ name: "optionPdf",
2128
+ fn: ge(() => [
2129
+ J(l.$slots, "optionPdf", {}, void 0, !0)
2130
+ ]),
2131
+ key: "2"
2132
+ } : void 0,
2133
+ l.$slots.optionCsv ? {
2134
+ name: "optionCsv",
2135
+ fn: ge(() => [
2136
+ J(l.$slots, "optionCsv", {}, void 0, !0)
2137
+ ]),
2138
+ key: "3"
2139
+ } : void 0,
2140
+ l.$slots.optionImg ? {
2141
+ name: "optionImg",
2142
+ fn: ge(() => [
2143
+ J(l.$slots, "optionImg", {}, void 0, !0)
2144
+ ]),
2145
+ key: "4"
2146
+ } : void 0,
2147
+ l.$slots.optionTable ? {
2148
+ name: "optionTable",
2149
+ fn: ge(() => [
2150
+ J(l.$slots, "optionTable", {}, void 0, !0)
2151
+ ]),
2152
+ key: "5"
2153
+ } : void 0,
2154
+ l.$slots.optionLabels ? {
2155
+ name: "optionLabels",
2156
+ fn: ge(() => [
2157
+ J(l.$slots, "optionLabels", {}, void 0, !0)
2158
+ ]),
2159
+ key: "6"
2160
+ } : void 0,
2161
+ l.$slots.optionStack ? {
2162
+ name: "optionStack",
2163
+ fn: ge(() => [
2164
+ J(l.$slots, "optionStack", {}, void 0, !0)
2165
+ ]),
2166
+ key: "7"
2167
+ } : void 0,
2168
+ l.$slots.optionFullscreen ? {
2169
+ name: "optionFullscreen",
2170
+ fn: ge(({ toggleFullscreen: e, isFullscreen: u }) => [
2171
+ J(l.$slots, "optionFullscreen", bt(Mt({ toggleFullscreen: e, isFullscreen: u })), void 0, !0)
2172
+ ]),
2173
+ key: "8"
2174
+ } : void 0,
2175
+ l.$slots.optionAnnotator ? {
2176
+ name: "optionAnnotator",
2177
+ fn: ge(({ toggleAnnotator: e, isAnnotator: u }) => [
2178
+ J(l.$slots, "optionAnnotator", bt(Mt({ toggleAnnotator: e, isAnnotator: u })), void 0, !0)
2179
+ ]),
2180
+ key: "9"
2181
+ } : void 0
2182
+ ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasLabel", "hasTable", "hasStack", "hasFullscreen", "isStacked", "isFullscreen", "chartElement", "position", "isTooltip", "titles", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : f("", !0),
2183
+ (n(), i("svg", {
2184
+ ref_key: "svgRef",
2185
+ ref: $e,
2186
+ xmlns: "http://www.w3.org/2000/svg",
2187
+ class: Be([{ "vue-data-ui-fullscreen--on": ke.value, "vue-data-ui-fulscreen--off": !ke.value }, "vue-ui-xy-svg vue-data-ui-svg"]),
2188
+ width: "100%",
2189
+ viewBox: ot.value,
2190
+ style: L({
2191
+ background: "transparent",
2192
+ color: t.value.chart.color,
2193
+ fontFamily: t.value.chart.fontFamily
2194
+ }),
2195
+ "aria-label": eo.value,
2196
+ role: "img",
2197
+ "aria-live": "polite",
2198
+ preserveAspectRatio: "xMidYMid",
2199
+ onMousemove: qa,
2200
+ onMouseleave: va,
2201
+ onClick: Ka
2202
+ }, [
2203
+ x("g", {
2204
+ ref_key: "G",
2205
+ ref: Bl,
2206
+ class: "vue-data-ui-g"
2207
+ }, [
2208
+ tl(v(Dt)),
2209
+ l.$slots["chart-background"] ? (n(), i("foreignObject", {
2210
+ key: 0,
2211
+ x: c.value.left + Q.value < 0 ? 0 : c.value.left + Q.value,
2212
+ y: c.value.top,
2213
+ width: c.value.width - (t.value.chart.grid.position === "middle" ? 0 : c.value.width / T.value) < 0 ? 0 : c.value.width - (t.value.chart.grid.position === "middle" ? 0 : c.value.width / T.value),
2214
+ height: c.value.height < 0 ? 0 : c.value.height,
2215
+ style: {
2216
+ pointerEvents: "none"
2217
+ }
2218
+ }, [
2219
+ J(l.$slots, "chart-background", {}, void 0, !0)
2220
+ ], 8, xn)) : f("", !0),
2221
+ T.value > 0 ? (n(), i("g", bn, [
2222
+ x("g", pn, [
2223
+ t.value.chart.grid.labels.xAxis.showBaseline ? (n(), i("line", {
2224
+ key: 0,
2225
+ stroke: t.value.chart.grid.stroke,
2226
+ "stroke-width": "1",
2227
+ x1: c.value.left + Q.value,
2228
+ x2: c.value.right - Q.value,
2229
+ y1: v(X)(c.value.bottom),
2230
+ y2: v(X)(c.value.bottom),
2231
+ "stroke-linecap": "round",
2232
+ style: { animation: "none !important" }
2233
+ }, null, 8, yn)) : f("", !0),
2234
+ y.value.useIndividualScale ? t.value.chart.grid.showHorizontalLines ? (n(!0), i(g, { key: 2 }, C(fl.value, (e) => (n(), i("g", null, [
2235
+ e.id === P.value && e.yLabels.length ? (n(!0), i(g, { key: 0 }, C(e.yLabels, (u) => (n(), i("line", {
2236
+ x1: c.value.left + Q.value,
2237
+ x2: c.value.right - Q.value,
2238
+ y1: v(X)(u.y),
2239
+ y2: v(X)(u.y),
2240
+ stroke: e.color,
2241
+ "stroke-width": 0.5,
2242
+ "stroke-linecap": "round",
2243
+ style: { animation: "none !important" }
2244
+ }, null, 8, $n))), 256)) : e.yLabels.length ? (n(!0), i(g, { key: 1 }, C(e.yLabels, (u) => (n(), i("line", {
2245
+ x1: c.value.left + Q.value,
2246
+ x2: c.value.right - Q.value,
2247
+ y1: v(X)(u.y),
2248
+ y2: v(X)(u.y),
2249
+ stroke: t.value.chart.grid.stroke,
2250
+ "stroke-width": 0.5,
2251
+ "stroke-linecap": "round",
2252
+ style: { animation: "none !important" }
2253
+ }, null, 8, _n))), 256)) : f("", !0)
2254
+ ]))), 256)) : f("", !0) : (n(), i(g, { key: 1 }, [
2255
+ t.value.chart.grid.labels.yAxis.showBaseline ? (n(), i("line", {
2256
+ key: 0,
2257
+ stroke: t.value.chart.grid.stroke,
2258
+ "stroke-width": "1",
2259
+ x1: c.value.left + Q.value,
2260
+ x2: c.value.left + Q.value,
2261
+ y1: v(X)(c.value.top),
2262
+ y2: v(X)(c.value.bottom),
2263
+ "stroke-linecap": "round",
2264
+ style: { animation: "none !important" }
2265
+ }, null, 8, kn)) : f("", !0),
2266
+ t.value.chart.grid.showHorizontalLines ? (n(), i("g", wn, [
2267
+ (n(!0), i(g, null, C(ma.value, (e) => (n(), i("line", {
2268
+ x1: c.value.left + Q.value,
2269
+ x2: c.value.right,
2270
+ y1: v(X)(e.y),
2271
+ y2: v(X)(e.y),
2272
+ stroke: t.value.chart.grid.stroke,
2273
+ "stroke-width": 0.5,
2274
+ "stroke-linecap": "round",
2275
+ style: { animation: "none !important" }
2276
+ }, null, 8, Sn))), 256))
2277
+ ])) : f("", !0)
2278
+ ], 64)),
2279
+ t.value.chart.grid.showVerticalLines ? (n(), i("g", Ln, [
2280
+ x("path", {
2281
+ d: Da.value,
2282
+ "stroke-width": 0.5,
2283
+ stroke: t.value.chart.grid.stroke,
2284
+ "stroke-linecap": "round",
2285
+ style: { animation: "none !important" }
2286
+ }, null, 8, Mn)
2287
+ ])) : f("", !0),
2288
+ t.value.chart.grid.labels.xAxisLabels.show ? (n(), i("g", Cn, [
2289
+ x("path", {
2290
+ d: Ya.value,
2291
+ stroke: t.value.chart.grid.stroke,
2292
+ "stroke-width": 1,
2293
+ "stroke-linecap": "round",
2294
+ style: { animation: "none !important" }
2295
+ }, null, 8, An)
2296
+ ])) : f("", !0)
2297
+ ]),
2298
+ (n(!0), i(g, null, C(xt.value, (e, u) => (n(), i("defs", {
2299
+ key: `def_rect_${u}`
2300
+ }, [
2301
+ x("linearGradient", {
2302
+ id: `rectGradient_pos_${u}_${G.value}`,
2303
+ x2: "0%",
2304
+ y2: "100%"
2305
+ }, [
2306
+ x("stop", {
2307
+ offset: "0%",
2308
+ "stop-color": e.color
2309
+ }, null, 8, Tn),
2310
+ x("stop", {
2311
+ offset: "62%",
2312
+ "stop-color": `${v(Ft)(e.color, 0.02)}`
2313
+ }, null, 8, In),
2314
+ x("stop", {
2315
+ offset: "100%",
2316
+ "stop-color": `${v(Ft)(e.color, 0.05)}`
2317
+ }, null, 8, Nn)
2318
+ ], 8, zn),
2319
+ x("linearGradient", {
2320
+ id: `rectGradient_neg_${u}_${G.value}`,
2321
+ x2: "0%",
2322
+ y2: "100%"
2323
+ }, [
2324
+ x("stop", {
2325
+ offset: "0%",
2326
+ "stop-color": `${v(Ft)(e.color, 0.05)}`
2327
+ }, null, 8, Pn),
2328
+ x("stop", {
2329
+ offset: "38%",
2330
+ "stop-color": `${v(Ft)(e.color, 0.02)}`
2331
+ }, null, 8, On),
2332
+ x("stop", {
2333
+ offset: "100%",
2334
+ "stop-color": e.color
2335
+ }, null, 8, Hn)
2336
+ ], 8, Rn)
2337
+ ]))), 128)),
2338
+ (n(!0), i(g, null, C(Je.value, (e, u) => (n(), i("defs", {
2339
+ key: `def_plot_${u}`
2340
+ }, [
2341
+ x("radialGradient", {
2342
+ id: `plotGradient_${u}_${G.value}`,
2343
+ cx: "50%",
2344
+ cy: "50%",
2345
+ r: "50%",
2346
+ fx: "50%",
2347
+ fy: "50%"
2348
+ }, [
2349
+ x("stop", {
2350
+ offset: "0%",
2351
+ "stop-color": `${v(Ft)(e.color, 0.05)}`
2352
+ }, null, 8, Bn),
2353
+ x("stop", {
2354
+ offset: "100%",
2355
+ "stop-color": e.color
2356
+ }, null, 8, En)
2357
+ ], 8, Vn)
2358
+ ]))), 128)),
2359
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i("defs", {
2360
+ key: `def_line_${u}`
2361
+ }, [
2362
+ x("radialGradient", {
2363
+ id: `lineGradient_${u}_${G.value}`,
2364
+ cx: "50%",
2365
+ cy: "50%",
2366
+ r: "50%",
2367
+ fx: "50%",
2368
+ fy: "50%"
2369
+ }, [
2370
+ x("stop", {
2371
+ offset: "0%",
2372
+ "stop-color": `${v(Ft)(e.color, 0.05)}`
2373
+ }, null, 8, Wn),
2374
+ x("stop", {
2375
+ offset: "100%",
2376
+ "stop-color": e.color
2377
+ }, null, 8, Dn)
2378
+ ], 8, Fn),
2379
+ x("linearGradient", {
2380
+ id: `areaGradient_${u}_${G.value}`,
2381
+ x1: "0%",
2382
+ x2: "100%",
2383
+ y1: "0%",
2384
+ y2: "0%"
2385
+ }, [
2386
+ x("stop", {
2387
+ offset: "0%",
2388
+ "stop-color": `${v(je)(v(Ft)(e.color, 0.03), t.value.line.area.opacity)}`
2389
+ }, null, 8, Xn),
2390
+ x("stop", {
2391
+ offset: "100%",
2392
+ "stop-color": `${v(je)(e.color, t.value.line.area.opacity)}`
2393
+ }, null, 8, Gn)
2394
+ ], 8, Yn)
2395
+ ]))), 128)),
2396
+ (n(!0), i(g, null, C(lo.value, (e) => (n(), i("g", null, [
2397
+ e.show ? (n(), i(g, { key: 0 }, [
2398
+ (n(!0), i(g, null, C(e.span, (u, a) => (n(), i("g", null, [
2399
+ x("rect", {
2400
+ style: L({
2401
+ transition: "none",
2402
+ opacity: e.from + a >= w.value.start && e.from + a <= w.value.end - 1 ? 1 : 0
2403
+ }),
2404
+ x: c.value.left + c.value.width / T.value * (e.from + a - w.value.start),
2405
+ y: c.value.top,
2406
+ height: c.value.height < 0 ? 10 : c.value.height,
2407
+ width: c.value.width / T.value < 0 ? 1e-5 : c.value.width / T.value,
2408
+ fill: v(je)(e.color, e.opacity)
2409
+ }, null, 12, Un)
2410
+ ]))), 256)),
2411
+ (n(!0), i(g, null, C(e.span, (u, a) => (n(), i("g", null, [
2412
+ e.caption.text && a === 0 ? (n(), i("foreignObject", {
2413
+ key: 0,
2414
+ x: c.value.left + c.value.width / T.value * (e.from + a - w.value.start) - (e.caption.width === "auto" ? 0 : e.caption.width / 2 - c.value.width / T.value * e.span / 2),
2415
+ y: c.value.top + e.caption.offsetY,
2416
+ style: L({
2417
+ overflow: "visible",
2418
+ opacity: e.to >= w.value.start && e.from < w.value.end ? 1 : 0
2419
+ }),
2420
+ height: "1",
2421
+ width: e.caption.width === "auto" ? c.value.width / T.value * e.span : e.caption.width
2422
+ }, [
2423
+ x("div", {
2424
+ style: L(`padding:${e.caption.padding}px;text-align:${e.caption.textAlign};font-size:${e.caption.fontSize}px;color:${e.caption.color};font-weight:${e.caption.bold ? "bold" : "normal"}`)
2425
+ }, ae(e.caption.text), 5)
2426
+ ], 12, Zn)) : f("", !0)
2427
+ ]))), 256))
2428
+ ], 64)) : f("", !0)
2429
+ ]))), 256)),
2430
+ jl.value ? (n(), i("g", qn, [
2431
+ (n(!0), i(g, null, C(T.value, (e, u) => (n(), i("g", {
2432
+ key: `tooltip_trap_highlighter_${u}`
2433
+ }, [
2434
+ x("rect", {
2435
+ x: c.value.left + c.value.width / T.value * u,
2436
+ y: c.value.top,
2437
+ height: c.value.height < 0 ? 10 : c.value.height,
2438
+ width: c.value.width / T.value < 0 ? 1e-5 : c.value.width / T.value,
2439
+ fill: [O.value, S.value, ft.value].includes(u) ? v(je)(t.value.chart.highlighter.color, t.value.chart.highlighter.opacity) : "transparent",
2440
+ style: { transition: "none !important", animation: "none !important" }
2441
+ }, null, 8, Kn)
2442
+ ]))), 128))
2443
+ ])) : f("", !0),
2444
+ xt.value.length ? (n(!0), i(g, { key: 1 }, C(xt.value, (e, u) => (n(), i("g", {
2445
+ key: `serie_bar_${u}`,
2446
+ class: Be(`serie_bar_${u}`),
2447
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2448
+ }, [
2449
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i("g", {
2450
+ key: `bar_plot_${u}_${s}`
2451
+ }, [
2452
+ Oe(a.value) ? (n(), i("rect", {
2453
+ key: 0,
2454
+ x: $l(a) + Ml.value / 2,
2455
+ y: y.value.useIndividualScale ? ca(a) : ra(a),
2456
+ height: y.value.useIndividualScale ? Math.abs(sa(a)) : Math.abs(ia(a)),
2457
+ width: Ll.value - Ml.value,
2458
+ rx: t.value.bar.borderRadius,
2459
+ fill: t.value.bar.useGradient ? a.value >= 0 ? `url(#rectGradient_pos_${u}_${G.value})` : `url(#rectGradient_neg_${u}_${G.value})` : e.color,
2460
+ stroke: t.value.bar.border.useSerieColor ? e.color : t.value.bar.border.stroke,
2461
+ "stroke-width": t.value.bar.border.strokeWidth,
2462
+ style: L({ transition: v(ue) || !t.value.bar.showTransition ? void 0 : `all ${t.value.bar.transitionDurationMs}ms ease-in-out` })
2463
+ }, null, 12, Jn)) : f("", !0),
2464
+ Oe(a.value) && l.$slots.pattern ? (n(), i("rect", {
2465
+ key: 1,
2466
+ x: $l(a) - Ml.value / 2,
2467
+ y: y.value.useIndividualScale ? ca(a) : ra(a),
2468
+ height: y.value.useIndividualScale ? Math.abs(sa(a)) : Math.abs(ia(a)),
2469
+ width: Ll.value - Ml.value,
2470
+ rx: t.value.bar.borderRadius,
2471
+ fill: `url(#pattern_${G.value}_${e.slotAbsoluteIndex})`,
2472
+ stroke: t.value.bar.border.useSerieColor ? e.color : t.value.bar.border.stroke,
2473
+ "stroke-width": t.value.bar.border.strokeWidth,
2474
+ style: L({ transition: v(ue) || !t.value.bar.showTransition ? void 0 : `all ${t.value.bar.transitionDurationMs}ms ease-in-out` })
2475
+ }, null, 12, Qn)) : f("", !0),
2476
+ a.comment && t.value.chart.comments.show ? (n(), i("foreignObject", {
2477
+ key: 2,
2478
+ style: { overflow: "visible" },
2479
+ height: "12",
2480
+ width: Ll.value / 2 + t.value.chart.comments.width,
2481
+ x: $l(a) - t.value.chart.comments.width / 2 + t.value.chart.comments.offsetX,
2482
+ y: v(B)(a.y) + t.value.chart.comments.offsetY + 6
2483
+ }, [
2484
+ J(l.$slots, "plot-comment", {
2485
+ plot: { ...a, color: e.color, seriesIndex: u, datapointIndex: s }
2486
+ }, void 0, !0)
2487
+ ], 8, jn)) : f("", !0)
2488
+ ]))), 128)),
2489
+ Object.hasOwn(e, "useProgression") && e.useProgression === !0 && !isNaN(v(j)(e.plots).trend) ? (n(), i("g", eu, [
2490
+ x("defs", null, [
2491
+ x("marker", {
2492
+ id: `bar_arrow_${u}`,
2493
+ markerWidth: 7,
2494
+ markerHeight: 7,
2495
+ refX: "0",
2496
+ refY: 7 / 2,
2497
+ orient: "auto"
2498
+ }, [
2499
+ x("polygon", {
2500
+ points: `0 0, 7 ${7 / 2}, 0 7`,
2501
+ fill: e.color
2502
+ }, null, 8, lu)
2503
+ ], 8, tu)
2504
+ ]),
2505
+ e.plots.length > 1 ? (n(), i("line", {
2506
+ key: 0,
2507
+ x1: v(j)(e.plots).x1 + Jt(),
2508
+ x2: v(j)(e.plots).x2 + Jt(),
2509
+ y1: v(X)(v(j)(e.plots).y1),
2510
+ y2: v(X)(v(j)(e.plots).y2),
2511
+ "stroke-width": 1,
2512
+ stroke: e.color,
2513
+ "stroke-dasharray": 2,
2514
+ "marker-end": `url(#bar_arrow_${u})`
2515
+ }, null, 8, au)) : f("", !0),
2516
+ e.plots.length > 1 ? (n(), i("text", {
2517
+ key: 1,
2518
+ "text-anchor": "middle",
2519
+ x: v(j)(e.plots).x2 + Jt(),
2520
+ y: v(j)(e.plots).y2 - 6,
2521
+ "font-size": _.value.plotLabels,
2522
+ fill: e.color
2523
+ }, ae(v(Ue)({
2524
+ v: v(j)(e.plots).trend * 100,
2525
+ s: "%",
2526
+ r: 2
2527
+ })), 9, ou)) : f("", !0)
2528
+ ])) : f("", !0)
2529
+ ], 6))), 128)) : f("", !0),
2530
+ !y.value.useIndividualScale && t.value.chart.grid.labels.zeroLine.show ? (n(), i("line", {
2531
+ key: 2,
2532
+ stroke: t.value.chart.grid.stroke,
2533
+ "stroke-width": "1",
2534
+ x1: c.value.left + Q.value,
2535
+ x2: c.value.right,
2536
+ y1: v(X)(Me.value),
2537
+ y2: v(X)(Me.value),
2538
+ "stroke-linecap": "round",
2539
+ style: { animation: "none !important" }
2540
+ }, null, 8, nu)) : f("", !0),
2541
+ t.value.chart.highlighter.useLine && (![null, void 0].includes(S.value) || ![null, void 0].includes(O.value)) ? (n(), i("g", uu, [
2542
+ x("line", {
2543
+ x1: c.value.left + c.value.width / T.value * ((S.value !== null ? S.value : 0) || (O.value !== null ? O.value : 0)) + c.value.width / T.value / 2,
2544
+ x2: c.value.left + c.value.width / T.value * ((S.value !== null ? S.value : 0) || (O.value !== null ? O.value : 0)) + c.value.width / T.value / 2,
2545
+ y1: v(X)(c.value.top),
2546
+ y2: v(X)(c.value.bottom),
2547
+ stroke: t.value.chart.highlighter.color,
2548
+ "stroke-width": t.value.chart.highlighter.lineWidth,
2549
+ "stroke-dasharray": t.value.chart.highlighter.lineDasharray,
2550
+ "stroke-linecap": "round",
2551
+ style: { transition: "none !important", animation: "none !important", "pointer-events": "none" }
2552
+ }, null, 8, iu)
2553
+ ])) : f("", !0),
2554
+ t.value.chart.grid.frame.show ? (n(), i("rect", {
2555
+ key: 4,
2556
+ style: { pointerEvents: "none", transition: "none", animation: "none !important" },
2557
+ x: c.value.left + Q.value < 0 ? 0 : c.value.left + Q.value,
2558
+ y: c.value.top,
2559
+ width: c.value.width - (t.value.chart.grid.position === "middle" ? 0 : c.value.width / T.value) < 0 ? 0 : c.value.width - (t.value.chart.grid.position === "middle" ? 0 : c.value.width / T.value),
2560
+ height: c.value.height < 0 ? 0 : c.value.height,
2561
+ fill: "transparent",
2562
+ stroke: t.value.chart.grid.frame.stroke,
2563
+ "stroke-width": t.value.chart.grid.frame.strokeWidth,
2564
+ "stroke-linecap": t.value.chart.grid.frame.strokeLinecap,
2565
+ "stroke-linejoin": t.value.chart.grid.frame.strokeLinejoin,
2566
+ "stroke-dasharray": t.value.chart.grid.frame.strokeDasharray
2567
+ }, null, 8, su)) : f("", !0),
2568
+ t.value.chart.grid.labels.show ? (n(), i("g", {
2569
+ key: 5,
2570
+ ref_key: "scaleLabels",
2571
+ ref: It
2572
+ }, [
2573
+ y.value.useIndividualScale ? (n(), i(g, { key: 0 }, [
2574
+ (n(!0), i(g, null, C(fl.value, (e) => (n(), i("g", null, [
2575
+ x("line", {
2576
+ x1: e.x + Q.value - c.value.individualOffsetX,
2577
+ x2: e.x + Q.value - c.value.individualOffsetX,
2578
+ y1: y.value.isStacked ? v(X)(c.value.bottom - e.yOffset - e.individualHeight) : v(X)(c.value.top),
2579
+ y2: y.value.isStacked ? v(X)(c.value.bottom - e.yOffset) : v(X)(c.value.bottom),
2580
+ stroke: e.color,
2581
+ "stroke-width": t.value.chart.grid.stroke,
2582
+ "stroke-linecap": "round",
2583
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.3 : 1};transition:opacity 0.2s ease-in-out; animation: none !important`)
2584
+ }, null, 12, ru)
2585
+ ]))), 256)),
2586
+ (n(!0), i(g, null, C(fl.value, (e) => (n(), i("g", {
2587
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.3 : 1};transition:opacity 0.2s ease-in-out`)
2588
+ }, [
2589
+ x("text", {
2590
+ fill: e.color,
2591
+ "font-size": _.value.dataLabels * 0.8,
2592
+ "text-anchor": "middle",
2593
+ transform: `translate(${e.x - _.value.dataLabels * 0.8 / 2 + Q.value}, ${y.value.isStacked ? c.value.bottom - e.yOffset - e.individualHeight / 2 : c.value.top + c.value.height / 2}) rotate(-90)`
2594
+ }, ae(e.name) + " " + ae(e.scaleLabel && e.unique && e.scaleLabel !== e.id ? `-
2595
+ ${e.scaleLabel}` : ""), 9, cu),
2596
+ (n(!0), i(g, null, C(e.yLabels, (u, a) => (n(), i(g, null, [
2597
+ t.value.chart.grid.labels.yAxis.showCrosshairs ? (n(), i("line", {
2598
+ key: 0,
2599
+ x1: e.x + 3 + Q.value - t.value.chart.grid.labels.yAxis.crosshairSize - c.value.individualOffsetX,
2600
+ x2: e.x + Q.value - c.value.individualOffsetX,
2601
+ y1: v(X)(u.y),
2602
+ y2: v(X)(u.y),
2603
+ stroke: e.color,
2604
+ "stroke-width": 1,
2605
+ "stroke-linecap": "round",
2606
+ style: { animation: "none !important" }
2607
+ }, null, 8, vu)) : f("", !0)
2608
+ ], 64))), 256)),
2609
+ (n(!0), i(g, null, C(e.yLabels, (u, a) => (n(), i("text", {
2610
+ x: e.x - 5 + Q.value - c.value.individualOffsetX,
2611
+ y: v(X)(u.y) + _.value.dataLabels / 3,
2612
+ "font-size": _.value.dataLabels,
2613
+ "text-anchor": "end",
2614
+ fill: e.color
2615
+ }, ae(v(Se)(
2616
+ t.value.chart.grid.labels.yAxis.formatter,
2617
+ u.value,
2618
+ v(Ue)({
2619
+ p: u.prefix,
2620
+ v: u.value,
2621
+ s: u.suffix,
2622
+ r: t.value.chart.grid.labels.yAxis.rounding
2623
+ }),
2624
+ { datapoint: u.datapoint, seriesIndex: a }
2625
+ )), 9, du))), 256))
2626
+ ], 4))), 256))
2627
+ ], 64)) : (n(!0), i(g, { key: 1 }, C(ma.value, (e, u) => (n(), i("g", {
2628
+ key: `yLabel_${u}`
2629
+ }, [
2630
+ Oe(e) && e.value >= Pe.value.min && e.value <= Pe.value.max && t.value.chart.grid.labels.yAxis.showCrosshairs ? (n(), i("line", {
2631
+ key: 0,
2632
+ x1: c.value.left + Q.value,
2633
+ x2: c.value.left + Q.value - t.value.chart.grid.labels.yAxis.crosshairSize,
2634
+ y1: v(X)(e.y),
2635
+ y2: v(X)(e.y),
2636
+ stroke: t.value.chart.grid.stroke,
2637
+ "stroke-width": "1",
2638
+ "stroke-linecap": "round",
2639
+ style: { animation: "none !important" }
2640
+ }, null, 8, hu)) : f("", !0),
2641
+ e.value >= Pe.value.min && e.value <= Pe.value.max ? (n(), i("text", {
2642
+ key: 1,
2643
+ x: c.value.scaleLabelX - t.value.chart.grid.labels.yAxis.crosshairSize,
2644
+ y: v(B)(e.y + _.value.dataLabels / 3),
2645
+ "font-size": _.value.dataLabels,
2646
+ "text-anchor": "end",
2647
+ fill: t.value.chart.grid.labels.color
2648
+ }, ae(Oe(e.value) ? v(Se)(
2649
+ t.value.chart.grid.labels.yAxis.formatter,
2650
+ e.value,
2651
+ v(Ue)({
2652
+ p: e.prefix,
2653
+ v: e.value,
2654
+ s: e.suffix,
2655
+ r: t.value.chart.grid.labels.yAxis.rounding
2656
+ })
2657
+ ) : ""), 9, fu)) : f("", !0)
2658
+ ]))), 128))
2659
+ ], 512)) : f("", !0),
2660
+ (n(!0), i(g, null, C(Je.value, (e, u) => (n(), i("g", {
2661
+ key: `serie_plot_${u}`,
2662
+ class: Be(`serie_plot_${u}`),
2663
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2664
+ }, [
2665
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i("g", {
2666
+ key: `circle_plot_${u}_${s}`
2667
+ }, [
2668
+ a && Oe(a.value) ? (n(), Ge(Nl, {
2669
+ key: 0,
2670
+ shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(e.shape) ? e.shape : "circle",
2671
+ color: t.value.plot.useGradient ? `url(#plotGradient_${u}_${G.value})` : t.value.plot.dot.useSerieColor ? e.color : t.value.plot.dot.fill,
2672
+ plot: { x: v(B)(a.x), y: v(B)(a.y) },
2673
+ radius: S.value !== null && S.value === s || O.value !== null && O.value === s ? (ze.value.plot || 6) * 1.5 : ze.value.plot || 6,
2674
+ stroke: t.value.plot.dot.useSerieColor ? t.value.chart.backgroundColor : e.color,
2675
+ strokeWidth: t.value.plot.dot.strokeWidth,
2676
+ transition: v(ue) || !t.value.plot.showTransition || S.value !== null && S.value === s || O.value !== null && O.value === s ? void 0 : `all ${t.value.plot.transitionDurationMs}ms ease-in-out`
2677
+ }, null, 8, ["shape", "color", "plot", "radius", "stroke", "strokeWidth", "transition"])) : f("", !0),
2678
+ a.comment && t.value.chart.comments.show ? (n(), i("foreignObject", {
2679
+ key: 1,
2680
+ style: { overflow: "visible" },
2681
+ height: "12",
2682
+ width: t.value.chart.comments.width,
2683
+ x: a.x - t.value.chart.comments.width / 2 + t.value.chart.comments.offsetX,
2684
+ y: a.y + t.value.chart.comments.offsetY + 6
2685
+ }, [
2686
+ x("div", gu, [
2687
+ J(l.$slots, "plot-comment", {
2688
+ plot: { ...a, color: e.color, seriesIndex: u, datapointIndex: s }
2689
+ }, void 0, !0)
2690
+ ])
2691
+ ], 8, mu)) : f("", !0)
2692
+ ]))), 128)),
2693
+ Object.hasOwn(e, "useProgression") && e.useProgression === !0 && !isNaN(v(j)(e.plots).trend) ? (n(), i("g", xu, [
2694
+ x("defs", null, [
2695
+ x("marker", {
2696
+ id: `plot_arrow_${u}`,
2697
+ markerWidth: 7,
2698
+ markerHeight: 7,
2699
+ refX: "0",
2700
+ refY: 7 / 2,
2701
+ orient: "auto"
2702
+ }, [
2703
+ x("polygon", {
2704
+ points: `0 0, 7 ${7 / 2}, 0 7`,
2705
+ fill: e.color
2706
+ }, null, 8, pu)
2707
+ ], 8, bu)
2708
+ ]),
2709
+ e.plots.length > 1 ? (n(), i("line", {
2710
+ key: 0,
2711
+ x1: v(j)(e.plots).x1,
2712
+ x2: v(j)(e.plots).x2,
2713
+ y1: v(X)(v(j)(e.plots).y1),
2714
+ y2: v(X)(v(j)(e.plots).y2),
2715
+ "stroke-width": 1,
2716
+ stroke: e.color,
2717
+ "stroke-dasharray": 2,
2718
+ "marker-end": `url(#plot_arrow_${u})`
2719
+ }, null, 8, yu)) : f("", !0),
2720
+ e.plots.length > 1 ? (n(), i("text", {
2721
+ key: 1,
2722
+ "text-anchor": "middle",
2723
+ x: v(j)(e.plots).x2,
2724
+ y: v(j)(e.plots).y2 - 6,
2725
+ "font-size": _.value.plotLabels,
2726
+ fill: e.color
2727
+ }, ae(v(Ue)({
2728
+ v: v(j)(e.plots).trend * 100,
2729
+ s: "%",
2730
+ r: 2
2731
+ })), 9, ku)) : f("", !0)
2732
+ ])) : f("", !0)
2733
+ ], 6))), 128)),
2734
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i("g", {
2735
+ key: `serie_line_${u}`,
2736
+ class: Be(`serie_line_${u}`),
2737
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2738
+ }, [
2739
+ e.smooth && e.plots.length > 1 && e.curve ? (n(), i("path", {
2740
+ key: 0,
2741
+ d: `M${e.curve}`,
2742
+ stroke: t.value.chart.backgroundColor,
2743
+ "stroke-width": t.value.line.strokeWidth + 1,
2744
+ "stroke-dasharray": e.dashed ? t.value.line.strokeWidth * 2 : 0,
2745
+ fill: "none",
2746
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2747
+ }, null, 12, wu)) : e.plots.length > 1 && e.straight ? (n(), i("path", {
2748
+ key: 1,
2749
+ d: `M${e.straight}`,
2750
+ stroke: t.value.chart.backgroundColor,
2751
+ "stroke-width": t.value.line.strokeWidth + 1,
2752
+ "stroke-dasharray": e.dashed ? t.value.line.strokeWidth * 2 : 0,
2753
+ fill: "none",
2754
+ "stroke-linecap": "round",
2755
+ "stroke-linejoin": "round",
2756
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2757
+ }, null, 12, Su)) : f("", !0)
2758
+ ], 6))), 128)),
2759
+ l.$slots.pattern ? (n(), i("defs", $u, [
2760
+ (n(!0), i(g, null, C(gt.value, (e, u) => J(l.$slots, "pattern", zl({
2761
+ key: `serie_pattern_slot_${u}`
2762
+ }, { ref_for: !0 }, { ...e, seriesIndex: e.slotAbsoluteIndex, patternId: `pattern_${G.value}_${u}` }), void 0, !0)), 128))
2763
+ ])) : f("", !0),
2764
+ ba.value.length && !y.value.isStacked ? (n(), i("g", _u, [
2765
+ (n(!0), i(g, null, C(ba.value, (e) => (n(), i("path", {
2766
+ key: e.key,
2767
+ d: e.d,
2768
+ fill: e.color,
2769
+ "fill-opacity": t.value.line.interLine.fillOpacity,
2770
+ stroke: "none",
2771
+ "pointer-events": "none",
2772
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2773
+ }, null, 12, Lu))), 128))
2774
+ ])) : f("", !0),
2775
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i("g", {
2776
+ key: `serie_line_${u}`,
2777
+ class: Be(`serie_line_${u}`),
2778
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2779
+ }, [
2780
+ e.useArea && e.plots.length > 1 ? (n(), i("g", Mu, [
2781
+ e.smooth ? (n(!0), i(g, { key: 0 }, C(e.curveAreas, (a, s) => (n(), i(g, { key: s }, [
2782
+ a ? (n(), i("path", {
2783
+ key: 0,
2784
+ d: a,
2785
+ fill: t.value.line.area.useGradient ? `url(#areaGradient_${u}_${G.value})` : v(je)(e.color, t.value.line.area.opacity),
2786
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2787
+ }, null, 12, Cu)) : f("", !0),
2788
+ l.$slots.pattern && a ? (n(), i("path", {
2789
+ key: 1,
2790
+ d: a,
2791
+ fill: `url(#pattern_${G.value}_${e.slotAbsoluteIndex})`,
2792
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2793
+ }, null, 12, Au)) : f("", !0)
2794
+ ], 64))), 128)) : (n(!0), i(g, { key: 1 }, C(e.area.split(";"), (a, s) => (n(), i(g, { key: s }, [
2795
+ a ? (n(), i("path", {
2796
+ key: 0,
2797
+ d: `M${a}Z`,
2798
+ fill: t.value.line.area.useGradient ? `url(#areaGradient_${u}_${G.value})` : v(je)(e.color, t.value.line.area.opacity),
2799
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2800
+ }, null, 12, zu)) : f("", !0),
2801
+ l.$slots.pattern && a ? (n(), i("path", {
2802
+ key: 1,
2803
+ d: `M${a}Z`,
2804
+ fill: `url(#pattern_${G.value}_${e.slotAbsoluteIndex})`,
2805
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2806
+ }, null, 12, Tu)) : f("", !0)
2807
+ ], 64))), 128))
2808
+ ])) : f("", !0),
2809
+ e.smooth && e.plots.length > 1 && e.curve ? (n(), i("path", {
2810
+ key: 1,
2811
+ d: `M${e.curve}`,
2812
+ stroke: e.color,
2813
+ "stroke-width": t.value.line.strokeWidth,
2814
+ "stroke-dasharray": e.dashed ? t.value.line.strokeWidth * 2 : 0,
2815
+ fill: "none",
2816
+ "stroke-linecap": "round",
2817
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2818
+ }, null, 12, Iu)) : e.plots.length > 1 && e.straight ? (n(), i("path", {
2819
+ key: 2,
2820
+ d: `M${e.straight}`,
2821
+ stroke: e.color,
2822
+ "stroke-width": t.value.line.strokeWidth,
2823
+ "stroke-dasharray": e.dashed ? t.value.line.strokeWidth * 2 : 0,
2824
+ fill: "none",
2825
+ "stroke-linecap": "round",
2826
+ "stroke-linejoin": "round",
2827
+ style: L({ transition: v(ue) || !t.value.line.showTransition ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out` })
2828
+ }, null, 12, Nu)) : f("", !0),
2829
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
2830
+ key: `circle_line_${u}_${s}`
2831
+ }, [
2832
+ !ha.value.linePlot && a && Oe(a.value) || ha.value.linePlot && a && Oe(a.value) && (S.value !== null && S.value === s || O.value !== null && O.value === s) || xa(e.plots, s) ? (n(), Ge(Nl, {
2833
+ key: 0,
2834
+ shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(e.shape) ? e.shape : "circle",
2835
+ color: t.value.line.useGradient ? `url(#lineGradient_${u}_${G.value})` : t.value.line.dot.useSerieColor ? e.color : t.value.line.dot.fill,
2836
+ plot: { x: v(B)(a.x), y: v(B)(a.y) },
2837
+ radius: S.value !== null && S.value === s || O.value !== null && O.value === s ? (ze.value.line || 6) * 1.5 : (xa(e.plots, s), ze.value.line || 6),
2838
+ stroke: t.value.line.dot.useSerieColor ? t.value.chart.backgroundColor : e.color,
2839
+ strokeWidth: t.value.line.dot.strokeWidth,
2840
+ transition: v(ue) || !t.value.line.showTransition || S.value !== null && S.value === s || O.value !== null && O.value === s ? void 0 : `all ${t.value.line.transitionDurationMs}ms ease-in-out`
2841
+ }, null, 8, ["shape", "color", "plot", "radius", "stroke", "strokeWidth", "transition"])) : f("", !0),
2842
+ a.comment && t.value.chart.comments.show ? (n(), i("foreignObject", {
2843
+ key: 1,
2844
+ style: { overflow: "visible" },
2845
+ height: "12",
2846
+ width: t.value.chart.comments.width,
2847
+ x: a.x - t.value.chart.comments.width / 2 + t.value.chart.comments.offsetX,
2848
+ y: a.y + t.value.chart.comments.offsetY + 6
2849
+ }, [
2850
+ x("div", Pu, [
2851
+ J(l.$slots, "plot-comment", {
2852
+ plot: { ...a, color: e.color, seriesIndex: u, datapointIndex: s }
2853
+ }, void 0, !0)
2854
+ ])
2855
+ ], 8, Ru)) : f("", !0)
2856
+ ], 64))), 128)),
2857
+ Object.hasOwn(e, "useProgression") && e.useProgression === !0 && !isNaN(v(j)(e.plots).trend) ? (n(), i("g", Ou, [
2858
+ x("defs", null, [
2859
+ x("marker", {
2860
+ id: `line_arrow_${u}`,
2861
+ markerWidth: 7,
2862
+ markerHeight: 7,
2863
+ refX: "0",
2864
+ refY: 7 / 2,
2865
+ orient: "auto"
2866
+ }, [
2867
+ x("polygon", {
2868
+ points: `0 0, 7 ${7 / 2}, 0 7`,
2869
+ fill: e.color
2870
+ }, null, 8, Vu)
2871
+ ], 8, Hu)
2872
+ ]),
2873
+ e.plots.length > 1 ? (n(), i("line", {
2874
+ key: 0,
2875
+ x1: v(j)(e.plots).x1,
2876
+ x2: v(j)(e.plots).x2,
2877
+ y1: v(X)(v(j)(e.plots).y1),
2878
+ y2: v(X)(v(j)(e.plots).y2),
2879
+ "stroke-width": 1,
2880
+ stroke: e.color,
2881
+ "stroke-dasharray": 2,
2882
+ "marker-end": `url(#line_arrow_${u})`
2883
+ }, null, 8, Bu)) : f("", !0),
2884
+ e.plots.length > 1 ? (n(), i("text", {
2885
+ key: 1,
2886
+ "text-anchor": "middle",
2887
+ x: v(j)(e.plots).x2,
2888
+ y: v(j)(e.plots).y2 - 6,
2889
+ "font-size": _.value.plotLabels,
2890
+ fill: e.color
2891
+ }, ae(v(Ue)({
2892
+ v: v(j)(e.plots).trend * 100,
2893
+ s: "%",
2894
+ r: 2
2895
+ })), 9, Eu)) : f("", !0)
2896
+ ])) : f("", !0)
2897
+ ], 6))), 128)),
2898
+ (t.value.bar.labels.show || t.value.bar.serieName.show) && y.value.dataLabels.show ? (n(), i("g", Fu, [
2899
+ (n(!0), i(g, null, C(xt.value, (e, u) => (n(), i(g, {
2900
+ key: `xLabel_bar_${u}`
2901
+ }, [
2902
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
2903
+ key: `xLabel_bar_${u}_${s}`
2904
+ }, [
2905
+ a && (!Object.hasOwn(e, "dataLabels") || e.dataLabels === !0 || S.value !== null && S.value === s || O.value !== null && O.value === s) && t.value.bar.labels.show ? (n(), i("text", {
2906
+ key: 0,
2907
+ x: y.value.useIndividualScale && y.value.isStacked ? a.x + le.value.line / 2 : $l(a) + Jt() / 2 - _l.value / 2,
2908
+ y: v(B)(a.y) + (a.value >= 0 ? t.value.bar.labels.offsetY : -t.value.bar.labels.offsetY * 3),
2909
+ "text-anchor": "middle",
2910
+ "font-size": _.value.plotLabels,
2911
+ fill: t.value.bar.labels.color,
2912
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2913
+ }, ae(Oe(a.value) ? v(Se)(
2914
+ t.value.bar.labels.formatter,
2915
+ a.value,
2916
+ v(Ue)({
2917
+ p: e.prefix || t.value.chart.labels.prefix,
2918
+ v: a.value,
2919
+ s: e.suffix || t.value.chart.labels.suffix,
2920
+ r: t.value.bar.labels.rounding
2921
+ }),
2922
+ {
2923
+ datapoint: a,
2924
+ serie: e
2925
+ }
2926
+ ) : ""), 13, Wu)) : f("", !0),
2927
+ a && t.value.bar.serieName.show ? (n(), i("text", {
2928
+ key: 1,
2929
+ x: y.value.useIndividualScale && y.value.isStacked ? a.x + le.value.line / 2 : a.x + Jt() * 1.1,
2930
+ y: a.y + (a.value > 0 ? t.value.bar.serieName.offsetY : -t.value.bar.serieName.offsetY * 3),
2931
+ "text-anchor": "middle",
2932
+ "font-size": _.value.plotLabels,
2933
+ fill: t.value.bar.serieName.useSerieColor ? e.color : t.value.bar.serieName.color,
2934
+ "font-weight": t.value.bar.serieName.bold ? "bold" : "normal",
2935
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2936
+ }, ae(t.value.bar.serieName.useAbbreviation ? v(To)({
2937
+ source: e.name,
2938
+ length: t.value.bar.serieName.abbreviationSize
2939
+ }) : e.name), 13, Du)) : f("", !0)
2940
+ ], 64))), 128))
2941
+ ], 64))), 128))
2942
+ ])) : f("", !0),
2943
+ t.value.plot.labels.show && y.value.dataLabels.show ? (n(), i("g", Yu, [
2944
+ (n(!0), i(g, null, C(Je.value, (e, u) => (n(), i(g, {
2945
+ key: `xLabel_plot_${u}`
2946
+ }, [
2947
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
2948
+ key: `xLabel_plot_${u}_${s}`
2949
+ }, [
2950
+ a && !Object.hasOwn(e, "dataLabels") || e.dataLabels === !0 || S.value !== null && S.value === s || O.value !== null && O.value === s ? (n(), i("text", {
2951
+ key: 0,
2952
+ x: a.x,
2953
+ y: a.y + t.value.plot.labels.offsetY,
2954
+ "text-anchor": "middle",
2955
+ "font-size": _.value.plotLabels,
2956
+ fill: t.value.plot.labels.color,
2957
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
2958
+ }, ae(Oe(a.value) ? v(Se)(
2959
+ t.value.plot.labels.formatter,
2960
+ a.value,
2961
+ v(Ue)({
2962
+ p: e.prefix || t.value.chart.labels.prefix,
2963
+ v: a.value,
2964
+ s: e.suffix || t.value.chart.labels.suffix,
2965
+ r: t.value.plot.labels.rounding
2966
+ }),
2967
+ {
2968
+ datapoint: a,
2969
+ serie: e
2970
+ }
2971
+ ) : ""), 13, Xu)) : f("", !0)
2972
+ ], 64))), 128))
2973
+ ], 64))), 128))
2974
+ ])) : (n(), i("g", Gu, [
2975
+ (n(!0), i(g, null, C(Je.value, (e, u) => (n(), i(g, {
2976
+ key: `xLabel_plot_${u}`
2977
+ }, [
2978
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
2979
+ key: `xLabel_plot_${u}_${s}`
2980
+ }, [
2981
+ t.value.plot.tag.followValue ? (n(), i(g, { key: 1 }, [
2982
+ [O.value, S.value, ft.value].includes(s) && e.useTag ? (n(), i("line", {
2983
+ key: 0,
2984
+ class: "vue-ui-xy-tag-plot",
2985
+ x1: c.value.left,
2986
+ x2: c.value.right,
2987
+ y1: a.y,
2988
+ y2: a.y,
2989
+ "stroke-width": 1,
2990
+ "stroke-linecap": "round",
2991
+ "stroke-dasharray": "2",
2992
+ stroke: e.color
2993
+ }, null, 8, Ju)) : f("", !0)
2994
+ ], 64)) : (n(), i(g, { key: 0 }, [
2995
+ a && s === 0 && e.useTag && e.useTag === "start" ? (n(), i("foreignObject", {
2996
+ key: 0,
2997
+ x: a.x,
2998
+ y: a.y - 20,
2999
+ height: 24,
3000
+ width: "150",
3001
+ style: L(`overflow: visible; opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3002
+ }, [
3003
+ x("div", {
3004
+ style: L(`padding: 3px; background:${v(je)(e.color, 80)};color:${v(et)(e.color)};width:fit-content;font-size:${_.value.plotLabels}px;border-radius: 2px;`),
3005
+ innerHTML: v(Se)(
3006
+ t.value.plot.tag.formatter,
3007
+ a.value,
3008
+ e.name,
3009
+ {
3010
+ datapoint: a,
3011
+ seriesIndex: s,
3012
+ serieName: e.name
3013
+ }
3014
+ )
3015
+ }, null, 12, Zu)
3016
+ ], 12, Uu)) : f("", !0),
3017
+ a && s === e.plots.length - 1 && e.useTag && e.useTag === "end" ? (n(), i("foreignObject", {
3018
+ key: 1,
3019
+ x: a.x - e.name.length * (_.value.plotLabels / 2),
3020
+ y: a.y - 20,
3021
+ height: 24,
3022
+ width: "150",
3023
+ style: L(`overflow: visible; opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3024
+ }, [
3025
+ x("div", {
3026
+ style: L(`padding: 3px; background:${v(je)(e.color, 80)};color:${v(et)(e.color)};width:fit-content;font-size:${_.value.plotLabels}px;border-radius: 2px;`),
3027
+ innerHTML: v(Se)(
3028
+ t.value.plot.tag.formatter,
3029
+ a.value,
3030
+ e.name,
3031
+ {
3032
+ datapoint: a,
3033
+ seriesIndex: s,
3034
+ serieName: e.name
3035
+ }
3036
+ )
3037
+ }, null, 12, Ku)
3038
+ ], 12, qu)) : f("", !0)
3039
+ ], 64))
3040
+ ], 64))), 128))
3041
+ ], 64))), 128))
3042
+ ])),
3043
+ t.value.line.labels.show && y.value.dataLabels.show ? (n(), i("g", Qu, [
3044
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i(g, {
3045
+ key: `xLabel_line_${u}`
3046
+ }, [
3047
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
3048
+ key: `xLabel_line_${u}_${s}`
3049
+ }, [
3050
+ a && !Object.hasOwn(e, "dataLabels") || e.dataLabels === !0 || S.value !== null && S.value === s || O.value !== null && O.value === s ? (n(), i("text", {
3051
+ key: 0,
3052
+ x: a.x,
3053
+ y: a.y + (a.value >= 0 ? t.value.line.labels.offsetY : -t.value.line.labels.offsetY * 3),
3054
+ "text-anchor": "middle",
3055
+ "font-size": _.value.plotLabels,
3056
+ fill: t.value.line.labels.color,
3057
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3058
+ }, ae(Oe(a.value) ? v(Se)(
3059
+ t.value.line.labels.formatter,
3060
+ a.value,
3061
+ v(Ue)({
3062
+ p: e.prefix || t.value.chart.labels.prefix,
3063
+ v: a.value,
3064
+ s: e.suffix || t.value.chart.labels.suffix,
3065
+ r: t.value.line.labels.rounding
3066
+ }),
3067
+ {
3068
+ datapoint: a,
3069
+ serie: e
3070
+ }
3071
+ ) : ""), 13, ju)) : f("", !0)
3072
+ ], 64))), 128))
3073
+ ], 64))), 128))
3074
+ ])) : (n(), i("g", ei, [
3075
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i(g, {
3076
+ key: `xLabel_line_${u}`
3077
+ }, [
3078
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
3079
+ key: `xLabel_line_${u}_${s}`
3080
+ }, [
3081
+ t.value.line.tag.followValue ? (n(), i(g, { key: 1 }, [
3082
+ [O.value, S.value, ft.value].includes(s) && e.useTag ? (n(), i("line", {
3083
+ key: 0,
3084
+ class: "vue-ui-xy-tag-line",
3085
+ x1: c.value.left,
3086
+ x2: c.value.right,
3087
+ y1: a.y,
3088
+ y2: a.y,
3089
+ "stroke-width": 1,
3090
+ "stroke-linecap": "round",
3091
+ "stroke-dasharray": "2",
3092
+ stroke: e.color
3093
+ }, null, 8, ni)) : f("", !0)
3094
+ ], 64)) : (n(), i(g, { key: 0 }, [
3095
+ a && s === 0 && e.useTag && e.useTag === "start" ? (n(), i("foreignObject", {
3096
+ key: 0,
3097
+ x: a.x,
3098
+ y: a.y - 20,
3099
+ height: 24,
3100
+ width: "150",
3101
+ style: L(`overflow: visible; opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3102
+ }, [
3103
+ x("div", {
3104
+ style: L(`padding: 3px; background:${v(je)(e.color, 80)};color:${v(et)(e.color)};width:fit-content;font-size:${_.value.plotLabels}px;border-radius: 2px;`),
3105
+ innerHTML: v(Se)(
3106
+ t.value.line.tag.formatter,
3107
+ a.value,
3108
+ e.name,
3109
+ {
3110
+ datapoint: a,
3111
+ seriesIndex: s,
3112
+ serieName: e.name
3113
+ }
3114
+ )
3115
+ }, null, 12, li)
3116
+ ], 12, ti)) : f("", !0),
3117
+ a && s === e.plots.length - 1 && e.useTag && e.useTag === "end" ? (n(), i("foreignObject", {
3118
+ key: 1,
3119
+ x: a.x,
3120
+ y: a.y - 20,
3121
+ height: 24,
3122
+ width: "150",
3123
+ style: L(`overflow: visible; opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3124
+ }, [
3125
+ x("div", {
3126
+ style: L(`padding: 3px; background:${v(je)(e.color, 80)};color:${v(et)(e.color)};width:fit-content;font-size:${_.value.plotLabels}px;border-radius: 2px;`),
3127
+ innerHTML: v(Se)(
3128
+ t.value.line.tag.formatter,
3129
+ a.value,
3130
+ e.name,
3131
+ {
3132
+ datapoint: a,
3133
+ seriesIndex: s,
3134
+ serieName: e.name
3135
+ }
3136
+ )
3137
+ }, null, 12, oi)
3138
+ ], 12, ai)) : f("", !0)
3139
+ ], 64))
3140
+ ], 64))), 128))
3141
+ ], 64))), 128))
3142
+ ])),
3143
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i(g, {
3144
+ key: `xLabel_line_${u}`
3145
+ }, [
3146
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
3147
+ key: `xLabel_line_${u}_${s}`
3148
+ }, [
3149
+ a && s === 0 && e.showSerieName && e.showSerieName === "start" ? (n(), i("text", {
3150
+ key: 0,
3151
+ x: a.x - _.value.plotLabels,
3152
+ y: a.y,
3153
+ "font-size": _.value.plotLabels,
3154
+ "text-anchor": "end",
3155
+ fill: e.color,
3156
+ innerHTML: v(Il)({
3157
+ content: e.name,
3158
+ fontSize: _.value.plotLabels,
3159
+ fill: e.color,
3160
+ x: a.x - _.value.plotLabels,
3161
+ y: a.y,
3162
+ maxWords: 2
3163
+ }),
3164
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3165
+ }, null, 12, ui)) : f("", !0),
3166
+ a && s === e.plots.length - 1 && e.showSerieName && e.showSerieName === "end" ? (n(), i("text", {
3167
+ key: 1,
3168
+ x: a.x + _.value.plotLabels,
3169
+ y: a.y,
3170
+ "font-size": _.value.plotLabels,
3171
+ "text-anchor": "start",
3172
+ fill: e.color,
3173
+ innerHTML: v(Il)({
3174
+ content: e.name,
3175
+ fontSize: _.value.plotLabels,
3176
+ fill: e.color,
3177
+ x: a.x + _.value.plotLabels,
3178
+ y: a.y,
3179
+ maxWords: 2
3180
+ }),
3181
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3182
+ }, null, 12, ii)) : f("", !0)
3183
+ ], 64))), 128))
3184
+ ], 64))), 128)),
3185
+ (n(!0), i(g, null, C(Je.value, (e, u) => (n(), i(g, {
3186
+ key: `xLabel_plot_${u}`
3187
+ }, [
3188
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
3189
+ key: `xLabel_plot_${u}_${s}`
3190
+ }, [
3191
+ a && s === 0 && e.showSerieName && e.showSerieName === "start" ? (n(), i("text", {
3192
+ key: 0,
3193
+ x: a.x - _.value.plotLabels,
3194
+ y: a.y,
3195
+ "font-size": _.value.plotLabels,
3196
+ "text-anchor": "end",
3197
+ fill: e.color,
3198
+ innerHTML: v(Il)({
3199
+ content: e.name,
3200
+ fontSize: _.value.plotLabels,
3201
+ fill: e.color,
3202
+ x: a.x - _.value.plotLabels,
3203
+ y: a.y,
3204
+ maxWords: 2
3205
+ }),
3206
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3207
+ }, null, 12, si)) : f("", !0),
3208
+ a && s === e.plots.length - 1 && e.showSerieName && e.showSerieName === "end" ? (n(), i("text", {
3209
+ key: 1,
3210
+ x: a.x + _.value.plotLabels,
3211
+ y: a.y,
3212
+ "font-size": _.value.plotLabels,
3213
+ "text-anchor": "start",
3214
+ fill: e.color,
3215
+ innerHTML: v(Il)({
3216
+ content: e.name,
3217
+ fontSize: _.value.plotLabels,
3218
+ fill: e.color,
3219
+ x: a.x + _.value.plotLabels,
3220
+ y: a.y,
3221
+ maxWords: 2
3222
+ }),
3223
+ style: L(`opacity:${P.value ? P.value === e.groupId ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
3224
+ }, null, 12, ri)) : f("", !0)
3225
+ ], 64))), 128))
3226
+ ], 64))), 128)),
3227
+ y.value.useIndividualScale && !y.value.isStacked ? (n(), i(g, { key: 13 }, [
3228
+ x("defs", null, [
3229
+ (n(!0), i(g, null, C(fl.value, (e, u) => (n(), i("linearGradient", {
3230
+ id: `individual_scale_gradient_${G.value}_${u}`,
3231
+ x1: "0%",
3232
+ x2: "100%",
3233
+ y1: "0%",
3234
+ y2: "0%"
3235
+ }, [
3236
+ x("stop", {
3237
+ offset: "0%",
3238
+ "stop-color": t.value.chart.backgroundColor,
3239
+ "stop-opacity": "0"
3240
+ }, null, 8, vi),
3241
+ x("stop", {
3242
+ offset: "100%",
3243
+ "stop-color": e.color,
3244
+ "stop-opacity": "0.2"
3245
+ }, null, 8, di)
3246
+ ], 8, ci))), 256))
3247
+ ]),
3248
+ (n(!0), i(g, null, C(fl.value, (e, u) => (n(), i("rect", {
3249
+ x: e.x - t.value.chart.grid.labels.yAxis.labelWidth + Q.value - c.value.individualOffsetX,
3250
+ y: c.value.top,
3251
+ width: t.value.chart.grid.labels.yAxis.labelWidth + c.value.individualOffsetX,
3252
+ height: c.value.height < 0 ? 10 : c.value.height,
3253
+ fill: P.value === e.groupId ? `url(#individual_scale_gradient_${G.value}_${u})` : "transparent",
3254
+ onMouseenter: (a) => P.value = e.groupId,
3255
+ onMouseleave: r[0] || (r[0] = (a) => P.value = null)
3256
+ }, null, 40, hi))), 256))
3257
+ ], 64)) : f("", !0),
3258
+ x("g", null, [
3259
+ t.value.chart.grid.labels.axis.yLabel && !y.value.useIndividualScale ? (n(), i("text", {
3260
+ key: 0,
3261
+ ref_key: "yAxisLabel",
3262
+ ref: Yt,
3263
+ "font-size": _.value.yAxis,
3264
+ fill: t.value.chart.grid.labels.color,
3265
+ transform: `translate(${t.value.chart.grid.labels.axis.fontSize}, ${c.value.top + c.value.height / 2}) rotate(-90)`,
3266
+ "text-anchor": "middle",
3267
+ style: { transition: "none" }
3268
+ }, ae(t.value.chart.grid.labels.axis.yLabel), 9, fi)) : f("", !0),
3269
+ t.value.chart.grid.labels.axis.xLabel ? (n(), i("text", {
3270
+ key: 1,
3271
+ ref_key: "xAxisLabel",
3272
+ ref: Fe,
3273
+ "text-anchor": "middle",
3274
+ x: oe.value / 2,
3275
+ y: me.value - 3,
3276
+ "font-size": _.value.yAxis,
3277
+ fill: t.value.chart.grid.labels.color
3278
+ }, ae(t.value.chart.grid.labels.axis.xLabel), 9, mi)) : f("", !0)
3279
+ ]),
3280
+ t.value.chart.grid.labels.xAxisLabels.show ? (n(), i("g", {
3281
+ key: 14,
3282
+ ref_key: "timeLabelsEls",
3283
+ ref: dt
3284
+ }, [
3285
+ l.$slots["time-label"] ? (n(!0), i(g, { key: 0 }, C(Wl.value, (e, u) => J(l.$slots, "time-label", zl({
3286
+ key: `time_label_${u}`,
3287
+ ref_for: !0
3288
+ }, {
3289
+ x: c.value.left + c.value.width / T.value * u + c.value.width / T.value / 2,
3290
+ y: c.value.bottom,
3291
+ fontSize: _.value.xAxis,
3292
+ fill: t.value.chart.grid.labels.xAxisLabels.color,
3293
+ transform: `translate(${c.value.left + c.value.width / T.value * u + c.value.width / T.value / 2}, ${c.value.bottom + _.value.xAxis * 1.3 + t.value.chart.grid.labels.xAxisLabels.yOffset}), rotate(${t.value.chart.grid.labels.xAxisLabels.rotation})`,
3294
+ absoluteIndex: e.absoluteIndex,
3295
+ content: e.text,
3296
+ textAnchor: t.value.chart.grid.labels.xAxisLabels.rotation > 0 ? "start" : t.value.chart.grid.labels.xAxisLabels.rotation < 0 ? "end" : "middle",
3297
+ show: e && e.text
3298
+ }), void 0, !0)), 128)) : (n(!0), i(g, { key: 1 }, C(Wl.value, (e, u) => (n(), i("g", {
3299
+ key: `time_label_${u}`
3300
+ }, [
3301
+ e && e.text ? (n(), i(g, { key: 0 }, [
3302
+ String(e.text).includes(`
3303
+ `) ? (n(), i("text", {
3304
+ key: 1,
3305
+ class: "vue-data-ui-time-label",
3306
+ "text-anchor": t.value.chart.grid.labels.xAxisLabels.rotation > 0 ? "start" : t.value.chart.grid.labels.xAxisLabels.rotation < 0 ? "end" : "middle",
3307
+ "font-size": _.value.xAxis,
3308
+ fill: t.value.chart.grid.labels.xAxisLabels.color,
3309
+ transform: `translate(${c.value.left + c.value.width / T.value * u + c.value.width / T.value / 2}, ${c.value.bottom + _.value.xAxis * 1.5}), rotate(${t.value.chart.grid.labels.xAxisLabels.rotation})`,
3310
+ style: L({
3311
+ cursor: Jl() ? "pointer" : "default"
3312
+ }),
3313
+ innerHTML: v(Io)({
3314
+ content: String(e.text),
3315
+ fontSize: _.value.xAxis,
3316
+ fill: t.value.chart.grid.labels.xAxisLabels.color,
3317
+ x: 0,
3318
+ y: 0
3319
+ }),
3320
+ onClick: () => la(e, u)
3321
+ }, null, 12, xi)) : (n(), i("text", {
3322
+ key: 0,
3323
+ class: "vue-data-ui-time-label",
3324
+ "text-anchor": t.value.chart.grid.labels.xAxisLabels.rotation > 0 ? "start" : t.value.chart.grid.labels.xAxisLabels.rotation < 0 ? "end" : "middle",
3325
+ "font-size": _.value.xAxis,
3326
+ fill: t.value.chart.grid.labels.xAxisLabels.color,
3327
+ transform: `translate(${c.value.left + c.value.width / T.value * u + c.value.width / T.value / 2}, ${c.value.bottom + _.value.xAxis * 1.5}), rotate(${t.value.chart.grid.labels.xAxisLabels.rotation})`,
3328
+ style: L({
3329
+ cursor: Jl() ? "pointer" : "default"
3330
+ }),
3331
+ onClick: () => la(e, u)
3332
+ }, ae(e.text || ""), 13, gi))
3333
+ ], 64)) : f("", !0)
3334
+ ]))), 128))
3335
+ ], 512)) : f("", !0),
3336
+ ga.value.length && !y.value.isStacked ? (n(), i("g", bi, [
3337
+ (n(!0), i(g, null, C(ga.value, (e) => (n(), i("g", {
3338
+ key: e.uid
3339
+ }, [
3340
+ e.yTop && e.show && isFinite(e.yTop) ? (n(), i("line", {
3341
+ key: 0,
3342
+ x1: e.x1,
3343
+ y1: e.yTop,
3344
+ x2: e.x2,
3345
+ y2: e.yTop,
3346
+ stroke: e.config.line.stroke,
3347
+ "stroke-width": e.config.line.strokeWidth,
3348
+ "stroke-dasharray": e.config.line.strokeDasharray,
3349
+ "stroke-linecap": "round",
3350
+ style: { animation: "none !important" }
3351
+ }, null, 8, pi)) : f("", !0),
3352
+ e.yBottom && e.show && isFinite(e.yBottom) ? (n(), i("line", {
3353
+ key: 1,
3354
+ x1: e.x1,
3355
+ y1: e.yBottom,
3356
+ x2: e.x2,
3357
+ y2: e.yBottom,
3358
+ stroke: e.config.line.stroke,
3359
+ "stroke-width": e.config.line.strokeWidth,
3360
+ "stroke-dasharray": e.config.line.strokeDasharray,
3361
+ "stroke-linecap": "round",
3362
+ style: { animation: "none !important" }
3363
+ }, null, 8, yi)) : f("", !0),
3364
+ e.hasArea && e.show && isFinite(e.yTop) && isFinite(e.yBottom) ? (n(), i("rect", {
3365
+ key: 2,
3366
+ y: Math.min(e.yTop, e.yBottom),
3367
+ x: e.x1,
3368
+ width: c.value.width,
3369
+ height: v(B)(e.areaHeight, 0),
3370
+ fill: v(je)(e.config.area.fill, e.config.area.opacity),
3371
+ style: { animation: "none !important" }
3372
+ }, null, 8, ki)) : f("", !0),
3373
+ e.config.label.text && e.show && isFinite(e._box.y) ? (n(), i("rect", zl({
3374
+ key: 3,
3375
+ class: "vue-ui-xy-annotation-label-box"
3376
+ }, { ref_for: !0 }, e._box, { style: { animation: "none !important", transition: "none !important" } }), null, 16)) : f("", !0),
3377
+ e.config.label.text && e.show && isFinite(e._text.y) ? (n(), i("text", {
3378
+ key: 4,
3379
+ id: e.id,
3380
+ class: "vue-ui-xy-annotation-label",
3381
+ x: e._text.x,
3382
+ y: e._text.y,
3383
+ "font-size": e.config.label.fontSize,
3384
+ fill: e.config.label.color,
3385
+ "text-anchor": e.config.label.textAnchor
3386
+ }, ae(e.config.label.text), 9, wi)) : f("", !0)
3387
+ ]))), 128))
3388
+ ])) : f("", !0),
3389
+ t.value.chart.timeTag.show && (![null, void 0].includes(S.value) || ![null, void 0].includes(O.value)) ? (n(), i("g", Si, [
3390
+ (n(), i("foreignObject", {
3391
+ x: c.value.left + c.value.width / T.value * ((S.value !== null ? S.value : 0) || (O.value !== null ? O.value : 0)) - 100 + c.value.width / T.value / 2,
3392
+ y: c.value.bottom,
3393
+ width: "200",
3394
+ height: "40",
3395
+ style: { overflow: "visible !important" }
3396
+ }, [
3397
+ x("div", {
3398
+ class: "vue-ui-xy-time-tag",
3399
+ style: L(`width: fit-content;margin: 0 auto;text-align:center;padding:3px 12px;background:${t.value.chart.timeTag.backgroundColor};color:${t.value.chart.timeTag.color};font-size:${t.value.chart.timeTag.fontSize}px`),
3400
+ innerHTML: so.value
3401
+ }, null, 12, _i)
3402
+ ], 8, $i)),
3403
+ x("circle", {
3404
+ cx: c.value.left + c.value.width / T.value * ((S.value !== null ? S.value : 0) || (O.value !== null ? O.value : 0)) + c.value.width / T.value / 2,
3405
+ cy: c.value.bottom,
3406
+ r: t.value.chart.timeTag.circleMarker.radius,
3407
+ fill: t.value.chart.timeTag.circleMarker.color
3408
+ }, null, 8, Li)
3409
+ ])) : f("", !0)
3410
+ ])) : f("", !0),
3411
+ kt.value ? (n(), i("rect", bt(zl({ key: 2 }, m.value)), null, 16)) : f("", !0),
3412
+ J(l.$slots, "svg", { svg: nt.value }, void 0, !0)
3413
+ ], 512)
3414
+ ], 46, gn)),
3415
+ l.$slots.watermark ? (n(), i("div", Mi, [
3416
+ J(l.$slots, "watermark", bt(Mt({ isPrinting: v(h) || v($) })), void 0, !0)
3417
+ ])) : f("", !0),
3418
+ (n(!0), i(g, null, C(Te.value, (e, u) => (n(), i(g, {
3419
+ key: `tag_line_${u}`
3420
+ }, [
3421
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
3422
+ key: `tag_line_${u}_${s}`
3423
+ }, [
3424
+ [O.value, S.value, ft.value].includes(s) && e.useTag && e.useTag === "end" && t.value.line.tag.followValue ? (n(), i("div", {
3425
+ key: 0,
3426
+ ref_for: !0,
3427
+ ref: (o) => wl(u, s, o, "right", "line"),
3428
+ class: "vue-ui-xy-tag",
3429
+ "data-tag": "right",
3430
+ style: L({
3431
+ position: "fixed",
3432
+ top: v(Ct)({
3433
+ svgElement: $e.value,
3434
+ x: c.value.right + t.value.line.tag.fontSize / 1.5,
3435
+ y: a.y,
3436
+ element: We.value[`${u}_${s}_right_line`],
3437
+ position: "right"
3438
+ }).top + "px",
3439
+ left: v(Ct)({
3440
+ svgElement: $e.value,
3441
+ x: c.value.right + t.value.line.tag.fontSize / 1.5,
3442
+ y: a.y,
3443
+ element: We.value[`${u}_${s}_right_line`],
3444
+ position: "right"
3445
+ }).left + "px",
3446
+ height: "fit-content",
3447
+ width: "fit-content",
3448
+ background: e.color,
3449
+ color: v(et)(e.color),
3450
+ padding: "0 6px",
3451
+ fontSize: t.value.line.tag.fontSize + "px",
3452
+ opacity: 1
3453
+ })
3454
+ }, [
3455
+ (n(), i("svg", Ci, [
3456
+ x("path", {
3457
+ d: "M 0,10 10,0 10,20 Z",
3458
+ fill: e.color,
3459
+ stroke: "none"
3460
+ }, null, 8, Ai)
3461
+ ])),
3462
+ x("div", {
3463
+ class: "vue-ui-xy-tag-content",
3464
+ innerHTML: v(Se)(
3465
+ t.value.line.tag.formatter,
3466
+ a.value,
3467
+ e.name,
3468
+ {
3469
+ datapoint: a,
3470
+ seriesIndex: s,
3471
+ serieName: e.name
3472
+ }
3473
+ )
3474
+ }, null, 8, zi)
3475
+ ], 4)) : f("", !0),
3476
+ [O.value, S.value, ft.value].includes(s) && e.useTag && e.useTag === "start" && t.value.line.tag.followValue ? (n(), i("div", {
3477
+ key: 1,
3478
+ ref_for: !0,
3479
+ ref: (o) => wl(u, s, o, "left", "line"),
3480
+ class: "vue-ui-xy-tag",
3481
+ "data-tag": "left",
3482
+ style: L({
3483
+ position: "fixed",
3484
+ top: v(Ct)({
3485
+ svgElement: $e.value,
3486
+ x: c.value.left - t.value.line.tag.fontSize / 1.5,
3487
+ y: a.y,
3488
+ element: We.value[`${u}_${s}_left_line`],
3489
+ position: "left"
3490
+ }).top + "px",
3491
+ left: v(Ct)({
3492
+ svgElement: $e.value,
3493
+ x: c.value.left - t.value.line.tag.fontSize / 1.5,
3494
+ y: a.y,
3495
+ element: We.value[`${u}_${s}_left_line`],
3496
+ position: "left"
3497
+ }).left + "px",
3498
+ height: "fit-content",
3499
+ width: "fit-content",
3500
+ background: e.color,
3501
+ color: v(et)(e.color),
3502
+ padding: "0 6px",
3503
+ fontSize: t.value.line.tag.fontSize + "px",
3504
+ opacity: 1
3505
+ })
3506
+ }, [
3507
+ (n(), i("svg", Ti, [
3508
+ x("path", {
3509
+ d: "M 0,0 10,10 0,20 Z",
3510
+ fill: e.color,
3511
+ stroke: "none"
3512
+ }, null, 8, Ii)
3513
+ ])),
3514
+ x("div", {
3515
+ class: "vue-ui-xy-tag-content",
3516
+ innerHTML: v(Se)(
3517
+ t.value.line.tag.formatter,
3518
+ a.value,
3519
+ e.name,
3520
+ {
3521
+ datapoint: a,
3522
+ seriesIndex: s,
3523
+ serieName: e.name
3524
+ }
3525
+ )
3526
+ }, null, 8, Ni)
3527
+ ], 4)) : f("", !0)
3528
+ ], 64))), 128))
3529
+ ], 64))), 128)),
3530
+ (n(!0), i(g, null, C(Je.value, (e, u) => (n(), i(g, {
3531
+ key: `tag_plot_${u}`
3532
+ }, [
3533
+ (n(!0), i(g, null, C(e.plots, (a, s) => (n(), i(g, {
3534
+ key: `tag_plot_${u}_${s}`
3535
+ }, [
3536
+ [O.value, S.value, ft.value].includes(s) && e.useTag && e.useTag === "end" && t.value.plot.tag.followValue ? (n(), i("div", {
3537
+ key: 0,
3538
+ ref_for: !0,
3539
+ ref: (o) => wl(u, s, o, "right", "plot"),
3540
+ class: "vue-ui-xy-tag",
3541
+ "data-tag": "right",
3542
+ style: L({
3543
+ position: "fixed",
3544
+ top: v(Ct)({
3545
+ svgElement: $e.value,
3546
+ x: c.value.right + t.value.plot.tag.fontSize / 1.5,
3547
+ y: a.y,
3548
+ element: We.value[`${u}_${s}_right_plot`],
3549
+ position: "right"
3550
+ }).top + "px",
3551
+ left: v(Ct)({
3552
+ svgElement: $e.value,
3553
+ x: c.value.right + t.value.plot.tag.fontSize / 1.5,
3554
+ y: a.y,
3555
+ element: We.value[`${u}_${s}_right_plot`],
3556
+ position: "right"
3557
+ }).left + "px",
3558
+ height: "fit-content",
3559
+ width: "fit-content",
3560
+ background: e.color,
3561
+ color: v(et)(e.color),
3562
+ padding: "0 6px",
3563
+ fontSize: t.value.plot.tag.fontSize + "px",
3564
+ opacity: 1
3565
+ })
3566
+ }, [
3567
+ (n(), i("svg", Ri, [
3568
+ x("path", {
3569
+ d: "M 0,10 10,0 10,20 Z",
3570
+ fill: e.color,
3571
+ stroke: "none"
3572
+ }, null, 8, Pi)
3573
+ ])),
3574
+ x("div", {
3575
+ class: "vue-ui-xy-tag-content",
3576
+ innerHTML: v(Se)(
3577
+ t.value.plot.tag.formatter,
3578
+ a.value,
3579
+ e.name,
3580
+ {
3581
+ datapoint: a,
3582
+ seriesIndex: s,
3583
+ serieName: e.name
3584
+ }
3585
+ )
3586
+ }, null, 8, Oi)
3587
+ ], 4)) : f("", !0),
3588
+ [O.value, S.value, ft.value].includes(s) && e.useTag && e.useTag === "start" && t.value.plot.tag.followValue ? (n(), i("div", {
3589
+ key: 1,
3590
+ ref_for: !0,
3591
+ ref: (o) => wl(u, s, o, "left", "plot"),
3592
+ class: "vue-ui-xy-tag",
3593
+ "data-tag": "left",
3594
+ style: L({
3595
+ position: "fixed",
3596
+ top: v(Ct)({
3597
+ svgElement: $e.value,
3598
+ x: c.value.left - t.value.plot.tag.fontSize / 1.5,
3599
+ y: a.y,
3600
+ element: We.value[`${u}_${s}_left_plot`],
3601
+ position: "left"
3602
+ }).top + "px",
3603
+ left: v(Ct)({
3604
+ svgElement: $e.value,
3605
+ x: c.value.left - t.value.plot.tag.fontSize / 1.5,
3606
+ y: a.y,
3607
+ element: We.value[`${u}_${s}_left_plot`],
3608
+ position: "left"
3609
+ }).left + "px",
3610
+ height: "fit-content",
3611
+ width: "fit-content",
3612
+ background: e.color,
3613
+ color: v(et)(e.color),
3614
+ padding: "0 6px",
3615
+ fontSize: t.value.plot.tag.fontSize + "px",
3616
+ opacity: 1
3617
+ })
3618
+ }, [
3619
+ (n(), i("svg", Hi, [
3620
+ x("path", {
3621
+ d: "M 0,0 10,10 0,20 Z",
3622
+ fill: e.color,
3623
+ stroke: "none"
3624
+ }, null, 8, Vi)
3625
+ ])),
3626
+ x("div", {
3627
+ class: "vue-ui-xy-tag-content",
3628
+ innerHTML: v(Se)(
3629
+ t.value.plot.tag.formatter,
3630
+ a.value,
3631
+ e.name,
3632
+ {
3633
+ datapoint: a,
3634
+ seriesIndex: s,
3635
+ serieName: e.name
3636
+ }
3637
+ )
3638
+ }, null, 8, Bi)
3639
+ ], 4)) : f("", !0)
3640
+ ], 64))), 128))
3641
+ ], 64))), 128)),
3642
+ t.value.chart.zoom.preview.enable ? (n(), i(g, { key: 5 }, [
3643
+ t.value.chart.zoom.show && _e.value > 6 && it.value ? (n(), Ge(hn, {
3644
+ ref_key: "chartSlicer",
3645
+ ref: Ne,
3646
+ key: `slicer_${Xt.value}`,
3647
+ background: t.value.chart.zoom.color,
3648
+ fontSize: t.value.chart.zoom.fontSize,
3649
+ useResetSlot: t.value.chart.zoom.useResetSlot,
3650
+ labelLeft: he.value[0] ? he.value[0].text : "",
3651
+ labelRight: he.value.at(-1) ? he.value.at(-1).text : "",
3652
+ textColor: t.value.chart.color,
3653
+ inputColor: t.value.chart.zoom.color,
3654
+ selectColor: t.value.chart.zoom.highlightColor,
3655
+ borderColor: t.value.chart.backgroundColor,
3656
+ minimap: fa.value,
3657
+ smoothMinimap: t.value.chart.zoom.minimap.smooth,
3658
+ minimapSelectedColor: t.value.chart.zoom.minimap.selectedColor,
3659
+ minimapSelectionRadius: t.value.chart.zoom.minimap.selectionRadius,
3660
+ minimapLineColor: t.value.chart.zoom.minimap.lineColor,
3661
+ minimapSelectedColorOpacity: t.value.chart.zoom.minimap.selectedColorOpacity,
3662
+ minimapSelectedIndex: S.value,
3663
+ minimapIndicatorColor: t.value.chart.zoom.minimap.indicatorColor,
3664
+ verticalHandles: t.value.chart.zoom.minimap.verticalHandles,
3665
+ max: _e.value,
3666
+ min: 0,
3667
+ valueStart: w.value.start,
3668
+ valueEnd: w.value.end,
3669
+ start: w.value.start,
3670
+ "onUpdate:start": r[1] || (r[1] = (e) => w.value.start = e),
3671
+ end: w.value.end,
3672
+ "onUpdate:end": r[2] || (r[2] = (e) => w.value.end = e),
3673
+ refreshStartPoint: t.value.chart.zoom.startIndex !== null ? t.value.chart.zoom.startIndex : 0,
3674
+ refreshEndPoint: t.value.chart.zoom.endIndex !== null ? t.value.chart.zoom.endIndex + 1 : Math.max(...R.dataset.map((e) => v(Qe)({ data: e.series, threshold: t.value.downsample.threshold }).length)),
3675
+ enableRangeHandles: t.value.chart.zoom.enableRangeHandles,
3676
+ enableSelectionDrag: t.value.chart.zoom.enableSelectionDrag,
3677
+ onReset: na,
3678
+ onTrapMouse: aa,
3679
+ onFutureStart: r[3] || (r[3] = (e) => wt("start", e)),
3680
+ onFutureEnd: r[4] || (r[4] = (e) => wt("end", e)),
3681
+ timeLabels: ta.value,
3682
+ isPreview: kt.value
3683
+ }, {
3684
+ "reset-action": ge(({ reset: e }) => [
3685
+ J(l.$slots, "reset-action", bt(Mt({ reset: e })), void 0, !0)
3686
+ ]),
3687
+ _: 3
3688
+ }, 8, ["background", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "borderColor", "minimap", "smoothMinimap", "minimapSelectedColor", "minimapSelectionRadius", "minimapLineColor", "minimapSelectedColorOpacity", "minimapSelectedIndex", "minimapIndicatorColor", "verticalHandles", "max", "valueStart", "valueEnd", "start", "end", "refreshStartPoint", "refreshEndPoint", "enableRangeHandles", "enableSelectionDrag", "timeLabels", "isPreview"])) : f("", !0)
3689
+ ], 64)) : (n(), i(g, { key: 6 }, [
3690
+ t.value.chart.zoom.show && _e.value > 6 && it.value ? (n(), Ge(Yo, {
3691
+ ref_key: "chartSlicer",
3692
+ ref: Ne,
3693
+ key: `slicer_${Xt.value}`,
3694
+ background: t.value.chart.zoom.color,
3695
+ fontSize: t.value.chart.zoom.fontSize,
3696
+ useResetSlot: t.value.chart.zoom.useResetSlot,
3697
+ labelLeft: he.value[0] ? he.value[0].text : "",
3698
+ labelRight: he.value.at(-1) ? he.value.at(-1).text : "",
3699
+ textColor: t.value.chart.color,
3700
+ inputColor: t.value.chart.zoom.color,
3701
+ selectColor: t.value.chart.zoom.highlightColor,
3702
+ borderColor: t.value.chart.backgroundColor,
3703
+ minimap: fa.value,
3704
+ smoothMinimap: t.value.chart.zoom.minimap.smooth,
3705
+ minimapSelectedColor: t.value.chart.zoom.minimap.selectedColor,
3706
+ minimapSelectionRadius: t.value.chart.zoom.minimap.selectionRadius,
3707
+ minimapLineColor: t.value.chart.zoom.minimap.lineColor,
3708
+ minimapSelectedColorOpacity: t.value.chart.zoom.minimap.selectedColorOpacity,
3709
+ minimapSelectedIndex: S.value,
3710
+ minimapIndicatorColor: t.value.chart.zoom.minimap.indicatorColor,
3711
+ verticalHandles: t.value.chart.zoom.minimap.verticalHandles,
3712
+ max: _e.value,
3713
+ min: 0,
3714
+ valueStart: w.value.start,
3715
+ valueEnd: w.value.end,
3716
+ start: w.value.start,
3717
+ "onUpdate:start": r[5] || (r[5] = (e) => w.value.start = e),
3718
+ end: w.value.end,
3719
+ "onUpdate:end": r[6] || (r[6] = (e) => w.value.end = e),
3720
+ refreshStartPoint: t.value.chart.zoom.startIndex !== null ? t.value.chart.zoom.startIndex : 0,
3721
+ refreshEndPoint: t.value.chart.zoom.endIndex !== null ? t.value.chart.zoom.endIndex + 1 : Math.max(...R.dataset.map((e) => v(Qe)({ data: e.series, threshold: t.value.downsample.threshold }).length)),
3722
+ enableRangeHandles: t.value.chart.zoom.enableRangeHandles,
3723
+ enableSelectionDrag: t.value.chart.zoom.enableSelectionDrag,
3724
+ onReset: na,
3725
+ onTrapMouse: aa
3726
+ }, {
3727
+ "reset-action": ge(({ reset: e }) => [
3728
+ J(l.$slots, "reset-action", bt(Mt({ reset: e })), void 0, !0)
3729
+ ]),
3730
+ _: 3
3731
+ }, 8, ["background", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "borderColor", "minimap", "smoothMinimap", "minimapSelectedColor", "minimapSelectionRadius", "minimapLineColor", "minimapSelectedColorOpacity", "minimapSelectedIndex", "minimapIndicatorColor", "verticalHandles", "max", "valueStart", "valueEnd", "start", "end", "refreshStartPoint", "refreshEndPoint", "enableRangeHandles", "enableSelectionDrag"])) : f("", !0)
3732
+ ], 64)),
3733
+ x("div", {
3734
+ id: `legend-bottom-${G.value}`
3735
+ }, null, 8, Ei),
3736
+ Ke.value ? (n(), Ge(bo, {
3737
+ key: 7,
3738
+ to: t.value.chart.legend.position === "top" ? `#legend-top-${G.value}` : `#legend-bottom-${G.value}`
3739
+ }, [
3740
+ t.value.chart.legend.show ? (n(), i("div", {
3741
+ key: 0,
3742
+ ref_key: "chartLegend",
3743
+ ref: lt,
3744
+ class: "vue-ui-xy-legend",
3745
+ style: L(`font-size:${t.value.chart.legend.fontSize}px`)
3746
+ }, [
3747
+ (n(!0), i(g, null, C(st.value, (e, u) => (n(), i("div", {
3748
+ key: `div_legend_item_${u}`,
3749
+ onClick: (a) => da(e),
3750
+ class: Be({ "vue-ui-xy-legend-item-alone": st.value.length === 1, "vue-ui-xy-legend-item": !0, "vue-ui-xy-legend-item-segregated": re.value.includes(e.id) })
3751
+ }, [
3752
+ ne.value[e.type] === "line" ? (n(), i("svg", Wi, [
3753
+ x("rect", {
3754
+ x: "0",
3755
+ y: "7.5",
3756
+ rx: "1.5",
3757
+ stroke: t.value.chart.backgroundColor,
3758
+ "stroke-width": 0.5,
3759
+ height: "3",
3760
+ width: "20",
3761
+ fill: e.color
3762
+ }, null, 8, Di),
3763
+ tl(Nl, {
3764
+ plot: { x: 10, y: 9 },
3765
+ radius: 4,
3766
+ color: e.color,
3767
+ shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(e.shape) ? e.shape : "circle",
3768
+ stroke: t.value.chart.backgroundColor,
3769
+ strokeWidth: 0.5
3770
+ }, null, 8, ["color", "shape", "stroke"])
3771
+ ])) : ne.value[e.type] === "bar" ? (n(), i("svg", Yi, [
3772
+ ne.value[e.type] === "bar" && l.$slots.pattern ? (n(), i("rect", {
3773
+ key: 0,
3774
+ x: "0",
3775
+ y: "0",
3776
+ rx: "1",
3777
+ height: "40",
3778
+ width: "40",
3779
+ stroke: "none",
3780
+ fill: e.color
3781
+ }, null, 8, Xi)) : f("", !0),
3782
+ ne.value[e.type] === "bar" ? (n(), i("rect", {
3783
+ key: 1,
3784
+ x: "0",
3785
+ y: "0",
3786
+ rx: "1",
3787
+ height: "40",
3788
+ width: "40",
3789
+ stroke: "none",
3790
+ fill: l.$slots.pattern ? `url(#pattern_${G.value}_${e.slotAbsoluteIndex})` : e.color
3791
+ }, null, 8, Gi)) : f("", !0)
3792
+ ])) : (n(), i("svg", Ui, [
3793
+ tl(Nl, {
3794
+ plot: { x: 6, y: 6 },
3795
+ radius: 5,
3796
+ color: e.color,
3797
+ shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(e.shape) ? e.shape : "circle"
3798
+ }, null, 8, ["color", "shape"])
3799
+ ])),
3800
+ x("span", {
3801
+ style: L(`color:${t.value.chart.legend.color}`)
3802
+ }, ae(e.name), 5)
3803
+ ], 10, Fi))), 128))
3804
+ ], 4)) : (n(), i("div", {
3805
+ key: 1,
3806
+ ref_key: "chartLegend",
3807
+ ref: lt
3808
+ }, [
3809
+ J(l.$slots, "legend", { legend: st.value }, void 0, !0)
3810
+ ], 512))
3811
+ ], 8, ["to"])) : f("", !0),
3812
+ l.$slots.source ? (n(), i("div", {
3813
+ key: 8,
3814
+ ref_key: "source",
3815
+ ref: zt,
3816
+ dir: "auto"
3817
+ }, [
3818
+ J(l.$slots, "source", {}, void 0, !0)
3819
+ ], 512)) : f("", !0),
3820
+ tl(v(xe), {
3821
+ show: y.value.showTooltip && ht.value,
3822
+ backgroundColor: t.value.chart.tooltip.backgroundColor,
3823
+ color: t.value.chart.tooltip.color,
3824
+ fontSize: t.value.chart.tooltip.fontSize,
3825
+ borderRadius: t.value.chart.tooltip.borderRadius,
3826
+ borderColor: t.value.chart.tooltip.borderColor,
3827
+ borderWidth: t.value.chart.tooltip.borderWidth,
3828
+ backgroundOpacity: t.value.chart.tooltip.backgroundOpacity,
3829
+ position: t.value.chart.tooltip.position,
3830
+ offsetY: t.value.chart.tooltip.offsetY,
3831
+ parent: l.$refs.chart,
3832
+ content: io.value,
3833
+ isFullscreen: ke.value,
3834
+ isCustom: t.value.chart.tooltip.customFormat && typeof t.value.chart.tooltip.customFormat == "function",
3835
+ smooth: t.value.chart.tooltip.smooth,
3836
+ backdropFilter: t.value.chart.tooltip.backdropFilter
3837
+ }, {
3838
+ "tooltip-before": ge(() => [
3839
+ J(l.$slots, "tooltip-before", bt(Mt({ ...pa.value })), void 0, !0)
3840
+ ]),
3841
+ "tooltip-after": ge(() => [
3842
+ J(l.$slots, "tooltip-after", bt(Mt({ ...pa.value })), void 0, !0)
3843
+ ]),
3844
+ _: 3
3845
+ }, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "position", "offsetY", "parent", "content", "isFullscreen", "isCustom", "smooth", "backdropFilter"]),
3846
+ it.value ? (n(), Ge(v(Wt), {
3847
+ key: 9,
3848
+ hideDetails: "",
3849
+ config: {
3850
+ open: y.value.showTable,
3851
+ maxHeight: 1e4,
3852
+ body: {
3853
+ backgroundColor: t.value.chart.backgroundColor,
3854
+ color: t.value.chart.color
3855
+ },
3856
+ head: {
3857
+ backgroundColor: t.value.chart.backgroundColor,
3858
+ color: t.value.chart.color
3859
+ }
3860
+ }
3861
+ }, {
3862
+ content: ge(() => [
3863
+ x("div", {
3864
+ style: L(`${v(h) ? "" : "max-height:400px"};overflow:auto;width:100%;margin-top:48px`)
3865
+ }, [
3866
+ x("div", Zi, [
3867
+ Zl(x("input", {
3868
+ type: "checkbox",
3869
+ "onUpdate:modelValue": r[7] || (r[7] = (e) => yt.value = e)
3870
+ }, null, 512), [
3871
+ [po, yt.value]
3872
+ ]),
3873
+ x("div", {
3874
+ onClick: r[8] || (r[8] = (e) => yt.value = !yt.value),
3875
+ style: { cursor: "pointer" }
3876
+ }, [
3877
+ tl(v(At), {
3878
+ name: "chartLine",
3879
+ size: 20,
3880
+ stroke: t.value.chart.color
3881
+ }, null, 8, ["stroke"])
3882
+ ])
3883
+ ]),
3884
+ yt.value ? (n(), Ge(v(al), {
3885
+ key: `sparkline_${Rt.value}`,
3886
+ dataset: oo.value,
3887
+ config: no.value
3888
+ }, null, 8, ["dataset", "config"])) : (n(), Ge(v(Ee), {
3889
+ key: `table_${il.value}`,
3890
+ colNames: Cl.value.colNames,
3891
+ head: Cl.value.head,
3892
+ body: Cl.value.body,
3893
+ config: Cl.value.config,
3894
+ title: `${t.value.chart.title.text}${t.value.chart.title.subtitle.text ? ` : ${t.value.chart.title.subtitle.text}` : ""}`,
3895
+ onClose: r[9] || (r[9] = (e) => y.value.showTable = !1)
3896
+ }, {
3897
+ th: ge(({ th: e }) => [
3898
+ x("div", { innerHTML: e }, null, 8, qi)
3899
+ ]),
3900
+ td: ge(({ td: e }) => [
3901
+ yo(ae(isNaN(Number(e)) ? e : v(Ue)({
3902
+ p: t.value.chart.labels.prefix,
3903
+ v: e,
3904
+ s: t.value.chart.labels.suffix,
3905
+ r: t.value.table.rounding
3906
+ })), 1)
3907
+ ]),
3908
+ _: 1
3909
+ }, 8, ["colNames", "head", "body", "config", "title"]))
3910
+ ], 4)
3911
+ ]),
3912
+ _: 1
3913
+ }, 8, ["config"])) : f("", !0),
3914
+ v(ue) ? (n(), Ge(Eo, { key: 10 })) : f("", !0)
3915
+ ], 46, fn));
3916
+ }
3917
+ }, vs = /* @__PURE__ */ Ba(Ki, [["__scopeId", "data-v-e75750e4"]]);
3918
+ export {
3919
+ vs as default
3920
+ };