vue-data-ui 3.2.5 → 3.2.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 (135) hide show
  1. package/dist/{PackageVersion-CPxZT-xH.js → PackageVersion-Cwrh45ON.js} +1 -1
  2. package/dist/{Title-B3UTqrqj.js → Title-DG2nloSB.js} +1 -1
  3. package/dist/components/vue-ui-3d-bar.js +1 -1
  4. package/dist/components/vue-ui-accordion.js +1 -1
  5. package/dist/components/vue-ui-age-pyramid.js +1 -1
  6. package/dist/components/vue-ui-annotator.js +1 -1
  7. package/dist/components/vue-ui-bullet.js +1 -1
  8. package/dist/components/vue-ui-candlestick.js +1 -1
  9. package/dist/components/vue-ui-carousel-table.js +1 -1
  10. package/dist/components/vue-ui-chestnut.js +1 -1
  11. package/dist/components/vue-ui-chord.js +1 -1
  12. package/dist/components/vue-ui-circle-pack.js +1 -1
  13. package/dist/components/vue-ui-cursor.js +1 -1
  14. package/dist/components/vue-ui-dashboard.js +1 -1
  15. package/dist/components/vue-ui-digits.js +1 -1
  16. package/dist/components/vue-ui-donut-evolution.js +1 -1
  17. package/dist/components/vue-ui-donut.js +1 -1
  18. package/dist/components/vue-ui-dumbbell.js +1 -1
  19. package/dist/components/vue-ui-flow.js +1 -1
  20. package/dist/components/vue-ui-funnel.js +1 -1
  21. package/dist/components/vue-ui-galaxy.js +1 -1
  22. package/dist/components/vue-ui-gauge.js +1 -1
  23. package/dist/components/vue-ui-gizmo.js +1 -1
  24. package/dist/components/vue-ui-heatmap.js +1 -1
  25. package/dist/components/vue-ui-history-plot.js +1 -1
  26. package/dist/components/vue-ui-horizontal-bar.js +1 -1
  27. package/dist/components/vue-ui-kpi.js +1 -1
  28. package/dist/components/vue-ui-mini-loader.js +1 -1
  29. package/dist/components/vue-ui-molecule.js +1 -1
  30. package/dist/components/vue-ui-mood-radar.js +1 -1
  31. package/dist/components/vue-ui-nested-donuts.js +1 -1
  32. package/dist/components/vue-ui-onion.js +1 -1
  33. package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
  34. package/dist/components/vue-ui-quadrant.js +1 -1
  35. package/dist/components/vue-ui-quick-chart.js +1 -1
  36. package/dist/components/vue-ui-radar.js +1 -1
  37. package/dist/components/vue-ui-rating.js +1 -1
  38. package/dist/components/vue-ui-relation-circle.js +1 -1
  39. package/dist/components/vue-ui-ridgeline.js +1 -1
  40. package/dist/components/vue-ui-rings.js +1 -1
  41. package/dist/components/vue-ui-scatter.js +1 -1
  42. package/dist/components/vue-ui-skeleton.js +1 -1
  43. package/dist/components/vue-ui-smiley.js +1 -1
  44. package/dist/components/vue-ui-spark-trend.js +1 -1
  45. package/dist/components/vue-ui-sparkbar.js +1 -1
  46. package/dist/components/vue-ui-sparkgauge.js +1 -1
  47. package/dist/components/vue-ui-sparkhistogram.js +1 -1
  48. package/dist/components/vue-ui-sparkline.js +1 -1
  49. package/dist/components/vue-ui-sparkstackbar.js +1 -1
  50. package/dist/components/vue-ui-stackbar.js +1 -1
  51. package/dist/components/vue-ui-strip-plot.js +1 -1
  52. package/dist/components/vue-ui-table-heatmap.js +1 -1
  53. package/dist/components/vue-ui-table-sparkline.js +1 -1
  54. package/dist/components/vue-ui-table.js +1 -1
  55. package/dist/components/vue-ui-thermometer.js +1 -1
  56. package/dist/components/vue-ui-timer.js +1 -1
  57. package/dist/components/vue-ui-tiremarks.js +1 -1
  58. package/dist/components/vue-ui-treemap.js +1 -1
  59. package/dist/components/vue-ui-vertical-bar.js +1 -1
  60. package/dist/components/vue-ui-waffle.js +1 -1
  61. package/dist/components/vue-ui-wheel.js +1 -1
  62. package/dist/components/vue-ui-word-cloud.js +1 -1
  63. package/dist/components/vue-ui-world.js +1 -1
  64. package/dist/components/vue-ui-xy-canvas.js +1 -1
  65. package/dist/components/vue-ui-xy.js +1 -1
  66. package/dist/style.css +1 -1
  67. package/dist/{themes-D3cUNuKw.js → themes-Dw-dDudK.js} +1 -1
  68. package/dist/types/vue-data-ui.d.ts +39 -1
  69. package/dist/{useNestedProp-B9OeNO-E.js → useNestedProp-BOk-tPdu.js} +157 -121
  70. package/dist/{vue-data-ui-C-XpoSih.js → vue-data-ui-DH8opsJv.js} +63 -63
  71. package/dist/vue-data-ui.js +65 -65
  72. package/dist/{vue-ui-3d-bar-DOecLYLE.js → vue-ui-3d-bar-CRXnB8wH.js} +4 -4
  73. package/dist/{vue-ui-accordion-DrKVXpRB.js → vue-ui-accordion-CeMTgpl0.js} +9 -9
  74. package/dist/{vue-ui-age-pyramid-C0-TsZiO.js → vue-ui-age-pyramid-BEGsngR6.js} +4 -4
  75. package/dist/{vue-ui-annotator-GYJPPkqk.js → vue-ui-annotator-BhZr9pFJ.js} +2 -2
  76. package/dist/{vue-ui-bullet-D8BTxLsh.js → vue-ui-bullet-CrCHb15S.js} +4 -4
  77. package/dist/{vue-ui-candlestick-C8EKzgk8.js → vue-ui-candlestick-CnWY88nd.js} +4 -4
  78. package/dist/{vue-ui-carousel-table-DWDAT9Bv.js → vue-ui-carousel-table-CsVWXrdA.js} +2 -2
  79. package/dist/{vue-ui-chestnut-moaiX3ch.js → vue-ui-chestnut-NpO91zJV.js} +3 -3
  80. package/dist/{vue-ui-chord-BV_o4nlt.js → vue-ui-chord-bIihB6Qf.js} +4 -4
  81. package/dist/{vue-ui-circle-pack-CGZzZeiw.js → vue-ui-circle-pack-Z5VTiXZU.js} +4 -4
  82. package/dist/{vue-ui-cursor-DPpffCgE.js → vue-ui-cursor-Detis-4Y.js} +1 -1
  83. package/dist/{vue-ui-dashboard-elD5LDyG.js → vue-ui-dashboard-BEJ5uSZV.js} +63 -63
  84. package/dist/{vue-ui-digits-D3ajh8NJ.js → vue-ui-digits-CDtdGqLS.js} +1 -1
  85. package/dist/{vue-ui-donut-fadiDQvI.js → vue-ui-donut-a82yzfvT.js} +4 -4
  86. package/dist/{vue-ui-donut-evolution-BtoygMFS.js → vue-ui-donut-evolution-DP_dXmIC.js} +4 -4
  87. package/dist/{vue-ui-dumbbell-DHCYzyJz.js → vue-ui-dumbbell-BDIzPnlX.js} +4 -4
  88. package/dist/{vue-ui-flow-D4ylW0W1.js → vue-ui-flow-B72CBzC3.js} +4 -4
  89. package/dist/{vue-ui-funnel-MoRuRQaq.js → vue-ui-funnel-CaxHiJIB.js} +4 -4
  90. package/dist/{vue-ui-galaxy-C7AvuJir.js → vue-ui-galaxy-CbGRAAFI.js} +4 -4
  91. package/dist/{vue-ui-gauge-D0R9gL9E.js → vue-ui-gauge-But_1QwV.js} +4 -4
  92. package/dist/{vue-ui-gizmo-BFyI_9mt.js → vue-ui-gizmo-DcBQp-C8.js} +2 -2
  93. package/dist/{vue-ui-heatmap-Dte8MPCp.js → vue-ui-heatmap-BAVkwnbX.js} +5 -5
  94. package/dist/{vue-ui-history-plot-6dD96OTH.js → vue-ui-history-plot-BlVib573.js} +4 -4
  95. package/dist/{vue-ui-kpi-BAwj45_1.js → vue-ui-kpi-DuFgWXJM.js} +2 -2
  96. package/dist/{vue-ui-mini-loader-D6fOQZX6.js → vue-ui-mini-loader-D4W9oE3V.js} +1 -1
  97. package/dist/{vue-ui-molecule-B5SmQ6k6.js → vue-ui-molecule-CEb6_0wR.js} +3 -3
  98. package/dist/{vue-ui-mood-radar-C7OVR2P_.js → vue-ui-mood-radar-CqJPicZv.js} +4 -4
  99. package/dist/{vue-ui-nested-donuts-BGX4yvnh.js → vue-ui-nested-donuts-B6rmNl9X.js} +4 -4
  100. package/dist/{vue-ui-onion-DS7LaVFL.js → vue-ui-onion-BWAdTZ6V.js} +4 -4
  101. package/dist/{vue-ui-parallel-coordinate-plot-DwK4-ZyV.js → vue-ui-parallel-coordinate-plot-DXbgnatq.js} +4 -4
  102. package/dist/{vue-ui-quadrant-CIIvIECe.js → vue-ui-quadrant-BwGMZ_d_.js} +4 -4
  103. package/dist/{vue-ui-quick-chart-Cba6XAFF.js → vue-ui-quick-chart-2bQ0DX_A.js} +3 -3
  104. package/dist/{vue-ui-radar-BCyKcnH1.js → vue-ui-radar-DPXvVIbh.js} +4 -4
  105. package/dist/{vue-ui-rating-HgSUBbJx.js → vue-ui-rating-CxIBq7Xr.js} +1 -1
  106. package/dist/{vue-ui-relation-circle-VBceGE52.js → vue-ui-relation-circle-BVGAfqBj.js} +4 -4
  107. package/dist/{vue-ui-ridgeline-Bn2iVW8_.js → vue-ui-ridgeline-C6UdClMT.js} +4 -4
  108. package/dist/{vue-ui-rings-NoFKU2kZ.js → vue-ui-rings-B_7zAshC.js} +4 -4
  109. package/dist/{vue-ui-scatter-BWIcu0AU.js → vue-ui-scatter-BRr9oPfo.js} +4 -4
  110. package/dist/{vue-ui-skeleton-DPYUcomF.js → vue-ui-skeleton-C3tGR_lR.js} +2 -2
  111. package/dist/{vue-ui-smiley-C2wHzhBj.js → vue-ui-smiley-B70Ck-49.js} +1 -1
  112. package/dist/{vue-ui-spark-trend-B57gzgJA.js → vue-ui-spark-trend-C2tSZULg.js} +3 -3
  113. package/dist/{vue-ui-sparkbar-BKMkKeAJ.js → vue-ui-sparkbar-BUPDw_qR.js} +3 -3
  114. package/dist/{vue-ui-sparkgauge-C3R0tWzz.js → vue-ui-sparkgauge-DufAZyFK.js} +3 -3
  115. package/dist/{vue-ui-sparkhistogram-31hSCW__.js → vue-ui-sparkhistogram-DDunWMKu.js} +3 -3
  116. package/dist/{vue-ui-sparkline-DGy1K2y4.js → vue-ui-sparkline-lRx2nNde.js} +3 -3
  117. package/dist/{vue-ui-sparkstackbar-C6wOF12V.js → vue-ui-sparkstackbar-CB6WHJHd.js} +3 -3
  118. package/dist/{vue-ui-stackbar-BSnIzSOz.js → vue-ui-stackbar-CQ9Zvuxh.js} +4 -4
  119. package/dist/{vue-ui-strip-plot-Dt8rJHX1.js → vue-ui-strip-plot-DW3c82dV.js} +4 -4
  120. package/dist/{vue-ui-table-DZ_jLauo.js → vue-ui-table-CEt97z7F.js} +259 -212
  121. package/dist/{vue-ui-table-heatmap-wRY63Mop.js → vue-ui-table-heatmap-DFZCaMxK.js} +2 -2
  122. package/dist/{vue-ui-table-sparkline-2ZPRQrqb.js → vue-ui-table-sparkline-RB40-Z1R.js} +3 -3
  123. package/dist/{vue-ui-thermometer-CZDRLAlr.js → vue-ui-thermometer-fmPzO-eT.js} +4 -4
  124. package/dist/{vue-ui-timer-wMk4sVkK.js → vue-ui-timer-qxLpO3HX.js} +3 -3
  125. package/dist/{vue-ui-tiremarks-C1IEecQB.js → vue-ui-tiremarks-Cxx97FLg.js} +4 -4
  126. package/dist/{vue-ui-treemap-Q4PWFmqT.js → vue-ui-treemap-B4-IPDxV.js} +4 -4
  127. package/dist/{vue-ui-vertical-bar-C7nhAu5t.js → vue-ui-vertical-bar-Y5LefeNg.js} +5 -5
  128. package/dist/{vue-ui-waffle-B7lfNgi8.js → vue-ui-waffle-gvnJOZlg.js} +4 -4
  129. package/dist/{vue-ui-wheel-h30eu5fl.js → vue-ui-wheel-BzS_N3GP.js} +4 -4
  130. package/dist/{vue-ui-word-cloud-C4fjGysW.js → vue-ui-word-cloud-vWhTarrE.js} +4 -4
  131. package/dist/{vue-ui-world-C9xV3sZJ.js → vue-ui-world-CqWuE8ZR.js} +2 -2
  132. package/dist/{vue-ui-xy-vlcc3Vxv.js → vue-ui-xy-BxpuE9Ng.js} +1766 -1754
  133. package/dist/vue-ui-xy-canvas-C9YQjaUA.js +1305 -0
  134. package/package.json +1 -1
  135. package/dist/vue-ui-xy-canvas-iPqn9H95.js +0 -1302
@@ -0,0 +1,1305 @@
1
+ import { defineAsyncComponent as ee, ref as c, computed as L, useSlots as el, onMounted as ha, watch as D, nextTick as fa, shallowRef as Me, onBeforeUnmount as al, createElementBlock as de, openBlock as S, unref as p, normalizeClass as ll, normalizeStyle as ae, createCommentVNode as H, createElementVNode as Y, createBlock as F, createSlots as ya, withCtx as m, renderSlot as k, normalizeProps as V, guardReactiveProps as Z, createVNode as ga, Teleport as tl, toDisplayString as Oe, resolveDynamicComponent as ol, mergeProps as ul, createTextVNode as pa } from "vue";
2
+ import { c as rl, b as sl, p as G, B as he, e as nl, C as Re, a as le, d as te, h as ma, _ as il, J as vl, a7 as cl, o as dl, f as hl, z as ba, x as fl, y as yl, A as gl, s as fe, m as pl } from "./lib-BEpWEyMm.js";
3
+ import { d as ml, t as bl, u as xl, c as Ll, a as xa, l as C, r as De, b as P, p as La } from "./useResponsive-DfdjqQps.js";
4
+ import { u as kl, a as Fe } from "./useNestedProp-BOk-tPdu.js";
5
+ import { u as Cl } from "./usePrinter-w23K-ezx.js";
6
+ import { u as wl } from "./useUserOptionState-BIvW1Kz7.js";
7
+ import { u as Sl } from "./useChartAccessibility-9icAAmYg.js";
8
+ import { t as zl } from "./themes-Dw-dDudK.js";
9
+ import $l from "./Legend-BpoFJ8fc.js";
10
+ import Tl from "./Title-DG2nloSB.js";
11
+ import { S as Il } from "./Slicer-BA2GhOmY.js";
12
+ import Ml from "./vue-ui-accordion-CeMTgpl0.js";
13
+ import { u as Ol } from "./useTimeLabels-BGFjWgrv.js";
14
+ import Rl from "./img-DjWwQXVS.js";
15
+ import Dl from "./BaseIcon-Bz-1GQhu.js";
16
+ import { _ as Fl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
17
+ const Pl = ["id"], El = ["id"], Al = ["id"], Nl = ["onClick"], Hl = {
18
+ key: 3,
19
+ class: "vue-data-ui-watermark"
20
+ }, Yl = ["innerHTML"], _l = {
21
+ __name: "vue-ui-xy-canvas",
22
+ props: {
23
+ dataset: {
24
+ type: Array,
25
+ default() {
26
+ return [];
27
+ }
28
+ },
29
+ config: {
30
+ type: Object,
31
+ default() {
32
+ return {};
33
+ }
34
+ }
35
+ },
36
+ emits: ["selectLegend"],
37
+ setup(Pe, { expose: ka, emit: Ca }) {
38
+ const wa = ee(() => import("./DataTable-BvjacRbw.js")), Sa = ee(() => import("./NonSvgPenAndPaper-l9giyY1Z.js")), za = ee(() => import("./vue-ui-skeleton-C3tGR_lR.js")), $a = ee(() => import("./Tooltip-BOXz8skU.js")), Ta = ee(() => import("./UserOptions-DsTgvAok.js")), Ia = ee(() => import("./BaseDraggableDialog-CHhZIht2.js")), { vue_ui_xy_canvas: Ma } = kl(), g = Pe, _ = c(rl()), I = c(null), oe = c(null), n = c(null), f = c(1), E = c(1), ye = c(!1), d = c(null), ge = c(""), Ee = c(null), $ = c([]), j = c(1), B = c(!0), q = c(!0), Le = c(null), Ae = c(0), Ne = c(0), ue = c(!1), He = c(null), Ye = c(null), _e = c(null), Be = c(null), ke = c(0), Ce = c(0), we = c(0), M = c(null), Ue = c(!1), re = c(null), Se = c(null), pe = L(() => !!g.dataset && g.dataset.length), Oa = Ca, Ra = el();
39
+ ha(() => {
40
+ Ra["chart-background"] && console.warn("VueUiXyCanvas does not support the #chart-background slot.");
41
+ });
42
+ const a = L({
43
+ get: () => Ve(),
44
+ set: (e) => e
45
+ }), { userOptionsVisible: ze, setUserOptionsVisibility: We, keepUserOptionState: Xe } = wl({ config: a.value }), { svgRef: O } = Sl({ config: a.value.style.chart.title });
46
+ function Ve() {
47
+ const e = Fe({
48
+ userConfig: g.config,
49
+ defaultConfig: Ma
50
+ });
51
+ let l = {};
52
+ return e.theme ? l = {
53
+ ...Fe({
54
+ userConfig: zl.vue_ui_xy_canvas[e.theme] || g.config,
55
+ defaultConfig: e
56
+ }),
57
+ customPalette: sl[e.theme] || G
58
+ } : l = e, g.config && he(g.config, "style.chart.scale.min") ? l.style.chart.scale.min = g.config.style.chart.scale.min : l.style.chart.scale.min = null, g.config && he(g.config, "style.chart.scale.max") ? l.style.chart.scale.max = g.config.style.chart.scale.max : l.style.chart.scale.max = null, g.config && he(g.config, "style.chart.zoom.startIndex") ? l.style.chart.zoom.startIndex = g.config.style.chart.zoom.startIndex : l.style.chart.zoom.startIndex = null, g.config && he(g.config, "style.chart.zoom.endIndex") ? l.style.chart.zoom.endIndex = g.config.style.chart.zoom.endIndex : l.style.chart.zoom.endIndex = null, g.config && he(g.config, "style.chart.grid.y.timeLabels") && (console.warn("VueUiXyCanvas: you are using the deprecated config.style.chart.grid.y.timeLabels. It is recommended to move this configuration to config.style.chart.grid.x.timeLabels."), l.style.chart.grid.x.timeLabels = Fe({
59
+ defaultConfig: l.style.chart.grid.x.timeLabels,
60
+ userConfig: g.config.style.chart.grid.y.timeLabels
61
+ })), l;
62
+ }
63
+ D(() => g.config, (e) => {
64
+ a.value = Ve(), ze.value = !a.value.userOptions.showOnChartHover, $e(), ke.value += 1, Ce.value += 1, we.value += 1, r.value.showTable = a.value.table.show, r.value.showDataLabels = a.value.style.chart.dataLabels.show, r.value.stacked = a.value.style.chart.stacked, r.value.showTooltip = a.value.style.chart.tooltip.show;
65
+ }, { deep: !0 }), D(() => g.dataset, () => {
66
+ $e(), ke.value += 1, Ce.value += 1, we.value += 1;
67
+ }, { deep: !0 });
68
+ const Ze = c(a.value.style.chart.aspectRatio), { isPrinting: Ge, isImaging: je, generatePdf: qe, generateImage: Je } = Cl({
69
+ elementId: `xy_canvas_${_.value}`,
70
+ fileName: a.value.style.chart.title.text || "vue-ui-xy-canvas",
71
+ options: a.value.userOptions.print
72
+ }), r = c({
73
+ showTable: a.value.table.show,
74
+ showDataLabels: a.value.style.chart.dataLabels.show,
75
+ stacked: a.value.style.chart.stacked,
76
+ showTooltip: a.value.style.chart.tooltip.show
77
+ });
78
+ function Ke(e) {
79
+ ue.value = e, Ne.value += 1;
80
+ }
81
+ const Qe = L(() => nl(a.value.customPalette)), T = L(() => J.value ? Math.max(...J.value.filter((e, l) => !$.value.includes(e.absoluteIndex)).map((e) => e.series.length)) : 0), t = L(() => {
82
+ const e = f.value - f.value * (a.value.style.chart.paddingProportions.left + a.value.style.chart.paddingProportions.right);
83
+ return {
84
+ canvasWidth: f.value,
85
+ canvasHeight: E.value,
86
+ left: f.value * a.value.style.chart.paddingProportions.left,
87
+ top: E.value * a.value.style.chart.paddingProportions.top,
88
+ right: f.value - f.value * a.value.style.chart.paddingProportions.right,
89
+ bottom: E.value - E.value * a.value.style.chart.paddingProportions.bottom,
90
+ width: e,
91
+ height: E.value - E.value * (a.value.style.chart.paddingProportions.top + a.value.style.chart.paddingProportions.bottom),
92
+ slot: e / (u.value.end - u.value.start)
93
+ };
94
+ });
95
+ function ea(e, l) {
96
+ return e / l;
97
+ }
98
+ function Da({ hasAutoScale: e, series: l, min: o, max: s, scale: i, yOffset: x, individualHeight: v, stackIndex: y = null }) {
99
+ return l.map((W, z) => {
100
+ const N = i.min < 0 ? Math.abs(i.min) : 0, X = ea(W + N, N + i.max);
101
+ let ve, ce;
102
+ e && (ve = i.min, ce = ea(W - ve, i.max - ve));
103
+ let R = 0;
104
+ return y === null ? R = t.value.bottom - t.value.height * (e ? ce : X) : R = t.value.bottom - x - v * (e ? ce : X), {
105
+ x: t.value.left + t.value.slot * z + t.value.slot / 2,
106
+ y: R,
107
+ value: W
108
+ };
109
+ });
110
+ }
111
+ const b = L(() => {
112
+ const e = a.value.style.chart.scale.min !== null ? a.value.style.chart.scale.min : Math.min(...J.value.filter((v, y) => !$.value.includes(v.absoluteIndex)).flatMap((v) => v.series.slice(u.value.start, u.value.end))), l = a.value.style.chart.scale.max !== null ? a.value.style.chart.scale.max : Math.max(...J.value.filter((v, y) => !$.value.includes(v.absoluteIndex)).flatMap((v) => v.series.slice(u.value.start, u.value.end))), o = Re(e < 0 ? e : 0, l === e ? e + 1 < 0 ? 0 : e + 1 : l < 0 ? 0 : l, a.value.style.chart.scale.ticks), s = o.min < 0 ? Math.abs(o.min) : 0, i = t.value.bottom - t.value.height * (s / (o.max + s)), x = o.ticks.map((v) => ({
113
+ y: t.value.bottom - t.value.height * ((v + s) / (o.max + s)),
114
+ x: t.value.left - 8,
115
+ value: v
116
+ }));
117
+ return {
118
+ absoluteMin: s,
119
+ max: l,
120
+ min: e,
121
+ scale: o,
122
+ yLabels: x,
123
+ zero: i
124
+ };
125
+ }), Fa = L(() => h.value.map((e) => `
126
+ <div style="display:flex;flex-direction:row;gap:6px;align-items:center;">
127
+ <svg viewBox="0 0 10 10" height="12" width="12">
128
+ <circle cx="5" cy="5" r="5" fill="${e.color}"/>
129
+ </svg>
130
+ <span>${e.name ? e.name + ": " : ""}</span>
131
+ <span>${le(
132
+ a.value.style.chart.dataLabels.formatter,
133
+ e.series[d.value],
134
+ te({
135
+ p: e.prefix || "",
136
+ v: e.series[d.value],
137
+ s: e.suffix || "",
138
+ r: e.rounding || 0
139
+ }),
140
+ { datapoint: e, seriesIndex: d.value }
141
+ )}</span>
142
+ </div>
143
+ `)), J = L(() => g.dataset.map((e, l) => ({
144
+ ...e,
145
+ series: il({
146
+ data: vl(e.series),
147
+ threshold: a.value.downsample.threshold
148
+ }),
149
+ absoluteIndex: l,
150
+ color: ma(e.color || Qe.value[l] || G[l] || G[l % G.length])
151
+ })));
152
+ D(T, (e) => {
153
+ e && aa();
154
+ });
155
+ const h = L(() => cl(J.value.filter((e, l) => !$.value.includes(e.absoluteIndex))).map((e, l) => ({
156
+ ...e,
157
+ series: e.series.slice(u.value.start, u.value.end)
158
+ })).map((e, l) => {
159
+ let o = [null, void 0].includes(e.scaleMin) ? Math.min(...e.series) || 0 : e.scaleMin, s = [null, void 0].includes(e.scaleMax) ? Math.max(...e.series) || 1 : e.scaleMax;
160
+ o === s && (o = o >= 0 ? s - 1 : o, s = s >= 0 ? s : o + 1), e.series.filter((R) => ![null, void 0].includes(R)).map((R) => (R - o) / (s - o));
161
+ const i = {
162
+ valueMin: o,
163
+ valueMax: s
164
+ }, x = e.scaleSteps || a.value.style.chart.scale.ticks;
165
+ let v;
166
+ e.autoScaling ? v = Re(i.valueMin, i.valueMax, x) : v = Re(i.valueMin < 0 ? i.valueMin : 0, i.valueMax <= 0 ? 0 : i.valueMax, x);
167
+ const y = r.value.stacked ? t.value.height * (1 - e.cumulatedStackRatio) : 0, W = r.value.stacked ? t.value.height / a.value.style.chart.stackGap : 0, z = r.value.stacked ? t.value.height * e.stackRatio - W : t.value.height, N = v.min < 0 ? Math.abs(v.min) : 0;
168
+ let X;
169
+ e.autoScaling && r.value.stacked && s <= 0 ? X = t.value.bottom - y - z : X = t.value.bottom - y - z * (N / (v.max + N));
170
+ const ve = v.ticks.map((R, Qa) => ({
171
+ y: t.value.bottom - y - z * (Qa / (v.ticks.length - 1)),
172
+ x: t.value.left - 8,
173
+ value: R
174
+ })), ce = Da({
175
+ hasAutoScale: r.value.stacked && e.autoScaling,
176
+ series: e.series,
177
+ min: r.value.stacked ? o : b.value.min,
178
+ max: r.value.stacked ? s : b.value.max,
179
+ scale: r.value.stacked ? v : b.value.scale,
180
+ yOffset: y,
181
+ individualHeight: z,
182
+ stackIndex: r.value.stacked ? l : null
183
+ });
184
+ return {
185
+ ...e,
186
+ coordinatesLine: ce,
187
+ min: o,
188
+ max: s,
189
+ localScale: v,
190
+ localZero: X,
191
+ localMin: N,
192
+ localYLabels: ve,
193
+ yOffset: y,
194
+ individualHeight: z
195
+ };
196
+ })), u = c({
197
+ start: 0,
198
+ end: T.value
199
+ });
200
+ function aa() {
201
+ ta();
202
+ }
203
+ const la = c(null);
204
+ async function ta() {
205
+ await fa(), await fa();
206
+ const { startIndex: e, endIndex: l } = a.value.style.chart.zoom, o = la.value, s = T.value;
207
+ u.value = { start: 0, end: s }, (e != null || l != null) && o ? (e != null ? o.setStartValue(e) : (u.value.start = 0, o.setStartValue(0)), l != null ? o.setEndValue(Pa(l + 1)) : (u.value.end = s, o.setEndValue(s))) : (u.value = { start: 0, end: s }, Ae.value += 1);
208
+ }
209
+ function Pa(e) {
210
+ const l = T.value;
211
+ return e > l ? l : 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;
212
+ }
213
+ const Ea = L(() => h.value.filter((e) => ["line", "plot", void 0].includes(e.type))), w = L(() => h.value.filter((e) => e.type === "bar"));
214
+ function Aa() {
215
+ if (!O.value)
216
+ return;
217
+ const e = oe.value.offsetWidth, l = oe.value.offsetHeight;
218
+ O.value.width = e * j.value * 2, O.value.height = l * j.value * 2, f.value = e * j.value * 2, E.value = l * j.value * 2, n.value.scale(j.value, j.value), se();
219
+ }
220
+ function Na() {
221
+ if (n.value.clearRect(0, 0, 1e4, 1e4), n.value.fillStyle = a.value.style.chart.backgroundColor, n.value.fillRect(0, 0, t.value.canvasWidth, t.value.canvasHeight), r.value.stacked)
222
+ a.value.style.chart.grid.y.verticalLines.show && u.value.end - u.value.start < a.value.style.chart.grid.y.verticalLines.hideUnderXLength ? h.value.forEach((e) => {
223
+ for (let l = 0; l < u.value.end - u.value.start + 1; l += 1)
224
+ C(
225
+ n.value,
226
+ [
227
+ {
228
+ x: t.value.left + t.value.slot * l,
229
+ y: t.value.bottom - e.yOffset - e.individualHeight
230
+ },
231
+ {
232
+ x: t.value.left + t.value.slot * l,
233
+ y: t.value.bottom - e.yOffset
234
+ }
235
+ ],
236
+ {
237
+ color: a.value.style.chart.grid.y.verticalLines.color
238
+ }
239
+ );
240
+ }) : a.value.style.chart.grid.y.verticalLines.show && u.value.end - u.value.start >= a.value.style.chart.grid.y.verticalLines.hideUnderXLength && h.value.forEach((e) => {
241
+ for (let l = u.value.start; l < u.value.end; l += 1)
242
+ l % Math.floor((u.value.end - u.value.start) / a.value.style.chart.grid.x.timeLabels.modulo) === 0 && C(
243
+ n.value,
244
+ [
245
+ {
246
+ x: t.value.left + t.value.slot * (l - u.value.start) + t.value.slot / 2,
247
+ y: t.value.bottom - e.yOffset - e.individualHeight
248
+ },
249
+ {
250
+ x: t.value.left + t.value.slot * (l - u.value.start) + t.value.slot / 2,
251
+ y: t.value.bottom - e.yOffset
252
+ }
253
+ ],
254
+ {
255
+ color: a.value.style.chart.grid.y.verticalLines.color
256
+ }
257
+ );
258
+ }), a.value.style.chart.grid.x.horizontalLines.show && (a.value.style.chart.grid.x.horizontalLines.alternate ? h.value.forEach((e) => {
259
+ e.localYLabels.forEach((l, o) => {
260
+ o < e.localYLabels.length - 1 && De(
261
+ n.value,
262
+ [
263
+ { x: t.value.left, y: l.y },
264
+ { x: t.value.right, y: l.y },
265
+ { x: t.value.right, y: e.localYLabels[o + 1].y },
266
+ { x: t.value.left, y: e.localYLabels[o + 1].y }
267
+ ],
268
+ {
269
+ fillColor: o % 2 === 0 ? "transparent" : fe(a.value.style.chart.grid.x.horizontalLines.color, a.value.style.chart.grid.x.horizontalLines.opacity),
270
+ strokeColor: "transparent"
271
+ }
272
+ );
273
+ });
274
+ }) : h.value.forEach((e) => {
275
+ e.localYLabels.slice(u.value.start, u.value.end).forEach((l) => {
276
+ C(
277
+ n.value,
278
+ [
279
+ { x: t.value.left, y: l.y },
280
+ { x: t.value.right, y: l.y }
281
+ ],
282
+ {
283
+ color: a.value.style.chart.grid.x.horizontalLines.color
284
+ }
285
+ );
286
+ });
287
+ })), a.value.style.chart.grid.zeroLine.show && h.value.forEach((e) => {
288
+ C(
289
+ n.value,
290
+ [
291
+ { x: t.value.left, y: e.localZero },
292
+ { x: t.value.right, y: e.localZero }
293
+ ],
294
+ {
295
+ color: a.value.style.chart.grid.zeroLine.color,
296
+ lineDash: a.value.style.chart.grid.zeroLine.dashed ? [10, 10] : [0, 0]
297
+ }
298
+ );
299
+ }), a.value.style.chart.grid.y.axisLabels.show && h.value.forEach((e) => {
300
+ C(
301
+ n.value,
302
+ [
303
+ { x: t.value.left, y: t.value.bottom - e.yOffset },
304
+ { x: t.value.left, y: t.value.bottom - e.yOffset - e.individualHeight }
305
+ ],
306
+ {
307
+ color: e.color
308
+ }
309
+ ), C(
310
+ n.value,
311
+ [
312
+ { x: t.value.right, y: t.value.bottom - e.yOffset },
313
+ { x: t.value.right, y: t.value.bottom - e.yOffset - e.individualHeight }
314
+ ],
315
+ {
316
+ color: e.color
317
+ }
318
+ );
319
+ }), h.value.forEach((e) => {
320
+ P(
321
+ n.value,
322
+ e.name,
323
+ f.value / 35,
324
+ t.value.bottom - e.yOffset - e.individualHeight / 2,
325
+ {
326
+ align: "center",
327
+ rotation: -90,
328
+ color: e.color,
329
+ font: `${Math.round(f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`
330
+ }
331
+ );
332
+ });
333
+ else {
334
+ if (a.value.style.chart.grid.y.verticalLines.show && u.value.end - u.value.start < a.value.style.chart.grid.y.verticalLines.hideUnderXLength)
335
+ for (let e = 0; e < u.value.end - u.value.start + 1; e += 1)
336
+ C(
337
+ n.value,
338
+ [
339
+ { x: t.value.left + t.value.slot * e, y: t.value.top },
340
+ { x: t.value.left + t.value.slot * e, y: t.value.bottom }
341
+ ],
342
+ {
343
+ color: a.value.style.chart.grid.y.verticalLines.color
344
+ }
345
+ );
346
+ else if (a.value.style.chart.grid.y.verticalLines.show && u.value.end - u.value.start >= a.value.style.chart.grid.y.verticalLines.hideUnderXLength)
347
+ for (let e = u.value.start; e < u.value.end; e += 1)
348
+ e % Math.floor((u.value.end - u.value.start) / a.value.style.chart.grid.x.timeLabels.modulo) === 0 && C(
349
+ n.value,
350
+ [
351
+ { x: t.value.left + t.value.slot * (e - u.value.start) + t.value.slot / 2, y: t.value.top },
352
+ { x: t.value.left + t.value.slot * (e - u.value.start) + t.value.slot / 2, y: t.value.bottom }
353
+ ],
354
+ {
355
+ color: a.value.style.chart.grid.y.verticalLines.color
356
+ }
357
+ );
358
+ a.value.style.chart.grid.x.horizontalLines.show && (a.value.style.chart.grid.x.horizontalLines.alternate ? b.value.yLabels.forEach((e, l) => {
359
+ l < b.value.yLabels.length - 1 && De(
360
+ n.value,
361
+ [
362
+ { x: t.value.left, y: e.y },
363
+ { x: t.value.right, y: e.y },
364
+ { x: t.value.right, y: b.value.yLabels[l + 1].y },
365
+ { x: t.value.left, y: b.value.yLabels[l + 1].y }
366
+ ],
367
+ {
368
+ fillColor: l % 2 === 0 ? "transparent" : fe(a.value.style.chart.grid.x.horizontalLines.color, a.value.style.chart.grid.x.horizontalLines.opacity),
369
+ strokeColor: "transparent"
370
+ }
371
+ );
372
+ }) : b.value.yLabels.forEach((e) => {
373
+ C(
374
+ n.value,
375
+ [
376
+ { x: t.value.left, y: e.y },
377
+ { x: t.value.right, y: e.y }
378
+ ],
379
+ {
380
+ color: a.value.style.chart.grid.x.horizontalLines.color
381
+ }
382
+ );
383
+ })), a.value.style.chart.grid.y.showAxis && C(
384
+ n.value,
385
+ [
386
+ { x: t.value.left, y: t.value.top },
387
+ { x: t.value.left, y: t.value.bottom }
388
+ ],
389
+ {
390
+ color: a.value.style.chart.grid.y.axisColor,
391
+ lineWidth: a.value.style.chart.grid.y.axisThickness
392
+ }
393
+ ), a.value.style.chart.grid.x.showAxis && C(
394
+ n.value,
395
+ [
396
+ { x: t.value.left, y: t.value.bottom },
397
+ { x: t.value.right, y: t.value.bottom }
398
+ ],
399
+ {
400
+ color: a.value.style.chart.grid.x.axisColor,
401
+ lineWidth: a.value.style.chart.grid.x.axisThickness
402
+ }
403
+ ), a.value.style.chart.grid.zeroLine.show && C(
404
+ n.value,
405
+ [
406
+ { x: t.value.left, y: b.value.zero },
407
+ { x: t.value.right, y: b.value.zero }
408
+ ],
409
+ {
410
+ color: a.value.style.chart.grid.zeroLine.color,
411
+ lineDash: a.value.style.chart.grid.zeroLine.dashed ? [10, 10] : [0, 0]
412
+ }
413
+ );
414
+ }
415
+ a.value.style.chart.grid.y.axisName && P(
416
+ n.value,
417
+ a.value.style.chart.grid.y.axisName,
418
+ f.value - f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio * 1.2,
419
+ t.value.bottom - t.value.height / 2,
420
+ {
421
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
422
+ color: a.value.style.chart.color,
423
+ align: "center",
424
+ rotation: 90
425
+ }
426
+ ), a.value.style.chart.grid.x.axisName && P(
427
+ n.value,
428
+ a.value.style.chart.grid.x.axisName,
429
+ f.value / 2,
430
+ E.value,
431
+ {
432
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
433
+ color: a.value.style.chart.color,
434
+ align: "center"
435
+ }
436
+ );
437
+ }
438
+ function Ha(e) {
439
+ for (let l = 0; l < e.coordinatesLine.length; l += 1) {
440
+ const o = (d.value === l ? f.value / 150 : a.value.style.chart.line.plots.show ? f.value / 200 : 0) * a.value.style.chart.line.plots.radiusRatio;
441
+ xa(
442
+ n.value,
443
+ { x: e.coordinatesLine[l].x, y: e.coordinatesLine[l].y },
444
+ o,
445
+ {
446
+ color: a.value.style.chart.backgroundColor,
447
+ fillStyle: e.color
448
+ }
449
+ );
450
+ }
451
+ }
452
+ function Ya() {
453
+ h.value.forEach((e) => {
454
+ e.showYMarker && ne(e) && P(
455
+ n.value,
456
+ le(
457
+ a.value.style.chart.dataLabels.formatter,
458
+ ne(e).value,
459
+ te({
460
+ p: e.prefix || a.value.style.chart.grid.y.axisLabels.prefix || "",
461
+ v: ne(e).value,
462
+ s: e.suffix || a.value.style.chart.grid.y.axisLabels.suffix || "",
463
+ r: e.rounding || a.value.style.chart.grid.y.axisLabels.rounding || 0
464
+ }),
465
+ { datapoint: ne(e), seriesIndex: null }
466
+ ),
467
+ t.value.left - 8 + a.value.style.chart.grid.y.axisLabels.offsetX,
468
+ ne(e).y,
469
+ {
470
+ align: "right",
471
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
472
+ color: e.color
473
+ }
474
+ );
475
+ });
476
+ }
477
+ function _a() {
478
+ a.value.style.chart.grid.y.axisLabels.show && (r.value.stacked ? h.value.forEach((e) => {
479
+ e.localYLabels.forEach((l, o) => {
480
+ P(
481
+ n.value,
482
+ le(
483
+ a.value.style.chart.dataLabels.formatter,
484
+ l.value,
485
+ te({
486
+ p: e.prefix || a.value.style.chart.grid.y.axisLabels.prefix || "",
487
+ v: l.value,
488
+ s: e.suffix || a.value.style.chart.grid.y.axisLabels.suffix || "",
489
+ r: e.rounding || a.value.style.chart.grid.y.axisLabels.rounding || 0
490
+ }),
491
+ { datapoint: l, seriesIndex: o }
492
+ ),
493
+ l.x + a.value.style.chart.grid.y.axisLabels.offsetX,
494
+ l.y,
495
+ {
496
+ align: "right",
497
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
498
+ color: e.color,
499
+ globalAlpha: e.showYMarker && ![null, void 0].includes(d.value) ? 0.2 : 1
500
+ }
501
+ );
502
+ });
503
+ }) : b.value.yLabels.forEach((e, l) => {
504
+ P(
505
+ n.value,
506
+ le(
507
+ a.value.style.chart.dataLabels.formatter,
508
+ e.value,
509
+ te({
510
+ p: a.value.style.chart.grid.y.axisLabels.prefix || "",
511
+ v: e.value,
512
+ s: a.value.style.chart.grid.y.axisLabels.suffix || "",
513
+ r: a.value.style.chart.grid.y.axisLabels.rounding || 0
514
+ }),
515
+ { datapoint: e, seriesIndex: l }
516
+ ),
517
+ e.x + a.value.style.chart.grid.y.axisLabels.offsetX,
518
+ e.y,
519
+ {
520
+ align: "right",
521
+ font: `${a.value.style.chart.grid.y.axisLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
522
+ color: a.value.style.chart.grid.y.axisLabels.color,
523
+ globalAlpha: h.value.some((o) => o.showYMarker) && ![null, void 0].includes(d.value) ? 0.2 : 1
524
+ }
525
+ );
526
+ }));
527
+ }
528
+ function Ba(e) {
529
+ for (let l = 0; l < e.coordinatesLine.length; l += 1)
530
+ P(
531
+ n.value,
532
+ le(
533
+ a.value.style.chart.dataLabels.formatter,
534
+ e.coordinatesLine[l].value,
535
+ te({
536
+ p: e.prefix || "",
537
+ v: e.coordinatesLine[l].value,
538
+ s: e.suffix || "",
539
+ r: e.rounding || 0
540
+ }),
541
+ { datapoint: e.coordinatesLine[l], seriesIndex: l }
542
+ ),
543
+ e.coordinatesLine[l].x,
544
+ e.coordinatesLine[l].y + a.value.style.chart.dataLabels.offsetY,
545
+ {
546
+ align: "center",
547
+ font: `${a.value.style.chart.dataLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.dataLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
548
+ color: a.value.style.chart.dataLabels.useSerieColor ? e.color : a.value.style.chart.dataLabels.color
549
+ }
550
+ );
551
+ }
552
+ const U = L(() => Ol({
553
+ values: a.value.style.chart.grid.x.timeLabels.values,
554
+ maxDatapoints: T.value,
555
+ formatter: a.value.style.chart.grid.x.timeLabels.datetimeFormatter,
556
+ start: 0,
557
+ end: a.value.style.chart.grid.x.timeLabels.values.length
558
+ }));
559
+ function Ua() {
560
+ for (let e = u.value.start; e < u.value.end; e += 1)
561
+ (u.value.end - u.value.start < a.value.style.chart.grid.x.timeLabels.modulo || u.value.end - u.value.start >= a.value.style.chart.grid.x.timeLabels.modulo && (e % Math.floor((u.value.end - u.value.start) / a.value.style.chart.grid.x.timeLabels.modulo) === 0 || e === d.value + u.value.start && a.value.style.chart.grid.x.timeLabels.showMarker)) && P(
562
+ n.value,
563
+ U.value[e] ? U.value[e].text : e + 1,
564
+ t.value.left + t.value.slot * (e - u.value.start) + t.value.slot / 2,
565
+ t.value.bottom + f.value / a.value.style.chart.grid.x.timeLabels.offsetY,
566
+ {
567
+ align: a.value.style.chart.grid.x.timeLabels.rotation === 0 ? "center" : a.value.style.chart.grid.x.timeLabels.rotation > 0 ? "left" : "right",
568
+ font: `${a.value.style.chart.grid.x.timeLabels.bold ? "bold " : ""}${Math.round(f.value / 40 * a.value.style.chart.grid.x.timeLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
569
+ color: a.value.style.chart.grid.x.timeLabels.showMarker ? fe(a.value.style.chart.grid.x.timeLabels.color, d.value !== null ? d.value + u.value.start === e ? 100 : 20 : 100) : a.value.style.chart.grid.x.timeLabels.color,
570
+ rotation: a.value.style.chart.grid.x.timeLabels.rotation
571
+ }
572
+ );
573
+ }
574
+ function oa() {
575
+ C(
576
+ n.value,
577
+ [
578
+ { x: t.value.left + t.value.slot * d.value + t.value.slot / 2, y: t.value.top },
579
+ { x: t.value.left + t.value.slot * d.value + t.value.slot / 2, y: t.value.bottom }
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 Wa() {
589
+ M.value && C(
590
+ n.value,
591
+ [
592
+ { x: t.value.left, y: M.value },
593
+ { x: t.value.right, y: M.value }
594
+ ],
595
+ {
596
+ color: a.value.style.chart.selector.color,
597
+ lineDash: a.value.style.chart.selector.dashed ? [8, 8] : [0, 0],
598
+ lineWidth: 2
599
+ }
600
+ );
601
+ }
602
+ function Xa() {
603
+ w.value.forEach((e, l) => {
604
+ for (let o = 0; o < e.coordinatesLine.length; o += 1)
605
+ De(
606
+ n.value,
607
+ [
608
+ {
609
+ x: t.value.left + t.value.slot * o + t.value.slot / 10 + (r.value.stacked ? 0 : t.value.slot / w.value.length * l - (l === 0 ? 0 : t.value.slot / (5 * w.value.length) * l)),
610
+ y: r.value.stacked ? e.localZero : b.value.zero
611
+ },
612
+ {
613
+ x: t.value.left + t.value.slot * o + t.value.slot / 10 + (r.value.stacked ? 0 : t.value.slot / w.value.length * l - (l === 0 ? 0 : t.value.slot / (5 * w.value.length) * l)) + t.value.slot * 0.8 / (r.value.stacked ? 1 : w.value.length),
614
+ y: r.value.stacked ? e.localZero : b.value.zero
615
+ },
616
+ {
617
+ x: t.value.left + t.value.slot * o + t.value.slot / 10 + (r.value.stacked ? 0 : t.value.slot / w.value.length * l - (l === 0 ? 0 : t.value.slot / (5 * w.value.length) * l)) + t.value.slot * 0.8 / (r.value.stacked ? 1 : w.value.length),
618
+ y: e.coordinatesLine[o].y
619
+ },
620
+ {
621
+ x: t.value.left + t.value.slot * o + t.value.slot / 10 + (r.value.stacked ? 0 : t.value.slot / w.value.length * l - (l === 0 ? 0 : t.value.slot / (5 * w.value.length) * l)),
622
+ y: e.coordinatesLine[o].y
623
+ }
624
+ ],
625
+ {
626
+ strokeColor: a.value.style.chart.backgroundColor,
627
+ gradient: {
628
+ type: "linear",
629
+ start: {
630
+ x: e.coordinatesLine[o].x,
631
+ y: e.coordinatesLine[o].y
632
+ },
633
+ end: {
634
+ x: e.coordinatesLine[o].x,
635
+ y: r.value.stacked ? e.localZero : b.value.zero
636
+ },
637
+ stops: [
638
+ { offset: 0, color: e.color },
639
+ { offset: 1, color: a.value.style.chart.bar.gradient.show ? pl(e.color, 0.5) : e.color }
640
+ ]
641
+ }
642
+ }
643
+ ), r.value.showDataLabels && [!0, void 0].includes(e.dataLabels) && P(
644
+ n.value,
645
+ le(
646
+ a.value.style.chart.dataLabels.formatter,
647
+ e.coordinatesLine[o].value,
648
+ te({
649
+ p: e.prefix || "",
650
+ v: e.coordinatesLine[o].value,
651
+ s: e.suffix || "",
652
+ r: e.rounding || 0
653
+ }),
654
+ { datapoint: e.coordinatesLine[o], seriesIndex: o }
655
+ ),
656
+ t.value.left + t.value.slot * o + t.value.slot / 10 + (r.value.stacked ? 0 : t.value.slot / w.value.length * l - (l === 0 ? 0 : t.value.slot / (5 * w.value.length) * l)) + t.value.slot * 0.4 / (r.value.stacked ? 1 : w.value.length),
657
+ (e.coordinatesLine[o].value < 0 ? r.value.stacked ? e.localZero : b.value.zero : e.coordinatesLine[o].y) + a.value.style.chart.dataLabels.offsetY,
658
+ {
659
+ align: "center",
660
+ font: `${Math.round(f.value / 40 * a.value.style.chart.dataLabels.fontSizeRatio)}px ${a.value.style.fontFamily}`,
661
+ color: a.value.style.chart.dataLabels.useSerieColor ? e.color : a.value.style.chart.dataLabels.color,
662
+ strokeColor: a.value.style.chart.backgroundColor,
663
+ lineWidth: 0.8
664
+ }
665
+ );
666
+ });
667
+ }
668
+ function Va(e) {
669
+ e.useArea ? r.value.stacked ? La(
670
+ n.value,
671
+ [{ x: e.coordinatesLine[0].x, y: e.localZero }, ...e.coordinatesLine, { x: e.coordinatesLine.at(-1).x, y: e.localZero }],
672
+ {
673
+ fillColor: fe(e.color, a.value.style.chart.area.opacity),
674
+ strokeColor: "transparent"
675
+ }
676
+ ) : La(
677
+ n.value,
678
+ [{ x: e.coordinatesLine[0].x, y: b.value.zero }, ...e.coordinatesLine, { x: e.coordinatesLine.at(-1).x, y: b.value.zero }],
679
+ {
680
+ fillColor: fe(e.color, a.value.style.chart.area.opacity),
681
+ strokeColor: "transparent"
682
+ }
683
+ ) : C(n.value, e.coordinatesLine, {
684
+ color: e.color,
685
+ lineWidth: 3
686
+ });
687
+ }
688
+ function Za() {
689
+ h.value.forEach((e, l) => {
690
+ C(
691
+ n.value,
692
+ [
693
+ { x: t.value.left, y: t.value.bottom - e.yOffset },
694
+ { x: t.value.right, y: t.value.bottom - e.yOffset }
695
+ ],
696
+ {
697
+ color: a.value.style.chart.grid.x.horizontalLines.color,
698
+ lineWidth: 1
699
+ }
700
+ );
701
+ });
702
+ }
703
+ function se() {
704
+ Na(), B.value ? (d.value !== null && a.value.style.chart.selector.show && oa(), Xa(), r.value.stacked && a.value.style.chart.grid.x.showAxis && Za(), Ea.value.forEach((e) => {
705
+ (e.type === "line" || !e.type) && Va(e), q.value && (Ha(e), r.value.showDataLabels && [!0, void 0].includes(e.dataLabels) && Ba(e));
706
+ }), Le.value = Ll(O.value)) : (Le.value && (n.value.clearRect(0, 0, 1e4, 1e4), n.value.drawImage(Le.value, 0, 0)), d.value !== null && a.value.style.chart.selector.show && oa(), d.value !== null && h.value.forEach((e) => {
707
+ if (e.type === "line" || !e.type || e.type === "plot") {
708
+ if (!e.coordinatesLine[d.value]) return;
709
+ e.coordinatesLine[d.value].x !== void 0 && e.coordinatesLine[d.value].y !== void 0 && xa(
710
+ n.value,
711
+ {
712
+ x: e.coordinatesLine[d.value].x,
713
+ y: e.coordinatesLine[d.value].y
714
+ },
715
+ f.value / 150 * a.value.style.chart.line.plots.radiusRatio,
716
+ {
717
+ color: a.value.style.chart.backgroundColor,
718
+ fillStyle: e.color
719
+ }
720
+ );
721
+ }
722
+ })), a.value.style.chart.grid.x.timeLabels.show && Ua(), a.value.style.chart.selector.show && a.value.style.chart.selector.showHorizontalSelector && Wa(), _a(), Ya(), B.value = !1;
723
+ }
724
+ const me = ml(() => {
725
+ q.value = !0, Aa();
726
+ }, T.value > 200 ? 10 : 1, !q.value);
727
+ function ne(e) {
728
+ if ([null, void 0].includes(d.value) || !e.coordinatesLine[d.value]) return !1;
729
+ const { y: l, value: o } = e.coordinatesLine[d.value];
730
+ return { y: l, value: o };
731
+ }
732
+ function Ga(e) {
733
+ const { left: l, top: o } = O.value.getBoundingClientRect(), s = e.clientX - l;
734
+ if (M.value = (e.clientY - o) * 2, (M.value < t.value.top || M.value > t.value.bottom) && (M.value = null), s * 2 < t.value.left || s * 2 > t.value.right) {
735
+ ye.value = !1, d.value = null;
736
+ return;
737
+ }
738
+ const i = s * 2 - t.value.left;
739
+ if (d.value = Math.floor(i / t.value.slot), ye.value = !0, !q.value) return;
740
+ let x = "";
741
+ const v = a.value.style.chart.tooltip.customFormat;
742
+ ba(v) && gl(() => v({
743
+ seriesIndex: d.value,
744
+ datapoint: h.value.map((y) => ({
745
+ shape: y.shape || null,
746
+ name: y.name,
747
+ color: y.color,
748
+ type: y.type || "line",
749
+ value: y.series.find((W, z) => z === d.value)
750
+ })),
751
+ series: h.value,
752
+ config: a.value
753
+ })) ? ge.value = v({
754
+ seriesIndex: d.value,
755
+ datapoint: h.value.map((y) => ({
756
+ shape: y.shape || null,
757
+ name: y.name,
758
+ color: y.color,
759
+ type: y.type || "line",
760
+ value: y.series.find((W, z) => z === d.value)
761
+ })),
762
+ series: h.value,
763
+ config: a.value
764
+ }) : (a.value.style.chart.grid.x.timeLabels.values.slice(u.value.start, u.value.end)[d.value] && (x += `<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${a.value.style.chart.tooltip.borderColor}; width:100%">${U.value.slice(u.value.start, u.value.end)[d.value].text}</div>`), x += Fa.value.join(""), ge.value = x), q.value = !1;
765
+ }
766
+ D(() => d.value, (e) => {
767
+ me();
768
+ }), D(() => u.value, (e) => {
769
+ B.value = !0, se();
770
+ }, {
771
+ deep: !0
772
+ }), D(() => r.value.showDataLabels, (e) => {
773
+ B.value = !0, se();
774
+ }), D(() => M.value, (e) => {
775
+ e && se();
776
+ }), D(() => r.value.stacked, (e) => {
777
+ B.value = !0, q.value = !0, me();
778
+ });
779
+ function ja() {
780
+ ye.value = !1, d.value = null, ge.value = "", M.value = null, se();
781
+ }
782
+ const A = Me(null), K = Me(null), Q = Me(null);
783
+ ha(() => {
784
+ Ue.value = !0, $e();
785
+ });
786
+ function $e() {
787
+ if (dl(g.dataset) ? hl({
788
+ componentName: "VueUiXyCanvas",
789
+ type: "dataset"
790
+ }) : O.value && (n.value = O.value.getContext("2d", { willReadFrequently: !0 })), a.value.responsive) {
791
+ const e = bl(() => {
792
+ const { width: l, height: o } = xl({
793
+ chart: I.value,
794
+ title: a.value.style.chart.title.text ? He.value : null,
795
+ legend: a.value.style.chart.legend.show ? Ye.value : null,
796
+ slicer: a.value.style.chart.zoom.show && T.value > 1 ? _e.value : null,
797
+ source: Be.value
798
+ });
799
+ requestAnimationFrame(() => {
800
+ Ze.value = `${l} / ${o}`;
801
+ });
802
+ });
803
+ A.value && (K.value && A.value.unobserve(K.value), A.value.disconnect()), A.value = new ResizeObserver(e), K.value = I.value.parentNode, A.value.observe(K.value);
804
+ }
805
+ Q.value && Q.value.disconnect(), Q.value = new ResizeObserver((e) => {
806
+ for (const l of e)
807
+ l.contentBoxSize && oe.value && (B.value = !0, me());
808
+ }), Q.value.observe(oe.value), ta();
809
+ }
810
+ al(() => {
811
+ Q.value && Q.value.disconnect(), A.value && (K.value && A.value.unobserve(K.value), A.value.disconnect());
812
+ });
813
+ function ua(e) {
814
+ Oa("selectLegend", h.value.find((l) => l.absoluteIndex === e)), $.value.includes(e) ? $.value = $.value.filter((l) => l !== e) : $.value.push(e), B.value = !0, me();
815
+ }
816
+ const ra = L(() => J.value.map((e, l) => ({
817
+ ...e,
818
+ name: e.name,
819
+ color: ma(e.color) || Qe.value[l] || G[l] || G[l % G.length],
820
+ shape: e.shape || "circle",
821
+ prefix: e.prefix || "",
822
+ suffix: e.suffix || "",
823
+ rounding: e.rounding || 0
824
+ })).map((e) => ({
825
+ ...e,
826
+ opacity: $.value.includes(e.absoluteIndex) ? 0.5 : 1,
827
+ segregate: () => ua(e.absoluteIndex),
828
+ isSegregated: $.value.includes(e.absoluteIndex)
829
+ }))), qa = L(() => ({
830
+ cy: "donut-div-legend",
831
+ backgroundColor: a.value.style.chart.legend.backgroundColor,
832
+ color: a.value.style.chart.legend.color,
833
+ fontSize: a.value.style.chart.legend.fontSize,
834
+ paddingBottom: 12,
835
+ fontWeight: a.value.style.chart.legend.bold ? "bold" : ""
836
+ })), be = L(() => {
837
+ const e = [""].concat(h.value.map((i) => i.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>');
838
+ let l = [];
839
+ for (let i = 0; i < T.value; i += 1) {
840
+ const x = h.value.map((v) => v.series[i] ?? 0).reduce((v, y) => v + y, 0);
841
+ l.push([a.value.style.chart.grid.x.timeLabels.values.slice(u.value.start, u.value.end)[i] ? U.value.slice(u.value.start, u.value.end)[i].text : i + 1].concat(h.value.map((v) => (v.series[i] ?? 0).toFixed(a.value.table.rounding))).concat((x ?? 0).toFixed(a.value.table.rounding)));
842
+ }
843
+ const o = {
844
+ th: {
845
+ backgroundColor: a.value.table.th.backgroundColor,
846
+ color: a.value.table.th.color,
847
+ outline: a.value.table.th.outline
848
+ },
849
+ td: {
850
+ backgroundColor: a.value.table.td.backgroundColor,
851
+ color: a.value.table.td.color,
852
+ outline: a.value.table.td.outline
853
+ },
854
+ breakpoint: a.value.table.responsiveBreakpoint
855
+ }, s = [a.value.table.columnNames.period].concat(h.value.map((i) => i.name)).concat(a.value.table.columnNames.total);
856
+ return { head: e, body: l.slice(0, u.value.end - u.value.start), config: o, colNames: s };
857
+ }), sa = L(() => {
858
+ if (h.value.length === 0) return { head: [], body: [], config: {}, columnNames: [] };
859
+ const e = h.value.map((o) => ({
860
+ label: o.name,
861
+ color: o.color,
862
+ type: o.type
863
+ })), l = [];
864
+ for (let o = u.value.start; o < u.value.end; o += 1) {
865
+ const s = [a.value.style.chart.grid.x.timeLabels.values[o] ? U.value[o].text : o + 1];
866
+ h.value.forEach((i) => {
867
+ s.push(Number((i.series[o] || 0).toFixed(a.value.table.rounding)));
868
+ }), l.push(s);
869
+ }
870
+ return { head: e, body: l };
871
+ });
872
+ function Te(e = null) {
873
+ const l = [[a.value.style.chart.title.text], [a.value.style.chart.title.subtitle.text], [""]], o = ["", ...sa.value.head.map((v) => v.label)], s = sa.value.body, i = l.concat([o]).concat(s), x = fl(i);
874
+ e ? e(x) : yl({ csvContent: x, title: a.value.style.chart.title.text || "vue-ui-xy-canvas" });
875
+ }
876
+ function Ja() {
877
+ return h.value;
878
+ }
879
+ function na() {
880
+ r.value.showTable = !r.value.showTable;
881
+ }
882
+ function ia() {
883
+ r.value.showDataLabels = !r.value.showDataLabels;
884
+ }
885
+ function va() {
886
+ r.value.stacked = !r.value.stacked;
887
+ }
888
+ function ca() {
889
+ r.value.showTooltip = !r.value.showTooltip;
890
+ }
891
+ const xe = c(!1);
892
+ function Ie() {
893
+ xe.value = !xe.value;
894
+ }
895
+ async function Ka({ scale: e = 2 } = {}) {
896
+ if (!I.value) return;
897
+ const { width: l, height: o } = I.value.getBoundingClientRect(), s = l / o, { imageUri: i, base64: x } = await Rl({ domElement: I.value, base64: !0, img: !0, scale: e });
898
+ return {
899
+ imageUri: i,
900
+ base64: x,
901
+ title: a.value.style.chart.title.text,
902
+ width: l,
903
+ height: o,
904
+ aspectRatio: s
905
+ };
906
+ }
907
+ const ie = L(() => {
908
+ const e = a.value.table.useDialog && !a.value.table.show, l = r.value.showTable;
909
+ return {
910
+ component: e ? Ia : Ml,
911
+ title: `${a.value.style.chart.title.text}${a.value.style.chart.title.subtitle.text ? `: ${a.value.style.chart.title.subtitle.text}` : ""}`,
912
+ props: e ? {
913
+ backgroundColor: a.value.table.th.backgroundColor,
914
+ color: a.value.table.th.color,
915
+ headerColor: a.value.table.th.color,
916
+ headerBg: a.value.table.th.backgroundColor,
917
+ isFullscreen: ue.value,
918
+ fullscreenParent: I.value,
919
+ forcedWidth: Math.min(800, window.innerWidth * 0.8)
920
+ } : {
921
+ hideDetails: !0,
922
+ config: {
923
+ open: l,
924
+ maxHeight: 1e4,
925
+ body: {
926
+ backgroundColor: a.value.style.chart.backgroundColor,
927
+ color: a.value.style.chart.color
928
+ },
929
+ head: {
930
+ backgroundColor: a.value.style.chart.backgroundColor,
931
+ color: a.value.style.chart.color
932
+ }
933
+ }
934
+ }
935
+ };
936
+ });
937
+ D(() => r.value.showTable, (e) => {
938
+ a.value.table.show || (e && a.value.table.useDialog && re.value ? re.value.open() : "close" in re.value && re.value.close());
939
+ });
940
+ function da() {
941
+ r.value.showTable = !1, Se.value && Se.value.setTableIconState(!1);
942
+ }
943
+ return ka({
944
+ getData: Ja,
945
+ getImage: Ka,
946
+ generateCsv: Te,
947
+ generatePdf: qe,
948
+ generateImage: Je,
949
+ toggleTable: na,
950
+ toggleLabels: ia,
951
+ toggleStack: va,
952
+ toggleTooltip: ca,
953
+ toggleAnnotator: Ie,
954
+ toggleFullscreen: Ke
955
+ }), (e, l) => (S(), de("div", {
956
+ style: ae(`width:100%; position:relative; ${a.value.responsive ? "height: 100%" : ""}`),
957
+ ref_key: "xy",
958
+ ref: I,
959
+ id: `xy_canvas_${_.value}`,
960
+ class: ll(`vue-ui-donut ${ue.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
961
+ onMouseenter: l[5] || (l[5] = () => p(We)(!0)),
962
+ onMouseleave: l[6] || (l[6] = () => p(We)(!1))
963
+ }, [
964
+ a.value.style.chart.title.text ? (S(), de("div", {
965
+ key: 0,
966
+ ref_key: "chartTitle",
967
+ ref: He,
968
+ style: ae(`width:100%;background:${a.value.style.chart.backgroundColor};`)
969
+ }, [
970
+ (S(), F(Tl, {
971
+ key: `title_${ke.value}`,
972
+ config: {
973
+ title: {
974
+ cy: "xy-canvas-title",
975
+ ...a.value.style.chart.title
976
+ },
977
+ subtitle: {
978
+ cy: "xy-canvas-subtitle",
979
+ ...a.value.style.chart.title.subtitle
980
+ }
981
+ }
982
+ }, null, 8, ["config"]))
983
+ ], 4)) : H("", !0),
984
+ Y("div", {
985
+ id: `legend-top-${_.value}`
986
+ }, null, 8, El),
987
+ a.value.userOptions.show && pe.value && (p(Xe) || p(ze)) ? (S(), F(p(Ta), {
988
+ ref_key: "userOptionsRef",
989
+ ref: Se,
990
+ key: `user_option_${Ne.value}`,
991
+ backgroundColor: a.value.style.chart.backgroundColor,
992
+ color: a.value.style.chart.color,
993
+ isPrinting: p(Ge),
994
+ isImaging: p(je),
995
+ uid: _.value,
996
+ hasTooltip: a.value.userOptions.buttons.tooltip && a.value.style.chart.tooltip.show,
997
+ hasPdf: a.value.userOptions.buttons.pdf,
998
+ hasImg: a.value.userOptions.buttons.img,
999
+ hasXls: a.value.userOptions.buttons.csv,
1000
+ hasLabel: a.value.userOptions.buttons.labels,
1001
+ hasStack: Pe.dataset.length > 1 && a.value.userOptions.buttons.stack,
1002
+ hasFullscreen: a.value.userOptions.buttons.fullscreen,
1003
+ hasTable: u.value.end - u.value.start <= 730 && a.value.userOptions.buttons.table,
1004
+ isFullscreen: ue.value,
1005
+ isTooltip: r.value.showTooltip,
1006
+ isStacked: r.value.stacked,
1007
+ titles: { ...a.value.userOptions.buttonTitles },
1008
+ chartElement: I.value,
1009
+ position: a.value.userOptions.position,
1010
+ hasAnnotator: a.value.userOptions.buttons.annotator,
1011
+ isAnnotation: xe.value,
1012
+ callbacks: a.value.userOptions.callbacks,
1013
+ printScale: a.value.userOptions.print.scale,
1014
+ tableDialog: a.value.table.useDialog,
1015
+ onToggleFullscreen: Ke,
1016
+ onGeneratePdf: p(qe),
1017
+ onGenerateCsv: Te,
1018
+ onGenerateImage: p(Je),
1019
+ onToggleTable: na,
1020
+ onToggleLabels: ia,
1021
+ onToggleStack: va,
1022
+ onToggleTooltip: ca,
1023
+ onToggleAnnotator: Ie,
1024
+ style: ae({
1025
+ visibility: p(Xe) ? p(ze) ? "visible" : "hidden" : "visible"
1026
+ })
1027
+ }, ya({ _: 2 }, [
1028
+ e.$slots.menuIcon ? {
1029
+ name: "menuIcon",
1030
+ fn: m(({ isOpen: o, color: s }) => [
1031
+ k(e.$slots, "menuIcon", V(Z({ isOpen: o, color: s })), void 0, !0)
1032
+ ]),
1033
+ key: "0"
1034
+ } : void 0,
1035
+ e.$slots.optionTooltip ? {
1036
+ name: "optionTooltip",
1037
+ fn: m(() => [
1038
+ k(e.$slots, "optionTooltip", {}, void 0, !0)
1039
+ ]),
1040
+ key: "1"
1041
+ } : void 0,
1042
+ e.$slots.optionPdf ? {
1043
+ name: "optionPdf",
1044
+ fn: m(() => [
1045
+ k(e.$slots, "optionPdf", {}, void 0, !0)
1046
+ ]),
1047
+ key: "2"
1048
+ } : void 0,
1049
+ e.$slots.optionCsv ? {
1050
+ name: "optionCsv",
1051
+ fn: m(() => [
1052
+ k(e.$slots, "optionCsv", {}, void 0, !0)
1053
+ ]),
1054
+ key: "3"
1055
+ } : void 0,
1056
+ e.$slots.optionImg ? {
1057
+ name: "optionImg",
1058
+ fn: m(() => [
1059
+ k(e.$slots, "optionImg", {}, void 0, !0)
1060
+ ]),
1061
+ key: "4"
1062
+ } : void 0,
1063
+ e.$slots.optionTable ? {
1064
+ name: "optionTable",
1065
+ fn: m(() => [
1066
+ k(e.$slots, "optionTable", {}, void 0, !0)
1067
+ ]),
1068
+ key: "5"
1069
+ } : void 0,
1070
+ e.$slots.optionLabels ? {
1071
+ name: "optionLabels",
1072
+ fn: m(() => [
1073
+ k(e.$slots, "optionLabels", {}, void 0, !0)
1074
+ ]),
1075
+ key: "6"
1076
+ } : void 0,
1077
+ e.$slots.optionStack ? {
1078
+ name: "optionStack",
1079
+ fn: m(() => [
1080
+ k(e.$slots, "optionStack", {}, void 0, !0)
1081
+ ]),
1082
+ key: "7"
1083
+ } : void 0,
1084
+ e.$slots.optionFullscreen ? {
1085
+ name: "optionFullscreen",
1086
+ fn: m(({ toggleFullscreen: o, isFullscreen: s }) => [
1087
+ k(e.$slots, "optionFullscreen", V(Z({ toggleFullscreen: o, isFullscreen: s })), void 0, !0)
1088
+ ]),
1089
+ key: "8"
1090
+ } : void 0,
1091
+ e.$slots.optionAnnotator ? {
1092
+ name: "optionAnnotator",
1093
+ fn: m(({ toggleAnnotator: o, isAnnotator: s }) => [
1094
+ k(e.$slots, "optionAnnotator", V(Z({ toggleAnnotator: o, isAnnotator: s })), void 0, !0)
1095
+ ]),
1096
+ key: "9"
1097
+ } : void 0
1098
+ ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasLabel", "hasStack", "hasFullscreen", "hasTable", "isFullscreen", "isTooltip", "isStacked", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "tableDialog", "onGeneratePdf", "onGenerateImage", "style"])) : H("", !0),
1099
+ Y("div", {
1100
+ class: "vue-ui-xy-canvas",
1101
+ style: ae(`position: relative; aspect-ratio: ${Ze.value}`),
1102
+ ref_key: "container",
1103
+ ref: oe
1104
+ }, [
1105
+ pe.value ? (S(), de("canvas", {
1106
+ key: 0,
1107
+ ref_key: "canvas",
1108
+ ref: O,
1109
+ style: { width: "100%", height: "100%" },
1110
+ onMousemove: l[0] || (l[0] = (o) => Ga(o)),
1111
+ onMouseleave: ja
1112
+ }, null, 544)) : (S(), F(p(za), {
1113
+ key: 1,
1114
+ config: {
1115
+ type: "line",
1116
+ style: {
1117
+ backgroundColor: a.value.style.chart.backgroundColor,
1118
+ line: {
1119
+ axis: {
1120
+ color: "#CCCCCC"
1121
+ },
1122
+ path: {
1123
+ color: "#CCCCCC",
1124
+ strokeWidth: 0.5
1125
+ }
1126
+ }
1127
+ }
1128
+ }
1129
+ }, null, 8, ["config"])),
1130
+ ga(p($a), {
1131
+ show: r.value.showTooltip && ye.value,
1132
+ backgroundColor: a.value.style.chart.tooltip.backgroundColor,
1133
+ color: a.value.style.chart.tooltip.color,
1134
+ fontSize: a.value.style.chart.tooltip.fontSize,
1135
+ borderRadius: a.value.style.chart.tooltip.borderRadius,
1136
+ borderColor: a.value.style.chart.tooltip.borderColor,
1137
+ borderWidth: a.value.style.chart.tooltip.borderWidth,
1138
+ position: a.value.style.chart.tooltip.position,
1139
+ offsetY: a.value.style.chart.tooltip.offsetY,
1140
+ parent: p(O),
1141
+ content: ge.value,
1142
+ isFullscreen: ue.value,
1143
+ backgroundOpacity: a.value.style.chart.tooltip.backgroundOpacity,
1144
+ isCustom: p(ba)(a.value.style.chart.tooltip.customFormat),
1145
+ smooth: a.value.style.chart.tooltip.smooth,
1146
+ backdropFilter: a.value.style.chart.tooltip.backdropFilter,
1147
+ smoothForce: a.value.style.chart.tooltip.smoothForce,
1148
+ smoothSnapThreshold: a.value.style.chart.tooltip.smoothSnapThreshold
1149
+ }, {
1150
+ "tooltip-before": m(() => [
1151
+ k(e.$slots, "tooltip-before", V(Z({ ...Ee.value })), void 0, !0)
1152
+ ]),
1153
+ "tooltip-after": m(() => [
1154
+ k(e.$slots, "tooltip-after", V(Z({ ...Ee.value })), void 0, !0)
1155
+ ]),
1156
+ _: 3
1157
+ }, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "position", "offsetY", "parent", "content", "isFullscreen", "backgroundOpacity", "isCustom", "smooth", "backdropFilter", "smoothForce", "smoothSnapThreshold"])
1158
+ ], 4),
1159
+ Y("div", {
1160
+ ref_key: "chartSlicer",
1161
+ ref: _e,
1162
+ style: ae(`width:100%;background:${a.value.style.chart.backgroundColor}`),
1163
+ "data-dom-to-png-ignore": ""
1164
+ }, [
1165
+ a.value.style.chart.zoom.show && T.value > 1 ? (S(), F(Il, {
1166
+ ref_key: "slicerComponent",
1167
+ ref: la,
1168
+ key: `slicer_${Ae.value}`,
1169
+ background: a.value.style.chart.zoom.color,
1170
+ borderColor: a.value.style.chart.backgroundColor,
1171
+ fontSize: a.value.style.chart.zoom.fontSize,
1172
+ useResetSlot: a.value.style.chart.zoom.useResetSlot,
1173
+ labelLeft: a.value.style.chart.grid.x.timeLabels.values[u.value.start] ? U.value[u.value.start].text : "",
1174
+ labelRight: a.value.style.chart.grid.x.timeLabels.values[u.value.end - 1] ? U.value[u.value.end - 1].text : "",
1175
+ textColor: a.value.style.chart.color,
1176
+ inputColor: a.value.style.chart.zoom.color,
1177
+ selectColor: a.value.style.chart.zoom.highlightColor,
1178
+ max: T.value,
1179
+ min: 0,
1180
+ valueStart: u.value.start,
1181
+ valueEnd: u.value.end,
1182
+ start: u.value.start,
1183
+ "onUpdate:start": l[1] || (l[1] = (o) => u.value.start = o),
1184
+ end: u.value.end,
1185
+ "onUpdate:end": l[2] || (l[2] = (o) => u.value.end = o),
1186
+ refreshStartPoint: a.value.style.chart.zoom.startIndex !== null ? a.value.style.chart.zoom.startIndex : 0,
1187
+ refreshEndPoint: a.value.style.chart.zoom.endIndex !== null ? a.value.style.chart.zoom.endIndex + 1 : T.value,
1188
+ enableRangeHandles: a.value.style.chart.zoom.enableRangeHandles,
1189
+ enableSelectionDrag: a.value.style.chart.zoom.enableSelectionDrag,
1190
+ focusOnDrag: a.value.style.chart.zoom.focusOnDrag,
1191
+ focusRangeRatio: a.value.style.chart.zoom.focusRangeRatio,
1192
+ onReset: aa
1193
+ }, {
1194
+ "reset-action": m(({ reset: o }) => [
1195
+ k(e.$slots, "reset-action", V(Z({ reset: o })), void 0, !0)
1196
+ ]),
1197
+ _: 3
1198
+ }, 8, ["background", "borderColor", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "max", "valueStart", "valueEnd", "start", "end", "refreshStartPoint", "refreshEndPoint", "enableRangeHandles", "enableSelectionDrag", "focusOnDrag", "focusRangeRatio"])) : H("", !0)
1199
+ ], 4),
1200
+ Y("div", {
1201
+ id: `legend-bottom-${_.value}`
1202
+ }, null, 8, Al),
1203
+ Ue.value ? (S(), F(tl, {
1204
+ key: 2,
1205
+ to: a.value.style.chart.legend.position === "top" ? `#legend-top-${_.value}` : `#legend-bottom-${_.value}`
1206
+ }, [
1207
+ Y("div", {
1208
+ ref_key: "chartLegend",
1209
+ ref: Ye
1210
+ }, [
1211
+ a.value.style.chart.legend.show && pe.value ? (S(), F($l, {
1212
+ legendSet: ra.value,
1213
+ config: qa.value,
1214
+ key: `legend_${we.value}`,
1215
+ onClickMarker: l[3] || (l[3] = ({ i: o }) => ua(o))
1216
+ }, {
1217
+ item: m(({ legend: o, index: s }) => [
1218
+ Y("div", {
1219
+ onClick: (i) => o.segregate(),
1220
+ style: ae(`opacity:${$.value.includes(s) ? 0.5 : 1}`)
1221
+ }, Oe(o.name), 13, Nl)
1222
+ ]),
1223
+ _: 1
1224
+ }, 8, ["legendSet", "config"])) : k(e.$slots, "legend", {
1225
+ key: 1,
1226
+ legend: ra.value
1227
+ }, void 0, !0)
1228
+ ], 512)
1229
+ ], 8, ["to"])) : H("", !0),
1230
+ e.$slots.watermark ? (S(), de("div", Hl, [
1231
+ k(e.$slots, "watermark", V(Z({ isPrinting: p(Ge) || p(je) })), void 0, !0)
1232
+ ])) : H("", !0),
1233
+ e.$slots.source ? (S(), de("div", {
1234
+ key: 4,
1235
+ ref_key: "source",
1236
+ ref: Be,
1237
+ dir: "auto"
1238
+ }, [
1239
+ k(e.$slots, "source", {}, void 0, !0)
1240
+ ], 512)) : H("", !0),
1241
+ pe.value && a.value.userOptions.buttons.table ? (S(), F(ol(ie.value.component), ul({ key: 5 }, ie.value.props, {
1242
+ ref_key: "tableUnit",
1243
+ ref: re,
1244
+ onClose: da
1245
+ }), ya({
1246
+ content: m(() => [
1247
+ (S(), F(p(wa), {
1248
+ key: `table_${Ce.value}`,
1249
+ colNames: be.value.colNames,
1250
+ head: be.value.head,
1251
+ body: be.value.body,
1252
+ config: be.value.config,
1253
+ title: a.value.table.useDialog ? "" : ie.value.title,
1254
+ withCloseButton: !a.value.table.useDialog,
1255
+ onClose: da
1256
+ }, {
1257
+ th: m(({ th: o }) => [
1258
+ Y("div", { innerHTML: o }, null, 8, Yl)
1259
+ ]),
1260
+ td: m(({ td: o }) => [
1261
+ pa(Oe(o), 1)
1262
+ ]),
1263
+ _: 1
1264
+ }, 8, ["colNames", "head", "body", "config", "title", "withCloseButton"]))
1265
+ ]),
1266
+ _: 2
1267
+ }, [
1268
+ a.value.table.useDialog ? {
1269
+ name: "title",
1270
+ fn: m(() => [
1271
+ pa(Oe(ie.value.title), 1)
1272
+ ]),
1273
+ key: "0"
1274
+ } : void 0,
1275
+ a.value.table.useDialog ? {
1276
+ name: "actions",
1277
+ fn: m(() => [
1278
+ Y("button", {
1279
+ tabindex: "0",
1280
+ class: "vue-ui-user-options-button",
1281
+ onClick: l[4] || (l[4] = (o) => Te(a.value.userOptions.callbacks.csv))
1282
+ }, [
1283
+ ga(Dl, {
1284
+ name: "excel",
1285
+ stroke: ie.value.props.color
1286
+ }, null, 8, ["stroke"])
1287
+ ])
1288
+ ]),
1289
+ key: "1"
1290
+ } : void 0
1291
+ ]), 1040)) : H("", !0),
1292
+ a.value.userOptions.buttons.annotator && h.value.length ? (S(), F(p(Sa), {
1293
+ key: 6,
1294
+ parent: I.value,
1295
+ backgroundColor: a.value.style.chart.backgroundColor,
1296
+ color: a.value.style.chart.color,
1297
+ active: xe.value,
1298
+ onClose: Ie
1299
+ }, null, 8, ["parent", "backgroundColor", "color", "active"])) : H("", !0)
1300
+ ], 46, Pl));
1301
+ }
1302
+ }, ot = /* @__PURE__ */ Fl(_l, [["__scopeId", "data-v-51365208"]]);
1303
+ export {
1304
+ ot as default
1305
+ };