vue-data-ui 3.22.13 → 3.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (224) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +13 -1
  3. package/dist/{Arrow-DKx74WtM.js → Arrow-o2qHNvrC.js} +1 -1
  4. package/dist/{BaseDraggableDialog-3n8udWmh.js → BaseDraggableDialog-qTnfhLBz.js} +2 -2
  5. package/dist/{BaseIcon-CP5RWnqt.js → BaseIcon-91MZoczJ.js} +4 -3
  6. package/dist/{BaseLegendToggle-DsWphmIb.js → BaseLegendToggle-CtAPwzr2.js} +1 -1
  7. package/dist/{BaseZoomControls-C9_ygNN4.js → BaseZoomControls-rdzlicuz.js} +2 -2
  8. package/dist/{ColorPicker-3N_HVgXs.js → ColorPicker-CIAkdPrj.js} +2 -2
  9. package/dist/{DataTable-DzPEVvSo.js → DataTable-D4tM9s5Y.js} +2 -2
  10. package/dist/HillActions-BWhxHlrj.js +187 -0
  11. package/dist/{Legend-C0xAnJdO.js → Legend-CQTRlzK-.js} +2 -2
  12. package/dist/{NonSvgPenAndPaper-B_mE5UbR.js → NonSvgPenAndPaper-Cawacw1W.js} +19 -19
  13. package/dist/{PackageVersion-B6Hokxw9.js → PackageVersion--QCMh5k_.js} +1 -1
  14. package/dist/{PenAndPaper-CSMVXpg2.js → PenAndPaper-cE4J8-rA.js} +11 -11
  15. package/dist/{Shape-BfnXr1nJ.js → Shape-BPMV94Ij.js} +3 -3
  16. package/dist/{Slicer-C6qNUmZ4.js → Slicer-5yIrdoJv.js} +15 -15
  17. package/dist/SlicerPreview-DvjLV2TW.js +1689 -0
  18. package/dist/{SparkTooltip-uoUiL_P8.js → SparkTooltip-BaYtEKS6.js} +6 -6
  19. package/dist/Title-BODtwViI.js +87 -0
  20. package/dist/{Tooltip-CA1rtSyl.js → Tooltip-CMTGxeYO.js} +1 -1
  21. package/dist/{UserOptions-DzAFK9cY.js → UserOptions-3ujTo3LD.js} +2 -2
  22. package/dist/components/arrow.js +1 -1
  23. package/dist/components/vue-ui-3d-bar.js +1 -1
  24. package/dist/components/vue-ui-accordion.js +1 -1
  25. package/dist/components/vue-ui-age-pyramid.js +1 -1
  26. package/dist/components/vue-ui-annotator.js +1 -1
  27. package/dist/components/vue-ui-bullet.js +1 -1
  28. package/dist/components/vue-ui-bump.js +1 -1
  29. package/dist/components/vue-ui-candlestick.js +1 -1
  30. package/dist/components/vue-ui-carousel-table.js +1 -1
  31. package/dist/components/vue-ui-chestnut.js +1 -1
  32. package/dist/components/vue-ui-chord.js +1 -1
  33. package/dist/components/vue-ui-circle-pack.js +1 -1
  34. package/dist/components/vue-ui-cursor.js +1 -1
  35. package/dist/components/vue-ui-dag.js +1 -1
  36. package/dist/components/vue-ui-dashboard.js +1 -1
  37. package/dist/components/vue-ui-digits.js +1 -1
  38. package/dist/components/vue-ui-donut-evolution.js +1 -1
  39. package/dist/components/vue-ui-donut.js +1 -1
  40. package/dist/components/vue-ui-dumbbell.js +1 -1
  41. package/dist/components/vue-ui-flow.js +1 -1
  42. package/dist/components/vue-ui-funnel.js +1 -1
  43. package/dist/components/vue-ui-galaxy.js +1 -1
  44. package/dist/components/vue-ui-gauge.js +1 -1
  45. package/dist/components/vue-ui-geo.js +1 -1
  46. package/dist/components/vue-ui-gizmo.js +1 -1
  47. package/dist/components/vue-ui-heatmap.js +1 -1
  48. package/dist/components/vue-ui-hill.js +2 -0
  49. package/dist/components/vue-ui-history-plot.js +1 -1
  50. package/dist/components/vue-ui-horizontal-bar.js +1 -1
  51. package/dist/components/vue-ui-icon.js +1 -1
  52. package/dist/components/vue-ui-kpi.js +1 -1
  53. package/dist/components/vue-ui-mini-loader.js +1 -1
  54. package/dist/components/vue-ui-molecule.js +1 -1
  55. package/dist/components/vue-ui-mood-radar.js +1 -1
  56. package/dist/components/vue-ui-nested-donuts.js +1 -1
  57. package/dist/components/vue-ui-onion.js +1 -1
  58. package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
  59. package/dist/components/vue-ui-quadrant.js +1 -1
  60. package/dist/components/vue-ui-quick-chart.js +1 -1
  61. package/dist/components/vue-ui-radar.js +1 -1
  62. package/dist/components/vue-ui-rating.js +1 -1
  63. package/dist/components/vue-ui-relation-circle.js +1 -1
  64. package/dist/components/vue-ui-ridgeline.js +1 -1
  65. package/dist/components/vue-ui-rings.js +1 -1
  66. package/dist/components/vue-ui-scatter.js +1 -1
  67. package/dist/components/vue-ui-skeleton.js +1 -1
  68. package/dist/components/vue-ui-smiley.js +1 -1
  69. package/dist/components/vue-ui-spark-trend.js +1 -1
  70. package/dist/components/vue-ui-sparkbar.js +1 -1
  71. package/dist/components/vue-ui-sparkgauge.js +1 -1
  72. package/dist/components/vue-ui-sparkhistogram.js +1 -1
  73. package/dist/components/vue-ui-sparkline.js +1 -1
  74. package/dist/components/vue-ui-sparkstackbar.js +1 -1
  75. package/dist/components/vue-ui-stackbar.js +1 -1
  76. package/dist/components/vue-ui-stackline.js +1 -1
  77. package/dist/components/vue-ui-strip-plot.js +1 -1
  78. package/dist/components/vue-ui-table-heatmap.js +1 -1
  79. package/dist/components/vue-ui-table-sparkline.js +1 -1
  80. package/dist/components/vue-ui-table.js +1 -1
  81. package/dist/components/vue-ui-thermometer.js +1 -1
  82. package/dist/components/vue-ui-timer.js +1 -1
  83. package/dist/components/vue-ui-tiremarks.js +1 -1
  84. package/dist/components/vue-ui-treemap.js +1 -1
  85. package/dist/components/vue-ui-vertical-bar.js +1 -1
  86. package/dist/components/vue-ui-waffle.js +1 -1
  87. package/dist/components/vue-ui-wheel.js +1 -1
  88. package/dist/components/vue-ui-word-cloud.js +1 -1
  89. package/dist/components/vue-ui-world.js +1 -1
  90. package/dist/components/vue-ui-xy-canvas.js +1 -1
  91. package/dist/components/vue-ui-xy.js +1 -1
  92. package/dist/{dom-to-png-BdAFKZQg.js → dom-to-png-4tdMNGPX.js} +1 -1
  93. package/dist/exposedLib-DWLRqRhv.js +25 -0
  94. package/dist/{img-Bikk1dGb.js → img-DIQG5q8T.js} +1 -1
  95. package/dist/{labelUtils-BUhssos9.js → labelUtils-C5lnc_xc.js} +1 -1
  96. package/dist/{lib-CFm_J26b.js → lib-BuMGJ_a0.js} +216 -173
  97. package/dist/{package-DmDydylu.js → package-BMc_ZieJ.js} +1 -1
  98. package/dist/{pdf-zmz3l2uy.js → pdf-Cnz4NKM9.js} +1 -1
  99. package/dist/{render-common-BIG8JYGK.js → render-common-Ktg2LZFG.js} +21 -21
  100. package/dist/ssr/vue-ui-donut.js +1 -1
  101. package/dist/ssr/vue-ui-xy.js +1 -1
  102. package/dist/ssr.js +2 -2
  103. package/dist/style.css +1 -1
  104. package/dist/types/vue-data-ui.d.ts +493 -0
  105. package/dist/types/vue-ui-hill.d.ts +90 -0
  106. package/dist/useAutoSizeLabelsInsideViewbox-DvDwcwi_.js +122 -0
  107. package/dist/{useConfig-C0V0eG7L.js → useConfig-BilxnBNr.js} +767 -476
  108. package/dist/useHints-Dq_w2E8B.js +66 -0
  109. package/dist/{useNestedProp-BY6DNN3i.js → useNestedProp--NSEmhOH.js} +1 -1
  110. package/dist/{useObjectBindings-Djwpii4d.js → useObjectBindings-Cwq7NcQz.js} +3 -2
  111. package/dist/{usePrinter-BH-xle1O.js → usePrinter-BFvi4jVy.js} +2 -2
  112. package/dist/useTransitions-g_zBREk2.js +39 -0
  113. package/dist/utils.js +14 -14
  114. package/dist/{vue-data-ui-rkzh6EkO.js → vue-data-ui-EsawKe_W.js} +85 -81
  115. package/dist/vue-data-ui.js +77 -76
  116. package/dist/vue-ui-3d-bar-RSUS2xpL.js +1849 -0
  117. package/dist/{vue-ui-accordion-UA88lv4d.js → vue-ui-accordion-61MlW-Ge.js} +4 -4
  118. package/dist/vue-ui-age-pyramid-CgnPWA93.js +1263 -0
  119. package/dist/vue-ui-annotator-DBRT85HG.js +2913 -0
  120. package/dist/vue-ui-bullet-Bc3-WaN1.js +724 -0
  121. package/dist/{vue-ui-bump-BS7RCf0Z.js → vue-ui-bump-Dvv3iSKr.js} +332 -295
  122. package/dist/{vue-ui-candlestick-BZSGDKrM.js → vue-ui-candlestick-DvvsrIdp.js} +464 -440
  123. package/dist/vue-ui-carousel-table-DtsNVim8.js +463 -0
  124. package/dist/vue-ui-chestnut-ArloORzP.js +2068 -0
  125. package/dist/{vue-ui-chord-D6G7ceE-.js → vue-ui-chord-xX5gWZy8.js} +430 -424
  126. package/dist/vue-ui-circle-pack-D8wykmqg.js +1638 -0
  127. package/dist/{vue-ui-cursor-BpN5MsXM.js → vue-ui-cursor-CxgE6Phh.js} +61 -61
  128. package/dist/{vue-ui-dag-BzgOgXzU.js → vue-ui-dag-C9Sf9vH7.js} +924 -916
  129. package/dist/vue-ui-dashboard-bGmaglAj.js +520 -0
  130. package/dist/{vue-ui-digits-OMPrn8fb.js → vue-ui-digits-DgDE-_Fn.js} +58 -50
  131. package/dist/vue-ui-donut-B_n6wF6B.js +2440 -0
  132. package/dist/{vue-ui-donut-Cp5NbZ1r.js → vue-ui-donut-Bmo149AR.js} +113 -113
  133. package/dist/{vue-ui-donut-evolution-DHVi5rOn.js → vue-ui-donut-evolution-D6vH_hfx.js} +528 -447
  134. package/dist/vue-ui-dumbbell-BX4Ao_wR.js +1582 -0
  135. package/dist/{vue-ui-flow-BusUK3H0.js → vue-ui-flow-Bshw8pT_.js} +415 -407
  136. package/dist/vue-ui-funnel-CjYosIik.js +797 -0
  137. package/dist/vue-ui-galaxy-CvXgy-dy.js +1111 -0
  138. package/dist/vue-ui-gauge-CByT0_vF.js +953 -0
  139. package/dist/{vue-ui-geo-CyFgFKlh.js → vue-ui-geo-C-gSZL2q.js} +378 -363
  140. package/dist/{vue-ui-gizmo-DdeXwCQp.js → vue-ui-gizmo-CJdxyPID.js} +57 -49
  141. package/dist/{vue-ui-heatmap-D8-qJ7fg.js → vue-ui-heatmap-DEEKv8ip.js} +498 -490
  142. package/dist/vue-ui-hill-D7LYAgAL.js +1768 -0
  143. package/dist/{vue-ui-history-plot-C2Aqk2ON.js → vue-ui-history-plot-BhcU94Pt.js} +553 -556
  144. package/dist/vue-ui-horizontal-bar-CfFye5tL.js +1733 -0
  145. package/dist/vue-ui-kpi-DCBnNfTb.js +104 -0
  146. package/dist/vue-ui-mini-loader-CtWpqnLW.js +133 -0
  147. package/dist/vue-ui-molecule-D3igGyOy.js +958 -0
  148. package/dist/{vue-ui-mood-radar-BiOjxFEN.js → vue-ui-mood-radar-sl6DMxqR.js} +349 -341
  149. package/dist/{vue-ui-nested-donuts-Cl1HVvDp.js → vue-ui-nested-donuts-aS4YzaB3.js} +449 -413
  150. package/dist/vue-ui-onion-EhPTZpW_.js +1258 -0
  151. package/dist/vue-ui-parallel-coordinate-plot-DE9wTmQQ.js +1455 -0
  152. package/dist/{vue-ui-quadrant-B21LkUc8.js → vue-ui-quadrant-SaY_RPSE.js} +625 -617
  153. package/dist/vue-ui-quick-chart-CJ9rejnj.js +2389 -0
  154. package/dist/{vue-ui-radar-CyzAyVos.js → vue-ui-radar-CaNen5Fj.js} +356 -310
  155. package/dist/vue-ui-rating--K7rX2an.js +360 -0
  156. package/dist/vue-ui-relation-circle-FLs8vOxQ.js +925 -0
  157. package/dist/vue-ui-ridgeline-Beg5hshN.js +1663 -0
  158. package/dist/{vue-ui-rings-FtcdX8xl.js → vue-ui-rings-BevKD8P-.js} +449 -423
  159. package/dist/{vue-ui-scatter-Cp_-2ahf.js → vue-ui-scatter-CNA7jF-o.js} +721 -702
  160. package/dist/{vue-ui-skeleton-COytVrfN.js → vue-ui-skeleton-B9ZP1w-i.js} +395 -387
  161. package/dist/{vue-ui-smiley-Da2jgkb7.js → vue-ui-smiley-DYnqqk6u.js} +128 -120
  162. package/dist/{vue-ui-spark-trend-DC2KUlEY.js → vue-ui-spark-trend-R0ebpg-G.js} +132 -117
  163. package/dist/{vue-ui-sparkbar-DdxQOFIF.js → vue-ui-sparkbar-DYC3By0v.js} +119 -111
  164. package/dist/{vue-ui-sparkgauge-DTA-fORH.js → vue-ui-sparkgauge-Bw6no-In.js} +76 -68
  165. package/dist/vue-ui-sparkhistogram-DvRKy8rq.js +590 -0
  166. package/dist/{vue-ui-sparkline-DcR_N-zT.js → vue-ui-sparkline-Dz1uzBos.js} +389 -364
  167. package/dist/vue-ui-sparkstackbar-DlnPdZih.js +692 -0
  168. package/dist/vue-ui-stackbar-B-THcavY.js +2350 -0
  169. package/dist/vue-ui-stackline-3dBPoI0h.js +2464 -0
  170. package/dist/{vue-ui-strip-plot-NLCwYvyw.js → vue-ui-strip-plot-ACeYOoHj.js} +505 -484
  171. package/dist/vue-ui-table-heatmap-DVwMqzje.js +364 -0
  172. package/dist/{vue-ui-table-AM9brdwU.js → vue-ui-table-rFy16bp0.js} +512 -504
  173. package/dist/{vue-ui-table-sparkline-BE6DAvur.js → vue-ui-table-sparkline-CABJzK8p.js} +207 -181
  174. package/dist/vue-ui-thermometer-CVQ-H69Q.js +777 -0
  175. package/dist/{vue-ui-timer-BZM5ITG9.js → vue-ui-timer-Bm8LpsnI.js} +66 -58
  176. package/dist/{vue-ui-tiremarks-BCncDpHX.js → vue-ui-tiremarks-DB3f5qiz.js} +127 -119
  177. package/dist/vue-ui-treemap-DP0Sx8Y8.js +1760 -0
  178. package/dist/vue-ui-waffle-iPpdk1Bm.js +1412 -0
  179. package/dist/vue-ui-wheel-BJkEYfLj.js +892 -0
  180. package/dist/{vue-ui-word-cloud-D7R7nhk1.js → vue-ui-word-cloud-B2sxtel9.js} +440 -432
  181. package/dist/{vue-ui-world-DZBt-07p.js → vue-ui-world-BBQZLnzm.js} +343 -335
  182. package/dist/vue-ui-xy-ChZg7AtI.js +1364 -0
  183. package/dist/{vue-ui-xy-CluEZ7lS.js → vue-ui-xy-DZj5DT-q.js} +1633 -1587
  184. package/dist/{vue-ui-xy-canvas-7YSYRdwr.js → vue-ui-xy-canvas-BN2u0bOJ.js} +456 -430
  185. package/dist/vue_ui_hill-dnltu0L-.js +368 -0
  186. package/package.json +2 -2
  187. package/dist/SlicerPreview-Cw6WMVhG.js +0 -1689
  188. package/dist/Title-BuPs74IB.js +0 -87
  189. package/dist/exposedLib-Ciw6TGtP.js +0 -25
  190. package/dist/useAutoSizeLabelsInsideViewbox-C9RNjsGv.js +0 -50
  191. package/dist/useMountedDelay-BAjrhRJb.js +0 -14
  192. package/dist/vue-ui-3d-bar-D5xHEWr1.js +0 -1824
  193. package/dist/vue-ui-age-pyramid-CAJg01c7.js +0 -1246
  194. package/dist/vue-ui-annotator-q3ZKx6ua.js +0 -2905
  195. package/dist/vue-ui-bullet-ByeaWGfI.js +0 -709
  196. package/dist/vue-ui-carousel-table-DO5NRXvX.js +0 -455
  197. package/dist/vue-ui-chestnut-BfeSPeEh.js +0 -2042
  198. package/dist/vue-ui-circle-pack-Cqmlw7AV.js +0 -1610
  199. package/dist/vue-ui-dashboard-DLvGJXJY.js +0 -512
  200. package/dist/vue-ui-donut-ZIRebAWc.js +0 -2418
  201. package/dist/vue-ui-dumbbell-gDYjU2oF.js +0 -1564
  202. package/dist/vue-ui-funnel-BtaYaU0r.js +0 -781
  203. package/dist/vue-ui-galaxy-BMp-HzDh.js +0 -1076
  204. package/dist/vue-ui-gauge-CBou0cFE.js +0 -925
  205. package/dist/vue-ui-horizontal-bar-BuwxI7d1.js +0 -1689
  206. package/dist/vue-ui-kpi-ByxoO01r.js +0 -96
  207. package/dist/vue-ui-mini-loader-D9pprk2c.js +0 -125
  208. package/dist/vue-ui-molecule-BqJJq49_.js +0 -932
  209. package/dist/vue-ui-onion-CRQOxurS.js +0 -1199
  210. package/dist/vue-ui-parallel-coordinate-plot-Dhn18RtR.js +0 -1412
  211. package/dist/vue-ui-quick-chart-DAhSXYnp.js +0 -2443
  212. package/dist/vue-ui-rating-DbxK-ftN.js +0 -352
  213. package/dist/vue-ui-relation-circle-Cb33DMZo.js +0 -917
  214. package/dist/vue-ui-ridgeline-D7aArzQk.js +0 -1627
  215. package/dist/vue-ui-sparkhistogram-D1oFTrvt.js +0 -575
  216. package/dist/vue-ui-sparkstackbar-BlFio0lP.js +0 -674
  217. package/dist/vue-ui-stackbar-Cu13EdVa.js +0 -2322
  218. package/dist/vue-ui-stackline-DKL0o_-3.js +0 -2427
  219. package/dist/vue-ui-table-heatmap-CSI482KG.js +0 -338
  220. package/dist/vue-ui-thermometer-D6Czx7Fb.js +0 -769
  221. package/dist/vue-ui-treemap-BOEYCOdk.js +0 -1727
  222. package/dist/vue-ui-waffle-BrM8IHdG.js +0 -1367
  223. package/dist/vue-ui-wheel-BNsajigQ.js +0 -884
  224. package/dist/vue-ui-xy-Dt_1bSBT.js +0 -1364
@@ -0,0 +1,2464 @@
1
+ import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
2
+ import { $ as t, Bt as n, D as r, Gt as i, Jt as a, Kt as o, M as s, Ot as c, P as l, Pt as u, S as d, St as f, V as p, Wt as m, X as h, _ as g, b as _, c as ee, ct as te, dt as ne, i as v, jt as re, ot as ie, pt as ae, q as oe, t as se, tt as ce, v as le, w as ue, xt as de, z as fe } from "./lib-BuMGJ_a0.js";
3
+ import { n as pe, t as me } from "./useHints-Dq_w2E8B.js";
4
+ import { n as he, r as ge, t as _e } from "./useTimeLabels-B9CEuiLZ.js";
5
+ import { t as ve } from "./useConfig-BilxnBNr.js";
6
+ import { t as ye } from "./usePrinter-BFvi4jVy.js";
7
+ import { n as be, t as xe } from "./BaseScanner-DZvpgOjM.js";
8
+ import { t as Se } from "./useSvgExport-Ba9qBr9M.js";
9
+ import { t as Ce } from "./useNestedProp--NSEmhOH.js";
10
+ import { t as we } from "./useThemeCheck-C43Tcqmk.js";
11
+ import { t as Te } from "./useTransitions-g_zBREk2.js";
12
+ import { t as Ee } from "./useStableElementSize-C7KADDKj.js";
13
+ import { t as De } from "./useTimeLabelCollider-AEcY4Ioe.js";
14
+ import { t as Oe } from "./img-DIQG5q8T.js";
15
+ import { n as ke } from "./Title-BODtwViI.js";
16
+ import { t as Ae } from "./Shape-BPMV94Ij.js";
17
+ import { t as je } from "./_plugin-vue_export-helper-B3ysoDQm.js";
18
+ import { l as Me, t as Ne } from "./useResponsive-ZtArZtUf.js";
19
+ import { t as Pe } from "./DefGrad-DVBqDjhO.js";
20
+ import { t as Fe } from "./SlicerPreview-DvjLV2TW.js";
21
+ import { t as Ie } from "./BaseLegendToggle-CtAPwzr2.js";
22
+ import { t as Le } from "./A11yDataTable-DdRsVULz.js";
23
+ import { t as Re } from "./useUserOptionState-DK-_1ddE.js";
24
+ import { t as ze } from "./useChartAccessibility-DYqac8yF.js";
25
+ import { t as Be } from "./Legend-CQTRlzK-.js";
26
+ import { t as Ve } from "./vue_ui_stackline-DQqKPA9z.js";
27
+ import { Fragment as y, Teleport as He, computed as b, createBlock as x, createCommentVNode as S, createElementBlock as C, createElementVNode as w, createSlots as Ue, createTextVNode as We, createVNode as Ge, defineAsyncComponent as Ke, guardReactiveProps as T, mergeProps as qe, nextTick as Je, normalizeClass as Ye, normalizeProps as E, normalizeStyle as Xe, onBeforeUnmount as Ze, onMounted as Qe, openBlock as D, ref as O, renderList as k, renderSlot as A, resolveDynamicComponent as $e, shallowRef as et, toDisplayString as j, toRefs as tt, unref as M, useSlots as nt, watch as rt, watchEffect as it, withCtx as N } from "vue";
28
+ //#region src/components/vue-ui-stackline.vue
29
+ var at = /* @__PURE__ */ e({ default: () => Ht }), ot = ["id"], st = ["id"], ct = ["id"], lt = { style: { position: "relative" } }, ut = [
30
+ "aria-describedby",
31
+ "xmlns",
32
+ "viewBox"
33
+ ], dt = { key: 0 }, ft = [
34
+ "x",
35
+ "y",
36
+ "width",
37
+ "height"
38
+ ], pt = { key: 1 }, mt = [
39
+ "x1",
40
+ "x2",
41
+ "y1",
42
+ "y2",
43
+ "stroke",
44
+ "stroke-width",
45
+ "stroke-dasharray"
46
+ ], ht = [
47
+ "x1",
48
+ "x2",
49
+ "y1",
50
+ "y2",
51
+ "stroke",
52
+ "stroke-width",
53
+ "stroke-dasharray"
54
+ ], gt = [
55
+ "x1",
56
+ "x2",
57
+ "y1",
58
+ "y2",
59
+ "stroke",
60
+ "stroke-width"
61
+ ], _t = [
62
+ "x1",
63
+ "x2",
64
+ "y1",
65
+ "y2",
66
+ "stroke",
67
+ "stroke-width"
68
+ ], vt = [
69
+ "x",
70
+ "y",
71
+ "font-size",
72
+ "fill",
73
+ "font-weight"
74
+ ], yt = [
75
+ "transform",
76
+ "font-size",
77
+ "fill",
78
+ "font-weight"
79
+ ], bt = [
80
+ "x",
81
+ "y",
82
+ "width",
83
+ "height",
84
+ "stroke",
85
+ "stroke-width",
86
+ "stroke-linecap",
87
+ "stroke-linejoin",
88
+ "stroke-dasharray"
89
+ ], xt = [
90
+ "d",
91
+ "fill",
92
+ "opacity"
93
+ ], St = [
94
+ "d",
95
+ "stroke",
96
+ "stroke-width"
97
+ ], Ct = [
98
+ "x1",
99
+ "x2",
100
+ "y1",
101
+ "y2",
102
+ "stroke"
103
+ ], wt = [
104
+ "transform",
105
+ "font-size",
106
+ "font-weight",
107
+ "fill",
108
+ "text-anchor"
109
+ ], Tt = { key: 0 }, Et = { key: 1 }, Dt = [
110
+ "text-anchor",
111
+ "font-size",
112
+ "font-weight",
113
+ "fill",
114
+ "transform",
115
+ "onClick"
116
+ ], Ot = [
117
+ "text-anchor",
118
+ "font-size",
119
+ "fill",
120
+ "transform",
121
+ "innerHTML",
122
+ "onClick"
123
+ ], kt = [
124
+ "x",
125
+ "y",
126
+ "height",
127
+ "width",
128
+ "fill"
129
+ ], At = { key: 0 }, jt = [
130
+ "x1",
131
+ "x2",
132
+ "y1",
133
+ "y2",
134
+ "stroke",
135
+ "stroke-width",
136
+ "stroke-dasharray"
137
+ ], Mt = { key: 0 }, Nt = [
138
+ "transform",
139
+ "font-size",
140
+ "fill",
141
+ "font-weight"
142
+ ], Pt = [
143
+ "transform",
144
+ "font-size",
145
+ "font-weight",
146
+ "fill"
147
+ ], Ft = ["data-start", "data-end"], It = {
148
+ key: 0,
149
+ style: {
150
+ position: "absolute",
151
+ top: "100%",
152
+ left: "0",
153
+ width: "100%"
154
+ },
155
+ "data-dom-to-png-ignore": "",
156
+ "aria-hidden": "true"
157
+ }, Lt = {
158
+ key: 5,
159
+ class: "vue-data-ui-watermark"
160
+ }, Rt = ["onClick"], zt = ["innerHTML"], Bt = ["innerHTML"], Vt = ["id"], Ht = /*#__PURE__*/ je({
161
+ __name: "vue-ui-stackline",
162
+ props: {
163
+ config: {
164
+ type: Object,
165
+ default() {
166
+ return {};
167
+ }
168
+ },
169
+ dataset: {
170
+ type: Array,
171
+ default() {
172
+ return [];
173
+ }
174
+ },
175
+ selectedXIndex: {
176
+ type: Number,
177
+ default: void 0
178
+ }
179
+ },
180
+ emits: [
181
+ "selectDatapoint",
182
+ "selectLegend",
183
+ "selectTimeLabel",
184
+ "selectX",
185
+ "copyAlt"
186
+ ],
187
+ setup(e, { expose: je, emit: at }) {
188
+ let Ht = Ke(() => import("./Tooltip-CMTGxeYO.js")), Ut = Ke(() => import("./BaseIcon-91MZoczJ.js").then((e) => e.n)), Wt = Ke(() => import("./vue-ui-accordion-61MlW-Ge.js").then((e) => e.n)), Gt = Ke(() => import("./DataTable-D4tM9s5Y.js")), Kt = Ke(() => import("./PenAndPaper-cE4J8-rA.js").then((e) => e.t)), qt = Ke(() => import("./UserOptions-3ujTo3LD.js").then((e) => e.n)), Jt = Ke(() => import("./PackageVersion--QCMh5k_.js").then((e) => e.t)), Yt = Ke(() => import("./BaseDraggableDialog-qTnfhLBz.js").then((e) => e.n)), { vue_ui_stackline: Xt } = ve(), { isThemeValid: Zt, warnInvalidTheme: Qt } = we(), $t = nt(), P = e, F = at, en = b({
189
+ get() {
190
+ return !!P.dataset && P.dataset.length;
191
+ },
192
+ set(e) {
193
+ return e;
194
+ }
195
+ }), tn = O(null), I = O(oe()), nn = O(!1), L = O([]), rn = O(0), an = O(null), on = O(null), sn = O(null), cn = O(null), ln = O(null), un = O(!1), dn = O(!1), fn = O(0), pn = O(0), mn = O(0), hn = O(!1), gn = O(null), _n = O(null), vn = O(!1), yn = O(!1), bn = O(!1), xn = O(null), Sn = O(null), Cn = O(null), wn = O(null), Tn = O(null), En = et(null), Dn = O(!1), On = O(0), kn = O(0), R = O(null), An = O({
196
+ x: 0,
197
+ y: 0
198
+ }), jn = O("pointer"), Mn = Ee({
199
+ elementRef: En,
200
+ minimumWidth: 2,
201
+ minimumHeight: 2,
202
+ stableFramesRequired: 2,
203
+ once: !1,
204
+ onSizeAccepted: () => {
205
+ Fn();
206
+ }
207
+ });
208
+ function Nn() {
209
+ En.value = tn.value?.parentNode ?? null;
210
+ }
211
+ function Pn() {
212
+ return new Promise((e) => {
213
+ requestAnimationFrame(() => {
214
+ requestAnimationFrame(e);
215
+ });
216
+ });
217
+ }
218
+ async function Fn() {
219
+ let e = ++kn.value;
220
+ Dn.value = !1, await Je(), await Pn(), await Pn(), e === kn.value && (On.value += 1, Dn.value = !0);
221
+ }
222
+ let In = O(null), Ln = O(!1);
223
+ function Rn() {
224
+ Ln.value = !Ln.value;
225
+ }
226
+ Qe(() => {
227
+ Nn(), Mn.start(), hn.value = !0, cr(), Fn();
228
+ });
229
+ let z = O(Yn());
230
+ pe({
231
+ config: () => z.value,
232
+ dataset: () => P.dataset,
233
+ component: "VueUiStackline",
234
+ rules: [
235
+ me.emptyArray,
236
+ {
237
+ test: (e) => e.some((e) => e.series.length > 200),
238
+ message: [
239
+ "👀 Some series have > 200 datapoints, which can impact performance. Consider:",
240
+ "",
241
+ "▶️ Aggregating data to larger time units, to reduce the number of datapoints.",
242
+ "",
243
+ "▶️ Using filters to constraint the data to a specific time range."
244
+ ]
245
+ },
246
+ {
247
+ test: (e) => e.length > 6,
248
+ message: [
249
+ "👀 The number of series > 6, which can make the chart hard to read. Consider:",
250
+ "",
251
+ "▶️ Grouping small values into an \"Other\" category.",
252
+ "",
253
+ "▶️ Using filters to let users choose a maximum number of series to display."
254
+ ]
255
+ }
256
+ ]
257
+ });
258
+ let { transitionEnabled: zn } = Te({
259
+ config: () => z.value.transitions,
260
+ dataset: () => P.dataset
261
+ }), B = b(() => z.value.userOptions.useCursorPointer), Bn = b(() => a({
262
+ defaultConfig: {
263
+ userOptions: { show: !1 },
264
+ useCssAnimation: !1,
265
+ table: { show: !1 },
266
+ tooltip: { show: !1 },
267
+ style: { chart: {
268
+ backgroundColor: "#99999930",
269
+ lines: {
270
+ totalValues: { show: !1 },
271
+ dataLabels: { show: !1 }
272
+ },
273
+ grid: {
274
+ frame: { stroke: "#6A6A6A" },
275
+ scale: {
276
+ scaleMin: 0,
277
+ scaleMax: 144
278
+ },
279
+ x: {
280
+ axisColor: "#6A6A6A",
281
+ linesColor: "#6A6A6A",
282
+ axisName: { show: !1 },
283
+ timeLabels: { show: !1 }
284
+ },
285
+ y: {
286
+ axisColor: "#6A6A6A",
287
+ linesColor: "#6A6A6A",
288
+ axisName: { show: !1 },
289
+ axisLabels: { show: !1 }
290
+ }
291
+ },
292
+ legend: { backgroundColor: "transparent" },
293
+ padding: {
294
+ left: 24,
295
+ right: 24,
296
+ bottom: 12
297
+ },
298
+ zoom: {
299
+ show: !1,
300
+ startIndex: null,
301
+ endIndex: null,
302
+ keepState: !1
303
+ }
304
+ } }
305
+ },
306
+ userConfig: z.value.skeletonConfig ?? {}
307
+ })), { loading: Vn, FINAL_DATASET: Hn, manualLoading: Un } = be({
308
+ ...tt(P),
309
+ FINAL_CONFIG: z,
310
+ prepareConfig: Yn,
311
+ callback: () => {
312
+ Promise.resolve().then(async () => {
313
+ (!z.value.style.chart.zoom.keepState || !ei.value || q.value.start === 0 && q.value.end === 0) && await ni();
314
+ });
315
+ },
316
+ skeletonDataset: P.config?.skeletonDataset ?? [{
317
+ name: "",
318
+ series: [
319
+ 3,
320
+ 2,
321
+ 1,
322
+ 5,
323
+ 13,
324
+ 21,
325
+ 8,
326
+ 89,
327
+ 34,
328
+ 55
329
+ ],
330
+ color: "#8A8A8A"
331
+ }, {
332
+ name: "",
333
+ series: [
334
+ 1,
335
+ 2,
336
+ 3,
337
+ 5,
338
+ 8,
339
+ 13,
340
+ 21,
341
+ 34,
342
+ 55,
343
+ 89
344
+ ],
345
+ color: "#CACACA"
346
+ }],
347
+ skeletonConfig: a({
348
+ defaultConfig: z.value,
349
+ userConfig: Bn.value
350
+ })
351
+ }), { userOptionsVisible: Wn, setUserOptionsVisibility: Gn, keepUserOptionState: Kn } = Re({ config: z.value }), { svgRef: V } = ze({ config: z.value.style.chart.title });
352
+ function qn() {
353
+ vn.value = !0, Gn(!0);
354
+ }
355
+ function Jn() {
356
+ Gn(!1), vn.value = !1, R.value = null, jn.value = "pointer", nn.value = !1, $.value = null, F("selectX", {
357
+ index: null,
358
+ indexLabel: null,
359
+ dataset: null
360
+ });
361
+ }
362
+ function Yn() {
363
+ let e = Ce({
364
+ userConfig: P.config,
365
+ defaultConfig: Xt
366
+ }), t = {}, n = e.theme;
367
+ if (n) if (!Zt.value(e)) Qt(e), t = e;
368
+ else {
369
+ let r = Ce({
370
+ userConfig: Ve[n] || P.config,
371
+ defaultConfig: e
372
+ });
373
+ t = {
374
+ ...Ce({
375
+ userConfig: P.config,
376
+ defaultConfig: r
377
+ }),
378
+ customPalette: e.customPalette.length ? e.customPalette : o[n] || u
379
+ };
380
+ }
381
+ else t = e;
382
+ return t;
383
+ }
384
+ let Xn = b(() => z.value.style.chart.lines.dataLabels.hideUnderValue !== null), Zn = b(() => z.value.style.chart.lines.dataLabels.hideUnderPercentage !== null);
385
+ rt(() => P.config, (e) => {
386
+ Vn.value || (z.value = Yn()), Wn.value = !z.value.userOptions.showOnChartHover, cr({ resetSlicer: !z.value.style.chart.zoom.keepState }), fn.value += 1, pn.value += 1, mn.value += 1, H.value.dataLabels.show = z.value.style.chart.lines.dataLabels.show, H.value.showTable = z.value.table.show, H.value.showTooltip = z.value.style.chart.tooltip.show, U.value.width = z.value.style.chart.width, U.value.height = z.value.style.chart.height, U.value.paddingRatio = {
387
+ top: z.value.style.chart.padding.top / z.value.style.chart.height,
388
+ right: z.value.style.chart.padding.right / z.value.style.chart.width,
389
+ bottom: z.value.style.chart.padding.bottom / z.value.style.chart.height,
390
+ left: z.value.style.chart.padding.left / z.value.style.chart.width
391
+ }, Nn(), Fn(), !z.value.style.chart.zoom.keepState || !ei.value || q.value.start === 0 && q.value.end === 0 ? ni() : wr();
392
+ }, { deep: !0 }), rt(() => P.dataset, (e) => {
393
+ Array.isArray(e) && e.length > 0 && (Un.value = !1), z.value.style.chart.zoom.keepState ? wr() : Dr(), Nn(), Fn();
394
+ }, { deep: !0 });
395
+ let H = O({
396
+ dataLabels: { show: z.value.style.chart.lines.dataLabels.show },
397
+ showTable: z.value.table.show,
398
+ showTooltip: z.value.style.chart.tooltip.show
399
+ });
400
+ rt(z, () => {
401
+ H.value = {
402
+ dataLabels: { show: z.value.style.chart.lines.dataLabels.show },
403
+ showTable: z.value.table.show,
404
+ showTooltip: z.value.style.chart.tooltip.show
405
+ };
406
+ }, { immediate: !0 });
407
+ let { isPrinting: Qn, isImaging: $n, generatePdf: er, generateImage: tr } = ye({
408
+ elementId: `stackline_${I.value}`,
409
+ fileName: z.value.style.chart.title.text || "vue-ui-stackline",
410
+ options: z.value.userOptions.print
411
+ }), nr = b(() => z.value.userOptions.show && !z.value.style.chart.title.text), U = O({
412
+ width: z.value.style.chart.width,
413
+ height: z.value.style.chart.height,
414
+ paddingRatio: {
415
+ top: z.value.style.chart.padding.top / z.value.style.chart.height,
416
+ right: z.value.style.chart.padding.right / z.value.style.chart.width,
417
+ bottom: z.value.style.chart.padding.bottom / z.value.style.chart.height,
418
+ left: z.value.style.chart.padding.left / z.value.style.chart.width
419
+ }
420
+ }), rr = b(() => ue(z.value.customPalette)), ir = et(null), ar = et(null), or = O(null), sr = b(() => !!z.value.debug);
421
+ function cr({ resetSlicer: e = !0 } = {}) {
422
+ if (re(P.dataset) ? (ce({
423
+ componentName: "VueUiStackline",
424
+ type: "dataset",
425
+ debug: sr.value
426
+ }), Un.value = !0) : P.dataset.forEach((e, t) => {
427
+ ae({
428
+ datasetObject: e,
429
+ requiredAttributes: ["name", "series"]
430
+ }).forEach((e) => {
431
+ en.value = !1, ce({
432
+ componentName: "VueUiStackline",
433
+ type: "datasetSerieAttribute",
434
+ property: e,
435
+ index: t,
436
+ debug: sr.value
437
+ }), Un.value = !0;
438
+ });
439
+ }), re(P.dataset) || (Un.value = z.value.loading), setTimeout(() => {
440
+ dn.value = !0;
441
+ }, 10), z.value.responsive) {
442
+ let e = Me(() => {
443
+ dn.value = !1;
444
+ let { width: e, height: t } = Ne({
445
+ chart: tn.value,
446
+ noTitle: cn.value,
447
+ title: z.value.style.chart.title.text ? an.value : null,
448
+ legend: z.value.style.chart.legend.show ? on.value : null,
449
+ slicer: z.value.style.chart.zoom.show && K.value > 6 ? sn.value.$el : null,
450
+ source: ln.value
451
+ });
452
+ requestAnimationFrame(() => {
453
+ U.value.width = e, U.value.height = t - 12, clearTimeout(or.value), or.value = setTimeout(() => {
454
+ dn.value = !0;
455
+ }, 10);
456
+ });
457
+ });
458
+ ir.value && (ar.value && ir.value.unobserve(ar.value), ir.value.disconnect()), ir.value = new ResizeObserver(e), ar.value = tn.value.parentNode, ir.value.observe(ar.value);
459
+ }
460
+ e && ni();
461
+ }
462
+ Ze(() => {
463
+ Mn.stop(), ir.value && (ar.value && ir.value.unobserve(ar.value), ir.value.disconnect());
464
+ });
465
+ let lr = b(() => z.value.style.chart.grid.y.position === "right");
466
+ function ur() {
467
+ let e = 0;
468
+ Cn.value && (e = Array.from(Cn.value.querySelectorAll("text")).reduce((e, t) => {
469
+ let n = t.getComputedTextLength();
470
+ return n > e ? n : e;
471
+ }, 0));
472
+ let t = Sn.value ? Sn.value.getBoundingClientRect().width + z.value.style.chart.grid.y.axisName.fontSize + z.value.style.chart.grid.y.axisName.offsetX : 0;
473
+ return {
474
+ left: lr.value ? 0 : e + t,
475
+ right: lr.value ? e + t : 0,
476
+ scaleLabelsWidth: e,
477
+ yAxisLabelWidth: t
478
+ };
479
+ }
480
+ let dr = O(0), fr = O(0), pr = O(0);
481
+ function mr() {
482
+ let e = wn.value;
483
+ if (!e) {
484
+ fr.value = 0;
485
+ return;
486
+ }
487
+ try {
488
+ let t = e.getBBox();
489
+ fr.value = Number.isFinite(t?.height) ? t.height : 0;
490
+ } catch {
491
+ fr.value = 0;
492
+ }
493
+ }
494
+ function hr() {
495
+ pr.value && cancelAnimationFrame(pr.value), pr.value = requestAnimationFrame(() => {
496
+ requestAnimationFrame(() => {
497
+ mr();
498
+ });
499
+ });
500
+ }
501
+ Ze(() => {
502
+ pr.value && cancelAnimationFrame(pr.value), fr.value = 0, dr.value = 0;
503
+ });
504
+ let gr = b(() => {
505
+ let e = 0;
506
+ if (xn.value) try {
507
+ e = xn.value.getBBox().height;
508
+ } catch {
509
+ e = 0;
510
+ }
511
+ let t = z.value.style.chart.grid.x.timeLabels.show ? fr.value : 0;
512
+ return e + t;
513
+ }), W = b(() => {
514
+ On.value;
515
+ let { height: e, width: t } = U.value, { right: n } = U.value.paddingRatio, r = z.value.style.chart.lines.totalValues.show && P.dataset && P.dataset.length > 1 ? z.value.style.chart.lines.totalValues.fontSize * 1.3 : 0, i = 0, a = 0, o = 0, s = 0;
516
+ if (z.value.style.chart.grid.y.axisLabels.show) {
517
+ let e = ur();
518
+ i = e.left, a = e.right, o = e.scaleLabelsWidth, s = e.yAxisLabelWidth;
519
+ }
520
+ let c = z.value.style.chart.padding.top + r, l = t - t * n - dr.value - a, u = e - z.value.style.chart.padding.bottom - gr.value - r, d = z.value.style.chart.padding.left + i, f = t - d - t * n - dr.value - a, p = e - c - z.value.style.chart.padding.bottom - gr.value - r;
521
+ return {
522
+ chartHeight: Math.max(0, e),
523
+ chartWidth: Math.max(0, t),
524
+ top: c,
525
+ right: Math.max(0, l),
526
+ bottom: Math.max(0, u),
527
+ left: Math.max(0, d),
528
+ width: Math.max(0, f),
529
+ height: Math.max(0, p),
530
+ offsetLeftAxis: i,
531
+ offsetRightAxis: a,
532
+ scaleLabelsWidth: o,
533
+ yAxisLabelWidth: s
534
+ };
535
+ }), _r = b(() => {
536
+ let { left: e, top: t, width: n, height: r } = W.value, i = q.value.start, a = q.value.end, o = Math.max(1, a - i), s = Math.max(0, Math.min(o, (J.value.start ?? i) - i)), c = Math.max(0, Math.min(o, (J.value.end ?? a) - i)), l = Math.max(0, c - s), u = {
537
+ fill: z.value.style.chart.zoom.preview.fill,
538
+ stroke: z.value.style.chart.zoom.preview.stroke,
539
+ "stroke-width": z.value.style.chart.zoom.preview.strokeWidth,
540
+ "stroke-dasharray": z.value.style.chart.zoom.preview.strokeDasharray,
541
+ "stroke-linecap": "round",
542
+ "stroke-linejoin": "round",
543
+ style: {
544
+ pointerEvents: "none",
545
+ transition: "none !important",
546
+ animation: "none !important"
547
+ }
548
+ }, d = n / o;
549
+ return {
550
+ x: e + s * d,
551
+ y: t,
552
+ width: l * d,
553
+ height: r,
554
+ ...u
555
+ };
556
+ }), G = b(() => Hn.value.map((e, t) => {
557
+ let n = oe(), r = d(e.color) || rr.value[t] || u[t] || u[t % u.length];
558
+ return {
559
+ ...e,
560
+ shape: e.shape || "circle",
561
+ standalone: !!e.standalone,
562
+ series: JSON.parse(JSON.stringify(e.series)).map((e) => z.value.style.chart.lines.distributed ? Math.abs(e) : e),
563
+ seriesSource: e.series,
564
+ signedSeries: e.series.map((e) => e >= 0 ? 1 : -1),
565
+ absoluteIndex: t,
566
+ id: n,
567
+ color: r
568
+ };
569
+ })), vr = b(() => G.value.filter((e) => !L.value.includes(e.id) && !e.standalone)), yr = b(() => G.value.filter((e) => !L.value.includes(e.id) && e.standalone)), K = b(() => {
570
+ let e = Math.max(...G.value.filter((e) => !L.value.includes(e.id)).map((e) => e.series.length));
571
+ return isFinite(e) ? e : Math.max(...G.value.map((e) => e.series.length));
572
+ });
573
+ function br(e) {
574
+ In.value = e;
575
+ }
576
+ let q = O({
577
+ start: 0,
578
+ end: Math.max(...Hn.value.map((e) => e.series.length))
579
+ }), J = O({
580
+ start: 0,
581
+ end: Math.max(...Hn.value.map((e) => e.series.length))
582
+ });
583
+ function xr(e) {
584
+ return (q.value.start ?? 0) + (e ?? 0);
585
+ }
586
+ let Sr = b(() => z.value.style.chart.zoom.preview.enable && (J.value.start !== q.value.start || J.value.end !== q.value.end));
587
+ function Cr(e, t) {
588
+ J.value[e] = t;
589
+ }
590
+ function wr() {
591
+ let e = K.value, t = Math.max(0, Math.min(q.value.start ?? 0, e - 1)), n = Math.max(t + 1, Math.min(q.value.end ?? e, e));
592
+ (!Number.isFinite(t) || !Number.isFinite(n) || n <= t) && (t = 0, n = e), q.value.start = t, q.value.end = n, J.value.start = t, J.value.end = n, sn.value && (sn.value.setStartValue(t), sn.value.setEndValue(n));
593
+ }
594
+ let Tr = O(null);
595
+ function Er() {
596
+ return new Promise((e) => requestAnimationFrame(() => requestAnimationFrame(() => e())));
597
+ }
598
+ Ze(() => {
599
+ Tr.value && cancelAnimationFrame(Tr.value);
600
+ });
601
+ async function Dr({ force: e = !1 } = {}) {
602
+ if (z.value.style.chart.zoom.keepState && !e && ei.value && !(q.value.start === 0 && q.value.end === 0)) {
603
+ wr();
604
+ return;
605
+ }
606
+ ni(), await Je(), Tr.value && cancelAnimationFrame(Tr.value), Tr.value = requestAnimationFrame(async () => {
607
+ await Er(), ni();
608
+ });
609
+ }
610
+ let Or = b(() => Math.max(0, W.value.width / (q.value.end - q.value.start))), kr = b(() => m(vr.value.map((e) => ({
611
+ ...e,
612
+ series: e.series.map((e) => e ?? 0)
613
+ }))).slice(q.value.start, q.value.end)), Ar = b(() => L.value.length === G.value.length), jr = b(() => {
614
+ if (!z.value.style.chart.zoom.minimap.show) return [];
615
+ let e = G.value.filter((e) => Ar.value ? !0 : !L.value.includes(e.id) && !e.standalone);
616
+ if (e.length) return m(e.map((e) => ({
617
+ ...e,
618
+ series: (e.series || []).map((e) => e ?? 0)
619
+ })));
620
+ let t = yr.value;
621
+ if (!t.length) return [];
622
+ let n = Math.max(...t.map((e) => e.series.length || 0));
623
+ return Array.from({ length: n }, (e, n) => t.reduce((e, t) => e + Math.abs(t.series[n] ?? 0), 0));
624
+ }), Mr = b(() => {
625
+ if (!z.value.style.chart.zoom.minimap.show) return [];
626
+ let e = G.value.filter((e) => Ar.value ? !0 : !L.value.includes(e.id) && !e.standalone), t = yr.value, n = e.length ? [{
627
+ name: "",
628
+ series: jr.value,
629
+ color: "#000000",
630
+ isVisible: !0
631
+ }] : [], r = t.map((e) => ({
632
+ name: e.name || "",
633
+ series: (e.series || []).map((e) => e ?? 0),
634
+ color: e.color,
635
+ isVisible: !0
636
+ }));
637
+ return n.concat(r);
638
+ }), Nr = b(() => m(vr.value.filter((e) => !L.value.includes(e.id)).map((e) => ({
639
+ ...e,
640
+ series: e.series.map((t, n) => {
641
+ let r = t ?? 0;
642
+ return e.signedSeries[n] === -1 && r >= 0 ? -r : r;
643
+ })
644
+ }))).slice(q.value.start, q.value.end)), Pr = b(() => {
645
+ let e = vr.value.filter((e) => !L.value.includes(e.id));
646
+ return {
647
+ positive: m(e.map((e) => ({
648
+ ...e,
649
+ series: e.series.slice(q.value.start, q.value.end).map((e) => (e ?? 0) >= 0 ? e ?? 0 : 0)
650
+ }))),
651
+ negative: m(e.map((e) => ({
652
+ ...e,
653
+ series: e.series.slice(q.value.start, q.value.end).map((e) => (e ?? 0) < 0 ? e ?? 0 : 0)
654
+ })))
655
+ };
656
+ }), Fr = b(() => {
657
+ let e = Math.max(0, q.value.end - q.value.start), t = Array(e).fill(0), n = Array(e).fill(0);
658
+ return yr.value.forEach((r) => {
659
+ for (let i = 0; i < e; i += 1) {
660
+ let e = r.series[q.value.start + i] ?? 0;
661
+ e > 0 && (t[i] = Math.max(t[i], e)), e < 0 && (n[i] = Math.min(n[i], e));
662
+ }
663
+ }), {
664
+ positive: t,
665
+ negative: n
666
+ };
667
+ }), Ir = b(() => Nr.value.map((e, t) => ({
668
+ value: e,
669
+ sign: e >= 0 ? 1 : -1
670
+ })));
671
+ function Lr() {
672
+ return { y0: zr.value?.[0]?.zero ?? W.value.bottom };
673
+ }
674
+ function Rr(e) {
675
+ let { y0: t } = Lr(), n = z.value.style.chart.lines.totalValues, r = Math.max(2, n.fontSize * 1.3 + n.offsetY), i = (e) => Math.min(Math.max(e, W.value.top - z.value.style.chart.lines.totalValues.fontSize * 1.3), W.value.bottom + z.value.style.chart.lines.totalValues.fontSize * 2);
676
+ if ((Ir.value?.[e]?.value ?? 0) >= 0 || z.value.style.chart.lines.distributed) {
677
+ let n = Infinity;
678
+ for (let t of Y.value || []) {
679
+ let r = t?.series?.[e], i = t?.topY?.[e];
680
+ (r ?? 0) > 0 && Number.isFinite(i) && i < n && (n = i);
681
+ }
682
+ return i((Number.isFinite(n) ? n : t) - r - z.value.style.chart.lines.totalValues.offsetY);
683
+ } else {
684
+ let a = -Infinity;
685
+ for (let t of Y.value || []) {
686
+ let n = t?.series?.[e], r = t?.topY?.[e];
687
+ (n ?? 0) < 0 && Number.isFinite(r) && r > a && (a = r);
688
+ }
689
+ return i((Number.isFinite(a) ? a : t) + r + n.fontSize * .7 + z.value.style.chart.lines.totalValues.offsetY);
690
+ }
691
+ }
692
+ let zr = b(() => {
693
+ let e = Math.max(...Pr.value.positive, 0), t = Math.min(...Pr.value.negative, 0), n = Math.max(...Fr.value.positive, 0), r = Math.min(...Fr.value.negative, 0), i = Math.max(e, n), a = Math.min(t, r), o = [
694
+ -Infinity,
695
+ Infinity,
696
+ NaN,
697
+ void 0,
698
+ null
699
+ ].includes(a) ? 0 : a, s = z.value.style.chart.grid.scale.scaleMin, c = z.value.style.chart.grid.scale.scaleMax, l = !z.value.style.chart.lines.distributed && (s !== null || c !== null), u = s !== null && !z.value.style.chart.lines.distributed ? s : o > 0 ? 0 : o, d = c !== null && !z.value.style.chart.lines.distributed ? c : i < 0 ? 0 : i, f = l ? le(u, d, z.value.style.chart.grid.scale.ticks) : g(u, d, z.value.style.chart.grid.scale.ticks), p = Math.abs(Number(f.min) || 0), m = (Number(f.max) || 0) + p, h = m === 0 || !Number.isFinite(m) ? 1 : m, _ = Array.isArray(f.ticks) && f.ticks.length ? f.ticks : [0], ee = W.value.bottom - W.value.height * (p / h);
700
+ return _.map((e) => {
701
+ let t = Number(e) || 0, n = W.value.bottom - W.value.height * ((t + p) / h);
702
+ return {
703
+ zero: ee,
704
+ y: n,
705
+ x: lr.value ? X.value.right + 8 : X.value.left - 8,
706
+ value: t
707
+ };
708
+ });
709
+ }), Br = O([]), Vr = O([]), Hr = 0;
710
+ it(() => {
711
+ let e = ++Hr;
712
+ (async () => {
713
+ let t = await _e({
714
+ values: z.value.style.chart.grid.x.timeLabels.values,
715
+ maxDatapoints: K.value,
716
+ formatter: z.value.style.chart.grid.x.timeLabels.datetimeFormatter,
717
+ start: q.value.start,
718
+ end: q.value.end
719
+ });
720
+ e === Hr && (Br.value = t);
721
+ })();
722
+ });
723
+ let Ur = 0;
724
+ it(() => {
725
+ let e = ++Ur;
726
+ (async () => {
727
+ let t = await _e({
728
+ values: z.value.style.chart.grid.x.timeLabels.values,
729
+ maxDatapoints: K.value,
730
+ formatter: z.value.style.chart.grid.x.timeLabels.datetimeFormatter,
731
+ start: 0,
732
+ end: K.value
733
+ });
734
+ e === Ur && (Vr.value = t);
735
+ })();
736
+ });
737
+ let Wr = b(() => {
738
+ let e = z.value.style.chart.grid.x.timeLabels.modulo;
739
+ return Br.value.length ? Math.min(e, [...new Set(Br.value.map((e) => e.text))].length) : e;
740
+ }), Gr = b(() => {
741
+ let e = z.value.style.chart.grid.x.timeLabels, t = Br.value || [], n = Vr.value || [], r = q.value.start ?? 0, i = $.value, a = K.value, o = t.map((e) => e?.text ?? ""), s = n.map((e) => e?.text ?? "");
742
+ return ee(!!e.showOnlyFirstAndLast, !!e.showOnlyAtModulo, Math.max(1, Wr.value || 1), o, s, r, i, a);
743
+ });
744
+ it(() => {
745
+ z.value.style.chart.grid.x.timeLabels.show, z.value.style.chart.grid.x.timeLabels.fontSize, z.value.style.chart.grid.x.timeLabels.rotation, z.value.style.chart.grid.x.timeLabels.offsetY, (Gr.value || []).map((e) => e?.text ?? "").join("|"), U.value.width, U.value.height, wn.value, xn.value, hr();
746
+ }, { flush: "post" });
747
+ let Kr = O({
748
+ months: [],
749
+ shortMonths: [],
750
+ days: [],
751
+ shortDays: []
752
+ }), qr = 0;
753
+ it(() => {
754
+ let e = ++qr, t = z.value.style.chart.grid.x.timeLabels.datetimeFormatter;
755
+ (async () => {
756
+ let n = await ge(t.locale).catch(() => ge("en"));
757
+ e === qr && (Kr.value = n.data);
758
+ })();
759
+ });
760
+ let Jr = b(() => {
761
+ let e = z.value.style.chart.grid.x.timeLabels.datetimeFormatter, t = he({
762
+ useUTC: e.useUTC,
763
+ locale: Kr.value,
764
+ januaryAsYear: e.januaryAsYear
765
+ });
766
+ return (e, n) => {
767
+ let r = z.value.style.chart.grid.x.timeLabels.values?.[e];
768
+ return r == null ? "" : t.formatDate(new Date(r), n);
769
+ };
770
+ }), Yr = b(() => (z.value.style.chart.grid.x.timeLabels.values || []).map((e, t) => ({
771
+ text: Jr.value(t, z.value.style.chart.zoom.timeFormat),
772
+ absoluteIndex: t
773
+ }))), Xr = b(() => (z.value.style.chart.grid.x.timeLabels.values || []).map((e, t) => ({
774
+ text: Jr.value(t, z.value.style.chart.tooltip.timeFormat),
775
+ absoluteIndex: t
776
+ }))), Zr = b(() => {
777
+ if (!en.value && !Vn.value) return [];
778
+ let e = W.value.height, t = zr.value[0] ? zr.value[0].zero : W.value.bottom, n = q.value.start ?? 0, r = q.value.end ?? 0, i = Math.max(1, r - n), a = Math.max(...Pr.value.positive, 0), o = Math.min(...Pr.value.negative, 0), s = Math.max(...Fr.value.positive, 0), c = Math.min(...Fr.value.negative, 0), l = Math.max(a, s), u = Math.min(o, c), { min: d, max: f } = !z.value.style.chart.lines.distributed && (z.value.style.chart.grid.scale.scaleMax !== null || z.value.style.chart.grid.scale.scaleMin !== null) ? le(z.value.style.chart.grid.scale.scaleMin === null ? u > 0 ? 0 : u : z.value.style.chart.grid.scale.scaleMin, z.value.style.chart.grid.scale.scaleMax === null ? l < 0 ? 0 : l : z.value.style.chart.grid.scale.scaleMax, z.value.style.chart.grid.scale.ticks) : g(z.value.style.chart.grid.scale.scaleMin === null ? u > 0 ? 0 : u : z.value.style.chart.grid.scale.scaleMin, z.value.style.chart.grid.scale.scaleMax === null ? l < 0 ? 0 : l : z.value.style.chart.grid.scale.scaleMax, z.value.style.chart.grid.scale.ticks), p = f + (d >= 0 ? 0 : Math.abs(d)) || 1, m = Array(i).fill(0), h = Array(i).fill(0), _ = (e) => i <= 1 ? W.value.left + W.value.width / 2 : W.value.left + e / (i - 1) * W.value.width;
779
+ return G.value.filter((e) => !L.value.includes(e.id)).map((r) => {
780
+ let a = [], o = [], s = [], c = Array(i).fill(null), l = Array(i).fill(null);
781
+ for (let u = 0; u < i; u += 1) {
782
+ let i = n + u, d = r.series?.[i], f = r.signedSeries?.[i], g = d == null || Number.isNaN(d) ? 0 : d, _ = r.standalone ? g / p : z.value.style.chart.lines.distributed ? g / (kr.value[u] || 1) : g / p;
783
+ if (g >= 0) {
784
+ let n = e * Math.abs(_);
785
+ if (r.standalone) c[u] = t, l[u] = t - n;
786
+ else {
787
+ let e = m[u], r = e + n;
788
+ c[u] = t - e, l[u] = t - r, m[u] = r;
789
+ }
790
+ } else {
791
+ let n = e * Math.abs(_);
792
+ if (r.standalone) c[u] = t, l[u] = t + n;
793
+ else {
794
+ let e = h[u], r = e + n;
795
+ c[u] = t + e, l[u] = t + r, h[u] = r;
796
+ }
797
+ }
798
+ a.push(u), o.push(g), s.push(f ?? (g >= 0 ? 1 : -1));
799
+ }
800
+ let u = a.map((e) => ({
801
+ x: _(e),
802
+ y: l[e]
803
+ })), d = u.map((e) => e.x), f = o.reduce((e, t) => e + Math.abs(t || 0), 0), g = f === 0 ? 1 : f, ee = o.map((e, t) => {
804
+ if (z.value.style.chart.lines.distributed && !r.standalone) {
805
+ let n = a[t], r = kr.value[n] || 1;
806
+ return (e || 0) / r;
807
+ }
808
+ return (e || 0) / g;
809
+ });
810
+ return {
811
+ ...r,
812
+ x: d,
813
+ points: u,
814
+ baseY: a.map((e) => c[e]),
815
+ topY: a.map((e) => l[e]),
816
+ series: o,
817
+ signedSeries: s,
818
+ proportions: ee,
819
+ rel: a,
820
+ fullSeries: Array.isArray(r.fullSeries) ? r.fullSeries : r.series
821
+ };
822
+ });
823
+ }), Y = b(() => {
824
+ let e = (e) => typeof e == "string" ? e.replace(/^M\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*,?\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*/i, "").trim() : "", t = Math.max(...Pr.value.positive, 0), n = Math.min(...Pr.value.negative, 0), r = Math.max(...Fr.value.positive, 0), i = Math.min(...Fr.value.negative, 0), a = Math.max(t, r), o = Math.min(n, i), s = !z.value.style.chart.lines.distributed && (z.value.style.chart.grid.scale.scaleMax !== null || z.value.style.chart.grid.scale.scaleMin !== null) ? le(z.value.style.chart.grid.scale.scaleMin === null ? o > 0 ? 0 : o : z.value.style.chart.grid.scale.scaleMin, z.value.style.chart.grid.scale.scaleMax === null ? a < 0 ? 0 : a : z.value.style.chart.grid.scale.scaleMax, z.value.style.chart.grid.scale.ticks) : g(z.value.style.chart.grid.scale.scaleMin === null ? o > 0 ? 0 : o : z.value.style.chart.grid.scale.scaleMin, z.value.style.chart.grid.scale.scaleMax === null ? a < 0 ? 0 : a : z.value.style.chart.grid.scale.scaleMax, z.value.style.chart.grid.scale.ticks), c = Number(s.min) || 0, u = Number(s.max) || 0, d = Math.abs(c), f = u + d || 1, m = (e) => {
825
+ if (z.value.style.chart.lines.distributed) {
826
+ let t = Math.max(0, Math.min(1, e));
827
+ return minimapH - minimapH * t;
828
+ }
829
+ return clampY(minimapH - minimapH * (((e ?? 0) + d) / f));
830
+ };
831
+ return Zr.value.map((t) => {
832
+ let n = t.x.length, r = Array.isArray(t.fullSeries) ? t.fullSeries : t.series, i = ({ left: e = 0, unitW: t }) => {
833
+ let n = r.length;
834
+ return !Number.isFinite(t) || t <= 0 || n <= 0 ? [] : n === 1 ? [e + t * .5] : r.map((n, r) => e + r * t);
835
+ }, a = ({ minimapH: e }) => !Number.isFinite(e) || e <= 0 ? [] : r.map((t) => m(t || 0, e)), o = ({ minimapH: e }) => {
836
+ if (!Number.isFinite(e) || e <= 0) return [];
837
+ let t = m(0, e);
838
+ return r.map(() => t);
839
+ };
840
+ if (n === 0) return {
841
+ ...t,
842
+ points: [],
843
+ smoothPath: "",
844
+ straightPath: "",
845
+ smoothArea: "",
846
+ straightArea: "",
847
+ xMinimap: i,
848
+ yMinimap: a,
849
+ yMinimapBase: o
850
+ };
851
+ let s = t.x.map((e, n) => ({
852
+ x: e,
853
+ y: t.topY[n]
854
+ })), c = t.x.map((e, n) => ({
855
+ x: e,
856
+ y: t.baseY[n]
857
+ })), u = n >= 2 ? l(s) : `M${s[0].x},${s[0].y}`, d = n >= 2 ? p(s) : `M${s[0].x},${s[0].y}`, f = n >= 2 ? `M${e(u)}` : u, h = n >= 2 ? `M${e(d)}` : d, g = "", _ = "";
858
+ if (z.value.style.chart.lines.useArea && n >= 2) {
859
+ let t = l([...c].reverse()), n = p([...c].reverse()), r = c[c.length - 1];
860
+ g = `M${s[0].x},${s[0].y} ${e(u)} L${r.x},${r.y} ${e(t)} Z`, _ = `M${s[0].x},${s[0].y} ${e(d)} L${r.x},${r.y} ${e(n)} Z`;
861
+ }
862
+ return {
863
+ ...t,
864
+ points: s,
865
+ smoothPath: f,
866
+ straightPath: h,
867
+ smoothArea: g,
868
+ straightArea: _,
869
+ xMinimap: i,
870
+ yMinimap: a,
871
+ yMinimapBase: o
872
+ };
873
+ });
874
+ }), Qr = b(() => $.value === null || $.value === void 0 ? null : {
875
+ timeLabel: gi($.value),
876
+ absoluteIndex: $.value + q.value.start,
877
+ seriesIndex: $.value,
878
+ datapoint: hi.value,
879
+ series: Y.value,
880
+ config: z.value
881
+ }), $r = O(!1), ei = O(!1);
882
+ function ti(e) {
883
+ let t = K.value;
884
+ return e > t ? t : e < 0 || e < q.value.start ? z.value.style.chart.zoom.startIndex === null ? 1 : q.value.start + 1 : e;
885
+ }
886
+ function ni() {
887
+ if (!$r.value) {
888
+ $r.value = !0;
889
+ try {
890
+ let { startIndex: e, endIndex: t, keepState: n } = z.value.style.chart.zoom, r = n ? Math.max(0, K.value) : K.value;
891
+ if (n && r <= 0) return;
892
+ let i = e ?? 0, a = t == null ? r : Math.min(ti(t + 1), r);
893
+ ai.value = !0, q.value.start = i, q.value.end = a, J.value.start = i, J.value.end = a, wr(), ei.value = !0;
894
+ } finally {
895
+ queueMicrotask(() => {
896
+ ai.value = !1;
897
+ }), $r.value = !1;
898
+ }
899
+ }
900
+ }
901
+ function ri(e) {
902
+ $r.value || ai.value || e !== q.value.start && (q.value.start = e, J.value.start = e, wr());
903
+ }
904
+ function ii(e) {
905
+ if ($r.value || ai.value) return;
906
+ let t = ti(e);
907
+ t !== q.value.end && (q.value.end = t, J.value.end = t, wr());
908
+ }
909
+ let X = b(() => ({
910
+ left: W.value.left,
911
+ right: W.value.right,
912
+ width: W.value.width
913
+ }));
914
+ rt([
915
+ b(() => {
916
+ let e = z.value.style.chart.grid.y.axisLabels, { prefix: t, suffix: n } = z.value.style.chart.lines.dataLabels;
917
+ return zr.value.map((r) => String(v(e.formatter, r.value, h({
918
+ p: t,
919
+ v: r.value,
920
+ s: n,
921
+ r: e.rounding
922
+ }), { datapoint: r }) ?? "")).join("|");
923
+ }),
924
+ () => z.value.style.chart.grid.y.axisLabels.show,
925
+ () => z.value.style.chart.grid.y.axisLabels.fontSize,
926
+ () => z.value.style.chart.grid.y.axisLabels.bold,
927
+ () => z.value.style.chart.grid.y.position
928
+ ], () => {
929
+ z.value.style.chart.grid.y.axisLabels.show && Fn();
930
+ }, { flush: "post" });
931
+ let ai = O(!1);
932
+ De({
933
+ timeLabelsEls: wn,
934
+ timeLabels: Br,
935
+ slicer: q,
936
+ configRef: z,
937
+ rotationPath: [
938
+ "style",
939
+ "chart",
940
+ "grid",
941
+ "x",
942
+ "timeLabels",
943
+ "rotation"
944
+ ],
945
+ autoRotatePath: [
946
+ "style",
947
+ "chart",
948
+ "grid",
949
+ "x",
950
+ "timeLabels",
951
+ "autoRotate",
952
+ "enable"
953
+ ],
954
+ isAutoSize: !1,
955
+ width: b(() => U.value.width),
956
+ height: b(() => U.value.height),
957
+ rotation: z.value.style.chart.grid.x.timeLabels.autoRotate.angle
958
+ });
959
+ let oi = O(null);
960
+ function si(e) {
961
+ let t = V.value;
962
+ if (!t) return null;
963
+ if (t.createSVGPoint && t.getScreenCTM) {
964
+ let n = t.createSVGPoint();
965
+ n.x = e.clientX, n.y = e.clientY;
966
+ let r = t.getScreenCTM();
967
+ if (r) {
968
+ let e = n.matrixTransform(r.inverse());
969
+ return {
970
+ x: e.x,
971
+ y: e.y,
972
+ ok: !0
973
+ };
974
+ }
975
+ }
976
+ let n = t.getBoundingClientRect(), r = t.viewBox?.baseVal || {
977
+ x: 0,
978
+ y: 0,
979
+ width: n.width,
980
+ height: n.height
981
+ }, i = Math.min(n.width / r.width, n.height / r.height), a = r.width * i, o = r.height * i, s = (n.width - a) / 2, c = (n.height - o) / 2;
982
+ return {
983
+ x: (e.clientX - n.left - s) / i + r.x,
984
+ y: (e.clientY - n.top - c) / i + r.y,
985
+ ok: !0
986
+ };
987
+ }
988
+ let ci = 0, Z = b(() => Math.max(1, q.value.end - q.value.start)), li = b(() => Z.value > 1 ? W.value.width / (Z.value - 1) : 0);
989
+ function Q(e) {
990
+ return Z.value <= 1 ? W.value.left + W.value.width / 2 : W.value.left + e * li.value;
991
+ }
992
+ function ui(e) {
993
+ if (Z.value <= 1) return {
994
+ x: W.value.left,
995
+ width: W.value.width
996
+ };
997
+ let t = e === 0 ? W.value.left : (Q(e - 1) + Q(e)) / 2, n = e === Z.value - 1 ? W.value.left + W.value.width : (Q(e) + Q(e + 1)) / 2;
998
+ return {
999
+ x: t,
1000
+ width: Math.max(0, n - t)
1001
+ };
1002
+ }
1003
+ function di(e) {
1004
+ Ln.value || (ci && cancelAnimationFrame(ci), ci = requestAnimationFrame(() => {
1005
+ ci = 0;
1006
+ let t = si(e);
1007
+ if (!t || !V.value) {
1008
+ mi();
1009
+ return;
1010
+ }
1011
+ let { left: n, right: r, top: i, bottom: a } = W.value;
1012
+ if (t.x < n || t.x > r || t.y < i || t.y > a) {
1013
+ mi();
1014
+ return;
1015
+ }
1016
+ let o = 0;
1017
+ if (Z.value > 1) {
1018
+ let e = (t.x - n) / li.value;
1019
+ o = Math.round(e);
1020
+ } else o = 0;
1021
+ o < 0 && (o = 0), o > Z.value - 1 && (o = Z.value - 1), oi.value !== o && (oi.value = o, vi(!0, o));
1022
+ }));
1023
+ }
1024
+ function fi(e) {
1025
+ let t = si(e);
1026
+ if (!t || !V.value) return;
1027
+ let { left: n, right: r, top: i, bottom: a } = W.value;
1028
+ if (t.x < n || t.x > r || t.y < i || t.y > a) return;
1029
+ let o = 0;
1030
+ if (Z.value > 1) {
1031
+ let e = (t.x - n) / li.value;
1032
+ o = Math.round(e);
1033
+ } else o = 0;
1034
+ o < 0 && (o = 0), o > Z.value - 1 && (o = Z.value - 1), Zi({
1035
+ seriesIndex: o,
1036
+ datapoint: Ui(o)
1037
+ }), pi(o);
1038
+ }
1039
+ function pi(e) {
1040
+ let t = JSON.parse(JSON.stringify(Y.value)).map((t) => ({
1041
+ name: t.name,
1042
+ value: t.series[e] === 0 ? 0 : t.series[e] || null,
1043
+ proportion: t.proportions[e] || null,
1044
+ color: t.color,
1045
+ id: t.id
1046
+ }));
1047
+ z.value.events.datapointClick && z.value.events.datapointClick({
1048
+ datapoint: t,
1049
+ seriesIndex: e + q.value.start
1050
+ }), F("selectDatapoint", {
1051
+ datapoint: t,
1052
+ period: Br.value[e]
1053
+ });
1054
+ }
1055
+ rt(() => [
1056
+ q.value.start,
1057
+ q.value.end,
1058
+ Y.value.length
1059
+ ], () => {
1060
+ let e = Z.value;
1061
+ if ($.value != null) {
1062
+ if (e <= 0) {
1063
+ $.value = null;
1064
+ return;
1065
+ }
1066
+ $.value < 0 && ($.value = 0), $.value > e - 1 && ($.value = e - 1);
1067
+ }
1068
+ });
1069
+ function mi() {
1070
+ ci &&= (cancelAnimationFrame(ci), 0), oi.value = null, vi(!1, null);
1071
+ }
1072
+ let $ = O(null), hi = b(() => {
1073
+ let e = $.value, t = e == null ? null : xr(e);
1074
+ return Y.value.map((n) => ({
1075
+ slotAbsoluteIndex: n.absoluteIndex,
1076
+ shape: n.shape || "circle",
1077
+ name: n.name,
1078
+ color: n.color,
1079
+ value: e == null ? null : n.series.find((t, n) => n === e),
1080
+ sourceValue: t == null ? null : n.seriesSource?.[t],
1081
+ comments: n.comments || [],
1082
+ id: n.id,
1083
+ standalone: !!n.standalone
1084
+ }));
1085
+ });
1086
+ function gi(e) {
1087
+ if (e == null || !z.value.style.chart.tooltip.showTimeLabel) return null;
1088
+ let t = Br.value?.[e]?.text || null, n = Xr.value?.[e]?.text || null, r = Vr.value?.[e]?.text || null;
1089
+ return z.value.style.chart.tooltip.useDefaultTimeFormat ? t : n || r;
1090
+ }
1091
+ let _i = b(() => {
1092
+ let e = z.value.style.chart.tooltip.customFormat, t = [...hi.value].reverse(), n = t.filter((e) => !e.standalone), r = t.filter((e) => e.standalone), i = n.map((e) => e.value).filter((e) => f(e) && e !== null).reduce((e, t) => Math.abs(e) + Math.abs(t), 0);
1093
+ if (de(e) && te(() => e({
1094
+ absoluteIndex: $.value + q.value.start,
1095
+ seriesIndex: $.value,
1096
+ datapoint: hi.value,
1097
+ series: G.value,
1098
+ config: z.value
1099
+ }))) return e({
1100
+ absoluteIndex: $.value + q.value.start,
1101
+ seriesIndex: $.value,
1102
+ datapoint: hi.value,
1103
+ series: G.value,
1104
+ config: z.value
1105
+ });
1106
+ let { showValue: a, showTotal: o, totalTranslation: c, showPercentage: l, borderColor: u, roundingValue: d, roundingPercentage: p } = z.value.style.chart.tooltip, m = (e) => !e.shape || ![
1107
+ "star",
1108
+ "triangle",
1109
+ "square",
1110
+ "diamond",
1111
+ "pentagon",
1112
+ "hexagon"
1113
+ ].includes(e.shape) ? `<svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" fill="${e.color}" /></svg>` : e.shape === "star" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><polygon stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" fill="${e.color}" points="${fe({
1114
+ plot: {
1115
+ x: 6,
1116
+ y: 6
1117
+ },
1118
+ radius: 5
1119
+ })}" /></svg>` : e.shape === "triangle" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${s({
1120
+ plot: {
1121
+ x: 6,
1122
+ y: 6
1123
+ },
1124
+ radius: 6,
1125
+ sides: 3,
1126
+ rotation: .52
1127
+ }).path}" fill="${e.color}" stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>` : e.shape === "square" ? `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${s({
1128
+ plot: {
1129
+ x: 6,
1130
+ y: 6
1131
+ },
1132
+ radius: 6,
1133
+ sides: 4,
1134
+ rotation: .8
1135
+ }).path}" fill="${e.color}" stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>` : e.shape === "diamond" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${s({
1136
+ plot: {
1137
+ x: 6,
1138
+ y: 6
1139
+ },
1140
+ radius: 5,
1141
+ sides: 4,
1142
+ rotation: 0
1143
+ }).path}" fill="${e.color}" stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>` : e.shape === "pentagon" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${s({
1144
+ plot: {
1145
+ x: 6,
1146
+ y: 6
1147
+ },
1148
+ radius: 5,
1149
+ sides: 5,
1150
+ rotation: .95
1151
+ }).path}" fill="${e.color}" stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>` : `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${s({
1152
+ plot: {
1153
+ x: 6,
1154
+ y: 6
1155
+ },
1156
+ radius: 5,
1157
+ sides: 6,
1158
+ rotation: 0
1159
+ }).path}" fill="${e.color}" stroke="${z.value.style.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`, g = (e, t) => {
1160
+ let n = t ? h({
1161
+ v: isNaN((e.value ?? 0) / (i || 1)) ? 0 : Math.abs(e.value ?? 0) / (i || 1) * 100,
1162
+ s: "%",
1163
+ r: p
1164
+ }) : "", r = a && t ? "(" : "", o = a && t ? ")" : "";
1165
+ return `
1166
+ <div style="display:flex;flex-direction:row;align-items:center;gap:4px">
1167
+ <div style="width:20px;height:20px;display:flex;align-items:center;justify-content:center;">${m(e)}</div>
1168
+ ${e.name}${a || t ? ":" : ""}
1169
+ ${a ? v(z.value.style.chart.lines.dataLabels.formatter, e.sourceValue, h({
1170
+ p: z.value.style.chart.lines.dataLabels.prefix,
1171
+ v: e.sourceValue,
1172
+ s: z.value.style.chart.lines.dataLabels.suffix,
1173
+ r: d
1174
+ }, { datapoint: e })) : ""} ${r}${n}${o}
1175
+ </div>
1176
+ `;
1177
+ }, _ = "", ee = gi($.value);
1178
+ return ee && (_ += `<div style="width:100%;text-align:center;border-bottom:1px solid ${u};padding-bottom:6px;margin-bottom:3px;">${ee}</div>`), o && n.length > 1 && (_ += `<div class="vue-data-ui-tooltip-total" style="display:flex;flex-direction:row;align-items:center;gap:4px">
1179
+ <span>${c}:</span>
1180
+ <span>${v(z.value.style.chart.lines.dataLabels.formatter, ie(i), h({
1181
+ p: z.value.style.chart.lines.dataLabels.prefix,
1182
+ v: ie(i),
1183
+ s: z.value.style.chart.lines.dataLabels.suffix,
1184
+ r: d
1185
+ }), { datapoint: {
1186
+ name: c,
1187
+ value: ie(i)
1188
+ } })}</span>
1189
+ </div>`), n.forEach((e) => {
1190
+ _ += g(e, l);
1191
+ }), r.length && (_ += `<div style="border-top:1px solid ${vr.value.length ? u : "transparent"}; margin:${vr.value.length ? "6px 0" : "0"};"></div>`, r.forEach((e) => {
1192
+ _ += g(e, !1);
1193
+ })), `<div>${_}</div>`;
1194
+ });
1195
+ function vi(e, t = null, n = "pointer") {
1196
+ if (Ar.value) return;
1197
+ jn.value = n, nn.value = e;
1198
+ let r = Y.value.map((e) => ({
1199
+ name: e.name,
1200
+ value: [
1201
+ null,
1202
+ void 0,
1203
+ NaN
1204
+ ].includes(e.series[t]) ? null : e.series[t],
1205
+ color: e.color
1206
+ }));
1207
+ e ? (R.value = t, $.value = t, Zi({
1208
+ seriesIndex: t,
1209
+ datapoint: r
1210
+ }), z.value.events.datapointEnter && z.value.events.datapointEnter({
1211
+ datapoint: r,
1212
+ seriesIndex: t + q.value.start
1213
+ })) : (R.value = null, $.value = null, F("selectX", {
1214
+ index: null,
1215
+ indexLabel: null,
1216
+ dataset: null
1217
+ }), z.value.events.datapointLeave && z.value.events.datapointLeave({
1218
+ datapoint: r,
1219
+ seriesIndex: t + q.value.start
1220
+ }));
1221
+ }
1222
+ function yi(e, t) {
1223
+ let n = JSON.parse(JSON.stringify(Y.value)).map((e) => ({
1224
+ name: e.name,
1225
+ value: e.series[t] === 0 ? 0 : (e.signedSeries[t] === -1 && e.series[t] >= 0 ? -e.series[t] : e.series[t]) || null,
1226
+ proportion: e.proportions[t] || null,
1227
+ color: e.color,
1228
+ id: e.id
1229
+ }));
1230
+ F("selectTimeLabel", {
1231
+ datapoint: n,
1232
+ absoluteIndex: e.absoluteIndex,
1233
+ label: e.text
1234
+ });
1235
+ }
1236
+ function bi() {
1237
+ L.value.length ? L.value = [] : Si.value.forEach((e) => {
1238
+ L.value.push(e.id);
1239
+ }), F("selectLegend", Y.value);
1240
+ }
1241
+ function xi(e) {
1242
+ if (L.value.includes(e.id)) L.value = L.value.filter((t) => t !== e.id);
1243
+ else {
1244
+ if (L.value.length === G.value.length - 1) return;
1245
+ L.value.push(e.id);
1246
+ }
1247
+ F("selectLegend", Y.value);
1248
+ }
1249
+ let Si = b(() => G.value.map((e) => ({
1250
+ ...e,
1251
+ opacity: L.value.includes(e.id) ? .5 : 1,
1252
+ segregate: () => xi(e),
1253
+ isSegregated: L.value.includes(e.id)
1254
+ }))), Ci = b(() => ({
1255
+ cy: "stackline-legend",
1256
+ backgroundColor: z.value.style.chart.legend.backgroundColor,
1257
+ color: z.value.style.chart.legend.color,
1258
+ fontSize: z.value.style.chart.legend.fontSize,
1259
+ paddingBottom: 12,
1260
+ fontWeight: z.value.style.chart.legend.bold ? "bold" : ""
1261
+ }));
1262
+ function wi(e) {
1263
+ return G.value.length ? G.value.find((t) => t.name === e) || (z.value.debug && console.warn(`VueUiStackline - Series name not found "${e}"`), null) : (z.value.debug && console.warn("VueUiStackline - There are no series to show."), null);
1264
+ }
1265
+ function Ti(e) {
1266
+ let t = wi(e);
1267
+ t !== null && L.value.includes(t.id) && xi({ id: t.id });
1268
+ }
1269
+ function Ei(e) {
1270
+ let t = wi(e);
1271
+ t !== null && (L.value.includes(t.id) || xi({ id: t.id }));
1272
+ }
1273
+ let Di = b(() => {
1274
+ if (Y.value.length === 0) return {
1275
+ head: [],
1276
+ body: [],
1277
+ config: {},
1278
+ columnNames: []
1279
+ };
1280
+ let e = Y.value.map(({ name: e, color: t }) => ({
1281
+ label: e,
1282
+ color: t
1283
+ })), t = [];
1284
+ return Gr.value.forEach((e) => {
1285
+ let n = e.absoluteIndex, r = [z.value.style.chart.grid.x.timeLabels.values?.[n] ? e.text : n + 1];
1286
+ G.value.forEach((e) => {
1287
+ let t = e.series?.[n], i = Number((t ?? 0).toFixed(z.value.table.td.roundingValue));
1288
+ r.push(i);
1289
+ }), t.push(r);
1290
+ }), {
1291
+ head: e,
1292
+ body: t
1293
+ };
1294
+ });
1295
+ function Oi(e = null) {
1296
+ let n = [
1297
+ [z.value.style.chart.title.text],
1298
+ [z.value.style.chart.title.subtitle.text],
1299
+ [""]
1300
+ ], i = ["", ...Di.value.head.map((e) => e.label)], a = Di.value.body, o = r(n.concat([i]).concat(a));
1301
+ e ? e(o) : t({
1302
+ csvContent: o,
1303
+ title: z.value.style.chart.title.text || "vue-ui-stackline"
1304
+ });
1305
+ }
1306
+ let ki = b(() => {
1307
+ let e = [""].concat(Y.value.map((e) => e.name), " <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" fill=\"none\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"/><path d=\"M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2\" /></svg>"), t = [], n = Math.max(0, q.value.end - q.value.start);
1308
+ for (let e = 0; e < n; e += 1) {
1309
+ let n = xr(e), r = z.value.style.chart.grid.x.timeLabels.values?.[n] ? Br.value?.[e]?.text ?? n + 1 : n + 1, i = Y.value.map((t) => {
1310
+ let n = t.series?.[e] ?? 0;
1311
+ return Number(n.toFixed(z.value.table.td.roundingValue));
1312
+ }), a = Y.value.filter((e) => !e.standalone).map((t) => t.series?.[e] ?? 0).reduce((e, t) => e + t, 0);
1313
+ t.push([r].concat(i, Number(a.toFixed(z.value.table.td.roundingValue))));
1314
+ }
1315
+ return {
1316
+ head: e,
1317
+ body: t,
1318
+ config: {
1319
+ th: {
1320
+ backgroundColor: z.value.table.th.backgroundColor,
1321
+ color: z.value.table.th.color,
1322
+ outline: z.value.table.th.outline
1323
+ },
1324
+ td: {
1325
+ backgroundColor: z.value.table.td.backgroundColor,
1326
+ color: z.value.table.td.color,
1327
+ outline: z.value.table.td.outline
1328
+ },
1329
+ breakpoint: z.value.table.responsiveBreakpoint
1330
+ },
1331
+ colNames: [z.value.table.columnNames.period].concat(Y.value.map((e) => e.name), z.value.table.columnNames.total)
1332
+ };
1333
+ }), Ai = b(() => z.value.style.chart.backgroundColor), ji = b(() => z.value.style.chart.legend), { exportSvg: Mi, getSvg: Ni } = Se({
1334
+ svg: V,
1335
+ title: b(() => z.value.style.chart.title),
1336
+ legend: ji,
1337
+ legendItems: Si,
1338
+ backgroundColor: Ai
1339
+ });
1340
+ async function Pi({ isCb: e }) {
1341
+ bn.value = !0, await Je();
1342
+ try {
1343
+ if (e) {
1344
+ let { blob: e, url: t, text: n, dataUrl: r } = await Ni();
1345
+ await Promise.resolve(z.value.userOptions.callbacks.svg({
1346
+ blob: e,
1347
+ url: t,
1348
+ text: n,
1349
+ dataUrl: r
1350
+ }));
1351
+ } else await Promise.resolve(Mi());
1352
+ } finally {
1353
+ bn.value = !1;
1354
+ }
1355
+ }
1356
+ async function Fi({ scale: e = 2 } = {}) {
1357
+ if (!tn.value) return;
1358
+ let { imageUri: t, base64: n } = await Oe({
1359
+ domElement: tn.value,
1360
+ base64: !0,
1361
+ img: !0,
1362
+ scale: e
1363
+ }), r = tn.value.getBoundingClientRect(), i = {
1364
+ width: r.width,
1365
+ height: r.height,
1366
+ aspectRatio: r.height ? r.width / r.height : 0
1367
+ }, a = await ne(t, e) ?? i;
1368
+ return {
1369
+ imageUri: t,
1370
+ base64: n,
1371
+ title: z.value.style.chart.title.text,
1372
+ ...a
1373
+ };
1374
+ }
1375
+ let Ii = b(() => {
1376
+ let e = z.value.table.useDialog && !z.value.table.show, t = H.value.showTable;
1377
+ return {
1378
+ component: e ? Yt : Wt,
1379
+ title: `${z.value.style.chart.title.text}${z.value.style.chart.title.subtitle.text ? `: ${z.value.style.chart.title.subtitle.text}` : ""}`,
1380
+ props: e ? {
1381
+ backgroundColor: z.value.table.th.backgroundColor,
1382
+ color: z.value.table.th.color,
1383
+ headerColor: z.value.table.th.color,
1384
+ headerBg: z.value.table.th.backgroundColor,
1385
+ isFullscreen: un.value,
1386
+ fullscreenParent: tn.value,
1387
+ forcedWidth: Math.min(800, window.innerWidth * .8),
1388
+ isCursorPointer: B.value
1389
+ } : {
1390
+ hideDetails: !0,
1391
+ config: {
1392
+ open: t,
1393
+ maxHeight: 1e4,
1394
+ body: {
1395
+ backgroundColor: z.value.style.chart.backgroundColor,
1396
+ color: z.value.style.chart.color
1397
+ },
1398
+ head: {
1399
+ backgroundColor: z.value.style.chart.backgroundColor,
1400
+ color: z.value.style.chart.color
1401
+ }
1402
+ }
1403
+ }
1404
+ };
1405
+ });
1406
+ rt(() => H.value.showTable, (e) => {
1407
+ z.value.table.show || (e && z.value.table.useDialog && gn.value ? gn.value.open() : "close" in gn.value && gn.value.close());
1408
+ });
1409
+ function Li() {
1410
+ H.value.showTable = !1, _n.value && _n.value.setTableIconState(!1);
1411
+ }
1412
+ function Ri(e) {
1413
+ un.value = e, rn.value += 1;
1414
+ }
1415
+ function zi() {
1416
+ H.value.showTable = !H.value.showTable;
1417
+ }
1418
+ function Bi() {
1419
+ H.value.dataLabels.show = !H.value.dataLabels.show;
1420
+ }
1421
+ function Vi() {
1422
+ H.value.showTooltip = !H.value.showTooltip;
1423
+ }
1424
+ function Hi() {
1425
+ return Y.value;
1426
+ }
1427
+ function Ui(e) {
1428
+ let t = e ?? 0, n = xr(t);
1429
+ return JSON.parse(JSON.stringify(Y.value)).map((e) => {
1430
+ let r = e.series[t], i = e.signedSeries?.[t], a = r === 0 ? 0 : (i === -1 && r >= 0 ? -r : r) || null;
1431
+ return {
1432
+ name: e.name,
1433
+ absoluteIndex: e.absoluteIndex,
1434
+ value: a,
1435
+ proportion: e.proportions?.[t] || null,
1436
+ color: e.color,
1437
+ id: e.id,
1438
+ timeLabel: Vr.value?.[n] || null
1439
+ };
1440
+ });
1441
+ }
1442
+ let Wi = b(() => Array(K.value).fill(0).map((e, t) => Ui(t)));
1443
+ rt(() => P.selectedXIndex, (e) => {
1444
+ if ([null, void 0].includes(P.selectedXIndex)) {
1445
+ $.value = null;
1446
+ return;
1447
+ }
1448
+ let t = e - q.value.start;
1449
+ t < 0 || e >= q.value.end ? $.value = null : $.value = t ?? null;
1450
+ }, { immediate: !0 });
1451
+ let Gi = b(() => {
1452
+ if (z.value.style.chart.lines.distributed) return {
1453
+ min: -1,
1454
+ max: 1
1455
+ };
1456
+ let e = vr.value, t = yr.value, n = Math.max(1, ...[...e, ...t].map((e) => e.series?.length || 0)), r = Array(n).fill(0), i = Array(n).fill(0);
1457
+ e.forEach((e) => {
1458
+ for (let t = 0; t < n; t += 1) {
1459
+ let n = e.series[t] ?? 0;
1460
+ n >= 0 ? r[t] += n : i[t] += n;
1461
+ }
1462
+ });
1463
+ let a = Array(n).fill(0), o = Array(n).fill(0);
1464
+ t.forEach((e) => {
1465
+ for (let t = 0; t < n; t += 1) {
1466
+ let n = e.series[t] ?? 0;
1467
+ n > 0 && (a[t] = Math.max(a[t], n)), n < 0 && (o[t] = Math.min(o[t], n));
1468
+ }
1469
+ });
1470
+ let s = Math.max(0, ...r, ...a), c = Math.min(0, ...i, ...o), l = z.value.style.chart.grid.scale.scaleMin, u = z.value.style.chart.grid.scale.scaleMax, d = z.value.style.chart.grid.scale.ticks, f = !z.value.style.chart.lines.distributed && (l !== null || u !== null) ? le(l === null ? c > 0 ? 0 : c : l, u === null ? s < 0 ? 0 : s : u, d) : g(l === null ? c > 0 ? 0 : c : l, u === null ? s < 0 ? 0 : s : u, d);
1471
+ return {
1472
+ min: Number(f.min) || 0,
1473
+ max: Number(f.max) || 0
1474
+ };
1475
+ });
1476
+ function Ki({ minimapH: e, unitW: t }) {
1477
+ let n = (e) => typeof e == "string" ? e.replace(/^M\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*,?\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*/i, "").trim() : "";
1478
+ if (!Number.isFinite(e) || e <= 0 || !Number.isFinite(t) || t <= 0) return "";
1479
+ let r = Y.value.filter((e) => !e.standalone), i = Y.value.filter((e) => e.standalone), a = Math.max(0, ...Y.value.map((e) => Array.isArray(e.fullSeries) ? e.fullSeries.length : e.series.length));
1480
+ if (a <= 0) return "";
1481
+ let o = a === 1 ? [t * .5] : Array.from({ length: a }, (e, n) => n * t);
1482
+ if (z.value.style.chart.lines.distributed) {
1483
+ let t = Array.from({ length: a }, (e, t) => {
1484
+ let n = 0;
1485
+ return r.forEach((e) => {
1486
+ let r = (Array.isArray(e.fullSeries) ? e.fullSeries : e.series)?.[t];
1487
+ r != null && !Number.isNaN(r) && (n += Math.abs(r));
1488
+ }), n || 1;
1489
+ }), s = (t) => e - e * Math.max(0, Math.min(1, t || 0)), c = [], u = Array(a).fill(0);
1490
+ return r.forEach((e) => {
1491
+ let r = Array.isArray(e.fullSeries) ? e.fullSeries : e.series, i = Array(a), d = Array(a);
1492
+ for (let e = 0; e < a; e += 1) {
1493
+ let n = r?.[e], a = n == null || Number.isNaN(n) ? 0 : Math.abs(n) / t[e];
1494
+ d[e] = u[e], u[e] += a, i[e] = u[e];
1495
+ }
1496
+ let f = i.map(s), m = d.map(s), h = o.map((e, t) => ({
1497
+ x: e,
1498
+ y: f[t]
1499
+ })), g = o.map((e, t) => ({
1500
+ x: e,
1501
+ y: m[t]
1502
+ })), _ = l(h), ee = l([...g].reverse()), te = p(h), ne = p([...g].reverse()), v = g[g.length - 1];
1503
+ if (z.value.style.chart.lines.useArea) {
1504
+ let t = z.value.style.chart.lines.smooth ? `M${h[0].x},${h[0].y} ${n(_)} L${v.x},${v.y} ${n(ee)} Z` : `M${h[0].x},${h[0].y} ${n(te)} L${v.x},${v.y} ${n(ne)} Z`;
1505
+ c.push(`<path d="${t}"
1506
+ fill="${$t.pattern ? `url(#pattern_${I.value}_${e.absoluteIndex})` : (z.value.style.chart.lines.gradient.show, e.color)}"
1507
+ opacity="${z.value.style.chart.lines.areaOpacity}"
1508
+ stroke="none" />`);
1509
+ }
1510
+ let re = z.value.style.chart.lines.smooth ? `M${h[0].x},${h[0].y} ${n(_)}` : `M${h[0].x},${h[0].y} ${n(te)}`;
1511
+ c.push(`<path d="${re}"
1512
+ fill="none"
1513
+ stroke="${e.color}"
1514
+ stroke-width="${z.value.style.chart.lines.strokeWidth}"
1515
+ stroke-linecap="round" />`);
1516
+ }), i.length && i.forEach((e) => {
1517
+ let r = Array.isArray(e.fullSeries) ? e.fullSeries : e.series, i = Array.from({ length: a }, (e, n) => s(Math.abs(r?.[n] ?? 0) / t[n])), u = o.map((e, t) => ({
1518
+ x: e,
1519
+ y: i[t]
1520
+ })), d = l(u), f = p(u), m = z.value.style.chart.lines.smooth ? `M${u[0].x},${u[0].y} ${n(d)}` : `M${u[0].x},${u[0].y} ${n(f)}`;
1521
+ c.push(`<path d="${m}"
1522
+ fill="none"
1523
+ stroke="${e.color}"
1524
+ stroke-width="${z.value.style.chart.lines.strokeWidth}"
1525
+ stroke-linecap="round" />`);
1526
+ }), c.join("");
1527
+ }
1528
+ let s = Gi.value.min, c = Gi.value.max, u = Math.abs(s), d = c + u || 1, f = (t) => Math.max(0, Math.min(e, t)), m = (t) => f(e - e * (((t ?? 0) + u) / d)), h = [];
1529
+ if (r.length) {
1530
+ let e = Array(a).fill(0), t = Array(a).fill(0);
1531
+ r.forEach((r) => {
1532
+ let i = Array.isArray(r.fullSeries) ? r.fullSeries : r.series, s = Array(a), c = Array(a);
1533
+ for (let n = 0; n < a; n += 1) {
1534
+ let r = i?.[n] ?? 0;
1535
+ r >= 0 ? (c[n] = e[n], e[n] += r, s[n] = e[n]) : (c[n] = t[n], t[n] += r, s[n] = t[n]);
1536
+ }
1537
+ let u = s.map(m), d = c.map(m), f = o.map((e, t) => ({
1538
+ x: e,
1539
+ y: u[t]
1540
+ })), g = o.map((e, t) => ({
1541
+ x: e,
1542
+ y: d[t]
1543
+ })), _ = l(f), ee = l([...g].reverse()), te = p(f), ne = p([...g].reverse()), v = g[g.length - 1];
1544
+ if (z.value.style.chart.lines.useArea) {
1545
+ let e = z.value.style.chart.lines.smooth ? `M${f[0].x},${f[0].y} ${n(_)} L${v.x},${v.y} ${n(ee)} Z` : `M${f[0].x},${f[0].y} ${n(te)} L${v.x},${v.y} ${n(ne)} Z`;
1546
+ h.push(`<path d="${e}"
1547
+ fill="${$t.pattern ? `url(#pattern_${I.value}_${r.absoluteIndex})` : (z.value.style.chart.lines.gradient.show, r.color)}"
1548
+ opacity="${z.value.style.chart.lines.areaOpacity}"
1549
+ stroke="none" />`);
1550
+ }
1551
+ let re = z.value.style.chart.lines.smooth ? `M${f[0].x},${f[0].y} ${n(_)}` : `M${f[0].x},${f[0].y} ${n(te)}`;
1552
+ h.push(`<path d="${re}"
1553
+ fill="none"
1554
+ stroke="${r.color}"
1555
+ stroke-width="${z.value.style.chart.lines.strokeWidth}"
1556
+ stroke-linecap="round" />`);
1557
+ });
1558
+ }
1559
+ return i.length && i.forEach((e) => {
1560
+ let t = (Array.isArray(e.fullSeries) ? e.fullSeries : e.series).map(m), r = o.map((e, n) => ({
1561
+ x: e,
1562
+ y: t[n]
1563
+ })), i = l(r), a = p(r), s = z.value.style.chart.lines.smooth ? `M${r[0].x},${r[0].y} ${n(i)}` : `M${r[0].x},${r[0].y} ${n(a)}`;
1564
+ h.push(`<path d="${s}"
1565
+ fill="none"
1566
+ stroke="${e.color}"
1567
+ stroke-width="${z.value.style.chart.lines.strokeWidth}"
1568
+ stroke-linecap="round" />`);
1569
+ }), h.join("");
1570
+ }
1571
+ function qi(e, t) {
1572
+ let n = z.value.style.chart.lines, r = n.dataLabels;
1573
+ return n.showDistributedPercentage && n.distributed ? Zn.value ? t === 0 ? !r.hideEmptyPercentages : Math.abs(t) * 100 >= r.hideUnderPercentage : !r.hideEmptyPercentages || Math.abs(t) > 0 : Zn.value ? (Xn.value && sr.value && console.warn("Vue Data UI - VueUiStackline - You cannot set both dataLabels.hideUnderPercentage and dataLabels.hideUnderValue. Note that dataLabels.hideUnderPercentage takes precedence in this case."), Math.abs(e) > Ji.value * r.hideUnderPercentage / 100) : Xn.value ? Math.abs(e) >= r.hideUnderValue : !r.hideEmptyValues || e !== 0;
1574
+ }
1575
+ let Ji = b(() => Math.max(...Y.value.flatMap((e) => e.series)));
1576
+ function Yi(e, t, n, r, i) {
1577
+ let a = i === -1 && e >= 0 ? -e : e;
1578
+ return v(z.value.style.chart.lines.dataLabels.formatter, a, h({
1579
+ p: z.value.style.chart.lines.dataLabels.prefix,
1580
+ v: a,
1581
+ s: z.value.style.chart.lines.dataLabels.suffix,
1582
+ r: z.value.style.chart.lines.dataLabels.rounding
1583
+ }), {
1584
+ datapoint: t,
1585
+ seriesIndex: n,
1586
+ datapointIndex: r
1587
+ });
1588
+ }
1589
+ function Xi(e, t, n, r) {
1590
+ return v(z.value.style.chart.lines.dataLabels.formatter, e, h({
1591
+ v: isNaN(e) ? 0 : e,
1592
+ s: "%",
1593
+ r: z.value.style.chart.lines.dataLabels.rounding
1594
+ }), {
1595
+ datapoint: t,
1596
+ seriesIndex: n,
1597
+ datapointIndex: r
1598
+ });
1599
+ }
1600
+ function Zi({ seriesIndex: e, datapoint: t }) {
1601
+ let n = q.value.start + e;
1602
+ F("selectX", {
1603
+ dataset: t,
1604
+ index: n,
1605
+ indexLabel: z.value.style.chart.grid.x.timeLabels.values[n]
1606
+ });
1607
+ }
1608
+ function Qi(e) {
1609
+ if (e?.stage === "start") {
1610
+ yn.value = !0;
1611
+ return;
1612
+ }
1613
+ if (e?.stage === "end") {
1614
+ yn.value = !1;
1615
+ return;
1616
+ }
1617
+ tr();
1618
+ }
1619
+ async function $i() {
1620
+ if (F("copyAlt", {
1621
+ config: z.value,
1622
+ dataset: Y.value
1623
+ }), !z.value.userOptions.callbacks.altCopy) {
1624
+ console.warn("Vue Data UI - A callback must be set for `altCopy` in userOptions.");
1625
+ return;
1626
+ }
1627
+ await Promise.resolve(z.value.userOptions.callbacks.altCopy({
1628
+ config: z.value,
1629
+ dataset: Y.value
1630
+ }));
1631
+ }
1632
+ let ea = O(!1);
1633
+ function ta() {
1634
+ R.value = null, ea.value = !0;
1635
+ }
1636
+ function na() {
1637
+ R.value = null, jn.value = "pointer", nn.value = !1, $.value = null, F("selectX", {
1638
+ index: null,
1639
+ indexLabel: null,
1640
+ dataset: null
1641
+ }), ea.value = !1;
1642
+ }
1643
+ function ra(e) {
1644
+ if (!V.value || Ln.value || document.activeElement !== V.value || Ar.value || !Z.value) return;
1645
+ let t = e.key === "ArrowLeft", n = e.key === "ArrowRight", r = e.key === "Enter" || e.key === " ", i = e.key === "Escape";
1646
+ if (!t && !n && !r && !i) return;
1647
+ if (e.preventDefault(), e.stopPropagation(), i) {
1648
+ R.value = null, jn.value = "pointer", nn.value = !1, $.value = null, F("selectX", {
1649
+ index: null,
1650
+ indexLabel: null,
1651
+ dataset: null
1652
+ });
1653
+ return;
1654
+ }
1655
+ if (r) {
1656
+ if (R.value === null) return;
1657
+ pi(R.value);
1658
+ return;
1659
+ }
1660
+ let a = R.value, o = oi.value, s = a !== null && a >= 0 && a < Z.value, c = o !== null && o >= 0 && o < Z.value;
1661
+ s ? n ? (a += 1, a >= Z.value && (a = 0)) : t && (--a, a < 0 && (a = Z.value - 1)) : c ? (a = n ? o + 1 : o - 1, a >= Z.value && (a = 0), a < 0 && (a = Z.value - 1)) : a = n ? 0 : Z.value - 1, R.value = a, ia(a), vi(!0, a, "keyboard");
1662
+ }
1663
+ function ia(e) {
1664
+ if (!Number.isFinite(e) || !V.value) return;
1665
+ let t = i(W.value.left + e * li.value, W.value.top + W.value.height / 2, V.value);
1666
+ t && (An.value = t);
1667
+ }
1668
+ let aa = b(() => ({
1669
+ headers: ki.value?.colNames ?? [],
1670
+ rows: ki.value?.body ?? []
1671
+ }));
1672
+ return je({
1673
+ getData: Hi,
1674
+ getImage: Fi,
1675
+ generatePdf: er,
1676
+ generateCsv: Oi,
1677
+ generateImage: tr,
1678
+ generateSvg: Pi,
1679
+ hideSeries: Ei,
1680
+ showSeries: Ti,
1681
+ toggleTable: zi,
1682
+ toggleLabels: Bi,
1683
+ toggleTooltip: Vi,
1684
+ toggleAnnotator: Rn,
1685
+ toggleFullscreen: Ri,
1686
+ copyAlt: $i
1687
+ }), (t, r) => (D(), C("div", {
1688
+ id: `stackline_${I.value}`,
1689
+ ref_key: "stacklineChart",
1690
+ ref: tn,
1691
+ class: Ye({
1692
+ "vue-data-ui-component": !0,
1693
+ "vue-ui-stackline": !0,
1694
+ "vue-data-ui-wrapper-fullscreen": un.value
1695
+ }),
1696
+ style: Xe(`background:${z.value.style.chart.backgroundColor};color:${z.value.style.chart.color};font-family:${z.value.style.fontFamily}; position: relative; ${z.value.responsive ? "height: 100%" : ""}`),
1697
+ onMouseenter: qn,
1698
+ onMouseleave: Jn
1699
+ }, [
1700
+ w("div", {
1701
+ id: `chart-instructions-${I.value}`,
1702
+ class: "sr-only"
1703
+ }, [w("p", null, j(z.value.a11y.translations.keyboardNavigation), 1)], 8, st),
1704
+ aa.value?.rows?.length ? (D(), x(Le, {
1705
+ key: 0,
1706
+ uid: I.value,
1707
+ head: aa.value.headers,
1708
+ body: aa.value.rows,
1709
+ notice: z.value.a11y.translations.tableAvailable,
1710
+ caption: z.value.a11y.translations.tableCaption
1711
+ }, null, 8, [
1712
+ "uid",
1713
+ "head",
1714
+ "body",
1715
+ "notice",
1716
+ "caption"
1717
+ ])) : S("", !0),
1718
+ z.value.userOptions.buttons.annotator ? (D(), x(M(Kt), {
1719
+ key: 1,
1720
+ svgRef: M(V),
1721
+ backgroundColor: z.value.style.chart.backgroundColor,
1722
+ color: z.value.style.chart.color,
1723
+ active: Ln.value,
1724
+ isCursorPointer: B.value,
1725
+ onClose: Rn
1726
+ }, {
1727
+ "annotator-action-close": N(() => [A(t.$slots, "annotator-action-close", {}, void 0, !0)]),
1728
+ "annotator-action-color": N(({ color: e }) => [A(t.$slots, "annotator-action-color", E(T({ color: e })), void 0, !0)]),
1729
+ "annotator-action-draw": N(({ mode: e }) => [A(t.$slots, "annotator-action-draw", E(T({ mode: e })), void 0, !0)]),
1730
+ "annotator-action-undo": N(({ disabled: e }) => [A(t.$slots, "annotator-action-undo", E(T({ disabled: e })), void 0, !0)]),
1731
+ "annotator-action-redo": N(({ disabled: e }) => [A(t.$slots, "annotator-action-redo", E(T({ disabled: e })), void 0, !0)]),
1732
+ "annotator-action-delete": N(({ disabled: e }) => [A(t.$slots, "annotator-action-delete", E(T({ disabled: e })), void 0, !0)]),
1733
+ _: 3
1734
+ }, 8, [
1735
+ "svgRef",
1736
+ "backgroundColor",
1737
+ "color",
1738
+ "active",
1739
+ "isCursorPointer"
1740
+ ])) : S("", !0),
1741
+ A(t.$slots, "userConfig", {}, void 0, !0),
1742
+ nr.value ? (D(), C("div", {
1743
+ key: 2,
1744
+ ref_key: "noTitle",
1745
+ ref: cn,
1746
+ class: "vue-data-ui-no-title-space",
1747
+ style: "height:36px; width: 100%;background:transparent"
1748
+ }, null, 512)) : S("", !0),
1749
+ z.value.style.chart.title.text ? (D(), C("div", {
1750
+ key: 3,
1751
+ ref_key: "chartTitle",
1752
+ ref: an,
1753
+ style: "width:100%;background:transparent;"
1754
+ }, [(D(), x(ke, {
1755
+ key: `title_${fn.value}`,
1756
+ config: {
1757
+ title: {
1758
+ cy: "stackline-title",
1759
+ ...z.value.style.chart.title
1760
+ },
1761
+ subtitle: {
1762
+ cy: "stackline-subtitle",
1763
+ ...z.value.style.chart.title.subtitle
1764
+ }
1765
+ }
1766
+ }, null, 8, ["config"]))], 512)) : S("", !0),
1767
+ w("div", { id: `legend-top-${I.value}` }, null, 8, ct),
1768
+ z.value.userOptions.show && en.value && (M(Kn) || M(Wn)) ? (D(), x(M(qt), {
1769
+ ref_key: "userOptionsRef",
1770
+ ref: _n,
1771
+ key: `user_option_${rn.value}`,
1772
+ backgroundColor: z.value.style.chart.backgroundColor,
1773
+ color: z.value.style.chart.color,
1774
+ isPrinting: M(Qn),
1775
+ isImaging: M($n),
1776
+ uid: I.value,
1777
+ hasTooltip: z.value.style.chart.tooltip.show && z.value.userOptions.buttons.tooltip,
1778
+ hasPdf: z.value.userOptions.buttons.pdf,
1779
+ hasImg: z.value.userOptions.buttons.img,
1780
+ hasSvg: z.value.userOptions.buttons.svg,
1781
+ hasXls: z.value.userOptions.buttons.csv,
1782
+ hasTable: z.value.userOptions.buttons.table,
1783
+ hasLabel: z.value.userOptions.buttons.labels,
1784
+ hasFullscreen: z.value.userOptions.buttons.fullscreen,
1785
+ hasAltCopy: z.value.userOptions.buttons.altCopy,
1786
+ isFullscreen: un.value,
1787
+ chartElement: tn.value,
1788
+ position: z.value.userOptions.position,
1789
+ isTooltip: H.value.showTooltip,
1790
+ titles: { ...z.value.userOptions.buttonTitles },
1791
+ hasAnnotator: z.value.userOptions.buttons.annotator,
1792
+ isAnnotation: Ln.value,
1793
+ callbacks: z.value.userOptions.callbacks,
1794
+ printScale: z.value.userOptions.print.scale,
1795
+ tableDialog: z.value.table.useDialog,
1796
+ isCursorPointer: B.value,
1797
+ onToggleFullscreen: Ri,
1798
+ onGeneratePdf: M(er),
1799
+ onGenerateCsv: Oi,
1800
+ onGenerateImage: Qi,
1801
+ onGenerateSvg: Pi,
1802
+ onToggleTable: zi,
1803
+ onToggleLabels: Bi,
1804
+ onToggleTooltip: Vi,
1805
+ onToggleAnnotator: Rn,
1806
+ onCopyAlt: $i,
1807
+ style: Xe({ visibility: M(Kn) ? M(Wn) ? "visible" : "hidden" : "visible" })
1808
+ }, Ue({ _: 2 }, [
1809
+ t.$slots.menuIcon ? {
1810
+ name: "menuIcon",
1811
+ fn: N(({ isOpen: e, color: n }) => [A(t.$slots, "menuIcon", E(T({
1812
+ isOpen: e,
1813
+ color: n
1814
+ })), void 0, !0)]),
1815
+ key: "0"
1816
+ } : void 0,
1817
+ t.$slots.optionTooltip ? {
1818
+ name: "optionTooltip",
1819
+ fn: N(() => [A(t.$slots, "optionTooltip", {}, void 0, !0)]),
1820
+ key: "1"
1821
+ } : void 0,
1822
+ t.$slots.optionPdf ? {
1823
+ name: "optionPdf",
1824
+ fn: N(() => [A(t.$slots, "optionPdf", {}, void 0, !0)]),
1825
+ key: "2"
1826
+ } : void 0,
1827
+ t.$slots.optionCsv ? {
1828
+ name: "optionCsv",
1829
+ fn: N(() => [A(t.$slots, "optionCsv", {}, void 0, !0)]),
1830
+ key: "3"
1831
+ } : void 0,
1832
+ t.$slots.optionImg ? {
1833
+ name: "optionImg",
1834
+ fn: N(() => [A(t.$slots, "optionImg", {}, void 0, !0)]),
1835
+ key: "4"
1836
+ } : void 0,
1837
+ t.$slots.optionSvg ? {
1838
+ name: "optionSvg",
1839
+ fn: N(() => [A(t.$slots, "optionSvg", {}, void 0, !0)]),
1840
+ key: "5"
1841
+ } : void 0,
1842
+ t.$slots.optionTable ? {
1843
+ name: "optionTable",
1844
+ fn: N(() => [A(t.$slots, "optionTable", {}, void 0, !0)]),
1845
+ key: "6"
1846
+ } : void 0,
1847
+ t.$slots.optionLabels ? {
1848
+ name: "optionLabels",
1849
+ fn: N(() => [A(t.$slots, "optionLabels", {}, void 0, !0)]),
1850
+ key: "7"
1851
+ } : void 0,
1852
+ t.$slots.optionFullscreen ? {
1853
+ name: "optionFullscreen",
1854
+ fn: N(({ toggleFullscreen: e, isFullscreen: n }) => [A(t.$slots, "optionFullscreen", E(T({
1855
+ toggleFullscreen: e,
1856
+ isFullscreen: n
1857
+ })), void 0, !0)]),
1858
+ key: "8"
1859
+ } : void 0,
1860
+ t.$slots.optionAnnotator ? {
1861
+ name: "optionAnnotator",
1862
+ fn: N(({ toggleAnnotator: e, isAnnotator: n }) => [A(t.$slots, "optionAnnotator", E(T({
1863
+ toggleAnnotator: e,
1864
+ isAnnotator: n
1865
+ })), void 0, !0)]),
1866
+ key: "9"
1867
+ } : void 0,
1868
+ t.$slots.optionAltCopy ? {
1869
+ name: "optionAltCopy",
1870
+ fn: N(({ altCopy: e }) => [A(t.$slots, "optionAltCopy", E(T({ altCopy: e })), void 0, !0)]),
1871
+ key: "10"
1872
+ } : void 0,
1873
+ t.$slots["custom-menu-before"] ? {
1874
+ name: "custom-menu-before",
1875
+ fn: N(() => [A(t.$slots, "custom-menu-before", {}, void 0, !0)]),
1876
+ key: "11"
1877
+ } : void 0,
1878
+ t.$slots["custom-menu-after"] ? {
1879
+ name: "custom-menu-after",
1880
+ fn: N(() => [A(t.$slots, "custom-menu-after", {}, void 0, !0)]),
1881
+ key: "12"
1882
+ } : void 0
1883
+ ]), 1032, /* @__PURE__ */ "backgroundColor.color.isPrinting.isImaging.uid.hasTooltip.hasPdf.hasImg.hasSvg.hasXls.hasTable.hasLabel.hasFullscreen.hasAltCopy.isFullscreen.chartElement.position.isTooltip.titles.hasAnnotator.isAnnotation.callbacks.printScale.tableDialog.isCursorPointer.onGeneratePdf.style".split("."))) : S("", !0),
1884
+ w("div", lt, [(D(), C("svg", {
1885
+ ref_key: "svgRef",
1886
+ ref: V,
1887
+ "aria-describedby": `chart-instructions-${I.value}`,
1888
+ xmlns: M(se),
1889
+ viewBox: `0 0 ${W.value.chartWidth <= 0 ? 10 : W.value.chartWidth} ${W.value.chartHeight <= 0 ? 10 : W.value.chartHeight}`,
1890
+ class: Ye({
1891
+ "vue-data-ui-loading": M(Vn),
1892
+ "vue-data-ui-fullscreen--on": un.value,
1893
+ "vue-data-ui-fulscreen--off": !un.value,
1894
+ "vue-data-ui-no-transition": !M(zn)
1895
+ }),
1896
+ style: Xe(`max-width:100%;overflow:visible;background:transparent;color:${z.value.style.chart.color}`),
1897
+ role: "img",
1898
+ "aria-live": "polite",
1899
+ tabindex: "0",
1900
+ preserveAspectRatio: "xMidYMid",
1901
+ onMousemove: di,
1902
+ onMouseleave: mi,
1903
+ onClick: fi,
1904
+ onFocus: ta,
1905
+ onBlur: na,
1906
+ onKeydown: ra
1907
+ }, [
1908
+ Ge(M(Jt)),
1909
+ (D(!0), C(y, null, k(vr.value, (e) => (D(), C(y, null, [t.$slots.pattern ? (D(), C("defs", dt, [A(t.$slots, "pattern", qe({ ref_for: !0 }, {
1910
+ seriesIndex: e.absoluteIndex,
1911
+ patternId: `pattern_${I.value}_${e.absoluteIndex}`
1912
+ }), void 0, !0)])) : S("", !0)], 64))), 256)),
1913
+ t.$slots["chart-background"] ? (D(), C("foreignObject", {
1914
+ key: 0,
1915
+ x: X.value.left,
1916
+ y: W.value.top,
1917
+ width: X.value.width,
1918
+ height: W.value.height,
1919
+ style: { pointerEvents: "none" }
1920
+ }, [A(t.$slots, "chart-background", {}, void 0, !0)], 8, ft)) : S("", !0),
1921
+ z.value.style.chart.lines.gradient.show ? (D(), C("defs", pt, [(D(!0), C(y, null, k(Y.value, (e, t) => (D(), x(Pe, {
1922
+ t: "linear",
1923
+ id: `gradient_${e.id}`,
1924
+ key: `gradient_${e.id}_${t}`,
1925
+ x1: "0%",
1926
+ y1: "0%",
1927
+ x2: "0%",
1928
+ y2: "100%",
1929
+ stops: [[
1930
+ "0%",
1931
+ e.color,
1932
+ 1
1933
+ ], [
1934
+ "100%",
1935
+ M(c)(e.color, z.value.style.chart.lines.gradient.intensity / 100),
1936
+ 1
1937
+ ]]
1938
+ }, null, 8, ["id", "stops"]))), 128))])) : S("", !0),
1939
+ z.value.style.chart.grid.x.showHorizontalLines ? (D(!0), C(y, { key: 2 }, k(zr.value, (e, t) => (D(), C("line", {
1940
+ x1: X.value.left,
1941
+ x2: X.value.right,
1942
+ y1: e.y,
1943
+ y2: e.y,
1944
+ stroke: z.value.style.chart.grid.x.linesColor,
1945
+ "stroke-width": z.value.style.chart.grid.x.linesThickness,
1946
+ "stroke-dasharray": z.value.style.chart.grid.x.linesStrokeDasharray,
1947
+ "stroke-linecap": "round"
1948
+ }, null, 8, mt))), 256)) : S("", !0),
1949
+ z.value.style.chart.grid.y.showVerticalLines ? (D(!0), C(y, { key: 3 }, k(q.value.end - q.value.start, (e, t) => (D(), C("line", {
1950
+ x1: Q(t),
1951
+ x2: Q(t),
1952
+ y1: W.value.top,
1953
+ y2: W.value.bottom,
1954
+ stroke: z.value.style.chart.grid.y.linesColor,
1955
+ "stroke-width": z.value.style.chart.grid.y.linesThickness,
1956
+ "stroke-dasharray": z.value.style.chart.grid.y.linesStrokeDasharray,
1957
+ "stroke-linecap": "round"
1958
+ }, null, 8, ht))), 256)) : S("", !0),
1959
+ z.value.style.chart.grid.x.showAxis ? (D(), C("line", {
1960
+ key: 4,
1961
+ x1: X.value.left,
1962
+ x2: X.value.right,
1963
+ y1: W.value.bottom,
1964
+ y2: W.value.bottom,
1965
+ stroke: z.value.style.chart.grid.x.axisColor,
1966
+ "stroke-width": z.value.style.chart.grid.x.axisThickness,
1967
+ "stroke-linecap": "round",
1968
+ "stroke-linejoin": "round"
1969
+ }, null, 8, gt)) : S("", !0),
1970
+ z.value.style.chart.grid.y.showAxis && !z.value.style.chart.lines.distributed ? (D(), C("line", {
1971
+ key: 5,
1972
+ x1: lr.value ? X.value.right : X.value.left,
1973
+ x2: lr.value ? X.value.right : X.value.left,
1974
+ y1: W.value.top,
1975
+ y2: W.value.bottom,
1976
+ stroke: z.value.style.chart.grid.y.axisColor,
1977
+ "stroke-width": z.value.style.chart.grid.y.axisThickness,
1978
+ "stroke-linecap": "round",
1979
+ "stroke-linejoin": "round"
1980
+ }, null, 8, _t)) : S("", !0),
1981
+ z.value.style.chart.grid.x.axisName.show && z.value.style.chart.grid.x.axisName.text ? (D(), C("text", {
1982
+ key: 6,
1983
+ ref_key: "xAxisLabel",
1984
+ ref: xn,
1985
+ x: W.value.left + W.value.width / 2,
1986
+ y: W.value.chartHeight - 3,
1987
+ "font-size": z.value.style.chart.grid.x.axisName.fontSize,
1988
+ fill: z.value.style.chart.grid.x.axisName.color,
1989
+ "font-weight": z.value.style.chart.grid.x.axisName.bold ? "bold" : "normal",
1990
+ "text-anchor": "middle"
1991
+ }, j(z.value.style.chart.grid.x.axisName.text), 9, vt)) : S("", !0),
1992
+ z.value.style.chart.grid.y.axisName.show && z.value.style.chart.grid.y.axisName.text ? (D(), C("text", {
1993
+ key: 7,
1994
+ ref_key: "yAxisLabel",
1995
+ ref: Sn,
1996
+ transform: `translate(${lr.value ? W.value.chartWidth - z.value.style.chart.grid.y.axisName.fontSize / 2 - z.value.style.chart.grid.y.axisName.offsetX : z.value.style.chart.grid.y.axisName.fontSize + z.value.style.chart.grid.y.axisName.offsetX}, ${W.value.top + W.value.height / 2}) rotate(-90)`,
1997
+ "font-size": z.value.style.chart.grid.y.axisName.fontSize,
1998
+ fill: z.value.style.chart.grid.y.axisName.color,
1999
+ "font-weight": z.value.style.chart.grid.y.axisName.bold ? "bold" : "normal",
2000
+ "text-anchor": "middle"
2001
+ }, j(z.value.style.chart.grid.y.axisName.text), 9, yt)) : S("", !0),
2002
+ z.value.style.chart.grid.frame.show ? (D(), C("rect", {
2003
+ key: 8,
2004
+ style: {
2005
+ pointerEvents: "none",
2006
+ transition: "none",
2007
+ animation: "none !important"
2008
+ },
2009
+ x: X.value.left,
2010
+ y: W.value.top,
2011
+ width: X.value.width,
2012
+ height: W.value.height,
2013
+ fill: "transparent",
2014
+ stroke: z.value.style.chart.grid.frame.stroke,
2015
+ "stroke-width": z.value.style.chart.grid.frame.strokeWidth,
2016
+ "stroke-linecap": z.value.style.chart.grid.frame.strokeLinecap,
2017
+ "stroke-linejoin": z.value.style.chart.grid.frame.strokeLinejoin,
2018
+ "stroke-dasharray": z.value.style.chart.grid.frame.strokeDasharray
2019
+ }, null, 8, bt)) : S("", !0),
2020
+ (D(!0), C(y, null, k(Y.value, (e) => (D(), C(y, null, [z.value.style.chart.lines.useArea && !e.standalone ? (D(), C("path", {
2021
+ key: 0,
2022
+ d: z.value.style.chart.lines.smooth ? e.smoothArea : e.straightArea,
2023
+ fill: t.$slots.pattern ? `url(#pattern_${I.value}_${e.absoluteIndex})` : z.value.style.chart.lines.gradient.show ? `url(#gradient_${e.id})` : e.color,
2024
+ opacity: z.value.style.chart.lines.areaOpacity,
2025
+ class: Ye({ "vue-data-ui-transition": M(zn) })
2026
+ }, null, 10, xt)) : S("", !0)], 64))), 256)),
2027
+ (D(!0), C(y, null, k(Y.value, (e) => (D(), C("path", {
2028
+ d: z.value.style.chart.lines.smooth ? e.smoothPath : e.straightPath,
2029
+ stroke: z.value.style.chart.lines.path.useSerieColor ? e.color : z.value.style.chart.lines.path.stroke,
2030
+ "stroke-width": z.value.style.chart.lines.strokeWidth,
2031
+ fill: "none",
2032
+ "stroke-linecap": "round",
2033
+ class: Ye({ "vue-data-ui-transition": M(zn) })
2034
+ }, null, 10, St))), 256)),
2035
+ z.value.style.chart.grid.y.axisLabels.show && !z.value.style.chart.lines.distributed ? (D(), C("g", {
2036
+ key: 9,
2037
+ ref_key: "scaleLabels",
2038
+ ref: Cn
2039
+ }, [(D(!0), C(y, null, k(zr.value, (e, t) => (D(), C("line", {
2040
+ key: `ytick_${t}`,
2041
+ class: Ye({ "vue-data-ui-transition": M(zn) }),
2042
+ x1: lr.value ? X.value.right : X.value.left,
2043
+ x2: lr.value ? X.value.right + 6 : X.value.left - 6,
2044
+ y1: e.y,
2045
+ y2: e.y,
2046
+ stroke: z.value.style.chart.grid.x.axisColor,
2047
+ "stroke-width": 1
2048
+ }, null, 10, Ct))), 128)), (D(!0), C(y, null, k(zr.value, (e, t) => (D(), C("text", {
2049
+ class: Ye({ "vue-data-ui-transition": M(zn) }),
2050
+ transform: `translate(${e.x}, ${e.y + z.value.style.chart.grid.y.axisLabels.fontSize / 3})`,
2051
+ "font-size": z.value.style.chart.grid.y.axisLabels.fontSize,
2052
+ "font-weight": z.value.style.chart.grid.y.axisLabels.bold ? "bold" : "normal",
2053
+ fill: z.value.style.chart.grid.y.axisLabels.color,
2054
+ "text-anchor": lr.value ? "start" : "end"
2055
+ }, j(M(v)(z.value.style.chart.grid.y.axisLabels.formatter, e.value, M(h)({
2056
+ p: z.value.style.chart.lines.dataLabels.prefix,
2057
+ v: e.value,
2058
+ s: z.value.style.chart.lines.dataLabels.suffix,
2059
+ r: z.value.style.chart.grid.y.axisLabels.rounding
2060
+ }), { datapoint: e })), 11, wt))), 256))], 512)) : S("", !0),
2061
+ z.value.style.chart.grid.x.timeLabels.show ? (D(), C("g", {
2062
+ key: 10,
2063
+ ref_key: "timeLabelsEls",
2064
+ ref: wn
2065
+ }, [t.$slots["time-label"] ? (D(), C("g", Tt, [(D(!0), C(y, null, k(Gr.value, (e, n) => (D(), C("g", null, [A(t.$slots, "time-label", qe({ ref_for: !0 }, {
2066
+ x: W.value.left + Or.value * n + Or.value / 2,
2067
+ y: W.value.bottom + z.value.style.chart.grid.x.timeLabels.fontSize * 1.3 + z.value.style.chart.grid.x.timeLabels.offsetY,
2068
+ fontSize: z.value.style.chart.grid.x.timeLabels.fontSize,
2069
+ fill: z.value.style.chart.grid.x.timeLabels.color,
2070
+ transform: `translate(${W.value.left + Or.value * n + Or.value / 2}, ${W.value.bottom + z.value.style.chart.grid.x.timeLabels.fontSize * 1.3 + z.value.style.chart.grid.x.timeLabels.offsetY}), rotate(${z.value.style.chart.grid.x.timeLabels.rotation})`,
2071
+ absoluteIndex: e.absoluteIndex,
2072
+ content: e.text,
2073
+ textAnchor: z.value.style.chart.grid.x.timeLabels.rotation > 0 ? "start" : z.value.style.chart.grid.x.timeLabels.rotation < 0 ? "end" : "middle",
2074
+ show: !0
2075
+ }), void 0, !0)]))), 256))])) : (D(), C("g", Et, [(D(!0), C(y, null, k(Gr.value, (e, n) => (D(), C("g", null, [String(e.text).includes("\n") ? (D(), C("text", {
2076
+ key: n + "-multi",
2077
+ "text-anchor": z.value.style.chart.grid.x.timeLabels.rotation > 0 ? "start" : z.value.style.chart.grid.x.timeLabels.rotation < 0 ? "end" : "middle",
2078
+ "font-size": z.value.style.chart.grid.x.timeLabels.fontSize,
2079
+ fill: z.value.style.chart.grid.x.timeLabels.color,
2080
+ transform: `
2081
+ translate(
2082
+ ${Q(n)},
2083
+ ${W.value.bottom + z.value.style.chart.grid.x.timeLabels.fontSize * 1.3 + z.value.style.chart.grid.x.timeLabels.offsetY}
2084
+ ),
2085
+ rotate(${z.value.style.chart.grid.x.timeLabels.rotation})
2086
+ `,
2087
+ style: Xe({ cursor: B.value ? "pointer" : "default" }),
2088
+ innerHTML: t.createTSpansFromLineBreaksOnX({
2089
+ content: String(e.text),
2090
+ fontSize: z.value.style.chart.grid.x.timeLabels.fontSize,
2091
+ fill: z.value.style.chart.grid.x.timeLabels.color,
2092
+ x: 0,
2093
+ y: 0
2094
+ }),
2095
+ onClick: () => yi(e, n)
2096
+ }, null, 12, Ot)) : (D(), C("text", {
2097
+ class: "vue-data-ui-time-label",
2098
+ key: n,
2099
+ "text-anchor": z.value.style.chart.grid.x.timeLabels.rotation > 0 ? "start" : z.value.style.chart.grid.x.timeLabels.rotation < 0 ? "end" : "middle",
2100
+ "font-size": z.value.style.chart.grid.x.timeLabels.fontSize,
2101
+ "font-weight": z.value.style.chart.grid.x.timeLabels.bold ? "bold" : "normal",
2102
+ fill: z.value.style.chart.grid.x.timeLabels.color,
2103
+ transform: `translate(${Q(n)}, ${W.value.bottom + z.value.style.chart.grid.x.timeLabels.fontSize * 1.3 + z.value.style.chart.grid.x.timeLabels.offsetY}), rotate(${z.value.style.chart.grid.x.timeLabels.rotation})`,
2104
+ style: Xe({ cursor: B.value ? "pointer" : "default" }),
2105
+ onClick: () => yi(e, n)
2106
+ }, j(e.text), 13, Dt))]))), 256))]))], 512)) : S("", !0),
2107
+ (vn.value || ![null, void 0].includes($.value)) && !z.value.style.chart.highlighter.useLine ? (D(!0), C(y, { key: 11 }, k(q.value.end - q.value.start, (e, t) => (D(), C("g", { key: `tooltip_trap_highlighter_${t}` }, [w("rect", {
2108
+ x: ui(t).x,
2109
+ y: W.value.top,
2110
+ height: W.value.height,
2111
+ width: ui(t).width,
2112
+ fill: [In.value, $.value].includes(t) ? M(n)(z.value.style.chart.highlighter.color, z.value.style.chart.highlighter.opacity) : "transparent",
2113
+ style: {
2114
+ transition: "none !important",
2115
+ animation: "none !important"
2116
+ }
2117
+ }, null, 8, kt)]))), 128)) : S("", !0),
2118
+ (vn.value || ![null, void 0].includes($.value)) && z.value.style.chart.highlighter.useLine ? (D(), C(y, { key: 12 }, [![null, void 0].includes($.value) || ![null, void 0].includes(In.value) ? (D(), C("g", At, [w("line", {
2119
+ x1: Q(($.value ?? In.value) || 0),
2120
+ x2: Q(($.value ?? In.value) || 0),
2121
+ y1: M(ie)(W.value.top),
2122
+ y2: M(ie)(W.value.bottom),
2123
+ stroke: z.value.style.chart.highlighter.color,
2124
+ "stroke-width": z.value.style.chart.highlighter.lineWidth,
2125
+ "stroke-dasharray": z.value.style.chart.highlighter.lineDasharray,
2126
+ "stroke-linecap": "round",
2127
+ style: {
2128
+ transition: "none !important",
2129
+ animation: "none !important",
2130
+ "pointer-events": "none"
2131
+ }
2132
+ }, null, 8, jt)])) : S("", !0)], 64)) : S("", !0),
2133
+ (D(!0), C(y, null, k(Y.value, (e) => (D(), C(y, { key: `shp_sel_${e.id}` }, [vn.value && q.value.end - q.value.start > z.value.style.chart.lines.dot.hideAboveMaxSerieLength ? (D(), C("g", Mt, [$.value == null ? S("", !0) : (D(), C(y, { key: 0 }, [e.rel.includes($.value) && e.fullSeries?.[q.value.start + $.value] != null && !Number.isNaN(e.fullSeries?.[q.value.start + $.value]) ? (D(), x(Ae, {
2134
+ key: 0,
2135
+ shape: [
2136
+ "triangle",
2137
+ "square",
2138
+ "diamond",
2139
+ "pentagon",
2140
+ "hexagon",
2141
+ "star"
2142
+ ].includes(e.shape) ? e.shape : "circle",
2143
+ color: z.value.style.chart.lines.dot.useSerieColor ? e.color : z.value.style.chart.lines.dot.fill,
2144
+ plot: {
2145
+ x: M(_)(e.points[e.rel.indexOf($.value)].x),
2146
+ y: M(_)(e.points[e.rel.indexOf($.value)].y)
2147
+ },
2148
+ radius: z.value.style.chart.lines.dot.radius * 1.3,
2149
+ stroke: z.value.style.chart.lines.dot.useSerieColor ? z.value.style.chart.lines.dot.stroke : e.color,
2150
+ strokeWidth: z.value.style.chart.lines.dot.strokeWidth,
2151
+ still: M(Vn),
2152
+ class: Ye({ "vue-data-ui-transition": M(zn) })
2153
+ }, null, 8, [
2154
+ "shape",
2155
+ "color",
2156
+ "plot",
2157
+ "radius",
2158
+ "stroke",
2159
+ "strokeWidth",
2160
+ "still",
2161
+ "class"
2162
+ ])) : S("", !0)], 64))])) : S("", !0)], 64))), 128)),
2163
+ (D(!0), C(y, null, k(Y.value, (e) => (D(), C(y, { key: `shp_${e.id}` }, [q.value.end - q.value.start < z.value.style.chart.lines.dot.hideAboveMaxSerieLength ? (D(!0), C(y, { key: 0 }, k(e.points, (t, n) => (D(), C("g", { key: `shp_${e.id}_${q.value.start + n}` }, [e.fullSeries?.[q.value.start + e.rel[n]] != null && !Number.isNaN(e.fullSeries?.[q.value.start + e.rel[n]]) ? (D(), x(Ae, {
2164
+ key: 0,
2165
+ shape: [
2166
+ "triangle",
2167
+ "square",
2168
+ "diamond",
2169
+ "pentagon",
2170
+ "hexagon",
2171
+ "star"
2172
+ ].includes(e.shape) ? e.shape : "circle",
2173
+ color: z.value.style.chart.lines.dot.useSerieColor ? e.color : z.value.style.chart.lines.dot.fill,
2174
+ plot: {
2175
+ x: t.x,
2176
+ y: t.y
2177
+ },
2178
+ radius: vn.value && $.value === e.rel[n] ? z.value.style.chart.lines.dot.radius * 1.3 : z.value.style.chart.lines.dot.radius,
2179
+ stroke: z.value.style.chart.lines.dot.useSerieColor ? z.value.style.chart.lines.dot.stroke : e.color,
2180
+ strokeWidth: z.value.style.chart.lines.dot.strokeWidth,
2181
+ still: M(Vn),
2182
+ class: Ye({ "vue-data-ui-transition": M(zn) })
2183
+ }, null, 8, [
2184
+ "shape",
2185
+ "color",
2186
+ "plot",
2187
+ "radius",
2188
+ "stroke",
2189
+ "strokeWidth",
2190
+ "still",
2191
+ "class"
2192
+ ])) : S("", !0)]))), 128)) : S("", !0)], 64))), 128)),
2193
+ H.value.dataLabels.show && z.value.style.chart.lines.dataLabels.hideAboveMaxSerieLength > q.value.end - q.value.start ? (D(), C(y, { key: 13 }, [(D(!0), C(y, null, k(Y.value, (e, t) => (D(), C("g", { key: `dl_${e.id}` }, [(D(!0), C(y, null, k(e.points, (n, r) => (D(), C(y, { key: `dp_${e.id}_${q.value.start + r}` }, [qi(e.series[r], e.proportions[r]) ? (D(), C("text", {
2194
+ key: 0,
2195
+ class: Ye({ "vue-data-ui-transition": M(zn) }),
2196
+ transform: `translate(${n.x}, ${n.y + (e.series[r] >= 0 ? -z.value.style.chart.lines.dataLabels.fontSize / 2 + z.value.style.chart.lines.dataLabels.offsetY : z.value.style.chart.lines.dataLabels.fontSize * 1.2 - z.value.style.chart.lines.dataLabels.offsetY)})`,
2197
+ "font-size": z.value.style.chart.lines.dataLabels.fontSize,
2198
+ fill: z.value.style.chart.lines.dataLabels.color,
2199
+ "font-weight": z.value.style.chart.lines.dataLabels.bold ? "bold" : "normal",
2200
+ "text-anchor": "middle"
2201
+ }, j(z.value.style.chart.lines.showDistributedPercentage && z.value.style.chart.lines.distributed ? Xi(e.proportions[r] * 100, e, t, e.rel[r]) : Yi(e.series[r], e, t, e.rel[r], e.signedSeries[r])), 11, Nt)) : S("", !0)], 64))), 128))]))), 128)), z.value.style.chart.lines.totalValues.show && Y.value.length > 1 ? (D(), C("g", {
2202
+ key: 0,
2203
+ ref_key: "sumTop",
2204
+ ref: Tn
2205
+ }, [(D(!0), C(y, null, k(Ir.value, (e, t) => (D(), C(y, { key: `total_l_${t + q.value.start}` }, [!z.value.style.chart.lines.dataLabels.hideEmptyValues || e.value !== 0 ? (D(), C("text", {
2206
+ key: 0,
2207
+ class: Ye({ "vue-data-ui-transition": M(zn) }),
2208
+ transform: `translate(${Q(t)}, ${Rr(t)})`,
2209
+ "text-anchor": "middle",
2210
+ "font-size": z.value.style.chart.lines.totalValues.fontSize,
2211
+ "font-weight": z.value.style.chart.lines.totalValues.bold ? "bold" : "normal",
2212
+ fill: z.value.style.chart.lines.totalValues.color
2213
+ }, j(Yi(e.value, e, t, t, e.sign)), 11, Pt)) : S("", !0)], 64))), 128))], 512)) : S("", !0)], 64)) : S("", !0),
2214
+ Sr.value ? (D(), C("rect", qe({ key: 14 }, _r.value, {
2215
+ "data-start": q.value.start,
2216
+ "data-end": q.value.end
2217
+ }), null, 16, Ft)) : S("", !0),
2218
+ A(t.$slots, "svg", { svg: {
2219
+ drawingArea: W.value,
2220
+ data: Y.value,
2221
+ isPrintingImg: M(Qn) || M($n) || yn.value,
2222
+ isPrintingSvg: bn.value
2223
+ } }, void 0, !0)
2224
+ ], 46, ut)), t.$slots.hint ? (D(), C("div", It, [A(t.$slots, "hint", E(T({
2225
+ hint: z.value.a11y.translations.keyboardNavigation,
2226
+ isVisible: ea.value
2227
+ })), void 0, !0)])) : S("", !0)]),
2228
+ t.$slots.watermark ? (D(), C("div", Lt, [A(t.$slots, "watermark", E(T({ isPrinting: M(Qn) || M($n) || yn.value || bn.value })), void 0, !0)])) : S("", !0),
2229
+ hn.value && (z.value.style.chart.legend.show || t.$slots.legend) ? (D(), x(He, {
2230
+ key: 6,
2231
+ to: z.value.style.chart.legend.position === "top" ? `#legend-top-${I.value}` : `#legend-bottom-${I.value}`
2232
+ }, [w("div", {
2233
+ ref_key: "chartLegend",
2234
+ ref: on
2235
+ }, [A(t.$slots, "legend", { legend: Si.value }, () => [z.value.style.chart.legend.show ? (D(), x(Be, {
2236
+ key: 0,
2237
+ legendSet: Si.value,
2238
+ config: Ci.value,
2239
+ isCursorPointer: B.value,
2240
+ onClickMarker: r[0] ||= ({ legend: e }) => e.segregate()
2241
+ }, Ue({
2242
+ item: N(({ legend: e }) => [M(Vn) ? S("", !0) : (D(), C("div", {
2243
+ key: 0,
2244
+ onClick: (t) => e.segregate(),
2245
+ style: Xe(`opacity:${L.value.includes(e.id) ? .5 : 1}`)
2246
+ }, j(e.name), 13, Rt))]),
2247
+ legendToggle: N(() => [Si.value.length > 2 && z.value.style.chart.legend.selectAllToggle.show && !M(Vn) ? (D(), x(Ie, {
2248
+ key: 0,
2249
+ backgroundColor: z.value.style.chart.legend.selectAllToggle.backgroundColor,
2250
+ color: z.value.style.chart.legend.selectAllToggle.color,
2251
+ fontSize: z.value.style.chart.legend.fontSize,
2252
+ checked: L.value.length > 0,
2253
+ isCursorPointer: B.value,
2254
+ onToggle: bi
2255
+ }, null, 8, [
2256
+ "backgroundColor",
2257
+ "color",
2258
+ "fontSize",
2259
+ "checked",
2260
+ "isCursorPointer"
2261
+ ])) : S("", !0)]),
2262
+ _: 2
2263
+ }, [t.$slots.pattern ? {
2264
+ name: "legend-pattern",
2265
+ fn: N(({ legend: e, index: t }) => [Ge(Ae, {
2266
+ shape: e.shape,
2267
+ radius: 30,
2268
+ stroke: "none",
2269
+ plot: {
2270
+ x: 30,
2271
+ y: 30
2272
+ },
2273
+ fill: `url(#pattern_${I.value}_${t})`
2274
+ }, null, 8, ["shape", "fill"])]),
2275
+ key: "0"
2276
+ } : void 0]), 1032, [
2277
+ "legendSet",
2278
+ "config",
2279
+ "isCursorPointer"
2280
+ ])) : S("", !0)], !0)], 512)], 8, ["to"])) : S("", !0),
2281
+ en.value && z.value.userOptions.buttons.table ? (D(), x($e(Ii.value.component), qe({ key: 7 }, Ii.value.props, {
2282
+ ref_key: "tableUnit",
2283
+ ref: gn,
2284
+ onClose: Li
2285
+ }), Ue({
2286
+ content: N(() => [Ge(M(Gt), {
2287
+ colNames: ki.value.colNames,
2288
+ head: ki.value.head,
2289
+ body: ki.value.body,
2290
+ config: ki.value.config,
2291
+ title: z.value.table.useDialog ? "" : Ii.value.title,
2292
+ withCloseButton: !z.value.table.useDialog,
2293
+ isCursorPointer: B.value,
2294
+ onClose: Li
2295
+ }, {
2296
+ th: N(({ th: e }) => [w("div", { innerHTML: e }, null, 8, zt)]),
2297
+ td: N(({ td: e }) => [We(j(isNaN(Number(e)) ? e : M(h)({
2298
+ p: z.value.style.chart.lines.dataLabels.prefix,
2299
+ v: e,
2300
+ s: z.value.style.chart.lines.dataLabels.suffix,
2301
+ r: z.value.table.td.roundingValue
2302
+ })), 1)]),
2303
+ _: 1
2304
+ }, 8, [
2305
+ "colNames",
2306
+ "head",
2307
+ "body",
2308
+ "config",
2309
+ "title",
2310
+ "withCloseButton",
2311
+ "isCursorPointer"
2312
+ ])]),
2313
+ _: 2
2314
+ }, [z.value.table.useDialog ? {
2315
+ name: "title",
2316
+ fn: N(() => [We(j(Ii.value.title), 1)]),
2317
+ key: "0"
2318
+ } : void 0, z.value.table.useDialog ? {
2319
+ name: "actions",
2320
+ fn: N(() => [w("button", {
2321
+ tabindex: "0",
2322
+ class: "vue-ui-user-options-button",
2323
+ onClick: r[1] ||= (e) => Oi(z.value.userOptions.callbacks.csv),
2324
+ style: Xe({ cursor: B.value ? "pointer" : "default" })
2325
+ }, [Ge(M(Ut), {
2326
+ name: "fileCsv",
2327
+ stroke: Ii.value.props.color
2328
+ }, null, 8, ["stroke"])], 4)]),
2329
+ key: "1"
2330
+ } : void 0]), 1040)) : S("", !0),
2331
+ z.value.style.chart.zoom.show && en.value && ei.value && K.value > 6 ? (D(), x(Fe, {
2332
+ key: 8,
2333
+ ref_key: "chartSlicer",
2334
+ ref: sn,
2335
+ "data-dom-to-png-ignore-layout": "",
2336
+ allMinimaps: Mr.value,
2337
+ background: z.value.style.chart.zoom.color,
2338
+ borderColor: z.value.style.chart.backgroundColor,
2339
+ customFormat: z.value.style.chart.zoom.customFormat,
2340
+ cutNullValues: !1,
2341
+ enableRangeHandles: z.value.style.chart.zoom.enableRangeHandles,
2342
+ enableSelectionDrag: z.value.style.chart.zoom.enableSelectionDrag,
2343
+ end: q.value.end,
2344
+ focusOnDrag: z.value.style.chart.zoom.focusOnDrag,
2345
+ focusRangeRatio: z.value.style.chart.zoom.focusRangeRatio,
2346
+ fontSize: z.value.style.chart.zoom.fontSize,
2347
+ immediate: !z.value.style.chart.zoom.preview.enable,
2348
+ inputColor: z.value.style.chart.zoom.color,
2349
+ isPreview: Sr.value,
2350
+ labelLeft: z.value.style.chart.grid.x.timeLabels.values[q.value.start] ? Br.value?.[0]?.text ?? "" : "",
2351
+ labelRight: z.value.style.chart.grid.x.timeLabels.values[q.value.end - 1] ? Br.value?.at(-1)?.text ?? "" : "",
2352
+ max: Math.max(...e.dataset.map((e) => e.series.length)),
2353
+ min: 0,
2354
+ minimap: jr.value,
2355
+ minimapCompact: z.value.style.chart.zoom.minimap.compact,
2356
+ minimapFrameColor: z.value.style.chart.zoom.minimap.frameColor,
2357
+ minimapIndicatorColor: z.value.style.chart.zoom.minimap.indicatorColor,
2358
+ minimapMerged: !1,
2359
+ minimapSelectedColor: z.value.style.chart.zoom.minimap.selectedColor,
2360
+ minimapSelectedColorOpacity: z.value.style.chart.zoom.minimap.selectedColorOpacity,
2361
+ minimapSelectedIndex: $.value,
2362
+ minimapSelectionRadius: 1,
2363
+ preciseLabels: Yr.value.length ? Yr.value : Vr.value,
2364
+ refreshEndPoint: z.value.style.chart.zoom.endIndex === null ? Math.max(...e.dataset.map((e) => e.series.length)) : z.value.style.chart.zoom.endIndex + 1,
2365
+ refreshStartPoint: z.value.style.chart.zoom.startIndex === null ? 0 : z.value.style.chart.zoom.startIndex,
2366
+ selectColor: z.value.style.chart.zoom.highlightColor,
2367
+ selectedSeries: Wi.value,
2368
+ smoothMinimap: !1,
2369
+ start: q.value.start,
2370
+ textColor: z.value.style.chart.color,
2371
+ timeLabels: Vr.value,
2372
+ usePreciseLabels: z.value.style.chart.grid.x.timeLabels.datetimeFormatter.enable && !z.value.style.chart.zoom.useDefaultFormat,
2373
+ valueEnd: q.value.end,
2374
+ valueStart: q.value.start,
2375
+ verticalHandles: z.value.style.chart.zoom.minimap.verticalHandles,
2376
+ maxWidth: z.value.style.chart.zoom.maxWidth,
2377
+ isCursorPointer: B.value,
2378
+ additionalMinimapHeight: z.value.style.chart.zoom.minimap.additionalHeight,
2379
+ handleType: z.value.style.chart.zoom.minimap.handleType,
2380
+ handleIconColor: z.value.style.chart.zoom.minimap.handleIconColor,
2381
+ handleBorderWidth: z.value.style.chart.zoom.minimap.handleBorderWidth,
2382
+ handleBorderColor: z.value.style.chart.zoom.minimap.handleBorderColor,
2383
+ handleFill: z.value.style.chart.zoom.minimap.handleFill,
2384
+ handleWidth: z.value.style.chart.zoom.minimap.handleWidth,
2385
+ "onUpdate:end": ii,
2386
+ "onUpdate:start": ri,
2387
+ onTrapMouse: br,
2388
+ onReset: r[2] ||= () => Dr({ force: !0 }),
2389
+ onFutureEnd: r[3] ||= (e) => Cr("end", e),
2390
+ onFutureStart: r[4] ||= (e) => Cr("start", e)
2391
+ }, {
2392
+ "reset-action": N(({ reset: e }) => [A(t.$slots, "reset-action", E(T({ reset: e })), void 0, !0)]),
2393
+ slotMap: N(({ width: e, height: t, unitW: n }) => [w("g", { innerHTML: Ki({
2394
+ minimapW: e,
2395
+ minimapH: t,
2396
+ unitW: n
2397
+ }) }, null, 8, Bt)]),
2398
+ _: 3
2399
+ }, 8, /* @__PURE__ */ "allMinimaps.background.borderColor.customFormat.enableRangeHandles.enableSelectionDrag.end.focusOnDrag.focusRangeRatio.fontSize.immediate.inputColor.isPreview.labelLeft.labelRight.max.minimap.minimapCompact.minimapFrameColor.minimapIndicatorColor.minimapSelectedColor.minimapSelectedColorOpacity.minimapSelectedIndex.preciseLabels.refreshEndPoint.refreshStartPoint.selectColor.selectedSeries.start.textColor.timeLabels.usePreciseLabels.valueEnd.valueStart.verticalHandles.maxWidth.isCursorPointer.additionalMinimapHeight.handleType.handleIconColor.handleBorderWidth.handleBorderColor.handleFill.handleWidth".split("."))) : S("", !0),
2400
+ w("div", { id: `legend-bottom-${I.value}` }, null, 8, Vt),
2401
+ Ge(M(Ht), {
2402
+ teleportTo: z.value.style.chart.tooltip.teleportTo,
2403
+ show: H.value.showTooltip && nn.value,
2404
+ backgroundColor: z.value.style.chart.tooltip.backgroundColor,
2405
+ color: z.value.style.chart.tooltip.color,
2406
+ fontSize: z.value.style.chart.tooltip.fontSize,
2407
+ borderRadius: z.value.style.chart.tooltip.borderRadius,
2408
+ borderColor: z.value.style.chart.tooltip.borderColor,
2409
+ borderWidth: z.value.style.chart.tooltip.borderWidth,
2410
+ backgroundOpacity: z.value.style.chart.tooltip.backgroundOpacity,
2411
+ position: z.value.style.chart.tooltip.position,
2412
+ offsetX: z.value.style.chart.tooltip.offsetX,
2413
+ offsetY: z.value.style.chart.tooltip.offsetY,
2414
+ parent: tn.value,
2415
+ content: _i.value,
2416
+ isFullscreen: un.value,
2417
+ isCustom: z.value.style.chart.tooltip.customFormat && typeof z.value.style.chart.tooltip.customFormat == "function",
2418
+ smooth: z.value.style.chart.tooltip.smooth,
2419
+ backdropFilter: z.value.style.chart.tooltip.backdropFilter,
2420
+ smoothForce: z.value.style.chart.tooltip.smoothForce,
2421
+ smoothSnapThreshold: z.value.style.chart.tooltip.smoothSnapThreshold,
2422
+ isA11yMode: jn.value === "keyboard",
2423
+ a11yPosition: An.value
2424
+ }, {
2425
+ "tooltip-before": N(() => [A(t.$slots, "tooltip-before", E(T({ ...Qr.value })), void 0, !0)]),
2426
+ tooltip: N(() => [A(t.$slots, "tooltip", E(T({ ...Qr.value })), void 0, !0)]),
2427
+ "tooltip-after": N(() => [A(t.$slots, "tooltip-after", E(T({ ...Qr.value })), void 0, !0)]),
2428
+ _: 3
2429
+ }, 8, [
2430
+ "teleportTo",
2431
+ "show",
2432
+ "backgroundColor",
2433
+ "color",
2434
+ "fontSize",
2435
+ "borderRadius",
2436
+ "borderColor",
2437
+ "borderWidth",
2438
+ "backgroundOpacity",
2439
+ "position",
2440
+ "offsetX",
2441
+ "offsetY",
2442
+ "parent",
2443
+ "content",
2444
+ "isFullscreen",
2445
+ "isCustom",
2446
+ "smooth",
2447
+ "backdropFilter",
2448
+ "smoothForce",
2449
+ "smoothSnapThreshold",
2450
+ "isA11yMode",
2451
+ "a11yPosition"
2452
+ ]),
2453
+ t.$slots.source ? (D(), C("div", {
2454
+ key: 9,
2455
+ ref_key: "source",
2456
+ ref: ln,
2457
+ dir: "auto"
2458
+ }, [A(t.$slots, "source", {}, void 0, !0)], 512)) : S("", !0),
2459
+ A(t.$slots, "skeleton", {}, () => [M(Vn) ? (D(), x(xe, { key: 0 })) : S("", !0)], !0)
2460
+ ], 46, ot));
2461
+ }
2462
+ }, [["__scopeId", "data-v-eaa07f6c"]]);
2463
+ //#endregion
2464
+ export { at as n, Ht as t };