vue-data-ui 3.0.0-next.6 → 3.0.0-next.8
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-BRtNjitS.js} +1 -1
- package/dist/{BaseDraggableDialog-Q2ajCztp.js → BaseDraggableDialog-CO9ok1PR.js} +2 -2
- package/dist/{BaseIcon-BKR7AGeP.js → BaseIcon-BuOIF6t5.js} +1 -1
- package/dist/{ColorPicker-BagIs8-K.js → ColorPicker-FH6oc0mS.js} +2 -2
- package/dist/{DataTable-CDwApkI_.js → DataTable-D36ZRtpU.js} +2 -2
- package/dist/{Legend-BSLj7tYc.js → Legend-DInM-hku.js} +2 -2
- package/dist/{NonSvgPenAndPaper-DjJe5fXu.js → NonSvgPenAndPaper-B60MxEaz.js} +3 -3
- package/dist/{PackageVersion-BsKpz6KS.js → PackageVersion-CGQlqnmq.js} +1 -1
- package/dist/{PenAndPaper-BYRk8xrS.js → PenAndPaper-B5slIHlh.js} +3 -3
- package/dist/{Shape-DK7zYTKa.js → Shape-BGr3dQKt.js} +1 -1
- package/dist/{Slicer-B_Hb6qSk.js → Slicer-O07lQwRC.js} +2 -2
- package/dist/{SparkTooltip-Dy2sVTb_.js → SparkTooltip-BWA23VgJ.js} +1 -1
- package/dist/{Title-Cednydse.js → Title-BSlAPr_H.js} +1 -1
- package/dist/{Tooltip-DJlwW-XP.js → Tooltip-lPcsweXz.js} +1 -1
- package/dist/{UserOptions-DxIzWere.js → UserOptions-Dn5TCQxg.js} +2 -2
- package/dist/{dom-to-png-lZcM-YfK.js → dom-to-png-Br-eVhJZ.js} +1 -1
- package/dist/{img-DqlIAUF6.js → img-CgMUOQnb.js} +1 -1
- package/dist/{index-BQcLOx39.js → index-Cfm5-hMQ.js} +490 -484
- package/dist/{pdf-CjIXhsyg.js → pdf-BMVHBLq5.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +1 -0
- package/dist/types/vue-data-ui.d.ts +1 -0
- package/dist/{useNestedProp-DefBVltl.js → useNestedProp-Hh7nGEjp.js} +1 -1
- package/dist/{usePrinter-BRY5saEA.js → usePrinter-B1Hgs47c.js} +2 -2
- package/dist/{vue-data-ui-CWRlSsiN.js → vue-data-ui-CD674-M3.js} +64 -64
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-CJMZqDo1.js → vue-ui-3d-bar-DWtJoryQ.js} +6 -6
- package/dist/{vue-ui-accordion-Df-5BRRg.js → vue-ui-accordion-CEDGlyKI.js} +3 -3
- package/dist/{vue-ui-age-pyramid-B6WAMtPk.js → vue-ui-age-pyramid-DbrA1G0r.js} +6 -6
- package/dist/{vue-ui-annotator-BxC5dcIv.js → vue-ui-annotator-CosgP-Fl.js} +2 -2
- package/dist/{vue-ui-bullet-NmtltFbU.js → vue-ui-bullet-9IB3mGon.js} +7 -7
- package/dist/{vue-ui-candlestick-BzqQtynP.js → vue-ui-candlestick-CWqPF_zW.js} +7 -7
- package/dist/{vue-ui-carousel-table-NTDzafWQ.js → vue-ui-carousel-table-BG1ItsAb.js} +4 -4
- package/dist/{vue-ui-chestnut-k21Qqjjq.js → vue-ui-chestnut-6uKesZW9.js} +5 -5
- package/dist/{vue-ui-chord-BVoA6nfI.js → vue-ui-chord-Crd3l1b6.js} +8 -8
- package/dist/{vue-ui-circle-pack-CEBgImRX.js → vue-ui-circle-pack-CAm2gxBi.js} +6 -6
- package/dist/{vue-ui-cursor-BQcz8xw2.js → vue-ui-cursor-CkVnNEGn.js} +2 -2
- package/dist/{vue-ui-dashboard-CyzEpJoI.js → vue-ui-dashboard-D07ivGS7.js} +62 -62
- package/dist/{vue-ui-digits-Dafw1UsT.js → vue-ui-digits-Doidl3Lz.js} +2 -2
- package/dist/{vue-ui-donut-DKfux8XT.js → vue-ui-donut-CWvzqAAa.js} +8 -8
- package/dist/{vue-ui-donut-evolution-D7cNk_6l.js → vue-ui-donut-evolution-Djp_eBqw.js} +8 -8
- package/dist/{vue-ui-dumbbell--H80zebk.js → vue-ui-dumbbell-B7GySnYf.js} +7 -7
- package/dist/{vue-ui-flow-lk_HU5NB.js → vue-ui-flow-XDpZAYWI.js} +7 -7
- package/dist/{vue-ui-funnel-CuN8HWwP.js → vue-ui-funnel-D1pFzjJa.js} +6 -6
- package/dist/{vue-ui-galaxy-BHCLFlmy.js → vue-ui-galaxy-DBQy21se.js} +5 -5
- package/dist/{vue-ui-gauge-DWlCh2_B.js → vue-ui-gauge-FBZaUrBD.js} +6 -6
- package/dist/{vue-ui-gizmo-DHEEfdp9.js → vue-ui-gizmo-CDbPxUzE.js} +3 -3
- package/dist/{vue-ui-heatmap-BK6BNOY_.js → vue-ui-heatmap-DsDWxYOS.js} +7 -7
- package/dist/{vue-ui-history-plot-CGF6lE-7.js → vue-ui-history-plot-CzO1Z1FH.js} +7 -7
- package/dist/{vue-ui-kpi-C4i2w_Yd.js → vue-ui-kpi-DTeZbrJk.js} +3 -3
- package/dist/{vue-ui-mini-loader-BeetGv_m.js → vue-ui-mini-loader-itpDcfZU.js} +2 -2
- package/dist/{vue-ui-molecule-F_gDXjJr.js → vue-ui-molecule-Ddd3FgID.js} +5 -5
- package/dist/{vue-ui-mood-radar-BJMOEqlu.js → vue-ui-mood-radar-24XAq8mg.js} +7 -7
- package/dist/{vue-ui-nested-donuts-BX0Z0rb1.js → vue-ui-nested-donuts-DjWASp62.js} +452 -417
- package/dist/{vue-ui-onion-BhjUET_W.js → vue-ui-onion-B9thdF_c.js} +7 -7
- package/dist/{vue-ui-parallel-coordinate-plot-n7QPVLrW.js → vue-ui-parallel-coordinate-plot-DT-GhOaA.js} +8 -8
- package/dist/{vue-ui-quadrant-DTyRC1_v.js → vue-ui-quadrant-0milmSNS.js} +8 -8
- package/dist/{vue-ui-quick-chart-5xX-yBIY.js → vue-ui-quick-chart-D0DukVN6.js} +6 -6
- package/dist/{vue-ui-radar-De2iznwo.js → vue-ui-radar-DY8y6oRc.js} +7 -7
- package/dist/{vue-ui-rating-CarXXyD-.js → vue-ui-rating-C3QUdrMw.js} +2 -2
- package/dist/{vue-ui-relation-circle-CKkK9D4E.js → vue-ui-relation-circle-8Gd7_fxt.js} +6 -6
- package/dist/{vue-ui-ridgeline-DQ8RQf3E.js → vue-ui-ridgeline-iPtG1McW.js} +8 -8
- package/dist/{vue-ui-rings-Cze6OsmO.js → vue-ui-rings-BXPo4MMo.js} +8 -8
- package/dist/{vue-ui-scatter-CwI3_Dn7.js → vue-ui-scatter-26d0eebx.js} +8 -8
- package/dist/{vue-ui-skeleton-C7maR60-.js → vue-ui-skeleton-P-1SRvsT.js} +3 -3
- package/dist/{vue-ui-smiley-DzCCn5Oc.js → vue-ui-smiley-Cd1bhDuU.js} +2 -2
- package/dist/{vue-ui-spark-trend-Db-Fnp8C.js → vue-ui-spark-trend-Dt3ctzpl.js} +3 -3
- package/dist/{vue-ui-sparkbar-C6wsNMMO.js → vue-ui-sparkbar-RrxErqrU.js} +3 -3
- package/dist/{vue-ui-sparkgauge-DAQ4zozy.js → vue-ui-sparkgauge-CyNi1b0O.js} +3 -3
- package/dist/{vue-ui-sparkhistogram-CMEaO0CW.js → vue-ui-sparkhistogram-DPpZCPuE.js} +4 -4
- package/dist/{vue-ui-sparkline-R7pfxRWN.js → vue-ui-sparkline-BMjQ_uYx.js} +3 -3
- package/dist/{vue-ui-sparkstackbar-DV_XqJQ2.js → vue-ui-sparkstackbar-CjO8pfE-.js} +3 -3
- package/dist/{vue-ui-stackbar-gReSujA_.js → vue-ui-stackbar-wgyvMlE6.js} +9 -9
- package/dist/{vue-ui-strip-plot-8fsm3nn2.js → vue-ui-strip-plot-BF1o8lvY.js} +7 -7
- package/dist/{vue-ui-table-Dck8Pyg9.js → vue-ui-table-B1tjuVi0.js} +3 -3
- package/dist/{vue-ui-table-heatmap-DknIGf9_.js → vue-ui-table-heatmap-BI8eIQG7.js} +5 -5
- package/dist/{vue-ui-table-sparkline-G4HAzUt6.js → vue-ui-table-sparkline-CqBD7xhZ.js} +4 -4
- package/dist/{vue-ui-thermometer-BIkXa4hY.js → vue-ui-thermometer-CtuxuYVt.js} +6 -6
- package/dist/{vue-ui-timer-Dmr-HCSc.js → vue-ui-timer-sgO_Z6ja.js} +5 -5
- package/dist/{vue-ui-tiremarks-YWbRk0dm.js → vue-ui-tiremarks-DOwj4ZE-.js} +6 -6
- package/dist/{vue-ui-treemap-D2OnG3Fh.js → vue-ui-treemap-C4LtyFug.js} +8 -8
- package/dist/{vue-ui-vertical-bar--QFtoFje.js → vue-ui-vertical-bar-BPay31_q.js} +299 -285
- package/dist/{vue-ui-waffle-BdaCXuWc.js → vue-ui-waffle-D8mzGTeo.js} +8 -8
- package/dist/{vue-ui-wheel-Bw3XSa8N.js → vue-ui-wheel-C6uAotal.js} +6 -6
- package/dist/{vue-ui-word-cloud-BH8UZH_J.js → vue-ui-word-cloud-Bge2211V.js} +6 -6
- package/dist/{vue-ui-world-BcK_brDq.js → vue-ui-world-DWskeHfE.js} +6 -6
- package/dist/{vue-ui-xy-Be--zwe9.js → vue-ui-xy-UzQacbnA.js} +63 -61
- package/dist/{vue-ui-xy-canvas--88oKdGN.js → vue-ui-xy-canvas-Dkmsguo1.js} +8 -8
- package/package.json +1 -1
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { defineAsyncComponent as
|
|
2
|
-
import { u as
|
|
1
|
+
import { defineAsyncComponent as R, computed as L, ref as h, watch as ot, onMounted as st, nextTick as ut, shallowRef as nt, onBeforeUnmount as Et, createElementBlock as r, openBlock as n, unref as i, normalizeStyle as ne, normalizeClass as D, createBlock as U, createCommentVNode as w, createVNode as rt, createSlots as Rt, withCtx as x, renderSlot as C, normalizeProps as W, guardReactiveProps as q, createElementVNode as y, Fragment as T, renderList as N, toDisplayString as S, withDirectives as it, vShow as dt, createTextVNode as Ut } from "vue";
|
|
2
|
+
import { u as Gt, c as Yt, t as Xt, p as Te, a as Wt, G as M, o as qt, e as H, b as Ht, d as Jt, m as Ne, f as O, X as Kt, s as Qt, L as ct, k as Ae, n as J, i as Q, x as vt, q as Zt, r as jt, y as el, v as Oe, T as ht } from "./index-Cfm5-hMQ.js";
|
|
3
3
|
import { t as tl, u as ll } from "./useResponsive-DfdjqQps.js";
|
|
4
|
-
import { u as
|
|
5
|
-
import { u as al } from "./usePrinter-
|
|
4
|
+
import { u as ft } from "./useNestedProp-Hh7nGEjp.js";
|
|
5
|
+
import { u as al } from "./usePrinter-B1Hgs47c.js";
|
|
6
6
|
import { u as ol } from "./useUserOptionState-BIvW1Kz7.js";
|
|
7
7
|
import { u as sl } from "./useChartAccessibility-9icAAmYg.js";
|
|
8
|
-
import ul from "./Title-
|
|
9
|
-
import nl from "./Legend-
|
|
10
|
-
import rl from "./img-
|
|
8
|
+
import ul from "./Title-BSlAPr_H.js";
|
|
9
|
+
import nl from "./Legend-DInM-hku.js";
|
|
10
|
+
import rl from "./img-CgMUOQnb.js";
|
|
11
11
|
import { _ as il } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
12
|
-
const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["id"], fl = ["offset", "stop-color"], yl = ["offset", "stop-opacity"], pl = ["id"], bl = ["id"], gl = ["id"], ml = ["flood-color"], wl = ["d", "fill", "stroke", "stroke-width", "filter"],
|
|
12
|
+
const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["id"], fl = ["offset", "stop-color"], yl = ["offset", "stop-opacity"], pl = ["id"], bl = ["id"], gl = ["id"], ml = ["flood-color"], wl = ["id", "d"], $l = ["d", "fill", "stroke", "stroke-width", "filter"], kl = ["d", "fill", "stroke", "stroke-width"], Ll = { key: 1 }, xl = ["d", "fill"], Cl = { key: 2 }, _l = ["font-size", "font-weight", "fill", "dy"], Tl = ["href"], Nl = ["x", "y", "font-size", "font-weight", "fill"], Al = { key: 3 }, Ol = ["filter"], Sl = ["opacity", "text-anchor", "x", "y", "fill", "font-size", "font-weight"], Fl = ["opacity", "text-anchor", "x", "y", "fill", "font-size", "font-weight"], Il = ["text-anchor", "x", "y", "fill", "font-size", "font-weight"], Vl = ["d", "fill", "onMouseenter", "onClick"], Pl = {
|
|
13
13
|
key: 5,
|
|
14
14
|
class: "vue-data-ui-watermark"
|
|
15
|
-
},
|
|
15
|
+
}, zl = {
|
|
16
16
|
key: 0,
|
|
17
17
|
class: "vue-ui-nested-donuts-legend-title"
|
|
18
|
-
},
|
|
18
|
+
}, Dl = ["onClick"], Ml = ["innerHTML"], Bl = {
|
|
19
19
|
__name: "vue-ui-nested-donuts",
|
|
20
20
|
props: {
|
|
21
21
|
config: {
|
|
@@ -32,202 +32,202 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
32
32
|
}
|
|
33
33
|
},
|
|
34
34
|
emits: ["selectLegend", "selectDatapoint"],
|
|
35
|
-
setup(
|
|
36
|
-
const
|
|
35
|
+
setup(yt, { expose: pt, emit: bt }) {
|
|
36
|
+
const gt = R(() => import("./vue-ui-accordion-CEDGlyKI.js")), mt = R(() => import("./DataTable-D36ZRtpU.js")), wt = R(() => import("./PackageVersion-CGQlqnmq.js")), $t = R(() => import("./PenAndPaper-B5slIHlh.js")), kt = R(() => import("./vue-ui-skeleton-P-1SRvsT.js")), Lt = R(() => import("./Tooltip-lPcsweXz.js")), xt = R(() => import("./UserOptions-Dn5TCQxg.js")), { vue_ui_nested_donuts: Ct } = Gt(), _ = yt, Z = L(() => !!_.dataset && _.dataset.length), p = h(Yt()), re = h(!1), ie = h(""), de = h(null), Se = h(0), V = h(null), Fe = h(null), ce = h(null), Ie = h(null), Ve = h(null), Pe = h(0), ze = h(0), De = h(0), B = h(!0), E = h([]), K = h([]), G = h(!1);
|
|
37
37
|
function Me(l) {
|
|
38
|
-
G.value = l,
|
|
38
|
+
G.value = l, Se.value += 1;
|
|
39
39
|
}
|
|
40
|
-
const e =
|
|
40
|
+
const e = L({
|
|
41
41
|
get: () => Re(),
|
|
42
42
|
set: (l) => l
|
|
43
|
-
}), { userOptionsVisible: ve, setUserOptionsVisibility: Be, keepUserOptionState: Ee } = ol({ config: e.value }), { svgRef:
|
|
43
|
+
}), { userOptionsVisible: ve, setUserOptionsVisibility: Be, keepUserOptionState: Ee } = ol({ config: e.value }), { svgRef: j } = sl({
|
|
44
44
|
config: e.value.style.chart.title
|
|
45
45
|
});
|
|
46
46
|
function Re() {
|
|
47
|
-
const l =
|
|
48
|
-
userConfig:
|
|
49
|
-
defaultConfig:
|
|
47
|
+
const l = ft({
|
|
48
|
+
userConfig: _.config,
|
|
49
|
+
defaultConfig: Ct
|
|
50
50
|
});
|
|
51
51
|
return l.theme ? {
|
|
52
|
-
...
|
|
53
|
-
userConfig:
|
|
52
|
+
...ft({
|
|
53
|
+
userConfig: Wt.vue_ui_nested_donuts[l.theme] || _.config,
|
|
54
54
|
defaultConfig: l
|
|
55
55
|
}),
|
|
56
|
-
customPalette:
|
|
56
|
+
customPalette: Xt[l.theme] || Te
|
|
57
57
|
} : l;
|
|
58
58
|
}
|
|
59
59
|
ot(
|
|
60
|
-
() =>
|
|
60
|
+
() => _.config,
|
|
61
61
|
(l) => {
|
|
62
|
-
e.value = Re(), ve.value = !e.value.userOptions.showOnChartHover, he(), Pe.value += 1,
|
|
62
|
+
e.value = Re(), ve.value = !e.value.userOptions.showOnChartHover, he(), Pe.value += 1, ze.value += 1, De.value += 1, k.value.dataLabels.show = e.value.style.chart.layout.labels.dataLabels.show, k.value.showTable = e.value.table.show, k.value.showTooltip = e.value.style.chart.tooltip.show, v.value.width = e.value.style.chart.width, v.value.height = e.value.style.chart.height;
|
|
63
63
|
},
|
|
64
64
|
{ deep: !0 }
|
|
65
65
|
);
|
|
66
|
-
const Ue =
|
|
67
|
-
const { top: l, right: s, bottom:
|
|
66
|
+
const Ue = L(() => {
|
|
67
|
+
const { top: l, right: s, bottom: o, left: a } = e.value.style.chart.padding;
|
|
68
68
|
return {
|
|
69
|
-
css: `padding:${l}px ${s}px ${
|
|
69
|
+
css: `padding:${l}px ${s}px ${o}px ${a}px`,
|
|
70
70
|
top: l,
|
|
71
71
|
right: s,
|
|
72
|
-
bottom:
|
|
73
|
-
left:
|
|
72
|
+
bottom: o,
|
|
73
|
+
left: a
|
|
74
74
|
};
|
|
75
75
|
});
|
|
76
|
-
function
|
|
77
|
-
return new Promise((
|
|
76
|
+
function _t(l, s = 1e3, o = 50) {
|
|
77
|
+
return new Promise((a) => {
|
|
78
78
|
const t = l.length;
|
|
79
|
-
|
|
79
|
+
E.value = Array(t).fill(0), K.value = [];
|
|
80
80
|
let u = 0;
|
|
81
|
-
l.forEach((c,
|
|
81
|
+
l.forEach((c, f) => {
|
|
82
82
|
setTimeout(() => {
|
|
83
|
-
const
|
|
84
|
-
function d(
|
|
85
|
-
const
|
|
86
|
-
|
|
83
|
+
const m = performance.now();
|
|
84
|
+
function d(b) {
|
|
85
|
+
const A = Math.min((b - m) / s, 1), we = ht(A), $e = c * we;
|
|
86
|
+
E.value[f] = $e, E.value = [...E.value];
|
|
87
87
|
const se = [];
|
|
88
88
|
let ke = 0;
|
|
89
|
-
|
|
90
|
-
const
|
|
91
|
-
(
|
|
89
|
+
_.dataset.forEach((ue, Le) => {
|
|
90
|
+
const zt = Oe(ue.series.reduce(
|
|
91
|
+
(Ce, _e) => Ce + Oe(M(_e.values).reduce((Mt, Bt) => Mt + Bt, 0)),
|
|
92
92
|
0
|
|
93
|
-
)), Dt =
|
|
93
|
+
)), Dt = Oe(E.value.slice(ke, ke + ue.series.length).reduce((Ce, _e) => Ce + _e, 0)), xe = zt - Dt;
|
|
94
94
|
xe > Number.MIN_VALUE && se.push({
|
|
95
95
|
name: "__ghost__",
|
|
96
96
|
arcOf: ue.name,
|
|
97
|
-
arcOfId: `${
|
|
98
|
-
id: `ghost_${
|
|
97
|
+
arcOfId: `${p.value}_${Le}`,
|
|
98
|
+
id: `ghost_${p.value}_${Le}`,
|
|
99
99
|
seriesIndex: -1,
|
|
100
|
-
datasetIndex:
|
|
100
|
+
datasetIndex: Le,
|
|
101
101
|
color: "transparent",
|
|
102
102
|
value: xe,
|
|
103
103
|
fullValue: xe,
|
|
104
104
|
absoluteValues: [],
|
|
105
105
|
ghost: !0
|
|
106
106
|
}), ke += ue.series.length;
|
|
107
|
-
}),
|
|
107
|
+
}), K.value = se, A < 1 ? requestAnimationFrame(d) : (u += 1, u === t && a());
|
|
108
108
|
}
|
|
109
109
|
requestAnimationFrame(d);
|
|
110
|
-
},
|
|
110
|
+
}, f * o);
|
|
111
111
|
});
|
|
112
112
|
});
|
|
113
113
|
}
|
|
114
114
|
st(async () => {
|
|
115
115
|
if (he(), e.value.startAnimation?.show) {
|
|
116
|
-
const s =
|
|
117
|
-
(
|
|
116
|
+
const s = _.dataset.flatMap((o) => o.series).map(
|
|
117
|
+
(o) => M(o.values).reduce((a, t) => a + t, 0)
|
|
118
118
|
);
|
|
119
|
-
|
|
120
|
-
const t =
|
|
121
|
-
(u, c) => u +
|
|
119
|
+
E.value = s.map(() => 0), B.value = !0, K.value = _.dataset.map((o, a) => {
|
|
120
|
+
const t = o.series.reduce(
|
|
121
|
+
(u, c) => u + M(c.values).reduce((f, m) => f + m, 0),
|
|
122
122
|
0
|
|
123
123
|
);
|
|
124
124
|
return {
|
|
125
125
|
name: "__ghost__",
|
|
126
|
-
arcOf:
|
|
127
|
-
arcOfId: `${
|
|
128
|
-
id: `ghost_${
|
|
126
|
+
arcOf: o.name,
|
|
127
|
+
arcOfId: `${p.value}_${a}`,
|
|
128
|
+
id: `ghost_${p.value}_${a}`,
|
|
129
129
|
seriesIndex: -1,
|
|
130
|
-
datasetIndex:
|
|
130
|
+
datasetIndex: a,
|
|
131
131
|
color: "transparent",
|
|
132
132
|
value: t,
|
|
133
133
|
fullValue: t,
|
|
134
134
|
absoluteValues: [],
|
|
135
135
|
ghost: !0
|
|
136
136
|
};
|
|
137
|
-
}), await ut(),
|
|
137
|
+
}), await ut(), _t(
|
|
138
138
|
s,
|
|
139
139
|
e.value.startAnimation.durationMs,
|
|
140
140
|
e.value.startAnimation.staggerMs
|
|
141
141
|
).then(() => {
|
|
142
|
-
|
|
142
|
+
B.value = !1, K.value = [];
|
|
143
143
|
});
|
|
144
144
|
} else
|
|
145
|
-
|
|
145
|
+
B.value = !1;
|
|
146
146
|
});
|
|
147
147
|
const P = nt(null), Y = nt(null);
|
|
148
148
|
st(() => {
|
|
149
149
|
he();
|
|
150
150
|
});
|
|
151
151
|
function he() {
|
|
152
|
-
if (
|
|
152
|
+
if (qt(_.dataset) && H({
|
|
153
153
|
componentName: "VueUiNestedDonuts",
|
|
154
154
|
type: "dataset"
|
|
155
155
|
}), e.value.responsive) {
|
|
156
156
|
const l = tl(() => {
|
|
157
|
-
const { width: s, height:
|
|
157
|
+
const { width: s, height: o } = ll({
|
|
158
158
|
chart: V.value,
|
|
159
|
-
title: e.value.style.chart.title.text ?
|
|
159
|
+
title: e.value.style.chart.title.text ? Fe.value : null,
|
|
160
160
|
legend: e.value.style.chart.legend.show ? ce.value : null,
|
|
161
161
|
source: Ie.value,
|
|
162
162
|
noTitle: Ve.value,
|
|
163
163
|
padding: Ue.value
|
|
164
164
|
});
|
|
165
165
|
requestAnimationFrame(() => {
|
|
166
|
-
|
|
166
|
+
v.value.width = s, v.value.height = o;
|
|
167
167
|
});
|
|
168
168
|
});
|
|
169
169
|
P.value && (Y.value && P.value.unobserve(Y.value), P.value.disconnect()), P.value = new ResizeObserver(l), Y.value = V.value.parentNode, P.value.observe(Y.value);
|
|
170
170
|
}
|
|
171
171
|
}
|
|
172
|
-
|
|
172
|
+
Et(() => {
|
|
173
173
|
P.value && (Y.value && P.value.unobserve(Y.value), P.value.disconnect());
|
|
174
174
|
});
|
|
175
175
|
const { isPrinting: Ge, isImaging: Ye, generatePdf: Xe, generateImage: We } = al({
|
|
176
|
-
elementId: `nested_donuts_${
|
|
176
|
+
elementId: `nested_donuts_${p.value}`,
|
|
177
177
|
fileName: e.value.style.chart.title.text || "vue-ui-nested-donuts",
|
|
178
178
|
options: e.value.userOptions.print
|
|
179
|
-
}),
|
|
179
|
+
}), Tt = L(() => e.value.userOptions.show && !e.value.style.chart.title.text), Nt = L(() => Ht(e.value.customPalette)), k = h({
|
|
180
180
|
dataLabels: {
|
|
181
181
|
show: e.value.style.chart.layout.labels.dataLabels.show
|
|
182
182
|
},
|
|
183
183
|
showTable: e.value.table.show,
|
|
184
184
|
showTooltip: e.value.style.chart.tooltip.show
|
|
185
|
-
}),
|
|
185
|
+
}), v = h({
|
|
186
186
|
width: e.value.style.chart.width,
|
|
187
187
|
height: e.value.style.chart.height
|
|
188
|
-
}), qe =
|
|
188
|
+
}), qe = bt;
|
|
189
189
|
function At({ datapoint: l, index: s }) {
|
|
190
190
|
qe("selectDatapoint", { datapoint: l, index: s });
|
|
191
191
|
}
|
|
192
192
|
function He({
|
|
193
193
|
from: l,
|
|
194
194
|
to: s,
|
|
195
|
-
duration:
|
|
196
|
-
onUpdate:
|
|
195
|
+
duration: o,
|
|
196
|
+
onUpdate: a,
|
|
197
197
|
onDone: t,
|
|
198
|
-
easing: u =
|
|
198
|
+
easing: u = ht
|
|
199
199
|
}) {
|
|
200
200
|
const c = performance.now();
|
|
201
|
-
function
|
|
202
|
-
const d = Math.min((
|
|
203
|
-
|
|
201
|
+
function f(m) {
|
|
202
|
+
const d = Math.min((m - c) / o, 1), b = u(d), A = l + (s - l) * b;
|
|
203
|
+
a(A, d), d < 1 ? requestAnimationFrame(f) : (a(s, 1), t && t());
|
|
204
204
|
}
|
|
205
|
-
requestAnimationFrame(
|
|
205
|
+
requestAnimationFrame(f);
|
|
206
206
|
}
|
|
207
|
-
const
|
|
208
|
-
|
|
209
|
-
[null, void 0].includes(s.name) &&
|
|
207
|
+
const $ = h([]), F = L(() => {
|
|
208
|
+
_.dataset.forEach((s, o) => {
|
|
209
|
+
[null, void 0].includes(s.name) && H({
|
|
210
210
|
componentName: "VueUiNestedDonuts",
|
|
211
211
|
type: "datasetSerieAttribute",
|
|
212
212
|
property: "name",
|
|
213
|
-
index:
|
|
214
|
-
}), [null, void 0].includes(s.series) ?
|
|
213
|
+
index: o
|
|
214
|
+
}), [null, void 0].includes(s.series) ? H({
|
|
215
215
|
componentName: "VueUiNestedDonuts",
|
|
216
216
|
type: "datasetSerieAttribute",
|
|
217
217
|
property: "series",
|
|
218
|
-
index:
|
|
219
|
-
}) : s.series.length === 0 ?
|
|
218
|
+
index: o
|
|
219
|
+
}) : s.series.length === 0 ? H({
|
|
220
220
|
componentName: "VueUiNestedDonuts",
|
|
221
221
|
type: "datasetAttributeEmpty",
|
|
222
|
-
property: `series at index ${
|
|
223
|
-
}) : s.series.forEach((
|
|
224
|
-
[null, void 0].includes(
|
|
222
|
+
property: `series at index ${o}`
|
|
223
|
+
}) : s.series.forEach((a, t) => {
|
|
224
|
+
[null, void 0].includes(a.name) && H({
|
|
225
225
|
componentName: "VueUiNestedDonuts",
|
|
226
226
|
type: "datasetSerieAttribute",
|
|
227
227
|
property: "name",
|
|
228
228
|
index: t,
|
|
229
229
|
key: "serie"
|
|
230
|
-
}), [null, void 0].includes(
|
|
230
|
+
}), [null, void 0].includes(a.values) && H({
|
|
231
231
|
componentName: "VueUiNestedDonuts",
|
|
232
232
|
type: "datasetSerieAttribute",
|
|
233
233
|
property: "values",
|
|
@@ -237,42 +237,42 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
237
237
|
});
|
|
238
238
|
});
|
|
239
239
|
let l = 0;
|
|
240
|
-
return
|
|
240
|
+
return _.dataset.map((s, o) => ({
|
|
241
241
|
...s,
|
|
242
|
-
total: s.series.filter((
|
|
243
|
-
datasetIndex:
|
|
244
|
-
id: `${
|
|
245
|
-
series: s.series.map((
|
|
246
|
-
const u =
|
|
242
|
+
total: s.series.filter((a) => !$.value.includes(a.id)).map((a) => M(a.values).reduce((t, u) => t + u, 0)).reduce((a, t) => a + t, 0),
|
|
243
|
+
datasetIndex: o,
|
|
244
|
+
id: `${p.value}_${o}`,
|
|
245
|
+
series: s.series.map((a, t) => {
|
|
246
|
+
const u = M(a.values).reduce((c, f) => c + f, 0);
|
|
247
247
|
return {
|
|
248
|
-
name:
|
|
248
|
+
name: a.name,
|
|
249
249
|
arcOf: s.name,
|
|
250
|
-
arcOfId: `${
|
|
251
|
-
id: `${
|
|
250
|
+
arcOfId: `${p.value}_${o}`,
|
|
251
|
+
id: `${p.value}_${o}_${t}`,
|
|
252
252
|
seriesIndex: t,
|
|
253
|
-
datasetIndex:
|
|
254
|
-
color:
|
|
255
|
-
value:
|
|
256
|
-
absoluteValues:
|
|
253
|
+
datasetIndex: o,
|
|
254
|
+
color: Jt(a.color) || Nt.value[t] || Te[t % Te.length],
|
|
255
|
+
value: B.value ? E.value[l++] ?? 0 : u,
|
|
256
|
+
absoluteValues: a.values || []
|
|
257
257
|
};
|
|
258
258
|
})
|
|
259
259
|
}));
|
|
260
|
-
}), I =
|
|
261
|
-
const
|
|
260
|
+
}), I = L(() => Math.min(v.value.height, v.value.width) * (e.value.style.chart.layout.donut.strokeWidth / 512)), Je = L(() => [...F.value].map((l, s) => {
|
|
261
|
+
const o = l.series.filter((a) => !$.value.includes(a.id)).map((a) => a.value).reduce((a, t) => a + t, 0);
|
|
262
262
|
return {
|
|
263
263
|
...l,
|
|
264
|
-
total:
|
|
265
|
-
series: l.series.filter((
|
|
266
|
-
...
|
|
267
|
-
proportion:
|
|
264
|
+
total: o,
|
|
265
|
+
series: l.series.filter((a) => !$.value.includes(a.id)).map((a) => ({
|
|
266
|
+
...a,
|
|
267
|
+
proportion: a.value / o
|
|
268
268
|
}))
|
|
269
269
|
};
|
|
270
270
|
}));
|
|
271
|
-
function Ot(l, s,
|
|
272
|
-
let
|
|
271
|
+
function Ot(l, s, o) {
|
|
272
|
+
let a = 0;
|
|
273
273
|
for (let t = 0; t < l.length; t += 1)
|
|
274
|
-
|
|
275
|
-
return
|
|
274
|
+
o.includes(l[t]) && (a += 1);
|
|
275
|
+
return a < s;
|
|
276
276
|
}
|
|
277
277
|
const g = h(Je.value);
|
|
278
278
|
ot(
|
|
@@ -281,143 +281,146 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
281
281
|
);
|
|
282
282
|
function fe(l) {
|
|
283
283
|
qe("selectLegend", l);
|
|
284
|
-
const s =
|
|
285
|
-
(d,
|
|
286
|
-
value:
|
|
287
|
-
id: `${
|
|
288
|
-
arcOfId: `${
|
|
284
|
+
const s = _.dataset.flatMap(
|
|
285
|
+
(d, b) => d.series.map((A, we) => ({
|
|
286
|
+
value: M(A.values).reduce(($e, se) => $e + se, 0),
|
|
287
|
+
id: `${p.value}_${b}_${we}`,
|
|
288
|
+
arcOfId: `${p.value}_${b}`
|
|
289
289
|
}))
|
|
290
290
|
).find((d) => d.id === l.id);
|
|
291
291
|
if (!s) return;
|
|
292
|
-
const
|
|
293
|
-
let u =
|
|
294
|
-
const c =
|
|
292
|
+
const o = F.value.flatMap((d) => d.series).find((d) => d.id === l.id)?.value ?? 0, a = g.value.flatMap((d) => d.series).find((d) => d.id === l.id);
|
|
293
|
+
let u = a ? a.value : 0;
|
|
294
|
+
const c = F.value.find(
|
|
295
295
|
(d) => d.id === s.arcOfId
|
|
296
296
|
);
|
|
297
297
|
if (!c) return;
|
|
298
|
-
const
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
298
|
+
const f = c.series.map((d) => d.id), m = Ot(
|
|
299
|
+
f,
|
|
300
|
+
f.length - 1,
|
|
301
|
+
$.value
|
|
302
302
|
);
|
|
303
|
-
|
|
303
|
+
$.value.includes(l.id) ? ($.value = $.value.filter((d) => d !== l.id), e.value.serieToggleAnimation.show ? He({
|
|
304
304
|
from: u,
|
|
305
|
-
to:
|
|
305
|
+
to: o,
|
|
306
306
|
duration: e.value.serieToggleAnimation.durationMs,
|
|
307
307
|
onUpdate: (d) => {
|
|
308
|
-
g.value = g.value.map((
|
|
309
|
-
...
|
|
310
|
-
series:
|
|
308
|
+
g.value = g.value.map((b) => ({
|
|
309
|
+
...b,
|
|
310
|
+
series: b.series.map((A) => A.id === l.id ? { ...A, value: d } : A)
|
|
311
311
|
}));
|
|
312
312
|
}
|
|
313
313
|
}) : g.value = g.value.map((d) => ({
|
|
314
314
|
...d,
|
|
315
|
-
series: d.series.map((
|
|
316
|
-
}))) :
|
|
315
|
+
series: d.series.map((b) => b.id === l.id ? { ...b, value: o } : b)
|
|
316
|
+
}))) : m && (e.value.serieToggleAnimation.show ? He({
|
|
317
317
|
from: u,
|
|
318
318
|
to: 0,
|
|
319
319
|
duration: e.value.serieToggleAnimation.durationMs,
|
|
320
320
|
onUpdate: (d) => {
|
|
321
|
-
g.value = g.value.map((
|
|
322
|
-
...
|
|
323
|
-
series:
|
|
321
|
+
g.value = g.value.map((b) => ({
|
|
322
|
+
...b,
|
|
323
|
+
series: b.series.map((A) => A.id === l.id ? { ...A, value: d } : A)
|
|
324
324
|
}));
|
|
325
325
|
},
|
|
326
326
|
onDone: () => {
|
|
327
|
-
|
|
327
|
+
$.value.push(l.id);
|
|
328
328
|
}
|
|
329
329
|
}) : (g.value = g.value.map((d) => ({
|
|
330
330
|
...d,
|
|
331
|
-
series: d.series.map((
|
|
332
|
-
})),
|
|
331
|
+
series: d.series.map((b) => b.id === l.id ? { ...b, value: 0 } : b)
|
|
332
|
+
})), $.value.push(l.id)));
|
|
333
333
|
}
|
|
334
|
-
const
|
|
335
|
-
const
|
|
336
|
-
...
|
|
337
|
-
value:
|
|
338
|
-
})), c =
|
|
334
|
+
const ee = L(() => I.value / F.value.length * e.value.style.chart.layout.donut.spacingRatio), Ke = L(() => g.value.map((l, s) => I.value - s * I.value / F.value.length)), X = L(() => g.value.map((l, s) => {
|
|
335
|
+
const o = Math.abs(l.series.map((m) => m.value).reduce((m, d) => m + d, 0)) > 0, a = I.value - s * I.value / g.value.length, t = B.value ? K.value.find((m) => m.datasetIndex === s) : null, u = [...l.series, ...t ? [t] : []].map((m) => ({
|
|
336
|
+
...m,
|
|
337
|
+
value: m.value < 1e-11 ? Number.MIN_VALUE : m.value
|
|
338
|
+
})), c = Ne(
|
|
339
339
|
{ series: [
|
|
340
340
|
{ name: "_", color: e.value.style.chart.layout.donut.emptyFill, value: 1 }
|
|
341
341
|
] },
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
342
|
+
v.value.width / 2,
|
|
343
|
+
v.value.height / 2,
|
|
344
|
+
a,
|
|
345
|
+
a,
|
|
346
346
|
1.99999,
|
|
347
347
|
2,
|
|
348
348
|
1,
|
|
349
349
|
360,
|
|
350
350
|
105.25,
|
|
351
|
-
|
|
352
|
-
)
|
|
351
|
+
ee.value
|
|
352
|
+
), f = `M ${v.value.width / 2},${v.value.height / 2 + a}
|
|
353
|
+
a ${a},${a} 0 1,1 0,${-2 * a}
|
|
354
|
+
a ${a},${a} 0 1,1 0,${2 * a}`;
|
|
353
355
|
return {
|
|
354
356
|
...l,
|
|
355
|
-
hasData:
|
|
356
|
-
radius:
|
|
357
|
+
hasData: o,
|
|
358
|
+
radius: a,
|
|
357
359
|
skeleton: c,
|
|
358
|
-
|
|
360
|
+
fullCirclePath: f,
|
|
361
|
+
donut: Ne(
|
|
359
362
|
{ series: u },
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
363
|
+
v.value.width / 2,
|
|
364
|
+
v.value.height / 2,
|
|
365
|
+
a,
|
|
366
|
+
a,
|
|
364
367
|
1.99999,
|
|
365
368
|
2,
|
|
366
369
|
1,
|
|
367
370
|
360,
|
|
368
371
|
105.25,
|
|
369
|
-
|
|
372
|
+
ee.value
|
|
370
373
|
)
|
|
371
374
|
};
|
|
372
|
-
})), Qe =
|
|
373
|
-
const
|
|
375
|
+
})), Qe = L(() => [...F.value].map((l, s) => {
|
|
376
|
+
const o = s * I.value / F.value.length;
|
|
374
377
|
return {
|
|
375
|
-
sizeRatio:
|
|
376
|
-
donut:
|
|
378
|
+
sizeRatio: o,
|
|
379
|
+
donut: Ne(
|
|
377
380
|
{ series: [{ value: 1 }] },
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
I.value -
|
|
381
|
-
I.value -
|
|
381
|
+
v.value.width / 2,
|
|
382
|
+
v.value.height / 2,
|
|
383
|
+
I.value - o,
|
|
384
|
+
I.value - o,
|
|
382
385
|
1.99999,
|
|
383
386
|
2,
|
|
384
387
|
1,
|
|
385
388
|
360,
|
|
386
389
|
105.25,
|
|
387
|
-
I.value /
|
|
390
|
+
I.value / F.value.length * e.value.style.chart.layout.donut.spacingRatio
|
|
388
391
|
)[0]
|
|
389
392
|
};
|
|
390
393
|
})), Ze = h(null), te = h(null), le = h(null), ye = h(null);
|
|
391
|
-
function
|
|
392
|
-
Ze.value = l.arcOfId, te.value = l.id, le.value =
|
|
394
|
+
function St({ datapoint: l, _relativeIndex: s, seriesIndex: o }) {
|
|
395
|
+
Ze.value = l.arcOfId, te.value = l.id, le.value = o, de.value = l.id, ye.value = {
|
|
393
396
|
datapoint: l,
|
|
394
|
-
seriesIndex:
|
|
397
|
+
seriesIndex: o,
|
|
395
398
|
series: g.value,
|
|
396
399
|
config: e.value
|
|
397
400
|
};
|
|
398
|
-
const
|
|
399
|
-
if (
|
|
400
|
-
() =>
|
|
401
|
-
seriesIndex:
|
|
401
|
+
const a = e.value.style.chart.tooltip.customFormat;
|
|
402
|
+
if (vt(a) && el(
|
|
403
|
+
() => a({
|
|
404
|
+
seriesIndex: o,
|
|
402
405
|
datapoint: l,
|
|
403
406
|
series: g.value,
|
|
404
407
|
config: e.value
|
|
405
408
|
})
|
|
406
409
|
))
|
|
407
|
-
ie.value =
|
|
408
|
-
seriesIndex:
|
|
410
|
+
ie.value = a({
|
|
411
|
+
seriesIndex: o,
|
|
409
412
|
datapoint: l,
|
|
410
413
|
series: g.value,
|
|
411
414
|
config: e.value
|
|
412
415
|
});
|
|
413
416
|
else {
|
|
414
417
|
let t = "";
|
|
415
|
-
if (e.value.style.chart.tooltip.showAllItemsAtIndex &&
|
|
416
|
-
const u = g.value.map((c) => c.series.find((
|
|
417
|
-
u.forEach((c,
|
|
418
|
+
if (e.value.style.chart.tooltip.showAllItemsAtIndex && $.value.length === 0) {
|
|
419
|
+
const u = g.value.map((c) => c.series.find((f) => f.seriesIndex === o));
|
|
420
|
+
u.forEach((c, f) => {
|
|
418
421
|
if (!c) return "";
|
|
419
422
|
t += `
|
|
420
|
-
<div style="display:flex; flex-direction: column; justify-content:flex-start; align-items:flex-start;padding:6px 0; ${
|
|
423
|
+
<div style="display:flex; flex-direction: column; justify-content:flex-start; align-items:flex-start;padding:6px 0; ${f < u.length - 1 ? `border-bottom:1px solid ${e.value.style.chart.tooltip.borderColor}` : ""}">
|
|
421
424
|
<div style="display:flex; flex-direction: row; gap: 3px; justify-content:flex-start; align-items:center;">
|
|
422
425
|
<svg viewBox="0 0 20 20" height="${e.value.style.chart.tooltip.fontSize}" width="${e.value.style.chart.tooltip.fontSize}">
|
|
423
426
|
<circle cx="10" cy="10" r="10" fill="${c.color}"/>
|
|
@@ -427,7 +430,7 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
427
430
|
</span>
|
|
428
431
|
</div>
|
|
429
432
|
<span>
|
|
430
|
-
${e.value.style.chart.tooltip.showValue ? `<b>${
|
|
433
|
+
${e.value.style.chart.tooltip.showValue ? `<b>${Q(
|
|
431
434
|
e.value.style.chart.layout.labels.dataLabels.formatter,
|
|
432
435
|
l.value,
|
|
433
436
|
O({
|
|
@@ -436,7 +439,7 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
436
439
|
s: e.value.style.chart.layout.labels.dataLabels.suffix,
|
|
437
440
|
r: e.value.style.chart.tooltip.roundingValue
|
|
438
441
|
}),
|
|
439
|
-
{ datapoint: l, seriesIndex:
|
|
442
|
+
{ datapoint: l, seriesIndex: o }
|
|
440
443
|
)}
|
|
441
444
|
</b>` : ""}
|
|
442
445
|
${e.value.style.chart.tooltip.showPercentage ? `(${O({
|
|
@@ -449,7 +452,7 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
449
452
|
`;
|
|
450
453
|
});
|
|
451
454
|
} else
|
|
452
|
-
t += `<div style="width:100%;text-align:center;border-bottom:1px solid ${e.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${l.arcOf ?? ""} - ${l.name}</div>`, t += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${l.color}"/></svg>`, e.value.style.chart.tooltip.showValue && (t += `<b>${
|
|
455
|
+
t += `<div style="width:100%;text-align:center;border-bottom:1px solid ${e.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${l.arcOf ?? ""} - ${l.name}</div>`, t += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${l.color}"/></svg>`, e.value.style.chart.tooltip.showValue && (t += `<b>${Q(
|
|
453
456
|
e.value.style.chart.layout.labels.dataLabels.formatter,
|
|
454
457
|
l.value,
|
|
455
458
|
O({
|
|
@@ -458,7 +461,7 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
458
461
|
s: e.value.style.chart.layout.labels.dataLabels.suffix,
|
|
459
462
|
r: e.value.style.chart.tooltip.roundingValue
|
|
460
463
|
}),
|
|
461
|
-
{ datapoint: l, seriesIndex:
|
|
464
|
+
{ datapoint: l, seriesIndex: o }
|
|
462
465
|
)}</b>`), e.value.style.chart.tooltip.showPercentage && (e.value.style.chart.tooltip.showValue ? t += `<span>(${O({
|
|
463
466
|
v: l.proportion * 100,
|
|
464
467
|
s: "%",
|
|
@@ -478,85 +481,85 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
478
481
|
function je(l, s) {
|
|
479
482
|
if (!e.value.useBlurOnHover)
|
|
480
483
|
return "";
|
|
481
|
-
if (e.value.style.chart.tooltip.showAllItemsAtIndex &&
|
|
482
|
-
return [null, void 0].includes(le.value) || le.value === s ? "" : `url(#blur_${
|
|
483
|
-
if (!e.value.style.chart.tooltip.showAllItemsAtIndex ||
|
|
484
|
-
return [null, void 0].includes(te.value) || te.value === l.id ? "" : `url(#blur_${
|
|
484
|
+
if (e.value.style.chart.tooltip.showAllItemsAtIndex && $.value.length === 0)
|
|
485
|
+
return [null, void 0].includes(le.value) || le.value === s ? "" : `url(#blur_${p.value})`;
|
|
486
|
+
if (!e.value.style.chart.tooltip.showAllItemsAtIndex || $.value.length)
|
|
487
|
+
return [null, void 0].includes(te.value) || te.value === l.id ? "" : `url(#blur_${p.value})`;
|
|
485
488
|
}
|
|
486
|
-
const be =
|
|
487
|
-
const
|
|
488
|
-
(t) =>
|
|
489
|
-
),
|
|
490
|
-
const u =
|
|
489
|
+
const be = L(() => F.value.map((l, s) => {
|
|
490
|
+
const o = l.series.filter(
|
|
491
|
+
(t) => !$.value.includes(t.id)
|
|
492
|
+
), a = B.value ? o.map((t) => {
|
|
493
|
+
const u = _.dataset[s].series.findIndex(
|
|
491
494
|
(c) => c.name === t.name
|
|
492
495
|
);
|
|
493
|
-
return
|
|
494
|
-
|
|
495
|
-
).reduce((c,
|
|
496
|
-
}).reduce((t, u) => t + u, 0) :
|
|
496
|
+
return M(
|
|
497
|
+
_.dataset[s].series[u].values
|
|
498
|
+
).reduce((c, f) => c + f, 0);
|
|
499
|
+
}).reduce((t, u) => t + u, 0) : o.map((t) => t.value).reduce((t, u) => t + u, 0);
|
|
497
500
|
return l.series.map((t, u) => {
|
|
498
|
-
const c =
|
|
499
|
-
(
|
|
501
|
+
const c = M(_.dataset[s].series[u].values).reduce(
|
|
502
|
+
(m, d) => m + d,
|
|
500
503
|
0
|
|
501
|
-
),
|
|
504
|
+
), f = B.value ? c : t.value;
|
|
502
505
|
return {
|
|
503
506
|
name: t.name,
|
|
504
507
|
color: t.color,
|
|
505
|
-
value:
|
|
508
|
+
value: f,
|
|
506
509
|
shape: "circle",
|
|
507
510
|
arcOf: t.arcOf,
|
|
508
511
|
id: t.id,
|
|
509
512
|
seriesIndex: u,
|
|
510
513
|
datasetIndex: s,
|
|
511
|
-
total:
|
|
512
|
-
opacity:
|
|
514
|
+
total: a,
|
|
515
|
+
opacity: $.value.includes(t.id) ? 0.5 : 1,
|
|
513
516
|
segregate: () => fe(t),
|
|
514
|
-
isSegregated:
|
|
517
|
+
isSegregated: $.value.includes(t.id)
|
|
515
518
|
};
|
|
516
519
|
});
|
|
517
|
-
})),
|
|
520
|
+
})), Ft = L(() => ({
|
|
518
521
|
cy: "nested-donuts-legend",
|
|
519
522
|
backgroundColor: e.value.style.chart.legend.backgroundColor,
|
|
520
523
|
color: e.value.style.chart.legend.color,
|
|
521
524
|
fontSize: e.value.style.chart.legend.fontSize,
|
|
522
525
|
paddingBottom: 12,
|
|
523
526
|
fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
|
|
524
|
-
})),
|
|
525
|
-
const l = g.value.flatMap((
|
|
526
|
-
name: `${
|
|
527
|
-
color:
|
|
528
|
-
total:
|
|
529
|
-
}))), s = g.value.flatMap((
|
|
527
|
+
})), z = L(() => {
|
|
528
|
+
const l = g.value.flatMap((o) => o.series.map((a) => ({
|
|
529
|
+
name: `${o.name} - ${a.name}`,
|
|
530
|
+
color: a.color,
|
|
531
|
+
total: o.total
|
|
532
|
+
}))), s = g.value.flatMap((o) => o.series.map((a) => a.value));
|
|
530
533
|
return { head: l, body: s };
|
|
531
534
|
});
|
|
532
535
|
function et(l = null) {
|
|
533
536
|
ut(() => {
|
|
534
|
-
const s =
|
|
537
|
+
const s = z.value.head.map((t, u) => [
|
|
535
538
|
[t.name],
|
|
536
|
-
[
|
|
539
|
+
[z.value.body[u]],
|
|
537
540
|
[
|
|
538
|
-
isNaN(
|
|
541
|
+
isNaN(z.value.body[u] / t.total) ? "-" : z.value.body[u] / t.total * 100
|
|
539
542
|
]
|
|
540
|
-
]),
|
|
543
|
+
]), o = [
|
|
541
544
|
[e.value.style.chart.title.text],
|
|
542
545
|
[e.value.style.chart.title.subtitle.text],
|
|
543
546
|
[[""], ["val"], ["%"]]
|
|
544
|
-
].concat(s),
|
|
545
|
-
l ? l(
|
|
546
|
-
csvContent:
|
|
547
|
+
].concat(s), a = Zt(o);
|
|
548
|
+
l ? l(a) : jt({
|
|
549
|
+
csvContent: a,
|
|
547
550
|
title: e.value.style.chart.title.text || "vue-ui-nested-donuts"
|
|
548
551
|
});
|
|
549
552
|
});
|
|
550
553
|
}
|
|
551
|
-
const ae =
|
|
554
|
+
const ae = L(() => {
|
|
552
555
|
const l = [
|
|
553
556
|
e.value.table.columnNames.series,
|
|
554
557
|
e.value.table.columnNames.value,
|
|
555
558
|
e.value.table.columnNames.percentage
|
|
556
|
-
], s =
|
|
559
|
+
], s = z.value.head.map((t, u) => {
|
|
557
560
|
const c = O({
|
|
558
561
|
p: e.value.style.chart.layout.labels.dataLabels.prefix,
|
|
559
|
-
v:
|
|
562
|
+
v: z.value.body[u],
|
|
560
563
|
s: e.value.style.chart.layout.labels.dataLabels.suffix,
|
|
561
564
|
r: e.value.table.td.roundingValue
|
|
562
565
|
});
|
|
@@ -566,13 +569,13 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
566
569
|
name: t.name
|
|
567
570
|
},
|
|
568
571
|
c,
|
|
569
|
-
isNaN(
|
|
570
|
-
v:
|
|
572
|
+
isNaN(z.value.body[u] / t.total) ? "-" : O({
|
|
573
|
+
v: z.value.body[u] / t.total * 100,
|
|
571
574
|
s: "%",
|
|
572
575
|
r: e.value.table.td.roundingPercentage
|
|
573
576
|
})
|
|
574
577
|
];
|
|
575
|
-
}),
|
|
578
|
+
}), o = {
|
|
576
579
|
th: {
|
|
577
580
|
backgroundColor: e.value.table.th.backgroundColor,
|
|
578
581
|
color: e.value.table.th.color,
|
|
@@ -593,47 +596,47 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
593
596
|
],
|
|
594
597
|
head: l,
|
|
595
598
|
body: s,
|
|
596
|
-
config:
|
|
599
|
+
config: o
|
|
597
600
|
};
|
|
598
601
|
});
|
|
599
|
-
function
|
|
600
|
-
return
|
|
602
|
+
function It() {
|
|
603
|
+
return F.value;
|
|
601
604
|
}
|
|
602
605
|
function tt() {
|
|
603
|
-
|
|
606
|
+
k.value.showTable = !k.value.showTable;
|
|
604
607
|
}
|
|
605
608
|
function lt() {
|
|
606
|
-
|
|
609
|
+
k.value.dataLabels.show = !k.value.dataLabels.show;
|
|
607
610
|
}
|
|
608
611
|
function at() {
|
|
609
|
-
|
|
612
|
+
k.value.showTooltip = !k.value.showTooltip;
|
|
610
613
|
}
|
|
611
614
|
const oe = h(!1);
|
|
612
615
|
function ge() {
|
|
613
616
|
oe.value = !oe.value;
|
|
614
617
|
}
|
|
615
|
-
async function
|
|
618
|
+
async function Vt({ scale: l = 2 } = {}) {
|
|
616
619
|
if (!V.value) return;
|
|
617
|
-
const { width: s, height:
|
|
620
|
+
const { width: s, height: o } = V.value.getBoundingClientRect(), a = s / o, { imageUri: t, base64: u } = await rl({ domElement: V.value, base64: !0, img: !0, scale: l });
|
|
618
621
|
return {
|
|
619
622
|
imageUri: t,
|
|
620
623
|
base64: u,
|
|
621
624
|
title: e.value.style.chart.title.text,
|
|
622
625
|
width: s,
|
|
623
|
-
height:
|
|
624
|
-
aspectRatio:
|
|
626
|
+
height: o,
|
|
627
|
+
aspectRatio: a
|
|
625
628
|
};
|
|
626
629
|
}
|
|
627
630
|
const me = h(null);
|
|
628
|
-
function
|
|
631
|
+
function Pt() {
|
|
629
632
|
if (!me.value) return;
|
|
630
|
-
const { x: l, y: s, width:
|
|
631
|
-
|
|
633
|
+
const { x: l, y: s, width: o, height: a } = me.value.getBBox();
|
|
634
|
+
j.value && j.value.setAttribute("viewBox", `${l} ${s} ${o + Math.min(0, l)} ${a + Math.min(0, s)}`);
|
|
632
635
|
}
|
|
633
|
-
return
|
|
634
|
-
autoSize:
|
|
635
|
-
getData:
|
|
636
|
-
getImage:
|
|
636
|
+
return pt({
|
|
637
|
+
autoSize: Pt,
|
|
638
|
+
getData: It,
|
|
639
|
+
getImage: Vt,
|
|
637
640
|
generatePdf: Xe,
|
|
638
641
|
generateCsv: et,
|
|
639
642
|
generateImage: We,
|
|
@@ -642,34 +645,34 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
642
645
|
toggleTooltip: at,
|
|
643
646
|
toggleAnnotator: ge,
|
|
644
647
|
toggleFullscreen: Me
|
|
645
|
-
}), (l, s) => (n(),
|
|
648
|
+
}), (l, s) => (n(), r("div", {
|
|
646
649
|
ref_key: "nestedDonutsChart",
|
|
647
650
|
ref: V,
|
|
648
|
-
class:
|
|
651
|
+
class: D(`vue-ui-nested-donuts ${G.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
|
|
649
652
|
style: ne(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;background:${e.value.style.chart.backgroundColor}`),
|
|
650
|
-
id: `nested_donuts_${
|
|
651
|
-
onMouseenter: s[3] || (s[3] = () =>
|
|
652
|
-
onMouseleave: s[4] || (s[4] = () =>
|
|
653
|
+
id: `nested_donuts_${p.value}`,
|
|
654
|
+
onMouseenter: s[3] || (s[3] = () => i(Be)(!0)),
|
|
655
|
+
onMouseleave: s[4] || (s[4] = () => i(Be)(!1))
|
|
653
656
|
}, [
|
|
654
|
-
e.value.userOptions.buttons.annotator ? (n(), U(
|
|
657
|
+
e.value.userOptions.buttons.annotator ? (n(), U(i($t), {
|
|
655
658
|
key: 0,
|
|
656
|
-
svgRef:
|
|
659
|
+
svgRef: i(j),
|
|
657
660
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
658
661
|
color: e.value.style.chart.color,
|
|
659
662
|
active: oe.value,
|
|
660
663
|
onClose: ge
|
|
661
|
-
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) :
|
|
662
|
-
|
|
664
|
+
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : w("", !0),
|
|
665
|
+
Tt.value ? (n(), r("div", {
|
|
663
666
|
key: 1,
|
|
664
667
|
ref_key: "noTitle",
|
|
665
668
|
ref: Ve,
|
|
666
669
|
class: "vue-data-ui-no-title-space",
|
|
667
670
|
style: "height:36px; width: 100%;background:transparent"
|
|
668
|
-
}, null, 512)) :
|
|
669
|
-
e.value.style.chart.title.text ? (n(),
|
|
671
|
+
}, null, 512)) : w("", !0),
|
|
672
|
+
e.value.style.chart.title.text ? (n(), r("div", {
|
|
670
673
|
key: 2,
|
|
671
674
|
ref_key: "chartTitle",
|
|
672
|
-
ref:
|
|
675
|
+
ref: Fe
|
|
673
676
|
}, [
|
|
674
677
|
(n(), U(ul, {
|
|
675
678
|
key: `title_${Pe.value}`,
|
|
@@ -684,15 +687,15 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
684
687
|
}
|
|
685
688
|
}
|
|
686
689
|
}, null, 8, ["config"]))
|
|
687
|
-
], 512)) :
|
|
688
|
-
e.value.userOptions.show &&
|
|
690
|
+
], 512)) : w("", !0),
|
|
691
|
+
e.value.userOptions.show && Z.value && (i(Ee) || i(ve)) ? (n(), U(i(xt), {
|
|
689
692
|
ref: "details",
|
|
690
|
-
key: `user_option_${
|
|
693
|
+
key: `user_option_${Se.value}`,
|
|
691
694
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
692
695
|
color: e.value.style.chart.color,
|
|
693
|
-
isPrinting:
|
|
694
|
-
isImaging:
|
|
695
|
-
uid:
|
|
696
|
+
isPrinting: i(Ge),
|
|
697
|
+
isImaging: i(Ye),
|
|
698
|
+
uid: p.value,
|
|
696
699
|
hasTooltip: e.value.userOptions.buttons.tooltip && e.value.style.chart.tooltip.show,
|
|
697
700
|
hasPdf: e.value.userOptions.buttons.pdf,
|
|
698
701
|
hasXls: e.value.userOptions.buttons.csv,
|
|
@@ -701,7 +704,7 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
701
704
|
hasLabel: e.value.userOptions.buttons.labels,
|
|
702
705
|
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
703
706
|
isFullscreen: G.value,
|
|
704
|
-
isTooltip:
|
|
707
|
+
isTooltip: k.value.showTooltip,
|
|
705
708
|
titles: { ...e.value.userOptions.buttonTitles },
|
|
706
709
|
chartElement: V.value,
|
|
707
710
|
position: e.value.userOptions.position,
|
|
@@ -710,161 +713,161 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
710
713
|
callbacks: e.value.userOptions.callbacks,
|
|
711
714
|
printScale: e.value.userOptions.print.scale,
|
|
712
715
|
onToggleFullscreen: Me,
|
|
713
|
-
onGeneratePdf:
|
|
716
|
+
onGeneratePdf: i(Xe),
|
|
714
717
|
onGenerateCsv: et,
|
|
715
|
-
onGenerateImage:
|
|
718
|
+
onGenerateImage: i(We),
|
|
716
719
|
onToggleTable: tt,
|
|
717
720
|
onToggleLabels: lt,
|
|
718
721
|
onToggleTooltip: at,
|
|
719
722
|
onToggleAnnotator: ge,
|
|
720
723
|
style: ne({
|
|
721
|
-
visibility:
|
|
724
|
+
visibility: i(Ee) ? i(ve) ? "visible" : "hidden" : "visible"
|
|
722
725
|
})
|
|
723
|
-
},
|
|
726
|
+
}, Rt({ _: 2 }, [
|
|
724
727
|
l.$slots.menuIcon ? {
|
|
725
728
|
name: "menuIcon",
|
|
726
|
-
fn:
|
|
727
|
-
|
|
729
|
+
fn: x(({ isOpen: o, color: a }) => [
|
|
730
|
+
C(l.$slots, "menuIcon", W(q({ isOpen: o, color: a })), void 0, !0)
|
|
728
731
|
]),
|
|
729
732
|
key: "0"
|
|
730
733
|
} : void 0,
|
|
731
734
|
l.$slots.optionTooltip ? {
|
|
732
735
|
name: "optionTooltip",
|
|
733
|
-
fn:
|
|
734
|
-
|
|
736
|
+
fn: x(() => [
|
|
737
|
+
C(l.$slots, "optionTooltip", {}, void 0, !0)
|
|
735
738
|
]),
|
|
736
739
|
key: "1"
|
|
737
740
|
} : void 0,
|
|
738
741
|
l.$slots.optionPdf ? {
|
|
739
742
|
name: "optionPdf",
|
|
740
|
-
fn:
|
|
741
|
-
|
|
743
|
+
fn: x(() => [
|
|
744
|
+
C(l.$slots, "optionPdf", {}, void 0, !0)
|
|
742
745
|
]),
|
|
743
746
|
key: "2"
|
|
744
747
|
} : void 0,
|
|
745
748
|
l.$slots.optionCsv ? {
|
|
746
749
|
name: "optionCsv",
|
|
747
|
-
fn:
|
|
748
|
-
|
|
750
|
+
fn: x(() => [
|
|
751
|
+
C(l.$slots, "optionCsv", {}, void 0, !0)
|
|
749
752
|
]),
|
|
750
753
|
key: "3"
|
|
751
754
|
} : void 0,
|
|
752
755
|
l.$slots.optionImg ? {
|
|
753
756
|
name: "optionImg",
|
|
754
|
-
fn:
|
|
755
|
-
|
|
757
|
+
fn: x(() => [
|
|
758
|
+
C(l.$slots, "optionImg", {}, void 0, !0)
|
|
756
759
|
]),
|
|
757
760
|
key: "4"
|
|
758
761
|
} : void 0,
|
|
759
762
|
l.$slots.optionTable ? {
|
|
760
763
|
name: "optionTable",
|
|
761
|
-
fn:
|
|
762
|
-
|
|
764
|
+
fn: x(() => [
|
|
765
|
+
C(l.$slots, "optionTable", {}, void 0, !0)
|
|
763
766
|
]),
|
|
764
767
|
key: "5"
|
|
765
768
|
} : void 0,
|
|
766
769
|
l.$slots.optionLabels ? {
|
|
767
770
|
name: "optionLabels",
|
|
768
|
-
fn:
|
|
769
|
-
|
|
771
|
+
fn: x(() => [
|
|
772
|
+
C(l.$slots, "optionLabels", {}, void 0, !0)
|
|
770
773
|
]),
|
|
771
774
|
key: "6"
|
|
772
775
|
} : void 0,
|
|
773
776
|
l.$slots.optionFullscreen ? {
|
|
774
777
|
name: "optionFullscreen",
|
|
775
|
-
fn:
|
|
776
|
-
|
|
778
|
+
fn: x(({ toggleFullscreen: o, isFullscreen: a }) => [
|
|
779
|
+
C(l.$slots, "optionFullscreen", W(q({ toggleFullscreen: o, isFullscreen: a })), void 0, !0)
|
|
777
780
|
]),
|
|
778
781
|
key: "7"
|
|
779
782
|
} : void 0,
|
|
780
783
|
l.$slots.optionAnnotator ? {
|
|
781
784
|
name: "optionAnnotator",
|
|
782
|
-
fn:
|
|
783
|
-
|
|
785
|
+
fn: x(({ toggleAnnotator: o, isAnnotator: a }) => [
|
|
786
|
+
C(l.$slots, "optionAnnotator", W(q({ toggleAnnotator: o, isAnnotator: a })), void 0, !0)
|
|
784
787
|
]),
|
|
785
788
|
key: "8"
|
|
786
789
|
} : void 0
|
|
787
|
-
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasTable", "hasLabel", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) :
|
|
788
|
-
|
|
790
|
+
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasTable", "hasLabel", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : w("", !0),
|
|
791
|
+
Z.value ? (n(), r("svg", {
|
|
789
792
|
key: 4,
|
|
790
793
|
ref_key: "svgRef",
|
|
791
|
-
ref:
|
|
792
|
-
xmlns:
|
|
793
|
-
class:
|
|
794
|
+
ref: j,
|
|
795
|
+
xmlns: i(Kt),
|
|
796
|
+
class: D({
|
|
794
797
|
"vue-data-ui-fullscreen--on": G.value,
|
|
795
798
|
"vue-data-ui-fulscreen--off": !G.value,
|
|
796
799
|
"vue-data-ui-svg": !0
|
|
797
800
|
}),
|
|
798
|
-
viewBox: `0 0 ${
|
|
801
|
+
viewBox: `0 0 ${v.value.width <= 0 ? 1e-3 : v.value.width} ${v.value.height < 0 ? 1e-3 : v.value.height}`,
|
|
799
802
|
style: ne(`max-width:100%; overflow: visible; background:transparent;color:${e.value.style.chart.color};${Ue.value.css}`)
|
|
800
803
|
}, [
|
|
801
|
-
|
|
804
|
+
y("g", {
|
|
802
805
|
ref_key: "G",
|
|
803
806
|
ref: me,
|
|
804
807
|
class: "vue-data-ui-g"
|
|
805
808
|
}, [
|
|
806
|
-
rt(
|
|
807
|
-
l.$slots["chart-background"] ? (n(),
|
|
809
|
+
rt(i(wt)),
|
|
810
|
+
l.$slots["chart-background"] ? (n(), r("foreignObject", {
|
|
808
811
|
key: 0,
|
|
809
812
|
x: 0,
|
|
810
813
|
y: 0,
|
|
811
|
-
width:
|
|
812
|
-
height:
|
|
814
|
+
width: v.value.width <= 0 ? 1e-3 : v.value.width,
|
|
815
|
+
height: v.value.height < 0 ? 1e-3 : v.value.height,
|
|
813
816
|
style: {
|
|
814
817
|
pointerEvents: "none"
|
|
815
818
|
}
|
|
816
819
|
}, [
|
|
817
|
-
|
|
818
|
-
], 8, vl)) :
|
|
819
|
-
|
|
820
|
-
(n(!0),
|
|
821
|
-
id: `radial_${
|
|
820
|
+
C(l.$slots, "chart-background", {}, void 0, !0)
|
|
821
|
+
], 8, vl)) : w("", !0),
|
|
822
|
+
y("defs", null, [
|
|
823
|
+
(n(!0), r(T, null, N(Qe.value, (o, a) => (n(), r("radialGradient", {
|
|
824
|
+
id: `radial_${p.value}_${a}`
|
|
822
825
|
}, [
|
|
823
|
-
s[5] || (s[5] =
|
|
826
|
+
s[5] || (s[5] = y("stop", {
|
|
824
827
|
offset: "0%",
|
|
825
828
|
"stop-color": "#FFFFFF",
|
|
826
829
|
"stop-opacity": "0"
|
|
827
830
|
}, null, -1)),
|
|
828
|
-
|
|
829
|
-
offset: `${(1 -
|
|
830
|
-
"stop-color":
|
|
831
|
+
y("stop", {
|
|
832
|
+
offset: `${(1 - ee.value / Ke.value[a]) * 100}%`,
|
|
833
|
+
"stop-color": i(Qt)("#FFFFFF", 0),
|
|
831
834
|
"stop-opacity": "0"
|
|
832
835
|
}, null, 8, fl),
|
|
833
|
-
|
|
834
|
-
offset: `${(1 -
|
|
836
|
+
y("stop", {
|
|
837
|
+
offset: `${(1 - ee.value / Ke.value[a] / 2) * 100}%`,
|
|
835
838
|
"stop-color": "#FFFFFF",
|
|
836
839
|
"stop-opacity": e.value.style.chart.gradientIntensity / 100
|
|
837
840
|
}, null, 8, yl),
|
|
838
|
-
s[6] || (s[6] =
|
|
841
|
+
s[6] || (s[6] = y("stop", {
|
|
839
842
|
offset: "100%",
|
|
840
843
|
"stop-color": "#FFFFFF",
|
|
841
844
|
"stop-opacity": "0"
|
|
842
845
|
}, null, -1))
|
|
843
846
|
], 8, hl))), 256))
|
|
844
847
|
]),
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
id: `blur_${
|
|
848
|
+
y("defs", null, [
|
|
849
|
+
y("filter", {
|
|
850
|
+
id: `blur_${p.value}`,
|
|
848
851
|
x: "-50%",
|
|
849
852
|
y: "-50%",
|
|
850
853
|
width: "200%",
|
|
851
854
|
height: "200%"
|
|
852
855
|
}, [
|
|
853
|
-
|
|
856
|
+
y("feGaussianBlur", {
|
|
854
857
|
in: "SourceGraphic",
|
|
855
858
|
stdDeviation: 2,
|
|
856
|
-
id: `blur_std_${
|
|
859
|
+
id: `blur_std_${p.value}`
|
|
857
860
|
}, null, 8, bl),
|
|
858
|
-
s[7] || (s[7] =
|
|
861
|
+
s[7] || (s[7] = y("feColorMatrix", {
|
|
859
862
|
type: "saturate",
|
|
860
863
|
values: "0"
|
|
861
864
|
}, null, -1))
|
|
862
865
|
], 8, pl),
|
|
863
|
-
|
|
864
|
-
id: `shadow_${
|
|
866
|
+
y("filter", {
|
|
867
|
+
id: `shadow_${p.value}`,
|
|
865
868
|
"color-interpolation-filters": "sRGB"
|
|
866
869
|
}, [
|
|
867
|
-
|
|
870
|
+
y("feDropShadow", {
|
|
868
871
|
dx: "0",
|
|
869
872
|
dy: "0",
|
|
870
873
|
stdDeviation: "10",
|
|
@@ -873,70 +876,102 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
873
876
|
}, null, 8, ml)
|
|
874
877
|
], 8, gl)
|
|
875
878
|
]),
|
|
876
|
-
(
|
|
877
|
-
|
|
878
|
-
|
|
879
|
+
y("defs", null, [
|
|
880
|
+
(n(!0), r(T, null, N(X.value, (o, a) => (n(), r("path", {
|
|
881
|
+
key: `path-full-${a}`,
|
|
882
|
+
id: `path-full-${a}-${p.value}`,
|
|
883
|
+
d: o.fullCirclePath,
|
|
884
|
+
fill: "none"
|
|
885
|
+
}, null, 8, wl))), 128))
|
|
886
|
+
]),
|
|
887
|
+
(n(!0), r(T, null, N(X.value, (o, a) => (n(), r("g", null, [
|
|
888
|
+
o.hasData ? (n(!0), r(T, { key: 0 }, N(o.donut.filter((t) => !t.ghost), (t, u) => (n(), r("g", null, [
|
|
889
|
+
y("path", {
|
|
879
890
|
class: "vue-ui-donut-arc-path",
|
|
880
891
|
d: t.arcSlice,
|
|
881
892
|
fill: t.color,
|
|
882
893
|
stroke: e.value.style.chart.layout.donut.borderColorAuto ? e.value.style.chart.backgroundColor : e.value.style.chart.layout.donut.borderColor,
|
|
883
894
|
"stroke-width": e.value.style.chart.layout.donut.borderWidth,
|
|
884
895
|
filter: je(t, u)
|
|
885
|
-
}, null, 8,
|
|
886
|
-
]))), 256)) : (n(!0),
|
|
887
|
-
|
|
896
|
+
}, null, 8, $l)
|
|
897
|
+
]))), 256)) : (n(!0), r(T, { key: 1 }, N(o.skeleton, (t, u) => (n(), r("g", null, [
|
|
898
|
+
y("path", {
|
|
888
899
|
class: "vue-ui-donut-arc-path",
|
|
889
900
|
d: t.arcSlice,
|
|
890
901
|
fill: t.color,
|
|
891
902
|
stroke: e.value.style.chart.layout.donut.borderColorAuto ? e.value.style.chart.backgroundColor : e.value.style.chart.layout.donut.borderColor,
|
|
892
903
|
"stroke-width": e.value.style.chart.layout.donut.borderWidth
|
|
893
|
-
}, null, 8,
|
|
904
|
+
}, null, 8, kl)
|
|
894
905
|
]))), 256))
|
|
895
906
|
]))), 256)),
|
|
896
|
-
e.value.style.chart.useGradient ? (n(),
|
|
897
|
-
(n(!0),
|
|
898
|
-
|
|
899
|
-
d:
|
|
900
|
-
fill: `url(#radial_${
|
|
907
|
+
e.value.style.chart.useGradient ? (n(), r("g", Ll, [
|
|
908
|
+
(n(!0), r(T, null, N(Qe.value, (o, a) => (n(), r("g", null, [
|
|
909
|
+
y("path", {
|
|
910
|
+
d: o.donut.arcSlice,
|
|
911
|
+
fill: `url(#radial_${p.value}_${a})`,
|
|
901
912
|
stroke: "transparent",
|
|
902
913
|
"stroke-width": "0"
|
|
903
|
-
}, null, 8,
|
|
914
|
+
}, null, 8, xl)
|
|
904
915
|
]))), 256))
|
|
905
|
-
])) :
|
|
906
|
-
e.value.style.chart.layout.labels.dataLabels.showDonutName ? (n(),
|
|
907
|
-
(n(!0),
|
|
908
|
-
(n(!0),
|
|
909
|
-
u === 0 &&
|
|
916
|
+
])) : w("", !0),
|
|
917
|
+
e.value.style.chart.layout.labels.dataLabels.showDonutName ? (n(), r("g", Cl, [
|
|
918
|
+
e.value.style.chart.layout.labels.dataLabels.curvedDonutName ? (n(!0), r(T, { key: 0 }, N(X.value, (o, a) => (n(), r("g", null, [
|
|
919
|
+
(n(!0), r(T, null, N(o.donut, (t, u) => (n(), r("g", null, [
|
|
920
|
+
u === 0 && v.value.width && v.value.height ? (n(), r("text", {
|
|
921
|
+
key: 0,
|
|
922
|
+
class: D({ animated: e.value.useCssAnimation }),
|
|
923
|
+
"text-anchor": "middle",
|
|
924
|
+
"font-size": e.value.style.chart.layout.labels.dataLabels.fontSize,
|
|
925
|
+
"font-weight": e.value.style.chart.layout.labels.dataLabels.boldDonutName ? "bold" : "normal",
|
|
926
|
+
fill: e.value.style.chart.layout.labels.dataLabels.color,
|
|
927
|
+
dy: e.value.style.chart.layout.labels.dataLabels.donutNameOffsetY
|
|
928
|
+
}, [
|
|
929
|
+
y("textPath", {
|
|
930
|
+
href: `#path-full-${a}-${p.value}`,
|
|
931
|
+
startOffset: "50%",
|
|
932
|
+
"text-anchor": "middle",
|
|
933
|
+
method: "align",
|
|
934
|
+
spacing: "auto",
|
|
935
|
+
side: "right"
|
|
936
|
+
}, S(e.value.style.chart.layout.labels.dataLabels.donutNameAbbreviation ? i(ct)({
|
|
937
|
+
source: o.name,
|
|
938
|
+
length: e.value.style.chart.layout.labels.dataLabels.donutNameMaxAbbreviationSize
|
|
939
|
+
}) : o.name), 9, Tl)
|
|
940
|
+
], 10, _l)) : w("", !0)
|
|
941
|
+
]))), 256))
|
|
942
|
+
]))), 256)) : (n(!0), r(T, { key: 1 }, N(X.value, (o, a) => (n(), r("g", null, [
|
|
943
|
+
(n(!0), r(T, null, N(o.donut, (t, u) => (n(), r("g", null, [
|
|
944
|
+
u === 0 && v.value.width && v.value.height ? (n(), r("text", {
|
|
910
945
|
key: 0,
|
|
911
|
-
class:
|
|
912
|
-
x:
|
|
946
|
+
class: D({ animated: e.value.useCssAnimation }),
|
|
947
|
+
x: v.value.width / 2,
|
|
913
948
|
y: t.startY - e.value.style.chart.layout.labels.dataLabels.fontSize + e.value.style.chart.layout.labels.dataLabels.donutNameOffsetY,
|
|
914
949
|
"text-anchor": "middle",
|
|
915
950
|
"font-size": e.value.style.chart.layout.labels.dataLabels.fontSize,
|
|
916
951
|
"font-weight": e.value.style.chart.layout.labels.dataLabels.boldDonutName ? "bold" : "normal",
|
|
917
952
|
fill: e.value.style.chart.layout.labels.dataLabels.color
|
|
918
|
-
}, S(e.value.style.chart.layout.labels.dataLabels.donutNameAbbreviation ?
|
|
919
|
-
source:
|
|
953
|
+
}, S(e.value.style.chart.layout.labels.dataLabels.donutNameAbbreviation ? i(ct)({
|
|
954
|
+
source: o.name,
|
|
920
955
|
length: e.value.style.chart.layout.labels.dataLabels.donutNameMaxAbbreviationSize
|
|
921
|
-
}) :
|
|
956
|
+
}) : o.name), 11, Nl)) : w("", !0)
|
|
922
957
|
]))), 256))
|
|
923
958
|
]))), 256))
|
|
924
|
-
])) :
|
|
925
|
-
e.value.style.chart.layout.labels.dataLabels.show ? (n(),
|
|
926
|
-
(n(!0),
|
|
927
|
-
(n(!0),
|
|
959
|
+
])) : w("", !0),
|
|
960
|
+
e.value.style.chart.layout.labels.dataLabels.show ? (n(), r("g", Al, [
|
|
961
|
+
(n(!0), r(T, null, N(X.value, (o, a) => (n(), r("g", null, [
|
|
962
|
+
(n(!0), r(T, null, N(o.donut.filter((t) => !t.ghost), (t, u) => (n(), r("g", {
|
|
928
963
|
filter: je(t, u)
|
|
929
964
|
}, [
|
|
930
|
-
it(
|
|
931
|
-
class:
|
|
965
|
+
it(y("text", {
|
|
966
|
+
class: D({ animated: e.value.useCssAnimation }),
|
|
932
967
|
opacity: pe(t) ? 1 : 0,
|
|
933
|
-
"text-anchor":
|
|
934
|
-
x:
|
|
968
|
+
"text-anchor": i(J)(t, !0).anchor,
|
|
969
|
+
x: i(J)(
|
|
935
970
|
t,
|
|
936
971
|
!1,
|
|
937
972
|
e.value.style.chart.layout.labels.dataLabels.offsetX
|
|
938
973
|
).x || 0,
|
|
939
|
-
y:
|
|
974
|
+
y: i(Ae)(
|
|
940
975
|
t,
|
|
941
976
|
e.value.style.chart.layout.labels.dataLabels.offsetY,
|
|
942
977
|
e.value.style.chart.layout.labels.dataLabels.offsetY
|
|
@@ -944,26 +979,26 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
944
979
|
fill: e.value.style.chart.layout.labels.dataLabels.useSerieColor ? t.color : e.value.style.chart.layout.labels.dataLabels.color,
|
|
945
980
|
"font-size": e.value.style.chart.layout.labels.dataLabels.fontSize,
|
|
946
981
|
"font-weight": e.value.style.chart.layout.labels.dataLabels.boldPercentage ? "bold" : "normal"
|
|
947
|
-
}, S(
|
|
982
|
+
}, S(i(O)({
|
|
948
983
|
v: t.proportion * 100,
|
|
949
984
|
s: "%",
|
|
950
985
|
r: e.value.style.chart.layout.labels.dataLabels.roundingPercentage
|
|
951
|
-
})), 11,
|
|
986
|
+
})), 11, Sl), [
|
|
952
987
|
[
|
|
953
988
|
dt,
|
|
954
|
-
|
|
989
|
+
k.value.dataLabels.show && e.value.style.chart.layout.labels.dataLabels.showPercentage
|
|
955
990
|
]
|
|
956
991
|
]),
|
|
957
|
-
it(
|
|
958
|
-
class:
|
|
992
|
+
it(y("text", {
|
|
993
|
+
class: D({ animated: e.value.useCssAnimation }),
|
|
959
994
|
opacity: pe(t) ? 1 : 0,
|
|
960
|
-
"text-anchor":
|
|
961
|
-
x:
|
|
995
|
+
"text-anchor": i(J)(t, !0).anchor,
|
|
996
|
+
x: i(J)(
|
|
962
997
|
t,
|
|
963
998
|
!1,
|
|
964
999
|
e.value.style.chart.layout.labels.dataLabels.offsetX
|
|
965
1000
|
).x || 0,
|
|
966
|
-
y:
|
|
1001
|
+
y: i(Ae)(
|
|
967
1002
|
t,
|
|
968
1003
|
e.value.style.chart.layout.labels.dataLabels.offsetY,
|
|
969
1004
|
e.value.style.chart.layout.labels.dataLabels.offsetY
|
|
@@ -971,32 +1006,32 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
971
1006
|
fill: e.value.style.chart.layout.labels.dataLabels.useSerieColor ? t.color : e.value.style.chart.layout.labels.dataLabels.color,
|
|
972
1007
|
"font-size": e.value.style.chart.layout.labels.dataLabels.fontSize,
|
|
973
1008
|
"font-weight": e.value.style.chart.layout.labels.dataLabels.boldValue ? "bold" : "normal"
|
|
974
|
-
}, " (" + S(
|
|
1009
|
+
}, " (" + S(i(Q)(
|
|
975
1010
|
e.value.style.chart.layout.labels.dataLabels.formatter,
|
|
976
1011
|
t.value,
|
|
977
|
-
|
|
1012
|
+
i(O)({
|
|
978
1013
|
p: e.value.style.chart.layout.labels.dataLabels.prefix,
|
|
979
1014
|
v: t.value,
|
|
980
1015
|
s: e.value.style.chart.layout.labels.dataLabels.suffix,
|
|
981
1016
|
r: e.value.style.chart.layout.labels.dataLabels.roundingValue
|
|
982
1017
|
}),
|
|
983
|
-
{ datapoint: t, seriesIndex:
|
|
984
|
-
)) + ") ", 11,
|
|
1018
|
+
{ datapoint: t, seriesIndex: a, datapointIndex: u }
|
|
1019
|
+
)) + ") ", 11, Fl), [
|
|
985
1020
|
[
|
|
986
1021
|
dt,
|
|
987
|
-
|
|
1022
|
+
k.value.dataLabels.show && e.value.style.chart.layout.labels.dataLabels.showPercentage && e.value.style.chart.layout.labels.dataLabels.showValue
|
|
988
1023
|
]
|
|
989
1024
|
]),
|
|
990
|
-
pe(t) &&
|
|
1025
|
+
pe(t) && k.value.dataLabels.show && !e.value.style.chart.layout.labels.dataLabels.showPercentage && e.value.style.chart.layout.labels.dataLabels.showValue ? (n(), r("text", {
|
|
991
1026
|
key: 0,
|
|
992
|
-
class:
|
|
993
|
-
"text-anchor":
|
|
994
|
-
x:
|
|
1027
|
+
class: D({ animated: e.value.useCssAnimation }),
|
|
1028
|
+
"text-anchor": i(J)(t, !0).anchor,
|
|
1029
|
+
x: i(J)(
|
|
995
1030
|
t,
|
|
996
1031
|
!1,
|
|
997
1032
|
e.value.style.chart.layout.labels.dataLabels.offsetX
|
|
998
1033
|
).x || 0,
|
|
999
|
-
y:
|
|
1034
|
+
y: i(Ae)(
|
|
1000
1035
|
t,
|
|
1001
1036
|
e.value.style.chart.layout.labels.dataLabels.offsetY,
|
|
1002
1037
|
e.value.style.chart.layout.labels.dataLabels.offsetY
|
|
@@ -1004,26 +1039,26 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
1004
1039
|
fill: e.value.style.chart.layout.labels.dataLabels.useSerieColor ? t.color : e.value.style.chart.layout.labels.dataLabels.color,
|
|
1005
1040
|
"font-size": e.value.style.chart.layout.labels.dataLabels.fontSize,
|
|
1006
1041
|
"font-weight": e.value.style.chart.layout.labels.dataLabels.boldValue ? "bold" : "normal"
|
|
1007
|
-
}, S(
|
|
1042
|
+
}, S(i(Q)(
|
|
1008
1043
|
e.value.style.chart.layout.labels.dataLabels.formatter,
|
|
1009
1044
|
t.value,
|
|
1010
|
-
|
|
1045
|
+
i(O)({
|
|
1011
1046
|
p: e.value.style.chart.layout.labels.dataLabels.prefix,
|
|
1012
1047
|
v: t.value,
|
|
1013
1048
|
s: e.value.style.chart.layout.labels.dataLabels.suffix,
|
|
1014
1049
|
r: e.value.style.chart.layout.labels.dataLabels.roundingValue
|
|
1015
1050
|
}),
|
|
1016
|
-
{ datapoint: t, seriesIndex:
|
|
1017
|
-
)), 11,
|
|
1018
|
-
], 8,
|
|
1051
|
+
{ datapoint: t, seriesIndex: a, datapointIndex: u }
|
|
1052
|
+
)), 11, Il)) : w("", !0)
|
|
1053
|
+
], 8, Ol))), 256))
|
|
1019
1054
|
]))), 256))
|
|
1020
|
-
])) :
|
|
1021
|
-
(n(!0),
|
|
1022
|
-
(n(!0),
|
|
1023
|
-
|
|
1055
|
+
])) : w("", !0),
|
|
1056
|
+
(n(!0), r(T, null, N(X.value, (o, a) => (n(), r("g", null, [
|
|
1057
|
+
(n(!0), r(T, null, N(o.donut, (t, u) => (n(), r("g", null, [
|
|
1058
|
+
y("path", {
|
|
1024
1059
|
d: t.arcSlice,
|
|
1025
1060
|
fill: de.value === t.id ? e.value.style.chart.layout.donut.selectedColor : "transparent",
|
|
1026
|
-
onMouseenter: (c) =>
|
|
1061
|
+
onMouseenter: (c) => St({
|
|
1027
1062
|
datapoint: t,
|
|
1028
1063
|
seriesIndex: t.seriesIndex
|
|
1029
1064
|
}),
|
|
@@ -1031,16 +1066,16 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
1031
1066
|
onMouseleave: s[0] || (s[0] = (c) => {
|
|
1032
1067
|
re.value = !1, Ze.value = null, te.value = null, le.value = null, de.value = null;
|
|
1033
1068
|
})
|
|
1034
|
-
}, null, 40,
|
|
1069
|
+
}, null, 40, Vl)
|
|
1035
1070
|
]))), 256))
|
|
1036
1071
|
]))), 256)),
|
|
1037
|
-
|
|
1072
|
+
C(l.$slots, "svg", { svg: v.value }, void 0, !0)
|
|
1038
1073
|
], 512)
|
|
1039
|
-
], 14, cl)) :
|
|
1040
|
-
l.$slots.watermark ? (n(),
|
|
1041
|
-
|
|
1042
|
-
])) :
|
|
1043
|
-
|
|
1074
|
+
], 14, cl)) : w("", !0),
|
|
1075
|
+
l.$slots.watermark ? (n(), r("div", Pl, [
|
|
1076
|
+
C(l.$slots, "watermark", W(q({ isPrinting: i(Ge) || i(Ye) })), void 0, !0)
|
|
1077
|
+
])) : w("", !0),
|
|
1078
|
+
Z.value ? w("", !0) : (n(), U(i(kt), {
|
|
1044
1079
|
key: 6,
|
|
1045
1080
|
config: {
|
|
1046
1081
|
type: "donut",
|
|
@@ -1052,8 +1087,8 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
1052
1087
|
}
|
|
1053
1088
|
}
|
|
1054
1089
|
}, null, 8, ["config"])),
|
|
1055
|
-
rt(
|
|
1056
|
-
show:
|
|
1090
|
+
rt(i(Lt), {
|
|
1091
|
+
show: k.value.showTooltip && re.value,
|
|
1057
1092
|
backgroundColor: e.value.style.chart.tooltip.backgroundColor,
|
|
1058
1093
|
color: e.value.style.chart.tooltip.color,
|
|
1059
1094
|
borderRadius: e.value.style.chart.tooltip.borderRadius,
|
|
@@ -1066,74 +1101,74 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
1066
1101
|
parent: V.value,
|
|
1067
1102
|
content: ie.value,
|
|
1068
1103
|
isFullscreen: G.value,
|
|
1069
|
-
isCustom:
|
|
1104
|
+
isCustom: i(vt)(e.value.style.chart.tooltip.customFormat)
|
|
1070
1105
|
}, {
|
|
1071
|
-
"tooltip-before":
|
|
1072
|
-
|
|
1106
|
+
"tooltip-before": x(() => [
|
|
1107
|
+
C(l.$slots, "tooltip-before", W(q({ ...ye.value })), void 0, !0)
|
|
1073
1108
|
]),
|
|
1074
|
-
"tooltip-after":
|
|
1075
|
-
|
|
1109
|
+
"tooltip-after": x(() => [
|
|
1110
|
+
C(l.$slots, "tooltip-after", W(q({ ...ye.value })), void 0, !0)
|
|
1076
1111
|
]),
|
|
1077
1112
|
_: 3
|
|
1078
1113
|
}, 8, ["show", "backgroundColor", "color", "borderRadius", "borderColor", "borderWidth", "fontSize", "backgroundOpacity", "position", "offsetY", "parent", "content", "isFullscreen", "isCustom"]),
|
|
1079
|
-
e.value.style.chart.legend.show ? (n(),
|
|
1114
|
+
e.value.style.chart.legend.show ? (n(), r("div", {
|
|
1080
1115
|
key: 7,
|
|
1081
1116
|
ref_key: "chartLegend",
|
|
1082
1117
|
ref: ce,
|
|
1083
|
-
class:
|
|
1118
|
+
class: D({ "vue-ui-nested-donuts-legend": be.value.length > 1 })
|
|
1084
1119
|
}, [
|
|
1085
|
-
(n(!0),
|
|
1086
|
-
key: `legend_${
|
|
1087
|
-
legendSet:
|
|
1088
|
-
config:
|
|
1120
|
+
(n(!0), r(T, null, N(be.value, (o, a) => (n(), U(nl, {
|
|
1121
|
+
key: `legend_${a}_${De.value}`,
|
|
1122
|
+
legendSet: o,
|
|
1123
|
+
config: Ft.value,
|
|
1089
1124
|
onClickMarker: s[1] || (s[1] = ({ legend: t }) => fe(t))
|
|
1090
1125
|
}, {
|
|
1091
|
-
legendTitle:
|
|
1092
|
-
t[0] && t[0].arcOf ? (n(),
|
|
1126
|
+
legendTitle: x(({ titleSet: t }) => [
|
|
1127
|
+
t[0] && t[0].arcOf ? (n(), r("div", zl, S(t[0].arcOf), 1)) : w("", !0)
|
|
1093
1128
|
]),
|
|
1094
|
-
item:
|
|
1095
|
-
|
|
1129
|
+
item: x(({ legend: t, index: u }) => [
|
|
1130
|
+
y("div", {
|
|
1096
1131
|
onClick: (c) => fe(t),
|
|
1097
|
-
style: ne(`opacity:${
|
|
1098
|
-
}, S(t.name) + S(e.value.style.chart.legend.showPercentage || e.value.style.chart.legend.showValue ? ":" : "") + " " + S(e.value.style.chart.legend.showValue ?
|
|
1132
|
+
style: ne(`opacity:${$.value.includes(t.id) ? 0.5 : 1}`)
|
|
1133
|
+
}, S(t.name) + S(e.value.style.chart.legend.showPercentage || e.value.style.chart.legend.showValue ? ":" : "") + " " + S(e.value.style.chart.legend.showValue ? i(Q)(
|
|
1099
1134
|
e.value.style.chart.layout.labels.dataLabels.formatter,
|
|
1100
1135
|
t.value,
|
|
1101
|
-
|
|
1136
|
+
i(O)({
|
|
1102
1137
|
p: e.value.style.chart.layout.labels.dataLabels.prefix,
|
|
1103
1138
|
v: t.value,
|
|
1104
1139
|
s: e.value.style.chart.layout.labels.dataLabels.suffix,
|
|
1105
1140
|
r: e.value.style.chart.legend.roundingValue
|
|
1106
1141
|
}),
|
|
1107
1142
|
{ datapoint: t, seriesIndex: u }
|
|
1108
|
-
) : "") + " " + S(e.value.style.chart.legend.showPercentage ?
|
|
1143
|
+
) : "") + " " + S(e.value.style.chart.legend.showPercentage ? $.value.includes(t.id) ? `${e.value.style.chart.legend.showValue ? "(" : ""}- %${e.value.style.chart.legend.showValue ? ")" : ""}` : `${e.value.style.chart.legend.showValue ? "(" : ""}${isNaN(t.value / t.total) ? "-" : i(O)({
|
|
1109
1144
|
v: t.value / t.total * 100,
|
|
1110
1145
|
s: "%",
|
|
1111
1146
|
r: e.value.style.chart.legend.roundingPercentage
|
|
1112
|
-
})}${e.value.style.chart.legend.showValue ? ")" : ""}` : ""), 13,
|
|
1147
|
+
})}${e.value.style.chart.legend.showValue ? ")" : ""}` : ""), 13, Dl)
|
|
1113
1148
|
]),
|
|
1114
1149
|
_: 2
|
|
1115
1150
|
}, 1032, ["legendSet", "config"]))), 128))
|
|
1116
|
-
], 2)) :
|
|
1117
|
-
e.value.style.chart.legend.show ?
|
|
1151
|
+
], 2)) : w("", !0),
|
|
1152
|
+
e.value.style.chart.legend.show ? w("", !0) : (n(), r("div", {
|
|
1118
1153
|
key: 8,
|
|
1119
1154
|
ref_key: "chartLegend",
|
|
1120
1155
|
ref: ce
|
|
1121
1156
|
}, [
|
|
1122
|
-
|
|
1157
|
+
C(l.$slots, "legend", { legend: be.value }, void 0, !0)
|
|
1123
1158
|
], 512)),
|
|
1124
|
-
l.$slots.source ? (n(),
|
|
1159
|
+
l.$slots.source ? (n(), r("div", {
|
|
1125
1160
|
key: 9,
|
|
1126
1161
|
ref_key: "source",
|
|
1127
1162
|
ref: Ie,
|
|
1128
1163
|
dir: "auto"
|
|
1129
1164
|
}, [
|
|
1130
|
-
|
|
1131
|
-
], 512)) :
|
|
1132
|
-
|
|
1165
|
+
C(l.$slots, "source", {}, void 0, !0)
|
|
1166
|
+
], 512)) : w("", !0),
|
|
1167
|
+
Z.value ? (n(), U(i(gt), {
|
|
1133
1168
|
key: 10,
|
|
1134
1169
|
hideDetails: "",
|
|
1135
1170
|
config: {
|
|
1136
|
-
open:
|
|
1171
|
+
open: k.value.showTable,
|
|
1137
1172
|
maxHeight: 1e4,
|
|
1138
1173
|
body: {
|
|
1139
1174
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
@@ -1145,33 +1180,33 @@ const dl = ["id"], cl = ["xmlns", "viewBox"], vl = ["width", "height"], hl = ["i
|
|
|
1145
1180
|
}
|
|
1146
1181
|
}
|
|
1147
1182
|
}, {
|
|
1148
|
-
content:
|
|
1149
|
-
(n(), U(
|
|
1150
|
-
key: `table_${
|
|
1183
|
+
content: x(() => [
|
|
1184
|
+
(n(), U(i(mt), {
|
|
1185
|
+
key: `table_${ze.value}`,
|
|
1151
1186
|
colNames: ae.value.colNames,
|
|
1152
1187
|
head: ae.value.head,
|
|
1153
1188
|
body: ae.value.body,
|
|
1154
1189
|
config: ae.value.config,
|
|
1155
1190
|
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
1156
|
-
onClose: s[2] || (s[2] = (
|
|
1191
|
+
onClose: s[2] || (s[2] = (o) => k.value.showTable = !1)
|
|
1157
1192
|
}, {
|
|
1158
|
-
th:
|
|
1159
|
-
|
|
1160
|
-
innerHTML:
|
|
1193
|
+
th: x(({ th: o }) => [
|
|
1194
|
+
y("div", {
|
|
1195
|
+
innerHTML: o,
|
|
1161
1196
|
style: { display: "flex", "align-items": "center" }
|
|
1162
|
-
}, null, 8,
|
|
1197
|
+
}, null, 8, Ml)
|
|
1163
1198
|
]),
|
|
1164
|
-
td:
|
|
1165
|
-
|
|
1199
|
+
td: x(({ td: o }) => [
|
|
1200
|
+
Ut(S(o.name || o), 1)
|
|
1166
1201
|
]),
|
|
1167
1202
|
_: 1
|
|
1168
1203
|
}, 8, ["colNames", "head", "body", "config", "title"]))
|
|
1169
1204
|
]),
|
|
1170
1205
|
_: 1
|
|
1171
|
-
}, 8, ["config"])) :
|
|
1206
|
+
}, 8, ["config"])) : w("", !0)
|
|
1172
1207
|
], 46, dl));
|
|
1173
1208
|
}
|
|
1174
|
-
},
|
|
1209
|
+
}, Ql = /* @__PURE__ */ il(Bl, [["__scopeId", "data-v-bb5bf10a"]]);
|
|
1175
1210
|
export {
|
|
1176
|
-
|
|
1211
|
+
Ql as default
|
|
1177
1212
|
};
|