vue-data-ui 3.4.9 → 3.5.0
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/README.md +88 -37
- package/dist/{PackageVersion-CTUqGqWV.js → PackageVersion-Cyx_s25h.js} +1 -1
- package/dist/components/vue-ui-3d-bar.js +1 -1
- package/dist/components/vue-ui-age-pyramid.js +1 -1
- package/dist/components/vue-ui-bullet.js +1 -1
- package/dist/components/vue-ui-candlestick.js +1 -1
- package/dist/components/vue-ui-carousel-table.js +1 -1
- package/dist/components/vue-ui-chestnut.js +1 -1
- package/dist/components/vue-ui-chord.js +1 -1
- package/dist/components/vue-ui-circle-pack.js +1 -1
- package/dist/components/vue-ui-dashboard.js +1 -1
- package/dist/components/vue-ui-donut-evolution.js +1 -1
- package/dist/components/vue-ui-donut.js +1 -1
- package/dist/components/vue-ui-dumbbell.js +1 -1
- package/dist/components/vue-ui-flow.js +1 -1
- package/dist/components/vue-ui-funnel.js +1 -1
- package/dist/components/vue-ui-galaxy.js +1 -1
- package/dist/components/vue-ui-gauge.js +1 -1
- package/dist/components/vue-ui-gizmo.js +1 -1
- package/dist/components/vue-ui-heatmap.js +1 -1
- package/dist/components/vue-ui-history-plot.js +1 -1
- package/dist/components/vue-ui-horizontal-bar.js +1 -1
- package/dist/components/vue-ui-molecule.js +1 -1
- package/dist/components/vue-ui-mood-radar.js +1 -1
- package/dist/components/vue-ui-nested-donuts.js +1 -1
- package/dist/components/vue-ui-onion.js +1 -1
- package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
- package/dist/components/vue-ui-quadrant.js +1 -1
- package/dist/components/vue-ui-quick-chart.js +1 -1
- package/dist/components/vue-ui-radar.js +1 -1
- package/dist/components/vue-ui-relation-circle.js +1 -1
- package/dist/components/vue-ui-ridgeline.js +1 -1
- package/dist/components/vue-ui-rings.js +1 -1
- package/dist/components/vue-ui-scatter.js +1 -1
- package/dist/components/vue-ui-skeleton.js +1 -1
- package/dist/components/vue-ui-spark-trend.js +1 -1
- package/dist/components/vue-ui-sparkbar.js +1 -1
- package/dist/components/vue-ui-sparkgauge.js +1 -1
- package/dist/components/vue-ui-sparkhistogram.js +1 -1
- package/dist/components/vue-ui-sparkline.js +1 -1
- package/dist/components/vue-ui-sparkstackbar.js +1 -1
- package/dist/components/vue-ui-stackbar.js +1 -1
- package/dist/components/vue-ui-strip-plot.js +1 -1
- package/dist/components/vue-ui-table-sparkline.js +1 -1
- package/dist/components/vue-ui-table.js +1 -1
- package/dist/components/vue-ui-thermometer.js +1 -1
- package/dist/components/vue-ui-timer.js +1 -1
- package/dist/components/vue-ui-tiremarks.js +1 -1
- package/dist/components/vue-ui-treemap.js +1 -1
- package/dist/components/vue-ui-vertical-bar.js +1 -1
- package/dist/components/vue-ui-waffle.js +1 -1
- package/dist/components/vue-ui-wheel.js +1 -1
- package/dist/components/vue-ui-word-cloud.js +1 -1
- package/dist/components/vue-ui-world.js +1 -1
- package/dist/components/vue-ui-xy-canvas.js +1 -1
- package/dist/components/vue-ui-xy.js +1 -1
- package/dist/style.css +1 -1
- package/dist/{vue-data-ui-DjxWWa78.js → vue-data-ui-DxgRqCAo.js} +104 -98
- package/dist/vue-data-ui.js +54 -54
- package/dist/{vue-ui-3d-bar-CLE7f9pl.js → vue-ui-3d-bar-DmNJp8SY.js} +1 -1
- package/dist/{vue-ui-age-pyramid-D73uIOPm.js → vue-ui-age-pyramid-CPAP3sNY.js} +1 -1
- package/dist/{vue-ui-bullet-Bybo0xK2.js → vue-ui-bullet-Ce6uvCQJ.js} +1 -1
- package/dist/{vue-ui-candlestick-D_FyMdqH.js → vue-ui-candlestick-DewevWV_.js} +1 -1
- package/dist/{vue-ui-carousel-table-BvMlNdVo.js → vue-ui-carousel-table-Dv1CDfE5.js} +1 -1
- package/dist/{vue-ui-chestnut-DA0g0bDV.js → vue-ui-chestnut-D9sdFZ4E.js} +1 -1
- package/dist/{vue-ui-chord-CDgzolI-.js → vue-ui-chord-BG4dxKNA.js} +1 -1
- package/dist/{vue-ui-circle-pack-BPDm-ro5.js → vue-ui-circle-pack-Be74QB_0.js} +1 -1
- package/dist/{vue-ui-dashboard-CeJwbiON.js → vue-ui-dashboard-C4BLwHey.js} +54 -54
- package/dist/{vue-ui-donut-DjQXHBJE.js → vue-ui-donut-BRGFcgxS.js} +542 -526
- package/dist/{vue-ui-donut-evolution-Ca3Svr0B.js → vue-ui-donut-evolution-DJ0C-7jH.js} +364 -348
- package/dist/{vue-ui-dumbbell-CxCE2luV.js → vue-ui-dumbbell-iQJ0BUhm.js} +1 -1
- package/dist/{vue-ui-flow-DEvwXd4W.js → vue-ui-flow-CTYFoib3.js} +1 -1
- package/dist/{vue-ui-funnel-Bgcx7xia.js → vue-ui-funnel-CG55Xcdy.js} +1 -1
- package/dist/{vue-ui-galaxy-BWr1EMob.js → vue-ui-galaxy-BQrxjKZJ.js} +221 -205
- package/dist/{vue-ui-gauge-DQricvo2.js → vue-ui-gauge-Tc-0NI0Y.js} +1 -1
- package/dist/{vue-ui-gizmo-C-fKe3io.js → vue-ui-gizmo-P8h-gnLd.js} +1 -1
- package/dist/{vue-ui-heatmap-B-o_i7Hu.js → vue-ui-heatmap-BZimPzsL.js} +1 -1
- package/dist/{vue-ui-history-plot-DzQ9DPUJ.js → vue-ui-history-plot-BVzbuqYY.js} +383 -367
- package/dist/{vue-ui-molecule-I2OhrCR2.js → vue-ui-molecule-BALqwB8c.js} +1 -1
- package/dist/{vue-ui-mood-radar-BAT7kZUy.js → vue-ui-mood-radar-QJ5nlZby.js} +1 -1
- package/dist/{vue-ui-nested-donuts-CjhJDAQi.js → vue-ui-nested-donuts-CmUabkkQ.js} +404 -384
- package/dist/{vue-ui-onion-DTY2p87s.js → vue-ui-onion-DAOCf3f8.js} +331 -309
- package/dist/{vue-ui-parallel-coordinate-plot-C8aWTcNn.js → vue-ui-parallel-coordinate-plot-D8jTuFjq.js} +378 -361
- package/dist/{vue-ui-quadrant-DGnasrCR.js → vue-ui-quadrant-CO52mSRY.js} +428 -411
- package/dist/{vue-ui-quick-chart-Cam_sWet.js → vue-ui-quick-chart-DEaVSldE.js} +1 -1
- package/dist/{vue-ui-radar-DNI9WI2R.js → vue-ui-radar-C5V4hhbW.js} +393 -374
- package/dist/{vue-ui-relation-circle-Dj1jhcsl.js → vue-ui-relation-circle-CbMM0Jka.js} +1 -1
- package/dist/{vue-ui-ridgeline-adIls6bj.js → vue-ui-ridgeline-CXCIRDq6.js} +454 -438
- package/dist/{vue-ui-rings-CnTMFK6R.js → vue-ui-rings-BpUcyqo7.js} +285 -263
- package/dist/{vue-ui-scatter-fzR2c0St.js → vue-ui-scatter--Dxe-hfO.js} +629 -613
- package/dist/{vue-ui-skeleton-DUdI2uOO.js → vue-ui-skeleton-BWq-VDzg.js} +1 -1
- package/dist/{vue-ui-spark-trend-DxpRfUJz.js → vue-ui-spark-trend-T4J_YOa_.js} +1 -1
- package/dist/{vue-ui-sparkbar-B44oER5n.js → vue-ui-sparkbar-DnKP55Vu.js} +1 -1
- package/dist/{vue-ui-sparkgauge-ix12NZ7M.js → vue-ui-sparkgauge-BDQLP-zi.js} +1 -1
- package/dist/{vue-ui-sparkhistogram-Cs-QDYBR.js → vue-ui-sparkhistogram-Dm7QXrA-.js} +1 -1
- package/dist/{vue-ui-sparkline-Cb8ZmyUq.js → vue-ui-sparkline-tXGDLHRy.js} +1 -1
- package/dist/vue-ui-sparkstackbar-M53Nt07M.js +441 -0
- package/dist/{vue-ui-stackbar-DubS6Pg8.js → vue-ui-stackbar-CkBOjryQ.js} +437 -421
- package/dist/{vue-ui-strip-plot-BjG-Jxnb.js → vue-ui-strip-plot-BX9i3wMn.js} +1 -1
- package/dist/{vue-ui-table-DdBdLrAL.js → vue-ui-table-7r02N9R9.js} +2 -2
- package/dist/{vue-ui-table-sparkline-EpCo2Be5.js → vue-ui-table-sparkline-DZaAh10E.js} +1 -1
- package/dist/{vue-ui-thermometer-DTnfnf9z.js → vue-ui-thermometer-CFPt3MOv.js} +1 -1
- package/dist/{vue-ui-timer-Br3wp8hG.js → vue-ui-timer-Ds-MJoW2.js} +1 -1
- package/dist/{vue-ui-tiremarks-CrC_tlIx.js → vue-ui-tiremarks-2eIQ6vxu.js} +1 -1
- package/dist/{vue-ui-treemap-kyuyi2ES.js → vue-ui-treemap-BEvl8hiw.js} +500 -484
- package/dist/{vue-ui-vertical-bar-yfbEfLqy.js → vue-ui-vertical-bar-D8dtM8sw.js} +350 -334
- package/dist/{vue-ui-waffle-m-9sqQik.js → vue-ui-waffle-B3q-2SCR.js} +302 -286
- package/dist/{vue-ui-wheel-BasM7FWt.js → vue-ui-wheel-BpirIgAG.js} +1 -1
- package/dist/{vue-ui-word-cloud-vNwswYZD.js → vue-ui-word-cloud-ChT7uLbN.js} +1 -1
- package/dist/{vue-ui-world-BsCNyZy_.js → vue-ui-world-CdP4g_3_.js} +1 -1
- package/dist/{vue-ui-xy-CIrw1lWQ.js → vue-ui-xy-B68qQ-gX.js} +1089 -1073
- package/dist/{vue-ui-xy-canvas-DXnLFwW3.js → vue-ui-xy-canvas-DDngEA1s.js} +338 -322
- package/package.json +1 -1
- package/dist/vue-ui-sparkstackbar-BiRZ51OU.js +0 -424
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { defineAsyncComponent as ge, useSlots as
|
|
2
|
-
import { c as
|
|
3
|
-
import { t as
|
|
4
|
-
import { u as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as
|
|
7
|
-
import { u as
|
|
8
|
-
import { u as
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { t as
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import { u as
|
|
15
|
-
import { _ as
|
|
16
|
-
function
|
|
1
|
+
import { defineAsyncComponent as ge, useSlots as Ul, onMounted as el, computed as y, ref as b, shallowRef as J, toRefs as Gl, watch as Ge, onBeforeUnmount as Xl, createElementBlock as w, openBlock as h, unref as p, normalizeStyle as ue, normalizeClass as bt, createBlock as re, createCommentVNode as M, createElementVNode as V, createVNode as Xe, createSlots as tl, withCtx as O, renderSlot as $, normalizeProps as me, guardReactiveProps as ye, Fragment as qe, renderList as wt, withKeys as ll, withModifiers as kt, mergeProps as Ct, createTextVNode as Ye, toDisplayString as je, Teleport as ql, resolveDynamicComponent as Yl, nextTick as jl } from "vue";
|
|
2
|
+
import { c as Ze, t as Zl, b as Kl, p as D, e as Jl, o as ol, f as Ql, h as Le, a as Ke, d as De, X as $t, S as al, J as nl, G as sl, P as eo, Q as to, H as lo, ap as xt, aq as Je } from "./lib-C_mNZmhD.js";
|
|
3
|
+
import { t as oo, u as ao } from "./useResponsive-DfdjqQps.js";
|
|
4
|
+
import { u as no, a as ul } from "./useNestedProp-BjZe1Y85.js";
|
|
5
|
+
import { u as so, B as uo } from "./BaseScanner-BgWxam9d.js";
|
|
6
|
+
import { u as ro } from "./usePrinter-DTzqpYKF.js";
|
|
7
|
+
import { u as io } from "./useUserOptionState-BIvW1Kz7.js";
|
|
8
|
+
import { u as co } from "./useChartAccessibility-9icAAmYg.js";
|
|
9
|
+
import vo from "./img-BecE5qXd.js";
|
|
10
|
+
import ho from "./Title-l36lOBMx.js";
|
|
11
|
+
import { t as fo } from "./themes-AUNCOb2G.js";
|
|
12
|
+
import po from "./Legend-G6GMcdAc.js";
|
|
13
|
+
import rl from "./BaseIcon-BmMbm4d0.js";
|
|
14
|
+
import { u as go } from "./useSvgExport-DrjCWun4.js";
|
|
15
|
+
import { _ as mo } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
16
|
+
function il(n, i) {
|
|
17
17
|
const u = n.length;
|
|
18
18
|
if (u === 0)
|
|
19
19
|
throw new Error(`Max aspect ratio cannot be computed: ${n} is an empty array`);
|
|
@@ -29,7 +29,7 @@ function rl(n, i) {
|
|
|
29
29
|
);
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
|
-
function
|
|
32
|
+
function cl(n) {
|
|
33
33
|
const { xOffset: i, yOffset: u, width: c, height: r } = n;
|
|
34
34
|
return {
|
|
35
35
|
x0: i,
|
|
@@ -38,18 +38,18 @@ function il(n) {
|
|
|
38
38
|
y1: u + r
|
|
39
39
|
};
|
|
40
40
|
}
|
|
41
|
-
function
|
|
41
|
+
function yo(n, i, u) {
|
|
42
42
|
if (n.length === 0)
|
|
43
43
|
return !0;
|
|
44
44
|
{
|
|
45
|
-
const c = n.concat(i), r =
|
|
45
|
+
const c = n.concat(i), r = il(
|
|
46
46
|
n,
|
|
47
47
|
u
|
|
48
|
-
), f =
|
|
48
|
+
), f = il(c, u);
|
|
49
49
|
return r >= f;
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function bo(n) {
|
|
53
53
|
const i = [], u = n.length;
|
|
54
54
|
for (let c = 0; c < u; c += 1) {
|
|
55
55
|
const r = n[c], f = r.length;
|
|
@@ -58,49 +58,49 @@ function go(n) {
|
|
|
58
58
|
}
|
|
59
59
|
return i;
|
|
60
60
|
}
|
|
61
|
-
function
|
|
61
|
+
function wo(n, i) {
|
|
62
62
|
const u = {
|
|
63
63
|
...i,
|
|
64
64
|
children: n
|
|
65
65
|
};
|
|
66
|
-
return
|
|
66
|
+
return dl(u);
|
|
67
67
|
}
|
|
68
|
-
function
|
|
68
|
+
function ko(n) {
|
|
69
69
|
return (n.x1 - n.x0) * (n.y1 - n.y0);
|
|
70
70
|
}
|
|
71
|
-
function
|
|
72
|
-
const { width: u, height: c, xOffset: r, yOffset: f } =
|
|
73
|
-
let
|
|
71
|
+
function vl(n, i) {
|
|
72
|
+
const { width: u, height: c, xOffset: r, yOffset: f } = Tt(i), d = n.length, m = n.map((T) => T.normalizedValue || 0).reduce((T, z) => T + z, 0), g = m / c, Q = m / u;
|
|
73
|
+
let W = r, x = f;
|
|
74
74
|
const _ = [];
|
|
75
75
|
if (u >= c) {
|
|
76
76
|
for (let T = 0; T < d; T += 1) {
|
|
77
|
-
const
|
|
78
|
-
x0:
|
|
77
|
+
const z = n[T], q = x + z.normalizedValue / g, I = {
|
|
78
|
+
x0: W,
|
|
79
79
|
y0: x,
|
|
80
|
-
x1:
|
|
80
|
+
x1: W + g,
|
|
81
81
|
y1: q
|
|
82
|
-
},
|
|
83
|
-
x = q, _.push(
|
|
82
|
+
}, B = Object.assign({}, z, I);
|
|
83
|
+
x = q, _.push(B);
|
|
84
84
|
}
|
|
85
85
|
return _;
|
|
86
86
|
} else {
|
|
87
87
|
for (let T = 0; T < d; T += 1) {
|
|
88
|
-
const
|
|
89
|
-
x0:
|
|
88
|
+
const z = n[T], q = W + z.normalizedValue / Q, I = {
|
|
89
|
+
x0: W,
|
|
90
90
|
y0: x,
|
|
91
91
|
x1: q,
|
|
92
92
|
y1: x + Q
|
|
93
|
-
},
|
|
94
|
-
|
|
93
|
+
}, B = Object.assign({}, z, I);
|
|
94
|
+
W = q, _.push(B);
|
|
95
95
|
}
|
|
96
96
|
return _;
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
|
-
function
|
|
100
|
-
const i =
|
|
99
|
+
function Co(n) {
|
|
100
|
+
const i = Tt(n), u = i.width, c = i.height;
|
|
101
101
|
return Math.min(u, c);
|
|
102
102
|
}
|
|
103
|
-
function
|
|
103
|
+
function $o(n, i) {
|
|
104
104
|
const u = n.length, c = n.map((g) => g.value ?? 0).reduce((g, Q) => g + Q, 0), r = i / c, f = [];
|
|
105
105
|
let d, m;
|
|
106
106
|
for (let g = 0; g < u; g += 1)
|
|
@@ -109,7 +109,7 @@ function wo(n, i) {
|
|
|
109
109
|
}), f.push(d);
|
|
110
110
|
return f;
|
|
111
111
|
}
|
|
112
|
-
function
|
|
112
|
+
function Tt(n) {
|
|
113
113
|
const { x0: i, y0: u, x1: c, y1: r } = n;
|
|
114
114
|
return {
|
|
115
115
|
xOffset: i,
|
|
@@ -118,43 +118,43 @@ function xt(n) {
|
|
|
118
118
|
height: r - u
|
|
119
119
|
};
|
|
120
120
|
}
|
|
121
|
-
function
|
|
121
|
+
function xo(n, i, u, c) {
|
|
122
122
|
let r = n, f = i, d = u, m = c;
|
|
123
123
|
for (; ; ) {
|
|
124
124
|
const g = r.length;
|
|
125
125
|
if (g === 0) {
|
|
126
|
-
const _ =
|
|
126
|
+
const _ = vl(f, d);
|
|
127
127
|
return m.concat(_);
|
|
128
128
|
}
|
|
129
|
-
const Q =
|
|
130
|
-
if (
|
|
131
|
-
const _ = f.concat(
|
|
129
|
+
const Q = Co(d), W = r[0], x = r.slice(1, g);
|
|
130
|
+
if (yo(f, W, Q)) {
|
|
131
|
+
const _ = f.concat(W);
|
|
132
132
|
r = x, f = _, d = d, m = m;
|
|
133
133
|
} else {
|
|
134
134
|
const _ = f.length;
|
|
135
135
|
let T = 0;
|
|
136
|
-
for (let
|
|
137
|
-
T += f[
|
|
138
|
-
const
|
|
139
|
-
r = r, f = [], d =
|
|
136
|
+
for (let B = 0; B < _; B += 1)
|
|
137
|
+
T += f[B].normalizedValue;
|
|
138
|
+
const z = To(d, T), q = vl(f, d), I = m.concat(q);
|
|
139
|
+
r = r, f = [], d = z, m = I;
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
}
|
|
143
|
-
function
|
|
143
|
+
function dl(n) {
|
|
144
144
|
if (typeof n.children > "u" || !n.children.length)
|
|
145
145
|
return [n];
|
|
146
146
|
{
|
|
147
|
-
const i =
|
|
147
|
+
const i = $o(
|
|
148
148
|
n.children,
|
|
149
|
-
|
|
150
|
-
), u =
|
|
149
|
+
ko(n)
|
|
150
|
+
), u = xo(i, [], n, []), c = u.length, r = [];
|
|
151
151
|
for (let d = 0; d < c; d += 1)
|
|
152
|
-
r.push(
|
|
153
|
-
return
|
|
152
|
+
r.push(dl(u[d]));
|
|
153
|
+
return bo(r);
|
|
154
154
|
}
|
|
155
155
|
}
|
|
156
|
-
function
|
|
157
|
-
const { width: u, height: c, xOffset: r, yOffset: f } =
|
|
156
|
+
function To(n, i) {
|
|
157
|
+
const { width: u, height: c, xOffset: r, yOffset: f } = Tt(n);
|
|
158
158
|
if (u >= c) {
|
|
159
159
|
const d = i / c, m = u - d, g = {
|
|
160
160
|
xOffset: r + d,
|
|
@@ -162,7 +162,7 @@ function Co(n, i) {
|
|
|
162
162
|
width: m,
|
|
163
163
|
height: c
|
|
164
164
|
};
|
|
165
|
-
return
|
|
165
|
+
return cl(g);
|
|
166
166
|
} else {
|
|
167
167
|
const d = i / u, m = c - d, g = {
|
|
168
168
|
xOffset: r,
|
|
@@ -170,19 +170,19 @@ function Co(n, i) {
|
|
|
170
170
|
width: u,
|
|
171
171
|
height: m
|
|
172
172
|
};
|
|
173
|
-
return
|
|
173
|
+
return cl(g);
|
|
174
174
|
}
|
|
175
175
|
}
|
|
176
|
-
const
|
|
176
|
+
const So = ["id"], Oo = ["id"], _o = ["tabindex", "onClick", "onKeydown", "data-last-crumb", "onMouseenter", "onFocus"], Ao = { class: "vue-ui-treemap-crumb-unit" }, Fo = { class: "vue-ui-treemap-crumb-unit-label" }, Mo = {
|
|
177
177
|
key: 0,
|
|
178
178
|
style: { width: "24px", display: "flex", "align-items": "center" }
|
|
179
|
-
},
|
|
179
|
+
}, Io = {
|
|
180
180
|
key: 0,
|
|
181
181
|
class: "vue-ui-treemap-crumb-unit-arrow"
|
|
182
|
-
},
|
|
182
|
+
}, No = ["xmlns", "viewBox"], Lo = { key: 0 }, Do = ["id"], zo = ["stop-color"], Ro = ["stop-color"], Po = ["x", "y", "height", "width", "fill", "rx", "stroke", "stroke-width", "onClick", "onMouseenter", "onMouseleave"], Vo = ["innerHTML"], Bo = ["x", "y", "height", "width"], Ho = {
|
|
183
183
|
key: 5,
|
|
184
184
|
class: "vue-data-ui-watermark"
|
|
185
|
-
},
|
|
185
|
+
}, Eo = ["id"], Wo = ["onClick"], Uo = ["innerHTML"], Go = {
|
|
186
186
|
__name: "vue-ui-treemap",
|
|
187
187
|
props: {
|
|
188
188
|
config: {
|
|
@@ -200,14 +200,14 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
200
200
|
},
|
|
201
201
|
emits: ["selectLegend", "selectDatapoint"],
|
|
202
202
|
setup(n, { expose: i, emit: u }) {
|
|
203
|
-
const c = ge(() => import("./DataTable-BT7VF2ua.js")), r = ge(() => import("./PenAndPaper-DSvu9dwa.js")), f = ge(() => import("./vue-ui-accordion-CZ0thhxa.js")), d = ge(() => import("./Tooltip-oWCO1HKy.js")), m = ge(() => import("./UserOptions-CGnQt6Fd.js")), g = ge(() => import("./PackageVersion-
|
|
204
|
-
|
|
203
|
+
const c = ge(() => import("./DataTable-BT7VF2ua.js")), r = ge(() => import("./PenAndPaper-DSvu9dwa.js")), f = ge(() => import("./vue-ui-accordion-CZ0thhxa.js")), d = ge(() => import("./Tooltip-oWCO1HKy.js")), m = ge(() => import("./UserOptions-CGnQt6Fd.js")), g = ge(() => import("./PackageVersion-Cyx_s25h.js")), Q = ge(() => import("./BaseDraggableDialog-ymf2sfB8.js")), { vue_ui_treemap: W } = no(), x = n, _ = u, T = Ul();
|
|
204
|
+
el(() => {
|
|
205
205
|
T["chart-background"] && console.warn("VueUiTreemap does not support the #chart-background slot.");
|
|
206
206
|
});
|
|
207
|
-
const
|
|
208
|
-
...
|
|
207
|
+
const z = y(() => !!x.dataset && x.dataset.length), q = y(() => /^((?!chrome|android).)*safari/i.test(navigator.userAgent)), I = b(Ze()), B = b(!1), Qe = b(""), ie = b(!1), St = b(0), R = b([]), U = J(null), Ot = J(null), _t = J(null), At = J(null), Ft = J(null), Mt = b(0), et = b(0), tt = b(0), F = b([]), lt = b(null), It = b(!1), Ae = b(null), ot = b(null), t = b(ut()), { loading: be, FINAL_DATASET: at, manualLoading: hl } = so({
|
|
208
|
+
...Gl(x),
|
|
209
209
|
FINAL_CONFIG: t,
|
|
210
|
-
prepareConfig:
|
|
210
|
+
prepareConfig: ut,
|
|
211
211
|
skeletonDataset: [
|
|
212
212
|
{
|
|
213
213
|
name: "_",
|
|
@@ -224,7 +224,7 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
224
224
|
]
|
|
225
225
|
}
|
|
226
226
|
],
|
|
227
|
-
skeletonConfig:
|
|
227
|
+
skeletonConfig: Zl({
|
|
228
228
|
defaultConfig: t.value,
|
|
229
229
|
userConfig: {
|
|
230
230
|
userOptions: { show: !1 },
|
|
@@ -246,33 +246,33 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
246
246
|
}
|
|
247
247
|
}
|
|
248
248
|
})
|
|
249
|
-
}), { userOptionsVisible:
|
|
250
|
-
function
|
|
251
|
-
const e =
|
|
249
|
+
}), { userOptionsVisible: nt, setUserOptionsVisibility: Nt, keepUserOptionState: Lt } = io({ config: t.value }), { svgRef: st } = co({ config: t.value.style.chart.title });
|
|
250
|
+
function ut() {
|
|
251
|
+
const e = ul({
|
|
252
252
|
userConfig: x.config,
|
|
253
|
-
defaultConfig:
|
|
253
|
+
defaultConfig: W
|
|
254
254
|
});
|
|
255
255
|
return e.theme ? {
|
|
256
|
-
...
|
|
257
|
-
userConfig:
|
|
256
|
+
...ul({
|
|
257
|
+
userConfig: fo.vue_ui_treemap[e.theme] || x.config,
|
|
258
258
|
defaultConfig: e
|
|
259
259
|
}),
|
|
260
|
-
customPalette:
|
|
260
|
+
customPalette: Kl[e.theme] || D
|
|
261
261
|
} : e;
|
|
262
262
|
}
|
|
263
|
-
|
|
264
|
-
be.value || (t.value =
|
|
263
|
+
Ge(() => x.config, (e) => {
|
|
264
|
+
be.value || (t.value = ut()), nt.value = !t.value.userOptions.showOnChartHover, Mt.value += 1, et.value += 1, tt.value += 1, P.value.showTable = t.value.table.show, P.value.showTooltip = t.value.style.chart.tooltip.show;
|
|
265
265
|
}, { deep: !0 });
|
|
266
|
-
const { isPrinting:
|
|
266
|
+
const { isPrinting: Dt, isImaging: zt, generatePdf: Rt, generateImage: Pt } = ro({
|
|
267
267
|
elementId: `treemap_${I.value}`,
|
|
268
268
|
fileName: t.value.style.chart.title.text || "vue-ui-treemap",
|
|
269
269
|
options: t.value.userOptions.print
|
|
270
|
-
}),
|
|
270
|
+
}), fl = y(() => t.value.userOptions.show && !t.value.style.chart.title.text), ze = y(() => Jl(t.value.customPalette)), P = b({
|
|
271
271
|
showTable: t.value.table.show,
|
|
272
272
|
showTooltip: t.value.style.chart.tooltip.show
|
|
273
273
|
});
|
|
274
|
-
|
|
275
|
-
|
|
274
|
+
Ge(t, () => {
|
|
275
|
+
P.value = {
|
|
276
276
|
showTable: t.value.table.show,
|
|
277
277
|
showTooltip: t.value.style.chart.tooltip.show
|
|
278
278
|
};
|
|
@@ -281,180 +281,180 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
281
281
|
height: t.value.style.chart.height,
|
|
282
282
|
width: t.value.style.chart.width
|
|
283
283
|
});
|
|
284
|
-
function
|
|
285
|
-
const
|
|
286
|
-
if (!
|
|
287
|
-
const a =
|
|
288
|
-
return e * (
|
|
284
|
+
function pl(e) {
|
|
285
|
+
const l = U.value, o = Fe.value.height;
|
|
286
|
+
if (!l || !o) return e;
|
|
287
|
+
const a = l.getBoundingClientRect();
|
|
288
|
+
return e * (o / a.height);
|
|
289
289
|
}
|
|
290
|
-
function
|
|
291
|
-
if (!
|
|
292
|
-
const e =
|
|
293
|
-
return
|
|
290
|
+
function gl() {
|
|
291
|
+
if (!lt.value || Y.value.length <= 1) return 0;
|
|
292
|
+
const e = lt.value, l = getComputedStyle(e), o = e.offsetHeight + parseFloat(l.marginTop || "0") + parseFloat(l.marginBottom || "0") + parseFloat(l.paddingTop || "0") + parseFloat(l.paddingBottom || "0");
|
|
293
|
+
return pl(o);
|
|
294
294
|
}
|
|
295
|
-
const
|
|
296
|
-
const e = t.value.style.chart.padding,
|
|
295
|
+
const H = y(() => {
|
|
296
|
+
const e = t.value.style.chart.padding, l = Fe.value.width, o = Fe.value.height, a = gl(), s = e.left, v = l - e.right, k = e.top, L = o - e.bottom - a;
|
|
297
297
|
return {
|
|
298
298
|
left: s,
|
|
299
299
|
top: k,
|
|
300
300
|
right: v,
|
|
301
|
-
bottom:
|
|
301
|
+
bottom: L,
|
|
302
302
|
width: v - s,
|
|
303
|
-
height: Math.max(0,
|
|
304
|
-
vbWidth:
|
|
305
|
-
vbHeight:
|
|
303
|
+
height: Math.max(0, L - k),
|
|
304
|
+
vbWidth: l,
|
|
305
|
+
vbHeight: o - a,
|
|
306
306
|
offsetY: a
|
|
307
307
|
};
|
|
308
|
-
}),
|
|
308
|
+
}), N = b(at.value), ee = b(N.value), Vt = J(/* @__PURE__ */ new Map());
|
|
309
309
|
function Bt(e) {
|
|
310
|
-
Array.isArray(e) && e.forEach((
|
|
311
|
-
|
|
312
|
-
let a = Le(
|
|
313
|
-
a = Le(a),
|
|
310
|
+
Array.isArray(e) && e.forEach((l, o) => {
|
|
311
|
+
l.id || (l.id = Ze());
|
|
312
|
+
let a = Le(l.color) || Vt.value.get(l.id) || ze.value[o] || D[o] || D[o % D.length];
|
|
313
|
+
a = Le(a), Vt.value.set(l.id, a), l.color = a, Ht(l, a);
|
|
314
314
|
});
|
|
315
315
|
}
|
|
316
|
-
function
|
|
317
|
-
Array.isArray(e.children) && e.children.forEach((
|
|
318
|
-
|
|
316
|
+
function Ht(e, l) {
|
|
317
|
+
Array.isArray(e.children) && e.children.forEach((o) => {
|
|
318
|
+
o.id || (o.id = Ze()), o.parentId = e.id, o.color = l, Ht(o, l);
|
|
319
319
|
});
|
|
320
320
|
}
|
|
321
|
-
function
|
|
321
|
+
function ml() {
|
|
322
322
|
if (!F.value.length)
|
|
323
|
-
ee.value =
|
|
323
|
+
ee.value = N.value.slice();
|
|
324
324
|
else {
|
|
325
|
-
const e = F.value[F.value.length - 1],
|
|
326
|
-
ee.value =
|
|
325
|
+
const e = F.value[F.value.length - 1], l = le(e);
|
|
326
|
+
ee.value = l?.children?.slice() || [];
|
|
327
327
|
}
|
|
328
328
|
}
|
|
329
|
-
|
|
330
|
-
() =>
|
|
329
|
+
Ge(
|
|
330
|
+
() => at.value,
|
|
331
331
|
() => {
|
|
332
|
-
|
|
332
|
+
N.value = at.value, Bt(N.value), ml(), tt.value += 1, et.value += 1;
|
|
333
333
|
},
|
|
334
334
|
{ deep: !0, immediate: !0, flush: "post" }
|
|
335
335
|
);
|
|
336
336
|
const te = J(null), we = J(null);
|
|
337
|
-
|
|
338
|
-
|
|
337
|
+
el(() => {
|
|
338
|
+
It.value = !0, bl();
|
|
339
339
|
});
|
|
340
|
-
const
|
|
341
|
-
function
|
|
342
|
-
if (
|
|
340
|
+
const yl = y(() => t.value.debug);
|
|
341
|
+
function bl() {
|
|
342
|
+
if (ol(x.dataset) && Ql({
|
|
343
343
|
componentName: "VueUiTreemap",
|
|
344
344
|
type: "dataset",
|
|
345
|
-
debug:
|
|
346
|
-
}), Bt(
|
|
347
|
-
const e =
|
|
348
|
-
const { width:
|
|
345
|
+
debug: yl.value
|
|
346
|
+
}), Bt(N.value), ol(x.dataset) || (hl.value = t.value.loading), t.value.responsive) {
|
|
347
|
+
const e = oo(() => {
|
|
348
|
+
const { width: l, height: o } = ao({
|
|
349
349
|
chart: U.value,
|
|
350
|
-
title: t.value.style.chart.title.text ?
|
|
351
|
-
legend: t.value.style.chart.legend.show ?
|
|
352
|
-
source:
|
|
353
|
-
noTitle:
|
|
350
|
+
title: t.value.style.chart.title.text ? Ot.value : null,
|
|
351
|
+
legend: t.value.style.chart.legend.show ? _t.value : null,
|
|
352
|
+
source: At.value,
|
|
353
|
+
noTitle: Ft.value
|
|
354
354
|
});
|
|
355
355
|
requestAnimationFrame(() => {
|
|
356
|
-
Fe.value.width =
|
|
356
|
+
Fe.value.width = l, Fe.value.height = o - 12;
|
|
357
357
|
});
|
|
358
358
|
});
|
|
359
359
|
te.value && (we.value && te.value.unobserve(we.value), te.value.disconnect()), te.value = new ResizeObserver(e), we.value = U.value.parentNode, te.value.observe(we.value);
|
|
360
360
|
}
|
|
361
361
|
}
|
|
362
|
-
|
|
362
|
+
Xl(() => {
|
|
363
363
|
te.value && (we.value && te.value.unobserve(we.value), te.value.disconnect());
|
|
364
364
|
});
|
|
365
|
-
const Me = y(() => ee.value.map((e,
|
|
365
|
+
const Me = y(() => ee.value.map((e, l) => ({
|
|
366
366
|
...e,
|
|
367
|
-
color: Le(e.color) || ze.value[
|
|
368
|
-
})).filter((e) => !
|
|
367
|
+
color: Le(e.color) || ze.value[l] || D[l] || D[l % D.length]
|
|
368
|
+
})).filter((e) => !R.value.includes(e.id))), ke = y(() => N.value.filter((e) => !R.value.includes(e.id)).map((e) => e.value || 0).reduce((e, l) => e + l, 0)), rt = y({
|
|
369
369
|
get() {
|
|
370
370
|
let e = [...Me.value];
|
|
371
|
-
return t.value.style.chart.layout.sorted && (e = [...Me.value].sort((
|
|
372
|
-
...
|
|
371
|
+
return t.value.style.chart.layout.sorted && (e = [...Me.value].sort((l, o) => o.value - l.value)), e.map((l) => ({
|
|
372
|
+
...l
|
|
373
373
|
}));
|
|
374
374
|
},
|
|
375
375
|
set(e) {
|
|
376
376
|
return e;
|
|
377
377
|
}
|
|
378
378
|
});
|
|
379
|
-
function
|
|
380
|
-
return e.value /
|
|
379
|
+
function Et(e, l) {
|
|
380
|
+
return e.value / l;
|
|
381
381
|
}
|
|
382
|
-
function
|
|
383
|
-
const a = t.value.style.chart.layout.rects.colorRatio -
|
|
384
|
-
return
|
|
382
|
+
function wl(e, l, o) {
|
|
383
|
+
const a = t.value.style.chart.layout.rects.colorRatio - Et(l, o);
|
|
384
|
+
return al(e, a < 0 ? 0 : a);
|
|
385
385
|
}
|
|
386
|
-
function
|
|
386
|
+
function Wt(e, l, o, a) {
|
|
387
387
|
return e.map((s, v) => {
|
|
388
|
-
const k =
|
|
388
|
+
const k = wl(Le(l) || ze.value[v] || D[v] || D[v % D.length], s, a), L = Et(s, a);
|
|
389
389
|
return {
|
|
390
390
|
...s,
|
|
391
391
|
color: k,
|
|
392
|
-
proportion:
|
|
393
|
-
parentName:
|
|
394
|
-
children: s.children ?
|
|
392
|
+
proportion: L,
|
|
393
|
+
parentName: o,
|
|
394
|
+
children: s.children ? Wt(s.children, k, s.name, a) : void 0
|
|
395
395
|
};
|
|
396
396
|
});
|
|
397
397
|
}
|
|
398
398
|
const Ie = y(() => {
|
|
399
|
-
const e =
|
|
400
|
-
return
|
|
401
|
-
|
|
402
|
-
const
|
|
399
|
+
const e = rt.value.map((l) => Number(l.value) || 0).reduce((l, o) => l + o, 0) || 1;
|
|
400
|
+
return wo(
|
|
401
|
+
rt.value.map((l) => {
|
|
402
|
+
const o = l.children ? l.children.reduce((a, s) => a + (Number(s.value) || 0), 0) : l.value;
|
|
403
403
|
return {
|
|
404
|
-
value:
|
|
405
|
-
id:
|
|
406
|
-
proportion: (Number(
|
|
407
|
-
children:
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
404
|
+
value: l.value,
|
|
405
|
+
id: l.id || Ze(),
|
|
406
|
+
proportion: (Number(l.value) || 0) / e,
|
|
407
|
+
children: l.children ? Wt(
|
|
408
|
+
l.children.sort((a, s) => (s.value || 0) - (a.value || 0)),
|
|
409
|
+
l.color,
|
|
410
|
+
l.name,
|
|
411
|
+
o || 1
|
|
412
412
|
) : void 0,
|
|
413
|
-
color:
|
|
414
|
-
name:
|
|
413
|
+
color: l.color,
|
|
414
|
+
name: l.name
|
|
415
415
|
};
|
|
416
416
|
}),
|
|
417
417
|
{
|
|
418
|
-
x0:
|
|
419
|
-
y0:
|
|
420
|
-
x1:
|
|
421
|
-
y1:
|
|
418
|
+
x0: H.value.left,
|
|
419
|
+
y0: H.value.top,
|
|
420
|
+
x1: H.value.left + H.value.width,
|
|
421
|
+
y1: H.value.top + H.value.height
|
|
422
422
|
}
|
|
423
423
|
);
|
|
424
424
|
});
|
|
425
|
-
function Ce({ y0: e, y1:
|
|
426
|
-
return
|
|
425
|
+
function Ce({ y0: e, y1: l }) {
|
|
426
|
+
return l - e <= 0 ? 1e-4 : l - e;
|
|
427
427
|
}
|
|
428
|
-
function $e({ x0: e, x1:
|
|
429
|
-
return
|
|
428
|
+
function $e({ x0: e, x1: l }) {
|
|
429
|
+
return l - e <= 0 ? 1e-4 : l - e;
|
|
430
430
|
}
|
|
431
431
|
function xe(e) {
|
|
432
|
-
const
|
|
432
|
+
const l = t.value.style.chart.layout.labels, o = l.fontSize, a = l.minFontSize, s = l.fontSize * 2, v = 0.5, k = 0.6, L = 1, ce = 0.9;
|
|
433
433
|
let oe = e.proportion;
|
|
434
434
|
if (!(typeof oe == "number" && isFinite(oe))) {
|
|
435
|
-
const
|
|
436
|
-
oe =
|
|
435
|
+
const We = Math.max(1e-6, $e(e) * Ce(e)), ve = Math.max(1e-6, H.value.width * H.value.height);
|
|
436
|
+
oe = We / ve;
|
|
437
437
|
}
|
|
438
|
-
const
|
|
439
|
-
let ne =
|
|
440
|
-
const
|
|
441
|
-
return ne = Math.min(ne,
|
|
438
|
+
const Ee = Math.pow(Math.min(1, Math.max(0, oe)), v), ae = k + (L - k) * Ee;
|
|
439
|
+
let ne = o * ae;
|
|
440
|
+
const ht = Math.max(1e-4, Math.min($e(e), Ce(e)));
|
|
441
|
+
return ne = Math.min(ne, ht * ce), ne = Math.max(a, Math.min(s, ne)), ne;
|
|
442
442
|
}
|
|
443
|
-
function
|
|
444
|
-
ie.value = e,
|
|
443
|
+
function Ut(e) {
|
|
444
|
+
ie.value = e, St.value += 1;
|
|
445
445
|
}
|
|
446
446
|
const Te = y(() => ({
|
|
447
447
|
startX: 0,
|
|
448
448
|
startY: 0,
|
|
449
|
-
width:
|
|
450
|
-
height:
|
|
449
|
+
width: H.value.vbWidth,
|
|
450
|
+
height: H.value.vbHeight
|
|
451
451
|
}));
|
|
452
|
-
function le(e,
|
|
453
|
-
for (const
|
|
454
|
-
if (
|
|
455
|
-
return
|
|
456
|
-
if (
|
|
457
|
-
const a = le(e,
|
|
452
|
+
function le(e, l = N.value) {
|
|
453
|
+
for (const o of l) {
|
|
454
|
+
if (o.id === e)
|
|
455
|
+
return o;
|
|
456
|
+
if (o.children) {
|
|
457
|
+
const a = le(e, o.children);
|
|
458
458
|
if (a)
|
|
459
459
|
return a;
|
|
460
460
|
}
|
|
@@ -462,15 +462,15 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
462
462
|
return null;
|
|
463
463
|
}
|
|
464
464
|
const Se = y(() => F.value.length > 0);
|
|
465
|
-
function Re(e,
|
|
465
|
+
function Re(e, l) {
|
|
466
466
|
if (!e) {
|
|
467
|
-
ee.value =
|
|
467
|
+
ee.value = N.value.slice(), _("selectDatapoint", void 0), F.value = [];
|
|
468
468
|
return;
|
|
469
469
|
}
|
|
470
|
-
t.value.events.datapointClick && t.value.events.datapointClick({ datapoint: e, seriesIndex:
|
|
471
|
-
const
|
|
472
|
-
if (
|
|
473
|
-
F.value.push(
|
|
470
|
+
t.value.events.datapointClick && t.value.events.datapointClick({ datapoint: e, seriesIndex: l });
|
|
471
|
+
const o = le(e.id);
|
|
472
|
+
if (o && o.children?.length)
|
|
473
|
+
F.value.push(o.id), ee.value = o.children.slice(), _("selectDatapoint", e);
|
|
474
474
|
else if (e.parentId) {
|
|
475
475
|
F.value.push(e.parentId);
|
|
476
476
|
const a = le(e.parentId);
|
|
@@ -482,10 +482,10 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
482
482
|
const s = le(a);
|
|
483
483
|
ee.value = s.children.slice();
|
|
484
484
|
} else
|
|
485
|
-
ee.value =
|
|
485
|
+
ee.value = N.value.slice(), F.value = [], _("selectDatapoint", void 0);
|
|
486
486
|
}
|
|
487
487
|
}
|
|
488
|
-
function
|
|
488
|
+
function kl(e) {
|
|
489
489
|
return !!(le(e.id)?.children?.length || e.parentId);
|
|
490
490
|
}
|
|
491
491
|
const Y = y(() => {
|
|
@@ -493,11 +493,11 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
493
493
|
{ id: null, label: "All" }
|
|
494
494
|
];
|
|
495
495
|
if (F.value.length > 0) {
|
|
496
|
-
let
|
|
497
|
-
const
|
|
498
|
-
for (;
|
|
499
|
-
|
|
500
|
-
for (const a of
|
|
496
|
+
let l = le(F.value[F.value.length - 1]);
|
|
497
|
+
const o = [];
|
|
498
|
+
for (; l; )
|
|
499
|
+
o.unshift(l), l = l.parentId ? le(l.parentId) : null;
|
|
500
|
+
for (const a of o)
|
|
501
501
|
e.push({
|
|
502
502
|
id: a.id,
|
|
503
503
|
label: a.name,
|
|
@@ -505,17 +505,17 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
505
505
|
});
|
|
506
506
|
}
|
|
507
507
|
return e;
|
|
508
|
-
}), G = J(null),
|
|
508
|
+
}), G = J(null), it = y(() => N.value.map((e, l) => ({
|
|
509
509
|
...e,
|
|
510
|
-
color: Le(e.color) || ze.value[
|
|
510
|
+
color: Le(e.color) || ze.value[l] || D[l] || D[l % D.length],
|
|
511
511
|
shape: "square"
|
|
512
|
-
})).sort((e,
|
|
513
|
-
const
|
|
512
|
+
})).sort((e, l) => l.value - e.value).map((e, l) => {
|
|
513
|
+
const o = e.value / N.value.map((a) => a.value).reduce((a, s) => a + s, 0);
|
|
514
514
|
return {
|
|
515
515
|
...e,
|
|
516
|
-
proportion:
|
|
517
|
-
opacity:
|
|
518
|
-
display: `${e.name}${t.value.style.chart.legend.showPercentage || t.value.style.chart.legend.showValue ? ": " : ""}${t.value.style.chart.legend.showValue ?
|
|
516
|
+
proportion: o,
|
|
517
|
+
opacity: R.value.includes(e.id) ? 0.5 : 1,
|
|
518
|
+
display: `${e.name}${t.value.style.chart.legend.showPercentage || t.value.style.chart.legend.showValue ? ": " : ""}${t.value.style.chart.legend.showValue ? Ke(
|
|
519
519
|
t.value.style.chart.layout.labels.formatter,
|
|
520
520
|
e.value,
|
|
521
521
|
De({
|
|
@@ -525,9 +525,9 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
525
525
|
r: t.value.style.chart.legend.roundingValue
|
|
526
526
|
}),
|
|
527
527
|
{ datapoint: e }
|
|
528
|
-
) : ""}${t.value.style.chart.legend.showPercentage ?
|
|
528
|
+
) : ""}${t.value.style.chart.legend.showPercentage ? R.value.includes(e.id) ? `${t.value.style.chart.legend.showValue ? " (" : ""}- %${t.value.style.chart.legend.showValue ? ")" : ""}` : `${t.value.style.chart.legend.showValue ? " (" : ""}${isNaN(e.value / ke.value) ? "-" : (e.value / ke.value * 100).toFixed(t.value.style.chart.legend.roundingPercentage)}%${t.value.style.chart.legend.showValue ? ")" : ""}` : ""}`
|
|
529
529
|
};
|
|
530
|
-
})),
|
|
530
|
+
})), Cl = y(() => ({
|
|
531
531
|
cy: "treemap-div-legend",
|
|
532
532
|
backgroundColor: t.value.style.chart.legend.backgroundColor,
|
|
533
533
|
color: t.value.style.chart.legend.color,
|
|
@@ -535,31 +535,45 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
535
535
|
paddingBottom: 12,
|
|
536
536
|
fontWeight: t.value.style.chart.legend.bold ? "bold" : ""
|
|
537
537
|
}));
|
|
538
|
-
function
|
|
539
|
-
G.value = null,
|
|
538
|
+
function Pe(e) {
|
|
539
|
+
G.value = null, R.value.includes(e.id) ? R.value = R.value.filter((l) => l !== e.id) : R.value.length < x.dataset.length - 1 && R.value.push(e.id), _("selectLegend", rt.value);
|
|
540
|
+
}
|
|
541
|
+
function Gt(e) {
|
|
542
|
+
if (!N.value.length)
|
|
543
|
+
return t.value.debug && console.warn("VueUiTreemap - There are no series to show."), null;
|
|
544
|
+
const l = N.value.find((o) => o.name === e);
|
|
545
|
+
return l || (t.value.debug && console.warn(`VueUiTreemap - Series name not found "${e}"`), null);
|
|
540
546
|
}
|
|
541
|
-
function
|
|
542
|
-
|
|
547
|
+
function $l(e) {
|
|
548
|
+
const l = Gt(e);
|
|
549
|
+
l !== null && R.value.includes(l.id) && Pe({ id: l.id });
|
|
543
550
|
}
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
551
|
+
function xl(e) {
|
|
552
|
+
const l = Gt(e);
|
|
553
|
+
l !== null && (R.value.includes(l.id) || Pe({ id: l.id }));
|
|
554
|
+
}
|
|
555
|
+
function Tl({ datapoint: e, seriesIndex: l }) {
|
|
556
|
+
G.value = null, B.value = !1, t.value.events.datapointLeave && t.value.events.datapointLeave({ datapoint: e, seriesIndex: l });
|
|
557
|
+
}
|
|
558
|
+
const ct = b(null);
|
|
559
|
+
function Sl({ datapoint: e, seriesIndex: l }) {
|
|
560
|
+
t.value.events.datapointEnter && t.value.events.datapointEnter({ datapoint: e, seriesIndex: l }), G.value = e, ct.value = { datapoint: e, seriesIndex: l, config: t.value, series: Me.value };
|
|
561
|
+
const o = t.value.style.chart.tooltip.customFormat;
|
|
562
|
+
if (sl(o) && lo(() => o({
|
|
563
|
+
seriesIndex: l,
|
|
550
564
|
datapoint: e,
|
|
551
565
|
series: Me.value,
|
|
552
566
|
config: t.value
|
|
553
567
|
})))
|
|
554
|
-
|
|
555
|
-
seriesIndex:
|
|
568
|
+
Qe.value = o({
|
|
569
|
+
seriesIndex: l,
|
|
556
570
|
datapoint: e,
|
|
557
571
|
series: Me.value,
|
|
558
572
|
config: t.value
|
|
559
573
|
});
|
|
560
574
|
else {
|
|
561
575
|
let a = "";
|
|
562
|
-
a += `<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${e.name}</div>`, a += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><rect x="0" y="0" height="12" width="12" stroke="none" fill="${e.color}"/></svg>`, a += `<b>${
|
|
576
|
+
a += `<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${e.name}</div>`, a += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><rect x="0" y="0" height="12" width="12" stroke="none" fill="${e.color}"/></svg>`, a += `<b>${Ke(
|
|
563
577
|
t.value.style.chart.layout.labels.formatter,
|
|
564
578
|
e.value,
|
|
565
579
|
De({
|
|
@@ -568,33 +582,33 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
568
582
|
s: t.value.style.chart.layout.labels.suffix,
|
|
569
583
|
r: t.value.style.chart.tooltip.roundingValue
|
|
570
584
|
}),
|
|
571
|
-
{ datapoint: e, seriesIndex:
|
|
572
|
-
)}</b>`,
|
|
585
|
+
{ datapoint: e, seriesIndex: l }
|
|
586
|
+
)}</b>`, Qe.value = `<div>${a}</div>`;
|
|
573
587
|
}
|
|
574
|
-
|
|
588
|
+
B.value = !0;
|
|
575
589
|
}
|
|
576
590
|
const j = y(() => {
|
|
577
|
-
const e = Ie.value.map((
|
|
578
|
-
name:
|
|
579
|
-
color:
|
|
580
|
-
})),
|
|
581
|
-
return { head: e, body:
|
|
591
|
+
const e = Ie.value.map((o) => ({
|
|
592
|
+
name: o.name,
|
|
593
|
+
color: o.color
|
|
594
|
+
})), l = Ie.value.map((o) => o.value);
|
|
595
|
+
return { head: e, body: l };
|
|
582
596
|
});
|
|
583
|
-
function
|
|
584
|
-
|
|
585
|
-
const
|
|
597
|
+
function vt(e = null) {
|
|
598
|
+
jl(() => {
|
|
599
|
+
const l = j.value.head.map((s, v) => [[
|
|
586
600
|
s.name
|
|
587
|
-
], [j.value.body[v]], [isNaN(j.value.body[v] / ke.value) ? "-" : j.value.body[v] / ke.value * 100]]),
|
|
588
|
-
e ? e(a) :
|
|
601
|
+
], [j.value.body[v]], [isNaN(j.value.body[v] / ke.value) ? "-" : j.value.body[v] / ke.value * 100]]), o = [[t.value.style.chart.title.text], [t.value.style.chart.title.subtitle.text], [[""], ["val"], ["%"]]].concat(l), a = eo(o);
|
|
602
|
+
e ? e(a) : to({ csvContent: a, title: t.value.style.chart.title.text || "vue-ui-treemap" });
|
|
589
603
|
});
|
|
590
604
|
}
|
|
591
|
-
const
|
|
605
|
+
const Ve = y(() => {
|
|
592
606
|
const e = [
|
|
593
607
|
t.value.table.columnNames.series,
|
|
594
608
|
t.value.table.columnNames.value,
|
|
595
609
|
t.value.table.columnNames.percentage
|
|
596
|
-
],
|
|
597
|
-
const k =
|
|
610
|
+
], l = j.value.head.map((s, v) => {
|
|
611
|
+
const k = Ke(
|
|
598
612
|
t.value.style.chart.layout.labels.formatter,
|
|
599
613
|
j.value.body[v],
|
|
600
614
|
De({
|
|
@@ -617,7 +631,7 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
617
631
|
r: t.value.table.td.roundingPercentage
|
|
618
632
|
})
|
|
619
633
|
];
|
|
620
|
-
}),
|
|
634
|
+
}), o = {
|
|
621
635
|
th: {
|
|
622
636
|
backgroundColor: t.value.table.th.backgroundColor,
|
|
623
637
|
color: t.value.table.th.color,
|
|
@@ -636,44 +650,44 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
636
650
|
t.value.table.columnNames.value
|
|
637
651
|
],
|
|
638
652
|
head: e,
|
|
639
|
-
body:
|
|
640
|
-
config:
|
|
653
|
+
body: l,
|
|
654
|
+
config: o
|
|
641
655
|
};
|
|
642
656
|
});
|
|
643
|
-
function
|
|
657
|
+
function Ol() {
|
|
644
658
|
return Ie.value;
|
|
645
659
|
}
|
|
646
|
-
function Gt() {
|
|
647
|
-
z.value.showTable = !z.value.showTable;
|
|
648
|
-
}
|
|
649
660
|
function Xt() {
|
|
650
|
-
|
|
661
|
+
P.value.showTable = !P.value.showTable;
|
|
662
|
+
}
|
|
663
|
+
function qt() {
|
|
664
|
+
P.value.showTooltip = !P.value.showTooltip;
|
|
651
665
|
}
|
|
652
666
|
const Be = b(!1);
|
|
653
|
-
function
|
|
667
|
+
function dt() {
|
|
654
668
|
Be.value = !Be.value;
|
|
655
669
|
}
|
|
656
|
-
const
|
|
657
|
-
function
|
|
658
|
-
|
|
670
|
+
const He = b(null);
|
|
671
|
+
function Yt(e) {
|
|
672
|
+
He.value = e;
|
|
659
673
|
}
|
|
660
|
-
function
|
|
661
|
-
|
|
674
|
+
function jt() {
|
|
675
|
+
He.value = null;
|
|
662
676
|
}
|
|
663
|
-
async function
|
|
677
|
+
async function _l({ scale: e = 2 } = {}) {
|
|
664
678
|
if (!U.value) return;
|
|
665
|
-
const { width:
|
|
679
|
+
const { width: l, height: o } = U.value.getBoundingClientRect(), a = l / o, { imageUri: s, base64: v } = await vo({ domElement: U.value, base64: !0, img: !0, scale: e });
|
|
666
680
|
return {
|
|
667
681
|
imageUri: s,
|
|
668
682
|
base64: v,
|
|
669
683
|
title: t.value.style.chart.title.text,
|
|
670
|
-
width:
|
|
671
|
-
height:
|
|
684
|
+
width: l,
|
|
685
|
+
height: o,
|
|
672
686
|
aspectRatio: a
|
|
673
687
|
};
|
|
674
688
|
}
|
|
675
689
|
const Ne = y(() => {
|
|
676
|
-
const e = t.value.table.useDialog && !t.value.table.show,
|
|
690
|
+
const e = t.value.table.useDialog && !t.value.table.show, l = P.value.showTable;
|
|
677
691
|
return {
|
|
678
692
|
component: e ? Q : f,
|
|
679
693
|
title: `${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text ? `: ${t.value.style.chart.title.subtitle.text}` : ""}`,
|
|
@@ -688,7 +702,7 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
688
702
|
} : {
|
|
689
703
|
hideDetails: !0,
|
|
690
704
|
config: {
|
|
691
|
-
open:
|
|
705
|
+
open: l,
|
|
692
706
|
maxHeight: 1e4,
|
|
693
707
|
body: {
|
|
694
708
|
backgroundColor: t.value.style.chart.backgroundColor,
|
|
@@ -702,35 +716,35 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
702
716
|
}
|
|
703
717
|
};
|
|
704
718
|
});
|
|
705
|
-
|
|
719
|
+
Ge(() => P.value.showTable, (e) => {
|
|
706
720
|
t.value.table.show || (e && t.value.table.useDialog && Ae.value ? Ae.value.open() : "close" in Ae.value && Ae.value.close());
|
|
707
721
|
});
|
|
708
|
-
function
|
|
709
|
-
|
|
722
|
+
function Zt() {
|
|
723
|
+
P.value.showTable = !1, ot.value && ot.value.setTableIconState(!1);
|
|
710
724
|
}
|
|
711
|
-
const
|
|
725
|
+
const Al = y(() => it.value.map((e) => ({
|
|
712
726
|
...e,
|
|
713
727
|
name: e.display
|
|
714
|
-
}))),
|
|
715
|
-
svg:
|
|
716
|
-
title:
|
|
717
|
-
legend:
|
|
718
|
-
legendItems:
|
|
719
|
-
backgroundColor:
|
|
728
|
+
}))), Fl = y(() => t.value.style.chart.backgroundColor), Ml = y(() => t.value.style.chart.legend), Il = y(() => t.value.style.chart.title), { exportSvg: Nl, getSvg: Ll } = go({
|
|
729
|
+
svg: st,
|
|
730
|
+
title: Il,
|
|
731
|
+
legend: Ml,
|
|
732
|
+
legendItems: Al,
|
|
733
|
+
backgroundColor: Fl
|
|
720
734
|
});
|
|
721
|
-
async function
|
|
735
|
+
async function Kt({ isCb: e }) {
|
|
722
736
|
if (e) {
|
|
723
|
-
const { blob:
|
|
724
|
-
t.value.userOptions.callbacks.svg({ blob:
|
|
737
|
+
const { blob: l, url: o, text: a, dataUrl: s } = await Ll();
|
|
738
|
+
t.value.userOptions.callbacks.svg({ blob: l, url: o, text: a, dataUrl: s });
|
|
725
739
|
} else
|
|
726
|
-
|
|
740
|
+
Nl();
|
|
727
741
|
}
|
|
728
|
-
function
|
|
729
|
-
const
|
|
730
|
-
if (!
|
|
731
|
-
const s = Math.max(2, xe(e) / 3), v = Math.max(8, xe(e)), k = v * 1.2,
|
|
732
|
-
if (
|
|
733
|
-
const oe = t.value.style.fontFamily,
|
|
742
|
+
function Dl({ rect: e, seriesIndex: l }) {
|
|
743
|
+
const o = t.value.style.chart.layout.labels.name.show, a = t.value.style.chart.layout.labels.value.show;
|
|
744
|
+
if (!o && !a) return "";
|
|
745
|
+
const s = Math.max(2, xe(e) / 3), v = Math.max(8, xe(e)), k = v * 1.2, L = Math.max(0, $e(e) - s * 2), ce = Math.max(0, Ce(e) - s * 2);
|
|
746
|
+
if (L <= 2 || ce <= v * 0.8) return "";
|
|
747
|
+
const oe = t.value.style.fontFamily, Ee = t.value.style.chart.layout.labels.name.bold ? "600" : "400", ae = t.value.style.chart.layout.labels.value.bold ? "600" : "400", ne = nl(e.color), ht = o ? String(e.name ?? "") : "", We = a ? Ke(
|
|
734
748
|
t.value.style.chart.layout.labels.formatter,
|
|
735
749
|
e.value,
|
|
736
750
|
De({
|
|
@@ -739,38 +753,38 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
739
753
|
s: t.value.style.chart.layout.labels.suffix,
|
|
740
754
|
r: t.value.style.chart.layout.labels.rounding
|
|
741
755
|
}),
|
|
742
|
-
{ datapoint: e, seriesIndex:
|
|
756
|
+
{ datapoint: e, seriesIndex: l }
|
|
743
757
|
) : "";
|
|
744
758
|
function ve(he, fe = v, _e = "400") {
|
|
745
|
-
const
|
|
746
|
-
|
|
747
|
-
const X = document.createElementNS(
|
|
748
|
-
X.setAttribute("font-size", String(fe)), X.setAttribute("font-family", oe), X.setAttribute("font-weight", String(_e)), X.textContent = he || "",
|
|
749
|
-
const
|
|
750
|
-
return document.body.removeChild(
|
|
759
|
+
const E = document.createElementNS($t, "svg");
|
|
760
|
+
E.setAttribute("width", "0"), E.setAttribute("height", "0"), E.style.position = "absolute", E.style.visibility = "hidden", E.style.pointerEvents = "none";
|
|
761
|
+
const X = document.createElementNS($t, "text");
|
|
762
|
+
X.setAttribute("font-size", String(fe)), X.setAttribute("font-family", oe), X.setAttribute("font-weight", String(_e)), X.textContent = he || "", E.appendChild(X), document.body.appendChild(E);
|
|
763
|
+
const Qt = X.getComputedTextLength();
|
|
764
|
+
return document.body.removeChild(E), Qt;
|
|
751
765
|
}
|
|
752
|
-
function
|
|
753
|
-
const
|
|
766
|
+
function Rl(he, fe, _e, E, X, Qt) {
|
|
767
|
+
const Bl = String(he).split(/\s+/).filter(Boolean), A = [];
|
|
754
768
|
let se = "";
|
|
755
769
|
function pe(S) {
|
|
756
|
-
return ve(S, _e,
|
|
770
|
+
return ve(S, _e, E) <= fe;
|
|
757
771
|
}
|
|
758
|
-
function
|
|
772
|
+
function Hl(S) {
|
|
759
773
|
if (pe(S)) return [S];
|
|
760
774
|
const K = [];
|
|
761
775
|
let C = 0;
|
|
762
776
|
for (; C < S.length; ) {
|
|
763
|
-
let
|
|
764
|
-
for (;
|
|
765
|
-
const
|
|
766
|
-
pe(
|
|
777
|
+
let gt = 1, mt = S.length - C, yt = 1;
|
|
778
|
+
for (; gt <= mt; ) {
|
|
779
|
+
const Ue = gt + mt >> 1, Wl = S.slice(C, C + Ue);
|
|
780
|
+
pe(Wl) ? (yt = Ue, gt = Ue + 1) : mt = Ue - 1;
|
|
767
781
|
}
|
|
768
|
-
K.push(S.slice(C, C +
|
|
782
|
+
K.push(S.slice(C, C + yt)), C += yt;
|
|
769
783
|
}
|
|
770
784
|
return K;
|
|
771
785
|
}
|
|
772
|
-
const
|
|
773
|
-
for (const S of
|
|
786
|
+
const El = Bl.flatMap((S) => Hl(S));
|
|
787
|
+
for (const S of El) {
|
|
774
788
|
const K = se ? se + " " + S : S;
|
|
775
789
|
if (pe(K))
|
|
776
790
|
se = K;
|
|
@@ -793,29 +807,29 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
793
807
|
}
|
|
794
808
|
return A;
|
|
795
809
|
}
|
|
796
|
-
const
|
|
797
|
-
if (
|
|
810
|
+
const Pl = a ? 1 : 0, Jt = Math.max(0, Math.floor(ce / k) - Pl);
|
|
811
|
+
if (Jt <= 0) {
|
|
798
812
|
if (!a) return "";
|
|
799
|
-
const he = e.x0 + s, fe = e.y0 + s + v, _e =
|
|
800
|
-
return ve(_e, v, ae) <=
|
|
813
|
+
const he = e.x0 + s, fe = e.y0 + s + v, _e = xt(We);
|
|
814
|
+
return ve(_e, v, ae) <= L ? `
|
|
801
815
|
<text
|
|
802
816
|
x="${he}"
|
|
803
817
|
y="${fe}"
|
|
804
818
|
font-size="${v}"
|
|
805
|
-
font-family="${
|
|
819
|
+
font-family="${Je(oe)}"
|
|
806
820
|
font-weight="${ae}"
|
|
807
|
-
fill="${
|
|
821
|
+
fill="${Je(ne)}"
|
|
808
822
|
>
|
|
809
823
|
${_e}
|
|
810
824
|
</text>` : "";
|
|
811
825
|
}
|
|
812
|
-
const de =
|
|
813
|
-
let Oe = v, Z = String(
|
|
826
|
+
const de = o ? Rl(ht, L, v, Ee, Jt) : [];
|
|
827
|
+
let Oe = v, Z = String(We);
|
|
814
828
|
if (a) {
|
|
815
|
-
for (; ve(Z, Oe, ae) >
|
|
829
|
+
for (; ve(Z, Oe, ae) > L && Oe > Math.max(8, v * 0.75); )
|
|
816
830
|
Oe -= 1;
|
|
817
|
-
if (ve(Z, Oe, ae) >
|
|
818
|
-
for (; Z.length && ve(Z + "…", Oe, ae) >
|
|
831
|
+
if (ve(Z, Oe, ae) > L) {
|
|
832
|
+
for (; Z.length && ve(Z + "…", Oe, ae) > L; )
|
|
819
833
|
Z = Z.slice(0, -1);
|
|
820
834
|
if (Z += "…", !Z.length) return "";
|
|
821
835
|
}
|
|
@@ -825,89 +839,91 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
825
839
|
de.pop();
|
|
826
840
|
if (!de.length && (!a || k > ce)) return "";
|
|
827
841
|
}
|
|
828
|
-
const
|
|
829
|
-
return
|
|
830
|
-
|
|
842
|
+
const ft = e.x0 + s, Vl = e.y0 + s + v, pt = [];
|
|
843
|
+
return o && de.forEach((he, fe) => {
|
|
844
|
+
pt.push(
|
|
831
845
|
`
|
|
832
846
|
<tspan
|
|
833
|
-
x="${
|
|
847
|
+
x="${ft}"
|
|
834
848
|
dy="${fe === 0 ? 0 : k}"
|
|
835
|
-
font-weight="${
|
|
849
|
+
font-weight="${Ee}"
|
|
836
850
|
>
|
|
837
|
-
${
|
|
851
|
+
${xt(he)}
|
|
838
852
|
</tspan>`
|
|
839
853
|
);
|
|
840
|
-
}), a &&
|
|
854
|
+
}), a && pt.push(
|
|
841
855
|
`
|
|
842
856
|
<tspan
|
|
843
|
-
x="${
|
|
857
|
+
x="${ft}"
|
|
844
858
|
dy="${de.length ? k : 0}"
|
|
845
859
|
font-weight="${ae}"
|
|
846
860
|
font-size="${Oe}"
|
|
847
861
|
>
|
|
848
|
-
${
|
|
862
|
+
${xt(Z)}
|
|
849
863
|
</tspan>`
|
|
850
864
|
), `<text
|
|
851
|
-
x="${
|
|
852
|
-
y="${
|
|
865
|
+
x="${ft}"
|
|
866
|
+
y="${Vl}"
|
|
853
867
|
font-size="${v}"
|
|
854
|
-
font-family="${
|
|
855
|
-
fill="${
|
|
868
|
+
font-family="${Je(oe)}"
|
|
869
|
+
fill="${Je(ne)}"
|
|
856
870
|
paint-order="stroke"
|
|
857
871
|
stroke="transparent"
|
|
858
872
|
stroke-width="0"
|
|
859
873
|
style="transition: all 0.2s ease-in-out;"
|
|
860
874
|
>
|
|
861
|
-
${
|
|
875
|
+
${pt.join("")}
|
|
862
876
|
</text>`;
|
|
863
877
|
}
|
|
864
|
-
function
|
|
865
|
-
const
|
|
866
|
-
return Math.min(
|
|
878
|
+
function zl(e) {
|
|
879
|
+
const l = t.value.style.chart.layout.rects.borderRadius, o = $e(e), a = Ce(e);
|
|
880
|
+
return Math.min(l, Math.min(o, a) / 6);
|
|
867
881
|
}
|
|
868
882
|
return i({
|
|
869
|
-
getData:
|
|
870
|
-
getImage:
|
|
871
|
-
generateCsv:
|
|
872
|
-
generateImage:
|
|
873
|
-
generateSvg:
|
|
874
|
-
generatePdf:
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
883
|
+
getData: Ol,
|
|
884
|
+
getImage: _l,
|
|
885
|
+
generateCsv: vt,
|
|
886
|
+
generateImage: Pt,
|
|
887
|
+
generateSvg: Kt,
|
|
888
|
+
generatePdf: Rt,
|
|
889
|
+
hideSeries: xl,
|
|
890
|
+
showSeries: $l,
|
|
891
|
+
toggleTable: Xt,
|
|
892
|
+
toggleTooltip: qt,
|
|
893
|
+
toggleAnnotator: dt,
|
|
894
|
+
toggleFullscreen: Ut
|
|
895
|
+
}), (e, l) => (h(), w("div", {
|
|
880
896
|
ref_key: "treemapChart",
|
|
881
897
|
ref: U,
|
|
882
|
-
class:
|
|
898
|
+
class: bt(`vue-data-ui-component vue-ui-treemap ${ie.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${t.value.useCssAnimation ? "" : "vue-ui-dna"}`),
|
|
883
899
|
style: ue(`font-family:${t.value.style.fontFamily};width:100%; ${t.value.responsive ? "height: 100%;" : ""} text-align:center;background:${t.value.style.chart.backgroundColor}`),
|
|
884
900
|
id: `treemap_${I.value}`,
|
|
885
|
-
onMouseenter:
|
|
886
|
-
onMouseleave:
|
|
901
|
+
onMouseenter: l[2] || (l[2] = () => p(Nt)(!0)),
|
|
902
|
+
onMouseleave: l[3] || (l[3] = () => p(Nt)(!1))
|
|
887
903
|
}, [
|
|
888
904
|
t.value.userOptions.buttons.annotator ? (h(), re(p(r), {
|
|
889
905
|
key: 0,
|
|
890
|
-
svgRef: p(
|
|
906
|
+
svgRef: p(st),
|
|
891
907
|
backgroundColor: t.value.style.chart.backgroundColor,
|
|
892
908
|
color: t.value.style.chart.color,
|
|
893
909
|
active: Be.value,
|
|
894
|
-
onClose:
|
|
910
|
+
onClose: dt
|
|
895
911
|
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : M("", !0),
|
|
896
|
-
|
|
912
|
+
fl.value ? (h(), w("div", {
|
|
897
913
|
key: 1,
|
|
898
914
|
ref_key: "noTitle",
|
|
899
|
-
ref:
|
|
915
|
+
ref: Ft,
|
|
900
916
|
class: "vue-data-ui-no-title-space",
|
|
901
917
|
style: "height:36px; width: 100%;background:transparent"
|
|
902
918
|
}, null, 512)) : M("", !0),
|
|
903
919
|
t.value.style.chart.title.text ? (h(), w("div", {
|
|
904
920
|
key: 2,
|
|
905
921
|
ref_key: "chartTitle",
|
|
906
|
-
ref:
|
|
922
|
+
ref: Ot,
|
|
907
923
|
style: ue(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:6px`)
|
|
908
924
|
}, [
|
|
909
|
-
(h(), re(
|
|
910
|
-
key: `title_${
|
|
925
|
+
(h(), re(ho, {
|
|
926
|
+
key: `title_${Mt.value}`,
|
|
911
927
|
config: {
|
|
912
928
|
title: {
|
|
913
929
|
cy: "treemap-div-title",
|
|
@@ -920,17 +936,17 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
920
936
|
}
|
|
921
937
|
}, null, 8, ["config"]))
|
|
922
938
|
], 4)) : M("", !0),
|
|
923
|
-
|
|
939
|
+
V("div", {
|
|
924
940
|
id: `legend-top-${I.value}`
|
|
925
|
-
}, null, 8,
|
|
926
|
-
t.value.userOptions.show &&
|
|
941
|
+
}, null, 8, Oo),
|
|
942
|
+
t.value.userOptions.show && z.value && (p(Lt) || p(nt)) ? (h(), re(p(m), {
|
|
927
943
|
ref_key: "userOptionsRef",
|
|
928
|
-
ref:
|
|
929
|
-
key: `user_option_${
|
|
944
|
+
ref: ot,
|
|
945
|
+
key: `user_option_${St.value}`,
|
|
930
946
|
backgroundColor: t.value.style.chart.backgroundColor,
|
|
931
947
|
color: t.value.style.chart.color,
|
|
932
|
-
isPrinting: p(
|
|
933
|
-
isImaging: p(
|
|
948
|
+
isPrinting: p(Dt),
|
|
949
|
+
isImaging: p(zt),
|
|
934
950
|
uid: I.value,
|
|
935
951
|
hasTooltip: t.value.userOptions.buttons.tooltip && t.value.style.chart.tooltip.show,
|
|
936
952
|
hasPdf: t.value.userOptions.buttons.pdf,
|
|
@@ -940,7 +956,7 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
940
956
|
hasTable: t.value.userOptions.buttons.table,
|
|
941
957
|
hasFullscreen: t.value.userOptions.buttons.fullscreen,
|
|
942
958
|
isFullscreen: ie.value,
|
|
943
|
-
isTooltip:
|
|
959
|
+
isTooltip: P.value.showTooltip,
|
|
944
960
|
titles: { ...t.value.userOptions.buttonTitles },
|
|
945
961
|
chartElement: U.value,
|
|
946
962
|
position: t.value.userOptions.position,
|
|
@@ -949,22 +965,22 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
949
965
|
callbacks: t.value.userOptions.callbacks,
|
|
950
966
|
printScale: t.value.userOptions.print.scale,
|
|
951
967
|
tableDialog: t.value.table.useDialog,
|
|
952
|
-
onToggleFullscreen:
|
|
953
|
-
onGeneratePdf: p(
|
|
954
|
-
onGenerateCsv:
|
|
955
|
-
onGenerateImage: p(
|
|
956
|
-
onGenerateSvg:
|
|
957
|
-
onToggleTable:
|
|
958
|
-
onToggleTooltip:
|
|
959
|
-
onToggleAnnotator:
|
|
968
|
+
onToggleFullscreen: Ut,
|
|
969
|
+
onGeneratePdf: p(Rt),
|
|
970
|
+
onGenerateCsv: vt,
|
|
971
|
+
onGenerateImage: p(Pt),
|
|
972
|
+
onGenerateSvg: Kt,
|
|
973
|
+
onToggleTable: Xt,
|
|
974
|
+
onToggleTooltip: qt,
|
|
975
|
+
onToggleAnnotator: dt,
|
|
960
976
|
style: ue({
|
|
961
|
-
visibility: p(
|
|
977
|
+
visibility: p(Lt) ? p(nt) ? "visible" : "hidden" : "visible"
|
|
962
978
|
})
|
|
963
|
-
},
|
|
979
|
+
}, tl({ _: 2 }, [
|
|
964
980
|
e.$slots.menuIcon ? {
|
|
965
981
|
name: "menuIcon",
|
|
966
|
-
fn: O(({ isOpen:
|
|
967
|
-
$(e.$slots, "menuIcon", me(ye({ isOpen:
|
|
982
|
+
fn: O(({ isOpen: o, color: a }) => [
|
|
983
|
+
$(e.$slots, "menuIcon", me(ye({ isOpen: o, color: a })), void 0, !0)
|
|
968
984
|
]),
|
|
969
985
|
key: "0"
|
|
970
986
|
} : void 0,
|
|
@@ -1012,15 +1028,15 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1012
1028
|
} : void 0,
|
|
1013
1029
|
e.$slots.optionFullscreen ? {
|
|
1014
1030
|
name: "optionFullscreen",
|
|
1015
|
-
fn: O(({ toggleFullscreen:
|
|
1016
|
-
$(e.$slots, "optionFullscreen", me(ye({ toggleFullscreen:
|
|
1031
|
+
fn: O(({ toggleFullscreen: o, isFullscreen: a }) => [
|
|
1032
|
+
$(e.$slots, "optionFullscreen", me(ye({ toggleFullscreen: o, isFullscreen: a })), void 0, !0)
|
|
1017
1033
|
]),
|
|
1018
1034
|
key: "7"
|
|
1019
1035
|
} : void 0,
|
|
1020
1036
|
e.$slots.optionAnnotator ? {
|
|
1021
1037
|
name: "optionAnnotator",
|
|
1022
|
-
fn: O(({ toggleAnnotator:
|
|
1023
|
-
$(e.$slots, "optionAnnotator", me(ye({ toggleAnnotator:
|
|
1038
|
+
fn: O(({ toggleAnnotator: o, isAnnotator: a }) => [
|
|
1039
|
+
$(e.$slots, "optionAnnotator", me(ye({ toggleAnnotator: o, isAnnotator: a })), void 0, !0)
|
|
1024
1040
|
]),
|
|
1025
1041
|
key: "8"
|
|
1026
1042
|
} : void 0
|
|
@@ -1030,181 +1046,181 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1030
1046
|
class: "vue-ui-treemap-breadcrumbs",
|
|
1031
1047
|
"data-dom-to-png-ignore": "",
|
|
1032
1048
|
ref_key: "breadcrumbsNav",
|
|
1033
|
-
ref:
|
|
1049
|
+
ref: lt
|
|
1034
1050
|
}, [
|
|
1035
|
-
(h(!0), w(
|
|
1051
|
+
(h(!0), w(qe, null, wt(Y.value, (o, a) => (h(), w("span", {
|
|
1036
1052
|
role: "button",
|
|
1037
1053
|
tabindex: a < Y.value.length - 1 ? 0 : void 0,
|
|
1038
|
-
key:
|
|
1054
|
+
key: o.id || "root",
|
|
1039
1055
|
onClick: (s) => a === Y.value.length - 1 ? () => {
|
|
1040
|
-
} : Re(
|
|
1056
|
+
} : Re(o.node),
|
|
1041
1057
|
onKeydown: [
|
|
1042
|
-
|
|
1043
|
-
|
|
1058
|
+
ll(kt((s) => a === Y.value.length - 1 ? void 0 : Re(o.node), ["prevent"]), ["enter"]),
|
|
1059
|
+
ll(kt((s) => a === Y.value.length - 1 ? void 0 : Re(o.node), ["prevent"]), ["space"])
|
|
1044
1060
|
],
|
|
1045
1061
|
class: "vue-ui-treemap-crumb",
|
|
1046
1062
|
"data-last-crumb": a === Y.value.length - 1,
|
|
1047
1063
|
style: ue({
|
|
1048
1064
|
color: t.value.style.chart.color
|
|
1049
1065
|
}),
|
|
1050
|
-
onMouseenter: (s) =>
|
|
1051
|
-
onMouseleave:
|
|
1052
|
-
onFocus: (s) =>
|
|
1053
|
-
onBlur:
|
|
1066
|
+
onMouseenter: (s) => Yt(a),
|
|
1067
|
+
onMouseleave: jt,
|
|
1068
|
+
onFocus: (s) => Yt(a),
|
|
1069
|
+
onBlur: jt
|
|
1054
1070
|
}, [
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
$(e.$slots, "breadcrumb-label",
|
|
1058
|
-
a === 0 ? (h(), w("div",
|
|
1059
|
-
|
|
1060
|
-
name:
|
|
1071
|
+
V("span", Ao, [
|
|
1072
|
+
V("span", Fo, [
|
|
1073
|
+
$(e.$slots, "breadcrumb-label", Ct({ ref_for: !0 }, { crumb: o, isRoot: a === 0, isFocus: He.value === a }), () => [
|
|
1074
|
+
a === 0 ? (h(), w("div", Mo, [
|
|
1075
|
+
Xe(rl, {
|
|
1076
|
+
name: He.value === 0 ? "homeFilled" : "home",
|
|
1061
1077
|
stroke: t.value.style.chart.color
|
|
1062
1078
|
}, null, 8, ["name", "stroke"])
|
|
1063
|
-
])) : (h(), w(
|
|
1064
|
-
|
|
1079
|
+
])) : (h(), w(qe, { key: 1 }, [
|
|
1080
|
+
Ye(je(o.label), 1)
|
|
1065
1081
|
], 64))
|
|
1066
1082
|
], !0)
|
|
1067
1083
|
]),
|
|
1068
|
-
a < Y.value.length - 1 ? (h(), w("span",
|
|
1084
|
+
a < Y.value.length - 1 ? (h(), w("span", Io, [
|
|
1069
1085
|
$(e.$slots, "breadcrumb-arrow", {}, () => [
|
|
1070
|
-
|
|
1086
|
+
l[4] || (l[4] = Ye(" › ", -1))
|
|
1071
1087
|
], !0)
|
|
1072
1088
|
])) : M("", !0)
|
|
1073
1089
|
])
|
|
1074
|
-
], 44,
|
|
1090
|
+
], 44, _o))), 128))
|
|
1075
1091
|
], 512)) : M("", !0),
|
|
1076
1092
|
(h(), w("svg", {
|
|
1077
1093
|
ref_key: "svgRef",
|
|
1078
|
-
ref:
|
|
1079
|
-
xmlns: p(
|
|
1080
|
-
class:
|
|
1094
|
+
ref: st,
|
|
1095
|
+
xmlns: p($t),
|
|
1096
|
+
class: bt({ "vue-data-ui-fullscreen--on": ie.value, "vue-data-ui-fulscreen--off": !ie.value, "vue-data-ui-zoom-plus": !Se.value, "vue-data-ui-zoom-minus": Se.value, loading: p(be) }),
|
|
1081
1097
|
viewBox: `${Te.value.startX} ${Te.value.startY} ${Te.value.width <= 0 ? 10 : Te.value.width} ${Te.value.height <= 0 ? 10 : Te.value.height}`,
|
|
1082
1098
|
style: ue(`max-width:100%; overflow: hidden; background:transparent;color:${t.value.style.chart.color}`)
|
|
1083
1099
|
}, [
|
|
1084
|
-
|
|
1085
|
-
(h(!0), w(
|
|
1086
|
-
key: `tgrad_${
|
|
1100
|
+
Xe(p(g)),
|
|
1101
|
+
(h(!0), w(qe, null, wt(Ie.value, (o, a) => (h(), w("g", {
|
|
1102
|
+
key: `tgrad_${o.id}`
|
|
1087
1103
|
}, [
|
|
1088
|
-
t.value.style.chart.layout.rects.gradient.show ? (h(), w("defs",
|
|
1089
|
-
|
|
1090
|
-
id: `tgrad_${
|
|
1104
|
+
t.value.style.chart.layout.rects.gradient.show ? (h(), w("defs", Lo, [
|
|
1105
|
+
V("radialGradient", {
|
|
1106
|
+
id: `tgrad_${o.id}`,
|
|
1091
1107
|
gradientTransform: "translate(-1, -1.000001) scale(2, 2)"
|
|
1092
1108
|
}, [
|
|
1093
|
-
|
|
1109
|
+
V("stop", {
|
|
1094
1110
|
offset: "18%",
|
|
1095
|
-
"stop-color":
|
|
1096
|
-
}, null, 8,
|
|
1097
|
-
|
|
1111
|
+
"stop-color": o.color
|
|
1112
|
+
}, null, 8, zo),
|
|
1113
|
+
V("stop", {
|
|
1098
1114
|
offset: "100%",
|
|
1099
|
-
"stop-color": p(
|
|
1100
|
-
}, null, 8,
|
|
1101
|
-
], 8,
|
|
1115
|
+
"stop-color": p(al)(o.color, t.value.style.chart.layout.rects.gradient.intensity / 100)
|
|
1116
|
+
}, null, 8, Ro)
|
|
1117
|
+
], 8, Do)
|
|
1102
1118
|
])) : M("", !0)
|
|
1103
1119
|
]))), 128)),
|
|
1104
|
-
(h(!0), w(
|
|
1105
|
-
key: `k_${
|
|
1120
|
+
(h(!0), w(qe, null, wt(Ie.value, (o, a) => (h(), w("g", {
|
|
1121
|
+
key: `k_${o.id}`
|
|
1106
1122
|
}, [
|
|
1107
|
-
|
|
1108
|
-
x:
|
|
1109
|
-
y:
|
|
1110
|
-
height: Ce(
|
|
1111
|
-
width: $e(
|
|
1112
|
-
fill: q.value ?
|
|
1113
|
-
rx:
|
|
1114
|
-
stroke: G.value && G.value.id ===
|
|
1115
|
-
"stroke-width": G.value && G.value.id ===
|
|
1116
|
-
onClick:
|
|
1117
|
-
onMouseenter: () =>
|
|
1118
|
-
datapoint:
|
|
1123
|
+
V("rect", {
|
|
1124
|
+
x: o.x0,
|
|
1125
|
+
y: o.y0,
|
|
1126
|
+
height: Ce(o),
|
|
1127
|
+
width: $e(o),
|
|
1128
|
+
fill: q.value ? o.color : t.value.style.chart.layout.rects.gradient.show ? `url(#tgrad_${o.id})` : o.color,
|
|
1129
|
+
rx: zl(o),
|
|
1130
|
+
stroke: G.value && G.value.id === o.id ? t.value.style.chart.layout.rects.selected.stroke : t.value.style.chart.layout.rects.stroke,
|
|
1131
|
+
"stroke-width": G.value && G.value.id === o.id ? t.value.style.chart.layout.rects.selected.strokeWidth : t.value.style.chart.layout.rects.strokeWidth,
|
|
1132
|
+
onClick: kt((s) => Re(o, a), ["stop"]),
|
|
1133
|
+
onMouseenter: () => Sl({
|
|
1134
|
+
datapoint: o,
|
|
1119
1135
|
seriesIndex: a
|
|
1120
1136
|
}),
|
|
1121
|
-
onMouseleave: (s) =>
|
|
1122
|
-
style: ue(`opacity:${G.value ? G.value.id ===
|
|
1123
|
-
class:
|
|
1137
|
+
onMouseleave: (s) => Tl({ datapoint: o, seriesIndex: a }),
|
|
1138
|
+
style: ue(`opacity:${G.value ? G.value.id === o.id ? 1 : t.value.style.chart.layout.rects.selected.unselectedOpacity : 1}`),
|
|
1139
|
+
class: bt([
|
|
1124
1140
|
"vue-ui-treemap-rect",
|
|
1125
|
-
|
|
1141
|
+
kl(o) ? "vue-data-ui-zoom-plus" : Se.value ? "vue-data-ui-zoom-minus" : ""
|
|
1126
1142
|
])
|
|
1127
|
-
}, null, 46,
|
|
1143
|
+
}, null, 46, Po),
|
|
1128
1144
|
!e.$slots.rect && !p(be) && t.value.style.chart.layout.labels.showDefaultLabels ? (h(), w("g", {
|
|
1129
1145
|
key: 0,
|
|
1130
1146
|
style: { "pointer-events": "none" },
|
|
1131
|
-
innerHTML:
|
|
1132
|
-
}, null, 8,
|
|
1147
|
+
innerHTML: Dl({ rect: o, seriesIndex: a })
|
|
1148
|
+
}, null, 8, Vo)) : M("", !0),
|
|
1133
1149
|
(h(), w("foreignObject", {
|
|
1134
|
-
x:
|
|
1135
|
-
y:
|
|
1136
|
-
height: Ce(
|
|
1137
|
-
width: $e(
|
|
1150
|
+
x: o.x0,
|
|
1151
|
+
y: o.y0,
|
|
1152
|
+
height: Ce(o),
|
|
1153
|
+
width: $e(o),
|
|
1138
1154
|
class: "vue-ui-treemap-cell-foreignObject"
|
|
1139
1155
|
}, [
|
|
1140
|
-
|
|
1156
|
+
V("div", {
|
|
1141
1157
|
style: ue({
|
|
1142
|
-
width: `calc(100% - ${xe(
|
|
1143
|
-
height: `calc(100% - ${xe(
|
|
1144
|
-
padding: `${xe(
|
|
1158
|
+
width: `calc(100% - ${xe(o) / 1.5}px)`,
|
|
1159
|
+
height: `calc(100% - ${xe(o) / 1.5}px)`,
|
|
1160
|
+
padding: `${xe(o) / 3}px`
|
|
1145
1161
|
}),
|
|
1146
1162
|
class: "vue-ui-treemap-cell"
|
|
1147
1163
|
}, [
|
|
1148
|
-
p(be) ? M("", !0) : $(e.$slots, "rect",
|
|
1164
|
+
p(be) ? M("", !0) : $(e.$slots, "rect", Ct({
|
|
1149
1165
|
key: 0,
|
|
1150
1166
|
ref_for: !0
|
|
1151
1167
|
}, {
|
|
1152
|
-
rect:
|
|
1153
|
-
shouldShow:
|
|
1154
|
-
fontSize: xe(
|
|
1168
|
+
rect: o,
|
|
1169
|
+
shouldShow: o.proportion > t.value.style.chart.layout.labels.hideUnderProportion || Se.value,
|
|
1170
|
+
fontSize: xe(o),
|
|
1155
1171
|
isZoom: Se.value,
|
|
1156
|
-
textColor: p(
|
|
1172
|
+
textColor: p(nl)(o.color)
|
|
1157
1173
|
}), void 0, !0)
|
|
1158
1174
|
], 4)
|
|
1159
|
-
], 8,
|
|
1175
|
+
], 8, Bo))
|
|
1160
1176
|
]))), 128)),
|
|
1161
|
-
$(e.$slots, "svg", me(ye({ svg:
|
|
1162
|
-
], 14,
|
|
1163
|
-
e.$slots.watermark ? (h(), w("div",
|
|
1164
|
-
$(e.$slots, "watermark", me(ye({ isPrinting: p(
|
|
1177
|
+
$(e.$slots, "svg", me(ye({ svg: H.value, isZoom: Se.value, rect: G.value, config: t.value })), void 0, !0)
|
|
1178
|
+
], 14, No)),
|
|
1179
|
+
e.$slots.watermark ? (h(), w("div", Ho, [
|
|
1180
|
+
$(e.$slots, "watermark", me(ye({ isPrinting: p(Dt) || p(zt) })), void 0, !0)
|
|
1165
1181
|
])) : M("", !0),
|
|
1166
|
-
|
|
1182
|
+
V("div", {
|
|
1167
1183
|
id: `legend-bottom-${I.value}`
|
|
1168
|
-
}, null, 8,
|
|
1169
|
-
|
|
1184
|
+
}, null, 8, Eo),
|
|
1185
|
+
It.value ? (h(), re(ql, {
|
|
1170
1186
|
key: 6,
|
|
1171
1187
|
to: t.value.style.chart.legend.position === "top" ? `#legend-top-${I.value}` : `#legend-bottom-${I.value}`
|
|
1172
1188
|
}, [
|
|
1173
|
-
|
|
1189
|
+
V("div", {
|
|
1174
1190
|
ref_key: "chartLegend",
|
|
1175
|
-
ref:
|
|
1191
|
+
ref: _t
|
|
1176
1192
|
}, [
|
|
1177
|
-
t.value.style.chart.legend.show ? (h(), re(
|
|
1178
|
-
key: `legend_${
|
|
1179
|
-
legendSet:
|
|
1180
|
-
config:
|
|
1193
|
+
t.value.style.chart.legend.show ? (h(), re(po, {
|
|
1194
|
+
key: `legend_${tt.value}`,
|
|
1195
|
+
legendSet: it.value,
|
|
1196
|
+
config: Cl.value,
|
|
1181
1197
|
id: `treemap_legend_${I.value}`,
|
|
1182
|
-
onClickMarker:
|
|
1198
|
+
onClickMarker: l[0] || (l[0] = ({ legend: o }) => Pe(o))
|
|
1183
1199
|
}, {
|
|
1184
|
-
item: O(({ legend:
|
|
1200
|
+
item: O(({ legend: o, index: a }) => [
|
|
1185
1201
|
p(be) ? M("", !0) : (h(), w("div", {
|
|
1186
1202
|
key: 0,
|
|
1187
|
-
onClick: (s) =>
|
|
1188
|
-
style: ue(`opacity:${
|
|
1189
|
-
},
|
|
1203
|
+
onClick: (s) => Pe(o),
|
|
1204
|
+
style: ue(`opacity:${R.value.includes(o.id) ? 0.5 : 1}`)
|
|
1205
|
+
}, je(o.display), 13, Wo))
|
|
1190
1206
|
]),
|
|
1191
1207
|
_: 1
|
|
1192
1208
|
}, 8, ["legendSet", "config", "id"])) : $(e.$slots, "legend", {
|
|
1193
1209
|
key: 1,
|
|
1194
|
-
legend:
|
|
1210
|
+
legend: it.value
|
|
1195
1211
|
}, void 0, !0)
|
|
1196
1212
|
], 512)
|
|
1197
1213
|
], 8, ["to"])) : M("", !0),
|
|
1198
1214
|
e.$slots.source ? (h(), w("div", {
|
|
1199
1215
|
key: 7,
|
|
1200
1216
|
ref_key: "source",
|
|
1201
|
-
ref:
|
|
1217
|
+
ref: At,
|
|
1202
1218
|
dir: "auto"
|
|
1203
1219
|
}, [
|
|
1204
1220
|
$(e.$slots, "source", {}, void 0, !0)
|
|
1205
1221
|
], 512)) : M("", !0),
|
|
1206
|
-
|
|
1207
|
-
show:
|
|
1222
|
+
Xe(p(d), {
|
|
1223
|
+
show: P.value.showTooltip && B.value,
|
|
1208
1224
|
backgroundColor: t.value.style.chart.tooltip.backgroundColor,
|
|
1209
1225
|
color: t.value.style.chart.tooltip.color,
|
|
1210
1226
|
fontSize: t.value.style.chart.tooltip.fontSize,
|
|
@@ -1215,46 +1231,46 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1215
1231
|
position: t.value.style.chart.tooltip.position,
|
|
1216
1232
|
offsetY: t.value.style.chart.tooltip.offsetY,
|
|
1217
1233
|
parent: U.value,
|
|
1218
|
-
content:
|
|
1234
|
+
content: Qe.value,
|
|
1219
1235
|
isFullscreen: ie.value,
|
|
1220
|
-
isCustom: p(
|
|
1236
|
+
isCustom: p(sl)(t.value.style.chart.tooltip.customFormat),
|
|
1221
1237
|
smooth: t.value.style.chart.tooltip.smooth,
|
|
1222
1238
|
backdropFilter: t.value.style.chart.tooltip.backdropFilter,
|
|
1223
1239
|
smoothForce: t.value.style.chart.tooltip.smoothForce,
|
|
1224
1240
|
smoothSnapThreshold: t.value.style.chart.tooltip.smoothSnapThreshold
|
|
1225
1241
|
}, {
|
|
1226
1242
|
"tooltip-before": O(() => [
|
|
1227
|
-
$(e.$slots, "tooltip-before", me(ye({ ...
|
|
1243
|
+
$(e.$slots, "tooltip-before", me(ye({ ...ct.value })), void 0, !0)
|
|
1228
1244
|
]),
|
|
1229
1245
|
"tooltip-after": O(() => [
|
|
1230
|
-
$(e.$slots, "tooltip-after", me(ye({ ...
|
|
1246
|
+
$(e.$slots, "tooltip-after", me(ye({ ...ct.value })), void 0, !0)
|
|
1231
1247
|
]),
|
|
1232
1248
|
_: 3
|
|
1233
1249
|
}, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "position", "offsetY", "parent", "content", "isFullscreen", "isCustom", "smooth", "backdropFilter", "smoothForce", "smoothSnapThreshold"]),
|
|
1234
|
-
|
|
1250
|
+
z.value && t.value.userOptions.buttons.table ? (h(), re(Yl(Ne.value.component), Ct({ key: 8 }, Ne.value.props, {
|
|
1235
1251
|
ref_key: "tableUnit",
|
|
1236
1252
|
ref: Ae,
|
|
1237
|
-
onClose:
|
|
1238
|
-
}),
|
|
1253
|
+
onClose: Zt
|
|
1254
|
+
}), tl({
|
|
1239
1255
|
content: O(() => [
|
|
1240
1256
|
(h(), re(p(c), {
|
|
1241
|
-
key: `table_${
|
|
1242
|
-
colNames:
|
|
1243
|
-
head:
|
|
1244
|
-
body:
|
|
1245
|
-
config:
|
|
1257
|
+
key: `table_${et.value}`,
|
|
1258
|
+
colNames: Ve.value.colNames,
|
|
1259
|
+
head: Ve.value.head,
|
|
1260
|
+
body: Ve.value.body,
|
|
1261
|
+
config: Ve.value.config,
|
|
1246
1262
|
title: t.value.table.useDialog ? "" : Ne.value.title,
|
|
1247
1263
|
withCloseButton: !t.value.table.useDialog,
|
|
1248
|
-
onClose:
|
|
1264
|
+
onClose: Zt
|
|
1249
1265
|
}, {
|
|
1250
|
-
th: O(({ th:
|
|
1251
|
-
|
|
1252
|
-
innerHTML:
|
|
1266
|
+
th: O(({ th: o }) => [
|
|
1267
|
+
V("div", {
|
|
1268
|
+
innerHTML: o,
|
|
1253
1269
|
style: { display: "flex", "align-items": "center" }
|
|
1254
|
-
}, null, 8,
|
|
1270
|
+
}, null, 8, Uo)
|
|
1255
1271
|
]),
|
|
1256
|
-
td: O(({ td:
|
|
1257
|
-
|
|
1272
|
+
td: O(({ td: o }) => [
|
|
1273
|
+
Ye(je(o.name || o), 1)
|
|
1258
1274
|
]),
|
|
1259
1275
|
_: 1
|
|
1260
1276
|
}, 8, ["colNames", "head", "body", "config", "title", "withCloseButton"]))
|
|
@@ -1264,19 +1280,19 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1264
1280
|
t.value.table.useDialog ? {
|
|
1265
1281
|
name: "title",
|
|
1266
1282
|
fn: O(() => [
|
|
1267
|
-
|
|
1283
|
+
Ye(je(Ne.value.title), 1)
|
|
1268
1284
|
]),
|
|
1269
1285
|
key: "0"
|
|
1270
1286
|
} : void 0,
|
|
1271
1287
|
t.value.table.useDialog ? {
|
|
1272
1288
|
name: "actions",
|
|
1273
1289
|
fn: O(() => [
|
|
1274
|
-
|
|
1290
|
+
V("button", {
|
|
1275
1291
|
tabindex: "0",
|
|
1276
1292
|
class: "vue-ui-user-options-button",
|
|
1277
|
-
onClick:
|
|
1293
|
+
onClick: l[1] || (l[1] = (o) => vt(t.value.userOptions.callbacks.csv))
|
|
1278
1294
|
}, [
|
|
1279
|
-
|
|
1295
|
+
Xe(rl, {
|
|
1280
1296
|
name: "excel",
|
|
1281
1297
|
stroke: Ne.value.props.color
|
|
1282
1298
|
}, null, 8, ["stroke"])
|
|
@@ -1285,10 +1301,10 @@ const $o = ["id"], xo = ["id"], To = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1285
1301
|
key: "1"
|
|
1286
1302
|
} : void 0
|
|
1287
1303
|
]), 1040)) : M("", !0),
|
|
1288
|
-
p(be) ? (h(), re(
|
|
1289
|
-
], 46,
|
|
1304
|
+
p(be) ? (h(), re(uo, { key: 9 })) : M("", !0)
|
|
1305
|
+
], 46, So));
|
|
1290
1306
|
}
|
|
1291
|
-
},
|
|
1307
|
+
}, ra = /* @__PURE__ */ mo(Go, [["__scopeId", "data-v-2a889e26"]]);
|
|
1292
1308
|
export {
|
|
1293
|
-
|
|
1309
|
+
ra as default
|
|
1294
1310
|
};
|