vue-data-ui 3.22.9 → 3.22.10

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 (204) hide show
  1. package/dist/{Arrow-DdymhUfY.js → Arrow-Ku6rQ87g.js} +1 -1
  2. package/dist/{BaseDraggableDialog-Av7Uxq5V.js → BaseDraggableDialog-CdkCqtag.js} +2 -2
  3. package/dist/{BaseIcon-UdRAvP2h.js → BaseIcon-CDTIUIKV.js} +1 -1
  4. package/dist/{BaseLegendToggle-DWtet-Hh.js → BaseLegendToggle-BrQ2OlzI.js} +1 -1
  5. package/dist/{BaseZoomControls-BY2KLqs6.js → BaseZoomControls-CkEX0292.js} +2 -2
  6. package/dist/{ColorPicker-DR_ummtM.js → ColorPicker-C959ZIW9.js} +2 -2
  7. package/dist/{DataTable-BxpTMgfK.js → DataTable-ByZy5gt1.js} +2 -2
  8. package/dist/{Legend-ROt6ugzW.js → Legend-5VQGLnmx.js} +2 -2
  9. package/dist/{NonSvgPenAndPaper-B6EG_Sga.js → NonSvgPenAndPaper-Bd8OzTqw.js} +3 -3
  10. package/dist/{PackageVersion-D__dRVRA.js → PackageVersion-BoTvk0i5.js} +1 -1
  11. package/dist/{PenAndPaper-DsXi7GJ-.js → PenAndPaper-CLaZJl6K.js} +3 -3
  12. package/dist/{Shape-UpH0a4Ur.js → Shape-B5ksaGa1.js} +3 -3
  13. package/dist/{Slicer-CW_XPIKL.js → Slicer-WsWTQPKt.js} +21 -21
  14. package/dist/{SlicerPreview-CTz41lOu.js → SlicerPreview-3n516NyE.js} +214 -214
  15. package/dist/{SparkTooltip-BTLN-Kex.js → SparkTooltip-CbYYc-xb.js} +1 -1
  16. package/dist/{Title-CcNiYzEo.js → Title-Cr3jP7Qd.js} +1 -1
  17. package/dist/{Tooltip-CxOrWlFy.js → Tooltip-CDbLl3TD.js} +1 -1
  18. package/dist/{UserOptions-trvJ26nz.js → UserOptions-BUQOnoPR.js} +2 -2
  19. package/dist/components/arrow.js +1 -1
  20. package/dist/components/vue-ui-3d-bar.js +1 -1
  21. package/dist/components/vue-ui-accordion.js +1 -1
  22. package/dist/components/vue-ui-age-pyramid.js +1 -1
  23. package/dist/components/vue-ui-annotator.js +1 -1
  24. package/dist/components/vue-ui-bullet.js +1 -1
  25. package/dist/components/vue-ui-bump.js +1 -1
  26. package/dist/components/vue-ui-candlestick.js +1 -1
  27. package/dist/components/vue-ui-carousel-table.js +1 -1
  28. package/dist/components/vue-ui-chestnut.js +1 -1
  29. package/dist/components/vue-ui-chord.js +1 -1
  30. package/dist/components/vue-ui-circle-pack.js +1 -1
  31. package/dist/components/vue-ui-cursor.js +1 -1
  32. package/dist/components/vue-ui-dag.js +1 -1
  33. package/dist/components/vue-ui-dashboard.js +1 -1
  34. package/dist/components/vue-ui-digits.js +1 -1
  35. package/dist/components/vue-ui-donut-evolution.js +1 -1
  36. package/dist/components/vue-ui-donut.js +1 -1
  37. package/dist/components/vue-ui-dumbbell.js +1 -1
  38. package/dist/components/vue-ui-flow.js +1 -1
  39. package/dist/components/vue-ui-funnel.js +1 -1
  40. package/dist/components/vue-ui-galaxy.js +1 -1
  41. package/dist/components/vue-ui-gauge.js +1 -1
  42. package/dist/components/vue-ui-geo.js +1 -1
  43. package/dist/components/vue-ui-gizmo.js +1 -1
  44. package/dist/components/vue-ui-heatmap.js +1 -1
  45. package/dist/components/vue-ui-history-plot.js +1 -1
  46. package/dist/components/vue-ui-horizontal-bar.js +1 -1
  47. package/dist/components/vue-ui-icon.js +1 -1
  48. package/dist/components/vue-ui-kpi.js +1 -1
  49. package/dist/components/vue-ui-mini-loader.js +1 -1
  50. package/dist/components/vue-ui-molecule.js +1 -1
  51. package/dist/components/vue-ui-mood-radar.js +1 -1
  52. package/dist/components/vue-ui-nested-donuts.js +1 -1
  53. package/dist/components/vue-ui-onion.js +1 -1
  54. package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
  55. package/dist/components/vue-ui-quadrant.js +1 -1
  56. package/dist/components/vue-ui-quick-chart.js +1 -1
  57. package/dist/components/vue-ui-radar.js +1 -1
  58. package/dist/components/vue-ui-rating.js +1 -1
  59. package/dist/components/vue-ui-relation-circle.js +1 -1
  60. package/dist/components/vue-ui-ridgeline.js +1 -1
  61. package/dist/components/vue-ui-rings.js +1 -1
  62. package/dist/components/vue-ui-scatter.js +1 -1
  63. package/dist/components/vue-ui-skeleton.js +1 -1
  64. package/dist/components/vue-ui-smiley.js +1 -1
  65. package/dist/components/vue-ui-spark-trend.js +1 -1
  66. package/dist/components/vue-ui-sparkbar.js +1 -1
  67. package/dist/components/vue-ui-sparkgauge.js +1 -1
  68. package/dist/components/vue-ui-sparkhistogram.js +1 -1
  69. package/dist/components/vue-ui-sparkline.js +1 -1
  70. package/dist/components/vue-ui-sparkstackbar.js +1 -1
  71. package/dist/components/vue-ui-stackbar.js +1 -1
  72. package/dist/components/vue-ui-stackline.js +1 -1
  73. package/dist/components/vue-ui-strip-plot.js +1 -1
  74. package/dist/components/vue-ui-table-heatmap.js +1 -1
  75. package/dist/components/vue-ui-table-sparkline.js +1 -1
  76. package/dist/components/vue-ui-table.js +1 -1
  77. package/dist/components/vue-ui-thermometer.js +1 -1
  78. package/dist/components/vue-ui-timer.js +1 -1
  79. package/dist/components/vue-ui-tiremarks.js +1 -1
  80. package/dist/components/vue-ui-treemap.js +1 -1
  81. package/dist/components/vue-ui-vertical-bar.js +1 -1
  82. package/dist/components/vue-ui-waffle.js +1 -1
  83. package/dist/components/vue-ui-wheel.js +1 -1
  84. package/dist/components/vue-ui-word-cloud.js +1 -1
  85. package/dist/components/vue-ui-world.js +1 -1
  86. package/dist/components/vue-ui-xy-canvas.js +1 -1
  87. package/dist/components/vue-ui-xy.js +1 -1
  88. package/dist/{dom-to-png-BbwhsRIr.js → dom-to-png-COPbGrdd.js} +1 -1
  89. package/dist/exposedLib-CZbtc2a6.js +25 -0
  90. package/dist/{img-DnP3eXuv.js → img-CNdXiUfZ.js} +1 -1
  91. package/dist/{labelUtils-DBEh078l.js → labelUtils-JaoYKi2N.js} +1 -1
  92. package/dist/{lib-JqW18y5I.js → lib-CnHx5WfV.js} +118 -107
  93. package/dist/{package-ByOT60IK.js → package-BRBLwZUc.js} +1 -1
  94. package/dist/{pdf-hj3gzrE7.js → pdf-CEMzBeuV.js} +1 -1
  95. package/dist/{render-common-D18VrP0h.js → render-common-DJXFRGhU.js} +10 -10
  96. package/dist/ssr/vue-ui-donut.js +1 -1
  97. package/dist/ssr/vue-ui-xy.js +1 -1
  98. package/dist/ssr.js +2 -2
  99. package/dist/types/utils.d.ts +40 -0
  100. package/dist/{useAutoSizeLabelsInsideViewbox-BGnDfZdg.js → useAutoSizeLabelsInsideViewbox-BUPt2iaP.js} +1 -1
  101. package/dist/{useNestedProp-DIuuzG1r.js → useNestedProp-D8NuRneO.js} +2 -2
  102. package/dist/{usePrinter-CqqHmnBI.js → usePrinter-B-X_Pub0.js} +2 -2
  103. package/dist/utils.js +26 -24
  104. package/dist/{vue-data-ui-ub3fCh6P.js → vue-data-ui-Bx_8d3b_.js} +68 -68
  105. package/dist/vue-data-ui.js +77 -77
  106. package/dist/vue-ui-3d-bar-CfUfbpSE.js +1825 -0
  107. package/dist/{vue-ui-accordion-CjAGqEJg.js → vue-ui-accordion-Oo3IsX3-.js} +3 -3
  108. package/dist/vue-ui-age-pyramid-DD-4y5Jd.js +1247 -0
  109. package/dist/{vue-ui-annotator-BIucnT0L.js → vue-ui-annotator-BvGE3lzE.js} +8 -8
  110. package/dist/vue-ui-bullet-DYOdbaO2.js +710 -0
  111. package/dist/vue-ui-bump-B8fJoxHF.js +1249 -0
  112. package/dist/{vue-ui-candlestick-DULUMU-Q.js → vue-ui-candlestick-BUP1JoNs.js} +287 -287
  113. package/dist/vue-ui-carousel-table-D-Bwhydt.js +455 -0
  114. package/dist/vue-ui-chestnut-C2VK2NEx.js +2042 -0
  115. package/dist/{vue-ui-chord-DL1M7cgL.js → vue-ui-chord-AA-QjUQI.js} +42 -42
  116. package/dist/{vue-ui-circle-pack-C1Pgq6si.js → vue-ui-circle-pack-CdBFGYOK.js} +37 -37
  117. package/dist/{vue-ui-cursor-d2uLAKTQ.js → vue-ui-cursor-Cm_J_5Gk.js} +5 -5
  118. package/dist/{vue-ui-dag-CVh9FpZr.js → vue-ui-dag-CgRph4-n.js} +32 -32
  119. package/dist/{vue-ui-dashboard-BH0N3ebj.js → vue-ui-dashboard-BuPw5QjB.js} +69 -69
  120. package/dist/{vue-ui-digits-R6wi3J-Y.js → vue-ui-digits-ClrukmcB.js} +3 -3
  121. package/dist/vue-ui-donut-Bc-EPZvu.js +2419 -0
  122. package/dist/{vue-ui-donut-BWDeVzLc.js → vue-ui-donut-DtQCrMKL.js} +207 -207
  123. package/dist/vue-ui-donut-evolution-DHkiY-BD.js +1522 -0
  124. package/dist/vue-ui-dumbbell-BlHEH4Mw.js +1564 -0
  125. package/dist/{vue-ui-flow-CNczKwTh.js → vue-ui-flow-PjwAW2tY.js} +71 -71
  126. package/dist/vue-ui-funnel-DojI09FV.js +782 -0
  127. package/dist/{vue-ui-galaxy-v3cTbUiM.js → vue-ui-galaxy-txYIK_LG.js} +276 -276
  128. package/dist/{vue-ui-gauge-DxvMjfoc.js → vue-ui-gauge-CoL0OzSd.js} +178 -178
  129. package/dist/{vue-ui-geo-BgmLkZZ2.js → vue-ui-geo-yuL-_sqF.js} +20 -20
  130. package/dist/{vue-ui-gizmo-n1kmcGeE.js → vue-ui-gizmo-CbC5zV3K.js} +9 -9
  131. package/dist/{vue-ui-heatmap-dSTh8ah_.js → vue-ui-heatmap-CwqsZIsR.js} +331 -331
  132. package/dist/{vue-ui-history-plot-N8BqMFVU.js → vue-ui-history-plot-CuWssH-D.js} +414 -414
  133. package/dist/vue-ui-horizontal-bar-Dyje3GND.js +1689 -0
  134. package/dist/{vue-ui-kpi-BKrUk9o8.js → vue-ui-kpi-BdYenScF.js} +3 -3
  135. package/dist/{vue-ui-mini-loader-D5we7V_W.js → vue-ui-mini-loader-BbwE3vBT.js} +2 -2
  136. package/dist/vue-ui-molecule-BBh31vmd.js +931 -0
  137. package/dist/{vue-ui-mood-radar-CpBRHQo_.js → vue-ui-mood-radar-B_6GFlaR.js} +261 -261
  138. package/dist/vue-ui-nested-donuts-BWq-At5Y.js +1493 -0
  139. package/dist/vue-ui-onion-BwGbSE-6.js +1200 -0
  140. package/dist/vue-ui-parallel-coordinate-plot-Bh9hNoqf.js +1416 -0
  141. package/dist/vue-ui-quadrant-B72Y4Zuw.js +1984 -0
  142. package/dist/{vue-ui-quick-chart-BO98uEPl.js → vue-ui-quick-chart-B3LF2ViM.js} +108 -108
  143. package/dist/vue-ui-radar-4v_E8oGX.js +1287 -0
  144. package/dist/{vue-ui-rating-CN-ZiAES.js → vue-ui-rating-CzLGCFWK.js} +101 -101
  145. package/dist/vue-ui-relation-circle-B_8dyIv2.js +924 -0
  146. package/dist/vue-ui-ridgeline-BArLhskj.js +1628 -0
  147. package/dist/vue-ui-rings-Csn5BgLk.js +1252 -0
  148. package/dist/vue-ui-scatter-BBaOx94M.js +2422 -0
  149. package/dist/{vue-ui-skeleton-DC2bZ0nk.js → vue-ui-skeleton-KeIPGp9U.js} +99 -99
  150. package/dist/{vue-ui-smiley-Dyyu1je3.js → vue-ui-smiley-C1mYDh4R.js} +17 -17
  151. package/dist/vue-ui-spark-trend-EqCqmHmU.js +443 -0
  152. package/dist/{vue-ui-sparkbar-DhIo1qsW.js → vue-ui-sparkbar-BPh45vBP.js} +66 -66
  153. package/dist/{vue-ui-sparkgauge-D0Fo3Hts.js → vue-ui-sparkgauge-CtouPcyW.js} +65 -65
  154. package/dist/vue-ui-sparkhistogram-D4sI0DHN.js +576 -0
  155. package/dist/{vue-ui-sparkline-ApivEMBP.js → vue-ui-sparkline-BDFZ78Fz.js} +51 -51
  156. package/dist/vue-ui-sparkstackbar-CbTXIfxm.js +674 -0
  157. package/dist/{vue-ui-stackbar-Ds4hXATH.js → vue-ui-stackbar-nMXIY9x8.js} +108 -108
  158. package/dist/vue-ui-stackline-CzfXl5ah.js +2425 -0
  159. package/dist/{vue-ui-strip-plot-C3ZHf4bD.js → vue-ui-strip-plot-BCf5nthl.js} +65 -65
  160. package/dist/vue-ui-table-BAKkFXki.js +1338 -0
  161. package/dist/{vue-ui-table-heatmap-CNXNXXBU.js → vue-ui-table-heatmap-CUMxqHKK.js} +15 -15
  162. package/dist/{vue-ui-table-sparkline-B9JJ4pFF.js → vue-ui-table-sparkline-BVTm16fd.js} +20 -20
  163. package/dist/vue-ui-thermometer-CGeEW1KV.js +770 -0
  164. package/dist/{vue-ui-timer-5NAWw5BN.js → vue-ui-timer-Bz7EnsM1.js} +5 -5
  165. package/dist/{vue-ui-tiremarks-Caz_g1c5.js → vue-ui-tiremarks-IOqtk_Rr.js} +17 -17
  166. package/dist/{vue-ui-treemap-F9upPyOI.js → vue-ui-treemap-JxNNtb7v.js} +232 -232
  167. package/dist/vue-ui-waffle-D34mcJWi.js +1368 -0
  168. package/dist/{vue-ui-wheel-DD6Q39BA.js → vue-ui-wheel-B_qEhyvk.js} +44 -44
  169. package/dist/{vue-ui-word-cloud-BZLT5svo.js → vue-ui-word-cloud-TtObhd91.js} +32 -32
  170. package/dist/{vue-ui-world-DbEJN5NA.js → vue-ui-world-R9o00A6c.js} +210 -210
  171. package/dist/{vue-ui-xy-BYMAITk_.js → vue-ui-xy-CUt6sU1s.js} +766 -766
  172. package/dist/{vue-ui-xy-Cn9Q8YPr.js → vue-ui-xy-Do34-UbE.js} +134 -134
  173. package/dist/vue-ui-xy-canvas-C6eRRH--.js +1790 -0
  174. package/package.json +1 -1
  175. package/dist/exposedLib-VXFp3Z2c.js +0 -19
  176. package/dist/vue-ui-3d-bar-taPI41_I.js +0 -1825
  177. package/dist/vue-ui-age-pyramid-jvQZbF8E.js +0 -1247
  178. package/dist/vue-ui-bullet-CIATzlsk.js +0 -710
  179. package/dist/vue-ui-bump-D8MxltQE.js +0 -1249
  180. package/dist/vue-ui-carousel-table-BSmdexG7.js +0 -455
  181. package/dist/vue-ui-chestnut-BIh1nQ7q.js +0 -2042
  182. package/dist/vue-ui-donut-BoZdciGh.js +0 -2419
  183. package/dist/vue-ui-donut-evolution-CpC9EMro.js +0 -1522
  184. package/dist/vue-ui-dumbbell-DGA5Bfnl.js +0 -1564
  185. package/dist/vue-ui-funnel-CaD2tZCT.js +0 -782
  186. package/dist/vue-ui-horizontal-bar-CwiQxYzv.js +0 -1689
  187. package/dist/vue-ui-molecule--kK1JfnP.js +0 -931
  188. package/dist/vue-ui-nested-donuts-8Ehwcuns.js +0 -1493
  189. package/dist/vue-ui-onion-Cf6JiYTH.js +0 -1200
  190. package/dist/vue-ui-parallel-coordinate-plot-Blnqp1DB.js +0 -1416
  191. package/dist/vue-ui-quadrant-CxU0jiOm.js +0 -1984
  192. package/dist/vue-ui-radar-eH2Qih4_.js +0 -1287
  193. package/dist/vue-ui-relation-circle-BIcP-aAt.js +0 -924
  194. package/dist/vue-ui-ridgeline-ChXHzEJw.js +0 -1628
  195. package/dist/vue-ui-rings-J990vNbX.js +0 -1252
  196. package/dist/vue-ui-scatter-BeJB0EKg.js +0 -2422
  197. package/dist/vue-ui-spark-trend-CpDX85H3.js +0 -443
  198. package/dist/vue-ui-sparkhistogram-CUjFiuAh.js +0 -576
  199. package/dist/vue-ui-sparkstackbar-DsKQJx_n.js +0 -674
  200. package/dist/vue-ui-stackline-DJbcVvmN.js +0 -2425
  201. package/dist/vue-ui-table-uudidrYt.js +0 -1338
  202. package/dist/vue-ui-thermometer-Bvw3oQb3.js +0 -770
  203. package/dist/vue-ui-waffle-Bk9AsrPp.js +0 -1368
  204. package/dist/vue-ui-xy-canvas-Dcm2ftwm.js +0 -1790
@@ -1,1493 +0,0 @@
1
- import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
2
- import { $ as t, Dt as n, G as r, It as i, J as a, Kt as o, Mt as s, Nt as c, Q as l, Rt as ee, S as te, T as ne, Wt as re, Z as ie, b as ae, d as oe, i as se, kt as ce, n as le, ot as ue, t as de, u as fe, v as pe, yt as me } from "./lib-JqW18y5I.js";
3
- import { t as he } from "./useConfig-DYM3f6EI.js";
4
- import { t as ge } from "./usePrinter-CqqHmnBI.js";
5
- import { n as _e, t as ve } from "./BaseScanner-DZvpgOjM.js";
6
- import { t as ye } from "./useSvgExport-SVIsDot8.js";
7
- import { t as be } from "./useNestedProp-DIuuzG1r.js";
8
- import { t as xe } from "./useThemeCheck-C43Tcqmk.js";
9
- import { t as Se } from "./img-DnP3eXuv.js";
10
- import { n as Ce } from "./Title-CcNiYzEo.js";
11
- import { t as we } from "./_plugin-vue_export-helper-B3ysoDQm.js";
12
- import { c as Te } from "./canvas-lib-BOP_HS11.js";
13
- import { t as Ee } from "./useResponsive-BfnK0KxU.js";
14
- import { t as De } from "./DefGrad-DVBqDjhO.js";
15
- import { t as Oe } from "./BaseLegendToggle-DWtet-Hh.js";
16
- import { t as ke } from "./A11yDataTable-DdRsVULz.js";
17
- import { t as Ae } from "./useUserOptionState-DK-_1ddE.js";
18
- import { t as je } from "./useChartAccessibility-DYqac8yF.js";
19
- import { t as Me } from "./labelUtils-DBEh078l.js";
20
- import { t as Ne } from "./Legend-ROt6ugzW.js";
21
- import { t as Pe } from "./vue_ui_nested_donuts-B8csIoVO.js";
22
- import { Fragment as u, Teleport as Fe, computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createSlots as Ie, createTextVNode as Le, createVNode as Re, defineAsyncComponent as g, guardReactiveProps as _, mergeProps as ze, nextTick as Be, normalizeClass as v, normalizeProps as y, normalizeStyle as Ve, onBeforeUnmount as He, onMounted as Ue, openBlock as b, ref as x, renderList as S, renderSlot as C, resolveDynamicComponent as We, shallowRef as Ge, toDisplayString as w, toRefs as Ke, unref as T, vShow as qe, watch as Je, withCtx as E, withDirectives as Ye } from "vue";
23
- //#region src/components/vue-ui-nested-donuts.vue
24
- var Xe = /* @__PURE__ */ e({ default: () => Dt }), Ze = ["id"], Qe = ["id"], $e = ["id"], et = { style: { position: "relative" } }, tt = [
25
- "xmlns",
26
- "aria-describedby",
27
- "viewBox"
28
- ], nt = ["width", "height"], rt = ["id"], it = ["id"], at = ["id"], ot = ["flood-color"], st = ["id", "d"], ct = [
29
- "d",
30
- "fill",
31
- "stroke",
32
- "stroke-width",
33
- "filter"
34
- ], lt = [
35
- "d",
36
- "fill",
37
- "stroke",
38
- "stroke-width"
39
- ], ut = { key: 1 }, dt = ["d", "fill"], ft = { key: 2 }, pt = [
40
- "font-size",
41
- "font-weight",
42
- "fill",
43
- "dy"
44
- ], mt = ["href"], ht = [
45
- "x",
46
- "y",
47
- "font-size",
48
- "font-weight",
49
- "fill"
50
- ], gt = { key: 3 }, _t = ["filter"], vt = [
51
- "opacity",
52
- "text-anchor",
53
- "x",
54
- "y",
55
- "fill",
56
- "font-size",
57
- "font-weight"
58
- ], yt = [
59
- "opacity",
60
- "text-anchor",
61
- "x",
62
- "y",
63
- "fill",
64
- "font-size",
65
- "font-weight"
66
- ], bt = [
67
- "d",
68
- "fill",
69
- "onMouseenter",
70
- "onClick",
71
- "onMouseleave"
72
- ], xt = {
73
- key: 0,
74
- style: {
75
- position: "absolute",
76
- top: "100%",
77
- left: "0",
78
- width: "100%"
79
- },
80
- "data-dom-to-png-ignore": "",
81
- "aria-hidden": "true"
82
- }, St = {
83
- key: 5,
84
- class: "vue-data-ui-watermark"
85
- }, Ct = ["id"], wt = {
86
- key: 0,
87
- class: "vue-ui-nested-donuts-legend-title"
88
- }, Tt = ["onClick"], Et = ["innerHTML"], Dt = /*#__PURE__*/ we({
89
- __name: "vue-ui-nested-donuts",
90
- props: {
91
- config: {
92
- type: Object,
93
- default() {
94
- return {};
95
- }
96
- },
97
- dataset: {
98
- type: Array,
99
- default() {
100
- return [];
101
- }
102
- }
103
- },
104
- emits: [
105
- "selectLegend",
106
- "selectDatapoint",
107
- "copyAlt"
108
- ],
109
- setup(e, { expose: we, emit: Xe }) {
110
- let Dt = g(() => import("./Tooltip-CxOrWlFy.js")), Ot = g(() => import("./BaseIcon-UdRAvP2h.js").then((e) => e.n)), kt = g(() => import("./vue-ui-accordion-CjAGqEJg.js").then((e) => e.n)), At = g(() => import("./DataTable-BxpTMgfK.js")), jt = g(() => import("./UserOptions-trvJ26nz.js").then((e) => e.n)), Mt = g(() => import("./PenAndPaper-DsXi7GJ-.js").then((e) => e.t)), Nt = g(() => import("./PackageVersion-D__dRVRA.js").then((e) => e.t)), Pt = g(() => import("./BaseDraggableDialog-Av7Uxq5V.js").then((e) => e.n)), { vue_ui_nested_donuts: Ft } = he(), { isThemeValid: It, warnInvalidTheme: Lt } = xe(), D = e, Rt = d({
111
- get() {
112
- return !!D.dataset && D.dataset.length;
113
- },
114
- set(e) {
115
- return e;
116
- }
117
- }), O = x(r()), zt = x(!1), Bt = x(""), Vt = x(null), Ht = x(0), k = x(null), Ut = x(null), Wt = x(null), Gt = x(null), Kt = x(null), qt = x(0), Jt = x(0), Yt = x(0), A = x(!0), j = x([]), Xt = x([]), Zt = x(!1), Qt = x(null), $t = x(null), en = x(!1), tn = x(!1), M = x(null), nn = x({
118
- x: 0,
119
- y: 0
120
- }), rn = x("pointer"), an = x(!1), N = x(!1);
121
- function on(e) {
122
- N.value = e, Ht.value += 1;
123
- }
124
- let P = x(mn()), F = d(() => P.value.userOptions.useCursorPointer), sn = {
125
- name: "",
126
- series: [
127
- {
128
- name: "",
129
- values: [3],
130
- color: "#BABABA"
131
- },
132
- {
133
- name: "",
134
- values: [2],
135
- color: "#AAAAAA"
136
- },
137
- {
138
- name: "",
139
- values: [1],
140
- color: "#CACACA"
141
- }
142
- ]
143
- }, cn = d(() => o({
144
- defaultConfig: {
145
- useCssAnimation: !1,
146
- table: { show: !1 },
147
- startAnimation: { show: !1 },
148
- userOptions: { show: !1 },
149
- style: { chart: {
150
- backgroundColor: "#99999930",
151
- layout: { labels: { dataLabels: { show: !1 } } },
152
- legend: {
153
- backgroundColor: "transparent",
154
- showValue: !1,
155
- showPercentage: !1
156
- },
157
- title: {
158
- color: "#1A1A1A",
159
- subtitle: { color: "#5A5A5A" }
160
- }
161
- } }
162
- },
163
- userConfig: P.value.skeletonConfig ?? {}
164
- })), { loading: ln, FINAL_DATASET: I, manualLoading: un } = _e({
165
- ...Ke(D),
166
- FINAL_CONFIG: P,
167
- prepareConfig: mn,
168
- callback: () => {
169
- Promise.resolve().then(async () => {
170
- await _n();
171
- });
172
- },
173
- skeletonDataset: D.config?.skeletonDataset ?? [sn, sn],
174
- skeletonConfig: o({
175
- defaultConfig: P.value,
176
- userConfig: cn.value
177
- })
178
- }), { userOptionsVisible: dn, setUserOptionsVisibility: fn, keepUserOptionState: pn } = Ae({ config: P.value }), { svgRef: L } = je({ config: P.value.style.chart.title });
179
- function mn() {
180
- let e = be({
181
- userConfig: D.config,
182
- defaultConfig: Ft
183
- }), t = {}, n = e.theme;
184
- if (n) if (!It.value(e)) Lt(e), t = e;
185
- else {
186
- let r = be({
187
- userConfig: Pe[n] || D.config,
188
- defaultConfig: e
189
- });
190
- t = {
191
- ...be({
192
- userConfig: D.config,
193
- defaultConfig: r
194
- }),
195
- customPalette: e.customPalette.length ? e.customPalette : re[n] || s
196
- };
197
- }
198
- else t = e;
199
- return t;
200
- }
201
- Je(() => D.config, (e) => {
202
- ln.value || (P.value = mn()), dn.value = !P.value.userOptions.showOnChartHover, vn(), qt.value += 1, Jt.value += 1, Yt.value += 1, V.value.dataLabels.show = P.value.style.chart.layout.labels.dataLabels.show, V.value.showTable = P.value.table.show, V.value.showTooltip = P.value.style.chart.tooltip.show, H.value.width = P.value.style.chart.width, H.value.height = P.value.style.chart.height;
203
- }, { deep: !0 });
204
- let hn = d(() => {
205
- let { top: e, right: t, bottom: n, left: r } = P.value.style.chart.padding;
206
- return {
207
- css: `padding:${e}px ${t}px ${n}px ${r}px`,
208
- top: e,
209
- right: t,
210
- bottom: n,
211
- left: r
212
- };
213
- });
214
- function gn(e, t = 1e3, n = 50) {
215
- return new Promise((r) => {
216
- let a = e.length;
217
- j.value = Array(a).fill(0), Xt.value = [];
218
- let o = 0;
219
- e.forEach((e, s) => {
220
- setTimeout(() => {
221
- let n = performance.now();
222
- function c(ee) {
223
- let te = Math.min((ee - n) / t, 1), ne = e * l(te);
224
- j.value[s] = ne, j.value = [...j.value];
225
- let re = [], ie = 0;
226
- D.dataset.forEach((e, t) => {
227
- let n = pe(e.series.reduce((e, t) => e + pe(i(t.values).reduce((e, t) => e + t, 0)), 0)) - pe(j.value.slice(ie, ie + e.series.length).reduce((e, t) => e + t, 0));
228
- n > Number.MIN_VALUE && re.push({
229
- name: "__ghost__",
230
- arcOf: e.name,
231
- arcOfId: `${O.value}_${t}`,
232
- id: `ghost_${O.value}_${t}`,
233
- seriesIndex: -1,
234
- datasetIndex: t,
235
- color: "transparent",
236
- value: n,
237
- fullValue: n,
238
- absoluteValues: [],
239
- ghost: !0
240
- }), ie += e.series.length;
241
- }), Xt.value = re, te < 1 ? requestAnimationFrame(c) : (o += 1, o === a && r());
242
- }
243
- requestAnimationFrame(c);
244
- }, s * n);
245
- });
246
- });
247
- }
248
- async function _n() {
249
- if (P.value.startAnimation?.show) {
250
- let e = I.value.flatMap((e) => e.series).map((e) => i(e.values).reduce((e, t) => e + t, 0));
251
- j.value = e.map(() => 0), A.value = !0, Xt.value = I.value.map((e, t) => {
252
- let n = e.series.reduce((e, t) => e + i(t.values).reduce((e, t) => e + t, 0), 0);
253
- return {
254
- name: "__ghost__",
255
- arcOf: e.name,
256
- arcOfId: `${O.value}_${t}`,
257
- id: `ghost_${O.value}_${t}`,
258
- seriesIndex: -1,
259
- datasetIndex: t,
260
- color: "transparent",
261
- value: n,
262
- fullValue: n,
263
- absoluteValues: [],
264
- ghost: !0
265
- };
266
- }), await Be(), gn(e, P.value.startAnimation.durationMs, P.value.startAnimation.staggerMs).then(() => {
267
- A.value = !1, Xt.value = [];
268
- });
269
- } else A.value = !1;
270
- }
271
- Ue(async () => {
272
- Zt.value = !0, vn(), await _n();
273
- });
274
- let R = Ge(null), z = Ge(null), B = d(() => !!P.value.debug);
275
- function vn() {
276
- if (ce(D.dataset) ? (t({
277
- componentName: "VueUiNestedDonuts",
278
- type: "dataset",
279
- debug: B.value
280
- }), Rt.value = !1, un.value = !0) : un.value = P.value.loading, P.value.responsive) {
281
- let e = Te(() => {
282
- let { width: e, height: t } = Ee({
283
- chart: k.value,
284
- title: P.value.style.chart.title.text ? Ut.value : null,
285
- legend: P.value.style.chart.legend.show ? Wt.value : null,
286
- source: Gt.value,
287
- noTitle: Kt.value,
288
- padding: hn.value
289
- });
290
- requestAnimationFrame(() => {
291
- H.value.width = e, H.value.height = t;
292
- });
293
- });
294
- R.value && (z.value && R.value.unobserve(z.value), R.value.disconnect()), R.value = new ResizeObserver(e), z.value = k.value.parentNode, R.value.observe(z.value);
295
- }
296
- }
297
- He(() => {
298
- R.value && (z.value && R.value.unobserve(z.value), R.value.disconnect());
299
- });
300
- let { isPrinting: yn, isImaging: bn, generatePdf: xn, generateImage: Sn } = ge({
301
- elementId: `nested_donuts_${O.value}`,
302
- fileName: P.value.style.chart.title.text || "vue-ui-nested-donuts",
303
- options: P.value.userOptions.print
304
- }), Cn = d(() => P.value.userOptions.show && !P.value.style.chart.title.text), wn = d(() => te(P.value.customPalette)), V = x({
305
- dataLabels: { show: P.value.style.chart.layout.labels.dataLabels.show },
306
- showTable: P.value.table.show,
307
- showTooltip: P.value.style.chart.tooltip.show
308
- });
309
- Je(P, () => {
310
- V.value = {
311
- dataLabels: { show: P.value.style.chart.layout.labels.dataLabels.show },
312
- showTable: P.value.table.show,
313
- showTooltip: P.value.style.chart.tooltip.show
314
- };
315
- }, { immediate: !0 });
316
- let H = x({
317
- width: P.value.style.chart.width,
318
- height: P.value.style.chart.height
319
- }), U = Xe;
320
- function Tn({ datapoint: e, index: t, seriesIndex: n }) {
321
- P.value.events.datapointClick && P.value.events.datapointClick({
322
- datapoint: e,
323
- seriesIndex: n
324
- }), U("selectDatapoint", {
325
- datapoint: e,
326
- index: t
327
- });
328
- }
329
- function En({ from: e, to: t, duration: n, onUpdate: r, onDone: i, easing: a = l }) {
330
- let o = performance.now();
331
- function s(c) {
332
- let l = Math.min((c - o) / n, 1), ee = a(l);
333
- r(e + (t - e) * ee, l), l < 1 ? requestAnimationFrame(s) : (r(t, 1), i && i());
334
- }
335
- requestAnimationFrame(s);
336
- }
337
- let W = x([]), G = d(() => {
338
- ln.value, I.value.forEach((e, n) => {
339
- [null, void 0].includes(e.name) && t({
340
- componentName: "VueUiNestedDonuts",
341
- type: "datasetSerieAttribute",
342
- property: "name",
343
- index: n,
344
- debug: B.value
345
- }), [null, void 0].includes(e.series) ? t({
346
- componentName: "VueUiNestedDonuts",
347
- type: "datasetSerieAttribute",
348
- property: "series",
349
- index: n,
350
- debug: B.value
351
- }) : e.series.length === 0 ? t({
352
- componentName: "VueUiNestedDonuts",
353
- type: "datasetAttributeEmpty",
354
- property: `series at index ${n}`,
355
- debug: B.value
356
- }) : e.series.forEach((e, n) => {
357
- [null, void 0].includes(e.name) && t({
358
- componentName: "VueUiNestedDonuts",
359
- type: "datasetSerieAttribute",
360
- property: "name",
361
- index: n,
362
- key: "serie",
363
- debug: B.value
364
- }), [null, void 0].includes(e.values) && t({
365
- componentName: "VueUiNestedDonuts",
366
- type: "datasetSerieAttribute",
367
- property: "values",
368
- index: n,
369
- key: "serie",
370
- debug: B.value
371
- });
372
- });
373
- });
374
- let e = 0;
375
- return I.value.map((t, n) => ({
376
- ...t,
377
- total: t.series.filter((e) => !W.value.includes(e.id)).map((e) => i(e.values).reduce((e, t) => e + t, 0)).reduce((e, t) => e + t, 0),
378
- datasetIndex: n,
379
- id: `${O.value}_${n}`,
380
- series: t.series.map((r, a) => {
381
- let o = i(r.values).reduce((e, t) => e + t, 0);
382
- return {
383
- name: r.name,
384
- arcOf: t.name,
385
- arcOfId: `${O.value}_${n}`,
386
- id: `${O.value}_${n}_${a}`,
387
- seriesIndex: a,
388
- datasetIndex: n,
389
- color: ae(r.color) || wn.value[a] || s[a % s.length],
390
- value: A.value ? j.value[e++] ?? 0 : o,
391
- absoluteValues: r.values || []
392
- };
393
- })
394
- }));
395
- });
396
- Je(() => D.dataset, (e) => {
397
- Array.isArray(e) && e.length > 0 && (un.value = !1);
398
- }, { immediate: !0 });
399
- let K = d(() => Math.min(H.value.height, H.value.width) * (P.value.style.chart.layout.donut.strokeWidth / 512)), q = d(() => [...G.value].map((e, t) => {
400
- let n = e.series.filter((e) => !W.value.includes(e.id)).map((e) => e.value).reduce((e, t) => e + t, 0);
401
- return {
402
- ...e,
403
- total: n,
404
- series: e.series.filter((e) => !W.value.includes(e.id)).map((e) => ({
405
- ...e,
406
- proportion: e.value / n
407
- }))
408
- };
409
- }));
410
- function Dn(e, t, n) {
411
- let r = 0;
412
- for (let t = 0; t < e.length; t += 1) n.includes(e[t]) && (r += 1);
413
- return r < t;
414
- }
415
- let J = x(q.value);
416
- Je(() => q.value, (e) => J.value = e);
417
- function On(e) {
418
- let t = e.map((e) => e.id);
419
- if (e.some((e) => W.value.includes(e.id))) {
420
- let e = new Set(t);
421
- W.value = W.value.filter((t) => !e.has(t));
422
- } else W.value.push(...t);
423
- U("selectLegend", q.value);
424
- }
425
- function Y(e) {
426
- let t = D.dataset.flatMap((e, t) => e.series.map((e, n) => ({
427
- value: i(e.values).reduce((e, t) => e + t, 0),
428
- id: `${O.value}_${t}_${n}`,
429
- arcOfId: `${O.value}_${t}`
430
- }))).find((t) => t.id === e.id);
431
- if (!t) return;
432
- let n = G.value.flatMap((e) => e.series).find((t) => t.id === e.id)?.value ?? 0, r = J.value.flatMap((e) => e.series).find((t) => t.id === e.id), a = r ? r.value : 0, o = G.value.find((e) => e.id === t.arcOfId);
433
- if (!o) return;
434
- let s = o.series.map((e) => e.id), c = Dn(s, s.length - 1, W.value);
435
- W.value.includes(e.id) ? (W.value = W.value.filter((t) => t !== e.id), P.value.serieToggleAnimation.show ? En({
436
- from: a,
437
- to: n,
438
- duration: P.value.serieToggleAnimation.durationMs,
439
- onUpdate: (t) => {
440
- J.value = J.value.map((n) => ({
441
- ...n,
442
- series: n.series.map((n) => n.id === e.id ? {
443
- ...n,
444
- value: t
445
- } : n)
446
- }));
447
- },
448
- onDone: () => {
449
- U("selectLegend", q.value);
450
- }
451
- }) : (J.value = J.value.map((t) => ({
452
- ...t,
453
- series: t.series.map((t) => t.id === e.id ? {
454
- ...t,
455
- value: n
456
- } : t)
457
- })), U("selectLegend", q.value))) : c && (P.value.serieToggleAnimation.show ? En({
458
- from: a,
459
- to: 0,
460
- duration: P.value.serieToggleAnimation.durationMs,
461
- onUpdate: (t) => {
462
- J.value = J.value.map((n) => ({
463
- ...n,
464
- series: n.series.map((n) => n.id === e.id ? {
465
- ...n,
466
- value: t
467
- } : n)
468
- }));
469
- },
470
- onDone: () => {
471
- W.value.push(e.id), U("selectLegend", q.value);
472
- }
473
- }) : (J.value = J.value.map((t) => ({
474
- ...t,
475
- series: t.series.map((t) => t.id === e.id ? {
476
- ...t,
477
- value: 0
478
- } : t)
479
- })), W.value.push(e.id), U("selectLegend", q.value)));
480
- }
481
- function kn(e) {
482
- return G.value.length ? G.value.flatMap((e) => e.series).filter((t) => t.name === e) || (P.value.debug && console.warn(`VueUiNestedDonuts - Series name not found "${e}"`), null) : (P.value.debug && console.warn("VueUiNestedDonuts - There are no series to show."), null);
483
- }
484
- function An(e) {
485
- let t = kn(e);
486
- t !== null && (Array.isArray(t) ? t.forEach((e) => {
487
- W.value.includes(e.id) && Y({ id: e.id });
488
- }) : W.value.includes(t.id) && Y({ id: t.id }));
489
- }
490
- function jn(e) {
491
- let t = kn(e);
492
- t !== null && (Array.isArray(t) ? t.forEach((e) => {
493
- W.value.includes(e.id) || Y({ id: e.id });
494
- }) : W.value.includes(t.id) || Y({ id: t.id }));
495
- }
496
- let Mn = d(() => K.value / G.value.length * P.value.style.chart.layout.donut.spacingRatio), Nn = d(() => J.value.map((e, t) => K.value - t * K.value / G.value.length)), X = d(() => J.value.map((e, t) => {
497
- let r = Math.abs(e.series.map((e) => e.value).reduce((e, t) => e + t, 0)) > 0, i = K.value - t * K.value / J.value.length, a = A.value ? Xt.value.find((e) => e.datasetIndex === t) : null, o = [...e.series, ...a ? [a] : []].map((e) => ({
498
- ...e,
499
- value: e.value < 1e-11 ? Number.MIN_VALUE : e.value
500
- })), s = n({ series: [{
501
- name: "_",
502
- color: P.value.style.chart.layout.donut.emptyFill,
503
- value: 1
504
- }] }, H.value.width / 2, H.value.height / 2, i, i, 1.99999, 2, 1, 360, 105.25, Mn.value), c = `M ${H.value.width / 2},${H.value.height / 2 + i}
505
- a ${i},${i} 0 1,1 0,${-2 * i}
506
- a ${i},${i} 0 1,1 0,${2 * i}`;
507
- return {
508
- ...e,
509
- hasData: r,
510
- radius: i,
511
- skeleton: s,
512
- fullCirclePath: c,
513
- donut: n({ series: o }, H.value.width / 2, H.value.height / 2, i, i, 1.99999, 2, 1, 360, 105.25, Mn.value)
514
- };
515
- })), Pn = d(() => [...G.value].map((e, t) => {
516
- let r = t * K.value / G.value.length;
517
- return {
518
- sizeRatio: r,
519
- donut: n({ series: [{ value: 1 }] }, H.value.width / 2, H.value.height / 2, K.value - r, K.value - r, 1.99999, 2, 1, 360, 105.25, K.value / G.value.length * P.value.style.chart.layout.donut.spacingRatio)[0]
520
- };
521
- })), Fn = x(null), In = x(null), Z = x(null), Ln = x(null);
522
- function Rn({ datapoint: e, seriesIndex: t }) {
523
- P.value.events.datapointLeave && P.value.events.datapointLeave({
524
- datapoint: e,
525
- seriesIndex: t
526
- }), zt.value = !1, Fn.value = null, Vt.value = null, In.value = null, Z.value = null, M.value = null, rn.value = "pointer";
527
- }
528
- function zn({ val: e, percentage: t, showVal: n, showPercentage: r, config: i }) {
529
- return Me({
530
- config: i,
531
- val: e,
532
- percentage: t,
533
- showVal: n,
534
- showPercentage: r
535
- });
536
- }
537
- function Bn({ datapoint: e, _relativeIndex: t, seriesIndex: n, triggerMode: r = "pointer" }) {
538
- P.value.events.datapointEnter && P.value.events.datapointEnter({
539
- datapoint: e,
540
- seriesIndex: n
541
- }), rn.value = r, M.value = n, Fn.value = e.arcOfId, In.value = e.id, Z.value = n, Vt.value = e.id, Ln.value = {
542
- datapoint: e,
543
- seriesIndex: n,
544
- series: J.value,
545
- config: P.value
546
- };
547
- let i = P.value.style.chart.tooltip.customFormat;
548
- if (me(i) && ue(() => i({
549
- seriesIndex: n,
550
- datapoint: e,
551
- series: J.value,
552
- config: P.value
553
- }))) Bt.value = i({
554
- seriesIndex: n,
555
- datapoint: e,
556
- series: J.value,
557
- config: P.value
558
- });
559
- else {
560
- let t = "";
561
- if (P.value.style.chart.tooltip.showAllItemsAtIndex && W.value.length === 0) {
562
- let r = J.value.map((e) => e.series.find((e) => e.seriesIndex === n));
563
- r.forEach((i, o) => {
564
- if (!i) return "";
565
- t += `
566
- <div style="display:flex; flex-direction: column; justify-content:flex-start; align-items:flex-start;padding:6px 0; ${o < r.length - 1 ? `border-bottom:1px solid ${P.value.style.chart.tooltip.borderColor}` : ""}">
567
- <div style="display:flex; flex-direction: row; gap: 3px; justify-content:flex-start; align-items:center;">
568
- <svg viewBox="0 0 20 20" height="${P.value.style.chart.tooltip.fontSize}" width="${P.value.style.chart.tooltip.fontSize}">
569
- <circle cx="10" cy="10" r="10" fill="${i.color}"/>
570
- </svg>
571
- <span>
572
- ${i.arcOf ?? ""} - ${i.name}
573
- </span>
574
- </div>
575
- <span>
576
- <b>
577
- ${zn({
578
- config: P.value.style.chart.tooltip,
579
- showVal: P.value.style.chart.tooltip.showValue,
580
- showPercentage: P.value.style.chart.tooltip.showPercentage,
581
- val: se(P.value.style.chart.layout.labels.dataLabels.formatter, e.value, a({
582
- p: P.value.style.chart.layout.labels.dataLabels.prefix,
583
- v: e.value,
584
- s: P.value.style.chart.layout.labels.dataLabels.suffix,
585
- r: P.value.style.chart.tooltip.roundingValue
586
- }), {
587
- datapoint: e,
588
- seriesIndex: n
589
- }),
590
- percentage: a({
591
- v: i.proportion * 100,
592
- s: "%",
593
- r: P.value.style.chart.tooltip.roundingPercentage
594
- })
595
- })}
596
- </b>
597
- </span>
598
- </div>
599
- `;
600
- });
601
- } else t += `<div style="width:100%;text-align:center;border-bottom:1px solid ${P.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${e.arcOf ?? ""} - ${e.name}</div>`, t += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${e.color}"/></svg>`, P.value.style.chart.tooltip.showValue && (t += `<b>${se(P.value.style.chart.layout.labels.dataLabels.formatter, e.value, a({
602
- p: P.value.style.chart.layout.labels.dataLabels.prefix,
603
- v: e.value,
604
- s: P.value.style.chart.layout.labels.dataLabels.suffix,
605
- r: P.value.style.chart.tooltip.roundingValue
606
- }), {
607
- datapoint: e,
608
- seriesIndex: n
609
- })}</b>`), P.value.style.chart.tooltip.showPercentage && (P.value.style.chart.tooltip.showValue ? t += `<span>(${a({
610
- v: e.proportion * 100,
611
- s: "%",
612
- r: P.value.style.chart.tooltip.roundingPercentage
613
- })})</span></div>` : t += `<b>${a({
614
- v: e.proportion * 100,
615
- s: "%",
616
- r: P.value.style.chart.tooltip.roundingPercentage
617
- })}</b></div>`);
618
- Bt.value = `<div style="font-size:${P.value.style.chart.tooltip.fontSize}px">${t}</div>`;
619
- }
620
- zt.value = !0;
621
- }
622
- function Vn(e) {
623
- return e.proportion * 100 > P.value.style.chart.layout.labels.dataLabels.hideUnderValue;
624
- }
625
- function Hn(e, t) {
626
- if (!P.value.useBlurOnHover) return "";
627
- if (P.value.style.chart.tooltip.showAllItemsAtIndex && W.value.length === 0) return [null, void 0].includes(Z.value) || Z.value === t ? "" : `url(#blur_${O.value})`;
628
- if (!P.value.style.chart.tooltip.showAllItemsAtIndex || W.value.length) return [null, void 0].includes(In.value) || In.value === e.id ? "" : `url(#blur_${O.value})`;
629
- }
630
- let Un = d(() => G.value.map((e, t) => {
631
- let n = e.series.filter((e) => !W.value.includes(e.id)), r = A.value ? n.map((e) => {
632
- let n = I.value[t].series.findIndex((t) => t.name === e.name);
633
- return i(I.value[t].series[n].values).reduce((e, t) => e + t, 0);
634
- }).reduce((e, t) => e + t, 0) : n.map((e) => e.value).reduce((e, t) => e + t, 0);
635
- return e.series.map((e, n) => {
636
- let o = i(I.value[t].series[n].values).reduce((e, t) => e + t, 0), s = A.value ? o : e.value, c = zn({
637
- val: se(P.value.style.chart.layout.labels.dataLabels.formatter, s, a({
638
- p: P.value.style.chart.layout.labels.dataLabels.prefix,
639
- v: s,
640
- s: P.value.style.chart.layout.labels.dataLabels.suffix,
641
- r: P.value.style.chart.legend.roundingValue
642
- }), {
643
- datapoint: e,
644
- seriesIndex: n
645
- }),
646
- percentage: isNaN(s / r) || W.value.includes(e.id) ? "-" : a({
647
- v: s / r * 100,
648
- s: "%",
649
- r: P.value.style.chart.legend.roundingPercentage
650
- }),
651
- showVal: P.value.style.chart.legend.showValue,
652
- showPercentage: P.value.style.chart.legend.showPercentage,
653
- config: P.value.style.chart.legend
654
- }), l = `${e.name}${P.value.style.chart.legend.showPercentage || P.value.style.chart.legend.showValue ? ": " : ""}${c}`;
655
- return {
656
- name: e.name,
657
- color: e.color,
658
- value: s,
659
- display: l,
660
- svgDisplay: `${e.arcOf ? `${e.arcOf} - ` : ""}${l}`,
661
- shape: "circle",
662
- arcOf: e.arcOf,
663
- id: e.id,
664
- seriesIndex: n,
665
- datasetIndex: t,
666
- total: r,
667
- opacity: W.value.includes(e.id) ? .5 : 1,
668
- segregate: () => Y(e),
669
- isSegregated: W.value.includes(e.id)
670
- };
671
- });
672
- })), Wn = d(() => ({
673
- cy: "nested-donuts-legend",
674
- backgroundColor: P.value.style.chart.legend.backgroundColor,
675
- color: P.value.style.chart.legend.color,
676
- fontSize: P.value.style.chart.legend.fontSize,
677
- paddingBottom: 12,
678
- fontWeight: P.value.style.chart.legend.bold ? "bold" : ""
679
- })), Q = d(() => ({
680
- head: J.value.flatMap((e) => e.series.map((t) => ({
681
- name: `${e.name} - ${t.name}`,
682
- color: t.color,
683
- total: e.total
684
- }))),
685
- body: J.value.flatMap((e) => e.series.map((e) => e.value))
686
- }));
687
- function Gn(e = null) {
688
- Be(() => {
689
- let t = Q.value.head.map((e, t) => [
690
- [e.name],
691
- [Q.value.body[t]],
692
- [isNaN(Q.value.body[t] / e.total) ? "-" : Q.value.body[t] / e.total * 100]
693
- ]), n = ne([
694
- [P.value.style.chart.title.text],
695
- [P.value.style.chart.title.subtitle.text],
696
- [
697
- [""],
698
- ["val"],
699
- ["%"]
700
- ]
701
- ].concat(t));
702
- e ? e(n) : ie({
703
- csvContent: n,
704
- title: P.value.style.chart.title.text || "vue-ui-nested-donuts"
705
- });
706
- });
707
- }
708
- let Kn = d(() => {
709
- let e = [
710
- P.value.table.columnNames.series,
711
- P.value.table.columnNames.value,
712
- P.value.table.columnNames.percentage
713
- ], t = Q.value.head.map((e, t) => {
714
- let n = a({
715
- p: P.value.style.chart.layout.labels.dataLabels.prefix,
716
- v: Q.value.body[t],
717
- s: P.value.style.chart.layout.labels.dataLabels.suffix,
718
- r: P.value.table.td.roundingValue
719
- });
720
- return [
721
- {
722
- color: e.color,
723
- name: e.name
724
- },
725
- n,
726
- isNaN(Q.value.body[t] / e.total) ? "-" : a({
727
- v: Q.value.body[t] / e.total * 100,
728
- s: "%",
729
- r: P.value.table.td.roundingPercentage
730
- })
731
- ];
732
- }), n = t.map((e) => e.map((e, t) => t === 0 ? e.name : e)), r = {
733
- th: {
734
- backgroundColor: P.value.table.th.backgroundColor,
735
- color: P.value.table.th.color,
736
- outline: P.value.table.th.outline
737
- },
738
- td: {
739
- backgroundColor: P.value.table.td.backgroundColor,
740
- color: P.value.table.td.color,
741
- outline: P.value.table.td.outline
742
- },
743
- breakpoint: P.value.table.responsiveBreakpoint
744
- };
745
- return {
746
- colNames: [
747
- P.value.table.columnNames.series,
748
- P.value.table.columnNames.value,
749
- P.value.table.columnNames.percentage
750
- ],
751
- head: e,
752
- body: t,
753
- a11yBody: n,
754
- config: r
755
- };
756
- });
757
- function qn() {
758
- return G.value;
759
- }
760
- function Jn() {
761
- V.value.showTable = !V.value.showTable;
762
- }
763
- function Yn() {
764
- V.value.dataLabels.show = !V.value.dataLabels.show;
765
- }
766
- function Xn() {
767
- V.value.showTooltip = !V.value.showTooltip;
768
- }
769
- let Zn = x(!1);
770
- function Qn() {
771
- Zn.value = !Zn.value;
772
- }
773
- async function $n({ scale: e = 2 } = {}) {
774
- if (!k.value) return;
775
- let { width: t, height: n } = k.value.getBoundingClientRect(), r = t / n, { imageUri: i, base64: a } = await Se({
776
- domElement: k.value,
777
- base64: !0,
778
- img: !0,
779
- scale: e
780
- });
781
- return {
782
- imageUri: i,
783
- base64: a,
784
- title: P.value.style.chart.title.text,
785
- width: t,
786
- height: n,
787
- aspectRatio: r
788
- };
789
- }
790
- let er = x(null);
791
- function tr() {
792
- if (!er.value) return;
793
- let { x: e, y: t, width: n, height: r } = er.value.getBBox();
794
- L.value && L.value.setAttribute("viewBox", `${e} ${t} ${n + Math.min(0, e)} ${r + Math.min(0, t)}`);
795
- }
796
- let nr = d(() => {
797
- let e = P.value.table.useDialog && !P.value.table.show, t = V.value.showTable;
798
- return {
799
- component: e ? Pt : kt,
800
- title: `${P.value.style.chart.title.text}${P.value.style.chart.title.subtitle.text ? `: ${P.value.style.chart.title.subtitle.text}` : ""}`,
801
- props: e ? {
802
- backgroundColor: P.value.table.th.backgroundColor,
803
- color: P.value.table.th.color,
804
- headerColor: P.value.table.th.color,
805
- headerBg: P.value.table.th.backgroundColor,
806
- isFullscreen: N.value,
807
- fullscreenParent: k.value,
808
- forcedWidth: Math.min(800, window.innerWidth * .8),
809
- isCursorPointer: F.value
810
- } : {
811
- hideDetails: !0,
812
- config: {
813
- open: t,
814
- maxHeight: 1e4,
815
- body: {
816
- backgroundColor: P.value.style.chart.backgroundColor,
817
- color: P.value.style.chart.color
818
- },
819
- head: {
820
- backgroundColor: P.value.style.chart.backgroundColor,
821
- color: P.value.style.chart.color
822
- }
823
- }
824
- }
825
- };
826
- });
827
- Je(() => V.value.showTable, (e) => {
828
- P.value.table.show || (e && P.value.table.useDialog && Qt.value ? Qt.value.open() : "close" in Qt.value && Qt.value.close());
829
- });
830
- function rr() {
831
- V.value.showTable = !1, $t.value && $t.value.setTableIconState(!1);
832
- }
833
- let ir = d(() => P.value.style.chart.backgroundColor), ar = d(() => P.value.style.chart.legend), { exportSvg: or, getSvg: sr } = ye({
834
- svg: L,
835
- title: d(() => P.value.style.chart.title),
836
- legend: ar,
837
- legendItems: d(() => Un.value.flat().map((e) => ({
838
- ...e,
839
- name: e.svgDisplay
840
- }))),
841
- backgroundColor: ir
842
- });
843
- async function cr({ isCb: e }) {
844
- tn.value = !0, await Be();
845
- try {
846
- if (e) {
847
- let { blob: e, url: t, text: n, dataUrl: r } = await sr();
848
- await Promise.resolve(P.value.userOptions.callbacks.svg({
849
- blob: e,
850
- url: t,
851
- text: n,
852
- dataUrl: r
853
- }));
854
- } else await Promise.resolve(or());
855
- } finally {
856
- tn.value = !1;
857
- }
858
- }
859
- function lr(e) {
860
- if (e?.stage === "start") {
861
- en.value = !0;
862
- return;
863
- }
864
- if (e?.stage === "end") {
865
- en.value = !1;
866
- return;
867
- }
868
- Sn();
869
- }
870
- async function ur() {
871
- if (U("copyAlt", {
872
- config: P.value,
873
- dataset: J.value
874
- }), !P.value.userOptions.callbacks.altCopy) {
875
- console.warn("Vue Data UI - A callback must be set for `altCopy` in userOptions.");
876
- return;
877
- }
878
- await Promise.resolve(P.value.userOptions.callbacks.altCopy({
879
- config: P.value,
880
- dataset: J.value
881
- }));
882
- }
883
- let $ = d(() => X.value.flatMap((e) => e.donut.filter((e) => !e.ghost)));
884
- function dr() {
885
- M.value = null, an.value = !0;
886
- }
887
- function fr() {
888
- M.value = null, rn.value = "pointer", zt.value = !1, Fn.value = null, Vt.value = null, In.value = null, Z.value = null, an.value = !1;
889
- }
890
- function pr(e) {
891
- if (!L.value || Zn.value || document.activeElement !== L.value || !$.value.length) return;
892
- let t = ["ArrowLeft", "ArrowUp"].includes(e.key), n = ["ArrowRight", "ArrowDown"].includes(e.key), r = e.key === "Enter" || e.key === " ", i = e.key === "Escape";
893
- if (!t && !n && !r && !i) return;
894
- if (e.preventDefault(), e.stopPropagation(), i) {
895
- M.value = null, rn.value = "pointer", zt.value = !1, Fn.value = null, Vt.value = null, In.value = null, Z.value = null;
896
- return;
897
- }
898
- if (r) {
899
- if (M.value === null) return;
900
- let e = $.value[M.value];
901
- if (!e) return;
902
- Tn({
903
- datapoint: e,
904
- index: M.value,
905
- seriesIndex: e.seriesIndex
906
- });
907
- return;
908
- }
909
- let a = M.value, o = Z.value, s = a !== null && a >= 0 && a < $.value.length, c = o !== null && o >= 0 && o < $.value.length;
910
- s ? n ? (a += 1, a >= $.value.length && (a = 0)) : t && (--a, a < 0 && (a = $.value.length - 1)) : c ? (a = n ? o + 1 : o - 1, a >= $.value.length && (a = 0), a < 0 && (a = $.value.length - 1)) : a = n ? 0 : $.value.length - 1;
911
- let l = $.value[a];
912
- l && (M.value = a, mr(), Bn({
913
- datapoint: l,
914
- relativeIndex: a,
915
- seriesIndex: l.seriesIndex,
916
- show: !0,
917
- triggerMode: "keyboard"
918
- }));
919
- }
920
- function mr() {
921
- if (!L.value) return;
922
- let e = L.value.getBoundingClientRect();
923
- nn.value = {
924
- x: e.left + e.width / 2,
925
- y: e.top + e.height / 2
926
- };
927
- }
928
- let hr = d(() => ({
929
- headers: Kn.value?.colNames ?? [],
930
- rows: Kn.value?.a11yBody ?? []
931
- }));
932
- return we({
933
- autoSize: tr,
934
- getData: qn,
935
- getImage: $n,
936
- generatePdf: xn,
937
- generateCsv: Gn,
938
- generateImage: Sn,
939
- generateSvg: cr,
940
- hideSeries: jn,
941
- showSeries: An,
942
- toggleTable: Jn,
943
- toggleLabels: Yn,
944
- toggleTooltip: Xn,
945
- toggleAnnotator: Qn,
946
- toggleFullscreen: on,
947
- copyAlt: ur
948
- }), (e, t) => (b(), m("div", {
949
- ref_key: "nestedDonutsChart",
950
- ref: k,
951
- class: v(`vue-data-ui-component vue-ui-nested-donuts ${N.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${P.value.useCssAnimation ? "" : "vue-ui-dna"}`),
952
- style: Ve(`font-family:${P.value.style.fontFamily};width:100%; text-align:center;background:${P.value.style.chart.backgroundColor}`),
953
- id: `nested_donuts_${O.value}`,
954
- onMouseenter: t[2] ||= () => T(fn)(!0),
955
- onMouseleave: t[3] ||= () => T(fn)(!1)
956
- }, [
957
- h("div", {
958
- id: `chart-instructions-${O.value}`,
959
- class: "sr-only"
960
- }, [h("p", null, w(P.value.a11y.translations.keyboardNavigation), 1)], 8, Qe),
961
- hr.value?.rows?.length ? (b(), f(ke, {
962
- key: 0,
963
- uid: O.value,
964
- head: hr.value.headers,
965
- body: hr.value.rows,
966
- notice: P.value.a11y.translations.tableAvailable,
967
- caption: P.value.a11y.translations.tableCaption
968
- }, null, 8, [
969
- "uid",
970
- "head",
971
- "body",
972
- "notice",
973
- "caption"
974
- ])) : p("", !0),
975
- P.value.userOptions.buttons.annotator ? (b(), f(T(Mt), {
976
- key: 1,
977
- svgRef: T(L),
978
- backgroundColor: P.value.style.chart.backgroundColor,
979
- color: P.value.style.chart.color,
980
- active: Zn.value,
981
- isCursorPointer: F.value,
982
- onClose: Qn
983
- }, {
984
- "annotator-action-close": E(() => [C(e.$slots, "annotator-action-close", {}, void 0, !0)]),
985
- "annotator-action-color": E(({ color: t }) => [C(e.$slots, "annotator-action-color", y(_({ color: t })), void 0, !0)]),
986
- "annotator-action-draw": E(({ mode: t }) => [C(e.$slots, "annotator-action-draw", y(_({ mode: t })), void 0, !0)]),
987
- "annotator-action-undo": E(({ disabled: t }) => [C(e.$slots, "annotator-action-undo", y(_({ disabled: t })), void 0, !0)]),
988
- "annotator-action-redo": E(({ disabled: t }) => [C(e.$slots, "annotator-action-redo", y(_({ disabled: t })), void 0, !0)]),
989
- "annotator-action-delete": E(({ disabled: t }) => [C(e.$slots, "annotator-action-delete", y(_({ disabled: t })), void 0, !0)]),
990
- _: 3
991
- }, 8, [
992
- "svgRef",
993
- "backgroundColor",
994
- "color",
995
- "active",
996
- "isCursorPointer"
997
- ])) : p("", !0),
998
- Cn.value ? (b(), m("div", {
999
- key: 2,
1000
- ref_key: "noTitle",
1001
- ref: Kt,
1002
- class: "vue-data-ui-no-title-space",
1003
- style: "height:36px; width: 100%;background:transparent"
1004
- }, null, 512)) : p("", !0),
1005
- P.value.style.chart.title.text ? (b(), m("div", {
1006
- key: 3,
1007
- ref_key: "chartTitle",
1008
- ref: Ut
1009
- }, [(b(), f(Ce, {
1010
- key: `title_${qt.value}`,
1011
- config: {
1012
- title: {
1013
- cy: "donut-div-title",
1014
- ...P.value.style.chart.title
1015
- },
1016
- subtitle: {
1017
- cy: "donut-div-subtitle",
1018
- ...P.value.style.chart.title.subtitle
1019
- }
1020
- }
1021
- }, null, 8, ["config"]))], 512)) : p("", !0),
1022
- h("div", { id: `legend-top-${O.value}` }, null, 8, $e),
1023
- P.value.userOptions.show && Rt.value && (T(pn) || T(dn)) ? (b(), f(T(jt), {
1024
- ref_key: "userOptionsRef",
1025
- ref: $t,
1026
- key: `user_option_${Ht.value}`,
1027
- backgroundColor: P.value.style.chart.backgroundColor,
1028
- color: P.value.style.chart.color,
1029
- isPrinting: T(yn),
1030
- isImaging: T(bn),
1031
- uid: O.value,
1032
- hasTooltip: P.value.userOptions.buttons.tooltip && P.value.style.chart.tooltip.show,
1033
- hasPdf: P.value.userOptions.buttons.pdf,
1034
- hasXls: P.value.userOptions.buttons.csv,
1035
- hasImg: P.value.userOptions.buttons.img,
1036
- hasSvg: P.value.userOptions.buttons.svg,
1037
- hasTable: P.value.userOptions.buttons.table,
1038
- hasLabel: P.value.userOptions.buttons.labels,
1039
- hasFullscreen: P.value.userOptions.buttons.fullscreen,
1040
- hasAltCopy: P.value.userOptions.buttons.altCopy,
1041
- isFullscreen: N.value,
1042
- isTooltip: V.value.showTooltip,
1043
- titles: { ...P.value.userOptions.buttonTitles },
1044
- chartElement: k.value,
1045
- position: P.value.userOptions.position,
1046
- hasAnnotator: P.value.userOptions.buttons.annotator,
1047
- isAnnotation: Zn.value,
1048
- callbacks: P.value.userOptions.callbacks,
1049
- printScale: P.value.userOptions.print.scale,
1050
- tableDialog: P.value.table.useDialog,
1051
- isCursorPointer: F.value,
1052
- onToggleFullscreen: on,
1053
- onGeneratePdf: T(xn),
1054
- onGenerateCsv: Gn,
1055
- onGenerateImage: lr,
1056
- onGenerateSvg: cr,
1057
- onToggleTable: Jn,
1058
- onToggleLabels: Yn,
1059
- onToggleTooltip: Xn,
1060
- onToggleAnnotator: Qn,
1061
- onCopyAlt: ur,
1062
- style: Ve({ visibility: T(pn) ? T(dn) ? "visible" : "hidden" : "visible" })
1063
- }, Ie({ _: 2 }, [
1064
- e.$slots.menuIcon ? {
1065
- name: "menuIcon",
1066
- fn: E(({ isOpen: t, color: n }) => [C(e.$slots, "menuIcon", y(_({
1067
- isOpen: t,
1068
- color: n
1069
- })), void 0, !0)]),
1070
- key: "0"
1071
- } : void 0,
1072
- e.$slots.optionTooltip ? {
1073
- name: "optionTooltip",
1074
- fn: E(() => [C(e.$slots, "optionTooltip", {}, void 0, !0)]),
1075
- key: "1"
1076
- } : void 0,
1077
- e.$slots.optionPdf ? {
1078
- name: "optionPdf",
1079
- fn: E(() => [C(e.$slots, "optionPdf", {}, void 0, !0)]),
1080
- key: "2"
1081
- } : void 0,
1082
- e.$slots.optionCsv ? {
1083
- name: "optionCsv",
1084
- fn: E(() => [C(e.$slots, "optionCsv", {}, void 0, !0)]),
1085
- key: "3"
1086
- } : void 0,
1087
- e.$slots.optionImg ? {
1088
- name: "optionImg",
1089
- fn: E(() => [C(e.$slots, "optionImg", {}, void 0, !0)]),
1090
- key: "4"
1091
- } : void 0,
1092
- e.$slots.optionSvg ? {
1093
- name: "optionSvg",
1094
- fn: E(() => [C(e.$slots, "optionSvg", {}, void 0, !0)]),
1095
- key: "5"
1096
- } : void 0,
1097
- e.$slots.optionTable ? {
1098
- name: "optionTable",
1099
- fn: E(() => [C(e.$slots, "optionTable", {}, void 0, !0)]),
1100
- key: "6"
1101
- } : void 0,
1102
- e.$slots.optionLabels ? {
1103
- name: "optionLabels",
1104
- fn: E(() => [C(e.$slots, "optionLabels", {}, void 0, !0)]),
1105
- key: "7"
1106
- } : void 0,
1107
- e.$slots.optionFullscreen ? {
1108
- name: "optionFullscreen",
1109
- fn: E(({ toggleFullscreen: t, isFullscreen: n }) => [C(e.$slots, "optionFullscreen", y(_({
1110
- toggleFullscreen: t,
1111
- isFullscreen: n
1112
- })), void 0, !0)]),
1113
- key: "8"
1114
- } : void 0,
1115
- e.$slots.optionAnnotator ? {
1116
- name: "optionAnnotator",
1117
- fn: E(({ toggleAnnotator: t, isAnnotator: n }) => [C(e.$slots, "optionAnnotator", y(_({
1118
- toggleAnnotator: t,
1119
- isAnnotator: n
1120
- })), void 0, !0)]),
1121
- key: "9"
1122
- } : void 0,
1123
- e.$slots.optionAltCopy ? {
1124
- name: "optionAltCopy",
1125
- fn: E(({ altCopy: t }) => [C(e.$slots, "optionAltCopy", y(_({ altCopy: t })), void 0, !0)]),
1126
- key: "10"
1127
- } : void 0,
1128
- e.$slots["custom-menu-before"] ? {
1129
- name: "custom-menu-before",
1130
- fn: E(() => [C(e.$slots, "custom-menu-before", {}, void 0, !0)]),
1131
- key: "11"
1132
- } : void 0,
1133
- e.$slots["custom-menu-after"] ? {
1134
- name: "custom-menu-after",
1135
- fn: E(() => [C(e.$slots, "custom-menu-after", {}, void 0, !0)]),
1136
- key: "12"
1137
- } : void 0
1138
- ]), 1032, /* @__PURE__ */ "backgroundColor.color.isPrinting.isImaging.uid.hasTooltip.hasPdf.hasXls.hasImg.hasSvg.hasTable.hasLabel.hasFullscreen.hasAltCopy.isFullscreen.isTooltip.titles.chartElement.position.hasAnnotator.isAnnotation.callbacks.printScale.tableDialog.isCursorPointer.onGeneratePdf.style".split("."))) : p("", !0),
1139
- h("div", et, [(b(), m("svg", {
1140
- ref_key: "svgRef",
1141
- ref: L,
1142
- xmlns: T(de),
1143
- "aria-describedby": `chart-instructions-${O.value}`,
1144
- class: v({
1145
- "vue-data-ui-fullscreen--on": N.value,
1146
- "vue-data-ui-fulscreen--off": !N.value,
1147
- "vue-data-ui-svg": !0
1148
- }),
1149
- viewBox: `0 0 ${H.value.width <= 0 ? .001 : H.value.width} ${H.value.height < 0 ? .001 : H.value.height}`,
1150
- style: Ve(`max-width:100%; overflow: visible; background:transparent;color:${P.value.style.chart.color};${hn.value.css}`),
1151
- tabindex: "0",
1152
- onFocus: dr,
1153
- onBlur: fr,
1154
- onKeydown: pr
1155
- }, [h("g", {
1156
- ref_key: "G",
1157
- ref: er,
1158
- class: "vue-data-ui-g"
1159
- }, [
1160
- Re(T(Nt)),
1161
- e.$slots["chart-background"] ? (b(), m("foreignObject", {
1162
- key: 0,
1163
- x: 0,
1164
- y: 0,
1165
- width: H.value.width <= 0 ? .001 : H.value.width,
1166
- height: H.value.height < 0 ? .001 : H.value.height,
1167
- style: { pointerEvents: "none" }
1168
- }, [C(e.$slots, "chart-background", {}, void 0, !0)], 8, nt)) : p("", !0),
1169
- h("defs", null, [(b(!0), m(u, null, S(Pn.value, (e, t) => (b(), f(De, {
1170
- t: "radial",
1171
- id: `radial_${O.value}_${t}`,
1172
- key: `radial_${O.value}_${t}`,
1173
- stops: [
1174
- [
1175
- "0%",
1176
- "#FFFFFF",
1177
- 0
1178
- ],
1179
- [
1180
- `${(1 - Mn.value / Nn.value[t]) * 100}%`,
1181
- T(ee)("#FFFFFF", 0),
1182
- 0
1183
- ],
1184
- [
1185
- `${(1 - Mn.value / Nn.value[t] / 2) * 100}%`,
1186
- "#FFFFFF",
1187
- P.value.style.chart.gradientIntensity / 100
1188
- ],
1189
- [
1190
- "100%",
1191
- "#FFFFFF",
1192
- 0
1193
- ]
1194
- ]
1195
- }, null, 8, ["id", "stops"]))), 128))]),
1196
- h("defs", null, [h("filter", {
1197
- id: `blur_${O.value}`,
1198
- x: "-50%",
1199
- y: "-50%",
1200
- width: "200%",
1201
- height: "200%"
1202
- }, [h("feGaussianBlur", {
1203
- in: "SourceGraphic",
1204
- stdDeviation: 2,
1205
- id: `blur_std_${O.value}`
1206
- }, null, 8, it), t[4] ||= h("feColorMatrix", {
1207
- type: "saturate",
1208
- values: "0"
1209
- }, null, -1)], 8, rt), h("filter", {
1210
- id: `shadow_${O.value}`,
1211
- "color-interpolation-filters": "sRGB"
1212
- }, [h("feDropShadow", {
1213
- dx: "0",
1214
- dy: "0",
1215
- stdDeviation: "10",
1216
- "flood-opacity": "0.5",
1217
- "flood-color": P.value.style.chart.layout.donut.shadowColor
1218
- }, null, 8, ot)], 8, at)]),
1219
- h("defs", null, [(b(!0), m(u, null, S(X.value, (e, t) => (b(), m("path", {
1220
- key: `path-full-${t}`,
1221
- id: `path-full-${t}-${O.value}`,
1222
- d: e.fullCirclePath,
1223
- fill: "none"
1224
- }, null, 8, st))), 128))]),
1225
- (b(!0), m(u, null, S(X.value, (e, t) => (b(), m("g", null, [e.hasData ? (b(!0), m(u, { key: 0 }, S(e.donut.filter((e) => !e.ghost), (e, t) => (b(), m("g", null, [h("path", {
1226
- class: "vue-ui-donut-arc-path",
1227
- d: e.arcSlice,
1228
- fill: e.color,
1229
- stroke: P.value.style.chart.layout.donut.borderColorAuto ? P.value.style.chart.backgroundColor : P.value.style.chart.layout.donut.borderColor,
1230
- "stroke-width": P.value.style.chart.layout.donut.borderWidth,
1231
- filter: Hn(e, t)
1232
- }, null, 8, ct)]))), 256)) : (b(!0), m(u, { key: 1 }, S(e.skeleton, (e, t) => (b(), m("g", null, [h("path", {
1233
- class: "vue-ui-donut-arc-path",
1234
- d: e.arcSlice,
1235
- fill: e.color,
1236
- stroke: P.value.style.chart.layout.donut.borderColorAuto ? P.value.style.chart.backgroundColor : P.value.style.chart.layout.donut.borderColor,
1237
- "stroke-width": P.value.style.chart.layout.donut.borderWidth
1238
- }, null, 8, lt)]))), 256))]))), 256)),
1239
- P.value.style.chart.useGradient ? (b(), m("g", ut, [(b(!0), m(u, null, S(Pn.value, (e, t) => (b(), m("g", null, [h("path", {
1240
- d: e.donut.arcSlice,
1241
- fill: `url(#radial_${O.value}_${t})`,
1242
- stroke: "transparent",
1243
- "stroke-width": "0"
1244
- }, null, 8, dt)]))), 256))])) : p("", !0),
1245
- P.value.style.chart.layout.labels.dataLabels.showDonutName ? (b(), m("g", ft, [P.value.style.chart.layout.labels.dataLabels.curvedDonutName ? (b(!0), m(u, { key: 0 }, S(X.value, (e, t) => (b(), m("g", null, [(b(!0), m(u, null, S(e.donut, (n, r) => (b(), m("g", null, [r === 0 && H.value.width && H.value.height ? (b(), m("text", {
1246
- key: 0,
1247
- class: v({ animated: P.value.useCssAnimation }),
1248
- "text-anchor": "middle",
1249
- "font-size": P.value.style.chart.layout.labels.dataLabels.fontSize,
1250
- "font-weight": P.value.style.chart.layout.labels.dataLabels.boldDonutName ? "bold" : "normal",
1251
- fill: P.value.style.chart.layout.labels.dataLabels.color,
1252
- dy: P.value.style.chart.layout.labels.dataLabels.donutNameOffsetY
1253
- }, [h("textPath", {
1254
- href: `#path-full-${t}-${O.value}`,
1255
- startOffset: "50%",
1256
- "text-anchor": "middle",
1257
- method: "align",
1258
- spacing: "auto"
1259
- }, w(P.value.style.chart.layout.labels.dataLabels.donutNameAbbreviation ? T(le)({
1260
- source: e.name,
1261
- length: P.value.style.chart.layout.labels.dataLabels.donutNameMaxAbbreviationSize
1262
- }) : e.name), 9, mt)], 10, pt)) : p("", !0)]))), 256))]))), 256)) : (b(!0), m(u, { key: 1 }, S(X.value, (e, t) => (b(), m("g", null, [(b(!0), m(u, null, S(e.donut, (t, n) => (b(), m("g", null, [n === 0 && H.value.width && H.value.height ? (b(), m("text", {
1263
- key: 0,
1264
- class: v({ animated: P.value.useCssAnimation }),
1265
- x: H.value.width / 2,
1266
- y: t.startY - P.value.style.chart.layout.labels.dataLabels.fontSize + P.value.style.chart.layout.labels.dataLabels.donutNameOffsetY,
1267
- "text-anchor": "middle",
1268
- "font-size": P.value.style.chart.layout.labels.dataLabels.fontSize,
1269
- "font-weight": P.value.style.chart.layout.labels.dataLabels.boldDonutName ? "bold" : "normal",
1270
- fill: P.value.style.chart.layout.labels.dataLabels.color
1271
- }, w(P.value.style.chart.layout.labels.dataLabels.donutNameAbbreviation ? T(le)({
1272
- source: e.name,
1273
- length: P.value.style.chart.layout.labels.dataLabels.donutNameMaxAbbreviationSize
1274
- }) : e.name), 11, ht)) : p("", !0)]))), 256))]))), 256))])) : p("", !0),
1275
- P.value.style.chart.layout.labels.dataLabels.show ? (b(), m("g", gt, [(b(!0), m(u, null, S(X.value, (e, t) => (b(), m("g", null, [(b(!0), m(u, null, S(e.donut.filter((e) => !e.ghost), (e, n) => (b(), m("g", { filter: Hn(e, n) }, [Ye(h("text", {
1276
- class: v({ animated: P.value.useCssAnimation }),
1277
- opacity: +!!Vn(e),
1278
- "text-anchor": T(fe)(e, !0).anchor,
1279
- x: T(fe)(e, !1, P.value.style.chart.layout.labels.dataLabels.offsetX).x || 0,
1280
- y: T(oe)(e, P.value.style.chart.layout.labels.dataLabels.offsetY, P.value.style.chart.layout.labels.dataLabels.offsetY) + (P.value.style.chart.layout.labels.dataLabels.showValueFirst && P.value.style.chart.layout.labels.dataLabels.showValue ? P.value.style.chart.layout.labels.dataLabels.fontSize : 0),
1281
- fill: P.value.style.chart.layout.labels.dataLabels.useSerieColor ? e.color : P.value.style.chart.layout.labels.dataLabels.color,
1282
- "font-size": P.value.style.chart.layout.labels.dataLabels.fontSize,
1283
- "font-weight": P.value.style.chart.layout.labels.dataLabels.boldPercentage ? "bold" : "normal"
1284
- }, w(T(c)(T(a)({
1285
- v: e.proportion * 100,
1286
- s: "%",
1287
- r: P.value.style.chart.layout.labels.dataLabels.roundingPercentage
1288
- }), P.value.style.chart.layout.labels.dataLabels.usePercentageParens ? "(" : "", P.value.style.chart.layout.labels.dataLabels.usePercentageParens ? ")" : "")), 11, vt), [[qe, V.value.dataLabels.show && P.value.style.chart.layout.labels.dataLabels.showPercentage]]), Ye(h("text", {
1289
- class: v({ animated: P.value.useCssAnimation }),
1290
- opacity: +!!Vn(e),
1291
- "text-anchor": T(fe)(e, !0).anchor,
1292
- x: T(fe)(e, !1, P.value.style.chart.layout.labels.dataLabels.offsetX).x || 0,
1293
- y: T(oe)(e, P.value.style.chart.layout.labels.dataLabels.offsetY, P.value.style.chart.layout.labels.dataLabels.offsetY) + (P.value.style.chart.layout.labels.dataLabels.showValueFirst || !P.value.style.chart.layout.labels.dataLabels.showPercentage ? 0 : P.value.style.chart.layout.labels.dataLabels.fontSize),
1294
- fill: P.value.style.chart.layout.labels.dataLabels.useSerieColor ? e.color : P.value.style.chart.layout.labels.dataLabels.color,
1295
- "font-size": P.value.style.chart.layout.labels.dataLabels.fontSize,
1296
- "font-weight": P.value.style.chart.layout.labels.dataLabels.boldValue ? "bold" : "normal"
1297
- }, w(T(c)(T(se)(P.value.style.chart.layout.labels.dataLabels.formatter, e.value, T(a)({
1298
- p: P.value.style.chart.layout.labels.dataLabels.prefix,
1299
- v: e.value,
1300
- s: P.value.style.chart.layout.labels.dataLabels.suffix,
1301
- r: P.value.style.chart.layout.labels.dataLabels.roundingValue
1302
- }), {
1303
- datapoint: e,
1304
- seriesIndex: t,
1305
- datapointIndex: n
1306
- }), P.value.style.chart.layout.labels.dataLabels.useValueParens ? "(" : "", P.value.style.chart.layout.labels.dataLabels.useValueParens ? ")" : "")), 11, yt), [[qe, V.value.dataLabels.show && P.value.style.chart.layout.labels.dataLabels.showValue]])], 8, _t))), 256))]))), 256))])) : p("", !0),
1307
- (b(!0), m(u, null, S(X.value, (e, t) => (b(), m("g", null, [(b(!0), m(u, null, S(e.donut, (e, t) => (b(), m("g", null, [h("path", {
1308
- d: e.arcSlice,
1309
- fill: Vt.value === e.id ? P.value.style.chart.layout.donut.selectedColor : "transparent",
1310
- onMouseenter: (t) => Bn({
1311
- datapoint: e,
1312
- relativeIndex: $.value.findIndex((t) => t.id === e.id),
1313
- seriesIndex: e.seriesIndex
1314
- }),
1315
- onClick: (n) => Tn({
1316
- datapoint: e,
1317
- index: t,
1318
- seriesIndex: e.seriesIndex
1319
- }),
1320
- onMouseleave: (t) => Rn({
1321
- datapoint: e,
1322
- seriesIndex: e.seriesIndex
1323
- })
1324
- }, null, 40, bt)]))), 256))]))), 256)),
1325
- C(e.$slots, "svg", { svg: {
1326
- ...H.value,
1327
- isPrintingImg: T(yn) || T(bn) || en.value,
1328
- isPrintingSvg: tn.value
1329
- } }, void 0, !0)
1330
- ], 512)], 46, tt)), e.$slots.hint ? (b(), m("div", xt, [C(e.$slots, "hint", y(_({
1331
- hint: P.value.a11y.translations.keyboardNavigation,
1332
- isVisible: an.value
1333
- })), void 0, !0)])) : p("", !0)]),
1334
- e.$slots.watermark ? (b(), m("div", St, [C(e.$slots, "watermark", y(_({ isPrinting: T(yn) || T(bn) || en.value || tn.value })), void 0, !0)])) : p("", !0),
1335
- Re(T(Dt), {
1336
- teleportTo: P.value.style.chart.tooltip.teleportTo,
1337
- show: V.value.showTooltip && zt.value,
1338
- backgroundColor: P.value.style.chart.tooltip.backgroundColor,
1339
- color: P.value.style.chart.tooltip.color,
1340
- borderRadius: P.value.style.chart.tooltip.borderRadius,
1341
- borderColor: P.value.style.chart.tooltip.borderColor,
1342
- borderWidth: P.value.style.chart.tooltip.borderWidth,
1343
- fontSize: P.value.style.chart.tooltip.fontSize,
1344
- backgroundOpacity: P.value.style.chart.tooltip.backgroundOpacity,
1345
- position: P.value.style.chart.tooltip.position,
1346
- offsetX: P.value.style.chart.tooltip.offsetX,
1347
- offsetY: P.value.style.chart.tooltip.offsetY,
1348
- parent: k.value,
1349
- content: Bt.value,
1350
- isFullscreen: N.value,
1351
- isCustom: T(me)(P.value.style.chart.tooltip.customFormat),
1352
- smooth: P.value.style.chart.tooltip.smooth,
1353
- backdropFilter: P.value.style.chart.tooltip.backdropFilter,
1354
- smoothForce: P.value.style.chart.tooltip.smoothForce,
1355
- smoothSnapThreshold: P.value.style.chart.tooltip.smoothSnapThreshold,
1356
- isA11yMode: rn.value === "keyboard",
1357
- a11yPosition: nn.value
1358
- }, {
1359
- "tooltip-before": E(() => [C(e.$slots, "tooltip-before", y(_({ ...Ln.value })), void 0, !0)]),
1360
- tooltip: E(() => [C(e.$slots, "tooltip", y(_({ ...Ln.value })), void 0, !0)]),
1361
- "tooltip-after": E(() => [C(e.$slots, "tooltip-after", y(_({ ...Ln.value })), void 0, !0)]),
1362
- _: 3
1363
- }, 8, [
1364
- "teleportTo",
1365
- "show",
1366
- "backgroundColor",
1367
- "color",
1368
- "borderRadius",
1369
- "borderColor",
1370
- "borderWidth",
1371
- "fontSize",
1372
- "backgroundOpacity",
1373
- "position",
1374
- "offsetX",
1375
- "offsetY",
1376
- "parent",
1377
- "content",
1378
- "isFullscreen",
1379
- "isCustom",
1380
- "smooth",
1381
- "backdropFilter",
1382
- "smoothForce",
1383
- "smoothSnapThreshold",
1384
- "isA11yMode",
1385
- "a11yPosition"
1386
- ]),
1387
- h("div", { id: `legend-bottom-${O.value}` }, null, 8, Ct),
1388
- Zt.value && (P.value.style.chart.legend.show || e.$slots.legend) ? (b(), f(Fe, {
1389
- key: 6,
1390
- to: P.value.style.chart.legend.position === "top" ? `#legend-top-${O.value}` : `#legend-bottom-${O.value}`
1391
- }, [P.value.style.chart.legend.show ? (b(), m("div", {
1392
- key: 0,
1393
- ref_key: "chartLegend",
1394
- ref: Wt,
1395
- class: v({ "vue-ui-nested-donuts-legend": Un.value.length > 1 })
1396
- }, [C(e.$slots, "legend", { legend: Un.value }, () => [(b(!0), m(u, null, S(Un.value, (e, n) => (b(), f(Ne, {
1397
- key: `legend_${n}_${Yt.value}`,
1398
- legendSet: e,
1399
- config: Wn.value,
1400
- isCursorPointer: F.value,
1401
- onClickMarker: t[0] ||= ({ legend: e }) => Y(e)
1402
- }, {
1403
- legendTitle: E(({ titleSet: e }) => [e[0] && e[0].arcOf ? (b(), m("div", wt, w(e[0].arcOf), 1)) : p("", !0)]),
1404
- item: E(({ legend: e, index: t }) => [h("div", {
1405
- onClick: (t) => Y(e),
1406
- style: Ve(`opacity:${W.value.includes(e.id) ? .5 : 1}`)
1407
- }, w(e.display), 13, Tt)]),
1408
- legendToggle: E(() => [e.length > 2 && P.value.style.chart.legend.selectAllToggle.show && !T(ln) ? (b(), f(Oe, {
1409
- key: `toggle-${n}`,
1410
- backgroundColor: P.value.style.chart.legend.selectAllToggle.backgroundColor,
1411
- color: P.value.style.chart.legend.selectAllToggle.color,
1412
- fontSize: P.value.style.chart.legend.fontSize,
1413
- checked: e.some((e) => W.value.includes(e.id)),
1414
- isCursorPointer: F.value,
1415
- onToggle: (t) => On(e)
1416
- }, null, 8, [
1417
- "backgroundColor",
1418
- "color",
1419
- "fontSize",
1420
- "checked",
1421
- "isCursorPointer",
1422
- "onToggle"
1423
- ])) : p("", !0)]),
1424
- _: 2
1425
- }, 1032, [
1426
- "legendSet",
1427
- "config",
1428
- "isCursorPointer"
1429
- ]))), 128))], !0)], 2)) : p("", !0)], 8, ["to"])) : p("", !0),
1430
- e.$slots.source ? (b(), m("div", {
1431
- key: 7,
1432
- ref_key: "source",
1433
- ref: Gt,
1434
- dir: "auto"
1435
- }, [C(e.$slots, "source", {}, void 0, !0)], 512)) : p("", !0),
1436
- Rt.value && P.value.userOptions.buttons.table ? (b(), f(We(nr.value.component), ze({ key: 8 }, nr.value.props, {
1437
- ref_key: "tableUnit",
1438
- ref: Qt,
1439
- onClose: rr
1440
- }), Ie({
1441
- content: E(() => [(b(), f(T(At), {
1442
- key: `table_${Jt.value}`,
1443
- colNames: Kn.value.colNames,
1444
- head: Kn.value.head,
1445
- body: Kn.value.body,
1446
- config: Kn.value.config,
1447
- title: P.value.table.useDialog ? "" : nr.value.title,
1448
- withCloseButton: !P.value.table.useDialog,
1449
- isCursorPointer: F.value,
1450
- onClose: rr
1451
- }, {
1452
- th: E(({ th: e }) => [h("div", {
1453
- innerHTML: e,
1454
- style: {
1455
- display: "flex",
1456
- "align-items": "center"
1457
- }
1458
- }, null, 8, Et)]),
1459
- td: E(({ td: e }) => [Le(w(e.name || e), 1)]),
1460
- _: 1
1461
- }, 8, [
1462
- "colNames",
1463
- "head",
1464
- "body",
1465
- "config",
1466
- "title",
1467
- "withCloseButton",
1468
- "isCursorPointer"
1469
- ]))]),
1470
- _: 2
1471
- }, [P.value.table.useDialog ? {
1472
- name: "title",
1473
- fn: E(() => [Le(w(nr.value.title), 1)]),
1474
- key: "0"
1475
- } : void 0, P.value.table.useDialog ? {
1476
- name: "actions",
1477
- fn: E(() => [h("button", {
1478
- tabindex: "0",
1479
- class: "vue-ui-user-options-button",
1480
- onClick: t[1] ||= (e) => Gn(P.value.userOptions.callbacks.csv),
1481
- style: Ve({ cursor: F.value ? "pointer" : "default" })
1482
- }, [Re(T(Ot), {
1483
- name: "fileCsv",
1484
- stroke: nr.value.props.color
1485
- }, null, 8, ["stroke"])], 4)]),
1486
- key: "1"
1487
- } : void 0]), 1040)) : p("", !0),
1488
- C(e.$slots, "skeleton", {}, () => [T(ln) ? (b(), f(ve, { key: 0 })) : p("", !0)], !0)
1489
- ], 46, Ze));
1490
- }
1491
- }, [["__scopeId", "data-v-24615b3d"]]);
1492
- //#endregion
1493
- export { Xe as n, Dt as t };