vue-data-ui 2.17.0 → 2.17.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.
Files changed (93) hide show
  1. package/README.md +2 -1
  2. package/dist/{Arrow-BAEkZGzL.js → Arrow-Dr2lyXds.js} +1 -1
  3. package/dist/{BaseDraggableDialog-ChCkcmj_.js → BaseDraggableDialog-DQ6yA8di.js} +2 -2
  4. package/dist/{BaseIcon-naqtCxVi.js → BaseIcon-C2f-EcZc.js} +1 -1
  5. package/dist/{ColorPicker-CfIPgxcj.js → ColorPicker-D-JmDe31.js} +2 -2
  6. package/dist/{DataTable-D0VYDhfx.js → DataTable-6BxhjBzt.js} +2 -2
  7. package/dist/{Legend-Bxlv67uY.js → Legend-1R-B-7st.js} +11 -11
  8. package/dist/{NonSvgPenAndPaper-b_oVy-Dd.js → NonSvgPenAndPaper-CLNy5uCL.js} +3 -3
  9. package/dist/{PackageVersion-5TR4ocqp.js → PackageVersion-CIX1W_aa.js} +1 -1
  10. package/dist/{PenAndPaper-D6AqipIO.js → PenAndPaper-CqJ4wudB.js} +3 -3
  11. package/dist/{Shape-DtFT5EJa.js → Shape-DJKQgAbU.js} +1 -1
  12. package/dist/{Slicer-CL6-MRI6.js → Slicer-Dju6LE-h.js} +2 -2
  13. package/dist/{SparkTooltip-Bcv1aoA5.js → SparkTooltip-D2mROH3o.js} +1 -1
  14. package/dist/{Title-B-2bV0SW.js → Title-BQb7X_OR.js} +1 -1
  15. package/dist/{Tooltip-CoQnTnr-.js → Tooltip-BTnTpPdO.js} +1 -1
  16. package/dist/{UserOptions-Dd34lEKb.js → UserOptions-lneAyZKu.js} +2 -2
  17. package/dist/{dom-to-png-2AA0wHlX.js → dom-to-png-C-9BWdwN.js} +1 -1
  18. package/dist/{img-Y_hYz-ZC.js → img-D0DpKcFX.js} +1 -1
  19. package/dist/{index-pPGk-uhD.js → index-JzUbx__y.js} +22 -8
  20. package/dist/{pdf-yfk3d1is.js → pdf-BgVDfZPT.js} +1 -1
  21. package/dist/style.css +1 -1
  22. package/dist/types/vue-data-ui.d.cts +65 -160
  23. package/dist/types/vue-data-ui.d.ts +65 -160
  24. package/dist/{useNestedProp-DjACxgdZ.js → useNestedProp-D_jd2dz9.js} +1 -1
  25. package/dist/{usePrinter-DDHcrl0A.js → usePrinter-CsyliflB.js} +2 -2
  26. package/dist/{vue-data-ui-CIWxgKjd.js → vue-data-ui-BMv8hEcb.js} +99 -97
  27. package/dist/vue-data-ui.js +1 -1
  28. package/dist/{vue-ui-3d-bar-D5Wpdqfk.js → vue-ui-3d-bar-CrdssfKx.js} +41 -34
  29. package/dist/{vue-ui-accordion-CVnA550V.js → vue-ui-accordion-CcTUbiHq.js} +3 -3
  30. package/dist/{vue-ui-age-pyramid-BuAl-zC5.js → vue-ui-age-pyramid-ZYFAAcwc.js} +134 -127
  31. package/dist/{vue-ui-annotator-gl2A20m3.js → vue-ui-annotator-BEgBoRWQ.js} +2 -2
  32. package/dist/{vue-ui-bullet-D-VMKpwe.js → vue-ui-bullet-DYzLfkYB.js} +90 -83
  33. package/dist/{vue-ui-candlestick-1r6YwiUV.js → vue-ui-candlestick-Cdu2ozig.js} +101 -94
  34. package/dist/{vue-ui-carousel-table-B6UJoNtP.js → vue-ui-carousel-table-Dce2wfVw.js} +4 -4
  35. package/dist/{vue-ui-chestnut-DnlBYpC5.js → vue-ui-chestnut-CCMAbLrw.js} +270 -263
  36. package/dist/{vue-ui-chord-D3kpzYjp.js → vue-ui-chord-B8Sl_FwD.js} +60 -53
  37. package/dist/{vue-ui-circle-pack-CHgdpoYu.js → vue-ui-circle-pack-BX6_ToJl.js} +121 -114
  38. package/dist/{vue-ui-cursor-63EAvElT.js → vue-ui-cursor-CyaF0qp7.js} +2 -2
  39. package/dist/{vue-ui-dashboard-Da6CPET-.js → vue-ui-dashboard-BmL_vnj5.js} +62 -62
  40. package/dist/{vue-ui-digits-CA8pUKej.js → vue-ui-digits-BRKjd-LQ.js} +2 -2
  41. package/dist/vue-ui-donut-LZR-vpdS.js +1338 -0
  42. package/dist/{vue-ui-donut-evolution-qeBEA4W8.js → vue-ui-donut-evolution-dax3dN9r.js} +215 -211
  43. package/dist/{vue-ui-dumbbell-Bm0PvAKT.js → vue-ui-dumbbell-C7ZNBVSy.js} +117 -110
  44. package/dist/{vue-ui-flow-C2dqXvrU.js → vue-ui-flow-BeLwkeHo.js} +105 -98
  45. package/dist/{vue-ui-funnel-Dvy5rRld.js → vue-ui-funnel-BywaRLZR.js} +138 -131
  46. package/dist/{vue-ui-galaxy-Y8LYp5n2.js → vue-ui-galaxy-DYavEd4o.js} +150 -146
  47. package/dist/{vue-ui-gauge-BBo0jWAP.js → vue-ui-gauge-DwQRlRWp.js} +125 -118
  48. package/dist/{vue-ui-gizmo-DjXfTOWn.js → vue-ui-gizmo-CjRczit6.js} +3 -3
  49. package/dist/{vue-ui-heatmap-BbxRpltP.js → vue-ui-heatmap-cRy0tcES.js} +155 -148
  50. package/dist/{vue-ui-history-plot-ChYf3Nvc.js → vue-ui-history-plot-D8aTdU23.js} +141 -134
  51. package/dist/{vue-ui-kpi-Vfc5-JnE.js → vue-ui-kpi-B10h_Hbt.js} +3 -3
  52. package/dist/{vue-ui-mini-loader-C0-Nsz8K.js → vue-ui-mini-loader-DNhr_0fr.js} +2 -2
  53. package/dist/{vue-ui-molecule-B7Yu7vzF.js → vue-ui-molecule-4MeyWn0c.js} +141 -134
  54. package/dist/{vue-ui-mood-radar-C8JUTwNw.js → vue-ui-mood-radar-DJmgRVT2.js} +126 -119
  55. package/dist/vue-ui-nested-donuts-CgaPLxV2.js +1177 -0
  56. package/dist/{vue-ui-onion-D4U7TL_N.js → vue-ui-onion-swDxtTT3.js} +88 -81
  57. package/dist/{vue-ui-parallel-coordinate-plot-CXMT7Rjr.js → vue-ui-parallel-coordinate-plot-DayzzOmK.js} +123 -116
  58. package/dist/{vue-ui-quadrant-B13pTVVZ.js → vue-ui-quadrant-CLf81ioF.js} +151 -144
  59. package/dist/{vue-ui-quick-chart-C0UL4o63.js → vue-ui-quick-chart-smKrpIwq.js} +39 -32
  60. package/dist/{vue-ui-radar-XpdiXnhz.js → vue-ui-radar-D8CIvG2q.js} +58 -51
  61. package/dist/{vue-ui-rating-CM8ZrUb1.js → vue-ui-rating-YZivkWBI.js} +2 -2
  62. package/dist/{vue-ui-relation-circle-CYoFNekk.js → vue-ui-relation-circle-DsEYbNs_.js} +127 -120
  63. package/dist/{vue-ui-ridgeline-QUquE6ck.js → vue-ui-ridgeline-Do6C5lMY.js} +98 -91
  64. package/dist/{vue-ui-rings-DwT0IfOh.js → vue-ui-rings-CMryJR1g.js} +208 -204
  65. package/dist/{vue-ui-scatter-zDpy1udm.js → vue-ui-scatter-BtLKWQbX.js} +172 -165
  66. package/dist/{vue-ui-skeleton-DJPjyNYn.js → vue-ui-skeleton-B4KQLEQy.js} +3 -3
  67. package/dist/{vue-ui-smiley-DoDXl6k0.js → vue-ui-smiley-CZBuA-1x.js} +2 -2
  68. package/dist/{vue-ui-spark-trend-CniV6Cpr.js → vue-ui-spark-trend-CdgyexDu.js} +3 -3
  69. package/dist/{vue-ui-sparkbar-Ds2ITgwn.js → vue-ui-sparkbar-DuZulYgD.js} +3 -3
  70. package/dist/{vue-ui-sparkgauge-CosfK-kw.js → vue-ui-sparkgauge-Di0FmUXs.js} +3 -3
  71. package/dist/{vue-ui-sparkhistogram-C7O1wPAJ.js → vue-ui-sparkhistogram-CHNHz9Gm.js} +4 -4
  72. package/dist/{vue-ui-sparkline-B_iUj3F2.js → vue-ui-sparkline-TaWMi8gF.js} +3 -3
  73. package/dist/{vue-ui-sparkstackbar-DBhWrysr.js → vue-ui-sparkstackbar-Bv2HEegT.js} +3 -3
  74. package/dist/{vue-ui-stackbar-C3aV4IcL.js → vue-ui-stackbar-Bk3Bbzjk.js} +61 -54
  75. package/dist/{vue-ui-strip-plot-Bvr1GAzH.js → vue-ui-strip-plot-BNMDY4GI.js} +116 -109
  76. package/dist/{vue-ui-table-DQKKRgyo.js → vue-ui-table-JG0B8HuS.js} +3 -3
  77. package/dist/{vue-ui-table-heatmap-Dyqj5XJC.js → vue-ui-table-heatmap-CCdWeNZj.js} +5 -5
  78. package/dist/{vue-ui-table-sparkline-D4RubyLj.js → vue-ui-table-sparkline-C1u_b0RG.js} +4 -4
  79. package/dist/{vue-ui-thermometer-B0FKI5cG.js → vue-ui-thermometer-DkldIXw7.js} +88 -81
  80. package/dist/{vue-ui-timer-DUCBRIl-.js → vue-ui-timer-0KDTN-Gt.js} +5 -5
  81. package/dist/{vue-ui-tiremarks-CRt4UQZD.js → vue-ui-tiremarks-FPtGzTGi.js} +127 -120
  82. package/dist/vue-ui-treemap-BA5wC5Bs.js +965 -0
  83. package/dist/{vue-ui-vertical-bar-C5fPYltO.js → vue-ui-vertical-bar-DUJWYMRn.js} +233 -226
  84. package/dist/{vue-ui-waffle-BpWLlfpg.js → vue-ui-waffle-BIngg99N.js} +183 -179
  85. package/dist/{vue-ui-wheel-CTzuCroy.js → vue-ui-wheel-l5U2UH9c.js} +121 -114
  86. package/dist/{vue-ui-word-cloud-BPokdaP1.js → vue-ui-word-cloud-CTKuxhFY.js} +152 -145
  87. package/dist/{vue-ui-world-CS6k-oil.js → vue-ui-world-Dx5O9Is5.js} +77 -70
  88. package/dist/{vue-ui-xy-CQ425kLR.js → vue-ui-xy-JjA1CMAo.js} +229 -222
  89. package/dist/{vue-ui-xy-canvas-D2IFwAr7.js → vue-ui-xy-canvas-CH82b2Lp.js} +154 -147
  90. package/package.json +1 -1
  91. package/dist/vue-ui-donut-CKa7nFjt.js +0 -1324
  92. package/dist/vue-ui-nested-donuts-D0RgFifU.js +0 -1163
  93. package/dist/vue-ui-treemap-CWP5nYDx.js +0 -961
@@ -1,18 +1,18 @@
1
- import { defineAsyncComponent as O, computed as h, ref as u, watch as xe, shallowRef as Te, onMounted as et, onBeforeUnmount as tt, createElementBlock as i, openBlock as s, unref as r, normalizeStyle as X, normalizeClass as E, createBlock as P, createCommentVNode as g, createElementVNode as S, createVNode as Oe, createSlots as at, withCtx as f, renderSlot as v, normalizeProps as F, guardReactiveProps as M, Fragment as D, renderList as L, toDisplayString as R, createTextVNode as lt, nextTick as ot } from "vue";
2
- import { u as nt, c as st, t as rt, p as Pe, a as ut, b as it, o as ct, e as Z, d as vt, X as dt, f as V, i as ee, x as _e, q as ht, r as ft, y as gt } from "./index-pPGk-uhD.js";
1
+ import { defineAsyncComponent as O, computed as h, ref as u, watch as xe, shallowRef as Te, onMounted as et, onBeforeUnmount as tt, createElementBlock as i, openBlock as s, unref as r, normalizeStyle as X, normalizeClass as E, createBlock as P, createCommentVNode as p, createElementVNode as S, createVNode as Oe, createSlots as at, withCtx as f, renderSlot as v, normalizeProps as F, guardReactiveProps as M, Fragment as D, renderList as L, toDisplayString as R, createTextVNode as lt, nextTick as ot } from "vue";
2
+ import { u as nt, c as st, t as rt, p as Pe, a as ut, b as it, o as ct, e as Z, d as vt, X as dt, f as V, i as ee, x as _e, q as ht, r as ft, y as gt } from "./index-JzUbx__y.js";
3
3
  import { t as pt, u as yt } from "./useResponsive-DfdjqQps.js";
4
- import { u as Ie } from "./useNestedProp-DjACxgdZ.js";
5
- import { u as mt } from "./usePrinter-DDHcrl0A.js";
4
+ import { u as Ie } from "./useNestedProp-D_jd2dz9.js";
5
+ import { u as mt } from "./usePrinter-CsyliflB.js";
6
6
  import { u as bt } from "./useUserOptionState-BIvW1Kz7.js";
7
7
  import { u as kt } from "./useChartAccessibility-9icAAmYg.js";
8
- import wt from "./Title-B-2bV0SW.js";
9
- import $t from "./Legend-Bxlv67uY.js";
10
- import Ct from "./img-Y_hYz-ZC.js";
8
+ import wt from "./Title-BQb7X_OR.js";
9
+ import $t from "./Legend-1R-B-7st.js";
10
+ import Ct from "./img-D0DpKcFX.js";
11
11
  import { _ as xt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
12
12
  const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["cx", "cy", "r", "stroke", "stroke-width", "stroke-dasharray", "stroke-dashoffset"], It = ["cx", "cy", "r", "stroke", "stroke-width", "stroke-dasharray", "stroke-dashoffset"], At = ["id"], St = ["stdDeviation"], Ft = ["filter"], Mt = ["cx", "cy", "r", "stroke-width", "stroke-dasharray", "stroke-dashoffset"], Rt = ["cx", "cy", "r", "stroke-width", "stroke-dasharray", "stroke-dashoffset", "onMouseenter"], Nt = { key: 2 }, Dt = ["onMouseenter"], Lt = ["x", "y", "font-size", "fill", "font-weight"], Vt = {
13
13
  key: 5,
14
14
  class: "vue-data-ui-watermark"
15
- }, zt = ["onClick"], Yt = ["innerHTML"], Bt = {
15
+ }, zt = ["onClick"], Bt = ["innerHTML"], Yt = {
16
16
  __name: "vue-ui-onion",
17
17
  props: {
18
18
  config: {
@@ -30,24 +30,24 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
30
30
  },
31
31
  emits: ["selectLegend"],
32
32
  setup(Ae, { expose: Se, emit: Fe }) {
33
- const Me = O(() => import("./vue-ui-accordion-CVnA550V.js")), Re = O(() => import("./DataTable-D0VYDhfx.js")), Ne = O(() => import("./PackageVersion-5TR4ocqp.js")), De = O(() => import("./PenAndPaper-D6AqipIO.js")), Le = O(() => import("./vue-ui-skeleton-DJPjyNYn.js")), Ve = O(() => import("./Tooltip-CoQnTnr-.js")), ze = O(() => import("./UserOptions-Dd34lEKb.js")), { vue_ui_onion: Ye } = nt(), w = Ae, z = h(() => !!w.dataset && w.dataset.length), _ = u(st()), Be = u(null), te = u(0), Y = u(!1), G = u(""), y = u([]), x = u(null), ae = u(null), le = u(null), oe = u(null), ne = u(null), se = u(0), re = u(0), ue = u(0), e = h({
33
+ const Me = O(() => import("./vue-ui-accordion-CcTUbiHq.js")), Re = O(() => import("./DataTable-6BxhjBzt.js")), Ne = O(() => import("./PackageVersion-CIX1W_aa.js")), De = O(() => import("./PenAndPaper-CqJ4wudB.js")), Le = O(() => import("./vue-ui-skeleton-B4KQLEQy.js")), Ve = O(() => import("./Tooltip-BTnTpPdO.js")), ze = O(() => import("./UserOptions-lneAyZKu.js")), { vue_ui_onion: Be } = nt(), $ = Ae, z = h(() => !!$.dataset && $.dataset.length), _ = u(st()), Ye = u(null), te = u(0), B = u(!1), G = u(""), y = u([]), C = u(null), ae = u(null), le = u(null), oe = u(null), ne = u(null), se = u(0), re = u(0), ue = u(0), e = h({
34
34
  get: () => de(),
35
35
  set: (t) => t
36
36
  }), { userOptionsVisible: H, setUserOptionsVisibility: ie, keepUserOptionState: ce } = bt({ config: e.value }), { svgRef: ve } = kt({ config: e.value.style.chart.title });
37
37
  function de() {
38
38
  const t = Ie({
39
- userConfig: w.config,
40
- defaultConfig: Ye
39
+ userConfig: $.config,
40
+ defaultConfig: Be
41
41
  });
42
42
  return t.theme ? {
43
43
  ...Ie({
44
- userConfig: ut.vue_ui_onion[t.theme] || w.config,
44
+ userConfig: ut.vue_ui_onion[t.theme] || $.config,
45
45
  defaultConfig: t
46
46
  }),
47
47
  customPalette: rt[t.theme] || Pe
48
48
  } : t;
49
49
  }
50
- xe(() => w.config, (t) => {
50
+ xe(() => $.config, (t) => {
51
51
  e.value = de(), H.value = !e.value.userOptions.showOnChartHover, ye(), se.value += 1, re.value += 1, ue.value += 1, m.value.showTable = e.value.table.show, m.value.showTooltip = e.value.style.chart.tooltip.show;
52
52
  }, { deep: !0 });
53
53
  const { isPrinting: he, isImaging: fe, generatePdf: ge, generateImage: pe } = mt({
@@ -67,18 +67,18 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
67
67
  bottom: 64
68
68
  },
69
69
  minRadius: 64
70
- }), $ = Te(null), I = Te(null);
70
+ }), x = Te(null), I = Te(null);
71
71
  et(() => {
72
72
  ye();
73
73
  });
74
74
  function ye() {
75
- if (ct(w.dataset) && Z({
75
+ if (ct($.dataset) && Z({
76
76
  componentName: "VueUiOnion",
77
77
  type: "dataset"
78
78
  }), e.value.responsive) {
79
79
  const o = pt(() => {
80
80
  const { width: a, height: l } = yt({
81
- chart: x.value,
81
+ chart: C.value,
82
82
  title: e.value.style.chart.title.text ? ae.value : null,
83
83
  legend: e.value.style.chart.legend.show ? le.value : null,
84
84
  source: oe.value,
@@ -88,11 +88,11 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
88
88
  n.value.width = a, n.value.height = l, n.value.padding.top = Math.max(a, l) * 0.125, n.value.padding.right = Math.max(a, l) * 0.125, n.value.padding.bottom = Math.max(a, l) * 0.125, n.value.padding.left = Math.max(a, l) * 0.125, n.value.minRadius = Math.min(a, l) * 0.125;
89
89
  });
90
90
  });
91
- $.value && (I.value && $.value.unobserve(I.value), $.value.disconnect()), $.value = new ResizeObserver(o), I.value = x.value.parentNode, $.value.observe(I.value);
91
+ x.value && (I.value && x.value.unobserve(I.value), x.value.disconnect()), x.value = new ResizeObserver(o), I.value = C.value.parentNode, x.value.observe(I.value);
92
92
  }
93
93
  }
94
94
  tt(() => {
95
- $.value && (I.value && $.value.unobserve(I.value), $.value.disconnect());
95
+ x.value && (I.value && x.value.unobserve(I.value), x.value.disconnect());
96
96
  });
97
97
  const c = h(() => ({
98
98
  top: n.value.padding.top,
@@ -105,7 +105,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
105
105
  height: n.value.height - n.value.padding.bottom - n.value.padding.top,
106
106
  minRadius: n.value.minRadius,
107
107
  maxRadius: Math.min(n.value.width, n.value.height) - n.value.padding.top * 2
108
- })), d = h(() => (w.dataset.forEach((t, o) => {
108
+ })), d = h(() => ($.dataset.forEach((t, o) => {
109
109
  [null, void 0].includes(t.name) && Z({
110
110
  componentName: "VueUiOnion",
111
111
  type: "datasetSerieAttribute",
@@ -117,7 +117,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
117
117
  property: "percentage",
118
118
  index: o
119
119
  });
120
- }), w.dataset.map((t, o) => {
120
+ }), $.dataset.map((t, o) => {
121
121
  const a = `onion_serie_${o}_${_.value}`;
122
122
  return {
123
123
  ...t,
@@ -163,7 +163,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
163
163
  gutter: (t > e.value.style.chart.layout.maxThickness ? e.value.style.chart.layout.maxThickness : t) * e.value.style.chart.layout.gutter.width,
164
164
  track: (t > e.value.style.chart.layout.maxThickness ? e.value.style.chart.layout.maxThickness : t) * e.value.style.chart.layout.track.width
165
165
  };
166
- }), b = h(() => N.value.filter((t) => !y.value.includes(t.id)).map((t, o) => {
166
+ }), k = h(() => N.value.filter((t) => !y.value.includes(t.id)).map((t, o) => {
167
167
  const a = (c.value.maxRadius - T.value.track) / qe.value / 2 * (1 + o), l = c.value.centerY - a;
168
168
  return {
169
169
  percentage: t.percentage || 0,
@@ -174,12 +174,12 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
174
174
  };
175
175
  }));
176
176
  function Je(t, o) {
177
- const a = 2 * Math.PI * t, l = a * 0.75, p = `${l} ${a}`, C = l * (1 - o / 100);
177
+ const a = 2 * Math.PI * t, l = a * 0.75, g = `${l} ${a}`, b = l * (1 - o / 100);
178
178
  return {
179
179
  bgDashArray: `${l} ${a}`,
180
180
  bgDashOffset: 0,
181
- dashArray: p,
182
- dashOffset: C,
181
+ dashArray: g,
182
+ dashOffset: b,
183
183
  fullOffset: 0,
184
184
  active: `
185
185
  M ${c.value.centerX},${c.value.centerY - t}
@@ -190,20 +190,20 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
190
190
  }
191
191
  const Ke = Fe;
192
192
  function me(t) {
193
- y.value.includes(t) ? y.value = y.value.filter((o) => o !== t) : y.value.push(t), Ke("selectLegend", b.value);
193
+ y.value.includes(t) ? y.value = y.value.filter((o) => o !== t) : y.value.push(t), Ke("selectLegend", k.value);
194
194
  }
195
195
  function Qe() {
196
- return b.value;
196
+ return k.value;
197
197
  }
198
198
  const j = h(() => {
199
- const t = [e.value.table.translations.serie, e.value.table.translations.percentage, e.value.table.translations.value], o = b.value.map((a) => [
199
+ const t = [e.value.table.translations.serie, e.value.table.translations.percentage, e.value.table.translations.value], o = k.value.map((a) => [
200
200
  a.name,
201
201
  a.percentage,
202
202
  a.value
203
203
  ]);
204
204
  return { head: t, body: o };
205
- }), B = h(() => {
206
- const t = j.value.head, o = b.value.map((l) => [
205
+ }), Y = h(() => {
206
+ const t = j.value.head, o = k.value.map((l) => [
207
207
  `<span style="color:${l.color}">⬤</span> ${l.name}`,
208
208
  `${Number(l.percentage ?? 0).toFixed(e.value.table.td.roundingPercentage).toLocaleString()}%`,
209
209
  `${l.prefix || ""}${[null, void 0, NaN, "NaN"].includes(l.value) ? "-" : l.value.toFixed(e.value.table.td.roundingValue).toLocaleString()}${l.suffix || ""}`
@@ -224,32 +224,32 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
224
224
  });
225
225
  function be(t = null) {
226
226
  ot(() => {
227
- const o = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [""]], a = j.value.head, l = j.value.body, p = o.concat([a]).concat(l), C = ht(p);
228
- t ? t(C) : ft({ csvContent: C, title: e.value.style.chart.title.text || "vue-ui-onion" });
227
+ const o = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [""]], a = j.value.head, l = j.value.body, g = o.concat([a]).concat(l), b = ht(g);
228
+ t ? t(b) : ft({ csvContent: b, title: e.value.style.chart.title.text || "vue-ui-onion" });
229
229
  });
230
230
  }
231
- const k = u(void 0), A = u(!1);
231
+ const w = u(void 0), A = u(!1);
232
232
  function ke(t) {
233
233
  A.value = t, te.value += 1;
234
234
  }
235
235
  const q = u(null);
236
236
  function we({ datapoint: t, seriesIndex: o, show: a = !0 }) {
237
237
  const l = t.absoluteIndex;
238
- k.value = o, q.value = {
238
+ w.value = o, q.value = {
239
239
  datapoint: t,
240
240
  seriesIndex: l,
241
241
  series: d.value,
242
242
  config: e.value
243
- }, Y.value = a;
244
- let p = "";
245
- const C = e.value.style.chart.tooltip.customFormat;
246
- if (_e(C) && gt(() => C({
243
+ }, B.value = a;
244
+ let g = "";
245
+ const b = e.value.style.chart.tooltip.customFormat;
246
+ if (_e(b) && gt(() => b({
247
247
  seriesIndex: l,
248
248
  datapoint: t,
249
249
  series: d.value,
250
250
  config: e.value
251
251
  })))
252
- G.value = C({
252
+ G.value = b({
253
253
  seriesIndex: l,
254
254
  datapoint: t,
255
255
  series: d.value,
@@ -257,7 +257,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
257
257
  });
258
258
  else {
259
259
  const K = e.value.style.chart.tooltip.showPercentage, Q = e.value.style.chart.tooltip.showValue;
260
- p += `<div style="width: 100%; border-bottom: 1px solid ${e.value.style.chart.tooltip.borderColor}; padding-bottom: 6px;margin-bottom:3px;display:flex;flex-direction:row;gap:3px;align-items:center"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${t.color}"/></svg><span></span>${t.name}</span></div>`, p += `<div style="width:100%;text-align:left;"><b>${K ? V({ p: "", v: t.percentage, s: "%", r: e.value.style.chart.tooltip.roundingPercentage }) : ""}</b> ${K && Q ? "(" : ""}${Q ? ee(
260
+ g += `<div style="width: 100%; border-bottom: 1px solid ${e.value.style.chart.tooltip.borderColor}; padding-bottom: 6px;margin-bottom:3px;display:flex;flex-direction:row;gap:3px;align-items:center"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${t.color}"/></svg><span></span>${t.name}</span></div>`, g += `<div style="width:100%;text-align:left;"><b>${K ? V({ p: "", v: t.percentage, s: "%", r: e.value.style.chart.tooltip.roundingPercentage }) : ""}</b> ${K && Q ? "(" : ""}${Q ? ee(
261
261
  e.value.style.chart.layout.labels.value.formatter,
262
262
  t.value,
263
263
  V({
@@ -267,7 +267,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
267
267
  r: e.value.style.chart.tooltip.roundingValue
268
268
  }),
269
269
  { datapoint: t, seriesIndex: o }
270
- ) : ""}${K && Q ? ")" : ""}</div>`, G.value = `<div>${p}</div>`;
270
+ ) : ""}${K && Q ? ")" : ""}</div>`, G.value = `<div>${g}</div>`;
271
271
  }
272
272
  }
273
273
  function $e() {
@@ -281,9 +281,16 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
281
281
  U.value = !U.value;
282
282
  }
283
283
  async function Ze({ scale: t = 2 } = {}) {
284
- if (!x.value) return;
285
- const { imageUri: o, base64: a } = await Ct({ domElement: x.value, base64: !0, img: !0, scale: t });
286
- return { imageUri: o, base64: a };
284
+ if (!C.value) return;
285
+ const { width: o, height: a } = C.value.getBoundingClientRect(), l = o / a, { imageUri: g, base64: b } = await Ct({ domElement: C.value, base64: !0, img: !0, scale: t });
286
+ return {
287
+ imageUri: g,
288
+ base64: b,
289
+ title: e.value.style.chart.title.text,
290
+ width: o,
291
+ height: a,
292
+ aspectRatio: l
293
+ };
287
294
  }
288
295
  return Se({
289
296
  getData: Qe,
@@ -298,7 +305,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
298
305
  }), (t, o) => (s(), i("div", {
299
306
  class: E(`vue-ui-onion ${A.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
300
307
  ref_key: "onionChart",
301
- ref: x,
308
+ ref: C,
302
309
  id: `vue-ui-onion_${_.value}`,
303
310
  style: X(`font-family:${e.value.style.fontFamily};width:100%; ${e.value.responsive ? "height: 100%;" : ""} text-align:center;background:${e.value.style.chart.backgroundColor}`),
304
311
  onMouseenter: o[4] || (o[4] = () => r(ie)(!0)),
@@ -311,14 +318,14 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
311
318
  color: e.value.style.chart.color,
312
319
  active: U.value,
313
320
  onClose: J
314
- }, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : g("", !0),
321
+ }, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : p("", !0),
315
322
  Ue.value ? (s(), i("div", {
316
323
  key: 1,
317
324
  ref_key: "noTitle",
318
325
  ref: ne,
319
326
  class: "vue-data-ui-no-title-space",
320
327
  style: "height:36px; width: 100%;background:transparent"
321
- }, null, 512)) : g("", !0),
328
+ }, null, 512)) : p("", !0),
322
329
  e.value.style.chart.title.text ? (s(), i("div", {
323
330
  key: 2,
324
331
  ref_key: "chartTitle",
@@ -338,10 +345,10 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
338
345
  }
339
346
  }
340
347
  }, null, 8, ["config"]))
341
- ], 512)) : g("", !0),
348
+ ], 512)) : p("", !0),
342
349
  e.value.userOptions.show && z.value && (r(ce) || r(H)) ? (s(), P(r(ze), {
343
350
  ref_key: "details",
344
- ref: Be,
351
+ ref: Ye,
345
352
  key: `user_options${te.value}`,
346
353
  backgroundColor: e.value.style.chart.backgroundColor,
347
354
  color: e.value.style.chart.color,
@@ -357,7 +364,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
357
364
  isFullscreen: A.value,
358
365
  isTooltip: m.value.showTooltip,
359
366
  titles: { ...e.value.userOptions.buttonTitles },
360
- chartElement: x.value,
367
+ chartElement: C.value,
361
368
  position: e.value.userOptions.position,
362
369
  hasAnnotator: e.value.userOptions.buttons.annotator,
363
370
  isAnnotation: U.value,
@@ -430,7 +437,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
430
437
  ]),
431
438
  key: "7"
432
439
  } : void 0
433
- ]), 1032, ["backgroundColor", "color", "isImaging", "isPrinting", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : g("", !0),
440
+ ]), 1032, ["backgroundColor", "color", "isImaging", "isPrinting", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : p("", !0),
434
441
  z.value ? (s(), i("svg", {
435
442
  key: 4,
436
443
  ref_key: "svgRef",
@@ -452,8 +459,8 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
452
459
  }
453
460
  }, [
454
461
  v(t.$slots, "chart-background", {}, void 0, !0)
455
- ], 8, Pt)) : g("", !0),
456
- (s(!0), i(D, null, L(b.value, (a, l) => (s(), i("circle", {
462
+ ], 8, Pt)) : p("", !0),
463
+ (s(!0), i(D, null, L(k.value, (a, l) => (s(), i("circle", {
457
464
  cx: c.value.centerX,
458
465
  cy: c.value.centerY,
459
466
  r: a.radius <= 0 ? 1e-4 : a.radius,
@@ -463,10 +470,10 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
463
470
  "stroke-dasharray": a.path.bgDashArray,
464
471
  "stroke-dashoffset": a.path.fullOffset,
465
472
  "stroke-linecap": "round",
466
- class: E({ "vue-ui-onion-path": !0, "vue-ui-onion-blur": e.value.useBlurOnHover && ![null, void 0].includes(k.value) && k.value !== l }),
473
+ class: E({ "vue-ui-onion-path": !0, "vue-ui-onion-blur": e.value.useBlurOnHover && ![null, void 0].includes(w.value) && w.value !== l }),
467
474
  style: { transform: "rotate(-90deg)", "transform-origin": "50% 50%" }
468
475
  }, null, 10, _t))), 256)),
469
- (s(!0), i(D, null, L(b.value, (a, l) => (s(), i("circle", {
476
+ (s(!0), i(D, null, L(k.value, (a, l) => (s(), i("circle", {
470
477
  cx: c.value.centerX,
471
478
  cy: c.value.centerY,
472
479
  r: a.radius < 0 ? 1e-4 : a.radius,
@@ -475,7 +482,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
475
482
  fill: "none",
476
483
  "stroke-dasharray": a.path.dashArray,
477
484
  "stroke-dashoffset": a.path.dashOffset,
478
- class: E({ "vue-ui-onion-path": !0, "vue-ui-onion-blur": e.value.useBlurOnHover && ![null, void 0].includes(k.value) && k.value !== l }),
485
+ class: E({ "vue-ui-onion-path": !0, "vue-ui-onion-blur": e.value.useBlurOnHover && ![null, void 0].includes(w.value) && w.value !== l }),
479
486
  "stroke-linecap": "round",
480
487
  style: { transform: "rotate(-90deg)", "transform-origin": "50% 50%" }
481
488
  }, null, 10, It))), 256)),
@@ -497,7 +504,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
497
504
  key: 1,
498
505
  filter: `url(#blur_${_.value})`
499
506
  }, [
500
- (s(!0), i(D, null, L(b.value, (a, l) => (s(), i("circle", {
507
+ (s(!0), i(D, null, L(k.value, (a, l) => (s(), i("circle", {
501
508
  cx: c.value.centerX,
502
509
  cy: c.value.centerY,
503
510
  r: a.radius <= 0 ? 1e-4 : a.radius,
@@ -509,8 +516,8 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
509
516
  "stroke-dashoffset": a.path.dashOffset,
510
517
  style: { transform: "rotate(-90deg)", "transform-origin": "50% 50%" }
511
518
  }, null, 8, Mt))), 256))
512
- ], 8, Ft)) : g("", !0),
513
- (s(!0), i(D, null, L(b.value, (a, l) => (s(), i("circle", {
519
+ ], 8, Ft)) : p("", !0),
520
+ (s(!0), i(D, null, L(k.value, (a, l) => (s(), i("circle", {
514
521
  cx: c.value.centerX,
515
522
  cy: c.value.centerY,
516
523
  r: a.radius <= 0 ? 1e-4 : a.radius,
@@ -522,33 +529,33 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
522
529
  "stroke-linecap": "round",
523
530
  class: "vue-ui-onion-path",
524
531
  style: { transform: "rotate(-90deg)", "transform-origin": "50% 50%" },
525
- onMouseenter: (p) => we({
532
+ onMouseenter: (g) => we({
526
533
  datapoint: a,
527
534
  show: !0,
528
535
  seriesIndex: l
529
536
  }),
530
- onMouseleave: o[0] || (o[0] = (p) => {
531
- k.value = void 0, Y.value = !1;
537
+ onMouseleave: o[0] || (o[0] = (g) => {
538
+ w.value = void 0, B.value = !1;
532
539
  })
533
540
  }, null, 40, Rt))), 256)),
534
541
  e.value.style.chart.layout.labels.show ? (s(), i("g", Nt, [
535
- (s(!0), i(D, null, L(b.value, (a, l) => (s(), i("g", {
536
- onMouseenter: (p) => we({
542
+ (s(!0), i(D, null, L(k.value, (a, l) => (s(), i("g", {
543
+ onMouseenter: (g) => we({
537
544
  datapoint: a,
538
545
  show: !0,
539
546
  seriesIndex: l
540
547
  }),
541
- onMouseleave: o[1] || (o[1] = (p) => {
542
- k.value = void 0, Y.value = !1;
548
+ onMouseleave: o[1] || (o[1] = (g) => {
549
+ w.value = void 0, B.value = !1;
543
550
  })
544
551
  }, [
545
- y.value.includes(a.id) ? g("", !0) : (s(), i("text", {
552
+ y.value.includes(a.id) ? p("", !0) : (s(), i("text", {
546
553
  key: 0,
547
554
  x: n.value.width / 2 - T.value.gutter * 0.8 + e.value.style.chart.layout.labels.offsetX,
548
555
  y: a.labelY + e.value.style.chart.layout.labels.offsetY,
549
556
  "text-anchor": "end",
550
557
  "font-size": e.value.style.chart.layout.labels.fontSize,
551
- fill: e.value.useBlurOnHover && ![null, void 0].includes(k.value) && k.value === l ? a.color : e.value.style.chart.layout.labels.color,
558
+ fill: e.value.useBlurOnHover && ![null, void 0].includes(w.value) && w.value === l ? a.color : e.value.style.chart.layout.labels.color,
552
559
  "font-weight": e.value.style.chart.layout.labels.bold ? "bold" : "normal"
553
560
  }, R(a.name ? a.name + ": " : "") + " " + R(e.value.style.chart.layout.labels.percentage.show ? r(V)({
554
561
  v: a.percentage,
@@ -576,13 +583,13 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
576
583
  { datapoint: a, seriesIndex: l }
577
584
  )})` : ""}`), 9, Lt))
578
585
  ], 40, Dt))), 256))
579
- ])) : g("", !0),
586
+ ])) : p("", !0),
580
587
  v(t.$slots, "svg", { svg: n.value }, void 0, !0)
581
- ], 14, Ot)) : g("", !0),
588
+ ], 14, Ot)) : p("", !0),
582
589
  t.$slots.watermark ? (s(), i("div", Vt, [
583
590
  v(t.$slots, "watermark", F(M({ isPrinting: r(he) || r(fe) })), void 0, !0)
584
- ])) : g("", !0),
585
- z.value ? g("", !0) : (s(), P(r(Le), {
591
+ ])) : p("", !0),
592
+ z.value ? p("", !0) : (s(), P(r(Le), {
586
593
  key: 6,
587
594
  config: {
588
595
  type: "onion",
@@ -624,9 +631,9 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
624
631
  dir: "auto"
625
632
  }, [
626
633
  v(t.$slots, "source", {}, void 0, !0)
627
- ], 512)) : g("", !0),
634
+ ], 512)) : p("", !0),
628
635
  Oe(r(Ve), {
629
- show: m.value.showTooltip && Y.value,
636
+ show: m.value.showTooltip && B.value,
630
637
  backgroundColor: e.value.style.chart.tooltip.backgroundColor,
631
638
  color: e.value.style.chart.tooltip.color,
632
639
  borderRadius: e.value.style.chart.tooltip.borderRadius,
@@ -636,7 +643,7 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
636
643
  backgroundOpacity: e.value.style.chart.tooltip.backgroundOpacity,
637
644
  position: e.value.style.chart.tooltip.position,
638
645
  offsetY: e.value.style.chart.tooltip.offsetY,
639
- parent: x.value,
646
+ parent: C.value,
640
647
  content: G.value,
641
648
  isFullscreen: A.value,
642
649
  isCustom: r(_e)(e.value.style.chart.tooltip.customFormat)
@@ -668,10 +675,10 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
668
675
  content: f(() => [
669
676
  (s(), P(r(Re), {
670
677
  key: `table_${re.value}`,
671
- colNames: B.value.colNames,
672
- head: B.value.head,
673
- body: B.value.body,
674
- config: B.value.config,
678
+ colNames: Y.value.colNames,
679
+ head: Y.value.head,
680
+ body: Y.value.body,
681
+ config: Y.value.config,
675
682
  title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
676
683
  onClose: o[3] || (o[3] = (a) => m.value.showTable = !1)
677
684
  }, {
@@ -679,16 +686,16 @@ const Tt = ["id"], Ot = ["xmlns", "viewBox"], Pt = ["width", "height"], _t = ["c
679
686
  lt(R(a), 1)
680
687
  ]),
681
688
  td: f(({ td: a }) => [
682
- S("div", { innerHTML: a }, null, 8, Yt)
689
+ S("div", { innerHTML: a }, null, 8, Bt)
683
690
  ]),
684
691
  _: 1
685
692
  }, 8, ["colNames", "head", "body", "config", "title"]))
686
693
  ]),
687
694
  _: 1
688
- }, 8, ["config"])) : g("", !0)
695
+ }, 8, ["config"])) : p("", !0)
689
696
  ], 46, Tt));
690
697
  }
691
- }, Zt = /* @__PURE__ */ xt(Bt, [["__scopeId", "data-v-b59ee3e3"]]);
698
+ }, Zt = /* @__PURE__ */ xt(Yt, [["__scopeId", "data-v-ba8786fc"]]);
692
699
  export {
693
700
  Zt as default
694
701
  };