vue-data-ui 3.7.13 → 3.7.15

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.
Files changed (136) hide show
  1. package/dist/{PackageVersion-zsGySlBm.js → PackageVersion-BAF3mEBQ.js} +1 -1
  2. package/dist/{Title-BwhstTFA.js → Title-Hk29BxeL.js} +1 -1
  3. package/dist/components/vue-ui-3d-bar.js +1 -1
  4. package/dist/components/vue-ui-accordion.js +1 -1
  5. package/dist/components/vue-ui-age-pyramid.js +1 -1
  6. package/dist/components/vue-ui-annotator.js +1 -1
  7. package/dist/components/vue-ui-bullet.js +1 -1
  8. package/dist/components/vue-ui-candlestick.js +1 -1
  9. package/dist/components/vue-ui-carousel-table.js +1 -1
  10. package/dist/components/vue-ui-chestnut.js +1 -1
  11. package/dist/components/vue-ui-chord.js +1 -1
  12. package/dist/components/vue-ui-circle-pack.js +1 -1
  13. package/dist/components/vue-ui-cursor.js +1 -1
  14. package/dist/components/vue-ui-dashboard.js +1 -1
  15. package/dist/components/vue-ui-digits.js +1 -1
  16. package/dist/components/vue-ui-donut-evolution.js +1 -1
  17. package/dist/components/vue-ui-donut.js +1 -1
  18. package/dist/components/vue-ui-dumbbell.js +1 -1
  19. package/dist/components/vue-ui-flow.js +1 -1
  20. package/dist/components/vue-ui-funnel.js +1 -1
  21. package/dist/components/vue-ui-galaxy.js +1 -1
  22. package/dist/components/vue-ui-gauge.js +1 -1
  23. package/dist/components/vue-ui-gizmo.js +1 -1
  24. package/dist/components/vue-ui-heatmap.js +1 -1
  25. package/dist/components/vue-ui-history-plot.js +1 -1
  26. package/dist/components/vue-ui-horizontal-bar.js +1 -1
  27. package/dist/components/vue-ui-kpi.js +1 -1
  28. package/dist/components/vue-ui-mini-loader.js +1 -1
  29. package/dist/components/vue-ui-molecule.js +1 -1
  30. package/dist/components/vue-ui-mood-radar.js +1 -1
  31. package/dist/components/vue-ui-nested-donuts.js +1 -1
  32. package/dist/components/vue-ui-onion.js +1 -1
  33. package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
  34. package/dist/components/vue-ui-quadrant.js +1 -1
  35. package/dist/components/vue-ui-quick-chart.js +1 -1
  36. package/dist/components/vue-ui-radar.js +1 -1
  37. package/dist/components/vue-ui-rating.js +1 -1
  38. package/dist/components/vue-ui-relation-circle.js +1 -1
  39. package/dist/components/vue-ui-ridgeline.js +1 -1
  40. package/dist/components/vue-ui-rings.js +1 -1
  41. package/dist/components/vue-ui-scatter.js +1 -1
  42. package/dist/components/vue-ui-skeleton.js +1 -1
  43. package/dist/components/vue-ui-smiley.js +1 -1
  44. package/dist/components/vue-ui-spark-trend.js +1 -1
  45. package/dist/components/vue-ui-sparkbar.js +1 -1
  46. package/dist/components/vue-ui-sparkgauge.js +1 -1
  47. package/dist/components/vue-ui-sparkhistogram.js +1 -1
  48. package/dist/components/vue-ui-sparkline.js +1 -1
  49. package/dist/components/vue-ui-sparkstackbar.js +1 -1
  50. package/dist/components/vue-ui-stackbar.js +1 -1
  51. package/dist/components/vue-ui-stackline.js +1 -1
  52. package/dist/components/vue-ui-strip-plot.js +1 -1
  53. package/dist/components/vue-ui-table-heatmap.js +1 -1
  54. package/dist/components/vue-ui-table-sparkline.js +1 -1
  55. package/dist/components/vue-ui-table.js +1 -1
  56. package/dist/components/vue-ui-thermometer.js +1 -1
  57. package/dist/components/vue-ui-timer.js +1 -1
  58. package/dist/components/vue-ui-tiremarks.js +1 -1
  59. package/dist/components/vue-ui-treemap.js +1 -1
  60. package/dist/components/vue-ui-vertical-bar.js +1 -1
  61. package/dist/components/vue-ui-waffle.js +1 -1
  62. package/dist/components/vue-ui-wheel.js +1 -1
  63. package/dist/components/vue-ui-word-cloud.js +1 -1
  64. package/dist/components/vue-ui-world.js +1 -1
  65. package/dist/components/vue-ui-xy-canvas.js +1 -1
  66. package/dist/components/vue-ui-xy.js +1 -1
  67. package/dist/style.css +1 -1
  68. package/dist/types/vue-data-ui.d.ts +3 -0
  69. package/dist/{useNestedProp-BjZ1Lg9E.js → useNestedProp-CVGae3Qt.js} +3 -1
  70. package/dist/{vue-data-ui-CPaWiyY3.js → vue-data-ui-BcTiYl7u.js} +64 -64
  71. package/dist/vue-data-ui.js +66 -66
  72. package/dist/{vue-ui-3d-bar-DPdwp0tW.js → vue-ui-3d-bar-Cg4nzpjZ.js} +3 -3
  73. package/dist/{vue-ui-accordion-BXTVRRX7.js → vue-ui-accordion-B3SlkXqV.js} +1 -1
  74. package/dist/{vue-ui-age-pyramid-DsYHBHvF.js → vue-ui-age-pyramid-BGA_e57_.js} +3 -3
  75. package/dist/{vue-ui-annotator-CmCG1U2b.js → vue-ui-annotator-BHmNl_oD.js} +2 -2
  76. package/dist/{vue-ui-bullet-BiuF7E-n.js → vue-ui-bullet-B8Td03RZ.js} +3 -3
  77. package/dist/{vue-ui-candlestick-t7STPkfD.js → vue-ui-candlestick-aRpv_WG-.js} +3 -3
  78. package/dist/{vue-ui-carousel-table-Am8NLVs-.js → vue-ui-carousel-table-yjrmp9Q4.js} +2 -2
  79. package/dist/{vue-ui-chestnut-DC1FEP0L.js → vue-ui-chestnut-mlal6Cjv.js} +2 -2
  80. package/dist/{vue-ui-chord-BPgH9XsI.js → vue-ui-chord-Ddbwnzl7.js} +3 -3
  81. package/dist/{vue-ui-circle-pack-IlflLArc.js → vue-ui-circle-pack-DUw81Lbf.js} +3 -3
  82. package/dist/{vue-ui-cursor-4Ldkkd2T.js → vue-ui-cursor-CIynd5w9.js} +1 -1
  83. package/dist/{vue-ui-dashboard-CyEcrJCz.js → vue-ui-dashboard-BzIopzfw.js} +64 -64
  84. package/dist/{vue-ui-digits-uszbkbEK.js → vue-ui-digits-BDVx5bMH.js} +1 -1
  85. package/dist/{vue-ui-donut-DM0YRak1.js → vue-ui-donut-D-uqv9-W.js} +3 -3
  86. package/dist/{vue-ui-donut-evolution-CUibw0Im.js → vue-ui-donut-evolution-C25j-w7G.js} +3 -3
  87. package/dist/{vue-ui-dumbbell-CVqWj5VK.js → vue-ui-dumbbell-DaBN6kZz.js} +3 -3
  88. package/dist/{vue-ui-flow-BO4uT-DU.js → vue-ui-flow-LBrbktKK.js} +412 -401
  89. package/dist/{vue-ui-funnel-BWZJVfXx.js → vue-ui-funnel-StsSjaZJ.js} +3 -3
  90. package/dist/{vue-ui-galaxy-CRdR3r4Q.js → vue-ui-galaxy-DATC0Ww1.js} +3 -3
  91. package/dist/{vue-ui-gauge-RO4XMio9.js → vue-ui-gauge-BuSVuoeo.js} +3 -3
  92. package/dist/{vue-ui-gizmo-BqpM6PoW.js → vue-ui-gizmo-B4Du388h.js} +2 -2
  93. package/dist/{vue-ui-heatmap-BdQeLMap.js → vue-ui-heatmap-C7jHSpqL.js} +4 -4
  94. package/dist/{vue-ui-history-plot-CklysnQU.js → vue-ui-history-plot-CMGhB2Zv.js} +3 -3
  95. package/dist/{vue-ui-horizontal-bar-B397SpYr.js → vue-ui-horizontal-bar-BlG3kfkk.js} +4 -4
  96. package/dist/{vue-ui-kpi-Bkxvv0Re.js → vue-ui-kpi-CTUnzHcT.js} +2 -2
  97. package/dist/{vue-ui-mini-loader-oYhRTSA7.js → vue-ui-mini-loader-DYMh6g7y.js} +1 -1
  98. package/dist/{vue-ui-molecule-D4Obih-D.js → vue-ui-molecule-BNwKqzIg.js} +2 -2
  99. package/dist/{vue-ui-mood-radar-wO772Pku.js → vue-ui-mood-radar-Bpfe33cj.js} +3 -3
  100. package/dist/{vue-ui-nested-donuts-DHRk6SO9.js → vue-ui-nested-donuts-CG6vyTLr.js} +3 -3
  101. package/dist/{vue-ui-onion-D9vTzXiT.js → vue-ui-onion-BNrW85xB.js} +3 -3
  102. package/dist/{vue-ui-parallel-coordinate-plot-D99Dn9nk.js → vue-ui-parallel-coordinate-plot-prQ8DLgP.js} +3 -3
  103. package/dist/{vue-ui-quadrant-DctQGzZQ.js → vue-ui-quadrant-mFM3WtKm.js} +3 -3
  104. package/dist/{vue-ui-quick-chart-Bk7bjM8M.js → vue-ui-quick-chart-CmJEoZEj.js} +2 -2
  105. package/dist/{vue-ui-radar-DwRAsabj.js → vue-ui-radar-MheG5gvf.js} +3 -3
  106. package/dist/{vue-ui-rating-BALFx0aJ.js → vue-ui-rating-BAfHKHmb.js} +1 -1
  107. package/dist/{vue-ui-relation-circle-fy7y6GPv.js → vue-ui-relation-circle-BPZDXdVc.js} +3 -3
  108. package/dist/{vue-ui-ridgeline-C50dzhcC.js → vue-ui-ridgeline-BPDURc5t.js} +3 -3
  109. package/dist/{vue-ui-rings-B2jXOL6I.js → vue-ui-rings-ByeUycTV.js} +3 -3
  110. package/dist/{vue-ui-scatter-CHcoShcn.js → vue-ui-scatter-HkSLoM2F.js} +3 -3
  111. package/dist/{vue-ui-skeleton-BaYEbtyL.js → vue-ui-skeleton-DtciU6S2.js} +2 -2
  112. package/dist/{vue-ui-smiley-DABDSgAF.js → vue-ui-smiley-B8k0b8-R.js} +1 -1
  113. package/dist/{vue-ui-spark-trend-CypB4Wyy.js → vue-ui-spark-trend-lSw8HYoA.js} +2 -2
  114. package/dist/{vue-ui-sparkbar-i5aJjN_0.js → vue-ui-sparkbar-DZlTPWdS.js} +2 -2
  115. package/dist/{vue-ui-sparkgauge-BIDEen6a.js → vue-ui-sparkgauge-Cwl9Ksz2.js} +2 -2
  116. package/dist/{vue-ui-sparkhistogram-CL60R6m9.js → vue-ui-sparkhistogram-Bq2DS4V0.js} +2 -2
  117. package/dist/{vue-ui-sparkline-BF2_TcCq.js → vue-ui-sparkline-DbkCbelr.js} +2 -2
  118. package/dist/{vue-ui-sparkstackbar-CgGqwbA3.js → vue-ui-sparkstackbar-DWDEh2j6.js} +2 -2
  119. package/dist/{vue-ui-stackbar-Bt2yYlf8.js → vue-ui-stackbar-BhbkdK0G.js} +3 -3
  120. package/dist/{vue-ui-stackline-DPTr6LCe.js → vue-ui-stackline-DqKYCBDP.js} +3 -3
  121. package/dist/{vue-ui-strip-plot-BgO9HCwc.js → vue-ui-strip-plot-BUbyj8j8.js} +3 -3
  122. package/dist/{vue-ui-table-CxRU36jP.js → vue-ui-table-B1bx46AB.js} +3 -3
  123. package/dist/{vue-ui-table-heatmap-BHqtF71-.js → vue-ui-table-heatmap-kuly5Mc1.js} +1 -1
  124. package/dist/{vue-ui-table-sparkline-BtYeprXs.js → vue-ui-table-sparkline-B9YLMDpp.js} +2 -2
  125. package/dist/{vue-ui-thermometer-vbFd6aId.js → vue-ui-thermometer-DGM9Cnnw.js} +3 -3
  126. package/dist/{vue-ui-timer-CTWbXBwm.js → vue-ui-timer-C1uo5WJb.js} +3 -3
  127. package/dist/{vue-ui-tiremarks-BCSR4cA2.js → vue-ui-tiremarks-B-xq7Ivj.js} +3 -3
  128. package/dist/{vue-ui-treemap-Dwu0UUYT.js → vue-ui-treemap-VI1FYNqD.js} +3 -3
  129. package/dist/{vue-ui-waffle-Cis2agi-.js → vue-ui-waffle-WdacXwVf.js} +3 -3
  130. package/dist/{vue-ui-wheel-BC544dca.js → vue-ui-wheel-C7yfIwbK.js} +3 -3
  131. package/dist/vue-ui-word-cloud-BlNxODSZ.js +1419 -0
  132. package/dist/{vue-ui-world-Cs5HO9RF.js → vue-ui-world-vfrFZPI1.js} +2 -2
  133. package/dist/{vue-ui-xy-Dy8c79U3.js → vue-ui-xy-DHN5H4Ln.js} +4 -4
  134. package/dist/{vue-ui-xy-canvas-i1eQQ9Bt.js → vue-ui-xy-canvas-B3oAOFin.js} +3 -3
  135. package/package.json +1 -1
  136. package/dist/vue-ui-word-cloud-DnOpztI1.js +0 -1033
@@ -1,1033 +0,0 @@
1
- import { useCssVars as St, defineAsyncComponent as ee, computed as te, ref as h, toRefs as Tt, watch as be, shallowRef as He, onMounted as zt, onBeforeUnmount as Mt, createElementBlock as j, openBlock as S, unref as r, normalizeStyle as Te, createBlock as ce, createCommentVNode as G, createVNode as ze, withCtx as g, renderSlot as b, normalizeProps as B, guardReactiveProps as _, createSlots as Je, normalizeClass as Ke, createElementVNode as ye, Fragment as Ot, renderList as Pt, toDisplayString as Ee, resolveDynamicComponent as It, mergeProps as Dt, createTextVNode as Qe, nextTick as et } from "vue";
2
- import { d as tt, u as Et } from "./useResponsive-DfdjqQps.js";
3
- import { c as Bt, t as _t, ap as Nt, M as Rt, i as Wt, p as Me, o as ot, g as at, k as Vt, d as Xt, X as Zt, u as Yt, q as Ut, x as Lt } from "./lib-DUaaQGCv.js";
4
- import { u as jt, a as Be } from "./useNestedProp-BjZ1Lg9E.js";
5
- import { u as Gt, B as qt } from "./BaseScanner-BgWxam9d.js";
6
- import { u as Ht } from "./usePrinter-BdVu83IN.js";
7
- import { u as Jt } from "./useSvgExport-DrjCWun4.js";
8
- import { u as Kt } from "./useThemeCheck-DGJ31Vi5.js";
9
- import { u as Qt } from "./useUserOptionState-BIvW1Kz7.js";
10
- import { u as eo } from "./useChartAccessibility-9icAAmYg.js";
11
- import to from "./img-BYzbY8TZ.js";
12
- import oo from "./Title-BwhstTFA.js";
13
- import { u as ao } from "./usePanZoom-DZtyJi5q.js";
14
- import { _ as lo } from "./_plugin-vue_export-helper-CHgC5LLL.js";
15
- function no($, x) {
16
- const { width: f, height: y } = $, C = x.getImageData(0, 0, f, y).data;
17
- let d = f, c = y, l = 0, v = 0, T = !1;
18
- for (let k = 0; k < y; k += 1)
19
- for (let z = 0; z < f; z += 1)
20
- C[(k * f + z) * 4 + 3] > 1 && (T = !0, z < d && (d = z), z > l && (l = z), k < c && (c = k), k > v && (v = k));
21
- return T ? [d, c, l, v] : [0, 0, 0, 0];
22
- }
23
- function lt({
24
- word: $,
25
- fontSize: x,
26
- pad: f,
27
- canvas: y,
28
- ctx: m,
29
- svg: C
30
- }) {
31
- m.save(), m.font = `${C.style && C.style.bold ? "bold " : ""}${x}px Arial`;
32
- const d = m.measureText($.name), c = Math.ceil(d.width) + 2 + (f ? f * 2 : 0), l = Math.ceil(x) + 2 + (f ? f * 2 : 0);
33
- y.width = c, y.height = l, m.clearRect(0, 0, c, l), m.font = `${C.style && C.style.bold ? "bold " : ""}${x}px Arial`, m.textAlign = "center", m.textBaseline = "middle", m.fillStyle = "black", m.fillText($.name, c / 2, l / 2);
34
- const T = m.getImageData(0, 0, c, l).data, k = [];
35
- for (let I = 0; I < l; I += 1)
36
- for (let w = 0; w < c; w += 1)
37
- T[(I * c + w) * 4 + 3] > 1 && k.push([w, I]);
38
- const [z, F, q, J] = no(y, m);
39
- return m.restore(), { w: c, h: l, wordMask: k, minX: z, minY: F, maxX: q, maxY: J };
40
- }
41
- function nt({ mask: $, maskW: x, maskH: f, wx: y, wy: m, wordMask: C }) {
42
- for (let d = 0; d < C.length; d += 1) {
43
- const c = y + C[d][0], l = m + C[d][1];
44
- if (c < 0 || l < 0 || c >= x || l >= f || $[l * x + c]) return !1;
45
- }
46
- return !0;
47
- }
48
- function st({ mask: $, maskW: x, maskH: f, wx: y, wy: m, wordMask: C }) {
49
- for (let d = 0; d < C.length; d += 1) {
50
- const c = y + C[d][0], l = m + C[d][1];
51
- c >= 0 && l >= 0 && c < x && l < f && ($[l * x + c] = 1);
52
- }
53
- }
54
- function so({ wordMask: $, w: x, h: f, dilation: y }) {
55
- const m = new Set($.map(([d, c]) => `${d},${c}`)), C = new Set(m);
56
- for (let [d, c] of $)
57
- for (let l = -y; l <= y; l += 1)
58
- for (let v = -y; v <= y; v += 1) {
59
- if (l === 0 && v === 0) continue;
60
- const T = d + l, k = c + v;
61
- T >= 0 && T < x && k >= 0 && k < f && C.add(`${T},${k}`);
62
- }
63
- return Array.from(C).map((d) => d.split(",").map(Number));
64
- }
65
- async function ro({
66
- words: $,
67
- proximity: x = 0,
68
- svg: f,
69
- strictPixelPadding: y,
70
- onProgress: m
71
- }) {
72
- function C() {
73
- return new Promise((A) => setTimeout(A, 0));
74
- }
75
- const { width: d, height: c } = f, l = Math.round(d), v = Math.round(c), T = 1, k = f.minFontSize, z = Math.min(f.maxFontSize, 100), F = $.map((A) => A.value), q = Math.min(...F), J = Math.max(...F), I = new Uint8Array(l * v), w = document.createElement("canvas"), de = w.getContext("2d", { willReadFrequently: !0 });
76
- w.width = l, w.height = v;
77
- const Ce = 6, ke = 2, we = 2, ve = 1, K = Math.floor(l / 2), se = Math.floor(v / 2), he = [...$.map((A, D) => ({
78
- ...A,
79
- __wcIndex: D,
80
- id: A.id != null ? A.id : `${A.name}__${D}`
81
- }))].sort((A, D) => D.value - A.value), e = [];
82
- for (const A of he) {
83
- const D = e.length;
84
- let re = k;
85
- J !== q && (re = (A.value - q) / (J - q) * (z - k) + k), re = Math.max(
86
- k,
87
- Math.min(z, re)
88
- );
89
- let E = !1, N = re;
90
- for (; !E && N >= T; ) {
91
- let {
92
- w: M,
93
- h: R,
94
- wordMask: V,
95
- minX: Q,
96
- minY: oe,
97
- maxX: ae,
98
- maxY: le
99
- } = lt({
100
- word: A,
101
- fontSize: N,
102
- pad: x,
103
- canvas: w,
104
- ctx: de,
105
- svg: f
106
- });
107
- y && (V = so({ wordMask: V, w: M, h: R, dilation: 2 }));
108
- let W = 0, X = 0;
109
- for (; W < Math.max(l, v) && !E && X < 1e4; ) {
110
- for (let s = 0; s < 360; s += Ce) {
111
- X += 1;
112
- const O = Math.round(
113
- K + W * Math.cos(s * Math.PI / 180) - M / 2
114
- ), P = Math.round(
115
- se + W * Math.sin(s * Math.PI / 180) - R / 2
116
- );
117
- if (!(O < 0 || P < 0 || O + M > l || P + R > v) && nt({
118
- mask: I,
119
- maskW: l,
120
- maskH: v,
121
- wx: O,
122
- wy: P,
123
- wordMask: V
124
- })) {
125
- const { __wcIndex: Z, ...Y } = A;
126
- e.push({
127
- ...Y,
128
- x: O - l / 2,
129
- y: P - v / 2,
130
- fontSize: N,
131
- width: M,
132
- height: R,
133
- angle: 0,
134
- minX: Q,
135
- minY: oe,
136
- maxX: ae,
137
- maxY: le
138
- }), st({
139
- mask: I,
140
- maskW: l,
141
- maskH: v,
142
- wx: O,
143
- wy: P,
144
- wordMask: V
145
- }), E = !0;
146
- break;
147
- }
148
- }
149
- W += ke;
150
- }
151
- E || (N -= 1);
152
- }
153
- if (!E && N < T) {
154
- N = T;
155
- const {
156
- w: M,
157
- h: R,
158
- wordMask: V,
159
- minX: Q,
160
- minY: oe,
161
- maxX: ae,
162
- maxY: le
163
- } = lt({
164
- word: A,
165
- fontSize: N,
166
- pad: x,
167
- canvas: w,
168
- ctx: de,
169
- svg: f
170
- });
171
- let W = 0, X = 0;
172
- for (; W < Math.max(l, v) && !E && X < 25e3; ) {
173
- for (let s = 0; s < 360; s += we) {
174
- X += 1;
175
- const O = Math.round(
176
- K + W * Math.cos(s * Math.PI / 180) - M / 2
177
- ), P = Math.round(
178
- se + W * Math.sin(s * Math.PI / 180) - R / 2
179
- );
180
- if (!(O < 0 || P < 0 || O + M > l || P + R > v) && nt({
181
- mask: I,
182
- maskW: l,
183
- maskH: v,
184
- wx: O,
185
- wy: P,
186
- wordMask: V
187
- })) {
188
- const { __wcIndex: Z, ...Y } = A;
189
- e.push({
190
- ...Y,
191
- x: O - l / 2,
192
- y: P - v / 2,
193
- fontSize: N,
194
- width: M,
195
- height: R,
196
- angle: 0,
197
- minX: Q,
198
- minY: oe,
199
- maxX: ae,
200
- maxY: le
201
- }), st({
202
- mask: I,
203
- maskW: l,
204
- maskH: v,
205
- wx: O,
206
- wy: P,
207
- wordMask: V
208
- }), E = !0;
209
- break;
210
- }
211
- }
212
- W += ve;
213
- }
214
- }
215
- if (m && e.length > D) {
216
- const M = e[e.length - 1];
217
- m({ word: M, all: e });
218
- }
219
- await C();
220
- }
221
- return e.sort((A, D) => D.fontSize - A.fontSize);
222
- }
223
- const rt = { style: { chart: { backgroundColor: "#1A1A1A", color: "#CCCCCC", title: { color: "#CCCCCC", subtitle: { color: "#757575" } }, words: { selectedStroke: "#1A1A1A" }, tooltip: { backgroundColor: "#1A1A1A", backgroundOpacity: 70, color: "#CCCCCC", borderColor: "#5A5A5A" } } }, table: { th: { backgroundColor: "#1A1A1A", color: "#CCCCCC" }, td: { backgroundColor: "#1A1A1A", color: "#CCCCCC" } } }, it = { style: { chart: { backgroundColor: "#FFF8E1", color: "#424242", title: { color: "#424242", subtitle: { color: "#757575" } }, words: { selectedStroke: "#FFF8E1" }, tooltip: { backgroundColor: "#FFECB3", backgroundOpacity: 30, color: "#424242", borderColor: "#FF8A65" }, zoom: { color: "#5D4037", highlightColor: "#FF8A65" } } }, table: { th: { backgroundColor: "#FFF8E1", color: "#424242" }, td: { backgroundColor: "#FFF8E1", color: "#424242" } } }, ut = { style: { chart: { backgroundColor: "#1E1E1E", color: "#BDBDBD", title: { color: "#FFF8E1", subtitle: { color: "#BDBDBD" } }, words: { selectedStroke: "#1E1E1E" }, tooltip: { backgroundColor: "#1E1E1E", backgroundOpacity: 30, color: "#FFF8E1", borderColor: "#FF8A65" }, zoom: { color: "#5D4037", highlightColor: "#FF8A65" } } }, table: { th: { backgroundColor: "#1E1E1E", color: "#BDBDBD" }, td: { backgroundColor: "#1E1E1E", color: "#BDBDBD" } } }, ct = { style: { chart: { backgroundColor: "#1A1A1A", color: "#99AA99", title: { color: "#66CC66", subtitle: { color: "#99AA99" } }, words: { selectedStroke: "#1A1A1A" } } }, table: { th: { backgroundColor: "#1A1A1A", color: "#99AA99" }, td: { backgroundColor: "#1A1A1A", color: "#AACCAA" } } }, dt = { style: { chart: { backgroundColor: "#fbfafa", color: "#8A9892", title: { color: "#8A9892", subtitle: { color: "#99AA99" } }, words: { selectedStroke: "#fbfafa" } } }, table: { th: { backgroundColor: "#fbfafa", color: "#8F837A" }, td: { backgroundColor: "#fbfafa", color: "#8F837A" } } }, vt = { style: { chart: { backgroundColor: "#f6f6fb", color: "#50606C", title: { color: "#50606C", subtitle: { color: "#718890" } }, words: { selectedStroke: "#f6f6fb" } } }, table: { th: { backgroundColor: "#f6f6fb", color: "#50606C" }, td: { backgroundColor: "#f6f6fb", color: "#50606C" } } }, ht = {
224
- default: {},
225
- dark: rt,
226
- celebration: it,
227
- celebrationNight: ut,
228
- hack: ct,
229
- zen: dt,
230
- concrete: vt
231
- }, Eo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
232
- __proto__: null,
233
- celebration: it,
234
- celebrationNight: ut,
235
- concrete: vt,
236
- dark: rt,
237
- default: ht,
238
- hack: ct,
239
- zen: dt
240
- }, Symbol.toStringTag, { value: "Module" })), io = ["id", "data-resizing", "data-relayout"], uo = ["xmlns", "viewBox"], co = ["width", "height"], vo = ["transform"], ho = ["transform"], mo = ["x", "y", "width", "height", "onMouseover", "onMouseleave", "onClick"], fo = ["fill", "font-weight", "font-size", "transform", "stroke", "stroke-width"], po = {
241
- key: 3,
242
- class: "vue-data-ui-watermark"
243
- }, go = {
244
- key: 4,
245
- "data-dom-to-png-ignore": "",
246
- class: "reset-wrapper"
247
- }, bo = ["innerHTML"], yo = {
248
- __name: "vue-ui-word-cloud",
249
- props: {
250
- config: {
251
- type: Object,
252
- default() {
253
- return {};
254
- }
255
- },
256
- dataset: {
257
- type: [Array, String],
258
- default() {
259
- return [];
260
- }
261
- }
262
- },
263
- setup($, { expose: x }) {
264
- St((t) => ({
265
- v6142108c: t.slicerColor
266
- }));
267
- const f = ee(() => import("./Tooltip-De7i-i20.js")), y = ee(() => import("./BaseIcon-Dl4VBlHV.js")), m = ee(() => import("./vue-ui-accordion-BXTVRRX7.js")), C = ee(() => import("./DataTable-Ho3Bf5oq.js")), d = ee(() => import("./PenAndPaper-kymjF6_b.js")), c = ee(() => import("./UserOptions-DgscxIaa.js")), l = ee(() => import("./PackageVersion-zsGySlBm.js")), v = ee(() => import("./BaseDraggableDialog-DZVSjhEw.js")), { vue_ui_word_cloud: T } = jt(), { isThemeValid: k, warnInvalidTheme: z } = Kt(), F = $, q = te({
268
- get() {
269
- return !!F.dataset && F.dataset.length;
270
- },
271
- set(t) {
272
- return t;
273
- }
274
- }), J = h(Bt()), I = h(0), w = h(null), de = h(null), Ce = h(null), ke = h(0), we = h(0), ve = h(!1), K = h(null), se = h(null), Ae = h(!1), he = h(!1), e = h(oe()), { loading: A, FINAL_DATASET: D, manualLoading: re } = Gt({
275
- ...Tt(F),
276
- FINAL_CONFIG: e,
277
- prepareConfig: oe,
278
- callback: () => {
279
- Promise.resolve().then(() => {
280
- p.value.showTable = e.value.table.show, p.value.showTooltip = e.value.style.chart.tooltip.show, p.value.showZoom = e.value.style.chart.zoom.show;
281
- });
282
- },
283
- skeletonDataset: [
284
- { name: "Lorem", value: 6 },
285
- { name: "ipsum", value: 3 },
286
- { name: "dolor", value: 1 },
287
- { name: "sit", value: 3 },
288
- { name: "amet", value: 3 },
289
- { name: "consectetur", value: 2 },
290
- { name: "adipiscing", value: 1 },
291
- { name: "elit", value: 2 },
292
- { name: "Vivamus", value: 2 },
293
- { name: "pulvinar", value: 1 },
294
- { name: "pretium", value: 1 },
295
- { name: "venenatis", value: 2 },
296
- { name: "Donec", value: 1 },
297
- { name: "imperdiet", value: 3 },
298
- { name: "id", value: 1 },
299
- { name: "porttitor", value: 2 },
300
- { name: "tristique", value: 1 },
301
- { name: "Aenean", value: 2 },
302
- { name: "ac", value: 5 },
303
- { name: "commodo", value: 2 },
304
- { name: "justo", value: 2 },
305
- { name: "Vestibulum", value: 2 },
306
- { name: "placerat", value: 1 },
307
- { name: "molestie", value: 1 },
308
- { name: "nisl", value: 1 },
309
- { name: "lacinia", value: 2 },
310
- { name: "nulla", value: 1 },
311
- { name: "posuere", value: 2 },
312
- { name: "quis", value: 3 },
313
- { name: "ullamcorper", value: 1 },
314
- { name: "eu", value: 1 },
315
- { name: "ex", value: 1 },
316
- { name: "vitae", value: 3 },
317
- { name: "facilisis", value: 1 },
318
- { name: "Aliquam", value: 1 },
319
- { name: "erat", value: 1 },
320
- { name: "volutpat", value: 1 },
321
- { name: "Proin", value: 1 },
322
- { name: "nunc", value: 1 },
323
- { name: "felis", value: 1 },
324
- { name: "gravida", value: 3 },
325
- { name: "sed", value: 1 },
326
- { name: "orci", value: 1 },
327
- { name: "Interdum", value: 1 },
328
- { name: "et", value: 1 },
329
- { name: "malesuada", value: 1 },
330
- { name: "fames", value: 1 },
331
- { name: "ante", value: 1 }
332
- ],
333
- skeletonConfig: _t({
334
- defaultConfig: e.value,
335
- userConfig: {
336
- userOptions: { show: !1 },
337
- table: { show: !1 },
338
- useCssAnimation: !1,
339
- animationDelayMs: 0,
340
- nodeCategories: {},
341
- nodeCategoryColors: {},
342
- style: {
343
- chart: {
344
- backgroundColor: "#99999930",
345
- words: {
346
- color: "#6A6A6A",
347
- usePalette: !1,
348
- selectedStroke: "#CCCCCC"
349
- }
350
- }
351
- }
352
- }
353
- })
354
- }), E = h(N());
355
- function N() {
356
- return typeof D.value == "string" ? Nt(D.value) : D.value.map((t, a) => ({
357
- ...t,
358
- value: Rt(t.value)
359
- }));
360
- }
361
- const { userOptionsVisible: M, setUserOptionsVisibility: R, keepUserOptionState: V } = Qt({ config: e.value }), { svgRef: Q } = eo({ config: e.value.style.chart.title });
362
- function oe() {
363
- const t = Be({
364
- userConfig: F.config,
365
- defaultConfig: T
366
- }), a = t.theme;
367
- if (!a) return t;
368
- if (!k.value(t))
369
- return z(t), t;
370
- const o = Be({
371
- userConfig: ht[a] || F.config,
372
- defaultConfig: t
373
- }), n = Be({
374
- userConfig: F.config,
375
- defaultConfig: o
376
- });
377
- return {
378
- ...n,
379
- customPalette: n.customPalette.length ? n.customPalette : Wt[a] || Me
380
- };
381
- }
382
- const ae = h({ x: 0, y: 0 });
383
- function le() {
384
- const t = {
385
- x: 0,
386
- y: 0,
387
- width: Math.max(10, s.value.width),
388
- height: Math.max(10, s.value.height)
389
- };
390
- bt(t), ae.value = {
391
- x: t.x + t.width / 2,
392
- y: t.y + t.height / 2
393
- }, Se();
394
- }
395
- const W = tt(() => {
396
- Ze();
397
- }, 100), X = h(!1);
398
- be(() => X.value, (t) => {
399
- t === !1 && (he.value = !0, W(), le());
400
- }), be(() => F.config, (t) => {
401
- e.value = oe(), M.value = !e.value.userOptions.showOnChartHover, Ne(), ke.value += 1, we.value += 1, p.value.showTable = e.value.table.show, p.value.showTooltip = e.value.style.chart.tooltip.show, p.value.showZoom = e.value.style.chart.zoom.show;
402
- }, { deep: !0 });
403
- const s = h({
404
- width: e.value.style.chart.width,
405
- height: e.value.style.chart.height,
406
- maxFontSize: e.value.style.chart.words.maxFontSize,
407
- minFontSize: e.value.style.chart.words.minFontSize,
408
- bold: e.value.style.chart.words.bold
409
- }), O = tt(() => {
410
- const { width: t, height: a } = Et({
411
- chart: w.value,
412
- title: e.value.style.chart.title.text ? de.value : null,
413
- source: Ce.value
414
- });
415
- requestAnimationFrame(async () => {
416
- s.value.width = Math.max(10, t), s.value.height = Math.max(10, a - 12), await et(), X.value = !1;
417
- });
418
- }, 100), P = () => {
419
- X.value = !0, O();
420
- }, Z = He(null), Y = He(null);
421
- zt(Ne);
422
- const _e = te(() => !!e.value.debug);
423
- function Ne() {
424
- ot(F.dataset) ? at({
425
- componentName: "VueUiWordCloud",
426
- type: "dataset",
427
- debug: _e.value
428
- }) : E.value.forEach((t, a) => {
429
- Vt({
430
- datasetObject: t,
431
- requiredAttributes: ["name", "value"]
432
- }).forEach((o) => {
433
- q.value = !1, at({
434
- componentName: "VueUiWordCloud",
435
- type: "datasetSerieAttribute",
436
- property: o,
437
- index: a,
438
- debug: _e.value
439
- });
440
- });
441
- }), ot(F.dataset) || (re.value = e.value.loading), e.value.responsive && (Z.value && (Y.value && Z.value.unobserve(Y.value), Z.value.disconnect()), Z.value = new ResizeObserver(P), Y.value = w.value.parentNode, Z.value.observe(Y.value)), le();
442
- }
443
- Mt(() => {
444
- Z.value && (Y.value && Z.value.unobserve(Y.value), Z.value.disconnect());
445
- });
446
- const { isPrinting: Re, isImaging: We, generatePdf: Ve, generateImage: Xe } = Ht({
447
- elementId: `wordCloud_${J.value}`,
448
- fileName: e.value.style.chart.title.text || "vue-ui-word-cloud",
449
- options: e.value.userOptions.print
450
- }), p = h({
451
- showTable: e.value.table.show,
452
- showTooltip: e.value.style.chart.tooltip.show,
453
- showZoom: e.value.style.chart.zoom.show
454
- });
455
- be(e, () => {
456
- p.value.showTable = e.value.table.show, p.value.showTooltip = e.value.style.chart.tooltip.show, p.value.showZoom = e.value.style.chart.zoom.show;
457
- }, { immediate: !0 });
458
- function mt(t, a, o = "Arial") {
459
- const i = document.createElement("canvas").getContext("2d");
460
- return i.font = `${a}px ${e.value.style.chart.words.bold ? "bold" : "normal"} ${o}`, {
461
- width: i.measureText(t).width + e.value.style.chart.words.proximity,
462
- height: a
463
- };
464
- }
465
- const U = h([]), me = /* @__PURE__ */ new Map();
466
- function Ze() {
467
- const t = [...E.value].map((i) => i.value), a = Math.max(...t), o = Math.min(...t), n = [...E.value].map((i, u) => {
468
- let L = (i.value - o) / (a - o) * (s.value.maxFontSize - s.value.minFontSize) + s.value.minFontSize;
469
- L = isNaN(L) ? s.value.minFontSize : L;
470
- const ne = mt(i.name, L);
471
- return {
472
- ...i,
473
- id: i.id ?? `${i.name}__${u}`,
474
- fontSize: L,
475
- width: ne.width,
476
- height: ne.height,
477
- color: e.value.style.chart.words.usePalette ? e.value.customPalette[u] || e.value.customPalette[u % e.value.customPalette.length] || Me[u] || Me[u % Me.length] : e.value.style.chart.words.color
478
- };
479
- });
480
- U.value.length = 0, me.clear(), ro({
481
- words: n,
482
- svg: s.value,
483
- proximity: e.value.style.chart.words.proximity,
484
- strictPixelPadding: e.value.strictPixelPadding,
485
- onProgress: ({ all: i }) => {
486
- for (const u of i) {
487
- const L = u.id;
488
- let ne = me.get(L);
489
- if (ne === void 0)
490
- ne = U.value.length, me.set(L, ne), U.value.push({ ...u });
491
- else {
492
- const H = U.value[ne];
493
- H.x = u.x, H.y = u.y, H.width = u.width, H.height = u.height, H.fontSize = u.fontSize, H.minX = u.minX, H.minY = u.minY, H.maxX = u.maxX, H.maxY = u.maxY;
494
- }
495
- }
496
- }
497
- }), U.value.sort((i, u) => u.fontSize - i.fontSize), me.clear(), U.value.forEach((i, u) => {
498
- me.set(i.id, u);
499
- }), Ae.value = !0, he.value = !1;
500
- }
501
- const xe = te(() => {
502
- const t = U.value.map((o) => ({
503
- name: o.name,
504
- color: o.color
505
- })), a = U.value.map((o) => o.value);
506
- return { head: t, body: a };
507
- });
508
- function Oe(t = null) {
509
- et(() => {
510
- const a = xe.value.head.map((i, u) => [[
511
- i.name
512
- ], [xe.value.body[u]]]), o = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], [e.value.table.columnNames.value]]].concat(a), n = Yt(o);
513
- t ? t(n) : Ut({ csvContent: n, title: e.value.style.chart.title.text || "vue-ui-word-cloud" });
514
- });
515
- }
516
- const $e = te(() => {
517
- const t = [
518
- e.value.table.columnNames.series,
519
- e.value.table.columnNames.value
520
- ], a = xe.value.head.map((i, u) => {
521
- const L = Xt({ p: e.value.table.td.prefix, v: xe.value.body[u], s: e.value.table.td.suffix, r: e.value.table.td.roundingValue });
522
- return [
523
- {
524
- color: i.color,
525
- name: i.name
526
- },
527
- L
528
- ];
529
- }), o = {
530
- th: {
531
- backgroundColor: e.value.table.th.backgroundColor,
532
- color: e.value.table.th.color,
533
- outline: e.value.table.th.outline
534
- },
535
- td: {
536
- backgroundColor: e.value.table.td.backgroundColor,
537
- color: e.value.table.td.color,
538
- outline: e.value.table.td.outline
539
- },
540
- breakpoint: e.value.table.responsiveBreakpoint
541
- };
542
- return {
543
- colNames: [
544
- e.value.table.columnNames.series,
545
- e.value.table.columnNames.value
546
- ],
547
- head: t,
548
- body: a,
549
- config: o
550
- };
551
- }), ie = h(!1);
552
- function Ye(t) {
553
- ie.value = t, I.value += 1;
554
- }
555
- function ft() {
556
- return U.value;
557
- }
558
- function Ue() {
559
- p.value.showTable = !p.value.showTable;
560
- }
561
- function Le() {
562
- p.value.showTooltip = !p.value.showTooltip;
563
- }
564
- const fe = h(!1);
565
- function Pe() {
566
- fe.value = !fe.value;
567
- }
568
- function je() {
569
- p.value.showZoom = !p.value.showZoom;
570
- }
571
- const pt = te(() => !fe.value && p.value.showZoom), { viewBox: Fe, resetZoom: Se, isZoom: gt, setInitialViewBox: bt } = ao(Q, {
572
- x: 0,
573
- y: 0,
574
- width: s.value.width <= 0 ? 10 : s.value.width,
575
- height: s.value.height <= 0 ? 10 : s.value.height
576
- }, 1, pt);
577
- be(() => F.dataset, () => {
578
- E.value = N(), e.value.responsive || (Ze(), le());
579
- }, { immediate: !0 });
580
- async function yt({ scale: t = 2 } = {}) {
581
- if (!w.value) return;
582
- const { width: a, height: o } = w.value.getBoundingClientRect(), n = a / o, { imageUri: i, base64: u } = await to({ domElement: w.value, base64: !0, img: !0, scale: t });
583
- return {
584
- imageUri: i,
585
- base64: u,
586
- title: e.value.style.chart.title.text,
587
- width: a,
588
- height: o,
589
- aspectRatio: n
590
- };
591
- }
592
- const pe = te(() => {
593
- const t = e.value.table.useDialog && !e.value.table.show, a = p.value.showTable;
594
- return {
595
- component: t ? v : m,
596
- title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? `: ${e.value.style.chart.title.subtitle.text}` : ""}`,
597
- props: t ? {
598
- backgroundColor: e.value.table.th.backgroundColor,
599
- color: e.value.table.th.color,
600
- headerColor: e.value.table.th.color,
601
- headerBg: e.value.table.th.backgroundColor,
602
- isFullscreen: ie.value,
603
- fullscreenParent: w.value,
604
- forcedWidth: Math.min(500, window.innerWidth * 0.8)
605
- } : {
606
- hideDetails: !0,
607
- config: {
608
- open: a,
609
- maxHeight: 1e4,
610
- body: {
611
- backgroundColor: e.value.style.chart.backgroundColor,
612
- color: e.value.style.chart.color
613
- },
614
- head: {
615
- backgroundColor: e.value.style.chart.backgroundColor,
616
- color: e.value.style.chart.color
617
- }
618
- }
619
- }
620
- };
621
- });
622
- be(() => p.value.showTable, (t) => {
623
- e.value.table.show || (t && e.value.table.useDialog && K.value ? K.value.open() : "close" in K.value && K.value.close());
624
- });
625
- function Ge() {
626
- p.value.showTable = !1, se.value && se.value.setTableIconState(!1);
627
- }
628
- const Ct = te(() => e.value.style.chart.backgroundColor), kt = te(() => e.value.style.chart.title), { exportSvg: wt, getSvg: At } = Jt({
629
- svg: Q,
630
- title: kt,
631
- backgroundColor: Ct
632
- });
633
- async function qe({ isCb: t }) {
634
- if (t) {
635
- const { blob: a, url: o, text: n, dataUrl: i } = await At();
636
- e.value.userOptions.callbacks.svg({ blob: a, url: o, text: n, dataUrl: i });
637
- } else
638
- wt();
639
- }
640
- x({
641
- getData: ft,
642
- getImage: yt,
643
- generateCsv: Oe,
644
- generatePdf: Ve,
645
- generateImage: Xe,
646
- generateSvg: qe,
647
- resetZoom: Se,
648
- toggleTable: Ue,
649
- toggleTooltip: Le,
650
- toggleAnnotator: Pe,
651
- toggleFullscreen: Ye,
652
- toggleZoom: je
653
- });
654
- const ue = h(null), ge = h(!1), Ie = h(""), De = h(null);
655
- function xt(t, a) {
656
- ue.value = null, ve.value = !1, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: a });
657
- }
658
- function $t(t, a) {
659
- e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: a });
660
- }
661
- function Ft(t, a) {
662
- if (e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: a }), !p.value.showTooltip) return;
663
- ue.value = t.id, De.value = { datapoint: t, config: e.value };
664
- const o = e.value.style.chart.tooltip.customFormat;
665
- if (ge.value = !1, Lt(o))
666
- try {
667
- const n = o({
668
- datapoint: t,
669
- config: e.value
670
- });
671
- typeof n == "string" && (Ie.value = n, ge.value = !0);
672
- } catch {
673
- console.warn("Custom format cannot be applied."), ge.value = !1;
674
- }
675
- if (!ge.value) {
676
- let n = `<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>`;
677
- Ie.value = `<div dir="auto" style="display:flex; gap:4px; align-items:center; jsutify-content:center;">${n}</div>`;
678
- }
679
- ve.value = !0;
680
- }
681
- return (t, a) => (S(), j("div", {
682
- class: "vue-data-ui-component vue-ui-word-cloud",
683
- ref_key: "wordCloudChart",
684
- ref: w,
685
- id: `wordCloud_${J.value}`,
686
- "data-resizing": X.value,
687
- "data-relayout": he.value,
688
- style: Te(`width: 100%; font-family:${e.value.style.fontFamily};background:${e.value.style.chart.backgroundColor};${e.value.responsive ? "height:100%" : ""}`),
689
- onMouseenter: a[2] || (a[2] = () => r(R)(!0)),
690
- onMouseleave: a[3] || (a[3] = () => r(R)(!1))
691
- }, [
692
- e.value.userOptions.buttons.annotator ? (S(), ce(r(d), {
693
- key: 0,
694
- svgRef: r(Q),
695
- backgroundColor: e.value.style.chart.backgroundColor,
696
- color: e.value.style.chart.color,
697
- active: fe.value,
698
- onClose: Pe
699
- }, {
700
- "annotator-action-close": g(() => [
701
- b(t.$slots, "annotator-action-close", {}, void 0, !0)
702
- ]),
703
- "annotator-action-color": g(({ color: o }) => [
704
- b(t.$slots, "annotator-action-color", B(_({ color: o })), void 0, !0)
705
- ]),
706
- "annotator-action-draw": g(({ mode: o }) => [
707
- b(t.$slots, "annotator-action-draw", B(_({ mode: o })), void 0, !0)
708
- ]),
709
- "annotator-action-undo": g(({ disabled: o }) => [
710
- b(t.$slots, "annotator-action-undo", B(_({ disabled: o })), void 0, !0)
711
- ]),
712
- "annotator-action-redo": g(({ disabled: o }) => [
713
- b(t.$slots, "annotator-action-redo", B(_({ disabled: o })), void 0, !0)
714
- ]),
715
- "annotator-action-delete": g(({ disabled: o }) => [
716
- b(t.$slots, "annotator-action-delete", B(_({ disabled: o })), void 0, !0)
717
- ]),
718
- _: 3
719
- }, 8, ["svgRef", "backgroundColor", "color", "active"])) : G("", !0),
720
- e.value.style.chart.title.text ? (S(), j("div", {
721
- key: 1,
722
- ref_key: "chartTitle",
723
- ref: de,
724
- style: "width:100%;background:transparent;padding-bottom:24px"
725
- }, [
726
- (S(), ce(oo, {
727
- key: `title_${ke.value}`,
728
- config: {
729
- title: {
730
- ...e.value.style.chart.title
731
- },
732
- subtitle: {
733
- ...e.value.style.chart.title.subtitle
734
- }
735
- }
736
- }, null, 8, ["config"]))
737
- ], 512)) : G("", !0),
738
- e.value.userOptions.show && q.value && (r(V) || r(M)) ? (S(), ce(r(c), {
739
- ref_key: "userOptionsRef",
740
- ref: se,
741
- key: `user_option_${I.value}`,
742
- backgroundColor: e.value.style.chart.backgroundColor,
743
- color: e.value.style.chart.color,
744
- isPrinting: r(Re),
745
- isImaging: r(We),
746
- uid: J.value,
747
- hasPdf: e.value.userOptions.buttons.pdf,
748
- hasXls: e.value.userOptions.buttons.csv,
749
- hasImg: e.value.userOptions.buttons.img,
750
- hasSvg: e.value.userOptions.buttons.svg,
751
- hasTable: e.value.userOptions.buttons.table,
752
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
753
- isFullscreen: ie.value,
754
- titles: { ...e.value.userOptions.buttonTitles },
755
- chartElement: w.value,
756
- position: e.value.userOptions.position,
757
- hasTooltip: e.value.style.chart.tooltip.show && e.value.userOptions.buttons.tooltip,
758
- isTooltip: p.value.showTooltip,
759
- hasAnnotator: e.value.userOptions.buttons.annotator,
760
- isAnnotation: fe.value,
761
- callbacks: e.value.userOptions.callbacks,
762
- printScale: e.value.userOptions.print.scale,
763
- tableDialog: e.value.table.useDialog,
764
- hasZoom: e.value.userOptions.buttons.zoom,
765
- isZoom: p.value.showZoom,
766
- onToggleFullscreen: Ye,
767
- onGeneratePdf: r(Ve),
768
- onGenerateCsv: Oe,
769
- onGenerateImage: r(Xe),
770
- onGenerateSvg: qe,
771
- onToggleTable: Ue,
772
- onToggleTooltip: Le,
773
- onToggleAnnotator: Pe,
774
- onToggleZoom: je,
775
- style: Te({
776
- visibility: r(V) ? r(M) ? "visible" : "hidden" : "visible"
777
- })
778
- }, Je({ _: 2 }, [
779
- t.$slots.menuIcon ? {
780
- name: "menuIcon",
781
- fn: g(({ isOpen: o, color: n }) => [
782
- b(t.$slots, "menuIcon", B(_({ isOpen: o, color: n })), void 0, !0)
783
- ]),
784
- key: "0"
785
- } : void 0,
786
- t.$slots.optionPdf ? {
787
- name: "optionPdf",
788
- fn: g(() => [
789
- b(t.$slots, "optionPdf", {}, void 0, !0)
790
- ]),
791
- key: "1"
792
- } : void 0,
793
- t.$slots.optionCsv ? {
794
- name: "optionCsv",
795
- fn: g(() => [
796
- b(t.$slots, "optionCsv", {}, void 0, !0)
797
- ]),
798
- key: "2"
799
- } : void 0,
800
- t.$slots.optionImg ? {
801
- name: "optionImg",
802
- fn: g(() => [
803
- b(t.$slots, "optionImg", {}, void 0, !0)
804
- ]),
805
- key: "3"
806
- } : void 0,
807
- t.$slots.optionSvg ? {
808
- name: "optionSvg",
809
- fn: g(() => [
810
- b(t.$slots, "optionSvg", {}, void 0, !0)
811
- ]),
812
- key: "4"
813
- } : void 0,
814
- t.$slots.optionTable ? {
815
- name: "optionTable",
816
- fn: g(() => [
817
- b(t.$slots, "optionTable", {}, void 0, !0)
818
- ]),
819
- key: "5"
820
- } : void 0,
821
- t.$slots.optionFullscreen ? {
822
- name: "optionFullscreen",
823
- fn: g(({ toggleFullscreen: o, isFullscreen: n }) => [
824
- b(t.$slots, "optionFullscreen", B(_({ toggleFullscreen: o, isFullscreen: n })), void 0, !0)
825
- ]),
826
- key: "6"
827
- } : void 0,
828
- t.$slots.optionAnnotator ? {
829
- name: "optionAnnotator",
830
- fn: g(({ toggleAnnotator: o, isAnnotator: n }) => [
831
- b(t.$slots, "optionAnnotator", B(_({ toggleAnnotator: o, isAnnotator: n })), void 0, !0)
832
- ]),
833
- key: "7"
834
- } : void 0,
835
- t.$slots.optionZoom ? {
836
- name: "optionZoom",
837
- fn: g(({ toggleZoom: o, isZoomLocked: n }) => [
838
- b(t.$slots, "optionZoom", B(_({ toggleZoom: o, isZoomLocked: n })), void 0, !0)
839
- ]),
840
- key: "8"
841
- } : void 0
842
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasSvg", "hasTable", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "hasTooltip", "isTooltip", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "tableDialog", "hasZoom", "isZoom", "onGeneratePdf", "onGenerateImage", "style"])) : G("", !0),
843
- (S(), j("svg", {
844
- ref_key: "svgRef",
845
- ref: Q,
846
- class: Ke({ "vue-data-ui-fullscreen--on": ie.value, "vue-data-ui-fulscreen--off": !ie.value }),
847
- xmlns: r(Zt),
848
- viewBox: `${r(Fe).x} ${r(Fe).y} ${r(Fe).width} ${r(Fe).height}`,
849
- style: "overflow:hidden;background:transparent;"
850
- }, [
851
- ze(r(l)),
852
- t.$slots["chart-background"] ? (S(), j("foreignObject", {
853
- key: 0,
854
- x: 0,
855
- y: 0,
856
- width: s.value.width <= 0 ? 10 : s.value.width,
857
- height: s.value.height <= 0 ? 10 : s.value.height,
858
- style: {
859
- pointerEvents: "none"
860
- }
861
- }, [
862
- b(t.$slots, "chart-background", {}, void 0, !0)
863
- ], 8, co)) : G("", !0),
864
- ye("g", {
865
- transform: `translate(${ae.value.x}, ${ae.value.y})`,
866
- class: Ke({ "wc-finalized": Ae.value })
867
- }, [
868
- (S(!0), j(Ot, null, Pt(U.value, (o, n) => (S(), j("g", {
869
- key: o.id,
870
- class: "vue-ui-word-cloud-word",
871
- transform: `translate(${o.x}, ${o.y})`
872
- }, [
873
- o.minX !== void 0 ? (S(), j("rect", {
874
- key: 0,
875
- x: o.minX,
876
- y: o.minY * 1.25,
877
- width: o.maxX - o.minX,
878
- height: o.maxY - o.minY,
879
- fill: "transparent",
880
- "pointer-events": "visiblePainted",
881
- onMouseover: (i) => Ft(o, n),
882
- onMouseleave: (i) => xt(o, n),
883
- onClick: (i) => $t(o, n)
884
- }, null, 40, mo)) : G("", !0),
885
- ye("text", {
886
- fill: o.color,
887
- "font-weight": e.value.style.chart.words.bold ? "bold" : "normal",
888
- x: 0,
889
- y: 0,
890
- "font-size": o.fontSize,
891
- transform: `translate(${o.width / 2}, ${o.height / 2})`,
892
- "text-anchor": "middle",
893
- "dominant-baseline": "central",
894
- "paint-order": "stroke fill",
895
- stroke: !ue.value || ue.value === o.id ? e.value.style.chart.words.selectedStroke : void 0,
896
- "stroke-width": o.height * 0.05,
897
- "stroke-linecap": "round",
898
- "stroke-linejoin": "round",
899
- style: Te(`
900
- pointer-events:none;
901
- fill-opacity:${!ue.value || ue.value === o.id || !Ae.value ? 1 : e.value.style.chart.words.hoverOpacity} !important;
902
- `)
903
- }, Ee(o.name), 13, fo)
904
- ], 8, ho))), 128))
905
- ], 10, vo),
906
- b(t.$slots, "svg", {
907
- svg: { height: s.value.height, width: s.value.width }
908
- }, void 0, !0)
909
- ], 10, uo)),
910
- t.$slots.watermark ? (S(), j("div", po, [
911
- b(t.$slots, "watermark", B(_({ isPrinting: r(Re) || r(We) })), void 0, !0)
912
- ])) : G("", !0),
913
- r(gt) ? (S(), j("div", go, [
914
- b(t.$slots, "reset-action", { reset: r(Se) }, () => [
915
- ye("button", {
916
- "data-cy-reset": "",
917
- tabindex: "0",
918
- role: "button",
919
- class: "vue-data-ui-refresh-button",
920
- style: Te({
921
- background: e.value.style.chart.backgroundColor
922
- }),
923
- onClick: a[0] || (a[0] = (o) => r(Se)(!0))
924
- }, [
925
- ze(r(y), {
926
- name: "refresh",
927
- stroke: e.value.style.chart.color
928
- }, null, 8, ["stroke"])
929
- ], 4)
930
- ], !0)
931
- ])) : G("", !0),
932
- ze(r(f), {
933
- show: p.value.showTooltip && ve.value,
934
- backgroundColor: e.value.style.chart.tooltip.backgroundColor,
935
- color: e.value.style.chart.tooltip.color,
936
- fontSize: e.value.style.chart.tooltip.fontSize,
937
- borderRadius: e.value.style.chart.tooltip.borderRadius,
938
- borderColor: e.value.style.chart.tooltip.borderColor,
939
- borderWidth: e.value.style.chart.tooltip.borderWidth,
940
- backgroundOpacity: e.value.style.chart.tooltip.backgroundOpacity,
941
- position: e.value.style.chart.tooltip.position,
942
- offsetY: e.value.style.chart.tooltip.offsetY,
943
- parent: w.value,
944
- content: Ie.value,
945
- isCustom: ge.value,
946
- isFullscreen: ie.value,
947
- smooth: e.value.style.chart.tooltip.smooth,
948
- backdropFilter: e.value.style.chart.tooltip.backdropFilter,
949
- smoothForce: e.value.style.chart.tooltip.smoothForce,
950
- smoothSnapThreshold: e.value.style.chart.tooltip.smoothSnapThreshold
951
- }, {
952
- "tooltip-before": g(() => [
953
- b(t.$slots, "tooltip-before", B(_({ ...De.value })), void 0, !0)
954
- ]),
955
- "tooltip-after": g(() => [
956
- b(t.$slots, "tooltip-after", B(_({ ...De.value })), void 0, !0)
957
- ]),
958
- _: 3
959
- }, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "position", "offsetY", "parent", "content", "isCustom", "isFullscreen", "smooth", "backdropFilter", "smoothForce", "smoothSnapThreshold"]),
960
- t.$slots.source ? (S(), j("div", {
961
- key: 5,
962
- ref_key: "source",
963
- ref: Ce,
964
- dir: "auto"
965
- }, [
966
- b(t.$slots, "source", {}, void 0, !0)
967
- ], 512)) : G("", !0),
968
- q.value && e.value.userOptions.buttons.table ? (S(), ce(It(pe.value.component), Dt({ key: 6 }, pe.value.props, {
969
- ref_key: "tableUnit",
970
- ref: K,
971
- onClose: Ge
972
- }), Je({
973
- content: g(() => [
974
- (S(), ce(r(C), {
975
- key: `table_${we.value}`,
976
- colNames: $e.value.colNames,
977
- head: $e.value.head,
978
- body: $e.value.body,
979
- config: $e.value.config,
980
- title: e.value.table.useDialog ? "" : pe.value.title,
981
- withCloseButton: !e.value.table.useDialog,
982
- onClose: Ge
983
- }, {
984
- th: g(({ th: o }) => [
985
- ye("div", {
986
- innerHTML: o,
987
- style: { display: "flex", "align-items": "center" }
988
- }, null, 8, bo)
989
- ]),
990
- td: g(({ td: o }) => [
991
- Qe(Ee(o.name || o), 1)
992
- ]),
993
- _: 1
994
- }, 8, ["colNames", "head", "body", "config", "title", "withCloseButton"]))
995
- ]),
996
- _: 2
997
- }, [
998
- e.value.table.useDialog ? {
999
- name: "title",
1000
- fn: g(() => [
1001
- Qe(Ee(pe.value.title), 1)
1002
- ]),
1003
- key: "0"
1004
- } : void 0,
1005
- e.value.table.useDialog ? {
1006
- name: "actions",
1007
- fn: g(() => [
1008
- ye("button", {
1009
- tabindex: "0",
1010
- class: "vue-ui-user-options-button",
1011
- onClick: a[1] || (a[1] = (o) => Oe(e.value.userOptions.callbacks.csv))
1012
- }, [
1013
- ze(r(y), {
1014
- name: "excel",
1015
- stroke: pe.value.props.color
1016
- }, null, 8, ["stroke"])
1017
- ])
1018
- ]),
1019
- key: "1"
1020
- } : void 0
1021
- ]), 1040)) : G("", !0),
1022
- r(A) ? (S(), ce(qt, { key: 7 })) : G("", !0)
1023
- ], 44, io));
1024
- }
1025
- }, Co = /* @__PURE__ */ lo(yo, [["__scopeId", "data-v-7164e284"]]), Bo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1026
- __proto__: null,
1027
- default: Co
1028
- }, Symbol.toStringTag, { value: "Module" }));
1029
- export {
1030
- Eo as a,
1031
- Bo as b,
1032
- Co as v
1033
- };