vue-data-ui 3.5.2 → 3.7.0
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 +36 -27
- package/dist/{Arrow-BGVin3AS.js → Arrow-CWYIBV-7.js} +1 -1
- package/dist/{BaseDraggableDialog-ymf2sfB8.js → BaseDraggableDialog-CRF94NJQ.js} +2 -2
- package/dist/{BaseIcon-BmMbm4d0.js → BaseIcon-CofSxalQ.js} +6 -5
- package/dist/{ColorPicker-ChuwChMo.js → ColorPicker-e1-OSGlQ.js} +10 -10
- package/dist/{DataTable-BT7VF2ua.js → DataTable-CHaOCmsE.js} +2 -2
- package/dist/{Legend-G6GMcdAc.js → Legend-Web3GjlR.js} +10 -10
- package/dist/{NonSvgPenAndPaper-DVgKKLIf.js → NonSvgPenAndPaper-CjYFLlns.js} +3 -3
- package/dist/{PackageVersion-Y7t79Jtq.js → PackageVersion-Bq_mtsqr.js} +1 -1
- package/dist/{PenAndPaper-SZQIAgkg.js → PenAndPaper-HCZQTkqi.js} +20 -20
- package/dist/{Shape-CNXKB8O0.js → Shape-DE6X_t31.js} +3 -3
- package/dist/{Slicer-D2wm0coO.js → Slicer-BFBBG6xv.js} +23 -23
- package/dist/{SlicerPreview-ij72TAs6.js → SlicerPreview-D76aSViW.js} +2 -2
- package/dist/{SparkTooltip-BEewz-_Q.js → SparkTooltip-B2rpVWE1.js} +6 -6
- package/dist/{Title-BzH_LEA3.js → Title-DfFUb9hd.js} +1 -1
- package/dist/{Tooltip-oWCO1HKy.js → Tooltip-WD0Ros6G.js} +1 -1
- package/dist/{UserOptions-CGnQt6Fd.js → UserOptions-B3I-s3Lw.js} +2 -2
- package/dist/components/arrow.js +1 -1
- package/dist/components/vue-ui-3d-bar.js +3 -3
- package/dist/components/vue-ui-accordion.js +1 -1
- package/dist/components/vue-ui-age-pyramid.js +3 -3
- package/dist/components/vue-ui-annotator.js +1 -1
- package/dist/components/vue-ui-bullet.js +3 -3
- package/dist/components/vue-ui-candlestick.js +3 -3
- package/dist/components/vue-ui-carousel-table.js +1 -1
- package/dist/components/vue-ui-chestnut.js +3 -3
- package/dist/components/vue-ui-chord.js +3 -3
- package/dist/components/vue-ui-circle-pack.js +3 -3
- package/dist/components/vue-ui-cursor.js +1 -1
- package/dist/components/vue-ui-dashboard.js +1 -1
- package/dist/components/vue-ui-digits.js +1 -1
- package/dist/components/vue-ui-donut-evolution.js +2 -2
- package/dist/components/vue-ui-donut.js +3 -3
- package/dist/components/vue-ui-dumbbell.js +3 -3
- package/dist/components/vue-ui-flow.js +3 -3
- package/dist/components/vue-ui-funnel.js +2 -2
- package/dist/components/vue-ui-galaxy.js +1 -1
- package/dist/components/vue-ui-gauge.js +1 -1
- package/dist/components/vue-ui-gizmo.js +1 -1
- package/dist/components/vue-ui-heatmap.js +1 -1
- package/dist/components/vue-ui-history-plot.js +3 -3
- package/dist/components/vue-ui-horizontal-bar.js +3 -3
- package/dist/components/vue-ui-icon.js +1 -1
- package/dist/components/vue-ui-kpi.js +1 -1
- package/dist/components/vue-ui-mini-loader.js +1 -1
- package/dist/components/vue-ui-molecule.js +3 -3
- package/dist/components/vue-ui-mood-radar.js +3 -3
- package/dist/components/vue-ui-nested-donuts.js +2 -2
- package/dist/components/vue-ui-onion.js +3 -3
- package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
- package/dist/components/vue-ui-quadrant.js +3 -3
- package/dist/components/vue-ui-quick-chart.js +3 -3
- package/dist/components/vue-ui-radar.js +3 -3
- package/dist/components/vue-ui-rating.js +1 -1
- package/dist/components/vue-ui-relation-circle.js +3 -3
- package/dist/components/vue-ui-ridgeline.js +3 -3
- package/dist/components/vue-ui-rings.js +3 -3
- package/dist/components/vue-ui-scatter.js +3 -3
- package/dist/components/vue-ui-skeleton.js +1 -1
- package/dist/components/vue-ui-smiley.js +1 -1
- package/dist/components/vue-ui-spark-trend.js +1 -1
- package/dist/components/vue-ui-sparkbar.js +2 -2
- package/dist/components/vue-ui-sparkgauge.js +3 -3
- package/dist/components/vue-ui-sparkhistogram.js +3 -3
- package/dist/components/vue-ui-sparkline.js +3 -3
- package/dist/components/vue-ui-sparkstackbar.js +2 -2
- package/dist/components/vue-ui-stackbar.js +3 -3
- package/dist/components/vue-ui-stackline.js +5 -0
- package/dist/components/vue-ui-strip-plot.js +3 -3
- package/dist/components/vue-ui-table-heatmap.js +1 -1
- package/dist/components/vue-ui-table-sparkline.js +2 -2
- package/dist/components/vue-ui-table.js +1 -1
- package/dist/components/vue-ui-thermometer.js +3 -3
- package/dist/components/vue-ui-timer.js +1 -1
- package/dist/components/vue-ui-tiremarks.js +2 -2
- package/dist/components/vue-ui-treemap.js +3 -3
- package/dist/components/vue-ui-vertical-bar.js +1 -1
- package/dist/components/vue-ui-waffle.js +2 -2
- package/dist/components/vue-ui-wheel.js +1 -1
- package/dist/components/vue-ui-word-cloud.js +3 -3
- package/dist/components/vue-ui-world.js +1 -1
- package/dist/components/vue-ui-xy-canvas.js +3 -3
- package/dist/components/vue-ui-xy.js +3 -3
- package/dist/{dom-to-png--BNgrTZV.js → dom-to-png-CH2DfsJe.js} +1 -1
- package/dist/{img-BecE5qXd.js → img-DUzJeMlr.js} +1 -1
- package/dist/{lib-C_mNZmhD.js → lib-C5BH09_g.js} +111 -110
- package/dist/{pdf-DuG5j3Wv.js → pdf-BSWQncok.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.ts +303 -9
- package/dist/types/vue-ui-stackline.d.ts +18 -0
- package/dist/{useAutoSizeLabelsInsideViewbox-BhzfwQ_k.js → useAutoSizeLabelsInsideViewbox-DOALwU4q.js} +7 -7
- package/dist/{useNestedProp-CReNavA0.js → useNestedProp-CWo6bftQ.js} +535 -329
- package/dist/{usePrinter-DTzqpYKF.js → usePrinter-DCJzEiS8.js} +2 -2
- package/dist/useThemeCheck-DGJ31Vi5.js +32 -0
- package/dist/{useTimeLabels-BGFjWgrv.js → useTimeLabels-C5qMhpbe.js} +50 -49
- package/dist/{vue-data-ui-BRaq4hRp.js → vue-data-ui-ByLTJx5V.js} +79 -77
- package/dist/vue-data-ui.js +226 -204
- package/dist/{vue-ui-3d-bar-BB4ii8Nt.js → vue-ui-3d-bar-Dkds4k5N.js} +546 -517
- package/dist/{vue-ui-accordion-BmFTVF1a.js → vue-ui-accordion-DSdZUn2C.js} +3 -3
- package/dist/vue-ui-age-pyramid-C-fwZRYE.js +960 -0
- package/dist/{vue-ui-annotator-CcpaXBNK.js → vue-ui-annotator-DRaH8hXn.js} +7 -7
- package/dist/vue-ui-bullet-BKVJRjGh.js +657 -0
- package/dist/{vue-ui-candlestick-CMP7UL6z.js → vue-ui-candlestick-BKFWHU4O.js} +596 -561
- package/dist/{vue-ui-carousel-table-CzOcKsDj.js → vue-ui-carousel-table-VmPH6y2g.js} +48 -48
- package/dist/{vue-ui-chestnut-S787oASt.js → vue-ui-chestnut-DpMHe-OI.js} +534 -505
- package/dist/vue-ui-chord-Djdr0PY_.js +1182 -0
- package/dist/vue-ui-circle-pack-CyUqNJQt.js +832 -0
- package/dist/{vue-ui-cursor-C3yD_TUr.js → vue-ui-cursor-BMe8ZiV6.js} +2 -2
- package/dist/{vue-ui-dashboard-BfEcVRxQ.js → vue-ui-dashboard-eBXj-KCw.js} +140 -140
- package/dist/{vue-ui-digits-pRh179Gg.js → vue-ui-digits-D382I0-w.js} +2 -2
- package/dist/{vue-ui-donut-B_tEm4dT.js → vue-ui-donut-BLb0kj_P.js} +634 -602
- package/dist/vue-ui-donut-evolution-BqrldXpI.js +1243 -0
- package/dist/vue-ui-dumbbell-BuZT5a-d.js +1258 -0
- package/dist/vue-ui-flow-LLp6ntEP.js +1026 -0
- package/dist/vue-ui-funnel-pILUR-OG.js +743 -0
- package/dist/vue-ui-galaxy-X6yiw8kx.js +837 -0
- package/dist/vue-ui-gauge-DBh-vFb9.js +864 -0
- package/dist/{vue-ui-gizmo-BQzQlUJ8.js → vue-ui-gizmo-DtyEukIP.js} +3 -3
- package/dist/{vue-ui-heatmap-C9MhHWpp.js → vue-ui-heatmap-mkD6QkXo.js} +501 -466
- package/dist/vue-ui-history-plot-CyTaBaxA.js +1239 -0
- package/dist/{vue-ui-kpi-jcrPjW4C.js → vue-ui-kpi-CKMZDc3n.js} +3 -3
- package/dist/{vue-ui-mini-loader-DTM98mRN.js → vue-ui-mini-loader-BN72OfS0.js} +2 -2
- package/dist/vue-ui-molecule-UzQ3o5HW.js +782 -0
- package/dist/vue-ui-mood-radar-C2zkRLGy.js +930 -0
- package/dist/vue-ui-nested-donuts-B5OpvmJ9.js +1454 -0
- package/dist/vue-ui-onion-DbhIOGtF.js +944 -0
- package/dist/vue-ui-parallel-coordinate-plot-Dv_T4mWW.js +1080 -0
- package/dist/{vue-ui-quadrant-CeM23s0z.js → vue-ui-quadrant-CG6_CWsQ.js} +510 -481
- package/dist/{vue-ui-quick-chart-C0RMQzjC.js → vue-ui-quick-chart-DOeRhk7r.js} +795 -758
- package/dist/vue-ui-radar-DdHa9Hsh.js +1013 -0
- package/dist/{vue-ui-rating-tj97undO.js → vue-ui-rating-DtzmtJwF.js} +26 -26
- package/dist/vue-ui-relation-circle-B5lL4l9w.js +670 -0
- package/dist/vue-ui-ridgeline-3pk4Mlft.js +1302 -0
- package/dist/vue-ui-rings-DhyrjrZi.js +884 -0
- package/dist/vue-ui-scatter-DKCD70mi.js +1619 -0
- package/dist/{vue-ui-skeleton-87TORm6s.js → vue-ui-skeleton-CzzdmraB.js} +3 -3
- package/dist/{vue-ui-smiley-B74geHT3.js → vue-ui-smiley-OYyM-ukP.js} +2 -2
- package/dist/vue-ui-spark-trend-BMTcxeCT.js +364 -0
- package/dist/vue-ui-sparkbar-DVk1JiPL.js +381 -0
- package/dist/vue-ui-sparkgauge-Cq9Nw_xu.js +260 -0
- package/dist/vue-ui-sparkhistogram-PFHlCE_k.js +411 -0
- package/dist/vue-ui-sparkline-BHHwO_cV.js +549 -0
- package/dist/vue-ui-sparkstackbar-BosVkkiC.js +470 -0
- package/dist/vue-ui-stackbar-Djk5CPUy.js +1867 -0
- package/dist/vue-ui-stackline-mU4CSol9.js +1963 -0
- package/dist/{vue-ui-strip-plot-C1N2n39d.js → vue-ui-strip-plot-CZQSL0GK.js} +343 -314
- package/dist/{vue-ui-table-CcuoPHgI.js → vue-ui-table-DMM090pe.js} +5 -5
- package/dist/vue-ui-table-heatmap-vQEFrjCX.js +307 -0
- package/dist/{vue-ui-table-sparkline-BAxmZRff.js → vue-ui-table-sparkline-CQJc0mJY.js} +292 -263
- package/dist/vue-ui-thermometer-D1uxoVeZ.js +613 -0
- package/dist/{vue-ui-timer-BVsUQJz_.js → vue-ui-timer-jTnS3ES5.js} +25 -25
- package/dist/vue-ui-tiremarks-Bv-oIFVV.js +477 -0
- package/dist/vue-ui-treemap-B9MVtunp.js +1359 -0
- package/dist/{vue-ui-vertical-bar-B3gfBqD_.js → vue-ui-vertical-bar-BSbDj5qZ.js} +520 -485
- package/dist/{vue-ui-waffle-Bhlqo4xM.js → vue-ui-waffle-DIALVfvc.js} +376 -347
- package/dist/vue-ui-wheel-aUhrFpGk.js +690 -0
- package/dist/vue-ui-word-cloud-DZmMWsUu.js +904 -0
- package/dist/{vue-ui-world-C8KVyDim.js → vue-ui-world-CVLlgp2f.js} +57 -57
- package/dist/vue-ui-xy-Cy7mOurZ.js +3455 -0
- package/dist/vue-ui-xy-canvas-Cr13t9M5.js +1599 -0
- package/dist/vue_ui_vertical_bar-CELc39b8.js +18 -0
- package/package.json +5 -5
- package/dist/themes-AUNCOb2G.js +0 -53
- package/dist/vue-ui-age-pyramid-8bUepd28.js +0 -933
- package/dist/vue-ui-bullet-BvT4scFv.js +0 -630
- package/dist/vue-ui-chord-Dl9Y4mcz.js +0 -1153
- package/dist/vue-ui-circle-pack-CU09BzOV.js +0 -803
- package/dist/vue-ui-donut-evolution-DiGhMwMO.js +0 -1208
- package/dist/vue-ui-dumbbell-BlF3CLbN.js +0 -1231
- package/dist/vue-ui-flow-BQi5L8mJ.js +0 -991
- package/dist/vue-ui-funnel-CM_6Sare.js +0 -716
- package/dist/vue-ui-galaxy-BnZA62Li.js +0 -808
- package/dist/vue-ui-gauge-DAk72bez.js +0 -835
- package/dist/vue-ui-history-plot-BYQh3E8U.js +0 -1204
- package/dist/vue-ui-molecule-Bd1OXvl3.js +0 -753
- package/dist/vue-ui-mood-radar-DuoiTsYn.js +0 -903
- package/dist/vue-ui-nested-donuts-BTswQFjz.js +0 -1419
- package/dist/vue-ui-onion-D-1U2Qgl.js +0 -915
- package/dist/vue-ui-parallel-coordinate-plot-D-7VFHas.js +0 -1051
- package/dist/vue-ui-radar-BSfxyur3.js +0 -984
- package/dist/vue-ui-relation-circle-C7uV2mIj.js +0 -641
- package/dist/vue-ui-ridgeline-CYMfTlwI.js +0 -1273
- package/dist/vue-ui-rings-C96aj57d.js +0 -855
- package/dist/vue-ui-scatter-CtvOXUnx.js +0 -1590
- package/dist/vue-ui-spark-trend-6_Ibziyv.js +0 -337
- package/dist/vue-ui-sparkbar-BDCocMLI.js +0 -352
- package/dist/vue-ui-sparkgauge-CQ4Zk9-f.js +0 -233
- package/dist/vue-ui-sparkhistogram-BlTV9wfn.js +0 -384
- package/dist/vue-ui-sparkline-DWESyiqL.js +0 -514
- package/dist/vue-ui-sparkstackbar-DK_7X8mL.js +0 -441
- package/dist/vue-ui-stackbar-BWuw8ff4.js +0 -1827
- package/dist/vue-ui-table-heatmap-C9EMEM3Z.js +0 -282
- package/dist/vue-ui-thermometer-CDrM-WFq.js +0 -584
- package/dist/vue-ui-tiremarks-BQH2pNkG.js +0 -450
- package/dist/vue-ui-treemap-6WLoCHsH.js +0 -1330
- package/dist/vue-ui-wheel-CqHw1WuW.js +0 -663
- package/dist/vue-ui-word-cloud-CKuWZGLv.js +0 -875
- package/dist/vue-ui-xy-Cz2qIEfi.js +0 -3424
- package/dist/vue-ui-xy-canvas-y4h7gEFp.js +0 -1564
|
@@ -0,0 +1,411 @@
|
|
|
1
|
+
import { useCssVars as Le, computed as k, defineAsyncComponent as $e, ref as h, toRefs as Se, onMounted as X, watch as G, nextTick as P, createElementBlock as o, openBlock as a, normalizeStyle as F, createCommentVNode as d, createBlock as q, createElementVNode as f, createTextVNode as ze, toDisplayString as g, unref as r, createVNode as Fe, renderSlot as Y, Fragment as y, renderList as b, normalizeClass as J } from "vue";
|
|
2
|
+
import { c as De, t as Be, o as Ee, g as K, k as Me, s as p, a as Q, d as Z, X as Te, h as N } from "./lib-C5BH09_g.js";
|
|
3
|
+
import { t as Ie, u as Ne } from "./useResponsive-DfdjqQps.js";
|
|
4
|
+
import { u as He, a as H } from "./useNestedProp-CWo6bftQ.js";
|
|
5
|
+
import { u as Oe, B as Ve } from "./BaseScanner-BgWxam9d.js";
|
|
6
|
+
import { u as We } from "./useFitSvgText-2crs6Fv5.js";
|
|
7
|
+
import { u as je } from "./useThemeCheck-DGJ31Vi5.js";
|
|
8
|
+
import { u as Re } from "./useChartAccessibility-9icAAmYg.js";
|
|
9
|
+
import { _ as Ue } from "./Shape-DE6X_t31.js";
|
|
10
|
+
import { _ as Xe } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
11
|
+
const ee = { style: { backgroundColor: "#1A1A1A", labels: { value: { color: "#CCCCCC" }, valueLabel: { color: "#CCCCCC" }, timeLabel: { color: "#CCCCCC" } }, selector: { stroke: "#5A5A5A" }, title: { color: "#CCCCCC", subtitle: { color: "#757575" } } } }, te = { style: { backgroundColor: "#FFF8E1", bars: { colors: { positive: "#D32F2F", negative: "#F57C00" } }, labels: { value: { color: "#424242" }, valueLabel: { color: "#424242" }, timeLabel: { color: "#757575" } }, selector: { stroke: "#D32F2F" }, title: { color: "#424242", subtitle: { color: "#757575" } } } }, le = { style: { backgroundColor: "#1E1E1E", bars: { colors: { positive: "#D32F2F", negative: "#F57C00" } }, labels: { value: { color: "#BDBDBD" }, valueLabel: { color: "#BDBDBD" }, timeLabel: { color: "#BDBDBD" } }, selector: { stroke: "#D32F2F" }, title: { color: "#FFF8E1", subtitle: { color: "#BDBDBD" } } } }, ae = { style: { backgroundColor: "#1A1A1A", bars: { colors: { positive: "#66CC66" } }, labels: { value: { color: "#AACCAA" }, valueLabel: { color: "#99CC99" }, timeLabel: { color: "#99AA99" } }, selector: { stroke: "#00FF00" }, title: { color: "#66CC66", subtitle: { color: "#99AA99" } } } }, oe = { style: { backgroundColor: "#fbfafa", bars: { colors: { positive: "#B9B99D", negative: "#C09E85" } }, labels: { value: { color: "#A0AC94" }, valueLabel: { color: "#A0AC94" }, timeLabel: { color: "#8A9892" } }, selector: { stroke: "#BBC4D3" }, title: { color: "#8A9892", subtitle: { color: "#99AA99" } } } }, se = { style: { backgroundColor: "#f6f6fb", bars: { colors: { positive: "#4A6A75" } }, labels: { value: { color: "#61747E" }, valueLabel: { color: "#8A9892" }, timeLabel: { color: "#50606C" } }, selector: { stroke: "#404C4D" }, title: { color: "#50606C", subtitle: { color: "#718890" } } } }, ie = {
|
|
12
|
+
default: {},
|
|
13
|
+
dark: ee,
|
|
14
|
+
celebration: te,
|
|
15
|
+
celebrationNight: le,
|
|
16
|
+
hack: ae,
|
|
17
|
+
zen: oe,
|
|
18
|
+
concrete: se
|
|
19
|
+
}, wt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
20
|
+
__proto__: null,
|
|
21
|
+
celebration: te,
|
|
22
|
+
celebrationNight: le,
|
|
23
|
+
concrete: se,
|
|
24
|
+
dark: ee,
|
|
25
|
+
default: ie,
|
|
26
|
+
hack: ae,
|
|
27
|
+
zen: oe
|
|
28
|
+
}, Symbol.toStringTag, { value: "Module" })), Ge = { key: 0 }, Pe = { key: 1 }, qe = ["xmlns", "viewBox"], Ye = ["width", "height"], Je = ["id"], Ke = ["stop-color"], Qe = ["stop-color"], Ze = ["id"], et = ["stop-color"], tt = ["stop-color"], lt = ["id"], at = ["stop-color"], ot = ["stop-color"], st = ["height", "width", "fill", "x", "stroke", "stroke-width", "rx", "stroke-dasharray"], it = { key: 1 }, ut = ["x", "y", "height", "width", "fill", "stroke", "stroke-width", "rx"], rt = { key: 2 }, nt = ["x", "y", "font-size", "font-weight", "fill"], vt = ["x", "y", "font-size", "fill"], ct = ["x", "y", "font-size", "fill"], dt = ["height", "width", "x", "onMouseover", "onMouseleave", "onClick"], yt = {
|
|
29
|
+
__name: "vue-ui-sparkhistogram",
|
|
30
|
+
props: {
|
|
31
|
+
config: {
|
|
32
|
+
type: Object,
|
|
33
|
+
default() {
|
|
34
|
+
return {};
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
dataset: {
|
|
38
|
+
type: Array,
|
|
39
|
+
default() {
|
|
40
|
+
return [];
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
emits: ["selectDatapoint"],
|
|
45
|
+
setup(ue, { emit: re }) {
|
|
46
|
+
Le((l) => ({
|
|
47
|
+
v47f58673: Ce.value
|
|
48
|
+
}));
|
|
49
|
+
const ne = $e(() => import("./PackageVersion-Bq_mtsqr.js")), { vue_ui_sparkhistogram: ve } = He(), { isThemeValid: ce, warnInvalidTheme: de } = je(), m = ue, C = h(De()), O = h(null), V = h(null), D = h(null), A = h(null), L = h(null), e = h(M()), { loading: W, FINAL_DATASET: x } = Oe({
|
|
50
|
+
...Se(m),
|
|
51
|
+
FINAL_CONFIG: e,
|
|
52
|
+
prepareConfig: M,
|
|
53
|
+
skeletonDataset: [
|
|
54
|
+
{ value: 1, intensity: 0.2, color: "#CACACA" },
|
|
55
|
+
{ value: 2, intensity: 0.3, color: "#CACACA" },
|
|
56
|
+
{ value: 3, intensity: 0.5, color: "#CACACA" },
|
|
57
|
+
{ value: 5, intensity: 0.7, color: "#CACACA" },
|
|
58
|
+
{ value: 8, intensity: 0.9, color: "#CACACA" },
|
|
59
|
+
{ value: 13, intensity: 0.95, color: "#CACACA" },
|
|
60
|
+
{ value: 21, intensity: 1, color: "#CACACA" },
|
|
61
|
+
{ value: 13, intensity: 0.95, color: "#CACACA" },
|
|
62
|
+
{ value: 8, intensity: 0.9, color: "#CACACA" },
|
|
63
|
+
{ value: 5, intensity: 0.7, color: "#CACACA" },
|
|
64
|
+
{ value: 3, intensity: 0.5, color: "#CACACA" },
|
|
65
|
+
{ value: 2, intensity: 0.3, color: "#CACACA" },
|
|
66
|
+
{ value: 1, intensity: 0.2, color: "#CACACA" }
|
|
67
|
+
],
|
|
68
|
+
skeletonConfig: Be({
|
|
69
|
+
defaultConfig: e.value,
|
|
70
|
+
userConfig: {
|
|
71
|
+
style: {
|
|
72
|
+
animation: { show: !1 },
|
|
73
|
+
backgroundColor: "#99999930"
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
})
|
|
77
|
+
}), B = h(e.value.style.layout.width), E = h(e.value.style.layout.height), { svgRef: j } = Re({ config: e.value.style.title });
|
|
78
|
+
function M() {
|
|
79
|
+
const l = H({
|
|
80
|
+
userConfig: m.config,
|
|
81
|
+
defaultConfig: ve
|
|
82
|
+
}), s = l.theme;
|
|
83
|
+
if (!s) return l;
|
|
84
|
+
if (!ce.value(l))
|
|
85
|
+
return de(l), l;
|
|
86
|
+
const t = H({
|
|
87
|
+
userConfig: ie[s] || m.config,
|
|
88
|
+
defaultConfig: l
|
|
89
|
+
});
|
|
90
|
+
return H({
|
|
91
|
+
userConfig: m.config,
|
|
92
|
+
defaultConfig: t
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
X(() => {
|
|
96
|
+
U();
|
|
97
|
+
});
|
|
98
|
+
const R = k(() => !!e.value.debug);
|
|
99
|
+
function U() {
|
|
100
|
+
if (Ee(m.dataset) ? K({
|
|
101
|
+
componentName: "VueUiSparkHistogram",
|
|
102
|
+
type: "dataset",
|
|
103
|
+
debug: R.value
|
|
104
|
+
}) : m.dataset.forEach((l, s) => {
|
|
105
|
+
Me({
|
|
106
|
+
datasetObject: l,
|
|
107
|
+
requiredAttributes: ["value"]
|
|
108
|
+
}).forEach((t) => {
|
|
109
|
+
K({
|
|
110
|
+
componentName: "VueUiSparkHistogram",
|
|
111
|
+
type: "datasetSerieAttribute",
|
|
112
|
+
property: t,
|
|
113
|
+
index: s,
|
|
114
|
+
debug: R.value
|
|
115
|
+
});
|
|
116
|
+
});
|
|
117
|
+
}), e.value.responsive) {
|
|
118
|
+
const l = Ie(() => {
|
|
119
|
+
const { width: s, height: t } = Ne({
|
|
120
|
+
chart: D.value,
|
|
121
|
+
title: e.value.style.title.text ? V.value : null,
|
|
122
|
+
source: O.value
|
|
123
|
+
}), i = e.value.style.labels.timeLabel.show ? e.value.style.labels.timeLabel.fontSize * 2 : 0, c = e.value.style.labels.valueLabel.show ? e.value.style.labels.valueLabel.fontSize * 2 : 0;
|
|
124
|
+
requestAnimationFrame(() => {
|
|
125
|
+
B.value = Math.max(10, s), E.value = Math.max(10, t - 12 - i - c);
|
|
126
|
+
});
|
|
127
|
+
});
|
|
128
|
+
A.value && (L.value && A.value.unobserve(L.value), A.value.disconnect()), A.value = new ResizeObserver(l), L.value = D.value.parentNode, A.value.observe(L.value);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
G(() => m.config, (l) => {
|
|
132
|
+
e.value = M(), U();
|
|
133
|
+
}, { deep: !0 });
|
|
134
|
+
const v = k(() => {
|
|
135
|
+
const l = e.value.style.labels.timeLabel.show ? e.value.style.labels.timeLabel.fontSize * 2 : 0, s = e.value.style.labels.valueLabel.show ? e.value.style.labels.valueLabel.fontSize * 2 : 0, t = E.value + l + s, i = B.value, c = e.value.style.layout.padding.top, $ = t - e.value.style.layout.padding.bottom, S = e.value.style.layout.padding.left, T = i - e.value.style.layout.padding.right, z = c + (t - c - e.value.style.layout.padding.bottom) / 2, I = t - e.value.style.layout.padding.top - e.value.style.layout.padding.bottom - l - s, w = i - e.value.style.layout.padding.left - e.value.style.layout.padding.right;
|
|
136
|
+
return {
|
|
137
|
+
bottom: $,
|
|
138
|
+
centerY: z,
|
|
139
|
+
drawingHeight: I,
|
|
140
|
+
drawingWidth: w,
|
|
141
|
+
height: t,
|
|
142
|
+
left: S,
|
|
143
|
+
right: T,
|
|
144
|
+
top: c,
|
|
145
|
+
width: i
|
|
146
|
+
};
|
|
147
|
+
}), ye = k(() => Math.max(...x.value.map((l) => Math.abs(l.value || 0))));
|
|
148
|
+
function he(l) {
|
|
149
|
+
return Math.abs(l) / ye.value;
|
|
150
|
+
}
|
|
151
|
+
const u = k(() => x.value.map((l, s) => {
|
|
152
|
+
const t = he(l.value || 0), i = v.value.drawingHeight * t, c = v.value.drawingWidth / x.value.length, $ = c * (e.value.style.bars.gap / 100), S = c - $, T = v.value.centerY - i / 2, z = v.value.left + ($ / 2 + s * c), I = v.value.left + s * c, w = typeof l.intensity > "u" ? 100 : Math.round(l.intensity * 100), ke = l.color ? l.color : l.value >= 0 ? p(e.value.style.bars.colors.positive, w) : p(e.value.style.bars.colors.negative, w), Ae = l.color ? l.color : l.value >= 0 ? e.value.style.bars.colors.positive : e.value.style.bars.colors.negative, xe = l.color ? `url(#gradient_datapoint_${s}_${C.value})` : l.value >= 0 ? `url(#gradient_positive_${s}_${C.value})` : `url(#gradient_negative_${s}_${C.value})`, we = z + S / 2;
|
|
153
|
+
return {
|
|
154
|
+
...l,
|
|
155
|
+
color: ke,
|
|
156
|
+
gradient: xe,
|
|
157
|
+
height: i,
|
|
158
|
+
intensity: w,
|
|
159
|
+
proportion: t,
|
|
160
|
+
stroke: Ae,
|
|
161
|
+
textAnchor: we,
|
|
162
|
+
trapX: I,
|
|
163
|
+
unitWidth: c,
|
|
164
|
+
width: S,
|
|
165
|
+
x: z,
|
|
166
|
+
y: T
|
|
167
|
+
};
|
|
168
|
+
}));
|
|
169
|
+
function be(l, s) {
|
|
170
|
+
return Q(
|
|
171
|
+
e.value.style.labels.value.formatter,
|
|
172
|
+
l.value,
|
|
173
|
+
Z({
|
|
174
|
+
p: e.value.style.labels.value.prefix,
|
|
175
|
+
v: l.value,
|
|
176
|
+
s: e.value.style.labels.value.suffix,
|
|
177
|
+
r: e.value.style.labels.value.rounding
|
|
178
|
+
}),
|
|
179
|
+
{ datapoint: l, seriesIndex: s }
|
|
180
|
+
);
|
|
181
|
+
}
|
|
182
|
+
const n = h(null), fe = re;
|
|
183
|
+
function ge(l, s) {
|
|
184
|
+
fe("selectDatapoint", { datapoint: l, index: s }), e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: l, seriesIndex: s });
|
|
185
|
+
}
|
|
186
|
+
function pe(l, s) {
|
|
187
|
+
n.value = s, e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: l, seriesIndex: s });
|
|
188
|
+
}
|
|
189
|
+
function me(l, s) {
|
|
190
|
+
n.value = null, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: l, seriesIndex: s });
|
|
191
|
+
}
|
|
192
|
+
const Ce = k(() => `${e.value.style.animation.speedMs}ms`), _e = k(() => v.value.drawingWidth / x.value.length * 0.9), { fitText: _ } = We({
|
|
193
|
+
svgRef: j,
|
|
194
|
+
unitWidth: _e
|
|
195
|
+
});
|
|
196
|
+
return X(async () => {
|
|
197
|
+
await P(), _(".vue-ui-sparkhistogram-top-label", e.value.style.labels.value.minFontSize), _(".vue-ui-sparkhistogram-bottom-label", e.value.style.labels.valueLabel.minFontSize), _(".vue-ui-sparkhistogram-time-label", e.value.style.labels.timeLabel.minFontSize);
|
|
198
|
+
}), G([B, E, () => x.value], async () => {
|
|
199
|
+
await P(), _(".vue-ui-sparkhistogram-top-label", e.value.style.labels.value.minFontSize), _(".vue-ui-sparkhistogram-bottom-label", e.value.style.labels.valueLabel.minFontSize), _(".vue-ui-sparkhistogram-time-label", e.value.style.labels.timeLabel.minFontSize);
|
|
200
|
+
}), (l, s) => (a(), o("div", {
|
|
201
|
+
class: "vue-data-ui-component vue-ui-spark-histogram",
|
|
202
|
+
ref_key: "histogramChart",
|
|
203
|
+
ref: D,
|
|
204
|
+
style: F(`width:100%;background:${e.value.style.backgroundColor};font-family:${e.value.style.fontFamily}`),
|
|
205
|
+
onMouseleave: s[0] || (s[0] = (t) => n.value = null)
|
|
206
|
+
}, [
|
|
207
|
+
e.value.style.title.text ? (a(), o("div", {
|
|
208
|
+
key: 0,
|
|
209
|
+
ref_key: "chartTitle",
|
|
210
|
+
ref: V,
|
|
211
|
+
style: F(`width:calc(100% - 12px);background:transparent;margin:0 auto;margin:${e.value.style.title.margin};padding: 0 6px;text-align:${e.value.style.title.textAlign}`)
|
|
212
|
+
}, [
|
|
213
|
+
f("div", {
|
|
214
|
+
style: F(`font-size:${e.value.style.title.fontSize}px;color:${e.value.style.title.color};font-weight:${e.value.style.title.bold ? "bold" : "normal"}`)
|
|
215
|
+
}, [
|
|
216
|
+
ze(g(e.value.style.title.text) + " ", 1),
|
|
217
|
+
n.value !== null ? (a(), o("span", Ge, "- " + g(u.value[n.value].timeLabel || "") + " " + g(r(Q)(
|
|
218
|
+
e.value.style.labels.value.formatter,
|
|
219
|
+
u.value[n.value].value,
|
|
220
|
+
r(Z)({
|
|
221
|
+
p: e.value.style.labels.value.prefix,
|
|
222
|
+
v: u.value[n.value].value,
|
|
223
|
+
s: e.value.style.labels.value.suffix,
|
|
224
|
+
r: e.value.style.labels.value.rounding
|
|
225
|
+
}),
|
|
226
|
+
{ datapoint: u.value[n.value], seriesIndex: n.value }
|
|
227
|
+
)), 1)) : d("", !0),
|
|
228
|
+
![void 0, null].includes(n.value) && ![null, void 0].includes(u.value[n.value].valueLabel) ? (a(), o("span", Pe, g(` (${u.value[n.value].valueLabel || 0})`), 1)) : d("", !0)
|
|
229
|
+
], 4),
|
|
230
|
+
e.value.style.title.subtitle.text ? (a(), o("div", {
|
|
231
|
+
key: 0,
|
|
232
|
+
style: F(`font-size:${e.value.style.title.subtitle.fontSize}px;color:${e.value.style.title.subtitle.color};font-weight:${e.value.style.title.subtitle.bold ? "bold" : "normal"}`)
|
|
233
|
+
}, g(e.value.style.title.subtitle.text), 5)) : d("", !0)
|
|
234
|
+
], 4)) : d("", !0),
|
|
235
|
+
(a(), o("svg", {
|
|
236
|
+
ref_key: "svgRef",
|
|
237
|
+
ref: j,
|
|
238
|
+
xmlns: r(Te),
|
|
239
|
+
viewBox: `0 0 ${v.value.width} ${v.value.height}`,
|
|
240
|
+
style: { overflow: "visible" }
|
|
241
|
+
}, [
|
|
242
|
+
Fe(r(ne)),
|
|
243
|
+
l.$slots["chart-background"] ? (a(), o("foreignObject", {
|
|
244
|
+
key: 0,
|
|
245
|
+
x: 0,
|
|
246
|
+
y: 0,
|
|
247
|
+
width: v.value.width,
|
|
248
|
+
height: v.value.height,
|
|
249
|
+
style: {
|
|
250
|
+
pointerEvents: "none"
|
|
251
|
+
}
|
|
252
|
+
}, [
|
|
253
|
+
Y(l.$slots, "chart-background", {}, void 0, !0)
|
|
254
|
+
], 8, Ye)) : d("", !0),
|
|
255
|
+
f("defs", null, [
|
|
256
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("radialGradient", {
|
|
257
|
+
id: `gradient_positive_${i}_${C.value}`,
|
|
258
|
+
cy: "50%",
|
|
259
|
+
cx: "50%",
|
|
260
|
+
r: "50%",
|
|
261
|
+
fx: "50%",
|
|
262
|
+
fy: "50%"
|
|
263
|
+
}, [
|
|
264
|
+
f("stop", {
|
|
265
|
+
offset: "0%",
|
|
266
|
+
"stop-color": r(p)(r(N)(e.value.style.bars.colors.positive, 0.05), t.intensity)
|
|
267
|
+
}, null, 8, Ke),
|
|
268
|
+
f("stop", {
|
|
269
|
+
offset: "100%",
|
|
270
|
+
"stop-color": r(p)(e.value.style.bars.colors.positive, t.intensity)
|
|
271
|
+
}, null, 8, Qe)
|
|
272
|
+
], 8, Je))), 256)),
|
|
273
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("radialGradient", {
|
|
274
|
+
id: `gradient_negative_${i}_${C.value}`,
|
|
275
|
+
cy: "50%",
|
|
276
|
+
cx: "50%",
|
|
277
|
+
r: "50%",
|
|
278
|
+
fx: "50%",
|
|
279
|
+
fy: "50%"
|
|
280
|
+
}, [
|
|
281
|
+
f("stop", {
|
|
282
|
+
offset: "0%",
|
|
283
|
+
"stop-color": r(p)(r(N)(e.value.style.bars.colors.negative, 0.05), t.intensity)
|
|
284
|
+
}, null, 8, et),
|
|
285
|
+
f("stop", {
|
|
286
|
+
offset: "100%",
|
|
287
|
+
"stop-color": r(p)(e.value.style.bars.colors.negative, t.intensity)
|
|
288
|
+
}, null, 8, tt)
|
|
289
|
+
], 8, Ze))), 256)),
|
|
290
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("radialGradient", {
|
|
291
|
+
id: `gradient_datapoint_${i}_${C.value}`,
|
|
292
|
+
cy: "50%",
|
|
293
|
+
cx: "50%",
|
|
294
|
+
r: "50%",
|
|
295
|
+
fx: "50%",
|
|
296
|
+
fy: "50%"
|
|
297
|
+
}, [
|
|
298
|
+
f("stop", {
|
|
299
|
+
offset: "0%",
|
|
300
|
+
"stop-color": r(p)(r(N)(t.color, 0.05), t.intensity)
|
|
301
|
+
}, null, 8, at),
|
|
302
|
+
f("stop", {
|
|
303
|
+
offset: "100%",
|
|
304
|
+
"stop-color": r(p)(t.color, t.intensity)
|
|
305
|
+
}, null, 8, ot)
|
|
306
|
+
], 8, lt))), 256))
|
|
307
|
+
]),
|
|
308
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("g", null, [
|
|
309
|
+
n.value !== null && n.value === i ? (a(), o("rect", {
|
|
310
|
+
key: 0,
|
|
311
|
+
height: v.value.height,
|
|
312
|
+
width: t.unitWidth,
|
|
313
|
+
fill: e.value.style.selector.fill,
|
|
314
|
+
x: t.trapX,
|
|
315
|
+
y: 0,
|
|
316
|
+
stroke: e.value.style.selector.stroke,
|
|
317
|
+
"stroke-width": e.value.style.selector.strokeWidth,
|
|
318
|
+
rx: e.value.style.selector.borderRadius,
|
|
319
|
+
"stroke-dasharray": e.value.style.selector.strokeDasharray
|
|
320
|
+
}, null, 8, st)) : d("", !0)
|
|
321
|
+
]))), 256)),
|
|
322
|
+
!e.value.style.bars.shape || e.value.style.bars.shape === "square" ? (a(), o("g", it, [
|
|
323
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("rect", {
|
|
324
|
+
x: t.x,
|
|
325
|
+
y: t.y,
|
|
326
|
+
height: t.height,
|
|
327
|
+
width: t.width,
|
|
328
|
+
fill: e.value.style.bars.colors.gradient.show ? t.gradient : t.color,
|
|
329
|
+
stroke: t.stroke,
|
|
330
|
+
"stroke-width": e.value.style.bars.strokeWidth,
|
|
331
|
+
rx: `${e.value.style.bars.borderRadius * t.proportion / 12}%`,
|
|
332
|
+
class: J({ "vue-ui-sparkhistogram-shape": e.value.style.animation.show })
|
|
333
|
+
}, null, 10, ut))), 256))
|
|
334
|
+
])) : (a(), o("g", rt, [
|
|
335
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), q(Ue, {
|
|
336
|
+
plot: { x: t.x + t.width / 2, y: t.y + t.height / 2 },
|
|
337
|
+
color: e.value.style.bars.colors.gradient.show ? t.gradient : t.color,
|
|
338
|
+
shape: e.value.style.bars.shape,
|
|
339
|
+
radius: Math.min(t.height * 0.4, t.width * 0.4),
|
|
340
|
+
class: J({ "vue-ui-sparkhistogram-shape": e.value.style.animation.show })
|
|
341
|
+
}, null, 8, ["plot", "color", "shape", "radius", "class"]))), 256))
|
|
342
|
+
])),
|
|
343
|
+
r(W) ? d("", !0) : (a(), o(y, { key: 3 }, [
|
|
344
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("g", null, [
|
|
345
|
+
e.value.style.labels.value.show ? (a(), o("text", {
|
|
346
|
+
key: 0,
|
|
347
|
+
class: "vue-ui-sparkhistogram-top-label",
|
|
348
|
+
"text-anchor": "middle",
|
|
349
|
+
x: t.textAnchor,
|
|
350
|
+
y: t.y - e.value.style.labels.value.fontSize / 3 + e.value.style.labels.value.offsetY,
|
|
351
|
+
"font-size": e.value.style.labels.value.fontSize,
|
|
352
|
+
"font-weight": e.value.style.labels.value.bold ? "bold" : "normal",
|
|
353
|
+
fill: e.value.style.labels.value.color
|
|
354
|
+
}, g(be(t, i)), 9, nt)) : d("", !0)
|
|
355
|
+
]))), 256)),
|
|
356
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("g", null, [
|
|
357
|
+
t.valueLabel && e.value.style.labels.valueLabel.show ? (a(), o("text", {
|
|
358
|
+
key: 0,
|
|
359
|
+
class: "vue-ui-sparkhistogram-bottom-label",
|
|
360
|
+
x: t.textAnchor,
|
|
361
|
+
y: t.y + t.height + e.value.style.labels.valueLabel.fontSize,
|
|
362
|
+
"font-size": e.value.style.labels.valueLabel.fontSize,
|
|
363
|
+
"text-anchor": "middle",
|
|
364
|
+
fill: e.value.style.labels.valueLabel.color
|
|
365
|
+
}, g(t.valueLabel), 9, vt)) : d("", !0)
|
|
366
|
+
]))), 256)),
|
|
367
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("g", null, [
|
|
368
|
+
t.timeLabel && e.value.style.labels.timeLabel.show ? (a(), o("text", {
|
|
369
|
+
key: 0,
|
|
370
|
+
class: "vue-ui-sparkhistogram-time-label",
|
|
371
|
+
x: t.textAnchor,
|
|
372
|
+
y: v.value.height,
|
|
373
|
+
"font-size": e.value.style.labels.timeLabel.fontSize,
|
|
374
|
+
fill: e.value.style.labels.timeLabel.color,
|
|
375
|
+
"text-anchor": "middle"
|
|
376
|
+
}, g(t.timeLabel), 9, ct)) : d("", !0)
|
|
377
|
+
]))), 256))
|
|
378
|
+
], 64)),
|
|
379
|
+
(a(!0), o(y, null, b(u.value, (t, i) => (a(), o("g", null, [
|
|
380
|
+
f("rect", {
|
|
381
|
+
height: v.value.height,
|
|
382
|
+
width: t.unitWidth,
|
|
383
|
+
fill: "transparent",
|
|
384
|
+
x: t.trapX,
|
|
385
|
+
y: 0,
|
|
386
|
+
onMouseover: (c) => pe(t, i),
|
|
387
|
+
onMouseleave: (c) => me(t, i),
|
|
388
|
+
onClick: () => ge(t, i)
|
|
389
|
+
}, null, 40, dt)
|
|
390
|
+
]))), 256))
|
|
391
|
+
], 8, qe)),
|
|
392
|
+
l.$slots.source ? (a(), o("div", {
|
|
393
|
+
key: 1,
|
|
394
|
+
ref_key: "source",
|
|
395
|
+
ref: O,
|
|
396
|
+
dir: "auto"
|
|
397
|
+
}, [
|
|
398
|
+
Y(l.$slots, "source", {}, void 0, !0)
|
|
399
|
+
], 512)) : d("", !0),
|
|
400
|
+
r(W) ? (a(), q(Ve, { key: 2 })) : d("", !0)
|
|
401
|
+
], 36));
|
|
402
|
+
}
|
|
403
|
+
}, ht = /* @__PURE__ */ Xe(yt, [["__scopeId", "data-v-3b5d52bb"]]), Lt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
404
|
+
__proto__: null,
|
|
405
|
+
default: ht
|
|
406
|
+
}, Symbol.toStringTag, { value: "Module" }));
|
|
407
|
+
export {
|
|
408
|
+
wt as a,
|
|
409
|
+
Lt as b,
|
|
410
|
+
ht as v
|
|
411
|
+
};
|