vue-data-ui 2.4.7 → 2.4.8
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 +11 -10
- package/dist/{Arrow-Ds1Mhkkt.cjs → Arrow-CyaIC3_N.cjs} +1 -1
- package/dist/{Arrow-BCeetU2P.js → Arrow-csGlRFph.js} +1 -1
- package/dist/{BaseIcon-Icg3SIlH.js → BaseIcon-C4xMR9-8.js} +1 -1
- package/dist/{BaseIcon-C31iTAGj.cjs → BaseIcon-fwPMcivX.cjs} +1 -1
- package/dist/{DataTable-CnLqhXZ2.js → DataTable-BlGRB1Pa.js} +2 -2
- package/dist/{DataTable-CqaGqXkz.cjs → DataTable-CxaymjxX.cjs} +1 -1
- package/dist/{Legend-D2iK-_M0.cjs → Legend-Ds7yCP4e.cjs} +1 -1
- package/dist/{Legend-8QHo6cZQ.js → Legend-xj_UZPuw.js} +1 -1
- package/dist/{PackageVersion-Bw7N_9KM.js → PackageVersion-Crfv987V.js} +1 -1
- package/dist/{PackageVersion-DjuywB0J.cjs → PackageVersion-DgPnBWYN.cjs} +1 -1
- package/dist/{PenAndPaper-BiWc81tP.js → PenAndPaper-D8QdkfKM.js} +18 -18
- package/dist/{PenAndPaper-DoKpW2Tl.cjs → PenAndPaper-vKdCNpVJ.cjs} +1 -1
- package/dist/{Shape-CppjH62a.js → Shape-DNQDrxfn.js} +1 -1
- package/dist/{Shape-BfZLKYNk.cjs → Shape-M9CIgwzd.cjs} +1 -1
- package/dist/{Slicer-U4q5iMIE.cjs → Slicer-BMIoaXrp.cjs} +1 -1
- package/dist/{Slicer-CA5jR9Em.js → Slicer-BtiO3aSt.js} +2 -2
- package/dist/{Title-aR9ViX_A.cjs → Title-BqcJ8-j1.cjs} +1 -1
- package/dist/{Title-yJsQ5q-l.js → Title-CoonHZp1.js} +1 -1
- package/dist/Tooltip-DSZJXOZo.cjs +1 -0
- package/dist/Tooltip-WJvwo3eC.js +109 -0
- package/dist/documentation/installation.md +10 -10
- package/dist/{index-Cn1EWnYG.js → index-Qst-5kz0.js} +66 -63
- package/dist/index-uTaoMjg1.cjs +9 -0
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +3 -0
- package/dist/types/vue-data-ui.d.ts +3 -0
- package/dist/{useNestedProp-BXn-g9sr.js → useNestedProp-D3SUMrZY.js} +1 -1
- package/dist/{useNestedProp-DxZ05ZEt.cjs → useNestedProp-P8wzQfmW.cjs} +1 -1
- package/dist/{usePrinter-B3HaYNI4.cjs → usePrinter-DGnyAFMM.cjs} +1 -1
- package/dist/{usePrinter-ZkzmtO6K.js → usePrinter-srpiqIq8.js} +1 -1
- package/dist/{vue-data-ui-DfGCpkA8.js → vue-data-ui-BWV0_3wY.js} +58 -58
- package/dist/{vue-data-ui-Bn_29KuS.cjs → vue-data-ui-vuDWhbxy.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-CERRaGHQ.cjs → vue-ui-3d-bar-DXXySQ7-.cjs} +1 -1
- package/dist/{vue-ui-3d-bar-Cz7ZSFFf.js → vue-ui-3d-bar-nqIMKDVC.js} +9 -9
- package/dist/{vue-ui-accordion-UADqAdVj.js → vue-ui-accordion-CHl3zwsU.js} +3 -3
- package/dist/{vue-ui-accordion-kQwtYRmD.cjs → vue-ui-accordion-D88l7NVk.cjs} +1 -1
- package/dist/{vue-ui-age-pyramid-DhGijqy5.js → vue-ui-age-pyramid-Cm9zRjyB.js} +10 -10
- package/dist/{vue-ui-age-pyramid-Rfk1WUfJ.cjs → vue-ui-age-pyramid-DlRVNxj5.cjs} +1 -1
- package/dist/{vue-ui-annotator-BdAFNoMu.cjs → vue-ui-annotator-BaLbEuPn.cjs} +1 -1
- package/dist/{vue-ui-annotator-CCgDEOdY.js → vue-ui-annotator-BcZwMf4k.js} +1 -1
- package/dist/{vue-ui-bullet-Bkx9sfrv.cjs → vue-ui-bullet-DZ3ISzEy.cjs} +1 -1
- package/dist/{vue-ui-bullet-CSVuqhhg.js → vue-ui-bullet-DfIZfg_U.js} +8 -8
- package/dist/{vue-ui-candlestick-CuNi5UZ7.cjs → vue-ui-candlestick-CjSR_UwH.cjs} +1 -1
- package/dist/{vue-ui-candlestick-D0RfMi-W.js → vue-ui-candlestick-CrKXtUTA.js} +11 -11
- package/dist/{vue-ui-carousel-table-Dch3TChE.cjs → vue-ui-carousel-table-DSYgD9k3.cjs} +1 -1
- package/dist/{vue-ui-carousel-table-DeY0f9Ba.js → vue-ui-carousel-table-RTzJDG_m.js} +4 -4
- package/dist/{vue-ui-chestnut-bqu8whHd.cjs → vue-ui-chestnut-C-P3GVoT.cjs} +1 -1
- package/dist/{vue-ui-chestnut-B2Gio3KC.js → vue-ui-chestnut-DvGUaaag.js} +8 -8
- package/dist/{vue-ui-cursor-BlW4uLBm.js → vue-ui-cursor-CURrSWJH.js} +2 -2
- package/dist/{vue-ui-cursor-Dnv5a5oy.cjs → vue-ui-cursor-u0uJ1nPk.cjs} +1 -1
- package/dist/{vue-ui-dashboard-DCaNJXOd.js → vue-ui-dashboard-D5UQ9d4W.js} +2 -2
- package/dist/{vue-ui-dashboard-De5_U4a9.cjs → vue-ui-dashboard-DJSg-19y.cjs} +1 -1
- package/dist/{vue-ui-digits-DlteJApK.js → vue-ui-digits-BESFcIu-.js} +2 -2
- package/dist/{vue-ui-digits-Dc0L7473.cjs → vue-ui-digits-OdhKcT0Z.cjs} +1 -1
- package/dist/{vue-ui-donut-CBTZK6YJ.cjs → vue-ui-donut-D1JD2JpW.cjs} +1 -1
- package/dist/{vue-ui-donut-6Vh9u3Xp.js → vue-ui-donut-eLSljaMD.js} +11 -11
- package/dist/{vue-ui-donut-evolution-CmgjvLvu.cjs → vue-ui-donut-evolution-C5IpwddH.cjs} +1 -1
- package/dist/{vue-ui-donut-evolution-gQyMiCiu.js → vue-ui-donut-evolution-nogin4DH.js} +11 -11
- package/dist/{vue-ui-dumbbell-ByhSaE6s.cjs → vue-ui-dumbbell-BHd8UFZA.cjs} +1 -1
- package/dist/{vue-ui-dumbbell-C4xg1FG4.js → vue-ui-dumbbell-D1g4t_ba.js} +10 -10
- package/dist/{vue-ui-flow-DYF0P7LD.js → vue-ui-flow-CQ4ZPEf9.js} +9 -9
- package/dist/{vue-ui-flow-Bef5hCwj.cjs → vue-ui-flow-Cbo8koaf.cjs} +1 -1
- package/dist/{vue-ui-galaxy-COY_QSwC.cjs → vue-ui-galaxy-CwqWivy9.cjs} +1 -1
- package/dist/{vue-ui-galaxy-aM8uOGRD.js → vue-ui-galaxy-cJyFGSj3.js} +11 -11
- package/dist/{vue-ui-gauge-qYg_QM-A.js → vue-ui-gauge-BJ73VPHK.js} +7 -7
- package/dist/{vue-ui-gauge-CW8ZpODM.cjs → vue-ui-gauge-BjlSrIzM.cjs} +1 -1
- package/dist/{vue-ui-gizmo-BZyOCD_y.js → vue-ui-gizmo-B0_McLBu.js} +3 -3
- package/dist/{vue-ui-gizmo-DgS57tJ2.cjs → vue-ui-gizmo-LKVdd220.cjs} +1 -1
- package/dist/{vue-ui-heatmap-BfJGluVp.js → vue-ui-heatmap-B_p_NA69.js} +10 -10
- package/dist/{vue-ui-heatmap-Czg21edC.cjs → vue-ui-heatmap-CMwpGcs-.cjs} +1 -1
- package/dist/{vue-ui-kpi-C5ISBjIs.js → vue-ui-kpi-BTjso80e.js} +3 -3
- package/dist/{vue-ui-kpi-DQpkO2MX.cjs → vue-ui-kpi-JdTRJHRm.cjs} +1 -1
- package/dist/{vue-ui-mini-loader-BiaLLW3x.js → vue-ui-mini-loader-CaQfIaet.js} +2 -2
- package/dist/{vue-ui-mini-loader-Db5Khvfw.cjs → vue-ui-mini-loader-DzPmmR1Y.cjs} +1 -1
- package/dist/{vue-ui-molecule-fmAXI5nL.js → vue-ui-molecule-fG82cUkT.js} +11 -11
- package/dist/{vue-ui-molecule-4AXvVmWt.cjs → vue-ui-molecule-j_a9VBda.cjs} +1 -1
- package/dist/{vue-ui-mood-radar-BzfFikJv.cjs → vue-ui-mood-radar-DKVd8LUE.cjs} +1 -1
- package/dist/{vue-ui-mood-radar-CVLad_RZ.js → vue-ui-mood-radar-Up3yenwX.js} +11 -11
- package/dist/{vue-ui-nested-donuts-BP0qdKto.cjs → vue-ui-nested-donuts-B7hiJJ1U.cjs} +1 -1
- package/dist/{vue-ui-nested-donuts-7VePVE4W.js → vue-ui-nested-donuts-JT8N_ith.js} +11 -11
- package/dist/{vue-ui-onion-tzmb3ARN.cjs → vue-ui-onion-CIWDaVKe.cjs} +1 -1
- package/dist/{vue-ui-onion-LCcrKbXJ.js → vue-ui-onion-CWJlmMOv.js} +11 -11
- package/dist/{vue-ui-parallel-coordinate-plot-Dgu-tY5L.cjs → vue-ui-parallel-coordinate-plot-BPmehEq0.cjs} +1 -1
- package/dist/{vue-ui-parallel-coordinate-plot-D0Xxq5a9.js → vue-ui-parallel-coordinate-plot-BdS7FR9e.js} +12 -12
- package/dist/{vue-ui-quadrant-DkOZbxio.cjs → vue-ui-quadrant-Bj0_m09T.cjs} +1 -1
- package/dist/{vue-ui-quadrant-D_e1Knsr.js → vue-ui-quadrant-DNSSfYxO.js} +12 -12
- package/dist/{vue-ui-quick-chart-Brzheuk8.cjs → vue-ui-quick-chart-CaePwM8z.cjs} +1 -1
- package/dist/{vue-ui-quick-chart-CIm7vclU.js → vue-ui-quick-chart-DdHb8oXV.js} +9 -9
- package/dist/{vue-ui-radar-DoNZ8Qv9.cjs → vue-ui-radar-B3kRIdyQ.cjs} +1 -1
- package/dist/{vue-ui-radar-Cx_w_viT.js → vue-ui-radar-BLaCDKDI.js} +12 -12
- package/dist/{vue-ui-rating-B4zDVBEd.cjs → vue-ui-rating-6murOKLs.cjs} +1 -1
- package/dist/{vue-ui-rating-NRP3A0oA.js → vue-ui-rating-ZTFd5PY9.js} +2 -2
- package/dist/{vue-ui-relation-circle-C4LKLsEz.js → vue-ui-relation-circle-8HwwVi9V.js} +7 -7
- package/dist/{vue-ui-relation-circle-Cuk4LDJo.cjs → vue-ui-relation-circle-dng0Wo7U.cjs} +1 -1
- package/dist/{vue-ui-rings-DXawhL1m.js → vue-ui-rings-Bg-gI2AV.js} +11 -11
- package/dist/{vue-ui-rings-D6Rs1eq0.cjs → vue-ui-rings-cJg30GML.cjs} +1 -1
- package/dist/{vue-ui-scatter-8EzIXx2n.js → vue-ui-scatter-BbGF7Kqu.js} +12 -12
- package/dist/{vue-ui-scatter-DlfZqYP9.cjs → vue-ui-scatter-mE1PRE_c.cjs} +1 -1
- package/dist/{vue-ui-screenshot-Wwmw7VVM.js → vue-ui-screenshot-8L5oXuB8.js} +1 -1
- package/dist/{vue-ui-screenshot-Dt0UpXVm.cjs → vue-ui-screenshot-BDncUrRv.cjs} +1 -1
- package/dist/{vue-ui-skeleton-D3AGluiW.js → vue-ui-skeleton-3V3a9YDD.js} +3 -3
- package/dist/{vue-ui-skeleton-Si57O3af.cjs → vue-ui-skeleton-B9HVcMQ5.cjs} +1 -1
- package/dist/{vue-ui-smiley-UxTt4IMY.cjs → vue-ui-smiley-D0cPnUvD.cjs} +1 -1
- package/dist/{vue-ui-smiley-CRddsfyu.js → vue-ui-smiley-bfJp-uDp.js} +2 -2
- package/dist/{vue-ui-spark-trend-Cgr4pAvU.js → vue-ui-spark-trend-CUiHyXEy.js} +5 -5
- package/dist/{vue-ui-spark-trend-tMuRiISe.cjs → vue-ui-spark-trend-QESJyQLY.cjs} +1 -1
- package/dist/{vue-ui-sparkbar-B6TEBbyt.js → vue-ui-sparkbar-DQ6xAWCW.js} +4 -4
- package/dist/{vue-ui-sparkbar-BZVjpA5h.cjs → vue-ui-sparkbar-LgONGPmJ.cjs} +1 -1
- package/dist/{vue-ui-sparkgauge-P5fVXRT8.js → vue-ui-sparkgauge-C71yrtal.js} +4 -4
- package/dist/{vue-ui-sparkgauge-B9P3ngyj.cjs → vue-ui-sparkgauge-Ebcv5WPF.cjs} +1 -1
- package/dist/{vue-ui-sparkhistogram-BSQsOim4.cjs → vue-ui-sparkhistogram-DR5bbtjv.cjs} +1 -1
- package/dist/{vue-ui-sparkhistogram-vlWx_CFP.js → vue-ui-sparkhistogram-DV9-qngy.js} +5 -5
- package/dist/{vue-ui-sparkline-B1UrThV_.js → vue-ui-sparkline-BUQwEBGh.js} +4 -4
- package/dist/{vue-ui-sparkline-5FsmrmmU.cjs → vue-ui-sparkline-CFApZqM6.cjs} +1 -1
- package/dist/vue-ui-sparkstackbar-CWfd4U7P.cjs +1 -0
- package/dist/vue-ui-sparkstackbar-Dy8NuRTo.js +374 -0
- package/dist/{vue-ui-stackbar-BpFxY9uX.cjs → vue-ui-stackbar-B8k4q2Ci.cjs} +1 -1
- package/dist/{vue-ui-stackbar-DhnCj5jR.js → vue-ui-stackbar-Dm3TUSfv.js} +12 -12
- package/dist/{vue-ui-strip-plot-CutPMUb1.js → vue-ui-strip-plot-AZWlE4bf.js} +11 -11
- package/dist/{vue-ui-strip-plot-DnFquLCu.cjs → vue-ui-strip-plot-BGIlRwxX.cjs} +1 -1
- package/dist/{vue-ui-table-CUtRHuc4.cjs → vue-ui-table-D07ATtZj.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-DS2cSiGt.cjs → vue-ui-table-heatmap-Cga1jg-5.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-DyGuk9kw.js → vue-ui-table-heatmap-DIYuyeya.js} +4 -4
- package/dist/{vue-ui-table-Cx0eqrK_.js → vue-ui-table-j1JKMJlY.js} +1 -1
- package/dist/{vue-ui-table-sparkline-C1ril5t8.cjs → vue-ui-table-sparkline-BCtjl04c.cjs} +1 -1
- package/dist/{vue-ui-table-sparkline--Ekk_QoU.js → vue-ui-table-sparkline-Bs68Kr3b.js} +5 -5
- package/dist/{vue-ui-thermometer-Dr6_S2Qz.cjs → vue-ui-thermometer-B-bVUAFf.cjs} +1 -1
- package/dist/{vue-ui-thermometer-Dz_xaxCt.js → vue-ui-thermometer-XragDhm1.js} +7 -7
- package/dist/{vue-ui-timer-DRdgSmMv.js → vue-ui-timer-CD6NO3sW.js} +5 -5
- package/dist/{vue-ui-timer-BkmRYrPn.cjs → vue-ui-timer-CzKkkrH7.cjs} +1 -1
- package/dist/{vue-ui-tiremarks-BwVRnR-c.cjs → vue-ui-tiremarks-B2nQDIj-.cjs} +1 -1
- package/dist/{vue-ui-tiremarks-XuaMScx0.js → vue-ui-tiremarks-CgFVKqyp.js} +7 -7
- package/dist/{vue-ui-treemap-yUQZvXta.cjs → vue-ui-treemap-FK55MDjM.cjs} +1 -1
- package/dist/{vue-ui-treemap-D8HfM8ny.js → vue-ui-treemap-gj4510HN.js} +11 -11
- package/dist/{vue-ui-vertical-bar-DpaRYTVo.cjs → vue-ui-vertical-bar-BFtin4EH.cjs} +1 -1
- package/dist/{vue-ui-vertical-bar-BcWnPMjH.js → vue-ui-vertical-bar-iEd5iot7.js} +11 -11
- package/dist/{vue-ui-waffle-uur49hDo.cjs → vue-ui-waffle-DcsTaFaS.cjs} +1 -1
- package/dist/{vue-ui-waffle-sLIM61xh.js → vue-ui-waffle-XLMUuduF.js} +11 -11
- package/dist/{vue-ui-wheel-CJBuFjJt.cjs → vue-ui-wheel-BuLz0PvU.cjs} +1 -1
- package/dist/{vue-ui-wheel-D3Pfhpbe.js → vue-ui-wheel-DvNNNUNo.js} +7 -7
- package/dist/{vue-ui-word-cloud-Dhz-n0_M.cjs → vue-ui-word-cloud-Cs6kdOG-.cjs} +1 -1
- package/dist/{vue-ui-word-cloud-DhC8SN1l.js → vue-ui-word-cloud-IMAaNlwt.js} +10 -10
- package/dist/{vue-ui-xy-D7nWzSu1.js → vue-ui-xy-Dc67UrQD.js} +14 -14
- package/dist/{vue-ui-xy-Cn-JnSRl.cjs → vue-ui-xy-DvgA1d7k.cjs} +1 -1
- package/dist/{vue-ui-xy-canvas-DWZRAtDJ.js → vue-ui-xy-canvas-CMQ_w0PG.js} +11 -11
- package/dist/{vue-ui-xy-canvas-BI5nAbis.cjs → vue-ui-xy-canvas-CzydPKZG.cjs} +1 -1
- package/package.json +1 -1
- package/dist/Tooltip-CN6_JyjT.cjs +0 -1
- package/dist/Tooltip-klg8yuWM.js +0 -104
- package/dist/index-Ci5MafHS.cjs +0 -9
- package/dist/vue-ui-sparkstackbar-BzrHl4LW.js +0 -290
- package/dist/vue-ui-sparkstackbar-CEXgwtwV.cjs +0 -1
|
@@ -1,290 +0,0 @@
|
|
|
1
|
-
import { computed as y, ref as k, watch as I, onMounted as X, openBlock as s, createElementBlock as r, normalizeStyle as g, createElementVNode as d, toDisplayString as _, createCommentVNode as h, unref as b, createVNode as W, Fragment as D, renderList as N, normalizeClass as P, createBlock as J, renderSlot as K } from "vue";
|
|
2
|
-
import { u as Q, c as U, t as R, a as Y, p as i, d as C, b as Z, o as ee, e as V, g as te, f as O, X as le, s as ae, w as oe, i as se } from "./index-Cn1EWnYG.js";
|
|
3
|
-
import { u as G } from "./useNestedProp-BXn-g9sr.js";
|
|
4
|
-
import ne from "./vue-ui-skeleton-D3AGluiW.js";
|
|
5
|
-
import { _ as re } from "./PackageVersion-Bw7N_9KM.js";
|
|
6
|
-
import { _ as ue } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
7
|
-
const ie = ["xmlns", "viewBox"], ce = ["id"], de = ["stop-color"], ve = ["stop-color"], ge = ["stop-color"], pe = {
|
|
8
|
-
id: "stackPill",
|
|
9
|
-
clipPathUnits: "objectBoundingBox"
|
|
10
|
-
}, he = ["fill"], fe = {
|
|
11
|
-
key: 0,
|
|
12
|
-
"clip-path": "url(#stackPill)"
|
|
13
|
-
}, ye = ["height", "width", "fill"], me = ["onClick", "x", "width", "height", "fill", "stroke"], ke = ["width", "height", "rx"], _e = ["onClick"], be = { style: { display: "flex", "flex-direction": "row", "align-items": "center", gap: "4px", "justify-content": "center" } }, we = ["height", "width"], xe = ["fill"], Ce = {
|
|
14
|
-
key: 4,
|
|
15
|
-
ref: "source",
|
|
16
|
-
dir: "auto"
|
|
17
|
-
}, $e = {
|
|
18
|
-
__name: "vue-ui-sparkstackbar",
|
|
19
|
-
props: {
|
|
20
|
-
config: {
|
|
21
|
-
type: Object,
|
|
22
|
-
default() {
|
|
23
|
-
return {};
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
dataset: {
|
|
27
|
-
type: Array,
|
|
28
|
-
default() {
|
|
29
|
-
return [];
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
emits: ["selectDatapoint"],
|
|
34
|
-
setup(M, { emit: T }) {
|
|
35
|
-
const u = M, { vue_ui_sparkstackbar: q } = Q(), z = y(() => !!u.dataset && u.dataset.length), A = k(U()), e = y({
|
|
36
|
-
get: () => L(),
|
|
37
|
-
set: (t) => t
|
|
38
|
-
});
|
|
39
|
-
function L() {
|
|
40
|
-
const t = G({
|
|
41
|
-
userConfig: u.config,
|
|
42
|
-
defaultConfig: q
|
|
43
|
-
});
|
|
44
|
-
return t.theme ? {
|
|
45
|
-
...G({
|
|
46
|
-
userConfig: R.vue_ui_sparkstackbar[t.theme] || u.config,
|
|
47
|
-
defaultConfig: t
|
|
48
|
-
}),
|
|
49
|
-
customPalette: Y[t.theme] || i
|
|
50
|
-
} : t;
|
|
51
|
-
}
|
|
52
|
-
I(() => u.config, (t) => {
|
|
53
|
-
e.value = L(), B();
|
|
54
|
-
}, { deep: !0 }), I(() => u.dataset, (t) => {
|
|
55
|
-
m.value = u.dataset.map((a, l) => ({
|
|
56
|
-
...a,
|
|
57
|
-
color: a.color ? C(a.color) : w.value[l] || i[l] || i[l % i.length]
|
|
58
|
-
}));
|
|
59
|
-
}, { deep: !0 });
|
|
60
|
-
const w = y(() => Z(e.value.customPalette)), m = k(u.dataset.map((t, a) => ({
|
|
61
|
-
...t,
|
|
62
|
-
value: e.value.style.animation.show ? 0 : t.value || 0,
|
|
63
|
-
color: t.color ? C(t.color) : w.value[a] || i[a] || i[a % i.length]
|
|
64
|
-
}))), x = k(!0);
|
|
65
|
-
X(() => {
|
|
66
|
-
if (B(), e.value.style.animation.show) {
|
|
67
|
-
let f = function() {
|
|
68
|
-
o += l / t, o < l ? (m.value = m.value.map((n, c) => ({
|
|
69
|
-
...n,
|
|
70
|
-
value: n.value += a[c],
|
|
71
|
-
color: n.color ? C(n.color) : w.value[c] || i[c] || i[c % i.length]
|
|
72
|
-
})), requestAnimationFrame(f)) : (x.value = !1, m.value = u.dataset.map((n, c) => ({
|
|
73
|
-
...n,
|
|
74
|
-
value: n.value || 0,
|
|
75
|
-
color: n.color ? C(n.color) : w.value[c] || i[c] || i[c % i.length],
|
|
76
|
-
id: U()
|
|
77
|
-
})));
|
|
78
|
-
};
|
|
79
|
-
const t = e.value.style.animation.animationFrames, a = u.dataset.map((n, c) => n.value / t), l = u.dataset.map((n) => n.value || 0).reduce((n, c) => n + c, 0);
|
|
80
|
-
let o = 0;
|
|
81
|
-
x.value = !0, f();
|
|
82
|
-
}
|
|
83
|
-
});
|
|
84
|
-
function B() {
|
|
85
|
-
ee(u.dataset) ? V({
|
|
86
|
-
componentName: "VueUiSparkStackbar",
|
|
87
|
-
type: "dataset"
|
|
88
|
-
}) : u.dataset.forEach((t, a) => {
|
|
89
|
-
te({
|
|
90
|
-
datasetObject: t,
|
|
91
|
-
requiredAttributes: ["name", "value"]
|
|
92
|
-
}).forEach((l) => {
|
|
93
|
-
V({
|
|
94
|
-
componentName: "VueUiSparkStackbar",
|
|
95
|
-
type: "datasetSerieAttribute",
|
|
96
|
-
property: l,
|
|
97
|
-
index: a
|
|
98
|
-
});
|
|
99
|
-
});
|
|
100
|
-
});
|
|
101
|
-
}
|
|
102
|
-
const p = k({
|
|
103
|
-
width: 500,
|
|
104
|
-
height: 16
|
|
105
|
-
}), v = k([]), F = y(() => u.dataset.map((t) => t.value || 0).filter((t, a) => !v.value.includes(a)).reduce((t, a) => t + a, 0)), j = y(() => m.value.map((t, a) => {
|
|
106
|
-
const l = t.value || 0, o = l / F.value, f = isNaN(o) ? 0 : o, n = f * p.value.width;
|
|
107
|
-
return {
|
|
108
|
-
...t,
|
|
109
|
-
value: l,
|
|
110
|
-
proportion: f,
|
|
111
|
-
width: n,
|
|
112
|
-
proportionLabel: O({
|
|
113
|
-
v: f * 100,
|
|
114
|
-
s: "%",
|
|
115
|
-
r: e.value.style.legend.percentage.rounding
|
|
116
|
-
})
|
|
117
|
-
};
|
|
118
|
-
})), $ = y(() => j.value.filter((t, a) => !v.value.includes(a)));
|
|
119
|
-
function H(t) {
|
|
120
|
-
v.value.includes(t) ? v.value = v.value.filter((a) => a !== t) : v.value.length < m.value.length - 1 && v.value.push(t);
|
|
121
|
-
}
|
|
122
|
-
const S = y(() => {
|
|
123
|
-
let t = 0;
|
|
124
|
-
const a = [];
|
|
125
|
-
for (let l = 0; l < $.value.length; l += 1)
|
|
126
|
-
a.push({
|
|
127
|
-
...$.value[l],
|
|
128
|
-
start: t
|
|
129
|
-
}), t += $.value[l].width;
|
|
130
|
-
return a;
|
|
131
|
-
});
|
|
132
|
-
function E(t, a) {
|
|
133
|
-
T("selectDatapoint", { datapoint: t, index: a });
|
|
134
|
-
}
|
|
135
|
-
return (t, a) => (s(), r("div", {
|
|
136
|
-
style: g(`width:100%; background:${e.value.style.backgroundColor}`)
|
|
137
|
-
}, [
|
|
138
|
-
e.value.style.title.text ? (s(), r("div", {
|
|
139
|
-
key: 0,
|
|
140
|
-
style: g(`width:calc(100% - 12px);background:transparent;margin:0 auto;margin:${e.value.style.title.margin};padding: 0 6px;text-align:${e.value.style.title.textAlign}`)
|
|
141
|
-
}, [
|
|
142
|
-
d("div", {
|
|
143
|
-
style: g(`font-size:${e.value.style.title.fontSize}px;color:${e.value.style.title.color};font-weight:${e.value.style.title.bold ? "bold" : "normal"}`)
|
|
144
|
-
}, _(e.value.style.title.text), 5),
|
|
145
|
-
e.value.style.title.subtitle.text ? (s(), r("div", {
|
|
146
|
-
key: 0,
|
|
147
|
-
style: g(`font-size:${e.value.style.title.subtitle.fontSize}px;color:${e.value.style.title.subtitle.color};font-weight:${e.value.style.title.subtitle.bold ? "bold" : "normal"}`)
|
|
148
|
-
}, _(e.value.style.title.subtitle.text), 5)) : h("", !0)
|
|
149
|
-
], 4)) : h("", !0),
|
|
150
|
-
z.value ? (s(), r("svg", {
|
|
151
|
-
key: 1,
|
|
152
|
-
xmlns: b(le),
|
|
153
|
-
width: "100%",
|
|
154
|
-
viewBox: `0 0 ${p.value.width} ${p.value.height}`
|
|
155
|
-
}, [
|
|
156
|
-
W(re),
|
|
157
|
-
d("defs", null, [
|
|
158
|
-
(s(!0), r(D, null, N(S.value, (l, o) => (s(), r("linearGradient", {
|
|
159
|
-
key: `stack_gradient_${o}`,
|
|
160
|
-
gradientTransform: "rotate(90)",
|
|
161
|
-
id: `stack_gradient_${o}_${A.value}`
|
|
162
|
-
}, [
|
|
163
|
-
d("stop", {
|
|
164
|
-
offset: "0%",
|
|
165
|
-
"stop-color": l.color
|
|
166
|
-
}, null, 8, de),
|
|
167
|
-
d("stop", {
|
|
168
|
-
offset: "50%",
|
|
169
|
-
"stop-color": b(ae)(b(oe)(l.color, 0.05), 100 - e.value.style.bar.gradient.intensity)
|
|
170
|
-
}, null, 8, ve),
|
|
171
|
-
d("stop", {
|
|
172
|
-
offset: "100%",
|
|
173
|
-
"stop-color": l.color
|
|
174
|
-
}, null, 8, ge)
|
|
175
|
-
], 8, ce))), 128)),
|
|
176
|
-
d("clipPath", pe, [
|
|
177
|
-
d("rect", {
|
|
178
|
-
x: "0.005",
|
|
179
|
-
y: "-2",
|
|
180
|
-
width: "0.99",
|
|
181
|
-
height: "5",
|
|
182
|
-
rx: "3",
|
|
183
|
-
ry: "3",
|
|
184
|
-
fill: e.value.style.backgroundColor
|
|
185
|
-
}, null, 8, he)
|
|
186
|
-
])
|
|
187
|
-
]),
|
|
188
|
-
F.value > 0 ? (s(), r("g", fe, [
|
|
189
|
-
d("rect", {
|
|
190
|
-
x: 0,
|
|
191
|
-
y: 0,
|
|
192
|
-
height: p.value.height,
|
|
193
|
-
width: S.value.map((l) => l.width).reduce((l, o) => l + o, 0),
|
|
194
|
-
fill: e.value.style.bar.gradient.underlayerColor,
|
|
195
|
-
class: P({ animated: !x.value })
|
|
196
|
-
}, null, 10, ye),
|
|
197
|
-
(s(!0), r(D, null, N(S.value, (l, o) => (s(), r("rect", {
|
|
198
|
-
key: `stack_${o}`,
|
|
199
|
-
onClick: () => E(l, o),
|
|
200
|
-
x: l.start,
|
|
201
|
-
y: 0,
|
|
202
|
-
width: l.width,
|
|
203
|
-
height: p.value.height,
|
|
204
|
-
fill: e.value.style.bar.gradient.show ? `url(#stack_gradient_${o}_${A.value})` : l.color,
|
|
205
|
-
stroke: e.value.style.backgroundColor,
|
|
206
|
-
"stroke-linecap": "round",
|
|
207
|
-
class: P({ animated: !x.value })
|
|
208
|
-
}, null, 10, me))), 128))
|
|
209
|
-
])) : (s(), r("rect", {
|
|
210
|
-
key: 1,
|
|
211
|
-
x: 2,
|
|
212
|
-
y: 1,
|
|
213
|
-
width: p.value.width - 4,
|
|
214
|
-
height: p.value.height - 2,
|
|
215
|
-
stroke: "#CCCCCC",
|
|
216
|
-
"stroke-width": "2",
|
|
217
|
-
fill: "transparent",
|
|
218
|
-
rx: (p.value.height - 4) / 2
|
|
219
|
-
}, null, 8, ke))
|
|
220
|
-
], 8, ie)) : h("", !0),
|
|
221
|
-
z.value ? h("", !0) : (s(), J(ne, {
|
|
222
|
-
key: 2,
|
|
223
|
-
config: {
|
|
224
|
-
type: "sparkStackbar",
|
|
225
|
-
style: {
|
|
226
|
-
backgroundColor: e.value.style.backgroundColor,
|
|
227
|
-
sparkStackbar: {
|
|
228
|
-
color: "#CCCCCC"
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
}, null, 8, ["config"])),
|
|
233
|
-
e.value.style.legend.show ? (s(), r("div", {
|
|
234
|
-
key: 3,
|
|
235
|
-
style: g(`background:transparent;margin:0 auto;margin:${e.value.style.legend.margin};justify-content:${e.value.style.legend.textAlign === "left" ? "flex-start" : e.value.style.legend.textAlign === "right" ? "flex-end" : "center"}`),
|
|
236
|
-
class: "vue-ui-sparkstackbar-legend"
|
|
237
|
-
}, [
|
|
238
|
-
(s(!0), r(D, null, N(j.value, (l, o) => (s(), r("div", {
|
|
239
|
-
style: g(`font-size:${e.value.style.legend.fontSize}px;`),
|
|
240
|
-
class: P({ "vue-ui-sparkstackbar-legend-item": !0, "vue-ui-sparkstackbar-legend-item-unselected": v.value.includes(o) }),
|
|
241
|
-
onClick: (f) => {
|
|
242
|
-
H(o), E(l, o);
|
|
243
|
-
}
|
|
244
|
-
}, [
|
|
245
|
-
d("div", be, [
|
|
246
|
-
(s(), r("svg", {
|
|
247
|
-
height: `${e.value.style.legend.fontSize}px`,
|
|
248
|
-
width: `${e.value.style.legend.fontSize}px`,
|
|
249
|
-
viewBox: "0 0 10 10"
|
|
250
|
-
}, [
|
|
251
|
-
d("circle", {
|
|
252
|
-
cx: 5,
|
|
253
|
-
cy: 5,
|
|
254
|
-
r: 5,
|
|
255
|
-
fill: l.color
|
|
256
|
-
}, null, 8, xe)
|
|
257
|
-
], 8, we)),
|
|
258
|
-
d("span", {
|
|
259
|
-
style: g(`color:${e.value.style.legend.name.color}; font-weight:${e.value.style.legend.name.bold ? "bold" : "normal"}`)
|
|
260
|
-
}, _(l.name), 5),
|
|
261
|
-
e.value.style.legend.percentage.show ? (s(), r("span", {
|
|
262
|
-
key: 0,
|
|
263
|
-
style: g(`font-weight:${e.value.style.legend.percentage.bold ? "bold" : "normal"};color:${e.value.style.legend.percentage.color}`)
|
|
264
|
-
}, _(v.value.includes(o) ? " - " : l.proportionLabel), 5)) : h("", !0),
|
|
265
|
-
e.value.style.legend.value.show ? (s(), r("span", {
|
|
266
|
-
key: 1,
|
|
267
|
-
style: g(`font-weight:${e.value.style.legend.value.bold ? "bold" : "normal"};color:${e.value.style.legend.value.color}`)
|
|
268
|
-
}, " (" + _(b(se)(
|
|
269
|
-
e.value.style.legend.value.formatter,
|
|
270
|
-
l.value,
|
|
271
|
-
b(O)({
|
|
272
|
-
p: e.value.style.legend.value.prefix,
|
|
273
|
-
v: l.value,
|
|
274
|
-
s: e.value.style.legend.value.suffix,
|
|
275
|
-
r: e.value.style.legend.value.rounding
|
|
276
|
-
}),
|
|
277
|
-
{ datapoint: l, seriesIndex: o }
|
|
278
|
-
)) + ") ", 5)) : h("", !0)
|
|
279
|
-
])
|
|
280
|
-
], 14, _e))), 256))
|
|
281
|
-
], 4)) : h("", !0),
|
|
282
|
-
t.$slots.source ? (s(), r("div", Ce, [
|
|
283
|
-
K(t.$slots, "source", {}, void 0, !0)
|
|
284
|
-
], 512)) : h("", !0)
|
|
285
|
-
], 4));
|
|
286
|
-
}
|
|
287
|
-
}, Le = /* @__PURE__ */ ue($e, [["__scopeId", "data-v-bda2b20a"]]);
|
|
288
|
-
export {
|
|
289
|
-
Le as default
|
|
290
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-Ci5MafHS.cjs"),w=require("./useNestedProp-DxZ05ZEt.cjs"),V=require("./vue-ui-skeleton-Si57O3af.cjs"),z=require("./PackageVersion-DjuywB0J.cjs"),D=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),P=["xmlns","viewBox"],L=["id"],A=["stop-color"],F=["stop-color"],q=["stop-color"],U={id:"stackPill",clipPathUnits:"objectBoundingBox"},j=["fill"],T={key:0,"clip-path":"url(#stackPill)"},H=["height","width","fill"],I=["onClick","x","width","height","fill","stroke"],O=["width","height","rx"],M=["onClick"],G={style:{display:"flex","flex-direction":"row","align-items":"center",gap:"4px","justify-content":"center"}},W=["height","width"],X=["fill"],J={key:4,ref:"source",dir:"auto"},K={__name:"vue-ui-sparkstackbar",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectDatapoint"],setup(S,{emit:E}){const u=S,{vue_ui_sparkstackbar:N}=o.useConfig(),f=e.computed(()=>!!u.dataset&&u.dataset.length),k=e.ref(o.createUid()),t=e.computed({get:()=>_(),set:l=>l});function _(){const l=w.useNestedProp({userConfig:u.config,defaultConfig:N});return l.theme?{...w.useNestedProp({userConfig:o.themes.vue_ui_sparkstackbar[l.theme]||u.config,defaultConfig:l}),customPalette:o.themePalettes[l.theme]||o.palette}:l}e.watch(()=>u.config,l=>{t.value=_(),b()},{deep:!0}),e.watch(()=>u.dataset,l=>{v.value=u.dataset.map((n,a)=>({...n,color:n.color?o.convertColorToHex(n.color):m.value[a]||o.palette[a]||o.palette[a%o.palette.length]}))},{deep:!0});const m=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),v=e.ref(u.dataset.map((l,n)=>({...l,value:t.value.style.animation.show?0:l.value||0,color:l.color?o.convertColorToHex(l.color):m.value[n]||o.palette[n]||o.palette[n%o.palette.length]}))),g=e.ref(!0);e.onMounted(()=>{if(b(),t.value.style.animation.show){let p=function(){r+=a/l,r<a?(v.value=v.value.map((s,i)=>({...s,value:s.value+=n[i],color:s.color?o.convertColorToHex(s.color):m.value[i]||o.palette[i]||o.palette[i%o.palette.length]})),requestAnimationFrame(p)):(g.value=!1,v.value=u.dataset.map((s,i)=>({...s,value:s.value||0,color:s.color?o.convertColorToHex(s.color):m.value[i]||o.palette[i]||o.palette[i%o.palette.length],id:o.createUid()})))};const l=t.value.style.animation.animationFrames,n=u.dataset.map((s,i)=>s.value/l),a=u.dataset.map(s=>s.value||0).reduce((s,i)=>s+i,0);let r=0;g.value=!0,p()}});function b(){o.objectIsEmpty(u.dataset)?o.error({componentName:"VueUiSparkStackbar",type:"dataset"}):u.dataset.forEach((l,n)=>{o.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","value"]}).forEach(a=>{o.error({componentName:"VueUiSparkStackbar",type:"datasetSerieAttribute",property:a,index:n})})})}const d=e.ref({width:500,height:16}),c=e.ref([]),C=e.computed(()=>u.dataset.map(l=>l.value||0).filter((l,n)=>!c.value.includes(n)).reduce((l,n)=>l+n,0)),x=e.computed(()=>v.value.map((l,n)=>{const a=l.value||0,r=a/C.value,p=isNaN(r)?0:r,s=p*d.value.width;return{...l,value:a,proportion:p,width:s,proportionLabel:o.dataLabel({v:p*100,s:"%",r:t.value.style.legend.percentage.rounding})}})),h=e.computed(()=>x.value.filter((l,n)=>!c.value.includes(n)));function $(l){c.value.includes(l)?c.value=c.value.filter(n=>n!==l):c.value.length<v.value.length-1&&c.value.push(l)}const y=e.computed(()=>{let l=0;const n=[];for(let a=0;a<h.value.length;a+=1)n.push({...h.value[a],start:l}),l+=h.value[a].width;return n});function B(l,n){E("selectDatapoint",{datapoint:l,index:n})}return(l,n)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`width:100%; background:${t.value.style.backgroundColor}`)},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:calc(100% - 12px);background:transparent;margin:0 auto;margin:${t.value.style.title.margin};padding: 0 6px;text-align:${t.value.style.title.textAlign}`)},[e.createElementVNode("div",{style:e.normalizeStyle(`font-size:${t.value.style.title.fontSize}px;color:${t.value.style.title.color};font-weight:${t.value.style.title.bold?"bold":"normal"}`)},e.toDisplayString(t.value.style.title.text),5),t.value.style.title.subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`font-size:${t.value.style.title.subtitle.fontSize}px;color:${t.value.style.title.subtitle.color};font-weight:${t.value.style.title.subtitle.bold?"bold":"normal"}`)},e.toDisplayString(t.value.style.title.subtitle.text),5)):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0),f.value?(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(o.XMLNS),width:"100%",viewBox:`0 0 ${d.value.width} ${d.value.height}`},[e.createVNode(z._sfc_main),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(a,r)=>(e.openBlock(),e.createElementBlock("linearGradient",{key:`stack_gradient_${r}`,gradientTransform:"rotate(90)",id:`stack_gradient_${r}_${k.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":a.color},null,8,A),e.createElementVNode("stop",{offset:"50%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(a.color,.05),100-t.value.style.bar.gradient.intensity)},null,8,F),e.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,q)],8,L))),128)),e.createElementVNode("clipPath",U,[e.createElementVNode("rect",{x:"0.005",y:"-2",width:"0.99",height:"5",rx:"3",ry:"3",fill:t.value.style.backgroundColor},null,8,j)])]),C.value>0?(e.openBlock(),e.createElementBlock("g",T,[e.createElementVNode("rect",{x:0,y:0,height:d.value.height,width:y.value.map(a=>a.width).reduce((a,r)=>a+r,0),fill:t.value.style.bar.gradient.underlayerColor,class:e.normalizeClass({animated:!g.value})},null,10,H),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(a,r)=>(e.openBlock(),e.createElementBlock("rect",{key:`stack_${r}`,onClick:()=>B(a,r),x:a.start,y:0,width:a.width,height:d.value.height,fill:t.value.style.bar.gradient.show?`url(#stack_gradient_${r}_${k.value})`:a.color,stroke:t.value.style.backgroundColor,"stroke-linecap":"round",class:e.normalizeClass({animated:!g.value})},null,10,I))),128))])):(e.openBlock(),e.createElementBlock("rect",{key:1,x:2,y:1,width:d.value.width-4,height:d.value.height-2,stroke:"#CCCCCC","stroke-width":"2",fill:"transparent",rx:(d.value.height-4)/2},null,8,O))],8,P)):e.createCommentVNode("",!0),f.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(V.default,{key:2,config:{type:"sparkStackbar",style:{backgroundColor:t.value.style.backgroundColor,sparkStackbar:{color:"#CCCCCC"}}}},null,8,["config"])),t.value.style.legend.show?(e.openBlock(),e.createElementBlock("div",{key:3,style:e.normalizeStyle(`background:transparent;margin:0 auto;margin:${t.value.style.legend.margin};justify-content:${t.value.style.legend.textAlign==="left"?"flex-start":t.value.style.legend.textAlign==="right"?"flex-end":"center"}`),class:"vue-ui-sparkstackbar-legend"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(a,r)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`font-size:${t.value.style.legend.fontSize}px;`),class:e.normalizeClass({"vue-ui-sparkstackbar-legend-item":!0,"vue-ui-sparkstackbar-legend-item-unselected":c.value.includes(r)}),onClick:p=>{$(r),B(a,r)}},[e.createElementVNode("div",G,[(e.openBlock(),e.createElementBlock("svg",{height:`${t.value.style.legend.fontSize}px`,width:`${t.value.style.legend.fontSize}px`,viewBox:"0 0 10 10"},[e.createElementVNode("circle",{cx:5,cy:5,r:5,fill:a.color},null,8,X)],8,W)),e.createElementVNode("span",{style:e.normalizeStyle(`color:${t.value.style.legend.name.color}; font-weight:${t.value.style.legend.name.bold?"bold":"normal"}`)},e.toDisplayString(a.name),5),t.value.style.legend.percentage.show?(e.openBlock(),e.createElementBlock("span",{key:0,style:e.normalizeStyle(`font-weight:${t.value.style.legend.percentage.bold?"bold":"normal"};color:${t.value.style.legend.percentage.color}`)},e.toDisplayString(c.value.includes(r)?" - ":a.proportionLabel),5)):e.createCommentVNode("",!0),t.value.style.legend.value.show?(e.openBlock(),e.createElementBlock("span",{key:1,style:e.normalizeStyle(`font-weight:${t.value.style.legend.value.bold?"bold":"normal"};color:${t.value.style.legend.value.color}`)}," ("+e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.legend.value.formatter,a.value,e.unref(o.dataLabel)({p:t.value.style.legend.value.prefix,v:a.value,s:t.value.style.legend.value.suffix,r:t.value.style.legend.value.rounding}),{datapoint:a,seriesIndex:r}))+") ",5)):e.createCommentVNode("",!0)])],14,M))),256))],4)):e.createCommentVNode("",!0),l.$slots.source?(e.openBlock(),e.createElementBlock("div",J,[e.renderSlot(l.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0)],4))}},Q=D._export_sfc(K,[["__scopeId","data-v-bda2b20a"]]);exports.default=Q;
|