vue-data-ui 3.2.7 → 3.3.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/dist/{Arrow-Bb0bGghy.js → Arrow-CKLBHe3L.js} +1 -1
- package/dist/{BaseDraggableDialog-CHhZIht2.js → BaseDraggableDialog-q3pgSDTz.js} +2 -2
- package/dist/{BaseIcon-Bz-1GQhu.js → BaseIcon-CtqN7W_g.js} +4 -3
- package/dist/{ColorPicker-B-WUqMoV.js → ColorPicker-Cr6rUDTP.js} +2 -2
- package/dist/{DataTable-BvjacRbw.js → DataTable-BeI6gYJX.js} +2 -2
- package/dist/{Legend-BpoFJ8fc.js → Legend-DsogCeTb.js} +2 -2
- package/dist/{NonSvgPenAndPaper-l9giyY1Z.js → NonSvgPenAndPaper-BDK_ucTG.js} +3 -3
- package/dist/{PackageVersion-Cwrh45ON.js → PackageVersion-C9oklnuy.js} +1 -1
- package/dist/{PenAndPaper-CR8q353D.js → PenAndPaper-BxbYiPy4.js} +3 -3
- package/dist/{Shape-C_C_OmqR.js → Shape-DJG2zW7b.js} +1 -1
- package/dist/{Slicer-BA2GhOmY.js → Slicer-D6T4aUhr.js} +2 -2
- package/dist/{SparkTooltip-Dz1PDE_h.js → SparkTooltip-Cp0G9giW.js} +1 -1
- package/dist/{Title-DG2nloSB.js → Title-D17CJXko.js} +1 -1
- package/dist/{Tooltip-BOXz8skU.js → Tooltip-CtVdvbZi.js} +1 -1
- package/dist/{UserOptions-DsTgvAok.js → UserOptions-B3vCIe-u.js} +168 -126
- package/dist/components/arrow.js +1 -1
- package/dist/components/vue-ui-3d-bar.js +1 -1
- package/dist/components/vue-ui-accordion.js +1 -1
- package/dist/components/vue-ui-age-pyramid.js +1 -1
- package/dist/components/vue-ui-annotator.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-cursor.js +1 -1
- package/dist/components/vue-ui-dashboard.js +1 -1
- package/dist/components/vue-ui-digits.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-icon.js +1 -1
- package/dist/components/vue-ui-kpi.js +1 -1
- package/dist/components/vue-ui-mini-loader.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-rating.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-smiley.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-heatmap.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/{dom-to-png-BgvOdfyW.js → dom-to-png-BiyqJA3t.js} +1 -1
- package/dist/{img-DjWwQXVS.js → img-6wPuVVtk.js} +1 -1
- package/dist/{lib-BEpWEyMm.js → lib-GIYcnm0E.js} +110 -96
- package/dist/{pdf-YD0ShN36.js → pdf-DjbHsnrb.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.ts +8 -1
- package/dist/{useAutoSizeLabelsInsideViewbox-BVJkib7z.js → useAutoSizeLabelsInsideViewbox-Csv3pVmh.js} +1 -1
- package/dist/{useNestedProp-BOk-tPdu.js → useNestedProp-mxyyqd0B.js} +291 -246
- package/dist/{usePrinter-w23K-ezx.js → usePrinter-DYRFiw7X.js} +2 -2
- package/dist/useSvgExport-B7-Vrjtu.js +732 -0
- package/dist/vue-data-ui-DLU1snC3.js +326 -0
- package/dist/vue-data-ui.js +68 -68
- package/dist/{vue-ui-3d-bar-CRXnB8wH.js → vue-ui-3d-bar-D6xoBrN6.js} +358 -342
- package/dist/{vue-ui-accordion-CeMTgpl0.js → vue-ui-accordion-Dch9YrCi.js} +19 -19
- package/dist/{vue-ui-age-pyramid-BEGsngR6.js → vue-ui-age-pyramid-D74mAaLA.js} +228 -212
- package/dist/{vue-ui-annotator-BhZr9pFJ.js → vue-ui-annotator-DwRwhrgB.js} +9 -9
- package/dist/{vue-ui-bullet-CrCHb15S.js → vue-ui-bullet-D2qVUqWs.js} +197 -179
- package/dist/{vue-ui-candlestick-CnWY88nd.js → vue-ui-candlestick-C81k1_f9.js} +279 -263
- package/dist/{vue-ui-carousel-table-CsVWXrdA.js → vue-ui-carousel-table-DBIhnEj-.js} +6 -6
- package/dist/{vue-ui-chestnut-NpO91zJV.js → vue-ui-chestnut-CSM-_IWw.js} +426 -380
- package/dist/{vue-ui-chord-bIihB6Qf.js → vue-ui-chord-BFW9nnNh.js} +318 -299
- package/dist/{vue-ui-circle-pack-Z5VTiXZU.js → vue-ui-circle-pack-D6mTG5i0.js} +249 -233
- package/dist/{vue-ui-cursor-Detis-4Y.js → vue-ui-cursor-BJmTAMpP.js} +2 -2
- package/dist/{vue-ui-dashboard-BEJ5uSZV.js → vue-ui-dashboard-BdFLsK4u.js} +72 -71
- package/dist/{vue-ui-digits-CDtdGqLS.js → vue-ui-digits-DXum1rs6.js} +10 -10
- package/dist/{vue-ui-donut-a82yzfvT.js → vue-ui-donut-CqefukGp.js} +662 -645
- package/dist/{vue-ui-donut-evolution-DP_dXmIC.js → vue-ui-donut-evolution-DFIbK50s.js} +407 -385
- package/dist/{vue-ui-dumbbell-BDIzPnlX.js → vue-ui-dumbbell-DIo2ecGY.js} +295 -274
- package/dist/vue-ui-flow--kiGWaq4.js +931 -0
- package/dist/{vue-ui-funnel-CaxHiJIB.js → vue-ui-funnel-B8UHwj15.js} +197 -181
- package/dist/{vue-ui-galaxy-CbGRAAFI.js → vue-ui-galaxy-eQZh_y3l.js} +265 -252
- package/dist/{vue-ui-gauge-But_1QwV.js → vue-ui-gauge-DJ-E6L2T.js} +256 -240
- package/dist/{vue-ui-gizmo-DcBQp-C8.js → vue-ui-gizmo-DFxlqPz7.js} +18 -18
- package/dist/{vue-ui-heatmap-BAVkwnbX.js → vue-ui-heatmap-CcAe5dDN.js} +394 -373
- package/dist/{vue-ui-history-plot-BlVib573.js → vue-ui-history-plot-CgKvd7Jx.js} +337 -319
- package/dist/{vue-ui-kpi-DuFgWXJM.js → vue-ui-kpi-Ct2iyD49.js} +4 -4
- package/dist/{vue-ui-mini-loader-D4W9oE3V.js → vue-ui-mini-loader-ByjcvXBB.js} +19 -19
- package/dist/{vue-ui-molecule-CEb6_0wR.js → vue-ui-molecule-CGDBEAkX.js} +176 -160
- package/dist/vue-ui-mood-radar-D9GuK4cI.js +876 -0
- package/dist/{vue-ui-nested-donuts-B6rmNl9X.js → vue-ui-nested-donuts-CGKgOTX2.js} +542 -519
- package/dist/{vue-ui-onion-BWAdTZ6V.js → vue-ui-onion-C5tE1Woz.js} +318 -289
- package/dist/{vue-ui-parallel-coordinate-plot-DXbgnatq.js → vue-ui-parallel-coordinate-plot-CVhD6IoH.js} +253 -234
- package/dist/{vue-ui-quadrant-BwGMZ_d_.js → vue-ui-quadrant-BGDCaOXv.js} +295 -277
- package/dist/{vue-ui-quick-chart-2bQ0DX_A.js → vue-ui-quick-chart-CjXSB-2S.js} +724 -686
- package/dist/{vue-ui-radar-DPXvVIbh.js → vue-ui-radar-rhxkROX7.js} +307 -282
- package/dist/{vue-ui-rating-CxIBq7Xr.js → vue-ui-rating-Bo9gSy-z.js} +4 -4
- package/dist/{vue-ui-relation-circle-BVGAfqBj.js → vue-ui-relation-circle-Qo8FKbL2.js} +147 -132
- package/dist/{vue-ui-ridgeline-C6UdClMT.js → vue-ui-ridgeline-ahOApbEC.js} +320 -299
- package/dist/{vue-ui-rings-B_7zAshC.js → vue-ui-rings-DFAVaEBs.js} +323 -310
- package/dist/{vue-ui-scatter-BRr9oPfo.js → vue-ui-scatter-zjlWyvVd.js} +390 -372
- package/dist/{vue-ui-skeleton-C3tGR_lR.js → vue-ui-skeleton-CKfOnyd_.js} +105 -105
- package/dist/{vue-ui-smiley-B70Ck-49.js → vue-ui-smiley-CY7UiJ9C.js} +88 -88
- package/dist/{vue-ui-spark-trend-C2tSZULg.js → vue-ui-spark-trend-DwNYP97M.js} +5 -5
- package/dist/{vue-ui-sparkbar-BUPDw_qR.js → vue-ui-sparkbar-BkdcYrmg.js} +30 -30
- package/dist/{vue-ui-sparkgauge-DufAZyFK.js → vue-ui-sparkgauge-C6Kq_OGV.js} +4 -4
- package/dist/{vue-ui-sparkhistogram-DDunWMKu.js → vue-ui-sparkhistogram-CjB33yXB.js} +7 -7
- package/dist/{vue-ui-sparkline-lRx2nNde.js → vue-ui-sparkline-DcH4yIEd.js} +5 -5
- package/dist/{vue-ui-sparkstackbar-CB6WHJHd.js → vue-ui-sparkstackbar-MKr2u_pO.js} +5 -5
- package/dist/{vue-ui-stackbar-CQ9Zvuxh.js → vue-ui-stackbar-DKV-exfd.js} +356 -338
- package/dist/{vue-ui-strip-plot-DW3c82dV.js → vue-ui-strip-plot-ncTrDlNC.js} +368 -352
- package/dist/{vue-ui-table-CEt97z7F.js → vue-ui-table-BdT3lGuv.js} +16 -16
- package/dist/{vue-ui-table-heatmap-DFZCaMxK.js → vue-ui-table-heatmap-D929cWB0.js} +9 -9
- package/dist/{vue-ui-table-sparkline-RB40-Z1R.js → vue-ui-table-sparkline-CkZ_ygR1.js} +7 -7
- package/dist/{vue-ui-thermometer-fmPzO-eT.js → vue-ui-thermometer-CjBLR6H9.js} +148 -133
- package/dist/{vue-ui-timer-qxLpO3HX.js → vue-ui-timer-Bs7eMmiC.js} +7 -7
- package/dist/vue-ui-tiremarks-nGOZKRcz.js +423 -0
- package/dist/{vue-ui-treemap-B4-IPDxV.js → vue-ui-treemap-SQ2f5wbN.js} +403 -373
- package/dist/{vue-ui-vertical-bar-Y5LefeNg.js → vue-ui-vertical-bar-Hh9gAN5j.js} +295 -260
- package/dist/{vue-ui-waffle-gvnJOZlg.js → vue-ui-waffle-C7moVBln.js} +396 -377
- package/dist/{vue-ui-wheel-BzS_N3GP.js → vue-ui-wheel-KrGLMCqW.js} +185 -169
- package/dist/{vue-ui-word-cloud-vWhTarrE.js → vue-ui-word-cloud-BQSu6kiR.js} +234 -218
- package/dist/{vue-ui-world-CqWuE8ZR.js → vue-ui-world-DdoMFJcV.js} +344 -326
- package/dist/{vue-ui-xy-BxpuE9Ng.js → vue-ui-xy-B2fjTYMJ.js} +1602 -1708
- package/dist/{vue-ui-xy-canvas-C9YQjaUA.js → vue-ui-xy-canvas-oUXISeU8.js} +12 -12
- package/package.json +1 -1
- package/dist/vue-data-ui-DH8opsJv.js +0 -325
- package/dist/vue-ui-flow-B72CBzC3.js +0 -909
- package/dist/vue-ui-mood-radar-CqJPicZv.js +0 -853
- package/dist/vue-ui-tiremarks-Cxx97FLg.js +0 -407
|
@@ -1,30 +1,31 @@
|
|
|
1
|
-
import { defineAsyncComponent as
|
|
2
|
-
import { c as Te, t 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 _t from "./BaseIcon-
|
|
14
|
-
import {
|
|
15
|
-
|
|
1
|
+
import { defineAsyncComponent as ee, useSlots as Kt, onMounted as bt, computed as m, ref as y, shallowRef as U, toRefs as Jt, watch as ke, onBeforeUnmount as Qt, createElementBlock as b, openBlock as h, unref as d, normalizeStyle as L, normalizeClass as Me, createBlock as Z, createCommentVNode as O, createElementVNode as _, createVNode as we, createSlots as kt, withCtx as T, renderSlot as C, normalizeProps as te, guardReactiveProps as le, Fragment as Ce, renderList as Ve, withKeys as wt, withModifiers as Ee, mergeProps as Ue, createTextVNode as $e, toDisplayString as se, Teleport as el, resolveDynamicComponent as tl, nextTick as ll } from "vue";
|
|
2
|
+
import { c as Te, t as ol, b as al, p as I, e as nl, o as Ct, f as sl, h as de, a as xe, d as he, X as ul, m as $t, E as Tt, z as xt, x as rl, y as il, A as cl } from "./lib-GIYcnm0E.js";
|
|
3
|
+
import { t as vl, u as dl } from "./useResponsive-DfdjqQps.js";
|
|
4
|
+
import { u as hl, a as Ot } from "./useNestedProp-mxyyqd0B.js";
|
|
5
|
+
import { u as pl, B as fl } from "./BaseScanner-BgWxam9d.js";
|
|
6
|
+
import { u as gl } from "./usePrinter-DYRFiw7X.js";
|
|
7
|
+
import { u as ml } from "./useUserOptionState-BIvW1Kz7.js";
|
|
8
|
+
import { u as yl } from "./useChartAccessibility-9icAAmYg.js";
|
|
9
|
+
import bl from "./img-6wPuVVtk.js";
|
|
10
|
+
import kl from "./Title-D17CJXko.js";
|
|
11
|
+
import { t as wl } from "./themes-Dw-dDudK.js";
|
|
12
|
+
import Cl from "./Legend-DsogCeTb.js";
|
|
13
|
+
import _t from "./BaseIcon-CtqN7W_g.js";
|
|
14
|
+
import { u as $l } from "./useSvgExport-B7-Vrjtu.js";
|
|
15
|
+
import { _ as Tl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
16
|
+
function St(n, r) {
|
|
16
17
|
const s = n.length;
|
|
17
18
|
if (s === 0)
|
|
18
19
|
throw new Error(`Max aspect ratio cannot be computed: ${n} is an empty array`);
|
|
19
20
|
{
|
|
20
|
-
let i = 1 / 0, u = -1 / 0,
|
|
21
|
+
let i = 1 / 0, u = -1 / 0, p = 0;
|
|
21
22
|
for (let g = 0; g < s; g += 1) {
|
|
22
23
|
const f = n[g].normalizedValue;
|
|
23
|
-
f < i && (i = f), f > u && (u = f),
|
|
24
|
+
f < i && (i = f), f > u && (u = f), p += f;
|
|
24
25
|
}
|
|
25
26
|
return Math.max(
|
|
26
|
-
r ** 2 * u /
|
|
27
|
-
|
|
27
|
+
r ** 2 * u / p ** 2,
|
|
28
|
+
p ** 2 / (r ** 2 * i)
|
|
28
29
|
);
|
|
29
30
|
}
|
|
30
31
|
}
|
|
@@ -37,78 +38,78 @@ function At(n) {
|
|
|
37
38
|
y1: s + u
|
|
38
39
|
};
|
|
39
40
|
}
|
|
40
|
-
function
|
|
41
|
+
function xl(n, r, s) {
|
|
41
42
|
if (n.length === 0)
|
|
42
43
|
return !0;
|
|
43
44
|
{
|
|
44
|
-
const i = n.concat(r), u =
|
|
45
|
+
const i = n.concat(r), u = St(
|
|
45
46
|
n,
|
|
46
47
|
s
|
|
47
|
-
),
|
|
48
|
-
return u >=
|
|
48
|
+
), p = St(i, s);
|
|
49
|
+
return u >= p;
|
|
49
50
|
}
|
|
50
51
|
}
|
|
51
|
-
function
|
|
52
|
+
function Ol(n) {
|
|
52
53
|
const r = [], s = n.length;
|
|
53
54
|
for (let i = 0; i < s; i += 1) {
|
|
54
|
-
const u = n[i],
|
|
55
|
-
for (let v = 0; v <
|
|
55
|
+
const u = n[i], p = u.length;
|
|
56
|
+
for (let v = 0; v < p; v += 1)
|
|
56
57
|
r.push(u[v]);
|
|
57
58
|
}
|
|
58
59
|
return r;
|
|
59
60
|
}
|
|
60
|
-
function
|
|
61
|
+
function _l(n, r) {
|
|
61
62
|
const s = {
|
|
62
63
|
...r,
|
|
63
64
|
children: n
|
|
64
65
|
};
|
|
65
66
|
return Ft(s);
|
|
66
67
|
}
|
|
67
|
-
function
|
|
68
|
+
function Sl(n) {
|
|
68
69
|
return (n.x1 - n.x0) * (n.y1 - n.y0);
|
|
69
70
|
}
|
|
70
|
-
function
|
|
71
|
-
const { width: s, height: i, xOffset: u, yOffset:
|
|
72
|
-
let P = u, k =
|
|
71
|
+
function It(n, r) {
|
|
72
|
+
const { width: s, height: i, xOffset: u, yOffset: p } = He(r), v = n.length, g = n.map((w) => w.normalizedValue || 0).reduce((w, F) => w + F, 0), f = g / i, H = g / s;
|
|
73
|
+
let P = u, k = p;
|
|
73
74
|
const $ = [];
|
|
74
75
|
if (s >= i) {
|
|
75
76
|
for (let w = 0; w < v; w += 1) {
|
|
76
|
-
const
|
|
77
|
+
const F = n[w], M = k + F.normalizedValue / f, S = {
|
|
77
78
|
x0: P,
|
|
78
79
|
y0: k,
|
|
79
80
|
x1: P + f,
|
|
80
|
-
y1:
|
|
81
|
-
}, N = Object.assign({},
|
|
82
|
-
k =
|
|
81
|
+
y1: M
|
|
82
|
+
}, N = Object.assign({}, F, S);
|
|
83
|
+
k = M, $.push(N);
|
|
83
84
|
}
|
|
84
85
|
return $;
|
|
85
86
|
} else {
|
|
86
87
|
for (let w = 0; w < v; w += 1) {
|
|
87
|
-
const
|
|
88
|
+
const F = n[w], M = P + F.normalizedValue / H, S = {
|
|
88
89
|
x0: P,
|
|
89
90
|
y0: k,
|
|
90
|
-
x1:
|
|
91
|
-
y1: k +
|
|
92
|
-
}, N = Object.assign({},
|
|
93
|
-
P =
|
|
91
|
+
x1: M,
|
|
92
|
+
y1: k + H
|
|
93
|
+
}, N = Object.assign({}, F, S);
|
|
94
|
+
P = M, $.push(N);
|
|
94
95
|
}
|
|
95
96
|
return $;
|
|
96
97
|
}
|
|
97
98
|
}
|
|
98
|
-
function
|
|
99
|
-
const r =
|
|
99
|
+
function Al(n) {
|
|
100
|
+
const r = He(n), s = r.width, i = r.height;
|
|
100
101
|
return Math.min(s, i);
|
|
101
102
|
}
|
|
102
|
-
function
|
|
103
|
-
const s = n.length, i = n.map((f) => f.value ?? 0).reduce((f,
|
|
103
|
+
function Il(n, r) {
|
|
104
|
+
const s = n.length, i = n.map((f) => f.value ?? 0).reduce((f, H) => f + H, 0), u = r / i, p = [];
|
|
104
105
|
let v, g;
|
|
105
106
|
for (let f = 0; f < s; f += 1)
|
|
106
107
|
g = n[f], v = Object.assign({}, g, {
|
|
107
108
|
normalizedValue: g.value * (u || 0)
|
|
108
|
-
}),
|
|
109
|
-
return
|
|
109
|
+
}), p.push(v);
|
|
110
|
+
return p;
|
|
110
111
|
}
|
|
111
|
-
function
|
|
112
|
+
function He(n) {
|
|
112
113
|
const { x0: r, y0: s, x1: i, y1: u } = n;
|
|
113
114
|
return {
|
|
114
115
|
xOffset: r,
|
|
@@ -117,25 +118,25 @@ function Ee(n) {
|
|
|
117
118
|
height: u - s
|
|
118
119
|
};
|
|
119
120
|
}
|
|
120
|
-
function
|
|
121
|
-
let u = n,
|
|
121
|
+
function Fl(n, r, s, i) {
|
|
122
|
+
let u = n, p = r, v = s, g = i;
|
|
122
123
|
for (; ; ) {
|
|
123
124
|
const f = u.length;
|
|
124
125
|
if (f === 0) {
|
|
125
|
-
const $ =
|
|
126
|
+
const $ = It(p, v);
|
|
126
127
|
return g.concat($);
|
|
127
128
|
}
|
|
128
|
-
const
|
|
129
|
-
if (
|
|
130
|
-
const $ =
|
|
131
|
-
u = k,
|
|
129
|
+
const H = Al(v), P = u[0], k = u.slice(1, f);
|
|
130
|
+
if (xl(p, P, H)) {
|
|
131
|
+
const $ = p.concat(P);
|
|
132
|
+
u = k, p = $, v = v, g = g;
|
|
132
133
|
} else {
|
|
133
|
-
const $ =
|
|
134
|
+
const $ = p.length;
|
|
134
135
|
let w = 0;
|
|
135
136
|
for (let N = 0; N < $; N += 1)
|
|
136
|
-
w +=
|
|
137
|
-
const
|
|
138
|
-
u = u,
|
|
137
|
+
w += p[N].normalizedValue;
|
|
138
|
+
const F = Dl(v, w), M = It(p, v), S = g.concat(M);
|
|
139
|
+
u = u, p = [], v = F, g = S;
|
|
139
140
|
}
|
|
140
141
|
}
|
|
141
142
|
}
|
|
@@ -143,21 +144,21 @@ function Ft(n) {
|
|
|
143
144
|
if (typeof n.children > "u" || !n.children.length)
|
|
144
145
|
return [n];
|
|
145
146
|
{
|
|
146
|
-
const r =
|
|
147
|
+
const r = Il(
|
|
147
148
|
n.children,
|
|
148
|
-
|
|
149
|
-
), s =
|
|
149
|
+
Sl(n)
|
|
150
|
+
), s = Fl(r, [], n, []), i = s.length, u = [];
|
|
150
151
|
for (let v = 0; v < i; v += 1)
|
|
151
152
|
u.push(Ft(s[v]));
|
|
152
|
-
return
|
|
153
|
+
return Ol(u);
|
|
153
154
|
}
|
|
154
155
|
}
|
|
155
|
-
function
|
|
156
|
-
const { width: s, height: i, xOffset: u, yOffset:
|
|
156
|
+
function Dl(n, r) {
|
|
157
|
+
const { width: s, height: i, xOffset: u, yOffset: p } = He(n);
|
|
157
158
|
if (s >= i) {
|
|
158
159
|
const v = r / i, g = s - v, f = {
|
|
159
160
|
xOffset: u + v,
|
|
160
|
-
yOffset:
|
|
161
|
+
yOffset: p,
|
|
161
162
|
width: g,
|
|
162
163
|
height: i
|
|
163
164
|
};
|
|
@@ -165,26 +166,23 @@ function Tl(n, r) {
|
|
|
165
166
|
} else {
|
|
166
167
|
const v = r / s, g = i - v, f = {
|
|
167
168
|
xOffset: u,
|
|
168
|
-
yOffset:
|
|
169
|
+
yOffset: p + v,
|
|
169
170
|
width: s,
|
|
170
171
|
height: g
|
|
171
172
|
};
|
|
172
173
|
return At(f);
|
|
173
174
|
}
|
|
174
175
|
}
|
|
175
|
-
const
|
|
176
|
+
const Nl = ["id"], Rl = ["id"], Ll = ["tabindex", "onClick", "onKeydown", "data-last-crumb", "onMouseenter", "onFocus"], Pl = { class: "vue-ui-treemap-crumb-unit" }, zl = { class: "vue-ui-treemap-crumb-unit-label" }, Bl = {
|
|
176
177
|
key: 0,
|
|
177
178
|
style: { width: "24px", display: "flex", "align-items": "center" }
|
|
178
|
-
},
|
|
179
|
+
}, Ml = {
|
|
179
180
|
key: 0,
|
|
180
181
|
class: "vue-ui-treemap-crumb-unit-arrow"
|
|
181
|
-
},
|
|
182
|
-
style: { width: "100%", height: "100%" },
|
|
183
|
-
class: "vue-ui-treemap-cell"
|
|
184
|
-
}, Vl = {
|
|
182
|
+
}, Vl = ["xmlns", "viewBox"], El = { key: 0 }, Ul = ["id"], Hl = ["stop-color"], Wl = ["stop-color"], Gl = ["x", "y", "height", "width", "fill", "rx", "stroke", "stroke-width", "onClick", "onMouseenter", "onMouseleave"], Xl = ["x", "y", "height", "width"], ql = {
|
|
185
183
|
key: 5,
|
|
186
184
|
class: "vue-data-ui-watermark"
|
|
187
|
-
},
|
|
185
|
+
}, Yl = ["id"], jl = ["onClick"], Zl = ["innerHTML"], Kl = {
|
|
188
186
|
__name: "vue-ui-treemap",
|
|
189
187
|
props: {
|
|
190
188
|
config: {
|
|
@@ -202,14 +200,14 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
202
200
|
},
|
|
203
201
|
emits: ["selectLegend", "selectDatapoint"],
|
|
204
202
|
setup(n, { expose: r, emit: s }) {
|
|
205
|
-
const i =
|
|
206
|
-
|
|
203
|
+
const i = ee(() => import("./DataTable-BeI6gYJX.js")), u = ee(() => import("./PenAndPaper-BxbYiPy4.js")), p = ee(() => import("./vue-ui-accordion-Dch9YrCi.js")), v = ee(() => import("./Tooltip-CtVdvbZi.js")), g = ee(() => import("./UserOptions-B3vCIe-u.js")), f = ee(() => import("./PackageVersion-C9oklnuy.js")), H = ee(() => import("./BaseDraggableDialog-q3pgSDTz.js")), { vue_ui_treemap: P } = hl(), k = n, $ = s, w = Kt();
|
|
204
|
+
bt(() => {
|
|
207
205
|
w["chart-background"] && console.warn("VueUiTreemap does not support the #chart-background slot.");
|
|
208
206
|
});
|
|
209
|
-
const
|
|
210
|
-
...
|
|
207
|
+
const F = m(() => !!k.dataset && k.dataset.length), M = m(() => /^((?!chrome|android).)*safari/i.test(navigator.userAgent)), S = y(Te()), N = y(!1), Oe = y(""), K = y(!1), We = y(0), z = y([]), V = U(null), Ge = U(null), Xe = U(null), qe = U(null), Ye = U(null), je = y(0), _e = y(0), Se = y(0), x = y([]), Ae = y(null), Ze = y(!1), ue = y(null), Ie = y(null), e = y(Re()), { loading: re, FINAL_DATASET: Fe, manualLoading: Dt } = pl({
|
|
208
|
+
...Jt(k),
|
|
211
209
|
FINAL_CONFIG: e,
|
|
212
|
-
prepareConfig:
|
|
210
|
+
prepareConfig: Re,
|
|
213
211
|
skeletonDataset: [
|
|
214
212
|
{
|
|
215
213
|
name: "_",
|
|
@@ -226,7 +224,7 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
226
224
|
]
|
|
227
225
|
}
|
|
228
226
|
],
|
|
229
|
-
skeletonConfig:
|
|
227
|
+
skeletonConfig: ol({
|
|
230
228
|
defaultConfig: e.value,
|
|
231
229
|
userConfig: {
|
|
232
230
|
userOptions: { show: !1 },
|
|
@@ -248,28 +246,28 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
248
246
|
}
|
|
249
247
|
}
|
|
250
248
|
})
|
|
251
|
-
}), { userOptionsVisible: De, setUserOptionsVisibility:
|
|
252
|
-
function
|
|
253
|
-
const t =
|
|
249
|
+
}), { userOptionsVisible: De, setUserOptionsVisibility: Ke, keepUserOptionState: Je } = ml({ config: e.value }), { svgRef: Ne } = yl({ config: e.value.style.chart.title });
|
|
250
|
+
function Re() {
|
|
251
|
+
const t = Ot({
|
|
254
252
|
userConfig: k.config,
|
|
255
253
|
defaultConfig: P
|
|
256
254
|
});
|
|
257
255
|
return t.theme ? {
|
|
258
|
-
...
|
|
259
|
-
userConfig:
|
|
256
|
+
...Ot({
|
|
257
|
+
userConfig: wl.vue_ui_treemap[t.theme] || k.config,
|
|
260
258
|
defaultConfig: t
|
|
261
259
|
}),
|
|
262
|
-
customPalette:
|
|
260
|
+
customPalette: al[t.theme] || I
|
|
263
261
|
} : t;
|
|
264
262
|
}
|
|
265
263
|
ke(() => k.config, (t) => {
|
|
266
|
-
re.value || (e.value =
|
|
264
|
+
re.value || (e.value = Re()), De.value = !e.value.userOptions.showOnChartHover, je.value += 1, _e.value += 1, Se.value += 1, D.value.showTable = e.value.table.show, D.value.showTooltip = e.value.style.chart.tooltip.show;
|
|
267
265
|
}, { deep: !0 });
|
|
268
|
-
const { isPrinting:
|
|
269
|
-
elementId: `treemap_${
|
|
266
|
+
const { isPrinting: Qe, isImaging: et, generatePdf: tt, generateImage: lt } = gl({
|
|
267
|
+
elementId: `treemap_${S.value}`,
|
|
270
268
|
fileName: e.value.style.chart.title.text || "vue-ui-treemap",
|
|
271
269
|
options: e.value.userOptions.print
|
|
272
|
-
}),
|
|
270
|
+
}), Nt = m(() => e.value.userOptions.show && !e.value.style.chart.title.text), pe = m(() => nl(e.value.customPalette)), D = y({
|
|
273
271
|
showTable: e.value.table.show,
|
|
274
272
|
showTooltip: e.value.style.chart.tooltip.show
|
|
275
273
|
});
|
|
@@ -279,79 +277,79 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
279
277
|
showTooltip: e.value.style.chart.tooltip.show
|
|
280
278
|
};
|
|
281
279
|
}, { immediate: !0 });
|
|
282
|
-
const
|
|
280
|
+
const W = y({
|
|
283
281
|
height: e.value.style.chart.height,
|
|
284
282
|
width: e.value.style.chart.width
|
|
285
|
-
}), J =
|
|
286
|
-
bottom:
|
|
287
|
-
height:
|
|
283
|
+
}), J = m(() => ({
|
|
284
|
+
bottom: W.value.height - e.value.style.chart.padding.bottom,
|
|
285
|
+
height: W.value.height - e.value.style.chart.padding.top - e.value.style.chart.padding.bottom,
|
|
288
286
|
left: e.value.style.chart.padding.left,
|
|
289
|
-
right:
|
|
287
|
+
right: W.value.width - e.value.style.chart.padding.right,
|
|
290
288
|
top: e.value.style.chart.padding.top,
|
|
291
|
-
vbHeight:
|
|
292
|
-
vbWidth:
|
|
293
|
-
width:
|
|
294
|
-
})), R =
|
|
295
|
-
function
|
|
289
|
+
vbHeight: W.value.height,
|
|
290
|
+
vbWidth: W.value.width,
|
|
291
|
+
width: W.value.width - e.value.style.chart.padding.left - e.value.style.chart.padding.right
|
|
292
|
+
})), R = y(Fe.value), G = y(R.value), ot = U(/* @__PURE__ */ new Map());
|
|
293
|
+
function at(t) {
|
|
296
294
|
Array.isArray(t) && t.forEach((o, l) => {
|
|
297
295
|
o.id || (o.id = Te());
|
|
298
|
-
let a = de(o.color) ||
|
|
299
|
-
a = de(a),
|
|
296
|
+
let a = de(o.color) || ot.value.get(o.id) || pe.value[l] || I[l] || I[l % I.length];
|
|
297
|
+
a = de(a), ot.value.set(o.id, a), o.color = a, nt(o, a);
|
|
300
298
|
});
|
|
301
299
|
}
|
|
302
|
-
function
|
|
300
|
+
function nt(t, o) {
|
|
303
301
|
Array.isArray(t.children) && t.children.forEach((l) => {
|
|
304
|
-
l.id || (l.id = Te()), l.parentId = t.id, l.color = o,
|
|
302
|
+
l.id || (l.id = Te()), l.parentId = t.id, l.color = o, nt(l, o);
|
|
305
303
|
});
|
|
306
304
|
}
|
|
307
|
-
function
|
|
305
|
+
function Rt() {
|
|
308
306
|
if (!x.value.length)
|
|
309
|
-
|
|
307
|
+
G.value = R.value.slice();
|
|
310
308
|
else {
|
|
311
309
|
const t = x.value[x.value.length - 1], o = Y(t);
|
|
312
|
-
|
|
310
|
+
G.value = o?.children?.slice() || [];
|
|
313
311
|
}
|
|
314
312
|
}
|
|
315
313
|
ke(
|
|
316
|
-
() =>
|
|
314
|
+
() => Fe.value,
|
|
317
315
|
() => {
|
|
318
|
-
R.value =
|
|
316
|
+
R.value = Fe.value, at(R.value), Rt(), Se.value += 1, _e.value += 1;
|
|
319
317
|
},
|
|
320
318
|
{ deep: !0, immediate: !0, flush: "post" }
|
|
321
319
|
);
|
|
322
|
-
const
|
|
323
|
-
|
|
324
|
-
|
|
320
|
+
const X = U(null), oe = U(null);
|
|
321
|
+
bt(() => {
|
|
322
|
+
Ze.value = !0, Pt();
|
|
325
323
|
});
|
|
326
|
-
const
|
|
324
|
+
const Lt = m(() => e.value.debug);
|
|
327
325
|
function Pt() {
|
|
328
|
-
if (
|
|
326
|
+
if (Ct(k.dataset) && sl({
|
|
329
327
|
componentName: "VueUiTreemap",
|
|
330
328
|
type: "dataset",
|
|
331
|
-
debug:
|
|
332
|
-
}),
|
|
333
|
-
const t =
|
|
334
|
-
const { width: o, height: l } =
|
|
329
|
+
debug: Lt.value
|
|
330
|
+
}), at(R.value), Ct(k.dataset) || (Dt.value = e.value.loading), e.value.responsive) {
|
|
331
|
+
const t = vl(() => {
|
|
332
|
+
const { width: o, height: l } = dl({
|
|
335
333
|
chart: V.value,
|
|
336
|
-
title: e.value.style.chart.title.text ?
|
|
337
|
-
legend: e.value.style.chart.legend.show ?
|
|
338
|
-
source:
|
|
339
|
-
noTitle:
|
|
334
|
+
title: e.value.style.chart.title.text ? Ge.value : null,
|
|
335
|
+
legend: e.value.style.chart.legend.show ? Xe.value : null,
|
|
336
|
+
source: qe.value,
|
|
337
|
+
noTitle: Ye.value
|
|
340
338
|
});
|
|
341
339
|
requestAnimationFrame(() => {
|
|
342
|
-
|
|
340
|
+
W.value.width = o, W.value.height = l - 12;
|
|
343
341
|
});
|
|
344
342
|
});
|
|
345
|
-
|
|
343
|
+
X.value && (oe.value && X.value.unobserve(oe.value), X.value.disconnect()), X.value = new ResizeObserver(t), oe.value = V.value.parentNode, X.value.observe(oe.value);
|
|
346
344
|
}
|
|
347
345
|
}
|
|
348
|
-
|
|
349
|
-
|
|
346
|
+
Qt(() => {
|
|
347
|
+
X.value && (oe.value && X.value.unobserve(oe.value), X.value.disconnect());
|
|
350
348
|
});
|
|
351
|
-
const ie =
|
|
349
|
+
const ie = m(() => G.value.map((t, o) => ({
|
|
352
350
|
...t,
|
|
353
|
-
color: de(t.color) || pe.value[o] ||
|
|
354
|
-
})).filter((t) => !z.value.includes(t.id))),
|
|
351
|
+
color: de(t.color) || pe.value[o] || I[o] || I[o % I.length]
|
|
352
|
+
})).filter((t) => !z.value.includes(t.id))), ae = m(() => R.value.filter((t) => !z.value.includes(t.id)).map((t) => t.value || 0).reduce((t, o) => t + o, 0)), st = m({
|
|
355
353
|
get() {
|
|
356
354
|
let t = [...ie.value];
|
|
357
355
|
return e.value.style.chart.layout.sorted && (t = [...ie.value].sort((o, l) => l.value - o.value)), t.map((o) => ({
|
|
@@ -362,54 +360,54 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
362
360
|
return t;
|
|
363
361
|
}
|
|
364
362
|
});
|
|
365
|
-
function
|
|
363
|
+
function ut(t, o) {
|
|
366
364
|
return t.value / o;
|
|
367
365
|
}
|
|
368
366
|
function zt(t, o, l) {
|
|
369
|
-
const a = e.value.style.chart.layout.rects.colorRatio -
|
|
370
|
-
return
|
|
367
|
+
const a = e.value.style.chart.layout.rects.colorRatio - ut(o, l);
|
|
368
|
+
return $t(t, a < 0 ? 0 : a);
|
|
371
369
|
}
|
|
372
|
-
function
|
|
373
|
-
return t.map((
|
|
374
|
-
const be = zt(de(o) || pe.value[
|
|
370
|
+
function rt(t, o, l, a) {
|
|
371
|
+
return t.map((c, A) => {
|
|
372
|
+
const be = zt(de(o) || pe.value[A] || I[A] || I[A % I.length], c, a), Zt = ut(c, a);
|
|
375
373
|
return {
|
|
376
|
-
...
|
|
374
|
+
...c,
|
|
377
375
|
color: be,
|
|
378
|
-
proportion:
|
|
376
|
+
proportion: Zt,
|
|
379
377
|
parentName: l,
|
|
380
|
-
children:
|
|
378
|
+
children: c.children ? rt(c.children, be, c.name, a) : void 0
|
|
381
379
|
};
|
|
382
380
|
});
|
|
383
381
|
}
|
|
384
|
-
const ce =
|
|
385
|
-
|
|
386
|
-
const l = t.children ? t.children.reduce((a,
|
|
382
|
+
const ce = m(() => _l(
|
|
383
|
+
st.value.map((t, o) => {
|
|
384
|
+
const l = t.children ? t.children.reduce((a, c) => a + c.value, 0) : t.value;
|
|
387
385
|
return {
|
|
388
386
|
value: t.value,
|
|
389
387
|
id: t.id || Te(),
|
|
390
|
-
children: t.children ?
|
|
388
|
+
children: t.children ? rt(t.children.sort((a, c) => c.value - a.value), t.color, t.name, l) : void 0,
|
|
391
389
|
color: t.color,
|
|
392
390
|
name: t.name
|
|
393
391
|
};
|
|
394
392
|
}),
|
|
395
393
|
{ x0: J.value.left * 2, y0: J.value.top, x1: J.value.width, y1: J.value.height }
|
|
396
394
|
));
|
|
397
|
-
function
|
|
395
|
+
function it({ y0: t, y1: o }) {
|
|
398
396
|
return o - t <= 0 ? 1e-4 : o - t;
|
|
399
397
|
}
|
|
400
|
-
function
|
|
398
|
+
function ct({ x0: t, x1: o }) {
|
|
401
399
|
return o - t <= 0 ? 1e-4 : o - t;
|
|
402
400
|
}
|
|
403
|
-
function
|
|
401
|
+
function q(t) {
|
|
404
402
|
const o = e.value.style.chart.layout.labels.fontSize * (t.proportion * 2 > 1 ? 1 : t.proportion * 2);
|
|
405
403
|
return o < e.value.style.chart.layout.labels.minFontSize ? e.value.style.chart.layout.labels.minFontSize : o;
|
|
406
404
|
}
|
|
407
|
-
function
|
|
408
|
-
K.value = t,
|
|
405
|
+
function vt(t) {
|
|
406
|
+
K.value = t, We.value += 1;
|
|
409
407
|
}
|
|
410
|
-
const
|
|
408
|
+
const ne = m(() => {
|
|
411
409
|
let t = 0;
|
|
412
|
-
return
|
|
410
|
+
return Ae.value && (t = Ae.value.getBoundingClientRect().height), {
|
|
413
411
|
startX: 0,
|
|
414
412
|
startY: 0,
|
|
415
413
|
width: J.value.vbWidth,
|
|
@@ -428,34 +426,34 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
428
426
|
}
|
|
429
427
|
return null;
|
|
430
428
|
}
|
|
431
|
-
const
|
|
429
|
+
const Q = m(() => x.value.length > 0);
|
|
432
430
|
function fe(t, o) {
|
|
433
431
|
if (!t) {
|
|
434
|
-
|
|
432
|
+
G.value = R.value.slice(), $("selectDatapoint", void 0), x.value = [];
|
|
435
433
|
return;
|
|
436
434
|
}
|
|
437
435
|
e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: o });
|
|
438
436
|
const l = Y(t.id);
|
|
439
437
|
if (l && l.children?.length)
|
|
440
|
-
x.value.push(l.id),
|
|
438
|
+
x.value.push(l.id), G.value = l.children.slice(), $("selectDatapoint", t);
|
|
441
439
|
else if (t.parentId) {
|
|
442
440
|
x.value.push(t.parentId);
|
|
443
441
|
const a = Y(t.parentId);
|
|
444
|
-
|
|
442
|
+
G.value = a.children.slice(), $("selectDatapoint", t);
|
|
445
443
|
} else if (x.value.length > 0) {
|
|
446
444
|
x.value.pop();
|
|
447
445
|
const a = x.value[x.value.length - 1];
|
|
448
446
|
if (a) {
|
|
449
|
-
const
|
|
450
|
-
|
|
447
|
+
const c = Y(a);
|
|
448
|
+
G.value = c.children.slice();
|
|
451
449
|
} else
|
|
452
|
-
|
|
450
|
+
G.value = R.value.slice(), x.value = [], $("selectDatapoint", void 0);
|
|
453
451
|
}
|
|
454
452
|
}
|
|
455
|
-
function
|
|
453
|
+
function Bt(t) {
|
|
456
454
|
return !!(Y(t.id)?.children?.length || t.parentId);
|
|
457
455
|
}
|
|
458
|
-
const j =
|
|
456
|
+
const j = m(() => {
|
|
459
457
|
const t = [
|
|
460
458
|
{ id: null, label: "All" }
|
|
461
459
|
];
|
|
@@ -472,15 +470,29 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
472
470
|
});
|
|
473
471
|
}
|
|
474
472
|
return t;
|
|
475
|
-
}),
|
|
473
|
+
}), B = U(null), Le = m(() => R.value.map((t, o) => ({
|
|
476
474
|
...t,
|
|
477
|
-
color: de(t.color) || pe.value[o] ||
|
|
475
|
+
color: de(t.color) || pe.value[o] || I[o] || I[o % I.length],
|
|
478
476
|
shape: "square"
|
|
479
|
-
})).sort((t, o) => o.value - t.value).map((t, o) =>
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
477
|
+
})).sort((t, o) => o.value - t.value).map((t, o) => {
|
|
478
|
+
const l = t.value / R.value.map((a) => a.value).reduce((a, c) => a + c, 0);
|
|
479
|
+
return {
|
|
480
|
+
...t,
|
|
481
|
+
proportion: l,
|
|
482
|
+
opacity: z.value.includes(t.id) ? 0.5 : 1,
|
|
483
|
+
display: `${t.name}${e.value.style.chart.legend.showPercentage || e.value.style.chart.legend.showValue ? ": " : ""}${e.value.style.chart.legend.showValue ? xe(
|
|
484
|
+
e.value.style.chart.layout.labels.formatter,
|
|
485
|
+
t.value,
|
|
486
|
+
he({
|
|
487
|
+
p: e.value.style.chart.layout.labels.prefix,
|
|
488
|
+
v: t.value,
|
|
489
|
+
s: e.value.style.chart.layout.labels.suffix,
|
|
490
|
+
r: e.value.style.chart.legend.roundingValue
|
|
491
|
+
}),
|
|
492
|
+
{ datapoint: t }
|
|
493
|
+
) : ""}${e.value.style.chart.legend.showPercentage ? z.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 / ae.value) ? "-" : (t.value / ae.value * 100).toFixed(e.value.style.chart.legend.roundingPercentage)}%${e.value.style.chart.legend.showValue ? ")" : ""}` : ""}`
|
|
494
|
+
};
|
|
495
|
+
})), Mt = m(() => ({
|
|
484
496
|
cy: "treemap-div-legend",
|
|
485
497
|
backgroundColor: e.value.style.chart.legend.backgroundColor,
|
|
486
498
|
color: e.value.style.chart.legend.color,
|
|
@@ -489,22 +501,22 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
489
501
|
fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
|
|
490
502
|
}));
|
|
491
503
|
function dt(t) {
|
|
492
|
-
|
|
493
|
-
}
|
|
494
|
-
function Bt({ datapoint: t, seriesIndex: o }) {
|
|
495
|
-
L.value = null, N.value = !1, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: o });
|
|
504
|
+
B.value = null, z.value.includes(t.id) ? z.value = z.value.filter((o) => o !== t.id) : z.value.length < k.dataset.length - 1 && z.value.push(t.id), $("selectLegend", st.value);
|
|
496
505
|
}
|
|
497
|
-
const Re = m(null);
|
|
498
506
|
function Vt({ datapoint: t, seriesIndex: o }) {
|
|
499
|
-
e.value.events.
|
|
507
|
+
B.value = null, N.value = !1, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: o });
|
|
508
|
+
}
|
|
509
|
+
const Pe = y(null);
|
|
510
|
+
function Et({ datapoint: t, seriesIndex: o }) {
|
|
511
|
+
e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: o }), B.value = t, Pe.value = { datapoint: t, seriesIndex: o, config: e.value, series: ie.value };
|
|
500
512
|
const l = e.value.style.chart.tooltip.customFormat;
|
|
501
|
-
if (
|
|
513
|
+
if (xt(l) && cl(() => l({
|
|
502
514
|
seriesIndex: o,
|
|
503
515
|
datapoint: t,
|
|
504
516
|
series: ie.value,
|
|
505
517
|
config: e.value
|
|
506
518
|
})))
|
|
507
|
-
|
|
519
|
+
Oe.value = l({
|
|
508
520
|
seriesIndex: o,
|
|
509
521
|
datapoint: t,
|
|
510
522
|
series: ie.value,
|
|
@@ -522,50 +534,50 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
522
534
|
r: e.value.style.chart.tooltip.roundingValue
|
|
523
535
|
}),
|
|
524
536
|
{ datapoint: t, seriesIndex: o }
|
|
525
|
-
)}</b>`,
|
|
537
|
+
)}</b>`, Oe.value = `<div>${a}</div>`;
|
|
526
538
|
}
|
|
527
539
|
N.value = !0;
|
|
528
540
|
}
|
|
529
|
-
const E =
|
|
541
|
+
const E = m(() => {
|
|
530
542
|
const t = ce.value.map((l) => ({
|
|
531
543
|
name: l.name,
|
|
532
544
|
color: l.color
|
|
533
545
|
})), o = ce.value.map((l) => l.value);
|
|
534
546
|
return { head: t, body: o };
|
|
535
547
|
});
|
|
536
|
-
function
|
|
537
|
-
|
|
538
|
-
const o = E.value.head.map((
|
|
539
|
-
|
|
540
|
-
], [E.value.body[
|
|
541
|
-
t ? t(a) :
|
|
548
|
+
function ze(t = null) {
|
|
549
|
+
ll(() => {
|
|
550
|
+
const o = E.value.head.map((c, A) => [[
|
|
551
|
+
c.name
|
|
552
|
+
], [E.value.body[A]], [isNaN(E.value.body[A] / ae.value) ? "-" : E.value.body[A] / ae.value * 100]]), l = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], ["val"], ["%"]]].concat(o), a = rl(l);
|
|
553
|
+
t ? t(a) : il({ csvContent: a, title: e.value.style.chart.title.text || "vue-ui-treemap" });
|
|
542
554
|
});
|
|
543
555
|
}
|
|
544
|
-
const ge =
|
|
556
|
+
const ge = m(() => {
|
|
545
557
|
const t = [
|
|
546
558
|
e.value.table.columnNames.series,
|
|
547
559
|
e.value.table.columnNames.value,
|
|
548
560
|
e.value.table.columnNames.percentage
|
|
549
|
-
], o = E.value.head.map((
|
|
561
|
+
], o = E.value.head.map((c, A) => {
|
|
550
562
|
const be = xe(
|
|
551
563
|
e.value.style.chart.layout.labels.formatter,
|
|
552
|
-
E.value.body[
|
|
564
|
+
E.value.body[A],
|
|
553
565
|
he({
|
|
554
566
|
p: e.value.style.chart.layout.labels.prefix,
|
|
555
|
-
v: E.value.body[
|
|
567
|
+
v: E.value.body[A],
|
|
556
568
|
s: e.value.style.chart.layout.labels.suffix,
|
|
557
569
|
r: e.value.table.td.roundingValue
|
|
558
570
|
})
|
|
559
571
|
);
|
|
560
572
|
return [
|
|
561
573
|
{
|
|
562
|
-
color:
|
|
563
|
-
name:
|
|
574
|
+
color: c.color,
|
|
575
|
+
name: c.name,
|
|
564
576
|
shape: "square"
|
|
565
577
|
},
|
|
566
578
|
be,
|
|
567
|
-
isNaN(E.value.body[
|
|
568
|
-
v: E.value.body[
|
|
579
|
+
isNaN(E.value.body[A] / ae.value) ? "-" : he({
|
|
580
|
+
v: E.value.body[A] / ae.value * 100,
|
|
569
581
|
s: "%",
|
|
570
582
|
r: e.value.table.td.roundingPercentage
|
|
571
583
|
})
|
|
@@ -593,7 +605,7 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
593
605
|
config: l
|
|
594
606
|
};
|
|
595
607
|
});
|
|
596
|
-
function
|
|
608
|
+
function Ut() {
|
|
597
609
|
return ce.value;
|
|
598
610
|
}
|
|
599
611
|
function ht() {
|
|
@@ -602,33 +614,33 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
602
614
|
function pt() {
|
|
603
615
|
D.value.showTooltip = !D.value.showTooltip;
|
|
604
616
|
}
|
|
605
|
-
const me =
|
|
606
|
-
function
|
|
617
|
+
const me = y(!1);
|
|
618
|
+
function Be() {
|
|
607
619
|
me.value = !me.value;
|
|
608
620
|
}
|
|
609
|
-
const ye =
|
|
621
|
+
const ye = y(null);
|
|
610
622
|
function ft(t) {
|
|
611
623
|
ye.value = t;
|
|
612
624
|
}
|
|
613
625
|
function gt() {
|
|
614
626
|
ye.value = null;
|
|
615
627
|
}
|
|
616
|
-
async function
|
|
628
|
+
async function Ht({ scale: t = 2 } = {}) {
|
|
617
629
|
if (!V.value) return;
|
|
618
|
-
const { width: o, height: l } = V.value.getBoundingClientRect(), a = o / l, { imageUri:
|
|
630
|
+
const { width: o, height: l } = V.value.getBoundingClientRect(), a = o / l, { imageUri: c, base64: A } = await bl({ domElement: V.value, base64: !0, img: !0, scale: t });
|
|
619
631
|
return {
|
|
620
|
-
imageUri:
|
|
621
|
-
base64:
|
|
632
|
+
imageUri: c,
|
|
633
|
+
base64: A,
|
|
622
634
|
title: e.value.style.chart.title.text,
|
|
623
635
|
width: o,
|
|
624
636
|
height: l,
|
|
625
637
|
aspectRatio: a
|
|
626
638
|
};
|
|
627
639
|
}
|
|
628
|
-
const ve =
|
|
640
|
+
const ve = m(() => {
|
|
629
641
|
const t = e.value.table.useDialog && !e.value.table.show, o = D.value.showTable;
|
|
630
642
|
return {
|
|
631
|
-
component: t ?
|
|
643
|
+
component: t ? H : p,
|
|
632
644
|
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? `: ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
633
645
|
props: t ? {
|
|
634
646
|
backgroundColor: e.value.table.th.backgroundColor,
|
|
@@ -659,50 +671,68 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
659
671
|
e.value.table.show || (t && e.value.table.useDialog && ue.value ? ue.value.open() : "close" in ue.value && ue.value.close());
|
|
660
672
|
});
|
|
661
673
|
function mt() {
|
|
662
|
-
D.value.showTable = !1,
|
|
674
|
+
D.value.showTable = !1, Ie.value && Ie.value.setTableIconState(!1);
|
|
675
|
+
}
|
|
676
|
+
const Wt = m(() => Le.value.map((t) => ({
|
|
677
|
+
...t,
|
|
678
|
+
name: t.display
|
|
679
|
+
}))), Gt = m(() => e.value.style.chart.backgroundColor), Xt = m(() => e.value.style.chart.legend), qt = m(() => e.value.style.chart.title), { exportSvg: Yt, getSvg: jt } = $l({
|
|
680
|
+
svg: Ne,
|
|
681
|
+
title: qt,
|
|
682
|
+
legend: Xt,
|
|
683
|
+
legendItems: Wt,
|
|
684
|
+
backgroundColor: Gt
|
|
685
|
+
});
|
|
686
|
+
async function yt({ isCb: t }) {
|
|
687
|
+
if (t) {
|
|
688
|
+
const { blob: o, url: l, text: a, dataUrl: c } = await jt();
|
|
689
|
+
e.value.userOptions.callbacks.svg({ blob: o, url: l, text: a, dataUrl: c });
|
|
690
|
+
} else
|
|
691
|
+
Yt();
|
|
663
692
|
}
|
|
664
693
|
return r({
|
|
665
|
-
getData:
|
|
666
|
-
getImage:
|
|
667
|
-
generateCsv:
|
|
668
|
-
generateImage:
|
|
669
|
-
|
|
694
|
+
getData: Ut,
|
|
695
|
+
getImage: Ht,
|
|
696
|
+
generateCsv: ze,
|
|
697
|
+
generateImage: lt,
|
|
698
|
+
generateSvg: yt,
|
|
699
|
+
generatePdf: tt,
|
|
670
700
|
toggleTable: ht,
|
|
671
701
|
toggleTooltip: pt,
|
|
672
|
-
toggleAnnotator:
|
|
673
|
-
toggleFullscreen:
|
|
674
|
-
}), (t, o) => (
|
|
702
|
+
toggleAnnotator: Be,
|
|
703
|
+
toggleFullscreen: vt
|
|
704
|
+
}), (t, o) => (h(), b("div", {
|
|
675
705
|
ref_key: "treemapChart",
|
|
676
706
|
ref: V,
|
|
677
|
-
class:
|
|
678
|
-
style:
|
|
679
|
-
id: `treemap_${
|
|
680
|
-
onMouseenter: o[2] || (o[2] = () =>
|
|
681
|
-
onMouseleave: o[3] || (o[3] = () =>
|
|
707
|
+
class: Me(`vue-data-ui-component vue-ui-treemap ${K.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
|
|
708
|
+
style: L(`font-family:${e.value.style.fontFamily};width:100%; ${e.value.responsive ? "height: 100%;" : ""} text-align:center;background:${e.value.style.chart.backgroundColor}`),
|
|
709
|
+
id: `treemap_${S.value}`,
|
|
710
|
+
onMouseenter: o[2] || (o[2] = () => d(Ke)(!0)),
|
|
711
|
+
onMouseleave: o[3] || (o[3] = () => d(Ke)(!1))
|
|
682
712
|
}, [
|
|
683
|
-
e.value.userOptions.buttons.annotator ? (
|
|
713
|
+
e.value.userOptions.buttons.annotator ? (h(), Z(d(u), {
|
|
684
714
|
key: 0,
|
|
685
|
-
svgRef:
|
|
715
|
+
svgRef: d(Ne),
|
|
686
716
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
687
717
|
color: e.value.style.chart.color,
|
|
688
718
|
active: me.value,
|
|
689
|
-
onClose:
|
|
690
|
-
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) :
|
|
691
|
-
|
|
719
|
+
onClose: Be
|
|
720
|
+
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : O("", !0),
|
|
721
|
+
Nt.value ? (h(), b("div", {
|
|
692
722
|
key: 1,
|
|
693
723
|
ref_key: "noTitle",
|
|
694
|
-
ref:
|
|
724
|
+
ref: Ye,
|
|
695
725
|
class: "vue-data-ui-no-title-space",
|
|
696
726
|
style: "height:36px; width: 100%;background:transparent"
|
|
697
|
-
}, null, 512)) :
|
|
698
|
-
e.value.style.chart.title.text ? (
|
|
727
|
+
}, null, 512)) : O("", !0),
|
|
728
|
+
e.value.style.chart.title.text ? (h(), b("div", {
|
|
699
729
|
key: 2,
|
|
700
730
|
ref_key: "chartTitle",
|
|
701
|
-
ref:
|
|
702
|
-
style:
|
|
731
|
+
ref: Ge,
|
|
732
|
+
style: L(`width:100%;background:${e.value.style.chart.backgroundColor};padding-bottom:6px`)
|
|
703
733
|
}, [
|
|
704
|
-
(
|
|
705
|
-
key: `title_${
|
|
734
|
+
(h(), Z(kl, {
|
|
735
|
+
key: `title_${je.value}`,
|
|
706
736
|
config: {
|
|
707
737
|
title: {
|
|
708
738
|
cy: "treemap-div-title",
|
|
@@ -714,23 +744,24 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
714
744
|
}
|
|
715
745
|
}
|
|
716
746
|
}, null, 8, ["config"]))
|
|
717
|
-
], 4)) :
|
|
718
|
-
|
|
719
|
-
id: `legend-top-${
|
|
720
|
-
}, null, 8,
|
|
721
|
-
e.value.userOptions.show &&
|
|
747
|
+
], 4)) : O("", !0),
|
|
748
|
+
_("div", {
|
|
749
|
+
id: `legend-top-${S.value}`
|
|
750
|
+
}, null, 8, Rl),
|
|
751
|
+
e.value.userOptions.show && F.value && (d(Je) || d(De)) ? (h(), Z(d(g), {
|
|
722
752
|
ref_key: "userOptionsRef",
|
|
723
|
-
ref:
|
|
724
|
-
key: `user_option_${
|
|
753
|
+
ref: Ie,
|
|
754
|
+
key: `user_option_${We.value}`,
|
|
725
755
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
726
756
|
color: e.value.style.chart.color,
|
|
727
|
-
isPrinting:
|
|
728
|
-
isImaging:
|
|
729
|
-
uid:
|
|
757
|
+
isPrinting: d(Qe),
|
|
758
|
+
isImaging: d(et),
|
|
759
|
+
uid: S.value,
|
|
730
760
|
hasTooltip: e.value.userOptions.buttons.tooltip && e.value.style.chart.tooltip.show,
|
|
731
761
|
hasPdf: e.value.userOptions.buttons.pdf,
|
|
732
762
|
hasXls: e.value.userOptions.buttons.csv,
|
|
733
763
|
hasImg: e.value.userOptions.buttons.img,
|
|
764
|
+
hasSvg: e.value.userOptions.buttons.svg,
|
|
734
765
|
hasTable: e.value.userOptions.buttons.table,
|
|
735
766
|
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
736
767
|
isFullscreen: K.value,
|
|
@@ -743,21 +774,22 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
743
774
|
callbacks: e.value.userOptions.callbacks,
|
|
744
775
|
printScale: e.value.userOptions.print.scale,
|
|
745
776
|
tableDialog: e.value.table.useDialog,
|
|
746
|
-
onToggleFullscreen:
|
|
747
|
-
onGeneratePdf:
|
|
748
|
-
onGenerateCsv:
|
|
749
|
-
onGenerateImage:
|
|
777
|
+
onToggleFullscreen: vt,
|
|
778
|
+
onGeneratePdf: d(tt),
|
|
779
|
+
onGenerateCsv: ze,
|
|
780
|
+
onGenerateImage: d(lt),
|
|
781
|
+
onGenerateSvg: yt,
|
|
750
782
|
onToggleTable: ht,
|
|
751
783
|
onToggleTooltip: pt,
|
|
752
|
-
onToggleAnnotator:
|
|
753
|
-
style:
|
|
754
|
-
visibility:
|
|
784
|
+
onToggleAnnotator: Be,
|
|
785
|
+
style: L({
|
|
786
|
+
visibility: d(Je) ? d(De) ? "visible" : "hidden" : "visible"
|
|
755
787
|
})
|
|
756
|
-
},
|
|
788
|
+
}, kt({ _: 2 }, [
|
|
757
789
|
t.$slots.menuIcon ? {
|
|
758
790
|
name: "menuIcon",
|
|
759
791
|
fn: T(({ isOpen: l, color: a }) => [
|
|
760
|
-
C(t.$slots, "menuIcon", le(
|
|
792
|
+
C(t.$slots, "menuIcon", te(le({ isOpen: l, color: a })), void 0, !0)
|
|
761
793
|
]),
|
|
762
794
|
key: "0"
|
|
763
795
|
} : void 0,
|
|
@@ -799,141 +831,149 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
799
831
|
t.$slots.optionFullscreen ? {
|
|
800
832
|
name: "optionFullscreen",
|
|
801
833
|
fn: T(({ toggleFullscreen: l, isFullscreen: a }) => [
|
|
802
|
-
C(t.$slots, "optionFullscreen", le(
|
|
834
|
+
C(t.$slots, "optionFullscreen", te(le({ toggleFullscreen: l, isFullscreen: a })), void 0, !0)
|
|
803
835
|
]),
|
|
804
836
|
key: "6"
|
|
805
837
|
} : void 0,
|
|
806
838
|
t.$slots.optionAnnotator ? {
|
|
807
839
|
name: "optionAnnotator",
|
|
808
840
|
fn: T(({ toggleAnnotator: l, isAnnotator: a }) => [
|
|
809
|
-
C(t.$slots, "optionAnnotator", le(
|
|
841
|
+
C(t.$slots, "optionAnnotator", te(le({ toggleAnnotator: l, isAnnotator: a })), void 0, !0)
|
|
810
842
|
]),
|
|
811
843
|
key: "7"
|
|
812
844
|
} : void 0
|
|
813
|
-
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasTable", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "tableDialog", "onGeneratePdf", "onGenerateImage", "style"])) :
|
|
814
|
-
j.value.length > 1 ? (
|
|
845
|
+
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasSvg", "hasTable", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "tableDialog", "onGeneratePdf", "onGenerateImage", "style"])) : O("", !0),
|
|
846
|
+
j.value.length > 1 ? (h(), b("nav", {
|
|
815
847
|
key: 4,
|
|
816
848
|
class: "vue-ui-treemap-breadcrumbs",
|
|
817
849
|
"data-dom-to-png-ignore": "",
|
|
818
850
|
ref_key: "breadcrumbsNav",
|
|
819
|
-
ref:
|
|
851
|
+
ref: Ae
|
|
820
852
|
}, [
|
|
821
|
-
(
|
|
853
|
+
(h(!0), b(Ce, null, Ve(j.value, (l, a) => (h(), b("span", {
|
|
822
854
|
role: "button",
|
|
823
855
|
tabindex: a < j.value.length - 1 ? 0 : void 0,
|
|
824
856
|
key: l.id || "root",
|
|
825
|
-
onClick: (
|
|
857
|
+
onClick: (c) => a === j.value.length - 1 ? () => {
|
|
826
858
|
} : fe(l.node),
|
|
827
859
|
onKeydown: [
|
|
828
|
-
|
|
829
|
-
|
|
860
|
+
wt(Ee((c) => a === j.value.length - 1 ? void 0 : fe(l.node), ["prevent"]), ["enter"]),
|
|
861
|
+
wt(Ee((c) => a === j.value.length - 1 ? void 0 : fe(l.node), ["prevent"]), ["space"])
|
|
830
862
|
],
|
|
831
863
|
class: "vue-ui-treemap-crumb",
|
|
832
864
|
"data-last-crumb": a === j.value.length - 1,
|
|
833
|
-
style:
|
|
865
|
+
style: L({
|
|
834
866
|
color: e.value.style.chart.color
|
|
835
867
|
}),
|
|
836
|
-
onMouseenter: (
|
|
868
|
+
onMouseenter: (c) => ft(a),
|
|
837
869
|
onMouseleave: gt,
|
|
838
|
-
onFocus: (
|
|
870
|
+
onFocus: (c) => ft(a),
|
|
839
871
|
onBlur: gt
|
|
840
872
|
}, [
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
C(t.$slots, "breadcrumb-label",
|
|
844
|
-
a === 0 ? (
|
|
873
|
+
_("span", Pl, [
|
|
874
|
+
_("span", zl, [
|
|
875
|
+
C(t.$slots, "breadcrumb-label", Ue({ ref_for: !0 }, { crumb: l, isRoot: a === 0, isFocus: ye.value === a }), () => [
|
|
876
|
+
a === 0 ? (h(), b("div", Bl, [
|
|
845
877
|
we(_t, {
|
|
846
878
|
name: ye.value === 0 ? "homeFilled" : "home",
|
|
847
879
|
stroke: e.value.style.chart.color
|
|
848
880
|
}, null, 8, ["name", "stroke"])
|
|
849
|
-
])) : (
|
|
850
|
-
$e(
|
|
881
|
+
])) : (h(), b(Ce, { key: 1 }, [
|
|
882
|
+
$e(se(l.label), 1)
|
|
851
883
|
], 64))
|
|
852
884
|
], !0)
|
|
853
885
|
]),
|
|
854
|
-
a < j.value.length - 1 ? (
|
|
886
|
+
a < j.value.length - 1 ? (h(), b("span", Ml, [
|
|
855
887
|
C(t.$slots, "breadcrumb-arrow", {}, () => [
|
|
856
888
|
o[4] || (o[4] = $e(" › ", -1))
|
|
857
889
|
], !0)
|
|
858
|
-
])) :
|
|
890
|
+
])) : O("", !0)
|
|
859
891
|
])
|
|
860
|
-
], 44,
|
|
861
|
-
], 512)) :
|
|
862
|
-
(
|
|
892
|
+
], 44, Ll))), 128))
|
|
893
|
+
], 512)) : O("", !0),
|
|
894
|
+
(h(), b("svg", {
|
|
863
895
|
ref_key: "svgRef",
|
|
864
|
-
ref:
|
|
865
|
-
xmlns:
|
|
866
|
-
class:
|
|
867
|
-
viewBox: `${
|
|
868
|
-
style:
|
|
896
|
+
ref: Ne,
|
|
897
|
+
xmlns: d(ul),
|
|
898
|
+
class: Me({ "vue-data-ui-fullscreen--on": K.value, "vue-data-ui-fulscreen--off": !K.value, "vue-data-ui-zoom-plus": !Q.value, "vue-data-ui-zoom-minus": Q.value, loading: d(re) }),
|
|
899
|
+
viewBox: `${ne.value.startX} ${ne.value.startY} ${ne.value.width <= 0 ? 10 : ne.value.width} ${ne.value.height <= 0 ? 10 : ne.value.height}`,
|
|
900
|
+
style: L(`max-width:100%; overflow: hidden; background:transparent;color:${e.value.style.chart.color}`)
|
|
869
901
|
}, [
|
|
870
|
-
we(
|
|
871
|
-
(
|
|
902
|
+
we(d(f)),
|
|
903
|
+
(h(!0), b(Ce, null, Ve(ce.value, (l, a) => (h(), b("g", {
|
|
872
904
|
key: `tgrad_${l.id}`
|
|
873
905
|
}, [
|
|
874
|
-
e.value.style.chart.layout.rects.gradient.show ? (
|
|
875
|
-
|
|
906
|
+
e.value.style.chart.layout.rects.gradient.show ? (h(), b("defs", El, [
|
|
907
|
+
_("radialGradient", {
|
|
876
908
|
id: `tgrad_${l.id}`,
|
|
877
909
|
gradientTransform: "translate(-1, -1.000001) scale(2, 2)"
|
|
878
910
|
}, [
|
|
879
|
-
|
|
911
|
+
_("stop", {
|
|
880
912
|
offset: "18%",
|
|
881
913
|
"stop-color": l.color
|
|
882
|
-
}, null, 8,
|
|
883
|
-
|
|
914
|
+
}, null, 8, Hl),
|
|
915
|
+
_("stop", {
|
|
884
916
|
offset: "100%",
|
|
885
|
-
"stop-color":
|
|
886
|
-
}, null, 8,
|
|
887
|
-
], 8,
|
|
888
|
-
])) :
|
|
917
|
+
"stop-color": d($t)(l.color, e.value.style.chart.layout.rects.gradient.intensity / 100)
|
|
918
|
+
}, null, 8, Wl)
|
|
919
|
+
], 8, Ul)
|
|
920
|
+
])) : O("", !0)
|
|
889
921
|
]))), 128)),
|
|
890
|
-
(
|
|
922
|
+
(h(!0), b(Ce, null, Ve(ce.value, (l, a) => (h(), b("g", {
|
|
891
923
|
key: `k_${l.id}`
|
|
892
924
|
}, [
|
|
893
|
-
|
|
925
|
+
_("rect", {
|
|
894
926
|
x: l.x0,
|
|
895
927
|
y: l.y0,
|
|
896
|
-
height:
|
|
897
|
-
width:
|
|
898
|
-
fill:
|
|
928
|
+
height: it(l),
|
|
929
|
+
width: ct(l),
|
|
930
|
+
fill: M.value ? l.color : e.value.style.chart.layout.rects.gradient.show ? `url(#tgrad_${l.id})` : l.color,
|
|
899
931
|
rx: e.value.style.chart.layout.rects.borderRadius,
|
|
900
|
-
stroke:
|
|
901
|
-
"stroke-width":
|
|
902
|
-
onClick:
|
|
903
|
-
onMouseenter: () =>
|
|
932
|
+
stroke: B.value && B.value.id === l.id ? e.value.style.chart.layout.rects.selected.stroke : e.value.style.chart.layout.rects.stroke,
|
|
933
|
+
"stroke-width": B.value && B.value.id === l.id ? e.value.style.chart.layout.rects.selected.strokeWidth : e.value.style.chart.layout.rects.strokeWidth,
|
|
934
|
+
onClick: Ee((c) => fe(l, a), ["stop"]),
|
|
935
|
+
onMouseenter: () => Et({
|
|
904
936
|
datapoint: l,
|
|
905
937
|
seriesIndex: a
|
|
906
938
|
}),
|
|
907
|
-
onMouseleave: (
|
|
908
|
-
style:
|
|
909
|
-
class:
|
|
939
|
+
onMouseleave: (c) => Vt({ datapoint: l, seriesIndex: a }),
|
|
940
|
+
style: L(`opacity:${B.value ? B.value.id === l.id ? 1 : e.value.style.chart.layout.rects.selected.unselectedOpacity : 1}`),
|
|
941
|
+
class: Me([
|
|
910
942
|
"vue-ui-treemap-rect",
|
|
911
|
-
|
|
943
|
+
Bt(l) ? "vue-data-ui-zoom-plus" : Q.value ? "vue-data-ui-zoom-minus" : ""
|
|
912
944
|
])
|
|
913
|
-
}, null, 46,
|
|
914
|
-
(
|
|
945
|
+
}, null, 46, Gl),
|
|
946
|
+
(h(), b("foreignObject", {
|
|
915
947
|
x: l.x0,
|
|
916
948
|
y: l.y0,
|
|
917
|
-
height:
|
|
918
|
-
width:
|
|
949
|
+
height: it(l),
|
|
950
|
+
width: ct(l),
|
|
919
951
|
class: "vue-ui-treemap-cell-foreignObject"
|
|
920
952
|
}, [
|
|
921
|
-
|
|
922
|
-
|
|
953
|
+
_("div", {
|
|
954
|
+
style: L({
|
|
955
|
+
width: `calc(100% - ${q(l) / 1.5}px)`,
|
|
956
|
+
height: `calc(100% - ${q(l) / 1.5}px)`,
|
|
957
|
+
padding: `${q(l) / 3}px`,
|
|
958
|
+
lineHeight: `${q(l)}px`
|
|
959
|
+
}),
|
|
960
|
+
class: "vue-ui-treemap-cell"
|
|
961
|
+
}, [
|
|
962
|
+
e.value.style.chart.layout.labels.showDefaultLabels && (l.proportion > e.value.style.chart.layout.labels.hideUnderProportion || Q.value) ? (h(), b("div", {
|
|
923
963
|
key: 0,
|
|
924
964
|
class: "vue-ui-treemap-cell-default",
|
|
925
|
-
style:
|
|
965
|
+
style: L(`width:calc(100% - ${q(l) / 1.5}px);text-align:left; color:${d(Tt)(l.color)}`)
|
|
926
966
|
}, [
|
|
927
|
-
|
|
928
|
-
style:
|
|
929
|
-
},
|
|
930
|
-
o[5] || (o[5] =
|
|
931
|
-
|
|
932
|
-
style:
|
|
933
|
-
},
|
|
967
|
+
_("span", {
|
|
968
|
+
style: L(`width:100%;font-size:${q(l)}px;`)
|
|
969
|
+
}, se(l.name), 5),
|
|
970
|
+
o[5] || (o[5] = _("br", null, null, -1)),
|
|
971
|
+
_("span", {
|
|
972
|
+
style: L(`width:100%;font-size:${q(l)}px;`)
|
|
973
|
+
}, se(d(xe)(
|
|
934
974
|
e.value.style.chart.layout.labels.formatter,
|
|
935
975
|
l.value,
|
|
936
|
-
|
|
976
|
+
d(he)({
|
|
937
977
|
p: e.value.style.chart.layout.labels.prefix,
|
|
938
978
|
v: l.value,
|
|
939
979
|
s: e.value.style.chart.layout.labels.suffix,
|
|
@@ -941,76 +981,66 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
941
981
|
}),
|
|
942
982
|
{ datapoint: l }
|
|
943
983
|
)), 5)
|
|
944
|
-
], 4)) :
|
|
945
|
-
|
|
984
|
+
], 4)) : O("", !0),
|
|
985
|
+
d(re) ? O("", !0) : C(t.$slots, "rect", Ue({
|
|
946
986
|
key: 1,
|
|
947
987
|
ref_for: !0
|
|
948
988
|
}, {
|
|
949
989
|
rect: l,
|
|
950
|
-
shouldShow: l.proportion > e.value.style.chart.layout.labels.hideUnderProportion ||
|
|
951
|
-
fontSize:
|
|
952
|
-
isZoom:
|
|
953
|
-
textColor:
|
|
990
|
+
shouldShow: l.proportion > e.value.style.chart.layout.labels.hideUnderProportion || Q.value,
|
|
991
|
+
fontSize: q(l),
|
|
992
|
+
isZoom: Q.value,
|
|
993
|
+
textColor: d(Tt)(l.color)
|
|
954
994
|
}), void 0, !0)
|
|
955
|
-
])
|
|
956
|
-
], 8,
|
|
995
|
+
], 4)
|
|
996
|
+
], 8, Xl))
|
|
957
997
|
]))), 128)),
|
|
958
|
-
C(t.$slots, "svg", le(
|
|
959
|
-
], 14,
|
|
960
|
-
t.$slots.watermark ? (
|
|
961
|
-
C(t.$slots, "watermark", le(
|
|
962
|
-
])) :
|
|
963
|
-
|
|
964
|
-
id: `legend-bottom-${
|
|
965
|
-
}, null, 8,
|
|
966
|
-
|
|
998
|
+
C(t.$slots, "svg", te(le({ svg: J.value, isZoom: Q.value, rect: B.value, config: e.value })), void 0, !0)
|
|
999
|
+
], 14, Vl)),
|
|
1000
|
+
t.$slots.watermark ? (h(), b("div", ql, [
|
|
1001
|
+
C(t.$slots, "watermark", te(le({ isPrinting: d(Qe) || d(et) })), void 0, !0)
|
|
1002
|
+
])) : O("", !0),
|
|
1003
|
+
_("div", {
|
|
1004
|
+
id: `legend-bottom-${S.value}`
|
|
1005
|
+
}, null, 8, Yl),
|
|
1006
|
+
Ze.value ? (h(), Z(el, {
|
|
967
1007
|
key: 6,
|
|
968
|
-
to: e.value.style.chart.legend.position === "top" ? `#legend-top-${
|
|
1008
|
+
to: e.value.style.chart.legend.position === "top" ? `#legend-top-${S.value}` : `#legend-bottom-${S.value}`
|
|
969
1009
|
}, [
|
|
970
|
-
|
|
1010
|
+
_("div", {
|
|
971
1011
|
ref_key: "chartLegend",
|
|
972
|
-
ref:
|
|
1012
|
+
ref: Xe
|
|
973
1013
|
}, [
|
|
974
|
-
e.value.style.chart.legend.show ? (
|
|
975
|
-
key: `legend_${
|
|
976
|
-
legendSet:
|
|
1014
|
+
e.value.style.chart.legend.show ? (h(), Z(Cl, {
|
|
1015
|
+
key: `legend_${Se.value}`,
|
|
1016
|
+
legendSet: Le.value,
|
|
977
1017
|
config: Mt.value,
|
|
978
|
-
id: `treemap_legend_${
|
|
1018
|
+
id: `treemap_legend_${S.value}`,
|
|
979
1019
|
onClickMarker: o[0] || (o[0] = ({ legend: l }) => dt(l))
|
|
980
1020
|
}, {
|
|
981
1021
|
item: T(({ legend: l, index: a }) => [
|
|
982
|
-
|
|
1022
|
+
d(re) ? O("", !0) : (h(), b("div", {
|
|
983
1023
|
key: 0,
|
|
984
|
-
onClick: (
|
|
985
|
-
style:
|
|
986
|
-
},
|
|
987
|
-
e.value.style.chart.layout.labels.formatter,
|
|
988
|
-
l.value,
|
|
989
|
-
c(he)({
|
|
990
|
-
p: e.value.style.chart.layout.labels.prefix,
|
|
991
|
-
v: l.value,
|
|
992
|
-
s: e.value.style.chart.layout.labels.suffix,
|
|
993
|
-
r: e.value.style.chart.legend.roundingValue
|
|
994
|
-
}),
|
|
995
|
-
{ datapoint: l }
|
|
996
|
-
) : "") + " " + H(e.value.style.chart.legend.showPercentage ? z.value.includes(l.id) ? `${e.value.style.chart.legend.showValue ? "(" : ""}- %${e.value.style.chart.legend.showValue ? ")" : ""}` : `${e.value.style.chart.legend.showValue ? "(" : ""}${isNaN(l.value / ne.value) ? "-" : (l.value / ne.value * 100).toFixed(e.value.style.chart.legend.roundingPercentage)}%${e.value.style.chart.legend.showValue ? ")" : ""}` : ""), 13, Ul))
|
|
1024
|
+
onClick: (c) => dt(l),
|
|
1025
|
+
style: L(`opacity:${z.value.includes(l.id) ? 0.5 : 1}`)
|
|
1026
|
+
}, se(l.display), 13, jl))
|
|
997
1027
|
]),
|
|
998
1028
|
_: 1
|
|
999
1029
|
}, 8, ["legendSet", "config", "id"])) : C(t.$slots, "legend", {
|
|
1000
1030
|
key: 1,
|
|
1001
|
-
legend:
|
|
1031
|
+
legend: Le.value
|
|
1002
1032
|
}, void 0, !0)
|
|
1003
1033
|
], 512)
|
|
1004
|
-
], 8, ["to"])) :
|
|
1005
|
-
t.$slots.source ? (
|
|
1034
|
+
], 8, ["to"])) : O("", !0),
|
|
1035
|
+
t.$slots.source ? (h(), b("div", {
|
|
1006
1036
|
key: 7,
|
|
1007
1037
|
ref_key: "source",
|
|
1008
|
-
ref:
|
|
1038
|
+
ref: qe,
|
|
1009
1039
|
dir: "auto"
|
|
1010
1040
|
}, [
|
|
1011
1041
|
C(t.$slots, "source", {}, void 0, !0)
|
|
1012
|
-
], 512)) :
|
|
1013
|
-
we(
|
|
1042
|
+
], 512)) : O("", !0),
|
|
1043
|
+
we(d(v), {
|
|
1014
1044
|
show: D.value.showTooltip && N.value,
|
|
1015
1045
|
backgroundColor: e.value.style.chart.tooltip.backgroundColor,
|
|
1016
1046
|
color: e.value.style.chart.tooltip.color,
|
|
@@ -1022,30 +1052,30 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1022
1052
|
position: e.value.style.chart.tooltip.position,
|
|
1023
1053
|
offsetY: e.value.style.chart.tooltip.offsetY,
|
|
1024
1054
|
parent: V.value,
|
|
1025
|
-
content:
|
|
1055
|
+
content: Oe.value,
|
|
1026
1056
|
isFullscreen: K.value,
|
|
1027
|
-
isCustom:
|
|
1057
|
+
isCustom: d(xt)(e.value.style.chart.tooltip.customFormat),
|
|
1028
1058
|
smooth: e.value.style.chart.tooltip.smooth,
|
|
1029
1059
|
backdropFilter: e.value.style.chart.tooltip.backdropFilter,
|
|
1030
1060
|
smoothForce: e.value.style.chart.tooltip.smoothForce,
|
|
1031
1061
|
smoothSnapThreshold: e.value.style.chart.tooltip.smoothSnapThreshold
|
|
1032
1062
|
}, {
|
|
1033
1063
|
"tooltip-before": T(() => [
|
|
1034
|
-
C(t.$slots, "tooltip-before", le(
|
|
1064
|
+
C(t.$slots, "tooltip-before", te(le({ ...Pe.value })), void 0, !0)
|
|
1035
1065
|
]),
|
|
1036
1066
|
"tooltip-after": T(() => [
|
|
1037
|
-
C(t.$slots, "tooltip-after", le(
|
|
1067
|
+
C(t.$slots, "tooltip-after", te(le({ ...Pe.value })), void 0, !0)
|
|
1038
1068
|
]),
|
|
1039
1069
|
_: 3
|
|
1040
1070
|
}, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "position", "offsetY", "parent", "content", "isFullscreen", "isCustom", "smooth", "backdropFilter", "smoothForce", "smoothSnapThreshold"]),
|
|
1041
|
-
|
|
1071
|
+
F.value && e.value.userOptions.buttons.table ? (h(), Z(tl(ve.value.component), Ue({ key: 8 }, ve.value.props, {
|
|
1042
1072
|
ref_key: "tableUnit",
|
|
1043
1073
|
ref: ue,
|
|
1044
1074
|
onClose: mt
|
|
1045
|
-
}),
|
|
1075
|
+
}), kt({
|
|
1046
1076
|
content: T(() => [
|
|
1047
|
-
(
|
|
1048
|
-
key: `table_${
|
|
1077
|
+
(h(), Z(d(i), {
|
|
1078
|
+
key: `table_${_e.value}`,
|
|
1049
1079
|
colNames: ge.value.colNames,
|
|
1050
1080
|
head: ge.value.head,
|
|
1051
1081
|
body: ge.value.body,
|
|
@@ -1055,13 +1085,13 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1055
1085
|
onClose: mt
|
|
1056
1086
|
}, {
|
|
1057
1087
|
th: T(({ th: l }) => [
|
|
1058
|
-
|
|
1088
|
+
_("div", {
|
|
1059
1089
|
innerHTML: l,
|
|
1060
1090
|
style: { display: "flex", "align-items": "center" }
|
|
1061
|
-
}, null, 8,
|
|
1091
|
+
}, null, 8, Zl)
|
|
1062
1092
|
]),
|
|
1063
1093
|
td: T(({ td: l }) => [
|
|
1064
|
-
$e(
|
|
1094
|
+
$e(se(l.name || l), 1)
|
|
1065
1095
|
]),
|
|
1066
1096
|
_: 1
|
|
1067
1097
|
}, 8, ["colNames", "head", "body", "config", "title", "withCloseButton"]))
|
|
@@ -1071,17 +1101,17 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1071
1101
|
e.value.table.useDialog ? {
|
|
1072
1102
|
name: "title",
|
|
1073
1103
|
fn: T(() => [
|
|
1074
|
-
$e(
|
|
1104
|
+
$e(se(ve.value.title), 1)
|
|
1075
1105
|
]),
|
|
1076
1106
|
key: "0"
|
|
1077
1107
|
} : void 0,
|
|
1078
1108
|
e.value.table.useDialog ? {
|
|
1079
1109
|
name: "actions",
|
|
1080
1110
|
fn: T(() => [
|
|
1081
|
-
|
|
1111
|
+
_("button", {
|
|
1082
1112
|
tabindex: "0",
|
|
1083
1113
|
class: "vue-ui-user-options-button",
|
|
1084
|
-
onClick: o[1] || (o[1] = (l) =>
|
|
1114
|
+
onClick: o[1] || (o[1] = (l) => ze(e.value.userOptions.callbacks.csv))
|
|
1085
1115
|
}, [
|
|
1086
1116
|
we(_t, {
|
|
1087
1117
|
name: "excel",
|
|
@@ -1091,11 +1121,11 @@ const xl = ["id"], _l = ["id"], Ol = ["tabindex", "onClick", "onKeydown", "data-
|
|
|
1091
1121
|
]),
|
|
1092
1122
|
key: "1"
|
|
1093
1123
|
} : void 0
|
|
1094
|
-
]), 1040)) :
|
|
1095
|
-
|
|
1096
|
-
], 46,
|
|
1124
|
+
]), 1040)) : O("", !0),
|
|
1125
|
+
d(re) ? (h(), Z(fl, { key: 9 })) : O("", !0)
|
|
1126
|
+
], 46, Nl));
|
|
1097
1127
|
}
|
|
1098
|
-
},
|
|
1128
|
+
}, po = /* @__PURE__ */ Tl(Kl, [["__scopeId", "data-v-49f64e31"]]);
|
|
1099
1129
|
export {
|
|
1100
|
-
|
|
1130
|
+
po as default
|
|
1101
1131
|
};
|