vue-data-ui 3.0.22 → 3.1.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-C3_2GkYQ.js → Arrow-DvG07exK.js} +1 -1
- package/dist/{BaseDraggableDialog-BhxUDwEm.js → BaseDraggableDialog-O7900pGp.js} +72 -59
- package/dist/{BaseIcon-B717hnWR.js → BaseIcon-DHtro8us.js} +1 -1
- package/dist/{useLoading-D7YHNtLX.js → BaseScanner-BgWxam9d.js} +11 -11
- package/dist/{ColorPicker-CH5_RNaK.js → ColorPicker-CpWzNn4r.js} +2 -2
- package/dist/DataTable-DJjA2_wf.js +140 -0
- package/dist/Legend-2-dC7DVb.js +72 -0
- package/dist/{NonSvgPenAndPaper-DCJGSteM.js → NonSvgPenAndPaper-DHeE4Yuv.js} +3 -3
- package/dist/{PackageVersion-CE7HSich.js → PackageVersion-DU12WH3O.js} +1 -1
- package/dist/{PenAndPaper-BMHsOtT8.js → PenAndPaper-B7QEDgx4.js} +3 -3
- package/dist/{Shape-C3J8aKNH.js → Shape-Dj2Hl33H.js} +1 -1
- package/dist/{Slicer-BEBDljWA.js → Slicer-D99HytqX.js} +2 -2
- package/dist/{SparkTooltip-CVSZQtoP.js → SparkTooltip-B-wL07rI.js} +1 -1
- package/dist/{Title-BL-IjQmj.js → Title-Dq2_Z9kR.js} +1 -1
- package/dist/{Tooltip-CCnDaboi.js → Tooltip-Y219DXZO.js} +1 -1
- package/dist/{UserOptions-BWMV0_Ze.js → UserOptions-BuGfCdAY.js} +2 -2
- package/dist/{dom-to-png-DwUGURhV.js → dom-to-png-BhciAKaM.js} +1 -1
- package/dist/{img-DsVqerdt.js → img-JOqdlnUs.js} +1 -1
- package/dist/{index-BHb_mcWF.js → index-CDQbCd41.js} +37 -2
- package/dist/{pdf-Ckt8JtYf.js → pdf-Dd-LIJqz.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +35 -0
- package/dist/types/vue-data-ui.d.ts +35 -0
- package/dist/{useAutoSizeLabelsInsideViewbox-Cy946l1e.js → useAutoSizeLabelsInsideViewbox-Bky5KGFZ.js} +1 -1
- package/dist/{useNestedProp-aC9S6EFJ.js → useNestedProp-BPEHGiYX.js} +1 -1
- package/dist/{usePrinter-B7rhbRrT.js → usePrinter-Bnl1YeUU.js} +2 -2
- package/dist/{vue-data-ui-Bu7qDtf0.js → vue-data-ui-DcNYz3cZ.js} +64 -64
- package/dist/vue-data-ui.js +1 -1
- package/dist/vue-ui-3d-bar-BNIFAeN-.js +1369 -0
- package/dist/{vue-ui-accordion-DsnF0JuK.js → vue-ui-accordion-Bf_LHFFX.js} +3 -3
- package/dist/{vue-ui-age-pyramid-s8xyb3Gf.js → vue-ui-age-pyramid-Bz-l1afR.js} +333 -286
- package/dist/{vue-ui-annotator-DRacM62z.js → vue-ui-annotator-BcfRH2BF.js} +2 -2
- package/dist/{vue-ui-bullet-DdDrdyOJ.js → vue-ui-bullet-DK1aM9fX.js} +8 -8
- package/dist/{vue-ui-candlestick-BsNnInNt.js → vue-ui-candlestick-D6mMjvtu.js} +453 -406
- package/dist/{vue-ui-carousel-table-Ci9mrUBd.js → vue-ui-carousel-table-Vp5f238W.js} +4 -4
- package/dist/{vue-ui-chestnut-fHfJNK0V.js → vue-ui-chestnut-BKc4v-lf.js} +509 -459
- package/dist/vue-ui-chord-CquhRjf0.js +1100 -0
- package/dist/vue-ui-circle-pack-D6zLgxa3.js +755 -0
- package/dist/{vue-ui-cursor-Bk5LHg5V.js → vue-ui-cursor-DIXb2S93.js} +2 -2
- package/dist/{vue-ui-dashboard-CjZMEYs6.js → vue-ui-dashboard-DmiriAK7.js} +62 -62
- package/dist/{vue-ui-digits-nDIvHyRB.js → vue-ui-digits-CLAIo9gW.js} +2 -2
- package/dist/{vue-ui-donut-CF9FdxfC.js → vue-ui-donut-C8h_tCSO.js} +477 -431
- package/dist/{vue-ui-donut-evolution-f5k-Yu3N.js → vue-ui-donut-evolution-C3r0YhKz.js} +482 -435
- package/dist/{vue-ui-dumbbell-Dm3gsrzi.js → vue-ui-dumbbell-D-t4M00E.js} +443 -398
- package/dist/vue-ui-flow-D7_D_UNm.js +900 -0
- package/dist/vue-ui-funnel-B0QOfZRz.js +666 -0
- package/dist/vue-ui-galaxy-Ccw5uNes.js +744 -0
- package/dist/{vue-ui-gauge-DkDpUAN7.js → vue-ui-gauge-DvW7nFmK.js} +8 -8
- package/dist/{vue-ui-gizmo-BD5fLs8r.js → vue-ui-gizmo-WGQxvGPy.js} +4 -4
- package/dist/vue-ui-heatmap-BQkLujyp.js +1127 -0
- package/dist/{vue-ui-history-plot-ICoBBO-y.js → vue-ui-history-plot-eU33r_Ot.js} +408 -361
- package/dist/{vue-ui-kpi-Dp2M2EFo.js → vue-ui-kpi-CKg2i71M.js} +3 -3
- package/dist/{vue-ui-mini-loader-C5672jjA.js → vue-ui-mini-loader-BmkGQsm_.js} +2 -2
- package/dist/vue-ui-molecule-Dlu0hjSg.js +702 -0
- package/dist/{vue-ui-mood-radar-B-qhYUcB.js → vue-ui-mood-radar-DQaxfw9R.js} +342 -291
- package/dist/{vue-ui-nested-donuts-V6BvP3pF.js → vue-ui-nested-donuts-Djj9Aw_i.js} +548 -502
- package/dist/{vue-ui-onion-BKqqbWbg.js → vue-ui-onion-ZgsErXis.js} +363 -317
- package/dist/vue-ui-parallel-coordinate-plot-B5fB22Jc.js +979 -0
- package/dist/vue-ui-quadrant-CMevCtXH.js +1483 -0
- package/dist/{vue-ui-quick-chart-BVZSdQeT.js → vue-ui-quick-chart-DcparKSX.js} +7 -7
- package/dist/vue-ui-radar-DFbxoKCK.js +858 -0
- package/dist/{vue-ui-rating-CncrxDCY.js → vue-ui-rating-ZUpxCWrk.js} +2 -2
- package/dist/{vue-ui-relation-circle-VYM1dclx.js → vue-ui-relation-circle-eNKJY4Sx.js} +8 -8
- package/dist/vue-ui-ridgeline-D4shpQZd.js +1204 -0
- package/dist/vue-ui-rings-TdTHMbsa.js +785 -0
- package/dist/{vue-ui-scatter-D2b-u5dv.js → vue-ui-scatter-CVuV9ljU.js} +594 -548
- package/dist/{vue-ui-skeleton-BTuBaaE_.js → vue-ui-skeleton-CFxBU2-p.js} +3 -3
- package/dist/{vue-ui-smiley-D1UxJNbV.js → vue-ui-smiley-Har3B3aQ.js} +2 -2
- package/dist/{vue-ui-spark-trend-BCP0BWMI.js → vue-ui-spark-trend-FPk-XEwI.js} +4 -4
- package/dist/{vue-ui-sparkbar-eBo-RSvE.js → vue-ui-sparkbar-V3eJ0w0t.js} +4 -4
- package/dist/{vue-ui-sparkgauge-DberOXWX.js → vue-ui-sparkgauge-DKTGkWnJ.js} +4 -4
- package/dist/{vue-ui-sparkhistogram-CoKQGG5X.js → vue-ui-sparkhistogram-DJsgFwHs.js} +5 -5
- package/dist/{vue-ui-sparkline-B_L4UNES.js → vue-ui-sparkline-Dmrm5SL5.js} +4 -4
- package/dist/{vue-ui-sparkstackbar-iAaRIyqb.js → vue-ui-sparkstackbar-B0Pl7VMI.js} +4 -4
- package/dist/{vue-ui-stackbar-B_0PJ7R2.js → vue-ui-stackbar-CNsgBPhj.js} +525 -479
- package/dist/{vue-ui-strip-plot-CWkA4l9P.js → vue-ui-strip-plot-CYAWwYOM.js} +390 -343
- package/dist/{vue-ui-table-CILVy7YP.js → vue-ui-table-Dn6H98rP.js} +3 -3
- package/dist/{vue-ui-table-heatmap-DL2n2Z7p.js → vue-ui-table-heatmap-COI9LRqC.js} +5 -5
- package/dist/{vue-ui-table-sparkline-DOt2EKpe.js → vue-ui-table-sparkline-B7Gg5FfJ.js} +4 -4
- package/dist/{vue-ui-thermometer-BTP1ic_T.js → vue-ui-thermometer-Bgynq5El.js} +8 -8
- package/dist/{vue-ui-timer-Bc-zJH9j.js → vue-ui-timer-CXng51v5.js} +5 -5
- package/dist/{vue-ui-tiremarks-B9n528e1.js → vue-ui-tiremarks-Cy1U3hO1.js} +7 -7
- package/dist/vue-ui-treemap-BsvIvRmE.js +1092 -0
- package/dist/{vue-ui-vertical-bar-CK2j09gJ.js → vue-ui-vertical-bar-DHqWeDIf.js} +512 -464
- package/dist/{vue-ui-waffle-DJkqgqlR.js → vue-ui-waffle-D1Mscj3N.js} +416 -370
- package/dist/{vue-ui-wheel-CcbgpIUr.js → vue-ui-wheel-DpV-N5tF.js} +7 -7
- package/dist/vue-ui-word-cloud-MaNQ3Kdk.js +811 -0
- package/dist/{vue-ui-world-DLmB_Z96.js → vue-ui-world-DYz6zw3x.js} +512 -466
- package/dist/{vue-ui-xy-KmrNT6qh.js → vue-ui-xy-B1nqNbzw.js} +1559 -1508
- package/dist/vue-ui-xy-canvas-D4wd-Asd.js +1291 -0
- package/package.json +1 -1
- package/dist/DataTable-Y5T9UxMO.js +0 -133
- package/dist/Legend-DkU3at-b.js +0 -72
- package/dist/vue-ui-3d-bar-CBfQ3Pcb.js +0 -1323
- package/dist/vue-ui-chord-0wf798ls.js +0 -1049
- package/dist/vue-ui-circle-pack-CuRHG8gr.js +0 -709
- package/dist/vue-ui-flow-K7UBguES.js +0 -852
- package/dist/vue-ui-funnel-DoDZbsTp.js +0 -620
- package/dist/vue-ui-galaxy-BsDlHxzE.js +0 -691
- package/dist/vue-ui-heatmap-DOT2tBy_.js +0 -1078
- package/dist/vue-ui-molecule-DgqVh2k0.js +0 -656
- package/dist/vue-ui-parallel-coordinate-plot-BZf24Zur.js +0 -927
- package/dist/vue-ui-quadrant-S58B2LrQ.js +0 -1432
- package/dist/vue-ui-radar-Dh67mQ9E.js +0 -807
- package/dist/vue-ui-ridgeline-CsByERvm.js +0 -1157
- package/dist/vue-ui-rings-CR2UfgnV.js +0 -739
- package/dist/vue-ui-treemap-Cl9qo9O-.js +0 -1046
- package/dist/vue-ui-word-cloud-CZ_TRf4o.js +0 -765
- package/dist/vue-ui-xy-canvas-6VYNyX6a.js +0 -1243
|
@@ -0,0 +1,755 @@
|
|
|
1
|
+
import { useCssVars as mt, computed as _, defineAsyncComponent as N, ref as y, toRefs as pt, watch as ne, shallowRef as Ue, onMounted as yt, onBeforeUnmount as bt, watchEffect as gt, createElementBlock as b, openBlock as m, unref as r, normalizeStyle as se, normalizeClass as Ve, createBlock as V, createCommentVNode as C, renderSlot as k, createSlots as He, withCtx as z, normalizeProps as J, guardReactiveProps as K, createVNode as je, Fragment as ue, renderList as kt, createElementVNode as $, mergeProps as be, toDisplayString as H, resolveDynamicComponent as wt, createTextVNode as Ge, nextTick as We } from "vue";
|
|
2
|
+
import { u as xt, c as qe, t as Ct, a as ge, p as re, b as _t, o as zt, f as $t, d as Tt, e as St, j as Xe, i as ke, X as Ft, l as Ot, F as Q, al as It, v as Pt, w as At, k as Ye } from "./index-CDQbCd41.js";
|
|
3
|
+
import { t as Dt, u as Mt } from "./useResponsive-DfdjqQps.js";
|
|
4
|
+
import { u as Et } from "./usePrinter-Bnl1YeUU.js";
|
|
5
|
+
import { u as Nt, B as Rt } from "./BaseScanner-BgWxam9d.js";
|
|
6
|
+
import { u as Ze } from "./useNestedProp-BPEHGiYX.js";
|
|
7
|
+
import { u as Bt } from "./useUserOptionState-BIvW1Kz7.js";
|
|
8
|
+
import { u as Lt } from "./useChartAccessibility-9icAAmYg.js";
|
|
9
|
+
import Ut from "./img-JOqdlnUs.js";
|
|
10
|
+
import Vt from "./Title-Dq2_Z9kR.js";
|
|
11
|
+
import { _ as Ht } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
12
|
+
function Je(u, c = 0) {
|
|
13
|
+
const f = u.reduce((o, { x: s, r: d }) => Math.min(o, s - d - c), 1 / 0), p = u.reduce((o, { x: s, r: d }) => Math.max(o, s + d + c), -1 / 0), v = u.reduce((o, { y: s, r: d }) => Math.min(o, s - d - c), 1 / 0), n = u.reduce((o, { y: s, r: d }) => Math.max(o, s + d + c), -1 / 0);
|
|
14
|
+
return [f, v, p - f, n - v];
|
|
15
|
+
}
|
|
16
|
+
function jt(u, c, f) {
|
|
17
|
+
const p = u._, v = u.next._, n = p.r + v.r, o = (p.x * v.r + v.x * p.r) / n, s = (p.y * v.r + v.y * p.r) / n;
|
|
18
|
+
return Math.max(Math.abs(o * f), Math.abs(s * c));
|
|
19
|
+
}
|
|
20
|
+
function Ke(u, c, f) {
|
|
21
|
+
const p = jt, v = u.length;
|
|
22
|
+
if (!v) return u;
|
|
23
|
+
let n, o, s;
|
|
24
|
+
if (n = u[0], n.x = 0, n.y = 0, !(v > 1) || (o = u[1], n.x = -o.r, o.x = n.r, o.y = 0, !(v > 2))) return u;
|
|
25
|
+
Qe(o, n, s = u[2]), n = new ie(n), o = new ie(o), s = new ie(s), n.next = s.previous = o, o.next = n.previous = s, s.next = o.previous = n;
|
|
26
|
+
e: for (let d = 3; d < v; ++d) {
|
|
27
|
+
Qe(n._, o._, s = u[d]), s = new ie(s);
|
|
28
|
+
let w = o.next, x = n.previous, ee = o._.r, te = n._.r;
|
|
29
|
+
do
|
|
30
|
+
if (ee <= te) {
|
|
31
|
+
if (et(w._, s._)) {
|
|
32
|
+
o = w, n.next = o, o.previous = n, --d;
|
|
33
|
+
continue e;
|
|
34
|
+
}
|
|
35
|
+
ee += w._.r, w = w.next;
|
|
36
|
+
} else {
|
|
37
|
+
if (et(x._, s._)) {
|
|
38
|
+
n = x, n.next = o, o.previous = n, --d;
|
|
39
|
+
continue e;
|
|
40
|
+
}
|
|
41
|
+
te += x._.r, x = x.previous;
|
|
42
|
+
}
|
|
43
|
+
while (w !== x.next);
|
|
44
|
+
s.previous = n, s.next = o, n.next = o.previous = o = s;
|
|
45
|
+
let j = p(n, f, c), S;
|
|
46
|
+
for (; (s = s.next) !== o; )
|
|
47
|
+
(S = p(s, f, c)) < j && (n = s, j = S);
|
|
48
|
+
o = n.next;
|
|
49
|
+
}
|
|
50
|
+
return u;
|
|
51
|
+
}
|
|
52
|
+
function Qe(u, c, f) {
|
|
53
|
+
const p = u.x - c.x, v = u.y - c.y, n = p * p + v * v;
|
|
54
|
+
if (n) {
|
|
55
|
+
const o = (c.r + f.r) ** 2, s = (u.r + f.r) ** 2;
|
|
56
|
+
if (o > s) {
|
|
57
|
+
const d = (n + s - o) / (2 * n), w = Math.sqrt(Math.max(0, s / n - d * d));
|
|
58
|
+
f.x = u.x - d * p - w * v, f.y = u.y - d * v + w * p;
|
|
59
|
+
} else {
|
|
60
|
+
const d = (n + o - s) / (2 * n), w = Math.sqrt(Math.max(0, o / n - d * d));
|
|
61
|
+
f.x = c.x + d * p - w * v, f.y = c.y + d * v + w * p;
|
|
62
|
+
}
|
|
63
|
+
} else
|
|
64
|
+
f.x = c.x + f.r, f.y = c.y;
|
|
65
|
+
}
|
|
66
|
+
function et(u, c) {
|
|
67
|
+
const f = u.r + c.r - 1e-6, p = c.x - u.x, v = c.y - u.y;
|
|
68
|
+
return f > 0 && f * f > p * p + v * v;
|
|
69
|
+
}
|
|
70
|
+
class ie {
|
|
71
|
+
constructor(c) {
|
|
72
|
+
this._ = c, this.next = null, this.previous = null;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
const Gt = ["id"], Wt = ["xmlns", "viewBox", "height", "width"], qt = ["x", "y", "width", "height"], Xt = ["id"], Yt = ["stop-color"], Zt = ["stop-color"], Jt = ["stop-color"], Kt = { key: 0 }, Qt = ["x", "y", "width", "height", "stroke", "stroke-width", "fill", "rx", "onMouseenter", "onMouseout", "onClick"], el = ["x", "y", "width", "height", "stroke", "stroke-width", "fill", "rx"], tl = ["opacity", "x", "y", "font-size", "fill", "font-weight"], ll = ["opacity", "x", "y", "font-size", "fill", "font-weight"], al = ["cx", "cy", "r", "opacity", "stroke", "stroke-width", "fill"], ol = {
|
|
76
|
+
key: 0,
|
|
77
|
+
style: { pointerEvents: "none" }
|
|
78
|
+
}, nl = { key: 1 }, sl = ["opacity", "x", "y", "font-size", "fill", "font-weight"], ul = ["opacity", "x", "y", "font-size", "fill", "font-weight"], rl = {
|
|
79
|
+
key: 4,
|
|
80
|
+
class: "vue-data-ui-watermark"
|
|
81
|
+
}, il = ["innerHTML"], cl = {
|
|
82
|
+
__name: "vue-ui-circle-pack",
|
|
83
|
+
props: {
|
|
84
|
+
config: {
|
|
85
|
+
type: Object,
|
|
86
|
+
default() {
|
|
87
|
+
return {};
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
dataset: {
|
|
91
|
+
type: Array,
|
|
92
|
+
default() {
|
|
93
|
+
return [];
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
emits: ["selectDatapoint"],
|
|
98
|
+
setup(u, { expose: c, emit: f }) {
|
|
99
|
+
mt((t) => ({
|
|
100
|
+
"5748196e": L.value,
|
|
101
|
+
"2de8b0e7": he.value
|
|
102
|
+
}));
|
|
103
|
+
const p = N(() => import("./BaseIcon-DHtro8us.js")), v = N(() => import("./vue-ui-accordion-Bf_LHFFX.js")), n = N(() => import("./DataTable-DJjA2_wf.js")), o = N(() => import("./UserOptions-BuGfCdAY.js")), s = N(() => import("./PenAndPaper-B7QEDgx4.js")), d = N(() => import("./PackageVersion-DU12WH3O.js")), w = N(() => import("./BaseDraggableDialog-O7900pGp.js")), x = u, ee = f, { vue_ui_circle_pack: te } = xt(), j = _(() => !!x.dataset && x.dataset.length), S = y(qe()), T = y(null), we = y(null), xe = y(null), Ce = y(0), _e = y(0), ze = y(0), tt = y(null), G = y(null), e = y(ve()), { loading: $e, FINAL_DATASET: Te } = Nt({
|
|
104
|
+
...pt(x),
|
|
105
|
+
FINAL_CONFIG: e,
|
|
106
|
+
prepareConfig: ve,
|
|
107
|
+
skeletonDataset: [
|
|
108
|
+
{ name: "_", value: 13, color: "#F2F2F2" },
|
|
109
|
+
{ name: "_", value: 8, color: "#DBDBDB" },
|
|
110
|
+
{ name: "_", value: 5, color: "#ADADAD" },
|
|
111
|
+
{ name: "_", value: 3, color: "#969696" },
|
|
112
|
+
{ name: "_", value: 2, color: "#808080" },
|
|
113
|
+
{ name: "_", value: 1, color: "#696969" }
|
|
114
|
+
],
|
|
115
|
+
skeletonConfig: Ct({
|
|
116
|
+
defaultConfig: e.value,
|
|
117
|
+
userConfig: {
|
|
118
|
+
userOptions: { show: !1 },
|
|
119
|
+
table: { show: !1 },
|
|
120
|
+
style: {
|
|
121
|
+
chart: {
|
|
122
|
+
backgroundColor: "#99999930",
|
|
123
|
+
circles: {
|
|
124
|
+
stroke: "#6A6A6A",
|
|
125
|
+
labels: {
|
|
126
|
+
name: { show: !1 },
|
|
127
|
+
value: { show: !1 }
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
})
|
|
134
|
+
}), { svgRef: Se } = Lt({ config: e.value.style.chart.title }), {
|
|
135
|
+
userOptionsVisible: ce,
|
|
136
|
+
setUserOptionsVisibility: Fe,
|
|
137
|
+
keepUserOptionState: Oe
|
|
138
|
+
} = Bt({ config: e.value });
|
|
139
|
+
function ve() {
|
|
140
|
+
const t = Ze({
|
|
141
|
+
userConfig: x.config,
|
|
142
|
+
defaultConfig: te
|
|
143
|
+
});
|
|
144
|
+
return t.theme ? {
|
|
145
|
+
...Ze({
|
|
146
|
+
userConfig: _t.vue_ui_circle_pack[t.theme] || x.config,
|
|
147
|
+
defaultConfig: t
|
|
148
|
+
}),
|
|
149
|
+
customPalette: ge[t.theme] || re
|
|
150
|
+
} : t;
|
|
151
|
+
}
|
|
152
|
+
ne(() => x.config, (t) => {
|
|
153
|
+
e.value = ve(), ce.value = !e.value.userOptions.showOnChartHover, de(), Ce.value += 1, _e.value += 1, F.value.showTable = e.value.table.show;
|
|
154
|
+
}, { deep: !0 });
|
|
155
|
+
const { isPrinting: Ie, isImaging: Pe, generatePdf: Ae, generateImage: De } = Et({
|
|
156
|
+
elementId: `vue-ui-circle-pack_${S.value}`,
|
|
157
|
+
fileName: e.value.style.chart.title.text || "vue-ui-circle-pack",
|
|
158
|
+
options: e.value.userOptions.print
|
|
159
|
+
}), lt = _(() => e.value.userOptions.show && !e.value.style.chart.title.text), F = y({
|
|
160
|
+
showTable: e.value.table.show
|
|
161
|
+
});
|
|
162
|
+
ne(e, () => {
|
|
163
|
+
F.value = {
|
|
164
|
+
showTable: e.value.table.show
|
|
165
|
+
};
|
|
166
|
+
}, { immediate: !0 });
|
|
167
|
+
const O = Ue(null), R = Ue(null), D = y({ h: 10, w: 10 }), Me = y(0), M = y([0, 0, 100, 100]), W = y({ h: 0, w: 0 }), at = _(() => e.value.debug);
|
|
168
|
+
async function de() {
|
|
169
|
+
zt(x.dataset) && $t({
|
|
170
|
+
componentName: "VueUiCirclePack",
|
|
171
|
+
type: "dataset",
|
|
172
|
+
debug: at.value
|
|
173
|
+
}), D.value = { h: 10, w: 10 }, M.value = [0, 0, 100, 100], W.value = { h: 0, w: 0 }, B.value = await Ke(le.value), I.value = Je(B.value, 1).join(" "), W.value = Ee(T.value);
|
|
174
|
+
const t = Dt(() => {
|
|
175
|
+
const { width: a, height: l, heightTitle: i, heightNoTitle: g } = Mt({
|
|
176
|
+
chart: T.value,
|
|
177
|
+
title: we.value,
|
|
178
|
+
noTitle: xe.value
|
|
179
|
+
}), E = Math.max(10, a), ye = Math.max(10, l - 12);
|
|
180
|
+
Me.value = e.value.style.chart.title.text ? i : g, requestAnimationFrame(() => {
|
|
181
|
+
D.value.w = E, D.value.h = ye - Me.value, We(async () => {
|
|
182
|
+
const ht = le.value.map((ft) => ({ ...ft }));
|
|
183
|
+
B.value = await Ke(ht, D.value.h, D.value.w), M.value = Je(B.value, 1), I.value = M.value.join(" "), W.value = Ee(T.value);
|
|
184
|
+
});
|
|
185
|
+
});
|
|
186
|
+
});
|
|
187
|
+
O.value && (R.value && O.value.unobserve(R.value), O.value.disconnect()), O.value = new ResizeObserver(t), R.value = T.value.parentNode, O.value.observe(R.value);
|
|
188
|
+
}
|
|
189
|
+
yt(de), bt(() => {
|
|
190
|
+
O.value && (R.value && O.value.unobserve(R.value), O.value.disconnect());
|
|
191
|
+
});
|
|
192
|
+
function Ee(t) {
|
|
193
|
+
if (!t || !t.parentElement)
|
|
194
|
+
return console.warn("Component or parent element is missing."), { w: 0, h: 0 };
|
|
195
|
+
const a = t.parentElement;
|
|
196
|
+
if (a.offsetWidth > 0 && a.offsetHeight > 0)
|
|
197
|
+
return { w: a.offsetWidth, h: a.offsetHeight };
|
|
198
|
+
const l = window.getComputedStyle(a), i = l.width, g = l.height;
|
|
199
|
+
return i !== "auto" && g !== "auto" && parseFloat(i) > 0 && parseFloat(g) > 0 ? { w: parseFloat(i), h: parseFloat(g) } : { w: 0, h: 0 };
|
|
200
|
+
}
|
|
201
|
+
ne(() => Te.value, async (t) => {
|
|
202
|
+
await de();
|
|
203
|
+
}, { deep: !0 });
|
|
204
|
+
const ot = _(() => Tt(e.value.customPalette)), le = _(() => Te.value.map((t, a) => {
|
|
205
|
+
const l = St(t.color) || ot.value[a] || ge[e.value.theme || "default"][a % ge[e.value.theme || "default"].length] || re[a] || re[a % re.length];
|
|
206
|
+
return {
|
|
207
|
+
...t,
|
|
208
|
+
r: t.value,
|
|
209
|
+
id: qe(),
|
|
210
|
+
color: l
|
|
211
|
+
};
|
|
212
|
+
}).filter((t) => ![null, void 0, 1 / 0, -1 / 0].includes(t.value))), B = y([]), I = y("0 0 100 100"), q = _(() => Math.max(...B.value.map((t) => t.r)));
|
|
213
|
+
function Ne(t, a) {
|
|
214
|
+
return a / q.value * t;
|
|
215
|
+
}
|
|
216
|
+
function nt(t, a) {
|
|
217
|
+
h.value = null, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: a });
|
|
218
|
+
}
|
|
219
|
+
function st(t, a) {
|
|
220
|
+
ee("selectDatapoint", t), e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: a });
|
|
221
|
+
}
|
|
222
|
+
function ut(t, a) {
|
|
223
|
+
rt(t), e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: a });
|
|
224
|
+
}
|
|
225
|
+
const h = y(null);
|
|
226
|
+
function rt(t) {
|
|
227
|
+
e.value.style.chart.circles.zoom.show && (h.value = t);
|
|
228
|
+
}
|
|
229
|
+
const L = _(() => h.value ? h.value.r : 0), he = _(() => A.value ? L.value : h.value ? h.value.r > M.value[3] / 6 * e.value.style.chart.circles.zoom.zoomRatio ? h.value.r : M.value[3] / 6 * e.value.style.chart.circles.zoom.zoomRatio : 0), P = y(0), it = _(() => ({
|
|
230
|
+
pointerEvents: "none",
|
|
231
|
+
opacity: P.value,
|
|
232
|
+
filter: `drop-shadow(0px 0px 6px ${Xe(h.value.color, e.value.style.chart.circles.zoom.shadowForce)})`
|
|
233
|
+
})), X = y(L.value);
|
|
234
|
+
gt(() => {
|
|
235
|
+
X.value = L.value, P.value = 0;
|
|
236
|
+
let t = null;
|
|
237
|
+
function a(l) {
|
|
238
|
+
t || (t = l);
|
|
239
|
+
const i = (l - t) / e.value.style.chart.circles.zoom.animationFrameMs;
|
|
240
|
+
i < 1 ? (X.value = L.value + (he.value - L.value) * i, P.value = 0 + e.value.style.chart.circles.zoom.opacity * i, requestAnimationFrame(a)) : (X.value = he.value, P.value = e.value.style.chart.circles.zoom.opacity);
|
|
241
|
+
}
|
|
242
|
+
requestAnimationFrame(a);
|
|
243
|
+
});
|
|
244
|
+
const Y = _(() => ({
|
|
245
|
+
name: e.value.style.chart.circles.zoom.label.name.fontSize * M.value[3] / 300,
|
|
246
|
+
value: e.value.style.chart.circles.zoom.label.value.fontSize * M.value[3] / 300
|
|
247
|
+
}));
|
|
248
|
+
function fe(t) {
|
|
249
|
+
return Ye(
|
|
250
|
+
e.value.style.chart.circles.labels.value.formatter,
|
|
251
|
+
t.value,
|
|
252
|
+
ke({
|
|
253
|
+
p: e.value.style.chart.circles.labels.value.prefix,
|
|
254
|
+
v: t.value,
|
|
255
|
+
s: e.value.style.chart.circles.labels.value.suffix,
|
|
256
|
+
r: e.value.style.chart.circles.labels.value.rounding
|
|
257
|
+
})
|
|
258
|
+
);
|
|
259
|
+
}
|
|
260
|
+
function ct() {
|
|
261
|
+
return Ye(
|
|
262
|
+
e.value.style.chart.circles.zoom.label.value.formatter,
|
|
263
|
+
h.value.value,
|
|
264
|
+
ke({
|
|
265
|
+
p: e.value.style.chart.circles.zoom.label.value.prefix,
|
|
266
|
+
v: h.value.value,
|
|
267
|
+
s: e.value.style.chart.circles.zoom.label.value.suffix,
|
|
268
|
+
r: e.value.style.chart.circles.zoom.label.value.rounding
|
|
269
|
+
})
|
|
270
|
+
);
|
|
271
|
+
}
|
|
272
|
+
function Re(t) {
|
|
273
|
+
if (!t)
|
|
274
|
+
return 0;
|
|
275
|
+
const a = t.r / fe(t).length * (fe(t).length === 1 ? 1 : 2);
|
|
276
|
+
return Math.min(t.r / 2.5, a);
|
|
277
|
+
}
|
|
278
|
+
const U = y(!1);
|
|
279
|
+
function Be(t) {
|
|
280
|
+
U.value = t, ze.value += 1;
|
|
281
|
+
}
|
|
282
|
+
const A = y(!1);
|
|
283
|
+
function me() {
|
|
284
|
+
A.value = !A.value;
|
|
285
|
+
}
|
|
286
|
+
const ae = _(() => {
|
|
287
|
+
const t = le.value.map((l) => ({
|
|
288
|
+
name: l.name,
|
|
289
|
+
value: l.value,
|
|
290
|
+
color: l.color
|
|
291
|
+
})).toSorted((l, i) => i.value - l.value), a = t.map((l) => l.value);
|
|
292
|
+
return { head: t, body: a };
|
|
293
|
+
});
|
|
294
|
+
function pe(t = null) {
|
|
295
|
+
We(() => {
|
|
296
|
+
const a = ae.value.head.map((g, E) => [[
|
|
297
|
+
g.name
|
|
298
|
+
], [ae.value.body[E]]]), l = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], [e.value.table.columnNames.value]]].concat(a), i = Pt(l);
|
|
299
|
+
t ? t(i) : At({ csvContent: i, title: e.value.style.chart.title.text || "vue-ui-circle-pack" });
|
|
300
|
+
});
|
|
301
|
+
}
|
|
302
|
+
const oe = _(() => {
|
|
303
|
+
const t = [
|
|
304
|
+
e.value.table.columnNames.datapoint,
|
|
305
|
+
e.value.table.columnNames.value
|
|
306
|
+
], a = ae.value.head.map((g, E) => {
|
|
307
|
+
const ye = ke({
|
|
308
|
+
p: e.value.style.chart.circles.labels.value.prefix,
|
|
309
|
+
v: ae.value.body[E],
|
|
310
|
+
s: e.value.style.chart.circles.labels.value.suffix,
|
|
311
|
+
r: e.value.style.chart.circles.labels.value.rounding
|
|
312
|
+
});
|
|
313
|
+
return [
|
|
314
|
+
{
|
|
315
|
+
color: g.color,
|
|
316
|
+
name: g.name
|
|
317
|
+
},
|
|
318
|
+
ye
|
|
319
|
+
];
|
|
320
|
+
}), l = {
|
|
321
|
+
th: {
|
|
322
|
+
backgroundColor: e.value.table.th.backgroundColor,
|
|
323
|
+
color: e.value.table.th.color,
|
|
324
|
+
outline: e.value.table.th.outline
|
|
325
|
+
},
|
|
326
|
+
td: {
|
|
327
|
+
backgroundColor: e.value.table.td.backgroundColor,
|
|
328
|
+
color: e.value.table.td.color,
|
|
329
|
+
outline: e.value.table.td.outline
|
|
330
|
+
},
|
|
331
|
+
breakpoint: e.value.table.responsiveBreakpoint
|
|
332
|
+
};
|
|
333
|
+
return {
|
|
334
|
+
colNames: [
|
|
335
|
+
e.value.table.columnNames.datapoint,
|
|
336
|
+
e.value.table.columnNames.value
|
|
337
|
+
],
|
|
338
|
+
head: t,
|
|
339
|
+
body: a,
|
|
340
|
+
config: l
|
|
341
|
+
};
|
|
342
|
+
});
|
|
343
|
+
function Le() {
|
|
344
|
+
F.value.showTable = !F.value.showTable;
|
|
345
|
+
}
|
|
346
|
+
function vt() {
|
|
347
|
+
return le.value;
|
|
348
|
+
}
|
|
349
|
+
async function dt({ scale: t = 2 } = {}) {
|
|
350
|
+
if (!T.value) return;
|
|
351
|
+
const { width: a, height: l } = T.value.getBoundingClientRect(), i = a / l, { imageUri: g, base64: E } = await Ut({ domElement: T.value, base64: !0, img: !0, scale: t });
|
|
352
|
+
return {
|
|
353
|
+
imageUri: g,
|
|
354
|
+
base64: E,
|
|
355
|
+
title: e.value.style.chart.title.text,
|
|
356
|
+
width: a,
|
|
357
|
+
height: l,
|
|
358
|
+
aspectRatio: i
|
|
359
|
+
};
|
|
360
|
+
}
|
|
361
|
+
const Z = _(() => {
|
|
362
|
+
const t = e.value.table.useDialog && !e.value.table.show, a = F.value.showTable;
|
|
363
|
+
return {
|
|
364
|
+
component: t ? w : v,
|
|
365
|
+
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? `: ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
366
|
+
props: t ? {
|
|
367
|
+
backgroundColor: e.value.table.th.backgroundColor,
|
|
368
|
+
color: e.value.table.th.color,
|
|
369
|
+
headerColor: e.value.table.th.color,
|
|
370
|
+
headerBg: e.value.table.th.backgroundColor,
|
|
371
|
+
isFullscreen: U.value,
|
|
372
|
+
fullscreenParent: T.value,
|
|
373
|
+
forcedWidth: Math.min(500, window.innerWidth * 0.8)
|
|
374
|
+
} : {
|
|
375
|
+
hideDetails: !0,
|
|
376
|
+
config: {
|
|
377
|
+
open: a,
|
|
378
|
+
maxHeight: 1e4,
|
|
379
|
+
body: {
|
|
380
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
381
|
+
color: e.value.style.chart.color
|
|
382
|
+
},
|
|
383
|
+
head: {
|
|
384
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
385
|
+
color: e.value.style.chart.color
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
};
|
|
390
|
+
});
|
|
391
|
+
return ne(() => F.value.showTable, (t) => {
|
|
392
|
+
e.value.table.show || (t && e.value.table.useDialog && G.value ? G.value.open() : "close" in G.value && G.value.close());
|
|
393
|
+
}), c({
|
|
394
|
+
getData: vt,
|
|
395
|
+
getImage: dt,
|
|
396
|
+
generateCsv: pe,
|
|
397
|
+
generatePdf: Ae,
|
|
398
|
+
generateImage: De,
|
|
399
|
+
toggleTable: Le,
|
|
400
|
+
toggleAnnotator: me,
|
|
401
|
+
toggleFullscreen: Be
|
|
402
|
+
}), (t, a) => (m(), b("div", {
|
|
403
|
+
id: `vue-ui-circle-pack_${S.value}`,
|
|
404
|
+
class: Ve(`vue-ui-circle-pack ${U.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${r($e) ? "loading" : ""}`),
|
|
405
|
+
ref_key: "circlePackChart",
|
|
406
|
+
ref: T,
|
|
407
|
+
style: se(`font-family:${e.value.style.fontFamily};text-align:center;background:${e.value.style.chart.backgroundColor}; height: ${W.value.h}px; width:${W.value.w}px`),
|
|
408
|
+
onMouseenter: a[3] || (a[3] = () => r(Fe)(!0)),
|
|
409
|
+
onMouseleave: a[4] || (a[4] = () => r(Fe)(!1))
|
|
410
|
+
}, [
|
|
411
|
+
e.value.userOptions.buttons.annotator ? (m(), V(r(s), {
|
|
412
|
+
key: 0,
|
|
413
|
+
svgRef: r(Se),
|
|
414
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
415
|
+
color: e.value.style.chart.color,
|
|
416
|
+
active: A.value,
|
|
417
|
+
scale: q.value / 100,
|
|
418
|
+
onClose: me
|
|
419
|
+
}, null, 8, ["svgRef", "backgroundColor", "color", "active", "scale"])) : C("", !0),
|
|
420
|
+
k(t.$slots, "userConfig", {}, void 0, !0),
|
|
421
|
+
lt.value ? (m(), b("div", {
|
|
422
|
+
key: 1,
|
|
423
|
+
ref_key: "noTitle",
|
|
424
|
+
ref: xe,
|
|
425
|
+
class: "vue-data-ui-no-title-space",
|
|
426
|
+
style: "height:36px; width: 100%;background:transparent"
|
|
427
|
+
}, null, 512)) : C("", !0),
|
|
428
|
+
e.value.style.chart.title.text ? (m(), b("div", {
|
|
429
|
+
key: 2,
|
|
430
|
+
ref_key: "chartTitle",
|
|
431
|
+
ref: we,
|
|
432
|
+
style: "width:100%;background:transparent;padding-bottom:12px"
|
|
433
|
+
}, [
|
|
434
|
+
(m(), V(Vt, {
|
|
435
|
+
key: `title_${Ce.value}`,
|
|
436
|
+
config: {
|
|
437
|
+
title: {
|
|
438
|
+
cy: "donut-div-title",
|
|
439
|
+
...e.value.style.chart.title
|
|
440
|
+
},
|
|
441
|
+
subtitle: {
|
|
442
|
+
cy: "donut-div-subtitle",
|
|
443
|
+
...e.value.style.chart.title.subtitle
|
|
444
|
+
}
|
|
445
|
+
}
|
|
446
|
+
}, null, 8, ["config"]))
|
|
447
|
+
], 512)) : C("", !0),
|
|
448
|
+
e.value.userOptions.show && j.value && (r(Oe) || r(ce)) ? (m(), V(r(o), {
|
|
449
|
+
ref: "details",
|
|
450
|
+
key: `user_option_${ze.value}`,
|
|
451
|
+
backgroundColor: e.value.style.chart.backgroundColor,
|
|
452
|
+
color: e.value.style.chart.color,
|
|
453
|
+
isPrinting: r(Ie),
|
|
454
|
+
isImaging: r(Pe),
|
|
455
|
+
uid: S.value,
|
|
456
|
+
hasTooltip: !1,
|
|
457
|
+
hasLabel: !1,
|
|
458
|
+
hasPdf: e.value.userOptions.buttons.pdf,
|
|
459
|
+
hasImg: e.value.userOptions.buttons.img,
|
|
460
|
+
hasXls: e.value.userOptions.buttons.csv,
|
|
461
|
+
hasTable: e.value.userOptions.buttons.table,
|
|
462
|
+
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
463
|
+
isFullscreen: U.value,
|
|
464
|
+
chartElement: T.value,
|
|
465
|
+
position: e.value.userOptions.position,
|
|
466
|
+
callbacks: e.value.userOptions.callbacks,
|
|
467
|
+
printScale: e.value.userOptions.print.scale,
|
|
468
|
+
titles: { ...e.value.userOptions.buttonTitles },
|
|
469
|
+
hasAnnotator: e.value.userOptions.buttons.annotator,
|
|
470
|
+
isAnnotation: A.value,
|
|
471
|
+
onToggleFullscreen: Be,
|
|
472
|
+
onGeneratePdf: r(Ae),
|
|
473
|
+
onGenerateCsv: pe,
|
|
474
|
+
onGenerateImage: r(De),
|
|
475
|
+
onToggleTable: Le,
|
|
476
|
+
onToggleAnnotator: me,
|
|
477
|
+
style: se({
|
|
478
|
+
visibility: r(Oe) ? r(ce) ? "visible" : "hidden" : "visible"
|
|
479
|
+
})
|
|
480
|
+
}, He({ _: 2 }, [
|
|
481
|
+
t.$slots.menuIcon ? {
|
|
482
|
+
name: "menuIcon",
|
|
483
|
+
fn: z(({ isOpen: l, color: i }) => [
|
|
484
|
+
k(t.$slots, "menuIcon", J(K({ isOpen: l, color: i })), void 0, !0)
|
|
485
|
+
]),
|
|
486
|
+
key: "0"
|
|
487
|
+
} : void 0,
|
|
488
|
+
t.$slots.optionPdf ? {
|
|
489
|
+
name: "optionPdf",
|
|
490
|
+
fn: z(() => [
|
|
491
|
+
k(t.$slots, "optionPdf", {}, void 0, !0)
|
|
492
|
+
]),
|
|
493
|
+
key: "1"
|
|
494
|
+
} : void 0,
|
|
495
|
+
t.$slots.optionCsv ? {
|
|
496
|
+
name: "optionCsv",
|
|
497
|
+
fn: z(() => [
|
|
498
|
+
k(t.$slots, "optionCsv", {}, void 0, !0)
|
|
499
|
+
]),
|
|
500
|
+
key: "2"
|
|
501
|
+
} : void 0,
|
|
502
|
+
t.$slots.optionImg ? {
|
|
503
|
+
name: "optionImg",
|
|
504
|
+
fn: z(() => [
|
|
505
|
+
k(t.$slots, "optionImg", {}, void 0, !0)
|
|
506
|
+
]),
|
|
507
|
+
key: "3"
|
|
508
|
+
} : void 0,
|
|
509
|
+
t.$slots.optionTable ? {
|
|
510
|
+
name: "optionTable",
|
|
511
|
+
fn: z(() => [
|
|
512
|
+
k(t.$slots, "optionTable", {}, void 0, !0)
|
|
513
|
+
]),
|
|
514
|
+
key: "4"
|
|
515
|
+
} : void 0,
|
|
516
|
+
t.$slots.optionFullscreen ? {
|
|
517
|
+
name: "optionFullscreen",
|
|
518
|
+
fn: z(({ toggleFullscreen: l, isFullscreen: i }) => [
|
|
519
|
+
k(t.$slots, "optionFullscreen", J(K({ toggleFullscreen: l, isFullscreen: i })), void 0, !0)
|
|
520
|
+
]),
|
|
521
|
+
key: "5"
|
|
522
|
+
} : void 0,
|
|
523
|
+
t.$slots.optionAnnotator ? {
|
|
524
|
+
name: "optionAnnotator",
|
|
525
|
+
fn: z(({ toggleAnnotator: l, isAnnotator: i }) => [
|
|
526
|
+
k(t.$slots, "optionAnnotator", J(K({ toggleAnnotator: l, isAnnotator: i })), void 0, !0)
|
|
527
|
+
]),
|
|
528
|
+
key: "6"
|
|
529
|
+
} : void 0
|
|
530
|
+
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "chartElement", "position", "callbacks", "printScale", "titles", "hasAnnotator", "isAnnotation", "onGeneratePdf", "onGenerateImage", "style"])) : C("", !0),
|
|
531
|
+
(m(), b("svg", {
|
|
532
|
+
ref_key: "svgRef",
|
|
533
|
+
ref: Se,
|
|
534
|
+
xmlns: r(Ft),
|
|
535
|
+
viewBox: I.value,
|
|
536
|
+
height: Math.max(10, D.value.h),
|
|
537
|
+
width: Math.max(10, D.value.w),
|
|
538
|
+
class: Ve({ "vue-data-ui-fullscreen--on": U.value, "vue-data-ui-fulscreen--off": !U.value }),
|
|
539
|
+
style: se(`max-width:100%;overflow:visible;background:transparent;color:${e.value.style.chart.color};background:${e.value.style.chart.backgroundColor};`)
|
|
540
|
+
}, [
|
|
541
|
+
je(r(d)),
|
|
542
|
+
t.$slots["chart-background"] ? (m(), b("foreignObject", {
|
|
543
|
+
key: 0,
|
|
544
|
+
x: I.value.x,
|
|
545
|
+
y: I.value.y,
|
|
546
|
+
width: I.value.width,
|
|
547
|
+
height: I.value.height,
|
|
548
|
+
style: {
|
|
549
|
+
pointerEvents: "none"
|
|
550
|
+
}
|
|
551
|
+
}, [
|
|
552
|
+
k(t.$slots, "chart-background", {}, void 0, !0)
|
|
553
|
+
], 8, qt)) : C("", !0),
|
|
554
|
+
(m(!0), b(ue, null, kt(B.value, (l, i) => (m(), b(ue, null, [
|
|
555
|
+
$("defs", null, [
|
|
556
|
+
$("radialGradient", {
|
|
557
|
+
id: l.id,
|
|
558
|
+
fy: "30%"
|
|
559
|
+
}, [
|
|
560
|
+
$("stop", {
|
|
561
|
+
offset: "10%",
|
|
562
|
+
"stop-color": r(Ot)(l.color, e.value.style.chart.circles.gradient.intensity / 100)
|
|
563
|
+
}, null, 8, Yt),
|
|
564
|
+
$("stop", {
|
|
565
|
+
offset: "90%",
|
|
566
|
+
"stop-color": r(Xe)(l.color, 0.1)
|
|
567
|
+
}, null, 8, Zt),
|
|
568
|
+
$("stop", {
|
|
569
|
+
offset: "100%",
|
|
570
|
+
"stop-color": l.color
|
|
571
|
+
}, null, 8, Jt)
|
|
572
|
+
], 8, Xt)
|
|
573
|
+
]),
|
|
574
|
+
t.$slots.pattern ? (m(), b("g", Kt, [
|
|
575
|
+
$("defs", null, [
|
|
576
|
+
k(t.$slots, "pattern", be({ ref_for: !0 }, { ...l, patternId: `pattern_${S.value}_${l.id}` }), void 0, !0)
|
|
577
|
+
])
|
|
578
|
+
])) : C("", !0),
|
|
579
|
+
$("rect", {
|
|
580
|
+
x: l.x - l.r,
|
|
581
|
+
y: l.y - l.r,
|
|
582
|
+
width: l.r * 2,
|
|
583
|
+
height: l.r * 2,
|
|
584
|
+
stroke: e.value.style.chart.circles.stroke,
|
|
585
|
+
"stroke-width": e.value.style.chart.circles.strokeWidth * q.value / 100,
|
|
586
|
+
fill: e.value.style.chart.circles.gradient.show ? `url(#${l.id})` : l.color,
|
|
587
|
+
rx: l.r,
|
|
588
|
+
onMouseenter: (g) => ut(l, i),
|
|
589
|
+
onMouseout: (g) => nt(l, i),
|
|
590
|
+
onClick: (g) => st(l, i)
|
|
591
|
+
}, null, 40, Qt),
|
|
592
|
+
t.$slots.pattern ? (m(), b("rect", {
|
|
593
|
+
key: 1,
|
|
594
|
+
x: l.x - l.r,
|
|
595
|
+
y: l.y - l.r,
|
|
596
|
+
width: l.r * 2,
|
|
597
|
+
height: l.r * 2,
|
|
598
|
+
stroke: e.value.style.chart.circles.stroke,
|
|
599
|
+
"stroke-width": e.value.style.chart.circles.strokeWidth * q.value / 100,
|
|
600
|
+
fill: `url(#pattern_${S.value}_${l.id})`,
|
|
601
|
+
rx: l.r,
|
|
602
|
+
style: {
|
|
603
|
+
pointerEvents: "none"
|
|
604
|
+
}
|
|
605
|
+
}, null, 8, el)) : C("", !0),
|
|
606
|
+
t.$slots["data-label"] ? k(t.$slots, "data-label", be({
|
|
607
|
+
key: 2,
|
|
608
|
+
ref_for: !0
|
|
609
|
+
}, { ...l, createTSpans: r(It), fontSize: { name: l.r / 3 * e.value.style.chart.circles.labels.name.fontSizeRatio, value: Re(l) * e.value.style.chart.circles.labels.value.fontSizeRatio }, color: e.value.style.chart.circles.labels.name.color ? e.value.style.chart.circles.labels.name.color : r(Q)(l.color) }), void 0, !0) : (m(), b(ue, { key: 3 }, [
|
|
610
|
+
e.value.style.chart.circles.labels.name.show && l.name ? (m(), b("text", {
|
|
611
|
+
key: 0,
|
|
612
|
+
style: {
|
|
613
|
+
pointerEvents: "none",
|
|
614
|
+
transition: "opacity 0.2s ease-in-out"
|
|
615
|
+
},
|
|
616
|
+
opacity: h.value && !A.value ? 0.2 : 1,
|
|
617
|
+
x: l.x,
|
|
618
|
+
y: l.y + Ne(l.r, e.value.style.chart.circles.labels.name.offsetY) - l.r / 10,
|
|
619
|
+
"font-size": l.r / 3 * e.value.style.chart.circles.labels.name.fontSizeRatio,
|
|
620
|
+
fill: e.value.style.chart.circles.labels.name.color ? e.value.style.chart.circles.labels.name.color : r(Q)(l.color),
|
|
621
|
+
"font-weight": e.value.style.chart.circles.labels.name.bold ? "bold" : "normal",
|
|
622
|
+
"text-anchor": "middle"
|
|
623
|
+
}, H(l.name), 9, tl)) : C("", !0),
|
|
624
|
+
e.value.style.chart.circles.labels.value.show ? (m(), b("text", {
|
|
625
|
+
key: 1,
|
|
626
|
+
style: {
|
|
627
|
+
pointerEvents: "none",
|
|
628
|
+
transition: "opacity 0.2s ease-in-out"
|
|
629
|
+
},
|
|
630
|
+
opacity: h.value && !A.value ? 0.2 : 1,
|
|
631
|
+
x: l.x,
|
|
632
|
+
y: l.y + Ne(l.r, e.value.style.chart.circles.labels.value.offsetY) + l.r / 2.5,
|
|
633
|
+
"font-size": Re(l) * e.value.style.chart.circles.labels.value.fontSizeRatio,
|
|
634
|
+
fill: e.value.style.chart.circles.labels.value.color ? e.value.style.chart.circles.labels.value.color : r(Q)(l.color),
|
|
635
|
+
"font-weight": e.value.style.chart.circles.labels.value.bold ? "bold" : "normal",
|
|
636
|
+
"text-anchor": "middle"
|
|
637
|
+
}, H(fe(l)), 9, ll)) : C("", !0)
|
|
638
|
+
], 64))
|
|
639
|
+
], 64))), 256)),
|
|
640
|
+
h.value && e.value.style.chart.circles.zoom.show && !A.value ? (m(), b(ue, { key: 1 }, [
|
|
641
|
+
$("circle", {
|
|
642
|
+
style: se(it.value),
|
|
643
|
+
cx: h.value.x,
|
|
644
|
+
cy: h.value.y,
|
|
645
|
+
r: X.value,
|
|
646
|
+
opacity: P.value,
|
|
647
|
+
stroke: e.value.style.chart.circles.stroke,
|
|
648
|
+
"stroke-width": e.value.style.chart.circles.strokeWidth * q.value / 100,
|
|
649
|
+
fill: e.value.style.chart.circles.gradient.show ? `url(#${h.value.id})` : h.value.color
|
|
650
|
+
}, null, 12, al),
|
|
651
|
+
t.$slots["zoom-label"] ? (m(), b("g", ol, [
|
|
652
|
+
k(t.$slots, "zoom-label", J(K({ ...h.value, zoomOpacity: P.value, currentRadius: X.value, fontSize: Y.value })), void 0, !0)
|
|
653
|
+
])) : (m(), b("g", nl, [
|
|
654
|
+
$("text", {
|
|
655
|
+
style: {
|
|
656
|
+
pointerEvents: "none"
|
|
657
|
+
},
|
|
658
|
+
opacity: P.value,
|
|
659
|
+
x: h.value.x,
|
|
660
|
+
y: h.value.y + e.value.style.chart.circles.zoom.label.name.offsetY - Y.value.name / 4,
|
|
661
|
+
"text-anchor": "middle",
|
|
662
|
+
"font-size": Y.value.name,
|
|
663
|
+
fill: e.value.style.chart.circles.zoom.label.name.color ? e.value.style.chart.circles.zoom.label.name.color : r(Q)(h.value.color),
|
|
664
|
+
"font-weight": e.value.style.chart.circles.zoom.label.name.bold ? "bold" : "normal"
|
|
665
|
+
}, H(h.value.name), 9, sl),
|
|
666
|
+
$("text", {
|
|
667
|
+
style: {
|
|
668
|
+
pointerEvents: "none"
|
|
669
|
+
},
|
|
670
|
+
opacity: P.value,
|
|
671
|
+
x: h.value.x,
|
|
672
|
+
y: h.value.y + Y.value.value + e.value.style.chart.circles.zoom.label.value.offsetY,
|
|
673
|
+
"text-anchor": "middle",
|
|
674
|
+
"font-size": Y.value.value,
|
|
675
|
+
fill: e.value.style.chart.circles.zoom.label.value.color ? e.value.style.chart.circles.zoom.label.value.color : r(Q)(h.value.color),
|
|
676
|
+
"font-weight": e.value.style.chart.circles.zoom.label.value.bold ? "bold" : "normal"
|
|
677
|
+
}, H(ct()), 9, ul)
|
|
678
|
+
]))
|
|
679
|
+
], 64)) : C("", !0),
|
|
680
|
+
k(t.$slots, "svg", {
|
|
681
|
+
svg: { ...I.value }
|
|
682
|
+
}, void 0, !0)
|
|
683
|
+
], 14, Wt)),
|
|
684
|
+
t.$slots.watermark ? (m(), b("div", rl, [
|
|
685
|
+
k(t.$slots, "watermark", J(K({ isPrinting: r(Ie) || r(Pe) })), void 0, !0)
|
|
686
|
+
])) : C("", !0),
|
|
687
|
+
t.$slots.source ? (m(), b("div", {
|
|
688
|
+
key: 5,
|
|
689
|
+
ref_key: "source",
|
|
690
|
+
ref: tt,
|
|
691
|
+
dir: "auto"
|
|
692
|
+
}, [
|
|
693
|
+
k(t.$slots, "source", {}, void 0, !0)
|
|
694
|
+
], 512)) : C("", !0),
|
|
695
|
+
j.value ? (m(), V(wt(Z.value.component), be({ key: 6 }, Z.value.props, {
|
|
696
|
+
ref_key: "tableUnit",
|
|
697
|
+
ref: G,
|
|
698
|
+
onClose: a[2] || (a[2] = (l) => F.value.showTable = !1)
|
|
699
|
+
}), He({
|
|
700
|
+
content: z(() => [
|
|
701
|
+
(m(), V(r(n), {
|
|
702
|
+
key: `table_${_e.value}`,
|
|
703
|
+
colNames: oe.value.colNames,
|
|
704
|
+
head: oe.value.head,
|
|
705
|
+
body: oe.value.body,
|
|
706
|
+
config: oe.value.config,
|
|
707
|
+
title: e.value.table.useDialog ? "" : Z.value.title,
|
|
708
|
+
withCloseButton: !e.value.table.useDialog,
|
|
709
|
+
onClose: a[1] || (a[1] = (l) => F.value.showTable = !1)
|
|
710
|
+
}, {
|
|
711
|
+
th: z(({ th: l }) => [
|
|
712
|
+
$("div", {
|
|
713
|
+
innerHTML: l,
|
|
714
|
+
style: { display: "flex", "align-items": "center" }
|
|
715
|
+
}, null, 8, il)
|
|
716
|
+
]),
|
|
717
|
+
td: z(({ td: l }) => [
|
|
718
|
+
Ge(H(l.name || l), 1)
|
|
719
|
+
]),
|
|
720
|
+
_: 1
|
|
721
|
+
}, 8, ["colNames", "head", "body", "config", "title", "withCloseButton"]))
|
|
722
|
+
]),
|
|
723
|
+
_: 2
|
|
724
|
+
}, [
|
|
725
|
+
e.value.table.useDialog ? {
|
|
726
|
+
name: "title",
|
|
727
|
+
fn: z(() => [
|
|
728
|
+
Ge(H(Z.value.title), 1)
|
|
729
|
+
]),
|
|
730
|
+
key: "0"
|
|
731
|
+
} : void 0,
|
|
732
|
+
e.value.table.useDialog ? {
|
|
733
|
+
name: "actions",
|
|
734
|
+
fn: z(() => [
|
|
735
|
+
$("button", {
|
|
736
|
+
tabindex: "0",
|
|
737
|
+
class: "vue-ui-user-options-button",
|
|
738
|
+
onClick: a[0] || (a[0] = (l) => pe(e.value.userOptions.callbacks.csv))
|
|
739
|
+
}, [
|
|
740
|
+
je(r(p), {
|
|
741
|
+
name: "excel",
|
|
742
|
+
stroke: Z.value.props.color
|
|
743
|
+
}, null, 8, ["stroke"])
|
|
744
|
+
])
|
|
745
|
+
]),
|
|
746
|
+
key: "1"
|
|
747
|
+
} : void 0
|
|
748
|
+
]), 1040)) : C("", !0),
|
|
749
|
+
r($e) ? (m(), V(Rt, { key: 7 })) : C("", !0)
|
|
750
|
+
], 46, Gt));
|
|
751
|
+
}
|
|
752
|
+
}, xl = /* @__PURE__ */ Ht(cl, [["__scopeId", "data-v-d0db794a"]]);
|
|
753
|
+
export {
|
|
754
|
+
xl as default
|
|
755
|
+
};
|