vue-data-ui 2.3.3 → 2.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Arrow-B6gJebT9.js +101 -0
- package/dist/Arrow-C5yj6zwY.cjs +1 -0
- package/dist/BaseIcon-7_g11dRj.js +174 -0
- package/dist/BaseIcon-JtWoVorZ.cjs +1 -0
- package/dist/DataTable-CwaOlAsy.js +127 -0
- package/dist/DataTable-Rm9II-m2.cjs +1 -0
- package/dist/Legend-CxvJTjEm.js +62 -0
- package/dist/Legend-D59FIuMs.cjs +1 -0
- package/dist/Shape-CVItL3vh.cjs +1 -0
- package/dist/Shape-CjLV0scA.js +107 -0
- package/dist/Slicer-Bxg5niHl.js +156 -0
- package/dist/Slicer-Cdss5Rus.cjs +1 -0
- package/dist/Title-2iks1ziC.js +46 -0
- package/dist/Title-Bb-A5OSV.cjs +1 -0
- package/dist/Tooltip-C3phqKuU.js +94 -0
- package/dist/Tooltip-C_UE6y-E.cjs +1 -0
- package/dist/_plugin-vue_export-helper-BHFhmbuH.cjs +1 -0
- package/dist/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
- package/dist/html2canvas.esm-BA_v9SIU.cjs +22 -0
- package/dist/html2canvas.esm-d2sM-0Wm.js +4870 -0
- package/dist/index-p5gfZSvB.cjs +4 -0
- package/dist/index-uOtklCCx.js +10268 -0
- package/dist/{index.es-ypwniJN8.js → index.es-YufTdp0y.js} +1 -1
- package/dist/{index.es-Dnua3tHc.cjs → index.es-uyeSCnWE.cjs} +1 -1
- package/dist/jspdf.es.min-C660YX78.js +8038 -0
- package/dist/jspdf.es.min-DLYY9DTT.cjs +243 -0
- package/dist/pdf-97UbtKC2.js +44 -0
- package/dist/pdf-Cz3729tZ.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/useNestedProp-2kIU-7On.cjs +1 -0
- package/dist/useNestedProp-BgWkUab_.js +13 -0
- package/dist/usePrinter-B6xQCyL-.js +464 -0
- package/dist/usePrinter-fZlsJid8.cjs +1 -0
- package/dist/useResponsive-B3TrDDIG.cjs +1 -0
- package/dist/useResponsive-NZB-WLRF.js +187 -0
- package/dist/vue-data-ui-Be0rgmbA.cjs +9 -0
- package/dist/vue-data-ui-Ccy6rBZN.js +246 -0
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +62 -61
- package/dist/vue-ui-3d-bar-BKMPFDi2.js +1085 -0
- package/dist/vue-ui-3d-bar-CKa4UXq4.cjs +19 -0
- package/dist/vue-ui-accordion-C_pwrAJl.cjs +1 -0
- package/dist/vue-ui-accordion-HJPf7My0.js +77 -0
- package/dist/vue-ui-age-pyramid-CE1xnA-8.cjs +1 -0
- package/dist/vue-ui-age-pyramid-DB_CL-gu.js +596 -0
- package/dist/vue-ui-annotator-BAMZcPlH.cjs +371 -0
- package/dist/vue-ui-annotator-DQsAL-nZ.js +2177 -0
- package/dist/vue-ui-candlestick-DCl8fpNu.js +657 -0
- package/dist/vue-ui-candlestick-Duv6oG79.cjs +2 -0
- package/dist/vue-ui-chestnut-BYHA6MT4.js +1051 -0
- package/dist/vue-ui-chestnut-mIZ4-ZEM.cjs +6 -0
- package/dist/vue-ui-cursor-C96IChA3.js +229 -0
- package/dist/vue-ui-cursor-De7dy4Mo.cjs +1 -0
- package/dist/vue-ui-dashboard-B2Yz41yO.js +232 -0
- package/dist/vue-ui-dashboard-BMGwKr0K.cjs +1 -0
- package/dist/vue-ui-digits-BnxLp7zQ.js +153 -0
- package/dist/vue-ui-digits-DSWyL-5K.cjs +1 -0
- package/dist/vue-ui-donut-1kei9ws5.cjs +1 -0
- package/dist/vue-ui-donut-B9iXisHK.js +743 -0
- package/dist/vue-ui-donut-evolution-B7Sun8sw.js +799 -0
- package/dist/vue-ui-donut-evolution-yv17DnGy.cjs +1 -0
- package/dist/vue-ui-dumbbell-BJEf_JEq.cjs +9 -0
- package/dist/vue-ui-dumbbell-DIsDnD1d.js +624 -0
- package/dist/vue-ui-flow-BTivYoGd.js +454 -0
- package/dist/vue-ui-flow-DOxJa8di.cjs +1 -0
- package/dist/vue-ui-galaxy-BEmywfFB.js +485 -0
- package/dist/vue-ui-galaxy-CHGOwCwM.cjs +1 -0
- package/dist/vue-ui-gauge-QAfMl-8t.cjs +1 -0
- package/dist/vue-ui-gauge-o4rDOqF3.js +466 -0
- package/dist/vue-ui-heatmap-BS4EzedX.cjs +1 -0
- package/dist/vue-ui-heatmap-DwqQqEsk.js +598 -0
- package/dist/vue-ui-kpi-F4qkJ_U-.cjs +1 -0
- package/dist/vue-ui-kpi-h8elYTcA.js +54 -0
- package/dist/vue-ui-mini-loader-C_8B2Pm6.cjs +1 -0
- package/dist/vue-ui-mini-loader-Cgoi9rhH.js +131 -0
- package/dist/vue-ui-molecule-Bmv76SWz.js +750 -0
- package/dist/vue-ui-molecule-C5CY_YYc.cjs +1 -0
- package/dist/vue-ui-mood-radar-BN0dzlfp.cjs +1 -0
- package/dist/vue-ui-mood-radar-DeMouUIe.js +548 -0
- package/dist/vue-ui-nested-donuts-ZyFoV-Zn.cjs +16 -0
- package/dist/vue-ui-nested-donuts-wOUkSVyZ.js +771 -0
- package/dist/vue-ui-onion-DCOKG2wG.js +554 -0
- package/dist/vue-ui-onion-VmTUo7TR.cjs +1 -0
- package/dist/vue-ui-parallel-coordinate-plot-BGtO2P4a.js +651 -0
- package/dist/vue-ui-parallel-coordinate-plot-BziXRF8E.cjs +8 -0
- package/dist/vue-ui-quadrant--JOTjPZh.js +1178 -0
- package/dist/vue-ui-quadrant-DawUUrur.cjs +1 -0
- package/dist/vue-ui-quick-chart-LXKfaJgS.js +1310 -0
- package/dist/vue-ui-quick-chart-jFlFtiNV.cjs +13 -0
- package/dist/vue-ui-radar-CWNIqvcA.js +614 -0
- package/dist/vue-ui-radar-VGH-lhaT.cjs +1 -0
- package/dist/vue-ui-rating-BNrIoJHN.js +271 -0
- package/dist/vue-ui-rating-Dtu6pwGx.cjs +1 -0
- package/dist/vue-ui-relation-circle-B3NKudOy.js +304 -0
- package/dist/vue-ui-relation-circle-Dwpx9o18.cjs +1 -0
- package/dist/vue-ui-rings-CsUngX_F.js +510 -0
- package/dist/vue-ui-rings-D9_OG--0.cjs +1 -0
- package/dist/vue-ui-scatter-DUsuh7bd.cjs +1 -0
- package/dist/vue-ui-scatter-DgxTz4Jx.js +874 -0
- package/dist/vue-ui-screenshot-51H_VrYY.js +160 -0
- package/dist/vue-ui-screenshot-C2Dz7CAe.cjs +3 -0
- package/dist/vue-ui-skeleton-BM9rwmxY.js +2064 -0
- package/dist/vue-ui-skeleton-sjfOtCZr.cjs +41 -0
- package/dist/vue-ui-smiley-DNnBtHht.cjs +2 -0
- package/dist/vue-ui-smiley-H5rSN-1B.js +763 -0
- package/dist/vue-ui-spark-trend-CLXZDYlk.js +246 -0
- package/dist/vue-ui-spark-trend-R4JJvfry.cjs +1 -0
- package/dist/vue-ui-sparkbar-C0k4ah-7.js +242 -0
- package/dist/vue-ui-sparkbar-CEUDIw0A.cjs +1 -0
- package/dist/vue-ui-sparkgauge-BHj00A07.js +157 -0
- package/dist/vue-ui-sparkgauge-CaEw6nmI.cjs +1 -0
- package/dist/vue-ui-sparkhistogram-B6GuavEu.cjs +1 -0
- package/dist/vue-ui-sparkhistogram-DbMLYKqE.js +244 -0
- package/dist/vue-ui-sparkline-CJydanLS.cjs +1 -0
- package/dist/vue-ui-sparkline-CYova9x3.js +333 -0
- package/dist/vue-ui-sparkstackbar-Df__yM5b.cjs +1 -0
- package/dist/vue-ui-sparkstackbar-N5rVBM2h.js +244 -0
- package/dist/vue-ui-strip-plot-DJJ1vEWz.js +618 -0
- package/dist/vue-ui-strip-plot-b5lhB35d.cjs +1 -0
- package/dist/vue-ui-table-NHhOVDbs.cjs +14 -0
- package/dist/vue-ui-table-heatmap-Cro2etCY.js +237 -0
- package/dist/vue-ui-table-heatmap-DlL2nCqz.cjs +1 -0
- package/dist/vue-ui-table-sparkline-Bw2Gc_ur.cjs +1 -0
- package/dist/vue-ui-table-sparkline-DppMitqF.js +420 -0
- package/dist/vue-ui-table-xSvwJIa7.js +1430 -0
- package/dist/vue-ui-thermometer-M2kdp1x5.js +385 -0
- package/dist/vue-ui-thermometer-Q_3PX2V3.cjs +1 -0
- package/dist/vue-ui-timer-BtSDeIRp.cjs +64 -0
- package/dist/vue-ui-timer-CAaQ-QD6.js +453 -0
- package/dist/vue-ui-tiremarks-CbGOSEvD.cjs +1 -0
- package/dist/vue-ui-tiremarks-JFv4JLP0.js +249 -0
- package/dist/vue-ui-treemap-BqDX-bPf.cjs +1 -0
- package/dist/vue-ui-treemap-DCnv-xYr.js +722 -0
- package/dist/vue-ui-vertical-bar-CEbApJZl.js +737 -0
- package/dist/vue-ui-vertical-bar-CJB_KXyr.cjs +4 -0
- package/dist/vue-ui-waffle-CTS6C7gu.js +638 -0
- package/dist/vue-ui-waffle-IMEbGe-b.cjs +1 -0
- package/dist/vue-ui-wheel-CuOmEWMQ.cjs +1 -0
- package/dist/vue-ui-wheel-_zyCdFiI.js +227 -0
- package/dist/vue-ui-word-cloud-RDlXBEAN.js +346 -0
- package/dist/vue-ui-word-cloud-Y7Yk7uUJ.cjs +1 -0
- package/dist/vue-ui-xy-BZJQBKnU.cjs +3 -0
- package/dist/vue-ui-xy-DsvN9EIQ.js +2064 -0
- package/dist/vue-ui-xy-canvas-D_dnbyFS.cjs +9 -0
- package/dist/vue-ui-xy-canvas-Dbcw8-9Q.js +1006 -0
- package/package.json +1 -1
- package/dist/index-BcMihqI4.cjs +0 -843
- package/dist/index-C7FeCQ7K.js +0 -57303
|
@@ -0,0 +1,2064 @@
|
|
|
1
|
+
import { p as Z } from "./pdf-97UbtKC2.js";
|
|
2
|
+
import { U as J, s as K } from "./usePrinter-B6xQCyL-.js";
|
|
3
|
+
import { c as U, a as Q, t as j, r as $, p as ee, u as te, O as X, I as M, E as le, T as ae, z as re, U as ie, L as se, V as oe, x as ne, s as ce, d as he, y as ue, b as de, q as ge, n as fe, C as be, R as Ie, W as me, f as Ne, v as _e, w as Fe, e as xe, o as ye, Y as Ae, B as Se } from "./index-uOtklCCx.js";
|
|
4
|
+
import { D as Le } from "./DataTable-CwaOlAsy.js";
|
|
5
|
+
import { _ as Ce } from "./Title-2iks1ziC.js";
|
|
6
|
+
import { _ as ke, u as we } from "./Tooltip-C3phqKuU.js";
|
|
7
|
+
import { _ as Oe } from "./Shape-CjLV0scA.js";
|
|
8
|
+
import ve from "./BaseIcon-7_g11dRj.js";
|
|
9
|
+
import Ge from "./vue-ui-table-sparkline-DppMitqF.js";
|
|
10
|
+
import ze from "./vue-ui-skeleton-BM9rwmxY.js";
|
|
11
|
+
import { S as pe } from "./Slicer-Bxg5niHl.js";
|
|
12
|
+
import Te from "./vue-ui-accordion-HJPf7My0.js";
|
|
13
|
+
import { u as q } from "./useNestedProp-BgWkUab_.js";
|
|
14
|
+
import { resolveComponent as P, openBlock as r, createElementBlock as i, normalizeClass as T, normalizeStyle as S, createVNode as W, createCommentVNode as c, createBlock as V, createSlots as Me, withCtx as z, renderSlot as G, normalizeProps as Y, guardReactiveProps as E, createElementVNode as d, Fragment as I, renderList as m, toDisplayString as C, withDirectives as Pe, vModelCheckbox as Ve, createTextVNode as Re } from "vue";
|
|
15
|
+
import { _ as De } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
16
|
+
const He = U(), Be = {
|
|
17
|
+
name: "vue-ui-xy",
|
|
18
|
+
props: {
|
|
19
|
+
config: {
|
|
20
|
+
type: Object,
|
|
21
|
+
default() {
|
|
22
|
+
return {};
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
dataset: {
|
|
26
|
+
type: Array,
|
|
27
|
+
default() {
|
|
28
|
+
return [];
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
components: {
|
|
33
|
+
DataTable: Le,
|
|
34
|
+
Shape: Oe,
|
|
35
|
+
Title: Ce,
|
|
36
|
+
Tooltip: ke,
|
|
37
|
+
UserOptions: J,
|
|
38
|
+
BaseIcon: ve,
|
|
39
|
+
TableSparkline: Ge,
|
|
40
|
+
Skeleton: ze,
|
|
41
|
+
Slicer: pe,
|
|
42
|
+
Accordion: Te
|
|
43
|
+
},
|
|
44
|
+
data() {
|
|
45
|
+
this.dataset.forEach((h, b) => {
|
|
46
|
+
[null, void 0].includes(h.series) && this.error({
|
|
47
|
+
componentName: "VueUiXy",
|
|
48
|
+
type: "datasetSerieAttribute",
|
|
49
|
+
property: "series (number[])",
|
|
50
|
+
index: b
|
|
51
|
+
});
|
|
52
|
+
});
|
|
53
|
+
const a = Math.max(...this.dataset.map((h) => h.series.length)), o = {
|
|
54
|
+
start: 0,
|
|
55
|
+
end: a
|
|
56
|
+
};
|
|
57
|
+
return {
|
|
58
|
+
themePalettes: Q,
|
|
59
|
+
themes: j,
|
|
60
|
+
slicerStep: 0,
|
|
61
|
+
selectedScale: null,
|
|
62
|
+
CTX: null,
|
|
63
|
+
CANVAS: null,
|
|
64
|
+
opacity: $,
|
|
65
|
+
useSafeValues: !0,
|
|
66
|
+
palette: ee,
|
|
67
|
+
height: 600,
|
|
68
|
+
width: 1e3,
|
|
69
|
+
viewBox: "0 0 1000 600",
|
|
70
|
+
clientPosition: {
|
|
71
|
+
x: 0,
|
|
72
|
+
y: 0
|
|
73
|
+
},
|
|
74
|
+
canvasClientPosition: {
|
|
75
|
+
x: 0,
|
|
76
|
+
y: 0
|
|
77
|
+
},
|
|
78
|
+
icons: {
|
|
79
|
+
line: "line",
|
|
80
|
+
bar: "bar",
|
|
81
|
+
plot: "plot"
|
|
82
|
+
},
|
|
83
|
+
isFullscreen: !1,
|
|
84
|
+
isPrinting: !1,
|
|
85
|
+
isImaging: !1,
|
|
86
|
+
isTooltip: !1,
|
|
87
|
+
mutableConfig: {
|
|
88
|
+
dataLabels: {
|
|
89
|
+
show: !0
|
|
90
|
+
},
|
|
91
|
+
showTooltip: !0,
|
|
92
|
+
showTable: !1,
|
|
93
|
+
isStacked: !1,
|
|
94
|
+
useIndividualScale: !1
|
|
95
|
+
},
|
|
96
|
+
selectedSerieIndex: null,
|
|
97
|
+
selectedRowIndex: null,
|
|
98
|
+
segregatedSeries: [],
|
|
99
|
+
uniqueId: U(),
|
|
100
|
+
step: 0,
|
|
101
|
+
slicer: o,
|
|
102
|
+
__to__: null,
|
|
103
|
+
maxX: a,
|
|
104
|
+
showSparklineTable: !0,
|
|
105
|
+
segregateStep: 0,
|
|
106
|
+
sliderId: He,
|
|
107
|
+
fontSizes: {
|
|
108
|
+
xAxis: 18,
|
|
109
|
+
yAxis: 12,
|
|
110
|
+
dataLabels: 20,
|
|
111
|
+
plotLabels: 10
|
|
112
|
+
},
|
|
113
|
+
plotRadii: {
|
|
114
|
+
plot: 3,
|
|
115
|
+
line: 3
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
},
|
|
119
|
+
computed: {
|
|
120
|
+
customPalette() {
|
|
121
|
+
return this.convertCustomPalette(this.FINAL_CONFIG.customPalette);
|
|
122
|
+
},
|
|
123
|
+
backgroundColor() {
|
|
124
|
+
return this.FINAL_CONFIG.chart.backgroundColor;
|
|
125
|
+
},
|
|
126
|
+
slicerColor() {
|
|
127
|
+
return this.FINAL_CONFIG.chart.zoom.color;
|
|
128
|
+
},
|
|
129
|
+
allScales() {
|
|
130
|
+
const a = this.lineSet.map((t) => ({
|
|
131
|
+
name: t.name,
|
|
132
|
+
color: t.color,
|
|
133
|
+
scale: t.individualScale,
|
|
134
|
+
scaleYLabels: t.scaleYLabels,
|
|
135
|
+
zero: t.zeroPosition,
|
|
136
|
+
max: t.individualMax,
|
|
137
|
+
scaleLabel: t.scaleLabel || "",
|
|
138
|
+
id: t.id,
|
|
139
|
+
yOffset: t.yOffset || 0,
|
|
140
|
+
individualHeight: t.individualHeight || this.drawingArea.height,
|
|
141
|
+
autoScaleYLabels: t.autoScaleYLabels
|
|
142
|
+
})), o = this.barSet.map((t) => ({
|
|
143
|
+
name: t.name,
|
|
144
|
+
color: t.color,
|
|
145
|
+
scale: t.individualScale,
|
|
146
|
+
scaleYLabels: t.scaleYLabels,
|
|
147
|
+
zero: t.zeroPosition,
|
|
148
|
+
max: t.individualMax,
|
|
149
|
+
scaleLabel: t.scaleLabel || "",
|
|
150
|
+
id: t.id,
|
|
151
|
+
yOffset: t.yOffset || 0,
|
|
152
|
+
individualHeight: t.individualHeight || this.drawingArea.height
|
|
153
|
+
})), h = this.plotSet.map((t) => ({
|
|
154
|
+
name: t.name,
|
|
155
|
+
color: t.color,
|
|
156
|
+
scale: t.individualScale,
|
|
157
|
+
scaleYLabels: t.scaleYLabels,
|
|
158
|
+
// FIX
|
|
159
|
+
zero: t.zeroPosition,
|
|
160
|
+
max: t.individualMax,
|
|
161
|
+
scaleLabel: t.scaleLabel || "",
|
|
162
|
+
id: t.id,
|
|
163
|
+
yOffset: t.yOffset || 0,
|
|
164
|
+
individualHeight: t.individualHeight || this.drawingArea.height
|
|
165
|
+
})), b = [...a, ...o, ...h].flatMap((t) => t).length;
|
|
166
|
+
return [...a, ...o, ...h].flatMap((t, e) => ({
|
|
167
|
+
id: t.id,
|
|
168
|
+
scaleLabel: t.scaleLabel,
|
|
169
|
+
name: t.name,
|
|
170
|
+
color: t.color,
|
|
171
|
+
scale: t.scale,
|
|
172
|
+
yOffset: t.yOffset,
|
|
173
|
+
individualHeight: t.individualHeight,
|
|
174
|
+
x: this.mutableConfig.isStacked ? this.drawingArea.left : this.drawingArea.left / b * (e + 1),
|
|
175
|
+
yLabels: t.scaleYLabels || t.scale.ticks.map((N) => ({
|
|
176
|
+
y: N >= 0 ? t.zero - t.individualHeight * (N / t.max) : t.zero + t.individualHeight * Math.abs(N) / t.max,
|
|
177
|
+
value: N
|
|
178
|
+
}))
|
|
179
|
+
}));
|
|
180
|
+
},
|
|
181
|
+
isDataset() {
|
|
182
|
+
return !!this.dataset && this.dataset.length;
|
|
183
|
+
},
|
|
184
|
+
chartFont() {
|
|
185
|
+
const a = document.getElementById(`vue-ui-xy_${this.uniqueId}`);
|
|
186
|
+
return window.getComputedStyle(a, null).getPropertyValue("font-family");
|
|
187
|
+
},
|
|
188
|
+
FINAL_CONFIG: {
|
|
189
|
+
get: function() {
|
|
190
|
+
const a = te().vue_ui_xy;
|
|
191
|
+
if (!Object.keys(this.config || {}).length)
|
|
192
|
+
return a;
|
|
193
|
+
const o = this.useNestedProp({
|
|
194
|
+
userConfig: this.config,
|
|
195
|
+
defaultConfig: a
|
|
196
|
+
});
|
|
197
|
+
return o.theme ? {
|
|
198
|
+
...q({
|
|
199
|
+
userConfig: this.themes.vue_ui_xy[o.theme] || this.config,
|
|
200
|
+
defaultConfig: o
|
|
201
|
+
}),
|
|
202
|
+
customPalette: this.themePalettes[o.theme] || this.palette
|
|
203
|
+
} : o;
|
|
204
|
+
},
|
|
205
|
+
set: function(a) {
|
|
206
|
+
return a;
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
hasHighlightArea() {
|
|
210
|
+
return this.FINAL_CONFIG.chart.highlightArea && this.FINAL_CONFIG.chart.highlightArea.show;
|
|
211
|
+
},
|
|
212
|
+
highlightAreaSpan() {
|
|
213
|
+
const { from: a, to: o } = this.FINAL_CONFIG.chart.highlightArea;
|
|
214
|
+
return a === o ? 1 : o < a ? 0 : o - a + 1;
|
|
215
|
+
},
|
|
216
|
+
relativeZero() {
|
|
217
|
+
return this.niceScale.min >= 0 ? 0 : Math.abs(this.niceScale.min);
|
|
218
|
+
},
|
|
219
|
+
absoluteMax() {
|
|
220
|
+
return this.niceScale.max + this.relativeZero;
|
|
221
|
+
},
|
|
222
|
+
safeDataset() {
|
|
223
|
+
return this.useSafeValues ? this.dataset.map((a, o) => ({
|
|
224
|
+
...a,
|
|
225
|
+
series: a.series.map((h) => this.isSafeValue(h) ? h : null).slice(this.slicer.start, this.slicer.end),
|
|
226
|
+
color: this.convertColorToHex(a.color ? a.color : this.customPalette[o] ? this.customPalette[o] : this.palette[o]),
|
|
227
|
+
id: `uniqueId_${o}`
|
|
228
|
+
})) : this.dataset;
|
|
229
|
+
},
|
|
230
|
+
relativeDataset() {
|
|
231
|
+
return this.safeDataset.map((a, o) => ({
|
|
232
|
+
...a,
|
|
233
|
+
series: a.series.map((h) => h + this.relativeZero),
|
|
234
|
+
absoluteValues: a.series
|
|
235
|
+
})).filter((a) => !this.segregatedSeries.includes(a.id));
|
|
236
|
+
},
|
|
237
|
+
tableSparklineDataset() {
|
|
238
|
+
return this.relativeDataset.map((a) => {
|
|
239
|
+
const o = a.absoluteValues.map((h) => [void 0, null].includes(h) ? 0 : h);
|
|
240
|
+
return {
|
|
241
|
+
id: a.id,
|
|
242
|
+
name: a.name,
|
|
243
|
+
color: a.color,
|
|
244
|
+
values: this.fillArray(this.maxSeries, o)
|
|
245
|
+
};
|
|
246
|
+
});
|
|
247
|
+
},
|
|
248
|
+
tableSparklineConfig() {
|
|
249
|
+
return {
|
|
250
|
+
responsiveBreakpoint: this.FINAL_CONFIG.table.responsiveBreakpoint,
|
|
251
|
+
roundingValues: this.FINAL_CONFIG.table.rounding,
|
|
252
|
+
showAverage: !1,
|
|
253
|
+
showMedian: !1,
|
|
254
|
+
showTotal: !1,
|
|
255
|
+
fontFamily: this.FINAL_CONFIG.chart.fontFamily,
|
|
256
|
+
colNames: JSON.parse(JSON.stringify(this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values)),
|
|
257
|
+
thead: {
|
|
258
|
+
backgroundColor: this.FINAL_CONFIG.table.th.backgroundColor,
|
|
259
|
+
color: this.FINAL_CONFIG.table.th.color,
|
|
260
|
+
outline: this.FINAL_CONFIG.table.th.outline
|
|
261
|
+
},
|
|
262
|
+
tbody: {
|
|
263
|
+
backgroundColor: this.FINAL_CONFIG.table.td.backgroundColor,
|
|
264
|
+
color: this.FINAL_CONFIG.table.td.color,
|
|
265
|
+
outline: this.FINAL_CONFIG.table.td.outline
|
|
266
|
+
},
|
|
267
|
+
userOptions: {
|
|
268
|
+
show: !1
|
|
269
|
+
}
|
|
270
|
+
};
|
|
271
|
+
},
|
|
272
|
+
absoluteDataset() {
|
|
273
|
+
return this.safeDataset.map((a, o) => ({
|
|
274
|
+
absoluteIndex: o,
|
|
275
|
+
...a,
|
|
276
|
+
series: a.series.map((h) => h + this.relativeZero),
|
|
277
|
+
absoluteValues: a.series,
|
|
278
|
+
segregate: () => this.segregate(a),
|
|
279
|
+
isSegregated: this.segregatedSeries.includes(a.id)
|
|
280
|
+
}));
|
|
281
|
+
},
|
|
282
|
+
barSet() {
|
|
283
|
+
return this.activeSeriesWithStackRatios.filter((a) => a.type === "bar").map((a, o) => {
|
|
284
|
+
this.checkAutoScaleError(a);
|
|
285
|
+
const h = Math.min(...a.absoluteValues.filter((u) => ![null, void 0].includes(u))), b = Math.max(...a.absoluteValues.filter((u) => ![null, void 0].includes(u))), e = {
|
|
286
|
+
ratios: a.absoluteValues.filter((u) => ![null, void 0].includes(u)).map((u) => (u - h) / (b - h)),
|
|
287
|
+
valueMin: h,
|
|
288
|
+
valueMax: b < 0 ? 0 : b
|
|
289
|
+
}, N = {
|
|
290
|
+
max: a.scaleMax || Math.max(...a.absoluteValues) || 1,
|
|
291
|
+
min: a.scaleMin || Math.min(...a.absoluteValues.filter((u) => ![void 0, null].includes(u))) > 0 ? 0 : Math.min(...a.absoluteValues.filter((u) => ![null, void 0].includes(u)))
|
|
292
|
+
}, A = a.scaleSteps || this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps, f = this.calculateNiceScale(N.min, N.max, A), F = this.calculateNiceScale(e.valueMin, e.valueMax, A), p = f.min >= 0 ? 0 : Math.abs(f.min), k = 0, w = f.max + p, v = F.max + Math.abs(k), _ = this.mutableConfig.isStacked ? this.drawingArea.height * (1 - a.cumulatedStackRatio) : 0, L = this.mutableConfig.isStacked ? this.drawingArea.height * a.stackRatio - this.FINAL_CONFIG.chart.grid.labels.yAxis.gap : this.drawingArea.height, l = this.drawingArea.bottom - _ - L * p / w, n = this.drawingArea.bottom - _ - L * k / v, s = this.absoluteDataset.filter((u) => u.type === "bar").filter((u) => !this.segregatedSeries.includes(u.id)).length, g = a.series.map((u, x) => {
|
|
293
|
+
const H = this.mutableConfig.useIndividualScale ? (a.absoluteValues[x] + p) / w : this.ratioToMax(u), B = this.mutableConfig.useIndividualScale && this.mutableConfig.isStacked ? this.drawingArea.left + this.drawingArea.width / this.maxSeries * x : this.drawingArea.left + this.slot.bar * o + this.slot.bar * x * s - this.barSlot / 2 - o * this.barPeriodGap;
|
|
294
|
+
return {
|
|
295
|
+
yOffset: _,
|
|
296
|
+
individualHeight: L,
|
|
297
|
+
x: B,
|
|
298
|
+
y: this.drawingArea.bottom - _ - L * H,
|
|
299
|
+
value: a.absoluteValues[x],
|
|
300
|
+
zeroPosition: l,
|
|
301
|
+
individualMax: w,
|
|
302
|
+
comment: a.comments && a.comments.slice(this.slicer.start, this.slicer.end)[x] || ""
|
|
303
|
+
};
|
|
304
|
+
}), D = a.absoluteValues.map((u) => F.min >= 0 ? (u - Math.abs(F.min)) / (F.max - Math.abs(F.min)) : (u + Math.abs(F.min)) / (F.max + Math.abs(F.min))), R = a.series.map((u, x) => {
|
|
305
|
+
const H = this.mutableConfig.useIndividualScale && this.mutableConfig.isStacked ? this.drawingArea.left + this.drawingArea.width / this.maxSeries * x : this.drawingArea.left - this.slot.bar / 2 + this.slot.bar * o + this.slot.bar * x * this.absoluteDataset.filter((B) => B.type === "bar").filter((B) => !this.segregatedSeries.includes(B.id)).length;
|
|
306
|
+
return {
|
|
307
|
+
yOffset: _,
|
|
308
|
+
individualHeight: L,
|
|
309
|
+
x: H,
|
|
310
|
+
y: this.drawingArea.bottom - _ - (L * D[x] || 0),
|
|
311
|
+
value: a.absoluteValues[x],
|
|
312
|
+
zeroPosition: l,
|
|
313
|
+
individualMax: w,
|
|
314
|
+
comment: a.comments && a.comments.slice(this.slicer.start, this.slicer.end)[x] || ""
|
|
315
|
+
};
|
|
316
|
+
}), y = f.ticks.map((u) => ({
|
|
317
|
+
y: u >= 0 ? l - L * (u / w) : l + L * Math.abs(u) / w,
|
|
318
|
+
value: u
|
|
319
|
+
})), O = F.ticks.map((u) => {
|
|
320
|
+
const x = (u - F.min) / (F.max - F.min);
|
|
321
|
+
return {
|
|
322
|
+
y: u >= 0 ? n - L * x : n + L * x,
|
|
323
|
+
value: u
|
|
324
|
+
};
|
|
325
|
+
});
|
|
326
|
+
return {
|
|
327
|
+
...a,
|
|
328
|
+
yOffset: _,
|
|
329
|
+
autoScaleYLabels: O,
|
|
330
|
+
individualHeight: L,
|
|
331
|
+
scaleYLabels: a.autoScaling ? O : y,
|
|
332
|
+
individualScale: a.autoScaling ? F : f,
|
|
333
|
+
individualMax: a.autoScaling ? v : w,
|
|
334
|
+
zeroPosition: a.autoScaling ? n : l,
|
|
335
|
+
plots: a.autoScaling ? R : g
|
|
336
|
+
};
|
|
337
|
+
});
|
|
338
|
+
},
|
|
339
|
+
activeSeriesLength() {
|
|
340
|
+
return this.absoluteDataset.length;
|
|
341
|
+
},
|
|
342
|
+
activeSeriesWithStackRatios() {
|
|
343
|
+
return this.assignStackRatios(this.absoluteDataset.filter((a) => !this.segregatedSeries.includes(a.id)));
|
|
344
|
+
},
|
|
345
|
+
lineSet() {
|
|
346
|
+
return this.activeSeriesWithStackRatios.filter((a) => a.type === "line").map((a) => {
|
|
347
|
+
this.checkAutoScaleError(a);
|
|
348
|
+
const o = Math.min(...a.absoluteValues.filter((u) => ![void 0, null].includes(u))), h = Math.max(...a.absoluteValues.filter((u) => ![void 0, null].includes(u))) || 1, t = {
|
|
349
|
+
ratios: a.absoluteValues.filter((u) => ![null, void 0].includes(u)).map((u) => (u - o) / (h - o)),
|
|
350
|
+
valueMin: o,
|
|
351
|
+
valueMax: h
|
|
352
|
+
}, e = {
|
|
353
|
+
max: a.scaleMax || Math.max(...a.absoluteValues) || 1,
|
|
354
|
+
min: a.scaleMin || (Math.min(...a.absoluteValues) > 0 ? 0 : Math.min(...a.absoluteValues))
|
|
355
|
+
}, N = a.scaleSteps || this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps, A = this.calculateNiceScale(e.min, e.max, N), f = this.calculateNiceScale(t.valueMin, t.valueMax, N), F = A.min >= 0 ? 0 : Math.abs(A.min), p = 0, k = A.max + Math.abs(F), w = f.max + Math.abs(p), v = this.mutableConfig.isStacked ? this.drawingArea.height * (1 - a.cumulatedStackRatio) : 0, _ = this.mutableConfig.isStacked ? this.drawingArea.height * a.stackRatio - this.FINAL_CONFIG.chart.grid.labels.yAxis.gap : this.drawingArea.height, L = this.drawingArea.bottom - v - _ * F / k, l = this.drawingArea.bottom - v - _ * p / w, n = a.series.map((u, x) => {
|
|
356
|
+
const H = this.mutableConfig.useIndividualScale ? (a.absoluteValues[x] + Math.abs(F)) / k : this.ratioToMax(u);
|
|
357
|
+
return {
|
|
358
|
+
x: this.drawingArea.left + this.slot.line / 2 + this.slot.line * x,
|
|
359
|
+
y: this.drawingArea.bottom - v - _ * H,
|
|
360
|
+
value: a.absoluteValues[x],
|
|
361
|
+
comment: a.comments && a.comments.slice(this.slicer.start, this.slicer.end)[x] || ""
|
|
362
|
+
};
|
|
363
|
+
}), s = a.absoluteValues.map((u) => f.min >= 0 ? (u - Math.abs(f.min)) / (f.max - Math.abs(f.min)) : (u + Math.abs(f.min)) / (f.max + Math.abs(f.min))), g = a.series.map((u, x) => {
|
|
364
|
+
if (![void 0, null].includes(a.absoluteValues[x]))
|
|
365
|
+
return {
|
|
366
|
+
x: this.drawingArea.left + this.slot.line / 2 + this.slot.line * x,
|
|
367
|
+
y: this.drawingArea.bottom - v - (_ * s[x] || 0),
|
|
368
|
+
value: a.absoluteValues[x],
|
|
369
|
+
comment: a.comments && a.comments.slice(this.slicer.start, this.slicer.end)[x] || ""
|
|
370
|
+
};
|
|
371
|
+
}), D = this.createSmoothPath(n), R = this.createSmoothPath(g), y = A.ticks.map((u) => ({
|
|
372
|
+
y: u >= 0 ? L - _ * (u / k) : L + _ * Math.abs(u) / k,
|
|
373
|
+
value: u
|
|
374
|
+
})), O = f.ticks.map((u) => {
|
|
375
|
+
const x = (u - f.min) / (f.max - f.min);
|
|
376
|
+
return {
|
|
377
|
+
y: u >= 0 ? l - _ * x : l + _ * x,
|
|
378
|
+
value: u
|
|
379
|
+
};
|
|
380
|
+
});
|
|
381
|
+
return {
|
|
382
|
+
...a,
|
|
383
|
+
yOffset: v,
|
|
384
|
+
autoScaleYLabels: O,
|
|
385
|
+
individualHeight: _,
|
|
386
|
+
scaleYLabels: a.autoScaling ? O : y,
|
|
387
|
+
individualScale: a.autoScaling ? f : A,
|
|
388
|
+
individualMax: a.autoScaling ? w : k,
|
|
389
|
+
zeroPosition: a.autoScaling ? l : L,
|
|
390
|
+
curve: a.autoScaling ? R : D,
|
|
391
|
+
plots: a.autoScaling ? g : n,
|
|
392
|
+
area: a.useArea ? this.mutableConfig.useIndividualScale ? this.createIndividualArea(a.autoScaling ? g : n, a.autoScaling ? l : L) : this.createArea(n) : ""
|
|
393
|
+
};
|
|
394
|
+
});
|
|
395
|
+
},
|
|
396
|
+
plotSet() {
|
|
397
|
+
return this.activeSeriesWithStackRatios.filter((a) => a.type === "plot").map((a) => {
|
|
398
|
+
this.checkAutoScaleError(a);
|
|
399
|
+
const o = Math.min(...a.absoluteValues.filter((y) => ![null, void 0].includes(y))), h = Math.max(...a.absoluteValues.filter((y) => ![null, void 0].includes(y))) || 1, t = {
|
|
400
|
+
ratios: a.absoluteValues.filter((y) => ![null, void 0].includes(y)).map((y) => (y - o) / (h - o)),
|
|
401
|
+
valueMin: o,
|
|
402
|
+
valueMax: h
|
|
403
|
+
}, e = {
|
|
404
|
+
max: a.scaleMax || Math.max(...a.absoluteValues) || 1,
|
|
405
|
+
min: a.scaleMin || Math.min(...a.absoluteValues) > 0 ? 0 : Math.min(...a.absoluteValues)
|
|
406
|
+
}, N = a.scaleSteps || this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps, A = this.calculateNiceScale(e.min, e.max, N), f = this.calculateNiceScale(t.valueMin, t.valueMax, N), F = A.min >= 0 ? 0 : Math.abs(A.min), p = 0, k = A.max + F, w = f.max + Math.abs(p), v = this.mutableConfig.isStacked ? this.drawingArea.height * (1 - a.cumulatedStackRatio) : 0, _ = this.mutableConfig.isStacked ? this.drawingArea.height * a.stackRatio - this.FINAL_CONFIG.chart.grid.labels.yAxis.gap : this.drawingArea.height, L = this.drawingArea.bottom - v - _ * F / k, l = this.drawingArea.bottom - v - _ * p / w, n = a.series.map((y, O) => {
|
|
407
|
+
const u = this.mutableConfig.useIndividualScale ? (a.absoluteValues[O] + Math.abs(F)) / k : this.ratioToMax(y);
|
|
408
|
+
return {
|
|
409
|
+
x: this.drawingArea.left + this.slot.plot / 2 + this.slot.plot * O,
|
|
410
|
+
y: this.drawingArea.bottom - v - _ * u,
|
|
411
|
+
value: a.absoluteValues[O],
|
|
412
|
+
comment: a.comments && a.comments.slice(this.slicer.start, this.slicer.end)[O] || ""
|
|
413
|
+
};
|
|
414
|
+
}), s = a.absoluteValues.map((y) => f.min >= 0 ? (y - Math.abs(f.min)) / (f.max - Math.abs(f.min)) : (y + Math.abs(f.min)) / (f.max + Math.abs(f.min))), g = a.series.map((y, O) => ({
|
|
415
|
+
x: this.drawingArea.left + this.slot.plot / 2 + this.slot.plot * O,
|
|
416
|
+
y: this.drawingArea.bottom - v - (_ * s[O] || 0),
|
|
417
|
+
value: a.absoluteValues[O],
|
|
418
|
+
comment: a.comments && a.comments.slice(this.slicer.start, this.slicer.end)[O] || ""
|
|
419
|
+
})), D = A.ticks.map((y) => ({
|
|
420
|
+
y: y >= 0 ? L - _ * (y / k) : L + _ * Math.abs(y) / k,
|
|
421
|
+
value: y
|
|
422
|
+
})), R = f.ticks.map((y) => {
|
|
423
|
+
const O = (y - f.min) / (f.max - f.min);
|
|
424
|
+
return {
|
|
425
|
+
y: y >= 0 ? l - _ * O : l + _ * O,
|
|
426
|
+
value: y
|
|
427
|
+
};
|
|
428
|
+
});
|
|
429
|
+
return {
|
|
430
|
+
...a,
|
|
431
|
+
yOffset: v,
|
|
432
|
+
autoScaleYLabels: R,
|
|
433
|
+
individualHeight: _,
|
|
434
|
+
scaleYLabels: a.autoScaling ? R : D,
|
|
435
|
+
individualScale: a.autoScaling ? f : A,
|
|
436
|
+
individualMax: a.autoScaling ? w : k,
|
|
437
|
+
zeroPosition: a.autoScaling ? l : L,
|
|
438
|
+
plots: a.autoScaling ? g : n
|
|
439
|
+
};
|
|
440
|
+
});
|
|
441
|
+
},
|
|
442
|
+
drawingArea() {
|
|
443
|
+
const a = this.mutableConfig.useIndividualScale && this.FINAL_CONFIG.chart.grid.labels.show ? this.absoluteDataset.filter((o) => !this.segregatedSeries.includes(o.id)).length * (this.mutableConfig.isStacked ? 0 : this.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth) : 0;
|
|
444
|
+
return {
|
|
445
|
+
top: this.FINAL_CONFIG.chart.padding.top,
|
|
446
|
+
right: this.width - this.FINAL_CONFIG.chart.padding.right,
|
|
447
|
+
bottom: this.height - this.FINAL_CONFIG.chart.padding.bottom,
|
|
448
|
+
left: this.FINAL_CONFIG.chart.padding.left + a,
|
|
449
|
+
height: this.height - (this.FINAL_CONFIG.chart.padding.top + this.FINAL_CONFIG.chart.padding.bottom),
|
|
450
|
+
width: this.width - (this.FINAL_CONFIG.chart.padding.right + this.FINAL_CONFIG.chart.padding.left + a)
|
|
451
|
+
};
|
|
452
|
+
},
|
|
453
|
+
max() {
|
|
454
|
+
return Math.max(...this.safeDataset.filter((a) => !this.segregatedSeries.includes(a.id)).map((a) => Math.max(...a.series)));
|
|
455
|
+
},
|
|
456
|
+
min() {
|
|
457
|
+
const a = Math.min(...this.safeDataset.filter((o) => !this.segregatedSeries.includes(o.id)).map((o) => Math.min(...o.series)));
|
|
458
|
+
return a > 0 ? 0 : a;
|
|
459
|
+
},
|
|
460
|
+
niceScale() {
|
|
461
|
+
return this.calculateNiceScale(this.min, this.max < 0 ? 0 : this.max, this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps);
|
|
462
|
+
},
|
|
463
|
+
maxSeries() {
|
|
464
|
+
return this.slicer.end - this.slicer.start;
|
|
465
|
+
},
|
|
466
|
+
timeLabels() {
|
|
467
|
+
return this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values.slice(this.slicer.start, this.slicer.end);
|
|
468
|
+
},
|
|
469
|
+
slot() {
|
|
470
|
+
return {
|
|
471
|
+
bar: this.drawingArea.width / this.maxSeries / this.safeDataset.filter((a) => a.type === "bar").filter((a) => !this.segregatedSeries.includes(a.id)).length,
|
|
472
|
+
plot: this.drawingArea.width / this.maxSeries,
|
|
473
|
+
line: this.drawingArea.width / this.maxSeries
|
|
474
|
+
};
|
|
475
|
+
},
|
|
476
|
+
barSlot() {
|
|
477
|
+
const a = this.safeDataset.filter((o) => o.type === "bar").filter((o) => !this.segregatedSeries.includes(o.id)).length;
|
|
478
|
+
return this.drawingArea.width / this.maxSeries / a - this.barPeriodGap * a;
|
|
479
|
+
},
|
|
480
|
+
barPeriodGap() {
|
|
481
|
+
return this.slot.line * this.FINAL_CONFIG.bar.periodGap;
|
|
482
|
+
},
|
|
483
|
+
maxSlot() {
|
|
484
|
+
return Math.max(...Object.values(this.slot).filter((a) => a !== 1 / 0));
|
|
485
|
+
},
|
|
486
|
+
table() {
|
|
487
|
+
if (this.safeDataset.length === 0) return { head: [], body: [], config: {}, columnNames: [] };
|
|
488
|
+
const a = this.relativeDataset.map((h) => ({
|
|
489
|
+
label: h.name,
|
|
490
|
+
color: h.color,
|
|
491
|
+
type: h.type
|
|
492
|
+
})), o = [];
|
|
493
|
+
return this.timeLabels.forEach((h, b) => {
|
|
494
|
+
const t = [h];
|
|
495
|
+
this.relativeDataset.forEach((e) => {
|
|
496
|
+
t.push(this.canShowValue(e.absoluteValues[b]) ? Number(e.absoluteValues[b].toFixed(this.FINAL_CONFIG.table.rounding)) : "");
|
|
497
|
+
}), o.push(t);
|
|
498
|
+
}), { head: a, body: o };
|
|
499
|
+
},
|
|
500
|
+
dataTable() {
|
|
501
|
+
const a = [""].concat(this.relativeDataset.map((t) => t.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>');
|
|
502
|
+
let o = [];
|
|
503
|
+
for (let t = 0; t < this.maxSeries; t += 1) {
|
|
504
|
+
const e = this.relativeDataset.map((N) => N.absoluteValues[t] ?? 0).reduce((N, A) => N + A, 0);
|
|
505
|
+
o.push([this.timeLabels[t] ?? "-"].concat(this.relativeDataset.map((N) => (N.absoluteValues[t] ?? 0).toFixed(this.FINAL_CONFIG.table.rounding))).concat((e ?? 0).toFixed(this.FINAL_CONFIG.table.rounding)));
|
|
506
|
+
}
|
|
507
|
+
const h = {
|
|
508
|
+
th: {
|
|
509
|
+
backgroundColor: this.FINAL_CONFIG.table.th.backgroundColor,
|
|
510
|
+
color: this.FINAL_CONFIG.table.th.color,
|
|
511
|
+
outline: this.FINAL_CONFIG.table.th.outline
|
|
512
|
+
},
|
|
513
|
+
td: {
|
|
514
|
+
backgroundColor: this.FINAL_CONFIG.table.td.backgroundColor,
|
|
515
|
+
color: this.FINAL_CONFIG.table.td.color,
|
|
516
|
+
outline: this.FINAL_CONFIG.table.td.outline
|
|
517
|
+
},
|
|
518
|
+
breakpoint: this.FINAL_CONFIG.table.responsiveBreakpoint
|
|
519
|
+
}, b = [this.FINAL_CONFIG.table.columnNames.period].concat(this.relativeDataset.map((t) => t.name)).concat(this.FINAL_CONFIG.table.columnNames.total);
|
|
520
|
+
return { head: a, body: o, config: h, colNames: b };
|
|
521
|
+
},
|
|
522
|
+
dataTooltipSlot() {
|
|
523
|
+
return {
|
|
524
|
+
datapoint: this.selectedSeries,
|
|
525
|
+
seriesIndex: this.selectedSerieIndex,
|
|
526
|
+
series: this.absoluteDataset,
|
|
527
|
+
bars: this.barSet,
|
|
528
|
+
lines: this.lineSet,
|
|
529
|
+
plots: this.plotSet,
|
|
530
|
+
config: this.FINAL_CONFIG
|
|
531
|
+
};
|
|
532
|
+
},
|
|
533
|
+
selectedSeries() {
|
|
534
|
+
return this.relativeDataset.map((a) => ({
|
|
535
|
+
shape: a.shape || null,
|
|
536
|
+
name: a.name,
|
|
537
|
+
color: a.color,
|
|
538
|
+
type: a.type,
|
|
539
|
+
value: a.absoluteValues.find((o, h) => h === this.selectedSerieIndex),
|
|
540
|
+
comments: a.comments || []
|
|
541
|
+
}));
|
|
542
|
+
},
|
|
543
|
+
tooltipContent() {
|
|
544
|
+
let a = "", o = this.selectedSeries.map((t) => t.value).filter((t) => this.isSafeValue(t) && t !== null).reduce((t, e) => Math.abs(t) + Math.abs(e), 0);
|
|
545
|
+
const h = this.timeLabels[this.selectedSerieIndex], b = this.FINAL_CONFIG.chart.tooltip.customFormat;
|
|
546
|
+
return this.isFunction(b) && this.functionReturnsString(() => b({
|
|
547
|
+
seriesIndex: this.selectedSerieIndex,
|
|
548
|
+
datapoint: this.selectedSeries,
|
|
549
|
+
series: this.absoluteDataset,
|
|
550
|
+
bars: this.barSet,
|
|
551
|
+
lines: this.lineSet,
|
|
552
|
+
plots: this.plotSet,
|
|
553
|
+
config: this.FINAL_CONFIG
|
|
554
|
+
})) ? b({
|
|
555
|
+
seriesIndex: this.selectedSerieIndex,
|
|
556
|
+
datapoint: this.selectedSeries,
|
|
557
|
+
series: this.absoluteDataset,
|
|
558
|
+
bars: this.barSet,
|
|
559
|
+
lines: this.lineSet,
|
|
560
|
+
plots: this.plotSet,
|
|
561
|
+
config: this.FINAL_CONFIG
|
|
562
|
+
}) : (h && (a += `<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${this.FINAL_CONFIG.chart.tooltip.borderColor}; width:100%">${h}</div>`), this.selectedSeries.forEach((t) => {
|
|
563
|
+
if (this.isSafeValue(t.value)) {
|
|
564
|
+
let e = "", N = "";
|
|
565
|
+
switch (this.icons[t.type]) {
|
|
566
|
+
case "bar":
|
|
567
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><rect x="0" y="0" rx="1" stroke="none" height="12" width="12" fill="${t.color}" /></svg>`;
|
|
568
|
+
break;
|
|
569
|
+
case "line":
|
|
570
|
+
!t.shape || !["star", "triangle", "square", "diamond", "pentagon", "hexagon"].includes(t.shape) ? N = `<circle cx="10" cy="8" r="4" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${t.color}" />` : t.shape === "triangle" ? N = `<path d="${M({ plot: { x: 10, y: 8 }, radius: 4, sides: 3, rotation: 0.52 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" />` : t.shape === "square" ? N = `<path d="${M({ plot: { x: 10, y: 8 }, radius: 4, sides: 4, rotation: 0.8 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" />` : t.shape === "diamond" ? N = `<path d="${M({ plot: { x: 10, y: 8 }, radius: 4, sides: 4, rotation: 0 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" />` : t.shape === "pentagon" ? N = `<path d="${M({ plot: { x: 10, y: 8 }, radius: 4, sides: 5, rotation: 0.95 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" />` : t.shape === "hexagon" ? N = `<path d="${M({ plot: { x: 10, y: 8 }, radius: 4, sides: 6, rotation: 0 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" />` : t.shape === "star" && (N = `<polygon stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${t.color}" points="${X({ plot: { x: 10, y: 8 }, radius: 4 })}" />`), e = `<svg viewBox="0 0 20 12" height="14" width="20"><rect rx="3" x="0" y="6" stroke="none" height="4" width="20" fill="${t.color}" />${N}</svg>`;
|
|
571
|
+
break;
|
|
572
|
+
case "plot":
|
|
573
|
+
if (!t.shape || !["star", "triangle", "square", "diamond", "pentagon", "hexagon"].includes(t.shape)) {
|
|
574
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${t.color}" /></svg>`;
|
|
575
|
+
break;
|
|
576
|
+
}
|
|
577
|
+
if (t.shape === "star") {
|
|
578
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><polygon stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${t.color}" points="${X({ plot: { x: 6, y: 6 }, radius: 5 })}" /></svg>`;
|
|
579
|
+
break;
|
|
580
|
+
}
|
|
581
|
+
if (t.shape === "triangle") {
|
|
582
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${M({ plot: { x: 6, y: 6 }, radius: 6, sides: 3, rotation: 0.52 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
|
|
583
|
+
break;
|
|
584
|
+
}
|
|
585
|
+
if (t.shape === "square") {
|
|
586
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${M({ plot: { x: 6, y: 6 }, radius: 6, sides: 4, rotation: 0.8 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
|
|
587
|
+
break;
|
|
588
|
+
}
|
|
589
|
+
if (t.shape === "diamond") {
|
|
590
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${M({ plot: { x: 6, y: 6 }, radius: 5, sides: 4, rotation: 0 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
|
|
591
|
+
break;
|
|
592
|
+
}
|
|
593
|
+
if (t.shape === "pentagon") {
|
|
594
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${M({ plot: { x: 6, y: 6 }, radius: 5, sides: 5, rotation: 0.95 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
|
|
595
|
+
break;
|
|
596
|
+
}
|
|
597
|
+
if (t.shape === "hexagon") {
|
|
598
|
+
e = `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${M({ plot: { x: 6, y: 6 }, radius: 5, sides: 6, rotation: 0 }).path}" fill="${t.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;
|
|
599
|
+
break;
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
a += `<div style="display:flex;flex-direction:row; align-items:center;gap:3px;"><div style="width:20px">${e}</div> ${t.name}: <b>${this.FINAL_CONFIG.chart.tooltip.showValue ? this.dataLabel({ p: this.FINAL_CONFIG.chart.labels.prefix, v: t.value, s: this.FINAL_CONFIG.chart.labels.suffix, r: this.FINAL_CONFIG.chart.tooltip.roundingValue }) : ""}</b> ${this.FINAL_CONFIG.chart.tooltip.showPercentage ? `(${this.checkNaN(Math.abs(t.value) / o * 100).toFixed(this.FINAL_CONFIG.chart.tooltip.roundingPercentage)}%)` : ""}</div>`, this.FINAL_CONFIG.chart.comments.showInTooltip && t.comments.length && t.comments.slice(this.slicer.start, this.slicer.end)[this.selectedSerieIndex] && (a += `<div class="vue-data-ui-tooltip-comment" style="background:${t.color}20; padding: 6px; margin-bottom: 6px; border-left: 1px solid ${t.color}">${t.comments.slice(this.slicer.start, this.slicer.end)[this.selectedSerieIndex]}</div>`);
|
|
603
|
+
}
|
|
604
|
+
}), `<div style="border-radius:4px;padding:12px;font-variant-numeric: tabular-nums;color:${this.FINAL_CONFIG.chart.tooltip.color}">${a}</div>`);
|
|
605
|
+
},
|
|
606
|
+
svg() {
|
|
607
|
+
return {
|
|
608
|
+
height: this.height,
|
|
609
|
+
width: this.width
|
|
610
|
+
};
|
|
611
|
+
},
|
|
612
|
+
yLabels() {
|
|
613
|
+
return this.niceScale.ticks.map((a) => ({
|
|
614
|
+
y: a >= 0 ? this.zero - this.drawingArea.height * this.ratioToMax(a) : this.zero + this.drawingArea.height * this.ratioToMax(Math.abs(a)),
|
|
615
|
+
value: a
|
|
616
|
+
}));
|
|
617
|
+
},
|
|
618
|
+
zero() {
|
|
619
|
+
return this.drawingArea.bottom - this.drawingArea.height * this.ratioToMax(this.relativeZero);
|
|
620
|
+
}
|
|
621
|
+
},
|
|
622
|
+
mounted() {
|
|
623
|
+
if (this.objectIsEmpty(this.dataset) ? this.error({
|
|
624
|
+
componentName: "VueUiXy",
|
|
625
|
+
type: "dataset"
|
|
626
|
+
}) : this.dataset.forEach((a, o) => {
|
|
627
|
+
[null, void 0].includes(a.name) && this.error({
|
|
628
|
+
componentName: "VueUiXy",
|
|
629
|
+
type: "datasetSerieAttribute",
|
|
630
|
+
property: "name (string)",
|
|
631
|
+
index: o
|
|
632
|
+
});
|
|
633
|
+
}), this.FINAL_CONFIG.showWarnings && this.dataset.forEach((a) => {
|
|
634
|
+
a.series.forEach((o, h) => {
|
|
635
|
+
this.isSafeValue(o) || console.warn(`SmartXY has detected an unsafe value in your dataset:
|
|
636
|
+
-----> The serie '${a.name}' contains the value '${o}' at index ${h}.
|
|
637
|
+
'${o}' was converted to null to allow the chart to display.`);
|
|
638
|
+
});
|
|
639
|
+
}), document.addEventListener("mousemove", (a) => {
|
|
640
|
+
this.clientPosition = {
|
|
641
|
+
x: a.clientX,
|
|
642
|
+
y: a.clientY
|
|
643
|
+
};
|
|
644
|
+
}), this.mutableConfig = {
|
|
645
|
+
dataLabels: {
|
|
646
|
+
show: !0
|
|
647
|
+
},
|
|
648
|
+
showTooltip: this.FINAL_CONFIG.chart.tooltip.show === !0,
|
|
649
|
+
showTable: this.FINAL_CONFIG.showTable === !0,
|
|
650
|
+
isStacked: this.FINAL_CONFIG.chart.grid.labels.yAxis.stacked,
|
|
651
|
+
useIndividualScale: this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale
|
|
652
|
+
}, this.FINAL_CONFIG.responsive) {
|
|
653
|
+
const o = this.$refs.chart.parentNode, { height: h, width: b } = o.getBoundingClientRect();
|
|
654
|
+
let t = null, e = 0;
|
|
655
|
+
this.FINAL_CONFIG.chart.title.show && (t = this.$refs.chartTitle, e = t.getBoundingClientRect().height);
|
|
656
|
+
let N = null, A = 0;
|
|
657
|
+
this.FINAL_CONFIG.chart.zoom.show && this.maxX > 6 && this.isDataset && (N = this.$refs.chartSlicer.$el, A = N.getBoundingClientRect().height);
|
|
658
|
+
let f = null, F = 0;
|
|
659
|
+
this.FINAL_CONFIG.chart.legend.show && (f = this.$refs.chartLegend, F = f.getBoundingClientRect().height), this.height = h - e - F - A, this.width = b, this.viewBox = `0 0 ${this.width < 0 ? 10 : this.width} ${this.height < 0 ? 10 : this.height}`, this.convertSizes(), new ResizeObserver((k) => {
|
|
660
|
+
for (const w of k)
|
|
661
|
+
t && (e = t.getBoundingClientRect().height), N && (A = N.getBoundingClientRect().height), f && (F = f.getBoundingClientRect().height), this.height = w.contentBoxSize[0].blockSize - e - F - A - 24, this.width = w.contentBoxSize[0].inlineSize, this.viewBox = `0 0 ${this.width < 0 ? 10 : this.width} ${this.height < 0 ? 10 : this.height}`, this.convertSizes();
|
|
662
|
+
}).observe(o);
|
|
663
|
+
} else
|
|
664
|
+
this.height = this.FINAL_CONFIG.chart.height, this.width = this.FINAL_CONFIG.chart.width, this.viewBox = `0 0 ${this.width} ${this.height}`, this.fontSizes.dataLabels = this.FINAL_CONFIG.chart.grid.labels.fontSize, this.fontSizes.yAxis = this.FINAL_CONFIG.chart.grid.labels.axis.fontSize, this.fontSizes.xAxis = this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.fontSize, this.fontSizes.plotLabels = this.FINAL_CONFIG.chart.labels.fontSize, this.plotRadii.plot = this.FINAL_CONFIG.plot.radius, this.plotRadii.line = this.FINAL_CONFIG.line.radius;
|
|
665
|
+
},
|
|
666
|
+
methods: {
|
|
667
|
+
abbreviate: le,
|
|
668
|
+
assignStackRatios: ae,
|
|
669
|
+
calculateNiceScale: re,
|
|
670
|
+
checkNaN: ie,
|
|
671
|
+
createSmoothPath: se,
|
|
672
|
+
isSafeValue: oe,
|
|
673
|
+
treeShake: ne,
|
|
674
|
+
shiftHue: ce,
|
|
675
|
+
pdf: Z,
|
|
676
|
+
img: K,
|
|
677
|
+
convertColorToHex: he,
|
|
678
|
+
convertConfigColors: ue,
|
|
679
|
+
convertCustomPalette: de,
|
|
680
|
+
downloadCsv: ge,
|
|
681
|
+
createCsvContent: fe,
|
|
682
|
+
adaptColorToBackground: be,
|
|
683
|
+
calcLinearProgression: Ie,
|
|
684
|
+
useMouse: we,
|
|
685
|
+
closestDecimal: me,
|
|
686
|
+
dataLabel: Ne,
|
|
687
|
+
isFunction: _e,
|
|
688
|
+
functionReturnsString: Fe,
|
|
689
|
+
error: xe,
|
|
690
|
+
objectIsEmpty: ye,
|
|
691
|
+
createTSpans: Ae,
|
|
692
|
+
useNestedProp: q,
|
|
693
|
+
translateSize: Se,
|
|
694
|
+
convertSizes() {
|
|
695
|
+
this.fontSizes.dataLabels = this.translateSize({
|
|
696
|
+
relator: this.height,
|
|
697
|
+
adjuster: 400,
|
|
698
|
+
source: this.FINAL_CONFIG.chart.grid.labels.fontSize,
|
|
699
|
+
threshold: 10,
|
|
700
|
+
fallback: 10
|
|
701
|
+
}), this.fontSizes.yAxis = this.translateSize({
|
|
702
|
+
relator: this.width,
|
|
703
|
+
adjuster: 1e3,
|
|
704
|
+
source: this.FINAL_CONFIG.chart.grid.labels.axis.fontSize,
|
|
705
|
+
threshold: 10,
|
|
706
|
+
fallback: 10
|
|
707
|
+
}), this.fontSizes.xAxis = this.translateSize({
|
|
708
|
+
relator: this.width,
|
|
709
|
+
adjuster: 1e3,
|
|
710
|
+
source: this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.fontSize,
|
|
711
|
+
threshold: 10,
|
|
712
|
+
fallback: 10
|
|
713
|
+
}), this.fontSizes.plotLabels = this.translateSize({
|
|
714
|
+
relator: this.width,
|
|
715
|
+
adjuster: 800,
|
|
716
|
+
source: this.FINAL_CONFIG.chart.labels.fontSize,
|
|
717
|
+
threshold: 10,
|
|
718
|
+
fallback: 10
|
|
719
|
+
}), this.plotRadii.plot = this.translateSize({
|
|
720
|
+
relator: this.width,
|
|
721
|
+
adjuster: 800,
|
|
722
|
+
source: this.FINAL_CONFIG.plot.radius,
|
|
723
|
+
threshold: 1,
|
|
724
|
+
fallback: 1
|
|
725
|
+
}), this.plotRadii.line = this.translateSize({
|
|
726
|
+
relator: this.width,
|
|
727
|
+
adjuster: 800,
|
|
728
|
+
source: this.FINAL_CONFIG.line.radius,
|
|
729
|
+
threshold: 1,
|
|
730
|
+
fallback: 1
|
|
731
|
+
});
|
|
732
|
+
},
|
|
733
|
+
toggleStack() {
|
|
734
|
+
this.mutableConfig.isStacked = !this.mutableConfig.isStacked, this.mutableConfig.isStacked ? this.mutableConfig.useIndividualScale = !0 : this.mutableConfig.useIndividualScale = this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale;
|
|
735
|
+
},
|
|
736
|
+
toggleTable() {
|
|
737
|
+
this.mutableConfig.showTable = !this.mutableConfig.showTable;
|
|
738
|
+
},
|
|
739
|
+
toggleLabels() {
|
|
740
|
+
this.mutableConfig.dataLabels.show = !this.mutableConfig.dataLabels.show;
|
|
741
|
+
},
|
|
742
|
+
toggleTooltip() {
|
|
743
|
+
this.mutableConfig.showTooltip = !this.mutableConfig.showTooltip;
|
|
744
|
+
},
|
|
745
|
+
checkAutoScaleError(a) {
|
|
746
|
+
a.autoScaling && (this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale || console.warn(`VueUiXy (datapoint: ${a.name}) : autoScaling only works when config.chart.grid.labels.yAxis.useIndividualScale is set to true`), this.FINAL_CONFIG.chart.grid.labels.yAxis.stacked || console.warn(`VueUiXy (datapoint: ${a.name}) : autoScaling only works when config.chart.grid.labels.yAxis.stacked is set to true`));
|
|
747
|
+
},
|
|
748
|
+
createArea(a) {
|
|
749
|
+
if (!a[0]) return [-10, -10, "", -10, -10];
|
|
750
|
+
const o = { x: a[0].x, y: this.zero }, h = { x: a.at(-1).x, y: this.zero }, b = [];
|
|
751
|
+
return a.forEach((t) => {
|
|
752
|
+
b.push(`${t.x},${t.y} `);
|
|
753
|
+
}), [o.x, o.y, ...b, h.x, h.y].toString();
|
|
754
|
+
},
|
|
755
|
+
createIndividualArea(a, o) {
|
|
756
|
+
if (!a[0]) return [-10, -10, "", -10, -10];
|
|
757
|
+
const h = { x: a[0] ? a[0].x : Math.min(...a.filter((e) => !!e).map((e) => e.x)), y: o }, b = { x: a.at(-1) ? a.at(-1).x : Math.min(...a.filter((e) => !!e).map((e) => e.x)), y: o }, t = [];
|
|
758
|
+
return a.filter((e) => !!e).forEach((e) => {
|
|
759
|
+
t.push(`${e.x},${e.y} `);
|
|
760
|
+
}), [h.x, h.y, ...t, b.x, b.y].toString();
|
|
761
|
+
},
|
|
762
|
+
createStar: X,
|
|
763
|
+
createPolygonPath: M,
|
|
764
|
+
/////////////////////////////// CANVAS /////////////////////////////////
|
|
765
|
+
fillArray(a, o) {
|
|
766
|
+
let h = Array(a).fill(0);
|
|
767
|
+
for (let b = 0; b < o.length && b < a; b += 1)
|
|
768
|
+
h[b] = o[b];
|
|
769
|
+
return h;
|
|
770
|
+
},
|
|
771
|
+
refreshSlicer() {
|
|
772
|
+
this.slicer = {
|
|
773
|
+
start: 0,
|
|
774
|
+
end: Math.max(...this.dataset.map((a) => a.series.length))
|
|
775
|
+
}, this.slicerStep += 1;
|
|
776
|
+
},
|
|
777
|
+
calcRectHeight(a) {
|
|
778
|
+
return a.value >= 0 ? this.zero - a.y <= 0 ? 1e-5 : this.zero - a.y : a.y - this.zero <= 0 ? 1e-5 : a.y - this.zero;
|
|
779
|
+
},
|
|
780
|
+
calcIndividualHeight(a) {
|
|
781
|
+
return a.value >= 0 ? a.zeroPosition - a.y <= 0 ? 1e-5 : a.zeroPosition - a.y : a.y - a.zeroPosition <= 0 ? 1e-5 : a.zeroPosition - a.y;
|
|
782
|
+
},
|
|
783
|
+
calcRectWidth() {
|
|
784
|
+
return this.mutableConfig.useIndividualScale && this.mutableConfig.isStacked ? this.slot.line - this.drawingArea.width / this.maxSeries * 0.1 : this.slot.bar;
|
|
785
|
+
},
|
|
786
|
+
calcRectX(a) {
|
|
787
|
+
return this.mutableConfig.useIndividualScale && this.mutableConfig.isStacked ? a.x + this.drawingArea.width / this.maxSeries * 0.05 : a.x + this.slot.bar / 2;
|
|
788
|
+
},
|
|
789
|
+
calcRectY(a) {
|
|
790
|
+
return a.value >= 0 ? a.y : this.zero;
|
|
791
|
+
},
|
|
792
|
+
calcIndividualRectY(a) {
|
|
793
|
+
return a.value >= 0 ? a.y : a.zeroPosition;
|
|
794
|
+
},
|
|
795
|
+
canShowValue(a) {
|
|
796
|
+
return ![null, void 0, NaN].includes(a);
|
|
797
|
+
},
|
|
798
|
+
findClosestValue(a, o) {
|
|
799
|
+
let h = o[0], b = Math.abs(a - o[0]);
|
|
800
|
+
for (let t = 1; t < o.length; t += 1) {
|
|
801
|
+
const e = Math.abs(a - o[t]);
|
|
802
|
+
e < b && o[t] < a && (h = o[t], b = e);
|
|
803
|
+
}
|
|
804
|
+
return h;
|
|
805
|
+
},
|
|
806
|
+
ratioToMax(a) {
|
|
807
|
+
return a / this.absoluteMax;
|
|
808
|
+
},
|
|
809
|
+
selectX(a) {
|
|
810
|
+
this.$emit(
|
|
811
|
+
"selectX",
|
|
812
|
+
{
|
|
813
|
+
dataset: this.relativeDataset.map((o) => ({
|
|
814
|
+
name: o.name,
|
|
815
|
+
value: [null, void 0, NaN].includes(o.absoluteValues[a]) ? null : o.absoluteValues[a],
|
|
816
|
+
color: o.color,
|
|
817
|
+
type: o.type
|
|
818
|
+
})),
|
|
819
|
+
index: a,
|
|
820
|
+
indexLabel: this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[a]
|
|
821
|
+
}
|
|
822
|
+
);
|
|
823
|
+
},
|
|
824
|
+
getData() {
|
|
825
|
+
return this.absoluteDataset.map((a) => ({
|
|
826
|
+
values: a.absoluteValues,
|
|
827
|
+
color: a.color,
|
|
828
|
+
name: a.name,
|
|
829
|
+
type: a.type
|
|
830
|
+
}));
|
|
831
|
+
},
|
|
832
|
+
segregate(a) {
|
|
833
|
+
if (this.segregatedSeries.includes(a.id))
|
|
834
|
+
this.segregatedSeries = this.segregatedSeries.filter((o) => o !== a.id);
|
|
835
|
+
else {
|
|
836
|
+
if (this.segregatedSeries.length + 1 === this.safeDataset.length) return;
|
|
837
|
+
this.segregatedSeries.push(a.id);
|
|
838
|
+
}
|
|
839
|
+
this.$emit("selectLegend", this.relativeDataset.map((o) => ({
|
|
840
|
+
name: o.name,
|
|
841
|
+
values: o.absoluteValues,
|
|
842
|
+
color: o.color,
|
|
843
|
+
type: o.type
|
|
844
|
+
}))), this.segregateStep += 1;
|
|
845
|
+
},
|
|
846
|
+
toggleTooltipVisibility(a, o = null) {
|
|
847
|
+
this.isTooltip = a, a ? this.selectedSerieIndex = o : this.selectedSerieIndex = null;
|
|
848
|
+
},
|
|
849
|
+
toggleFullscreen(a) {
|
|
850
|
+
this.isFullscreen = a, this.step += 1;
|
|
851
|
+
},
|
|
852
|
+
showSpinnerPdf() {
|
|
853
|
+
this.isPrinting = !0;
|
|
854
|
+
},
|
|
855
|
+
generatePdf() {
|
|
856
|
+
this.showSpinnerPdf(), clearTimeout(this.__to__), this.__to__ = setTimeout(() => {
|
|
857
|
+
this.pdf({
|
|
858
|
+
domElement: document.getElementById(`vue-ui-xy_${this.uniqueId}`),
|
|
859
|
+
fileName: this.FINAL_CONFIG.chart.title.text || "vue-ui-xy"
|
|
860
|
+
}).finally(() => {
|
|
861
|
+
this.isPrinting = !1;
|
|
862
|
+
});
|
|
863
|
+
}, 100);
|
|
864
|
+
},
|
|
865
|
+
generateCsv() {
|
|
866
|
+
const a = [[this.FINAL_CONFIG.chart.title.text], [this.FINAL_CONFIG.chart.title.subtitle.text], [""]], o = ["", ...this.table.head.map((e) => e.label)], h = this.table.body, b = a.concat([o]).concat(h), t = this.createCsvContent(b);
|
|
867
|
+
this.downloadCsv({ csvContent: t, title: this.FINAL_CONFIG.chart.title.text || "vue-ui-xy" });
|
|
868
|
+
},
|
|
869
|
+
showSpinnerImage() {
|
|
870
|
+
this.isImaging = !0;
|
|
871
|
+
},
|
|
872
|
+
generateImage() {
|
|
873
|
+
this.showSpinnerImage(), clearTimeout(this.__to__), this.__to__ = setTimeout(() => {
|
|
874
|
+
this.img({
|
|
875
|
+
domElement: document.getElementById(`vue-ui-xy_${this.uniqueId}`),
|
|
876
|
+
fileName: this.FINAL_CONFIG.chart.title.text || "vue-ui-xy",
|
|
877
|
+
format: "png"
|
|
878
|
+
}).finally(() => {
|
|
879
|
+
this.isImaging = !1;
|
|
880
|
+
});
|
|
881
|
+
}, 100);
|
|
882
|
+
}
|
|
883
|
+
}
|
|
884
|
+
}, We = ["id"], Ye = ["viewBox"], Ee = { key: 0 }, Xe = { class: "vue-ui-xy-grid" }, qe = ["stroke", "x1", "x2", "y1", "y2"], Ue = ["stroke", "x1", "x2", "y1", "y2"], Ze = { key: 1 }, Je = ["x1", "x2", "y1", "y2", "stroke"], Ke = ["x1", "x2", "y1", "y2", "stroke"], Qe = ["x1", "x2", "y1", "y2", "stroke"], je = { key: 3 }, $e = ["x1", "x2", "y1", "y2", "stroke"], et = ["id"], tt = ["stop-color"], lt = ["stop-color"], at = ["stop-color"], rt = ["id"], it = ["stop-color"], st = ["stop-color"], ot = ["stop-color"], nt = ["id"], ct = ["stop-color"], ht = ["stop-color"], ut = ["id"], dt = ["stop-color"], gt = ["stop-color"], ft = ["id"], bt = ["stop-color"], It = ["stop-color"], mt = ["x", "y", "height", "width", "rx", "fill", "stroke", "stroke-width"], Nt = ["width", "x", "y"], _t = { key: 0 }, Ft = ["id"], xt = ["fill"], yt = ["x1", "x2", "y1", "y2", "stroke", "marker-end"], At = ["x", "y", "font-size", "fill"], St = ["stroke", "x1", "x2", "y1", "y2"], Lt = ["width", "x", "y"], Ct = { style: { width: "100%" } }, kt = { key: 0 }, wt = ["id"], Ot = ["fill"], vt = ["x1", "x2", "y1", "y2", "stroke", "marker-end"], Gt = ["x", "y", "font-size", "fill"], zt = ["d", "stroke", "stroke-width", "stroke-dasharray"], pt = { key: 1 }, Tt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Mt = { key: 0 }, Pt = ["d", "fill"], Vt = ["d", "fill"], Rt = ["d", "stroke", "stroke-width", "stroke-dasharray"], Dt = { key: 2 }, Ht = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Bt = ["width", "x", "y"], Wt = { style: { width: "100%" } }, Yt = { key: 3 }, Et = ["id"], Xt = ["fill"], qt = ["x1", "x2", "y1", "y2", "stroke", "marker-end"], Ut = ["x", "y", "font-size", "fill"], Zt = { key: 2 }, Jt = ["x", "y", "font-size", "fill"], Kt = ["x", "y", "font-size", "fill", "font-weight"], Qt = { key: 3 }, jt = ["x", "y", "font-size", "fill"], $t = ["x", "y"], el = ["x", "y"], tl = { key: 4 }, ll = ["x", "y", "font-size", "fill"], al = ["x", "y"], rl = ["x", "y"], il = { key: 5 }, sl = ["x", "y", "height", "width", "fill"], ol = ["x", "y", "width"], nl = ["y", "width", "height", "fill"], cl = ["x", "y", "width", "height", "fill"], hl = ["x", "y", "font-size", "fill", "innerHTML"], ul = ["x", "y", "font-size", "fill", "innerHTML"], dl = ["x", "y", "font-size", "fill", "innerHTML"], gl = ["x", "y", "font-size", "fill", "innerHTML"], fl = { key: 6 }, bl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Il = ["fill", "font-size", "transform"], ml = ["x1", "x2", "y1", "y2", "stroke"], Nl = ["x", "y", "font-size", "fill"], _l = ["x1", "x2", "y1", "y2", "stroke"], Fl = ["x", "y", "font-size", "fill"], xl = ["x", "y", "width", "height", "fill", "onMouseenter"], yl = ["font-size", "fill", "transform"], Al = ["x", "y", "font-size", "fill"], Sl = { key: 8 }, Ll = ["text-anchor", "font-size", "fill", "transform"], Cl = ["x", "y", "height", "width", "fill", "onMouseenter", "onClick"], kl = { key: 9 }, wl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Ol = { key: 10 }, vl = ["x", "y"], Gl = ["cx", "cy", "r", "fill"], zl = ["onClick"], pl = {
|
|
885
|
+
key: 0,
|
|
886
|
+
viewBox: "0 0 20 12",
|
|
887
|
+
height: "14",
|
|
888
|
+
width: "20"
|
|
889
|
+
}, Tl = ["fill"], Ml = {
|
|
890
|
+
key: 1,
|
|
891
|
+
viewBox: "0 0 12 12",
|
|
892
|
+
height: "14",
|
|
893
|
+
width: "14"
|
|
894
|
+
}, Pl = ["fill"], Vl = {
|
|
895
|
+
key: 6,
|
|
896
|
+
ref: "chartLegend"
|
|
897
|
+
}, Rl = {
|
|
898
|
+
style: { display: "flex", "flex-direction": "row", gap: "6px", "align-items": "center", "padding-left": "6px" },
|
|
899
|
+
"data-html2canvas-ignore": ""
|
|
900
|
+
}, Dl = ["innerHTML"];
|
|
901
|
+
function Hl(a, o, h, b, t, e) {
|
|
902
|
+
const N = P("Title"), A = P("UserOptions"), f = P("Shape"), F = P("Skeleton"), p = P("Slicer"), k = P("Tooltip"), w = P("BaseIcon"), v = P("TableSparkline"), _ = P("DataTable"), L = P("Accordion");
|
|
903
|
+
return r(), i("div", {
|
|
904
|
+
id: `vue-ui-xy_${t.uniqueId}`,
|
|
905
|
+
class: T(`vue-ui-xy ${t.isFullscreen ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.FINAL_CONFIG.useCssAnimation ? "" : "vue-ui-dna"}`),
|
|
906
|
+
ref: "chart",
|
|
907
|
+
style: S(`background:${e.FINAL_CONFIG.chart.backgroundColor}; color:${e.FINAL_CONFIG.chart.color};width:100%;${e.FINAL_CONFIG.chart.title.text ? "" : "padding-top:36px"};font-family:${e.FINAL_CONFIG.chart.fontFamily};${e.FINAL_CONFIG.responsive ? "height: 100%" : ""}`)
|
|
908
|
+
}, [
|
|
909
|
+
e.FINAL_CONFIG.chart.title.show ? (r(), i("div", {
|
|
910
|
+
key: 0,
|
|
911
|
+
ref: "chartTitle",
|
|
912
|
+
class: "vue-ui-xy-title",
|
|
913
|
+
style: S(`font-family:${e.FINAL_CONFIG.chart.fontFamily}`)
|
|
914
|
+
}, [
|
|
915
|
+
W(N, {
|
|
916
|
+
config: {
|
|
917
|
+
title: {
|
|
918
|
+
cy: "xy-div-title",
|
|
919
|
+
...e.FINAL_CONFIG.chart.title
|
|
920
|
+
},
|
|
921
|
+
subtitle: {
|
|
922
|
+
cy: "xy-div-subtitle",
|
|
923
|
+
...e.FINAL_CONFIG.chart.title.subtitle
|
|
924
|
+
}
|
|
925
|
+
}
|
|
926
|
+
}, null, 8, ["config"])
|
|
927
|
+
], 4)) : c("", !0),
|
|
928
|
+
e.FINAL_CONFIG.chart.userOptions.show && e.isDataset ? (r(), V(A, {
|
|
929
|
+
ref: "defails",
|
|
930
|
+
key: `user_options_${t.step}`,
|
|
931
|
+
backgroundColor: e.FINAL_CONFIG.chart.backgroundColor,
|
|
932
|
+
color: e.FINAL_CONFIG.chart.color,
|
|
933
|
+
isPrinting: t.isPrinting,
|
|
934
|
+
isImaging: t.isImaging,
|
|
935
|
+
uid: t.uniqueId,
|
|
936
|
+
hasTooltip: e.FINAL_CONFIG.chart.userOptions.buttons.tooltip && e.FINAL_CONFIG.chart.tooltip.show,
|
|
937
|
+
hasPdf: e.FINAL_CONFIG.chart.userOptions.buttons.pdf,
|
|
938
|
+
hasXls: e.FINAL_CONFIG.chart.userOptions.buttons.csv,
|
|
939
|
+
hasImg: e.FINAL_CONFIG.chart.userOptions.buttons.img,
|
|
940
|
+
hasLabel: e.FINAL_CONFIG.chart.userOptions.buttons.labels,
|
|
941
|
+
hasTable: e.FINAL_CONFIG.chart.userOptions.buttons.table,
|
|
942
|
+
hasStack: h.dataset.length > 1 && e.FINAL_CONFIG.chart.userOptions.buttons.stack,
|
|
943
|
+
hasFullscreen: e.FINAL_CONFIG.chart.userOptions.buttons.fullscreen,
|
|
944
|
+
isStacked: t.mutableConfig.isStacked,
|
|
945
|
+
isFullscreen: t.isFullscreen,
|
|
946
|
+
chartElement: a.$refs.chart,
|
|
947
|
+
isTooltip: t.mutableConfig.showTooltip,
|
|
948
|
+
titles: { ...e.FINAL_CONFIG.chart.userOptions.buttonTitles },
|
|
949
|
+
onToggleFullscreen: e.toggleFullscreen,
|
|
950
|
+
onGeneratePdf: e.generatePdf,
|
|
951
|
+
onGenerateCsv: e.generateCsv,
|
|
952
|
+
onGenerateImage: e.generateImage,
|
|
953
|
+
onToggleTable: e.toggleTable,
|
|
954
|
+
onToggleLabels: e.toggleLabels,
|
|
955
|
+
onToggleStack: e.toggleStack,
|
|
956
|
+
onToggleTooltip: e.toggleTooltip
|
|
957
|
+
}, Me({ _: 2 }, [
|
|
958
|
+
a.$slots.optionTooltip ? {
|
|
959
|
+
name: "optionTooltip",
|
|
960
|
+
fn: z(() => [
|
|
961
|
+
G(a.$slots, "optionTooltip", {}, void 0, !0)
|
|
962
|
+
]),
|
|
963
|
+
key: "0"
|
|
964
|
+
} : void 0,
|
|
965
|
+
a.$slots.optionPdf ? {
|
|
966
|
+
name: "optionPdf",
|
|
967
|
+
fn: z(() => [
|
|
968
|
+
G(a.$slots, "optionPdf", {}, void 0, !0)
|
|
969
|
+
]),
|
|
970
|
+
key: "1"
|
|
971
|
+
} : void 0,
|
|
972
|
+
a.$slots.optionCsv ? {
|
|
973
|
+
name: "optionCsv",
|
|
974
|
+
fn: z(() => [
|
|
975
|
+
G(a.$slots, "optionCsv", {}, void 0, !0)
|
|
976
|
+
]),
|
|
977
|
+
key: "2"
|
|
978
|
+
} : void 0,
|
|
979
|
+
a.$slots.optionImg ? {
|
|
980
|
+
name: "optionImg",
|
|
981
|
+
fn: z(() => [
|
|
982
|
+
G(a.$slots, "optionImg", {}, void 0, !0)
|
|
983
|
+
]),
|
|
984
|
+
key: "3"
|
|
985
|
+
} : void 0,
|
|
986
|
+
a.$slots.optionTable ? {
|
|
987
|
+
name: "optionTable",
|
|
988
|
+
fn: z(() => [
|
|
989
|
+
G(a.$slots, "optionTable", {}, void 0, !0)
|
|
990
|
+
]),
|
|
991
|
+
key: "4"
|
|
992
|
+
} : void 0,
|
|
993
|
+
a.$slots.optionLabels ? {
|
|
994
|
+
name: "optionLabels",
|
|
995
|
+
fn: z(() => [
|
|
996
|
+
G(a.$slots, "optionLabels", {}, void 0, !0)
|
|
997
|
+
]),
|
|
998
|
+
key: "5"
|
|
999
|
+
} : void 0,
|
|
1000
|
+
a.$slots.optionStack ? {
|
|
1001
|
+
name: "optionStack",
|
|
1002
|
+
fn: z(() => [
|
|
1003
|
+
G(a.$slots, "optionStack", {}, void 0, !0)
|
|
1004
|
+
]),
|
|
1005
|
+
key: "6"
|
|
1006
|
+
} : void 0,
|
|
1007
|
+
a.$slots.optionFullscreen ? {
|
|
1008
|
+
name: "optionFullscreen",
|
|
1009
|
+
fn: z(({ toggleFullscreen: l, isFullscreen: n }) => [
|
|
1010
|
+
G(a.$slots, "optionFullscreen", Y(E({ toggleFullscreen: l, isFullscreen: n })), void 0, !0)
|
|
1011
|
+
]),
|
|
1012
|
+
key: "7"
|
|
1013
|
+
} : void 0
|
|
1014
|
+
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasLabel", "hasTable", "hasStack", "hasFullscreen", "isStacked", "isFullscreen", "chartElement", "isTooltip", "titles", "onToggleFullscreen", "onGeneratePdf", "onGenerateCsv", "onGenerateImage", "onToggleTable", "onToggleLabels", "onToggleStack", "onToggleTooltip"])) : c("", !0),
|
|
1015
|
+
e.isDataset ? (r(), i("svg", {
|
|
1016
|
+
key: 2,
|
|
1017
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1018
|
+
class: T([{ "vue-data-ui-fullscreen--on": t.isFullscreen, "vue-data-ui-fulscreen--off": !t.isFullscreen }, "vue-ui-xy-svg"]),
|
|
1019
|
+
width: "100%",
|
|
1020
|
+
viewBox: t.viewBox,
|
|
1021
|
+
style: S(`background:${e.FINAL_CONFIG.chart.backgroundColor}; color:${e.FINAL_CONFIG.chart.color}; font-family:${e.FINAL_CONFIG.chart.fontFamily}`)
|
|
1022
|
+
}, [
|
|
1023
|
+
e.maxSeries > 0 ? (r(), i("g", Ee, [
|
|
1024
|
+
d("g", Xe, [
|
|
1025
|
+
e.FINAL_CONFIG.chart.grid.labels.xAxis.showBaseline ? (r(), i("line", {
|
|
1026
|
+
key: 0,
|
|
1027
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1028
|
+
"stroke-width": "1",
|
|
1029
|
+
x1: e.drawingArea.left,
|
|
1030
|
+
x2: e.drawingArea.right,
|
|
1031
|
+
y1: e.drawingArea.bottom,
|
|
1032
|
+
y2: e.drawingArea.bottom,
|
|
1033
|
+
"stroke-linecap": "round"
|
|
1034
|
+
}, null, 8, qe)) : c("", !0),
|
|
1035
|
+
t.mutableConfig.useIndividualScale ? e.FINAL_CONFIG.chart.grid.showHorizontalLines ? (r(!0), i(I, { key: 2 }, m(e.allScales, (l) => (r(), i("g", null, [
|
|
1036
|
+
l.id === t.selectedScale && l.yLabels.length ? (r(!0), i(I, { key: 0 }, m(l.yLabels, (n) => (r(), i("line", {
|
|
1037
|
+
x1: e.drawingArea.left,
|
|
1038
|
+
x2: e.drawingArea.right,
|
|
1039
|
+
y1: n.y,
|
|
1040
|
+
y2: n.y,
|
|
1041
|
+
stroke: l.color,
|
|
1042
|
+
"stroke-width": 0.5,
|
|
1043
|
+
"stroke-linecap": "round"
|
|
1044
|
+
}, null, 8, Ke))), 256)) : l.yLabels.length ? (r(!0), i(I, { key: 1 }, m(l.yLabels, (n) => (r(), i("line", {
|
|
1045
|
+
x1: e.drawingArea.left,
|
|
1046
|
+
x2: e.drawingArea.right,
|
|
1047
|
+
y1: n.y,
|
|
1048
|
+
y2: n.y,
|
|
1049
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1050
|
+
"stroke-width": 0.5,
|
|
1051
|
+
"stroke-linecap": "round"
|
|
1052
|
+
}, null, 8, Qe))), 256)) : c("", !0)
|
|
1053
|
+
]))), 256)) : c("", !0) : (r(), i(I, { key: 1 }, [
|
|
1054
|
+
e.FINAL_CONFIG.chart.grid.labels.yAxis.showBaseline ? (r(), i("line", {
|
|
1055
|
+
key: 0,
|
|
1056
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1057
|
+
"stroke-width": "1",
|
|
1058
|
+
x1: e.drawingArea.left,
|
|
1059
|
+
x2: e.drawingArea.left,
|
|
1060
|
+
y1: e.drawingArea.top,
|
|
1061
|
+
y2: e.drawingArea.bottom,
|
|
1062
|
+
"stroke-linecap": "round"
|
|
1063
|
+
}, null, 8, Ue)) : c("", !0),
|
|
1064
|
+
e.FINAL_CONFIG.chart.grid.showHorizontalLines ? (r(), i("g", Ze, [
|
|
1065
|
+
(r(!0), i(I, null, m(e.yLabels, (l) => (r(), i("line", {
|
|
1066
|
+
x1: e.drawingArea.left,
|
|
1067
|
+
x2: e.drawingArea.right,
|
|
1068
|
+
y1: l.y,
|
|
1069
|
+
y2: l.y,
|
|
1070
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1071
|
+
"stroke-width": 0.5,
|
|
1072
|
+
"stroke-linecap": "round"
|
|
1073
|
+
}, null, 8, Je))), 256))
|
|
1074
|
+
])) : c("", !0)
|
|
1075
|
+
], 64)),
|
|
1076
|
+
e.FINAL_CONFIG.chart.grid.showVerticalLines ? (r(), i("g", je, [
|
|
1077
|
+
(r(!0), i(I, null, m(e.maxSeries + 1, (l, n) => (r(), i("line", {
|
|
1078
|
+
key: `grid_vertical_line_${n}`,
|
|
1079
|
+
x1: e.drawingArea.width / e.maxSeries * n + e.drawingArea.left,
|
|
1080
|
+
x2: e.drawingArea.width / e.maxSeries * n + e.drawingArea.left,
|
|
1081
|
+
y1: e.drawingArea.top,
|
|
1082
|
+
y2: e.drawingArea.bottom,
|
|
1083
|
+
"stroke-width": "0.5",
|
|
1084
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke
|
|
1085
|
+
}, null, 8, $e))), 128))
|
|
1086
|
+
])) : c("", !0)
|
|
1087
|
+
]),
|
|
1088
|
+
(r(!0), i(I, null, m(e.barSet, (l, n) => (r(), i("defs", {
|
|
1089
|
+
key: `def_rect_${n}`
|
|
1090
|
+
}, [
|
|
1091
|
+
d("linearGradient", {
|
|
1092
|
+
id: `rectGradient_pos_${n}_${t.uniqueId}`,
|
|
1093
|
+
x2: "0%",
|
|
1094
|
+
y2: "100%"
|
|
1095
|
+
}, [
|
|
1096
|
+
d("stop", {
|
|
1097
|
+
offset: "0%",
|
|
1098
|
+
"stop-color": l.color
|
|
1099
|
+
}, null, 8, tt),
|
|
1100
|
+
d("stop", {
|
|
1101
|
+
offset: "62%",
|
|
1102
|
+
"stop-color": `${e.shiftHue(l.color, 0.02)}DE`
|
|
1103
|
+
}, null, 8, lt),
|
|
1104
|
+
d("stop", {
|
|
1105
|
+
offset: "100%",
|
|
1106
|
+
"stop-color": `${e.shiftHue(l.color, 0.05)}66`
|
|
1107
|
+
}, null, 8, at)
|
|
1108
|
+
], 8, et),
|
|
1109
|
+
d("linearGradient", {
|
|
1110
|
+
id: `rectGradient_neg_${n}_${t.uniqueId}`,
|
|
1111
|
+
x2: "0%",
|
|
1112
|
+
y2: "100%"
|
|
1113
|
+
}, [
|
|
1114
|
+
d("stop", {
|
|
1115
|
+
offset: "0%",
|
|
1116
|
+
"stop-color": `${e.shiftHue(l.color, 0.05)}66`
|
|
1117
|
+
}, null, 8, it),
|
|
1118
|
+
d("stop", {
|
|
1119
|
+
offset: "38%",
|
|
1120
|
+
"stop-color": `${e.shiftHue(l.color, 0.02)}DE`
|
|
1121
|
+
}, null, 8, st),
|
|
1122
|
+
d("stop", {
|
|
1123
|
+
offset: "100%",
|
|
1124
|
+
"stop-color": l.color
|
|
1125
|
+
}, null, 8, ot)
|
|
1126
|
+
], 8, rt)
|
|
1127
|
+
]))), 128)),
|
|
1128
|
+
(r(!0), i(I, null, m(e.plotSet, (l, n) => (r(), i("defs", {
|
|
1129
|
+
key: `def_plot_${n}`
|
|
1130
|
+
}, [
|
|
1131
|
+
d("radialGradient", {
|
|
1132
|
+
id: `plotGradient_${n}_${t.uniqueId}`,
|
|
1133
|
+
cx: "50%",
|
|
1134
|
+
cy: "50%",
|
|
1135
|
+
r: "50%",
|
|
1136
|
+
fx: "50%",
|
|
1137
|
+
fy: "50%"
|
|
1138
|
+
}, [
|
|
1139
|
+
d("stop", {
|
|
1140
|
+
offset: "0%",
|
|
1141
|
+
"stop-color": `${e.shiftHue(l.color, 0.05)}`
|
|
1142
|
+
}, null, 8, ct),
|
|
1143
|
+
d("stop", {
|
|
1144
|
+
offset: "100%",
|
|
1145
|
+
"stop-color": l.color
|
|
1146
|
+
}, null, 8, ht)
|
|
1147
|
+
], 8, nt)
|
|
1148
|
+
]))), 128)),
|
|
1149
|
+
(r(!0), i(I, null, m(e.lineSet, (l, n) => (r(), i("defs", {
|
|
1150
|
+
key: `def_line_${n}`
|
|
1151
|
+
}, [
|
|
1152
|
+
d("radialGradient", {
|
|
1153
|
+
id: `lineGradient_${n}_${t.uniqueId}`,
|
|
1154
|
+
cx: "50%",
|
|
1155
|
+
cy: "50%",
|
|
1156
|
+
r: "50%",
|
|
1157
|
+
fx: "50%",
|
|
1158
|
+
fy: "50%"
|
|
1159
|
+
}, [
|
|
1160
|
+
d("stop", {
|
|
1161
|
+
offset: "0%",
|
|
1162
|
+
"stop-color": `${e.shiftHue(l.color, 0.05)}`
|
|
1163
|
+
}, null, 8, dt),
|
|
1164
|
+
d("stop", {
|
|
1165
|
+
offset: "100%",
|
|
1166
|
+
"stop-color": l.color
|
|
1167
|
+
}, null, 8, gt)
|
|
1168
|
+
], 8, ut),
|
|
1169
|
+
d("linearGradient", {
|
|
1170
|
+
id: `areaGradient_${n}_${t.uniqueId}`,
|
|
1171
|
+
x1: "0%",
|
|
1172
|
+
x2: "100%",
|
|
1173
|
+
y1: "0%",
|
|
1174
|
+
y2: "0%"
|
|
1175
|
+
}, [
|
|
1176
|
+
d("stop", {
|
|
1177
|
+
offset: "0%",
|
|
1178
|
+
"stop-color": `${e.shiftHue(l.color, 0.03)}${t.opacity[e.FINAL_CONFIG.line.area.opacity]}`
|
|
1179
|
+
}, null, 8, bt),
|
|
1180
|
+
d("stop", {
|
|
1181
|
+
offset: "100%",
|
|
1182
|
+
"stop-color": `${l.color}${t.opacity[e.FINAL_CONFIG.line.area.opacity]}`
|
|
1183
|
+
}, null, 8, It)
|
|
1184
|
+
], 8, ft)
|
|
1185
|
+
]))), 128)),
|
|
1186
|
+
e.barSet.length ? (r(!0), i(I, { key: 0 }, m(e.barSet, (l, n) => (r(), i("g", {
|
|
1187
|
+
key: `serie_bar_${n}`,
|
|
1188
|
+
class: T(`serie_bar_${n}`),
|
|
1189
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1190
|
+
}, [
|
|
1191
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1192
|
+
key: `bar_plot_${n}_${g}`
|
|
1193
|
+
}, [
|
|
1194
|
+
e.canShowValue(s.value) ? (r(), i("rect", {
|
|
1195
|
+
key: 0,
|
|
1196
|
+
x: e.calcRectX(s),
|
|
1197
|
+
y: t.mutableConfig.useIndividualScale ? e.calcIndividualRectY(s) : e.calcRectY(s),
|
|
1198
|
+
height: t.mutableConfig.useIndividualScale ? Math.abs(e.calcIndividualHeight(s)) : Math.abs(e.calcRectHeight(s)),
|
|
1199
|
+
width: e.calcRectWidth() - (t.mutableConfig.useIndividualScale && t.mutableConfig.isStacked ? 0 : e.barPeriodGap) < 0 ? 1e-5 : e.calcRectWidth() - (t.mutableConfig.useIndividualScale && t.mutableConfig.isStacked ? 0 : e.barPeriodGap),
|
|
1200
|
+
rx: e.FINAL_CONFIG.bar.borderRadius,
|
|
1201
|
+
fill: e.FINAL_CONFIG.bar.useGradient ? s.value >= 0 ? `url(#rectGradient_pos_${n}_${t.uniqueId})` : `url(#rectGradient_neg_${n}_${t.uniqueId})` : l.color,
|
|
1202
|
+
stroke: e.FINAL_CONFIG.bar.border.useSerieColor ? l.color : e.FINAL_CONFIG.bar.border.stroke,
|
|
1203
|
+
"stroke-width": e.FINAL_CONFIG.bar.border.strokeWidth
|
|
1204
|
+
}, null, 8, mt)) : c("", !0),
|
|
1205
|
+
s.comment && e.FINAL_CONFIG.chart.comments.show ? (r(), i("foreignObject", {
|
|
1206
|
+
key: 1,
|
|
1207
|
+
style: { overflow: "visible" },
|
|
1208
|
+
height: "12",
|
|
1209
|
+
width: (e.calcRectWidth() - (t.mutableConfig.useIndividualScale && t.mutableConfig.isStacked ? 0 : e.barPeriodGap) < 0 ? 1e-5 : e.calcRectWidth() - (t.mutableConfig.useIndividualScale && t.mutableConfig.isStacked ? 0 : e.barPeriodGap) / 2) + e.FINAL_CONFIG.chart.comments.width,
|
|
1210
|
+
x: e.calcRectX(s) - e.FINAL_CONFIG.chart.comments.width / 2 + e.FINAL_CONFIG.chart.comments.offsetX,
|
|
1211
|
+
y: s.y + e.FINAL_CONFIG.chart.comments.offsetY + 6
|
|
1212
|
+
}, [
|
|
1213
|
+
G(a.$slots, "plot-comment", {
|
|
1214
|
+
plot: { ...s, color: l.color }
|
|
1215
|
+
}, void 0, !0)
|
|
1216
|
+
], 8, Nt)) : c("", !0)
|
|
1217
|
+
]))), 128)),
|
|
1218
|
+
Object.hasOwn(l, "useProgression") && l.useProgression === !0 && !isNaN(e.calcLinearProgression(l.plots).trend) ? (r(), i("g", _t, [
|
|
1219
|
+
d("defs", null, [
|
|
1220
|
+
d("marker", {
|
|
1221
|
+
id: `bar_arrow_${n}`,
|
|
1222
|
+
markerWidth: 7,
|
|
1223
|
+
markerHeight: 7,
|
|
1224
|
+
refX: "0",
|
|
1225
|
+
refY: 7 / 2,
|
|
1226
|
+
orient: "auto"
|
|
1227
|
+
}, [
|
|
1228
|
+
d("polygon", {
|
|
1229
|
+
points: `0 0, 7 ${7 / 2}, 0 7`,
|
|
1230
|
+
fill: l.color
|
|
1231
|
+
}, null, 8, xt)
|
|
1232
|
+
], 8, Ft)
|
|
1233
|
+
]),
|
|
1234
|
+
l.plots.length > 1 ? (r(), i("line", {
|
|
1235
|
+
key: 0,
|
|
1236
|
+
x1: e.calcLinearProgression(l.plots).x1,
|
|
1237
|
+
x2: e.calcLinearProgression(l.plots).x2,
|
|
1238
|
+
y1: e.calcLinearProgression(l.plots).y1,
|
|
1239
|
+
y2: e.calcLinearProgression(l.plots).y2,
|
|
1240
|
+
"stroke-width": 1,
|
|
1241
|
+
stroke: l.color,
|
|
1242
|
+
"stroke-dasharray": 2,
|
|
1243
|
+
"marker-end": `url(#bar_arrow_${n})`
|
|
1244
|
+
}, null, 8, yt)) : c("", !0),
|
|
1245
|
+
l.plots.length > 1 ? (r(), i("text", {
|
|
1246
|
+
key: 1,
|
|
1247
|
+
"text-anchor": "middle",
|
|
1248
|
+
x: e.calcLinearProgression(l.plots).x2,
|
|
1249
|
+
y: e.calcLinearProgression(l.plots).y2 - 6,
|
|
1250
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1251
|
+
fill: l.color
|
|
1252
|
+
}, C(e.dataLabel({
|
|
1253
|
+
v: e.calcLinearProgression(l.plots).trend * 100,
|
|
1254
|
+
s: "%",
|
|
1255
|
+
r: 2
|
|
1256
|
+
})), 9, At)) : c("", !0)
|
|
1257
|
+
])) : c("", !0)
|
|
1258
|
+
], 6))), 128)) : c("", !0),
|
|
1259
|
+
!t.mutableConfig.useIndividualScale && e.FINAL_CONFIG.chart.grid.labels.zeroLine.show ? (r(), i("line", {
|
|
1260
|
+
key: 1,
|
|
1261
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1262
|
+
"stroke-width": "1",
|
|
1263
|
+
x1: e.drawingArea.left,
|
|
1264
|
+
x2: e.drawingArea.right,
|
|
1265
|
+
y1: e.zero,
|
|
1266
|
+
y2: e.zero,
|
|
1267
|
+
"stroke-linecap": "round"
|
|
1268
|
+
}, null, 8, St)) : c("", !0),
|
|
1269
|
+
(r(!0), i(I, null, m(e.plotSet, (l, n) => (r(), i("g", {
|
|
1270
|
+
key: `serie_plot_${n}`,
|
|
1271
|
+
class: T(`serie_plot_${n}`),
|
|
1272
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1273
|
+
}, [
|
|
1274
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1275
|
+
key: `circle_plot_${n}_${g}`
|
|
1276
|
+
}, [
|
|
1277
|
+
e.canShowValue(s.value) ? (r(), V(f, {
|
|
1278
|
+
key: 0,
|
|
1279
|
+
shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(l.shape) ? l.shape : "circle",
|
|
1280
|
+
color: e.FINAL_CONFIG.plot.useGradient ? `url(#plotGradient_${n}_${t.uniqueId})` : l.color,
|
|
1281
|
+
plot: { x: s.x, y: s.y },
|
|
1282
|
+
radius: t.selectedSerieIndex !== null && t.selectedSerieIndex === g ? (t.plotRadii.plot || 6) * 1.5 : t.plotRadii.plot || 6,
|
|
1283
|
+
stroke: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1284
|
+
strokeWidth: 0.5
|
|
1285
|
+
}, null, 8, ["shape", "color", "plot", "radius", "stroke"])) : c("", !0),
|
|
1286
|
+
s.comment && e.FINAL_CONFIG.chart.comments.show ? (r(), i("foreignObject", {
|
|
1287
|
+
key: 1,
|
|
1288
|
+
style: { overflow: "visible" },
|
|
1289
|
+
height: "12",
|
|
1290
|
+
width: e.FINAL_CONFIG.chart.comments.width,
|
|
1291
|
+
x: s.x - e.FINAL_CONFIG.chart.comments.width / 2 + e.FINAL_CONFIG.chart.comments.offsetX,
|
|
1292
|
+
y: s.y + e.FINAL_CONFIG.chart.comments.offsetY + 6
|
|
1293
|
+
}, [
|
|
1294
|
+
d("div", Ct, [
|
|
1295
|
+
G(a.$slots, "plot-comment", {
|
|
1296
|
+
plot: { ...s, color: l.color }
|
|
1297
|
+
}, void 0, !0)
|
|
1298
|
+
])
|
|
1299
|
+
], 8, Lt)) : c("", !0)
|
|
1300
|
+
]))), 128)),
|
|
1301
|
+
Object.hasOwn(l, "useProgression") && l.useProgression === !0 && !isNaN(e.calcLinearProgression(l.plots).trend) ? (r(), i("g", kt, [
|
|
1302
|
+
d("defs", null, [
|
|
1303
|
+
d("marker", {
|
|
1304
|
+
id: `plot_arrow_${n}`,
|
|
1305
|
+
markerWidth: 7,
|
|
1306
|
+
markerHeight: 7,
|
|
1307
|
+
refX: "0",
|
|
1308
|
+
refY: 7 / 2,
|
|
1309
|
+
orient: "auto"
|
|
1310
|
+
}, [
|
|
1311
|
+
d("polygon", {
|
|
1312
|
+
points: `0 0, 7 ${7 / 2}, 0 7`,
|
|
1313
|
+
fill: l.color
|
|
1314
|
+
}, null, 8, Ot)
|
|
1315
|
+
], 8, wt)
|
|
1316
|
+
]),
|
|
1317
|
+
l.plots.length > 1 ? (r(), i("line", {
|
|
1318
|
+
key: 0,
|
|
1319
|
+
x1: e.calcLinearProgression(l.plots).x1,
|
|
1320
|
+
x2: e.calcLinearProgression(l.plots).x2,
|
|
1321
|
+
y1: e.calcLinearProgression(l.plots).y1,
|
|
1322
|
+
y2: e.calcLinearProgression(l.plots).y2,
|
|
1323
|
+
"stroke-width": 1,
|
|
1324
|
+
stroke: l.color,
|
|
1325
|
+
"stroke-dasharray": 2,
|
|
1326
|
+
"marker-end": `url(#plot_arrow_${n})`
|
|
1327
|
+
}, null, 8, vt)) : c("", !0),
|
|
1328
|
+
l.plots.length > 1 ? (r(), i("text", {
|
|
1329
|
+
key: 1,
|
|
1330
|
+
"text-anchor": "middle",
|
|
1331
|
+
x: e.calcLinearProgression(l.plots).x2,
|
|
1332
|
+
y: e.calcLinearProgression(l.plots).y2 - 6,
|
|
1333
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1334
|
+
fill: l.color
|
|
1335
|
+
}, C(e.dataLabel({
|
|
1336
|
+
v: e.calcLinearProgression(l.plots).trend * 100,
|
|
1337
|
+
s: "%",
|
|
1338
|
+
r: 2
|
|
1339
|
+
})), 9, Gt)) : c("", !0)
|
|
1340
|
+
])) : c("", !0)
|
|
1341
|
+
], 6))), 128)),
|
|
1342
|
+
(r(!0), i(I, null, m(e.lineSet, (l, n) => (r(), i("g", {
|
|
1343
|
+
key: `serie_line_${n}`,
|
|
1344
|
+
class: T(`serie_line_${n}`),
|
|
1345
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1346
|
+
}, [
|
|
1347
|
+
l.smooth && l.plots.length > 1 ? (r(), i("path", {
|
|
1348
|
+
key: 0,
|
|
1349
|
+
d: `M${l.curve}`,
|
|
1350
|
+
stroke: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1351
|
+
"stroke-width": e.FINAL_CONFIG.line.strokeWidth + 1,
|
|
1352
|
+
"stroke-dasharray": l.dashed ? e.FINAL_CONFIG.line.strokeWidth * 2 : 0,
|
|
1353
|
+
fill: "none"
|
|
1354
|
+
}, null, 8, zt)) : l.plots.length > 1 ? (r(), i("g", pt, [
|
|
1355
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1356
|
+
key: `line_${n}_${g}`
|
|
1357
|
+
}, [
|
|
1358
|
+
s && g < l.plots.length - 1 && l.plots[g + 1] && e.canShowValue(s.value) && e.canShowValue(l.plots[g + 1].value) ? (r(), i("line", {
|
|
1359
|
+
key: 0,
|
|
1360
|
+
x1: s.x,
|
|
1361
|
+
x2: l.plots[g + 1].x,
|
|
1362
|
+
y1: s.y,
|
|
1363
|
+
y2: l.plots[g + 1].y,
|
|
1364
|
+
stroke: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1365
|
+
"stroke-width": e.FINAL_CONFIG.line.strokeWidth + 1,
|
|
1366
|
+
"stroke-dasharray": l.dashed ? e.FINAL_CONFIG.line.strokeWidth * 2 : 0,
|
|
1367
|
+
"stroke-linejoin": "round",
|
|
1368
|
+
"stroke-linecap": "round"
|
|
1369
|
+
}, null, 8, Tt)) : c("", !0)
|
|
1370
|
+
]))), 128))
|
|
1371
|
+
])) : c("", !0)
|
|
1372
|
+
], 6))), 128)),
|
|
1373
|
+
(r(!0), i(I, null, m(e.lineSet, (l, n) => (r(), i("g", {
|
|
1374
|
+
key: `serie_line_${n}`,
|
|
1375
|
+
class: T(`serie_line_${n}`),
|
|
1376
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1377
|
+
}, [
|
|
1378
|
+
l.useArea && l.plots.length > 1 ? (r(), i("g", Mt, [
|
|
1379
|
+
l.smooth ? (r(), i("path", {
|
|
1380
|
+
key: 0,
|
|
1381
|
+
d: `M ${l.plots[0] ? l.plots[0].x : Math.min(...l.plots.filter((s) => !!s).map((s) => s.x))},${t.mutableConfig.isStacked ? e.drawingArea.bottom - l.yOffset : e.drawingArea.bottom} ${l.curve} L ${l.plots.at(-1) ? l.plots.at(-1).x : e.drawingArea.left + e.slot.line * n + e.slot.line / 2},${t.mutableConfig.isStacked ? e.drawingArea.bottom - l.yOffset : e.drawingArea.bottom} Z`,
|
|
1382
|
+
fill: e.FINAL_CONFIG.line.area.useGradient ? `url(#areaGradient_${n}_${t.uniqueId})` : `${l.color}${t.opacity[e.FINAL_CONFIG.line.area.opacity]}`
|
|
1383
|
+
}, null, 8, Pt)) : (r(), i("path", {
|
|
1384
|
+
key: 1,
|
|
1385
|
+
d: `M${l.area}Z`,
|
|
1386
|
+
fill: e.FINAL_CONFIG.line.area.useGradient ? `url(#areaGradient_${n}_${t.uniqueId})` : `${l.color}${t.opacity[e.FINAL_CONFIG.line.area.opacity]}`
|
|
1387
|
+
}, null, 8, Vt))
|
|
1388
|
+
])) : c("", !0),
|
|
1389
|
+
l.smooth && l.plots.length > 1 ? (r(), i("path", {
|
|
1390
|
+
key: 1,
|
|
1391
|
+
d: `M${l.curve}`,
|
|
1392
|
+
stroke: l.color,
|
|
1393
|
+
"stroke-width": e.FINAL_CONFIG.line.strokeWidth,
|
|
1394
|
+
"stroke-dasharray": l.dashed ? e.FINAL_CONFIG.line.strokeWidth * 2 : 0,
|
|
1395
|
+
fill: "none"
|
|
1396
|
+
}, null, 8, Rt)) : l.plots.length > 1 ? (r(), i("g", Dt, [
|
|
1397
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1398
|
+
key: `line_${n}_${g}`
|
|
1399
|
+
}, [
|
|
1400
|
+
s && g < l.plots.length - 1 && l.plots[g + 1] && e.canShowValue(s.value) && e.canShowValue(l.plots[g + 1].value) ? (r(), i("line", {
|
|
1401
|
+
key: 0,
|
|
1402
|
+
x1: s.x,
|
|
1403
|
+
x2: l.plots[g + 1].x,
|
|
1404
|
+
y1: s.y,
|
|
1405
|
+
y2: l.plots[g + 1].y,
|
|
1406
|
+
stroke: l.color,
|
|
1407
|
+
"stroke-width": e.FINAL_CONFIG.line.strokeWidth,
|
|
1408
|
+
"stroke-dasharray": l.dashed ? e.FINAL_CONFIG.line.strokeWidth * 2 : 0,
|
|
1409
|
+
"stroke-linejoin": "round",
|
|
1410
|
+
"stroke-linecap": "round"
|
|
1411
|
+
}, null, 8, Ht)) : c("", !0)
|
|
1412
|
+
]))), 128))
|
|
1413
|
+
])) : c("", !0),
|
|
1414
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1415
|
+
key: `circle_line_${n}_${g}`
|
|
1416
|
+
}, [
|
|
1417
|
+
s && e.canShowValue(s.value) ? (r(), V(f, {
|
|
1418
|
+
key: 0,
|
|
1419
|
+
shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(l.shape) ? l.shape : "circle",
|
|
1420
|
+
color: e.FINAL_CONFIG.line.useGradient ? `url(#lineGradient_${n}_${t.uniqueId})` : l.color,
|
|
1421
|
+
plot: { x: s.x, y: s.y },
|
|
1422
|
+
radius: t.selectedSerieIndex !== null && t.selectedSerieIndex === g ? (t.plotRadii.line || 6) * 1.5 : t.plotRadii.line,
|
|
1423
|
+
stroke: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1424
|
+
strokeWidth: 0.5
|
|
1425
|
+
}, null, 8, ["shape", "color", "plot", "radius", "stroke"])) : c("", !0),
|
|
1426
|
+
s.comment && e.FINAL_CONFIG.chart.comments.show ? (r(), i("foreignObject", {
|
|
1427
|
+
key: 1,
|
|
1428
|
+
style: { overflow: "visible" },
|
|
1429
|
+
height: "12",
|
|
1430
|
+
width: e.FINAL_CONFIG.chart.comments.width,
|
|
1431
|
+
x: s.x - e.FINAL_CONFIG.chart.comments.width / 2 + e.FINAL_CONFIG.chart.comments.offsetX,
|
|
1432
|
+
y: s.y + e.FINAL_CONFIG.chart.comments.offsetY + 6
|
|
1433
|
+
}, [
|
|
1434
|
+
d("div", Wt, [
|
|
1435
|
+
G(a.$slots, "plot-comment", {
|
|
1436
|
+
plot: { ...s, color: l.color }
|
|
1437
|
+
}, void 0, !0)
|
|
1438
|
+
])
|
|
1439
|
+
], 8, Bt)) : c("", !0)
|
|
1440
|
+
]))), 128)),
|
|
1441
|
+
Object.hasOwn(l, "useProgression") && l.useProgression === !0 && !isNaN(e.calcLinearProgression(l.plots).trend) ? (r(), i("g", Yt, [
|
|
1442
|
+
d("defs", null, [
|
|
1443
|
+
d("marker", {
|
|
1444
|
+
id: `line_arrow_${n}`,
|
|
1445
|
+
markerWidth: 7,
|
|
1446
|
+
markerHeight: 7,
|
|
1447
|
+
refX: "0",
|
|
1448
|
+
refY: 7 / 2,
|
|
1449
|
+
orient: "auto"
|
|
1450
|
+
}, [
|
|
1451
|
+
d("polygon", {
|
|
1452
|
+
points: `0 0, 7 ${7 / 2}, 0 7`,
|
|
1453
|
+
fill: l.color
|
|
1454
|
+
}, null, 8, Xt)
|
|
1455
|
+
], 8, Et)
|
|
1456
|
+
]),
|
|
1457
|
+
l.plots.length > 1 ? (r(), i("line", {
|
|
1458
|
+
key: 0,
|
|
1459
|
+
x1: e.calcLinearProgression(l.plots).x1,
|
|
1460
|
+
x2: e.calcLinearProgression(l.plots).x2,
|
|
1461
|
+
y1: e.calcLinearProgression(l.plots).y1,
|
|
1462
|
+
y2: e.calcLinearProgression(l.plots).y2,
|
|
1463
|
+
"stroke-width": 1,
|
|
1464
|
+
stroke: l.color,
|
|
1465
|
+
"stroke-dasharray": 2,
|
|
1466
|
+
"marker-end": `url(#line_arrow_${n})`
|
|
1467
|
+
}, null, 8, qt)) : c("", !0),
|
|
1468
|
+
l.plots.length > 1 ? (r(), i("text", {
|
|
1469
|
+
key: 1,
|
|
1470
|
+
"text-anchor": "middle",
|
|
1471
|
+
x: e.calcLinearProgression(l.plots).x2,
|
|
1472
|
+
y: e.calcLinearProgression(l.plots).y2 - 6,
|
|
1473
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1474
|
+
fill: l.color
|
|
1475
|
+
}, C(e.dataLabel({
|
|
1476
|
+
v: e.calcLinearProgression(l.plots).trend * 100,
|
|
1477
|
+
s: "%",
|
|
1478
|
+
r: 2
|
|
1479
|
+
})), 9, Ut)) : c("", !0)
|
|
1480
|
+
])) : c("", !0)
|
|
1481
|
+
], 6))), 128)),
|
|
1482
|
+
(e.FINAL_CONFIG.bar.labels.show || e.FINAL_CONFIG.bar.serieName.show) && t.mutableConfig.dataLabels.show ? (r(), i("g", Zt, [
|
|
1483
|
+
(r(!0), i(I, null, m(e.barSet, (l, n) => (r(), i("g", {
|
|
1484
|
+
key: `xLabel_bar_${n}`,
|
|
1485
|
+
class: T(`xLabel_bar_${n}`),
|
|
1486
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1487
|
+
}, [
|
|
1488
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1489
|
+
key: `xLabel_bar_${n}_${g}`
|
|
1490
|
+
}, [
|
|
1491
|
+
s && (!Object.hasOwn(l, "dataLabels") || l.dataLabels === !0) && e.FINAL_CONFIG.bar.labels.show ? (r(), i("text", {
|
|
1492
|
+
key: 0,
|
|
1493
|
+
x: t.mutableConfig.useIndividualScale && t.mutableConfig.isStacked ? s.x + e.slot.line / 2 : e.calcRectX(s) + e.calcRectWidth() / 2 - e.barPeriodGap / 2,
|
|
1494
|
+
y: s.y + (s.value > 0 ? e.FINAL_CONFIG.bar.labels.offsetY : -e.FINAL_CONFIG.bar.labels.offsetY * 3),
|
|
1495
|
+
"text-anchor": "middle",
|
|
1496
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1497
|
+
fill: e.FINAL_CONFIG.bar.labels.color
|
|
1498
|
+
}, C(e.canShowValue(s.value) ? e.dataLabel({ p: e.FINAL_CONFIG.chart.labels.prefix, v: s.value, s: e.FINAL_CONFIG.chart.labels.suffix, r: e.FINAL_CONFIG.bar.labels.rounding }) : ""), 9, Jt)) : c("", !0),
|
|
1499
|
+
s && e.FINAL_CONFIG.bar.serieName.show ? (r(), i("text", {
|
|
1500
|
+
key: 1,
|
|
1501
|
+
x: t.mutableConfig.useIndividualScale && t.mutableConfig.isStacked ? s.x + e.slot.line / 2 : s.x + e.calcRectWidth() * 1.1,
|
|
1502
|
+
y: s.y + (s.value > 0 ? e.FINAL_CONFIG.bar.serieName.offsetY : -e.FINAL_CONFIG.bar.serieName.offsetY * 3),
|
|
1503
|
+
"text-anchor": "middle",
|
|
1504
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1505
|
+
fill: e.FINAL_CONFIG.bar.serieName.useSerieColor ? l.color : e.FINAL_CONFIG.bar.serieName.color,
|
|
1506
|
+
"font-weight": e.FINAL_CONFIG.bar.serieName.bold ? "bold" : "normal"
|
|
1507
|
+
}, C(e.FINAL_CONFIG.bar.serieName.useAbbreviation ? e.abbreviate({ source: l.name, length: e.FINAL_CONFIG.bar.serieName.abbreviationSize }) : l.name), 9, Kt)) : c("", !0)
|
|
1508
|
+
]))), 128))
|
|
1509
|
+
], 6))), 128))
|
|
1510
|
+
])) : c("", !0),
|
|
1511
|
+
e.FINAL_CONFIG.plot.labels.show && t.mutableConfig.dataLabels.show ? (r(), i("g", Qt, [
|
|
1512
|
+
(r(!0), i(I, null, m(e.plotSet, (l, n) => (r(), i("g", {
|
|
1513
|
+
key: `xLabel_plot_${n}`,
|
|
1514
|
+
class: T(`xLabel_plot_${n}`),
|
|
1515
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1516
|
+
}, [
|
|
1517
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1518
|
+
key: `xLabel_plot_${n}_${g}`
|
|
1519
|
+
}, [
|
|
1520
|
+
s && !Object.hasOwn(l, "dataLabels") || l.dataLabels === !0 ? (r(), i("text", {
|
|
1521
|
+
key: 0,
|
|
1522
|
+
x: s.x,
|
|
1523
|
+
y: s.y + e.FINAL_CONFIG.plot.labels.offsetY,
|
|
1524
|
+
"text-anchor": "middle",
|
|
1525
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1526
|
+
fill: e.FINAL_CONFIG.plot.labels.color
|
|
1527
|
+
}, C(e.canShowValue(s.value) ? e.dataLabel({ p: e.FINAL_CONFIG.chart.labels.prefix, v: s.value, s: e.FINAL_CONFIG.chart.labels.suffix, r: e.FINAL_CONFIG.plot.labels.rounding }) : ""), 9, jt)) : c("", !0),
|
|
1528
|
+
s && g === 0 && l.useTag && l.useTag === "start" ? (r(), i("foreignObject", {
|
|
1529
|
+
key: 1,
|
|
1530
|
+
x: s.x,
|
|
1531
|
+
y: s.y - 20,
|
|
1532
|
+
height: 24,
|
|
1533
|
+
width: "150",
|
|
1534
|
+
style: { overflow: "visible" }
|
|
1535
|
+
}, [
|
|
1536
|
+
d("div", {
|
|
1537
|
+
style: S(`padding: 3px; background:${l.color}${t.opacity[80]};color:${e.adaptColorToBackground(l.color)};width:fit-content;font-size:${t.fontSizes.plotLabels}px;border-radius: 2px;`)
|
|
1538
|
+
}, C(l.name), 5)
|
|
1539
|
+
], 8, $t)) : c("", !0),
|
|
1540
|
+
s && g === l.plots.length - 1 && l.useTag && l.useTag === "end" ? (r(), i("foreignObject", {
|
|
1541
|
+
key: 2,
|
|
1542
|
+
x: s.x - l.name.length * (t.fontSizes.plotLabels / 2),
|
|
1543
|
+
y: s.y - 20,
|
|
1544
|
+
height: 24,
|
|
1545
|
+
width: "150",
|
|
1546
|
+
style: { overflow: "visible" }
|
|
1547
|
+
}, [
|
|
1548
|
+
d("div", {
|
|
1549
|
+
style: S(`padding: 3px; background:${l.color}${t.opacity[80]};color:${e.adaptColorToBackground(l.color)};width:fit-content;font-size:${t.fontSizes.plotLabels}px;border-radius: 2px;`)
|
|
1550
|
+
}, C(l.name), 5)
|
|
1551
|
+
], 8, el)) : c("", !0)
|
|
1552
|
+
]))), 128))
|
|
1553
|
+
], 6))), 128))
|
|
1554
|
+
])) : c("", !0),
|
|
1555
|
+
e.FINAL_CONFIG.line.labels.show && t.mutableConfig.dataLabels.show ? (r(), i("g", tl, [
|
|
1556
|
+
(r(!0), i(I, null, m(e.lineSet, (l, n) => (r(), i("g", {
|
|
1557
|
+
key: `xLabel_line_${n}`,
|
|
1558
|
+
class: T(`xLabel_line_${n}`),
|
|
1559
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1560
|
+
}, [
|
|
1561
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1562
|
+
key: `xLabel_line_${n}_${g}`
|
|
1563
|
+
}, [
|
|
1564
|
+
s && !Object.hasOwn(l, "dataLabels") || l.dataLabels === !0 ? (r(), i("text", {
|
|
1565
|
+
key: 0,
|
|
1566
|
+
x: s.x,
|
|
1567
|
+
y: s.y + (s.value > 0 ? e.FINAL_CONFIG.line.labels.offsetY : -e.FINAL_CONFIG.line.labels.offsetY * 3),
|
|
1568
|
+
"text-anchor": "middle",
|
|
1569
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1570
|
+
fill: e.FINAL_CONFIG.line.labels.color
|
|
1571
|
+
}, C(e.canShowValue(s.value) ? e.dataLabel({ p: e.FINAL_CONFIG.chart.labels.prefix, v: s.value, s: e.FINAL_CONFIG.chart.labels.suffix, r: e.FINAL_CONFIG.line.labels.rounding }) : ""), 9, ll)) : c("", !0),
|
|
1572
|
+
s && g === 0 && l.useTag && l.useTag === "start" ? (r(), i("foreignObject", {
|
|
1573
|
+
key: 1,
|
|
1574
|
+
x: s.x,
|
|
1575
|
+
y: s.y - 20,
|
|
1576
|
+
height: 24,
|
|
1577
|
+
width: "150",
|
|
1578
|
+
style: { overflow: "visible" }
|
|
1579
|
+
}, [
|
|
1580
|
+
d("div", {
|
|
1581
|
+
style: S(`padding: 3px; background:${l.color}${t.opacity[80]};color:${e.adaptColorToBackground(l.color)};width:fit-content;font-size:${t.fontSizes.plotLabels}px;border-radius: 2px;`)
|
|
1582
|
+
}, C(l.name), 5)
|
|
1583
|
+
], 8, al)) : c("", !0),
|
|
1584
|
+
s && g === l.plots.length - 1 && l.useTag && l.useTag === "end" ? (r(), i("foreignObject", {
|
|
1585
|
+
key: 2,
|
|
1586
|
+
x: s.x - l.name.length * (t.fontSizes.plotLabels / 2),
|
|
1587
|
+
y: s.y - 20,
|
|
1588
|
+
height: 24,
|
|
1589
|
+
width: "150",
|
|
1590
|
+
style: { overflow: "visible" }
|
|
1591
|
+
}, [
|
|
1592
|
+
d("div", {
|
|
1593
|
+
style: S(`padding: 3px; background:${l.color}${t.opacity[80]};color:${e.adaptColorToBackground(l.color)};width:fit-content;font-size:${t.fontSizes.plotLabels}px;border-radius: 2px;`)
|
|
1594
|
+
}, C(l.name), 5)
|
|
1595
|
+
], 8, rl)) : c("", !0)
|
|
1596
|
+
]))), 128))
|
|
1597
|
+
], 6))), 128))
|
|
1598
|
+
])) : c("", !0),
|
|
1599
|
+
e.hasHighlightArea ? (r(), i("g", il, [
|
|
1600
|
+
d("rect", {
|
|
1601
|
+
x: e.drawingArea.left + e.drawingArea.width / e.maxSeries * (e.FINAL_CONFIG.chart.highlightArea.from - t.slicer.start),
|
|
1602
|
+
y: e.drawingArea.top,
|
|
1603
|
+
height: e.drawingArea.height < 0 ? 10 : e.drawingArea.height,
|
|
1604
|
+
width: e.drawingArea.width / e.maxSeries * e.highlightAreaSpan < 0 ? 1e-5 : e.drawingArea.width / e.maxSeries * e.highlightAreaSpan,
|
|
1605
|
+
fill: `${e.FINAL_CONFIG.chart.highlightArea.color}${t.opacity[e.FINAL_CONFIG.chart.highlightArea.opacity]}`
|
|
1606
|
+
}, null, 8, sl),
|
|
1607
|
+
e.FINAL_CONFIG.chart.highlightArea.caption.text ? (r(), i("foreignObject", {
|
|
1608
|
+
key: 0,
|
|
1609
|
+
x: e.drawingArea.left + e.drawingArea.width / e.maxSeries * (e.FINAL_CONFIG.chart.highlightArea.from - t.slicer.start) - (e.FINAL_CONFIG.chart.highlightArea.caption.width === "auto" ? 0 : e.FINAL_CONFIG.chart.highlightArea.caption.width / 2 - e.drawingArea.width / e.maxSeries * e.highlightAreaSpan / 2),
|
|
1610
|
+
y: e.drawingArea.top + e.FINAL_CONFIG.chart.highlightArea.caption.offsetY,
|
|
1611
|
+
style: { overflow: "visible" },
|
|
1612
|
+
height: "1",
|
|
1613
|
+
width: e.FINAL_CONFIG.chart.highlightArea.caption.width === "auto" ? e.drawingArea.width / e.maxSeries * e.highlightAreaSpan : e.FINAL_CONFIG.chart.highlightArea.caption.width
|
|
1614
|
+
}, [
|
|
1615
|
+
d("div", {
|
|
1616
|
+
style: S(`padding:${e.FINAL_CONFIG.chart.highlightArea.caption.padding}px;text-align:${e.FINAL_CONFIG.chart.highlightArea.caption.textAlign};font-size:${e.FINAL_CONFIG.chart.highlightArea.caption.fontSize}px;color:${e.FINAL_CONFIG.chart.highlightArea.caption.color};font-weight:${e.FINAL_CONFIG.chart.highlightArea.caption.bold ? "bold" : "normal"}`)
|
|
1617
|
+
}, C(e.FINAL_CONFIG.chart.highlightArea.caption.text), 5)
|
|
1618
|
+
], 8, ol)) : c("", !0)
|
|
1619
|
+
])) : c("", !0),
|
|
1620
|
+
d("g", null, [
|
|
1621
|
+
d("rect", {
|
|
1622
|
+
x: 0,
|
|
1623
|
+
y: e.drawingArea.top,
|
|
1624
|
+
width: e.FINAL_CONFIG.chart.padding.left - 1,
|
|
1625
|
+
height: e.drawingArea.height < 0 ? 10 : e.drawingArea.height,
|
|
1626
|
+
fill: e.FINAL_CONFIG.chart.backgroundColor
|
|
1627
|
+
}, null, 8, nl),
|
|
1628
|
+
d("rect", {
|
|
1629
|
+
x: e.drawingArea.right + 1,
|
|
1630
|
+
y: e.drawingArea.top,
|
|
1631
|
+
width: e.FINAL_CONFIG.chart.padding.right,
|
|
1632
|
+
height: e.drawingArea.height < 0 ? 10 : e.drawingArea.height,
|
|
1633
|
+
fill: e.FINAL_CONFIG.chart.backgroundColor
|
|
1634
|
+
}, null, 8, cl)
|
|
1635
|
+
]),
|
|
1636
|
+
(r(!0), i(I, null, m(e.lineSet, (l, n) => (r(), i("g", {
|
|
1637
|
+
key: `xLabel_line_${n}`,
|
|
1638
|
+
class: T(`xLabel_line_${n}`),
|
|
1639
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1640
|
+
}, [
|
|
1641
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1642
|
+
key: `xLabel_line_${n}_${g}`
|
|
1643
|
+
}, [
|
|
1644
|
+
s && g === 0 && l.showSerieName && l.showSerieName === "start" ? (r(), i("text", {
|
|
1645
|
+
key: 0,
|
|
1646
|
+
x: s.x - t.fontSizes.plotLabels,
|
|
1647
|
+
y: s.y,
|
|
1648
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1649
|
+
"text-anchor": "end",
|
|
1650
|
+
fill: l.color,
|
|
1651
|
+
innerHTML: e.createTSpans({
|
|
1652
|
+
content: l.name,
|
|
1653
|
+
fontSize: t.fontSizes.plotLabels,
|
|
1654
|
+
fill: l.color,
|
|
1655
|
+
x: s.x - t.fontSizes.plotLabels,
|
|
1656
|
+
y: s.y,
|
|
1657
|
+
maxWords: 2
|
|
1658
|
+
})
|
|
1659
|
+
}, null, 8, hl)) : c("", !0),
|
|
1660
|
+
s && g === l.plots.length - 1 && l.showSerieName && l.showSerieName === "end" ? (r(), i("text", {
|
|
1661
|
+
key: 1,
|
|
1662
|
+
x: s.x + t.fontSizes.plotLabels,
|
|
1663
|
+
y: s.y,
|
|
1664
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1665
|
+
"text-anchor": "start",
|
|
1666
|
+
fill: l.color,
|
|
1667
|
+
innerHTML: e.createTSpans({
|
|
1668
|
+
content: l.name,
|
|
1669
|
+
fontSize: t.fontSizes.plotLabels,
|
|
1670
|
+
fill: l.color,
|
|
1671
|
+
x: s.x + t.fontSizes.plotLabels,
|
|
1672
|
+
y: s.y,
|
|
1673
|
+
maxWords: 2
|
|
1674
|
+
})
|
|
1675
|
+
}, null, 8, ul)) : c("", !0)
|
|
1676
|
+
]))), 128))
|
|
1677
|
+
], 6))), 128)),
|
|
1678
|
+
(r(!0), i(I, null, m(e.plotSet, (l, n) => (r(), i("g", {
|
|
1679
|
+
key: `xLabel_plot_${n}`,
|
|
1680
|
+
class: T(`xLabel_plot_${n}`),
|
|
1681
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.2 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1682
|
+
}, [
|
|
1683
|
+
(r(!0), i(I, null, m(l.plots, (s, g) => (r(), i("g", {
|
|
1684
|
+
key: `xLabel_plot_${n}_${g}`
|
|
1685
|
+
}, [
|
|
1686
|
+
s && g === 0 && l.showSerieName && l.showSerieName === "start" ? (r(), i("text", {
|
|
1687
|
+
key: 0,
|
|
1688
|
+
x: s.x - t.fontSizes.plotLabels,
|
|
1689
|
+
y: s.y,
|
|
1690
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1691
|
+
"text-anchor": "end",
|
|
1692
|
+
fill: l.color,
|
|
1693
|
+
innerHTML: e.createTSpans({
|
|
1694
|
+
content: l.name,
|
|
1695
|
+
fontSize: t.fontSizes.plotLabels,
|
|
1696
|
+
fill: l.color,
|
|
1697
|
+
x: s.x - t.fontSizes.plotLabels,
|
|
1698
|
+
y: s.y,
|
|
1699
|
+
maxWords: 2
|
|
1700
|
+
})
|
|
1701
|
+
}, null, 8, dl)) : c("", !0),
|
|
1702
|
+
s && g === l.plots.length - 1 && l.showSerieName && l.showSerieName === "end" ? (r(), i("text", {
|
|
1703
|
+
key: 1,
|
|
1704
|
+
x: s.x + t.fontSizes.plotLabels,
|
|
1705
|
+
y: s.y,
|
|
1706
|
+
"font-size": t.fontSizes.plotLabels,
|
|
1707
|
+
"text-anchor": "start",
|
|
1708
|
+
fill: l.color,
|
|
1709
|
+
innerHTML: e.createTSpans({
|
|
1710
|
+
content: l.name,
|
|
1711
|
+
fontSize: t.fontSizes.plotLabels,
|
|
1712
|
+
fill: l.color,
|
|
1713
|
+
x: s.x + t.fontSizes.plotLabels,
|
|
1714
|
+
y: s.y,
|
|
1715
|
+
maxWords: 2
|
|
1716
|
+
})
|
|
1717
|
+
}, null, 8, gl)) : c("", !0)
|
|
1718
|
+
]))), 128))
|
|
1719
|
+
], 6))), 128)),
|
|
1720
|
+
e.FINAL_CONFIG.chart.grid.labels.show ? (r(), i("g", fl, [
|
|
1721
|
+
t.mutableConfig.useIndividualScale ? (r(), i(I, { key: 0 }, [
|
|
1722
|
+
(r(!0), i(I, null, m(e.allScales, (l) => (r(), i("g", null, [
|
|
1723
|
+
d("line", {
|
|
1724
|
+
x1: l.x,
|
|
1725
|
+
x2: l.x,
|
|
1726
|
+
y1: t.mutableConfig.isStacked ? e.drawingArea.bottom - l.yOffset - l.individualHeight : e.drawingArea.top,
|
|
1727
|
+
y2: t.mutableConfig.isStacked ? e.drawingArea.bottom - l.yOffset : e.drawingArea.bottom,
|
|
1728
|
+
stroke: l.color,
|
|
1729
|
+
"stroke-width": e.FINAL_CONFIG.chart.grid.stroke,
|
|
1730
|
+
"stroke-linecap": "round",
|
|
1731
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.3 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1732
|
+
}, null, 12, bl)
|
|
1733
|
+
]))), 256)),
|
|
1734
|
+
(r(!0), i(I, null, m(e.allScales, (l) => (r(), i("g", {
|
|
1735
|
+
style: S(`opacity:${t.selectedScale ? t.selectedScale === l.id ? 1 : 0.3 : 1};transition:opacity 0.2s ease-in-out`)
|
|
1736
|
+
}, [
|
|
1737
|
+
d("text", {
|
|
1738
|
+
fill: l.color,
|
|
1739
|
+
"font-size": t.fontSizes.dataLabels,
|
|
1740
|
+
"text-anchor": "middle",
|
|
1741
|
+
transform: `translate(${l.x - e.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth + 5}, ${t.mutableConfig.isStacked ? e.drawingArea.bottom - l.yOffset - l.individualHeight / 2 : e.drawingArea.top + e.drawingArea.height / 2}) rotate(-90)`
|
|
1742
|
+
}, C(l.name) + " " + C(l.scaleLabel ? `- ${l.scaleLabel}` : ""), 9, Il),
|
|
1743
|
+
(r(!0), i(I, null, m(l.yLabels, (n, s) => (r(), i("line", {
|
|
1744
|
+
x1: l.x - 3,
|
|
1745
|
+
x2: l.x,
|
|
1746
|
+
y1: n.y,
|
|
1747
|
+
y2: n.y,
|
|
1748
|
+
stroke: l.color,
|
|
1749
|
+
"stroke-width": 1,
|
|
1750
|
+
"stroke-linecap": "round"
|
|
1751
|
+
}, null, 8, ml))), 256)),
|
|
1752
|
+
(r(!0), i(I, null, m(l.yLabels, (n, s) => (r(), i("text", {
|
|
1753
|
+
x: l.x - 5,
|
|
1754
|
+
y: n.y,
|
|
1755
|
+
"font-size": t.fontSizes.dataLabels,
|
|
1756
|
+
"text-anchor": "end",
|
|
1757
|
+
fill: l.color
|
|
1758
|
+
}, C(e.dataLabel({ p: e.FINAL_CONFIG.chart.labels.prefix, v: n.value, s: e.FINAL_CONFIG.chart.labels.suffix, r: 1 })), 9, Nl))), 256))
|
|
1759
|
+
], 4))), 256))
|
|
1760
|
+
], 64)) : (r(!0), i(I, { key: 1 }, m(e.yLabels, (l, n) => (r(), i("g", {
|
|
1761
|
+
key: `yLabel_${n}`
|
|
1762
|
+
}, [
|
|
1763
|
+
e.canShowValue(l) && l.value >= e.niceScale.min && l.value <= e.niceScale.max ? (r(), i("line", {
|
|
1764
|
+
key: 0,
|
|
1765
|
+
x1: e.drawingArea.left,
|
|
1766
|
+
x2: e.drawingArea.left - 5,
|
|
1767
|
+
y1: l.y,
|
|
1768
|
+
y2: l.y,
|
|
1769
|
+
stroke: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1770
|
+
"stroke-width": "1",
|
|
1771
|
+
"stroke-linecap": "round"
|
|
1772
|
+
}, null, 8, _l)) : c("", !0),
|
|
1773
|
+
l.value >= e.niceScale.min && l.value <= e.niceScale.max ? (r(), i("text", {
|
|
1774
|
+
key: 1,
|
|
1775
|
+
x: e.drawingArea.left - 7,
|
|
1776
|
+
y: l.y + t.fontSizes.dataLabels / 3,
|
|
1777
|
+
"font-size": t.fontSizes.dataLabels,
|
|
1778
|
+
"text-anchor": "end",
|
|
1779
|
+
fill: e.FINAL_CONFIG.chart.grid.labels.color
|
|
1780
|
+
}, C(e.canShowValue(l.value) ? e.dataLabel({ p: e.FINAL_CONFIG.chart.labels.prefix, v: l.value, s: e.FINAL_CONFIG.chart.labels.suffix, r: 1 }) : ""), 9, Fl)) : c("", !0)
|
|
1781
|
+
]))), 128))
|
|
1782
|
+
])) : c("", !0),
|
|
1783
|
+
t.mutableConfig.useIndividualScale && !t.mutableConfig.isStacked ? (r(!0), i(I, { key: 7 }, m(e.allScales, (l) => (r(), i("rect", {
|
|
1784
|
+
x: l.x - e.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth,
|
|
1785
|
+
y: e.drawingArea.top,
|
|
1786
|
+
width: e.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth,
|
|
1787
|
+
height: e.drawingArea.height < 0 ? 10 : e.drawingArea.height,
|
|
1788
|
+
fill: t.selectedScale === l.id ? `${l.color}20` : "transparent",
|
|
1789
|
+
onMouseenter: (n) => t.selectedScale = l.id,
|
|
1790
|
+
onMouseleave: o[0] || (o[0] = (n) => t.selectedScale = null)
|
|
1791
|
+
}, null, 40, xl))), 256)) : c("", !0),
|
|
1792
|
+
d("g", null, [
|
|
1793
|
+
e.FINAL_CONFIG.chart.grid.labels.axis.yLabel && !t.mutableConfig.useIndividualScale ? (r(), i("text", {
|
|
1794
|
+
key: 0,
|
|
1795
|
+
"font-size": t.fontSizes.yAxis,
|
|
1796
|
+
fill: e.FINAL_CONFIG.chart.grid.labels.color,
|
|
1797
|
+
transform: `translate(${t.fontSizes.yAxis + e.FINAL_CONFIG.chart.grid.labels.axis.yLabelOffsetX}, ${e.drawingArea.top + e.drawingArea.height / 2}) rotate(-90)`,
|
|
1798
|
+
"text-anchor": "middle",
|
|
1799
|
+
style: { transition: "none" }
|
|
1800
|
+
}, C(e.FINAL_CONFIG.chart.grid.labels.axis.yLabel), 9, yl)) : c("", !0),
|
|
1801
|
+
e.FINAL_CONFIG.chart.grid.labels.axis.xLabel ? (r(), i("text", {
|
|
1802
|
+
key: 1,
|
|
1803
|
+
"text-anchor": "middle",
|
|
1804
|
+
x: t.width / 2,
|
|
1805
|
+
y: e.drawingArea.bottom + t.fontSizes.yAxis + t.fontSizes.xAxis * 1.3 + e.FINAL_CONFIG.chart.grid.labels.axis.xLabelOffsetY,
|
|
1806
|
+
"font-size": t.fontSizes.yAxis,
|
|
1807
|
+
fill: e.FINAL_CONFIG.chart.grid.labels.color
|
|
1808
|
+
}, C(e.FINAL_CONFIG.chart.grid.labels.axis.xLabel), 9, Al)) : c("", !0)
|
|
1809
|
+
]),
|
|
1810
|
+
e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.show ? (r(), i("g", Sl, [
|
|
1811
|
+
(r(!0), i(I, null, m(e.timeLabels, (l, n) => (r(), i("g", {
|
|
1812
|
+
key: `time_label_${n}`
|
|
1813
|
+
}, [
|
|
1814
|
+
l && !e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast && !e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo || l && e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast && (n === 0 || n === e.timeLabels.length - 1) && !e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo || l && e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast && t.selectedSerieIndex === n && !e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo || l && !e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast && e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo && n % Math.floor((this.slicer.end - this.slicer.start) / e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.modulo) === 0 ? (r(), i("text", {
|
|
1815
|
+
key: 0,
|
|
1816
|
+
"text-anchor": e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation > 0 ? "start" : e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation < 0 ? "end" : "middle",
|
|
1817
|
+
"font-size": t.fontSizes.xAxis,
|
|
1818
|
+
fill: e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.color,
|
|
1819
|
+
transform: `translate(${e.drawingArea.left + e.drawingArea.width / e.maxSeries * n + e.drawingArea.width / e.maxSeries / 2}, ${e.drawingArea.bottom + t.fontSizes.xAxis * 1.3 + e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.yOffset}), rotate(${e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation})`
|
|
1820
|
+
}, C(l || ""), 9, Ll)) : c("", !0)
|
|
1821
|
+
]))), 128))
|
|
1822
|
+
])) : c("", !0),
|
|
1823
|
+
d("g", null, [
|
|
1824
|
+
(r(!0), i(I, null, m(e.maxSeries, (l, n) => (r(), i("g", {
|
|
1825
|
+
key: `tooltip_trap_${n}`
|
|
1826
|
+
}, [
|
|
1827
|
+
d("rect", {
|
|
1828
|
+
"data-cy-trap": "",
|
|
1829
|
+
x: e.drawingArea.left + e.drawingArea.width / e.maxSeries * n,
|
|
1830
|
+
y: e.drawingArea.top,
|
|
1831
|
+
height: e.drawingArea.height < 0 ? 10 : e.drawingArea.height,
|
|
1832
|
+
width: e.drawingArea.width / e.maxSeries < 0 ? 1e-5 : e.drawingArea.width / e.maxSeries,
|
|
1833
|
+
fill: t.selectedSerieIndex === n || t.selectedRowIndex === n ? `${e.FINAL_CONFIG.chart.highlighter.color}${t.opacity[e.FINAL_CONFIG.chart.highlighter.opacity]}` : "transparent",
|
|
1834
|
+
onMouseenter: (s) => e.toggleTooltipVisibility(!0, n),
|
|
1835
|
+
onMouseleave: o[1] || (o[1] = (s) => e.toggleTooltipVisibility(!1)),
|
|
1836
|
+
onClick: (s) => e.selectX(n)
|
|
1837
|
+
}, null, 40, Cl)
|
|
1838
|
+
]))), 128))
|
|
1839
|
+
]),
|
|
1840
|
+
e.FINAL_CONFIG.chart.highlighter.useLine && ![null, void 0].includes(t.selectedSerieIndex) ? (r(), i("g", kl, [
|
|
1841
|
+
d("line", {
|
|
1842
|
+
x1: e.drawingArea.left + e.drawingArea.width / e.maxSeries * t.selectedSerieIndex + e.drawingArea.width / e.maxSeries / 2,
|
|
1843
|
+
x2: e.drawingArea.left + e.drawingArea.width / e.maxSeries * t.selectedSerieIndex + e.drawingArea.width / e.maxSeries / 2,
|
|
1844
|
+
y1: e.drawingArea.top,
|
|
1845
|
+
y2: e.drawingArea.bottom,
|
|
1846
|
+
stroke: e.FINAL_CONFIG.chart.highlighter.color,
|
|
1847
|
+
"stroke-width": e.FINAL_CONFIG.chart.highlighter.lineWidth,
|
|
1848
|
+
"stroke-dasharray": e.FINAL_CONFIG.chart.highlighter.lineDasharray,
|
|
1849
|
+
"stroke-linecap": "round",
|
|
1850
|
+
style: { transition: "none !important", animation: "none !important", "pointer-events": "none" }
|
|
1851
|
+
}, null, 8, wl)
|
|
1852
|
+
])) : c("", !0),
|
|
1853
|
+
e.FINAL_CONFIG.chart.timeTag.show && ![null, void 0].includes(t.selectedSerieIndex) ? (r(), i("g", Ol, [
|
|
1854
|
+
(r(), i("foreignObject", {
|
|
1855
|
+
x: e.drawingArea.left + e.drawingArea.width / e.maxSeries * t.selectedSerieIndex - 100 + e.drawingArea.width / e.maxSeries / 2,
|
|
1856
|
+
y: e.drawingArea.bottom,
|
|
1857
|
+
width: "200",
|
|
1858
|
+
height: "40",
|
|
1859
|
+
style: { overflow: "visible !important" }
|
|
1860
|
+
}, [
|
|
1861
|
+
d("div", {
|
|
1862
|
+
class: "vue-ui-xy-time-tag",
|
|
1863
|
+
style: S(`width: fit-content;margin: 0 auto;text-align:center;padding:3px 12px;background:${e.FINAL_CONFIG.chart.timeTag.backgroundColor};color:${e.FINAL_CONFIG.chart.timeTag.color};font-size:${e.FINAL_CONFIG.chart.timeTag.fontSize}px`)
|
|
1864
|
+
}, C(e.timeLabels[t.selectedSerieIndex] || t.selectedSerieIndex), 5)
|
|
1865
|
+
], 8, vl)),
|
|
1866
|
+
d("circle", {
|
|
1867
|
+
cx: e.drawingArea.left + e.drawingArea.width / e.maxSeries * t.selectedSerieIndex + e.drawingArea.width / e.maxSeries / 2,
|
|
1868
|
+
cy: e.drawingArea.bottom,
|
|
1869
|
+
r: e.FINAL_CONFIG.chart.timeTag.circleMarker.radius,
|
|
1870
|
+
fill: e.FINAL_CONFIG.chart.timeTag.circleMarker.color
|
|
1871
|
+
}, null, 8, Gl)
|
|
1872
|
+
])) : c("", !0)
|
|
1873
|
+
])) : c("", !0),
|
|
1874
|
+
G(a.$slots, "svg", { svg: e.svg }, void 0, !0)
|
|
1875
|
+
], 14, Ye)) : c("", !0),
|
|
1876
|
+
e.isDataset ? c("", !0) : (r(), V(F, {
|
|
1877
|
+
key: 3,
|
|
1878
|
+
config: {
|
|
1879
|
+
type: "line",
|
|
1880
|
+
style: {
|
|
1881
|
+
backgroundColor: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1882
|
+
line: {
|
|
1883
|
+
axis: {
|
|
1884
|
+
color: e.FINAL_CONFIG.chart.grid.stroke
|
|
1885
|
+
},
|
|
1886
|
+
path: {
|
|
1887
|
+
color: e.FINAL_CONFIG.chart.grid.stroke,
|
|
1888
|
+
strokeWidth: 0.5
|
|
1889
|
+
}
|
|
1890
|
+
}
|
|
1891
|
+
}
|
|
1892
|
+
}
|
|
1893
|
+
}, null, 8, ["config"])),
|
|
1894
|
+
e.FINAL_CONFIG.chart.zoom.show && t.maxX > 6 && e.isDataset ? (r(), V(p, {
|
|
1895
|
+
ref: "chartSlicer",
|
|
1896
|
+
key: `slicer_${t.slicerStep}`,
|
|
1897
|
+
background: e.FINAL_CONFIG.chart.zoom.color,
|
|
1898
|
+
fontSize: e.FINAL_CONFIG.chart.zoom.fontSize,
|
|
1899
|
+
useResetSlot: e.FINAL_CONFIG.chart.zoom.useResetSlot,
|
|
1900
|
+
labelLeft: e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[t.slicer.start],
|
|
1901
|
+
labelRight: e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[t.slicer.end - 1],
|
|
1902
|
+
textColor: e.FINAL_CONFIG.chart.color,
|
|
1903
|
+
inputColor: e.FINAL_CONFIG.chart.zoom.color,
|
|
1904
|
+
selectColor: e.FINAL_CONFIG.chart.zoom.highlightColor,
|
|
1905
|
+
borderColor: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1906
|
+
max: t.maxX,
|
|
1907
|
+
min: 0,
|
|
1908
|
+
valueStart: t.slicer.start,
|
|
1909
|
+
valueEnd: t.slicer.end,
|
|
1910
|
+
start: t.slicer.start,
|
|
1911
|
+
"onUpdate:start": o[2] || (o[2] = (l) => t.slicer.start = l),
|
|
1912
|
+
end: t.slicer.end,
|
|
1913
|
+
"onUpdate:end": o[3] || (o[3] = (l) => t.slicer.end = l),
|
|
1914
|
+
onReset: e.refreshSlicer
|
|
1915
|
+
}, {
|
|
1916
|
+
"reset-action": z(({ reset: l }) => [
|
|
1917
|
+
G(a.$slots, "reset-action", Y(E({ reset: l })), void 0, !0)
|
|
1918
|
+
]),
|
|
1919
|
+
_: 3
|
|
1920
|
+
}, 8, ["background", "fontSize", "useResetSlot", "labelLeft", "labelRight", "textColor", "inputColor", "selectColor", "borderColor", "max", "valueStart", "valueEnd", "start", "end", "onReset"])) : c("", !0),
|
|
1921
|
+
e.FINAL_CONFIG.chart.legend.show ? (r(), i("div", {
|
|
1922
|
+
key: 5,
|
|
1923
|
+
ref: "chartLegend",
|
|
1924
|
+
class: "vue-ui-xy-legend",
|
|
1925
|
+
style: S(`font-size:${e.FINAL_CONFIG.chart.legend.fontSize}px`)
|
|
1926
|
+
}, [
|
|
1927
|
+
(r(!0), i(I, null, m(e.absoluteDataset, (l, n) => (r(), i("div", {
|
|
1928
|
+
key: `div_legend_item_${n}`,
|
|
1929
|
+
onClick: (s) => e.segregate(l),
|
|
1930
|
+
class: T({ "vue-ui-xy-legend-item": !0, "vue-ui-xy-legend-item-segregated": t.segregatedSeries.includes(l.id) })
|
|
1931
|
+
}, [
|
|
1932
|
+
t.icons[l.type] === "line" ? (r(), i("svg", pl, [
|
|
1933
|
+
d("rect", {
|
|
1934
|
+
x: "0",
|
|
1935
|
+
y: "7",
|
|
1936
|
+
rx: "3",
|
|
1937
|
+
stroke: "none",
|
|
1938
|
+
height: "4",
|
|
1939
|
+
width: "20",
|
|
1940
|
+
fill: l.color
|
|
1941
|
+
}, null, 8, Tl),
|
|
1942
|
+
W(f, {
|
|
1943
|
+
plot: { x: 10, y: 9 },
|
|
1944
|
+
radius: 4,
|
|
1945
|
+
color: l.color,
|
|
1946
|
+
shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(l.shape) ? l.shape : "circle",
|
|
1947
|
+
stroke: e.FINAL_CONFIG.chart.backgroundColor,
|
|
1948
|
+
strokeWidth: 1
|
|
1949
|
+
}, null, 8, ["color", "shape", "stroke"])
|
|
1950
|
+
])) : (r(), i("svg", Ml, [
|
|
1951
|
+
t.icons[l.type] === "bar" ? (r(), i("rect", {
|
|
1952
|
+
key: 0,
|
|
1953
|
+
x: "0",
|
|
1954
|
+
y: "0",
|
|
1955
|
+
rx: "1",
|
|
1956
|
+
height: "12",
|
|
1957
|
+
width: "12",
|
|
1958
|
+
stroke: "none",
|
|
1959
|
+
fill: l.color
|
|
1960
|
+
}, null, 8, Pl)) : (r(), V(f, {
|
|
1961
|
+
key: 1,
|
|
1962
|
+
plot: { x: 6, y: 6 },
|
|
1963
|
+
radius: 5,
|
|
1964
|
+
color: l.color,
|
|
1965
|
+
shape: ["triangle", "square", "diamond", "pentagon", "hexagon", "star"].includes(l.shape) ? l.shape : "circle"
|
|
1966
|
+
}, null, 8, ["color", "shape"]))
|
|
1967
|
+
])),
|
|
1968
|
+
d("span", {
|
|
1969
|
+
style: S(`color:${e.FINAL_CONFIG.chart.legend.color}`)
|
|
1970
|
+
}, C(l.name), 5)
|
|
1971
|
+
], 10, zl))), 128))
|
|
1972
|
+
], 4)) : (r(), i("div", Vl, [
|
|
1973
|
+
G(a.$slots, "legend", { legend: e.absoluteDataset }, void 0, !0)
|
|
1974
|
+
], 512)),
|
|
1975
|
+
W(k, {
|
|
1976
|
+
show: t.mutableConfig.showTooltip && t.isTooltip,
|
|
1977
|
+
backgroundColor: e.FINAL_CONFIG.chart.tooltip.backgroundColor,
|
|
1978
|
+
color: e.FINAL_CONFIG.chart.tooltip.color,
|
|
1979
|
+
fontSize: e.FINAL_CONFIG.chart.tooltip.fontSize,
|
|
1980
|
+
borderRadius: e.FINAL_CONFIG.chart.tooltip.borderRadius,
|
|
1981
|
+
borderColor: e.FINAL_CONFIG.chart.tooltip.borderColor,
|
|
1982
|
+
borderWidth: e.FINAL_CONFIG.chart.tooltip.borderWidth,
|
|
1983
|
+
backgroundOpacity: e.FINAL_CONFIG.chart.tooltip.backgroundOpacity,
|
|
1984
|
+
parent: a.$refs.chart,
|
|
1985
|
+
content: e.tooltipContent,
|
|
1986
|
+
isCustom: e.FINAL_CONFIG.chart.tooltip.customFormat && typeof e.FINAL_CONFIG.chart.tooltip.customFormat == "function"
|
|
1987
|
+
}, {
|
|
1988
|
+
"tooltip-before": z(() => [
|
|
1989
|
+
G(a.$slots, "tooltip-before", Y(E({ ...e.dataTooltipSlot })), void 0, !0)
|
|
1990
|
+
]),
|
|
1991
|
+
"tooltip-after": z(() => [
|
|
1992
|
+
G(a.$slots, "tooltip-after", Y(E({ ...e.dataTooltipSlot })), void 0, !0)
|
|
1993
|
+
]),
|
|
1994
|
+
_: 3
|
|
1995
|
+
}, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "parent", "content", "isCustom"]),
|
|
1996
|
+
e.isDataset ? (r(), V(L, {
|
|
1997
|
+
key: 7,
|
|
1998
|
+
hideDetails: "",
|
|
1999
|
+
config: {
|
|
2000
|
+
open: t.mutableConfig.showTable,
|
|
2001
|
+
maxHeight: 1e4,
|
|
2002
|
+
body: {
|
|
2003
|
+
backgroundColor: e.FINAL_CONFIG.chart.backgroundColor,
|
|
2004
|
+
color: e.FINAL_CONFIG.chart.color
|
|
2005
|
+
},
|
|
2006
|
+
head: {
|
|
2007
|
+
backgroundColor: e.FINAL_CONFIG.chart.backgroundColor,
|
|
2008
|
+
color: e.FINAL_CONFIG.chart.color
|
|
2009
|
+
}
|
|
2010
|
+
}
|
|
2011
|
+
}, {
|
|
2012
|
+
content: z(() => [
|
|
2013
|
+
d("div", {
|
|
2014
|
+
style: S(`${t.isPrinting ? "" : "max-height:400px"};overflow:auto;width:100%;margin-top:48px`)
|
|
2015
|
+
}, [
|
|
2016
|
+
d("div", Rl, [
|
|
2017
|
+
Pe(d("input", {
|
|
2018
|
+
type: "checkbox",
|
|
2019
|
+
"onUpdate:modelValue": o[4] || (o[4] = (l) => t.showSparklineTable = l)
|
|
2020
|
+
}, null, 512), [
|
|
2021
|
+
[Ve, t.showSparklineTable]
|
|
2022
|
+
]),
|
|
2023
|
+
d("div", {
|
|
2024
|
+
onClick: o[5] || (o[5] = (l) => t.showSparklineTable = !t.showSparklineTable),
|
|
2025
|
+
style: { cursor: "pointer" }
|
|
2026
|
+
}, [
|
|
2027
|
+
W(w, {
|
|
2028
|
+
name: "chartLine",
|
|
2029
|
+
size: 20,
|
|
2030
|
+
stroke: e.FINAL_CONFIG.chart.color
|
|
2031
|
+
}, null, 8, ["stroke"])
|
|
2032
|
+
])
|
|
2033
|
+
]),
|
|
2034
|
+
t.showSparklineTable ? (r(), V(v, {
|
|
2035
|
+
key: `sparkline_${t.segregateStep}`,
|
|
2036
|
+
dataset: e.tableSparklineDataset,
|
|
2037
|
+
config: e.tableSparklineConfig
|
|
2038
|
+
}, null, 8, ["dataset", "config"])) : (r(), V(_, {
|
|
2039
|
+
key: 1,
|
|
2040
|
+
colNames: e.dataTable.colNames,
|
|
2041
|
+
head: e.dataTable.head,
|
|
2042
|
+
body: e.dataTable.body,
|
|
2043
|
+
config: e.dataTable.config,
|
|
2044
|
+
title: `${e.FINAL_CONFIG.chart.title.text}${e.FINAL_CONFIG.chart.title.subtitle.text ? ` : ${e.FINAL_CONFIG.chart.title.subtitle.text}` : ""}`,
|
|
2045
|
+
onClose: o[6] || (o[6] = (l) => t.mutableConfig.showTable = !1)
|
|
2046
|
+
}, {
|
|
2047
|
+
th: z(({ th: l }) => [
|
|
2048
|
+
d("div", { innerHTML: l }, null, 8, Dl)
|
|
2049
|
+
]),
|
|
2050
|
+
td: z(({ td: l }) => [
|
|
2051
|
+
Re(C(l), 1)
|
|
2052
|
+
]),
|
|
2053
|
+
_: 1
|
|
2054
|
+
}, 8, ["colNames", "head", "body", "config", "title"]))
|
|
2055
|
+
], 4)
|
|
2056
|
+
]),
|
|
2057
|
+
_: 1
|
|
2058
|
+
}, 8, ["config"])) : c("", !0)
|
|
2059
|
+
], 14, We);
|
|
2060
|
+
}
|
|
2061
|
+
const la = /* @__PURE__ */ De(Be, [["render", Hl], ["__scopeId", "data-v-185b12a6"]]);
|
|
2062
|
+
export {
|
|
2063
|
+
la as default
|
|
2064
|
+
};
|