vue-data-ui 3.0.0-next.6 → 3.0.0-next.60
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-Ul64M9UV.js → Arrow-Dt0ZxTK2.js} +1 -1
- package/dist/{BaseDraggableDialog-Q2ajCztp.js → BaseDraggableDialog-Bl-2tw3H.js} +2 -2
- package/dist/{BaseIcon-BKR7AGeP.js → BaseIcon-C3ljqn8J.js} +1 -1
- package/dist/{ColorPicker-BagIs8-K.js → ColorPicker-0d0whOB3.js} +2 -2
- package/dist/{DataTable-CDwApkI_.js → DataTable-C_tJHvMd.js} +2 -2
- package/dist/{Legend-BSLj7tYc.js → Legend-VD0VB7l7.js} +2 -2
- package/dist/{NonSvgPenAndPaper-DjJe5fXu.js → NonSvgPenAndPaper-DQsHc_AG.js} +3 -3
- package/dist/{PackageVersion-BsKpz6KS.js → PackageVersion-5S8ajCUS.js} +1 -1
- package/dist/{PenAndPaper-BYRk8xrS.js → PenAndPaper-D6wazxlT.js} +3 -3
- package/dist/{Shape-DK7zYTKa.js → Shape-DDSX29LV.js} +43 -37
- package/dist/Slicer-D3SbIarX.js +602 -0
- package/dist/{SparkTooltip-Dy2sVTb_.js → SparkTooltip-BCdP3VDl.js} +1 -1
- package/dist/{Title-Cednydse.js → Title-DEKAfzRX.js} +1 -1
- package/dist/{Tooltip-DJlwW-XP.js → Tooltip-DJlC-n25.js} +23 -19
- package/dist/{UserOptions-DxIzWere.js → UserOptions-D2G7II3G.js} +2 -2
- package/dist/{dom-to-png-lZcM-YfK.js → dom-to-png-Y0tASTWQ.js} +1 -1
- package/dist/{img-DqlIAUF6.js → img-ChLGv8nO.js} +1 -1
- package/dist/{index-BQcLOx39.js → index-BLtc1AIS.js} +1707 -1131
- package/dist/{pdf-CjIXhsyg.js → pdf-DNiq-xsc.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +481 -21
- package/dist/types/vue-data-ui.d.ts +481 -21
- package/dist/useAutoSizeLabelsInsideViewbox-BJDcwsoB.js +41 -0
- package/dist/useNestedProp-DExlTpuj.js +13 -0
- package/dist/usePanZoom-BVca3eMk.js +122 -0
- package/dist/{usePrinter-BRY5saEA.js → usePrinter-fqbzwh0l.js} +2 -2
- package/dist/useTimeLabelCollider-CIsgDrl9.js +78 -0
- package/dist/{useTimeLabels-Mrr0jrpL.js → useTimeLabels-DkzmKfZn.js} +211 -152
- package/dist/{vue-data-ui-CWRlSsiN.js → vue-data-ui-B8bRwUEL.js} +105 -100
- package/dist/vue-data-ui.js +23 -22
- package/dist/vue-ui-3d-bar-Dddx5kJW.js +1323 -0
- package/dist/{vue-ui-accordion-Df-5BRRg.js → vue-ui-accordion-EMAj3Ykx.js} +3 -3
- package/dist/vue-ui-age-pyramid-CMzKOGfv.js +834 -0
- package/dist/{vue-ui-annotator-BxC5dcIv.js → vue-ui-annotator-BQxXVdZW.js} +2 -2
- package/dist/vue-ui-bullet-DIie_6-T.js +571 -0
- package/dist/vue-ui-candlestick-DU796IGE.js +999 -0
- package/dist/{vue-ui-carousel-table-NTDzafWQ.js → vue-ui-carousel-table-xDItqzuw.js} +29 -29
- package/dist/{vue-ui-chestnut-k21Qqjjq.js → vue-ui-chestnut-DnQ494SU.js} +5 -5
- package/dist/{vue-ui-chord-BVoA6nfI.js → vue-ui-chord-DTs9gQ-R.js} +8 -8
- package/dist/{vue-ui-circle-pack-CEBgImRX.js → vue-ui-circle-pack-D73gxFJW.js} +24 -24
- package/dist/{vue-ui-cursor-BQcz8xw2.js → vue-ui-cursor-CNXTFeSs.js} +2 -2
- package/dist/{vue-ui-dashboard-CyzEpJoI.js → vue-ui-dashboard-Duph5Yta.js} +62 -62
- package/dist/{vue-ui-digits-Dafw1UsT.js → vue-ui-digits-D7qOSGZ-.js} +2 -2
- package/dist/{vue-ui-donut-DKfux8XT.js → vue-ui-donut-EfxITdHJ.js} +320 -308
- package/dist/vue-ui-donut-evolution-H6nfW_kx.js +1075 -0
- package/dist/vue-ui-dumbbell-DCUR8kl_.js +1119 -0
- package/dist/vue-ui-flow-DUENWmgc.js +841 -0
- package/dist/{vue-ui-funnel-CuN8HWwP.js → vue-ui-funnel-BSGUxWhW.js} +16 -16
- package/dist/{vue-ui-galaxy-BHCLFlmy.js → vue-ui-galaxy-D8PBQfbb.js} +60 -58
- package/dist/vue-ui-gauge-C8v8wKJO.js +791 -0
- package/dist/{vue-ui-gizmo-DHEEfdp9.js → vue-ui-gizmo-DmguslRh.js} +3 -3
- package/dist/vue-ui-heatmap-BM5Gfdzz.js +1078 -0
- package/dist/vue-ui-history-plot-CF6SlpwK.js +1073 -0
- package/dist/{vue-ui-kpi-C4i2w_Yd.js → vue-ui-kpi-BCyX-Zu-.js} +7 -7
- package/dist/{vue-ui-mini-loader-BeetGv_m.js → vue-ui-mini-loader-ByMff4PK.js} +2 -2
- package/dist/{vue-ui-molecule-F_gDXjJr.js → vue-ui-molecule-Cxnf2xDy.js} +53 -51
- package/dist/{vue-ui-mood-radar-BJMOEqlu.js → vue-ui-mood-radar-DEfJWXE7.js} +15 -15
- package/dist/vue-ui-nested-donuts-Bt7Pw9l0.js +1286 -0
- package/dist/vue-ui-onion-Bk3KL1Nk.js +776 -0
- package/dist/vue-ui-parallel-coordinate-plot-BpKRlOYy.js +915 -0
- package/dist/{vue-ui-quadrant-DTyRC1_v.js → vue-ui-quadrant-D1dgOAp2.js} +59 -57
- package/dist/vue-ui-quick-chart-_I6OrH-J.js +1761 -0
- package/dist/{vue-ui-radar-De2iznwo.js → vue-ui-radar-BWnhxayf.js} +30 -28
- package/dist/{vue-ui-rating-CarXXyD-.js → vue-ui-rating-I08lL1Nb.js} +2 -2
- package/dist/{vue-ui-relation-circle-CKkK9D4E.js → vue-ui-relation-circle-CMF5FSha.js} +6 -6
- package/dist/vue-ui-ridgeline-prYrXNYF.js +1153 -0
- package/dist/vue-ui-rings-DmbUIw9S.js +728 -0
- package/dist/vue-ui-scatter-srTVLcUK.js +1178 -0
- package/dist/{vue-ui-skeleton-C7maR60-.js → vue-ui-skeleton-FanSnKr8.js} +3 -3
- package/dist/{vue-ui-smiley-DzCCn5Oc.js → vue-ui-smiley-CWA0Y6wM.js} +26 -26
- package/dist/{vue-ui-spark-trend-Db-Fnp8C.js → vue-ui-spark-trend-EiEzMoPj.js} +3 -3
- package/dist/vue-ui-sparkbar-CCe0U_o0.js +351 -0
- package/dist/{vue-ui-sparkgauge-DAQ4zozy.js → vue-ui-sparkgauge-Cdcirik_.js} +3 -3
- package/dist/{vue-ui-sparkhistogram-CMEaO0CW.js → vue-ui-sparkhistogram-CEj9qz9m.js} +4 -4
- package/dist/vue-ui-sparkline-B2-YztKx.js +489 -0
- package/dist/vue-ui-sparkstackbar-BGMtc_HC.js +421 -0
- package/dist/vue-ui-stackbar-DrKaioRS.js +1370 -0
- package/dist/vue-ui-strip-plot-C4qWoDEh.js +915 -0
- package/dist/{vue-ui-table-Dck8Pyg9.js → vue-ui-table-CXqyTj_Z.js} +11 -11
- package/dist/{vue-ui-table-heatmap-DknIGf9_.js → vue-ui-table-heatmap-BZTn3qnM.js} +5 -5
- package/dist/{vue-ui-table-sparkline-G4HAzUt6.js → vue-ui-table-sparkline-CIBdN_KF.js} +14 -14
- package/dist/vue-ui-thermometer-DPIpWKUI.js +541 -0
- package/dist/{vue-ui-timer-Dmr-HCSc.js → vue-ui-timer-Cha-Gb1x.js} +5 -5
- package/dist/vue-ui-tiremarks-B4SjQyS7.js +406 -0
- package/dist/vue-ui-treemap-1twI_ag-.js +1035 -0
- package/dist/{vue-ui-vertical-bar--QFtoFje.js → vue-ui-vertical-bar-C31Jqkbw.js} +318 -302
- package/dist/vue-ui-waffle-DkZykFPK.js +910 -0
- package/dist/vue-ui-wheel-CYOrBHBD.js +379 -0
- package/dist/vue-ui-word-cloud-Clyg0CRZ.js +765 -0
- package/dist/{vue-ui-world-BcK_brDq.js → vue-ui-world-BYgMbS-e.js} +11 -9
- package/dist/vue-ui-xy-BMszd4wZ.js +3760 -0
- package/dist/{vue-ui-xy-canvas--88oKdGN.js → vue-ui-xy-canvas-DwXvZ311.js} +265 -264
- package/package.json +1 -1
- package/dist/Slicer-B_Hb6qSk.js +0 -577
- package/dist/useNestedProp-DefBVltl.js +0 -13
- package/dist/usePanZoom-BQMvRXEQ.js +0 -115
- package/dist/vue-ui-3d-bar-CJMZqDo1.js +0 -1227
- package/dist/vue-ui-age-pyramid-B6WAMtPk.js +0 -746
- package/dist/vue-ui-bullet-NmtltFbU.js +0 -513
- package/dist/vue-ui-candlestick-BzqQtynP.js +0 -873
- package/dist/vue-ui-donut-evolution-D7cNk_6l.js +0 -903
- package/dist/vue-ui-dumbbell--H80zebk.js +0 -753
- package/dist/vue-ui-flow-lk_HU5NB.js +0 -765
- package/dist/vue-ui-gauge-DWlCh2_B.js +0 -738
- package/dist/vue-ui-heatmap-BK6BNOY_.js +0 -877
- package/dist/vue-ui-history-plot-CGF6lE-7.js +0 -924
- package/dist/vue-ui-nested-donuts-BX0Z0rb1.js +0 -1177
- package/dist/vue-ui-onion-BhjUET_W.js +0 -701
- package/dist/vue-ui-parallel-coordinate-plot-n7QPVLrW.js +0 -807
- package/dist/vue-ui-quick-chart-5xX-yBIY.js +0 -1612
- package/dist/vue-ui-ridgeline-DQ8RQf3E.js +0 -969
- package/dist/vue-ui-rings-Cze6OsmO.js +0 -685
- package/dist/vue-ui-scatter-CwI3_Dn7.js +0 -1045
- package/dist/vue-ui-sparkbar-C6wsNMMO.js +0 -301
- package/dist/vue-ui-sparkline-R7pfxRWN.js +0 -459
- package/dist/vue-ui-sparkstackbar-DV_XqJQ2.js +0 -381
- package/dist/vue-ui-stackbar-gReSujA_.js +0 -1207
- package/dist/vue-ui-strip-plot-8fsm3nn2.js +0 -761
- package/dist/vue-ui-thermometer-BIkXa4hY.js +0 -495
- package/dist/vue-ui-tiremarks-YWbRk0dm.js +0 -358
- package/dist/vue-ui-treemap-D2OnG3Fh.js +0 -965
- package/dist/vue-ui-waffle-BdaCXuWc.js +0 -863
- package/dist/vue-ui-wheel-Bw3XSa8N.js +0 -352
- package/dist/vue-ui-word-cloud-BH8UZH_J.js +0 -659
- package/dist/vue-ui-xy-Be--zwe9.js +0 -2980
|
@@ -0,0 +1,1119 @@
|
|
|
1
|
+
import { defineAsyncComponent as U, computed as g, ref as h, toRefs as $t, watch as ge, shallowRef as je, onMounted as Ye, onBeforeUnmount as Ze, watchEffect as Lt, createElementBlock as c, openBlock as n, unref as i, normalizeStyle as ee, normalizeClass as Je, createBlock as F, createCommentVNode as f, createElementVNode as v, createSlots as At, withCtx as x, renderSlot as p, normalizeProps as te, guardReactiveProps as le, createVNode as Nt, withDirectives as W, Fragment as C, renderList as A, toDisplayString as _, vShow as q, createTextVNode as Ke, nextTick as St } from "vue";
|
|
2
|
+
import { u as Mt, c as Qe, t as Xt, b as zt, o as Tt, f as et, g as It, h as tt, D as Ot, i as w, k as H, X as lt, s as at, l as j, j as Y, v as Ft, w as Ht } from "./index-BLtc1AIS.js";
|
|
3
|
+
import { t as me, u as Pt } from "./useResponsive-DfdjqQps.js";
|
|
4
|
+
import { u as Dt } from "./usePrinter-fqbzwh0l.js";
|
|
5
|
+
import { u as Gt, B as Et } from "./useLoading-Bt5Doa8m.js";
|
|
6
|
+
import { u as st } from "./useNestedProp-DExlTpuj.js";
|
|
7
|
+
import { u as Rt } from "./useUserOptionState-BIvW1Kz7.js";
|
|
8
|
+
import { u as Bt } from "./useChartAccessibility-9icAAmYg.js";
|
|
9
|
+
import { u as Vt } from "./useTimeLabelCollider-CIsgDrl9.js";
|
|
10
|
+
import Ut from "./img-ChLGv8nO.js";
|
|
11
|
+
import Wt from "./Title-DEKAfzRX.js";
|
|
12
|
+
import qt from "./Legend-VD0VB7l7.js";
|
|
13
|
+
import { _ as jt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
14
|
+
const Yt = ["id"], Zt = ["xmlns", "viewBox"], Jt = ["x", "y", "width", "height"], Kt = { key: 1 }, Qt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], el = { key: 2 }, tl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], ll = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], al = ["transform", "font-size", "fill"], sl = ["x", "y", "font-size", "fill", "font-weight", "onMouseenter", "onMouseleave", "onClick"], ol = ["x", "y", "font-size", "fill", "onMouseenter", "onMouseleave", "onClick"], nl = ["x", "y", "font-size", "fill"], rl = ["transform", "font-size", "fill", "font-weight", "text-anchor"], ul = ["d", "stroke", "stroke-width", "stroke-dasharray"], il = ["d", "stroke", "stroke-width", "stroke-dasharray"], cl = ["x", "y", "height", "width", "fill"], vl = ["transform", "fill", "font-size"], dl = ["id"], hl = ["stop-color"], yl = ["stop-color"], fl = ["stop-color"], bl = ["id"], gl = ["stop-color"], ml = ["stop-color"], pl = ["stop-color"], xl = ["id"], _l = ["stop-color"], kl = ["stop-color"], Cl = ["stop-color"], wl = ["id"], $l = ["stop-color"], Ll = ["stop-color"], Al = ["stop-color"], Nl = ["id"], Sl = ["stop-color"], Ml = ["stop-color"], Xl = ["stop-color"], zl = ["id"], Tl = ["stop-color"], Il = ["stop-color"], Ol = ["id"], Fl = ["stop-color"], Hl = ["stop-color"], Pl = { key: 0 }, Dl = { key: 0 }, Gl = ["d", "fill"], El = { key: 1 }, Rl = ["x", "y", "height", "width", "fill"], Bl = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], Vl = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], Ul = { key: 7 }, Wl = ["x", "y", "fill", "font-size"], ql = { key: 8 }, jl = ["x", "y", "fill", "font-size"], Yl = ["x", "y", "width", "height", "fill", "onMouseenter", "onMouseleave", "onClick"], Zl = {
|
|
15
|
+
key: 4,
|
|
16
|
+
class: "vue-data-ui-watermark"
|
|
17
|
+
}, Jl = ["xmlns", "height", "width"], Kl = ["fill"], Ql = ["innerHTML"], ea = {
|
|
18
|
+
__name: "vue-ui-dumbbell",
|
|
19
|
+
props: {
|
|
20
|
+
config: {
|
|
21
|
+
type: Object,
|
|
22
|
+
default() {
|
|
23
|
+
return {};
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
dataset: {
|
|
27
|
+
type: Array,
|
|
28
|
+
default() {
|
|
29
|
+
return [];
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
emits: ["selectDatapoint"],
|
|
34
|
+
setup(ot, { expose: nt, emit: ta }) {
|
|
35
|
+
const rt = U(() => import("./vue-ui-accordion-EMAj3Ykx.js")), ut = U(() => import("./DataTable-C_tJHvMd.js")), it = U(() => import("./PenAndPaper-D6wazxlT.js")), ct = U(() => import("./UserOptions-D2G7II3G.js")), vt = U(() => import("./PackageVersion-5S8ajCUS.js")), { vue_ui_dumbbell: dt } = Mt(), N = ot, Z = g({
|
|
36
|
+
get() {
|
|
37
|
+
return !!N.dataset && N.dataset.length;
|
|
38
|
+
},
|
|
39
|
+
set(l) {
|
|
40
|
+
return l;
|
|
41
|
+
}
|
|
42
|
+
}), b = h(Qe()), pe = h(0), T = h(null), xe = h(null), _e = h(null), ke = h(null), Ce = h(null), we = h(0), $e = h(0), Le = h(0), ae = h(null), se = h(null), J = h(null), oe = h(null), I = h(null), r = h(null), O = h(!1), e = h(ie()), { loading: ne, FINAL_DATASET: re, manualLoading: ht } = Gt({
|
|
43
|
+
...$t(N),
|
|
44
|
+
FINAL_CONFIG: e,
|
|
45
|
+
prepareConfig: ie,
|
|
46
|
+
skeletonDataset: [
|
|
47
|
+
{ name: "_", start: 21, end: 34 },
|
|
48
|
+
{ name: "_", start: 13, end: 21 },
|
|
49
|
+
{ name: "_", start: 8, end: 13 },
|
|
50
|
+
{ name: "_", start: 5, end: 8 },
|
|
51
|
+
{ name: "_", start: 3, end: 5 }
|
|
52
|
+
],
|
|
53
|
+
skeletonConfig: Xt({
|
|
54
|
+
defaultConfig: e.value,
|
|
55
|
+
userConfig: {
|
|
56
|
+
userOptions: { show: !1 },
|
|
57
|
+
table: { show: !1 },
|
|
58
|
+
useAnimation: !1,
|
|
59
|
+
style: {
|
|
60
|
+
chart: {
|
|
61
|
+
backgroundColor: "#99999930",
|
|
62
|
+
padding: {
|
|
63
|
+
top: 12,
|
|
64
|
+
right: 12,
|
|
65
|
+
bottom: 12,
|
|
66
|
+
left: 12
|
|
67
|
+
},
|
|
68
|
+
grid: {
|
|
69
|
+
horizontalGrid: { stroke: "#6A6A6A" },
|
|
70
|
+
verticalGrid: { stroke: "#6A6A6A" }
|
|
71
|
+
},
|
|
72
|
+
labels: {
|
|
73
|
+
axis: {
|
|
74
|
+
yLabel: "",
|
|
75
|
+
xLabel: ""
|
|
76
|
+
},
|
|
77
|
+
xAxisLabels: { show: !1 },
|
|
78
|
+
yAxisLabels: { show: !1 },
|
|
79
|
+
endLabels: { show: !1 },
|
|
80
|
+
startLabels: { show: !1 }
|
|
81
|
+
},
|
|
82
|
+
legend: {
|
|
83
|
+
backgroundColor: "transparent"
|
|
84
|
+
},
|
|
85
|
+
plots: {
|
|
86
|
+
endColor: "#969696",
|
|
87
|
+
startColor: "#DBDBDB",
|
|
88
|
+
stroke: "#6A6A6A",
|
|
89
|
+
evaluationColors: { enable: !1 }
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
})
|
|
95
|
+
}), { userOptionsVisible: ue, setUserOptionsVisibility: Ae, keepUserOptionState: Ne } = Rt({ config: e.value }), { svgRef: Se } = Bt({ config: e.value.style.chart.title });
|
|
96
|
+
function ie() {
|
|
97
|
+
const l = st({
|
|
98
|
+
userConfig: N.config,
|
|
99
|
+
defaultConfig: dt
|
|
100
|
+
});
|
|
101
|
+
return l.theme ? {
|
|
102
|
+
...st({
|
|
103
|
+
userConfig: zt.vue_ui_dumbbell[l.theme] || N.config,
|
|
104
|
+
defaultConfig: l
|
|
105
|
+
})
|
|
106
|
+
} : l;
|
|
107
|
+
}
|
|
108
|
+
ge(() => N.config, (l) => {
|
|
109
|
+
ne.value || (e.value = ie()), ue.value = !e.value.userOptions.showOnChartHover, Xe(), we.value += 1, $e.value += 1, Le.value += 1, E.value = e.value.style.chart.rowHeight, R.value = e.value.style.chart.width, D.value.showTable = e.value.table.show;
|
|
110
|
+
}, { deep: !0 }), ge(() => re.value, (l) => {
|
|
111
|
+
Array.isArray(l) && l.length > 0 && (ht.value = !1), De(), Ge();
|
|
112
|
+
}, { deep: !0 });
|
|
113
|
+
const S = je(null), P = je(null);
|
|
114
|
+
Ye(() => {
|
|
115
|
+
Xe();
|
|
116
|
+
});
|
|
117
|
+
const Me = g(() => !!e.value.debug);
|
|
118
|
+
function Xe() {
|
|
119
|
+
if (Tt(N.dataset) ? et({
|
|
120
|
+
componentName: "VueUiDumbbell",
|
|
121
|
+
type: "dataset",
|
|
122
|
+
debug: Me.value
|
|
123
|
+
}) : N.dataset.forEach((l, s) => {
|
|
124
|
+
It({
|
|
125
|
+
datasetObject: l,
|
|
126
|
+
requiredAttributes: ["name", "start", "end"]
|
|
127
|
+
}).forEach((t) => {
|
|
128
|
+
Z.value = !1, et({
|
|
129
|
+
componentName: "VueUiDumbbell",
|
|
130
|
+
type: "datasetSerieAttribute",
|
|
131
|
+
property: t,
|
|
132
|
+
index: s,
|
|
133
|
+
debug: Me.value
|
|
134
|
+
});
|
|
135
|
+
});
|
|
136
|
+
}), e.value.responsive) {
|
|
137
|
+
const l = me(() => {
|
|
138
|
+
const { width: s, height: t } = Pt({
|
|
139
|
+
chart: T.value,
|
|
140
|
+
title: e.value.style.chart.title.text ? xe.value : null,
|
|
141
|
+
legend: e.value.style.chart.legend.show ? _e.value : null,
|
|
142
|
+
source: ke.value,
|
|
143
|
+
noTitle: Ce.value
|
|
144
|
+
}), a = e.value.style.chart.title.text ? 24 : 0, u = e.value.style.chart.legend.show ? 24 : 0;
|
|
145
|
+
requestAnimationFrame(async () => {
|
|
146
|
+
R.value = Math.max(0.1, s), E.value = Math.max(0.1, (Math.max(0.1, t) - (a + u)) / re.value.length), We();
|
|
147
|
+
});
|
|
148
|
+
});
|
|
149
|
+
S.value && (P.value && S.value.unobserve(P.value), S.value.disconnect()), S.value = new ResizeObserver(l), P.value = T.value.parentNode, S.value.observe(P.value);
|
|
150
|
+
}
|
|
151
|
+
We();
|
|
152
|
+
}
|
|
153
|
+
Ze(() => {
|
|
154
|
+
L.value != null && (cancelAnimationFrame(L.value), L.value = null), S.value && (P.value && S.value.unobserve(P.value), S.value.disconnect());
|
|
155
|
+
});
|
|
156
|
+
const { isPrinting: ze, isImaging: Te, generatePdf: Ie, generateImage: Oe } = Dt({
|
|
157
|
+
elementId: `dumbbell_${b.value}`,
|
|
158
|
+
fileName: e.value.style.chart.title.text || "vue-ui-dumbbell",
|
|
159
|
+
options: e.value.userOptions.print
|
|
160
|
+
}), yt = g(() => e.value.userOptions.show && !e.value.style.chart.title.text), D = h({
|
|
161
|
+
showTable: e.value.table.show
|
|
162
|
+
});
|
|
163
|
+
ge(e, () => {
|
|
164
|
+
D.value = {
|
|
165
|
+
showTable: e.value.table.show
|
|
166
|
+
};
|
|
167
|
+
}, { immediate: !0 });
|
|
168
|
+
const G = g(() => re.value.map((l, s) => ({
|
|
169
|
+
...l,
|
|
170
|
+
start: tt(l.start),
|
|
171
|
+
end: tt(l.end),
|
|
172
|
+
id: l.id ?? `${String(l.name)}__${String(l.start)}__${String(l.end)}__${Qe()}`
|
|
173
|
+
}))), Fe = g(() => {
|
|
174
|
+
const l = e.value.style.chart.grid, s = G.value.flatMap((y) => [y.start, y.end]).map((y) => Number(y)).filter((y) => Number.isFinite(y)), t = s.length ? Math.min(...s) : 0, a = s.length ? Math.max(...s) : 0, u = l.scaleMin ?? Math.min(t, 0), d = l.scaleMax ?? a;
|
|
175
|
+
return { min: u, max: d };
|
|
176
|
+
}), $ = g(() => Ot(Fe.value.min, Fe.value.max, e.value.style.chart.grid.scaleSteps)), E = h(e.value.style.chart.rowHeight), R = h(e.value.style.chart.width);
|
|
177
|
+
function ft() {
|
|
178
|
+
let l = 0;
|
|
179
|
+
se.value && (l = Array.from(se.value.querySelectorAll("text")).reduce((a, u) => {
|
|
180
|
+
const d = u.getComputedTextLength();
|
|
181
|
+
return d > a ? d : a;
|
|
182
|
+
}, 0));
|
|
183
|
+
const s = ae.value ? ae.value.getBoundingClientRect().width : 0;
|
|
184
|
+
return l + s + (s ? 24 + e.value.style.chart.labels.axis.yLabelOffsetX : 0);
|
|
185
|
+
}
|
|
186
|
+
const ce = h(0), bt = me((l) => {
|
|
187
|
+
ce.value = l;
|
|
188
|
+
}, 100);
|
|
189
|
+
Lt((l) => {
|
|
190
|
+
const s = J.value;
|
|
191
|
+
if (!s) return;
|
|
192
|
+
const t = new ResizeObserver((a) => {
|
|
193
|
+
bt(a[0].contentRect.height);
|
|
194
|
+
});
|
|
195
|
+
t.observe(s), l(() => t.disconnect());
|
|
196
|
+
}), Ze(() => {
|
|
197
|
+
ce.value = 0;
|
|
198
|
+
});
|
|
199
|
+
const He = g(() => {
|
|
200
|
+
O.value;
|
|
201
|
+
let l = 0;
|
|
202
|
+
oe.value && (l = oe.value.getBBox().height);
|
|
203
|
+
let s = 0;
|
|
204
|
+
return J.value && (s = ce.value), l + s;
|
|
205
|
+
}), ve = g(() => G.value.length);
|
|
206
|
+
function Pe(l, s, t) {
|
|
207
|
+
const a = Number(l), u = Number(s.min), d = Number(s.max), y = Number(t.width);
|
|
208
|
+
if (!Number.isFinite(a) || !Number.isFinite(u) || !Number.isFinite(d) || !Number.isFinite(y))
|
|
209
|
+
return t.left;
|
|
210
|
+
const m = d - u;
|
|
211
|
+
return m <= 0 ? t.left : t.left + (a - u) / m * y;
|
|
212
|
+
}
|
|
213
|
+
const o = g(() => {
|
|
214
|
+
O.value;
|
|
215
|
+
const l = ft(), s = e.value.style.chart.padding, t = e.value.style.chart.labels.axis.xLabel ? e.value.style.chart.labels.axis.xLabelOffsetY : 0, a = E.value * ve.value - He.value - s.top - s.bottom - t, u = a / ve.value, d = E.value * ve.value, y = R.value - l - s.left - s.right, m = $.value.ticks.length * (y / $.value.ticks.length);
|
|
216
|
+
return {
|
|
217
|
+
left: e.value.style.chart.padding.left + l,
|
|
218
|
+
right: R.value - e.value.style.chart.padding.right,
|
|
219
|
+
top: e.value.style.chart.padding.top,
|
|
220
|
+
bottom: d - e.value.style.chart.padding.bottom - He.value - t,
|
|
221
|
+
width: y,
|
|
222
|
+
height: a,
|
|
223
|
+
rowHeight: u,
|
|
224
|
+
absoluteHeight: d,
|
|
225
|
+
widthPlotReference: m
|
|
226
|
+
};
|
|
227
|
+
}), M = g(() => Math.min(E.value / 2 * 0.7, e.value.style.chart.plots.radius)), B = h([]), k = g({
|
|
228
|
+
get() {
|
|
229
|
+
const l = o.value, s = $.value;
|
|
230
|
+
return B.value.map((t, a) => {
|
|
231
|
+
const u = Pe(t.start, s, l), d = Pe(t.endVal, s, l), y = u + (d - u) / 2, m = ![null, void 0].includes(t.start) && ![null, void 0].includes(t.end) && t.end > t.start, z = ![null, void 0].includes(t.start) && ![null, void 0].includes(t.end) && t.end < t.start, qe = ![null, void 0].includes(t.start) && ![null, void 0].includes(t.end) && t.end === t.start || [null, void 0].includes(t.start) || [null, void 0].includes(t.end), wt = m ? e.value.style.chart.plots.evaluationColors.positive : z ? e.value.style.chart.plots.evaluationColors.negative : e.value.style.chart.plots.evaluationColors.neutral;
|
|
232
|
+
return {
|
|
233
|
+
...t,
|
|
234
|
+
isPositive: m,
|
|
235
|
+
isNegative: z,
|
|
236
|
+
isNeutral: qe,
|
|
237
|
+
evaluationColor: wt,
|
|
238
|
+
evaluationGrad: `url(#${m ? "positive" : z ? "negative" : "neutral"}_grad_${b.value})`,
|
|
239
|
+
startX: u,
|
|
240
|
+
endX: d,
|
|
241
|
+
centerX: y,
|
|
242
|
+
y: l.top + a * l.rowHeight + l.rowHeight / 2
|
|
243
|
+
};
|
|
244
|
+
});
|
|
245
|
+
},
|
|
246
|
+
set(l) {
|
|
247
|
+
B.value = l;
|
|
248
|
+
}
|
|
249
|
+
});
|
|
250
|
+
function De() {
|
|
251
|
+
B.value = G.value.map((l) => {
|
|
252
|
+
const s = Number(l.start);
|
|
253
|
+
return {
|
|
254
|
+
...l,
|
|
255
|
+
endVal: Number.isFinite(s) ? s : 0
|
|
256
|
+
};
|
|
257
|
+
});
|
|
258
|
+
}
|
|
259
|
+
const L = h(null);
|
|
260
|
+
Ye(() => {
|
|
261
|
+
Ge();
|
|
262
|
+
});
|
|
263
|
+
function Ge() {
|
|
264
|
+
if (L.value != null && (cancelAnimationFrame(L.value), L.value = null), De(), !e.value.useAnimation) {
|
|
265
|
+
k.value = B.value.map((a) => {
|
|
266
|
+
const u = Number(a.end);
|
|
267
|
+
return { ...a, endVal: Number.isFinite(u) ? u : a.endVal };
|
|
268
|
+
});
|
|
269
|
+
return;
|
|
270
|
+
}
|
|
271
|
+
const l = Math.max(1, Math.min(100, e.value.animationSpeed || 100)) / 100, s = G.value.map((a) => {
|
|
272
|
+
const u = Number(a.start), d = Number(a.end), y = Number.isFinite(u) ? u : 0;
|
|
273
|
+
return (Number.isFinite(d) ? d : y) - y;
|
|
274
|
+
}), t = () => {
|
|
275
|
+
let a = !0;
|
|
276
|
+
k.value = B.value.map((u, d) => {
|
|
277
|
+
const y = Number.isFinite(Number(u.end)) ? Number(u.end) : u.endVal, m = u.endVal + s[d] * l, z = s[d] >= 0 ? Math.min(m, y) : Math.max(m, y);
|
|
278
|
+
return z !== y && (a = !1), { ...u, endVal: z };
|
|
279
|
+
}), a ? L.value = null : L.value = requestAnimationFrame(t);
|
|
280
|
+
};
|
|
281
|
+
L.value = requestAnimationFrame(t);
|
|
282
|
+
}
|
|
283
|
+
const Ee = g(() => e.value.style.chart.plots.evaluationColors.enable ? [
|
|
284
|
+
{ name: e.value.style.chart.legend.labelNegative, color: e.value.style.chart.plots.gradient.show ? `url(#negative_grad_${b.value})` : e.value.style.chart.plots.evaluationColors.negative },
|
|
285
|
+
{ name: e.value.style.chart.legend.labelNeutral, color: e.value.style.chart.plots.gradient.show ? `url(#neutral_grad_${b.value})` : e.value.style.chart.plots.evaluationColors.neutral },
|
|
286
|
+
{ name: e.value.style.chart.legend.labelPositive, color: e.value.style.chart.plots.gradient.show ? `url(#positive_grad_${b.value})` : e.value.style.chart.plots.evaluationColors.positive }
|
|
287
|
+
] : [
|
|
288
|
+
{ name: e.value.style.chart.legend.labelStart, color: e.value.style.chart.plots.gradient.show ? `url(#start_grad_${b.value})` : e.value.style.chart.plots.startColor },
|
|
289
|
+
{ name: e.value.style.chart.legend.labelEnd, color: e.value.style.chart.plots.gradient.show ? `url(#end_grad_${b.value})` : e.value.style.chart.plots.endColor }
|
|
290
|
+
]), gt = g(() => ({
|
|
291
|
+
cy: "donut-div-legend",
|
|
292
|
+
backgroundColor: e.value.style.chart.legend.backgroundColor,
|
|
293
|
+
color: e.value.style.chart.legend.color,
|
|
294
|
+
fontSize: e.value.style.chart.legend.fontSize,
|
|
295
|
+
paddingBottom: 12,
|
|
296
|
+
paddingTop: 12,
|
|
297
|
+
fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
|
|
298
|
+
})), X = g(() => {
|
|
299
|
+
const l = k.value.map((t) => ({
|
|
300
|
+
name: t.name
|
|
301
|
+
})), s = k.value.map((t) => ({
|
|
302
|
+
start: t.start,
|
|
303
|
+
end: t.end
|
|
304
|
+
}));
|
|
305
|
+
return { head: l, body: s };
|
|
306
|
+
}), K = g(() => {
|
|
307
|
+
const l = [
|
|
308
|
+
e.value.table.columnNames.series,
|
|
309
|
+
e.value.table.columnNames.start,
|
|
310
|
+
e.value.table.columnNames.end,
|
|
311
|
+
e.value.table.columnNames.progression
|
|
312
|
+
], s = X.value.head.map((u, d) => {
|
|
313
|
+
const y = w({
|
|
314
|
+
p: e.value.style.chart.labels.prefix,
|
|
315
|
+
v: X.value.body[d].start,
|
|
316
|
+
s: e.value.style.chart.labels.suffix,
|
|
317
|
+
r: e.value.table.td.roundingValue
|
|
318
|
+
}), m = w({
|
|
319
|
+
p: e.value.style.chart.labels.prefix,
|
|
320
|
+
v: X.value.body[d].end,
|
|
321
|
+
s: e.value.style.chart.labels.suffix,
|
|
322
|
+
r: e.value.table.td.roundingValue
|
|
323
|
+
}), z = w({
|
|
324
|
+
v: 100 * (X.value.body[d].end / X.value.body[d].start - 1),
|
|
325
|
+
s: "%",
|
|
326
|
+
r: e.value.table.td.roundingPercentage
|
|
327
|
+
});
|
|
328
|
+
return [
|
|
329
|
+
{ name: u.name },
|
|
330
|
+
y,
|
|
331
|
+
m,
|
|
332
|
+
z
|
|
333
|
+
];
|
|
334
|
+
}), t = {
|
|
335
|
+
th: {
|
|
336
|
+
backgroundColor: e.value.table.th.backgroundColor,
|
|
337
|
+
color: e.value.table.th.color,
|
|
338
|
+
outline: e.value.table.th.outline
|
|
339
|
+
},
|
|
340
|
+
td: {
|
|
341
|
+
backgroundColor: e.value.table.td.backgroundColor,
|
|
342
|
+
color: e.value.table.td.color,
|
|
343
|
+
outline: e.value.table.td.outline
|
|
344
|
+
},
|
|
345
|
+
breakpoint: e.value.table.responsiveBreakpoint
|
|
346
|
+
};
|
|
347
|
+
return {
|
|
348
|
+
colNames: [
|
|
349
|
+
e.value.table.columnNames.series,
|
|
350
|
+
e.value.table.columnNames.start,
|
|
351
|
+
e.value.table.columnNames.end,
|
|
352
|
+
e.value.table.columnNames.progression
|
|
353
|
+
],
|
|
354
|
+
head: l,
|
|
355
|
+
body: s,
|
|
356
|
+
config: t
|
|
357
|
+
};
|
|
358
|
+
});
|
|
359
|
+
function Re(l = null) {
|
|
360
|
+
St(() => {
|
|
361
|
+
const s = X.value.head.map((u, d) => [[
|
|
362
|
+
u.name
|
|
363
|
+
], [X.value.body[d].start], [X.value.body[d].end]]), t = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[e.value.table.columnNames.series], [e.value.table.columnNames.start], [e.value.table.columnNames.end]]].concat(s), a = Ft(t);
|
|
364
|
+
l ? l(a) : Ht({ csvContent: a, title: e.value.style.chart.title.text || "vue-ui-dumbbell" });
|
|
365
|
+
});
|
|
366
|
+
}
|
|
367
|
+
const V = h(!1);
|
|
368
|
+
function Be(l) {
|
|
369
|
+
V.value = l, pe.value += 1;
|
|
370
|
+
}
|
|
371
|
+
function mt() {
|
|
372
|
+
return G.value;
|
|
373
|
+
}
|
|
374
|
+
function Ve() {
|
|
375
|
+
D.value.showTable = !D.value.showTable;
|
|
376
|
+
}
|
|
377
|
+
const Q = h(!1);
|
|
378
|
+
function de() {
|
|
379
|
+
Q.value = !Q.value;
|
|
380
|
+
}
|
|
381
|
+
async function pt({ scale: l = 2 } = {}) {
|
|
382
|
+
if (!T.value) return;
|
|
383
|
+
const { width: s, height: t } = T.value.getBoundingClientRect(), a = s / t, { imageUri: u, base64: d } = await Ut({ domElement: T.value, base64: !0, img: !0, scale: l });
|
|
384
|
+
return {
|
|
385
|
+
imageUri: u,
|
|
386
|
+
base64: d,
|
|
387
|
+
title: e.value.style.chart.title.text,
|
|
388
|
+
width: s,
|
|
389
|
+
height: t,
|
|
390
|
+
aspectRatio: a
|
|
391
|
+
};
|
|
392
|
+
}
|
|
393
|
+
const Ue = g(() => $.value.ticks), xt = g(() => ({ start: 0, end: Ue.value.length }));
|
|
394
|
+
Vt({
|
|
395
|
+
timeLabelsEls: J,
|
|
396
|
+
timeLabels: Ue,
|
|
397
|
+
slicer: xt,
|
|
398
|
+
configRef: e,
|
|
399
|
+
rotationPath: ["style", "chart", "labels", "xAxisLabels", "rotation"],
|
|
400
|
+
autoRotatePath: ["style", "chart", "labels", "xAxisLabels", "autoRotate"],
|
|
401
|
+
isAutoSize: !1,
|
|
402
|
+
width: R,
|
|
403
|
+
height: E,
|
|
404
|
+
targetClass: ".vue-ui-dumbbell-scale-label"
|
|
405
|
+
});
|
|
406
|
+
function _t({
|
|
407
|
+
rowHeight: l,
|
|
408
|
+
fontSize: s,
|
|
409
|
+
showProgression: t
|
|
410
|
+
}) {
|
|
411
|
+
if (!t) return !1;
|
|
412
|
+
const a = l / 3, u = l / 1.3, d = Math.abs(u - a), y = s * 1.2;
|
|
413
|
+
return d < y;
|
|
414
|
+
}
|
|
415
|
+
const kt = /* @__PURE__ */ (() => {
|
|
416
|
+
let l = null, s = 0;
|
|
417
|
+
const t = 1;
|
|
418
|
+
return (a) => {
|
|
419
|
+
if (a === O.value) {
|
|
420
|
+
l = null, s = 0;
|
|
421
|
+
return;
|
|
422
|
+
}
|
|
423
|
+
l === null || l !== a ? (l = a, s = 1) : (s += 1, s >= t && (O.value = a, l = null, s = 0));
|
|
424
|
+
};
|
|
425
|
+
})(), We = me(() => {
|
|
426
|
+
requestAnimationFrame(() => {
|
|
427
|
+
requestAnimationFrame(() => {
|
|
428
|
+
const l = _t({
|
|
429
|
+
rowHeight: o.value.rowHeight,
|
|
430
|
+
fontSize: e.value.style.chart.labels.yAxisLabels.fontSize,
|
|
431
|
+
showProgression: e.value.style.chart.labels.yAxisLabels.showProgression
|
|
432
|
+
});
|
|
433
|
+
kt(l);
|
|
434
|
+
});
|
|
435
|
+
});
|
|
436
|
+
}, 100);
|
|
437
|
+
function he({ datapoint: l, seriesIndex: s }) {
|
|
438
|
+
I.value = s, r.value = l, e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: l, seriesIndex: s });
|
|
439
|
+
}
|
|
440
|
+
function ye({ datapoint: l, seriesIndex: s }) {
|
|
441
|
+
I.value = null, r.value = null, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: l, seriesIndex: s });
|
|
442
|
+
}
|
|
443
|
+
function fe({ datapoint: l, seriesIndex: s }) {
|
|
444
|
+
e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: l, seriesIndex: s });
|
|
445
|
+
}
|
|
446
|
+
const be = g(() => {
|
|
447
|
+
if (r.value === null) return 0;
|
|
448
|
+
const l = ![null, void 0].includes(r.value.start), s = ![null, void 0].includes(r.value.end);
|
|
449
|
+
return l && s ? Math.min(r.value.startX, r.value.endX) + Math.abs(r.value.startX - r.value.endX) / 2 : l && !s ? r.value.startX : s && !l ? r.value.endX : null;
|
|
450
|
+
}), Ct = g(() => {
|
|
451
|
+
if (r.value === null) return "";
|
|
452
|
+
const l = ![null, void 0].includes(r.value.start), s = ![null, void 0].includes(r.value.end);
|
|
453
|
+
let t = "", a = "";
|
|
454
|
+
return l && (t = H(
|
|
455
|
+
e.value.style.chart.labels.formatter,
|
|
456
|
+
r.value.start,
|
|
457
|
+
w({
|
|
458
|
+
p: e.value.style.chart.labels.prefix,
|
|
459
|
+
v: r.value.start,
|
|
460
|
+
s: e.value.style.chart.labels.suffix,
|
|
461
|
+
r: e.value.style.chart.labels.startLabels.rounding
|
|
462
|
+
}),
|
|
463
|
+
{ datapoint: r.value, seriesIndex: I.value }
|
|
464
|
+
)), s && (a = H(
|
|
465
|
+
e.value.style.chart.labels.formatter,
|
|
466
|
+
r.value.end,
|
|
467
|
+
w({
|
|
468
|
+
p: e.value.style.chart.labels.prefix,
|
|
469
|
+
v: r.value.end,
|
|
470
|
+
s: e.value.style.chart.labels.suffix,
|
|
471
|
+
r: e.value.style.chart.labels.startLabels.rounding
|
|
472
|
+
}),
|
|
473
|
+
{ datapoint: r.value, seriesIndex: I.value }
|
|
474
|
+
)), l && s ? `${t} → ${a}` : l && !s ? t : s && !l ? a : "";
|
|
475
|
+
});
|
|
476
|
+
return nt({
|
|
477
|
+
getData: mt,
|
|
478
|
+
getImage: pt,
|
|
479
|
+
generatePdf: Ie,
|
|
480
|
+
generateCsv: Re,
|
|
481
|
+
generateImage: Oe,
|
|
482
|
+
toggleTable: Ve,
|
|
483
|
+
toggleAnnotator: de,
|
|
484
|
+
toggleFullscreen: Be
|
|
485
|
+
}), (l, s) => (n(), c("div", {
|
|
486
|
+
ref_key: "dumbbellChart",
|
|
487
|
+
ref: T,
|
|
488
|
+
class: Je(`vue-ui-dumbbell ${V.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
|
|
489
|
+
style: ee(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;background:${e.value.style.chart.backgroundColor};${e.value.responsive ? "height:100%" : ""}`),
|
|
490
|
+
id: `dumbbell_${b.value}`,
|
|
491
|
+
onMouseenter: s[1] || (s[1] = () => i(Ae)(!0)),
|
|
492
|
+
onMouseleave: s[2] || (s[2] = () => i(Ae)(!1))
|
|
493
|
+
}, [
|
|
494
|
+
e.value.userOptions.buttons.annotator ? (n(), F(i(it), {
|
|
495
|
+
key: 0,
|
|
496
|
+
svgRef: i(Se),
|
|
497
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
498
|
+
color: e.value.style.chart.color,
|
|
499
|
+
active: Q.value,
|
|
500
|
+
onClose: de
|
|
501
|
+
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : f("", !0),
|
|
502
|
+
yt.value ? (n(), c("div", {
|
|
503
|
+
key: 1,
|
|
504
|
+
ref_key: "noTitle",
|
|
505
|
+
ref: Ce,
|
|
506
|
+
class: "vue-data-ui-no-title-space",
|
|
507
|
+
style: "height:36px; width: 100%;background:transparent"
|
|
508
|
+
}, null, 512)) : f("", !0),
|
|
509
|
+
e.value.style.chart.title.text ? (n(), c("div", {
|
|
510
|
+
key: 2,
|
|
511
|
+
ref_key: "chartTitle",
|
|
512
|
+
ref: xe,
|
|
513
|
+
style: "width:100%;background:transparent;padding-bottom:24px"
|
|
514
|
+
}, [
|
|
515
|
+
(n(), F(Wt, {
|
|
516
|
+
key: `title_${we.value}`,
|
|
517
|
+
config: {
|
|
518
|
+
title: {
|
|
519
|
+
cy: "donut-div-title",
|
|
520
|
+
...e.value.style.chart.title
|
|
521
|
+
},
|
|
522
|
+
subtitle: {
|
|
523
|
+
cy: "donut-div-subtitle",
|
|
524
|
+
...e.value.style.chart.title.subtitle
|
|
525
|
+
}
|
|
526
|
+
}
|
|
527
|
+
}, null, 8, ["config"]))
|
|
528
|
+
], 512)) : f("", !0),
|
|
529
|
+
e.value.userOptions.show && Z.value && (i(Ne) || i(ue)) ? (n(), F(i(ct), {
|
|
530
|
+
ref: "details",
|
|
531
|
+
key: `user_option_${pe.value}`,
|
|
532
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
533
|
+
color: e.value.style.chart.color,
|
|
534
|
+
isPrinting: i(ze),
|
|
535
|
+
isImaging: i(Te),
|
|
536
|
+
uid: b.value,
|
|
537
|
+
hasPdf: e.value.userOptions.buttons.pdf,
|
|
538
|
+
hasXls: e.value.userOptions.buttons.csv,
|
|
539
|
+
hasImg: e.value.userOptions.buttons.img,
|
|
540
|
+
hasTable: e.value.userOptions.buttons.table,
|
|
541
|
+
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
542
|
+
isFullscreen: V.value,
|
|
543
|
+
titles: { ...e.value.userOptions.buttonTitles },
|
|
544
|
+
chartElement: T.value,
|
|
545
|
+
position: e.value.userOptions.position,
|
|
546
|
+
hasAnnotator: e.value.userOptions.buttons.annotator,
|
|
547
|
+
isAnnotation: Q.value,
|
|
548
|
+
callbacks: e.value.userOptions.callbacks,
|
|
549
|
+
printScale: e.value.userOptions.print.scale,
|
|
550
|
+
onToggleFullscreen: Be,
|
|
551
|
+
onGeneratePdf: i(Ie),
|
|
552
|
+
onGenerateCsv: Re,
|
|
553
|
+
onGenerateImage: i(Oe),
|
|
554
|
+
onToggleTable: Ve,
|
|
555
|
+
onToggleAnnotator: de,
|
|
556
|
+
style: ee({
|
|
557
|
+
visibility: i(Ne) ? i(ue) ? "visible" : "hidden" : "visible"
|
|
558
|
+
})
|
|
559
|
+
}, At({ _: 2 }, [
|
|
560
|
+
l.$slots.menuIcon ? {
|
|
561
|
+
name: "menuIcon",
|
|
562
|
+
fn: x(({ isOpen: t, color: a }) => [
|
|
563
|
+
p(l.$slots, "menuIcon", te(le({ isOpen: t, color: a })), void 0, !0)
|
|
564
|
+
]),
|
|
565
|
+
key: "0"
|
|
566
|
+
} : void 0,
|
|
567
|
+
l.$slots.optionPdf ? {
|
|
568
|
+
name: "optionPdf",
|
|
569
|
+
fn: x(() => [
|
|
570
|
+
p(l.$slots, "optionPdf", {}, void 0, !0)
|
|
571
|
+
]),
|
|
572
|
+
key: "1"
|
|
573
|
+
} : void 0,
|
|
574
|
+
l.$slots.optionCsv ? {
|
|
575
|
+
name: "optionCsv",
|
|
576
|
+
fn: x(() => [
|
|
577
|
+
p(l.$slots, "optionCsv", {}, void 0, !0)
|
|
578
|
+
]),
|
|
579
|
+
key: "2"
|
|
580
|
+
} : void 0,
|
|
581
|
+
l.$slots.optionImg ? {
|
|
582
|
+
name: "optionImg",
|
|
583
|
+
fn: x(() => [
|
|
584
|
+
p(l.$slots, "optionImg", {}, void 0, !0)
|
|
585
|
+
]),
|
|
586
|
+
key: "3"
|
|
587
|
+
} : void 0,
|
|
588
|
+
l.$slots.optionTable ? {
|
|
589
|
+
name: "optionTable",
|
|
590
|
+
fn: x(() => [
|
|
591
|
+
p(l.$slots, "optionTable", {}, void 0, !0)
|
|
592
|
+
]),
|
|
593
|
+
key: "4"
|
|
594
|
+
} : void 0,
|
|
595
|
+
l.$slots.optionFullscreen ? {
|
|
596
|
+
name: "optionFullscreen",
|
|
597
|
+
fn: x(({ toggleFullscreen: t, isFullscreen: a }) => [
|
|
598
|
+
p(l.$slots, "optionFullscreen", te(le({ toggleFullscreen: t, isFullscreen: a })), void 0, !0)
|
|
599
|
+
]),
|
|
600
|
+
key: "5"
|
|
601
|
+
} : void 0,
|
|
602
|
+
l.$slots.optionAnnotator ? {
|
|
603
|
+
name: "optionAnnotator",
|
|
604
|
+
fn: x(({ toggleAnnotator: t, isAnnotator: a }) => [
|
|
605
|
+
p(l.$slots, "optionAnnotator", te(le({ toggleAnnotator: t, isAnnotator: a })), void 0, !0)
|
|
606
|
+
]),
|
|
607
|
+
key: "6"
|
|
608
|
+
} : void 0
|
|
609
|
+
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasTable", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : f("", !0),
|
|
610
|
+
(n(), c("svg", {
|
|
611
|
+
ref_key: "svgRef",
|
|
612
|
+
ref: Se,
|
|
613
|
+
xmlns: i(lt),
|
|
614
|
+
class: Je({ "vue-data-ui-fullscreen--on": V.value, "vue-data-ui-fulscreen--off": !V.value }),
|
|
615
|
+
viewBox: `0 0 ${R.value} ${o.value.absoluteHeight <= 0 ? 10 : o.value.absoluteHeight}`,
|
|
616
|
+
style: ee(`max-width:100%; overflow: visible; background:transparent;color:${e.value.style.chart.color}`)
|
|
617
|
+
}, [
|
|
618
|
+
Nt(i(vt)),
|
|
619
|
+
l.$slots["chart-background"] ? (n(), c("foreignObject", {
|
|
620
|
+
key: 0,
|
|
621
|
+
x: o.value.left,
|
|
622
|
+
y: o.value.top,
|
|
623
|
+
width: Math.max(0.1, o.value.width),
|
|
624
|
+
height: Math.max(0.1, o.value.height),
|
|
625
|
+
style: {
|
|
626
|
+
pointerEvents: "none"
|
|
627
|
+
}
|
|
628
|
+
}, [
|
|
629
|
+
p(l.$slots, "chart-background", {}, void 0, !0)
|
|
630
|
+
], 8, Jt)) : f("", !0),
|
|
631
|
+
e.value.style.chart.grid.verticalGrid.show ? (n(), c("g", Kt, [
|
|
632
|
+
(n(!0), c(C, null, A($.value.ticks, (t, a) => (n(), c("line", {
|
|
633
|
+
x1: o.value.left + a * o.value.width / ($.value.ticks.length - 1),
|
|
634
|
+
x2: o.value.left + a * o.value.width / ($.value.ticks.length - 1),
|
|
635
|
+
y1: o.value.top,
|
|
636
|
+
y2: o.value.bottom,
|
|
637
|
+
stroke: e.value.style.chart.grid.verticalGrid.stroke,
|
|
638
|
+
"stroke-width": e.value.style.chart.grid.verticalGrid.strokeWidth,
|
|
639
|
+
"stroke-dasharray": e.value.style.chart.grid.verticalGrid.strokeDasharray
|
|
640
|
+
}, null, 8, Qt))), 256))
|
|
641
|
+
])) : f("", !0),
|
|
642
|
+
e.value.style.chart.grid.horizontalGrid.show ? (n(), c("g", el, [
|
|
643
|
+
(n(!0), c(C, null, A(G.value, (t, a) => (n(), c("line", {
|
|
644
|
+
x1: o.value.left,
|
|
645
|
+
x2: o.value.right,
|
|
646
|
+
y1: o.value.top + a * o.value.rowHeight,
|
|
647
|
+
y2: o.value.top + a * o.value.rowHeight,
|
|
648
|
+
stroke: e.value.style.chart.grid.horizontalGrid.stroke,
|
|
649
|
+
"stroke-width": e.value.style.chart.grid.horizontalGrid.strokeWidth,
|
|
650
|
+
"stroke-dasharray": e.value.style.chart.grid.horizontalGrid.strokeDasharray
|
|
651
|
+
}, null, 8, tl))), 256)),
|
|
652
|
+
v("line", {
|
|
653
|
+
x1: o.value.left,
|
|
654
|
+
x2: o.value.right,
|
|
655
|
+
y1: o.value.bottom,
|
|
656
|
+
y2: o.value.bottom,
|
|
657
|
+
stroke: e.value.style.chart.grid.horizontalGrid.stroke,
|
|
658
|
+
"stroke-width": e.value.style.chart.grid.horizontalGrid.strokeWidth,
|
|
659
|
+
"stroke-dasharray": e.value.style.chart.grid.horizontalGrid.strokeDasharray
|
|
660
|
+
}, null, 8, ll)
|
|
661
|
+
])) : f("", !0),
|
|
662
|
+
e.value.style.chart.labels.axis.yLabel ? (n(), c("text", {
|
|
663
|
+
key: 3,
|
|
664
|
+
ref_key: "yAxisLabel",
|
|
665
|
+
ref: ae,
|
|
666
|
+
transform: `translate(${e.value.style.chart.labels.axis.fontSize}, ${o.value.absoluteHeight / 2}), rotate(-90)`,
|
|
667
|
+
"font-size": e.value.style.chart.labels.axis.fontSize,
|
|
668
|
+
fill: e.value.style.chart.labels.axis.color,
|
|
669
|
+
"text-anchor": "middle"
|
|
670
|
+
}, _(e.value.style.chart.labels.axis.yLabel), 9, al)) : f("", !0),
|
|
671
|
+
e.value.style.chart.labels.yAxisLabels.show ? (n(), c("g", {
|
|
672
|
+
key: 4,
|
|
673
|
+
ref_key: "serieLabels",
|
|
674
|
+
ref: se
|
|
675
|
+
}, [
|
|
676
|
+
(n(!0), c(C, null, A(k.value, (t, a) => (n(), c("text", {
|
|
677
|
+
class: "vue-ui-dumbbell-serie-name",
|
|
678
|
+
key: `serieLabel_${t.id}_${a}`,
|
|
679
|
+
x: o.value.left - 6 + e.value.style.chart.labels.yAxisLabels.offsetX,
|
|
680
|
+
y: o.value.top + a * o.value.rowHeight + (!e.value.style.chart.labels.yAxisLabels.showProgression || O.value ? o.value.rowHeight / 2 : o.value.rowHeight / 3) + e.value.style.chart.labels.yAxisLabels.fontSize / 3,
|
|
681
|
+
"font-size": e.value.style.chart.labels.yAxisLabels.fontSize,
|
|
682
|
+
fill: e.value.style.chart.labels.yAxisLabels.color,
|
|
683
|
+
"font-weight": e.value.style.chart.labels.yAxisLabels.bold ? "bold" : "normal",
|
|
684
|
+
"text-anchor": "end",
|
|
685
|
+
onMouseenter: (u) => he({ datapoint: t, seriesIndex: a }),
|
|
686
|
+
onMouseleave: (u) => ye({ datapoint: t, seriesIndex: a }),
|
|
687
|
+
onClick: (u) => fe({ datapoint: t, seriesIndex: a })
|
|
688
|
+
}, _(t.name) + " " + _(O.value && e.value.style.chart.labels.yAxisLabels.showProgression ? [null, void 0].includes(t.start) || [null, void 0].includes(t.end) ? "" : `(${i(H)(
|
|
689
|
+
e.value.style.chart.labels.yAxisLabels.formatter,
|
|
690
|
+
100 * (t.end / t.start - 1),
|
|
691
|
+
i(w)({
|
|
692
|
+
v: 100 * (t.end / t.start - 1),
|
|
693
|
+
s: "%",
|
|
694
|
+
r: e.value.style.chart.labels.yAxisLabels.rounding
|
|
695
|
+
}),
|
|
696
|
+
{ datapoint: t }
|
|
697
|
+
)})` : ""), 41, sl))), 128)),
|
|
698
|
+
e.value.style.chart.labels.yAxisLabels.showProgression && !O.value ? (n(!0), c(C, { key: 0 }, A(k.value, (t, a) => (n(), c("text", {
|
|
699
|
+
class: "vue-ui-dumbbell-serie-value",
|
|
700
|
+
x: o.value.left - 6 + e.value.style.chart.labels.yAxisLabels.offsetX,
|
|
701
|
+
y: o.value.top + a * o.value.rowHeight + o.value.rowHeight / 1.3 + e.value.style.chart.labels.yAxisLabels.fontSize / 3,
|
|
702
|
+
"font-size": e.value.style.chart.labels.yAxisLabels.fontSize,
|
|
703
|
+
fill: e.value.style.chart.labels.yAxisLabels.color,
|
|
704
|
+
"text-anchor": "end",
|
|
705
|
+
onMouseenter: (u) => he({ datapoint: t, seriesIndex: a }),
|
|
706
|
+
onMouseleave: (u) => ye({ datapoint: t, seriesIndex: a }),
|
|
707
|
+
onClick: (u) => fe({ datapoint: t, seriesIndex: a })
|
|
708
|
+
}, _([null, void 0].includes(t.start) || [null, void 0].includes(t.end) ? "" : i(H)(
|
|
709
|
+
e.value.style.chart.labels.yAxisLabels.formatter,
|
|
710
|
+
100 * (t.end / t.start - 1),
|
|
711
|
+
i(w)({
|
|
712
|
+
v: 100 * (t.end / t.start - 1),
|
|
713
|
+
s: "%",
|
|
714
|
+
r: e.value.style.chart.labels.yAxisLabels.rounding
|
|
715
|
+
}),
|
|
716
|
+
{ datapoint: t }
|
|
717
|
+
)), 41, ol))), 256)) : f("", !0)
|
|
718
|
+
], 512)) : f("", !0),
|
|
719
|
+
e.value.style.chart.labels.axis.xLabel ? (n(), c("text", {
|
|
720
|
+
key: 5,
|
|
721
|
+
ref_key: "xAxisLabel",
|
|
722
|
+
ref: oe,
|
|
723
|
+
x: o.value.left + o.value.width / 2,
|
|
724
|
+
y: o.value.absoluteHeight - e.value.style.chart.labels.axis.fontSize / 3,
|
|
725
|
+
"font-size": e.value.style.chart.labels.axis.fontSize,
|
|
726
|
+
fill: e.value.style.chart.labels.axis.color,
|
|
727
|
+
"text-anchor": "middle"
|
|
728
|
+
}, _(e.value.style.chart.labels.axis.xLabel), 9, nl)) : f("", !0),
|
|
729
|
+
e.value.style.chart.labels.xAxisLabels.show ? (n(), c("g", {
|
|
730
|
+
key: 6,
|
|
731
|
+
ref_key: "scaleLabels",
|
|
732
|
+
ref: J
|
|
733
|
+
}, [
|
|
734
|
+
(n(!0), c(C, null, A($.value.ticks, (t, a) => (n(), c("text", {
|
|
735
|
+
class: "vue-ui-dumbbell-scale-label",
|
|
736
|
+
key: `tick_${a}`,
|
|
737
|
+
transform: `translate(${o.value.left + a * (o.value.width / ($.value.ticks.length - 1))}, ${o.value.bottom + e.value.style.chart.labels.xAxisLabels.fontSize + e.value.style.chart.labels.xAxisLabels.offsetY}), rotate(${e.value.style.chart.labels.xAxisLabels.rotation})`,
|
|
738
|
+
"font-size": e.value.style.chart.labels.xAxisLabels.fontSize,
|
|
739
|
+
fill: e.value.style.chart.labels.xAxisLabels.color,
|
|
740
|
+
"font-weight": e.value.style.chart.labels.xAxisLabels.bold ? "bold" : "normal",
|
|
741
|
+
"text-anchor": e.value.style.chart.labels.xAxisLabels.rotation > 0 ? "start" : e.value.style.chart.labels.xAxisLabels.rotation < 0 ? "end" : "middle"
|
|
742
|
+
}, _(i(H)(
|
|
743
|
+
e.value.style.chart.labels.formatter,
|
|
744
|
+
t,
|
|
745
|
+
i(w)({
|
|
746
|
+
p: e.value.style.chart.labels.prefix,
|
|
747
|
+
v: t,
|
|
748
|
+
s: e.value.style.chart.labels.suffix,
|
|
749
|
+
r: e.value.style.chart.labels.xAxisLabels.rounding
|
|
750
|
+
}),
|
|
751
|
+
{ datapoint: t, seriesIndex: a }
|
|
752
|
+
)), 9, rl))), 128))
|
|
753
|
+
], 512)) : f("", !0),
|
|
754
|
+
W(v("g", null, [
|
|
755
|
+
W(v("path", {
|
|
756
|
+
d: `M ${r.value ? r.value.startX : o.value.left},${o.value.top} ${r.value ? r.value.startX : o.value.left},${o.value.bottom}`,
|
|
757
|
+
stroke: r.value ? e.value.style.chart.plots.evaluationColors.enable ? r.value.evaluationColor : e.value.style.chart.plots.startColor : "transparent",
|
|
758
|
+
"stroke-width": e.value.style.chart.comparisonLines.strokeWidth,
|
|
759
|
+
"stroke-dasharray": e.value.style.chart.comparisonLines.strokeDasharray,
|
|
760
|
+
style: { transition: "all 0.3s ease-in-out" }
|
|
761
|
+
}, null, 8, ul), [
|
|
762
|
+
[q, r.value !== null && ![null, void 0].includes(r.value.start)]
|
|
763
|
+
]),
|
|
764
|
+
W(v("path", {
|
|
765
|
+
d: `M ${r.value ? r.value.endX : o.value.left},${o.value.top} ${r.value ? r.value.endX : o.value.left},${o.value.bottom}`,
|
|
766
|
+
stroke: r.value ? e.value.style.chart.plots.evaluationColors.enable ? r.value.evaluationColor : e.value.style.chart.plots.endColor : "transparent",
|
|
767
|
+
"stroke-width": e.value.style.chart.comparisonLines.strokeWidth,
|
|
768
|
+
"stroke-dasharray": e.value.style.chart.comparisonLines.strokeDasharray,
|
|
769
|
+
style: { transition: "all 0.3s ease-in-out" }
|
|
770
|
+
}, null, 8, il), [
|
|
771
|
+
[q, r.value !== null && ![null, void 0].includes(r.value.end)]
|
|
772
|
+
]),
|
|
773
|
+
W(v("rect", {
|
|
774
|
+
x: r.value ? Math.min(r.value.startX, r.value.endX) : o.value.left,
|
|
775
|
+
y: o.value.top,
|
|
776
|
+
height: Math.max(0.1, o.value.height),
|
|
777
|
+
width: r.value ? Math.max(0.1, Math.abs(r.value.endX - r.value.startX)) : 0,
|
|
778
|
+
fill: r.value ? i(at)(e.value.style.chart.comparisonLines.rectColor, e.value.style.chart.comparisonLines.rectOpacity) : "transparent",
|
|
779
|
+
style: { transition: "all 0.3s ease-in-out" }
|
|
780
|
+
}, null, 8, cl), [
|
|
781
|
+
[q, e.value.style.chart.comparisonLines.showRect && r.value !== null && ![null, void 0].includes(r.value.start) && ![null, void 0].includes(r.value.end)]
|
|
782
|
+
]),
|
|
783
|
+
W(v("text", {
|
|
784
|
+
transform: `translate(${be.value == null ? 0 : be.value}, ${o.value.top - 6})`,
|
|
785
|
+
fill: e.value.style.chart.comparisonLines.labelColor,
|
|
786
|
+
"font-size": e.value.style.chart.comparisonLines.labelFontSize,
|
|
787
|
+
"text-anchor": "middle",
|
|
788
|
+
style: { transition: "all 0.3s ease-in-out" }
|
|
789
|
+
}, _(Ct.value), 9, vl), [
|
|
790
|
+
[q, r.value !== null && be.value !== null && e.value.style.chart.comparisonLines.showLabel]
|
|
791
|
+
])
|
|
792
|
+
], 512), [
|
|
793
|
+
[q, e.value.style.chart.comparisonLines.show && I.value !== null]
|
|
794
|
+
]),
|
|
795
|
+
v("defs", null, [
|
|
796
|
+
v("radialGradient", {
|
|
797
|
+
id: `start_grad_${b.value}`,
|
|
798
|
+
fy: "30%"
|
|
799
|
+
}, [
|
|
800
|
+
v("stop", {
|
|
801
|
+
offset: "10%",
|
|
802
|
+
"stop-color": i(j)(e.value.style.chart.plots.startColor, e.value.style.chart.plots.gradient.intensity / 100)
|
|
803
|
+
}, null, 8, hl),
|
|
804
|
+
v("stop", {
|
|
805
|
+
offset: "90%",
|
|
806
|
+
"stop-color": i(Y)(e.value.style.chart.plots.startColor, 0.1)
|
|
807
|
+
}, null, 8, yl),
|
|
808
|
+
v("stop", {
|
|
809
|
+
offset: "100%",
|
|
810
|
+
"stop-color": e.value.style.chart.plots.startColor
|
|
811
|
+
}, null, 8, fl)
|
|
812
|
+
], 8, dl),
|
|
813
|
+
v("radialGradient", {
|
|
814
|
+
id: `end_grad_${b.value}`,
|
|
815
|
+
fy: "30%"
|
|
816
|
+
}, [
|
|
817
|
+
v("stop", {
|
|
818
|
+
offset: "10%",
|
|
819
|
+
"stop-color": i(j)(e.value.style.chart.plots.endColor, e.value.style.chart.plots.gradient.intensity / 100)
|
|
820
|
+
}, null, 8, gl),
|
|
821
|
+
v("stop", {
|
|
822
|
+
offset: "90%",
|
|
823
|
+
"stop-color": i(Y)(e.value.style.chart.plots.endColor, 0.1)
|
|
824
|
+
}, null, 8, ml),
|
|
825
|
+
v("stop", {
|
|
826
|
+
offset: "100%",
|
|
827
|
+
"stop-color": e.value.style.chart.plots.endColor
|
|
828
|
+
}, null, 8, pl)
|
|
829
|
+
], 8, bl),
|
|
830
|
+
v("radialGradient", {
|
|
831
|
+
id: `positive_grad_${b.value}`,
|
|
832
|
+
fy: "30%"
|
|
833
|
+
}, [
|
|
834
|
+
v("stop", {
|
|
835
|
+
offset: "10%",
|
|
836
|
+
"stop-color": i(j)(e.value.style.chart.plots.evaluationColors.positive, e.value.style.chart.plots.gradient.intensity / 100)
|
|
837
|
+
}, null, 8, _l),
|
|
838
|
+
v("stop", {
|
|
839
|
+
offset: "90%",
|
|
840
|
+
"stop-color": i(Y)(e.value.style.chart.plots.evaluationColors.positive, 0.1)
|
|
841
|
+
}, null, 8, kl),
|
|
842
|
+
v("stop", {
|
|
843
|
+
offset: "100%",
|
|
844
|
+
"stop-color": e.value.style.chart.plots.evaluationColors.positive
|
|
845
|
+
}, null, 8, Cl)
|
|
846
|
+
], 8, xl),
|
|
847
|
+
v("radialGradient", {
|
|
848
|
+
id: `negative_grad_${b.value}`,
|
|
849
|
+
fy: "30%"
|
|
850
|
+
}, [
|
|
851
|
+
v("stop", {
|
|
852
|
+
offset: "10%",
|
|
853
|
+
"stop-color": i(j)(e.value.style.chart.plots.evaluationColors.negative, e.value.style.chart.plots.gradient.intensity / 100)
|
|
854
|
+
}, null, 8, $l),
|
|
855
|
+
v("stop", {
|
|
856
|
+
offset: "90%",
|
|
857
|
+
"stop-color": i(Y)(e.value.style.chart.plots.evaluationColors.negative, 0.1)
|
|
858
|
+
}, null, 8, Ll),
|
|
859
|
+
v("stop", {
|
|
860
|
+
offset: "100%",
|
|
861
|
+
"stop-color": e.value.style.chart.plots.evaluationColors.negative
|
|
862
|
+
}, null, 8, Al)
|
|
863
|
+
], 8, wl),
|
|
864
|
+
v("radialGradient", {
|
|
865
|
+
id: `neutral_grad_${b.value}`,
|
|
866
|
+
fy: "30%"
|
|
867
|
+
}, [
|
|
868
|
+
v("stop", {
|
|
869
|
+
offset: "10%",
|
|
870
|
+
"stop-color": i(j)(e.value.style.chart.plots.evaluationColors.neutral, e.value.style.chart.plots.gradient.intensity / 100)
|
|
871
|
+
}, null, 8, Sl),
|
|
872
|
+
v("stop", {
|
|
873
|
+
offset: "90%",
|
|
874
|
+
"stop-color": i(Y)(e.value.style.chart.plots.evaluationColors.neutral, 0.1)
|
|
875
|
+
}, null, 8, Ml),
|
|
876
|
+
v("stop", {
|
|
877
|
+
offset: "100%",
|
|
878
|
+
"stop-color": e.value.style.chart.plots.evaluationColors.neutral
|
|
879
|
+
}, null, 8, Xl)
|
|
880
|
+
], 8, Nl)
|
|
881
|
+
]),
|
|
882
|
+
(n(!0), c(C, null, A(k.value, (t, a) => (n(), c("g", {
|
|
883
|
+
key: `plot_${a}_${t.id}`
|
|
884
|
+
}, [
|
|
885
|
+
v("defs", null, [
|
|
886
|
+
v("linearGradient", {
|
|
887
|
+
id: `grad_pos_${b.value}`,
|
|
888
|
+
x1: "0%",
|
|
889
|
+
x2: "100%",
|
|
890
|
+
y1: "0%",
|
|
891
|
+
y2: "0%"
|
|
892
|
+
}, [
|
|
893
|
+
v("stop", {
|
|
894
|
+
offset: "0%",
|
|
895
|
+
"stop-color": e.value.style.chart.plots.startColor
|
|
896
|
+
}, null, 8, Tl),
|
|
897
|
+
v("stop", {
|
|
898
|
+
offset: "100%",
|
|
899
|
+
"stop-color": e.value.style.chart.plots.endColor
|
|
900
|
+
}, null, 8, Il)
|
|
901
|
+
], 8, zl),
|
|
902
|
+
v("linearGradient", {
|
|
903
|
+
id: `grad_neg_${b.value}`,
|
|
904
|
+
x1: "0%",
|
|
905
|
+
x2: "100%",
|
|
906
|
+
y1: "0%",
|
|
907
|
+
y2: "0%"
|
|
908
|
+
}, [
|
|
909
|
+
v("stop", {
|
|
910
|
+
offset: "0%",
|
|
911
|
+
"stop-color": e.value.style.chart.plots.endColor
|
|
912
|
+
}, null, 8, Fl),
|
|
913
|
+
v("stop", {
|
|
914
|
+
offset: "100%",
|
|
915
|
+
"stop-color": e.value.style.chart.plots.startColor
|
|
916
|
+
}, null, 8, Hl)
|
|
917
|
+
], 8, Ol)
|
|
918
|
+
]),
|
|
919
|
+
![void 0, null].includes(t.end) && ![void 0, null].includes(t.start) ? (n(), c("g", Pl, [
|
|
920
|
+
e.value.style.chart.plots.link.type === "curved" ? (n(), c("g", Dl, [
|
|
921
|
+
v("path", {
|
|
922
|
+
d: `M
|
|
923
|
+
${t.startX},${t.y + M.value / 2}
|
|
924
|
+
C ${t.centerX},${t.y} ${t.centerX},${t.y}
|
|
925
|
+
${t.endX},${t.y + M.value / 2}
|
|
926
|
+
L ${t.endX},${t.y - M.value / 2}
|
|
927
|
+
C ${t.centerX},${t.y} ${t.centerX},${t.y}
|
|
928
|
+
${t.startX},${t.y - M.value / 2}
|
|
929
|
+
Z
|
|
930
|
+
`,
|
|
931
|
+
fill: e.value.style.chart.plots.evaluationColors.enable ? t.evaluationColor : t.endX > t.startX ? `url(#grad_pos_${b.value})` : `url(#grad_neg_${b.value})`
|
|
932
|
+
}, null, 8, Gl)
|
|
933
|
+
])) : (n(), c("g", El, [
|
|
934
|
+
v("rect", {
|
|
935
|
+
x: t.endX > t.startX ? t.startX : t.endX,
|
|
936
|
+
y: t.y - e.value.style.chart.plots.link.strokeWidth / 2,
|
|
937
|
+
height: Math.max(0.01, e.value.style.chart.plots.link.strokeWidth),
|
|
938
|
+
width: Math.max(0.01, Math.abs(t.endX - t.startX)),
|
|
939
|
+
fill: e.value.style.chart.plots.evaluationColors.enable ? t.evaluationColor : t.endX > t.startX ? `url(#grad_pos_${b.value})` : `url(#grad_neg_${b.value})`
|
|
940
|
+
}, null, 8, Rl)
|
|
941
|
+
]))
|
|
942
|
+
])) : f("", !0),
|
|
943
|
+
[null, void 0].includes(t.start) ? f("", !0) : (n(), c("circle", {
|
|
944
|
+
key: 1,
|
|
945
|
+
cx: t.startX,
|
|
946
|
+
cy: t.y,
|
|
947
|
+
r: M.value,
|
|
948
|
+
fill: e.value.style.chart.plots.gradient.show ? e.value.style.chart.plots.evaluationColors.enable ? t.evaluationGrad : `url(#start_grad_${b.value})` : e.value.style.chart.plots.evaluationColors.enable ? t.evaluationColor : e.value.style.chart.plots.startColor,
|
|
949
|
+
stroke: e.value.style.chart.plots.stroke,
|
|
950
|
+
"stroke-width": e.value.style.chart.plots.strokeWidth
|
|
951
|
+
}, null, 8, Bl)),
|
|
952
|
+
[null, void 0].includes(t.end) ? f("", !0) : (n(), c("circle", {
|
|
953
|
+
key: 2,
|
|
954
|
+
cx: t.endX,
|
|
955
|
+
cy: t.y,
|
|
956
|
+
r: M.value,
|
|
957
|
+
fill: e.value.style.chart.plots.gradient.show ? e.value.style.chart.plots.evaluationColors.enable ? t.evaluationGrad : `url(#end_grad_${b.value})` : e.value.style.chart.plots.evaluationColors.enable ? t.evaluationColor : e.value.style.chart.plots.endColor,
|
|
958
|
+
stroke: e.value.style.chart.plots.stroke,
|
|
959
|
+
"stroke-width": e.value.style.chart.plots.strokeWidth
|
|
960
|
+
}, null, 8, Vl))
|
|
961
|
+
]))), 128)),
|
|
962
|
+
e.value.style.chart.labels.startLabels.show ? (n(), c("g", Ul, [
|
|
963
|
+
(n(!0), c(C, null, A(k.value, (t, a) => (n(), c("g", {
|
|
964
|
+
key: `start_label_${a}_${t.id}`
|
|
965
|
+
}, [
|
|
966
|
+
[null, void 0].includes(t.start) ? f("", !0) : (n(), c("text", {
|
|
967
|
+
key: 0,
|
|
968
|
+
x: t.startX,
|
|
969
|
+
y: t.y + M.value * 2 + e.value.style.chart.labels.startLabels.fontSize / 2,
|
|
970
|
+
fill: e.value.style.chart.plots.evaluationColors.enable && e.value.style.chart.labels.startLabels.useEvaluationColor ? t.evaluationColor : e.value.style.chart.labels.startLabels.useStartColor ? e.value.style.chart.plots.startColor : e.value.style.chart.labels.startLabels.color,
|
|
971
|
+
"font-size": e.value.style.chart.labels.startLabels.fontSize,
|
|
972
|
+
"text-anchor": "middle"
|
|
973
|
+
}, _(i(H)(
|
|
974
|
+
e.value.style.chart.labels.formatter,
|
|
975
|
+
t.start,
|
|
976
|
+
i(w)({
|
|
977
|
+
p: e.value.style.chart.labels.prefix,
|
|
978
|
+
v: t.start,
|
|
979
|
+
s: e.value.style.chart.labels.suffix,
|
|
980
|
+
r: e.value.style.chart.labels.startLabels.rounding
|
|
981
|
+
}),
|
|
982
|
+
{ datapoint: t, seriesIndex: a }
|
|
983
|
+
)), 9, Wl))
|
|
984
|
+
]))), 128))
|
|
985
|
+
])) : f("", !0),
|
|
986
|
+
e.value.style.chart.labels.endLabels.show ? (n(), c("g", ql, [
|
|
987
|
+
(n(!0), c(C, null, A(k.value, (t, a) => (n(), c("g", {
|
|
988
|
+
key: `end_label_${a}_${t.id}`
|
|
989
|
+
}, [
|
|
990
|
+
[null, void 0].includes(t.end) ? f("", !0) : (n(), c("text", {
|
|
991
|
+
key: 0,
|
|
992
|
+
x: t.endX,
|
|
993
|
+
y: t.y - (M.value * 2 - e.value.style.chart.labels.startLabels.fontSize / 3),
|
|
994
|
+
fill: e.value.style.chart.plots.evaluationColors.enable && e.value.style.chart.labels.endLabels.useEvaluationColor ? t.evaluationColor : e.value.style.chart.labels.endLabels.useEndColor ? e.value.style.chart.plots.endColor : e.value.style.chart.labels.endLabels.color,
|
|
995
|
+
"font-size": e.value.style.chart.labels.endLabels.fontSize,
|
|
996
|
+
"text-anchor": "middle"
|
|
997
|
+
}, _(i(H)(
|
|
998
|
+
e.value.style.chart.labels.formatter,
|
|
999
|
+
t.end,
|
|
1000
|
+
i(w)({
|
|
1001
|
+
p: e.value.style.chart.labels.prefix,
|
|
1002
|
+
v: t.end,
|
|
1003
|
+
s: e.value.style.chart.labels.suffix,
|
|
1004
|
+
r: e.value.style.chart.labels.endLabels.rounding
|
|
1005
|
+
}),
|
|
1006
|
+
{ datapoint: t, seriesIndex: a }
|
|
1007
|
+
)), 9, jl))
|
|
1008
|
+
]))), 128))
|
|
1009
|
+
])) : f("", !0),
|
|
1010
|
+
v("g", null, [
|
|
1011
|
+
(n(!0), c(C, null, A(k.value, (t, a) => (n(), c("rect", {
|
|
1012
|
+
x: o.value.left,
|
|
1013
|
+
y: o.value.top + a * Math.max(0.1, o.value.rowHeight),
|
|
1014
|
+
width: Math.max(0.1, o.value.width),
|
|
1015
|
+
height: Math.max(0.1, o.value.rowHeight),
|
|
1016
|
+
fill: I.value !== null && I.value === a ? i(at)(e.value.style.chart.highlighter.color, e.value.style.chart.highlighter.opacity) : "transparent",
|
|
1017
|
+
onMouseenter: (u) => he({ datapoint: t, seriesIndex: a }),
|
|
1018
|
+
onMouseleave: (u) => ye({ datapoint: t, seriesIndex: a }),
|
|
1019
|
+
onClick: (u) => fe({ datapoint: t, seriesIndex: a })
|
|
1020
|
+
}, null, 40, Yl))), 256))
|
|
1021
|
+
]),
|
|
1022
|
+
p(l.$slots, "svg", { svg: o.value }, void 0, !0)
|
|
1023
|
+
], 14, Zt)),
|
|
1024
|
+
l.$slots.watermark ? (n(), c("div", Zl, [
|
|
1025
|
+
p(l.$slots, "watermark", te(le({ isPrinting: i(ze) || i(Te) })), void 0, !0)
|
|
1026
|
+
])) : f("", !0),
|
|
1027
|
+
v("div", {
|
|
1028
|
+
ref_key: "chartLegend",
|
|
1029
|
+
ref: _e
|
|
1030
|
+
}, [
|
|
1031
|
+
e.value.style.chart.legend.show && Z.value ? (n(), F(qt, {
|
|
1032
|
+
key: `legend_${Le.value}`,
|
|
1033
|
+
legendSet: Ee.value,
|
|
1034
|
+
config: gt.value,
|
|
1035
|
+
clickable: !1
|
|
1036
|
+
}, {
|
|
1037
|
+
item: x(({ legend: t }) => [
|
|
1038
|
+
v("div", {
|
|
1039
|
+
style: ee(`display:flex;align-items:center;gap:4px;font-size:${e.value.style.chart.legend.fontSize}px`)
|
|
1040
|
+
}, [
|
|
1041
|
+
(n(), c("svg", {
|
|
1042
|
+
xmlns: i(lt),
|
|
1043
|
+
viewBox: "0 0 20 20",
|
|
1044
|
+
height: e.value.style.chart.legend.fontSize,
|
|
1045
|
+
width: e.value.style.chart.legend.fontSize
|
|
1046
|
+
}, [
|
|
1047
|
+
v("circle", {
|
|
1048
|
+
cx: 10,
|
|
1049
|
+
cy: 10,
|
|
1050
|
+
r: 9,
|
|
1051
|
+
fill: t.color
|
|
1052
|
+
}, null, 8, Kl)
|
|
1053
|
+
], 8, Jl)),
|
|
1054
|
+
i(ne) ? f("", !0) : (n(), c(C, { key: 0 }, [
|
|
1055
|
+
Ke(_(t.name), 1)
|
|
1056
|
+
], 64))
|
|
1057
|
+
], 4)
|
|
1058
|
+
]),
|
|
1059
|
+
_: 1
|
|
1060
|
+
}, 8, ["legendSet", "config"])) : p(l.$slots, "legend", {
|
|
1061
|
+
key: 1,
|
|
1062
|
+
legend: Ee.value
|
|
1063
|
+
}, void 0, !0)
|
|
1064
|
+
], 512),
|
|
1065
|
+
l.$slots.source ? (n(), c("div", {
|
|
1066
|
+
key: 5,
|
|
1067
|
+
ref_key: "source",
|
|
1068
|
+
ref: ke,
|
|
1069
|
+
dir: "auto"
|
|
1070
|
+
}, [
|
|
1071
|
+
p(l.$slots, "source", {}, void 0, !0)
|
|
1072
|
+
], 512)) : f("", !0),
|
|
1073
|
+
Z.value ? (n(), F(i(rt), {
|
|
1074
|
+
key: 6,
|
|
1075
|
+
hideDetails: "",
|
|
1076
|
+
config: {
|
|
1077
|
+
open: D.value.showTable,
|
|
1078
|
+
maxHeight: 1e4,
|
|
1079
|
+
body: {
|
|
1080
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
1081
|
+
color: e.value.style.chart.color
|
|
1082
|
+
},
|
|
1083
|
+
head: {
|
|
1084
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
1085
|
+
color: e.value.style.chart.color
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
}, {
|
|
1089
|
+
content: x(() => [
|
|
1090
|
+
(n(), F(i(ut), {
|
|
1091
|
+
key: `table_${$e.value}`,
|
|
1092
|
+
colNames: K.value.colNames,
|
|
1093
|
+
head: K.value.head,
|
|
1094
|
+
body: K.value.body,
|
|
1095
|
+
config: K.value.config,
|
|
1096
|
+
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
1097
|
+
onClose: s[0] || (s[0] = (t) => D.value.showTable = !1)
|
|
1098
|
+
}, {
|
|
1099
|
+
th: x(({ th: t }) => [
|
|
1100
|
+
v("div", {
|
|
1101
|
+
innerHTML: t,
|
|
1102
|
+
style: { display: "flex", "align-items": "center" }
|
|
1103
|
+
}, null, 8, Ql)
|
|
1104
|
+
]),
|
|
1105
|
+
td: x(({ td: t }) => [
|
|
1106
|
+
Ke(_(t.name || t), 1)
|
|
1107
|
+
]),
|
|
1108
|
+
_: 1
|
|
1109
|
+
}, 8, ["colNames", "head", "body", "config", "title"]))
|
|
1110
|
+
]),
|
|
1111
|
+
_: 1
|
|
1112
|
+
}, 8, ["config"])) : f("", !0),
|
|
1113
|
+
i(ne) ? (n(), F(Et, { key: 7 })) : f("", !0)
|
|
1114
|
+
], 46, Yt));
|
|
1115
|
+
}
|
|
1116
|
+
}, fa = /* @__PURE__ */ jt(ea, [["__scopeId", "data-v-e9195160"]]);
|
|
1117
|
+
export {
|
|
1118
|
+
fa as default
|
|
1119
|
+
};
|