vue-data-ui 2.3.91 → 2.3.92
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -2
- package/dist/{Arrow-CHTslrAF.js → Arrow-16rQhq4i.js} +1 -1
- package/dist/{Arrow-DpuaFuue.cjs → Arrow-CdJD01md.cjs} +1 -1
- package/dist/{BaseIcon-DfaCNBgc.js → BaseIcon-CAmYNoaf.js} +1 -1
- package/dist/{BaseIcon-JWGtHqTA.cjs → BaseIcon-dYWMubrH.cjs} +1 -1
- package/dist/{DataTable-BKc3r3k3.js → DataTable-BXnbua0J.js} +2 -2
- package/dist/{DataTable-CnkdsvIo.cjs → DataTable-oa0Srfuc.cjs} +1 -1
- package/dist/{Legend-WNL92WSx.js → Legend-Cr1hulgT.js} +1 -1
- package/dist/{Legend-BQJV6Xk4.cjs → Legend-Dhm9_peB.cjs} +1 -1
- package/dist/{PackageVersion-D9PU8glB.js → PackageVersion-BVZfgDqm.js} +1 -1
- package/dist/{PackageVersion-LdLhc8hQ.cjs → PackageVersion-BkgJVmj1.cjs} +1 -1
- package/dist/{Shape-DPvoEBm9.js → Shape-D75m5xWM.js} +1 -1
- package/dist/{Shape-CgW0V2Og.cjs → Shape-hGbEoQOv.cjs} +1 -1
- package/dist/{Slicer-Dma3nlzi.cjs → Slicer-B7ya0m2Q.cjs} +1 -1
- package/dist/{Slicer-DE9nFM_c.js → Slicer-Bx8AozB8.js} +2 -2
- package/dist/{Title-CECK1w9L.js → Title-1Sw6EmHy.js} +1 -1
- package/dist/{Title-Bg_BK11V.cjs → Title-Bjrh7khe.cjs} +1 -1
- package/dist/{Tooltip-lM1Jzkza.cjs → Tooltip-CPATjuur.cjs} +1 -1
- package/dist/{Tooltip-Ci3AprCm.js → Tooltip-EJf3VBPR.js} +1 -1
- package/dist/documentation/installation.md +1 -1
- package/dist/index-D09qCApg.cjs +4 -0
- package/dist/{index-mBy4elhB.js → index-DhJby8wL.js} +8 -3
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +16 -0
- package/dist/types/vue-data-ui.d.ts +16 -0
- package/dist/{useNestedProp-m8IH8hWW.cjs → useNestedProp-Bwd7mK1Z.cjs} +1 -1
- package/dist/{useNestedProp-BrIRtQj1.js → useNestedProp-CrHvyupb.js} +1 -1
- package/dist/{usePrinter-Ck-yukK2.js → usePrinter-Bwm8J3RQ.js} +1 -1
- package/dist/{usePrinter-B8jr_V3b.cjs → usePrinter-DdsPm5a4.cjs} +1 -1
- package/dist/{vue-data-ui-BuL-2aYA.js → vue-data-ui-CLxne31S.js} +57 -57
- package/dist/{vue-data-ui-BgaY7Noy.cjs → vue-data-ui-ZitCqVgG.cjs} +1 -1
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-C9a-AsIX.cjs → vue-ui-3d-bar-DAv5cYGJ.cjs} +1 -1
- package/dist/{vue-ui-3d-bar-Cv-56A3m.js → vue-ui-3d-bar-Dg87_AAm.js} +8 -8
- package/dist/{vue-ui-accordion-Bzq1iTL2.cjs → vue-ui-accordion-BAHX7KzB.cjs} +1 -1
- package/dist/{vue-ui-accordion-dyF20BlD.js → vue-ui-accordion-Cn5Jbplg.js} +3 -3
- package/dist/{vue-ui-age-pyramid-DDPU8QV8.cjs → vue-ui-age-pyramid-GzHwQzsH.cjs} +1 -1
- package/dist/{vue-ui-age-pyramid-BqsDR6uw.js → vue-ui-age-pyramid-PlamQWqC.js} +9 -9
- package/dist/{vue-ui-annotator-B9HxrEVE.cjs → vue-ui-annotator-DGgQwl-K.cjs} +1 -1
- package/dist/{vue-ui-annotator-CkJsRR0r.js → vue-ui-annotator-Dd5KF_cy.js} +1 -1
- package/dist/{vue-ui-candlestick-DbbbJa-d.cjs → vue-ui-candlestick-BIEB2J1w.cjs} +1 -1
- package/dist/{vue-ui-candlestick-B8eYA2g0.js → vue-ui-candlestick-DTzwPhV5.js} +10 -10
- package/dist/{vue-ui-carousel-table-CCWGcKb7.cjs → vue-ui-carousel-table-HNTf5AYY.cjs} +1 -1
- package/dist/{vue-ui-carousel-table-BCiTg3Ok.js → vue-ui-carousel-table-YEfvPESA.js} +4 -4
- package/dist/{vue-ui-chestnut-rsWP_sXY.cjs → vue-ui-chestnut-DzjdAYsT.cjs} +1 -1
- package/dist/{vue-ui-chestnut-DI-N69Ad.js → vue-ui-chestnut-PzMOM7mp.js} +7 -7
- package/dist/{vue-ui-cursor-wY14Z-Vd.cjs → vue-ui-cursor-C5rsiCdn.cjs} +1 -1
- package/dist/{vue-ui-cursor-BUzJk1oC.js → vue-ui-cursor-DWea2yXV.js} +2 -2
- package/dist/{vue-ui-dashboard-Cf8TYbAr.cjs → vue-ui-dashboard-BqXhoS8m.cjs} +1 -1
- package/dist/{vue-ui-dashboard-CiG3kXLl.js → vue-ui-dashboard-CVespiTo.js} +2 -2
- package/dist/{vue-ui-digits-DZJI0YuX.js → vue-ui-digits-gNKgZqYU.js} +2 -2
- package/dist/{vue-ui-digits-BBho1-xO.cjs → vue-ui-digits-wmDN7Vkf.cjs} +1 -1
- package/dist/{vue-ui-donut-evolution-BtTiBfLb.js → vue-ui-donut-evolution-Ch6HH0ja.js} +10 -10
- package/dist/{vue-ui-donut-evolution-BVnSrr-b.cjs → vue-ui-donut-evolution-DhDxLZ1J.cjs} +1 -1
- package/dist/{vue-ui-donut-D4WpeX9W.cjs → vue-ui-donut-n37BZPxr.cjs} +1 -1
- package/dist/{vue-ui-donut-CBG9ECp8.js → vue-ui-donut-sQunZI1L.js} +10 -10
- package/dist/{vue-ui-dumbbell-BQKiB9yH.cjs → vue-ui-dumbbell-B9Z_pjnG.cjs} +1 -1
- package/dist/{vue-ui-dumbbell-DlEN2c_X.js → vue-ui-dumbbell-lFlZX8Yi.js} +9 -9
- package/dist/{vue-ui-flow-DfMNmttZ.cjs → vue-ui-flow-BaFpUJg-.cjs} +1 -1
- package/dist/{vue-ui-flow-CXqGztWj.js → vue-ui-flow-CSIOC-JR.js} +8 -8
- package/dist/{vue-ui-galaxy-CGn5nkD5.cjs → vue-ui-galaxy-BIR5GxIc.cjs} +1 -1
- package/dist/{vue-ui-galaxy-xI38Kf-S.js → vue-ui-galaxy-DL2mnel_.js} +10 -10
- package/dist/{vue-ui-gauge-BEludqYn.js → vue-ui-gauge-BMq7KT3t.js} +6 -6
- package/dist/{vue-ui-gauge-Bz-OSNOJ.cjs → vue-ui-gauge-r_qvpwE7.cjs} +1 -1
- package/dist/{vue-ui-gizmo-CZZB7YgY.cjs → vue-ui-gizmo-DBas_Sw_.cjs} +1 -1
- package/dist/{vue-ui-gizmo-BB28OTr1.js → vue-ui-gizmo-Dj7zvNI1.js} +3 -3
- package/dist/{vue-ui-heatmap-mywZXUV8.js → vue-ui-heatmap-pqBYIrxm.js} +9 -9
- package/dist/{vue-ui-heatmap-BtUvE7rK.cjs → vue-ui-heatmap-qPgEhAzc.cjs} +1 -1
- package/dist/{vue-ui-kpi-CEAGjnkj.cjs → vue-ui-kpi-Cmo9J7wp.cjs} +1 -1
- package/dist/{vue-ui-kpi-zr721ux9.js → vue-ui-kpi-ZPBinMiF.js} +3 -3
- package/dist/{vue-ui-mini-loader-DBFAzGb2.cjs → vue-ui-mini-loader-Ce-jbgMT.cjs} +1 -1
- package/dist/{vue-ui-mini-loader-9zyuKIpT.js → vue-ui-mini-loader-DOTWhLi9.js} +2 -2
- package/dist/{vue-ui-molecule-DltNL0kV.cjs → vue-ui-molecule-D429iwPP.cjs} +1 -1
- package/dist/{vue-ui-molecule-Bv_ppQig.js → vue-ui-molecule-RDpgNrHQ.js} +10 -10
- package/dist/{vue-ui-mood-radar-CIK2Xohn.js → vue-ui-mood-radar-CD5L8WCU.js} +10 -10
- package/dist/{vue-ui-mood-radar-CQkF2Rp1.cjs → vue-ui-mood-radar-CdLJxrkT.cjs} +1 -1
- package/dist/{vue-ui-nested-donuts-f-cMx3iQ.js → vue-ui-nested-donuts-A-tid5cQ.js} +10 -10
- package/dist/{vue-ui-nested-donuts-vHr23QlH.cjs → vue-ui-nested-donuts-DyM3uc7x.cjs} +1 -1
- package/dist/{vue-ui-onion-B6ZrryDW.cjs → vue-ui-onion-BKql8oal.cjs} +1 -1
- package/dist/{vue-ui-onion-CmUXelhy.js → vue-ui-onion-Cap01Ehu.js} +10 -10
- package/dist/{vue-ui-parallel-coordinate-plot-BU0yoxD9.cjs → vue-ui-parallel-coordinate-plot-B0zMgtnq.cjs} +1 -1
- package/dist/{vue-ui-parallel-coordinate-plot-h9dS2u_k.js → vue-ui-parallel-coordinate-plot-CcDKe4L0.js} +11 -11
- package/dist/{vue-ui-quadrant-DNT_0fTL.js → vue-ui-quadrant-BDEfAeyJ.js} +11 -11
- package/dist/{vue-ui-quadrant-DPPXilUd.cjs → vue-ui-quadrant-CZzdpeQ2.cjs} +1 -1
- package/dist/{vue-ui-quick-chart-T6C0BTyw.js → vue-ui-quick-chart-DlAUYg5u.js} +8 -8
- package/dist/{vue-ui-quick-chart-1gG267X0.cjs → vue-ui-quick-chart-DpGYUyhq.cjs} +1 -1
- package/dist/{vue-ui-radar-CfCHXIYJ.js → vue-ui-radar-CbTln7gs.js} +11 -11
- package/dist/{vue-ui-radar-DpzjMFZD.cjs → vue-ui-radar-oBeaHlpT.cjs} +1 -1
- package/dist/{vue-ui-rating-DYcT_LS-.cjs → vue-ui-rating-BU7-F3_e.cjs} +1 -1
- package/dist/{vue-ui-rating-DuRLpMwk.js → vue-ui-rating-BkDncqow.js} +2 -2
- package/dist/{vue-ui-relation-circle-WmZMKqHL.js → vue-ui-relation-circle-C5B6UNGd.js} +6 -6
- package/dist/{vue-ui-relation-circle-BMrPtD2n.cjs → vue-ui-relation-circle-IWiJWgcB.cjs} +1 -1
- package/dist/{vue-ui-rings-Ce0Z_osd.js → vue-ui-rings-BujVUJ90.js} +10 -10
- package/dist/{vue-ui-rings-CkYl3uce.cjs → vue-ui-rings-Df2cRgD8.cjs} +1 -1
- package/dist/{vue-ui-scatter-DY9EpoGP.js → vue-ui-scatter-D6yqZJ7s.js} +11 -11
- package/dist/{vue-ui-scatter-Cjie2D-t.cjs → vue-ui-scatter-jFTeM2hW.cjs} +1 -1
- package/dist/{vue-ui-screenshot-lQLJHBQ2.js → vue-ui-screenshot-CHAySwpv.js} +1 -1
- package/dist/{vue-ui-screenshot-BCFym6go.cjs → vue-ui-screenshot-CVu8IM33.cjs} +1 -1
- package/dist/{vue-ui-skeleton-DDhwPZd_.js → vue-ui-skeleton-ASX40MGk.js} +3 -3
- package/dist/{vue-ui-skeleton-Cf89QIhl.cjs → vue-ui-skeleton-CAlTn_Cg.cjs} +1 -1
- package/dist/{vue-ui-smiley-xxMwBT9c.js → vue-ui-smiley-DGVzhza2.js} +2 -2
- package/dist/{vue-ui-smiley-DMA6fgGr.cjs → vue-ui-smiley-dwCqhB0r.cjs} +1 -1
- package/dist/{vue-ui-spark-trend-Btj_H6fa.cjs → vue-ui-spark-trend-A1EHFK_r.cjs} +1 -1
- package/dist/{vue-ui-spark-trend-CLHTqp94.js → vue-ui-spark-trend-B7XhDvTj.js} +5 -5
- package/dist/{vue-ui-sparkbar-Btk6snt4.js → vue-ui-sparkbar-BuNcvi66.js} +4 -4
- package/dist/{vue-ui-sparkbar-CKrbBVKQ.cjs → vue-ui-sparkbar-CwNjHOjD.cjs} +1 -1
- package/dist/{vue-ui-sparkgauge-DfWLtFYS.cjs → vue-ui-sparkgauge-ISu154lS.cjs} +1 -1
- package/dist/{vue-ui-sparkgauge-DKJtFTSv.js → vue-ui-sparkgauge-JY2kB9WX.js} +4 -4
- package/dist/{vue-ui-sparkhistogram-wHJ-8zVV.cjs → vue-ui-sparkhistogram-C8zyC-ii.cjs} +1 -1
- package/dist/{vue-ui-sparkhistogram-JRLlw9EX.js → vue-ui-sparkhistogram-DyEPWxkP.js} +5 -5
- package/dist/{vue-ui-sparkline-DElVaalm.cjs → vue-ui-sparkline-DL3Thtc4.cjs} +1 -1
- package/dist/{vue-ui-sparkline-tBF9iaNm.js → vue-ui-sparkline-DYC3sdvQ.js} +4 -4
- package/dist/{vue-ui-sparkstackbar-BS9I8en7.js → vue-ui-sparkstackbar-7TmtP3WR.js} +4 -4
- package/dist/{vue-ui-sparkstackbar-tZa2IYHP.cjs → vue-ui-sparkstackbar-ChIM9bn2.cjs} +1 -1
- package/dist/{vue-ui-stackbar-UiX8q4yL.js → vue-ui-stackbar-CP5C6Gb_.js} +11 -11
- package/dist/{vue-ui-stackbar-rOa0atA9.cjs → vue-ui-stackbar-DrtiSaNc.cjs} +1 -1
- package/dist/{vue-ui-strip-plot-hRy6QRHK.cjs → vue-ui-strip-plot-BMYMIHGu.cjs} +1 -1
- package/dist/{vue-ui-strip-plot-BOkfg5vB.js → vue-ui-strip-plot-DJQCq_KE.js} +10 -10
- package/dist/{vue-ui-table-B9dc0l0k.cjs → vue-ui-table-D6hvgMif.cjs} +1 -1
- package/dist/{vue-ui-table-Dtfv71zG.js → vue-ui-table-IJi0xaVg.js} +1 -1
- package/dist/{vue-ui-table-heatmap-DUQEHohs.cjs → vue-ui-table-heatmap-BZNKXZNs.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-BMl-sP5Q.js → vue-ui-table-heatmap-Ls8_xq0D.js} +4 -4
- package/dist/{vue-ui-table-sparkline-BVnGb-lu.cjs → vue-ui-table-sparkline-BQFK30H1.cjs} +1 -1
- package/dist/{vue-ui-table-sparkline-BeunspIj.js → vue-ui-table-sparkline-BeuvdssX.js} +5 -5
- package/dist/{vue-ui-thermometer-A3Xxn5Ly.cjs → vue-ui-thermometer-DKm8SXlE.cjs} +1 -1
- package/dist/{vue-ui-thermometer-Cb9ALBj_.js → vue-ui-thermometer-DPWIvG92.js} +6 -6
- package/dist/{vue-ui-timer-2PRDq1w6.js → vue-ui-timer-CEzDvZf7.js} +5 -5
- package/dist/{vue-ui-timer-DltmIdrq.cjs → vue-ui-timer-n6lv7oTx.cjs} +1 -1
- package/dist/{vue-ui-tiremarks-BTlJcW4v.cjs → vue-ui-tiremarks-B33mHXZN.cjs} +1 -1
- package/dist/{vue-ui-tiremarks-Bse3PMGV.js → vue-ui-tiremarks-BUGoY22W.js} +6 -6
- package/dist/{vue-ui-treemap-Cv_mHK8H.cjs → vue-ui-treemap-DPxBZUUr.cjs} +1 -1
- package/dist/{vue-ui-treemap-D8fjVYq0.js → vue-ui-treemap-DmOYjJ_F.js} +10 -10
- package/dist/{vue-ui-vertical-bar-ZgJq3_CI.cjs → vue-ui-vertical-bar-BJMYX8t4.cjs} +1 -1
- package/dist/{vue-ui-vertical-bar-BVldPT8k.js → vue-ui-vertical-bar-BpVKdSY5.js} +10 -10
- package/dist/{vue-ui-waffle-BpeGEjCl.cjs → vue-ui-waffle-DGcueccy.cjs} +1 -1
- package/dist/{vue-ui-waffle-wikAjwZY.js → vue-ui-waffle-ULg6SwPx.js} +10 -10
- package/dist/{vue-ui-wheel-BlgfdULS.cjs → vue-ui-wheel-CWKq-CFW.cjs} +1 -1
- package/dist/{vue-ui-wheel-D5qyBs0Y.js → vue-ui-wheel-DlmgZd-_.js} +6 -6
- package/dist/vue-ui-word-cloud-BhHWdmqP.cjs +1 -0
- package/dist/vue-ui-word-cloud-DWyboczt.js +574 -0
- package/dist/{vue-ui-xy-FHLTc7xG.cjs → vue-ui-xy-Cz81fw_E.cjs} +1 -1
- package/dist/{vue-ui-xy-CUjllUSv.js → vue-ui-xy-V13Ns1gv.js} +13 -13
- package/dist/{vue-ui-xy-canvas-BkOlPU8e.js → vue-ui-xy-canvas-B9cRe5gT.js} +10 -10
- package/dist/{vue-ui-xy-canvas-BJUnRVuf.cjs → vue-ui-xy-canvas-GiuHOyj5.cjs} +1 -1
- package/package.json +1 -1
- package/dist/index-BhH89oF0.cjs +0 -4
- package/dist/vue-ui-word-cloud-Bcdl2iE-.js +0 -515
- package/dist/vue-ui-word-cloud-sNzfl_Tq.cjs +0 -1
|
@@ -1,515 +0,0 @@
|
|
|
1
|
-
import { useCssVars as Fe, computed as g, openBlock as r, createElementBlock as v, createVNode as de, renderSlot as f, createElementVNode as w, normalizeStyle as H, pushScopeId as _e, popScopeId as Ne, ref as c, watch as X, onMounted as Pe, onBeforeUnmount as Te, createBlock as I, createCommentVNode as _, unref as C, createSlots as ze, withCtx as m, normalizeProps as j, guardReactiveProps as q, normalizeClass as se, Fragment as Ie, renderList as Ae, toDisplayString as ne, createTextVNode as Oe, nextTick as re } from "vue";
|
|
2
|
-
import { u as Me, Y as De, v as We, c as ue, t as Be, a as Ee, p as R, o as Re, e as ie, g as Ue, f as Ve, X as Ge, q as Le, r as Xe } from "./index-mBy4elhB.js";
|
|
3
|
-
import { _ as je } from "./Title-CECK1w9L.js";
|
|
4
|
-
import { u as qe, U as He } from "./usePrinter-Ck-yukK2.js";
|
|
5
|
-
import { d as Ye, t as Je, u as Ke } from "./useResponsive-NZB-WLRF.js";
|
|
6
|
-
import Qe from "./vue-ui-accordion-dyF20BlD.js";
|
|
7
|
-
import { D as Ze } from "./DataTable-BKc3r3k3.js";
|
|
8
|
-
import et from "./BaseIcon-DfaCNBgc.js";
|
|
9
|
-
import { _ as ve } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
10
|
-
import { u as ce } from "./useNestedProp-BrIRtQj1.js";
|
|
11
|
-
import { _ as tt } from "./PackageVersion-D9PU8glB.js";
|
|
12
|
-
const at = (u) => (_e("data-v-3fd7d274"), u = u(), Ne(), u), ot = { "data-html2canvas-ignore": "" }, lt = {
|
|
13
|
-
key: 0,
|
|
14
|
-
class: "reset-wrapper"
|
|
15
|
-
}, st = {
|
|
16
|
-
key: 1,
|
|
17
|
-
class: "reset-wrapper"
|
|
18
|
-
}, nt = { class: "mono-slicer" }, rt = /* @__PURE__ */ at(() => /* @__PURE__ */ w("div", { class: "slider-track" }, null, -1)), ut = ["min", "max", "value"], it = {
|
|
19
|
-
__name: "MonoSlicer",
|
|
20
|
-
props: {
|
|
21
|
-
min: {
|
|
22
|
-
type: Number,
|
|
23
|
-
default: 0
|
|
24
|
-
},
|
|
25
|
-
max: {
|
|
26
|
-
type: Number,
|
|
27
|
-
default: 0
|
|
28
|
-
},
|
|
29
|
-
inputColor: {
|
|
30
|
-
type: String,
|
|
31
|
-
default: "#1A1A1A"
|
|
32
|
-
},
|
|
33
|
-
background: {
|
|
34
|
-
type: String,
|
|
35
|
-
default: "#FFFFFF"
|
|
36
|
-
},
|
|
37
|
-
borderColor: {
|
|
38
|
-
type: String,
|
|
39
|
-
default: "#FFFFFF"
|
|
40
|
-
},
|
|
41
|
-
selectColor: {
|
|
42
|
-
type: String,
|
|
43
|
-
default: "#4A4A4A"
|
|
44
|
-
},
|
|
45
|
-
textColor: {
|
|
46
|
-
type: String,
|
|
47
|
-
default: "#1A1A1A"
|
|
48
|
-
},
|
|
49
|
-
useResetSlot: {
|
|
50
|
-
type: Boolean,
|
|
51
|
-
default: !1
|
|
52
|
-
},
|
|
53
|
-
value: {
|
|
54
|
-
type: Number,
|
|
55
|
-
default: 0
|
|
56
|
-
},
|
|
57
|
-
source: {
|
|
58
|
-
type: Number,
|
|
59
|
-
default: 0
|
|
60
|
-
}
|
|
61
|
-
},
|
|
62
|
-
emits: ["update:value", "reset"],
|
|
63
|
-
setup(u, { emit: A }) {
|
|
64
|
-
const s = u;
|
|
65
|
-
Fe((b) => ({
|
|
66
|
-
"90ad3208": U.value,
|
|
67
|
-
"4f9eef70": P.value,
|
|
68
|
-
"6e07ae3e": N.value,
|
|
69
|
-
"2fd430a0": u.selectColor,
|
|
70
|
-
"6b8169a4": k.value
|
|
71
|
-
}));
|
|
72
|
-
const U = g(() => s.inputColor), k = g(() => s.background), N = g(() => `${s.selectColor}33`), P = g(() => s.borderColor);
|
|
73
|
-
function T() {
|
|
74
|
-
A("reset");
|
|
75
|
-
}
|
|
76
|
-
const x = g(() => {
|
|
77
|
-
const b = s.max - s.min, p = 0, $ = (s.value - s.min) / b * 100;
|
|
78
|
-
return {
|
|
79
|
-
left: `${p}%`,
|
|
80
|
-
width: `${$ - p}%`,
|
|
81
|
-
background: s.selectColor
|
|
82
|
-
};
|
|
83
|
-
});
|
|
84
|
-
return (b, p) => (r(), v("div", ot, [
|
|
85
|
-
u.value !== u.source ? (r(), v("div", lt, [
|
|
86
|
-
u.useResetSlot ? f(b.$slots, "reset-action", {
|
|
87
|
-
key: 1,
|
|
88
|
-
reset: T
|
|
89
|
-
}, void 0, !0) : (r(), v("button", {
|
|
90
|
-
key: 0,
|
|
91
|
-
"data-cy-reset": "",
|
|
92
|
-
tabindex: "0",
|
|
93
|
-
role: "button",
|
|
94
|
-
class: "vue-data-ui-refresh-button",
|
|
95
|
-
onClick: T
|
|
96
|
-
}, [
|
|
97
|
-
de(et, {
|
|
98
|
-
name: "refresh",
|
|
99
|
-
stroke: u.textColor
|
|
100
|
-
}, null, 8, ["stroke"])
|
|
101
|
-
]))
|
|
102
|
-
])) : (r(), v("div", st)),
|
|
103
|
-
w("div", nt, [
|
|
104
|
-
rt,
|
|
105
|
-
w("div", {
|
|
106
|
-
class: "range-highlight",
|
|
107
|
-
style: H(x.value)
|
|
108
|
-
}, null, 4),
|
|
109
|
-
w("input", {
|
|
110
|
-
type: "range",
|
|
111
|
-
min: u.min,
|
|
112
|
-
max: u.max,
|
|
113
|
-
value: Number(u.value),
|
|
114
|
-
onInput: p[0] || (p[0] = ($) => A("update:value", Number($.target.value)))
|
|
115
|
-
}, null, 40, ut)
|
|
116
|
-
])
|
|
117
|
-
]));
|
|
118
|
-
}
|
|
119
|
-
}, ct = /* @__PURE__ */ ve(it, [["__scopeId", "data-v-3fd7d274"]]), dt = ["id"], vt = ["xmlns", "viewBox"], ht = ["transform"], mt = ["fill", "font-weight", "x", "y", "font-size", "transform"], ft = {
|
|
120
|
-
key: 3,
|
|
121
|
-
class: "vue-data-ui-watermark"
|
|
122
|
-
}, gt = ["innerHTML"], pt = {
|
|
123
|
-
__name: "vue-ui-word-cloud",
|
|
124
|
-
props: {
|
|
125
|
-
config: {
|
|
126
|
-
type: Object,
|
|
127
|
-
default() {
|
|
128
|
-
return {};
|
|
129
|
-
}
|
|
130
|
-
},
|
|
131
|
-
dataset: {
|
|
132
|
-
type: [Array, String],
|
|
133
|
-
default() {
|
|
134
|
-
return [];
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
},
|
|
138
|
-
setup(u, { expose: A }) {
|
|
139
|
-
const s = u, { vue_ui_word_cloud: U } = Me(), k = g({
|
|
140
|
-
get() {
|
|
141
|
-
return !!s.dataset && s.dataset.length;
|
|
142
|
-
},
|
|
143
|
-
set(t) {
|
|
144
|
-
return t;
|
|
145
|
-
}
|
|
146
|
-
}), N = c(typeof s.dataset == "string" ? De(s.dataset) : s.dataset.map((t) => ({
|
|
147
|
-
...t,
|
|
148
|
-
value: We(t.value)
|
|
149
|
-
}))), P = c(ue()), T = c(0), x = c(null), b = c(null), p = c(0), $ = c(0), e = g({
|
|
150
|
-
get: () => Y(),
|
|
151
|
-
set: (t) => t
|
|
152
|
-
});
|
|
153
|
-
function Y() {
|
|
154
|
-
const t = ce({
|
|
155
|
-
userConfig: s.config,
|
|
156
|
-
defaultConfig: U
|
|
157
|
-
});
|
|
158
|
-
return t.theme ? {
|
|
159
|
-
...ce({
|
|
160
|
-
userConfig: Be.vue_ui_word_cloud[t.theme] || s.config,
|
|
161
|
-
defaultConfig: t
|
|
162
|
-
}),
|
|
163
|
-
customPalette: Ee[t.theme] || R
|
|
164
|
-
} : t;
|
|
165
|
-
}
|
|
166
|
-
X(() => s.config, (t) => {
|
|
167
|
-
e.value = Y(), K(), p.value += 1, $.value += 1, h.value = e.value.style.chart.width;
|
|
168
|
-
}, { deep: !0 });
|
|
169
|
-
const J = c(null), h = c(e.value.style.chart.width), n = c({
|
|
170
|
-
width: h.value,
|
|
171
|
-
height: e.value.style.chart.height / e.value.style.chart.height * h.value,
|
|
172
|
-
maxFontSize: e.value.style.chart.words.maxFontSize,
|
|
173
|
-
minFontSize: e.value.style.chart.words.minFontSize
|
|
174
|
-
}), he = Je(() => {
|
|
175
|
-
const { width: t, height: o } = Ke({
|
|
176
|
-
chart: x.value,
|
|
177
|
-
title: e.value.style.chart.title.text ? b.value : null,
|
|
178
|
-
slicer: e.value.style.chart.zoom.show && J.value
|
|
179
|
-
});
|
|
180
|
-
n.value.width = t, n.value.height = o, re(V);
|
|
181
|
-
});
|
|
182
|
-
X(() => h.value, () => {
|
|
183
|
-
me();
|
|
184
|
-
});
|
|
185
|
-
const me = Ye(() => {
|
|
186
|
-
n.value.width = Number(h.value), n.value.height = e.value.style.chart.height / e.value.style.chart.height * Number(h.value), V();
|
|
187
|
-
}, 10);
|
|
188
|
-
function fe() {
|
|
189
|
-
h.value = e.value.style.chart.width;
|
|
190
|
-
}
|
|
191
|
-
const O = c(null);
|
|
192
|
-
Pe(() => {
|
|
193
|
-
K();
|
|
194
|
-
});
|
|
195
|
-
function K() {
|
|
196
|
-
Re(s.dataset) ? ie({
|
|
197
|
-
componentName: "VueUiWordCloud",
|
|
198
|
-
type: "dataset"
|
|
199
|
-
}) : N.value.forEach((t, o) => {
|
|
200
|
-
Ue({
|
|
201
|
-
datasetObject: t,
|
|
202
|
-
requiredAttributes: ["name", "value"]
|
|
203
|
-
}).forEach((a) => {
|
|
204
|
-
k.value = !1, ie({
|
|
205
|
-
componentName: "VueUiWordCloud",
|
|
206
|
-
type: "datasetSerieAttribute",
|
|
207
|
-
property: a,
|
|
208
|
-
index: o
|
|
209
|
-
});
|
|
210
|
-
});
|
|
211
|
-
}), e.value.responsive && (O.value = new ResizeObserver(he), O.value.observe(x.value.parentNode));
|
|
212
|
-
}
|
|
213
|
-
Te(() => {
|
|
214
|
-
O.value && O.value.disconnect();
|
|
215
|
-
});
|
|
216
|
-
const { isPrinting: Q, isImaging: Z, generatePdf: ee, generateImage: te } = qe({
|
|
217
|
-
elementId: `wordCloud_${P.value}`,
|
|
218
|
-
fileName: e.value.style.chart.title.text || "vue-ui-word-cloud"
|
|
219
|
-
}), M = c({
|
|
220
|
-
showTable: e.value.table.show
|
|
221
|
-
});
|
|
222
|
-
function ge(t, o, a = "Arial") {
|
|
223
|
-
const l = document.createElement("canvas").getContext("2d");
|
|
224
|
-
return l.font = `${o}px ${e.value.style.chart.words.bold ? "bold" : "normal"} ${a}`, {
|
|
225
|
-
width: l.measureText(t).width + e.value.style.chart.words.proximity,
|
|
226
|
-
height: o
|
|
227
|
-
};
|
|
228
|
-
}
|
|
229
|
-
function pe(t, o) {
|
|
230
|
-
return t.x < o.x + o.width && t.x + t.width > o.x && t.y < o.y + o.height && t.y + t.height > o.y;
|
|
231
|
-
}
|
|
232
|
-
function ye(t, o, a) {
|
|
233
|
-
const i = [], l = { x: -o / 2, y: -a / 2, width: o, height: a }, d = 0, S = 0;
|
|
234
|
-
return t.forEach((F) => {
|
|
235
|
-
let G = !1;
|
|
236
|
-
for (let E = 0; E < Math.max(o, a) / 2 && !G; E += e.value.style.chart.words.packingWeight)
|
|
237
|
-
for (let L = 0; L < 360 && !G; L += e.value.style.chart.words.packingWeight) {
|
|
238
|
-
const le = L * Math.PI / 180, we = d + E * Math.cos(le) - F.width / 2, ke = S + E * Math.sin(le) - F.height / 2, y = { ...F, x: we, y: ke }, xe = y.x >= l.x && y.y >= l.y && y.x + y.width <= l.x + l.width && y.y + y.height <= l.y + l.height, $e = i.some((Se) => pe(y, Se));
|
|
239
|
-
xe && !$e && (i.push(y), G = !0);
|
|
240
|
-
}
|
|
241
|
-
}), i;
|
|
242
|
-
}
|
|
243
|
-
const z = c([]);
|
|
244
|
-
X(() => s.dataset, V, { immediate: !0 });
|
|
245
|
-
function V() {
|
|
246
|
-
const t = N.value.map((l) => l.value), o = Math.max(...t), a = Math.min(...t), i = N.value.map((l, d) => {
|
|
247
|
-
const S = (l.value - a) / (o - a) * (n.value.maxFontSize - n.value.minFontSize) + n.value.minFontSize, F = ge(l.name, S);
|
|
248
|
-
return {
|
|
249
|
-
...l,
|
|
250
|
-
id: ue(),
|
|
251
|
-
fontSize: S,
|
|
252
|
-
width: F.width,
|
|
253
|
-
height: F.height,
|
|
254
|
-
color: e.value.style.chart.words.usePalette ? e.value.customPalette[d] || e.value.customPalette[d % e.value.customPalette.length] || R[d] || R[d % R.length] : e.value.style.chart.words.color
|
|
255
|
-
};
|
|
256
|
-
});
|
|
257
|
-
z.value = ye(i, n.value.width, n.value.height).sort((l, d) => d.fontSize - l.fontSize);
|
|
258
|
-
}
|
|
259
|
-
const D = g(() => {
|
|
260
|
-
const t = z.value.map((a) => ({
|
|
261
|
-
name: a.name,
|
|
262
|
-
color: a.color
|
|
263
|
-
})), o = z.value.map((a) => a.value);
|
|
264
|
-
return { head: t, body: o };
|
|
265
|
-
});
|
|
266
|
-
function ae() {
|
|
267
|
-
re(() => {
|
|
268
|
-
const t = D.value.head.map((i, l) => [[
|
|
269
|
-
i.name
|
|
270
|
-
], [D.value.body[l]]]), o = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], [e.value.table.columnNames.value]]].concat(t), a = Le(o);
|
|
271
|
-
Xe({ csvContent: a, title: e.value.style.chart.title.text || "vue-ui-word-cloud" });
|
|
272
|
-
});
|
|
273
|
-
}
|
|
274
|
-
const W = g(() => {
|
|
275
|
-
const t = [
|
|
276
|
-
e.value.table.columnNames.series,
|
|
277
|
-
e.value.table.columnNames.value
|
|
278
|
-
], o = D.value.head.map((l, d) => {
|
|
279
|
-
const S = Ve({ p: e.value.table.td.prefix, v: D.value.body[d], s: e.value.table.td.suffix, r: e.value.table.td.roundingValue });
|
|
280
|
-
return [
|
|
281
|
-
{
|
|
282
|
-
color: l.color,
|
|
283
|
-
name: l.name
|
|
284
|
-
},
|
|
285
|
-
S
|
|
286
|
-
];
|
|
287
|
-
}), a = {
|
|
288
|
-
th: {
|
|
289
|
-
backgroundColor: e.value.table.th.backgroundColor,
|
|
290
|
-
color: e.value.table.th.color,
|
|
291
|
-
outline: e.value.table.th.outline
|
|
292
|
-
},
|
|
293
|
-
td: {
|
|
294
|
-
backgroundColor: e.value.table.td.backgroundColor,
|
|
295
|
-
color: e.value.table.td.color,
|
|
296
|
-
outline: e.value.table.td.outline
|
|
297
|
-
},
|
|
298
|
-
breakpoint: e.value.table.responsiveBreakpoint
|
|
299
|
-
};
|
|
300
|
-
return {
|
|
301
|
-
colNames: [
|
|
302
|
-
e.value.table.columnNames.series,
|
|
303
|
-
e.value.table.columnNames.value
|
|
304
|
-
],
|
|
305
|
-
head: t,
|
|
306
|
-
body: o,
|
|
307
|
-
config: a
|
|
308
|
-
};
|
|
309
|
-
}), B = c(!1);
|
|
310
|
-
function be(t) {
|
|
311
|
-
B.value = t, T.value += 1;
|
|
312
|
-
}
|
|
313
|
-
function Ce() {
|
|
314
|
-
return z.value;
|
|
315
|
-
}
|
|
316
|
-
function oe() {
|
|
317
|
-
M.value.showTable = !M.value.showTable;
|
|
318
|
-
}
|
|
319
|
-
return A({
|
|
320
|
-
getData: Ce,
|
|
321
|
-
generateCsv: ae,
|
|
322
|
-
generatePdf: ee,
|
|
323
|
-
generateImage: te,
|
|
324
|
-
toggleTable: oe
|
|
325
|
-
}), (t, o) => (r(), v("div", {
|
|
326
|
-
class: "vue-ui-word-cloud",
|
|
327
|
-
ref_key: "wordCloudChart",
|
|
328
|
-
ref: x,
|
|
329
|
-
id: `wordCloud_${P.value}`,
|
|
330
|
-
style: H(`width: 100%; font-family:${e.value.style.fontFamily};background:${e.value.style.chart.backgroundColor};${e.value.responsive ? "height:100%" : ""}`)
|
|
331
|
-
}, [
|
|
332
|
-
e.value.style.chart.title.text ? (r(), v("div", {
|
|
333
|
-
key: 0,
|
|
334
|
-
ref_key: "chartTitle",
|
|
335
|
-
ref: b,
|
|
336
|
-
style: "width:100%;background:transparent;padding-bottom:24px"
|
|
337
|
-
}, [
|
|
338
|
-
(r(), I(je, {
|
|
339
|
-
key: `title_${p.value}`,
|
|
340
|
-
config: {
|
|
341
|
-
title: {
|
|
342
|
-
...e.value.style.chart.title
|
|
343
|
-
},
|
|
344
|
-
subtitle: {
|
|
345
|
-
...e.value.style.chart.title.subtitle
|
|
346
|
-
}
|
|
347
|
-
}
|
|
348
|
-
}, null, 8, ["config"]))
|
|
349
|
-
], 512)) : _("", !0),
|
|
350
|
-
e.value.userOptions.show && k.value ? (r(), I(He, {
|
|
351
|
-
ref: "details",
|
|
352
|
-
key: `user_option_${T.value}`,
|
|
353
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
354
|
-
color: e.value.style.chart.color,
|
|
355
|
-
isPrinting: C(Q),
|
|
356
|
-
isImaging: C(Z),
|
|
357
|
-
uid: P.value,
|
|
358
|
-
hasPdf: e.value.userOptions.buttons.pdf,
|
|
359
|
-
hasXls: e.value.userOptions.buttons.csv,
|
|
360
|
-
hasImg: e.value.userOptions.buttons.img,
|
|
361
|
-
hasTable: e.value.userOptions.buttons.table,
|
|
362
|
-
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
363
|
-
isFullscreen: B.value,
|
|
364
|
-
titles: { ...e.value.userOptions.buttonTitles },
|
|
365
|
-
chartElement: x.value,
|
|
366
|
-
position: e.value.userOptions.position,
|
|
367
|
-
onToggleFullscreen: be,
|
|
368
|
-
onGeneratePdf: C(ee),
|
|
369
|
-
onGenerateCsv: ae,
|
|
370
|
-
onGenerateImage: C(te),
|
|
371
|
-
onToggleTable: oe
|
|
372
|
-
}, ze({ _: 2 }, [
|
|
373
|
-
t.$slots.optionPdf ? {
|
|
374
|
-
name: "optionPdf",
|
|
375
|
-
fn: m(() => [
|
|
376
|
-
f(t.$slots, "optionPdf", {}, void 0, !0)
|
|
377
|
-
]),
|
|
378
|
-
key: "0"
|
|
379
|
-
} : void 0,
|
|
380
|
-
t.$slots.optionCsv ? {
|
|
381
|
-
name: "optionCsv",
|
|
382
|
-
fn: m(() => [
|
|
383
|
-
f(t.$slots, "optionCsv", {}, void 0, !0)
|
|
384
|
-
]),
|
|
385
|
-
key: "1"
|
|
386
|
-
} : void 0,
|
|
387
|
-
t.$slots.optionImg ? {
|
|
388
|
-
name: "optionImg",
|
|
389
|
-
fn: m(() => [
|
|
390
|
-
f(t.$slots, "optionImg", {}, void 0, !0)
|
|
391
|
-
]),
|
|
392
|
-
key: "2"
|
|
393
|
-
} : void 0,
|
|
394
|
-
t.$slots.optionTable ? {
|
|
395
|
-
name: "optionTable",
|
|
396
|
-
fn: m(() => [
|
|
397
|
-
f(t.$slots, "optionTable", {}, void 0, !0)
|
|
398
|
-
]),
|
|
399
|
-
key: "3"
|
|
400
|
-
} : void 0,
|
|
401
|
-
t.$slots.optionFullscreen ? {
|
|
402
|
-
name: "optionFullscreen",
|
|
403
|
-
fn: m(({ toggleFullscreen: a, isFullscreen: i }) => [
|
|
404
|
-
f(t.$slots, "optionFullscreen", j(q({ toggleFullscreen: a, isFullscreen: i })), void 0, !0)
|
|
405
|
-
]),
|
|
406
|
-
key: "4"
|
|
407
|
-
} : void 0
|
|
408
|
-
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasTable", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "onGeneratePdf", "onGenerateImage"])) : _("", !0),
|
|
409
|
-
k.value ? (r(), v("svg", {
|
|
410
|
-
key: 2,
|
|
411
|
-
class: se({ "vue-data-ui-fullscreen--on": B.value, "vue-data-ui-fulscreen--off": !B.value }),
|
|
412
|
-
xmlns: C(Ge),
|
|
413
|
-
viewBox: `0 0 ${n.value.width <= 0 ? 10 : n.value.width} ${n.value.height <= 0 ? 10 : n.value.height}`,
|
|
414
|
-
style: "overflow:visible;background:transparent;"
|
|
415
|
-
}, [
|
|
416
|
-
de(tt),
|
|
417
|
-
w("g", {
|
|
418
|
-
transform: `translate(${(n.value.width <= 0 ? 10 : n.value.width) / 2}, ${(n.value.height <= 0 ? 10 : n.value.height) / 2})`
|
|
419
|
-
}, [
|
|
420
|
-
(r(!0), v(Ie, null, Ae(z.value, (a, i) => (r(), v("g", null, [
|
|
421
|
-
(r(), v("text", {
|
|
422
|
-
fill: a.color,
|
|
423
|
-
"font-weight": e.value.style.chart.words.bold ? "bold" : "normal",
|
|
424
|
-
key: i,
|
|
425
|
-
x: a.x,
|
|
426
|
-
y: a.y,
|
|
427
|
-
"font-size": a.fontSize,
|
|
428
|
-
transform: `translate(${a.width / 2}, ${a.height / 2})`,
|
|
429
|
-
style: H(`animation-delay:${i * e.value.animationDelayMs}ms !important`),
|
|
430
|
-
class: se({ animated: e.value.useCssAnimation }),
|
|
431
|
-
"text-anchor": "middle",
|
|
432
|
-
"dominant-baseline": "middle"
|
|
433
|
-
}, ne(a.name), 15, mt))
|
|
434
|
-
]))), 256))
|
|
435
|
-
], 8, ht),
|
|
436
|
-
f(t.$slots, "svg", {
|
|
437
|
-
svg: { height: n.value.height, width: n.value.width }
|
|
438
|
-
}, void 0, !0)
|
|
439
|
-
], 10, vt)) : _("", !0),
|
|
440
|
-
t.$slots.watermark ? (r(), v("div", ft, [
|
|
441
|
-
f(t.$slots, "watermark", j(q({ isPrinting: C(Q) || C(Z) })), void 0, !0)
|
|
442
|
-
])) : _("", !0),
|
|
443
|
-
w("div", {
|
|
444
|
-
ref_key: "chartSlicer",
|
|
445
|
-
ref: J,
|
|
446
|
-
style: "width:100%;background:transparent",
|
|
447
|
-
"data-html2canvas-ignore": ""
|
|
448
|
-
}, [
|
|
449
|
-
e.value.style.chart.zoom.show ? (r(), I(ct, {
|
|
450
|
-
key: 0,
|
|
451
|
-
value: h.value,
|
|
452
|
-
"onUpdate:value": o[0] || (o[0] = (a) => h.value = a),
|
|
453
|
-
min: 100,
|
|
454
|
-
max: e.value.style.chart.width * 3,
|
|
455
|
-
textColor: e.value.style.chart.color,
|
|
456
|
-
inputColor: e.value.style.chart.zoom.color,
|
|
457
|
-
selectColor: e.value.style.chart.zoom.highlightColor,
|
|
458
|
-
useResetSlot: e.value.style.chart.zoom.useResetSlot,
|
|
459
|
-
background: e.value.style.chart.zoom.color,
|
|
460
|
-
borderColor: e.value.style.chart.backgroundColor,
|
|
461
|
-
source: e.value.style.chart.width,
|
|
462
|
-
onReset: fe
|
|
463
|
-
}, {
|
|
464
|
-
"reset-action": m(({ reset: a }) => [
|
|
465
|
-
f(t.$slots, "reset-action", j(q({ reset: a })), void 0, !0)
|
|
466
|
-
]),
|
|
467
|
-
_: 3
|
|
468
|
-
}, 8, ["value", "max", "textColor", "inputColor", "selectColor", "useResetSlot", "background", "borderColor", "source"])) : _("", !0)
|
|
469
|
-
], 512),
|
|
470
|
-
k.value ? (r(), I(Qe, {
|
|
471
|
-
key: 4,
|
|
472
|
-
hideDetails: "",
|
|
473
|
-
config: {
|
|
474
|
-
open: M.value.showTable,
|
|
475
|
-
maxHeight: 1e4,
|
|
476
|
-
body: {
|
|
477
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
478
|
-
color: e.value.style.chart.color
|
|
479
|
-
},
|
|
480
|
-
head: {
|
|
481
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
482
|
-
color: e.value.style.chart.color
|
|
483
|
-
}
|
|
484
|
-
}
|
|
485
|
-
}, {
|
|
486
|
-
content: m(() => [
|
|
487
|
-
(r(), I(Ze, {
|
|
488
|
-
key: `table_${$.value}`,
|
|
489
|
-
colNames: W.value.colNames,
|
|
490
|
-
head: W.value.head,
|
|
491
|
-
body: W.value.body,
|
|
492
|
-
config: W.value.config,
|
|
493
|
-
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
494
|
-
onClose: o[1] || (o[1] = (a) => M.value.showTable = !1)
|
|
495
|
-
}, {
|
|
496
|
-
th: m(({ th: a }) => [
|
|
497
|
-
w("div", {
|
|
498
|
-
innerHTML: a,
|
|
499
|
-
style: { display: "flex", "align-items": "center" }
|
|
500
|
-
}, null, 8, gt)
|
|
501
|
-
]),
|
|
502
|
-
td: m(({ td: a }) => [
|
|
503
|
-
Oe(ne(a.name || a), 1)
|
|
504
|
-
]),
|
|
505
|
-
_: 1
|
|
506
|
-
}, 8, ["colNames", "head", "body", "config", "title"]))
|
|
507
|
-
]),
|
|
508
|
-
_: 1
|
|
509
|
-
}, 8, ["config"])) : _("", !0)
|
|
510
|
-
], 12, dt));
|
|
511
|
-
}
|
|
512
|
-
}, Pt = /* @__PURE__ */ ve(pt, [["__scopeId", "data-v-e1d21ba1"]]);
|
|
513
|
-
export {
|
|
514
|
-
Pt as default
|
|
515
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-BhH89oF0.cjs"),ie=require("./Title-Bg_BK11V.cjs"),j=require("./usePrinter-B8jr_V3b.cjs"),O=require("./useResponsive-B3TrDDIG.cjs"),ce=require("./vue-ui-accordion-Bzq1iTL2.cjs"),de=require("./DataTable-CnkdsvIo.cjs"),ve=require("./BaseIcon-JWGtHqTA.cjs"),Y=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),H=require("./useNestedProp-m8IH8hWW.cjs"),he=require("./PackageVersion-LdLhc8hQ.cjs"),me=i=>(e.pushScopeId("data-v-3fd7d274"),i=i(),e.popScopeId(),i),fe={"data-html2canvas-ignore":""},pe={key:0,class:"reset-wrapper"},ge={key:1,class:"reset-wrapper"},ye={class:"mono-slicer"},be=me(()=>e.createElementVNode("div",{class:"slider-track"},null,-1)),ke=["min","max","value"],Ce={__name:"MonoSlicer",props:{min:{type:Number,default:0},max:{type:Number,default:0},inputColor:{type:String,default:"#1A1A1A"},background:{type:String,default:"#FFFFFF"},borderColor:{type:String,default:"#FFFFFF"},selectColor:{type:String,default:"#4A4A4A"},textColor:{type:String,default:"#1A1A1A"},useResetSlot:{type:Boolean,default:!1},value:{type:Number,default:0},source:{type:Number,default:0}},emits:["update:value","reset"],setup(i,{emit:N}){const r=i;e.useCssVars(f=>({"90ad3208":T.value,"4f9eef70":w.value,"6e07ae3e":C.value,"2fd430a0":i.selectColor,"6b8169a4":p.value}));const T=e.computed(()=>r.inputColor),p=e.computed(()=>r.background),C=e.computed(()=>`${r.selectColor}33`),w=e.computed(()=>r.borderColor);function x(){N("reset")}const g=e.computed(()=>{const f=r.max-r.min,h=0,y=(r.value-r.min)/f*100;return{left:`${h}%`,width:`${y-h}%`,background:r.selectColor}});return(f,h)=>(e.openBlock(),e.createElementBlock("div",fe,[i.value!==i.source?(e.openBlock(),e.createElementBlock("div",pe,[i.useResetSlot?e.renderSlot(f.$slots,"reset-action",{key:1,reset:x},void 0,!0):(e.openBlock(),e.createElementBlock("button",{key:0,"data-cy-reset":"",tabindex:"0",role:"button",class:"vue-data-ui-refresh-button",onClick:x},[e.createVNode(ve.default,{name:"refresh",stroke:i.textColor},null,8,["stroke"])]))])):(e.openBlock(),e.createElementBlock("div",ge)),e.createElementVNode("div",ye,[be,e.createElementVNode("div",{class:"range-highlight",style:e.normalizeStyle(g.value)},null,4),e.createElementVNode("input",{type:"range",min:i.min,max:i.max,value:Number(i.value),onInput:h[0]||(h[0]=y=>N("update:value",Number(y.target.value)))},null,40,ke)])]))}},we=Y._export_sfc(Ce,[["__scopeId","data-v-3fd7d274"]]),xe=["id"],Se=["xmlns","viewBox"],Ne=["transform"],$e=["fill","font-weight","x","y","font-size","transform"],Be={key:3,class:"vue-data-ui-watermark"},Pe=["innerHTML"],_e={__name:"vue-ui-word-cloud",props:{config:{type:Object,default(){return{}}},dataset:{type:[Array,String],default(){return[]}}},setup(i,{expose:N}){const r=i,{vue_ui_word_cloud:T}=u.useConfig(),p=e.computed({get(){return!!r.dataset&&r.dataset.length},set(o){return o}}),C=e.ref(typeof r.dataset=="string"?u.createWordCloudDatasetFromPlainText(r.dataset):r.dataset.map(o=>({...o,value:u.checkNaN(o.value)}))),w=e.ref(u.createUid()),x=e.ref(0),g=e.ref(null),f=e.ref(null),h=e.ref(0),y=e.ref(0),t=e.computed({get:()=>A(),set:o=>o});function A(){const o=H.useNestedProp({userConfig:r.config,defaultConfig:T});return o.theme?{...H.useNestedProp({userConfig:u.themes.vue_ui_word_cloud[o.theme]||r.config,defaultConfig:o}),customPalette:u.themePalettes[o.theme]||u.palette}:o}e.watch(()=>r.config,o=>{t.value=A(),q(),h.value+=1,y.value+=1,v.value=t.value.style.chart.width},{deep:!0});const M=e.ref(null),v=e.ref(t.value.style.chart.width),s=e.ref({width:v.value,height:t.value.style.chart.height/t.value.style.chart.height*v.value,maxFontSize:t.value.style.chart.words.maxFontSize,minFontSize:t.value.style.chart.words.minFontSize}),J=O.throttle(()=>{const{width:o,height:a}=O.useResponsive({chart:g.value,title:t.value.style.chart.title.text?f.value:null,slicer:t.value.style.chart.zoom.show&&M.value});s.value.width=o,s.value.height=a,e.nextTick(E)});e.watch(()=>v.value,()=>{K()});const K=O.debounce(()=>{s.value.width=Number(v.value),s.value.height=t.value.style.chart.height/t.value.style.chart.height*Number(v.value),E()},10);function Q(){v.value=t.value.style.chart.width}const $=e.ref(null);e.onMounted(()=>{q()});function q(){u.objectIsEmpty(r.dataset)?u.error({componentName:"VueUiWordCloud",type:"dataset"}):C.value.forEach((o,a)=>{u.getMissingDatasetAttributes({datasetObject:o,requiredAttributes:["name","value"]}).forEach(l=>{p.value=!1,u.error({componentName:"VueUiWordCloud",type:"datasetSerieAttribute",property:l,index:a})})}),t.value.responsive&&($.value=new ResizeObserver(J),$.value.observe(g.value.parentNode))}e.onBeforeUnmount(()=>{$.value&&$.value.disconnect()});const{isPrinting:R,isImaging:D,generatePdf:U,generateImage:W}=j.usePrinter({elementId:`wordCloud_${w.value}`,fileName:t.value.style.chart.title.text||"vue-ui-word-cloud"}),B=e.ref({showTable:t.value.table.show});function Z(o,a,l="Arial"){const n=document.createElement("canvas").getContext("2d");return n.font=`${a}px ${t.value.style.chart.words.bold?"bold":"normal"} ${l}`,{width:n.measureText(o).width+t.value.style.chart.words.proximity,height:a}}function ee(o,a){return o.x<a.x+a.width&&o.x+o.width>a.x&&o.y<a.y+a.height&&o.y+o.height>a.y}function te(o,a,l){const c=[],n={x:-a/2,y:-l/2,width:a,height:l},d=0,b=0;return o.forEach(k=>{let I=!1;for(let z=0;z<Math.max(a,l)/2&&!I;z+=t.value.style.chart.words.packingWeight)for(let V=0;V<360&&!I;V+=t.value.style.chart.words.packingWeight){const X=V*Math.PI/180,ae=d+z*Math.cos(X)-k.width/2,ne=b+z*Math.sin(X)-k.height/2,m={...k,x:ae,y:ne},re=m.x>=n.x&&m.y>=n.y&&m.x+m.width<=n.x+n.width&&m.y+m.height<=n.y+n.height,se=c.some(ue=>ee(m,ue));re&&!se&&(c.push(m),I=!0)}}),c}const S=e.ref([]);e.watch(()=>r.dataset,E,{immediate:!0});function E(){const o=C.value.map(n=>n.value),a=Math.max(...o),l=Math.min(...o),c=C.value.map((n,d)=>{const b=(n.value-l)/(a-l)*(s.value.maxFontSize-s.value.minFontSize)+s.value.minFontSize,k=Z(n.name,b);return{...n,id:u.createUid(),fontSize:b,width:k.width,height:k.height,color:t.value.style.chart.words.usePalette?t.value.customPalette[d]||t.value.customPalette[d%t.value.customPalette.length]||u.palette[d]||u.palette[d%u.palette.length]:t.value.style.chart.words.color}});S.value=te(c,s.value.width,s.value.height).sort((n,d)=>d.fontSize-n.fontSize)}const P=e.computed(()=>{const o=S.value.map(l=>({name:l.name,color:l.color})),a=S.value.map(l=>l.value);return{head:o,body:a}});function G(){e.nextTick(()=>{const o=P.value.head.map((c,n)=>[[c.name],[P.value.body[n]]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],[t.value.table.columnNames.value]]].concat(o),l=u.createCsvContent(a);u.downloadCsv({csvContent:l,title:t.value.style.chart.title.text||"vue-ui-word-cloud"})})}const _=e.computed(()=>{const o=[t.value.table.columnNames.series,t.value.table.columnNames.value],a=P.value.head.map((n,d)=>{const b=u.dataLabel({p:t.value.table.td.prefix,v:P.value.body[d],s:t.value.table.td.suffix,r:t.value.table.td.roundingValue});return[{color:n.color,name:n.name},b]}),l={th:{backgroundColor:t.value.table.th.backgroundColor,color:t.value.table.th.color,outline:t.value.table.th.outline},td:{backgroundColor:t.value.table.td.backgroundColor,color:t.value.table.td.color,outline:t.value.table.td.outline},breakpoint:t.value.table.responsiveBreakpoint};return{colNames:[t.value.table.columnNames.series,t.value.table.columnNames.value],head:o,body:a,config:l}}),F=e.ref(!1);function oe(o){F.value=o,x.value+=1}function le(){return S.value}function L(){B.value.showTable=!B.value.showTable}return N({getData:le,generateCsv:G,generatePdf:U,generateImage:W,toggleTable:L}),(o,a)=>(e.openBlock(),e.createElementBlock("div",{class:"vue-ui-word-cloud",ref_key:"wordCloudChart",ref:g,id:`wordCloud_${w.value}`,style:e.normalizeStyle(`width: 100%; font-family:${t.value.style.fontFamily};background:${t.value.style.chart.backgroundColor};${t.value.responsive?"height:100%":""}`)},[t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:f,style:"width:100%;background:transparent;padding-bottom:24px"},[(e.openBlock(),e.createBlock(ie._sfc_main,{key:`title_${h.value}`,config:{title:{...t.value.style.chart.title},subtitle:{...t.value.style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&p.value?(e.openBlock(),e.createBlock(j.UserOptions,{ref:"details",key:`user_option_${x.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(R),isImaging:e.unref(D),uid:w.value,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:F.value,titles:{...t.value.userOptions.buttonTitles},chartElement:g.value,position:t.value.userOptions.position,onToggleFullscreen:oe,onGeneratePdf:e.unref(U),onGenerateCsv:G,onGenerateImage:e.unref(W),onToggleTable:L},e.createSlots({_:2},[o.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,o.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,o.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,o.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,o.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:c})=>[e.renderSlot(o.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:c})),void 0,!0)]),key:"4"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","isFullscreen","titles","chartElement","position","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),p.value?(e.openBlock(),e.createElementBlock("svg",{key:2,class:e.normalizeClass({"vue-data-ui-fullscreen--on":F.value,"vue-data-ui-fulscreen--off":!F.value}),xmlns:e.unref(u.XMLNS),viewBox:`0 0 ${s.value.width<=0?10:s.value.width} ${s.value.height<=0?10:s.value.height}`,style:"overflow:visible;background:transparent;"},[e.createVNode(he._sfc_main),e.createElementVNode("g",{transform:`translate(${(s.value.width<=0?10:s.value.width)/2}, ${(s.value.height<=0?10:s.value.height)/2})`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(l,c)=>(e.openBlock(),e.createElementBlock("g",null,[(e.openBlock(),e.createElementBlock("text",{fill:l.color,"font-weight":t.value.style.chart.words.bold?"bold":"normal",key:c,x:l.x,y:l.y,"font-size":l.fontSize,transform:`translate(${l.width/2}, ${l.height/2})`,style:e.normalizeStyle(`animation-delay:${c*t.value.animationDelayMs}ms !important`),class:e.normalizeClass({animated:t.value.useCssAnimation}),"text-anchor":"middle","dominant-baseline":"middle"},e.toDisplayString(l.name),15,$e))]))),256))],8,Ne),e.renderSlot(o.$slots,"svg",{svg:{height:s.value.height,width:s.value.width}},void 0,!0)],10,Se)):e.createCommentVNode("",!0),o.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Be,[e.renderSlot(o.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(R)||e.unref(D)})),void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"chartSlicer",ref:M,style:"width:100%;background:transparent","data-html2canvas-ignore":""},[t.value.style.chart.zoom.show?(e.openBlock(),e.createBlock(we,{key:0,value:v.value,"onUpdate:value":a[0]||(a[0]=l=>v.value=l),min:100,max:t.value.style.chart.width*3,textColor:t.value.style.chart.color,inputColor:t.value.style.chart.zoom.color,selectColor:t.value.style.chart.zoom.highlightColor,useResetSlot:t.value.style.chart.zoom.useResetSlot,background:t.value.style.chart.zoom.color,borderColor:t.value.style.chart.backgroundColor,source:t.value.style.chart.width,onReset:Q},{"reset-action":e.withCtx(({reset:l})=>[e.renderSlot(o.$slots,"reset-action",e.normalizeProps(e.guardReactiveProps({reset:l})),void 0,!0)]),_:3},8,["value","max","textColor","inputColor","selectColor","useResetSlot","background","borderColor","source"])):e.createCommentVNode("",!0)],512),p.value?(e.openBlock(),e.createBlock(ce.default,{key:4,hideDetails:"",config:{open:B.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:e.withCtx(()=>[(e.openBlock(),e.createBlock(de.DataTable,{key:`table_${y.value}`,colNames:_.value.colNames,head:_.value.head,body:_.value.body,config:_.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:a[1]||(a[1]=l=>B.value.showTable=!1)},{th:e.withCtx(({th:l})=>[e.createElementVNode("div",{innerHTML:l,style:{display:"flex","align-items":"center"}},null,8,Pe)]),td:e.withCtx(({td:l})=>[e.createTextVNode(e.toDisplayString(l.name||l),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],12,xe))}},Fe=Y._export_sfc(_e,[["__scopeId","data-v-e1d21ba1"]]);exports.default=Fe;
|