vue-data-ui 2.12.6 → 2.12.7-beta.0

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 (109) hide show
  1. package/dist/{Arrow-Bd9ZVBnX.js → Arrow-CmqjRRUl.js} +1 -1
  2. package/dist/BaseDraggableDialog-BMlyvt7E.js +180 -0
  3. package/dist/{BaseIcon-CNbwMh_-.js → BaseIcon-CZdMutjs.js} +1 -1
  4. package/dist/{ColorPicker-B_FoQwtO.js → ColorPicker-DvVKgyAl.js} +23 -24
  5. package/dist/{DataTable-Rajdtaf6.js → DataTable-Cv9CIz-a.js} +11 -11
  6. package/dist/{Legend-BxtDQCIv.js → Legend-DFunFf8i.js} +8 -8
  7. package/dist/NonSvgPenAndPaper-pVuHj6_A.js +467 -0
  8. package/dist/PackageVersion-CLY-udAA.js +10 -0
  9. package/dist/{PenAndPaper-BkP3J-Ft.js → PenAndPaper-B9na2mbr.js} +8 -10
  10. package/dist/RecursiveCircles-Dn3TGoL6.js +96 -0
  11. package/dist/RecursiveLabels-NTMB9w5C.js +49 -0
  12. package/dist/RecursiveLinks-ld_gDZH4.js +64 -0
  13. package/dist/{Shape-C69a0f29.js → Shape-D3w9qas1.js} +2 -2
  14. package/dist/{Slicer-7qFdY-bT.js → Slicer-ncY8krrM.js} +2 -2
  15. package/dist/SparkTooltip-CwThutH2.js +68 -0
  16. package/dist/{Title-CzaCeCOm.js → Title-B5qqUI3M.js} +2 -2
  17. package/dist/Tooltip-C9rxJ-Ru.js +149 -0
  18. package/dist/{usePrinter-C5bLp34h.js → UserOptions-Ddy6CuLC.js} +172 -231
  19. package/dist/{dom-to-png-Bm0D0yPL.js → dom-to-png-DDlooC9r.js} +1 -1
  20. package/dist/{img-BN9AzqUr.js → img-m9g7lR5d.js} +1 -1
  21. package/dist/{index-BFzQMJda.js → index-BiHmNd1-.js} +21 -21
  22. package/dist/{pdf-uTbs813M.js → pdf-BqM953uL.js} +1 -1
  23. package/dist/style.css +1 -1
  24. package/dist/useChartAccessibility-9icAAmYg.js +12 -0
  25. package/dist/useMouse-AicQS8Vf.js +13 -0
  26. package/dist/{useNestedProp-v7KPpwuP.js → useNestedProp-tRqS0ZAM.js} +1 -1
  27. package/dist/{usePanZoom-CUkkqW81.js → usePanZoom-BQMvRXEQ.js} +16 -17
  28. package/dist/usePrinter-CRCbl1WG.js +53 -0
  29. package/dist/vClickOutside-C6WiFswA.js +13 -0
  30. package/dist/{vue-data-ui-D1k8FeRp.js → vue-data-ui-D9uTDt73.js} +63 -63
  31. package/dist/vue-data-ui.js +19 -19
  32. package/dist/{vue-ui-3d-bar-DoklA4DT.js → vue-ui-3d-bar-rtuSc8FS.js} +397 -402
  33. package/dist/{vue-ui-accordion-BUz4JIIX.js → vue-ui-accordion-CmCs2yR2.js} +3 -3
  34. package/dist/{vue-ui-age-pyramid-4kyBq-Dy.js → vue-ui-age-pyramid-BrzMSiyu.js} +215 -218
  35. package/dist/{vue-ui-annotator-Bq1ZeFfb.js → vue-ui-annotator-CYxmTpf6.js} +2 -2
  36. package/dist/{vue-ui-bullet-DU10avvA.js → vue-ui-bullet-D25qNQfb.js} +137 -140
  37. package/dist/{vue-ui-candlestick-BI1t3flz.js → vue-ui-candlestick-BuerNa-r.js} +265 -271
  38. package/dist/{vue-ui-carousel-table-VowLf_oc.js → vue-ui-carousel-table-aN0HLsOO.js} +137 -137
  39. package/dist/{vue-ui-chestnut-BHjV3d94.js → vue-ui-chestnut-oUj2ocsZ.js} +397 -400
  40. package/dist/{vue-ui-chord-CPr7r-2_.js → vue-ui-chord-C4evlXYB.js} +356 -365
  41. package/dist/vue-ui-circle-pack-CWrNiKTY.js +656 -0
  42. package/dist/{vue-ui-cursor-C9teAbVI.js → vue-ui-cursor-DgpSttlt.js} +2 -2
  43. package/dist/{vue-ui-dashboard-CwDYB8tP.js → vue-ui-dashboard-BN2ha1Eh.js} +62 -62
  44. package/dist/{vue-ui-digits-CHmkL0hn.js → vue-ui-digits-BhjAxXgm.js} +2 -2
  45. package/dist/vue-ui-donut-D3_z61HI.js +1291 -0
  46. package/dist/vue-ui-donut-evolution-oKtmZPx4.js +864 -0
  47. package/dist/{vue-ui-dumbbell-DTKLLd1N.js → vue-ui-dumbbell-C8Lokx-F.js} +265 -270
  48. package/dist/{vue-ui-flow-BLBhsU2n.js → vue-ui-flow-BVRkH0PS.js} +291 -300
  49. package/dist/{vue-ui-funnel-CIrWdeBk.js → vue-ui-funnel-DFxcmAB5.js} +216 -219
  50. package/dist/{vue-ui-galaxy-ByhKyIV4.js → vue-ui-galaxy-CGE0hlBC.js} +227 -235
  51. package/dist/{vue-ui-gauge-BbfBMpng.js → vue-ui-gauge-B48eMvOR.js} +240 -243
  52. package/dist/{vue-ui-gizmo-BM-_QfHM.js → vue-ui-gizmo-zTKNpjvv.js} +57 -58
  53. package/dist/{vue-ui-heatmap-BA4z4hsw.js → vue-ui-heatmap-UNfTt8SM.js} +239 -242
  54. package/dist/{vue-ui-history-plot-8vM_IUy8.js → vue-ui-history-plot-CbCWmvtg.js} +257 -262
  55. package/dist/{vue-ui-kpi-D57QLK6A.js → vue-ui-kpi-Drf_lrlh.js} +29 -30
  56. package/dist/{vue-ui-mini-loader-CR4c-xJQ.js → vue-ui-mini-loader-DU3G6BVs.js} +2 -2
  57. package/dist/vue-ui-molecule-B5MOXYEA.js +580 -0
  58. package/dist/{vue-ui-mood-radar-Brc9cxoD.js → vue-ui-mood-radar-CC_CVLvn.js} +180 -186
  59. package/dist/{vue-ui-nested-donuts-W3Z5F--L.js → vue-ui-nested-donuts-D_H962kk.js} +366 -374
  60. package/dist/{vue-ui-onion-BNBlGNlF.js → vue-ui-onion-P8k6T724.js} +252 -258
  61. package/dist/{vue-ui-parallel-coordinate-plot-B5G3jyvg.js → vue-ui-parallel-coordinate-plot-B5Los0vX.js} +296 -303
  62. package/dist/{vue-ui-quadrant-CUy9mVIA.js → vue-ui-quadrant-B3wzCTxK.js} +402 -409
  63. package/dist/{vue-ui-quick-chart-D4_8mRXU.js → vue-ui-quick-chart-oucj6hXk.js} +611 -616
  64. package/dist/{vue-ui-radar-BUk56jGL.js → vue-ui-radar-Cjqlyu6d.js} +270 -277
  65. package/dist/{vue-ui-rating-B9TQl5KP.js → vue-ui-rating-gryk_h_6.js} +2 -2
  66. package/dist/vue-ui-relation-circle-ielvWC-1.js +525 -0
  67. package/dist/{vue-ui-ridgeline-Cl06bGom.js → vue-ui-ridgeline-Dydqo68b.js} +321 -326
  68. package/dist/{vue-ui-rings-B6bpFlFp.js → vue-ui-rings-BRBXektJ.js} +262 -269
  69. package/dist/{vue-ui-scatter--WUuVw5G.js → vue-ui-scatter-Df-BM7Ts.js} +372 -379
  70. package/dist/{vue-ui-skeleton-B_YI7Yuc.js → vue-ui-skeleton-CbYQYRvD.js} +19 -19
  71. package/dist/{vue-ui-smiley-Bbam2fDz.js → vue-ui-smiley-BfHaQMaW.js} +2 -2
  72. package/dist/{vue-ui-spark-trend-DavXuwGt.js → vue-ui-spark-trend-z3fUChs_.js} +114 -117
  73. package/dist/{vue-ui-sparkbar-9N1FU9-J.js → vue-ui-sparkbar-ChtFIugH.js} +104 -106
  74. package/dist/{vue-ui-sparkgauge-_9ntq4EK.js → vue-ui-sparkgauge-DtpODCww.js} +72 -74
  75. package/dist/{vue-ui-sparkhistogram-BEzOV4HV.js → vue-ui-sparkhistogram-C3XnYiXI.js} +83 -86
  76. package/dist/vue-ui-sparkline-CoL8jiX8.js +459 -0
  77. package/dist/{vue-ui-sparkstackbar-BSWcs3v0.js → vue-ui-sparkstackbar-CYk3mZJH.js} +102 -105
  78. package/dist/{vue-ui-stackbar-gG5BLlAr.js → vue-ui-stackbar-D9LGbuG5.js} +433 -437
  79. package/dist/{vue-ui-strip-plot-BJouRmxh.js → vue-ui-strip-plot-C5r1Ee2R.js} +245 -252
  80. package/dist/{vue-ui-table-D9Ry8s4N.js → vue-ui-table-DBaT_TfA.js} +3 -3
  81. package/dist/{vue-ui-table-heatmap-Bizzpi31.js → vue-ui-table-heatmap-CYW4YfKN.js} +93 -94
  82. package/dist/{vue-ui-table-sparkline-Dg54Ovs2.js → vue-ui-table-sparkline-Di0MYR4p.js} +212 -212
  83. package/dist/{vue-ui-thermometer-6MSdF_Gm.js → vue-ui-thermometer-BF1btHY2.js} +154 -157
  84. package/dist/{vue-ui-timer-ByaKokk8.js → vue-ui-timer-D9FfRWN5.js} +180 -181
  85. package/dist/vue-ui-tiremarks-CQ0lk8fJ.js +341 -0
  86. package/dist/vue-ui-treemap-1Lx7YRtc.js +947 -0
  87. package/dist/{vue-ui-vertical-bar-CE4oBwBv.js → vue-ui-vertical-bar-DdVVQ1ED.js} +397 -403
  88. package/dist/{vue-ui-waffle-DNEEnY_G.js → vue-ui-waffle-BhnuPiRD.js} +317 -324
  89. package/dist/vue-ui-wheel-BIjJ0fg8.js +335 -0
  90. package/dist/vue-ui-word-cloud-3-r8HwO_.js +642 -0
  91. package/dist/{vue-ui-world-Brhq17TE.js → vue-ui-world-CPIGEswq.js} +430 -442
  92. package/dist/{vue-ui-xy-K2G7QQxG.js → vue-ui-xy-9e_epIN4.js} +845 -846
  93. package/dist/vue-ui-xy-canvas-DcGgQ7s4.js +1206 -0
  94. package/package.json +6 -6
  95. package/dist/BaseDraggableDialog-Bzwlfmy1.js +0 -186
  96. package/dist/PackageVersion-BjrblLPQ.js +0 -10
  97. package/dist/Tooltip-CWmRmhJr.js +0 -158
  98. package/dist/useChartAccessibility-BWojgys7.js +0 -13
  99. package/dist/vue-ui-circle-pack-D_jYpsuD.js +0 -659
  100. package/dist/vue-ui-donut-WRUDvvZa.js +0 -1292
  101. package/dist/vue-ui-donut-evolution-BQxV5D_L.js +0 -871
  102. package/dist/vue-ui-molecule-Bq69N7rC.js +0 -782
  103. package/dist/vue-ui-relation-circle-T6aTibIU.js +0 -528
  104. package/dist/vue-ui-sparkline-D__GCUAz.js +0 -519
  105. package/dist/vue-ui-tiremarks-Z8pjUT1g.js +0 -344
  106. package/dist/vue-ui-treemap-pRJ3be5l.js +0 -956
  107. package/dist/vue-ui-wheel-DWPYZxdT.js +0 -338
  108. package/dist/vue-ui-word-cloud-DAR7R8F8.js +0 -648
  109. package/dist/vue-ui-xy-canvas-ml44sPHS.js +0 -1673
@@ -0,0 +1,1206 @@
1
+ import { defineAsyncComponent as J, ref as d, computed as k, useSlots as _a, onMounted as ra, watch as A, nextTick as ge, shallowRef as $e, onBeforeUnmount as Ba, createElementBlock as se, openBlock as z, unref as p, normalizeClass as Va, normalizeStyle as K, createCommentVNode as U, createBlock as D, createElementVNode as ne, createSlots as Za, withCtx as b, renderSlot as x, normalizeProps as W, guardReactiveProps as X, createVNode as Ga, toDisplayString as ua, createTextVNode as ja } from "vue";
2
+ import { u as qa, c as Ja, t as Ka, p as _, a as Qa, C as pe, b as el, D as Ie, i as Q, f as ee, d as sa, a1 as al, H as ll, ai as tl, o as ol, e as rl, x as na, q as ul, r as sl, y as nl, s as ie, l as il } from "./index-BiHmNd1-.js";
3
+ import { d as vl, t as cl, u as dl, c as hl, a as ia, l as L, r as Me, b as R, p as va } from "./useResponsive-JZ9xq-JV.js";
4
+ import { u as ca } from "./useNestedProp-tRqS0ZAM.js";
5
+ import { u as yl } from "./usePrinter-CRCbl1WG.js";
6
+ import { u as fl } from "./useUserOptionState-BIvW1Kz7.js";
7
+ import { u as gl } from "./useChartAccessibility-9icAAmYg.js";
8
+ import pl from "./Legend-DFunFf8i.js";
9
+ import ml from "./Title-B5qqUI3M.js";
10
+ import { S as bl } from "./Slicer-ncY8krrM.js";
11
+ import { _ as xl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
12
+ const Ll = ["id"], kl = ["onClick"], Cl = {
13
+ key: 2,
14
+ class: "vue-data-ui-watermark"
15
+ }, wl = ["innerHTML"], zl = {
16
+ __name: "vue-ui-xy-canvas",
17
+ props: {
18
+ dataset: {
19
+ type: Array,
20
+ default() {
21
+ return [];
22
+ }
23
+ },
24
+ config: {
25
+ type: Object,
26
+ default() {
27
+ return {};
28
+ }
29
+ }
30
+ },
31
+ emits: ["selectLegend"],
32
+ setup(Te, { expose: da, emit: ha }) {
33
+ const ya = J(() => import("./vue-ui-accordion-CmCs2yR2.js")), fa = J(() => import("./DataTable-Cv9CIz-a.js")), ga = J(() => import("./NonSvgPenAndPaper-pVuHj6_A.js")), pa = J(() => import("./vue-ui-skeleton-CbYQYRvD.js")), ma = J(() => import("./Tooltip-C9rxJ-Ru.js")), ba = J(() => import("./UserOptions-Ddy6CuLC.js")), { vue_ui_xy_canvas: xa } = qa(), g = Te, me = d(Ja()), ae = d(null), le = d(null), s = d(null), y = d(1), P = d(1), ve = d(!1), v = d(null), ce = d(""), Oe = d(null), $ = d([]), B = d(1), H = d(!0), V = d(!0), be = d(null), Re = d(0), Pe = d(0), de = d(!1), Ee = d(null), Fe = d(null), Ae = d(null), De = d(null), xe = d(0), Le = d(0), ke = d(0), M = d(null), Ce = k(() => !!g.dataset && g.dataset.length), La = ha, ka = _a();
34
+ ra(() => {
35
+ ka["chart-background"] && console.warn("VueUiXyCanvas does not support the #chart-background slot.");
36
+ });
37
+ const a = k({
38
+ get: () => Ye(),
39
+ set: (e) => e
40
+ }), { userOptionsVisible: we, setUserOptionsVisibility: He, keepUserOptionState: Ne } = fl({ config: a.value }), { svgRef: T } = gl({ config: a.value.style.chart.title });
41
+ function Ye() {
42
+ const e = ca({
43
+ userConfig: g.config,
44
+ defaultConfig: xa
45
+ });
46
+ let t = {};
47
+ return e.theme ? t = {
48
+ ...ca({
49
+ userConfig: Qa.vue_ui_xy_canvas[e.theme] || g.config,
50
+ defaultConfig: e
51
+ }),
52
+ customPalette: Ka[e.theme] || _
53
+ } : t = e, g.config && pe(g.config, "style.chart.scale.min") ? t.style.chart.scale.min = g.config.style.chart.scale.min : t.style.chart.scale.min = null, g.config && pe(g.config, "style.chart.scale.max") ? t.style.chart.scale.max = g.config.style.chart.scale.max : t.style.chart.scale.max = null, g.config && pe(g.config, "style.chart.zoom.startIndex") ? t.style.chart.zoom.startIndex = g.config.style.chart.zoom.startIndex : t.style.chart.zoom.startIndex = null, g.config && pe(g.config, "style.chart.zoom.endIndex") ? t.style.chart.zoom.endIndex = g.config.style.chart.zoom.endIndex : t.style.chart.zoom.endIndex = null, t;
54
+ }
55
+ A(() => g.config, (e) => {
56
+ a.value = Ye(), we.value = !a.value.userOptions.showOnChartHover, ze(), xe.value += 1, Le.value += 1, ke.value += 1, u.value.showTable = a.value.table.show, u.value.showDataLabels = a.value.style.chart.dataLabels.show, u.value.stacked = a.value.style.chart.stacked, u.value.showTooltip = a.value.style.chart.tooltip.show;
57
+ }, { deep: !0 }), A(() => g.dataset, () => {
58
+ ze(), xe.value += 1, Le.value += 1, ke.value += 1;
59
+ }, { deep: !0 });
60
+ const Ue = d(a.value.style.chart.aspectRatio), { isPrinting: We, isImaging: Xe, generatePdf: _e, generateImage: Be } = yl({
61
+ elementId: `xy_canvas_${me.value}`,
62
+ fileName: a.value.style.chart.title.text || "vue-ui-xy-canvas",
63
+ options: a.value.userOptions.print
64
+ }), u = d({
65
+ showTable: a.value.table.show,
66
+ showDataLabels: a.value.style.chart.dataLabels.show,
67
+ stacked: a.value.style.chart.stacked,
68
+ showTooltip: a.value.style.chart.tooltip.show
69
+ });
70
+ function Ca(e) {
71
+ de.value = e, Pe.value += 1;
72
+ }
73
+ const Ve = k(() => el(a.value.customPalette)), I = k(() => Z.value ? Math.max(...Z.value.filter((e, t) => !$.value.includes(e.absoluteIndex)).map((e) => e.series.length)) : 0), l = k(() => {
74
+ const e = y.value - y.value * (a.value.style.chart.paddingProportions.left + a.value.style.chart.paddingProportions.right);
75
+ return {
76
+ canvasWidth: y.value,
77
+ canvasHeight: P.value,
78
+ left: y.value * a.value.style.chart.paddingProportions.left,
79
+ top: P.value * a.value.style.chart.paddingProportions.top,
80
+ right: y.value - y.value * a.value.style.chart.paddingProportions.right,
81
+ bottom: P.value - P.value * a.value.style.chart.paddingProportions.bottom,
82
+ width: e,
83
+ height: P.value - P.value * (a.value.style.chart.paddingProportions.top + a.value.style.chart.paddingProportions.bottom),
84
+ slot: e / (r.value.end - r.value.start)
85
+ };
86
+ });
87
+ function Ze(e, t) {
88
+ return e / t;
89
+ }
90
+ function wa({ hasAutoScale: e, series: t, min: o, max: n, scale: c, yOffset: w, individualHeight: i, stackIndex: f = null }) {
91
+ return t.map((N, S) => {
92
+ const F = c.min < 0 ? Math.abs(c.min) : 0, Y = Ze(N + F, F + c.max);
93
+ let re, ue;
94
+ e && (re = c.min, ue = Ze(N - re, c.max - re));
95
+ let O = 0;
96
+ return f === null ? O = l.value.bottom - l.value.height * (e ? ue : Y) : O = l.value.bottom - w - i * (e ? ue : Y), {
97
+ x: l.value.left + l.value.slot * S + l.value.slot / 2,
98
+ y: O,
99
+ value: N
100
+ };
101
+ });
102
+ }
103
+ const m = k(() => {
104
+ const e = a.value.style.chart.scale.min !== null ? a.value.style.chart.scale.min : Math.min(...Z.value.filter((i, f) => !$.value.includes(i.absoluteIndex)).flatMap((i) => i.series.slice(r.value.start, r.value.end))), t = a.value.style.chart.scale.max !== null ? a.value.style.chart.scale.max : Math.max(...Z.value.filter((i, f) => !$.value.includes(i.absoluteIndex)).flatMap((i) => i.series.slice(r.value.start, r.value.end))), o = Ie(e < 0 ? e : 0, t === e ? e + 1 < 0 ? 0 : e + 1 : t < 0 ? 0 : t, a.value.style.chart.scale.ticks), n = o.min < 0 ? Math.abs(o.min) : 0, c = l.value.bottom - l.value.height * (n / (o.max + n)), w = o.ticks.map((i) => ({
105
+ y: l.value.bottom - l.value.height * ((i + n) / (o.max + n)),
106
+ x: l.value.left - 8,
107
+ value: i
108
+ }));
109
+ return {
110
+ absoluteMin: n,
111
+ max: t,
112
+ min: e,
113
+ scale: o,
114
+ yLabels: w,
115
+ zero: c
116
+ };
117
+ }), za = k(() => h.value.map((e) => `
118
+ <div style="display:flex;flex-direction:row;gap:6px;align-items:center;">
119
+ <svg viewBox="0 0 10 10" height="12" width="12">
120
+ <circle cx="5" cy="5" r="5" fill="${e.color}"/>
121
+ </svg>
122
+ <span>${e.name ? e.name + ": " : ""}</span>
123
+ <span>${Q(
124
+ a.value.style.chart.dataLabels.formatter,
125
+ e.series[v.value],
126
+ ee({
127
+ p: e.prefix || "",
128
+ v: e.series[v.value],
129
+ s: e.suffix || "",
130
+ r: e.rounding || 0
131
+ }),
132
+ { datapoint: e, seriesIndex: v.value }
133
+ )}</span>
134
+ </div>
135
+ `)), Z = k(() => g.dataset.map((e, t) => ({
136
+ ...e,
137
+ series: al({
138
+ data: ll(e.series),
139
+ threshold: a.value.downsample.threshold
140
+ }),
141
+ absoluteIndex: t,
142
+ color: sa(e.color || Ve.value[t] || _[t] || _[t % _.length])
143
+ })));
144
+ A(I, (e) => {
145
+ e && Ge();
146
+ });
147
+ const h = k(() => tl(Z.value.filter((e, t) => !$.value.includes(e.absoluteIndex))).map((e, t) => ({
148
+ ...e,
149
+ series: e.series.slice(r.value.start, r.value.end)
150
+ })).map((e, t) => {
151
+ let o = [null, void 0].includes(e.scaleMin) ? Math.min(...e.series) || 0 : e.scaleMin, n = [null, void 0].includes(e.scaleMax) ? Math.max(...e.series) || 1 : e.scaleMax;
152
+ o === n && (o = o >= 0 ? n - 1 : o, n = n >= 0 ? n : o + 1), e.series.filter((O) => ![null, void 0].includes(O)).map((O) => (O - o) / (n - o));
153
+ const c = {
154
+ valueMin: o,
155
+ valueMax: n
156
+ }, w = e.scaleSteps || a.value.style.chart.scale.ticks;
157
+ let i;
158
+ e.autoScaling ? i = Ie(c.valueMin, c.valueMax, w) : i = Ie(c.valueMin < 0 ? c.valueMin : 0, c.valueMax <= 0 ? 0 : c.valueMax, w);
159
+ const f = u.value.stacked ? l.value.height * (1 - e.cumulatedStackRatio) : 0, N = u.value.stacked ? l.value.height / a.value.style.chart.stackGap : 0, S = u.value.stacked ? l.value.height * e.stackRatio - N : l.value.height, F = i.min < 0 ? Math.abs(i.min) : 0;
160
+ let Y;
161
+ e.autoScaling && u.value.stacked && n <= 0 ? Y = l.value.bottom - f - S : Y = l.value.bottom - f - S * (F / (i.max + F));
162
+ const re = i.ticks.map((O, Xa) => ({
163
+ y: l.value.bottom - f - S * (Xa / (i.ticks.length - 1)),
164
+ x: l.value.left - 8,
165
+ value: O
166
+ })), ue = wa({
167
+ hasAutoScale: u.value.stacked && e.autoScaling,
168
+ series: e.series,
169
+ min: u.value.stacked ? o : m.value.min,
170
+ max: u.value.stacked ? n : m.value.max,
171
+ scale: u.value.stacked ? i : m.value.scale,
172
+ yOffset: f,
173
+ individualHeight: S,
174
+ stackIndex: u.value.stacked ? t : null
175
+ });
176
+ return {
177
+ ...e,
178
+ coordinatesLine: ue,
179
+ min: o,
180
+ max: n,
181
+ localScale: i,
182
+ localZero: Y,
183
+ localMin: F,
184
+ localYLabels: re,
185
+ yOffset: f,
186
+ individualHeight: S
187
+ };
188
+ })), r = d({
189
+ start: 0,
190
+ end: I.value
191
+ });
192
+ function Ge() {
193
+ je();
194
+ }
195
+ const G = d(null);
196
+ async function je() {
197
+ (a.value.style.chart.zoom.startIndex !== null || a.value.style.chart.zoom.endIndex !== null) && G.value ? (a.value.style.chart.zoom.startIndex !== null && (await ge(), await ge(), G.value && G.value.setStartValue(a.value.style.chart.zoom.startIndex)), a.value.style.chart.zoom.endIndex !== null && (await ge(), await ge(), G.value && G.value.setEndValue(Sa(a.value.style.chart.zoom.endIndex + 1)))) : (r.value = {
198
+ start: 0,
199
+ end: I.value
200
+ }, Re.value += 1);
201
+ }
202
+ function Sa(e) {
203
+ const t = I.value;
204
+ return e > t ? t : e < 0 || a.value.style.chart.zoom.startIndex !== null && e < a.value.style.chart.zoom.startIndex ? a.value.style.chart.zoom.startIndex !== null ? a.value.style.chart.zoom.startIndex + 1 : 1 : e;
205
+ }
206
+ const $a = k(() => h.value.filter((e) => ["line", "plot", void 0].includes(e.type))), C = k(() => h.value.filter((e) => e.type === "bar"));
207
+ function Ia() {
208
+ if (!T.value)
209
+ return;
210
+ const e = le.value.offsetWidth, t = le.value.offsetHeight;
211
+ T.value.width = e * B.value * 2, T.value.height = t * B.value * 2, y.value = e * B.value * 2, P.value = t * B.value * 2, s.value.scale(B.value, B.value), te();
212
+ }
213
+ function Ma() {
214
+ if (s.value.clearRect(0, 0, 1e4, 1e4), s.value.fillStyle = a.value.style.chart.backgroundColor, s.value.fillRect(0, 0, l.value.canvasWidth, l.value.canvasHeight), u.value.stacked)
215
+ a.value.style.chart.grid.y.verticalLines.show && r.value.end - r.value.start < a.value.style.chart.grid.y.verticalLines.hideUnderXLength ? h.value.forEach((e) => {
216
+ for (let t = 0; t < r.value.end - r.value.start + 1; t += 1)
217
+ L(
218
+ s.value,
219
+ [
220
+ {
221
+ x: l.value.left + l.value.slot * t,
222
+ y: l.value.bottom - e.yOffset - e.individualHeight
223
+ },
224
+ {
225
+ x: l.value.left + l.value.slot * t,
226
+ y: l.value.bottom - e.yOffset
227
+ }
228
+ ],
229
+ {
230
+ color: a.value.style.chart.grid.y.verticalLines.color
231
+ }
232
+ );
233
+ }) : a.value.style.chart.grid.y.verticalLines.show && r.value.end - r.value.start >= a.value.style.chart.grid.y.verticalLines.hideUnderXLength && h.value.forEach((e) => {
234
+ for (let t = r.value.start; t < r.value.end; t += 1)
235
+ t % Math.floor((r.value.end - r.value.start) / a.value.style.chart.grid.y.timeLabels.modulo) === 0 && L(
236
+ s.value,
237
+ [
238
+ {
239
+ x: l.value.left + l.value.slot * (t - r.value.start) + l.value.slot / 2,
240
+ y: l.value.bottom - e.yOffset - e.individualHeight
241
+ },
242
+ {
243
+ x: l.value.left + l.value.slot * (t - r.value.start) + l.value.slot / 2,
244
+ y: l.value.bottom - e.yOffset
245
+ }
246
+ ],
247
+ {
248
+ color: a.value.style.chart.grid.y.verticalLines.color
249
+ }
250
+ );
251
+ }), a.value.style.chart.grid.x.horizontalLines.show && (a.value.style.chart.grid.x.horizontalLines.alternate ? h.value.forEach((e) => {
252
+ e.localYLabels.forEach((t, o) => {
253
+ o < e.localYLabels.length - 1 && Me(
254
+ s.value,
255
+ [
256
+ { x: l.value.left, y: t.y },
257
+ { x: l.value.right, y: t.y },
258
+ { x: l.value.right, y: e.localYLabels[o + 1].y },
259
+ { x: l.value.left, y: e.localYLabels[o + 1].y }
260
+ ],
261
+ {
262
+ fillColor: o % 2 === 0 ? "transparent" : ie(a.value.style.chart.grid.x.horizontalLines.color, a.value.style.chart.grid.x.horizontalLines.opacity),
263
+ strokeColor: "transparent"
264
+ }
265
+ );
266
+ });
267
+ }) : h.value.forEach((e) => {
268
+ e.localYLabels.slice(r.value.start, r.value.end).forEach((t) => {
269
+ L(
270
+ s.value,
271
+ [
272
+ { x: l.value.left, y: t.y },
273
+ { x: l.value.right, y: t.y }
274
+ ],
275
+ {
276
+ color: a.value.style.chart.grid.x.horizontalLines.color
277
+ }
278
+ );
279
+ });
280
+ })), a.value.style.chart.grid.zeroLine.show && h.value.forEach((e) => {
281
+ L(
282
+ s.value,
283
+ [
284
+ { x: l.value.left, y: e.localZero },
285
+ { x: l.value.right, y: e.localZero }
286
+ ],
287
+ {
288
+ color: a.value.style.chart.grid.zeroLine.color,
289
+ lineDash: a.value.style.chart.grid.zeroLine.dashed ? [10, 10] : [0, 0]
290
+ }
291
+ );
292
+ }), a.value.style.chart.grid.y.axisLabels.show && h.value.forEach((e) => {
293
+ L(
294
+ s.value,
295
+ [
296
+ { x: l.value.left, y: l.value.bottom - e.yOffset },
297
+ { x: l.value.left, y: l.value.bottom - e.yOffset - e.individualHeight }
298
+ ],
299
+ {
300
+ color: e.color
301
+ }
302
+ ), L(
303
+ s.value,
304
+ [
305
+ { x: l.value.right, y: l.value.bottom - e.yOffset },
306
+ { x: l.value.right, y: l.value.bottom - e.yOffset - e.individualHeight }
307
+ ],
308
+ {
309
+ color: e.color
310
+ }
311
+ );
312
+ }), h.value.forEach((e) => {
313
+ R(
314
+ s.value,
315
+ e.name,
316
+ y.value / 35,
317
+ l.value.bottom - e.yOffset - e.individualHeight / 2,
318
+ {
319
+ align: "center",
320
+ rotation: -90,
321
+ color: e.color,
322
+ font: `${Math.round(y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`
323
+ }
324
+ );
325
+ });
326
+ else {
327
+ if (a.value.style.chart.grid.y.verticalLines.show && r.value.end - r.value.start < a.value.style.chart.grid.y.verticalLines.hideUnderXLength)
328
+ for (let e = 0; e < r.value.end - r.value.start + 1; e += 1)
329
+ L(
330
+ s.value,
331
+ [
332
+ { x: l.value.left + l.value.slot * e, y: l.value.top },
333
+ { x: l.value.left + l.value.slot * e, y: l.value.bottom }
334
+ ],
335
+ {
336
+ color: a.value.style.chart.grid.y.verticalLines.color
337
+ }
338
+ );
339
+ else if (a.value.style.chart.grid.y.verticalLines.show && r.value.end - r.value.start >= a.value.style.chart.grid.y.verticalLines.hideUnderXLength)
340
+ for (let e = r.value.start; e < r.value.end; e += 1)
341
+ e % Math.floor((r.value.end - r.value.start) / a.value.style.chart.grid.y.timeLabels.modulo) === 0 && L(
342
+ s.value,
343
+ [
344
+ { x: l.value.left + l.value.slot * (e - r.value.start) + l.value.slot / 2, y: l.value.top },
345
+ { x: l.value.left + l.value.slot * (e - r.value.start) + l.value.slot / 2, y: l.value.bottom }
346
+ ],
347
+ {
348
+ color: a.value.style.chart.grid.y.verticalLines.color
349
+ }
350
+ );
351
+ a.value.style.chart.grid.x.horizontalLines.show && (a.value.style.chart.grid.x.horizontalLines.alternate ? m.value.yLabels.forEach((e, t) => {
352
+ t < m.value.yLabels.length - 1 && Me(
353
+ s.value,
354
+ [
355
+ { x: l.value.left, y: e.y },
356
+ { x: l.value.right, y: e.y },
357
+ { x: l.value.right, y: m.value.yLabels[t + 1].y },
358
+ { x: l.value.left, y: m.value.yLabels[t + 1].y }
359
+ ],
360
+ {
361
+ fillColor: t % 2 === 0 ? "transparent" : ie(a.value.style.chart.grid.x.horizontalLines.color, a.value.style.chart.grid.x.horizontalLines.opacity),
362
+ strokeColor: "transparent"
363
+ }
364
+ );
365
+ }) : m.value.yLabels.forEach((e) => {
366
+ L(
367
+ s.value,
368
+ [
369
+ { x: l.value.left, y: e.y },
370
+ { x: l.value.right, y: e.y }
371
+ ],
372
+ {
373
+ color: a.value.style.chart.grid.x.horizontalLines.color
374
+ }
375
+ );
376
+ })), a.value.style.chart.grid.y.showAxis && L(
377
+ s.value,
378
+ [
379
+ { x: l.value.left, y: l.value.top },
380
+ { x: l.value.left, y: l.value.bottom }
381
+ ],
382
+ {
383
+ color: a.value.style.chart.grid.y.axisColor,
384
+ lineWidth: a.value.style.chart.grid.y.axisThickness
385
+ }
386
+ ), a.value.style.chart.grid.x.showAxis && L(
387
+ s.value,
388
+ [
389
+ { x: l.value.left, y: l.value.bottom },
390
+ { x: l.value.right, y: l.value.bottom }
391
+ ],
392
+ {
393
+ color: a.value.style.chart.grid.x.axisColor,
394
+ lineWidth: a.value.style.chart.grid.x.axisThickness
395
+ }
396
+ ), a.value.style.chart.grid.zeroLine.show && L(
397
+ s.value,
398
+ [
399
+ { x: l.value.left, y: m.value.zero },
400
+ { x: l.value.right, y: m.value.zero }
401
+ ],
402
+ {
403
+ color: a.value.style.chart.grid.zeroLine.color,
404
+ lineDash: a.value.style.chart.grid.zeroLine.dashed ? [10, 10] : [0, 0]
405
+ }
406
+ );
407
+ }
408
+ a.value.style.chart.grid.y.axisName && R(
409
+ s.value,
410
+ a.value.style.chart.grid.y.axisName,
411
+ y.value - y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio * 1.2,
412
+ l.value.bottom - l.value.height / 2,
413
+ {
414
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
415
+ color: a.value.style.chart.color,
416
+ align: "center",
417
+ rotation: 90
418
+ }
419
+ ), a.value.style.chart.grid.x.axisName && R(
420
+ s.value,
421
+ a.value.style.chart.grid.x.axisName,
422
+ y.value / 2,
423
+ P.value,
424
+ {
425
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
426
+ color: a.value.style.chart.color,
427
+ align: "center"
428
+ }
429
+ );
430
+ }
431
+ function Ta(e) {
432
+ for (let t = 0; t < e.coordinatesLine.length; t += 1) {
433
+ const o = (v.value === t ? y.value / 150 : a.value.style.chart.line.plots.show ? y.value / 200 : 0) * a.value.style.chart.line.plots.radiusRatio;
434
+ ia(
435
+ s.value,
436
+ { x: e.coordinatesLine[t].x, y: e.coordinatesLine[t].y },
437
+ o,
438
+ {
439
+ color: a.value.style.chart.backgroundColor,
440
+ fillStyle: e.color
441
+ }
442
+ );
443
+ }
444
+ }
445
+ function Oa() {
446
+ h.value.forEach((e) => {
447
+ e.showYMarker && oe(e) && R(
448
+ s.value,
449
+ Q(
450
+ a.value.style.chart.dataLabels.formatter,
451
+ oe(e).value,
452
+ ee({
453
+ p: e.prefix || a.value.style.chart.grid.y.axisLabels.prefix || "",
454
+ v: oe(e).value,
455
+ s: e.suffix || a.value.style.chart.grid.y.axisLabels.suffix || "",
456
+ r: e.rounding || a.value.style.chart.grid.y.axisLabels.rounding || 0
457
+ }),
458
+ { datapoint: oe(e), seriesIndex: null }
459
+ ),
460
+ l.value.left - 8 + a.value.style.chart.grid.y.axisLabels.offsetX,
461
+ oe(e).y,
462
+ {
463
+ align: "right",
464
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
465
+ color: e.color
466
+ }
467
+ );
468
+ });
469
+ }
470
+ function Ra() {
471
+ a.value.style.chart.grid.y.axisLabels.show && (u.value.stacked ? h.value.forEach((e) => {
472
+ e.localYLabels.forEach((t, o) => {
473
+ R(
474
+ s.value,
475
+ Q(
476
+ a.value.style.chart.dataLabels.formatter,
477
+ t.value,
478
+ ee({
479
+ p: e.prefix || a.value.style.chart.grid.y.axisLabels.prefix || "",
480
+ v: t.value,
481
+ s: e.suffix || a.value.style.chart.grid.y.axisLabels.suffix || "",
482
+ r: e.rounding || a.value.style.chart.grid.y.axisLabels.rounding || 0
483
+ }),
484
+ { datapoint: t, seriesIndex: o }
485
+ ),
486
+ t.x + a.value.style.chart.grid.y.axisLabels.offsetX,
487
+ t.y,
488
+ {
489
+ align: "right",
490
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
491
+ color: e.color,
492
+ globalAlpha: e.showYMarker && ![null, void 0].includes(v.value) ? 0.2 : 1
493
+ }
494
+ );
495
+ });
496
+ }) : m.value.yLabels.forEach((e, t) => {
497
+ R(
498
+ s.value,
499
+ Q(
500
+ a.value.style.chart.dataLabels.formatter,
501
+ e.value,
502
+ ee({
503
+ p: a.value.style.chart.grid.y.axisLabels.prefix || "",
504
+ v: e.value,
505
+ s: a.value.style.chart.grid.y.axisLabels.suffix || "",
506
+ r: a.value.style.chart.grid.y.axisLabels.rounding || 0
507
+ }),
508
+ { datapoint: e, seriesIndex: t }
509
+ ),
510
+ e.x + a.value.style.chart.grid.y.axisLabels.offsetX,
511
+ e.y,
512
+ {
513
+ align: "right",
514
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
515
+ color: a.value.style.chart.grid.y.axisLabels.color,
516
+ globalAlpha: h.value.some((o) => o.showYMarker) && ![null, void 0].includes(v.value) ? 0.2 : 1
517
+ }
518
+ );
519
+ }));
520
+ }
521
+ function Pa(e) {
522
+ for (let t = 0; t < e.coordinatesLine.length; t += 1)
523
+ R(
524
+ s.value,
525
+ Q(
526
+ a.value.style.chart.dataLabels.formatter,
527
+ e.coordinatesLine[t].value,
528
+ ee({
529
+ p: e.prefix || "",
530
+ v: e.coordinatesLine[t].value,
531
+ s: e.suffix || "",
532
+ r: e.rounding || 0
533
+ }),
534
+ { datapoint: e.coordinatesLine[t], seriesIndex: t }
535
+ ),
536
+ e.coordinatesLine[t].x,
537
+ e.coordinatesLine[t].y + a.value.style.chart.dataLabels.offsetY,
538
+ {
539
+ align: "center",
540
+ font: `${a.value.style.chart.dataLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.dataLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
541
+ color: a.value.style.chart.dataLabels.useSerieColor ? e.color : a.value.style.chart.dataLabels.color
542
+ }
543
+ );
544
+ }
545
+ function Ea() {
546
+ for (let e = r.value.start; e < r.value.end; e += 1)
547
+ (r.value.end - r.value.start < a.value.style.chart.grid.y.timeLabels.modulo || r.value.end - r.value.start >= a.value.style.chart.grid.y.timeLabels.modulo && (e % Math.floor((r.value.end - r.value.start) / a.value.style.chart.grid.y.timeLabels.modulo) === 0 || e === v.value + r.value.start && a.value.style.chart.grid.y.timeLabels.showMarker)) && R(
548
+ s.value,
549
+ a.value.style.chart.grid.y.timeLabels.values[e] || e + 1,
550
+ l.value.left + l.value.slot * (e - r.value.start) + l.value.slot / 2,
551
+ l.value.bottom + y.value / a.value.style.chart.grid.y.timeLabels.offsetY,
552
+ {
553
+ align: a.value.style.chart.grid.y.timeLabels.rotation === 0 ? "center" : a.value.style.chart.grid.y.timeLabels.rotation > 0 ? "left" : "right",
554
+ font: `${a.value.style.chart.grid.y.timeLabels.bold ? "bold " : ""}${Math.round(y.value / 40 * a.value.style.chart.grid.y.timeLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
555
+ color: a.value.style.chart.grid.y.timeLabels.showMarker ? ie(a.value.style.chart.grid.y.timeLabels.color, v.value !== null ? v.value + r.value.start === e ? 100 : 20 : 100) : a.value.style.chart.grid.y.timeLabels.color,
556
+ rotation: a.value.style.chart.grid.y.timeLabels.rotation
557
+ }
558
+ );
559
+ }
560
+ function qe() {
561
+ L(
562
+ s.value,
563
+ [
564
+ { x: l.value.left + l.value.slot * v.value + l.value.slot / 2, y: l.value.top },
565
+ { x: l.value.left + l.value.slot * v.value + l.value.slot / 2, y: l.value.bottom }
566
+ ],
567
+ {
568
+ color: a.value.style.chart.selector.color,
569
+ lineDash: a.value.style.chart.selector.dashed ? [8, 8] : [0, 0],
570
+ lineWidth: 2
571
+ }
572
+ );
573
+ }
574
+ function Fa() {
575
+ M.value && L(
576
+ s.value,
577
+ [
578
+ { x: l.value.left, y: M.value },
579
+ { x: l.value.right, y: M.value }
580
+ ],
581
+ {
582
+ color: a.value.style.chart.selector.color,
583
+ lineDash: a.value.style.chart.selector.dashed ? [8, 8] : [0, 0],
584
+ lineWidth: 2
585
+ }
586
+ );
587
+ }
588
+ function Aa() {
589
+ C.value.forEach((e, t) => {
590
+ for (let o = 0; o < e.coordinatesLine.length; o += 1)
591
+ Me(
592
+ s.value,
593
+ [
594
+ {
595
+ x: l.value.left + l.value.slot * o + l.value.slot / 10 + (u.value.stacked ? 0 : l.value.slot / C.value.length * t - (t === 0 ? 0 : l.value.slot / (5 * C.value.length) * t)),
596
+ y: u.value.stacked ? e.localZero : m.value.zero
597
+ },
598
+ {
599
+ x: l.value.left + l.value.slot * o + l.value.slot / 10 + (u.value.stacked ? 0 : l.value.slot / C.value.length * t - (t === 0 ? 0 : l.value.slot / (5 * C.value.length) * t)) + l.value.slot * 0.8 / (u.value.stacked ? 1 : C.value.length),
600
+ y: u.value.stacked ? e.localZero : m.value.zero
601
+ },
602
+ {
603
+ x: l.value.left + l.value.slot * o + l.value.slot / 10 + (u.value.stacked ? 0 : l.value.slot / C.value.length * t - (t === 0 ? 0 : l.value.slot / (5 * C.value.length) * t)) + l.value.slot * 0.8 / (u.value.stacked ? 1 : C.value.length),
604
+ y: e.coordinatesLine[o].y
605
+ },
606
+ {
607
+ x: l.value.left + l.value.slot * o + l.value.slot / 10 + (u.value.stacked ? 0 : l.value.slot / C.value.length * t - (t === 0 ? 0 : l.value.slot / (5 * C.value.length) * t)),
608
+ y: e.coordinatesLine[o].y
609
+ }
610
+ ],
611
+ {
612
+ strokeColor: a.value.style.chart.backgroundColor,
613
+ gradient: {
614
+ type: "linear",
615
+ start: {
616
+ x: e.coordinatesLine[o].x,
617
+ y: e.coordinatesLine[o].y
618
+ },
619
+ end: {
620
+ x: e.coordinatesLine[o].x,
621
+ y: u.value.stacked ? e.localZero : m.value.zero
622
+ },
623
+ stops: [
624
+ { offset: 0, color: e.color },
625
+ { offset: 1, color: a.value.style.chart.bar.gradient.show ? il(e.color, 0.5) : e.color }
626
+ ]
627
+ }
628
+ }
629
+ ), u.value.showDataLabels && [!0, void 0].includes(e.dataLabels) && R(
630
+ s.value,
631
+ Q(
632
+ a.value.style.chart.dataLabels.formatter,
633
+ e.coordinatesLine[o].value,
634
+ ee({
635
+ p: e.prefix || "",
636
+ v: e.coordinatesLine[o].value,
637
+ s: e.suffix || "",
638
+ r: e.rounding || 0
639
+ }),
640
+ { datapoint: e.coordinatesLine[o], seriesIndex: o }
641
+ ),
642
+ l.value.left + l.value.slot * o + l.value.slot / 10 + (u.value.stacked ? 0 : l.value.slot / C.value.length * t - (t === 0 ? 0 : l.value.slot / (5 * C.value.length) * t)) + l.value.slot * 0.4 / (u.value.stacked ? 1 : C.value.length),
643
+ (e.coordinatesLine[o].value < 0 ? u.value.stacked ? e.localZero : m.value.zero : e.coordinatesLine[o].y) + a.value.style.chart.dataLabels.offsetY,
644
+ {
645
+ align: "center",
646
+ font: `${Math.round(y.value / 40 * a.value.style.chart.dataLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
647
+ color: a.value.style.chart.dataLabels.useSerieColor ? e.color : a.value.style.chart.dataLabels.color,
648
+ strokeColor: a.value.style.chart.backgroundColor,
649
+ lineWidth: 0.8
650
+ }
651
+ );
652
+ });
653
+ }
654
+ function Da(e) {
655
+ e.useArea ? u.value.stacked ? va(
656
+ s.value,
657
+ [{ x: e.coordinatesLine[0].x, y: e.localZero }, ...e.coordinatesLine, { x: e.coordinatesLine.at(-1).x, y: e.localZero }],
658
+ {
659
+ fillColor: ie(e.color, a.value.style.chart.area.opacity),
660
+ strokeColor: "transparent"
661
+ }
662
+ ) : va(
663
+ s.value,
664
+ [{ x: e.coordinatesLine[0].x, y: m.value.zero }, ...e.coordinatesLine, { x: e.coordinatesLine.at(-1).x, y: m.value.zero }],
665
+ {
666
+ fillColor: ie(e.color, a.value.style.chart.area.opacity),
667
+ strokeColor: "transparent"
668
+ }
669
+ ) : L(s.value, e.coordinatesLine, {
670
+ color: e.color,
671
+ lineWidth: 3
672
+ });
673
+ }
674
+ function Ha() {
675
+ h.value.forEach((e, t) => {
676
+ L(
677
+ s.value,
678
+ [
679
+ { x: l.value.left, y: l.value.bottom - e.yOffset },
680
+ { x: l.value.right, y: l.value.bottom - e.yOffset }
681
+ ],
682
+ {
683
+ color: a.value.style.chart.grid.x.horizontalLines.color,
684
+ lineWidth: 1
685
+ }
686
+ );
687
+ });
688
+ }
689
+ function te() {
690
+ Ma(), H.value ? (v.value !== null && a.value.style.chart.selector.show && qe(), Aa(), u.value.stacked && a.value.style.chart.grid.x.showAxis && Ha(), $a.value.forEach((e) => {
691
+ (e.type === "line" || !e.type) && Da(e), V.value && (Ta(e), u.value.showDataLabels && [!0, void 0].includes(e.dataLabels) && Pa(e));
692
+ }), be.value = hl(T.value)) : (be.value && (s.value.clearRect(0, 0, 1e4, 1e4), s.value.drawImage(be.value, 0, 0)), v.value !== null && a.value.style.chart.selector.show && qe(), v.value !== null && h.value.forEach((e) => {
693
+ if (e.type === "line" || !e.type || e.type === "plot") {
694
+ if (!e.coordinatesLine[v.value]) return;
695
+ e.coordinatesLine[v.value].x !== void 0 && e.coordinatesLine[v.value].y !== void 0 && ia(
696
+ s.value,
697
+ {
698
+ x: e.coordinatesLine[v.value].x,
699
+ y: e.coordinatesLine[v.value].y
700
+ },
701
+ y.value / 150 * a.value.style.chart.line.plots.radiusRatio,
702
+ {
703
+ color: a.value.style.chart.backgroundColor,
704
+ fillStyle: e.color
705
+ }
706
+ );
707
+ }
708
+ })), a.value.style.chart.grid.y.timeLabels.show && Ea(), a.value.style.chart.selector.show && a.value.style.chart.selector.showHorizontalSelector && Fa(), Ra(), Oa(), H.value = !1;
709
+ }
710
+ const he = vl(() => {
711
+ V.value = !0, Ia();
712
+ }, I.value > 200 ? 10 : 1, !V.value);
713
+ function oe(e) {
714
+ if ([null, void 0].includes(v.value) || !e.coordinatesLine[v.value]) return !1;
715
+ const { y: t, value: o } = e.coordinatesLine[v.value];
716
+ return { y: t, value: o };
717
+ }
718
+ function Na(e) {
719
+ const { left: t, top: o } = T.value.getBoundingClientRect(), n = e.clientX - t;
720
+ if (M.value = (e.clientY - o) * 2, (M.value < l.value.top || M.value > l.value.bottom) && (M.value = null), n * 2 < l.value.left || n * 2 > l.value.right) {
721
+ ve.value = !1, v.value = null;
722
+ return;
723
+ }
724
+ const c = n * 2 - l.value.left;
725
+ if (v.value = Math.floor(c / l.value.slot), ve.value = !0, !V.value) return;
726
+ let w = "";
727
+ const i = a.value.style.chart.tooltip.customFormat;
728
+ na(i) && nl(() => i({
729
+ seriesIndex: v.value,
730
+ datapoint: h.value.map((f) => ({
731
+ shape: f.shape || null,
732
+ name: f.name,
733
+ color: f.color,
734
+ type: f.type || "line",
735
+ value: f.series.find((N, S) => S === v.value)
736
+ })),
737
+ series: h.value,
738
+ config: a.value
739
+ })) ? ce.value = i({
740
+ seriesIndex: v.value,
741
+ datapoint: h.value.map((f) => ({
742
+ shape: f.shape || null,
743
+ name: f.name,
744
+ color: f.color,
745
+ type: f.type || "line",
746
+ value: f.series.find((N, S) => S === v.value)
747
+ })),
748
+ series: h.value,
749
+ config: a.value
750
+ }) : (a.value.style.chart.grid.y.timeLabels.values.slice(r.value.start, r.value.end)[v.value] && (w += `<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${a.value.style.chart.tooltip.borderColor}; width:100%">${a.value.style.chart.grid.y.timeLabels.values.slice(r.value.start, r.value.end)[v.value]}</div>`), w += za.value.join(""), ce.value = w), V.value = !1;
751
+ }
752
+ A(() => v.value, (e) => {
753
+ he();
754
+ }), A(() => r.value, (e) => {
755
+ H.value = !0, te();
756
+ }, {
757
+ deep: !0
758
+ }), A(() => u.value.showDataLabels, (e) => {
759
+ H.value = !0, te();
760
+ }), A(() => M.value, (e) => {
761
+ e && te();
762
+ }), A(() => u.value.stacked, (e) => {
763
+ H.value = !0, V.value = !0, he();
764
+ });
765
+ function Ya() {
766
+ ve.value = !1, v.value = null, ce.value = "", M.value = null, te();
767
+ }
768
+ const E = $e(null), j = $e(null), q = $e(null);
769
+ ra(() => {
770
+ ze();
771
+ });
772
+ function ze() {
773
+ if (ol(g.dataset) ? rl({
774
+ componentName: "VueUiXyCanvas",
775
+ type: "dataset"
776
+ }) : T.value && (s.value = T.value.getContext("2d", { willReadFrequently: !0 })), a.value.responsive) {
777
+ const e = cl(() => {
778
+ const { width: t, height: o } = dl({
779
+ chart: ae.value,
780
+ title: a.value.style.chart.title.text ? Ee.value : null,
781
+ legend: a.value.style.chart.legend.show ? Fe.value : null,
782
+ slicer: a.value.style.chart.zoom.show && I.value > 1 ? Ae.value : null,
783
+ source: De.value
784
+ });
785
+ requestAnimationFrame(() => {
786
+ Ue.value = `${t} / ${o}`;
787
+ });
788
+ });
789
+ E.value && (j.value && E.value.unobserve(j.value), E.value.disconnect()), E.value = new ResizeObserver(e), j.value = ae.value.parentNode, E.value.observe(j.value);
790
+ }
791
+ q.value && q.value.disconnect(), q.value = new ResizeObserver((e) => {
792
+ for (const t of e)
793
+ t.contentBoxSize && le.value && (H.value = !0, he());
794
+ }), q.value.observe(le.value), je();
795
+ }
796
+ Ba(() => {
797
+ q.value && q.value.disconnect(), E.value && (j.value && E.value.unobserve(j.value), E.value.disconnect());
798
+ });
799
+ function Je(e) {
800
+ La("selectLegend", h.value.find((t) => t.absoluteIndex === e)), $.value.includes(e) ? $.value = $.value.filter((t) => t !== e) : $.value.push(e), H.value = !0, he();
801
+ }
802
+ const Ke = k(() => Z.value.map((e, t) => ({
803
+ ...e,
804
+ name: e.name,
805
+ color: sa(e.color) || Ve.value[t] || _[t] || _[t % _.length],
806
+ shape: e.shape || "circle",
807
+ prefix: e.prefix || "",
808
+ suffix: e.suffix || "",
809
+ rounding: e.rounding || 0
810
+ })).map((e) => ({
811
+ ...e,
812
+ opacity: $.value.includes(e.absoluteIndex) ? 0.5 : 1,
813
+ segregate: () => Je(e.absoluteIndex),
814
+ isSegregated: $.value.includes(e.absoluteIndex)
815
+ }))), Ua = k(() => ({
816
+ cy: "donut-div-legend",
817
+ backgroundColor: a.value.style.chart.legend.backgroundColor,
818
+ color: a.value.style.chart.legend.color,
819
+ fontSize: a.value.style.chart.legend.fontSize,
820
+ paddingBottom: 12,
821
+ fontWeight: a.value.style.chart.legend.bold ? "bold" : ""
822
+ })), ye = k(() => {
823
+ const e = [""].concat(h.value.map((c) => c.name)).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>');
824
+ let t = [];
825
+ for (let c = 0; c < I.value; c += 1) {
826
+ const w = h.value.map((i) => i.series[c] ?? 0).reduce((i, f) => i + f, 0);
827
+ t.push([a.value.style.chart.grid.y.timeLabels.values.slice(r.value.start, r.value.end)[c] ?? c + 1].concat(h.value.map((i) => (i.series[c] ?? 0).toFixed(a.value.table.rounding))).concat((w ?? 0).toFixed(a.value.table.rounding)));
828
+ }
829
+ const o = {
830
+ th: {
831
+ backgroundColor: a.value.table.th.backgroundColor,
832
+ color: a.value.table.th.color,
833
+ outline: a.value.table.th.outline
834
+ },
835
+ td: {
836
+ backgroundColor: a.value.table.td.backgroundColor,
837
+ color: a.value.table.td.color,
838
+ outline: a.value.table.td.outline
839
+ },
840
+ breakpoint: a.value.table.responsiveBreakpoint
841
+ }, n = [a.value.table.columnNames.period].concat(h.value.map((c) => c.name)).concat(a.value.table.columnNames.total);
842
+ return { head: e, body: t.slice(0, r.value.end - r.value.start), config: o, colNames: n };
843
+ }), Qe = k(() => {
844
+ if (h.value.length === 0) return { head: [], body: [], config: {}, columnNames: [] };
845
+ const e = h.value.map((o) => ({
846
+ label: o.name,
847
+ color: o.color,
848
+ type: o.type
849
+ })), t = [];
850
+ for (let o = r.value.start; o < r.value.end; o += 1) {
851
+ const n = [a.value.style.chart.grid.y.timeLabels.values[o] || o + 1];
852
+ h.value.forEach((c) => {
853
+ n.push(Number((c.series[o] || 0).toFixed(a.value.table.rounding)));
854
+ }), t.push(n);
855
+ }
856
+ return { head: e, body: t };
857
+ });
858
+ function ea() {
859
+ const e = [[a.value.style.chart.title.text], [a.value.style.chart.title.subtitle.text], [""]], t = ["", ...Qe.value.head.map((w) => w.label)], o = Qe.value.body, n = e.concat([t]).concat(o), c = ul(n);
860
+ sl({ csvContent: c, title: a.value.style.chart.title.text || "vue-ui-xy-canvas" });
861
+ }
862
+ function Wa() {
863
+ return h.value;
864
+ }
865
+ function aa() {
866
+ u.value.showTable = !u.value.showTable;
867
+ }
868
+ function la() {
869
+ u.value.showDataLabels = !u.value.showDataLabels;
870
+ }
871
+ function ta() {
872
+ u.value.stacked = !u.value.stacked;
873
+ }
874
+ function oa() {
875
+ u.value.showTooltip = !u.value.showTooltip;
876
+ }
877
+ const fe = d(!1);
878
+ function Se() {
879
+ fe.value = !fe.value;
880
+ }
881
+ return da({
882
+ getData: Wa,
883
+ generateCsv: ea,
884
+ generatePdf: _e,
885
+ generateImage: Be,
886
+ toggleTable: aa,
887
+ toggleLabels: la,
888
+ toggleStack: ta,
889
+ toggleTooltip: oa,
890
+ toggleAnnotator: Se
891
+ }), (e, t) => (z(), se("div", {
892
+ style: K(`width:100%; position:relative; ${a.value.responsive ? "height: 100%" : ""}`),
893
+ ref_key: "xy",
894
+ ref: ae,
895
+ id: `xy_canvas_${me.value}`,
896
+ class: Va(`vue-ui-donut ${de.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
897
+ onMouseenter: t[5] || (t[5] = () => p(He)(!0)),
898
+ onMouseleave: t[6] || (t[6] = () => p(He)(!1))
899
+ }, [
900
+ a.value.style.chart.title.text ? (z(), se("div", {
901
+ key: 0,
902
+ ref_key: "chartTitle",
903
+ ref: Ee,
904
+ style: K(`width:100%;background:${a.value.style.chart.backgroundColor};`)
905
+ }, [
906
+ (z(), D(ml, {
907
+ key: `title_${xe.value}`,
908
+ config: {
909
+ title: {
910
+ cy: "xy-canvas-title",
911
+ ...a.value.style.chart.title
912
+ },
913
+ subtitle: {
914
+ cy: "xy-canvas-subtitle",
915
+ ...a.value.style.chart.title.subtitle
916
+ }
917
+ }
918
+ }, null, 8, ["config"]))
919
+ ], 4)) : U("", !0),
920
+ a.value.userOptions.show && Ce.value && (p(Ne) || p(we)) ? (z(), D(p(ba), {
921
+ ref: "details",
922
+ key: `user_option_${Pe.value}`,
923
+ backgroundColor: a.value.style.chart.backgroundColor,
924
+ color: a.value.style.chart.color,
925
+ isPrinting: p(We),
926
+ isImaging: p(Xe),
927
+ uid: me.value,
928
+ hasTooltip: a.value.userOptions.buttons.tooltip && a.value.style.chart.tooltip.show,
929
+ hasPdf: a.value.userOptions.buttons.pdf,
930
+ hasImg: a.value.userOptions.buttons.img,
931
+ hasXls: a.value.userOptions.buttons.csv,
932
+ hasLabel: a.value.userOptions.buttons.labels,
933
+ hasStack: Te.dataset.length > 1 && a.value.userOptions.buttons.stack,
934
+ hasFullscreen: a.value.userOptions.buttons.fullscreen,
935
+ hasTable: r.value.end - r.value.start < 200 && a.value.userOptions.buttons.table,
936
+ isFullscreen: de.value,
937
+ isTooltip: u.value.showTooltip,
938
+ isStacked: u.value.stacked,
939
+ titles: { ...a.value.userOptions.buttonTitles },
940
+ chartElement: ae.value,
941
+ position: a.value.userOptions.position,
942
+ hasAnnotator: a.value.userOptions.buttons.annotator,
943
+ isAnnotation: fe.value,
944
+ onToggleFullscreen: Ca,
945
+ onGeneratePdf: p(_e),
946
+ onGenerateCsv: ea,
947
+ onGenerateImage: p(Be),
948
+ onToggleTable: aa,
949
+ onToggleLabels: la,
950
+ onToggleStack: ta,
951
+ onToggleTooltip: oa,
952
+ onToggleAnnotator: Se,
953
+ style: K({
954
+ visibility: p(Ne) ? p(we) ? "visible" : "hidden" : "visible"
955
+ })
956
+ }, Za({ _: 2 }, [
957
+ e.$slots.menuIcon ? {
958
+ name: "menuIcon",
959
+ fn: b(({ isOpen: o, color: n }) => [
960
+ x(e.$slots, "menuIcon", W(X({ isOpen: o, color: n })), void 0, !0)
961
+ ]),
962
+ key: "0"
963
+ } : void 0,
964
+ e.$slots.optionTooltip ? {
965
+ name: "optionTooltip",
966
+ fn: b(() => [
967
+ x(e.$slots, "optionTooltip", {}, void 0, !0)
968
+ ]),
969
+ key: "1"
970
+ } : void 0,
971
+ e.$slots.optionPdf ? {
972
+ name: "optionPdf",
973
+ fn: b(() => [
974
+ x(e.$slots, "optionPdf", {}, void 0, !0)
975
+ ]),
976
+ key: "2"
977
+ } : void 0,
978
+ e.$slots.optionCsv ? {
979
+ name: "optionCsv",
980
+ fn: b(() => [
981
+ x(e.$slots, "optionCsv", {}, void 0, !0)
982
+ ]),
983
+ key: "3"
984
+ } : void 0,
985
+ e.$slots.optionImg ? {
986
+ name: "optionImg",
987
+ fn: b(() => [
988
+ x(e.$slots, "optionImg", {}, void 0, !0)
989
+ ]),
990
+ key: "4"
991
+ } : void 0,
992
+ e.$slots.optionTable ? {
993
+ name: "optionTable",
994
+ fn: b(() => [
995
+ x(e.$slots, "optionTable", {}, void 0, !0)
996
+ ]),
997
+ key: "5"
998
+ } : void 0,
999
+ e.$slots.optionLabels ? {
1000
+ name: "optionLabels",
1001
+ fn: b(() => [
1002
+ x(e.$slots, "optionLabels", {}, void 0, !0)
1003
+ ]),
1004
+ key: "6"
1005
+ } : void 0,
1006
+ e.$slots.optionStack ? {
1007
+ name: "optionStack",
1008
+ fn: b(() => [
1009
+ x(e.$slots, "optionStack", {}, void 0, !0)
1010
+ ]),
1011
+ key: "7"
1012
+ } : void 0,
1013
+ e.$slots.optionFullscreen ? {
1014
+ name: "optionFullscreen",
1015
+ fn: b(({ toggleFullscreen: o, isFullscreen: n }) => [
1016
+ x(e.$slots, "optionFullscreen", W(X({ toggleFullscreen: o, isFullscreen: n })), void 0, !0)
1017
+ ]),
1018
+ key: "8"
1019
+ } : void 0,
1020
+ e.$slots.optionAnnotator ? {
1021
+ name: "optionAnnotator",
1022
+ fn: b(({ toggleAnnotator: o, isAnnotator: n }) => [
1023
+ x(e.$slots, "optionAnnotator", W(X({ toggleAnnotator: o, isAnnotator: n })), void 0, !0)
1024
+ ]),
1025
+ key: "9"
1026
+ } : void 0
1027
+ ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasLabel", "hasStack", "hasFullscreen", "hasTable", "isFullscreen", "isTooltip", "isStacked", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "onGeneratePdf", "onGenerateImage", "style"])) : U("", !0),
1028
+ ne("div", {
1029
+ class: "vue-ui-xy-canvas",
1030
+ style: K(`position: relative; aspect-ratio: ${Ue.value}`),
1031
+ ref_key: "container",
1032
+ ref: le
1033
+ }, [
1034
+ Ce.value ? (z(), se("canvas", {
1035
+ key: 0,
1036
+ ref_key: "canvas",
1037
+ ref: T,
1038
+ style: { width: "100%", height: "100%" },
1039
+ onMousemove: t[0] || (t[0] = (o) => Na(o)),
1040
+ onMouseleave: Ya
1041
+ }, null, 544)) : (z(), D(p(pa), {
1042
+ key: 1,
1043
+ config: {
1044
+ type: "line",
1045
+ style: {
1046
+ backgroundColor: a.value.style.chart.backgroundColor,
1047
+ line: {
1048
+ axis: {
1049
+ color: "#CCCCCC"
1050
+ },
1051
+ path: {
1052
+ color: "#CCCCCC",
1053
+ strokeWidth: 0.5
1054
+ }
1055
+ }
1056
+ }
1057
+ }
1058
+ }, null, 8, ["config"])),
1059
+ Ga(p(ma), {
1060
+ show: u.value.showTooltip && ve.value,
1061
+ backgroundColor: a.value.style.chart.tooltip.backgroundColor,
1062
+ color: a.value.style.chart.tooltip.color,
1063
+ fontSize: a.value.style.chart.tooltip.fontSize,
1064
+ borderRadius: a.value.style.chart.tooltip.borderRadius,
1065
+ borderColor: a.value.style.chart.tooltip.borderColor,
1066
+ borderWidth: a.value.style.chart.tooltip.borderWidth,
1067
+ position: a.value.style.chart.tooltip.position,
1068
+ offsetY: a.value.style.chart.tooltip.offsetY,
1069
+ parent: p(T),
1070
+ content: ce.value,
1071
+ isFullscreen: de.value,
1072
+ backgroundOpacity: a.value.style.chart.tooltip.backgroundOpacity,
1073
+ isCustom: p(na)(a.value.style.chart.tooltip.customFormat)
1074
+ }, {
1075
+ "tooltip-before": b(() => [
1076
+ x(e.$slots, "tooltip-before", W(X({ ...Oe.value })), void 0, !0)
1077
+ ]),
1078
+ "tooltip-after": b(() => [
1079
+ x(e.$slots, "tooltip-after", W(X({ ...Oe.value })), void 0, !0)
1080
+ ]),
1081
+ _: 3
1082
+ }, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "position", "offsetY", "parent", "content", "isFullscreen", "backgroundOpacity", "isCustom"])
1083
+ ], 4),
1084
+ ne("div", {
1085
+ ref_key: "chartSlicer",
1086
+ ref: Ae,
1087
+ style: K(`width:100%;background:${a.value.style.chart.backgroundColor}`),
1088
+ "data-dom-to-png-ignore": ""
1089
+ }, [
1090
+ a.value.style.chart.zoom.show && I.value > 1 ? (z(), D(bl, {
1091
+ ref_key: "slicerComponent",
1092
+ ref: G,
1093
+ key: `slicer_${Re.value}`,
1094
+ background: a.value.style.chart.zoom.color,
1095
+ borderColor: a.value.style.chart.backgroundColor,
1096
+ fontSize: a.value.style.chart.zoom.fontSize,
1097
+ useResetSlot: a.value.style.chart.zoom.useResetSlot,
1098
+ labelLeft: a.value.style.chart.grid.y.timeLabels.values[r.value.start] ? a.value.style.chart.grid.y.timeLabels.values[r.value.start] : "",
1099
+ labelRight: a.value.style.chart.grid.y.timeLabels.values[r.value.end - 1] ? a.value.style.chart.grid.y.timeLabels.values[r.value.end - 1] : "",
1100
+ textColor: a.value.style.chart.color,
1101
+ inputColor: a.value.style.chart.zoom.color,
1102
+ selectColor: a.value.style.chart.zoom.highlightColor,
1103
+ max: I.value,
1104
+ min: 0,
1105
+ valueStart: r.value.start,
1106
+ valueEnd: r.value.end,
1107
+ start: r.value.start,
1108
+ "onUpdate:start": t[1] || (t[1] = (o) => r.value.start = o),
1109
+ end: r.value.end,
1110
+ "onUpdate:end": t[2] || (t[2] = (o) => r.value.end = o),
1111
+ refreshStartPoint: a.value.style.chart.zoom.startIndex !== null ? a.value.style.chart.zoom.startIndex : 0,
1112
+ refreshEndPoint: a.value.style.chart.zoom.endIndex !== null ? a.value.style.chart.zoom.endIndex + 1 : I.value,
1113
+ enableRangeHandles: a.value.style.chart.zoom.enableRangeHandles,
1114
+ enableSelectionDrag: a.value.style.chart.zoom.enableSelectionDrag,
1115
+ onReset: Ge
1116
+ }, {
1117
+ "reset-action": b(({ reset: o }) => [
1118
+ x(e.$slots, "reset-action", W(X({ reset: o })), void 0, !0)
1119
+ ]),
1120
+ _: 3
1121
+ }, 8, ["background", "borderColor", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "max", "valueStart", "valueEnd", "start", "end", "refreshStartPoint", "refreshEndPoint", "enableRangeHandles", "enableSelectionDrag"])) : U("", !0)
1122
+ ], 4),
1123
+ ne("div", {
1124
+ ref_key: "chartLegend",
1125
+ ref: Fe
1126
+ }, [
1127
+ a.value.style.chart.legend.show && Ce.value ? (z(), D(pl, {
1128
+ legendSet: Ke.value,
1129
+ config: Ua.value,
1130
+ key: `legend_${ke.value}`,
1131
+ onClickMarker: t[3] || (t[3] = ({ i: o }) => Je(o))
1132
+ }, {
1133
+ item: b(({ legend: o, index: n }) => [
1134
+ ne("div", {
1135
+ onClick: (c) => o.segregate(),
1136
+ style: K(`opacity:${$.value.includes(n) ? 0.5 : 1}`)
1137
+ }, ua(o.name), 13, kl)
1138
+ ]),
1139
+ _: 1
1140
+ }, 8, ["legendSet", "config"])) : x(e.$slots, "legend", {
1141
+ key: 1,
1142
+ legend: Ke.value
1143
+ }, void 0, !0)
1144
+ ], 512),
1145
+ e.$slots.watermark ? (z(), se("div", Cl, [
1146
+ x(e.$slots, "watermark", W(X({ isPrinting: p(We) || p(Xe) })), void 0, !0)
1147
+ ])) : U("", !0),
1148
+ e.$slots.source ? (z(), se("div", {
1149
+ key: 3,
1150
+ ref_key: "source",
1151
+ ref: De,
1152
+ dir: "auto"
1153
+ }, [
1154
+ x(e.$slots, "source", {}, void 0, !0)
1155
+ ], 512)) : U("", !0),
1156
+ r.value.end - r.value.start < 200 ? (z(), D(p(ya), {
1157
+ key: 4,
1158
+ hideDetails: "",
1159
+ config: {
1160
+ open: u.value.showTable,
1161
+ maxHeight: 1e4,
1162
+ body: {
1163
+ backgroundColor: a.value.style.chart.backgroundColor,
1164
+ color: a.value.style.chart.color
1165
+ },
1166
+ head: {
1167
+ backgroundColor: a.value.style.chart.backgroundColor,
1168
+ color: a.value.style.chart.color
1169
+ }
1170
+ }
1171
+ }, {
1172
+ content: b(() => [
1173
+ (z(), D(p(fa), {
1174
+ key: `table_${Le.value}`,
1175
+ colNames: ye.value.colNames,
1176
+ head: ye.value.head,
1177
+ body: ye.value.body,
1178
+ config: ye.value.config,
1179
+ title: `${a.value.style.chart.title.text}${a.value.style.chart.title.subtitle.text ? ` : ${a.value.style.chart.title.subtitle.text}` : ""}`,
1180
+ onClose: t[4] || (t[4] = (o) => u.value.showTable = !1)
1181
+ }, {
1182
+ th: b(({ th: o }) => [
1183
+ ne("div", { innerHTML: o }, null, 8, wl)
1184
+ ]),
1185
+ td: b(({ td: o }) => [
1186
+ ja(ua(o), 1)
1187
+ ]),
1188
+ _: 1
1189
+ }, 8, ["colNames", "head", "body", "config", "title"]))
1190
+ ]),
1191
+ _: 1
1192
+ }, 8, ["config"])) : U("", !0),
1193
+ a.value.userOptions.buttons.annotator && h.value.length ? (z(), D(p(ga), {
1194
+ key: 5,
1195
+ parent: ae.value,
1196
+ backgroundColor: a.value.style.chart.backgroundColor,
1197
+ color: a.value.style.chart.color,
1198
+ active: fe.value,
1199
+ onClose: Se
1200
+ }, null, 8, ["parent", "backgroundColor", "color", "active"])) : U("", !0)
1201
+ ], 46, Ll));
1202
+ }
1203
+ }, Dl = /* @__PURE__ */ xl(zl, [["__scopeId", "data-v-557b6e93"]]);
1204
+ export {
1205
+ Dl as default
1206
+ };