vue-data-ui 3.0.0-next.41 → 3.0.0-next.43

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 (91) hide show
  1. package/dist/{Arrow-FZbM_OMm.js → Arrow-Bd6Ph2ch.js} +1 -1
  2. package/dist/{BaseDraggableDialog-rjsCDxdM.js → BaseDraggableDialog-C--SKjDO.js} +2 -2
  3. package/dist/{BaseIcon-d5M_8gn6.js → BaseIcon-D7epehwu.js} +1 -1
  4. package/dist/{ColorPicker-Br0iohs5.js → ColorPicker-BH0rB6ld.js} +2 -2
  5. package/dist/{DataTable-CyFoVhAB.js → DataTable-BB8Wz165.js} +2 -2
  6. package/dist/{Legend-BY-3lPeC.js → Legend-vx12pxjd.js} +2 -2
  7. package/dist/{NonSvgPenAndPaper-DjILEBYN.js → NonSvgPenAndPaper-BmmU-AcQ.js} +3 -3
  8. package/dist/{PackageVersion-QefvdSlr.js → PackageVersion-D218wea-.js} +1 -1
  9. package/dist/{PenAndPaper-CeTnED7E.js → PenAndPaper-dIGZM-jo.js} +3 -3
  10. package/dist/{Shape-ClINMlel.js → Shape-DWkgkl1v.js} +1 -1
  11. package/dist/{Slicer-CTVgtwAo.js → Slicer-LE0PTt3i.js} +2 -2
  12. package/dist/{SparkTooltip-D7iBCVUT.js → SparkTooltip-CCmYl6zn.js} +1 -1
  13. package/dist/{Title-C2MeWc6b.js → Title-BYwMvy7Q.js} +1 -1
  14. package/dist/{Tooltip-CyC0lofV.js → Tooltip-CIqkHlwJ.js} +1 -1
  15. package/dist/{UserOptions-Q4MLYmK1.js → UserOptions-BSMOmm78.js} +2 -2
  16. package/dist/{dom-to-png-Bmhnn6-_.js → dom-to-png-C56Fv7JN.js} +1 -1
  17. package/dist/{img-1ZBpWF3A.js → img-DdFXJwAG.js} +1 -1
  18. package/dist/{index-D-ozSgn5.js → index-seTAwZa0.js} +36 -5
  19. package/dist/{pdf-Dm9wepT-.js → pdf-Dl8ZF3y5.js} +1 -1
  20. package/dist/style.css +1 -1
  21. package/dist/types/vue-data-ui.d.cts +38 -1
  22. package/dist/types/vue-data-ui.d.ts +38 -1
  23. package/dist/{useNestedProp-xgFDyd-D.js → useNestedProp-CU8l_fXF.js} +1 -1
  24. package/dist/{usePrinter-CyhyubAW.js → usePrinter-Dk2fZbxG.js} +2 -2
  25. package/dist/{vue-data-ui-BvqaMmwo.js → vue-data-ui-DiluSkKR.js} +64 -64
  26. package/dist/vue-data-ui.js +1 -1
  27. package/dist/{vue-ui-3d-bar-wFrj_nHo.js → vue-ui-3d-bar-D9JzKCj3.js} +6 -6
  28. package/dist/{vue-ui-accordion-CzcfvDc6.js → vue-ui-accordion-BV8sqaEM.js} +3 -3
  29. package/dist/{vue-ui-age-pyramid-C06opmye.js → vue-ui-age-pyramid-ooNy9i5a.js} +6 -6
  30. package/dist/{vue-ui-annotator-rLnZGNrU.js → vue-ui-annotator-C1isLUoY.js} +2 -2
  31. package/dist/{vue-ui-bullet-BrtBslm2.js → vue-ui-bullet-BJEvtumk.js} +7 -7
  32. package/dist/{vue-ui-candlestick-CTHK4Nkb.js → vue-ui-candlestick-7T6fVigp.js} +7 -7
  33. package/dist/{vue-ui-carousel-table-BEot5M0l.js → vue-ui-carousel-table-CHrwQJKm.js} +4 -4
  34. package/dist/{vue-ui-chestnut-C4xlmyWV.js → vue-ui-chestnut-1dMZKU8l.js} +5 -5
  35. package/dist/{vue-ui-chord-odv0oGun.js → vue-ui-chord-BDMYLMI6.js} +8 -8
  36. package/dist/{vue-ui-circle-pack-Dv7OO-jl.js → vue-ui-circle-pack-DBZ38AiG.js} +6 -6
  37. package/dist/{vue-ui-cursor-CHPi6ptC.js → vue-ui-cursor-cymBdQPf.js} +2 -2
  38. package/dist/{vue-ui-dashboard-yZ6EoUYB.js → vue-ui-dashboard-p97MvAL1.js} +62 -62
  39. package/dist/{vue-ui-digits-C502piFU.js → vue-ui-digits-DVP-mqGl.js} +2 -2
  40. package/dist/{vue-ui-donut-XKTZp6vn.js → vue-ui-donut-DUuJbxDd.js} +8 -8
  41. package/dist/{vue-ui-donut-evolution-BETQ3m-1.js → vue-ui-donut-evolution-COL2Q6T8.js} +8 -8
  42. package/dist/{vue-ui-dumbbell-B0koyYHY.js → vue-ui-dumbbell-CIjWYz3j.js} +7 -7
  43. package/dist/{vue-ui-flow-BOXbr-B4.js → vue-ui-flow-D0DtQP8s.js} +7 -7
  44. package/dist/{vue-ui-funnel-BuLuXMWN.js → vue-ui-funnel-DjondOD5.js} +6 -6
  45. package/dist/{vue-ui-galaxy-Duo4_PQ0.js → vue-ui-galaxy-TlGKc0Se.js} +5 -5
  46. package/dist/{vue-ui-gauge-CzvkhWyr.js → vue-ui-gauge-CEKh6wdN.js} +6 -6
  47. package/dist/{vue-ui-gizmo-C_s3Mad5.js → vue-ui-gizmo-KHlyl1I_.js} +3 -3
  48. package/dist/{vue-ui-heatmap-BfPyDKrE.js → vue-ui-heatmap-O-XLCBYP.js} +7 -7
  49. package/dist/vue-ui-history-plot-BFRVky6o.js +1073 -0
  50. package/dist/{vue-ui-kpi-BAFYYyfo.js → vue-ui-kpi-C4pD97vb.js} +3 -3
  51. package/dist/{vue-ui-mini-loader-DUDhlnIj.js → vue-ui-mini-loader-CFx2urSq.js} +2 -2
  52. package/dist/{vue-ui-molecule-Dng9xRXp.js → vue-ui-molecule-CzvTkkvk.js} +5 -5
  53. package/dist/{vue-ui-mood-radar-CZITumE0.js → vue-ui-mood-radar-Bd1PtwHi.js} +7 -7
  54. package/dist/{vue-ui-nested-donuts-BvLGT-wp.js → vue-ui-nested-donuts-D81ruw2p.js} +9 -9
  55. package/dist/{vue-ui-onion-BVXel8xL.js → vue-ui-onion-_m4Fz3Zv.js} +7 -7
  56. package/dist/{vue-ui-parallel-coordinate-plot-CCVeKuyk.js → vue-ui-parallel-coordinate-plot-BAsS-UhV.js} +8 -8
  57. package/dist/{vue-ui-quadrant-CvH-NZdr.js → vue-ui-quadrant-EdLEsbQj.js} +8 -8
  58. package/dist/{vue-ui-quick-chart-Cw9hhg7p.js → vue-ui-quick-chart-CvI_F1vi.js} +6 -6
  59. package/dist/{vue-ui-radar-CgOon7mZ.js → vue-ui-radar-ChHw9L0L.js} +7 -7
  60. package/dist/{vue-ui-rating-B5c-kqdn.js → vue-ui-rating-_759UJ0S.js} +2 -2
  61. package/dist/{vue-ui-relation-circle-qt6Rkmmg.js → vue-ui-relation-circle-BE7IyKPH.js} +6 -6
  62. package/dist/vue-ui-ridgeline-DDmQ0KEQ.js +1153 -0
  63. package/dist/{vue-ui-rings-CRRnF21q.js → vue-ui-rings-DYR2Zffo.js} +8 -8
  64. package/dist/{vue-ui-scatter-CmFDRXa2.js → vue-ui-scatter-ndISiTaO.js} +8 -8
  65. package/dist/{vue-ui-skeleton-CIU55VVP.js → vue-ui-skeleton-NmSoASV8.js} +3 -3
  66. package/dist/{vue-ui-smiley-BBTuuurS.js → vue-ui-smiley-DD3AcPoa.js} +2 -2
  67. package/dist/{vue-ui-spark-trend-CfCb4r4K.js → vue-ui-spark-trend-CRFIrsdc.js} +3 -3
  68. package/dist/{vue-ui-sparkbar-CY2g4HPf.js → vue-ui-sparkbar-DYaUzFFQ.js} +3 -3
  69. package/dist/{vue-ui-sparkgauge-0xVecWxL.js → vue-ui-sparkgauge-DFFPfZpj.js} +3 -3
  70. package/dist/{vue-ui-sparkhistogram-DXT4M8c6.js → vue-ui-sparkhistogram-DAXOYsKU.js} +4 -4
  71. package/dist/{vue-ui-sparkline-BgUGZ1AX.js → vue-ui-sparkline-Dq98pgZo.js} +3 -3
  72. package/dist/{vue-ui-sparkstackbar-ic4Q92W2.js → vue-ui-sparkstackbar-DHm7zDFw.js} +3 -3
  73. package/dist/{vue-ui-stackbar-C1K77Eph.js → vue-ui-stackbar-DGcjtz2t.js} +9 -9
  74. package/dist/{vue-ui-strip-plot-B-EluNpw.js → vue-ui-strip-plot-mg7SEjXG.js} +7 -7
  75. package/dist/{vue-ui-table-D8yiQSAZ.js → vue-ui-table-ClPA8SKE.js} +3 -3
  76. package/dist/{vue-ui-table-heatmap-BV03Xipx.js → vue-ui-table-heatmap-B412nk-m.js} +5 -5
  77. package/dist/{vue-ui-table-sparkline-BJDrPMNM.js → vue-ui-table-sparkline-L_G0kf0u.js} +4 -4
  78. package/dist/{vue-ui-thermometer-BfTaCEvy.js → vue-ui-thermometer-CHa-MhGY.js} +6 -6
  79. package/dist/{vue-ui-timer-yaD9CnrU.js → vue-ui-timer-wVinu4ky.js} +5 -5
  80. package/dist/{vue-ui-tiremarks-DZmn0x0x.js → vue-ui-tiremarks-3Ku4fPPU.js} +6 -6
  81. package/dist/{vue-ui-treemap-cLoY4lkA.js → vue-ui-treemap-B8sSc70D.js} +8 -8
  82. package/dist/{vue-ui-vertical-bar-CptPUybG.js → vue-ui-vertical-bar-DLdtQziT.js} +9 -9
  83. package/dist/{vue-ui-waffle-C6_JY56k.js → vue-ui-waffle-CC71XEn9.js} +8 -8
  84. package/dist/{vue-ui-wheel-CZa3V2a8.js → vue-ui-wheel-CI_xJP2J.js} +6 -6
  85. package/dist/{vue-ui-word-cloud-Bwa3o0gV.js → vue-ui-word-cloud-76QvSUIu.js} +6 -6
  86. package/dist/{vue-ui-world-Dk4VR0iE.js → vue-ui-world-BhDu6-N4.js} +6 -6
  87. package/dist/{vue-ui-xy-CLRcmnNU.js → vue-ui-xy-BBqz-9hP.js} +9 -9
  88. package/dist/{vue-ui-xy-canvas-CVW7Wok4.js → vue-ui-xy-canvas-BEsL3iix.js} +8 -8
  89. package/package.json +1 -1
  90. package/dist/vue-ui-history-plot-11zollOK.js +0 -926
  91. package/dist/vue-ui-ridgeline-BbLx23HV.js +0 -971
@@ -1,971 +0,0 @@
1
- import { defineAsyncComponent as O, computed as f, ref as u, shallowRef as Be, onMounted as Nt, onBeforeUnmount as Ft, watch as Ue, createElementBlock as n, openBlock as r, unref as i, normalizeStyle as _, normalizeClass as q, createBlock as P, createCommentVNode as c, renderSlot as p, createElementVNode as d, createSlots as Ge, withCtx as m, normalizeProps as K, guardReactiveProps as J, createVNode as We, Fragment as g, renderList as A, mergeProps as je, toDisplayString as V, createTextVNode as Ye, nextTick as Dt } from "vue";
2
- import { u as It, c as ve, o as Rt, e as he, g as qe, b as Xt, d as Et, p as Q, ao as Ke, ah as Ht, U as Je, V as Vt, W as Bt, X as Ut, F as Gt, I as Wt, i as Z, f as ee, t as jt, a as Yt, q as qt, r as Kt, K as Jt } from "./index-D-ozSgn5.js";
3
- import { u as Qt } from "./useUserOptionState-BIvW1Kz7.js";
4
- import { u as Zt } from "./useChartAccessibility-9icAAmYg.js";
5
- import { u as el } from "./usePrinter-CyhyubAW.js";
6
- import { t as tl, u as ll } from "./useResponsive-DfdjqQps.js";
7
- import { u as Qe } from "./useNestedProp-xgFDyd-D.js";
8
- import al from "./Legend-BY-3lPeC.js";
9
- import sl from "./Title-C2MeWc6b.js";
10
- import { _ as ol } from "./Shape-ClINMlel.js";
11
- import { u as rl } from "./useTimeLabels-DkzmKfZn.js";
12
- import nl from "./img-1ZBpWF3A.js";
13
- import { _ as il } from "./_plugin-vue_export-helper-CHgC5LLL.js";
14
- const ul = ["id"], cl = ["xmlns", "viewBox"], vl = ["id"], hl = ["stop-color"], dl = ["stop-color"], yl = ["stop-color"], fl = ["stop-color"], gl = ["id"], pl = ["stop-color"], ml = ["stop-color"], bl = ["stop-color"], xl = ["stop-color"], kl = { key: 0 }, Al = ["fill", "d"], wl = ["stroke", "stroke-width", "d"], $l = ["fill", "d"], Cl = ["stroke", "stroke-dasharray", "stroke-width", "d"], _l = ["x1", "y1", "x2", "y2", "stroke", "stroke-width", "stroke-dasharray"], Ml = ["cx", "cy", "stroke", "stroke-width", "r", "fill"], Pl = ["x", "y", "font-size", "font-weight", "fill", "text-decoration", "onMouseenter", "onClick"], Tl = { key: 0 }, Sl = { key: 0 }, zl = ["font-size", "fill", "font-weight", "transform", "text-anchor"], Ol = ["font-size", "fill", "font-weight", "transform", "text-anchor", "innerHTML"], Ll = ["x", "y", "width", "height", "onMouseenter", "onClick"], Nl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Fl = ["cx", "cy", "stroke", "stroke-width", "r", "fill"], Dl = ["x", "y", "text-anchor", "font-size", "fill"], Il = {
15
- key: 5,
16
- class: "vue-data-ui-watermark"
17
- }, Rl = ["onClick"], Xl = ["innerHTML"], El = {
18
- __name: "vue-ui-ridgeline",
19
- props: {
20
- config: {
21
- type: Object,
22
- default() {
23
- return {};
24
- }
25
- },
26
- dataset: {
27
- type: Array,
28
- default() {
29
- return [];
30
- }
31
- }
32
- },
33
- emits: ["selectLegend", "selectDatapoint", "selectX"],
34
- setup(Ze, { expose: et, emit: tt }) {
35
- const lt = O(() => import("./vue-ui-accordion-CzcfvDc6.js")), at = O(() => import("./BaseDraggableDialog-rjsCDxdM.js")), st = O(() => import("./DataTable-CyFoVhAB.js")), ot = O(() => import("./PackageVersion-QefvdSlr.js")), rt = O(() => import("./PenAndPaper-CeTnED7E.js")), nt = O(() => import("./vue-ui-skeleton-CIU55VVP.js")), it = O(() => import("./UserOptions-Q4MLYmK1.js")), ut = O(() => import("./vue-ui-xy-CLRcmnNU.js")), { vue_ui_ridgeline: ct } = It(), k = Ze, L = f({
36
- get() {
37
- return !!k.dataset && k.dataset.length;
38
- },
39
- set(l) {
40
- return l;
41
- }
42
- }), te = tt, T = u(null), de = u(null), ye = u(null), S = Be(null), I = Be(null), fe = u(null), ge = u(null), pe = u(0), vt = u(0), me = u(0), w = u(ve()), be = u(0), ht = u(0), xe = u(512), v = u(null), R = u(null), le = u(null), ke = u(0);
43
- function Ae() {
44
- const l = Qe({
45
- userConfig: k.config,
46
- defaultConfig: ct
47
- });
48
- return l.theme ? {
49
- ...Qe({
50
- userConfig: Yt.vue_ui_ridgeline[l.theme] || k.config,
51
- defaultConfig: l
52
- }),
53
- customPalette: jt[l.theme] || Q
54
- } : l;
55
- }
56
- const e = f({
57
- get: () => Ae(),
58
- set: (l) => l
59
- }), $ = u(Math.min(
60
- e.value.style.chart.areas.height,
61
- e.value.style.chart.areas.rowHeight
62
- )), {
63
- userOptionsVisible: ae,
64
- setUserOptionsVisibility: we,
65
- keepUserOptionState: $e
66
- } = Qt({ config: e.value }), { svgRef: se } = Zt({ config: e.value.style.chart.title });
67
- Nt(oe);
68
- function oe() {
69
- if (Rt(k.dataset) ? he({
70
- componentName: "VueUiRidgeline",
71
- type: "dataset"
72
- }) : k.dataset.forEach((l, o) => {
73
- qe({
74
- datasetObject: l,
75
- requiredAttributes: ["name", "datapoints"]
76
- }).forEach((t) => {
77
- L.value = !1, he({
78
- componentName: "VueUiRidgeline",
79
- type: "datasetSerieAttribute",
80
- property: t,
81
- index: o
82
- });
83
- }), l.datapoints.length && l.datapoints.forEach((t, s) => {
84
- qe({
85
- datasetObject: t,
86
- requiredAttributes: ["name", "values"]
87
- }).forEach((a) => {
88
- L.value = !1, he({
89
- componentName: "VueUiRidgeline",
90
- type: "datasetSerieAttribute",
91
- property: `datapoint.${a}`,
92
- index: `${o}-${s}`
93
- });
94
- });
95
- });
96
- }), ht.value = k.dataset.length, $.value = Math.min(
97
- e.value.style.chart.areas.height,
98
- e.value.style.chart.areas.rowHeight
99
- ), e.value.responsive) {
100
- const l = tl(() => {
101
- const { width: o, height: t } = ll({
102
- chart: T.value,
103
- title: e.value.style.chart.title.text ? de.value : null,
104
- legend: e.value.style.chart.legend.show ? ye.value : null,
105
- source: fe.value,
106
- noTitle: ge.value,
107
- padding: e.value.style.chart.padding
108
- });
109
- requestAnimationFrame(() => {
110
- xe.value = o, $.value = t / k.dataset.length, ke.value = t;
111
- });
112
- });
113
- S.value && (I.value && S.value.unobserve(I.value), S.value.disconnect()), S.value = new ResizeObserver(l), I.value = T.value.parentNode, S.value.observe(I.value);
114
- }
115
- }
116
- Ft(() => {
117
- S.value && (I.value && S.value.unobserve(I.value), S.value.disconnect());
118
- });
119
- const { isPrinting: Ce, isImaging: _e, generatePdf: Me, generateImage: Pe } = el({
120
- elementId: `vue-ui-ridgeline_${w.value}`,
121
- fileName: e.value.style.chart.title.text || "vue-ui-ridgeline",
122
- options: e.value.userOptions.print
123
- }), dt = f(() => e.value.userOptions.show && !e.value.style.chart.title.text), yt = f(() => Xt(e.value.customPalette)), B = u({
124
- showTable: e.value.table.show
125
- });
126
- Ue(() => k.config, (l) => {
127
- e.value = Ae(), ae.value = !e.value.userOptions.showOnChartHover, oe(), pe.value += 1, me.value += 1, $.value = Math.min(
128
- e.value.style.chart.areas.height,
129
- e.value.style.chart.areas.rowHeight
130
- ), B.value.showTable = e.value.table.show;
131
- }, { deep: !0 }), Ue(() => k.dataset, oe, { deep: !0 });
132
- const re = f(() => e.value.style.chart.areas.height / e.value.style.chart.areas.rowHeight);
133
- function Te(l) {
134
- z.value.includes(l) ? z.value = z.value.filter((o) => o !== l) : z.value.push(l), te("selectLegend", E.value);
135
- }
136
- const M = f(() => L.value ? k.dataset.map((l, o) => ({
137
- ...l,
138
- labelLen: pt(l.name, e.value.style.chart.yAxis.labels.fontSize),
139
- uid: ve(),
140
- datapoints: l.datapoints.map((t, s) => {
141
- const a = t.color ? Et(t.color) : yt.value[s] || Q[s] || Q[s % Q.length], h = Ke(t.name);
142
- return {
143
- ...t,
144
- color: a,
145
- id: h
146
- };
147
- })
148
- })) : []), Se = f(() => e.value.style.chart.padding.top + $.value * k.dataset.length + $.value * re.value), b = f(() => ({
149
- fullHeight: y.value.padding.top + y.value.padding.bottom + y.value.height,
150
- top: y.value.padding.top,
151
- left: y.value.padding.left,
152
- right: y.value.width - y.value.padding.right,
153
- bottom: y.value.padding.top + y.value.height,
154
- width: y.value.width - (y.value.padding.left + y.value.padding.right)
155
- })), y = f(() => {
156
- const l = e.value.style.chart.padding;
157
- return {
158
- width: xe.value,
159
- height: Se.value,
160
- padding: l
161
- };
162
- }), ne = f(() => Math.max(...M.value.flatMap((l) => l.datapoints.map((o) => o.values.length)))), W = f(() => rl({
163
- values: e.value.style.chart.xAxis.labels.values,
164
- maxDatapoints: ne.value,
165
- formatter: e.value.style.chart.xAxis.labels.datetimeFormatter,
166
- start: 0,
167
- end: e.value.style.chart.xAxis.labels.values.length
168
- })), X = f(() => {
169
- const l = Math.max(...M.value.map((a) => a.labelLen)), o = y.value.padding.left + l + 16 + e.value.style.chart.yAxis.labels.offsetX, t = (b.value.width - o) / ne.value, s = [];
170
- for (let a = 0; a < ne.value; a += 1)
171
- s.push({
172
- selectorX: o + t * a,
173
- x: o + t * a - t / 2,
174
- y: b.value.top,
175
- label: e.value.style.chart.xAxis.labels.values[a] ? W.value[a].text : "",
176
- index: a,
177
- width: t,
178
- height: Se.value
179
- });
180
- return s;
181
- });
182
- function ft(l) {
183
- te("selectX", M.value.map((o) => o.datapoints.map((t) => ({
184
- dp: t,
185
- selected: t.values[l.index]
186
- }))));
187
- }
188
- function gt(l, o) {
189
- return l.length * o / 2 + o;
190
- }
191
- function ze(l, o, t) {
192
- const s = gt(o, t);
193
- return l + s > b.value.right;
194
- }
195
- function pt(l, o, t = "sans-serif") {
196
- const a = document.createElement("canvas").getContext("2d"), h = typeof o == "number" ? `${o}px` : o;
197
- return a.font = `${h} ${t}`, a.measureText(l).width;
198
- }
199
- const E = f(() => {
200
- $.value;
201
- const l = Math.max(...M.value.map((x) => x.labelLen)), o = Math.max(...M.value.flatMap((x) => x.datapoints.map((N) => N.values.length))), t = Math.max(...M.value.flatMap((x) => x.datapoints.flatMap((N) => N.values))), s = Math.min(...M.value.flatMap((x) => x.datapoints.flatMap((N) => N.values))), a = y.value.padding.left + l + 16 + e.value.style.chart.yAxis.labels.offsetX, h = (b.value.width - a) / o, C = Math.abs(Math.min(s, 0)), Re = t + C;
202
- function Xe(x) {
203
- return isNaN(x / Re) ? 0 : x / Re;
204
- }
205
- return M.value.map((x, N) => {
206
- const Ee = b.value.top + $.value * N, F = b.value.top + Ee + $.value * re.value * (1 - Xe(C));
207
- return {
208
- ...x,
209
- label: {
210
- x: a - e.value.style.chart.yAxis.labels.fontSize,
211
- y: F
212
- },
213
- datapoints: x.datapoints.map((U) => {
214
- const D = U.values.map((G, Tt) => {
215
- const St = isNaN(G) || [void 0, null, "NaN", NaN, 1 / 0, -1 / 0].includes(G) ? 0 : G || 0, zt = a + h * Tt, Ot = b.value.top + Ee + $.value * re.value * (1 - Xe(St + C)), Lt = G === Math.max(...U.values);
216
- return {
217
- x: zt,
218
- y: Ot,
219
- value: G,
220
- isMaxPoint: Lt,
221
- zero: F
222
- };
223
- }), Ct = `${Ht(D, F, !1, !1)}`, _t = `M ${a},${F} ${Je(D)} ${D.at(-1).x},${F}`, Mt = `M ${a},${F} ${D.at(-1).x},${F}`, He = `M ${Vt(D)}`, Ve = `M ${Je(D)}`, Pt = Bt(
224
- e.value.style.chart.areas.smooth ? He : Ve
225
- );
226
- return {
227
- ...U,
228
- uid: ve(),
229
- plots: D,
230
- smoothPath: Ct,
231
- straightPath: _t,
232
- zeroPath: Mt,
233
- pathLength: Pt,
234
- smoothPathRidge: He,
235
- straightPathRidge: Ve
236
- };
237
- }).filter((U) => !z.value.includes(U.id))
238
- };
239
- });
240
- }), z = u([]);
241
- function mt(l) {
242
- const o = /* @__PURE__ */ new Map();
243
- return l.forEach((t) => {
244
- t.datapoints.forEach((s, a) => {
245
- const h = Ke(s.name);
246
- o.has(h) || o.set(h, {
247
- id: h,
248
- name: s.name,
249
- color: s.color,
250
- shape: "circle",
251
- segregate: () => Te(h),
252
- isSegregated: z.value.includes(h),
253
- opacity: z.value.includes(h) ? 0.5 : 1
254
- });
255
- });
256
- }), Array.from(o.values());
257
- }
258
- const ie = f(() => mt(M.value)), bt = f(() => ({
259
- cy: "donut-div-legend",
260
- backgroundColor: e.value.style.chart.legend.backgroundColor,
261
- color: e.value.style.chart.legend.color,
262
- fontSize: e.value.style.chart.legend.fontSize,
263
- paddingBottom: 12,
264
- fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
265
- })), H = u(!1);
266
- function Oe(l) {
267
- H.value = l, be.value += 1;
268
- }
269
- const Le = u({}), Ne = u([]);
270
- function xt(l) {
271
- te("selectDatapoint", l), e.value.style.chart.dialog.show && (Ne.value = l.datapoints.map((o) => ({
272
- name: o.name,
273
- color: o.color,
274
- type: "line",
275
- useArea: !0,
276
- smooth: e.value.style.chart.areas.smooth,
277
- series: o.values
278
- })), R.value = l, Le.value = Jt({
279
- ...e.value.style.chart.dialog.xyChart,
280
- responsive: !0,
281
- // Overriding
282
- chart: {
283
- ...e.value.style.chart.dialog.xyChart.chart,
284
- grid: {
285
- ...e.value.style.chart.dialog.xyChart.chart.grid,
286
- labels: {
287
- ...e.value.style.chart.dialog.xyChart.chart.grid.labels,
288
- xAxisLabels: {
289
- ...e.value.style.chart.dialog.xyChart.chart.grid.labels.xAxisLabels,
290
- values: e.value.style.chart.xAxis.labels.values,
291
- // Overriding
292
- autoRotate: !0,
293
- // overriding
294
- datetimeFormatter: e.value.style.chart.xAxis.labels.datetimeFormatter
295
- // Overriding
296
- }
297
- }
298
- },
299
- tooltip: {
300
- ...e.value.style.chart.dialog.xyChart.chart.tooltip,
301
- showTimeLabel: e.value.style.chart.xAxis.labels.values.length > 0
302
- // Overriding
303
- }
304
- }
305
- }), le.value && le.value.open());
306
- }
307
- const ue = u(null);
308
- function kt(l) {
309
- ue.value = l;
310
- }
311
- function At() {
312
- ue.value = null;
313
- }
314
- const j = u(!1);
315
- function ce() {
316
- j.value = !j.value;
317
- }
318
- function Fe() {
319
- B.value.showTable = !B.value.showTable;
320
- }
321
- const De = f(() => ({ body: E.value.flatMap((t) => t.datapoints.flatMap((s) => ({
322
- ...s,
323
- rowName: `${t.name}: ${s.name}`
324
- }))).map((t) => [
325
- {
326
- name: t.rowName,
327
- color: t.color
328
- },
329
- ...t.values
330
- ]) })), Y = f(() => {
331
- const l = [
332
- e.value.table.columnNames.series,
333
- ...W.value.map((s) => s.text)
334
- ], o = {
335
- th: {
336
- backgroundColor: e.value.table.th.backgroundColor,
337
- color: e.value.table.th.color,
338
- outline: e.value.table.th.outline
339
- },
340
- td: {
341
- backgroundColor: e.value.table.td.backgroundColor,
342
- color: e.value.table.td.color,
343
- outline: e.value.table.td.outline
344
- },
345
- breakpoint: e.value.table.responsiveBreakpoint
346
- };
347
- return {
348
- colNames: [
349
- e.value.table.columnNames.series,
350
- ...W.value.map((s) => s.text)
351
- ],
352
- head: l,
353
- body: De.value.body,
354
- config: o
355
- };
356
- });
357
- function Ie(l = null) {
358
- Dt(() => {
359
- const o = [
360
- [e.value.table.columnNames.series, ...W.map((a) => [a.text])],
361
- ...De.value.body.map((a, h) => [a[0].name, ...a.slice(1)])
362
- ], t = [
363
- [e.value.style.chart.title.text],
364
- [e.value.style.chart.title.subtitle.text]
365
- ].concat(o), s = qt(t);
366
- l ? l(s) : Kt({
367
- csvContent: s,
368
- title: e.value.style.chart.title.text || "vue-ui-ridgeline"
369
- });
370
- });
371
- }
372
- function wt() {
373
- return E.value;
374
- }
375
- async function $t({ scale: l = 2 } = {}) {
376
- if (!T.value) return;
377
- const { width: o, height: t } = T.value.getBoundingClientRect(), s = o / t, { imageUri: a, base64: h } = await nl({ domElement: T.value, base64: !0, img: !0, scale: l });
378
- return {
379
- imageUri: a,
380
- base64: h,
381
- title: e.value.style.chart.title.text,
382
- width: o,
383
- height: t,
384
- aspectRatio: s
385
- };
386
- }
387
- return et({
388
- getData: wt,
389
- getImage: $t,
390
- generateImage: Pe,
391
- generatePdf: Me,
392
- generateCsv: Ie,
393
- toggleAnnotator: ce,
394
- toggleTable: Fe,
395
- toggleFullscreen: Oe
396
- }), (l, o) => (r(), n("div", {
397
- ref_key: "ridgelineChart",
398
- ref: T,
399
- class: q(`vue-ui-ridgeline ${H.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
400
- id: `vue-ui-ridgeline_${w.value}`,
401
- style: _({
402
- fontFamily: e.value.style.fontFamily,
403
- width: "100%",
404
- textAlign: "center",
405
- background: e.value.style.chart.backgroundColor,
406
- height: e.value.responsive ? "100%" : void 0
407
- }),
408
- onMouseenter: o[4] || (o[4] = () => i(we)(!0)),
409
- onMouseleave: o[5] || (o[5] = () => i(we)(!1))
410
- }, [
411
- e.value.userOptions.buttons.annotator && i(se) ? (r(), P(i(rt), {
412
- key: 0,
413
- color: e.value.style.chart.color,
414
- backgroundColor: e.value.style.chart.backgroundColor,
415
- active: j.value,
416
- svgRef: i(se),
417
- onClose: ce
418
- }, null, 8, ["color", "backgroundColor", "active", "svgRef"])) : c("", !0),
419
- p(l.$slots, "userConfig", {}, void 0, !0),
420
- dt.value ? (r(), n("div", {
421
- key: 1,
422
- ref_key: "noTitle",
423
- ref: ge,
424
- class: "vue-data-ui-no-title-space",
425
- style: "height:36px; width: 100%;background:transparent"
426
- }, null, 512)) : c("", !0),
427
- e.value.style.chart.title.text ? (r(), n("div", {
428
- key: 2,
429
- ref_key: "chartTitle",
430
- ref: de,
431
- style: "width:100%;background:transparent;padding-bottom:24px"
432
- }, [
433
- (r(), P(sl, {
434
- key: `title_${pe.value}`,
435
- config: {
436
- title: {
437
- cy: "ridgeline-div-title",
438
- ...e.value.style.chart.title
439
- },
440
- subtitle: {
441
- cy: "ridgeline-div-subtitle",
442
- ...e.value.style.chart.title.subtitle
443
- }
444
- }
445
- }, null, 8, ["config"]))
446
- ], 512)) : c("", !0),
447
- e.value.userOptions.show && L.value && (i($e) || i(ae)) ? (r(), P(i(it), {
448
- ref: "details",
449
- key: `user_option_${be.value}`,
450
- backgroundColor: e.value.style.chart.backgroundColor,
451
- color: e.value.style.chart.color,
452
- isPrinting: i(Ce),
453
- isImaging: i(_e),
454
- uid: w.value,
455
- hasTooltip: !1,
456
- callbacks: e.value.userOptions.callbacks,
457
- hasPdf: e.value.userOptions.buttons.pdf,
458
- hasImg: e.value.userOptions.buttons.img,
459
- hasXls: e.value.userOptions.buttons.csv,
460
- hasTable: e.value.userOptions.buttons.table,
461
- hasLabel: !1,
462
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
463
- isFullscreen: H.value,
464
- printScale: e.value.userOptions.print.scale,
465
- chartElement: T.value,
466
- position: e.value.userOptions.position,
467
- isTooltip: !1,
468
- titles: { ...e.value.userOptions.buttonTitles },
469
- hasAnnotator: e.value.userOptions.buttons.annotator,
470
- isAnnotation: j.value,
471
- style: _({
472
- visibility: i($e) ? i(ae) ? "visible" : "hidden" : "visible"
473
- }),
474
- onToggleFullscreen: Oe,
475
- onGeneratePdf: i(Me),
476
- onGenerateCsv: Ie,
477
- onGenerateImage: i(Pe),
478
- onToggleTable: Fe,
479
- onToggleAnnotator: ce
480
- }, Ge({ _: 2 }, [
481
- l.$slots.menuIcon ? {
482
- name: "menuIcon",
483
- fn: m(({ isOpen: t, color: s }) => [
484
- p(l.$slots, "menuIcon", K(J({ isOpen: t, color: s })), void 0, !0)
485
- ]),
486
- key: "0"
487
- } : void 0,
488
- l.$slots.optionTooltip ? {
489
- name: "optionTooltip",
490
- fn: m(() => [
491
- p(l.$slots, "optionTooltip", {}, void 0, !0)
492
- ]),
493
- key: "1"
494
- } : void 0,
495
- l.$slots.optionPdf ? {
496
- name: "optionPdf",
497
- fn: m(() => [
498
- p(l.$slots, "optionPdf", {}, void 0, !0)
499
- ]),
500
- key: "2"
501
- } : void 0,
502
- l.$slots.optionCsv ? {
503
- name: "optionCsv",
504
- fn: m(() => [
505
- p(l.$slots, "optionCsv", {}, void 0, !0)
506
- ]),
507
- key: "3"
508
- } : void 0,
509
- l.$slots.optionImg ? {
510
- name: "optionImg",
511
- fn: m(() => [
512
- p(l.$slots, "optionImg", {}, void 0, !0)
513
- ]),
514
- key: "4"
515
- } : void 0,
516
- l.$slots.optionTable ? {
517
- name: "optionTable",
518
- fn: m(() => [
519
- p(l.$slots, "optionTable", {}, void 0, !0)
520
- ]),
521
- key: "5"
522
- } : void 0,
523
- l.$slots.optionFullscreen ? {
524
- name: "optionFullscreen",
525
- fn: m(({ toggleFullscreen: t, isFullscreen: s }) => [
526
- p(l.$slots, "optionFullscreen", K(J({ toggleFullscreen: t, isFullscreen: s })), void 0, !0)
527
- ]),
528
- key: "6"
529
- } : void 0,
530
- l.$slots.optionAnnotator ? {
531
- name: "optionAnnotator",
532
- fn: m(({ toggleAnnotator: t, isAnnotator: s }) => [
533
- p(l.$slots, "optionAnnotator", K(J({ toggleAnnotator: t, isAnnotator: s })), void 0, !0)
534
- ]),
535
- key: "7"
536
- } : void 0
537
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "callbacks", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "printScale", "chartElement", "position", "titles", "hasAnnotator", "isAnnotation", "style", "onGeneratePdf", "onGenerateImage"])) : c("", !0),
538
- L.value ? (r(), n("svg", {
539
- key: 4,
540
- ref_key: "svgRef",
541
- ref: se,
542
- xmlns: i(Ut),
543
- class: q({ "vue-data-ui-fullscreen--on": H.value, "vue-data-ui-fulscreen--off": !H.value }),
544
- viewBox: `0 0 ${y.value.width <= 0 ? 10 : y.value.width} ${b.value.fullHeight <= 0 ? 10 : b.value.fullHeight}`,
545
- style: _(`max-width:100%;overflow:visible;background:transparent;color:${e.value.style.chart.color};${e.value.responsive ? `height: ${ke.value}px; width: 100%;` : ""}`)
546
- }, [
547
- We(i(ot)),
548
- d("defs", null, [
549
- (r(!0), n(g, null, A(ie.value, (t, s) => (r(), n("linearGradient", {
550
- id: `gradient-${t.id}-${w.value}`,
551
- x1: "50%",
552
- y1: "0%",
553
- x2: "50%",
554
- y2: "100%"
555
- }, [
556
- d("stop", {
557
- offset: "0%",
558
- "stop-color": t.color,
559
- "stop-opacity": "1"
560
- }, null, 8, hl),
561
- d("stop", {
562
- offset: "30%",
563
- "stop-color": t.color,
564
- "stop-opacity": "0.7"
565
- }, null, 8, dl),
566
- d("stop", {
567
- offset: "70%",
568
- "stop-color": t.color,
569
- "stop-opacity": "0.3"
570
- }, null, 8, yl),
571
- d("stop", {
572
- offset: "100%",
573
- "stop-color": t.color,
574
- "stop-opacity": "0.1"
575
- }, null, 8, fl)
576
- ], 8, vl))), 256)),
577
- (r(!0), n(g, null, A(E.value, (t, s) => (r(), n(g, null, [
578
- (r(!0), n(g, null, A(t.datapoints, (a, h) => (r(), n("linearGradient", {
579
- key: `grad${a.id}`,
580
- id: `gradient-single-${w.value}-${a.uid}`,
581
- x1: "50%",
582
- y1: "0%",
583
- x2: "50%",
584
- y2: "100%"
585
- }, [
586
- d("stop", {
587
- offset: "0%",
588
- "stop-color": a.color,
589
- "stop-opacity": "1"
590
- }, null, 8, pl),
591
- d("stop", {
592
- offset: "30%",
593
- "stop-color": a.color,
594
- "stop-opacity": "0.7"
595
- }, null, 8, ml),
596
- d("stop", {
597
- offset: "70%",
598
- "stop-color": a.color,
599
- "stop-opacity": "0.3"
600
- }, null, 8, bl),
601
- d("stop", {
602
- offset: "100%",
603
- "stop-color": a.color,
604
- "stop-opacity": "0.1"
605
- }, null, 8, xl)
606
- ], 8, gl))), 128))
607
- ], 64))), 256))
608
- ]),
609
- (r(!0), n(g, null, A(E.value, (t, s) => (r(), n("g", {
610
- key: `ds-${s}`
611
- }, [
612
- (r(!0), n(g, null, A(t.datapoints, (a, h) => (r(), n("g", {
613
- key: a.id
614
- }, [
615
- l.$slots.pattern ? (r(), n("g", kl, [
616
- d("defs", null, [
617
- p(l.$slots, "pattern", je({ ref_for: !0 }, { datapointIndex: s, seriesIndex: h, patternId: `pattern_${w.value}_${a.uid}` }), void 0, !0)
618
- ])
619
- ])) : c("", !0),
620
- d("path", {
621
- fill: l.$slots.pattern ? `url(#pattern_${w.value}_${a.uid})` : e.value.style.chart.backgroundColor,
622
- stroke: "none",
623
- "stroke-linecap": "round",
624
- d: e.value.style.chart.areas.smooth ? a.smoothPath : a.straightPath,
625
- style: _({
626
- opacity: e.value.style.chart.areas.opacity
627
- })
628
- }, null, 12, Al),
629
- d("path", {
630
- fill: "none",
631
- stroke: e.value.style.chart.areas.stroke.useSerieColor ? a.color : e.value.style.chart.areas.stroke.color,
632
- "stroke-width": e.value.style.chart.areas.strokeWidth,
633
- d: e.value.style.chart.areas.smooth ? a.smoothPathRidge : a.straightPathRidge,
634
- "stroke-linecap": "round",
635
- "stroke-linejoin": "round",
636
- class: q({ "vue-ui-ridgeline-animate": e.value.useCssAnimation }),
637
- style: _({
638
- strokeDasharray: a.pathLength,
639
- strokeDashoffset: e.value.useCssAnimation ? a.pathLength : 0
640
- })
641
- }, null, 14, wl),
642
- d("path", {
643
- fill: e.value.style.chart.areas.useGradient ? e.value.style.chart.areas.useCommonColor ? `url(#gradient-${a.id}-${w.value})` : `url(#gradient-single-${w.value}-${a.uid})` : a.color,
644
- stroke: "none",
645
- d: e.value.style.chart.areas.smooth ? a.smoothPath : a.straightPath,
646
- "stroke-linecap": "round",
647
- "stroke-linejoin": "round",
648
- class: q({ "vue-ui-ridgeline-animate": e.value.useCssAnimation }),
649
- style: _({
650
- strokeDasharray: a.pathLength,
651
- strokeDashoffset: e.value.useCssAnimation ? a.pathLength : 0
652
- })
653
- }, null, 14, $l),
654
- e.value.style.chart.zeroLine.show ? (r(), n("path", {
655
- key: 1,
656
- stroke: e.value.style.chart.zeroLine.useSerieColor ? a.color : e.value.style.chart.zeroLine.stroke,
657
- "stroke-dasharray": e.value.style.chart.zeroLine.strokeDasharray,
658
- "stroke-width": e.value.style.chart.zeroLine.strokeWidth,
659
- d: a.zeroPath,
660
- "stroke-linecap": "round"
661
- }, null, 8, Cl)) : c("", !0),
662
- e.value.style.chart.areas.maxPoint.show && a.plots.length > 1 ? (r(!0), n(g, { key: 2 }, A(a.plots, (C) => (r(), n(g, null, [
663
- C.isMaxPoint ? (r(), n("line", {
664
- key: 0,
665
- x1: C.x,
666
- y1: C.y,
667
- x2: C.x,
668
- y2: C.zero,
669
- stroke: e.value.style.chart.areas.maxPoint.adaptStrokeToBackground ? i(Gt)(a.color) : e.value.style.chart.areas.maxPoint.stroke,
670
- "stroke-width": e.value.style.chart.areas.maxPoint.strokeWidth,
671
- "stroke-linecap": "round",
672
- "stroke-dasharray": e.value.style.chart.areas.maxPoint.strokeDasharray
673
- }, null, 8, _l)) : c("", !0)
674
- ], 64))), 256)) : c("", !0),
675
- a.plots.length === 1 ? (r(), n("circle", {
676
- key: 3,
677
- cx: a.plots[0].x,
678
- cy: a.plots[0].y,
679
- stroke: e.value.style.chart.selector.dot.stroke,
680
- "stroke-width": e.value.style.chart.selector.dot.strokeWidth,
681
- r: e.value.style.chart.selector.dot.radius,
682
- fill: e.value.style.chart.selector.dot.useDatapointColor ? a.color : e.value.style.chart.selector.dot.fill,
683
- style: {
684
- pointerEvents: "none"
685
- }
686
- }, null, 8, Ml)) : c("", !0)
687
- ]))), 128)),
688
- d("text", {
689
- x: t.label.x,
690
- y: t.label.y,
691
- "text-anchor": "end",
692
- "font-size": e.value.style.chart.yAxis.labels.fontSize,
693
- "font-weight": e.value.style.chart.yAxis.labels.bold ? "bold" : "normal",
694
- fill: e.value.style.chart.yAxis.labels.color,
695
- style: _({
696
- cursor: e.value.style.chart.dialog.show ? "pointer" : "default"
697
- }),
698
- "text-decoration": e.value.style.chart.dialog.show && (ue.value === s || R.value && t.uid === R.value.uid) ? "underline" : "",
699
- onMouseenter: (a) => kt(s),
700
- onMouseleave: At,
701
- onClick: (a) => xt(t)
702
- }, V(t.name), 45, Pl)
703
- ]))), 128)),
704
- e.value.style.chart.xAxis.labels.values.length ? (r(), n("g", Tl, [
705
- (r(!0), n(g, null, A(X.value, (t, s) => p(l.$slots, "time-label", je({ ref_for: !0 }, {
706
- show: t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && !e.value.style.chart.xAxis.labels.showOnlyAtModulo || t && e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && (s === 0 || s === X.value.length - 1) || t && v.value && v.value.index === s || t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && e.value.style.chart.xAxis.labels.showOnlyAtModulo && s % Math.floor(X.value.length / e.value.style.chart.xAxis.labels.modulo) === 0,
707
- fontSize: e.value.style.chart.xAxis.labels.fontSize,
708
- content: t.label,
709
- textAnchor: e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
710
- fill: e.value.style.chart.xAxis.labels.color,
711
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
712
- x: t.selectorX,
713
- y: b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY
714
- }), () => [
715
- t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && !e.value.style.chart.xAxis.labels.showOnlyAtModulo || t && e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && (s === 0 || s === X.value.length - 1) || t && v.value && v.value.index === s || t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && e.value.style.chart.xAxis.labels.showOnlyAtModulo && s % Math.floor(X.value.length / e.value.style.chart.xAxis.labels.modulo) === 0 ? (r(), n("g", Sl, [
716
- String(t.label).includes(`
717
- `) ? (r(), n("text", {
718
- key: 1,
719
- "font-size": e.value.style.chart.xAxis.labels.fontSize,
720
- fill: e.value.style.chart.xAxis.labels.color,
721
- "font-weight": e.value.style.chart.xAxis.labels.bold ? "bold" : "normal",
722
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
723
- "text-anchor": e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
724
- style: _({
725
- opacity: v.value ? v.value.index === s ? 1 : 0.2 : 1
726
- }),
727
- innerHTML: i(Wt)({
728
- content: String(t.label),
729
- fontSize: e.value.style.chart.xAxis.labels.fontSize,
730
- fill: e.value.style.chart.xAxis.labels.color,
731
- x: 0,
732
- y: 0
733
- })
734
- }, null, 12, Ol)) : (r(), n("text", {
735
- key: 0,
736
- "font-size": e.value.style.chart.xAxis.labels.fontSize,
737
- fill: e.value.style.chart.xAxis.labels.color,
738
- "font-weight": e.value.style.chart.xAxis.labels.bold ? "bold" : "normal",
739
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
740
- "text-anchor": e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
741
- style: _({
742
- opacity: v.value ? v.value.index === s ? 1 : 0.2 : 1
743
- })
744
- }, V(t.label), 13, zl))
745
- ])) : c("", !0)
746
- ], !0)), 256))
747
- ])) : c("", !0),
748
- d("g", null, [
749
- (r(!0), n(g, null, A(X.value, (t, s) => (r(), n("rect", {
750
- x: t.x,
751
- y: t.y,
752
- width: t.width < 0 ? 0.1 : t.width,
753
- height: t.height < 0 ? 0.1 : t.height,
754
- fill: "transparent",
755
- onMouseenter: (a) => v.value = t,
756
- onMouseleave: o[0] || (o[0] = (a) => v.value = null),
757
- onClick: () => ft(t)
758
- }, null, 40, Ll))), 256)),
759
- e.value.style.chart.selector.show && v.value ? (r(), n("line", {
760
- key: 0,
761
- x1: v.value.selectorX,
762
- x2: v.value.selectorX,
763
- y1: v.value.y,
764
- y2: v.value.y + v.value.height - $.value / 2,
765
- stroke: e.value.style.chart.selector.stroke,
766
- "stroke-width": e.value.style.chart.selector.strokeWidth,
767
- "stroke-dasharray": e.value.style.chart.selector.strokeDasharray,
768
- "stroke-linecap": "round",
769
- style: { pointerEvents: "none" }
770
- }, null, 8, Nl)) : c("", !0),
771
- v.value ? (r(!0), n(g, { key: 1 }, A(E.value, (t) => (r(), n(g, null, [
772
- (r(!0), n(g, null, A(t.datapoints, (s) => (r(), n(g, null, [
773
- (r(!0), n(g, null, A(s.plots, (a, h) => (r(), n(g, null, [
774
- v.value && v.value.index === h ? (r(), n("circle", {
775
- key: 0,
776
- cx: a.x,
777
- cy: a.y,
778
- stroke: e.value.style.chart.selector.dot.stroke,
779
- "stroke-width": e.value.style.chart.selector.dot.strokeWidth,
780
- r: e.value.style.chart.selector.dot.radius,
781
- fill: e.value.style.chart.selector.dot.useDatapointColor ? s.color : e.value.style.chart.selector.dot.fill,
782
- style: {
783
- pointerEvents: "none"
784
- }
785
- }, null, 8, Fl)) : c("", !0),
786
- v.value && v.value.index === h ? (r(), n("text", {
787
- key: 1,
788
- x: ze(
789
- a.x,
790
- i(Z)(
791
- e.value.style.chart.selector.labels.formatter,
792
- a.value,
793
- i(ee)({
794
- p: e.value.style.chart.xAxis.labels.prefix,
795
- v: a.value,
796
- s: e.value.style.chart.xAxis.labels.suffix,
797
- r: e.value.style.chart.selector.labels.rounding
798
- })
799
- ),
800
- e.value.style.chart.selector.labels.fontSize
801
- ) ? a.x - e.value.style.chart.selector.labels.fontSize / 2 : a.x + e.value.style.chart.selector.labels.fontSize / 2,
802
- y: a.y + e.value.style.chart.selector.labels.fontSize / 3,
803
- "text-anchor": ze(
804
- a.x,
805
- i(Z)(
806
- e.value.style.chart.selector.labels.formatter,
807
- a.value,
808
- i(ee)({
809
- p: e.value.style.chart.xAxis.labels.prefix,
810
- v: a.value,
811
- s: e.value.style.chart.xAxis.labels.suffix,
812
- r: e.value.style.chart.selector.labels.rounding
813
- })
814
- ),
815
- e.value.style.chart.selector.labels.fontSize
816
- ) ? "end" : "start",
817
- "font-size": e.value.style.chart.selector.labels.fontSize,
818
- fill: e.value.style.chart.selector.labels.color,
819
- style: {
820
- pointerEvents: "none"
821
- }
822
- }, V(i(Z)(
823
- e.value.style.chart.selector.labels.formatter,
824
- a.value,
825
- i(ee)({
826
- p: e.value.style.chart.xAxis.labels.prefix,
827
- v: a.value,
828
- s: e.value.style.chart.xAxis.labels.suffix,
829
- r: e.value.style.chart.selector.labels.rounding
830
- })
831
- )), 9, Dl)) : c("", !0)
832
- ], 64))), 256))
833
- ], 64))), 256))
834
- ], 64))), 256)) : c("", !0)
835
- ]),
836
- p(l.$slots, "svg", { svg: y.value }, void 0, !0)
837
- ], 14, cl)) : c("", !0),
838
- l.$slots.watermark ? (r(), n("div", Il, [
839
- p(l.$slots, "watermark", K(J({ isPrinting: i(Ce) || i(_e) })), void 0, !0)
840
- ])) : c("", !0),
841
- L.value ? c("", !0) : (r(), P(i(nt), {
842
- key: 6,
843
- config: {
844
- type: "ridgeline",
845
- style: {
846
- backgroundColor: e.value.style.chart.backgroundColor,
847
- ridgeline: {
848
- color: "#CCCCCC"
849
- }
850
- }
851
- }
852
- }, null, 8, ["config"])),
853
- d("div", {
854
- ref_key: "chartLegend",
855
- ref: ye
856
- }, [
857
- e.value.style.chart.legend.show ? (r(), P(al, {
858
- key: `legend_${me.value}`,
859
- legendSet: ie.value,
860
- config: bt.value,
861
- onClickMarker: o[1] || (o[1] = ({ legend: t }) => Te(t.id))
862
- }, Ge({
863
- item: m(({ legend: t }) => [
864
- d("div", {
865
- style: _(`opacity:${z.value.includes(t.id) ? 0.5 : 1}`),
866
- onClick: (s) => t.segregate()
867
- }, V(t.name), 13, Rl)
868
- ]),
869
- _: 2
870
- }, [
871
- l.$slots.pattern ? {
872
- name: "legend-pattern",
873
- fn: m(({ legend: t, index: s }) => [
874
- We(ol, {
875
- shape: t.shape,
876
- radius: 30,
877
- stroke: "none",
878
- plot: { x: 30, y: 30 },
879
- fill: `url(#pattern_${w.value}_${s})`
880
- }, null, 8, ["shape", "fill"])
881
- ]),
882
- key: "0"
883
- } : void 0
884
- ]), 1032, ["legendSet", "config"])) : c("", !0),
885
- p(l.$slots, "legend", { legend: ie.value }, void 0, !0)
886
- ], 512),
887
- l.$slots.source ? (r(), n("div", {
888
- key: 7,
889
- ref_key: "source",
890
- ref: fe,
891
- dir: "auto"
892
- }, [
893
- p(l.$slots, "source", {}, void 0, !0)
894
- ], 512)) : c("", !0),
895
- L.value ? (r(), P(i(lt), {
896
- key: 8,
897
- hideDetails: "",
898
- config: {
899
- open: B.value.showTable,
900
- maxHeight: 1e4,
901
- body: {
902
- backgroundColor: e.value.style.chart.backgroundColor,
903
- color: e.value.style.chart.color
904
- },
905
- head: {
906
- backgroundColor: e.value.style.chart.backgroundColor,
907
- color: e.value.style.chart.color
908
- }
909
- }
910
- }, {
911
- content: m(() => [
912
- (r(), P(i(st), {
913
- key: `table_${vt.value}`,
914
- colNames: Y.value.colNames,
915
- head: Y.value.head,
916
- body: Y.value.body,
917
- config: Y.value.config,
918
- title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` :${e.value.style.chart.title.subtitle.text}` : ""}`,
919
- onClose: o[2] || (o[2] = (t) => B.value.showTable = !1)
920
- }, {
921
- th: m(({ th: t }) => [
922
- d("div", { innerHTML: t }, null, 8, Xl)
923
- ]),
924
- td: m(({ td: t }) => [
925
- Ye(V(t.name ? t.name : i(Z)(
926
- e.value.style.chart.selector.labels.formatter,
927
- t,
928
- i(ee)({
929
- p: e.value.style.chart.xAxis.labels.prefix,
930
- v: t,
931
- s: e.value.style.chart.xAxis.labels.suffix,
932
- r: e.value.table.td.roundingValue
933
- })
934
- )), 1)
935
- ]),
936
- _: 1
937
- }, 8, ["colNames", "head", "body", "config", "title"]))
938
- ]),
939
- _: 1
940
- }, 8, ["config"])) : c("", !0),
941
- e.value.style.chart.dialog.show ? (r(), P(i(at), {
942
- key: 9,
943
- ref_key: "dialog",
944
- ref: le,
945
- onClose: o[3] || (o[3] = (t) => R.value = null),
946
- backgroundColor: e.value.style.chart.dialog.backgroundColor,
947
- color: e.value.style.chart.dialog.color,
948
- headerBg: e.value.style.chart.dialog.header.backgroundColor,
949
- headerColor: e.value.style.chart.dialog.header.color,
950
- isFullscreen: H.value,
951
- fullscreenParent: T.value,
952
- withPadding: ""
953
- }, {
954
- title: m(() => [
955
- Ye(V(R.value.name), 1)
956
- ]),
957
- default: m(() => [
958
- R.value ? (r(), P(i(ut), {
959
- key: 0,
960
- config: Le.value,
961
- dataset: Ne.value
962
- }, null, 8, ["config", "dataset"])) : c("", !0)
963
- ]),
964
- _: 1
965
- }, 8, ["backgroundColor", "color", "headerBg", "headerColor", "isFullscreen", "fullscreenParent"])) : c("", !0)
966
- ], 46, ul));
967
- }
968
- }, ea = /* @__PURE__ */ il(El, [["__scopeId", "data-v-1839aa08"]]);
969
- export {
970
- ea as default
971
- };