vue-data-ui 2.3.60 → 2.3.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Arrow-BJ47KXjY.js → Arrow-Dho8ylDy.js} +1 -1
- package/dist/{Arrow-VxZlHkwt.cjs → Arrow-ov-EIAPu.cjs} +1 -1
- package/dist/{BaseIcon-Bv5uh10R.cjs → BaseIcon-B6v-Txn-.cjs} +1 -1
- package/dist/{BaseIcon-Fm7sUbd2.js → BaseIcon-BNStcP8c.js} +1 -1
- package/dist/{DataTable-1VV0us-8.js → DataTable-luIjNnne.js} +2 -2
- package/dist/{DataTable-CPAt686N.cjs → DataTable-yf_eyv8c.cjs} +1 -1
- package/dist/{Legend-BJ2Mynop.cjs → Legend-6JY5pUsT.cjs} +1 -1
- package/dist/{Legend-DB6v_LvZ.js → Legend-B9dawQa7.js} +1 -1
- package/dist/{Shape-DWZSJJ6-.cjs → Shape-BoXM3HKY.cjs} +1 -1
- package/dist/{Shape-B_f1_6Ob.js → Shape-BsAETTif.js} +1 -1
- package/dist/Slicer-DoMAeSUY.cjs +1 -0
- package/dist/{Slicer-CHiUxRAh.js → Slicer-iGmqxtRQ.js} +51 -54
- package/dist/{Title-CR-JDJwq.cjs → Title-CBcoQe02.cjs} +1 -1
- package/dist/{Title-xP0rAF4q.js → Title-fb3BzoXj.js} +1 -1
- package/dist/{Tooltip-B4DNihSF.cjs → Tooltip-BhuD1Kc5.cjs} +1 -1
- package/dist/{Tooltip-DfBa_7Ur.js → Tooltip-CBugtvWB.js} +5 -5
- package/dist/{index-CpHoINpJ.js → index-BshV7sX1.js} +538 -515
- package/dist/{index-CDK3omwG.cjs → index-D2ZScauW.cjs} +4 -4
- package/dist/style.css +1 -1
- package/dist/{useNestedProp-BOjw3Yqn.js → useNestedProp-B235bkr5.js} +1 -1
- package/dist/{useNestedProp-CaaW8JIS.cjs → useNestedProp-BU7yyXFA.cjs} +1 -1
- package/dist/{usePrinter-BHy-mfVg.js → usePrinter-Culo-aKo.js} +1 -1
- package/dist/{usePrinter-vQu-8tRD.cjs → usePrinter-eqT4IYET.cjs} +1 -1
- package/dist/{vue-data-ui-Ccdrn4OV.cjs → vue-data-ui-B7ebF4_E.cjs} +1 -1
- package/dist/{vue-data-ui-Dcg7DPMn.js → vue-data-ui-aJ6K70wA.js} +57 -57
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +7 -7
- package/dist/{vue-ui-3d-bar-BqtnNU7h.js → vue-ui-3d-bar-BYgxIW27.js} +7 -7
- package/dist/{vue-ui-3d-bar-DdBlV5AX.cjs → vue-ui-3d-bar-DFv8qpsI.cjs} +1 -1
- package/dist/{vue-ui-accordion-BZloYo0L.js → vue-ui-accordion-B6AxEnAr.js} +3 -3
- package/dist/{vue-ui-accordion-EVAolVkD.cjs → vue-ui-accordion-BhCJcWDd.cjs} +1 -1
- package/dist/vue-ui-age-pyramid-BBRjCRtS.cjs +1 -0
- package/dist/{vue-ui-age-pyramid-CTxkOn4v.js → vue-ui-age-pyramid-yZrvdnPP.js} +226 -226
- package/dist/{vue-ui-annotator-D_AK0JCi.cjs → vue-ui-annotator-CEVmAufb.cjs} +1 -1
- package/dist/{vue-ui-annotator-BDWKiQ6S.js → vue-ui-annotator-ZKUlOqUq.js} +1 -1
- package/dist/{vue-ui-candlestick-CIKgu0F2.cjs → vue-ui-candlestick-CUNLZRIM.cjs} +2 -2
- package/dist/{vue-ui-candlestick-ByA9FGZb.js → vue-ui-candlestick-De4WgpPk.js} +158 -158
- package/dist/{vue-ui-carousel-table-ez9gbOZ7.cjs → vue-ui-carousel-table-C968uL6J.cjs} +1 -1
- package/dist/{vue-ui-carousel-table-BnYxbq5A.js → vue-ui-carousel-table-DJ0AWPea.js} +4 -4
- package/dist/{vue-ui-chestnut-BumsSmCv.js → vue-ui-chestnut-Cl0UKWsI.js} +65 -64
- package/dist/{vue-ui-chestnut-CnYqa2Fx.cjs → vue-ui-chestnut-DmjmL02K.cjs} +3 -3
- package/dist/{vue-ui-cursor-D-4-MMw7.js → vue-ui-cursor-BWyE3tgm.js} +2 -2
- package/dist/{vue-ui-cursor-Drl8jibt.cjs → vue-ui-cursor-D5XEblLW.cjs} +1 -1
- package/dist/{vue-ui-dashboard-CX0jA181.cjs → vue-ui-dashboard-BJLi81kg.cjs} +1 -1
- package/dist/{vue-ui-dashboard-B_iV-3hq.js → vue-ui-dashboard-D9dQIIti.js} +2 -2
- package/dist/{vue-ui-digits-DMhl9plv.js → vue-ui-digits-DkYpomD9.js} +2 -2
- package/dist/{vue-ui-digits-RAZl_4Kb.cjs → vue-ui-digits-IIiSTczs.cjs} +1 -1
- package/dist/{vue-ui-donut-BG28U01c.cjs → vue-ui-donut-Bq66xmG0.cjs} +1 -1
- package/dist/{vue-ui-donut-evolution-DPU-Nd8y.js → vue-ui-donut-evolution-Bto1ZaWx.js} +95 -95
- package/dist/vue-ui-donut-evolution-CNVUtEEk.cjs +1 -0
- package/dist/{vue-ui-donut-BpQC9-Uz.js → vue-ui-donut-uujhj36t.js} +42 -42
- package/dist/vue-ui-dumbbell-CLNVYG0j.cjs +9 -0
- package/dist/{vue-ui-dumbbell-C4JnuC1b.js → vue-ui-dumbbell-D6Xyfvff.js} +72 -72
- package/dist/vue-ui-flow-BwrqexSU.cjs +1 -0
- package/dist/vue-ui-flow-Cg4oKZz8.js +469 -0
- package/dist/{vue-ui-galaxy-148JtEdK.js → vue-ui-galaxy-D_s9dfYN.js} +91 -91
- package/dist/vue-ui-galaxy-DixlciaO.cjs +1 -0
- package/dist/{vue-ui-gauge-DOJ98R_N.js → vue-ui-gauge-DGQVW6UO.js} +84 -84
- package/dist/vue-ui-gauge-Jse5ZYyj.cjs +1 -0
- package/dist/{vue-ui-gizmo-KeWvd226.js → vue-ui-gizmo-DDTaLaSI.js} +2 -2
- package/dist/{vue-ui-gizmo-a6WNWyf7.cjs → vue-ui-gizmo-sgq75uBG.cjs} +1 -1
- package/dist/vue-ui-heatmap-4-gnNgQ_.cjs +1 -0
- package/dist/{vue-ui-heatmap-BGsSOTPJ.js → vue-ui-heatmap-Dvd5ZGVw.js} +257 -239
- package/dist/{vue-ui-kpi-Dhah6Fgx.cjs → vue-ui-kpi-Co1WqN3k.cjs} +1 -1
- package/dist/{vue-ui-kpi-Leb1rK38.js → vue-ui-kpi-aLwUkIjv.js} +3 -3
- package/dist/{vue-ui-mini-loader-BLH4ncUB.js → vue-ui-mini-loader-Bm2xpTIh.js} +2 -2
- package/dist/{vue-ui-mini-loader-Dpa9uYkn.cjs → vue-ui-mini-loader-D98KCpoT.cjs} +1 -1
- package/dist/{vue-ui-molecule-DjvOvDUa.cjs → vue-ui-molecule-C3-9ojnv.cjs} +1 -1
- package/dist/{vue-ui-molecule-DuPAOQcj.js → vue-ui-molecule-Dv4hYPVd.js} +20 -20
- package/dist/{vue-ui-mood-radar-AOHK6R10.cjs → vue-ui-mood-radar-Dh3Q2NiI.cjs} +1 -1
- package/dist/{vue-ui-mood-radar-BmcIz0JR.js → vue-ui-mood-radar-DsIPsXTh.js} +9 -9
- package/dist/{vue-ui-nested-donuts-CMmcmAd9.cjs → vue-ui-nested-donuts-CFC8tyGY.cjs} +2 -2
- package/dist/{vue-ui-nested-donuts-BYLc86qs.js → vue-ui-nested-donuts-CZ9vcclX.js} +120 -120
- package/dist/{vue-ui-onion-BjG8xbMh.cjs → vue-ui-onion-BLV33CBr.cjs} +1 -1
- package/dist/{vue-ui-onion-shZ4g9mJ.js → vue-ui-onion-CI9ARfRM.js} +9 -9
- package/dist/{vue-ui-parallel-coordinate-plot-O7lS6u2q.cjs → vue-ui-parallel-coordinate-plot-CIhpHeCI.cjs} +1 -1
- package/dist/{vue-ui-parallel-coordinate-plot-wv0O9t7U.js → vue-ui-parallel-coordinate-plot-CxzFJuza.js} +69 -69
- package/dist/{vue-ui-quadrant-CuB8sYgF.cjs → vue-ui-quadrant-CS3LAiCu.cjs} +1 -1
- package/dist/{vue-ui-quadrant-BRF5Czj4.js → vue-ui-quadrant-DenUcNcS.js} +36 -36
- package/dist/{vue-ui-quick-chart-BQdUHrm2.js → vue-ui-quick-chart-BdpKv0ES.js} +549 -515
- package/dist/vue-ui-quick-chart-UxaO0jzI.cjs +15 -0
- package/dist/vue-ui-radar-CQ-LymAS.cjs +1 -0
- package/dist/{vue-ui-radar-CLUs0tD9.js → vue-ui-radar-Dd24aGwh.js} +59 -59
- package/dist/{vue-ui-rating-Dcy1l1PB.js → vue-ui-rating-CQWK2lk1.js} +9 -9
- package/dist/{vue-ui-rating-CA25nHJe.cjs → vue-ui-rating-DTuDjrt8.cjs} +1 -1
- package/dist/{vue-ui-relation-circle-DC-RFa9X.js → vue-ui-relation-circle-BcOzK8Iz.js} +5 -5
- package/dist/{vue-ui-relation-circle-Drr6Gdnq.cjs → vue-ui-relation-circle-DMhNCwpg.cjs} +1 -1
- package/dist/vue-ui-rings--pu1fIcl.cjs +2 -0
- package/dist/{vue-ui-rings-DbPbelCU.js → vue-ui-rings-yyFx2W1b.js} +188 -185
- package/dist/{vue-ui-scatter-D2jYZ4Wu.js → vue-ui-scatter-BV4sXNqz.js} +378 -375
- package/dist/{vue-ui-scatter-xyLvaw0d.cjs → vue-ui-scatter-CrmsJjjl.cjs} +1 -1
- package/dist/{vue-ui-screenshot-DXCBzrPZ.js → vue-ui-screenshot-C6wYv3cc.js} +6 -6
- package/dist/{vue-ui-screenshot-DGqjaE1x.cjs → vue-ui-screenshot-eoAWixSo.cjs} +1 -1
- package/dist/{vue-ui-skeleton-DuM6yey6.js → vue-ui-skeleton-7qakoAGH.js} +23 -23
- package/dist/{vue-ui-skeleton-DRDC3yxK.cjs → vue-ui-skeleton-BLhbQje-.cjs} +1 -1
- package/dist/{vue-ui-smiley-DQrvx_S9.js → vue-ui-smiley-DG3_ORXA.js} +2 -2
- package/dist/{vue-ui-smiley-BCmY1siL.cjs → vue-ui-smiley-sS92V85O.cjs} +1 -1
- package/dist/vue-ui-spark-trend-C9Ii4Ue5.cjs +1 -0
- package/dist/vue-ui-spark-trend-D8_rEspZ.js +251 -0
- package/dist/{vue-ui-sparkbar-C_vNsxM_.cjs → vue-ui-sparkbar-CQz9GWxh.cjs} +1 -1
- package/dist/{vue-ui-sparkbar-DiU5Yt-V.js → vue-ui-sparkbar-DuNNnbs9.js} +3 -3
- package/dist/{vue-ui-sparkgauge-BnF9Vbs0.js → vue-ui-sparkgauge-Buo2ms6b.js} +64 -64
- package/dist/vue-ui-sparkgauge-Dxsnkehz.cjs +1 -0
- package/dist/{vue-ui-sparkhistogram-BUBwn9A4.cjs → vue-ui-sparkhistogram-Cw-w_Rhv.cjs} +1 -1
- package/dist/{vue-ui-sparkhistogram-CsOfCo_3.js → vue-ui-sparkhistogram-edeeQ1HN.js} +4 -4
- package/dist/{vue-ui-sparkline-CoUeD8Np.cjs → vue-ui-sparkline-Cyddej9t.cjs} +1 -1
- package/dist/{vue-ui-sparkline-B628G3Nl.js → vue-ui-sparkline-DGIqGoR2.js} +25 -25
- package/dist/{vue-ui-sparkstackbar-Cr-Q7uDo.cjs → vue-ui-sparkstackbar-DN0XiDpQ.cjs} +1 -1
- package/dist/{vue-ui-sparkstackbar-DIHGbrF5.js → vue-ui-sparkstackbar-G7Ojd39B.js} +3 -3
- package/dist/{vue-ui-stackbar-DCbJhdZy.js → vue-ui-stackbar-CfK9lv_E.js} +35 -35
- package/dist/{vue-ui-stackbar-DMyP3IRK.cjs → vue-ui-stackbar-kiZ9J1eh.cjs} +1 -1
- package/dist/vue-ui-strip-plot-Bd4NwUia.cjs +1 -0
- package/dist/{vue-ui-strip-plot-CNb3VtYF.js → vue-ui-strip-plot-d-bNHZDG.js} +64 -64
- package/dist/{vue-ui-table-CjuXpy2d.cjs → vue-ui-table-ChORiy2h.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-D6px_Z1a.cjs → vue-ui-table-heatmap-BcA1TmV1.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-nbBDuSiw.js → vue-ui-table-heatmap-BcPqaYXz.js} +26 -26
- package/dist/{vue-ui-table-BqcI8E7E.js → vue-ui-table-ipCsGZPx.js} +1 -1
- package/dist/{vue-ui-table-sparkline-Blbaz2zX.js → vue-ui-table-sparkline-BwwiWOX_.js} +13 -13
- package/dist/{vue-ui-table-sparkline-CqNPx5Zw.cjs → vue-ui-table-sparkline-dXyBTv6X.cjs} +1 -1
- package/dist/vue-ui-thermometer-DpWtOskJ.cjs +1 -0
- package/dist/{vue-ui-thermometer-BCGHbgj9.js → vue-ui-thermometer-U5IIot6j.js} +116 -116
- package/dist/{vue-ui-timer-BjqbxjQO.cjs → vue-ui-timer-DqVQjRdU.cjs} +1 -1
- package/dist/{vue-ui-timer-DhpBvc_5.js → vue-ui-timer-cCfNkOpe.js} +4 -4
- package/dist/{vue-ui-tiremarks-CNhB7Iqe.js → vue-ui-tiremarks-BcXrnO0N.js} +71 -71
- package/dist/vue-ui-tiremarks-C8pNPR_E.cjs +1 -0
- package/dist/vue-ui-treemap-24TuOX-H.cjs +1 -0
- package/dist/{vue-ui-treemap-C4memkYu.js → vue-ui-treemap-CVCaxcwW.js} +89 -82
- package/dist/{vue-ui-vertical-bar-LZ-GMZ2T.js → vue-ui-vertical-bar-Cuz2Qxi6.js} +246 -242
- package/dist/vue-ui-vertical-bar-kZxc3vG5.cjs +4 -0
- package/dist/{vue-ui-waffle-Cd4IU62n.js → vue-ui-waffle-BVFZf7mm.js} +44 -44
- package/dist/{vue-ui-waffle-CtY5CSX9.cjs → vue-ui-waffle-X-mNfs6F.cjs} +1 -1
- package/dist/{vue-ui-wheel-Do3pWPFB.cjs → vue-ui-wheel-CWOh-9CT.cjs} +1 -1
- package/dist/{vue-ui-wheel-CaEAQhJt.js → vue-ui-wheel-SUtbKs4l.js} +5 -5
- package/dist/vue-ui-word-cloud-BE_jkp2h.cjs +1 -0
- package/dist/{vue-ui-word-cloud-BSalPYqO.js → vue-ui-word-cloud-DAa0far7.js} +68 -65
- package/dist/vue-ui-xy-BTocPMsA.cjs +3 -0
- package/dist/{vue-ui-xy-C7tpVpGu.js → vue-ui-xy-B_dmMYPU.js} +82 -82
- package/dist/vue-ui-xy-canvas-BtuD8xjy.cjs +9 -0
- package/dist/{vue-ui-xy-canvas-rHcYmvec.js → vue-ui-xy-canvas-jq1j84oA.js} +122 -121
- package/package.json +1 -1
- package/dist/Slicer-PPS43jOo.cjs +0 -1
- package/dist/vue-ui-age-pyramid-Ce3DbeqC.cjs +0 -1
- package/dist/vue-ui-donut-evolution-BWvrYKlH.cjs +0 -1
- package/dist/vue-ui-dumbbell-2Lsks-8o.cjs +0 -9
- package/dist/vue-ui-flow-DBhdVKxF.cjs +0 -1
- package/dist/vue-ui-flow-DSdWqWgh.js +0 -465
- package/dist/vue-ui-galaxy-BMsdd9Rh.cjs +0 -1
- package/dist/vue-ui-gauge-fVk9B_1W.cjs +0 -1
- package/dist/vue-ui-heatmap-DFpSo2gr.cjs +0 -1
- package/dist/vue-ui-quick-chart-DsVFRO68.cjs +0 -15
- package/dist/vue-ui-radar-lcS6n5TC.cjs +0 -1
- package/dist/vue-ui-rings-DxqSAs9h.cjs +0 -2
- package/dist/vue-ui-spark-trend-B9PR0wxN.js +0 -251
- package/dist/vue-ui-spark-trend-Kj1bJmBL.cjs +0 -1
- package/dist/vue-ui-sparkgauge-SlYA1lqc.cjs +0 -1
- package/dist/vue-ui-strip-plot-Da_TQpOq.cjs +0 -1
- package/dist/vue-ui-thermometer-coTC0T6k.cjs +0 -1
- package/dist/vue-ui-tiremarks-DgbTo_Cb.cjs +0 -1
- package/dist/vue-ui-treemap-B5moKzuO.cjs +0 -1
- package/dist/vue-ui-vertical-bar-DtkGW5Tk.cjs +0 -4
- package/dist/vue-ui-word-cloud-pzaBe3Et.cjs +0 -1
- package/dist/vue-ui-xy-BgLF5ZNP.cjs +0 -3
- package/dist/vue-ui-xy-canvas-OuDGiOOW.cjs +0 -9
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { computed as s, onMounted as
|
|
2
|
-
import { u as
|
|
3
|
-
import { u as
|
|
4
|
-
import
|
|
5
|
-
const
|
|
1
|
+
import { computed as s, onMounted as C, ref as y, watch as O, openBlock as n, createElementBlock as v, normalizeStyle as c, toDisplayString as g, createCommentVNode as d, unref as i, createElementVNode as r, normalizeClass as j, createBlock as B } from "vue";
|
|
2
|
+
import { u as D, o as E, e as L, g as G, c as I, t as U, L as V, X as q, i as P, s as p, f as T } from "./index-BshV7sX1.js";
|
|
3
|
+
import { u as A } from "./useNestedProp-B235bkr5.js";
|
|
4
|
+
import X from "./vue-ui-skeleton-7qakoAGH.js";
|
|
5
|
+
const H = ["xmlns", "viewBox"], R = ["id"], Y = ["stop-color"], J = ["stop-color"], K = ["d", "stroke", "stroke-linecap"], Q = ["d", "stroke", "stroke-linecap", "stroke-dashoffset"], W = ["x", "y", "font-size", "fill", "font-weight"], le = {
|
|
6
6
|
__name: "vue-ui-sparkgauge",
|
|
7
7
|
props: {
|
|
8
8
|
config: {
|
|
@@ -18,31 +18,31 @@ const X = ["xmlns", "viewBox"], H = ["id"], J = ["stop-color"], R = ["stop-color
|
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
|
-
setup(
|
|
22
|
-
const t =
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
setup(N) {
|
|
22
|
+
const t = N, { vue_ui_sparkgauge: S } = D(), b = s(() => !!t.dataset && Object.keys(t.dataset).length);
|
|
23
|
+
C(() => {
|
|
24
|
+
E(t.dataset) ? L({
|
|
25
25
|
componentName: "VueUiSparkgauge",
|
|
26
26
|
type: "dataset"
|
|
27
|
-
}) :
|
|
27
|
+
}) : G({
|
|
28
28
|
datasetObject: t.dataset,
|
|
29
29
|
requiredAttributes: ["value", "min", "max"]
|
|
30
30
|
}).forEach((o) => {
|
|
31
|
-
|
|
31
|
+
L({
|
|
32
32
|
componentName: "VueUiSparkgauge",
|
|
33
33
|
type: "datasetAttribute",
|
|
34
34
|
property: o
|
|
35
35
|
});
|
|
36
36
|
});
|
|
37
37
|
});
|
|
38
|
-
const
|
|
39
|
-
const o =
|
|
38
|
+
const h = y(I()), e = s(() => {
|
|
39
|
+
const o = A({
|
|
40
40
|
userConfig: t.config,
|
|
41
41
|
defaultConfig: S
|
|
42
42
|
});
|
|
43
43
|
return o.theme ? {
|
|
44
|
-
...
|
|
45
|
-
userConfig:
|
|
44
|
+
...A({
|
|
45
|
+
userConfig: U.vue_ui_sparkgauge[o.theme] || t.config,
|
|
46
46
|
defaultConfig: o
|
|
47
47
|
})
|
|
48
48
|
} : o;
|
|
@@ -51,98 +51,98 @@ const X = ["xmlns", "viewBox"], H = ["id"], J = ["stop-color"], R = ["stop-color
|
|
|
51
51
|
width: 128,
|
|
52
52
|
base: e.value.style.basePosition
|
|
53
53
|
})), a = s(() => {
|
|
54
|
-
const o = t.dataset.min ?? 0,
|
|
54
|
+
const o = t.dataset.min ?? 0, m = t.dataset.max ?? 0, F = m - o;
|
|
55
55
|
return {
|
|
56
56
|
min: o,
|
|
57
|
-
max:
|
|
58
|
-
diff:
|
|
57
|
+
max: m,
|
|
58
|
+
diff: F
|
|
59
59
|
};
|
|
60
|
-
}), l =
|
|
61
|
-
|
|
62
|
-
l.value =
|
|
60
|
+
}), l = y(e.value.style.animation.show ? a.value.min : t.dataset.value);
|
|
61
|
+
O(() => t.dataset.value, () => {
|
|
62
|
+
l.value = y(e.value.style.animation.show ? a.value.min : t.dataset.value), x();
|
|
63
63
|
});
|
|
64
|
-
const
|
|
65
|
-
|
|
66
|
-
|
|
64
|
+
const k = s(() => l.value > a.value.max ? a.value.max : l.value < a.value.min ? a.value.min : l.value), z = s(() => a.value.diff / e.value.style.animation.speedMs);
|
|
65
|
+
C(() => {
|
|
66
|
+
x();
|
|
67
67
|
});
|
|
68
|
-
function
|
|
68
|
+
function x() {
|
|
69
69
|
function o() {
|
|
70
70
|
l.value += z.value, l.value < t.dataset.value ? requestAnimationFrame(o) : l.value = t.dataset.value;
|
|
71
71
|
}
|
|
72
72
|
e.value.style.animation.show && (l.value = a.value.min, o());
|
|
73
73
|
}
|
|
74
|
-
const
|
|
75
|
-
return (o,
|
|
76
|
-
style:
|
|
74
|
+
const f = s(() => t.dataset.title ?? ""), _ = s(() => l.value >= 0 ? (k.value - a.value.min) / a.value.diff : (Math.abs(a.value.min) - Math.abs(k.value)) / a.value.diff), $ = s(() => V(e.value.style.colors.min, e.value.style.colors.max, a.value.min, a.value.max, l.value)), w = s(() => e.value.style.dataLabel.autoColor ? $.value : e.value.style.dataLabel.color), M = s(() => e.value.style.track.autoColor ? $.value : e.value.style.track.color);
|
|
75
|
+
return (o, m) => (n(), v("div", {
|
|
76
|
+
style: c(`font-family:${e.value.style.fontFamily};width: 100%; background:${e.value.style.background}`)
|
|
77
77
|
}, [
|
|
78
|
-
e.value.style.title.show &&
|
|
78
|
+
e.value.style.title.show && f.value && e.value.style.title.position === "top" ? (n(), v("div", {
|
|
79
79
|
key: 0,
|
|
80
80
|
class: "vue-data-ui-sparkgauge-label",
|
|
81
|
-
style:
|
|
82
|
-
},
|
|
83
|
-
|
|
81
|
+
style: c(`font-size:${e.value.style.title.fontSize}px;text-align:${e.value.style.title.textAlign};font-weight:${e.value.style.title.bold ? "bold" : "normal"};color:${e.value.style.title.color}`)
|
|
82
|
+
}, g(f.value), 5)) : d("", !0),
|
|
83
|
+
b.value ? (n(), v("svg", {
|
|
84
84
|
key: 1,
|
|
85
|
-
xmlns:
|
|
85
|
+
xmlns: i(q),
|
|
86
86
|
viewBox: `0 0 ${u.value.width} ${u.value.height}`,
|
|
87
|
-
style:
|
|
87
|
+
style: c(`overflow: visible; background:${e.value.style.background}; width:100%;`)
|
|
88
88
|
}, [
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
id: `gradient_${
|
|
89
|
+
r("defs", null, [
|
|
90
|
+
r("linearGradient", {
|
|
91
|
+
id: `gradient_${h.value}`,
|
|
92
92
|
x1: "-10%",
|
|
93
93
|
y1: "100%",
|
|
94
94
|
x2: "110%",
|
|
95
95
|
y2: "100%"
|
|
96
96
|
}, [
|
|
97
|
-
|
|
97
|
+
r("stop", {
|
|
98
98
|
offset: "0%",
|
|
99
99
|
"stop-color": e.value.style.colors.min
|
|
100
|
-
}, null, 8,
|
|
101
|
-
|
|
100
|
+
}, null, 8, Y),
|
|
101
|
+
r("stop", {
|
|
102
102
|
offset: "100%",
|
|
103
103
|
"stop-color": e.value.style.colors.max
|
|
104
|
-
}, null, 8,
|
|
105
|
-
], 8,
|
|
104
|
+
}, null, 8, J)
|
|
105
|
+
], 8, R)
|
|
106
106
|
]),
|
|
107
|
-
|
|
107
|
+
r("path", {
|
|
108
108
|
d: `M10 ${u.value.base} A 1 1 0 1 1 118 ${u.value.base}`,
|
|
109
109
|
stroke: e.value.style.gutter.color,
|
|
110
110
|
"stroke-width": 8,
|
|
111
111
|
"stroke-linecap": e.value.style.gutter.strokeLinecap,
|
|
112
112
|
fill: "none"
|
|
113
|
-
}, null, 8,
|
|
114
|
-
|
|
113
|
+
}, null, 8, K),
|
|
114
|
+
_.value !== 0 ? (n(), v("path", {
|
|
115
115
|
key: 0,
|
|
116
116
|
d: `M10 ${u.value.base} A 1 1 0 1 1 118 ${u.value.base}`,
|
|
117
|
-
stroke: e.value.style.colors.showGradient ? `url(#gradient_${
|
|
117
|
+
stroke: e.value.style.colors.showGradient ? `url(#gradient_${h.value})` : M.value,
|
|
118
118
|
"stroke-width": 8,
|
|
119
119
|
"stroke-linecap": e.value.style.track.strokeLinecap,
|
|
120
120
|
fill: "none",
|
|
121
121
|
"stroke-dasharray": 169.5,
|
|
122
|
-
"stroke-dashoffset": 169.5 - 169.5 *
|
|
123
|
-
class:
|
|
124
|
-
style:
|
|
125
|
-
}, null, 14,
|
|
126
|
-
|
|
122
|
+
"stroke-dashoffset": 169.5 - 169.5 * _.value,
|
|
123
|
+
class: j({ "vue-ui-sparkgauge-track": e.value.style.animation.show }),
|
|
124
|
+
style: c(e.value.style.animation.show ? `animation: vue-ui-sparkgauge-animation ${e.value.style.animation.speedMs}ms ease-in;` : "")
|
|
125
|
+
}, null, 14, Q)) : d("", !0),
|
|
126
|
+
r("text", {
|
|
127
127
|
"text-anchor": "middle",
|
|
128
128
|
x: u.value.width / 2,
|
|
129
129
|
y: u.value.base + 6 + e.value.style.dataLabel.offsetY,
|
|
130
130
|
"font-size": e.value.style.dataLabel.fontSize,
|
|
131
|
-
fill:
|
|
131
|
+
fill: w.value,
|
|
132
132
|
"font-weight": e.value.style.dataLabel.bold ? "bold" : "normal"
|
|
133
|
-
},
|
|
133
|
+
}, g(i(P)(
|
|
134
134
|
e.value.style.dataLabel.formatter,
|
|
135
|
-
l.value,
|
|
136
|
-
|
|
135
|
+
i(p)(l.value),
|
|
136
|
+
i(T)({
|
|
137
137
|
p: e.value.style.dataLabel.prefix,
|
|
138
|
-
v: l.value,
|
|
138
|
+
v: i(p)(l.value),
|
|
139
139
|
s: e.value.style.dataLabel.suffix,
|
|
140
140
|
r: e.value.style.dataLabel.rounding
|
|
141
141
|
}),
|
|
142
|
-
{ datapoint: l.value, color:
|
|
143
|
-
)), 9,
|
|
144
|
-
], 12,
|
|
145
|
-
|
|
142
|
+
{ datapoint: i(p)(l.value), color: w.value }
|
|
143
|
+
)), 9, W)
|
|
144
|
+
], 12, H)) : d("", !0),
|
|
145
|
+
b.value ? d("", !0) : (n(), B(X, {
|
|
146
146
|
key: 2,
|
|
147
147
|
config: {
|
|
148
148
|
type: "gauge",
|
|
@@ -154,14 +154,14 @@ const X = ["xmlns", "viewBox"], H = ["id"], J = ["stop-color"], R = ["stop-color
|
|
|
154
154
|
}
|
|
155
155
|
}
|
|
156
156
|
}, null, 8, ["config"])),
|
|
157
|
-
e.value.style.title.show &&
|
|
157
|
+
e.value.style.title.show && f.value && e.value.style.title.position === "bottom" ? (n(), v("div", {
|
|
158
158
|
key: 3,
|
|
159
159
|
class: "vue-data-ui-sparkgauge-label",
|
|
160
|
-
style:
|
|
161
|
-
},
|
|
160
|
+
style: c(`font-size:${e.value.style.title.fontSize}px;text-align:${e.value.style.title.textAlign};font-weight:${e.value.style.title.bold ? "bold" : "normal"};font-weight:${e.value.style.title.bold ? "bold" : "normal"};color:${e.value.style.title.color}`)
|
|
161
|
+
}, g(f.value), 5)) : d("", !0)
|
|
162
162
|
], 4));
|
|
163
163
|
}
|
|
164
164
|
};
|
|
165
165
|
export {
|
|
166
|
-
|
|
166
|
+
le as default
|
|
167
167
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-D2ZScauW.cjs"),g=require("./useNestedProp-BU7yyXFA.cjs"),C=require("./vue-ui-skeleton-BLhbQje-.cjs"),N=["xmlns","viewBox"],$=["id"],w=["stop-color"],S=["stop-color"],L=["d","stroke","stroke-linecap"],B=["d","stroke","stroke-linecap","stroke-dashoffset"],E=["x","y","font-size","fill","font-weight"],z={__name:"vue-ui-sparkgauge",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(k){const a=k,{vue_ui_sparkgauge:b}=o.useConfig(),c=e.computed(()=>!!a.dataset&&Object.keys(a.dataset).length);e.onMounted(()=>{o.objectIsEmpty(a.dataset)?o.error({componentName:"VueUiSparkgauge",type:"dataset"}):o.getMissingDatasetAttributes({datasetObject:a.dataset,requiredAttributes:["value","min","max"]}).forEach(u=>{o.error({componentName:"VueUiSparkgauge",type:"datasetAttribute",property:u})})});const v=e.ref(o.createUid()),t=e.computed(()=>{const u=g.useNestedProp({userConfig:a.config,defaultConfig:b});return u.theme?{...g.useNestedProp({userConfig:o.themes.vue_ui_sparkgauge[u.theme]||a.config,defaultConfig:u})}:u}),n=e.computed(()=>({height:t.value.style.height,width:128,base:t.value.style.basePosition})),l=e.computed(()=>{const u=a.dataset.min??0,i=a.dataset.max??0,_=i-u;return{min:u,max:i,diff:_}}),s=e.ref(t.value.style.animation.show?l.value.min:a.dataset.value);e.watch(()=>a.dataset.value,()=>{s.value=e.ref(t.value.style.animation.show?l.value.min:a.dataset.value),m()});const d=e.computed(()=>s.value>l.value.max?l.value.max:s.value<l.value.min?l.value.min:s.value),h=e.computed(()=>l.value.diff/t.value.style.animation.speedMs);e.onMounted(()=>{m()});function m(){function u(){s.value+=h.value,s.value<a.dataset.value?requestAnimationFrame(u):s.value=a.dataset.value}t.value.style.animation.show&&(s.value=l.value.min,u())}const r=e.computed(()=>a.dataset.title??""),f=e.computed(()=>s.value>=0?(d.value-l.value.min)/l.value.diff:(Math.abs(l.value.min)-Math.abs(d.value))/l.value.diff),y=e.computed(()=>o.interpolateColorHex(t.value.style.colors.min,t.value.style.colors.max,l.value.min,l.value.max,s.value)),p=e.computed(()=>t.value.style.dataLabel.autoColor?y.value:t.value.style.dataLabel.color),x=e.computed(()=>t.value.style.track.autoColor?y.value:t.value.style.track.color);return(u,i)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width: 100%; background:${t.value.style.background}`)},[t.value.style.title.show&&r.value&&t.value.style.title.position==="top"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"vue-data-ui-sparkgauge-label",style:e.normalizeStyle(`font-size:${t.value.style.title.fontSize}px;text-align:${t.value.style.title.textAlign};font-weight:${t.value.style.title.bold?"bold":"normal"};color:${t.value.style.title.color}`)},e.toDisplayString(r.value),5)):e.createCommentVNode("",!0),c.value?(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(o.XMLNS),viewBox:`0 0 ${n.value.width} ${n.value.height}`,style:e.normalizeStyle(`overflow: visible; background:${t.value.style.background}; width:100%;`)},[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`gradient_${v.value}`,x1:"-10%",y1:"100%",x2:"110%",y2:"100%"},[e.createElementVNode("stop",{offset:"0%","stop-color":t.value.style.colors.min},null,8,w),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.colors.max},null,8,S)],8,$)]),e.createElementVNode("path",{d:`M10 ${n.value.base} A 1 1 0 1 1 118 ${n.value.base}`,stroke:t.value.style.gutter.color,"stroke-width":8,"stroke-linecap":t.value.style.gutter.strokeLinecap,fill:"none"},null,8,L),f.value!==0?(e.openBlock(),e.createElementBlock("path",{key:0,d:`M10 ${n.value.base} A 1 1 0 1 1 118 ${n.value.base}`,stroke:t.value.style.colors.showGradient?`url(#gradient_${v.value})`:x.value,"stroke-width":8,"stroke-linecap":t.value.style.track.strokeLinecap,fill:"none","stroke-dasharray":169.5,"stroke-dashoffset":169.5-169.5*f.value,class:e.normalizeClass({"vue-ui-sparkgauge-track":t.value.style.animation.show}),style:e.normalizeStyle(t.value.style.animation.show?`animation: vue-ui-sparkgauge-animation ${t.value.style.animation.speedMs}ms ease-in;`:"")},null,14,B)):e.createCommentVNode("",!0),e.createElementVNode("text",{"text-anchor":"middle",x:n.value.width/2,y:n.value.base+6+t.value.style.dataLabel.offsetY,"font-size":t.value.style.dataLabel.fontSize,fill:p.value,"font-weight":t.value.style.dataLabel.bold?"bold":"normal"},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.dataLabel.formatter,e.unref(o.checkNaN)(s.value),e.unref(o.dataLabel)({p:t.value.style.dataLabel.prefix,v:e.unref(o.checkNaN)(s.value),s:t.value.style.dataLabel.suffix,r:t.value.style.dataLabel.rounding}),{datapoint:e.unref(o.checkNaN)(s.value),color:p.value})),9,E)],12,N)):e.createCommentVNode("",!0),c.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(C.default,{key:2,config:{type:"gauge",style:{backgroundColor:t.value.style.background,gauge:{color:"#CCCCCC"}}}},null,8,["config"])),t.value.style.title.show&&r.value&&t.value.style.title.position==="bottom"?(e.openBlock(),e.createElementBlock("div",{key:3,class:"vue-data-ui-sparkgauge-label",style:e.normalizeStyle(`font-size:${t.value.style.title.fontSize}px;text-align:${t.value.style.title.textAlign};font-weight:${t.value.style.title.bold?"bold":"normal"};font-weight:${t.value.style.title.bold?"bold":"normal"};color:${t.value.style.title.color}`)},e.toDisplayString(r.value),5)):e.createCommentVNode("",!0)],4))}};exports.default=z;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),a=require("./index-CDK3omwG.cjs"),k=require("./useNestedProp-CaaW8JIS.cjs"),z=require("./Shape-DWZSJJ6-.cjs"),D=require("./vue-ui-skeleton-DRDC3yxK.cjs"),F=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),M={key:0},A={key:1},H=["xmlns","viewBox"],q=["id"],I=["stop-color"],U=["stop-color"],W=["id"],O=["stop-color"],j=["stop-color"],P=["id"],G=["stop-color"],T=["stop-color"],X={key:0},Y=["x","y","height","width","fill","stroke","stroke-width","rx"],R={key:1},J=["x","y","font-size","font-weight","fill"],K=["x","y","font-size","fill"],Q=["x","y","font-size","fill"],Z=["height","width","x","onMouseover","stroke","stroke-width","rx","stroke-dasharray","onClick"],ee={__name:"vue-ui-sparkhistogram",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectDatapoint"],setup(b,{emit:_}){const u=b;e.useCssVars(o=>({"07c89730":w.value}));const{vue_ui_sparkhistogram:x}=a.useConfig(),f=e.computed(()=>!!u.dataset&&u.dataset.length);e.onMounted(()=>{a.objectIsEmpty(u.dataset)?a.error({componentName:"VueUiSparkHistogram",type:"dataset"}):u.dataset.forEach((o,n)=>{a.getMissingDatasetAttributes({datasetObject:o,requiredAttributes:["value"]}).forEach(l=>{a.error({componentName:"VueUiSparkHistogram",type:"datasetSerieAttribute",property:l,index:n})})})});const v=e.ref(a.createUid()),t=e.computed(()=>{const o=k.useNestedProp({userConfig:u.config,defaultConfig:x});return o.theme?{...k.useNestedProp({userConfig:a.themes.vue_ui_sparkhistogram[o.theme]||u.config,defaultConfig:o})}:o}),c=e.computed(()=>{const o=t.value.style.layout.height,n=t.value.style.layout.width,l=t.value.style.layout.padding.top,s=o-t.value.style.layout.padding.bottom,d=t.value.style.layout.padding.left,y=n-t.value.style.layout.padding.right,p=l+(o-l-t.value.style.layout.padding.bottom)/2,g=o-t.value.style.layout.padding.top-t.value.style.layout.padding.bottom,m=n-t.value.style.layout.padding.left-t.value.style.layout.padding.right;return{bottom:s,centerY:p,drawingHeight:g,drawingWidth:m,height:o,left:d,right:y,top:l,width:n}}),B=e.computed(()=>Math.max(...u.dataset.map(o=>Math.abs(o.value||0))));function $(o){return Math.abs(o)/B.value}const i=e.computed(()=>u.dataset.map((o,n)=>{const l=$(o.value||0),s=c.value.drawingHeight*l,d=c.value.drawingWidth/u.dataset.length,y=d*(t.value.style.bars.gap/100),p=d-y,g=c.value.centerY-s/2,m=c.value.left+(y/2+n*d),S=c.value.left+n*d,h=typeof o.intensity>"u"?100:Math.round(o.intensity*100),C=o.color?o.color:o.value>=0?`${t.value.style.bars.colors.positive}${a.opacity[h]}`:`${t.value.style.bars.colors.negative}${a.opacity[h]}`,N=o.color?o.color:o.value>=0?t.value.style.bars.colors.positive:t.value.style.bars.colors.negative,L=o.color?`url(#gradient_datapoint_${n}_${v.value})`:o.value>=0?`url(#gradient_positive_${n}_${v.value})`:`url(#gradient_negative_${n}_${v.value})`,V=m+p/2;return{...o,color:C,gradient:L,height:s,intensity:h,proportion:l,stroke:N,textAnchor:V,trapX:S,unitWidth:d,width:p,x:m,y:g}})),r=e.ref(null);function E(o,n){_("selectDatapoint",{datapoint:o,index:n})}const w=e.computed(()=>`${t.value.style.animation.speedMs}ms`);return(o,n)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`width:100%;background:${t.value.style.backgroundColor};font-family:${t.value.style.fontFamily}`),onMouseleave:n[1]||(n[1]=l=>r.value=null)},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:calc(100% - 12px);background:${t.value.style.backgroundColor};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.createTextVNode(e.toDisplayString(t.value.style.title.text)+" ",1),r.value!==null?(e.openBlock(),e.createElementBlock("span",M,"- "+e.toDisplayString(i.value[r.value].timeLabel||"")+" "+e.toDisplayString(e.unref(a.applyDataLabel)(t.value.style.labels.value.formatter,i.value[r.value].value,e.unref(a.dataLabel)({p:t.value.style.labels.value.prefix,v:i.value[r.value].value,s:t.value.style.labels.value.suffix,r:t.value.style.labels.value.rounding}),{datapoint:i.value[r.value],seriesIndex:r.value})),1)):e.createCommentVNode("",!0),![void 0,null].includes(r.value)&&![null,void 0].includes(i.value[r.value].valueLabel)?(e.openBlock(),e.createElementBlock("span",A,"("+e.toDisplayString(i.value[r.value].valueLabel||0)+")",1)):e.createCommentVNode("",!0)],4),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(a.XMLNS),viewBox:`0 0 ${c.value.width} ${c.value.height}`,style:{overflow:"visible"}},[e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("radialGradient",{id:`gradient_positive_${s}_${v.value}`,cy:"50%",cx:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(a.shiftHue)(t.value.style.bars.colors.positive,.05)}${e.unref(a.opacity)[l.intensity]}`},null,8,I),e.createElementVNode("stop",{offset:"100%","stop-color":`${t.value.style.bars.colors.positive}${e.unref(a.opacity)[l.intensity]}`},null,8,U)],8,q))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("radialGradient",{id:`gradient_negative_${s}_${v.value}`,cy:"50%",cx:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(a.shiftHue)(t.value.style.bars.colors.negative,.05)}${e.unref(a.opacity)[l.intensity]}`},null,8,O),e.createElementVNode("stop",{offset:"100%","stop-color":`${t.value.style.bars.colors.negative}${e.unref(a.opacity)[l.intensity]}`},null,8,j)],8,W))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("radialGradient",{id:`gradient_datapoint_${s}_${v.value}`,cy:"50%",cx:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(a.shiftHue)(l.color,.05)}${e.unref(a.opacity)[l.intensity]}`},null,8,G),e.createElementVNode("stop",{offset:"100%","stop-color":`${l.color}${e.unref(a.opacity)[l.intensity]}`},null,8,T)],8,P))),256))]),!t.value.style.bars.shape||t.value.style.bars.shape==="square"?(e.openBlock(),e.createElementBlock("g",X,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("rect",{x:l.x,y:l.y,height:l.height,width:l.width,fill:t.value.style.bars.colors.gradient.show?l.gradient:l.color,stroke:l.stroke,"stroke-width":t.value.style.bars.strokeWidth,rx:`${t.value.style.bars.borderRadius*l.proportion/12}%`,class:e.normalizeClass({"vue-ui-sparkhistogram-shape":t.value.style.animation.show})},null,10,Y))),256))])):(e.openBlock(),e.createElementBlock("g",R,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createBlock(z._sfc_main,{plot:{x:l.x+l.width/2,y:l.y+l.height/2},color:t.value.style.bars.colors.gradient.show?l.gradient:l.color,shape:t.value.style.bars.shape,radius:l.height*.4,class:e.normalizeClass({"vue-ui-sparkhistogram-shape":t.value.style.animation.show})},null,8,["plot","color","shape","radius","class"]))),256))])),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("text",{"text-anchor":"middle",x:l.textAnchor,y:l.y-t.value.style.labels.value.fontSize/3+t.value.style.labels.value.offsetY,"font-size":t.value.style.labels.value.fontSize,"font-weight":t.value.style.labels.value.bold?"bold":"normal",fill:t.value.style.labels.value.color},e.toDisplayString(t.value.style.labels.value.prefix)+e.toDisplayString(isNaN(l.value)?"":Number(l.value.toFixed(t.value.style.labels.value.rounding)).toLocaleString())+e.toDisplayString(t.value.style.labels.value.suffix),9,J))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("g",null,[l.valueLabel?(e.openBlock(),e.createElementBlock("text",{key:0,x:l.textAnchor,y:l.y+l.height+t.value.style.labels.valueLabel.fontSize,"font-size":t.value.style.labels.valueLabel.fontSize,"text-anchor":"middle",fill:t.value.style.labels.valueLabel.color},e.toDisplayString(l.valueLabel),9,K)):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("g",null,[l.timeLabel?(e.openBlock(),e.createElementBlock("text",{key:0,x:l.textAnchor,y:c.value.height-t.value.style.labels.timeLabel.fontSize/2,"font-size":t.value.style.labels.timeLabel.fontSize,fill:t.value.style.labels.timeLabel.color,"text-anchor":"middle"},e.toDisplayString(l.timeLabel),9,Q)):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("rect",{height:c.value.height,width:l.unitWidth,fill:"transparent",x:l.trapX,y:0,onMouseover:d=>r.value=s,onMouseleave:n[0]||(n[0]=d=>r.value=null),stroke:r.value!==null&&r.value===s?t.value.style.selector.stroke:"","stroke-width":r.value!==null&&r.value===s?t.value.style.selector.strokeWidth:0,rx:t.value.style.selector.borderRadius,"stroke-dasharray":t.value.style.selector.strokeDasharray,onClick:()=>E(l,s)},null,40,Z)]))),256))],8,H)):e.createCommentVNode("",!0),f.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(D.default,{key:2,config:{type:"sparkHistogram",style:{backgroundColor:t.value.style.backgroundColor,sparkHistogram:{color:"#CCCCCC"}}}},null,8,["config"]))],36))}},te=F._export_sfc(ee,[["__scopeId","data-v-27ede5f8"]]);exports.default=te;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),a=require("./index-D2ZScauW.cjs"),k=require("./useNestedProp-BU7yyXFA.cjs"),z=require("./Shape-BoXM3HKY.cjs"),D=require("./vue-ui-skeleton-BLhbQje-.cjs"),F=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),M={key:0},A={key:1},H=["xmlns","viewBox"],q=["id"],I=["stop-color"],U=["stop-color"],W=["id"],O=["stop-color"],j=["stop-color"],P=["id"],G=["stop-color"],T=["stop-color"],X={key:0},Y=["x","y","height","width","fill","stroke","stroke-width","rx"],R={key:1},J=["x","y","font-size","font-weight","fill"],K=["x","y","font-size","fill"],Q=["x","y","font-size","fill"],Z=["height","width","x","onMouseover","stroke","stroke-width","rx","stroke-dasharray","onClick"],ee={__name:"vue-ui-sparkhistogram",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectDatapoint"],setup(b,{emit:_}){const u=b;e.useCssVars(o=>({"07c89730":w.value}));const{vue_ui_sparkhistogram:x}=a.useConfig(),f=e.computed(()=>!!u.dataset&&u.dataset.length);e.onMounted(()=>{a.objectIsEmpty(u.dataset)?a.error({componentName:"VueUiSparkHistogram",type:"dataset"}):u.dataset.forEach((o,n)=>{a.getMissingDatasetAttributes({datasetObject:o,requiredAttributes:["value"]}).forEach(l=>{a.error({componentName:"VueUiSparkHistogram",type:"datasetSerieAttribute",property:l,index:n})})})});const v=e.ref(a.createUid()),t=e.computed(()=>{const o=k.useNestedProp({userConfig:u.config,defaultConfig:x});return o.theme?{...k.useNestedProp({userConfig:a.themes.vue_ui_sparkhistogram[o.theme]||u.config,defaultConfig:o})}:o}),c=e.computed(()=>{const o=t.value.style.layout.height,n=t.value.style.layout.width,l=t.value.style.layout.padding.top,s=o-t.value.style.layout.padding.bottom,d=t.value.style.layout.padding.left,y=n-t.value.style.layout.padding.right,p=l+(o-l-t.value.style.layout.padding.bottom)/2,g=o-t.value.style.layout.padding.top-t.value.style.layout.padding.bottom,m=n-t.value.style.layout.padding.left-t.value.style.layout.padding.right;return{bottom:s,centerY:p,drawingHeight:g,drawingWidth:m,height:o,left:d,right:y,top:l,width:n}}),B=e.computed(()=>Math.max(...u.dataset.map(o=>Math.abs(o.value||0))));function $(o){return Math.abs(o)/B.value}const i=e.computed(()=>u.dataset.map((o,n)=>{const l=$(o.value||0),s=c.value.drawingHeight*l,d=c.value.drawingWidth/u.dataset.length,y=d*(t.value.style.bars.gap/100),p=d-y,g=c.value.centerY-s/2,m=c.value.left+(y/2+n*d),S=c.value.left+n*d,h=typeof o.intensity>"u"?100:Math.round(o.intensity*100),C=o.color?o.color:o.value>=0?`${t.value.style.bars.colors.positive}${a.opacity[h]}`:`${t.value.style.bars.colors.negative}${a.opacity[h]}`,N=o.color?o.color:o.value>=0?t.value.style.bars.colors.positive:t.value.style.bars.colors.negative,L=o.color?`url(#gradient_datapoint_${n}_${v.value})`:o.value>=0?`url(#gradient_positive_${n}_${v.value})`:`url(#gradient_negative_${n}_${v.value})`,V=m+p/2;return{...o,color:C,gradient:L,height:s,intensity:h,proportion:l,stroke:N,textAnchor:V,trapX:S,unitWidth:d,width:p,x:m,y:g}})),r=e.ref(null);function E(o,n){_("selectDatapoint",{datapoint:o,index:n})}const w=e.computed(()=>`${t.value.style.animation.speedMs}ms`);return(o,n)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`width:100%;background:${t.value.style.backgroundColor};font-family:${t.value.style.fontFamily}`),onMouseleave:n[1]||(n[1]=l=>r.value=null)},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:calc(100% - 12px);background:${t.value.style.backgroundColor};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.createTextVNode(e.toDisplayString(t.value.style.title.text)+" ",1),r.value!==null?(e.openBlock(),e.createElementBlock("span",M,"- "+e.toDisplayString(i.value[r.value].timeLabel||"")+" "+e.toDisplayString(e.unref(a.applyDataLabel)(t.value.style.labels.value.formatter,i.value[r.value].value,e.unref(a.dataLabel)({p:t.value.style.labels.value.prefix,v:i.value[r.value].value,s:t.value.style.labels.value.suffix,r:t.value.style.labels.value.rounding}),{datapoint:i.value[r.value],seriesIndex:r.value})),1)):e.createCommentVNode("",!0),![void 0,null].includes(r.value)&&![null,void 0].includes(i.value[r.value].valueLabel)?(e.openBlock(),e.createElementBlock("span",A,"("+e.toDisplayString(i.value[r.value].valueLabel||0)+")",1)):e.createCommentVNode("",!0)],4),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(a.XMLNS),viewBox:`0 0 ${c.value.width} ${c.value.height}`,style:{overflow:"visible"}},[e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("radialGradient",{id:`gradient_positive_${s}_${v.value}`,cy:"50%",cx:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(a.shiftHue)(t.value.style.bars.colors.positive,.05)}${e.unref(a.opacity)[l.intensity]}`},null,8,I),e.createElementVNode("stop",{offset:"100%","stop-color":`${t.value.style.bars.colors.positive}${e.unref(a.opacity)[l.intensity]}`},null,8,U)],8,q))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("radialGradient",{id:`gradient_negative_${s}_${v.value}`,cy:"50%",cx:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(a.shiftHue)(t.value.style.bars.colors.negative,.05)}${e.unref(a.opacity)[l.intensity]}`},null,8,O),e.createElementVNode("stop",{offset:"100%","stop-color":`${t.value.style.bars.colors.negative}${e.unref(a.opacity)[l.intensity]}`},null,8,j)],8,W))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("radialGradient",{id:`gradient_datapoint_${s}_${v.value}`,cy:"50%",cx:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(a.shiftHue)(l.color,.05)}${e.unref(a.opacity)[l.intensity]}`},null,8,G),e.createElementVNode("stop",{offset:"100%","stop-color":`${l.color}${e.unref(a.opacity)[l.intensity]}`},null,8,T)],8,P))),256))]),!t.value.style.bars.shape||t.value.style.bars.shape==="square"?(e.openBlock(),e.createElementBlock("g",X,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("rect",{x:l.x,y:l.y,height:l.height,width:l.width,fill:t.value.style.bars.colors.gradient.show?l.gradient:l.color,stroke:l.stroke,"stroke-width":t.value.style.bars.strokeWidth,rx:`${t.value.style.bars.borderRadius*l.proportion/12}%`,class:e.normalizeClass({"vue-ui-sparkhistogram-shape":t.value.style.animation.show})},null,10,Y))),256))])):(e.openBlock(),e.createElementBlock("g",R,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createBlock(z._sfc_main,{plot:{x:l.x+l.width/2,y:l.y+l.height/2},color:t.value.style.bars.colors.gradient.show?l.gradient:l.color,shape:t.value.style.bars.shape,radius:l.height*.4,class:e.normalizeClass({"vue-ui-sparkhistogram-shape":t.value.style.animation.show})},null,8,["plot","color","shape","radius","class"]))),256))])),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("text",{"text-anchor":"middle",x:l.textAnchor,y:l.y-t.value.style.labels.value.fontSize/3+t.value.style.labels.value.offsetY,"font-size":t.value.style.labels.value.fontSize,"font-weight":t.value.style.labels.value.bold?"bold":"normal",fill:t.value.style.labels.value.color},e.toDisplayString(t.value.style.labels.value.prefix)+e.toDisplayString(isNaN(l.value)?"":Number(l.value.toFixed(t.value.style.labels.value.rounding)).toLocaleString())+e.toDisplayString(t.value.style.labels.value.suffix),9,J))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("g",null,[l.valueLabel?(e.openBlock(),e.createElementBlock("text",{key:0,x:l.textAnchor,y:l.y+l.height+t.value.style.labels.valueLabel.fontSize,"font-size":t.value.style.labels.valueLabel.fontSize,"text-anchor":"middle",fill:t.value.style.labels.valueLabel.color},e.toDisplayString(l.valueLabel),9,K)):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("g",null,[l.timeLabel?(e.openBlock(),e.createElementBlock("text",{key:0,x:l.textAnchor,y:c.value.height-t.value.style.labels.timeLabel.fontSize/2,"font-size":t.value.style.labels.timeLabel.fontSize,fill:t.value.style.labels.timeLabel.color,"text-anchor":"middle"},e.toDisplayString(l.timeLabel),9,Q)):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(l,s)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("rect",{height:c.value.height,width:l.unitWidth,fill:"transparent",x:l.trapX,y:0,onMouseover:d=>r.value=s,onMouseleave:n[0]||(n[0]=d=>r.value=null),stroke:r.value!==null&&r.value===s?t.value.style.selector.stroke:"","stroke-width":r.value!==null&&r.value===s?t.value.style.selector.strokeWidth:0,rx:t.value.style.selector.borderRadius,"stroke-dasharray":t.value.style.selector.strokeDasharray,onClick:()=>E(l,s)},null,40,Z)]))),256))],8,H)):e.createCommentVNode("",!0),f.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(D.default,{key:2,config:{type:"sparkHistogram",style:{backgroundColor:t.value.style.backgroundColor,sparkHistogram:{color:"#CCCCCC"}}}},null,8,["config"]))],36))}},te=F._export_sfc(ee,[["__scopeId","data-v-27ede5f8"]]);exports.default=te;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useCssVars as q, computed as _, onMounted as R, ref as M, openBlock as a, createElementBlock as o, normalizeStyle as w, createElementVNode as h, createTextVNode as T, toDisplayString as v, unref as r, createCommentVNode as p, Fragment as f, renderList as g, normalizeClass as N, createBlock as A } from "vue";
|
|
2
|
-
import { u as P, o as J, e as D, g as K, c as Q, t as Z,
|
|
3
|
-
import { u as F } from "./useNestedProp-
|
|
4
|
-
import { _ as ae } from "./Shape-
|
|
5
|
-
import oe from "./vue-ui-skeleton-
|
|
2
|
+
import { u as P, o as J, e as D, g as K, c as Q, t as Z, w as b, i as ee, f as te, X as le, v as z } from "./index-BshV7sX1.js";
|
|
3
|
+
import { u as F } from "./useNestedProp-B235bkr5.js";
|
|
4
|
+
import { _ as ae } from "./Shape-BsAETTif.js";
|
|
5
|
+
import oe from "./vue-ui-skeleton-7qakoAGH.js";
|
|
6
6
|
import { _ as se } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
7
7
|
const ue = { key: 0 }, ie = { key: 1 }, ne = ["xmlns", "viewBox"], re = ["id"], ve = ["stop-color"], de = ["stop-color"], ce = ["id"], ye = ["stop-color"], he = ["stop-color"], fe = ["id"], ge = ["stop-color"], pe = ["stop-color"], be = { key: 0 }, me = ["x", "y", "height", "width", "fill", "stroke", "stroke-width", "rx"], _e = { key: 1 }, xe = ["x", "y", "font-size", "font-weight", "fill"], ke = ["x", "y", "font-size", "fill"], $e = ["x", "y", "font-size", "fill"], we = ["height", "width", "x", "onMouseover", "stroke", "stroke-width", "rx", "stroke-dasharray", "onClick"], Ce = {
|
|
8
8
|
__name: "vue-ui-sparkhistogram",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-CDK3omwG.cjs"),C=require("./useNestedProp-CaaW8JIS.cjs"),F=require("./vue-ui-skeleton-DRDC3yxK.cjs"),E=require("./useResponsive-B3TrDDIG.cjs"),T=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),q=["id"],G=["xmlns","viewBox"],O=["id"],j=["stop-color"],R=["stop-color"],H=["id"],U=["stop-color"],X=["stop-color"],Z=["id"],Y=["stop-color"],J=["stop-color"],K={key:0},Q=["d","fill"],ee=["d","fill"],te=["d","stroke","stroke-width"],le=["x1","x2","y1","y2","stroke","stroke-width"],ae=["x","y","width","height","fill","rx"],oe=["x1","x2","y1","y2","stroke","stroke-width","stroke-dasharray"],ne=["x1","x2","y1","y2","stroke","stroke-dasharray","stroke-width"],ue=["cx","cy","r","fill","stroke","stroke-width"],re=["x","y","font-size","font-weight","fill"],se=["x","y","height","width","onMouseenter","onClick"],ie={__name:"vue-ui-sparkline",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}},showInfo:{type:Boolean,default:!0},selectedIndex:{type:Number,default:void 0}},emits:["hoverIndex","selectDatapoint"],setup(f,{emit:x}){const i=f,{vue_ui_sparkline:I}=u.useConfig(),g=e.computed(()=>!!i.dataset&&i.dataset.length),v=e.ref(u.createUid()),_=e.ref(null),B=e.ref(null),t=e.computed(()=>{const l=C.useNestedProp({userConfig:i.config,defaultConfig:I});return l.theme?{...C.useNestedProp({userConfig:u.themes.vue_ui_sparkline[l.theme]||i.config,defaultConfig:l})}:l}),p=e.ref(i.dataset.map(l=>t.value.style.animation.show?{...l,value:null}:{...l,value:[void 0].includes(l.value)?null:l.value})),L=e.ref(null);e.onMounted(()=>{if(u.objectIsEmpty(i.dataset)?u.error({componentName:"VueUiSparkline",type:"dataset"}):i.dataset.forEach((l,n)=>{u.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["period","value"]}).forEach(a=>{u.error({componentName:"VueUiSparkline",type:"datasetSerieAttribute",property:a,index:n})})}),t.value.style.animation.show&&i.dataset.length>1){let a=function(){n<i.dataset.length?(p.value.push(i.dataset[n]),setTimeout(()=>{requestAnimationFrame(a)},l)):p.value=i.dataset,n+=1};p.value=[];const l=t.value.style.animation.animationFrames/i.dataset.length;let n=0;a()}if(t.value.responsive){const l=E.throttle(()=>{const{width:n,height:a}=E.useResponsive({chart:_.value,title:t.value.style.title.show&&i.showInfo?B.value:null});o.value.width=n,o.value.height=a,o.value.chartWidth=t.value.style.chartWidth/500*n,o.value.padding=.06*n});L.value=new ResizeObserver(l),L.value.observe(_.value.parentNode)}});const o=e.ref({height:80,width:500,chartWidth:t.value.style.chartWidth,padding:30}),S=e.ref(6),r=e.computed(()=>({top:12,left:0,right:o.value.width,bottom:o.value.height-3,start:i.showInfo&&t.value.style.dataLabel.show&&t.value.style.dataLabel.position==="left"?o.value.width-o.value.chartWidth:o.value.padding,width:i.showInfo&&t.value.style.dataLabel.show?o.value.chartWidth:o.value.width-o.value.padding,height:o.value.height-12})),w=e.computed(()=>Math.min(...p.value.map(l=>isNaN(l.value)||[void 0,null,"NaN",NaN,1/0,-1/0].includes(l.value)?0:l.value||0))),M=e.computed(()=>Math.max(...p.value.map(l=>isNaN(l.value)||[void 0,null,"NaN",NaN,1/0,-1/0].includes(l.value)?0:l.value||0))),m=e.computed(()=>{const l=w.value>=0?0:w.value;return Math.abs(l)}),z=e.computed(()=>M.value+m.value+S.value),b=e.computed(()=>r.value.bottom-r.value.height*N(m.value));function N(l){return l/z.value}const h=e.computed(()=>i.dataset.length-1),s=e.computed(()=>p.value.map((l,n)=>{const a=isNaN(l.value)||[void 0,null,"NaN",NaN,1/0,-1/0].includes(l.value)?0:l.value||0;return{absoluteValue:a,period:l.period,plotValue:a+m.value,toMax:N(a+m.value),x:r.value.start+n*(r.value.width/(h.value+1)>o.padding?o.padding:r.value.width/(h.value+1)),y:r.value.bottom-r.value.height*N(a+m.value),id:`plot_${v.value}_${n}`,color:k.value?t.value.style.bar.color:t.value.style.area.useGradient?u.shiftHue(t.value.style.line.color,.05*(1-n/h.value)):t.value.style.line.color,width:r.value.width/(h.value+1)>o.padding?o.padding:r.value.width/(h.value+1)}})),P=e.computed(()=>{const l={x:s.value[0].x,y:o.value.height-6},n={x:s.value[s.value.length-1].x,y:o.value.height-6},a=[];return s.value.forEach(d=>{a.push(`${d.x},${d.y} `)}),[l.x,l.y,...a,n.x,n.y].toString()}),c=e.ref(void 0);function D(l,n){c.value=l,x("hoverIndex",{index:n})}function A(){c.value=void 0,x("hoverIndex",{index:void 0})}const y=e.computed(()=>{if(g.value){const l=s.value.map(a=>a.absoluteValue),n=l.reduce((a,d)=>a+d,0);return{latest:s.value[s.value.length-1].absoluteValue,sum:n,average:n/s.value.length,median:u.calcMedian(l),trend:u.calcLinearProgression(s.value.map(({x:a,y:d,absoluteValue:V})=>({x:a,y:d,value:V}))).trend}}else return{latest:null,sum:null,average:null,median:null,trend:null}}),$=e.computed(()=>g.value?t.value.style.dataLabel.valueType==="latest"?y.value.latest:t.value.style.dataLabel.valueType==="sum"?y.value.sum:t.value.style.dataLabel.valueType==="average"?y.value.average:0:0),k=e.computed(()=>t.value.type&&t.value.type==="bar");function W(l,n){x("selectDatapoint",{datapoint:l,index:n})}return(l,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"sparklineChart",ref:_,class:"vue-ui-sparkline",id:v.value,style:e.normalizeStyle(`width:100%;font-family:${t.value.style.fontFamily}`)},[e.renderSlot(l.$slots,"before",e.normalizeProps(e.guardReactiveProps({selected:c.value,latest:y.value.latest,sum:y.value.sum,average:y.value.average,median:y.value.median,trend:y.value.trend})),void 0,!0),t.value.style.title.show&&f.showInfo?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:B,class:"vue-ui-sparkline-title",style:e.normalizeStyle(`display:flex;align-items:center;width:100%;color:${t.value.style.title.color};background:${t.value.style.backgroundColor};justify-content:${t.value.style.title.textAlign==="left"?"flex-start":t.value.style.title.textAlign==="right"?"flex-end":"center"};height:${t.value.style.title.fontSize*2}px;font-size:${t.value.style.title.fontSize}px;font-weight:${t.value.style.title.bold?"bold":"normal"};`)},[e.createElementVNode("span",{style:e.normalizeStyle(`padding:${t.value.style.title.textAlign==="left"?"0 0 0 12px":t.value.style.title.textAlign==="right"?"0 12px 0 0":"0"}`)},e.toDisplayString(c.value?c.value.period:t.value.style.title.text),5)],4)):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(u.XMLNS),viewBox:`0 0 ${o.value.width} ${o.value.height}`,style:e.normalizeStyle(`background:${t.value.style.backgroundColor};overflow:visible`)},[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`sparkline_gradient_${v.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(u.shiftHue)(t.value.style.area.color,.05)}${e.unref(u.opacity)[t.value.style.area.opacity]}`},null,8,j),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.area.color+e.unref(u.opacity)[t.value.style.area.opacity]},null,8,R)],8,O),e.createElementVNode("linearGradient",{x2:"0%",y2:"100%",id:`sparkline_bar_gradient_pos_${v.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":t.value.style.bar.color},null,8,U),e.createElementVNode("stop",{offset:"100%","stop-color":`${e.unref(u.shiftHue)(t.value.style.bar.color,.05)}`},null,8,X)],8,H),e.createElementVNode("linearGradient",{x2:"0%",y2:"100%",id:`sparkline_bar_gradient_neg_${v.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(u.shiftHue)(t.value.style.bar.color,.05)}`},null,8,Y),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.bar.color},null,8,J)],8,Z)]),t.value.style.area.show&&!k.value&&s.value[0]?(e.openBlock(),e.createElementBlock("g",K,[t.value.style.line.smooth?(e.openBlock(),e.createElementBlock("path",{key:0,d:`M ${s.value[0].x},${r.value.bottom} ${e.unref(u.createSmoothPath)(s.value)} L ${s.value.at(-1).x},${r.value.bottom} Z`,fill:t.value.style.area.useGradient?`url(#sparkline_gradient_${v.value})`:`${t.value.style.area.color}${e.unref(u.opacity)[t.value.style.area.opacity]}`},null,8,Q)):(e.openBlock(),e.createElementBlock("path",{key:1,d:`M${P.value}Z`,fill:t.value.style.area.useGradient?`url(#sparkline_gradient_${v.value})`:`${t.value.style.area.color}${e.unref(u.opacity)[t.value.style.area.opacity]}`},null,8,ee))])):e.createCommentVNode("",!0),t.value.style.line.smooth&&!k.value?(e.openBlock(),e.createElementBlock("path",{key:1,d:`M ${e.unref(u.createSmoothPath)(s.value)}`,stroke:t.value.style.line.color,fill:"none","stroke-width":t.value.style.line.strokeWidth,"stroke-linecap":"round"},null,8,te)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(a,d)=>(e.openBlock(),e.createElementBlock("g",null,[d<s.value.length-1&&!t.value.style.line.smooth&&!k.value?(e.openBlock(),e.createElementBlock("line",{key:0,x1:a.x,x2:s.value[d+1].x,y1:a.y,y2:s.value[d+1].y,stroke:a.color,"stroke-width":t.value.style.line.strokeWidth,"stroke-linecap":"round","stroke-linejoin":"round","shape-rendering":"geometricPrecision"},null,8,le)):e.createCommentVNode("",!0),k.value?(e.openBlock(),e.createElementBlock("rect",{key:1,x:a.x-a.width/2,y:a.absoluteValue>0?a.y:b.value,width:a.width,height:Math.abs(a.y-b.value),fill:a.absoluteValue>0?`url(#sparkline_bar_gradient_pos_${v.value})`:`url(#sparkline_bar_gradient_neg_${v.value})`,rx:t.value.style.bar.borderRadius},null,8,ae)):e.createCommentVNode("",!0),t.value.style.verticalIndicator.show&&(c.value&&a.id===c.value.id||f.selectedIndex===d)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:a.x,x2:a.x,y1:r.value.top-6,y2:r.value.bottom,stroke:t.value.style.verticalIndicator.color||a.color,"stroke-width":t.value.style.verticalIndicator.strokeWidth,"stroke-linecap":"round","stroke-dasharray":t.value.style.verticalIndicator.strokeDasharray||0},null,8,oe)):e.createCommentVNode("",!0)]))),256)),w.value<0?(e.openBlock(),e.createElementBlock("line",{key:2,x1:r.value.start,x2:r.value.start+r.value.width-16,y1:b.value,y2:b.value,stroke:t.value.style.zeroLine.color,"stroke-dasharray":t.value.style.zeroLine.strokeWidth*2,"stroke-width":t.value.style.zeroLine.strokeWidth,"stroke-linecap":"round"},null,8,ne)):e.createCommentVNode("",!0),t.value.style.plot.show?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:3},e.renderList(s.value,(a,d)=>(e.openBlock(),e.createElementBlock("g",null,[c.value&&a.id===c.value.id||f.selectedIndex===d?(e.openBlock(),e.createElementBlock("circle",{key:0,cx:a.x,cy:a.y,r:t.value.style.plot.radius,fill:a.color,stroke:t.value.style.plot.stroke,"stroke-width":t.value.style.plot.strokeWidth},null,8,ue)):e.createCommentVNode("",!0)]))),256)):e.createCommentVNode("",!0),f.showInfo&&t.value.style.dataLabel.show?(e.openBlock(),e.createElementBlock("text",{key:4,x:t.value.style.dataLabel.position==="left"?12+t.value.style.dataLabel.offsetX:r.value.width+12+t.value.style.dataLabel.offsetX,y:o.value.height/2+t.value.style.dataLabel.fontSize/2.5+t.value.style.dataLabel.offsetY,"font-size":t.value.style.dataLabel.fontSize,"font-weight":t.value.style.dataLabel.bold?"bold":"normal",fill:t.value.style.dataLabel.color},e.toDisplayString(c.value?e.unref(u.applyDataLabel)(t.value.style.dataLabel.formatter,c.value.absoluteValue,e.unref(u.dataLabel)({p:t.value.style.dataLabel.prefix,v:c.value.absoluteValue,s:t.value.style.dataLabel.suffix,r:t.value.style.dataLabel.roundingValue}),{datapoint:c.value}):e.unref(u.applyDataLabel)(t.value.style.dataLabel.formatter,$.value,e.unref(u.dataLabel)({p:t.value.style.dataLabel.prefix,v:$.value,s:t.value.style.dataLabel.suffix,r:t.value.style.dataLabel.roundingValue}))),9,re)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(a,d)=>(e.openBlock(),e.createElementBlock("rect",{x:a.x-(r.value.width/(h.value+1)>o.value.padding?o.value.padding:r.value.width/(h.value+1))/2,y:r.value.top-6,height:r.value.height+6,width:r.value.width/(h.value+1)>o.value.padding?o.value.padding:r.value.width/(h.value+1),fill:"transparent",onMouseenter:V=>D(a,d),onMouseleave:A,onClick:()=>W(a,d)},null,40,se))),256)),e.renderSlot(l.$slots,"svg",{svg:o.value},void 0,!0)],12,G)):e.createCommentVNode("",!0),g.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(F.default,{key:2,config:{type:"sparkline",style:{backgroundColor:t.value.style.backgroundColor,sparkline:{color:"#CCCCCC"}}}},null,8,["config"]))],12,q))}},de=T._export_sfc(ie,[["__scopeId","data-v-a8f8425a"]]);exports.default=de;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-D2ZScauW.cjs"),C=require("./useNestedProp-BU7yyXFA.cjs"),F=require("./vue-ui-skeleton-BLhbQje-.cjs"),E=require("./useResponsive-B3TrDDIG.cjs"),T=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),q=["id"],G=["xmlns","viewBox"],O=["id"],j=["stop-color"],R=["stop-color"],H=["id"],U=["stop-color"],X=["stop-color"],Z=["id"],Y=["stop-color"],J=["stop-color"],K={key:0},Q=["d","fill"],ee=["d","fill"],te=["d","stroke","stroke-width"],le=["x1","x2","y1","y2","stroke","stroke-width"],ae=["x","y","width","height","fill","rx"],oe=["x1","x2","y1","y2","stroke","stroke-width","stroke-dasharray"],ne=["x1","x2","y1","y2","stroke","stroke-dasharray","stroke-width"],ue=["cx","cy","r","fill","stroke","stroke-width"],re=["x","y","font-size","font-weight","fill"],se=["x","y","height","width","onMouseenter","onClick"],ie={__name:"vue-ui-sparkline",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}},showInfo:{type:Boolean,default:!0},selectedIndex:{type:Number,default:void 0}},emits:["hoverIndex","selectDatapoint"],setup(f,{emit:x}){const i=f,{vue_ui_sparkline:I}=u.useConfig(),g=e.computed(()=>!!i.dataset&&i.dataset.length),v=e.ref(u.createUid()),_=e.ref(null),B=e.ref(null),t=e.computed(()=>{const l=C.useNestedProp({userConfig:i.config,defaultConfig:I});return l.theme?{...C.useNestedProp({userConfig:u.themes.vue_ui_sparkline[l.theme]||i.config,defaultConfig:l})}:l}),p=e.ref(i.dataset.map(l=>t.value.style.animation.show?{...l,value:null}:{...l,value:[void 0].includes(l.value)?null:l.value})),L=e.ref(null);e.onMounted(()=>{if(u.objectIsEmpty(i.dataset)?u.error({componentName:"VueUiSparkline",type:"dataset"}):i.dataset.forEach((l,n)=>{u.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["period","value"]}).forEach(a=>{u.error({componentName:"VueUiSparkline",type:"datasetSerieAttribute",property:a,index:n})})}),t.value.style.animation.show&&i.dataset.length>1){let a=function(){n<i.dataset.length?(p.value.push(i.dataset[n]),setTimeout(()=>{requestAnimationFrame(a)},l)):p.value=i.dataset,n+=1};p.value=[];const l=t.value.style.animation.animationFrames/i.dataset.length;let n=0;a()}if(t.value.responsive){const l=E.throttle(()=>{const{width:n,height:a}=E.useResponsive({chart:_.value,title:t.value.style.title.show&&i.showInfo?B.value:null});o.value.width=n,o.value.height=a,o.value.chartWidth=t.value.style.chartWidth/500*n,o.value.padding=.06*n});L.value=new ResizeObserver(l),L.value.observe(_.value.parentNode)}});const o=e.ref({height:80,width:500,chartWidth:t.value.style.chartWidth,padding:30}),S=e.ref(6),r=e.computed(()=>({top:12,left:0,right:o.value.width,bottom:o.value.height-3,start:i.showInfo&&t.value.style.dataLabel.show&&t.value.style.dataLabel.position==="left"?o.value.width-o.value.chartWidth:o.value.padding,width:i.showInfo&&t.value.style.dataLabel.show?o.value.chartWidth:o.value.width-o.value.padding,height:o.value.height-12})),w=e.computed(()=>Math.min(...p.value.map(l=>isNaN(l.value)||[void 0,null,"NaN",NaN,1/0,-1/0].includes(l.value)?0:l.value||0))),M=e.computed(()=>Math.max(...p.value.map(l=>isNaN(l.value)||[void 0,null,"NaN",NaN,1/0,-1/0].includes(l.value)?0:l.value||0))),m=e.computed(()=>{const l=w.value>=0?0:w.value;return Math.abs(l)}),z=e.computed(()=>M.value+m.value+S.value),b=e.computed(()=>r.value.bottom-r.value.height*N(m.value));function N(l){return l/z.value}const h=e.computed(()=>i.dataset.length-1),s=e.computed(()=>p.value.map((l,n)=>{const a=isNaN(l.value)||[void 0,null,"NaN",NaN,1/0,-1/0].includes(l.value)?0:l.value||0;return{absoluteValue:a,period:l.period,plotValue:a+m.value,toMax:N(a+m.value),x:r.value.start+n*(r.value.width/(h.value+1)>o.padding?o.padding:r.value.width/(h.value+1)),y:r.value.bottom-r.value.height*N(a+m.value),id:`plot_${v.value}_${n}`,color:k.value?t.value.style.bar.color:t.value.style.area.useGradient?u.shiftHue(t.value.style.line.color,.05*(1-n/h.value)):t.value.style.line.color,width:r.value.width/(h.value+1)>o.padding?o.padding:r.value.width/(h.value+1)}})),P=e.computed(()=>{const l={x:s.value[0].x,y:o.value.height-6},n={x:s.value[s.value.length-1].x,y:o.value.height-6},a=[];return s.value.forEach(d=>{a.push(`${d.x},${d.y} `)}),[l.x,l.y,...a,n.x,n.y].toString()}),c=e.ref(void 0);function D(l,n){c.value=l,x("hoverIndex",{index:n})}function A(){c.value=void 0,x("hoverIndex",{index:void 0})}const y=e.computed(()=>{if(g.value){const l=s.value.map(a=>a.absoluteValue),n=l.reduce((a,d)=>a+d,0);return{latest:s.value[s.value.length-1].absoluteValue,sum:n,average:n/s.value.length,median:u.calcMedian(l),trend:u.calcLinearProgression(s.value.map(({x:a,y:d,absoluteValue:V})=>({x:a,y:d,value:V}))).trend}}else return{latest:null,sum:null,average:null,median:null,trend:null}}),$=e.computed(()=>g.value?t.value.style.dataLabel.valueType==="latest"?y.value.latest:t.value.style.dataLabel.valueType==="sum"?y.value.sum:t.value.style.dataLabel.valueType==="average"?y.value.average:0:0),k=e.computed(()=>t.value.type&&t.value.type==="bar");function W(l,n){x("selectDatapoint",{datapoint:l,index:n})}return(l,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"sparklineChart",ref:_,class:"vue-ui-sparkline",id:v.value,style:e.normalizeStyle(`width:100%;font-family:${t.value.style.fontFamily}`)},[e.renderSlot(l.$slots,"before",e.normalizeProps(e.guardReactiveProps({selected:c.value,latest:y.value.latest,sum:y.value.sum,average:y.value.average,median:y.value.median,trend:y.value.trend})),void 0,!0),t.value.style.title.show&&f.showInfo?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:B,class:"vue-ui-sparkline-title",style:e.normalizeStyle(`display:flex;align-items:center;width:100%;color:${t.value.style.title.color};background:${t.value.style.backgroundColor};justify-content:${t.value.style.title.textAlign==="left"?"flex-start":t.value.style.title.textAlign==="right"?"flex-end":"center"};height:${t.value.style.title.fontSize*2}px;font-size:${t.value.style.title.fontSize}px;font-weight:${t.value.style.title.bold?"bold":"normal"};`)},[e.createElementVNode("span",{style:e.normalizeStyle(`padding:${t.value.style.title.textAlign==="left"?"0 0 0 12px":t.value.style.title.textAlign==="right"?"0 12px 0 0":"0"}`)},e.toDisplayString(c.value?c.value.period:t.value.style.title.text),5)],4)):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(u.XMLNS),viewBox:`0 0 ${o.value.width} ${o.value.height}`,style:e.normalizeStyle(`background:${t.value.style.backgroundColor};overflow:visible`)},[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`sparkline_gradient_${v.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(u.shiftHue)(t.value.style.area.color,.05)}${e.unref(u.opacity)[t.value.style.area.opacity]}`},null,8,j),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.area.color+e.unref(u.opacity)[t.value.style.area.opacity]},null,8,R)],8,O),e.createElementVNode("linearGradient",{x2:"0%",y2:"100%",id:`sparkline_bar_gradient_pos_${v.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":t.value.style.bar.color},null,8,U),e.createElementVNode("stop",{offset:"100%","stop-color":`${e.unref(u.shiftHue)(t.value.style.bar.color,.05)}`},null,8,X)],8,H),e.createElementVNode("linearGradient",{x2:"0%",y2:"100%",id:`sparkline_bar_gradient_neg_${v.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(u.shiftHue)(t.value.style.bar.color,.05)}`},null,8,Y),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.bar.color},null,8,J)],8,Z)]),t.value.style.area.show&&!k.value&&s.value[0]?(e.openBlock(),e.createElementBlock("g",K,[t.value.style.line.smooth?(e.openBlock(),e.createElementBlock("path",{key:0,d:`M ${s.value[0].x},${r.value.bottom} ${e.unref(u.createSmoothPath)(s.value)} L ${s.value.at(-1).x},${r.value.bottom} Z`,fill:t.value.style.area.useGradient?`url(#sparkline_gradient_${v.value})`:`${t.value.style.area.color}${e.unref(u.opacity)[t.value.style.area.opacity]}`},null,8,Q)):(e.openBlock(),e.createElementBlock("path",{key:1,d:`M${P.value}Z`,fill:t.value.style.area.useGradient?`url(#sparkline_gradient_${v.value})`:`${t.value.style.area.color}${e.unref(u.opacity)[t.value.style.area.opacity]}`},null,8,ee))])):e.createCommentVNode("",!0),t.value.style.line.smooth&&!k.value?(e.openBlock(),e.createElementBlock("path",{key:1,d:`M ${e.unref(u.createSmoothPath)(s.value)}`,stroke:t.value.style.line.color,fill:"none","stroke-width":t.value.style.line.strokeWidth,"stroke-linecap":"round"},null,8,te)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(a,d)=>(e.openBlock(),e.createElementBlock("g",null,[d<s.value.length-1&&!t.value.style.line.smooth&&!k.value?(e.openBlock(),e.createElementBlock("line",{key:0,x1:a.x,x2:s.value[d+1].x,y1:a.y,y2:s.value[d+1].y,stroke:a.color,"stroke-width":t.value.style.line.strokeWidth,"stroke-linecap":"round","stroke-linejoin":"round","shape-rendering":"geometricPrecision"},null,8,le)):e.createCommentVNode("",!0),k.value?(e.openBlock(),e.createElementBlock("rect",{key:1,x:a.x-a.width/2,y:a.absoluteValue>0?a.y:b.value,width:a.width,height:Math.abs(a.y-b.value),fill:a.absoluteValue>0?`url(#sparkline_bar_gradient_pos_${v.value})`:`url(#sparkline_bar_gradient_neg_${v.value})`,rx:t.value.style.bar.borderRadius},null,8,ae)):e.createCommentVNode("",!0),t.value.style.verticalIndicator.show&&(c.value&&a.id===c.value.id||f.selectedIndex===d)?(e.openBlock(),e.createElementBlock("line",{key:2,x1:a.x,x2:a.x,y1:r.value.top-6,y2:r.value.bottom,stroke:t.value.style.verticalIndicator.color||a.color,"stroke-width":t.value.style.verticalIndicator.strokeWidth,"stroke-linecap":"round","stroke-dasharray":t.value.style.verticalIndicator.strokeDasharray||0},null,8,oe)):e.createCommentVNode("",!0)]))),256)),w.value<0?(e.openBlock(),e.createElementBlock("line",{key:2,x1:r.value.start,x2:r.value.start+r.value.width-16,y1:b.value,y2:b.value,stroke:t.value.style.zeroLine.color,"stroke-dasharray":t.value.style.zeroLine.strokeWidth*2,"stroke-width":t.value.style.zeroLine.strokeWidth,"stroke-linecap":"round"},null,8,ne)):e.createCommentVNode("",!0),t.value.style.plot.show?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:3},e.renderList(s.value,(a,d)=>(e.openBlock(),e.createElementBlock("g",null,[c.value&&a.id===c.value.id||f.selectedIndex===d?(e.openBlock(),e.createElementBlock("circle",{key:0,cx:a.x,cy:a.y,r:t.value.style.plot.radius,fill:a.color,stroke:t.value.style.plot.stroke,"stroke-width":t.value.style.plot.strokeWidth},null,8,ue)):e.createCommentVNode("",!0)]))),256)):e.createCommentVNode("",!0),f.showInfo&&t.value.style.dataLabel.show?(e.openBlock(),e.createElementBlock("text",{key:4,x:t.value.style.dataLabel.position==="left"?12+t.value.style.dataLabel.offsetX:r.value.width+12+t.value.style.dataLabel.offsetX,y:o.value.height/2+t.value.style.dataLabel.fontSize/2.5+t.value.style.dataLabel.offsetY,"font-size":t.value.style.dataLabel.fontSize,"font-weight":t.value.style.dataLabel.bold?"bold":"normal",fill:t.value.style.dataLabel.color},e.toDisplayString(c.value?e.unref(u.applyDataLabel)(t.value.style.dataLabel.formatter,c.value.absoluteValue,e.unref(u.dataLabel)({p:t.value.style.dataLabel.prefix,v:c.value.absoluteValue,s:t.value.style.dataLabel.suffix,r:t.value.style.dataLabel.roundingValue}),{datapoint:c.value}):e.unref(u.applyDataLabel)(t.value.style.dataLabel.formatter,$.value,e.unref(u.dataLabel)({p:t.value.style.dataLabel.prefix,v:$.value,s:t.value.style.dataLabel.suffix,r:t.value.style.dataLabel.roundingValue}))),9,re)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(a,d)=>(e.openBlock(),e.createElementBlock("rect",{x:a.x-(r.value.width/(h.value+1)>o.value.padding?o.value.padding:r.value.width/(h.value+1))/2,y:r.value.top-6,height:r.value.height+6,width:r.value.width/(h.value+1)>o.value.padding?o.value.padding:r.value.width/(h.value+1),fill:"transparent",onMouseenter:V=>D(a,d),onMouseleave:A,onClick:()=>W(a,d)},null,40,se))),256)),e.renderSlot(l.$slots,"svg",{svg:o.value},void 0,!0)],12,G)):e.createCommentVNode("",!0),g.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(F.default,{key:2,config:{type:"sparkline",style:{backgroundColor:t.value.style.backgroundColor,sparkline:{color:"#CCCCCC"}}}},null,8,["config"]))],12,q))}},de=T._export_sfc(ie,[["__scopeId","data-v-a8f8425a"]]);exports.default=de;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { computed as v, ref as m, onMounted as ee, openBlock as n, createElementBlock as r, normalizeStyle as N, renderSlot as
|
|
2
|
-
import { u as ue, c as se, t as oe, o as ne, e as E, g as re,
|
|
3
|
-
import { u as U } from "./useNestedProp-
|
|
4
|
-
import ce from "./vue-ui-skeleton-
|
|
1
|
+
import { computed as v, ref as m, onMounted as ee, openBlock as n, createElementBlock as r, normalizeStyle as N, renderSlot as T, normalizeProps as te, guardReactiveProps as ae, createElementVNode as f, toDisplayString as B, createCommentVNode as y, unref as c, Fragment as P, renderList as A, createBlock as le } from "vue";
|
|
2
|
+
import { u as ue, c as se, t as oe, o as ne, e as E, g as re, v as I, U as ie, V as de, X as ve, w as C, P as O, i as j, f as R } from "./index-BshV7sX1.js";
|
|
3
|
+
import { u as U } from "./useNestedProp-B235bkr5.js";
|
|
4
|
+
import ce from "./vue-ui-skeleton-7qakoAGH.js";
|
|
5
5
|
import { t as he, u as ye } from "./useResponsive-NZB-WLRF.js";
|
|
6
6
|
import { _ as fe } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
7
|
-
const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"], be = ["stop-color"], xe = ["id"], _e = ["stop-color"], we = ["stop-color"], $e = ["id"], Le = ["stop-color"], Ne = ["stop-color"], Ie = { key: 0 }, Ce = ["d", "fill"], Me = ["d", "fill"],
|
|
7
|
+
const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"], be = ["stop-color"], xe = ["id"], _e = ["stop-color"], we = ["stop-color"], $e = ["id"], Le = ["stop-color"], Ne = ["stop-color"], Ie = { key: 0 }, Ce = ["d", "fill"], Me = ["d", "fill"], Ve = ["d", "stroke", "stroke-width"], ze = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Se = ["x", "y", "width", "height", "fill", "rx"], Pe = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Ae = ["x1", "x2", "y1", "y2", "stroke", "stroke-dasharray", "stroke-width"], We = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], De = ["x", "y", "font-size", "font-weight", "fill"], Fe = ["x", "y", "height", "width", "onMouseenter", "onClick"], Ge = {
|
|
8
8
|
__name: "vue-ui-sparkline",
|
|
9
9
|
props: {
|
|
10
10
|
config: {
|
|
@@ -30,7 +30,7 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
30
30
|
},
|
|
31
31
|
emits: ["hoverIndex", "selectDatapoint"],
|
|
32
32
|
setup(x, { emit: M }) {
|
|
33
|
-
const i = x, { vue_ui_sparkline: X } = ue(), $ = v(() => !!i.dataset && i.dataset.length), p = m(se()),
|
|
33
|
+
const i = x, { vue_ui_sparkline: X } = ue(), $ = v(() => !!i.dataset && i.dataset.length), p = m(se()), V = m(null), W = m(null), e = v(() => {
|
|
34
34
|
const t = U({
|
|
35
35
|
userConfig: i.config,
|
|
36
36
|
defaultConfig: X
|
|
@@ -78,12 +78,12 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
78
78
|
if (e.value.responsive) {
|
|
79
79
|
const t = he(() => {
|
|
80
80
|
const { width: u, height: a } = ye({
|
|
81
|
-
chart:
|
|
81
|
+
chart: V.value,
|
|
82
82
|
title: e.value.style.title.show && i.showInfo ? W.value : null
|
|
83
83
|
});
|
|
84
84
|
l.value.width = u, l.value.height = a, l.value.chartWidth = e.value.style.chartWidth / 500 * u, l.value.padding = 0.06 * u;
|
|
85
85
|
});
|
|
86
|
-
D.value = new ResizeObserver(t), D.value.observe(
|
|
86
|
+
D.value = new ResizeObserver(t), D.value.observe(V.value.parentNode);
|
|
87
87
|
}
|
|
88
88
|
});
|
|
89
89
|
const l = m({
|
|
@@ -102,8 +102,8 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
102
102
|
})), z = v(() => Math.min(...b.value.map((t) => isNaN(t.value) || [void 0, null, "NaN", NaN, 1 / 0, -1 / 0].includes(t.value) ? 0 : t.value || 0))), q = v(() => Math.max(...b.value.map((t) => isNaN(t.value) || [void 0, null, "NaN", NaN, 1 / 0, -1 / 0].includes(t.value) ? 0 : t.value || 0))), _ = v(() => {
|
|
103
103
|
const t = z.value >= 0 ? 0 : z.value;
|
|
104
104
|
return Math.abs(t);
|
|
105
|
-
}), H = v(() => q.value + _.value + Z.value), L = v(() => s.value.bottom - s.value.height *
|
|
106
|
-
function
|
|
105
|
+
}), H = v(() => q.value + _.value + Z.value), L = v(() => s.value.bottom - s.value.height * S(_.value));
|
|
106
|
+
function S(t) {
|
|
107
107
|
return t / H.value;
|
|
108
108
|
}
|
|
109
109
|
const g = v(() => i.dataset.length - 1), o = v(() => b.value.map((t, u) => {
|
|
@@ -112,9 +112,9 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
112
112
|
absoluteValue: a,
|
|
113
113
|
period: t.period,
|
|
114
114
|
plotValue: a + _.value,
|
|
115
|
-
toMax:
|
|
115
|
+
toMax: S(a + _.value),
|
|
116
116
|
x: s.value.start + u * (s.value.width / (g.value + 1) > l.padding ? l.padding : s.value.width / (g.value + 1)),
|
|
117
|
-
y: s.value.bottom - s.value.height *
|
|
117
|
+
y: s.value.bottom - s.value.height * S(a + _.value),
|
|
118
118
|
id: `plot_${p.value}_${u}`,
|
|
119
119
|
color: w.value ? e.value.style.bar.color : e.value.style.area.useGradient ? I(e.value.style.line.color, 0.05 * (1 - u / g.value)) : e.value.style.line.color,
|
|
120
120
|
width: s.value.width / (g.value + 1) > l.padding ? l.padding : s.value.width / (g.value + 1)
|
|
@@ -139,10 +139,10 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
139
139
|
sum: u,
|
|
140
140
|
average: u / o.value.length,
|
|
141
141
|
median: ie(t),
|
|
142
|
-
trend: de(o.value.map(({ x: a, y: d, absoluteValue:
|
|
142
|
+
trend: de(o.value.map(({ x: a, y: d, absoluteValue: G }) => ({
|
|
143
143
|
x: a,
|
|
144
144
|
y: d,
|
|
145
|
-
value:
|
|
145
|
+
value: G
|
|
146
146
|
}))).trend
|
|
147
147
|
};
|
|
148
148
|
} else
|
|
@@ -153,18 +153,18 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
153
153
|
median: null,
|
|
154
154
|
trend: null
|
|
155
155
|
};
|
|
156
|
-
}),
|
|
156
|
+
}), F = v(() => $.value ? e.value.style.dataLabel.valueType === "latest" ? k.value.latest : e.value.style.dataLabel.valueType === "sum" ? k.value.sum : e.value.style.dataLabel.valueType === "average" ? k.value.average : 0 : 0), w = v(() => e.value.type && e.value.type === "bar");
|
|
157
157
|
function Q(t, u) {
|
|
158
158
|
M("selectDatapoint", { datapoint: t, index: u });
|
|
159
159
|
}
|
|
160
160
|
return (t, u) => (n(), r("div", {
|
|
161
161
|
ref_key: "sparklineChart",
|
|
162
|
-
ref:
|
|
162
|
+
ref: V,
|
|
163
163
|
class: "vue-ui-sparkline",
|
|
164
164
|
id: p.value,
|
|
165
165
|
style: N(`width:100%;font-family:${e.value.style.fontFamily}`)
|
|
166
166
|
}, [
|
|
167
|
-
|
|
167
|
+
T(t.$slots, "before", te(ae({
|
|
168
168
|
selected: h.value,
|
|
169
169
|
latest: k.value.latest,
|
|
170
170
|
sum: k.value.sum,
|
|
@@ -253,7 +253,7 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
253
253
|
fill: "none",
|
|
254
254
|
"stroke-width": e.value.style.line.strokeWidth,
|
|
255
255
|
"stroke-linecap": "round"
|
|
256
|
-
}, null, 8,
|
|
256
|
+
}, null, 8, Ve)) : y("", !0),
|
|
257
257
|
(n(!0), r(P, null, A(o.value, (a, d) => (n(), r("g", null, [
|
|
258
258
|
d < o.value.length - 1 && !e.value.style.line.smooth && !w.value ? (n(), r("line", {
|
|
259
259
|
key: 0,
|
|
@@ -275,7 +275,7 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
275
275
|
height: Math.abs(a.y - L.value),
|
|
276
276
|
fill: a.absoluteValue > 0 ? `url(#sparkline_bar_gradient_pos_${p.value})` : `url(#sparkline_bar_gradient_neg_${p.value})`,
|
|
277
277
|
rx: e.value.style.bar.borderRadius
|
|
278
|
-
}, null, 8,
|
|
278
|
+
}, null, 8, Se)) : y("", !0),
|
|
279
279
|
e.value.style.verticalIndicator.show && (h.value && a.id === h.value.id || x.selectedIndex === d) ? (n(), r("line", {
|
|
280
280
|
key: 2,
|
|
281
281
|
x1: a.x,
|
|
@@ -324,8 +324,8 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
324
324
|
{ datapoint: h.value }
|
|
325
325
|
) : c(j)(
|
|
326
326
|
e.value.style.dataLabel.formatter,
|
|
327
|
-
|
|
328
|
-
c(R)({ p: e.value.style.dataLabel.prefix, v:
|
|
327
|
+
F.value,
|
|
328
|
+
c(R)({ p: e.value.style.dataLabel.prefix, v: F.value, s: e.value.style.dataLabel.suffix, r: e.value.style.dataLabel.roundingValue })
|
|
329
329
|
)), 9, De)) : y("", !0),
|
|
330
330
|
(n(!0), r(P, null, A(o.value, (a, d) => (n(), r("rect", {
|
|
331
331
|
x: a.x - (s.value.width / (g.value + 1) > l.value.padding ? l.value.padding : s.value.width / (g.value + 1)) / 2,
|
|
@@ -333,11 +333,11 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
333
333
|
height: s.value.height + 6,
|
|
334
334
|
width: s.value.width / (g.value + 1) > l.value.padding ? l.value.padding : s.value.width / (g.value + 1),
|
|
335
335
|
fill: "transparent",
|
|
336
|
-
onMouseenter: (
|
|
336
|
+
onMouseenter: (G) => J(a, d),
|
|
337
337
|
onMouseleave: K,
|
|
338
338
|
onClick: () => Q(a, d)
|
|
339
|
-
}, null, 40,
|
|
340
|
-
|
|
339
|
+
}, null, 40, Fe))), 256)),
|
|
340
|
+
T(t.$slots, "svg", { svg: l.value }, void 0, !0)
|
|
341
341
|
], 12, ge)) : y("", !0),
|
|
342
342
|
$.value ? y("", !0) : (n(), le(ce, {
|
|
343
343
|
key: 2,
|
|
@@ -353,7 +353,7 @@ const pe = ["id"], ge = ["xmlns", "viewBox"], ke = ["id"], me = ["stop-color"],
|
|
|
353
353
|
}, null, 8, ["config"]))
|
|
354
354
|
], 12, pe));
|
|
355
355
|
}
|
|
356
|
-
}, Ue = /* @__PURE__ */ fe(
|
|
356
|
+
}, Ue = /* @__PURE__ */ fe(Ge, [["__scopeId", "data-v-a8f8425a"]]);
|
|
357
357
|
export {
|
|
358
358
|
Ue as default
|
|
359
359
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-D2ZScauW.cjs"),C=require("./useNestedProp-BU7yyXFA.cjs"),E=require("./vue-ui-skeleton-BLhbQje-.cjs"),N=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),V=["xmlns","viewBox"],z=["id"],D=["stop-color"],P=["stop-color"],L=["stop-color"],A={id:"stackPill",clipPathUnits:"objectBoundingBox"},F=["fill"],U={"clip-path":"url(#stackPill)"},j=["height","width","fill"],q=["onClick","x","width","height","fill","stroke"],I=["onClick"],T={style:{display:"flex","flex-direction":"row","align-items":"center",gap:"4px","justify-content":"center"}},H=["height","width"],O=["fill"],M={__name:"vue-ui-sparkstackbar",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectDatapoint"],setup(B,{emit:w}){const u=B,{vue_ui_sparkstackbar:$}=o.useConfig(),k=e.computed(()=>!!u.dataset&&u.dataset.length),b=e.ref(o.createUid()),t=e.computed(()=>{const l=C.useNestedProp({userConfig:u.config,defaultConfig:$});return l.theme?{...C.useNestedProp({userConfig:o.themes.vue_ui_sparkstackbar[l.theme]||u.config,defaultConfig:l}),customPalette:o.themePalettes[l.theme]||o.palette}:l}),m=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),d=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]}))),p=e.ref(!0);e.onMounted(()=>{if(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})})}),t.value.style.animation.show){let h=function(){r+=a/l,r<a?(d.value=d.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(h)):(p.value=!1,d.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;p.value=!0,h()}});const v=e.ref({width:500,height:16}),c=e.ref([]),g=e.computed(()=>u.dataset.map(l=>l.value||0).filter((l,n)=>!c.value.includes(n)).reduce((l,n)=>l+n,0)),_=e.computed(()=>d.value.map((l,n)=>({...l,value:l.value||0,proportion:(l.value||0)/g.value,width:(l.value||0)/g.value*v.value.width,proportionLabel:o.dataLabel({v:(l.value||0)/g.value*100,s:"%",r:t.value.style.legend.percentage.rounding})}))),y=e.computed(()=>_.value.filter((l,n)=>!c.value.includes(n)));function S(l){c.value.includes(l)?c.value=c.value.filter(n=>n!==l):c.value.length<d.value.length-1&&c.value.push(l)}const f=e.computed(()=>{let l=0;const n=[];for(let a=0;a<y.value.length;a+=1)n.push({...y.value[a],start:l}),l+=y.value[a].width;return n});function x(l,n){w("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:${t.value.style.backgroundColor};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),k.value?(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(o.XMLNS),width:"100%",viewBox:`0 0 ${v.value.width} ${v.value.height}`},[e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(a,r)=>(e.openBlock(),e.createElementBlock("linearGradient",{key:`stack_gradient_${r}`,gradientTransform:"rotate(90)",id:`stack_gradient_${r}_${b.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":a.color},null,8,D),e.createElementVNode("stop",{offset:"50%","stop-color":`${e.unref(o.shiftHue)(a.color,.05)}${e.unref(o.opacity)[100-t.value.style.bar.gradient.intensity]}`},null,8,P),e.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,L)],8,z))),128)),e.createElementVNode("clipPath",A,[e.createElementVNode("rect",{x:"0.005",y:"-2",width:"0.99",height:"5",rx:"3",ry:"3",fill:t.value.style.backgroundColor},null,8,F)])]),e.createElementVNode("g",U,[e.createElementVNode("rect",{x:0,y:0,height:v.value.height,width:f.value.map(a=>a.width).reduce((a,r)=>a+r,0),fill:t.value.style.bar.gradient.underlayerColor,class:e.normalizeClass({animated:!p.value})},null,10,j),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(a,r)=>(e.openBlock(),e.createElementBlock("rect",{key:`stack_${r}`,onClick:()=>x(a,r),x:a.start,y:0,width:a.width,height:v.value.height,fill:t.value.style.bar.gradient.show?`url(#stack_gradient_${r}_${b.value})`:a.color,stroke:t.value.style.backgroundColor,"stroke-linecap":"round",class:e.normalizeClass({animated:!p.value})},null,10,q))),128))])],8,V)):e.createCommentVNode("",!0),k.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(E.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:${t.value.style.backgroundColor};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(_.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:h=>{S(r),x(a,r)}},[e.createElementVNode("div",T,[(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,O)],8,H)),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,I))),256))],4)):e.createCommentVNode("",!0)],4))}},G=N._export_sfc(M,[["__scopeId","data-v-86f11bbc"]]);exports.default=G;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { computed as p, ref as m, onMounted as T, openBlock as n, createElementBlock as r, normalizeStyle as g, createElementVNode as u, toDisplayString as k, createCommentVNode as h, unref as b, Fragment as D, renderList as z, normalizeClass as A, createBlock as q } from "vue";
|
|
2
|
-
import { u as H, c as j, t as X, a as J, p as d, b as K, d as P, o as Q, e as E, g as R, f as I, X as W,
|
|
3
|
-
import { u as U } from "./useNestedProp-
|
|
4
|
-
import te from "./vue-ui-skeleton-
|
|
2
|
+
import { u as H, c as j, t as X, a as J, p as d, b as K, d as P, o as Q, e as E, g as R, f as I, X as W, v as Y, w as Z, i as ee } from "./index-BshV7sX1.js";
|
|
3
|
+
import { u as U } from "./useNestedProp-B235bkr5.js";
|
|
4
|
+
import te from "./vue-ui-skeleton-7qakoAGH.js";
|
|
5
5
|
import { _ as le } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
6
6
|
const ae = ["xmlns", "viewBox"], oe = ["id"], se = ["stop-color"], ne = ["stop-color"], re = ["stop-color"], ue = {
|
|
7
7
|
id: "stackPill",
|