vue-data-ui 3.23.0 → 3.23.2
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-o2qHNvrC.js → Arrow-CF0VFcBH.js} +1 -1
- package/dist/{BaseDraggableDialog-qTnfhLBz.js → BaseDraggableDialog-LoqqwRtV.js} +2 -2
- package/dist/{BaseIcon-91MZoczJ.js → BaseIcon-BfndwIWE.js} +1 -1
- package/dist/{BaseLegendToggle-CtAPwzr2.js → BaseLegendToggle-DZVucLnv.js} +1 -1
- package/dist/{BaseZoomControls-rdzlicuz.js → BaseZoomControls-BZvCnZEi.js} +2 -2
- package/dist/{ColorPicker-CIAkdPrj.js → ColorPicker--ayG2YHf.js} +2 -2
- package/dist/{DataTable-D4tM9s5Y.js → DataTable-BbKgJ5UI.js} +2 -2
- package/dist/{HillActions-BWhxHlrj.js → HillActions-BD9j_sOU.js} +1 -1
- package/dist/{Legend-CQTRlzK-.js → Legend-CQxUgOd-.js} +2 -2
- package/dist/{NonSvgPenAndPaper-Cawacw1W.js → NonSvgPenAndPaper-4ypecDg1.js} +6 -6
- package/dist/{PackageVersion--QCMh5k_.js → PackageVersion-DXU7nRr9.js} +1 -1
- package/dist/{PenAndPaper-cE4J8-rA.js → PenAndPaper-DAE-tnEQ.js} +6 -6
- package/dist/{Shape-BPMV94Ij.js → Shape-C21CMlWS.js} +1 -1
- package/dist/SlicerPreview-wUw1hFwe.js +1703 -0
- package/dist/{SparkTooltip-BaYtEKS6.js → SparkTooltip-CjsbIhzi.js} +1 -1
- package/dist/{Title-BODtwViI.js → Title-BE3qg9xl.js} +1 -1
- package/dist/{Tooltip-CMTGxeYO.js → Tooltip-DhjyfHwz.js} +2 -2
- package/dist/{UserOptions-3ujTo3LD.js → UserOptions-Dt98of5H.js} +2 -2
- package/dist/components/arrow.js +1 -1
- package/dist/components/vue-ui-3d-bar.js +1 -1
- package/dist/components/vue-ui-accordion.js +1 -1
- package/dist/components/vue-ui-age-pyramid.js +1 -1
- package/dist/components/vue-ui-annotator.js +1 -1
- package/dist/components/vue-ui-bullet.js +1 -1
- package/dist/components/vue-ui-bump.js +1 -1
- package/dist/components/vue-ui-candlestick.js +1 -1
- package/dist/components/vue-ui-carousel-table.js +1 -1
- package/dist/components/vue-ui-chestnut.js +1 -1
- package/dist/components/vue-ui-chord.js +1 -1
- package/dist/components/vue-ui-circle-pack.js +1 -1
- package/dist/components/vue-ui-cursor.js +1 -1
- package/dist/components/vue-ui-dag.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 +1 -1
- package/dist/components/vue-ui-donut.js +1 -1
- package/dist/components/vue-ui-dumbbell.js +1 -1
- package/dist/components/vue-ui-flow.js +1 -1
- package/dist/components/vue-ui-funnel.js +1 -1
- package/dist/components/vue-ui-galaxy.js +1 -1
- package/dist/components/vue-ui-gauge.js +1 -1
- package/dist/components/vue-ui-geo.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-hill.js +1 -1
- package/dist/components/vue-ui-history-plot.js +1 -1
- package/dist/components/vue-ui-horizontal-bar.js +1 -1
- 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 +1 -1
- package/dist/components/vue-ui-mood-radar.js +1 -1
- package/dist/components/vue-ui-nested-donuts.js +1 -1
- package/dist/components/vue-ui-onion.js +1 -1
- package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
- package/dist/components/vue-ui-quadrant.js +1 -1
- package/dist/components/vue-ui-quick-chart.js +1 -1
- package/dist/components/vue-ui-radar.js +1 -1
- package/dist/components/vue-ui-rating.js +1 -1
- package/dist/components/vue-ui-relation-circle.js +1 -1
- package/dist/components/vue-ui-ridgeline.js +1 -1
- package/dist/components/vue-ui-rings.js +1 -1
- package/dist/components/vue-ui-scatter.js +1 -1
- 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 +1 -1
- package/dist/components/vue-ui-sparkgauge.js +1 -1
- package/dist/components/vue-ui-sparkhistogram.js +1 -1
- package/dist/components/vue-ui-sparkline.js +1 -1
- package/dist/components/vue-ui-sparkstackbar.js +1 -1
- package/dist/components/vue-ui-stackbar.js +1 -1
- package/dist/components/vue-ui-stackline.js +1 -1
- package/dist/components/vue-ui-strip-plot.js +1 -1
- package/dist/components/vue-ui-table-heatmap.js +1 -1
- package/dist/components/vue-ui-table-sparkline.js +1 -1
- package/dist/components/vue-ui-table.js +1 -1
- package/dist/components/vue-ui-thermometer.js +1 -1
- package/dist/components/vue-ui-timer.js +1 -1
- package/dist/components/vue-ui-tiremarks.js +1 -1
- package/dist/components/vue-ui-treemap.js +1 -1
- package/dist/components/vue-ui-vertical-bar.js +1 -1
- package/dist/components/vue-ui-waffle.js +1 -1
- package/dist/components/vue-ui-wheel.js +1 -1
- package/dist/components/vue-ui-word-cloud.js +1 -1
- package/dist/components/vue-ui-world.js +1 -1
- package/dist/components/vue-ui-xy-canvas.js +1 -1
- package/dist/components/vue-ui-xy.js +1 -1
- package/dist/composables.js +1 -1
- package/dist/{dom-to-png-4tdMNGPX.js → dom-to-png-BYIvdTe8.js} +1 -1
- package/dist/{exposedLib-DWLRqRhv.js → exposedLib-C0DPCgFj.js} +7 -4
- package/dist/{geoProjections-BCP_PoiB.js → geoProjections-CEo3dVaL.js} +1 -1
- package/dist/{img-DIQG5q8T.js → img-Bnokohej.js} +1 -1
- package/dist/{labelUtils-C5lnc_xc.js → labelUtils-BeVpDvTJ.js} +1 -1
- package/dist/{lib-BuMGJ_a0.js → lib-Bttd6u5E.js} +21 -11
- package/dist/{package-BMc_ZieJ.js → package-bsfpO6y3.js} +1 -1
- package/dist/{pdf-Cnz4NKM9.js → pdf-CVIDfCrS.js} +1 -1
- package/dist/{render-common-Ktg2LZFG.js → render-common-C0PEe9so.js} +2 -2
- package/dist/ssr/vue-ui-donut.js +1 -1
- package/dist/ssr/vue-ui-xy.js +1 -1
- package/dist/ssr.js +2 -2
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.ts +9 -0
- package/dist/{useSvgExport-Ba9qBr9M.js → useChartExport-DNiwdPmb.js} +48 -2
- package/dist/{useConfig-BilxnBNr.js → useConfig-DlNpz6P8.js} +13 -1
- package/dist/{useNestedProp--NSEmhOH.js → useNestedProp-vPNvh7rV.js} +5 -3
- package/dist/{useObjectBindings-Cwq7NcQz.js → useObjectBindings-BeWS5v0i.js} +1 -1
- package/dist/{usePrinter-BFvi4jVy.js → usePrinter-DN5bYhTG.js} +2 -2
- package/dist/{useTimeLabels-B9CEuiLZ.js → useTimeLabels-d2f-W1L4.js} +2 -4
- package/dist/{useTooltipPosition-BsRysTrw.js → useTooltipPosition-DifeoeQW.js} +13 -13
- package/dist/utils.js +3 -3
- package/dist/{vue-data-ui-EsawKe_W.js → vue-data-ui-BNxtW8pK.js} +69 -69
- package/dist/vue-data-ui.js +74 -74
- package/dist/{vue-ui-3d-bar-RSUS2xpL.js → vue-ui-3d-bar-BYumVxZG.js} +147 -165
- package/dist/{vue-ui-accordion-61MlW-Ge.js → vue-ui-accordion-DegI2lzR.js} +4 -4
- package/dist/vue-ui-age-pyramid-tJx_hCsS.js +1241 -0
- package/dist/{vue-ui-annotator-DBRT85HG.js → vue-ui-annotator-DfG79D4r.js} +41 -68
- package/dist/vue-ui-bullet-DrWG4jRy.js +700 -0
- package/dist/{vue-ui-bump-Dvv3iSKr.js → vue-ui-bump-mKysp0KO.js} +222 -272
- package/dist/vue-ui-candlestick-PgKcBZdy.js +1837 -0
- package/dist/vue-ui-carousel-table-DRvycNBl.js +467 -0
- package/dist/{vue-ui-chestnut-ArloORzP.js → vue-ui-chestnut-Dpklo-VE.js} +311 -365
- package/dist/vue-ui-chord-7PPVH_iG.js +1345 -0
- package/dist/vue-ui-circle-pack-DW4Os6_8.js +1636 -0
- package/dist/{vue-ui-cursor-CxgE6Phh.js → vue-ui-cursor-DIt7vOwc.js} +4 -4
- package/dist/{vue-ui-dag-C9Sf9vH7.js → vue-ui-dag-Cl0WdSLb.js} +812 -840
- package/dist/{vue-ui-dashboard-bGmaglAj.js → vue-ui-dashboard-BwxRLR4E.js} +70 -70
- package/dist/{vue-ui-digits-DgDE-_Fn.js → vue-ui-digits-Bp1OH_t1.js} +5 -5
- package/dist/{vue-ui-donut-B_n6wF6B.js → vue-ui-donut-BZUT7QYt.js} +352 -377
- package/dist/vue-ui-donut-evolution-CQy3ZKXk.js +1549 -0
- package/dist/{vue-ui-donut-Bmo149AR.js → vue-ui-donut-y6tOAVyY.js} +18 -17
- package/dist/{vue-ui-dumbbell-BX4Ao_wR.js → vue-ui-dumbbell-BtKZcAOV.js} +370 -420
- package/dist/{vue-ui-flow-Bshw8pT_.js → vue-ui-flow-BF_cndsv.js} +191 -216
- package/dist/vue-ui-funnel-z3AeiDu6.js +750 -0
- package/dist/{vue-ui-galaxy-CvXgy-dy.js → vue-ui-galaxy-ClWaSOmM.js} +276 -302
- package/dist/vue-ui-gauge-CJstpakj.js +932 -0
- package/dist/{vue-ui-geo-C-gSZL2q.js → vue-ui-geo-B1tOD3HC.js} +398 -449
- package/dist/{vue-ui-gizmo-CJdxyPID.js → vue-ui-gizmo-foatosAv.js} +4 -4
- package/dist/{vue-ui-heatmap-DEEKv8ip.js → vue-ui-heatmap-By33A9dZ.js} +479 -502
- package/dist/{vue-ui-hill-D7LYAgAL.js → vue-ui-hill-ewqkK9s5.js} +570 -593
- package/dist/vue-ui-history-plot-FEIwXlsz.js +1698 -0
- package/dist/{vue-ui-horizontal-bar-CfFye5tL.js → vue-ui-horizontal-bar-D51sAeVu.js} +307 -332
- package/dist/{vue-ui-kpi-DCBnNfTb.js → vue-ui-kpi-y3EkgqJQ.js} +4 -4
- package/dist/{vue-ui-mini-loader-CtWpqnLW.js → vue-ui-mini-loader-CtTewZJG.js} +3 -3
- package/dist/vue-ui-molecule-paWHp18h.js +935 -0
- package/dist/{vue-ui-mood-radar-sl6DMxqR.js → vue-ui-mood-radar-wBRTZI5k.js} +341 -390
- package/dist/vue-ui-nested-donuts-CB-HOLo2.js +1503 -0
- package/dist/vue-ui-onion-B2Q2n55x.js +1233 -0
- package/dist/{vue-ui-parallel-coordinate-plot-DE9wTmQQ.js → vue-ui-parallel-coordinate-plot-GpkXiIZA.js} +189 -214
- package/dist/{vue-ui-quadrant-SaY_RPSE.js → vue-ui-quadrant-DOPuejDE.js} +254 -284
- package/dist/{vue-ui-quick-chart-CJ9rejnj.js → vue-ui-quick-chart-CgHX9njq.js} +108 -109
- package/dist/{vue-ui-radar-CaNen5Fj.js → vue-ui-radar-BLvG-_zE.js} +407 -434
- package/dist/{vue-ui-rating--K7rX2an.js → vue-ui-rating-BDVSVFA0.js} +10 -11
- package/dist/vue-ui-relation-circle-plOXwxJ5.js +903 -0
- package/dist/vue-ui-ridgeline-BbrnXvBo.js +1614 -0
- package/dist/{vue-ui-rings-BevKD8P-.js → vue-ui-rings-B3cKfMWy.js} +419 -444
- package/dist/vue-ui-scatter-BY7waF2T.js +2403 -0
- package/dist/{vue-ui-skeleton-B9ZP1w-i.js → vue-ui-skeleton-DwKxd7fk.js} +4 -4
- package/dist/{vue-ui-smiley-DYnqqk6u.js → vue-ui-smiley-5iHJeTPc.js} +64 -65
- package/dist/{vue-ui-spark-trend-R0ebpg-G.js → vue-ui-spark-trend-MpvrV5Wd.js} +11 -11
- package/dist/{vue-ui-sparkbar-DYC3By0v.js → vue-ui-sparkbar-s-2rBmEz.js} +97 -100
- package/dist/{vue-ui-sparkgauge-Bw6no-In.js → vue-ui-sparkgauge-B-BYVv4p.js} +4 -4
- package/dist/{vue-ui-sparkhistogram-DvRKy8rq.js → vue-ui-sparkhistogram-D7D4NHdi.js} +18 -19
- package/dist/{vue-ui-sparkline-Dz1uzBos.js → vue-ui-sparkline-RbeYtLWp.js} +11 -11
- package/dist/{vue-ui-sparkstackbar-DlnPdZih.js → vue-ui-sparkstackbar-ohN7mtbg.js} +194 -198
- package/dist/{vue-ui-stackbar-B-THcavY.js → vue-ui-stackbar-D2bpvQYt.js} +530 -552
- package/dist/{vue-ui-stackline-3dBPoI0h.js → vue-ui-stackline-Bo1oE8yq.js} +592 -614
- package/dist/vue-ui-strip-plot-CZ-C4a5x.js +1734 -0
- package/dist/vue-ui-table-3PPiJPV6.js +1352 -0
- package/dist/{vue-ui-table-heatmap-DVwMqzje.js → vue-ui-table-heatmap-D1bbPXKG.js} +56 -57
- package/dist/{vue-ui-table-sparkline-CABJzK8p.js → vue-ui-table-sparkline-l1cUX3ny.js} +13 -15
- package/dist/{vue-ui-thermometer-CVQ-H69Q.js → vue-ui-thermometer-DltAELO7.js} +240 -261
- package/dist/{vue-ui-timer-Bm8LpsnI.js → vue-ui-timer-DWNdx47q.js} +6 -6
- package/dist/vue-ui-tiremarks-GYhji_fa.js +538 -0
- package/dist/{vue-ui-treemap-DP0Sx8Y8.js → vue-ui-treemap-DjNlnOG5.js} +521 -547
- package/dist/vue-ui-waffle-BAA9EX6O.js +1386 -0
- package/dist/vue-ui-wheel-DrefGLos.js +871 -0
- package/dist/{vue-ui-word-cloud-B2sxtel9.js → vue-ui-word-cloud-CQZ8AyOi.js} +382 -405
- package/dist/{vue-ui-world-BBQZLnzm.js → vue-ui-world-Y7a3VEjq.js} +426 -451
- package/dist/{vue-ui-xy-DZj5DT-q.js → vue-ui-xy-CJcdttNL.js} +879 -905
- package/dist/{vue-ui-xy-ChZg7AtI.js → vue-ui-xy-DPxtkYGc.js} +329 -326
- package/dist/{vue-ui-xy-canvas-BN2u0bOJ.js → vue-ui-xy-canvas-1rbwMA1m.js} +30 -27
- package/package.json +4 -4
- package/dist/Slicer-5yIrdoJv.js +0 -1149
- package/dist/SlicerPreview-DvjLV2TW.js +0 -1689
- package/dist/vue-ui-age-pyramid-CgnPWA93.js +0 -1263
- package/dist/vue-ui-bullet-Bc3-WaN1.js +0 -724
- package/dist/vue-ui-candlestick-DvvsrIdp.js +0 -1864
- package/dist/vue-ui-carousel-table-DtsNVim8.js +0 -463
- package/dist/vue-ui-chord-xX5gWZy8.js +0 -1396
- package/dist/vue-ui-circle-pack-D8wykmqg.js +0 -1638
- package/dist/vue-ui-donut-evolution-D6vH_hfx.js +0 -1598
- package/dist/vue-ui-funnel-CjYosIik.js +0 -797
- package/dist/vue-ui-gauge-CByT0_vF.js +0 -953
- package/dist/vue-ui-history-plot-BhcU94Pt.js +0 -1722
- package/dist/vue-ui-molecule-D3igGyOy.js +0 -958
- package/dist/vue-ui-nested-donuts-aS4YzaB3.js +0 -1528
- package/dist/vue-ui-onion-EhPTZpW_.js +0 -1258
- package/dist/vue-ui-relation-circle-FLs8vOxQ.js +0 -925
- package/dist/vue-ui-ridgeline-Beg5hshN.js +0 -1663
- package/dist/vue-ui-scatter-CNA7jF-o.js +0 -2428
- package/dist/vue-ui-strip-plot-ACeYOoHj.js +0 -1757
- package/dist/vue-ui-table-rFy16bp0.js +0 -1347
- package/dist/vue-ui-tiremarks-DB3f5qiz.js +0 -559
- package/dist/vue-ui-waffle-iPpdk1Bm.js +0 -1412
- package/dist/vue-ui-wheel-BJkEYfLj.js +0 -892
|
@@ -0,0 +1,1233 @@
|
|
|
1
|
+
import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
|
|
2
|
+
import { $ as t, D as n, Jt as r, Kt as i, Pt as a, S as o, X as s, ct as ee, i as te, jt as ne, q as re, t as ie, tt as ae, w as oe, xt as se } from "./lib-Bttd6u5E.js";
|
|
3
|
+
import { n as ce, t as le } from "./useHints-Dq_w2E8B.js";
|
|
4
|
+
import { t as ue } from "./useConfig-DlNpz6P8.js";
|
|
5
|
+
import { t as de } from "./usePrinter-DN5bYhTG.js";
|
|
6
|
+
import { n as fe, t as pe } from "./BaseScanner-DZvpgOjM.js";
|
|
7
|
+
import { t as me } from "./useNestedProp-vPNvh7rV.js";
|
|
8
|
+
import { t as he } from "./useThemeCheck-C43Tcqmk.js";
|
|
9
|
+
import { t as ge } from "./useChartExport-DNiwdPmb.js";
|
|
10
|
+
import { t as _e } from "./useTransitions-g_zBREk2.js";
|
|
11
|
+
import { t as ve } from "./img-Bnokohej.js";
|
|
12
|
+
import { n as ye } from "./Title-BE3qg9xl.js";
|
|
13
|
+
import { t as be } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
14
|
+
import { l as xe, t as Se } from "./useResponsive-ZtArZtUf.js";
|
|
15
|
+
import { t as Ce } from "./BaseLegendToggle-DZVucLnv.js";
|
|
16
|
+
import { t as we } from "./A11yDataTable-DdRsVULz.js";
|
|
17
|
+
import { t as Te } from "./useUserOptionState-DK-_1ddE.js";
|
|
18
|
+
import { t as Ee } from "./useChartAccessibility-DYqac8yF.js";
|
|
19
|
+
import { t as De } from "./labelUtils-BeVpDvTJ.js";
|
|
20
|
+
import { t as Oe } from "./Legend-CQxUgOd-.js";
|
|
21
|
+
import { t as ke } from "./useAutoSizeLabelsInsideViewbox-DvDwcwi_.js";
|
|
22
|
+
import { t as Ae } from "./vue_ui_onion-1FTFFS46.js";
|
|
23
|
+
import { Fragment as je, Teleport as Me, computed as c, createBlock as l, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createSlots as Ne, createTextVNode as Pe, createVNode as Fe, defineAsyncComponent as p, guardReactiveProps as m, mergeProps as Ie, nextTick as Le, normalizeClass as h, normalizeProps as g, normalizeStyle as _, onBeforeUnmount as Re, onMounted as ze, openBlock as v, ref as y, renderList as b, renderSlot as x, resolveDynamicComponent as Be, shallowRef as Ve, toDisplayString as He, toRefs as Ue, unref as S, watch as C, withCtx as w } from "vue";
|
|
24
|
+
//#region src/components/vue-ui-onion.vue
|
|
25
|
+
var We = /* @__PURE__ */ e({ default: () => ft }), Ge = ["id"], Ke = ["id"], qe = ["id"], Je = { style: { position: "relative" } }, Ye = [
|
|
26
|
+
"xmlns",
|
|
27
|
+
"aria-describedby",
|
|
28
|
+
"viewBox"
|
|
29
|
+
], Xe = ["width", "height"], Ze = [
|
|
30
|
+
"cx",
|
|
31
|
+
"cy",
|
|
32
|
+
"r",
|
|
33
|
+
"stroke",
|
|
34
|
+
"stroke-width",
|
|
35
|
+
"stroke-dasharray",
|
|
36
|
+
"stroke-dashoffset"
|
|
37
|
+
], Qe = [
|
|
38
|
+
"cx",
|
|
39
|
+
"cy",
|
|
40
|
+
"r",
|
|
41
|
+
"stroke",
|
|
42
|
+
"stroke-width",
|
|
43
|
+
"stroke-dasharray",
|
|
44
|
+
"stroke-dashoffset"
|
|
45
|
+
], $e = ["id"], et = ["stdDeviation"], tt = ["filter"], nt = [
|
|
46
|
+
"cx",
|
|
47
|
+
"cy",
|
|
48
|
+
"r",
|
|
49
|
+
"stroke-width",
|
|
50
|
+
"stroke-dasharray",
|
|
51
|
+
"stroke-dashoffset"
|
|
52
|
+
], rt = [
|
|
53
|
+
"cx",
|
|
54
|
+
"cy",
|
|
55
|
+
"r",
|
|
56
|
+
"stroke-width",
|
|
57
|
+
"stroke-dasharray",
|
|
58
|
+
"stroke-dashoffset",
|
|
59
|
+
"onMouseenter",
|
|
60
|
+
"onMouseleave",
|
|
61
|
+
"onClick"
|
|
62
|
+
], it = { key: 2 }, at = [
|
|
63
|
+
"onMouseenter",
|
|
64
|
+
"onMouseleave",
|
|
65
|
+
"onClick"
|
|
66
|
+
], ot = [
|
|
67
|
+
"transform",
|
|
68
|
+
"font-size",
|
|
69
|
+
"fill",
|
|
70
|
+
"font-weight"
|
|
71
|
+
], st = {
|
|
72
|
+
key: 0,
|
|
73
|
+
style: {
|
|
74
|
+
position: "absolute",
|
|
75
|
+
top: "100%",
|
|
76
|
+
left: "0",
|
|
77
|
+
width: "100%"
|
|
78
|
+
},
|
|
79
|
+
"data-dom-to-png-ignore": "",
|
|
80
|
+
"aria-hidden": "true"
|
|
81
|
+
}, ct = {
|
|
82
|
+
key: 5,
|
|
83
|
+
class: "vue-data-ui-watermark"
|
|
84
|
+
}, lt = ["id"], ut = ["onClick"], dt = ["innerHTML"], ft = /*#__PURE__*/ be({
|
|
85
|
+
__name: "vue-ui-onion",
|
|
86
|
+
props: {
|
|
87
|
+
config: {
|
|
88
|
+
type: Object,
|
|
89
|
+
default() {
|
|
90
|
+
return {};
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
dataset: {
|
|
94
|
+
type: Array,
|
|
95
|
+
default() {
|
|
96
|
+
return [];
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
emits: ["selectLegend", "copyAlt"],
|
|
101
|
+
setup(e, { expose: be, emit: We }) {
|
|
102
|
+
let ft = p(() => import("./Tooltip-DhjyfHwz.js")), pt = p(() => import("./BaseIcon-BfndwIWE.js").then((e) => e.n)), mt = p(() => import("./vue-ui-accordion-DegI2lzR.js").then((e) => e.n)), ht = p(() => import("./DataTable-BbKgJ5UI.js")), gt = p(() => import("./UserOptions-Dt98of5H.js").then((e) => e.n)), _t = p(() => import("./PenAndPaper-DAE-tnEQ.js").then((e) => e.t)), vt = p(() => import("./PackageVersion-DXU7nRr9.js").then((e) => e.t)), yt = p(() => import("./BaseDraggableDialog-LoqqwRtV.js").then((e) => e.n)), { vue_ui_onion: bt } = ue(), { isThemeValid: xt, warnInvalidTheme: St } = he(), T = e, Ct = c(() => !!T.dataset && T.dataset.length), E = y(re()), wt = y(null), Tt = y(0), D = y(!1), Et = y(""), O = y([]), k = y(null), Dt = y(null), Ot = y(null), kt = y(null), At = y(null), jt = y(0), Mt = y(0), Nt = y(0), Pt = y(!1), Ft = y(!1), It = y(null), A = y(null), Lt = y({
|
|
103
|
+
x: 0,
|
|
104
|
+
y: 0
|
|
105
|
+
}), j = y("pointer"), Rt = y(!1), M = y(Gt());
|
|
106
|
+
ce({
|
|
107
|
+
config: () => M.value,
|
|
108
|
+
dataset: () => T.dataset,
|
|
109
|
+
component: "VueUiOnion",
|
|
110
|
+
rules: [le.emptyArray, {
|
|
111
|
+
test: (e) => e.length > 8,
|
|
112
|
+
message: [
|
|
113
|
+
"👀 The number of series is > 8. Consider:",
|
|
114
|
+
"",
|
|
115
|
+
"▶️ Grouping small values dynamically into a single \"Other\" series.",
|
|
116
|
+
"",
|
|
117
|
+
"▶️ Using filters to let users choose a maximum number of series to display.",
|
|
118
|
+
"",
|
|
119
|
+
"▶️ Using VueUiHorizontalBar instead to make the dataset breakdown easier to read."
|
|
120
|
+
]
|
|
121
|
+
}]
|
|
122
|
+
});
|
|
123
|
+
let { transitionEnabled: N } = _e({
|
|
124
|
+
config: () => M.value.transitions,
|
|
125
|
+
dataset: () => T.dataset
|
|
126
|
+
}), P = c(() => M.value.userOptions.useCursorPointer), zt = c(() => r({
|
|
127
|
+
defaultConfig: {
|
|
128
|
+
userOptions: { show: !1 },
|
|
129
|
+
table: { show: !1 },
|
|
130
|
+
style: { chart: {
|
|
131
|
+
backgroundColor: "#99999930",
|
|
132
|
+
layout: {
|
|
133
|
+
gutter: { color: "#99999950" },
|
|
134
|
+
labels: { show: !1 }
|
|
135
|
+
},
|
|
136
|
+
legend: { backgroundColor: "transparent" }
|
|
137
|
+
} }
|
|
138
|
+
},
|
|
139
|
+
userConfig: M.value.skeletonConfig ?? {}
|
|
140
|
+
})), { loading: F, FINAL_DATASET: Bt, manualLoading: Vt } = fe({
|
|
141
|
+
...Ue(T),
|
|
142
|
+
FINAL_CONFIG: M,
|
|
143
|
+
prepareConfig: Gt,
|
|
144
|
+
callback: () => {
|
|
145
|
+
Promise.resolve().then(async () => {
|
|
146
|
+
await Le(), dn();
|
|
147
|
+
});
|
|
148
|
+
},
|
|
149
|
+
skeletonDataset: T.config?.skeletonDataset ?? [
|
|
150
|
+
{
|
|
151
|
+
name: "_",
|
|
152
|
+
percentage: 50,
|
|
153
|
+
value: 1,
|
|
154
|
+
color: "#DBDBDB"
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
name: "_",
|
|
158
|
+
percentage: 50,
|
|
159
|
+
value: 1,
|
|
160
|
+
color: "#C4C4C4"
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
name: "_",
|
|
164
|
+
percentage: 50,
|
|
165
|
+
value: 1,
|
|
166
|
+
color: "#ADADAD"
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
name: "_",
|
|
170
|
+
percentage: 50,
|
|
171
|
+
value: 1,
|
|
172
|
+
color: "#969696"
|
|
173
|
+
}
|
|
174
|
+
],
|
|
175
|
+
skeletonConfig: r({
|
|
176
|
+
defaultConfig: M.value,
|
|
177
|
+
userConfig: zt.value
|
|
178
|
+
})
|
|
179
|
+
}), { userOptionsVisible: Ht, setUserOptionsVisibility: Ut, keepUserOptionState: Wt } = Te({ config: M.value }), { svgRef: I } = Ee({ config: M.value.style.chart.title });
|
|
180
|
+
function Gt() {
|
|
181
|
+
let e = me({
|
|
182
|
+
userConfig: T.config,
|
|
183
|
+
defaultConfig: bt
|
|
184
|
+
}), t = e.theme;
|
|
185
|
+
if (!t) return e;
|
|
186
|
+
if (!xt.value(e)) return St(e), e;
|
|
187
|
+
let n = me({
|
|
188
|
+
userConfig: Ae[t] || T.config,
|
|
189
|
+
defaultConfig: e
|
|
190
|
+
}), r = me({
|
|
191
|
+
userConfig: T.config,
|
|
192
|
+
defaultConfig: n
|
|
193
|
+
});
|
|
194
|
+
return {
|
|
195
|
+
...r,
|
|
196
|
+
customPalette: r.customPalette.length ? r.customPalette : i[t] || a
|
|
197
|
+
};
|
|
198
|
+
}
|
|
199
|
+
C(() => T.config, (e) => {
|
|
200
|
+
F.value || (M.value = Gt()), Ht.value = !M.value.userOptions.showOnChartHover, on(), jt.value += 1, Mt.value += 1, Nt.value += 1, L.value.showTable = M.value.table.show, L.value.showTooltip = M.value.style.chart.tooltip.show;
|
|
201
|
+
}, { deep: !0 });
|
|
202
|
+
let { isPrinting: Kt, isImaging: qt, generatePdf: Jt, generateImage: Yt } = de({
|
|
203
|
+
elementId: `vue-ui-onion_${E.value}`,
|
|
204
|
+
fileName: M.value.style.chart.title.text || "vue-ui-onion",
|
|
205
|
+
options: M.value.userOptions.print
|
|
206
|
+
}), Xt = c(() => M.value.userOptions.show && !M.value.style.chart.title.text), Zt = c(() => oe(M.value.customPalette)), L = y({
|
|
207
|
+
showTable: M.value.table.show,
|
|
208
|
+
showTooltip: M.value.style.chart.tooltip.show
|
|
209
|
+
});
|
|
210
|
+
C(M, () => {
|
|
211
|
+
L.value = {
|
|
212
|
+
showTable: M.value.table.show,
|
|
213
|
+
showTooltip: M.value.style.chart.tooltip.show
|
|
214
|
+
};
|
|
215
|
+
}, { immediate: !0 });
|
|
216
|
+
let R = y({
|
|
217
|
+
height: 512,
|
|
218
|
+
width: 512,
|
|
219
|
+
padding: {
|
|
220
|
+
top: 64,
|
|
221
|
+
left: 64,
|
|
222
|
+
right: 64,
|
|
223
|
+
bottom: 64
|
|
224
|
+
},
|
|
225
|
+
minRadius: 64
|
|
226
|
+
}), z = Ve(null), B = Ve(null);
|
|
227
|
+
ze(() => {
|
|
228
|
+
Ft.value = !0, on();
|
|
229
|
+
});
|
|
230
|
+
let { autoSizeLabels: Qt } = ke({
|
|
231
|
+
svgRef: I,
|
|
232
|
+
fontSize: () => M.value.style.chart.layout.labels.fontSize,
|
|
233
|
+
minFontSize: () => M.value.style.chart.layout.labels.minFontSize,
|
|
234
|
+
labelClass: ".vue-ui-onion-label"
|
|
235
|
+
}), V = null, H = null, U = 0;
|
|
236
|
+
function $t() {
|
|
237
|
+
V !== null && (cancelAnimationFrame(V), V = null), H !== null && (clearTimeout(H), H = null);
|
|
238
|
+
}
|
|
239
|
+
function en(e) {
|
|
240
|
+
return String(e).split(",").map((e) => {
|
|
241
|
+
let t = e.trim(), n = Number.parseFloat(t);
|
|
242
|
+
return Number.isFinite(n) ? t.endsWith("ms") ? n : n * 1e3 : 0;
|
|
243
|
+
});
|
|
244
|
+
}
|
|
245
|
+
function tn() {
|
|
246
|
+
return typeof window > "u" || !N.value || Pt.value || F.value || !I.value ? 0 : Array.from(I.value.querySelectorAll(".vue-ui-onion-label.vue-data-ui-transition")).reduce((e, t) => {
|
|
247
|
+
let n = window.getComputedStyle(t);
|
|
248
|
+
if (n.transitionProperty === "none") return e;
|
|
249
|
+
let r = en(n.transitionDuration), i = en(n.transitionDelay), a = Math.max(r.length, i.length), o = Array.from({ length: a }, (e, t) => (r[t % r.length] ?? 0) + (i[t % i.length] ?? 0)).reduce((e, t) => Math.max(e, t), 0);
|
|
250
|
+
return Math.max(e, o);
|
|
251
|
+
}, 0);
|
|
252
|
+
}
|
|
253
|
+
function nn() {
|
|
254
|
+
typeof window > "u" || (V = requestAnimationFrame(() => {
|
|
255
|
+
V = null, Qt();
|
|
256
|
+
}));
|
|
257
|
+
}
|
|
258
|
+
function W() {
|
|
259
|
+
if (typeof window > "u") return;
|
|
260
|
+
let e = ++U;
|
|
261
|
+
$t(), Le(() => {
|
|
262
|
+
e === U && (V = requestAnimationFrame(() => {
|
|
263
|
+
if (V = null, e !== U) return;
|
|
264
|
+
let t = tn();
|
|
265
|
+
if (t <= 0) {
|
|
266
|
+
nn();
|
|
267
|
+
return;
|
|
268
|
+
}
|
|
269
|
+
H = setTimeout(() => {
|
|
270
|
+
H = null, e === U && nn();
|
|
271
|
+
}, t + 34);
|
|
272
|
+
}));
|
|
273
|
+
});
|
|
274
|
+
}
|
|
275
|
+
let rn = c(() => M.value.debug), an = null;
|
|
276
|
+
function on() {
|
|
277
|
+
if (ne(T.dataset) && (ae({
|
|
278
|
+
componentName: "VueUiOnion",
|
|
279
|
+
type: "dataset",
|
|
280
|
+
debug: rn.value
|
|
281
|
+
}), Vt.value = !0), ne(T.dataset) || (Vt.value = M.value.loading), M.value.responsive) {
|
|
282
|
+
let e = 64 / 512, t = xe(() => {
|
|
283
|
+
an && clearTimeout(an), Pt.value = !0;
|
|
284
|
+
let { width: t, height: n } = Se({
|
|
285
|
+
chart: k.value,
|
|
286
|
+
title: M.value.style.chart.title.text ? Dt.value : null,
|
|
287
|
+
legend: M.value.style.chart.legend.show ? Ot.value : null,
|
|
288
|
+
source: kt.value,
|
|
289
|
+
noTitle: At.value
|
|
290
|
+
});
|
|
291
|
+
n -= 12, requestAnimationFrame(async () => {
|
|
292
|
+
R.value.width = t, R.value.height = n, R.value.padding.top = Math.max(t, n) * e, R.value.padding.right = Math.max(t, n) * e, R.value.padding.bottom = Math.max(t, n) * e, R.value.padding.left = Math.max(t, n) * e, R.value.minRadius = Math.min(t, n) * e, an = setTimeout(() => {
|
|
293
|
+
Pt.value = !1, W();
|
|
294
|
+
}, 0);
|
|
295
|
+
});
|
|
296
|
+
});
|
|
297
|
+
z.value && (B.value && z.value.unobserve(B.value), z.value.disconnect()), z.value = new ResizeObserver(t), B.value = k.value.parentNode, z.value.observe(B.value);
|
|
298
|
+
}
|
|
299
|
+
W();
|
|
300
|
+
}
|
|
301
|
+
Re(() => {
|
|
302
|
+
U += 1, $t(), z.value && (B.value && z.value.unobserve(B.value), z.value.disconnect());
|
|
303
|
+
});
|
|
304
|
+
let G = c(() => ({
|
|
305
|
+
top: R.value.padding.top,
|
|
306
|
+
left: R.value.padding.left,
|
|
307
|
+
right: R.value.width - R.value.padding.right,
|
|
308
|
+
bottom: R.value.height - R.value.padding.bottom,
|
|
309
|
+
centerX: R.value.width / 2,
|
|
310
|
+
centerY: R.value.height / 2,
|
|
311
|
+
width: R.value.width - R.value.padding.right - R.value.padding.left,
|
|
312
|
+
height: R.value.height - R.value.padding.bottom - R.value.padding.top,
|
|
313
|
+
minRadius: R.value.minRadius,
|
|
314
|
+
maxRadius: Math.min(R.value.width, R.value.height) - R.value.padding.top * 2
|
|
315
|
+
})), K = c(() => (rn.value && Bt.value.forEach((e, t) => {
|
|
316
|
+
[null, void 0].includes(e.name) && ae({
|
|
317
|
+
componentName: "VueUiOnion",
|
|
318
|
+
type: "datasetSerieAttribute",
|
|
319
|
+
property: "name",
|
|
320
|
+
index: t
|
|
321
|
+
}), [void 0].includes(e.percentage) && ae({
|
|
322
|
+
componentName: "VueUiOnion",
|
|
323
|
+
type: "datasetSerieAttribute",
|
|
324
|
+
property: "percentage",
|
|
325
|
+
index: t
|
|
326
|
+
});
|
|
327
|
+
}), Bt.value.map((e, t) => {
|
|
328
|
+
let n = `onion_serie_${t}_${E.value}`;
|
|
329
|
+
return {
|
|
330
|
+
...e,
|
|
331
|
+
percentage: e.percentage || 0,
|
|
332
|
+
targetPercentage: e.percentage || 0,
|
|
333
|
+
color: o(e.color) || Zt.value[t] || a[t],
|
|
334
|
+
id: n,
|
|
335
|
+
shape: "circle",
|
|
336
|
+
opacity: O.value.includes(n) ? .5 : 1,
|
|
337
|
+
absoluteIndex: t,
|
|
338
|
+
segregate: () => _n(n),
|
|
339
|
+
isSegregated: O.value.includes(n)
|
|
340
|
+
};
|
|
341
|
+
}))), q = c(() => K.value.map((e, t) => {
|
|
342
|
+
let n = M.value.style.chart.legend.showValue, r = M.value.style.chart.legend.showPercentage, i = Dn({
|
|
343
|
+
showVal: n,
|
|
344
|
+
showPercentage: r,
|
|
345
|
+
val: te(M.value.style.chart.layout.labels.value.formatter, e.value, s({
|
|
346
|
+
p: e.prefix || "",
|
|
347
|
+
v: e.value,
|
|
348
|
+
s: e.suffix || "",
|
|
349
|
+
r: M.value.style.chart.legend.roundingValue
|
|
350
|
+
})),
|
|
351
|
+
percentage: s({
|
|
352
|
+
v: e.percentage ?? 0,
|
|
353
|
+
s: "%",
|
|
354
|
+
r: M.value.style.chart.legend.roundingPercentage
|
|
355
|
+
}),
|
|
356
|
+
config: M.value.style.chart.legend
|
|
357
|
+
});
|
|
358
|
+
return {
|
|
359
|
+
...e,
|
|
360
|
+
display: `${e.name}${n || r ? ": " : ""}${i}`
|
|
361
|
+
};
|
|
362
|
+
})), J = y(K.value), sn = c(() => M.value.useStartAnimation), cn = y(null), ln = c(() => Math.max(...K.value.map((e) => e.percentage))), un = y(!1);
|
|
363
|
+
C(() => K.value, dn, {
|
|
364
|
+
immediate: !0,
|
|
365
|
+
deep: !0
|
|
366
|
+
}), C(() => T.dataset, (e) => {
|
|
367
|
+
Array.isArray(e) && e.length > 0 && (Vt.value = !1), W();
|
|
368
|
+
}, {
|
|
369
|
+
deep: !0,
|
|
370
|
+
flush: "post"
|
|
371
|
+
});
|
|
372
|
+
function dn() {
|
|
373
|
+
if (sn.value && !un.value && !F.value) {
|
|
374
|
+
J.value = K.value.map((e) => ({
|
|
375
|
+
...e,
|
|
376
|
+
percentage: 0
|
|
377
|
+
}));
|
|
378
|
+
let e = 0;
|
|
379
|
+
function t() {
|
|
380
|
+
e >= ln.value ? (cancelAnimationFrame(cn.value), J.value = K.value, un.value = !0) : (J.value = K.value.map((t) => ({
|
|
381
|
+
...t,
|
|
382
|
+
percentage: e < t.targetPercentage ? e : t.targetPercentage
|
|
383
|
+
})), e += 1, requestAnimationFrame(t), un.value = !0);
|
|
384
|
+
}
|
|
385
|
+
t();
|
|
386
|
+
} else J.value = K.value;
|
|
387
|
+
}
|
|
388
|
+
let fn = c(() => ({
|
|
389
|
+
cy: "onion-div-legend",
|
|
390
|
+
backgroundColor: M.value.style.chart.legend.backgroundColor,
|
|
391
|
+
color: M.value.style.chart.legend.color,
|
|
392
|
+
fontSize: M.value.style.chart.legend.fontSize,
|
|
393
|
+
paddingBottom: 12,
|
|
394
|
+
fontWeight: M.value.style.chart.legend.bold ? "bold" : ""
|
|
395
|
+
})), pn = c(() => K.value.filter((e) => !O.value.includes(e.id)).length), Y = c(() => {
|
|
396
|
+
let e = Math.min(G.value.width, G.value.height) / 2 / K.value.length;
|
|
397
|
+
return {
|
|
398
|
+
gutter: (e > M.value.style.chart.layout.maxThickness ? M.value.style.chart.layout.maxThickness : e) * M.value.style.chart.layout.gutter.width,
|
|
399
|
+
track: (e > M.value.style.chart.layout.maxThickness ? M.value.style.chart.layout.maxThickness : e) * M.value.style.chart.layout.track.width
|
|
400
|
+
};
|
|
401
|
+
}), X = c(() => J.value.filter((e) => !O.value.includes(e.id)).map((e, t) => {
|
|
402
|
+
let n = (G.value.maxRadius - Y.value.track) / pn.value / 2 * (1 + t), r = G.value.centerY - n;
|
|
403
|
+
return {
|
|
404
|
+
percentage: e.percentage || 0,
|
|
405
|
+
...e,
|
|
406
|
+
labelY: r,
|
|
407
|
+
radius: n,
|
|
408
|
+
path: mn(n, e.percentage || 0)
|
|
409
|
+
};
|
|
410
|
+
}));
|
|
411
|
+
function mn(e, t) {
|
|
412
|
+
let n = 2 * Math.PI * e, r = n * .75, i = `${r} ${n}`, a = r * (1 - t / 100);
|
|
413
|
+
return {
|
|
414
|
+
bgDashArray: `${r} ${n}`,
|
|
415
|
+
bgDashOffset: 0,
|
|
416
|
+
dashArray: i,
|
|
417
|
+
dashOffset: a,
|
|
418
|
+
fullOffset: 0,
|
|
419
|
+
active: `
|
|
420
|
+
M ${G.value.centerX},${G.value.centerY - e}
|
|
421
|
+
A ${e},${e} 0 1 1
|
|
422
|
+
${G.value.centerX + e * Math.cos(Math.PI * 3 / 4)},${G.value.centerY + e * Math.sin(Math.PI * 3 / 4)}
|
|
423
|
+
`.trim()
|
|
424
|
+
};
|
|
425
|
+
}
|
|
426
|
+
let hn = We;
|
|
427
|
+
function gn() {
|
|
428
|
+
O.value.length ? O.value = [] : q.value.forEach((e) => {
|
|
429
|
+
O.value.push(e.id);
|
|
430
|
+
}), W(), hn("selectLegend", X.value);
|
|
431
|
+
}
|
|
432
|
+
function _n(e) {
|
|
433
|
+
if (O.value.includes(e)) O.value = O.value.filter((t) => t !== e);
|
|
434
|
+
else {
|
|
435
|
+
if (O.value.length === K.value.length - 1) return;
|
|
436
|
+
O.value.push(e);
|
|
437
|
+
}
|
|
438
|
+
W(), hn("selectLegend", X.value);
|
|
439
|
+
}
|
|
440
|
+
function vn(e) {
|
|
441
|
+
return K.value.length ? K.value.find((t) => t.name === e) || (rn.value && console.warn(`VueUiOnion - Series name not found "${e}"`), null) : (rn.value && console.warn("VueUiOnion - There are no series to show."), null);
|
|
442
|
+
}
|
|
443
|
+
function yn(e) {
|
|
444
|
+
let t = vn(e);
|
|
445
|
+
t !== null && O.value.includes(t.id) && _n(t.id);
|
|
446
|
+
}
|
|
447
|
+
function bn(e) {
|
|
448
|
+
let t = vn(e);
|
|
449
|
+
t !== null && (O.value.includes(t.id) || _n(t.id));
|
|
450
|
+
}
|
|
451
|
+
function xn() {
|
|
452
|
+
return X.value;
|
|
453
|
+
}
|
|
454
|
+
let Sn = c(() => ({
|
|
455
|
+
head: [
|
|
456
|
+
M.value.table.translations.serie,
|
|
457
|
+
M.value.table.translations.percentage,
|
|
458
|
+
M.value.table.translations.value
|
|
459
|
+
],
|
|
460
|
+
body: X.value.map((e) => [
|
|
461
|
+
e.name,
|
|
462
|
+
e.percentage,
|
|
463
|
+
e.value
|
|
464
|
+
])
|
|
465
|
+
})), Z = c(() => {
|
|
466
|
+
let e = Sn.value.head;
|
|
467
|
+
return {
|
|
468
|
+
head: e,
|
|
469
|
+
body: X.value.map((e) => [
|
|
470
|
+
`<span style="color:${e.color}" aria-hidden="true">⬤</span> ${e.name}`,
|
|
471
|
+
`${Number(e.percentage ?? 0).toFixed(M.value.table.td.roundingPercentage).toLocaleString()}%`,
|
|
472
|
+
`${e.prefix || ""}${[
|
|
473
|
+
null,
|
|
474
|
+
void 0,
|
|
475
|
+
NaN,
|
|
476
|
+
"NaN"
|
|
477
|
+
].includes(e.value) ? "-" : e.value.toFixed(M.value.table.td.roundingValue).toLocaleString()}${e.suffix || ""}`
|
|
478
|
+
]),
|
|
479
|
+
config: {
|
|
480
|
+
th: {
|
|
481
|
+
backgroundColor: M.value.table.th.backgroundColor,
|
|
482
|
+
color: M.value.table.th.color,
|
|
483
|
+
outline: M.value.table.th.outline
|
|
484
|
+
},
|
|
485
|
+
td: {
|
|
486
|
+
backgroundColor: M.value.table.td.backgroundColor,
|
|
487
|
+
color: M.value.table.td.color,
|
|
488
|
+
outline: M.value.table.td.outline
|
|
489
|
+
},
|
|
490
|
+
breakpoint: M.value.table.responsiveBreakpoint
|
|
491
|
+
},
|
|
492
|
+
colNames: e
|
|
493
|
+
};
|
|
494
|
+
});
|
|
495
|
+
function Cn(e = null) {
|
|
496
|
+
Le(() => {
|
|
497
|
+
let r = [
|
|
498
|
+
[M.value.style.chart.title.text],
|
|
499
|
+
[M.value.style.chart.title.subtitle.text],
|
|
500
|
+
[""]
|
|
501
|
+
], i = Sn.value.head, a = Sn.value.body, o = r.concat([i]).concat(a), s = n(o);
|
|
502
|
+
e ? e(s) : t({
|
|
503
|
+
csvContent: s,
|
|
504
|
+
title: M.value.style.chart.title.text || "vue-ui-onion"
|
|
505
|
+
});
|
|
506
|
+
});
|
|
507
|
+
}
|
|
508
|
+
let Q = y(void 0), $ = y(!1);
|
|
509
|
+
function wn(e) {
|
|
510
|
+
$.value = e, Tt.value += 1;
|
|
511
|
+
}
|
|
512
|
+
function Tn({ datapoint: e }) {
|
|
513
|
+
M.value.events.datapointClick && M.value.events.datapointClick({
|
|
514
|
+
datapoint: e,
|
|
515
|
+
seriesIndex: e.absoluteIndex
|
|
516
|
+
});
|
|
517
|
+
}
|
|
518
|
+
function En({ datapoint: e }) {
|
|
519
|
+
Q.value = void 0, D.value = !1, A.value = null, j.value = "pointer", M.value.events.datapointLeave && M.value.events.datapointLeave({
|
|
520
|
+
datapoint: e,
|
|
521
|
+
seriesIndex: e.absoluteIndex
|
|
522
|
+
});
|
|
523
|
+
}
|
|
524
|
+
function Dn({ val: e, percentage: t, showVal: n, showPercentage: r, config: i }) {
|
|
525
|
+
return De({
|
|
526
|
+
config: i,
|
|
527
|
+
val: e,
|
|
528
|
+
percentage: t,
|
|
529
|
+
showVal: n,
|
|
530
|
+
showPercentage: r
|
|
531
|
+
});
|
|
532
|
+
}
|
|
533
|
+
function On(e, t) {
|
|
534
|
+
let n = M.value.style.chart.layout.labels.value.show, r = M.value.style.chart.layout.labels.percentage.show, i = Dn({
|
|
535
|
+
config: M.value.style.chart.layout.labels,
|
|
536
|
+
showVal: n,
|
|
537
|
+
showPercentage: r,
|
|
538
|
+
val: te(M.value.style.chart.layout.labels.value.formatter, e.value, s({
|
|
539
|
+
p: e.prefix || "",
|
|
540
|
+
v: e.value || 0,
|
|
541
|
+
s: e.suffix || "",
|
|
542
|
+
r: M.value.style.chart.layout.labels.roundingValue
|
|
543
|
+
}), {
|
|
544
|
+
datapoint: e,
|
|
545
|
+
seriesIndex: t
|
|
546
|
+
}),
|
|
547
|
+
percentage: s({
|
|
548
|
+
v: e.percentage,
|
|
549
|
+
s: "%",
|
|
550
|
+
r: M.value.style.chart.layout.labels.roundingPercentage
|
|
551
|
+
})
|
|
552
|
+
});
|
|
553
|
+
return `${e.name}${n || r ? ": " : ""}${i}`;
|
|
554
|
+
}
|
|
555
|
+
let kn = y(null);
|
|
556
|
+
function An({ datapoint: e, seriesIndex: t, show: n = !0, triggerMode: r = "pointer" }) {
|
|
557
|
+
M.value.events.datapointEnter && M.value.events.datapointEnter({
|
|
558
|
+
datapoint: e,
|
|
559
|
+
seriesIndex: e.absoluteIndex
|
|
560
|
+
}), j.value = r, A.value = t;
|
|
561
|
+
let i = e.absoluteIndex;
|
|
562
|
+
Q.value = t, kn.value = {
|
|
563
|
+
datapoint: e,
|
|
564
|
+
seriesIndex: i,
|
|
565
|
+
series: K.value,
|
|
566
|
+
config: M.value
|
|
567
|
+
}, D.value = n;
|
|
568
|
+
let a = "", o = M.value.style.chart.tooltip.customFormat;
|
|
569
|
+
if (se(o) && ee(() => o({
|
|
570
|
+
seriesIndex: i,
|
|
571
|
+
datapoint: e,
|
|
572
|
+
series: K.value,
|
|
573
|
+
config: M.value
|
|
574
|
+
}))) Et.value = o({
|
|
575
|
+
seriesIndex: i,
|
|
576
|
+
datapoint: e,
|
|
577
|
+
series: K.value,
|
|
578
|
+
config: M.value
|
|
579
|
+
});
|
|
580
|
+
else {
|
|
581
|
+
let n = M.value.style.chart.tooltip.showPercentage, r = M.value.style.chart.tooltip.showValue;
|
|
582
|
+
a += `<div style="width:100%;text-align:center;border-bottom:1px solid ${M.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${e.name}</div>`, a += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 60 60" height="14" width="14"><circle cx="30" cy="30" r="30" stroke="none" fill="${e.color}"/></svg>`, a += `<b>${Dn({
|
|
583
|
+
config: M.value.style.chart.tooltip,
|
|
584
|
+
showVal: r,
|
|
585
|
+
showPercentage: n,
|
|
586
|
+
val: `<span>${te(M.value.style.chart.layout.labels.value.formatter, e.value, s({
|
|
587
|
+
p: e.prefix || "",
|
|
588
|
+
v: e.value,
|
|
589
|
+
s: e.suffix || "",
|
|
590
|
+
r: M.value.style.chart.tooltip.roundingValue
|
|
591
|
+
}), {
|
|
592
|
+
datapoint: e,
|
|
593
|
+
seriesIndex: t
|
|
594
|
+
})}</span>`,
|
|
595
|
+
percentage: s({
|
|
596
|
+
v: e.percentage,
|
|
597
|
+
s: "%",
|
|
598
|
+
r: M.value.style.chart.tooltip.roundingPercentage
|
|
599
|
+
})
|
|
600
|
+
})}</b></div>`, Et.value = `<div>${a}</div>`;
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
function jn() {
|
|
604
|
+
L.value.showTable = !L.value.showTable;
|
|
605
|
+
}
|
|
606
|
+
function Mn() {
|
|
607
|
+
L.value.showTooltip = !L.value.showTooltip;
|
|
608
|
+
}
|
|
609
|
+
let Nn = y(!1);
|
|
610
|
+
function Pn() {
|
|
611
|
+
Nn.value = !Nn.value;
|
|
612
|
+
}
|
|
613
|
+
async function Fn({ scale: e = 2 } = {}) {
|
|
614
|
+
if (!k.value) return;
|
|
615
|
+
let { width: t, height: n } = k.value.getBoundingClientRect(), r = t / n, { imageUri: i, base64: a } = await ve({
|
|
616
|
+
domElement: k.value,
|
|
617
|
+
base64: !0,
|
|
618
|
+
img: !0,
|
|
619
|
+
scale: e
|
|
620
|
+
});
|
|
621
|
+
return {
|
|
622
|
+
imageUri: i,
|
|
623
|
+
base64: a,
|
|
624
|
+
title: M.value.style.chart.title.text,
|
|
625
|
+
width: t,
|
|
626
|
+
height: n,
|
|
627
|
+
aspectRatio: r
|
|
628
|
+
};
|
|
629
|
+
}
|
|
630
|
+
let In = c(() => {
|
|
631
|
+
let e = M.value.table.useDialog && !M.value.table.show, t = L.value.showTable;
|
|
632
|
+
return {
|
|
633
|
+
component: e ? yt : mt,
|
|
634
|
+
title: `${M.value.style.chart.title.text}${M.value.style.chart.title.subtitle.text ? `: ${M.value.style.chart.title.subtitle.text}` : ""}`,
|
|
635
|
+
props: e ? {
|
|
636
|
+
backgroundColor: M.value.table.th.backgroundColor,
|
|
637
|
+
color: M.value.table.th.color,
|
|
638
|
+
headerColor: M.value.table.th.color,
|
|
639
|
+
headerBg: M.value.table.th.backgroundColor,
|
|
640
|
+
isFullscreen: $.value,
|
|
641
|
+
fullscreenParent: k.value,
|
|
642
|
+
forcedWidth: Math.min(600, window.innerWidth * .8),
|
|
643
|
+
isCursorPointer: P.value
|
|
644
|
+
} : {
|
|
645
|
+
hideDetails: !0,
|
|
646
|
+
config: {
|
|
647
|
+
open: t,
|
|
648
|
+
maxHeight: 1e4,
|
|
649
|
+
body: {
|
|
650
|
+
backgroundColor: M.value.style.chart.backgroundColor,
|
|
651
|
+
color: M.value.style.chart.color
|
|
652
|
+
},
|
|
653
|
+
head: {
|
|
654
|
+
backgroundColor: M.value.style.chart.backgroundColor,
|
|
655
|
+
color: M.value.style.chart.color
|
|
656
|
+
}
|
|
657
|
+
}
|
|
658
|
+
}
|
|
659
|
+
};
|
|
660
|
+
});
|
|
661
|
+
C(() => L.value.showTable, (e) => {
|
|
662
|
+
M.value.table.show || (e && M.value.table.useDialog && It.value ? It.value.open() : "close" in It.value && It.value.close());
|
|
663
|
+
});
|
|
664
|
+
let Ln = c(() => q.value.map((e) => ({
|
|
665
|
+
...e,
|
|
666
|
+
name: e.display
|
|
667
|
+
}))), Rn = c(() => M.value.style.chart.backgroundColor), zn = c(() => M.value.style.chart.legend), Bn = c(() => M.value.style.chart.title), { isCallbackImaging: Vn, isCallbackSvg: Hn, generateSvg: Un, onGenerateImage: Wn } = ge({
|
|
668
|
+
svg: I,
|
|
669
|
+
title: Bn,
|
|
670
|
+
legend: zn,
|
|
671
|
+
legendItems: Ln,
|
|
672
|
+
backgroundColor: Rn,
|
|
673
|
+
getSvgCallback: () => M.value.userOptions.callbacks.svg,
|
|
674
|
+
generateImage: Yt
|
|
675
|
+
});
|
|
676
|
+
async function Gn() {
|
|
677
|
+
if (hn("copyAlt", {
|
|
678
|
+
config: M.value,
|
|
679
|
+
dataset: X.value
|
|
680
|
+
}), !M.value.userOptions.callbacks.altCopy) {
|
|
681
|
+
console.warn("Vue Data UI - A callback must be set for `altCopy` in userOptions.");
|
|
682
|
+
return;
|
|
683
|
+
}
|
|
684
|
+
await Promise.resolve(M.value.userOptions.callbacks.altCopy({
|
|
685
|
+
config: M.value,
|
|
686
|
+
dataset: X.value
|
|
687
|
+
}));
|
|
688
|
+
}
|
|
689
|
+
function Kn() {
|
|
690
|
+
A.value = null, Rt.value = !0;
|
|
691
|
+
}
|
|
692
|
+
function qn() {
|
|
693
|
+
A.value = null, j.value = "pointer", D.value = !1, Q.value = void 0, Rt.value = !1;
|
|
694
|
+
}
|
|
695
|
+
function Jn(e) {
|
|
696
|
+
if (!I.value || Nn.value || document.activeElement !== I.value || !X.value.length) return;
|
|
697
|
+
let t = ["ArrowLeft", "ArrowDown"].includes(e.key), n = ["ArrowRight", "ArrowUp"].includes(e.key), r = e.key === "Enter" || e.key === " ", i = e.key === "Escape";
|
|
698
|
+
if (!t && !n && !r && !i) return;
|
|
699
|
+
if (e.preventDefault(), e.stopPropagation(), i) {
|
|
700
|
+
A.value = null, j.value = "pointer", D.value = !1, Q.value = void 0;
|
|
701
|
+
return;
|
|
702
|
+
}
|
|
703
|
+
if (r) {
|
|
704
|
+
if (A.value === null) return;
|
|
705
|
+
let e = X.value[A.value];
|
|
706
|
+
if (!e) return;
|
|
707
|
+
Tn({ datapoint: e });
|
|
708
|
+
return;
|
|
709
|
+
}
|
|
710
|
+
let a = A.value;
|
|
711
|
+
a === null || a < 0 || a >= X.value.length ? a = n ? 0 : X.value.length - 1 : n ? (a += 1, a >= X.value.length && (a = 0)) : t && (--a, a < 0 && (a = X.value.length - 1));
|
|
712
|
+
let o = X.value[a];
|
|
713
|
+
o && (Yn(a), An({
|
|
714
|
+
datapoint: o,
|
|
715
|
+
seriesIndex: a,
|
|
716
|
+
show: !0,
|
|
717
|
+
triggerMode: "keyboard"
|
|
718
|
+
}));
|
|
719
|
+
}
|
|
720
|
+
function Yn(e) {
|
|
721
|
+
if (!Number.isFinite(e) || !I.value) return;
|
|
722
|
+
let t = X.value[e];
|
|
723
|
+
if (!t) return;
|
|
724
|
+
let n = t.radius, r = Math.PI * 7 / 4, i = G.value.centerX + n * Math.cos(r), a = G.value.centerY + n * Math.sin(r), o = I.value.getBoundingClientRect();
|
|
725
|
+
Lt.value = {
|
|
726
|
+
x: o.left + i / R.value.width * o.width,
|
|
727
|
+
y: o.top + a / R.value.height * o.height
|
|
728
|
+
};
|
|
729
|
+
}
|
|
730
|
+
let Xn = c(() => ({
|
|
731
|
+
headers: Z.value?.colNames ?? [],
|
|
732
|
+
rows: Z.value?.body ?? []
|
|
733
|
+
}));
|
|
734
|
+
return be({
|
|
735
|
+
getData: xn,
|
|
736
|
+
getImage: Fn,
|
|
737
|
+
generatePdf: Jt,
|
|
738
|
+
generateCsv: Cn,
|
|
739
|
+
generateImage: Yt,
|
|
740
|
+
generateSvg: Un,
|
|
741
|
+
hideSeries: bn,
|
|
742
|
+
showSeries: yn,
|
|
743
|
+
toggleTable: jn,
|
|
744
|
+
toggleTooltip: Mn,
|
|
745
|
+
toggleAnnotator: Pn,
|
|
746
|
+
toggleFullscreen: wn,
|
|
747
|
+
copyAlt: Gn
|
|
748
|
+
}), (e, t) => (v(), d("div", {
|
|
749
|
+
class: h(`vue-data-ui-component vue-ui-onion ${$.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${M.value.useCssAnimation ? "" : "vue-ui-dna"}`),
|
|
750
|
+
ref_key: "onionChart",
|
|
751
|
+
ref: k,
|
|
752
|
+
id: `vue-ui-onion_${E.value}`,
|
|
753
|
+
style: _(`font-family:${M.value.style.fontFamily};width:100%; ${M.value.responsive ? "height: 100%;" : ""} text-align:center;background:${M.value.style.chart.backgroundColor}`),
|
|
754
|
+
onMouseenter: t[4] ||= () => S(Ut)(!0),
|
|
755
|
+
onMouseleave: t[5] ||= () => S(Ut)(!1)
|
|
756
|
+
}, [
|
|
757
|
+
f("div", {
|
|
758
|
+
id: `chart-instructions-${E.value}`,
|
|
759
|
+
class: "sr-only"
|
|
760
|
+
}, [f("p", null, He(M.value.a11y.translations.keyboardNavigation), 1)], 8, Ke),
|
|
761
|
+
Xn.value?.rows?.length ? (v(), l(we, {
|
|
762
|
+
key: 0,
|
|
763
|
+
uid: E.value,
|
|
764
|
+
head: Xn.value.headers,
|
|
765
|
+
body: Xn.value.rows,
|
|
766
|
+
notice: M.value.a11y.translations.tableAvailable,
|
|
767
|
+
caption: M.value.a11y.translations.tableCaption
|
|
768
|
+
}, null, 8, [
|
|
769
|
+
"uid",
|
|
770
|
+
"head",
|
|
771
|
+
"body",
|
|
772
|
+
"notice",
|
|
773
|
+
"caption"
|
|
774
|
+
])) : u("", !0),
|
|
775
|
+
M.value.userOptions.buttons.annotator ? (v(), l(S(_t), {
|
|
776
|
+
key: 1,
|
|
777
|
+
svgRef: S(I),
|
|
778
|
+
backgroundColor: M.value.style.chart.backgroundColor,
|
|
779
|
+
color: M.value.style.chart.color,
|
|
780
|
+
active: Nn.value,
|
|
781
|
+
isCursorPointer: P.value,
|
|
782
|
+
onClose: Pn
|
|
783
|
+
}, {
|
|
784
|
+
"annotator-action-close": w(() => [x(e.$slots, "annotator-action-close", {}, void 0, !0)]),
|
|
785
|
+
"annotator-action-color": w(({ color: t }) => [x(e.$slots, "annotator-action-color", g(m({ color: t })), void 0, !0)]),
|
|
786
|
+
"annotator-action-draw": w(({ mode: t }) => [x(e.$slots, "annotator-action-draw", g(m({ mode: t })), void 0, !0)]),
|
|
787
|
+
"annotator-action-undo": w(({ disabled: t }) => [x(e.$slots, "annotator-action-undo", g(m({ disabled: t })), void 0, !0)]),
|
|
788
|
+
"annotator-action-redo": w(({ disabled: t }) => [x(e.$slots, "annotator-action-redo", g(m({ disabled: t })), void 0, !0)]),
|
|
789
|
+
"annotator-action-delete": w(({ disabled: t }) => [x(e.$slots, "annotator-action-delete", g(m({ disabled: t })), void 0, !0)]),
|
|
790
|
+
_: 3
|
|
791
|
+
}, 8, [
|
|
792
|
+
"svgRef",
|
|
793
|
+
"backgroundColor",
|
|
794
|
+
"color",
|
|
795
|
+
"active",
|
|
796
|
+
"isCursorPointer"
|
|
797
|
+
])) : u("", !0),
|
|
798
|
+
Xt.value ? (v(), d("div", {
|
|
799
|
+
key: 2,
|
|
800
|
+
ref_key: "noTitle",
|
|
801
|
+
ref: At,
|
|
802
|
+
class: "vue-data-ui-no-title-space",
|
|
803
|
+
style: "height:36px; width: 100%;background:transparent"
|
|
804
|
+
}, null, 512)) : u("", !0),
|
|
805
|
+
M.value.style.chart.title.text ? (v(), d("div", {
|
|
806
|
+
key: 3,
|
|
807
|
+
ref_key: "chartTitle",
|
|
808
|
+
ref: Dt,
|
|
809
|
+
style: "width:100%;background:transparent"
|
|
810
|
+
}, [(v(), l(ye, {
|
|
811
|
+
key: `title_${jt.value}`,
|
|
812
|
+
config: {
|
|
813
|
+
title: {
|
|
814
|
+
cy: "onion-div-title",
|
|
815
|
+
...M.value.style.chart.title
|
|
816
|
+
},
|
|
817
|
+
subtitle: {
|
|
818
|
+
cy: "onion-div-subtitle",
|
|
819
|
+
...M.value.style.chart.title.subtitle
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
}, null, 8, ["config"]))], 512)) : u("", !0),
|
|
823
|
+
f("div", { id: `legend-top-${E.value}` }, null, 8, qe),
|
|
824
|
+
M.value.userOptions.show && Ct.value && (S(Wt) || S(Ht)) ? (v(), l(S(gt), {
|
|
825
|
+
ref_key: "details",
|
|
826
|
+
ref: wt,
|
|
827
|
+
key: `user_options${Tt.value}`,
|
|
828
|
+
backgroundColor: M.value.style.chart.backgroundColor,
|
|
829
|
+
color: M.value.style.chart.color,
|
|
830
|
+
isImaging: S(qt),
|
|
831
|
+
isPrinting: S(Kt),
|
|
832
|
+
uid: E.value,
|
|
833
|
+
hasTooltip: M.value.userOptions.buttons.tooltip && M.value.style.chart.tooltip.show,
|
|
834
|
+
hasPdf: M.value.userOptions.buttons.pdf,
|
|
835
|
+
hasImg: M.value.userOptions.buttons.img,
|
|
836
|
+
hasSvg: M.value.userOptions.buttons.svg,
|
|
837
|
+
hasXls: M.value.userOptions.buttons.csv,
|
|
838
|
+
hasTable: M.value.userOptions.buttons.table,
|
|
839
|
+
hasFullscreen: M.value.userOptions.buttons.fullscreen,
|
|
840
|
+
hasAltCopy: M.value.userOptions.buttons.altCopy,
|
|
841
|
+
isFullscreen: $.value,
|
|
842
|
+
isTooltip: L.value.showTooltip,
|
|
843
|
+
titles: { ...M.value.userOptions.buttonTitles },
|
|
844
|
+
chartElement: k.value,
|
|
845
|
+
position: M.value.userOptions.position,
|
|
846
|
+
hasAnnotator: M.value.userOptions.buttons.annotator,
|
|
847
|
+
isAnnotation: Nn.value,
|
|
848
|
+
callbacks: M.value.userOptions.callbacks,
|
|
849
|
+
printScale: M.value.userOptions.print.scale,
|
|
850
|
+
tableDialog: M.value.table.useDialog,
|
|
851
|
+
isCursorPointer: P.value,
|
|
852
|
+
onToggleFullscreen: wn,
|
|
853
|
+
onGeneratePdf: S(Jt),
|
|
854
|
+
onGenerateCsv: Cn,
|
|
855
|
+
onGenerateImage: S(Wn),
|
|
856
|
+
onGenerateSvg: S(Un),
|
|
857
|
+
onToggleTable: jn,
|
|
858
|
+
onToggleTooltip: Mn,
|
|
859
|
+
onToggleAnnotator: Pn,
|
|
860
|
+
onCopyAlt: Gn,
|
|
861
|
+
style: _({ visibility: S(Wt) ? S(Ht) ? "visible" : "hidden" : "visible" })
|
|
862
|
+
}, Ne({ _: 2 }, [
|
|
863
|
+
e.$slots.menuIcon ? {
|
|
864
|
+
name: "menuIcon",
|
|
865
|
+
fn: w(({ isOpen: t, color: n }) => [x(e.$slots, "menuIcon", g(m({
|
|
866
|
+
isOpen: t,
|
|
867
|
+
color: n
|
|
868
|
+
})), void 0, !0)]),
|
|
869
|
+
key: "0"
|
|
870
|
+
} : void 0,
|
|
871
|
+
e.$slots.optionTooltip ? {
|
|
872
|
+
name: "optionTooltip",
|
|
873
|
+
fn: w(() => [x(e.$slots, "optionTooltip", {}, void 0, !0)]),
|
|
874
|
+
key: "1"
|
|
875
|
+
} : void 0,
|
|
876
|
+
e.$slots.optionPdf ? {
|
|
877
|
+
name: "optionPdf",
|
|
878
|
+
fn: w(() => [x(e.$slots, "optionPdf", {}, void 0, !0)]),
|
|
879
|
+
key: "2"
|
|
880
|
+
} : void 0,
|
|
881
|
+
e.$slots.optionCsv ? {
|
|
882
|
+
name: "optionCsv",
|
|
883
|
+
fn: w(() => [x(e.$slots, "optionCsv", {}, void 0, !0)]),
|
|
884
|
+
key: "3"
|
|
885
|
+
} : void 0,
|
|
886
|
+
e.$slots.optionImg ? {
|
|
887
|
+
name: "optionImg",
|
|
888
|
+
fn: w(() => [x(e.$slots, "optionImg", {}, void 0, !0)]),
|
|
889
|
+
key: "4"
|
|
890
|
+
} : void 0,
|
|
891
|
+
e.$slots.optionSvg ? {
|
|
892
|
+
name: "optionSvg",
|
|
893
|
+
fn: w(() => [x(e.$slots, "optionSvg", {}, void 0, !0)]),
|
|
894
|
+
key: "5"
|
|
895
|
+
} : void 0,
|
|
896
|
+
e.$slots.optionTable ? {
|
|
897
|
+
name: "optionTable",
|
|
898
|
+
fn: w(() => [x(e.$slots, "optionTable", {}, void 0, !0)]),
|
|
899
|
+
key: "6"
|
|
900
|
+
} : void 0,
|
|
901
|
+
e.$slots.optionFullscreen ? {
|
|
902
|
+
name: "optionFullscreen",
|
|
903
|
+
fn: w(({ toggleFullscreen: t, isFullscreen: n }) => [x(e.$slots, "optionFullscreen", g(m({
|
|
904
|
+
toggleFullscreen: t,
|
|
905
|
+
isFullscreen: n
|
|
906
|
+
})), void 0, !0)]),
|
|
907
|
+
key: "7"
|
|
908
|
+
} : void 0,
|
|
909
|
+
e.$slots.optionAnnotator ? {
|
|
910
|
+
name: "optionAnnotator",
|
|
911
|
+
fn: w(({ toggleAnnotator: t, isAnnotator: n }) => [x(e.$slots, "optionAnnotator", g(m({
|
|
912
|
+
toggleAnnotator: t,
|
|
913
|
+
isAnnotator: n
|
|
914
|
+
})), void 0, !0)]),
|
|
915
|
+
key: "8"
|
|
916
|
+
} : void 0,
|
|
917
|
+
e.$slots.optionAltCopy ? {
|
|
918
|
+
name: "optionAltCopy",
|
|
919
|
+
fn: w(({ altCopy: t }) => [x(e.$slots, "optionAltCopy", g(m({ altCopy: t })), void 0, !0)]),
|
|
920
|
+
key: "9"
|
|
921
|
+
} : void 0,
|
|
922
|
+
e.$slots["custom-menu-before"] ? {
|
|
923
|
+
name: "custom-menu-before",
|
|
924
|
+
fn: w(() => [x(e.$slots, "custom-menu-before", {}, void 0, !0)]),
|
|
925
|
+
key: "10"
|
|
926
|
+
} : void 0,
|
|
927
|
+
e.$slots["custom-menu-after"] ? {
|
|
928
|
+
name: "custom-menu-after",
|
|
929
|
+
fn: w(() => [x(e.$slots, "custom-menu-after", {}, void 0, !0)]),
|
|
930
|
+
key: "11"
|
|
931
|
+
} : void 0
|
|
932
|
+
]), 1032, /* @__PURE__ */ "backgroundColor.color.isImaging.isPrinting.uid.hasTooltip.hasPdf.hasImg.hasSvg.hasXls.hasTable.hasFullscreen.hasAltCopy.isFullscreen.isTooltip.titles.chartElement.position.hasAnnotator.isAnnotation.callbacks.printScale.tableDialog.isCursorPointer.onGeneratePdf.onGenerateImage.onGenerateSvg.style".split("."))) : u("", !0),
|
|
933
|
+
f("div", Je, [(v(), d("svg", {
|
|
934
|
+
ref_key: "svgRef",
|
|
935
|
+
ref: I,
|
|
936
|
+
xmlns: S(ie),
|
|
937
|
+
"aria-describedby": `chart-instructions-${E.value}`,
|
|
938
|
+
class: h({
|
|
939
|
+
"vue-data-ui-fullscreen--on": $.value,
|
|
940
|
+
"vue-data-ui-fulscreen--off": !$.value,
|
|
941
|
+
resizing: Pt.value,
|
|
942
|
+
"vue-data-ui-no-transition": !S(N) || Pt.value || S(F)
|
|
943
|
+
}),
|
|
944
|
+
viewBox: `0 0 ${R.value.width <= 0 ? 10 : R.value.width} ${R.value.height <= 0 ? 10 : R.value.height}`,
|
|
945
|
+
style: _(`max-width:100%;overflow:visible;background:transparent;color:${M.value.style.chart.color}`),
|
|
946
|
+
tabindex: "0",
|
|
947
|
+
onFocus: Kn,
|
|
948
|
+
onBlur: qn,
|
|
949
|
+
onKeydown: Jn
|
|
950
|
+
}, [
|
|
951
|
+
Fe(S(vt)),
|
|
952
|
+
e.$slots["chart-background"] ? (v(), d("foreignObject", {
|
|
953
|
+
key: 0,
|
|
954
|
+
x: 0,
|
|
955
|
+
y: 0,
|
|
956
|
+
width: R.value.width <= 0 ? 10 : R.value.width,
|
|
957
|
+
height: R.value.height <= 0 ? 10 : R.value.height,
|
|
958
|
+
style: { pointerEvents: "none" }
|
|
959
|
+
}, [x(e.$slots, "chart-background", {}, void 0, !0)], 8, Xe)) : u("", !0),
|
|
960
|
+
(v(!0), d(je, null, b(X.value, (e, t) => (v(), d("circle", {
|
|
961
|
+
cx: G.value.centerX,
|
|
962
|
+
cy: G.value.centerY,
|
|
963
|
+
r: e.radius <= 0 ? 1e-4 : e.radius,
|
|
964
|
+
stroke: M.value.style.chart.layout.gutter.color,
|
|
965
|
+
"stroke-width": Y.value.gutter,
|
|
966
|
+
fill: "none",
|
|
967
|
+
"stroke-dasharray": e.path.bgDashArray,
|
|
968
|
+
"stroke-dashoffset": e.path.fullOffset,
|
|
969
|
+
"stroke-linecap": "round",
|
|
970
|
+
class: h({
|
|
971
|
+
"vue-ui-onion-path": !0,
|
|
972
|
+
"vue-ui-onion-blur": M.value.useBlurOnHover && ![null, void 0].includes(Q.value) && Q.value !== t,
|
|
973
|
+
"vue-data-ui-transition": S(N)
|
|
974
|
+
}),
|
|
975
|
+
style: {
|
|
976
|
+
transform: "rotate(-90deg)",
|
|
977
|
+
transformOrigin: "50% 50%"
|
|
978
|
+
}
|
|
979
|
+
}, null, 10, Ze))), 256)),
|
|
980
|
+
(v(!0), d(je, null, b(X.value, (e, t) => (v(), d("circle", {
|
|
981
|
+
cx: G.value.centerX,
|
|
982
|
+
cy: G.value.centerY,
|
|
983
|
+
r: e.radius < 0 ? 1e-4 : e.radius,
|
|
984
|
+
stroke: `${e.color}`,
|
|
985
|
+
"stroke-width": Y.value.track,
|
|
986
|
+
fill: "none",
|
|
987
|
+
"stroke-dasharray": e.path.dashArray,
|
|
988
|
+
"stroke-dashoffset": e.path.dashOffset,
|
|
989
|
+
class: h({
|
|
990
|
+
"vue-ui-onion-path": !0,
|
|
991
|
+
"vue-ui-onion-blur": M.value.useBlurOnHover && ![null, void 0].includes(Q.value) && Q.value !== t,
|
|
992
|
+
"vue-data-ui-transition": S(N)
|
|
993
|
+
}),
|
|
994
|
+
"stroke-linecap": "round",
|
|
995
|
+
style: {
|
|
996
|
+
transform: "rotate(-90deg)",
|
|
997
|
+
transformOrigin: "50% 50%"
|
|
998
|
+
}
|
|
999
|
+
}, null, 10, Qe))), 256)),
|
|
1000
|
+
f("defs", null, [f("filter", {
|
|
1001
|
+
id: `blur_${E.value}`,
|
|
1002
|
+
x: "-50%",
|
|
1003
|
+
y: "-50%",
|
|
1004
|
+
width: "200%",
|
|
1005
|
+
height: "200%"
|
|
1006
|
+
}, [f("feGaussianBlur", {
|
|
1007
|
+
in: "SourceGraphic",
|
|
1008
|
+
stdDeviation: 100 / M.value.style.chart.gradientIntensity
|
|
1009
|
+
}, null, 8, et)], 8, $e)]),
|
|
1010
|
+
M.value.style.chart.useGradient ? (v(), d("g", {
|
|
1011
|
+
key: 1,
|
|
1012
|
+
filter: `url(#blur_${E.value})`
|
|
1013
|
+
}, [(v(!0), d(je, null, b(X.value, (e, t) => (v(), d("circle", {
|
|
1014
|
+
cx: G.value.centerX,
|
|
1015
|
+
cy: G.value.centerY,
|
|
1016
|
+
r: e.radius <= 0 ? 1e-4 : e.radius,
|
|
1017
|
+
stroke: "white",
|
|
1018
|
+
"stroke-width": Y.value.track / 3,
|
|
1019
|
+
fill: "none",
|
|
1020
|
+
"stroke-linecap": "round",
|
|
1021
|
+
"stroke-dasharray": e.path.dashArray,
|
|
1022
|
+
"stroke-dashoffset": e.path.dashOffset,
|
|
1023
|
+
style: {
|
|
1024
|
+
transform: "rotate(-90deg)",
|
|
1025
|
+
transformOrigin: "50% 50%"
|
|
1026
|
+
},
|
|
1027
|
+
class: h({ "vue-data-ui-transition": S(N) })
|
|
1028
|
+
}, null, 10, nt))), 256))], 8, tt)) : u("", !0),
|
|
1029
|
+
(v(!0), d(je, null, b(X.value, (e, t) => (v(), d("circle", {
|
|
1030
|
+
cx: G.value.centerX,
|
|
1031
|
+
cy: G.value.centerY,
|
|
1032
|
+
r: e.radius <= 0 ? 1e-4 : e.radius,
|
|
1033
|
+
stroke: "transparent",
|
|
1034
|
+
"stroke-width": Math.max(Y.value.track, Y.value.gutter),
|
|
1035
|
+
fill: "none",
|
|
1036
|
+
"stroke-dasharray": e.path.bgDashArray,
|
|
1037
|
+
"stroke-dashoffset": e.path.fullOffset,
|
|
1038
|
+
"stroke-linecap": "round",
|
|
1039
|
+
class: "vue-ui-onion-path",
|
|
1040
|
+
style: {
|
|
1041
|
+
transform: "rotate(-90deg)",
|
|
1042
|
+
transformOrigin: "50% 50%"
|
|
1043
|
+
},
|
|
1044
|
+
onMouseenter: (n) => An({
|
|
1045
|
+
datapoint: e,
|
|
1046
|
+
show: !0,
|
|
1047
|
+
seriesIndex: t,
|
|
1048
|
+
triggerMode: "pointer"
|
|
1049
|
+
}),
|
|
1050
|
+
onMouseleave: (t) => En({ datapoint: e }),
|
|
1051
|
+
onClick: (t) => Tn({ datapoint: e })
|
|
1052
|
+
}, null, 40, rt))), 256)),
|
|
1053
|
+
M.value.style.chart.layout.labels.show ? (v(), d("g", it, [(v(!0), d(je, null, b(X.value, (e, t) => (v(), d("g", {
|
|
1054
|
+
key: `dl_${e.id}`,
|
|
1055
|
+
onMouseenter: (n) => An({
|
|
1056
|
+
datapoint: e,
|
|
1057
|
+
show: !0,
|
|
1058
|
+
seriesIndex: t,
|
|
1059
|
+
triggerMode: "pointer"
|
|
1060
|
+
}),
|
|
1061
|
+
onMouseleave: (t) => En({ datapoint: e }),
|
|
1062
|
+
onClick: (t) => Tn({ datapoint: e })
|
|
1063
|
+
}, [O.value.includes(e.id) ? u("", !0) : (v(), d("text", {
|
|
1064
|
+
key: 0,
|
|
1065
|
+
class: h(["vue-ui-onion-label", { "vue-data-ui-transition": S(N) }]),
|
|
1066
|
+
transform: `translate(${R.value.width / 2 - Y.value.gutter * .8 + M.value.style.chart.layout.labels.offsetX},${e.labelY + M.value.style.chart.layout.labels.offsetY})`,
|
|
1067
|
+
"text-anchor": "end",
|
|
1068
|
+
"font-size": M.value.style.chart.layout.labels.fontSize,
|
|
1069
|
+
fill: M.value.useBlurOnHover && ![null, void 0].includes(Q.value) && Q.value === t ? e.color : M.value.style.chart.layout.labels.color,
|
|
1070
|
+
"font-weight": M.value.style.chart.layout.labels.bold ? "bold" : "normal"
|
|
1071
|
+
}, He(On(e, t)), 11, ot))], 40, at))), 128))])) : u("", !0),
|
|
1072
|
+
x(e.$slots, "svg", { svg: {
|
|
1073
|
+
...R.value,
|
|
1074
|
+
drawingArea: G.value,
|
|
1075
|
+
isPrintingImg: S(Kt) || S(qt) || S(Vn),
|
|
1076
|
+
isPrintingSvg: S(Hn)
|
|
1077
|
+
} }, void 0, !0)
|
|
1078
|
+
], 46, Ye)), e.$slots.hint ? (v(), d("div", st, [x(e.$slots, "hint", g(m({
|
|
1079
|
+
hint: M.value.a11y.translations.keyboardNavigation,
|
|
1080
|
+
isVisible: Rt.value
|
|
1081
|
+
})), void 0, !0)])) : u("", !0)]),
|
|
1082
|
+
e.$slots.watermark ? (v(), d("div", ct, [x(e.$slots, "watermark", g(m({ isPrinting: S(Kt) || S(qt) || S(Vn) || S(Hn) })), void 0, !0)])) : u("", !0),
|
|
1083
|
+
f("div", { id: `legend-bottom-${E.value}` }, null, 8, lt),
|
|
1084
|
+
Ft.value && (M.value.style.chart.legend.show || e.$slots.legend) ? (v(), l(Me, {
|
|
1085
|
+
key: 6,
|
|
1086
|
+
to: M.value.style.chart.legend.position === "top" ? `#legend-top-${E.value}` : `#legend-bottom-${E.value}`
|
|
1087
|
+
}, [f("div", {
|
|
1088
|
+
ref_key: "chartLegend",
|
|
1089
|
+
ref: Ot
|
|
1090
|
+
}, [x(e.$slots, "legend", { legend: q.value }, () => [M.value.style.chart.legend.show ? (v(), l(Oe, {
|
|
1091
|
+
key: `legend_${Nt.value}`,
|
|
1092
|
+
legendSet: q.value,
|
|
1093
|
+
config: fn.value,
|
|
1094
|
+
isCursorPointer: P.value,
|
|
1095
|
+
onClickMarker: t[0] ||= ({ legend: e }) => _n(e.id)
|
|
1096
|
+
}, {
|
|
1097
|
+
item: w(({ legend: e }) => [S(F) ? u("", !0) : (v(), d("div", {
|
|
1098
|
+
key: 0,
|
|
1099
|
+
"data-cy-legend-item": "",
|
|
1100
|
+
onClick: (t) => e.segregate(),
|
|
1101
|
+
style: _(`opacity:${O.value.includes(e.id) ? .5 : 1}`)
|
|
1102
|
+
}, He(e.display), 13, ut))]),
|
|
1103
|
+
legendToggle: w(() => [q.value.length > 2 && M.value.style.chart.legend.selectAllToggle.show && !S(F) ? (v(), l(Ce, {
|
|
1104
|
+
key: 0,
|
|
1105
|
+
backgroundColor: M.value.style.chart.legend.selectAllToggle.backgroundColor,
|
|
1106
|
+
color: M.value.style.chart.legend.selectAllToggle.color,
|
|
1107
|
+
fontSize: M.value.style.chart.legend.fontSize,
|
|
1108
|
+
checked: O.value.length > 0,
|
|
1109
|
+
isCursorPointer: P.value,
|
|
1110
|
+
onToggle: gn
|
|
1111
|
+
}, null, 8, [
|
|
1112
|
+
"backgroundColor",
|
|
1113
|
+
"color",
|
|
1114
|
+
"fontSize",
|
|
1115
|
+
"checked",
|
|
1116
|
+
"isCursorPointer"
|
|
1117
|
+
])) : u("", !0)]),
|
|
1118
|
+
_: 1
|
|
1119
|
+
}, 8, [
|
|
1120
|
+
"legendSet",
|
|
1121
|
+
"config",
|
|
1122
|
+
"isCursorPointer"
|
|
1123
|
+
])) : u("", !0)], !0)], 512)], 8, ["to"])) : u("", !0),
|
|
1124
|
+
e.$slots.source ? (v(), d("div", {
|
|
1125
|
+
key: 7,
|
|
1126
|
+
ref_key: "source",
|
|
1127
|
+
ref: kt,
|
|
1128
|
+
dir: "auto"
|
|
1129
|
+
}, [x(e.$slots, "source", {}, void 0, !0)], 512)) : u("", !0),
|
|
1130
|
+
Fe(S(ft), {
|
|
1131
|
+
teleportTo: M.value.style.chart.tooltip.teleportTo,
|
|
1132
|
+
show: L.value.showTooltip && D.value,
|
|
1133
|
+
backgroundColor: M.value.style.chart.tooltip.backgroundColor,
|
|
1134
|
+
color: M.value.style.chart.tooltip.color,
|
|
1135
|
+
borderRadius: M.value.style.chart.tooltip.borderRadius,
|
|
1136
|
+
borderColor: M.value.style.chart.tooltip.borderColor,
|
|
1137
|
+
borderWidth: M.value.style.chart.tooltip.borderWidth,
|
|
1138
|
+
fontSize: M.value.style.chart.tooltip.fontSize,
|
|
1139
|
+
backgroundOpacity: M.value.style.chart.tooltip.backgroundOpacity,
|
|
1140
|
+
position: M.value.style.chart.tooltip.position,
|
|
1141
|
+
offsetX: M.value.style.chart.tooltip.offsetX,
|
|
1142
|
+
offsetY: M.value.style.chart.tooltip.offsetY,
|
|
1143
|
+
parent: k.value,
|
|
1144
|
+
content: Et.value,
|
|
1145
|
+
isFullscreen: $.value,
|
|
1146
|
+
isCustom: S(se)(M.value.style.chart.tooltip.customFormat),
|
|
1147
|
+
smooth: M.value.style.chart.tooltip.smooth,
|
|
1148
|
+
backdropFilter: M.value.style.chart.tooltip.backdropFilter,
|
|
1149
|
+
smoothForce: M.value.style.chart.tooltip.smoothForce,
|
|
1150
|
+
smoothSnapThreshold: M.value.style.chart.tooltip.smoothSnapThreshold,
|
|
1151
|
+
isA11yMode: j.value === "keyboard",
|
|
1152
|
+
a11yPosition: Lt.value
|
|
1153
|
+
}, {
|
|
1154
|
+
"tooltip-before": w(() => [x(e.$slots, "tooltip-before", g(m({ ...kn.value })), void 0, !0)]),
|
|
1155
|
+
tooltip: w(() => [x(e.$slots, "tooltip", g(m({ ...kn.value })), void 0, !0)]),
|
|
1156
|
+
"tooltip-after": w(() => [x(e.$slots, "tooltip-after", g(m({ ...kn.value })), void 0, !0)]),
|
|
1157
|
+
_: 3
|
|
1158
|
+
}, 8, [
|
|
1159
|
+
"teleportTo",
|
|
1160
|
+
"show",
|
|
1161
|
+
"backgroundColor",
|
|
1162
|
+
"color",
|
|
1163
|
+
"borderRadius",
|
|
1164
|
+
"borderColor",
|
|
1165
|
+
"borderWidth",
|
|
1166
|
+
"fontSize",
|
|
1167
|
+
"backgroundOpacity",
|
|
1168
|
+
"position",
|
|
1169
|
+
"offsetX",
|
|
1170
|
+
"offsetY",
|
|
1171
|
+
"parent",
|
|
1172
|
+
"content",
|
|
1173
|
+
"isFullscreen",
|
|
1174
|
+
"isCustom",
|
|
1175
|
+
"smooth",
|
|
1176
|
+
"backdropFilter",
|
|
1177
|
+
"smoothForce",
|
|
1178
|
+
"smoothSnapThreshold",
|
|
1179
|
+
"isA11yMode",
|
|
1180
|
+
"a11yPosition"
|
|
1181
|
+
]),
|
|
1182
|
+
Ct.value && M.value.userOptions.buttons.table ? (v(), l(Be(In.value.component), Ie({ key: 8 }, In.value.props, {
|
|
1183
|
+
ref_key: "tableUnit",
|
|
1184
|
+
ref: It,
|
|
1185
|
+
onClose: t[3] ||= (e) => L.value.showTable = !1
|
|
1186
|
+
}), Ne({
|
|
1187
|
+
content: w(() => [(v(), l(S(ht), {
|
|
1188
|
+
key: `table_${Mt.value}`,
|
|
1189
|
+
colNames: Z.value.colNames,
|
|
1190
|
+
head: Z.value.head,
|
|
1191
|
+
body: Z.value.body,
|
|
1192
|
+
config: Z.value.config,
|
|
1193
|
+
title: M.value.table.useDialog ? "" : In.value.title,
|
|
1194
|
+
withCloseButton: !M.value.table.useDialog,
|
|
1195
|
+
isCursorPointer: P.value,
|
|
1196
|
+
onClose: t[2] ||= (e) => L.value.showTable = !1
|
|
1197
|
+
}, {
|
|
1198
|
+
th: w(({ th: e }) => [Pe(He(e), 1)]),
|
|
1199
|
+
td: w(({ td: e }) => [f("div", { innerHTML: e }, null, 8, dt)]),
|
|
1200
|
+
_: 1
|
|
1201
|
+
}, 8, [
|
|
1202
|
+
"colNames",
|
|
1203
|
+
"head",
|
|
1204
|
+
"body",
|
|
1205
|
+
"config",
|
|
1206
|
+
"title",
|
|
1207
|
+
"withCloseButton",
|
|
1208
|
+
"isCursorPointer"
|
|
1209
|
+
]))]),
|
|
1210
|
+
_: 2
|
|
1211
|
+
}, [M.value.table.useDialog ? {
|
|
1212
|
+
name: "title",
|
|
1213
|
+
fn: w(() => [Pe(He(In.value.title), 1)]),
|
|
1214
|
+
key: "0"
|
|
1215
|
+
} : void 0, M.value.table.useDialog ? {
|
|
1216
|
+
name: "actions",
|
|
1217
|
+
fn: w(() => [f("button", {
|
|
1218
|
+
tabindex: "0",
|
|
1219
|
+
class: "vue-ui-user-options-button",
|
|
1220
|
+
onClick: t[1] ||= (e) => Cn(M.value.userOptions.callbacks.csv),
|
|
1221
|
+
style: _({ cursor: P.value ? "pointer" : "default" })
|
|
1222
|
+
}, [Fe(S(pt), {
|
|
1223
|
+
name: "fileCsv",
|
|
1224
|
+
stroke: In.value.props.color
|
|
1225
|
+
}, null, 8, ["stroke"])], 4)]),
|
|
1226
|
+
key: "1"
|
|
1227
|
+
} : void 0]), 1040)) : u("", !0),
|
|
1228
|
+
x(e.$slots, "skeleton", {}, () => [S(F) ? (v(), l(pe, { key: 0 })) : u("", !0)], !0)
|
|
1229
|
+
], 46, Ge));
|
|
1230
|
+
}
|
|
1231
|
+
}, [["__scopeId", "data-v-e202bda3"]]);
|
|
1232
|
+
//#endregion
|
|
1233
|
+
export { We as n, ft as t };
|