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
|
@@ -1,765 +0,0 @@
|
|
|
1
|
-
import { useCssVars as et, defineAsyncComponent as Z, computed as ie, ref as f, toRefs as tt, watch as ue, shallowRef as Ne, onMounted as at, onBeforeUnmount as ot, createElementBlock as X, openBlock as w, unref as i, normalizeStyle as pe, createBlock as Q, createCommentVNode as L, createVNode as xe, createSlots as lt, withCtx as N, renderSlot as A, normalizeProps as ee, guardReactiveProps as te, normalizeClass as _e, createElementVNode as $e, Fragment as nt, renderList as st, toDisplayString as Re, createTextVNode as it, nextTick as Ve } from "vue";
|
|
2
|
-
import { d as ut, t as rt, u as ct } from "./useResponsive-DfdjqQps.js";
|
|
3
|
-
import { u as vt, c as Be, t as dt, an as mt, h as ht, a as ft, p as ge, b as pt, o as Xe, f as De, g as gt, i as yt, X as bt, v as wt, w as Ct, y as kt } from "./index-BHb_mcWF.js";
|
|
4
|
-
import { u as xt, B as $t } from "./useLoading-D7YHNtLX.js";
|
|
5
|
-
import { u as Tt } from "./usePrinter-B7rhbRrT.js";
|
|
6
|
-
import { u as Ee } from "./useNestedProp-aC9S6EFJ.js";
|
|
7
|
-
import { u as St } from "./useUserOptionState-BIvW1Kz7.js";
|
|
8
|
-
import { u as Mt } from "./useChartAccessibility-9icAAmYg.js";
|
|
9
|
-
import Ft from "./img-DsVqerdt.js";
|
|
10
|
-
import Pt from "./Title-BL-IjQmj.js";
|
|
11
|
-
import { u as At } from "./usePanZoom-BVca3eMk.js";
|
|
12
|
-
import { _ as It } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
13
|
-
function Ot(C, g) {
|
|
14
|
-
const { width: r, height: p } = C, m = g.getImageData(0, 0, r, p).data;
|
|
15
|
-
let l = r, o = p, s = 0, k = 0, d = !1;
|
|
16
|
-
for (let h = 0; h < p; h += 1)
|
|
17
|
-
for (let b = 0; b < r; b += 1)
|
|
18
|
-
m[(h * r + b) * 4 + 3] > 1 && (d = !0, b < l && (l = b), b > s && (s = b), h < o && (o = h), h > k && (k = h));
|
|
19
|
-
return d ? [l, o, s, k] : [0, 0, 0, 0];
|
|
20
|
-
}
|
|
21
|
-
function We({
|
|
22
|
-
word: C,
|
|
23
|
-
fontSize: g,
|
|
24
|
-
pad: r,
|
|
25
|
-
canvas: p,
|
|
26
|
-
ctx: c,
|
|
27
|
-
svg: m
|
|
28
|
-
}) {
|
|
29
|
-
c.save(), c.font = `${m.style && m.style.bold ? "bold " : ""}${g}px Arial`;
|
|
30
|
-
const l = c.measureText(C.name), o = Math.ceil(l.width) + 2 + (r ? r * 2 : 0), s = Math.ceil(g) + 2 + (r ? r * 2 : 0);
|
|
31
|
-
p.width = o, p.height = s, c.clearRect(0, 0, o, s), c.font = `${m.style && m.style.bold ? "bold " : ""}${g}px Arial`, c.textAlign = "center", c.textBaseline = "middle", c.fillStyle = "black", c.fillText(C.name, o / 2, s / 2);
|
|
32
|
-
const d = c.getImageData(0, 0, o, s).data, h = [];
|
|
33
|
-
for (let E = 0; E < s; E += 1)
|
|
34
|
-
for (let Y = 0; Y < o; Y += 1)
|
|
35
|
-
d[(E * o + Y) * 4 + 3] > 1 && h.push([Y, E]);
|
|
36
|
-
const [b, U, $, D] = Ot(p, c);
|
|
37
|
-
return c.restore(), { w: o, h: s, wordMask: h, minX: b, minY: U, maxX: $, maxY: D };
|
|
38
|
-
}
|
|
39
|
-
function Le({ mask: C, maskW: g, maskH: r, wx: p, wy: c, wordMask: m }) {
|
|
40
|
-
for (let l = 0; l < m.length; l += 1) {
|
|
41
|
-
const o = p + m[l][0], s = c + m[l][1];
|
|
42
|
-
if (o < 0 || s < 0 || o >= g || s >= r || C[s * g + o]) return !1;
|
|
43
|
-
}
|
|
44
|
-
return !0;
|
|
45
|
-
}
|
|
46
|
-
function Ye({ mask: C, maskW: g, maskH: r, wx: p, wy: c, wordMask: m }) {
|
|
47
|
-
for (let l = 0; l < m.length; l += 1) {
|
|
48
|
-
const o = p + m[l][0], s = c + m[l][1];
|
|
49
|
-
o >= 0 && s >= 0 && o < g && s < r && (C[s * g + o] = 1);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
function zt({ wordMask: C, w: g, h: r, dilation: p }) {
|
|
53
|
-
const c = new Set(C.map(([l, o]) => `${l},${o}`)), m = new Set(c);
|
|
54
|
-
for (let [l, o] of C)
|
|
55
|
-
for (let s = -p; s <= p; s += 1)
|
|
56
|
-
for (let k = -p; k <= p; k += 1) {
|
|
57
|
-
if (s === 0 && k === 0) continue;
|
|
58
|
-
const d = l + s, h = o + k;
|
|
59
|
-
d >= 0 && d < g && h >= 0 && h < r && m.add(`${d},${h}`);
|
|
60
|
-
}
|
|
61
|
-
return Array.from(m).map((l) => l.split(",").map(Number));
|
|
62
|
-
}
|
|
63
|
-
function Nt({
|
|
64
|
-
words: C,
|
|
65
|
-
proximity: g = 0,
|
|
66
|
-
svg: r,
|
|
67
|
-
strictPixelPadding: p
|
|
68
|
-
}) {
|
|
69
|
-
const { width: c, height: m } = r, l = Math.round(c), o = Math.round(m), s = 1, k = r.minFontSize, d = Math.min(r.maxFontSize, 100), h = C.map((T) => T.value), b = Math.min(...h), U = Math.max(...h), $ = new Uint8Array(l * o), D = document.createElement("canvas"), E = D.getContext("2d", { willReadFrequently: !0 });
|
|
70
|
-
D.width = l, D.height = o;
|
|
71
|
-
const Y = 6, re = 2, ae = 2, e = 1, ce = Math.floor(l / 2), J = Math.floor(o / 2), ye = [...C].sort((T, I) => I.value - T.value), G = [];
|
|
72
|
-
for (const T of ye) {
|
|
73
|
-
let I = k;
|
|
74
|
-
U !== b && (I = (T.value - b) / (U - b) * (d - k) + k), I = Math.max(k, Math.min(d, I));
|
|
75
|
-
let W = !1, _ = I;
|
|
76
|
-
for (; !W && _ >= s; ) {
|
|
77
|
-
let { w: O, h: z, wordMask: R, minX: j, minY: oe, maxX: q, maxY: v } = We({
|
|
78
|
-
word: T,
|
|
79
|
-
fontSize: _,
|
|
80
|
-
pad: g,
|
|
81
|
-
canvas: D,
|
|
82
|
-
ctx: E,
|
|
83
|
-
svg: r
|
|
84
|
-
});
|
|
85
|
-
p && (R = zt({ wordMask: R, w: O, h: z, dilation: 1 }));
|
|
86
|
-
let V = 0, S = 0;
|
|
87
|
-
for (; V < Math.max(l, o) && !W && S < 1e4; ) {
|
|
88
|
-
for (let x = 0; x < 360; x += Y) {
|
|
89
|
-
S += 1;
|
|
90
|
-
const M = Math.round(ce + V * Math.cos(x * Math.PI / 180) - O / 2), F = Math.round(J + V * Math.sin(x * Math.PI / 180) - z / 2);
|
|
91
|
-
if (!(M < 0 || F < 0 || M + O > l || F + z > o) && Le({ mask: $, maskW: l, maskH: o, wx: M, wy: F, wordMask: R })) {
|
|
92
|
-
G.push({ ...T, x: M - l / 2, y: F - o / 2, fontSize: _, width: O, height: z, angle: 0, minX: j, minY: oe, maxX: q, maxY: v }), Ye({ mask: $, maskW: l, maskH: o, wx: M, wy: F, wordMask: R }), W = !0;
|
|
93
|
-
break;
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
V += re;
|
|
97
|
-
}
|
|
98
|
-
W || (_ -= 1);
|
|
99
|
-
}
|
|
100
|
-
if (!W && _ < s) {
|
|
101
|
-
_ = s;
|
|
102
|
-
const { w: O, h: z, wordMask: R, minX: j, minY: oe, maxX: q, maxY: v } = We({
|
|
103
|
-
word: T,
|
|
104
|
-
fontSize: _,
|
|
105
|
-
pad: g,
|
|
106
|
-
canvas: D,
|
|
107
|
-
ctx: E,
|
|
108
|
-
svg: r
|
|
109
|
-
});
|
|
110
|
-
let V = 0, S = 0;
|
|
111
|
-
for (; V < Math.max(l, o) && !W && S < 25e3; ) {
|
|
112
|
-
for (let x = 0; x < 360; x += ae) {
|
|
113
|
-
S += 1;
|
|
114
|
-
const M = Math.round(ce + V * Math.cos(x * Math.PI / 180) - O / 2), F = Math.round(J + V * Math.sin(x * Math.PI / 180) - z / 2);
|
|
115
|
-
if (!(M < 0 || F < 0 || M + O > l || F + z > o) && Le({ mask: $, maskW: l, maskH: o, wx: M, wy: F, wordMask: R })) {
|
|
116
|
-
G.push({ ...T, x: M - l / 2, y: F - o / 2, fontSize: _, width: O, height: z, angle: 0, minX: j, minY: oe, maxX: q, maxY: v }), Ye({ mask: $, maskW: l, maskH: o, wx: M, wy: F, wordMask: R }), W = !0;
|
|
117
|
-
break;
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
V += e;
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
return G.sort((T, I) => I.fontSize - T.fontSize);
|
|
125
|
-
}
|
|
126
|
-
const _t = ["id"], Rt = ["xmlns", "viewBox"], Vt = ["width", "height"], Bt = ["transform"], Xt = ["x", "y", "width", "height", "onMouseover", "onMouseleave", "onClick"], Dt = ["fill", "font-weight", "x", "y", "font-size", "transform"], Et = {
|
|
127
|
-
key: 3,
|
|
128
|
-
class: "vue-data-ui-watermark"
|
|
129
|
-
}, Wt = {
|
|
130
|
-
key: 4,
|
|
131
|
-
"data-dom-to-png-ignore": "",
|
|
132
|
-
class: "reset-wrapper"
|
|
133
|
-
}, Lt = ["innerHTML"], Yt = {
|
|
134
|
-
__name: "vue-ui-word-cloud",
|
|
135
|
-
props: {
|
|
136
|
-
config: {
|
|
137
|
-
type: Object,
|
|
138
|
-
default() {
|
|
139
|
-
return {};
|
|
140
|
-
}
|
|
141
|
-
},
|
|
142
|
-
dataset: {
|
|
143
|
-
type: [Array, String],
|
|
144
|
-
default() {
|
|
145
|
-
return [];
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
},
|
|
149
|
-
setup(C, { expose: g }) {
|
|
150
|
-
et((t) => ({
|
|
151
|
-
"1946195c": t.slicerColor
|
|
152
|
-
}));
|
|
153
|
-
const r = Z(() => import("./Tooltip-CCnDaboi.js")), p = Z(() => import("./BaseIcon-B717hnWR.js")), c = Z(() => import("./vue-ui-accordion-DsnF0JuK.js")), m = Z(() => import("./DataTable-Y5T9UxMO.js")), l = Z(() => import("./PenAndPaper-BMHsOtT8.js")), o = Z(() => import("./UserOptions-BWMV0_Ze.js")), s = Z(() => import("./PackageVersion-CE7HSich.js")), { vue_ui_word_cloud: k } = vt(), d = C, h = ie({
|
|
154
|
-
get() {
|
|
155
|
-
return !!d.dataset && d.dataset.length;
|
|
156
|
-
},
|
|
157
|
-
set(t) {
|
|
158
|
-
return t;
|
|
159
|
-
}
|
|
160
|
-
}), b = f(Be()), U = f(0), $ = f(null), D = f(null), E = f(null), Y = f(0), re = f(0), ae = f(!1), e = f(z()), { loading: ce, FINAL_DATASET: J, manualLoading: ye } = xt({
|
|
161
|
-
...tt(d),
|
|
162
|
-
FINAL_CONFIG: e,
|
|
163
|
-
prepareConfig: z,
|
|
164
|
-
skeletonDataset: [
|
|
165
|
-
{ name: "Lorem", value: 6 },
|
|
166
|
-
{ name: "ipsum", value: 3 },
|
|
167
|
-
{ name: "dolor", value: 1 },
|
|
168
|
-
{ name: "sit", value: 3 },
|
|
169
|
-
{ name: "amet", value: 3 },
|
|
170
|
-
{ name: "consectetur", value: 2 },
|
|
171
|
-
{ name: "adipiscing", value: 1 },
|
|
172
|
-
{ name: "elit", value: 2 },
|
|
173
|
-
{ name: "Vivamus", value: 2 },
|
|
174
|
-
{ name: "pulvinar", value: 1 },
|
|
175
|
-
{ name: "pretium", value: 1 },
|
|
176
|
-
{ name: "venenatis", value: 2 },
|
|
177
|
-
{ name: "Donec", value: 1 },
|
|
178
|
-
{ name: "imperdiet", value: 3 },
|
|
179
|
-
{ name: "id", value: 1 },
|
|
180
|
-
{ name: "porttitor", value: 2 },
|
|
181
|
-
{ name: "tristique", value: 1 },
|
|
182
|
-
{ name: "Aenean", value: 2 },
|
|
183
|
-
{ name: "ac", value: 5 },
|
|
184
|
-
{ name: "commodo", value: 2 },
|
|
185
|
-
{ name: "justo", value: 2 },
|
|
186
|
-
{ name: "Vestibulum", value: 2 },
|
|
187
|
-
{ name: "placerat", value: 1 },
|
|
188
|
-
{ name: "molestie", value: 1 },
|
|
189
|
-
{ name: "nisl", value: 1 },
|
|
190
|
-
{ name: "lacinia", value: 2 },
|
|
191
|
-
{ name: "nulla", value: 1 },
|
|
192
|
-
{ name: "posuere", value: 2 },
|
|
193
|
-
{ name: "quis", value: 3 },
|
|
194
|
-
{ name: "ullamcorper", value: 1 },
|
|
195
|
-
{ name: "eu", value: 1 },
|
|
196
|
-
{ name: "ex", value: 1 },
|
|
197
|
-
{ name: "vitae", value: 3 },
|
|
198
|
-
{ name: "facilisis", value: 1 },
|
|
199
|
-
{ name: "Aliquam", value: 1 },
|
|
200
|
-
{ name: "erat", value: 1 },
|
|
201
|
-
{ name: "volutpat", value: 1 },
|
|
202
|
-
{ name: "Proin", value: 1 },
|
|
203
|
-
{ name: "nunc", value: 1 },
|
|
204
|
-
{ name: "felis", value: 1 },
|
|
205
|
-
{ name: "gravida", value: 3 },
|
|
206
|
-
{ name: "sed", value: 1 },
|
|
207
|
-
{ name: "orci", value: 1 },
|
|
208
|
-
{ name: "Interdum", value: 1 },
|
|
209
|
-
{ name: "et", value: 1 },
|
|
210
|
-
{ name: "malesuada", value: 1 },
|
|
211
|
-
{ name: "fames", value: 1 },
|
|
212
|
-
{ name: "ante", value: 1 }
|
|
213
|
-
],
|
|
214
|
-
skeletonConfig: dt({
|
|
215
|
-
defaultConfig: e.value,
|
|
216
|
-
userConfig: {
|
|
217
|
-
userOptions: { show: !1 },
|
|
218
|
-
table: { show: !1 },
|
|
219
|
-
useCssAnimation: !1,
|
|
220
|
-
animationDelayMs: 0,
|
|
221
|
-
nodeCategories: {},
|
|
222
|
-
nodeCategoryColors: {},
|
|
223
|
-
style: {
|
|
224
|
-
chart: {
|
|
225
|
-
backgroundColor: "#99999930",
|
|
226
|
-
words: {
|
|
227
|
-
color: "#6A6A6A",
|
|
228
|
-
usePalette: !1
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
})
|
|
234
|
-
}), G = f(T());
|
|
235
|
-
function T() {
|
|
236
|
-
return typeof J.value == "string" ? mt(J.value) : J.value.map((t, n) => ({
|
|
237
|
-
...t,
|
|
238
|
-
value: ht(t.value)
|
|
239
|
-
}));
|
|
240
|
-
}
|
|
241
|
-
ue(() => d.dataset, () => {
|
|
242
|
-
G.value = T(), be(), j();
|
|
243
|
-
});
|
|
244
|
-
const { userOptionsVisible: I, setUserOptionsVisibility: W, keepUserOptionState: _ } = St({ config: e.value }), { svgRef: O } = Mt({ config: e.value.style.chart.title });
|
|
245
|
-
function z() {
|
|
246
|
-
const t = Ee({
|
|
247
|
-
userConfig: d.config,
|
|
248
|
-
defaultConfig: k
|
|
249
|
-
});
|
|
250
|
-
return t.theme ? {
|
|
251
|
-
...Ee({
|
|
252
|
-
userConfig: pt.vue_ui_word_cloud[t.theme] || d.config,
|
|
253
|
-
defaultConfig: t
|
|
254
|
-
}),
|
|
255
|
-
customPalette: ft[t.theme] || ge
|
|
256
|
-
} : t;
|
|
257
|
-
}
|
|
258
|
-
const R = f({ x: 0, y: 0 });
|
|
259
|
-
function j() {
|
|
260
|
-
const t = {
|
|
261
|
-
x: 0,
|
|
262
|
-
y: 0,
|
|
263
|
-
width: Math.max(10, v.value.width),
|
|
264
|
-
height: Math.max(10, v.value.height)
|
|
265
|
-
};
|
|
266
|
-
He(t), R.value = {
|
|
267
|
-
x: t.x + t.width / 2,
|
|
268
|
-
y: t.y + t.height / 2
|
|
269
|
-
}, fe();
|
|
270
|
-
}
|
|
271
|
-
const oe = ut(() => {
|
|
272
|
-
be();
|
|
273
|
-
}, 10), q = f(!1);
|
|
274
|
-
ue(() => q.value, (t) => {
|
|
275
|
-
t === !1 && (oe(), j());
|
|
276
|
-
}), ue(() => d.config, (t) => {
|
|
277
|
-
e.value = z(), I.value = !e.value.userOptions.showOnChartHover, F(), Y.value += 1, re.value += 1, P.value.showTable = e.value.table.show, P.value.showTooltip = e.value.style.chart.tooltip.show;
|
|
278
|
-
}, { deep: !0 });
|
|
279
|
-
const v = f({
|
|
280
|
-
width: e.value.style.chart.width,
|
|
281
|
-
height: e.value.style.chart.height,
|
|
282
|
-
maxFontSize: e.value.style.chart.words.maxFontSize,
|
|
283
|
-
minFontSize: e.value.style.chart.words.minFontSize,
|
|
284
|
-
bold: e.value.style.chart.words.bold
|
|
285
|
-
}), V = rt(() => {
|
|
286
|
-
q.value = !0;
|
|
287
|
-
const { width: t, height: n } = ct({
|
|
288
|
-
chart: $.value,
|
|
289
|
-
title: e.value.style.chart.title.text ? D.value : null,
|
|
290
|
-
source: E.value
|
|
291
|
-
});
|
|
292
|
-
requestAnimationFrame(async () => {
|
|
293
|
-
v.value.width = Math.max(10, t), v.value.height = Math.max(10, n - 12), await Ve(), q.value = !1;
|
|
294
|
-
});
|
|
295
|
-
}), S = Ne(null), x = Ne(null);
|
|
296
|
-
at(F);
|
|
297
|
-
const M = ie(() => !!e.value.debug);
|
|
298
|
-
function F() {
|
|
299
|
-
Xe(d.dataset) ? De({
|
|
300
|
-
componentName: "VueUiWordCloud",
|
|
301
|
-
type: "dataset",
|
|
302
|
-
debug: M.value
|
|
303
|
-
}) : G.value.forEach((t, n) => {
|
|
304
|
-
gt({
|
|
305
|
-
datasetObject: t,
|
|
306
|
-
requiredAttributes: ["name", "value"]
|
|
307
|
-
}).forEach((a) => {
|
|
308
|
-
h.value = !1, De({
|
|
309
|
-
componentName: "VueUiWordCloud",
|
|
310
|
-
type: "datasetSerieAttribute",
|
|
311
|
-
property: a,
|
|
312
|
-
index: n,
|
|
313
|
-
debug: M.value
|
|
314
|
-
});
|
|
315
|
-
});
|
|
316
|
-
}), Xe(d.dataset) || (ye.value = e.value.loading), e.value.responsive && (S.value && (x.value && S.value.unobserve(x.value), S.value.disconnect()), S.value = new ResizeObserver(V), x.value = $.value.parentNode, S.value.observe(x.value)), j();
|
|
317
|
-
}
|
|
318
|
-
ot(() => {
|
|
319
|
-
S.value && (x.value && S.value.unobserve(x.value), S.value.disconnect());
|
|
320
|
-
});
|
|
321
|
-
const { isPrinting: Te, isImaging: Se, generatePdf: Me, generateImage: Fe } = Tt({
|
|
322
|
-
elementId: `wordCloud_${b.value}`,
|
|
323
|
-
fileName: e.value.style.chart.title.text || "vue-ui-word-cloud",
|
|
324
|
-
options: e.value.userOptions.print
|
|
325
|
-
}), P = f({
|
|
326
|
-
showTable: e.value.table.show,
|
|
327
|
-
showTooltip: e.value.style.chart.tooltip.show
|
|
328
|
-
});
|
|
329
|
-
ue(e, () => {
|
|
330
|
-
P.value = {
|
|
331
|
-
showTable: e.value.table.show,
|
|
332
|
-
showTooltip: e.value.style.chart.tooltip.show
|
|
333
|
-
};
|
|
334
|
-
}, { immediate: !0 });
|
|
335
|
-
function Ue(t, n, a = "Arial") {
|
|
336
|
-
const y = document.createElement("canvas").getContext("2d");
|
|
337
|
-
return y.font = `${n}px ${e.value.style.chart.words.bold ? "bold" : "normal"} ${a}`, {
|
|
338
|
-
width: y.measureText(t).width + e.value.style.chart.words.proximity,
|
|
339
|
-
height: n
|
|
340
|
-
};
|
|
341
|
-
}
|
|
342
|
-
const le = f([]);
|
|
343
|
-
ue(() => d.dataset, be, { immediate: !0 });
|
|
344
|
-
function be() {
|
|
345
|
-
const t = [...G.value].map((y) => y.value), n = Math.max(...t), a = Math.min(...t), u = [...G.value].map((y, B) => {
|
|
346
|
-
let H = (y.value - a) / (n - a) * (v.value.maxFontSize - v.value.minFontSize) + v.value.minFontSize;
|
|
347
|
-
H = isNaN(H) ? v.value.minFontSize : H;
|
|
348
|
-
const ze = Ue(y.name, H);
|
|
349
|
-
return {
|
|
350
|
-
...y,
|
|
351
|
-
id: Be(),
|
|
352
|
-
fontSize: H,
|
|
353
|
-
width: ze.width,
|
|
354
|
-
height: ze.height,
|
|
355
|
-
color: e.value.style.chart.words.usePalette ? e.value.customPalette[B] || e.value.customPalette[B % e.value.customPalette.length] || ge[B] || ge[B % ge.length] : e.value.style.chart.words.color
|
|
356
|
-
};
|
|
357
|
-
});
|
|
358
|
-
le.value = Nt({
|
|
359
|
-
words: u,
|
|
360
|
-
svg: v.value,
|
|
361
|
-
proximity: e.value.style.chart.words.proximity,
|
|
362
|
-
strictPixelPadding: e.value.strictPixelPadding
|
|
363
|
-
});
|
|
364
|
-
}
|
|
365
|
-
const ve = ie(() => {
|
|
366
|
-
const t = le.value.map((a) => ({
|
|
367
|
-
name: a.name,
|
|
368
|
-
color: a.color
|
|
369
|
-
})), n = le.value.map((a) => a.value);
|
|
370
|
-
return { head: t, body: n };
|
|
371
|
-
});
|
|
372
|
-
function Pe(t = null) {
|
|
373
|
-
Ve(() => {
|
|
374
|
-
const n = ve.value.head.map((y, B) => [[
|
|
375
|
-
y.name
|
|
376
|
-
], [ve.value.body[B]]]), a = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], [e.value.table.columnNames.value]]].concat(n), u = wt(a);
|
|
377
|
-
t ? t(u) : Ct({ csvContent: u, title: e.value.style.chart.title.text || "vue-ui-word-cloud" });
|
|
378
|
-
});
|
|
379
|
-
}
|
|
380
|
-
const de = ie(() => {
|
|
381
|
-
const t = [
|
|
382
|
-
e.value.table.columnNames.series,
|
|
383
|
-
e.value.table.columnNames.value
|
|
384
|
-
], n = ve.value.head.map((y, B) => {
|
|
385
|
-
const H = yt({ p: e.value.table.td.prefix, v: ve.value.body[B], s: e.value.table.td.suffix, r: e.value.table.td.roundingValue });
|
|
386
|
-
return [
|
|
387
|
-
{
|
|
388
|
-
color: y.color,
|
|
389
|
-
name: y.name
|
|
390
|
-
},
|
|
391
|
-
H
|
|
392
|
-
];
|
|
393
|
-
}), a = {
|
|
394
|
-
th: {
|
|
395
|
-
backgroundColor: e.value.table.th.backgroundColor,
|
|
396
|
-
color: e.value.table.th.color,
|
|
397
|
-
outline: e.value.table.th.outline
|
|
398
|
-
},
|
|
399
|
-
td: {
|
|
400
|
-
backgroundColor: e.value.table.td.backgroundColor,
|
|
401
|
-
color: e.value.table.td.color,
|
|
402
|
-
outline: e.value.table.td.outline
|
|
403
|
-
},
|
|
404
|
-
breakpoint: e.value.table.responsiveBreakpoint
|
|
405
|
-
};
|
|
406
|
-
return {
|
|
407
|
-
colNames: [
|
|
408
|
-
e.value.table.columnNames.series,
|
|
409
|
-
e.value.table.columnNames.value
|
|
410
|
-
],
|
|
411
|
-
head: t,
|
|
412
|
-
body: n,
|
|
413
|
-
config: a
|
|
414
|
-
};
|
|
415
|
-
}), me = f(!1);
|
|
416
|
-
function Ae(t) {
|
|
417
|
-
me.value = t, U.value += 1;
|
|
418
|
-
}
|
|
419
|
-
function Ge() {
|
|
420
|
-
return le.value;
|
|
421
|
-
}
|
|
422
|
-
function Ie() {
|
|
423
|
-
P.value.showTable = !P.value.showTable;
|
|
424
|
-
}
|
|
425
|
-
function Oe() {
|
|
426
|
-
P.value.showTooltip = !P.value.showTooltip;
|
|
427
|
-
}
|
|
428
|
-
const ne = f(!1);
|
|
429
|
-
function we() {
|
|
430
|
-
ne.value = !ne.value;
|
|
431
|
-
}
|
|
432
|
-
const je = ie(() => !ne.value && e.value.style.chart.zoom.show), { viewBox: he, resetZoom: fe, isZoom: qe, setInitialViewBox: He } = At(O, {
|
|
433
|
-
x: 0,
|
|
434
|
-
y: 0,
|
|
435
|
-
width: v.value.width <= 0 ? 10 : v.value.width,
|
|
436
|
-
height: v.value.height <= 0 ? 10 : v.value.height
|
|
437
|
-
}, 1, je);
|
|
438
|
-
async function Ze({ scale: t = 2 } = {}) {
|
|
439
|
-
if (!$.value) return;
|
|
440
|
-
const { width: n, height: a } = $.value.getBoundingClientRect(), u = n / a, { imageUri: y, base64: B } = await Ft({ domElement: $.value, base64: !0, img: !0, scale: t });
|
|
441
|
-
return {
|
|
442
|
-
imageUri: y,
|
|
443
|
-
base64: B,
|
|
444
|
-
title: e.value.style.chart.title.text,
|
|
445
|
-
width: n,
|
|
446
|
-
height: a,
|
|
447
|
-
aspectRatio: u
|
|
448
|
-
};
|
|
449
|
-
}
|
|
450
|
-
g({
|
|
451
|
-
getData: Ge,
|
|
452
|
-
getImage: Ze,
|
|
453
|
-
generateCsv: Pe,
|
|
454
|
-
generatePdf: Me,
|
|
455
|
-
generateImage: Fe,
|
|
456
|
-
resetZoom: fe,
|
|
457
|
-
toggleTable: Ie,
|
|
458
|
-
toggleTooltip: Oe,
|
|
459
|
-
toggleAnnotator: we,
|
|
460
|
-
toggleFullscreen: Ae
|
|
461
|
-
});
|
|
462
|
-
const K = f(null), se = f(!1), Ce = f(""), ke = f(null);
|
|
463
|
-
function Je(t, n) {
|
|
464
|
-
K.value = null, ae.value = !1, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: n });
|
|
465
|
-
}
|
|
466
|
-
function Ke(t, n) {
|
|
467
|
-
e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: n });
|
|
468
|
-
}
|
|
469
|
-
function Qe(t, n) {
|
|
470
|
-
if (e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: n }), !P.value.showTooltip) return;
|
|
471
|
-
K.value = t.id, ke.value = { datapoint: t, config: e.value };
|
|
472
|
-
const a = e.value.style.chart.tooltip.customFormat;
|
|
473
|
-
if (se.value = !1, kt(a))
|
|
474
|
-
try {
|
|
475
|
-
const u = a({
|
|
476
|
-
datapoint: t,
|
|
477
|
-
config: e.value
|
|
478
|
-
});
|
|
479
|
-
typeof u == "string" && (Ce.value = u, se.value = !0);
|
|
480
|
-
} catch {
|
|
481
|
-
console.warn("Custom format cannot be applied."), se.value = !1;
|
|
482
|
-
}
|
|
483
|
-
if (!se.value) {
|
|
484
|
-
let u = `<svg viewBox="0 0 10 10" height="${e.value.style.chart.tooltip.fontSize}"><circle cx="5" cy="5" r="5" fill="${t.color}"/></svg><span>${t.name}:</span><b>${(t.value || 0).toFixed(e.value.style.chart.tooltip.roundingValue)}</b>`;
|
|
485
|
-
Ce.value = `<div dir="auto" style="display:flex; gap:4px; align-items:center; jsutify-content:center;">${u}</div>`;
|
|
486
|
-
}
|
|
487
|
-
ae.value = !0;
|
|
488
|
-
}
|
|
489
|
-
return (t, n) => (w(), X("div", {
|
|
490
|
-
class: "vue-ui-word-cloud",
|
|
491
|
-
ref_key: "wordCloudChart",
|
|
492
|
-
ref: $,
|
|
493
|
-
id: `wordCloud_${b.value}`,
|
|
494
|
-
style: pe(`width: 100%; font-family:${e.value.style.fontFamily};background:${e.value.style.chart.backgroundColor};${e.value.responsive ? "height:100%" : ""}`),
|
|
495
|
-
onMouseenter: n[2] || (n[2] = () => i(W)(!0)),
|
|
496
|
-
onMouseleave: n[3] || (n[3] = () => i(W)(!1))
|
|
497
|
-
}, [
|
|
498
|
-
e.value.userOptions.buttons.annotator ? (w(), Q(i(l), {
|
|
499
|
-
key: 0,
|
|
500
|
-
svgRef: i(O),
|
|
501
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
502
|
-
color: e.value.style.chart.color,
|
|
503
|
-
active: ne.value,
|
|
504
|
-
onClose: we
|
|
505
|
-
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : L("", !0),
|
|
506
|
-
e.value.style.chart.title.text ? (w(), X("div", {
|
|
507
|
-
key: 1,
|
|
508
|
-
ref_key: "chartTitle",
|
|
509
|
-
ref: D,
|
|
510
|
-
style: "width:100%;background:transparent;padding-bottom:24px"
|
|
511
|
-
}, [
|
|
512
|
-
(w(), Q(Pt, {
|
|
513
|
-
key: `title_${Y.value}`,
|
|
514
|
-
config: {
|
|
515
|
-
title: {
|
|
516
|
-
...e.value.style.chart.title
|
|
517
|
-
},
|
|
518
|
-
subtitle: {
|
|
519
|
-
...e.value.style.chart.title.subtitle
|
|
520
|
-
}
|
|
521
|
-
}
|
|
522
|
-
}, null, 8, ["config"]))
|
|
523
|
-
], 512)) : L("", !0),
|
|
524
|
-
e.value.userOptions.show && h.value && (i(_) || i(I)) ? (w(), Q(i(o), {
|
|
525
|
-
ref: "details",
|
|
526
|
-
key: `user_option_${U.value}`,
|
|
527
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
528
|
-
color: e.value.style.chart.color,
|
|
529
|
-
isPrinting: i(Te),
|
|
530
|
-
isImaging: i(Se),
|
|
531
|
-
uid: b.value,
|
|
532
|
-
hasPdf: e.value.userOptions.buttons.pdf,
|
|
533
|
-
hasXls: e.value.userOptions.buttons.csv,
|
|
534
|
-
hasImg: e.value.userOptions.buttons.img,
|
|
535
|
-
hasTable: e.value.userOptions.buttons.table,
|
|
536
|
-
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
537
|
-
isFullscreen: me.value,
|
|
538
|
-
titles: { ...e.value.userOptions.buttonTitles },
|
|
539
|
-
chartElement: $.value,
|
|
540
|
-
position: e.value.userOptions.position,
|
|
541
|
-
hasTooltip: e.value.style.chart.tooltip.show && e.value.userOptions.buttons.tooltip,
|
|
542
|
-
isTooltip: P.value.showTooltip,
|
|
543
|
-
hasAnnotator: e.value.userOptions.buttons.annotator,
|
|
544
|
-
isAnnotation: ne.value,
|
|
545
|
-
callbacks: e.value.userOptions.callbacks,
|
|
546
|
-
printScale: e.value.userOptions.print.scale,
|
|
547
|
-
onToggleFullscreen: Ae,
|
|
548
|
-
onGeneratePdf: i(Me),
|
|
549
|
-
onGenerateCsv: Pe,
|
|
550
|
-
onGenerateImage: i(Fe),
|
|
551
|
-
onToggleTable: Ie,
|
|
552
|
-
onToggleTooltip: Oe,
|
|
553
|
-
onToggleAnnotator: we,
|
|
554
|
-
style: pe({
|
|
555
|
-
visibility: i(_) ? i(I) ? "visible" : "hidden" : "visible"
|
|
556
|
-
})
|
|
557
|
-
}, lt({ _: 2 }, [
|
|
558
|
-
t.$slots.menuIcon ? {
|
|
559
|
-
name: "menuIcon",
|
|
560
|
-
fn: N(({ isOpen: a, color: u }) => [
|
|
561
|
-
A(t.$slots, "menuIcon", ee(te({ isOpen: a, color: u })), void 0, !0)
|
|
562
|
-
]),
|
|
563
|
-
key: "0"
|
|
564
|
-
} : void 0,
|
|
565
|
-
t.$slots.optionPdf ? {
|
|
566
|
-
name: "optionPdf",
|
|
567
|
-
fn: N(() => [
|
|
568
|
-
A(t.$slots, "optionPdf", {}, void 0, !0)
|
|
569
|
-
]),
|
|
570
|
-
key: "1"
|
|
571
|
-
} : void 0,
|
|
572
|
-
t.$slots.optionCsv ? {
|
|
573
|
-
name: "optionCsv",
|
|
574
|
-
fn: N(() => [
|
|
575
|
-
A(t.$slots, "optionCsv", {}, void 0, !0)
|
|
576
|
-
]),
|
|
577
|
-
key: "2"
|
|
578
|
-
} : void 0,
|
|
579
|
-
t.$slots.optionImg ? {
|
|
580
|
-
name: "optionImg",
|
|
581
|
-
fn: N(() => [
|
|
582
|
-
A(t.$slots, "optionImg", {}, void 0, !0)
|
|
583
|
-
]),
|
|
584
|
-
key: "3"
|
|
585
|
-
} : void 0,
|
|
586
|
-
t.$slots.optionTable ? {
|
|
587
|
-
name: "optionTable",
|
|
588
|
-
fn: N(() => [
|
|
589
|
-
A(t.$slots, "optionTable", {}, void 0, !0)
|
|
590
|
-
]),
|
|
591
|
-
key: "4"
|
|
592
|
-
} : void 0,
|
|
593
|
-
t.$slots.optionFullscreen ? {
|
|
594
|
-
name: "optionFullscreen",
|
|
595
|
-
fn: N(({ toggleFullscreen: a, isFullscreen: u }) => [
|
|
596
|
-
A(t.$slots, "optionFullscreen", ee(te({ toggleFullscreen: a, isFullscreen: u })), void 0, !0)
|
|
597
|
-
]),
|
|
598
|
-
key: "5"
|
|
599
|
-
} : void 0,
|
|
600
|
-
t.$slots.optionAnnotator ? {
|
|
601
|
-
name: "optionAnnotator",
|
|
602
|
-
fn: N(({ toggleAnnotator: a, isAnnotator: u }) => [
|
|
603
|
-
A(t.$slots, "optionAnnotator", ee(te({ toggleAnnotator: a, isAnnotator: u })), void 0, !0)
|
|
604
|
-
]),
|
|
605
|
-
key: "6"
|
|
606
|
-
} : void 0
|
|
607
|
-
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasTable", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "hasTooltip", "isTooltip", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : L("", !0),
|
|
608
|
-
(w(), X("svg", {
|
|
609
|
-
ref_key: "svgRef",
|
|
610
|
-
ref: O,
|
|
611
|
-
class: _e({ "vue-data-ui-fullscreen--on": me.value, "vue-data-ui-fulscreen--off": !me.value }),
|
|
612
|
-
xmlns: i(bt),
|
|
613
|
-
viewBox: `${i(he).x} ${i(he).y} ${i(he).width} ${i(he).height}`,
|
|
614
|
-
style: "overflow:hidden;background:transparent;"
|
|
615
|
-
}, [
|
|
616
|
-
xe(i(s)),
|
|
617
|
-
t.$slots["chart-background"] ? (w(), X("foreignObject", {
|
|
618
|
-
key: 0,
|
|
619
|
-
x: 0,
|
|
620
|
-
y: 0,
|
|
621
|
-
width: v.value.width <= 0 ? 10 : v.value.width,
|
|
622
|
-
height: v.value.height <= 0 ? 10 : v.value.height,
|
|
623
|
-
style: {
|
|
624
|
-
pointerEvents: "none"
|
|
625
|
-
}
|
|
626
|
-
}, [
|
|
627
|
-
A(t.$slots, "chart-background", {}, void 0, !0)
|
|
628
|
-
], 8, Vt)) : L("", !0),
|
|
629
|
-
$e("g", {
|
|
630
|
-
transform: `translate(${R.value.x}, ${R.value.y})`
|
|
631
|
-
}, [
|
|
632
|
-
(w(!0), X(nt, null, st(le.value, (a, u) => (w(), X("g", null, [
|
|
633
|
-
a.minX !== void 0 ? (w(), X("rect", {
|
|
634
|
-
key: 0,
|
|
635
|
-
x: a.x + a.minX,
|
|
636
|
-
y: a.y + a.minY * 1.25,
|
|
637
|
-
width: a.maxX - a.minX,
|
|
638
|
-
height: a.maxY - a.minY,
|
|
639
|
-
fill: "transparent",
|
|
640
|
-
"pointer-events": "visiblePainted",
|
|
641
|
-
onMouseover: (y) => Qe(a, u),
|
|
642
|
-
onMouseleave: (y) => Je(a, u),
|
|
643
|
-
onClick: (y) => Ke(a, u)
|
|
644
|
-
}, null, 40, Xt)) : L("", !0),
|
|
645
|
-
(w(), X("text", {
|
|
646
|
-
fill: a.color,
|
|
647
|
-
"font-weight": e.value.style.chart.words.bold ? "bold" : "normal",
|
|
648
|
-
key: u,
|
|
649
|
-
x: a.x,
|
|
650
|
-
y: a.y,
|
|
651
|
-
"font-size": a.fontSize,
|
|
652
|
-
transform: `translate(${a.width / 2}, ${a.height / 2})`,
|
|
653
|
-
class: _e({ animated: e.value.useCssAnimation, "word-selected": K.value && K.value === a.id && P.value.showTooltip, "word-not-selected": K.value && K.value !== a.id && P.value.showTooltip }),
|
|
654
|
-
"text-anchor": "middle",
|
|
655
|
-
"dominant-baseline": "central",
|
|
656
|
-
style: pe(`animation-delay:${u * e.value.animationDelayMs}ms !important; pointer-events:none;`)
|
|
657
|
-
}, Re(a.name), 15, Dt))
|
|
658
|
-
]))), 256))
|
|
659
|
-
], 8, Bt),
|
|
660
|
-
A(t.$slots, "svg", {
|
|
661
|
-
svg: { height: v.value.height, width: v.value.width }
|
|
662
|
-
}, void 0, !0)
|
|
663
|
-
], 10, Rt)),
|
|
664
|
-
t.$slots.watermark ? (w(), X("div", Et, [
|
|
665
|
-
A(t.$slots, "watermark", ee(te({ isPrinting: i(Te) || i(Se) })), void 0, !0)
|
|
666
|
-
])) : L("", !0),
|
|
667
|
-
i(qe) ? (w(), X("div", Wt, [
|
|
668
|
-
A(t.$slots, "reset-action", { reset: i(fe) }, () => [
|
|
669
|
-
$e("button", {
|
|
670
|
-
"data-cy-reset": "",
|
|
671
|
-
tabindex: "0",
|
|
672
|
-
role: "button",
|
|
673
|
-
class: "vue-data-ui-refresh-button",
|
|
674
|
-
style: pe({
|
|
675
|
-
background: e.value.style.chart.backgroundColor
|
|
676
|
-
}),
|
|
677
|
-
onClick: n[0] || (n[0] = (a) => i(fe)(!0))
|
|
678
|
-
}, [
|
|
679
|
-
xe(i(p), {
|
|
680
|
-
name: "refresh",
|
|
681
|
-
stroke: e.value.style.chart.color
|
|
682
|
-
}, null, 8, ["stroke"])
|
|
683
|
-
], 4)
|
|
684
|
-
], !0)
|
|
685
|
-
])) : L("", !0),
|
|
686
|
-
xe(i(r), {
|
|
687
|
-
show: P.value.showTooltip && ae.value,
|
|
688
|
-
backgroundColor: e.value.style.chart.tooltip.backgroundColor,
|
|
689
|
-
color: e.value.style.chart.tooltip.color,
|
|
690
|
-
fontSize: e.value.style.chart.tooltip.fontSize,
|
|
691
|
-
borderRadius: e.value.style.chart.tooltip.borderRadius,
|
|
692
|
-
borderColor: e.value.style.chart.tooltip.borderColor,
|
|
693
|
-
borderWidth: e.value.style.chart.tooltip.borderWidth,
|
|
694
|
-
backgroundOpacity: e.value.style.chart.tooltip.backgroundOpacity,
|
|
695
|
-
position: e.value.style.chart.tooltip.position,
|
|
696
|
-
offsetY: e.value.style.chart.tooltip.offsetY,
|
|
697
|
-
parent: $.value,
|
|
698
|
-
content: Ce.value,
|
|
699
|
-
isCustom: se.value,
|
|
700
|
-
smooth: e.value.style.chart.tooltip.smooth,
|
|
701
|
-
backdropFilter: e.value.style.chart.tooltip.backdropFilter
|
|
702
|
-
}, {
|
|
703
|
-
"tooltip-before": N(() => [
|
|
704
|
-
A(t.$slots, "tooltip-before", ee(te({ ...ke.value })), void 0, !0)
|
|
705
|
-
]),
|
|
706
|
-
"tooltip-after": N(() => [
|
|
707
|
-
A(t.$slots, "tooltip-after", ee(te({ ...ke.value })), void 0, !0)
|
|
708
|
-
]),
|
|
709
|
-
_: 3
|
|
710
|
-
}, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "position", "offsetY", "parent", "content", "isCustom", "smooth", "backdropFilter"]),
|
|
711
|
-
t.$slots.source ? (w(), X("div", {
|
|
712
|
-
key: 5,
|
|
713
|
-
ref_key: "source",
|
|
714
|
-
ref: E,
|
|
715
|
-
dir: "auto"
|
|
716
|
-
}, [
|
|
717
|
-
A(t.$slots, "source", {}, void 0, !0)
|
|
718
|
-
], 512)) : L("", !0),
|
|
719
|
-
h.value ? (w(), Q(i(c), {
|
|
720
|
-
key: 6,
|
|
721
|
-
hideDetails: "",
|
|
722
|
-
config: {
|
|
723
|
-
open: P.value.showTable,
|
|
724
|
-
maxHeight: 1e4,
|
|
725
|
-
body: {
|
|
726
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
727
|
-
color: e.value.style.chart.color
|
|
728
|
-
},
|
|
729
|
-
head: {
|
|
730
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
731
|
-
color: e.value.style.chart.color
|
|
732
|
-
}
|
|
733
|
-
}
|
|
734
|
-
}, {
|
|
735
|
-
content: N(() => [
|
|
736
|
-
(w(), Q(i(m), {
|
|
737
|
-
key: `table_${re.value}`,
|
|
738
|
-
colNames: de.value.colNames,
|
|
739
|
-
head: de.value.head,
|
|
740
|
-
body: de.value.body,
|
|
741
|
-
config: de.value.config,
|
|
742
|
-
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
743
|
-
onClose: n[1] || (n[1] = (a) => P.value.showTable = !1)
|
|
744
|
-
}, {
|
|
745
|
-
th: N(({ th: a }) => [
|
|
746
|
-
$e("div", {
|
|
747
|
-
innerHTML: a,
|
|
748
|
-
style: { display: "flex", "align-items": "center" }
|
|
749
|
-
}, null, 8, Lt)
|
|
750
|
-
]),
|
|
751
|
-
td: N(({ td: a }) => [
|
|
752
|
-
it(Re(a.name || a), 1)
|
|
753
|
-
]),
|
|
754
|
-
_: 1
|
|
755
|
-
}, 8, ["colNames", "head", "body", "config", "title"]))
|
|
756
|
-
]),
|
|
757
|
-
_: 1
|
|
758
|
-
}, 8, ["config"])) : L("", !0),
|
|
759
|
-
i(ce) ? (w(), Q($t, { key: 7 })) : L("", !0)
|
|
760
|
-
], 44, _t));
|
|
761
|
-
}
|
|
762
|
-
}, oa = /* @__PURE__ */ It(Yt, [["__scopeId", "data-v-e1be8307"]]);
|
|
763
|
-
export {
|
|
764
|
-
oa as default
|
|
765
|
-
};
|