vue-data-ui 2.4.58 → 2.4.60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +82 -51
- package/dist/{Arrow-gAjHZoeI.js → Arrow-BLYi22nR.js} +1 -1
- package/dist/{Arrow-DyvFEpcu.cjs → Arrow-BoAS4IQq.cjs} +1 -1
- package/dist/{BaseIcon-DKQOeA_7.cjs → BaseIcon-BHIQREMO.cjs} +1 -1
- package/dist/{BaseIcon-B0g_Fksl.js → BaseIcon-EWtqg17H.js} +1 -1
- package/dist/{DataTable-BloVsNyj.js → DataTable-DO8KGCcE.js} +2 -2
- package/dist/{DataTable-Bju6hUOX.cjs → DataTable-Dtq94CxH.cjs} +1 -1
- package/dist/{Legend-BsPIe_nG.cjs → Legend-CMyzYtIb.cjs} +1 -1
- package/dist/{Legend-CdpH9pz7.js → Legend-DGWOCyLt.js} +1 -1
- package/dist/{PackageVersion-W3d_oNMs.js → PackageVersion-BSLNI6kk.js} +1 -1
- package/dist/{PackageVersion-Bmujq1-q.cjs → PackageVersion-B_1OHk5A.cjs} +1 -1
- package/dist/{PenAndPaper-xuFs3BqZ.js → PenAndPaper-CxMtGtJt.js} +3 -3
- package/dist/{PenAndPaper-Be8tn5wI.cjs → PenAndPaper-DhXsAnuf.cjs} +1 -1
- package/dist/{Shape-CXTDY_Vo.js → Shape-DnqZey62.js} +1 -1
- package/dist/{Shape-Cx89w9Ul.cjs → Shape-y66NSXKp.cjs} +1 -1
- package/dist/{Slicer-HGyFRIya.cjs → Slicer-CkI4c7ft.cjs} +1 -1
- package/dist/{Slicer-ENfxtrty.js → Slicer-D9bKLcPd.js} +2 -2
- package/dist/{Title-1u-GspsX.js → Title-CSqO5Y62.js} +1 -1
- package/dist/{Title-CNO85jNx.cjs → Title-DjAOcuWO.cjs} +1 -1
- package/dist/{Tooltip-DQOeAhx3.cjs → Tooltip-AHTiRuWB.cjs} +1 -1
- package/dist/{Tooltip-B-1Q-Tts.js → Tooltip-D_6iYZSH.js} +1 -1
- package/dist/documentation/installation.md +48 -48
- package/dist/index-CgZGelSi.cjs +9 -0
- package/dist/{index-BSzkwF5n.js → index-D7dTQAhm.js} +2 -2
- package/dist/style.css +1 -1
- package/dist/{useNestedProp-CSKuqs0C.cjs → useNestedProp-BxCE3J3Z.cjs} +1 -1
- package/dist/{useNestedProp-BWC_DPZ5.js → useNestedProp-Dqsj7eUX.js} +1 -1
- package/dist/{usePrinter-DtwWejoO.js → usePrinter-B_Ihuvge.js} +1 -1
- package/dist/{usePrinter-D-iwyLyE.cjs → usePrinter-sTw1FdN_.cjs} +1 -1
- package/dist/{vue-data-ui-Com866XF.cjs → vue-data-ui-BttN99Pm.cjs} +1 -1
- package/dist/{vue-data-ui-jb1K_VTO.js → vue-data-ui-CcmpjOfT.js} +60 -60
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +1 -1
- package/dist/vue-ui-3d-bar-8ewYobNj.cjs +19 -0
- package/dist/{vue-ui-3d-bar-Cqc5gqnb.js → vue-ui-3d-bar-TVrDBG5I.js} +170 -158
- package/dist/{vue-ui-accordion-lCjQo2kd.cjs → vue-ui-accordion-BZH6cz4t.cjs} +1 -1
- package/dist/{vue-ui-accordion-CJdfn7N-.js → vue-ui-accordion-lCiFhb8k.js} +3 -3
- package/dist/vue-ui-age-pyramid-BqL8zDjt.cjs +1 -0
- package/dist/{vue-ui-age-pyramid-D89kDZnF.js → vue-ui-age-pyramid-rHtMf5-R.js} +176 -164
- package/dist/{vue-ui-annotator-Cf-zFFmT.js → vue-ui-annotator-DHgSReIY.js} +1 -1
- package/dist/{vue-ui-annotator-muK3_F6c.cjs → vue-ui-annotator-fZIPfk7y.cjs} +1 -1
- package/dist/vue-ui-bullet-48af9PqJ.cjs +34 -0
- package/dist/{vue-ui-bullet-CT5Gkoot.js → vue-ui-bullet-BwhlvcvA.js} +155 -143
- package/dist/vue-ui-candlestick-Ce3tBGpX.cjs +2 -0
- package/dist/{vue-ui-candlestick-DmsHITZF.js → vue-ui-candlestick-dMIrnPD6.js} +96 -84
- package/dist/{vue-ui-carousel-table-N7QL7jRR.js → vue-ui-carousel-table-EcwgqGoI.js} +97 -95
- package/dist/vue-ui-carousel-table-ZhjRbt5-.cjs +1 -0
- package/dist/vue-ui-chestnut-VbrVVUon.cjs +6 -0
- package/dist/{vue-ui-chestnut-C7b1puxs.js → vue-ui-chestnut-vnOyc43k.js} +160 -148
- package/dist/{vue-ui-cursor-BOS7Yvio.cjs → vue-ui-cursor-BdXcdH2e.cjs} +1 -1
- package/dist/{vue-ui-cursor-CAnOat4M.js → vue-ui-cursor-nMbvzf_R.js} +2 -2
- package/dist/{vue-ui-dashboard-OzgTaY3n.js → vue-ui-dashboard-BtaQn50h.js} +2 -2
- package/dist/{vue-ui-dashboard-DI22fn9M.cjs → vue-ui-dashboard-CboN2WC8.cjs} +1 -1
- package/dist/{vue-ui-digits-DGP4EmpQ.cjs → vue-ui-digits-CUvrlpPz.cjs} +1 -1
- package/dist/{vue-ui-digits-DCm2stj-.js → vue-ui-digits-CVfceh4-.js} +2 -2
- package/dist/vue-ui-donut-BckYXDZJ.cjs +1 -0
- package/dist/{vue-ui-donut-BilWHtZy.js → vue-ui-donut-CgYNthls.js} +292 -280
- package/dist/vue-ui-donut-evolution-BhlBp6R-.cjs +1 -0
- package/dist/{vue-ui-donut-evolution-DKmnEHH_.js → vue-ui-donut-evolution-Bose25D6.js} +285 -273
- package/dist/vue-ui-dumbbell-C2iT17s8.cjs +9 -0
- package/dist/{vue-ui-dumbbell-KwkTK5_q.js → vue-ui-dumbbell-CzSlukSu.js} +159 -147
- package/dist/vue-ui-flow-DDlFrtkk.cjs +1 -0
- package/dist/{vue-ui-flow-BShJPhpa.js → vue-ui-flow-DoDWK84L.js} +162 -150
- package/dist/vue-ui-funnel-BfJoFIfh.cjs +1 -0
- package/dist/{vue-ui-funnel-D4xk_DsA.js → vue-ui-funnel-CM_ixf98.js} +229 -215
- package/dist/vue-ui-galaxy-CP71UAF5.cjs +1 -0
- package/dist/{vue-ui-galaxy-Ch3QRiP6.js → vue-ui-galaxy-DlwjTJCx.js} +148 -136
- package/dist/{vue-ui-gauge-DZUv5beK.js → vue-ui-gauge-ByfGCK6z.js} +119 -107
- package/dist/vue-ui-gauge-LqhfOqH-.cjs +1 -0
- package/dist/{vue-ui-gizmo-B39J58Zm.js → vue-ui-gizmo-D8Rq5vzL.js} +45 -43
- package/dist/vue-ui-gizmo-DFnOaVHf.cjs +1 -0
- package/dist/vue-ui-heatmap-A8qDlc58.cjs +1 -0
- package/dist/{vue-ui-heatmap-z8KMf1yo.js → vue-ui-heatmap-BLjVXXW4.js} +138 -126
- package/dist/vue-ui-history-plot-Bxi5QRP8.cjs +1 -0
- package/dist/{vue-ui-history-plot--Lw1-910.js → vue-ui-history-plot-DXoNlRFZ.js} +127 -115
- package/dist/vue-ui-kpi-5cGZ0OBJ.cjs +1 -0
- package/dist/{vue-ui-kpi-BgNONvkD.js → vue-ui-kpi-Bbot_WSI.js} +36 -33
- package/dist/{vue-ui-mini-loader-BrCuKpE6.js → vue-ui-mini-loader-DOE9WO73.js} +2 -2
- package/dist/{vue-ui-mini-loader-DjEyKAQe.cjs → vue-ui-mini-loader-DWX9tRhG.cjs} +1 -1
- package/dist/{vue-ui-molecule-C_eF6tga.js → vue-ui-molecule-0TReXB2j.js} +212 -200
- package/dist/vue-ui-molecule-CxeFzXS5.cjs +1 -0
- package/dist/vue-ui-mood-radar-1jLzXLXZ.cjs +1 -0
- package/dist/{vue-ui-mood-radar-Ch_Qkx9d.js → vue-ui-mood-radar-BMFn685U.js} +123 -111
- package/dist/vue-ui-nested-donuts-4FVj04vI.cjs +17 -0
- package/dist/{vue-ui-nested-donuts-uqfXLRGX.js → vue-ui-nested-donuts-B9rWg9V8.js} +156 -144
- package/dist/vue-ui-onion-Br97OxbL.cjs +5 -0
- package/dist/{vue-ui-onion-CbYOkmrF.js → vue-ui-onion-CnIF_tv7.js} +125 -113
- package/dist/vue-ui-parallel-coordinate-plot-Bi_h0H7e.cjs +8 -0
- package/dist/{vue-ui-parallel-coordinate-plot-aLNOckoo.js → vue-ui-parallel-coordinate-plot-D9iHCwiA.js} +159 -147
- package/dist/{vue-ui-quadrant-CuPCDHgS.js → vue-ui-quadrant-4wjbqumK.js} +211 -199
- package/dist/vue-ui-quadrant-DHDToQ9a.cjs +1 -0
- package/dist/vue-ui-quick-chart-CJKM6r9X.cjs +15 -0
- package/dist/{vue-ui-quick-chart-DBCH5qM1.js → vue-ui-quick-chart-s6FHOZf8.js} +576 -540
- package/dist/vue-ui-radar-DBR2qBM5.cjs +1 -0
- package/dist/{vue-ui-radar-BamYIcPL.js → vue-ui-radar-DpT9w1N-.js} +183 -171
- package/dist/vue-ui-rating-D1Mbw1G8.cjs +1 -0
- package/dist/{vue-ui-rating-DxaSXiPx.js → vue-ui-rating-D31vSe7a.js} +102 -98
- package/dist/vue-ui-relation-circle-BNJbqK_A.cjs +1 -0
- package/dist/{vue-ui-relation-circle-C9_8YW0u.js → vue-ui-relation-circle-DfP6BpVn.js} +129 -117
- package/dist/{vue-ui-rings-DFzPi4m9.js → vue-ui-rings-ChcGuwL9.js} +150 -138
- package/dist/vue-ui-rings-CjB8a3kO.cjs +2 -0
- package/dist/vue-ui-scatter-jk0N3EwD.cjs +1 -0
- package/dist/{vue-ui-scatter-n_jHEngt.js → vue-ui-scatter-wUZ2CBpp.js} +320 -308
- package/dist/{vue-ui-screenshot-1_OHWjZv.js → vue-ui-screenshot-Blg3Suvg.js} +1 -1
- package/dist/{vue-ui-screenshot-BzY_uB1R.cjs → vue-ui-screenshot-DAFpjSWg.cjs} +1 -1
- package/dist/{vue-ui-skeleton-Ojz7f2oH.js → vue-ui-skeleton-BObG0eVD.js} +3 -3
- package/dist/{vue-ui-skeleton-DKtNfORj.cjs → vue-ui-skeleton-m4l9jfqA.cjs} +1 -1
- package/dist/{vue-ui-smiley-CXvJ3sXA.js → vue-ui-smiley-DuQ3M02e.js} +208 -206
- package/dist/vue-ui-smiley-rh3J3TRY.cjs +2 -0
- package/dist/vue-ui-spark-trend-DlNNTu2c.cjs +1 -0
- package/dist/{vue-ui-spark-trend-uyDT9RJC.js → vue-ui-spark-trend-SMpnQ3VV.js} +124 -112
- package/dist/{vue-ui-sparkbar-CxW1vMP2.js → vue-ui-sparkbar-BB6fvRXK.js} +100 -96
- package/dist/vue-ui-sparkbar-chnu8aw9.cjs +1 -0
- package/dist/{vue-ui-sparkgauge-NmLBla47.js → vue-ui-sparkgauge-Bk_78-YB.js} +60 -48
- package/dist/vue-ui-sparkgauge-FONvy7z9.cjs +1 -0
- package/dist/vue-ui-sparkhistogram--uyRru2f.cjs +1 -0
- package/dist/{vue-ui-sparkhistogram-B8SukBWt.js → vue-ui-sparkhistogram-CIsN7kQ2.js} +116 -104
- package/dist/{vue-ui-sparkline-CokyAm9w.js → vue-ui-sparkline-CFvUW--O.js} +124 -112
- package/dist/vue-ui-sparkline-i6LHjMJR.cjs +1 -0
- package/dist/vue-ui-sparkstackbar-1RvV2xwt.cjs +1 -0
- package/dist/{vue-ui-sparkstackbar-QgZq1O55.js → vue-ui-sparkstackbar-DDMsCq0l.js} +85 -81
- package/dist/{vue-ui-stackbar-CTvPYXjb.js → vue-ui-stackbar-BSo9t-88.js} +219 -207
- package/dist/vue-ui-stackbar-CQgtC1I4.cjs +6 -0
- package/dist/vue-ui-strip-plot-BOSoKxsk.cjs +1 -0
- package/dist/{vue-ui-strip-plot-DXPoWvNA.js → vue-ui-strip-plot-C99LsMeZ.js} +113 -101
- package/dist/{vue-ui-table-Bb3BBVjm.js → vue-ui-table-3M-aoEc7.js} +1 -1
- package/dist/{vue-ui-table-8M1ctuqL.cjs → vue-ui-table-M-6G46br.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-Bv0EfTut.js → vue-ui-table-heatmap-BuYlqsq9.js} +82 -78
- package/dist/vue-ui-table-heatmap-CoozQ9bU.cjs +1 -0
- package/dist/{vue-ui-table-sparkline-Bs72Df0-.js → vue-ui-table-sparkline-Dm5kErGp.js} +78 -74
- package/dist/vue-ui-table-sparkline-u0a2YCwp.cjs +1 -0
- package/dist/vue-ui-thermometer-DAz_NjaN.cjs +1 -0
- package/dist/{vue-ui-thermometer-DRGjTOIy.js → vue-ui-thermometer-DrY5FsCD.js} +132 -120
- package/dist/vue-ui-timer-dCCTsApx.cjs +64 -0
- package/dist/{vue-ui-timer-DCA2Dkfi.js → vue-ui-timer-meFVXDUZ.js} +94 -82
- package/dist/vue-ui-tiremarks-CRKQklZh.cjs +1 -0
- package/dist/{vue-ui-tiremarks-CTqweMbJ.js → vue-ui-tiremarks-PaZ-lr2D.js} +104 -94
- package/dist/vue-ui-treemap-Bce1C9jk.cjs +1 -0
- package/dist/{vue-ui-treemap-tz9AdMu0.js → vue-ui-treemap-RjHcVtc6.js} +336 -332
- package/dist/{vue-ui-vertical-bar-BEkWSr_A.js → vue-ui-vertical-bar-C8rC-QBl.js} +188 -176
- package/dist/vue-ui-vertical-bar-e7zR_v0M.cjs +4 -0
- package/dist/{vue-ui-waffle-DQPO5aOU.js → vue-ui-waffle-BT8Yn0cl.js} +140 -136
- package/dist/vue-ui-waffle-BZLPoVht.cjs +1 -0
- package/dist/{vue-ui-wheel-B0u6LKiw.js → vue-ui-wheel-Bq75N1i7.js} +100 -88
- package/dist/vue-ui-wheel-CT6r7EQR.cjs +1 -0
- package/dist/{vue-ui-word-cloud-CEns9_NI.js → vue-ui-word-cloud-BGh6DY8P.js} +132 -120
- package/dist/vue-ui-word-cloud-PcOI8TCE.cjs +1 -0
- package/dist/vue-ui-xy-BmNqzUPR.cjs +3 -0
- package/dist/{vue-ui-xy-DxpIt6dh.js → vue-ui-xy-DuCsguVf.js} +139 -127
- package/dist/{vue-ui-xy-canvas-D_Qiy2N1.js → vue-ui-xy-canvas-6qf3rgfa.js} +231 -227
- package/dist/{vue-ui-xy-canvas--zS_4x6O.cjs → vue-ui-xy-canvas-BnJBE19B.cjs} +2 -2
- package/package.json +1 -1
- package/dist/index-DHwfzZfj.cjs +0 -9
- package/dist/vue-ui-3d-bar-Dif8_wHk.cjs +0 -19
- package/dist/vue-ui-age-pyramid-DHxsu2a1.cjs +0 -1
- package/dist/vue-ui-bullet-CKbrouCq.cjs +0 -34
- package/dist/vue-ui-candlestick-C3YNgFyO.cjs +0 -2
- package/dist/vue-ui-carousel-table-BU1bmZWZ.cjs +0 -1
- package/dist/vue-ui-chestnut-BEALHSS3.cjs +0 -6
- package/dist/vue-ui-donut-Jjz58SJJ.cjs +0 -1
- package/dist/vue-ui-donut-evolution-BtfRmlIq.cjs +0 -1
- package/dist/vue-ui-dumbbell-C2LYuBRx.cjs +0 -9
- package/dist/vue-ui-flow-3vjkptJR.cjs +0 -1
- package/dist/vue-ui-funnel-DyJdIi_i.cjs +0 -1
- package/dist/vue-ui-galaxy-BmGIzIeD.cjs +0 -1
- package/dist/vue-ui-gauge-LeMSJBEk.cjs +0 -1
- package/dist/vue-ui-gizmo-B7Kum6eT.cjs +0 -1
- package/dist/vue-ui-heatmap-CqPuEjJ1.cjs +0 -1
- package/dist/vue-ui-history-plot-bjMvk_4h.cjs +0 -1
- package/dist/vue-ui-kpi-DIuPP4R7.cjs +0 -1
- package/dist/vue-ui-molecule-C3wtpoCr.cjs +0 -1
- package/dist/vue-ui-mood-radar-BomqP0zI.cjs +0 -1
- package/dist/vue-ui-nested-donuts-KRq3Fcqy.cjs +0 -17
- package/dist/vue-ui-onion-G4p7rA61.cjs +0 -5
- package/dist/vue-ui-parallel-coordinate-plot-B2OIBraO.cjs +0 -8
- package/dist/vue-ui-quadrant-DoWeGQSC.cjs +0 -1
- package/dist/vue-ui-quick-chart-DR1qF9kr.cjs +0 -15
- package/dist/vue-ui-radar-B6M2ZChR.cjs +0 -1
- package/dist/vue-ui-rating-HSL7IrbQ.cjs +0 -1
- package/dist/vue-ui-relation-circle-CM_QkigI.cjs +0 -1
- package/dist/vue-ui-rings-CmD8g04s.cjs +0 -2
- package/dist/vue-ui-scatter-D_WxNGoY.cjs +0 -1
- package/dist/vue-ui-smiley-sKWpgakD.cjs +0 -2
- package/dist/vue-ui-spark-trend-ByxJmVE5.cjs +0 -1
- package/dist/vue-ui-sparkbar-DYHuBv3f.cjs +0 -1
- package/dist/vue-ui-sparkgauge-CCvUn2R2.cjs +0 -1
- package/dist/vue-ui-sparkhistogram-FU-uE07T.cjs +0 -1
- package/dist/vue-ui-sparkline-9LU8yp1t.cjs +0 -1
- package/dist/vue-ui-sparkstackbar-9k6C-g_r.cjs +0 -1
- package/dist/vue-ui-stackbar-Drqz1of9.cjs +0 -6
- package/dist/vue-ui-strip-plot-UYP2fk1H.cjs +0 -1
- package/dist/vue-ui-table-heatmap-BqQpJ_Ou.cjs +0 -1
- package/dist/vue-ui-table-sparkline-D5xemE-q.cjs +0 -1
- package/dist/vue-ui-thermometer-DzynFkq0.cjs +0 -1
- package/dist/vue-ui-timer-W5dIiOew.cjs +0 -64
- package/dist/vue-ui-tiremarks-BbAzwE5q.cjs +0 -1
- package/dist/vue-ui-treemap-CEVP7-S2.cjs +0 -1
- package/dist/vue-ui-vertical-bar-D_2WzLxJ.cjs +0 -4
- package/dist/vue-ui-waffle-BAvqVwhK.cjs +0 -1
- package/dist/vue-ui-wheel-Cjnheeql.cjs +0 -1
- package/dist/vue-ui-word-cloud-bxF8a7TI.cjs +0 -1
- package/dist/vue-ui-xy-BBvVOSPm.cjs +0 -3
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { ref as n, onMounted as Q, onBeforeUnmount as Y, computed as z, watch as Z, openBlock as l, createElementBlock as
|
|
2
|
-
import { u as se } from "./useNestedProp-
|
|
3
|
-
import { u as le, c as oe, X as re, F as W } from "./index-
|
|
1
|
+
import { ref as n, onMounted as Q, onBeforeUnmount as Y, computed as z, watch as Z, openBlock as l, createElementBlock as o, normalizeStyle as f, createBlock as ee, createCommentVNode as v, unref as te, createVNode as M, renderSlot as A, createElementVNode as C, mergeProps as V, normalizeProps as E, guardReactiveProps as U, toDisplayString as ae } from "vue";
|
|
2
|
+
import { u as se } from "./useNestedProp-Dqsj7eUX.js";
|
|
3
|
+
import { u as le, c as oe, X as re, F as W } from "./index-D7dTQAhm.js";
|
|
4
4
|
import { t as ue, u as ie } from "./useResponsive-CoxXLe23.js";
|
|
5
|
-
import P from "./BaseIcon-
|
|
6
|
-
import { _ as ne } from "./Title-
|
|
7
|
-
import { _ as ce } from "./PackageVersion-
|
|
5
|
+
import P from "./BaseIcon-EWtqg17H.js";
|
|
6
|
+
import { _ as ne } from "./Title-CSqO5Y62.js";
|
|
7
|
+
import { _ as ce } from "./PackageVersion-BSLNI6kk.js";
|
|
8
8
|
import { _ as de } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
9
9
|
class he {
|
|
10
|
-
constructor(
|
|
10
|
+
constructor(H, k, T, L = !0, $ = !0) {
|
|
11
11
|
this.interval = k, this.elapsed = 0, this.isPaused = !1;
|
|
12
12
|
const S = `
|
|
13
13
|
let interval;
|
|
@@ -73,9 +73,9 @@ class he {
|
|
|
73
73
|
}
|
|
74
74
|
};
|
|
75
75
|
`, R = new Blob([S], { type: "application/javascript" }), m = URL.createObjectURL(R), i = new Worker(m);
|
|
76
|
-
function
|
|
76
|
+
function x(c) {
|
|
77
77
|
let e = Math.floor(c / 1e3), w = Math.floor(c % 1e3 / 10), y = Math.floor(e / 3600), t = Math.floor(e % 3600 / 60), d = e % 60, u = "";
|
|
78
|
-
return
|
|
78
|
+
return $ && (u += String(y).padStart(2, "0") + ":"), u += String(t).padStart(2, "0") + ":", u += String(d).padStart(2, "0"), L && (u += "." + String(w).padStart(2, "0")), u;
|
|
79
79
|
}
|
|
80
80
|
this.start = () => {
|
|
81
81
|
this.isPaused = !1, i.postMessage({ action: "start", data: { interval: this.interval } });
|
|
@@ -94,7 +94,7 @@ class he {
|
|
|
94
94
|
const e = (w) => {
|
|
95
95
|
const { elapsed: y, timestamp: t, action: d } = w.data;
|
|
96
96
|
if (d === "lap") {
|
|
97
|
-
const u =
|
|
97
|
+
const u = x(y);
|
|
98
98
|
c({
|
|
99
99
|
timestamp: t || 0,
|
|
100
100
|
elapsed: y,
|
|
@@ -105,20 +105,20 @@ class he {
|
|
|
105
105
|
i.addEventListener("message", e, { once: !0 });
|
|
106
106
|
}), i.onmessage = (c) => {
|
|
107
107
|
const { elapsed: e, timestamp: w } = c.data;
|
|
108
|
-
this.elapsed = e,
|
|
108
|
+
this.elapsed = e, H({
|
|
109
109
|
timestamp: w || 0,
|
|
110
110
|
elapsed: this.elapsed,
|
|
111
|
-
formatted:
|
|
111
|
+
formatted: x(this.elapsed)
|
|
112
112
|
});
|
|
113
113
|
}, i.onerror = (c) => {
|
|
114
114
|
T && T(c);
|
|
115
115
|
};
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
|
-
const ve = ["xmlns", "viewBox"], pe = { key:
|
|
118
|
+
const ve = ["xmlns", "viewBox"], pe = ["width", "height"], fe = { key: 1 }, we = ["id"], ke = ["stop-color"], ge = ["stop-color"], me = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], ye = ["d", "stroke", "stroke-width"], be = ["r", "fill", "stroke", "stroke-width"], _e = ["r", "fill", "stroke", "stroke-width"], Me = ["x", "y"], Ce = ["x", "y", "font-size", "fill", "font-weight"], Te = {
|
|
119
119
|
key: 0,
|
|
120
120
|
class: "vue-ui-timer-controls"
|
|
121
|
-
},
|
|
121
|
+
}, $e = ["title"], xe = ["title"], Ie = ["title"], Pe = ["title"], Se = ["title"], Re = {
|
|
122
122
|
__name: "vue-ui-timer",
|
|
123
123
|
props: {
|
|
124
124
|
config: {
|
|
@@ -129,40 +129,40 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
129
129
|
}
|
|
130
130
|
},
|
|
131
131
|
emits: ["start", "pause", "reset", "restart", "lap"],
|
|
132
|
-
setup(G, { expose:
|
|
133
|
-
const T = G, { vue_ui_timer:
|
|
132
|
+
setup(G, { expose: H, emit: k }) {
|
|
133
|
+
const T = G, { vue_ui_timer: L } = le(), $ = n(null), S = n(null), R = n(null), m = n(null), i = n(oe()), x = n(0);
|
|
134
134
|
Q(() => {
|
|
135
135
|
c();
|
|
136
136
|
});
|
|
137
137
|
function c() {
|
|
138
138
|
if (e.value.responsive) {
|
|
139
139
|
const a = ue(() => {
|
|
140
|
-
const { width:
|
|
141
|
-
chart:
|
|
140
|
+
const { width: r, height: h } = ie({
|
|
141
|
+
chart: $.value,
|
|
142
142
|
title: e.value.style.title.text ? S.value : null,
|
|
143
143
|
legend: R.value
|
|
144
144
|
});
|
|
145
|
-
t.value.width =
|
|
146
|
-
relator: Math.min(
|
|
145
|
+
t.value.width = r, t.value.height = h, t.value.tracker.core = W({
|
|
146
|
+
relator: Math.min(r, h),
|
|
147
147
|
adjuster: e.value.style.width,
|
|
148
148
|
source: 6 * e.value.stopwatch.tracker.radiusRatio,
|
|
149
149
|
threshold: 1,
|
|
150
150
|
fallback: 1
|
|
151
151
|
}), t.value.tracker.aura = W({
|
|
152
|
-
relator: Math.min(
|
|
152
|
+
relator: Math.min(r, h),
|
|
153
153
|
adjuster: e.value.style.width,
|
|
154
154
|
source: 12 * e.value.stopwatch.tracker.aura.radiusRatio,
|
|
155
155
|
threshold: 1,
|
|
156
156
|
fallback: 1
|
|
157
157
|
}), t.value.label = W({
|
|
158
|
-
relator: Math.min(
|
|
158
|
+
relator: Math.min(r, h),
|
|
159
159
|
adjuster: e.value.style.width,
|
|
160
160
|
source: e.value.stopwatch.label.fontSize,
|
|
161
161
|
threshold: 10,
|
|
162
162
|
fallback: 10
|
|
163
163
|
});
|
|
164
164
|
});
|
|
165
|
-
m.value = new ResizeObserver(a), m.value.observe(
|
|
165
|
+
m.value = new ResizeObserver(a), m.value.observe($.value.parentNode);
|
|
166
166
|
}
|
|
167
167
|
}
|
|
168
168
|
Y(() => {
|
|
@@ -175,11 +175,11 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
175
175
|
function w() {
|
|
176
176
|
return se({
|
|
177
177
|
userConfig: T.config,
|
|
178
|
-
defaultConfig:
|
|
178
|
+
defaultConfig: L
|
|
179
179
|
});
|
|
180
180
|
}
|
|
181
181
|
Z(() => T.config, (a) => {
|
|
182
|
-
e.value = w(), c(),
|
|
182
|
+
e.value = w(), c(), x.value += 1;
|
|
183
183
|
}, { deep: !0 });
|
|
184
184
|
const y = z(() => {
|
|
185
185
|
if (e.value.stopwatch.showHours && e.value.stopwatch.showHundredth)
|
|
@@ -205,16 +205,16 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
205
205
|
e.value.stopwatch.showHundredth,
|
|
206
206
|
e.value.stopwatch.showHours
|
|
207
207
|
), D = n(!0), s = n(!1), p = n(!1);
|
|
208
|
-
function
|
|
208
|
+
function N() {
|
|
209
209
|
k("start"), D.value && u.start(), D.value = !1, s.value = !0;
|
|
210
210
|
}
|
|
211
|
-
function
|
|
211
|
+
function j() {
|
|
212
212
|
s.value && (k("reset"), u.stop(), b.value = [], D.value = !0, s.value = !1);
|
|
213
213
|
}
|
|
214
214
|
function B() {
|
|
215
215
|
p.value = !p.value, k("pause", d.value), u.pause();
|
|
216
216
|
}
|
|
217
|
-
function
|
|
217
|
+
function O() {
|
|
218
218
|
s.value && (p.value = !1, k("restart"), b.value = [], u.restart());
|
|
219
219
|
}
|
|
220
220
|
const b = n([]);
|
|
@@ -223,36 +223,36 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
223
223
|
const a = await u.lap();
|
|
224
224
|
a && (b.value.push(a), k("lap", b.value));
|
|
225
225
|
}
|
|
226
|
-
function X({ timestamp: a, elapsed:
|
|
227
|
-
d.value = { timestamp: a, elapsed:
|
|
226
|
+
function X({ timestamp: a, elapsed: r, formatted: h }) {
|
|
227
|
+
d.value = { timestamp: a, elapsed: r, formatted: h };
|
|
228
228
|
}
|
|
229
229
|
const g = z(() => Math.min(t.value.width, t.value.height) / 2.5 * e.value.stopwatch.track.radiusRatio);
|
|
230
|
-
function q(a,
|
|
231
|
-
const
|
|
232
|
-
return a *
|
|
230
|
+
function q(a, r) {
|
|
231
|
+
const I = 360 / (r * 1e3);
|
|
232
|
+
return a * I % 360;
|
|
233
233
|
}
|
|
234
234
|
function J(a) {
|
|
235
|
-
let
|
|
236
|
-
return { cx: h, cy:
|
|
235
|
+
let r = a * (Math.PI / 180), h = t.value.width / 2 + g.value * Math.cos(r), I = t.value.height / 2 + g.value * Math.sin(r);
|
|
236
|
+
return { cx: h, cy: I };
|
|
237
237
|
}
|
|
238
238
|
const _ = z(() => {
|
|
239
|
-
const a = q(d.value.elapsed, e.value.stopwatch.cycleSeconds), { cx:
|
|
239
|
+
const a = q(d.value.elapsed, e.value.stopwatch.cycleSeconds), { cx: r, cy: h } = J(a - 90), I = a > 180 ? 1 : 0;
|
|
240
240
|
return {
|
|
241
|
-
cx:
|
|
241
|
+
cx: r || t.value.width / 2,
|
|
242
242
|
cy: h || t.value.height / 2 - g.value,
|
|
243
|
-
largeArcFlag:
|
|
243
|
+
largeArcFlag: I,
|
|
244
244
|
sweepFlag: 1
|
|
245
245
|
};
|
|
246
246
|
});
|
|
247
|
-
return
|
|
248
|
-
start:
|
|
247
|
+
return H({
|
|
248
|
+
start: N,
|
|
249
249
|
pause: B,
|
|
250
|
-
reset:
|
|
251
|
-
restart:
|
|
250
|
+
reset: j,
|
|
251
|
+
restart: O,
|
|
252
252
|
lap: F
|
|
253
|
-
}), (a,
|
|
253
|
+
}), (a, r) => (l(), o("div", {
|
|
254
254
|
ref_key: "timerChart",
|
|
255
|
-
ref:
|
|
255
|
+
ref: $,
|
|
256
256
|
class: "vue-ui-timer",
|
|
257
257
|
style: f({
|
|
258
258
|
fontFamily: e.value.style.fontFamily,
|
|
@@ -261,7 +261,7 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
261
261
|
textAlign: "center"
|
|
262
262
|
})
|
|
263
263
|
}, [
|
|
264
|
-
e.value.style.title.text ? (l(),
|
|
264
|
+
e.value.style.title.text ? (l(), o("div", {
|
|
265
265
|
key: 0,
|
|
266
266
|
ref_key: "chartTitle",
|
|
267
267
|
ref: S,
|
|
@@ -271,7 +271,7 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
271
271
|
})
|
|
272
272
|
}, [
|
|
273
273
|
(l(), ee(ne, {
|
|
274
|
-
key: `title_${
|
|
274
|
+
key: `title_${x.value}`,
|
|
275
275
|
config: {
|
|
276
276
|
title: {
|
|
277
277
|
cy: "title",
|
|
@@ -284,7 +284,7 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
284
284
|
}
|
|
285
285
|
}, null, 8, ["config"]))
|
|
286
286
|
], 4)) : v("", !0),
|
|
287
|
-
(l(),
|
|
287
|
+
(l(), o("svg", {
|
|
288
288
|
xmlns: te(re),
|
|
289
289
|
viewBox: `0 0 ${t.value.width <= 0 ? 10 : t.value.width} ${t.value.height <= 0 ? 10 : t.value.height}`,
|
|
290
290
|
style: f({
|
|
@@ -294,7 +294,19 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
294
294
|
})
|
|
295
295
|
}, [
|
|
296
296
|
M(ce),
|
|
297
|
-
|
|
297
|
+
a.$slots["chart-background"] ? (l(), o("foreignObject", {
|
|
298
|
+
key: 0,
|
|
299
|
+
x: 0,
|
|
300
|
+
y: 0,
|
|
301
|
+
width: t.value.width <= 0 ? 10 : t.value.width,
|
|
302
|
+
height: t.value.height <= 0 ? 10 : t.value.height,
|
|
303
|
+
style: {
|
|
304
|
+
pointerEvents: "none"
|
|
305
|
+
}
|
|
306
|
+
}, [
|
|
307
|
+
A(a.$slots, "chart-background", {}, void 0, !0)
|
|
308
|
+
], 8, pe)) : v("", !0),
|
|
309
|
+
e.value.stopwatch.tracker.gradient.show ? (l(), o("defs", fe, [
|
|
298
310
|
C("radialGradient", {
|
|
299
311
|
id: `tracker_gradient_${i.value}`,
|
|
300
312
|
cx: "50%",
|
|
@@ -306,12 +318,12 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
306
318
|
C("stop", {
|
|
307
319
|
offset: "0%",
|
|
308
320
|
"stop-color": e.value.stopwatch.tracker.gradient.color
|
|
309
|
-
}, null, 8,
|
|
321
|
+
}, null, 8, ke),
|
|
310
322
|
C("stop", {
|
|
311
323
|
offset: "100%",
|
|
312
324
|
"stop-color": e.value.stopwatch.tracker.fill
|
|
313
|
-
}, null, 8,
|
|
314
|
-
], 8,
|
|
325
|
+
}, null, 8, ge)
|
|
326
|
+
], 8, we)
|
|
315
327
|
])) : v("", !0),
|
|
316
328
|
C("circle", {
|
|
317
329
|
cx: t.value.width / 2,
|
|
@@ -320,38 +332,38 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
320
332
|
fill: e.value.stopwatch.track.fill,
|
|
321
333
|
stroke: e.value.stopwatch.track.stroke,
|
|
322
334
|
"stroke-width": e.value.stopwatch.track.strokeWidth
|
|
323
|
-
}, null, 8,
|
|
324
|
-
e.value.stopwatch.cycleTrack.show ? (l(),
|
|
325
|
-
key:
|
|
335
|
+
}, null, 8, me),
|
|
336
|
+
e.value.stopwatch.cycleTrack.show ? (l(), o("path", {
|
|
337
|
+
key: 2,
|
|
326
338
|
d: `M ${t.value.width / 2},${t.value.height / 2 - g.value} A ${g.value},${g.value} 0 ${_.value.largeArcFlag},${_.value.sweepFlag} ${_.value.cx},${_.value.cy}`,
|
|
327
339
|
stroke: e.value.stopwatch.cycleTrack.stroke,
|
|
328
340
|
"stroke-width": e.value.stopwatch.cycleTrack.strokeWidth,
|
|
329
341
|
"stroke-linecap": "round",
|
|
330
342
|
fill: "none"
|
|
331
|
-
}, null, 8,
|
|
343
|
+
}, null, 8, ye)) : v("", !0),
|
|
332
344
|
C("circle", V(_.value, {
|
|
333
345
|
r: t.value.tracker.core,
|
|
334
346
|
fill: e.value.stopwatch.tracker.gradient.show ? `url(#tracker_gradient_${i.value})` : e.value.stopwatch.tracker.fill,
|
|
335
347
|
stroke: e.value.stopwatch.tracker.stroke,
|
|
336
348
|
"stroke-width": e.value.stopwatch.tracker.strokeWidth
|
|
337
|
-
}), null, 16,
|
|
338
|
-
e.value.stopwatch.tracker.aura.show ? (l(),
|
|
349
|
+
}), null, 16, be),
|
|
350
|
+
e.value.stopwatch.tracker.aura.show ? (l(), o("circle", V({ key: 3 }, _.value, {
|
|
339
351
|
r: t.value.tracker.aura,
|
|
340
352
|
fill: `${e.value.stopwatch.tracker.aura.fill}20`,
|
|
341
353
|
stroke: e.value.stopwatch.tracker.aura.stroke,
|
|
342
354
|
"stroke-width": e.value.stopwatch.tracker.aura.strokeWidth
|
|
343
|
-
}), null, 16,
|
|
344
|
-
a.$slots.time ? (l(),
|
|
345
|
-
key:
|
|
355
|
+
}), null, 16, _e)) : v("", !0),
|
|
356
|
+
a.$slots.time ? (l(), o("foreignObject", {
|
|
357
|
+
key: 4,
|
|
346
358
|
x: t.value.width / 2,
|
|
347
359
|
y: t.value.height / 2,
|
|
348
360
|
height: "0.1",
|
|
349
361
|
width: "0.1",
|
|
350
362
|
style: { overflow: "visible" }
|
|
351
363
|
}, [
|
|
352
|
-
|
|
353
|
-
], 8,
|
|
354
|
-
key:
|
|
364
|
+
A(a.$slots, "time", E(U({ ...d.value })), void 0, !0)
|
|
365
|
+
], 8, Me)) : (l(), o("text", {
|
|
366
|
+
key: 5,
|
|
355
367
|
x: t.value.width / 2,
|
|
356
368
|
y: t.value.height / 2 + t.value.label / 4,
|
|
357
369
|
"font-size": t.value.label,
|
|
@@ -359,18 +371,18 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
359
371
|
fill: e.value.stopwatch.label.color,
|
|
360
372
|
"font-weight": e.value.stopwatch.label.bold ? "bold" : "normal",
|
|
361
373
|
style: { "font-variant-numeric": "tabular-nums !important" }
|
|
362
|
-
}, ae(d.value.formatted || y.value), 9,
|
|
374
|
+
}, ae(d.value.formatted || y.value), 9, Ce))
|
|
363
375
|
], 12, ve)),
|
|
364
376
|
C("div", {
|
|
365
377
|
ref_key: "chartLegend",
|
|
366
378
|
ref: R,
|
|
367
379
|
style: f({ width: "100%", backgroundColor: e.value.stopwatch.legend.backgroundColor })
|
|
368
380
|
}, [
|
|
369
|
-
a.$slots.controls ? v("", !0) : (l(),
|
|
370
|
-
e.value.stopwatch.legend.buttons.start ? (l(),
|
|
381
|
+
a.$slots.controls ? v("", !0) : (l(), o("div", Te, [
|
|
382
|
+
e.value.stopwatch.legend.buttons.start ? (l(), o("button", {
|
|
371
383
|
key: 0,
|
|
372
384
|
title: e.value.stopwatch.legend.buttonTitles.start,
|
|
373
|
-
onClick:
|
|
385
|
+
onClick: N,
|
|
374
386
|
class: "vue-ui-timer-button",
|
|
375
387
|
style: f({
|
|
376
388
|
opacity: s.value ? 0.2 : 1,
|
|
@@ -381,8 +393,8 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
381
393
|
name: "play",
|
|
382
394
|
stroke: e.value.stopwatch.legend.buttons.iconColor
|
|
383
395
|
}, null, 8, ["stroke"])
|
|
384
|
-
], 12,
|
|
385
|
-
e.value.stopwatch.legend.buttons.pause ? (l(),
|
|
396
|
+
], 12, $e)) : v("", !0),
|
|
397
|
+
e.value.stopwatch.legend.buttons.pause ? (l(), o("button", {
|
|
386
398
|
key: 1,
|
|
387
399
|
title: p.value ? e.value.stopwatch.legend.buttonTitles.resume : e.value.stopwatch.legend.buttonTitles.pause,
|
|
388
400
|
onClick: B,
|
|
@@ -397,10 +409,10 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
397
409
|
stroke: e.value.stopwatch.legend.buttons.iconColor
|
|
398
410
|
}, null, 8, ["stroke"])
|
|
399
411
|
], 12, xe)) : v("", !0),
|
|
400
|
-
e.value.stopwatch.legend.buttons.reset ? (l(),
|
|
412
|
+
e.value.stopwatch.legend.buttons.reset ? (l(), o("button", {
|
|
401
413
|
key: 2,
|
|
402
414
|
title: e.value.stopwatch.legend.buttonTitles.reset,
|
|
403
|
-
onClick:
|
|
415
|
+
onClick: j,
|
|
404
416
|
class: "vue-ui-timer-button",
|
|
405
417
|
style: f({
|
|
406
418
|
opacity: s.value ? 1 : 0.2,
|
|
@@ -412,10 +424,10 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
412
424
|
stroke: e.value.stopwatch.legend.buttons.iconColor
|
|
413
425
|
}, null, 8, ["stroke"])
|
|
414
426
|
], 12, Ie)) : v("", !0),
|
|
415
|
-
e.value.stopwatch.legend.buttons.restart ? (l(),
|
|
427
|
+
e.value.stopwatch.legend.buttons.restart ? (l(), o("button", {
|
|
416
428
|
key: 3,
|
|
417
429
|
title: e.value.stopwatch.legend.buttonTitles.restart,
|
|
418
|
-
onClick:
|
|
430
|
+
onClick: O,
|
|
419
431
|
class: "vue-ui-timer-button",
|
|
420
432
|
style: f({
|
|
421
433
|
opacity: s.value ? 1 : 0.2,
|
|
@@ -426,8 +438,8 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
426
438
|
name: "restart",
|
|
427
439
|
stroke: e.value.stopwatch.legend.buttons.iconColor
|
|
428
440
|
}, null, 8, ["stroke"])
|
|
429
|
-
], 12,
|
|
430
|
-
e.value.stopwatch.legend.buttons.lap ? (l(),
|
|
441
|
+
], 12, Pe)) : v("", !0),
|
|
442
|
+
e.value.stopwatch.legend.buttons.lap ? (l(), o("button", {
|
|
431
443
|
key: 4,
|
|
432
444
|
title: e.value.stopwatch.legend.buttonTitles.lap,
|
|
433
445
|
onClick: F,
|
|
@@ -441,20 +453,20 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
441
453
|
name: "lap",
|
|
442
454
|
stroke: e.value.stopwatch.legend.buttons.iconColor
|
|
443
455
|
}, null, 8, ["stroke"])
|
|
444
|
-
], 12,
|
|
456
|
+
], 12, Se)) : v("", !0)
|
|
445
457
|
])),
|
|
446
|
-
|
|
447
|
-
start:
|
|
458
|
+
A(a.$slots, "controls", E(U({
|
|
459
|
+
start: N,
|
|
448
460
|
pause: B,
|
|
449
|
-
reset:
|
|
450
|
-
restart:
|
|
461
|
+
reset: j,
|
|
462
|
+
restart: O,
|
|
451
463
|
lap: F,
|
|
452
464
|
laps: b.value,
|
|
453
465
|
isRunning: s.value,
|
|
454
466
|
isPaused: p.value,
|
|
455
467
|
...d.value
|
|
456
468
|
})), void 0, !0),
|
|
457
|
-
|
|
469
|
+
A(a.$slots, "laps", E(U({
|
|
458
470
|
laps: b.value,
|
|
459
471
|
lap: F,
|
|
460
472
|
isRunning: s.value,
|
|
@@ -464,7 +476,7 @@ const ve = ["xmlns", "viewBox"], pe = { key: 0 }, fe = ["id"], we = ["stop-color
|
|
|
464
476
|
], 4)
|
|
465
477
|
], 4));
|
|
466
478
|
}
|
|
467
|
-
}, Be = /* @__PURE__ */ de(
|
|
479
|
+
}, Be = /* @__PURE__ */ de(Re, [["__scopeId", "data-v-b9d21393"]]);
|
|
468
480
|
export {
|
|
469
481
|
Be as default
|
|
470
482
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),L=require("./useNestedProp-BxCE3J3Z.cjs"),c=require("./index-CgZGelSi.cjs"),J=require("./Title-DjAOcuWO.cjs"),j=require("./usePrinter-sTw1FdN_.cjs"),K=require("./vue-ui-skeleton-m4l9jfqA.cjs"),Q=require("./PackageVersion-B_1OHk5A.cjs"),W=require("./PenAndPaper-DhXsAnuf.cjs"),Z=require("./useUserOptionState-BgepsfED.cjs"),ee=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),te=["id"],oe={key:2,style:"width:100%;background:transparent;padding-bottom:12px"},ae=["xmlns","viewBox"],le=["width","height"],re={key:1},ne=["d","stroke-width","stroke"],se={key:2},ue=["x1","y1","x2","y2","stroke-width","stroke"],ie=["x","y","font-size","fill","font-weight","text-anchor"],ce={key:5,class:"vue-data-ui-watermark"},ve={key:6,ref:"source",dir:"auto"},de={__name:"vue-ui-tiremarks",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(G,{expose:H}){const v=G,{vue_ui_tiremarks:D}=c.useConfig(),$=e.computed(()=>!!v.dataset&&Object.keys(v.dataset).length),B=e.ref(c.createUid()),P=e.ref(null),R=e.ref(null),O=e.ref(0),A=e.ref(0),t=e.computed({get:()=>E(),set:o=>o}),{userOptionsVisible:x,setUserOptionsVisibility:N,keepUserOptionState:z}=Z.useUserOptionState({config:t.value});function E(){const o=L.useNestedProp({userConfig:v.config,defaultConfig:D});return o.theme?{...L.useNestedProp({userConfig:c.themes.vue_ui_tiremarks[o.theme]||v.config,defaultConfig:o})}:o}e.watch(()=>v.config,o=>{t.value=E(),x.value=!t.value.showOnChartHover,M(),A.value+=1},{deep:!0});const{isPrinting:I,isImaging:F,generatePdf:V,generateImage:q}=j.usePrinter({elementId:B.value,fileName:t.value.style.chart.title.text||"vue-ui-tiremarks"}),X=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),s=e.ref(t.value.style.chart.animation.use?0:c.checkNaN(v.dataset.percentage));e.watch(()=>v.dataset,o=>{t.value.style.chart.animation.use?T(o.percentage):s.value=o.percentage||0},{deep:!0}),e.onMounted(()=>{M()});function T(o){let n=t.value.style.chart.animation.speed;const a=Math.abs(o-s.value)/(n*120);function r(){s.value<o?s.value=Math.min(s.value+a,o):s.value>o&&(s.value=Math.max(s.value-a,o)),s.value!==o&&requestAnimationFrame(r)}r()}function M(){c.objectIsEmpty(v.dataset)&&c.error({componentName:"VueUiTiremarks",type:"dataset"}),T(v.dataset.percentage||0)}const f=e.computed(()=>t.value.style.chart.layout.display==="vertical"),u=e.computed(()=>{const o={top:48,left:64,right:64,bottom:48};return f.value?{top:t.value.style.chart.percentage.verticalPosition==="top"?o.top:3,left:3,right:3,bottom:t.value.style.chart.percentage.verticalPosition==="bottom"?o.bottom:3}:{top:0,bottom:0,left:t.value.style.chart.percentage.horizontalPosition==="left"?o.left:3,right:t.value.style.chart.percentage.horizontalPosition==="right"?o.right:10}}),C=e.computed(()=>Object.values(u.value).reduce((o,n)=>o+n,0)),l=e.computed(()=>({height:f.value?312:56,width:f.value?56:312})),i=e.computed(()=>f.value?{mark:(l.value.height-C.value)/100*.5,space:(l.value.height-C.value)/100*.5}:{mark:(l.value.width-C.value)/100*.5,space:(l.value.width-C.value)/100*.5}),U=e.computed(()=>{const o=[];for(let a=0;a<100;a+=1){const r=t.value.style.chart.layout.ticks.gradient.show?c.shiftHue(t.value.style.chart.layout.activeColor,a/100*(t.value.style.chart.layout.ticks.gradient.shiftHueIntensity/100)):t.value.style.chart.layout.activeColor;if(f.value){const y=t.value.style.chart.layout.crescendo?(100-a)*(l.value.width-u.value.left-u.value.right)/100/3:0,d=u.value.left+4+y,h=l.value.width-u.value.right-4-y,p=l.value.height-u.value.bottom-a*i.value.mark-a*i.value.space-i.value.mark,m=l.value.height-u.value.bottom-a*i.value.mark-a*i.value.space-i.value.mark,k=(h-d)/t.value.style.chart.layout.curveAngleX,b=t.value.style.chart.layout.curveAngleY*((1+a)/100);o.push({x1:d,x2:h,y1:p,y2:m,curve:`M ${d} ${p} C ${d+k} ${p-b}, ${h-k} ${m-b}, ${h} ${m}`,color:r})}else{const y=t.value.style.chart.layout.crescendo?(100-a)*(l.value.height-u.value.top-u.value.bottom)/100/3:0,d=u.value.left+a*i.value.mark+a*i.value.space-i.value.mark,h=d,p=u.value.top+4+y,m=l.value.height-u.value.bottom-4-y,k=t.value.style.chart.layout.curveAngleY*((1+a)/100),b=(m-p)/t.value.style.chart.layout.curveAngleX;o.push({x1:d,x2:h,y1:p,y2:m,curve:`M ${d} ${p} C ${d+k} ${p+b}, ${h+k} ${m-b}, ${h} ${m}`,color:r})}}return o}),g=e.computed(()=>{let o,n,a;const r=t.value.style.chart.percentage.fontSize/3;return f.value?t.value.style.chart.percentage.verticalPosition==="top"?(o=l.value.width/2,n=u.value.top/2,a="middle"):t.value.style.chart.percentage.verticalPosition==="bottom"&&(o=l.value.width/2,n=l.value.height-u.value.bottom/2+r,a="middle"):t.value.style.chart.percentage.horizontalPosition==="left"?(o=4,n=l.value.height/2+r,a="start"):t.value.style.chart.percentage.horizontalPosition==="right"&&(o=l.value.width-u.value.right+8,n=l.value.height/2+r,a="start"),{x:o,y:n,textAnchor:a,bold:t.value.style.chart.percentage.bold,fontSize:t.value.style.chart.percentage.fontSize,fill:t.value.style.chart.percentage.color}}),_=e.ref(!1);function Y(o){_.value=o,O.value+=1}const w=e.ref(!1);function S(){w.value=!w.value}return H({generatePdf:V,generateImage:q,toggleAnnotator:S}),(o,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"tiremarksChart",ref:P,class:e.normalizeClass(`vue-ui-tiremarks ${t.value.useCssAnimation?"":"vue-ui-dna"}`),style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),id:B.value,onMouseenter:n[0]||(n[0]=()=>e.unref(N)(!0)),onMouseleave:n[1]||(n[1]=()=>e.unref(N)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(W.PenAndPaper,{key:0,parent:P.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:w.value,onClose:S},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),X.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:R,class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},null,512)):e.createCommentVNode("",!0),t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",oe,[(e.openBlock(),e.createBlock(J._sfc_main,{key:`title_${A.value}`,config:{title:{cy:"wheel-title",...t.value.style.chart.title},subtitle:{cy:"wheel-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))])):e.createCommentVNode("",!0),t.value.userOptions.show&&$.value&&(e.unref(z)||e.unref(x))?(e.openBlock(),e.createBlock(j.UserOptions,{ref:"details",key:`user_options_${O.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(I),isImaging:e.unref(F),uid:B.value,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasFullscreen:t.value.userOptions.buttons.fullscreen,hasXls:!1,isFullscreen:_.value,titles:{...t.value.userOptions.buttonTitles},chartElement:P.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:w.value,onToggleFullscreen:Y,onGeneratePdf:e.unref(V),onGenerateImage:e.unref(q),onToggleAnnotator:S,style:e.normalizeStyle({visibility:e.unref(z)?e.unref(x)?"visible":"hidden":"visible"})},e.createSlots({_:2},[o.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,o.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionImg",{},void 0,!0)]),key:"1"}:void 0,o.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:a,isFullscreen:r})=>[e.renderSlot(o.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:a,isFullscreen:r})),void 0,!0)]),key:"2"}:void 0,o.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:a,isAnnotator:r})=>[e.renderSlot(o.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:a,isAnnotator:r})),void 0,!0)]),key:"3"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasImg","hasFullscreen","isFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),$.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(c.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":_.value,"vue-data-ui-fulscreen--off":!_.value}),viewBox:`0 0 ${l.value.width} ${l.value.height}`,style:e.normalizeStyle(`max-width:100%; overflow: visible; background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(Q._sfc_main),o.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:l.value.width,height:l.value.height,style:{pointerEvents:"none"}},[e.renderSlot(o.$slots,"chart-background",{},void 0,!0)],8,le)):e.createCommentVNode("",!0),t.value.style.chart.layout.curved?(e.openBlock(),e.createElementBlock("g",re,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U.value,(a,r)=>(e.openBlock(),e.createElementBlock("path",{d:a.curve,"stroke-width":i.value.mark,stroke:s.value>=r?a.color:t.value.style.chart.layout.inactiveColor,"stroke-linecap":"round",fill:"none",class:e.normalizeClass({"vue-ui-tick-animated":t.value.style.chart.animation.use&&r<=s.value})},null,10,ne))),256))])):(e.openBlock(),e.createElementBlock("g",se,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U.value,(a,r)=>(e.openBlock(),e.createElementBlock("line",{x1:a.x1,y1:a.y1,x2:a.x2,y2:a.y2,"stroke-width":i.value.mark,stroke:s.value>=r?a.color:t.value.style.chart.layout.inactiveColor,"stroke-linecap":"round"},null,8,ue))),256))])),t.value.style.chart.percentage.show?(e.openBlock(),e.createElementBlock("text",{key:3,x:g.value.x,y:g.value.y,"font-size":g.value.fontSize,fill:t.value.style.chart.layout.ticks.gradient.show&&t.value.style.chart.percentage.useGradientColor?e.unref(c.shiftHue)(t.value.style.chart.layout.activeColor,s.value/100*(t.value.style.chart.layout.ticks.gradient.shiftHueIntensity/100)):t.value.style.chart.percentage.color,"font-weight":g.value.bold?"bold":"normal","text-anchor":g.value.textAnchor},e.toDisplayString(e.unref(c.applyDataLabel)(t.value.style.chart.percentage.formatter,s.value,e.unref(c.dataLabel)({v:s.value,s:"%",r:t.value.style.chart.percentage.rounding}))),9,ie)):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"svg",{svg:l.value},void 0,!0)],14,ae)):e.createCommentVNode("",!0),o.$slots.watermark?(e.openBlock(),e.createElementBlock("div",ce,[e.renderSlot(o.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(I)||e.unref(F)})),void 0,!0)])):e.createCommentVNode("",!0),o.$slots.source?(e.openBlock(),e.createElementBlock("div",ve,[e.renderSlot(o.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),$.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(K.default,{key:7,config:{type:"tiremarks",style:{backgroundColor:t.value.style.chart.backgroundColor,tiremarks:{color:"#CCCCCC"}}}},null,8,["config"]))],46,te))}},he=ee._export_sfc(de,[["__scopeId","data-v-60aa805a"]]);exports.default=he;
|