vue-data-ui 3.25.13 → 3.26.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 (205) hide show
  1. package/README.md +53 -53
  2. package/dist/{Arrow-BhZDUeMp.js → Arrow-Bt3aGRMb.js} +1 -1
  3. package/dist/{BaseDraggableDialog-Ck6R5Q0K.js → BaseDraggableDialog-C1Slb3Yh.js} +2 -2
  4. package/dist/{BaseIcon-Dlz7gfx0.js → BaseIcon-BV75ei8X.js} +1 -1
  5. package/dist/{BaseLegendToggle-DGG65LAR.js → BaseLegendToggle-DtS_Oj3B.js} +1 -1
  6. package/dist/{BaseZoomControls-BK0PxEa8.js → BaseZoomControls-DIhoeyZu.js} +2 -2
  7. package/dist/{ColorPicker-DMTwxvi_.js → ColorPicker--Y89hTnE.js} +2 -2
  8. package/dist/{DataTable-BD1eZ0zB.js → DataTable-DX5fToAo.js} +2 -2
  9. package/dist/{HillActions-CiP2m7Nz.js → HillActions-D6weVdns.js} +1 -1
  10. package/dist/{Legend-C0Ln0VNe.js → Legend-Dv90gh-6.js} +2 -2
  11. package/dist/{NonSvgPenAndPaper-BjrMLISf.js → NonSvgPenAndPaper-D2BM5C1-.js} +3 -3
  12. package/dist/{PackageVersion-D5QkTJQU.js → PackageVersion-DhXk363L.js} +1 -1
  13. package/dist/{PenAndPaper-XdUD8uB3.js → PenAndPaper-DkQ4sEhs.js} +3 -3
  14. package/dist/{Shape-VCdxvFV9.js → Shape-B_kDj1gF.js} +1 -1
  15. package/dist/SlicerPreview-BgyIezm0.js +1730 -0
  16. package/dist/{SparkTooltip-B1gRxPfb.js → SparkTooltip-BNpyQ021.js} +1 -1
  17. package/dist/{Title-DeqmC-vN.js → Title-C2JKI5td.js} +1 -1
  18. package/dist/{Tooltip-DZ4a3XJQ.js → Tooltip-2NAb_Rrx.js} +1 -1
  19. package/dist/{UserOptions-wFD9vo9g.js → UserOptions-Dgn3StKw.js} +2 -2
  20. package/dist/components/arrow.js +1 -1
  21. package/dist/components/vue-ui-3d-bar.js +1 -1
  22. package/dist/components/vue-ui-accordion.js +1 -1
  23. package/dist/components/vue-ui-age-pyramid.js +1 -1
  24. package/dist/components/vue-ui-annotator.js +1 -1
  25. package/dist/components/vue-ui-bullet.js +1 -1
  26. package/dist/components/vue-ui-bump.js +1 -1
  27. package/dist/components/vue-ui-candlestick.js +1 -1
  28. package/dist/components/vue-ui-carousel-table.js +1 -1
  29. package/dist/components/vue-ui-chestnut.js +1 -1
  30. package/dist/components/vue-ui-chord.js +1 -1
  31. package/dist/components/vue-ui-circle-pack.js +1 -1
  32. package/dist/components/vue-ui-cursor.js +1 -1
  33. package/dist/components/vue-ui-dag.js +1 -1
  34. package/dist/components/vue-ui-dashboard.js +1 -1
  35. package/dist/components/vue-ui-digits.js +1 -1
  36. package/dist/components/vue-ui-donut-evolution.js +1 -1
  37. package/dist/components/vue-ui-donut.js +1 -1
  38. package/dist/components/vue-ui-dumbbell.js +1 -1
  39. package/dist/components/vue-ui-flow.js +1 -1
  40. package/dist/components/vue-ui-funnel.js +1 -1
  41. package/dist/components/vue-ui-galaxy.js +1 -1
  42. package/dist/components/vue-ui-gauge.js +1 -1
  43. package/dist/components/vue-ui-geo.js +1 -1
  44. package/dist/components/vue-ui-gizmo.js +1 -1
  45. package/dist/components/vue-ui-heatmap.js +1 -1
  46. package/dist/components/vue-ui-hill.js +1 -1
  47. package/dist/components/vue-ui-history-plot.js +1 -1
  48. package/dist/components/vue-ui-horizontal-bar.js +1 -1
  49. package/dist/components/vue-ui-icon.js +1 -1
  50. package/dist/components/vue-ui-kpi.js +1 -1
  51. package/dist/components/vue-ui-label.js +1 -1
  52. package/dist/components/vue-ui-mini-loader.js +1 -1
  53. package/dist/components/vue-ui-molecule.js +1 -1
  54. package/dist/components/vue-ui-mood-radar.js +1 -1
  55. package/dist/components/vue-ui-nested-donuts.js +1 -1
  56. package/dist/components/vue-ui-onion.js +1 -1
  57. package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
  58. package/dist/components/vue-ui-quadrant.js +1 -1
  59. package/dist/components/vue-ui-quick-chart.js +1 -1
  60. package/dist/components/vue-ui-radar.js +1 -1
  61. package/dist/components/vue-ui-rating.js +1 -1
  62. package/dist/components/vue-ui-relation-circle.js +1 -1
  63. package/dist/components/vue-ui-ridgeline.js +1 -1
  64. package/dist/components/vue-ui-rings.js +1 -1
  65. package/dist/components/vue-ui-scatter.js +1 -1
  66. package/dist/components/vue-ui-skeleton.js +1 -1
  67. package/dist/components/vue-ui-smiley.js +1 -1
  68. package/dist/components/vue-ui-spark-trend.js +1 -1
  69. package/dist/components/vue-ui-sparkbar.js +1 -1
  70. package/dist/components/vue-ui-sparkgauge.js +1 -1
  71. package/dist/components/vue-ui-sparkhistogram.js +1 -1
  72. package/dist/components/vue-ui-sparkline.js +1 -1
  73. package/dist/components/vue-ui-sparkstackbar.js +1 -1
  74. package/dist/components/vue-ui-stackbar.js +1 -1
  75. package/dist/components/vue-ui-stackline.js +1 -1
  76. package/dist/components/vue-ui-strip-plot.js +1 -1
  77. package/dist/components/vue-ui-table-heatmap.js +1 -1
  78. package/dist/components/vue-ui-table-sparkline.js +1 -1
  79. package/dist/components/vue-ui-table.js +1 -1
  80. package/dist/components/vue-ui-thermometer.js +1 -1
  81. package/dist/components/vue-ui-timer.js +1 -1
  82. package/dist/components/vue-ui-tiremarks.js +1 -1
  83. package/dist/components/vue-ui-treemap.js +1 -1
  84. package/dist/components/vue-ui-vertical-bar.js +1 -1
  85. package/dist/components/vue-ui-waffle.js +1 -1
  86. package/dist/components/vue-ui-wheel.js +1 -1
  87. package/dist/components/vue-ui-word-cloud.js +1 -1
  88. package/dist/components/vue-ui-world.js +1 -1
  89. package/dist/components/vue-ui-xy-canvas.js +1 -1
  90. package/dist/components/vue-ui-xy.js +1 -1
  91. package/dist/{dom-to-png-DdqmzDdY.js → dom-to-png-DKdtTkNC.js} +1 -1
  92. package/dist/{exposedLib-BBtjpydc.js → exposedLib-DN6QRAx2.js} +1 -1
  93. package/dist/{img-W50sC9SC.js → img-CaIaBHA0.js} +1 -1
  94. package/dist/{labelUtils-Dvm-7rse.js → labelUtils-CD5XzcAo.js} +1 -1
  95. package/dist/{lib-DOpaUOQx.js → lib-CklJ7rIN.js} +29 -18
  96. package/dist/{package-Cmcke8zR.js → package-BVRea5S_.js} +1 -1
  97. package/dist/{pdf-zGbDDpCi.js → pdf-6hacmnKW.js} +1 -1
  98. package/dist/{render-common-CG1wuHZY.js → render-common-ChwuwzU3.js} +2 -2
  99. package/dist/ssr/vue-ui-donut.js +1 -1
  100. package/dist/ssr/vue-ui-xy.js +1 -1
  101. package/dist/ssr.js +2 -2
  102. package/dist/style.css +1 -1
  103. package/dist/types/vue-data-ui.d.ts +110 -5
  104. package/dist/types/vue-ui-candlestick.d.ts +4 -0
  105. package/dist/types/vue-ui-donut-evolution.d.ts +4 -0
  106. package/dist/types/vue-ui-quick-chart.d.ts +4 -0
  107. package/dist/types/vue-ui-sparkline.d.ts +5 -1
  108. package/dist/types/vue-ui-stackbar.d.ts +4 -0
  109. package/dist/types/vue-ui-stackline.d.ts +4 -0
  110. package/dist/types/vue-ui-xy-canvas.d.ts +2 -0
  111. package/dist/types/vue-ui-xy.d.ts +2 -0
  112. package/dist/{useConfig-C2uy4ltq.js → useConfig-DObkR9Aa.js} +49 -4
  113. package/dist/{useNestedProp-Bux0f4iY.js → useNestedProp-Tc9i6ZcN.js} +1 -1
  114. package/dist/{useObjectBindings-CEuNiBIT.js → useObjectBindings-CPmyIJxB.js} +9 -9
  115. package/dist/{usePrinter-BBBooAGP.js → usePrinter-Dp3X1vqr.js} +2 -2
  116. package/dist/utils.js +3 -3
  117. package/dist/vue-data-ui-Dr0uoRD_.js +191 -0
  118. package/dist/vue-data-ui.js +74 -74
  119. package/dist/{vue-ui-3d-bar-Ckauu3d4.js → vue-ui-3d-bar-BvJwq13N.js} +7 -7
  120. package/dist/{vue-ui-accordion-yHZMJLaY.js → vue-ui-accordion-15kKhkup.js} +4 -4
  121. package/dist/{vue-ui-age-pyramid-BczIt1-U.js → vue-ui-age-pyramid-CVzina7X.js} +7 -7
  122. package/dist/{vue-ui-annotator-BGB6K6u0.js → vue-ui-annotator-J4Wo2_DR.js} +7 -7
  123. package/dist/{vue-ui-bullet-BoTsLccZ.js → vue-ui-bullet-CuI5_uF1.js} +8 -8
  124. package/dist/{vue-ui-bump-B5ztSSQO.js → vue-ui-bump-GGNG4vwu.js} +7 -7
  125. package/dist/vue-ui-candlestick-Ca9dvzvk.js +2144 -0
  126. package/dist/{vue-ui-carousel-table-D-3KSWok.js → vue-ui-carousel-table-DOxh9sEm.js} +5 -5
  127. package/dist/{vue-ui-chestnut-W2l-W0_e.js → vue-ui-chestnut-DQhC_gB8.js} +6 -6
  128. package/dist/{vue-ui-chord-BFPQsMj8.js → vue-ui-chord-Blnvne2p.js} +9 -9
  129. package/dist/{vue-ui-circle-pack-BtPc1BR3.js → vue-ui-circle-pack-mNHA1U8B.js} +7 -7
  130. package/dist/{vue-ui-cursor-CpNOiwkt.js → vue-ui-cursor-D2hgivhn.js} +4 -4
  131. package/dist/{vue-ui-dag-i-zPwLcN.js → vue-ui-dag-DDSyO2ts.js} +8 -8
  132. package/dist/{vue-ui-dashboard-DtaW9a2P.js → vue-ui-dashboard-C9MnWAnE.js} +70 -70
  133. package/dist/{vue-ui-digits-BIlec9af.js → vue-ui-digits-h7H-yHd0.js} +4 -4
  134. package/dist/{vue-ui-donut-CJlBEyxu.js → vue-ui-donut-D-8OekQ5.js} +3 -3
  135. package/dist/vue-ui-donut-evolution-CJ6tIbgl.js +1869 -0
  136. package/dist/{vue-ui-donut-Bgf-n95J.js → vue-ui-donut-oY4iu5pY.js} +11 -11
  137. package/dist/{vue-ui-dumbbell-C112YLkC.js → vue-ui-dumbbell-52gWeLGK.js} +8 -8
  138. package/dist/{vue-ui-flow-j4bDg9Zd.js → vue-ui-flow-edMUCkcr.js} +8 -8
  139. package/dist/{vue-ui-funnel-CVHpfBCW.js → vue-ui-funnel-B08mSlHH.js} +7 -7
  140. package/dist/{vue-ui-galaxy-ChGpUWh8.js → vue-ui-galaxy-CV59UO9t.js} +10 -10
  141. package/dist/{vue-ui-gauge-Cp00vXfG.js → vue-ui-gauge-BnBzapom.js} +7 -7
  142. package/dist/{vue-ui-geo-B4hDk5NO.js → vue-ui-geo-BCmDw5me.js} +8 -8
  143. package/dist/{vue-ui-gizmo-D6nCCsS4.js → vue-ui-gizmo-BZBV8haQ.js} +4 -4
  144. package/dist/{vue-ui-heatmap-scVJc1cw.js → vue-ui-heatmap-CjiffI23.js} +8 -8
  145. package/dist/{vue-ui-hill-DnYUHGAK.js → vue-ui-hill-D5WV6zro.js} +7 -7
  146. package/dist/{vue-ui-history-plot-C5qAMaaW.js → vue-ui-history-plot-Bd06L1Od.js} +9 -9
  147. package/dist/{vue-ui-horizontal-bar-nEG4uvpv.js → vue-ui-horizontal-bar-B5Yp6Uql.js} +11 -11
  148. package/dist/{vue-ui-kpi-DOxId6xg.js → vue-ui-kpi-CNreX8BM.js} +4 -4
  149. package/dist/{vue-ui-label-BDKY7BI7.js → vue-ui-label-BDP67zvQ.js} +4 -4
  150. package/dist/{vue-ui-mini-loader-BknVs9VJ.js → vue-ui-mini-loader-pzS7SsP4.js} +3 -3
  151. package/dist/{vue-ui-molecule-_x232mMu.js → vue-ui-molecule-DqeRhja8.js} +6 -6
  152. package/dist/{vue-ui-mood-radar-D-F4855V.js → vue-ui-mood-radar-Cgl_QD-j.js} +8 -8
  153. package/dist/{vue-ui-nested-donuts-0E5IllFW.js → vue-ui-nested-donuts-MDPBZLnW.js} +10 -10
  154. package/dist/{vue-ui-onion-Eip0S1H7.js → vue-ui-onion-kgZ3uV3c.js} +10 -10
  155. package/dist/{vue-ui-parallel-coordinate-plot-DO0sQdJw.js → vue-ui-parallel-coordinate-plot-CJbZCsPd.js} +10 -10
  156. package/dist/{vue-ui-quadrant-CA0ClWfL.js → vue-ui-quadrant-B9efnVWT.js} +10 -10
  157. package/dist/{vue-ui-quick-chart-D-VuAoll.js → vue-ui-quick-chart-hNOMlqTI.js} +1053 -681
  158. package/dist/{vue-ui-radar-BTD7Y0Ps.js → vue-ui-radar-DJO16PTU.js} +9 -9
  159. package/dist/{vue-ui-rating-C_Qj6gnP.js → vue-ui-rating-BYLWm5aG.js} +3 -3
  160. package/dist/{vue-ui-relation-circle-CcxLBVFV.js → vue-ui-relation-circle-DVF3RlHU.js} +7 -7
  161. package/dist/{vue-ui-ridgeline-BZrzbbhb.js → vue-ui-ridgeline-DvgIu54T.js} +10 -10
  162. package/dist/{vue-ui-rings-CO48GOP2.js → vue-ui-rings-DVU7F6bL.js} +11 -11
  163. package/dist/{vue-ui-scatter-DrxUgZbQ.js → vue-ui-scatter-BtlRfhTt.js} +10 -10
  164. package/dist/{vue-ui-skeleton-CeKjW4MX.js → vue-ui-skeleton-DcMhyC4L.js} +4 -4
  165. package/dist/{vue-ui-smiley-BvRwx69s.js → vue-ui-smiley-qHvZQJcB.js} +3 -3
  166. package/dist/{vue-ui-spark-trend-DnujGRyt.js → vue-ui-spark-trend-BuHZP190.js} +4 -4
  167. package/dist/{vue-ui-sparkbar-Cd_uhYGD.js → vue-ui-sparkbar-MH9VeqdO.js} +4 -4
  168. package/dist/{vue-ui-sparkgauge-hT31YEtt.js → vue-ui-sparkgauge-Bg_IFD0m.js} +4 -4
  169. package/dist/{vue-ui-sparkhistogram-PKlTYhKA.js → vue-ui-sparkhistogram-DZu07vIL.js} +5 -5
  170. package/dist/vue-ui-sparkline-LwEiJPe6.js +2067 -0
  171. package/dist/{vue-ui-sparkstackbar-R0ij2vi1.js → vue-ui-sparkstackbar-hbIoybeq.js} +5 -5
  172. package/dist/vue-ui-stackbar-CaxNkWPz.js +2660 -0
  173. package/dist/vue-ui-stackline-BJqnZXeR.js +2829 -0
  174. package/dist/{vue-ui-strip-plot-DR3N56rS.js → vue-ui-strip-plot-BWK3JQr6.js} +8 -8
  175. package/dist/{vue-ui-table-Bg6BeLrf.js → vue-ui-table-CRWoH6dc.js} +6 -6
  176. package/dist/{vue-ui-table-heatmap-C1b1Pcp8.js → vue-ui-table-heatmap-Bu9RiTU0.js} +6 -6
  177. package/dist/{vue-ui-table-sparkline-CkVXyequ.js → vue-ui-table-sparkline-CTA_6-gu.js} +5 -5
  178. package/dist/{vue-ui-thermometer-CqkaMF7Z.js → vue-ui-thermometer-Y5CnROrM.js} +7 -7
  179. package/dist/{vue-ui-timer-CgJvNwBv.js → vue-ui-timer-BYEpxxDX.js} +6 -6
  180. package/dist/{vue-ui-tiremarks-B078YJ9M.js → vue-ui-tiremarks-DBndWNiA.js} +7 -7
  181. package/dist/{vue-ui-treemap-Cfjf8mDl.js → vue-ui-treemap-Cw8a0oFl.js} +10 -10
  182. package/dist/{vue-ui-waffle-BZIcPa0l.js → vue-ui-waffle-BvfD05mS.js} +11 -11
  183. package/dist/{vue-ui-wheel-CPTm8AHn.js → vue-ui-wheel-D6NsnLRc.js} +7 -7
  184. package/dist/{vue-ui-word-cloud-DnGblUwj.js → vue-ui-word-cloud-YrgMp1Fo.js} +8 -8
  185. package/dist/{vue-ui-world-KkcpeKqp.js → vue-ui-world-BMcqvuJH.js} +8 -8
  186. package/dist/{vue-ui-xy-ClCV7xA5.js → vue-ui-xy-B6wckF4S.js} +4 -4
  187. package/dist/vue-ui-xy-Bv7fhRbS.js +5769 -0
  188. package/dist/{vue-ui-xy-canvas-BlpCbXKR.js → vue-ui-xy-canvas-NzaEYHDR.js} +875 -560
  189. package/dist/{vue_ui_candlestick-J8jmJvxP.js → vue_ui_candlestick-BXSQY82k.js} +96 -9
  190. package/dist/{vue_ui_donut_evolution-D1yAAIHr.js → vue_ui_donut_evolution-C6951a2f.js} +35 -7
  191. package/dist/{vue_ui_quick_chart-mZBdml3Z.js → vue_ui_quick_chart-DByCqSYE.js} +45 -4
  192. package/dist/{vue_ui_sparkline-auZhap6Y.js → vue_ui_sparkline-b9pEUyGF.js} +33 -1
  193. package/dist/{vue_ui_stackbar-COOrQQdK.js → vue_ui_stackbar-DdjDL6aq.js} +88 -9
  194. package/dist/{vue_ui_stackline-DQqKPA9z.js → vue_ui_stackline-Bh0RuInt.js} +88 -9
  195. package/dist/{vue_ui_xy-BA3-_LCx.js → vue_ui_xy-CcJADijP.js} +78 -9
  196. package/dist/{vue_ui_xy_canvas-Cb6dg3eK.js → vue_ui_xy_canvas-DrNSzYWq.js} +88 -9
  197. package/package.json +1 -1
  198. package/dist/SlicerPreview-BJ4usfYd.js +0 -1708
  199. package/dist/vue-data-ui-BVzA0tEV.js +0 -280
  200. package/dist/vue-ui-candlestick-BJtdA4Yu.js +0 -1871
  201. package/dist/vue-ui-donut-evolution-C0BKntfL.js +0 -1552
  202. package/dist/vue-ui-sparkline-BSu1uRvP.js +0 -1610
  203. package/dist/vue-ui-stackbar-BrzzkGFk.js +0 -2369
  204. package/dist/vue-ui-stackline-zEX3gR3y.js +0 -2483
  205. package/dist/vue-ui-xy-C6lVqZnx.js +0 -5367
@@ -0,0 +1,2829 @@
1
+ import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
2
+ import { $ as t, $t as n, B as r, Ct as i, D as a, Dt as o, Et as s, M as c, P as l, Pt as u, Qt as d, Rt as f, S as p, U as m, Vt as h, X as g, Zt as _, _ as ee, at as te, b as ne, c as re, et as ie, ft as ae, gt as oe, ht as se, i as ce, nt as le, qt as ue, t as de, tn as fe, ut as pe, v as me, vt as he, w as ge } from "./lib-CklJ7rIN.js";
3
+ import { n as _e, t as ve } from "./useHints-Dq_w2E8B.js";
4
+ import { n as ye, r as be, t as xe } from "./useTimeLabels-d2f-W1L4.js";
5
+ import { t as Se } from "./useConfig-DObkR9Aa.js";
6
+ import { t as Ce } from "./usePrinter-Dp3X1vqr.js";
7
+ import { n as we, t as Te } from "./BaseScanner-Dzc8VT3j.js";
8
+ import { t as Ee } from "./useNestedProp-Tc9i6ZcN.js";
9
+ import { t as De } from "./useThemeCheck-C43Tcqmk.js";
10
+ import { t as Oe } from "./useChartExport-iwOqiIWX.js";
11
+ import { t as ke } from "./useTransitions-g_zBREk2.js";
12
+ import { t as Ae } from "./useStableElementSize-C7KADDKj.js";
13
+ import { t as je } from "./useTimeLabelCollider-AEcY4Ioe.js";
14
+ import { t as Me } from "./img-CaIaBHA0.js";
15
+ import { n as Ne } from "./Title-C2JKI5td.js";
16
+ import { t as Pe } from "./Shape-B_kDj1gF.js";
17
+ import { t as Fe } from "./_plugin-vue_export-helper-B3ysoDQm.js";
18
+ import { l as Ie, t as Le } from "./useResponsive-ZtArZtUf.js";
19
+ import { t as Re } from "./DefGrad-DVBqDjhO.js";
20
+ import { t as ze } from "./SlicerPreview-BgyIezm0.js";
21
+ import { t as Be } from "./BaseLegendToggle-DtS_Oj3B.js";
22
+ import { t as Ve } from "./A11yDataTable-DdRsVULz.js";
23
+ import { t as He } from "./useUserOptionState-DK-_1ddE.js";
24
+ import { t as Ue } from "./useChartAccessibility-DYqac8yF.js";
25
+ import { t as We } from "./Legend-Dv90gh-6.js";
26
+ import { t as Ge } from "./vue_ui_stackline-Bh0RuInt.js";
27
+ import { Fragment as v, Teleport as Ke, computed as y, createBlock as b, createCommentVNode as x, createElementBlock as S, createElementVNode as C, createSlots as qe, createTextVNode as Je, createVNode as Ye, defineAsyncComponent as Xe, guardReactiveProps as w, mergeProps as Ze, nextTick as Qe, normalizeClass as T, normalizeProps as E, normalizeStyle as $e, onBeforeUnmount as et, onMounted as tt, openBlock as D, ref as O, renderList as k, renderSlot as A, resolveDynamicComponent as nt, shallowRef as rt, toDisplayString as it, toRefs as at, unref as j, useSlots as ot, watch as st, watchEffect as ct, withCtx as M } from "vue";
28
+ //#region src/components/vue-ui-stackline.vue
29
+ var lt = /* @__PURE__ */ e({ default: () => $t }), ut = ["id"], dt = ["id"], ft = ["id"], pt = { style: { position: "relative" } }, mt = [
30
+ "aria-describedby",
31
+ "xmlns",
32
+ "viewBox"
33
+ ], ht = ["id"], gt = [
34
+ "x",
35
+ "y",
36
+ "width",
37
+ "height"
38
+ ], _t = { key: 0 }, vt = [
39
+ "x",
40
+ "y",
41
+ "width",
42
+ "height"
43
+ ], yt = { key: 1 }, bt = [
44
+ "x1",
45
+ "x2",
46
+ "y1",
47
+ "y2",
48
+ "stroke",
49
+ "stroke-width",
50
+ "stroke-dasharray"
51
+ ], xt = [
52
+ "x1",
53
+ "x2",
54
+ "y1",
55
+ "y2",
56
+ "stroke",
57
+ "stroke-width",
58
+ "stroke-dasharray"
59
+ ], St = [
60
+ "x1",
61
+ "x2",
62
+ "y1",
63
+ "y2",
64
+ "stroke",
65
+ "stroke-width"
66
+ ], Ct = [
67
+ "x1",
68
+ "x2",
69
+ "y1",
70
+ "y2",
71
+ "stroke",
72
+ "stroke-width"
73
+ ], wt = [
74
+ "x",
75
+ "y",
76
+ "font-size",
77
+ "fill",
78
+ "font-weight"
79
+ ], Tt = [
80
+ "transform",
81
+ "font-size",
82
+ "fill",
83
+ "font-weight"
84
+ ], Et = [
85
+ "x",
86
+ "y",
87
+ "width",
88
+ "height",
89
+ "stroke",
90
+ "stroke-width",
91
+ "stroke-linecap",
92
+ "stroke-linejoin",
93
+ "stroke-dasharray"
94
+ ], Dt = ["clip-path"], Ot = [
95
+ "d",
96
+ "fill",
97
+ "opacity"
98
+ ], kt = [
99
+ "d",
100
+ "stroke",
101
+ "stroke-width"
102
+ ], At = [
103
+ "x1",
104
+ "x2",
105
+ "y1",
106
+ "y2",
107
+ "stroke"
108
+ ], jt = [
109
+ "transform",
110
+ "font-size",
111
+ "font-weight",
112
+ "fill",
113
+ "text-anchor"
114
+ ], Mt = { key: 0 }, Nt = { key: 1 }, Pt = [
115
+ "text-anchor",
116
+ "font-size",
117
+ "font-weight",
118
+ "fill",
119
+ "stroke",
120
+ "transform",
121
+ "onClick"
122
+ ], Ft = [
123
+ "text-anchor",
124
+ "font-size",
125
+ "fill",
126
+ "transform",
127
+ "innerHTML",
128
+ "onClick"
129
+ ], It = [
130
+ "x",
131
+ "y",
132
+ "height",
133
+ "width",
134
+ "fill"
135
+ ], Lt = { key: 0 }, Rt = [
136
+ "x1",
137
+ "x2",
138
+ "y1",
139
+ "y2",
140
+ "stroke",
141
+ "stroke-width",
142
+ "stroke-dasharray"
143
+ ], zt = ["clip-path"], Bt = { key: 0 }, Vt = [
144
+ "transform",
145
+ "font-size",
146
+ "fill",
147
+ "font-weight"
148
+ ], Ht = [
149
+ "transform",
150
+ "font-size",
151
+ "font-weight",
152
+ "fill"
153
+ ], Ut = [
154
+ "x",
155
+ "y",
156
+ "width",
157
+ "height",
158
+ "fill",
159
+ "fill-opacity",
160
+ "stroke",
161
+ "stroke-opacity",
162
+ "stroke-width",
163
+ "stroke-dasharray"
164
+ ], Wt = ["data-start", "data-end"], Gt = {
165
+ key: 0,
166
+ style: {
167
+ position: "absolute",
168
+ top: "100%",
169
+ left: "0",
170
+ width: "100%"
171
+ },
172
+ "data-dom-to-png-ignore": "",
173
+ "aria-hidden": "true"
174
+ }, Kt = {
175
+ key: 5,
176
+ class: "vue-data-ui-watermark"
177
+ }, qt = ["onClick"], Jt = { key: 0 }, Yt = { key: 1 }, Xt = ["innerHTML"], Zt = ["id"], Qt = 280, $t = /*#__PURE__*/ Fe({
178
+ __name: "vue-ui-stackline",
179
+ props: {
180
+ config: {
181
+ type: Object,
182
+ default() {
183
+ return {};
184
+ }
185
+ },
186
+ dataset: {
187
+ type: Array,
188
+ default() {
189
+ return [];
190
+ }
191
+ },
192
+ selectedXIndex: {
193
+ type: Number,
194
+ default: void 0
195
+ },
196
+ zoomState: {
197
+ type: Object,
198
+ default: null
199
+ }
200
+ },
201
+ emits: [
202
+ "selectDatapoint",
203
+ "selectLegend",
204
+ "selectTimeLabel",
205
+ "selectX",
206
+ "zoomStart",
207
+ "zoomEnd",
208
+ "zoomReset",
209
+ "update:zoomState",
210
+ "copyAlt"
211
+ ],
212
+ setup(e, { expose: Fe, emit: lt }) {
213
+ let $t = Xe(() => import("./Tooltip-2NAb_Rrx.js")), en = Xe(() => import("./BaseIcon-BV75ei8X.js").then((e) => e.n)), tn = Xe(() => import("./vue-ui-accordion-15kKhkup.js").then((e) => e.n)), nn = Xe(() => import("./DataTable-DX5fToAo.js")), rn = Xe(() => import("./PenAndPaper-DkQ4sEhs.js").then((e) => e.t)), an = Xe(() => import("./UserOptions-Dgn3StKw.js").then((e) => e.n)), on = Xe(() => import("./PackageVersion-DhXk363L.js").then((e) => e.t)), sn = Xe(() => import("./BaseDraggableDialog-C1Slb3Yh.js").then((e) => e.n)), { vue_ui_stackline: cn } = Se(), { isThemeValid: ln, warnInvalidTheme: un } = De(), dn = ot(), N = e, P = lt, fn = y({
214
+ get() {
215
+ return !!N.dataset && N.dataset.length;
216
+ },
217
+ set(e) {
218
+ return e;
219
+ }
220
+ }), pn = O(null), F = O(g()), mn = O(!1), I = O([]), hn = O(0), gn = O(null), _n = O(null), vn = O(null), yn = O(null), bn = O(null), xn = O(!1), Sn = O(!1), Cn = O(0), wn = O(0), Tn = O(0), En = O(!1), Dn = O(null), On = O(null), kn = O(!1), An = O(null), jn = O(null), Mn = O(null), Nn = O(null), Pn = O(null), Fn = rt(null), In = O(!1), Ln = O(0), Rn = O(0), zn = O(null), Bn = O({
221
+ x: 0,
222
+ y: 0
223
+ }), Vn = O("pointer"), Hn = Ae({
224
+ elementRef: Fn,
225
+ minimumWidth: 2,
226
+ minimumHeight: 2,
227
+ stableFramesRequired: 2,
228
+ once: !1,
229
+ onSizeAccepted: () => {
230
+ Gn();
231
+ }
232
+ });
233
+ function Un() {
234
+ Fn.value = pn.value?.parentNode ?? null;
235
+ }
236
+ function Wn() {
237
+ return new Promise((e) => {
238
+ requestAnimationFrame(() => {
239
+ requestAnimationFrame(e);
240
+ });
241
+ });
242
+ }
243
+ async function Gn() {
244
+ let e = ++Rn.value;
245
+ In.value = !1, await Qe(), await Wn(), await Wn(), e === Rn.value && (Ln.value += 1, In.value = !0);
246
+ }
247
+ let Kn = O(null), qn = O(!1);
248
+ function Jn() {
249
+ qn.value = !qn.value;
250
+ }
251
+ tt(() => {
252
+ Un(), Hn.start(), En.value = !0, Sr(), Gn();
253
+ });
254
+ let L = O(or()), R = y(() => L.value.userOptions), z = y(() => L.value.style.chart.grid.x.timeLabels), B = y(() => L.value.style.chart.grid), V = y(() => L.value.style.chart.lines), H = y(() => L.value.style.chart.tooltip), U = y(() => L.value.style.chart);
255
+ _e({
256
+ config: () => L.value,
257
+ dataset: () => N.dataset,
258
+ component: "VueUiStackline",
259
+ rules: [
260
+ ve.emptyArray,
261
+ {
262
+ test: (e) => e.some((e) => e.series.length > 200),
263
+ message: [
264
+ "👀 Some series have > 200 datapoints, which can impact performance. Consider:",
265
+ "",
266
+ "▶️ Aggregating data to larger time units, to reduce the number of datapoints.",
267
+ "",
268
+ "▶️ Using filters to constraint the data to a specific time range."
269
+ ]
270
+ },
271
+ {
272
+ test: (e) => e.length > 6,
273
+ message: [
274
+ "👀 The number of series > 6, which can make the chart hard to read. Consider:",
275
+ "",
276
+ "▶️ Grouping small values into an \"Other\" category.",
277
+ "",
278
+ "▶️ Using filters to let users choose a maximum number of series to display."
279
+ ]
280
+ }
281
+ ]
282
+ });
283
+ let { transitionEnabled: Yn } = ke({
284
+ config: () => L.value.transitions,
285
+ dataset: () => N.dataset
286
+ }), Xn = y(() => L.value.userOptions.useCursorPointer), Zn = y(() => fe({
287
+ defaultConfig: {
288
+ userOptions: { show: !1 },
289
+ useCssAnimation: !1,
290
+ table: { show: !1 },
291
+ tooltip: { show: !1 },
292
+ style: { chart: {
293
+ backgroundColor: "#99999930",
294
+ lines: {
295
+ totalValues: { show: !1 },
296
+ dataLabels: { show: !1 }
297
+ },
298
+ grid: {
299
+ frame: { stroke: "#6A6A6A" },
300
+ scale: {
301
+ scaleMin: 0,
302
+ scaleMax: 144
303
+ },
304
+ x: {
305
+ axisColor: "#6A6A6A",
306
+ linesColor: "#6A6A6A",
307
+ axisName: { show: !1 },
308
+ timeLabels: { show: !1 }
309
+ },
310
+ y: {
311
+ axisColor: "#6A6A6A",
312
+ linesColor: "#6A6A6A",
313
+ axisName: { show: !1 },
314
+ axisLabels: { show: !1 }
315
+ }
316
+ },
317
+ legend: { backgroundColor: "transparent" },
318
+ padding: {
319
+ left: 24,
320
+ right: 24,
321
+ bottom: 12
322
+ },
323
+ zoom: {
324
+ show: !1,
325
+ startIndex: null,
326
+ endIndex: null,
327
+ keepState: !1
328
+ }
329
+ } }
330
+ },
331
+ userConfig: L.value.skeletonConfig ?? {}
332
+ })), { loading: Qn, FINAL_DATASET: $n, manualLoading: er } = we({
333
+ ...at(N),
334
+ FINAL_CONFIG: L,
335
+ prepareConfig: or,
336
+ callback: () => {
337
+ Promise.resolve().then(async () => {
338
+ (!U.value.zoom.keepState || !Xi.value || Y.value.start === 0 && Y.value.end === 0) && await Qi();
339
+ });
340
+ },
341
+ skeletonDataset: N.config?.skeletonDataset ?? [{
342
+ name: "",
343
+ series: [
344
+ 3,
345
+ 2,
346
+ 1,
347
+ 5,
348
+ 13,
349
+ 21,
350
+ 8,
351
+ 89,
352
+ 34,
353
+ 55
354
+ ],
355
+ color: "#8A8A8A"
356
+ }, {
357
+ name: "",
358
+ series: [
359
+ 1,
360
+ 2,
361
+ 3,
362
+ 5,
363
+ 8,
364
+ 13,
365
+ 21,
366
+ 34,
367
+ 55,
368
+ 89
369
+ ],
370
+ color: "#CACACA"
371
+ }],
372
+ skeletonConfig: fe({
373
+ defaultConfig: L.value,
374
+ userConfig: Zn.value
375
+ })
376
+ }), { userOptionsVisible: tr, setUserOptionsVisibility: nr, keepUserOptionState: rr } = He({ config: L.value }), { svgRef: W } = Ue({ config: U.value.title });
377
+ function ir() {
378
+ kn.value = !0, nr(!0);
379
+ }
380
+ function ar() {
381
+ nr(!1), kn.value = !1, zn.value = null, Vn.value = "pointer", mn.value = !1, $.value = null, P("selectX", {
382
+ index: null,
383
+ indexLabel: null,
384
+ dataset: null
385
+ });
386
+ }
387
+ function or() {
388
+ let e = Ee({
389
+ userConfig: N.config,
390
+ defaultConfig: cn
391
+ }), t = {};
392
+ N.config && i(N.config, "style.chart.grid.x.timeLabels.showFirstAndLast") && (e.style.chart.grid.x.timeLabels.showFirstAndLast = !!N.config.style.chart.grid.x.timeLabels.showFirstAndLast);
393
+ let r = e.theme;
394
+ if (r) {
395
+ if (!ln.value(e)) un(e), t = e;
396
+ else {
397
+ let i = Ee({
398
+ userConfig: Ge[r] || N.config,
399
+ defaultConfig: e
400
+ });
401
+ t = {
402
+ ...Ee({
403
+ userConfig: N.config,
404
+ defaultConfig: i
405
+ }),
406
+ customPalette: e.customPalette.length ? e.customPalette : n[r] || h
407
+ };
408
+ }
409
+ } else t = e;
410
+ return t;
411
+ }
412
+ let sr = y(() => V.value.dataLabels.hideUnderValue !== null), cr = y(() => V.value.dataLabels.hideUnderPercentage !== null);
413
+ function lr(e) {
414
+ let t = ie(e);
415
+ return t?.style?.chart && delete t.style.chart.tooltip, JSON.stringify(t);
416
+ }
417
+ let ur = lr(N.config);
418
+ st(() => N.config, (e, t) => {
419
+ let n = lr(e), r = n !== ur;
420
+ ur = n;
421
+ let i = or();
422
+ if (!r) {
423
+ L.value.style.chart.tooltip = i.style.chart.tooltip, G.value.showTooltip = L.value.style.chart.tooltip.show;
424
+ return;
425
+ }
426
+ Qn.value || (L.value = i), tr.value = !L.value.userOptions.showOnChartHover, G.value.dataLabels.show = V.value.dataLabels.show, G.value.showTable = L.value.table.show, G.value.showTooltip = H.value.show, Sr({ resetSlicer: !U.value.zoom.keepState }), Cn.value += 1, wn.value += 1, Tn.value += 1, gr.value.width = U.value.width, gr.value.height = U.value.height, gr.value.paddingRatio = {
427
+ top: U.value.padding.top / U.value.height,
428
+ right: U.value.padding.right / U.value.width,
429
+ bottom: U.value.padding.bottom / U.value.height,
430
+ left: U.value.padding.left / U.value.width
431
+ }, Un(), Gn(), !U.value.zoom.keepState || !Xi.value || Y.value.start === 0 && Y.value.end === 0 ? Qi() : vi();
432
+ }, { deep: !0 }), st(() => N.dataset, (e) => {
433
+ Array.isArray(e) && e.length > 0 && (er.value = !1), U.value.zoom.keepState ? vi() : xi(), Un(), Gn();
434
+ }, { deep: !0 });
435
+ let G = O({
436
+ dataLabels: { show: V.value.dataLabels.show },
437
+ showTable: L.value.table.show,
438
+ showTooltip: H.value.show
439
+ });
440
+ st(L, () => {
441
+ G.value = {
442
+ dataLabels: { show: V.value.dataLabels.show },
443
+ showTable: L.value.table.show,
444
+ showTooltip: H.value.show
445
+ };
446
+ }, { immediate: !0 });
447
+ let { isPrinting: dr, isImaging: fr, generatePdf: pr, generateImage: mr } = Ce({
448
+ elementId: `stackline_${F.value}`,
449
+ fileName: U.value.title.text || "vue-ui-stackline",
450
+ options: L.value.userOptions.print
451
+ }), hr = y(() => L.value.userOptions.show && !U.value.title.text), gr = O({
452
+ width: U.value.width,
453
+ height: U.value.height,
454
+ paddingRatio: {
455
+ top: U.value.padding.top / U.value.height,
456
+ right: U.value.padding.right / U.value.width,
457
+ bottom: U.value.padding.bottom / U.value.height,
458
+ left: U.value.padding.left / U.value.width
459
+ }
460
+ }), _r = y(() => ge(L.value.customPalette)), vr = rt(null), yr = rt(null), br = O(null), xr = y(() => L.value.debug);
461
+ function Sr({ resetSlicer: e = !0 } = {}) {
462
+ if (f(N.dataset) ? (te({
463
+ componentName: "VueUiStackline",
464
+ type: "dataset",
465
+ debug: xr.value
466
+ }), er.value = !0) : N.dataset.forEach((e, t) => {
467
+ he({
468
+ datasetObject: e,
469
+ requiredAttributes: ["name", "series"]
470
+ }).forEach((e) => {
471
+ fn.value = !1, te({
472
+ componentName: "VueUiStackline",
473
+ type: "datasetSerieAttribute",
474
+ property: e,
475
+ index: t,
476
+ debug: xr.value
477
+ }), er.value = !0;
478
+ });
479
+ }), f(N.dataset) || (er.value = L.value.loading), setTimeout(() => {
480
+ Sn.value = !0;
481
+ }, 10), L.value.responsive) {
482
+ let e = Ie(() => {
483
+ Sn.value = !1;
484
+ let { width: e, height: t } = Le({
485
+ chart: pn.value,
486
+ noTitle: yn.value,
487
+ title: U.value.title.text ? gn.value : null,
488
+ legend: U.value.legend.show ? _n.value : null,
489
+ slicer: U.value.zoom.show && J.value > 6 ? vn.value.$el : null,
490
+ source: bn.value
491
+ });
492
+ requestAnimationFrame(() => {
493
+ gr.value.width = e, gr.value.height = t - 12, clearTimeout(br.value), br.value = setTimeout(() => {
494
+ Sn.value = !0;
495
+ }, 10);
496
+ });
497
+ });
498
+ vr.value && (yr.value && vr.value.unobserve(yr.value), vr.value.disconnect()), vr.value = new ResizeObserver(e), yr.value = pn.value.parentNode, vr.value.observe(yr.value);
499
+ }
500
+ e && Qi();
501
+ }
502
+ et(() => {
503
+ Hn.stop(), vr.value && (yr.value && vr.value.unobserve(yr.value), vr.value.disconnect());
504
+ });
505
+ let Cr = y(() => B.value.y.position === "right");
506
+ function wr() {
507
+ let e = 0;
508
+ Mn.value && (e = Array.from(Mn.value.querySelectorAll("text")).reduce((e, t) => {
509
+ let n = t.getComputedTextLength();
510
+ return n > e ? n : e;
511
+ }, 0));
512
+ let t = jn.value ? jn.value.getBoundingClientRect().width + B.value.y.axisName.fontSize + B.value.y.axisName.offsetX : 0;
513
+ return {
514
+ left: Cr.value ? 0 : e + t,
515
+ right: Cr.value ? e + t : 0,
516
+ scaleLabelsWidth: e,
517
+ yAxisLabelWidth: t
518
+ };
519
+ }
520
+ let Tr = O(0), Er = O(0), Dr = O(0);
521
+ function Or() {
522
+ let e = Nn.value;
523
+ if (!e) {
524
+ Er.value = 0;
525
+ return;
526
+ }
527
+ try {
528
+ let t = e.getBBox();
529
+ Er.value = Number.isFinite(t?.height) ? t.height : 0;
530
+ } catch {
531
+ Er.value = 0;
532
+ }
533
+ }
534
+ function kr() {
535
+ Dr.value && cancelAnimationFrame(Dr.value), Dr.value = requestAnimationFrame(() => {
536
+ requestAnimationFrame(() => {
537
+ Or();
538
+ });
539
+ });
540
+ }
541
+ et(() => {
542
+ Dr.value && cancelAnimationFrame(Dr.value), Er.value = 0, Tr.value = 0;
543
+ });
544
+ let Ar = y(() => {
545
+ let e = 0;
546
+ if (An.value) try {
547
+ e = An.value.getBBox().height;
548
+ } catch {
549
+ e = 0;
550
+ }
551
+ let t = z.value.show ? Er.value : 0;
552
+ return e + t;
553
+ }), K = y(() => {
554
+ Ln.value;
555
+ let { height: e, width: t } = gr.value, { right: n } = gr.value.paddingRatio, r = V.value.totalValues.show && N.dataset && N.dataset.length > 1 ? V.value.totalValues.fontSize * 1.3 : 0, i = 0, a = 0, o = 0, s = 0;
556
+ if (B.value.y.axisLabels.show) {
557
+ let e = wr();
558
+ i = e.left, a = e.right, o = e.scaleLabelsWidth, s = e.yAxisLabelWidth;
559
+ }
560
+ let c = U.value.padding.top + r, l = t - t * n - Tr.value - a, u = e - U.value.padding.bottom - Ar.value - r, d = U.value.padding.left + i, f = t - d - t * n - Tr.value - a, p = e - c - U.value.padding.bottom - Ar.value - r;
561
+ return {
562
+ chartHeight: Math.max(0, e),
563
+ chartWidth: Math.max(0, t),
564
+ top: c,
565
+ right: Math.max(0, l),
566
+ bottom: Math.max(0, u),
567
+ left: Math.max(0, d),
568
+ width: Math.max(0, f),
569
+ height: Math.max(0, p),
570
+ offsetLeftAxis: i,
571
+ offsetRightAxis: a,
572
+ scaleLabelsWidth: o,
573
+ yAxisLabelWidth: s
574
+ };
575
+ }), jr = y(() => {
576
+ let { left: e, top: t, width: n, height: r } = K.value, i = Y.value.start, a = Y.value.end, o = Math.max(1, a - i), s = Math.max(0, Math.min(o, (Fr.value.start ?? i) - i)), c = Math.max(0, Math.min(o, (Fr.value.end ?? a) - i)), l = Math.max(0, c - s), u = {
577
+ fill: U.value.zoom.preview.fill,
578
+ stroke: U.value.zoom.preview.stroke,
579
+ "stroke-width": U.value.zoom.preview.strokeWidth,
580
+ "stroke-dasharray": U.value.zoom.preview.strokeDasharray,
581
+ "stroke-linecap": "round",
582
+ "stroke-linejoin": "round",
583
+ style: {
584
+ pointerEvents: "none",
585
+ transition: "none !important",
586
+ animation: "none !important"
587
+ }
588
+ }, d = n / o;
589
+ return {
590
+ x: e + s * d,
591
+ y: t,
592
+ width: l * d,
593
+ height: r,
594
+ ...u
595
+ };
596
+ }), q = y(() => $n.value.map((e, t) => {
597
+ let n = g(), r = p(e.color) || _r.value[t] || h[t] || h[t % h.length];
598
+ return {
599
+ ...e,
600
+ shape: e.shape || "circle",
601
+ standalone: !!e.standalone,
602
+ series: JSON.parse(JSON.stringify(e.series)).map((e) => V.value.distributed ? Math.abs(e) : e),
603
+ seriesSource: e.series,
604
+ signedSeries: e.series.map((e) => e >= 0 ? 1 : -1),
605
+ absoluteIndex: t,
606
+ id: n,
607
+ color: r
608
+ };
609
+ })), Mr = y(() => q.value.filter((e) => !I.value.includes(e.id) && !e.standalone)), Nr = y(() => q.value.filter((e) => !I.value.includes(e.id) && e.standalone)), J = y(() => {
610
+ let e = Math.max(...q.value.filter((e) => !I.value.includes(e.id)).map((e) => e.series.length));
611
+ return isFinite(e) ? e : Math.max(...q.value.map((e) => e.series.length));
612
+ });
613
+ function Pr(e) {
614
+ Kn.value = e;
615
+ }
616
+ let Y = O({
617
+ start: 0,
618
+ end: Math.max(...$n.value.map((e) => e.series.length))
619
+ }), Fr = O({
620
+ start: 0,
621
+ end: Math.max(...$n.value.map((e) => e.series.length))
622
+ }), Ir = O(!1), Lr = O(!1), Rr = O(!1), zr = O("matrix(1, 0, 0, 1, 0, 0)"), Br = O(!1), Vr = 0, Hr = 0, Ur = 0, Wr = 0, Gr = O(null), Kr = O(null), qr = O(null), Jr = O(!1), Yr = O({
623
+ time: 0,
624
+ x: 0,
625
+ y: 0,
626
+ pointerType: null
627
+ }), Xr = y(() => U.value.zoom?.dragToZoom), Zr = y(() => Xr.value.show && fn.value && Xi.value && !Qn.value), Qr = null, $r = {};
628
+ function ei(e) {
629
+ return (Y.value.start ?? 0) + (e ?? 0);
630
+ }
631
+ let ti = y(() => U.value.zoom.preview.enable && (Fr.value.start !== Y.value.start || Fr.value.end !== Y.value.end));
632
+ function ni(e, t) {
633
+ Fr.value[e] = t;
634
+ }
635
+ function ri(e, t = Y.value) {
636
+ if (!e || typeof e != "object") return null;
637
+ let n = e.start !== void 0 && e.start !== null, r = e.end !== void 0 && e.end !== null;
638
+ if (!n && !r) return null;
639
+ let i = Number(n ? e.start : t.start), a = Number(r ? e.end : t.end);
640
+ return !Number.isFinite(i) || !Number.isFinite(a) ? null : {
641
+ start: i,
642
+ end: a
643
+ };
644
+ }
645
+ function ii(e) {
646
+ let t = ri(e);
647
+ t && P("update:zoomState", t);
648
+ }
649
+ function ai() {
650
+ Qr &&= (cancelAnimationFrame(Qr), null), $r = {};
651
+ }
652
+ function oi(e = Y.value) {
653
+ return {
654
+ start: Number(e.start),
655
+ end: Number(e.end)
656
+ };
657
+ }
658
+ function si(e, t) {
659
+ let n = Number(K.value?.left) || 0, r = Math.max(0, Number(K.value?.width) || 0), i = Number(t?.start), a = Number(t?.end), o = a - i;
660
+ return !Number.isFinite(e) || !Number.isFinite(i) || !Number.isFinite(a) || o <= 0 ? n : o <= 1 ? n + r / 2 : n + (e - i) / (o - 1) * r;
661
+ }
662
+ function ci() {
663
+ if (V.value.distributed) return null;
664
+ let e = (Ni.value || []).filter((e) => Number.isFinite(e?.value) && Number.isFinite(e?.y));
665
+ if (e.length < 2) return null;
666
+ let t = e.reduce((e, t) => t.value < e.value ? t : e), n = e.reduce((e, t) => t.value > e.value ? t : e);
667
+ return n.value === t.value || n.y === t.y ? null : {
668
+ minValue: t.value,
669
+ maxValue: n.value,
670
+ minY: t.y,
671
+ maxY: n.y
672
+ };
673
+ }
674
+ function li(e, t) {
675
+ if (!t || !Number.isFinite(e)) return Number(K.value?.bottom) || 0;
676
+ let n = t.maxValue - t.minValue;
677
+ if (!Number.isFinite(n) || n === 0) return t.minY;
678
+ let r = (e - t.minValue) / n;
679
+ return t.minY + (t.maxY - t.minY) * r;
680
+ }
681
+ function ui({ previousRange: e, targetRange: t, previousYScale: n, targetYScale: r }) {
682
+ let i = Number(t.start), a = Number(t.end) - 1, o = 1, s = 0;
683
+ if (Number.isFinite(i) && Number.isFinite(a) && a > i) {
684
+ let n = si(i, t), r = si(a, t), c = si(i, e), l = si(a, e), u = r - n;
685
+ Number.isFinite(u) && Math.abs(u) > 1e-9 && (o = (l - c) / u, s = c - o * n);
686
+ }
687
+ let c = 1, l = 0;
688
+ if (n && r) {
689
+ let e = r.minValue, t = r.maxValue, i = li(e, r), a = li(t, r), o = li(e, n), s = li(t, n), u = a - i;
690
+ Number.isFinite(u) && Math.abs(u) > 1e-9 && (c = (s - o) / u, l = o - c * i);
691
+ }
692
+ return [
693
+ o,
694
+ s,
695
+ c,
696
+ l
697
+ ].every(Number.isFinite) ? `matrix(${o}, 0, 0, ${c}, ${s}, ${l})` : "matrix(1, 0, 0, 1, 0, 0)";
698
+ }
699
+ function di({ resetTransform: e = !0 } = {}) {
700
+ Wr += 1, Vr &&= (cancelAnimationFrame(Vr), 0), Hr &&= (cancelAnimationFrame(Hr), 0), Ur &&= (clearTimeout(Ur), 0), Br.value = !1, Rr.value = !1, e && (zr.value = "matrix(1, 0, 0, 1, 0, 0)");
701
+ }
702
+ function fi(e, t) {
703
+ return !W.value || Qn.value || !fn.value || !e || !t || typeof window < "u" && window.matchMedia?.("(prefers-reduced-motion: reduce)")?.matches ? !1 : Number.isFinite(e.start) && Number.isFinite(e.end) && Number.isFinite(t.start) && Number.isFinite(t.end) && e.end > e.start && t.end > t.start;
704
+ }
705
+ function pi(e, t) {
706
+ let n = oi();
707
+ if (!fi(e, n)) return di(), !1;
708
+ let r = ui({
709
+ previousRange: e,
710
+ targetRange: n,
711
+ previousYScale: t,
712
+ targetYScale: ci()
713
+ });
714
+ if (r === "matrix(1, 0, 0, 1, 0, 0)") return di(), !1;
715
+ di();
716
+ let i = ++Wr;
717
+ return Rr.value = !0, Br.value = !1, zr.value = r, Vr = requestAnimationFrame(() => {
718
+ Vr = 0, Hr = requestAnimationFrame(() => {
719
+ Hr = 0, i === Wr && (Br.value = !0, zr.value = "matrix(1, 0, 0, 1, 0, 0)", Ur = setTimeout(() => {
720
+ Ur = 0, i === Wr && (Br.value = !1, Rr.value = !1);
721
+ }, Qt));
722
+ });
723
+ }), !0;
724
+ }
725
+ let mi = y(() => ({
726
+ transform: zr.value,
727
+ transformOrigin: "0 0",
728
+ transformBox: "view-box",
729
+ transition: Br.value ? `transform ${Qt}ms cubic-bezier(0.4, 0, 0.2, 1)` : "none",
730
+ willChange: Rr.value ? "transform" : void 0
731
+ })), hi = y(() => Rr.value ? `url(#vue_ui_stackline_zoom_clip_${F.value})` : void 0);
732
+ function gi(e, { transition: t = !1 } = {}) {
733
+ let n = ri(e);
734
+ if (!n) return null;
735
+ let { start: r, end: i } = n;
736
+ if (r !== Number(Y.value.start) || i !== Number(Y.value.end)) {
737
+ let e = oi(), n = ci();
738
+ ai(), Y.value = {
739
+ start: r,
740
+ end: i
741
+ }, Fr.value = {
742
+ start: r,
743
+ end: i
744
+ }, vi(), t && pi(e, n);
745
+ }
746
+ return {
747
+ start: Number(Y.value.start),
748
+ end: Number(Y.value.end)
749
+ };
750
+ }
751
+ function _i(e, { transition: t = !0 } = {}) {
752
+ let n = gi(e, { transition: t });
753
+ return n ? (P("update:zoomState", n), n) : null;
754
+ }
755
+ function vi() {
756
+ let e = J.value, t = Math.max(0, Math.min(Y.value.start ?? 0, e - 1)), n = Math.max(t + 1, Math.min(Y.value.end ?? e, e));
757
+ (!Number.isFinite(t) || !Number.isFinite(n) || n <= t) && (t = 0, n = e), Y.value.start = t, Y.value.end = n, Fr.value.start = t, Fr.value.end = n, vn.value && vn.value.setRangeValues(t, n);
758
+ }
759
+ let yi = O(null);
760
+ function bi() {
761
+ return new Promise((e) => requestAnimationFrame(() => requestAnimationFrame(() => e())));
762
+ }
763
+ et(() => {
764
+ yi.value && cancelAnimationFrame(yi.value), ai(), fa(), di();
765
+ });
766
+ async function xi({ force: e = !1, publish: t = !1, transition: n = e && t } = {}) {
767
+ if (U.value.zoom.keepState && !e && Xi.value && (Y.value.start !== 0 || Y.value.end !== 0)) {
768
+ vi();
769
+ return;
770
+ }
771
+ let r = !e, i = n ? oi() : null, a = n ? ci() : null;
772
+ Qi(r), n && pi(i, a), await Qe(), yi.value && cancelAnimationFrame(yi.value), yi.value = requestAnimationFrame(async () => {
773
+ await bi(), Qi(r), yi.value = null, t && (ii({
774
+ start: Number(Y.value.start),
775
+ end: Number(Y.value.end)
776
+ }), P("zoomReset"));
777
+ });
778
+ }
779
+ let Si = y(() => Math.max(0, K.value.width / (Y.value.end - Y.value.start))), Ci = y(() => _(Mr.value.map((e) => ({
780
+ ...e,
781
+ series: e.series.map((e) => e ?? 0)
782
+ }))).slice(Y.value.start, Y.value.end)), wi = y(() => I.value.length === q.value.length), Ti = y(() => {
783
+ if (!U.value.zoom.minimap.show) return [];
784
+ let e = q.value.filter((e) => wi.value ? !0 : !I.value.includes(e.id) && !e.standalone);
785
+ if (e.length) return _(e.map((e) => ({
786
+ ...e,
787
+ series: (e.series || []).map((e) => e ?? 0)
788
+ })));
789
+ let t = Nr.value;
790
+ if (!t.length) return [];
791
+ let n = Math.max(...t.map((e) => e.series.length || 0));
792
+ return Array.from({ length: n }, (e, n) => t.reduce((e, t) => e + Math.abs(t.series[n] ?? 0), 0));
793
+ }), Ei = y(() => {
794
+ if (!U.value.zoom.minimap.show) return [];
795
+ let e = q.value.filter((e) => wi.value ? !0 : !I.value.includes(e.id) && !e.standalone), t = Nr.value, n = e.length ? [{
796
+ name: "",
797
+ series: Ti.value,
798
+ color: "#000000",
799
+ isVisible: !0
800
+ }] : [], r = t.map((e) => ({
801
+ name: e.name || "",
802
+ series: (e.series || []).map((e) => e ?? 0),
803
+ color: e.color,
804
+ isVisible: !0
805
+ }));
806
+ return n.concat(r);
807
+ }), Di = y(() => _(Mr.value.filter((e) => !I.value.includes(e.id)).map((e) => ({
808
+ ...e,
809
+ series: e.series.map((t, n) => {
810
+ let r = t ?? 0;
811
+ return e.signedSeries[n] === -1 && r >= 0 ? -r : r;
812
+ })
813
+ }))).slice(Y.value.start, Y.value.end)), Oi = y(() => {
814
+ let e = Mr.value.filter((e) => !I.value.includes(e.id));
815
+ return {
816
+ positive: _(e.map((e) => ({
817
+ ...e,
818
+ series: e.series.slice(Y.value.start, Y.value.end).map((e) => (e ?? 0) >= 0 ? e ?? 0 : 0)
819
+ }))),
820
+ negative: _(e.map((e) => ({
821
+ ...e,
822
+ series: e.series.slice(Y.value.start, Y.value.end).map((e) => (e ?? 0) < 0 ? e ?? 0 : 0)
823
+ })))
824
+ };
825
+ }), ki = y(() => {
826
+ let e = Math.max(0, Y.value.end - Y.value.start), t = Array(e).fill(0), n = Array(e).fill(0);
827
+ return Nr.value.forEach((r) => {
828
+ for (let i = 0; i < e; i += 1) {
829
+ let e = r.series[Y.value.start + i] ?? 0;
830
+ e > 0 && (t[i] = Math.max(t[i], e)), e < 0 && (n[i] = Math.min(n[i], e));
831
+ }
832
+ }), {
833
+ positive: t,
834
+ negative: n
835
+ };
836
+ }), Ai = y(() => Di.value.map((e, t) => ({
837
+ value: e,
838
+ sign: e >= 0 ? 1 : -1
839
+ })));
840
+ function ji() {
841
+ return { y0: Ni.value?.[0]?.zero ?? K.value.bottom };
842
+ }
843
+ function Mi(e) {
844
+ let { y0: t } = ji(), n = V.value.totalValues, r = Math.max(2, n.fontSize * 1.3 + n.offsetY), i = (e) => Math.min(Math.max(e, K.value.top - V.value.totalValues.fontSize * 1.3), K.value.bottom + V.value.totalValues.fontSize * 2);
845
+ if ((Ai.value?.[e]?.value ?? 0) >= 0 || V.value.distributed) {
846
+ let n = Infinity;
847
+ for (let t of X.value || []) {
848
+ let r = t?.series?.[e], i = t?.topY?.[e];
849
+ (r ?? 0) > 0 && Number.isFinite(i) && i < n && (n = i);
850
+ }
851
+ return i((Number.isFinite(n) ? n : t) - r - V.value.totalValues.offsetY);
852
+ }
853
+ {
854
+ let a = -Infinity;
855
+ for (let t of X.value || []) {
856
+ let n = t?.series?.[e], r = t?.topY?.[e];
857
+ (n ?? 0) < 0 && Number.isFinite(r) && r > a && (a = r);
858
+ }
859
+ return i((Number.isFinite(a) ? a : t) + r + n.fontSize * .7 + V.value.totalValues.offsetY);
860
+ }
861
+ }
862
+ let Ni = y(() => {
863
+ let e = Math.max(...Oi.value.positive, 0), t = Math.min(...Oi.value.negative, 0), n = Math.max(...ki.value.positive, 0), r = Math.min(...ki.value.negative, 0), i = Math.max(e, n), a = Math.min(t, r), o = [
864
+ -Infinity,
865
+ Infinity,
866
+ NaN,
867
+ void 0,
868
+ null
869
+ ].includes(a) ? 0 : a, s = B.value.scale.scaleMin, c = B.value.scale.scaleMax, l = !V.value.distributed && (s !== null || c !== null), u = s !== null && !V.value.distributed ? s : o > 0 ? 0 : o, d = c !== null && !V.value.distributed ? c : i < 0 ? 0 : i, f = l ? me(u, d, B.value.scale.ticks) : ee(u, d, B.value.scale.ticks), p = Math.abs(Number(f.min) || 0), m = (Number(f.max) || 0) + p, h = m === 0 || !Number.isFinite(m) ? 1 : m, g = Array.isArray(f.ticks) && f.ticks.length ? f.ticks : [0], _ = K.value.bottom - K.value.height * (p / h);
870
+ return g.map((e) => {
871
+ let t = Number(e) || 0, n = K.value.bottom - K.value.height * ((t + p) / h);
872
+ return {
873
+ zero: _,
874
+ y: n,
875
+ x: Cr.value ? Z.value.right + 8 : Z.value.left - 8,
876
+ value: t
877
+ };
878
+ });
879
+ }), Pi = O([]), Fi = O([]), Ii = 0;
880
+ ct(() => {
881
+ let e = ++Ii;
882
+ (async () => {
883
+ let t = await xe({
884
+ values: z.value.values,
885
+ maxDatapoints: J.value,
886
+ formatter: z.value.datetimeFormatter,
887
+ start: Y.value.start,
888
+ end: Y.value.end
889
+ });
890
+ e === Ii && (Pi.value = t);
891
+ })();
892
+ });
893
+ let Li = 0;
894
+ ct(() => {
895
+ let e = ++Li;
896
+ (async () => {
897
+ let t = await xe({
898
+ values: z.value.values,
899
+ maxDatapoints: J.value,
900
+ formatter: z.value.datetimeFormatter,
901
+ start: 0,
902
+ end: J.value
903
+ });
904
+ e === Li && (Fi.value = t);
905
+ })();
906
+ });
907
+ let Ri = y(() => {
908
+ let e = Math.max(1, Math.floor(Number(z.value.modulo) || 1)), t = (Pi.value || []).map((e) => e?.text ?? ""), n = (Fi.value || []).map((e) => e?.text ?? ""), r = Y.value.start ?? 0, i = r > 0 || t.length < n.length;
909
+ return se({
910
+ configuredModulo: e,
911
+ visibleTexts: t,
912
+ allTexts: n,
913
+ startAbs: r,
914
+ isZoomed: i
915
+ });
916
+ });
917
+ function zi(e) {
918
+ let t = z.value, n = Pi.value || [], r = Fi.value || [], i = Y.value.start ?? 0, a = J.value, o = n.map((e) => e?.text ?? ""), s = r.map((e) => e?.text ?? ""), c = re(!!t.showOnlyFirstAndLast, !!t.showOnlyAtModulo, Ri.value, o, s, i, e, a);
919
+ if (!t.showFirstAndLast || t.showOnlyFirstAndLast || !c.length) return c;
920
+ let l = c.length - 1;
921
+ return c.map((e, t) => t !== 0 && t !== l ? e : {
922
+ ...e,
923
+ text: o[t] ?? ""
924
+ });
925
+ }
926
+ let Bi = y(() => zi($.value)), Vi = y(() => zi(null));
927
+ ct(() => {
928
+ z.value.show, z.value.fontSize, z.value.rotation, z.value.offsetY, (Vi.value || []).map((e) => e?.text ?? "").join("|"), gr.value.width, gr.value.height, Nn.value, An.value, kr();
929
+ }, { flush: "post" });
930
+ let Hi = O({
931
+ months: [],
932
+ shortMonths: [],
933
+ days: [],
934
+ shortDays: []
935
+ }), Ui = 0;
936
+ ct(() => {
937
+ let e = ++Ui, t = z.value.datetimeFormatter;
938
+ (async () => {
939
+ let n = await be(t.locale).catch(() => be("en"));
940
+ e === Ui && (Hi.value = n.data);
941
+ })();
942
+ });
943
+ let Wi = y(() => {
944
+ let e = z.value.datetimeFormatter, t = ye({
945
+ useUTC: e.useUTC,
946
+ locale: Hi.value,
947
+ januaryAsYear: e.januaryAsYear
948
+ });
949
+ return (e, n) => {
950
+ let r = z.value.values?.[e];
951
+ return r == null ? "" : t.formatDate(new Date(r), n);
952
+ };
953
+ }), Gi = y(() => (z.value.values || []).map((e, t) => ({
954
+ text: Wi.value(t, U.value.zoom.timeFormat),
955
+ absoluteIndex: t
956
+ }))), Ki = y(() => (z.value.values || []).map((e, t) => ({
957
+ text: Wi.value(t, H.value.timeFormat),
958
+ absoluteIndex: t
959
+ }))), qi = y(() => {
960
+ if (!fn.value && !Qn.value) return [];
961
+ let e = K.value.height, t = Ni.value[0] ? Ni.value[0].zero : K.value.bottom, n = Y.value.start ?? 0, r = Y.value.end ?? 0, i = Math.max(1, r - n), a = Math.max(...Oi.value.positive, 0), o = Math.min(...Oi.value.negative, 0), s = Math.max(...ki.value.positive, 0), c = Math.min(...ki.value.negative, 0), l = Math.max(a, s), u = Math.min(o, c), { min: d, max: f } = !V.value.distributed && (B.value.scale.scaleMax !== null || B.value.scale.scaleMin !== null) ? me(B.value.scale.scaleMin === null ? u > 0 ? 0 : u : B.value.scale.scaleMin, B.value.scale.scaleMax === null ? l < 0 ? 0 : l : B.value.scale.scaleMax, B.value.scale.ticks) : ee(B.value.scale.scaleMin === null ? u > 0 ? 0 : u : B.value.scale.scaleMin, B.value.scale.scaleMax === null ? l < 0 ? 0 : l : B.value.scale.scaleMax, B.value.scale.ticks), p = f + (d >= 0 ? 0 : Math.abs(d)) || 1, m = Array(i).fill(0), h = Array(i).fill(0), g = (e) => i <= 1 ? K.value.left + K.value.width / 2 : K.value.left + e / (i - 1) * K.value.width;
962
+ return q.value.filter((e) => !I.value.includes(e.id)).map((r) => {
963
+ let a = [], o = [], s = [], c = Array(i).fill(null), l = Array(i).fill(null);
964
+ for (let u = 0; u < i; u += 1) {
965
+ let i = n + u, d = r.series?.[i], f = r.signedSeries?.[i], g = d == null || Number.isNaN(d) ? 0 : d, _ = r.standalone ? g / p : V.value.distributed ? g / (Ci.value[u] || 1) : g / p;
966
+ if (g >= 0) {
967
+ let n = e * Math.abs(_);
968
+ if (r.standalone) c[u] = t, l[u] = t - n;
969
+ else {
970
+ let e = m[u], r = e + n;
971
+ c[u] = t - e, l[u] = t - r, m[u] = r;
972
+ }
973
+ } else {
974
+ let n = e * Math.abs(_);
975
+ if (r.standalone) c[u] = t, l[u] = t + n;
976
+ else {
977
+ let e = h[u], r = e + n;
978
+ c[u] = t + e, l[u] = t + r, h[u] = r;
979
+ }
980
+ }
981
+ a.push(u), o.push(g), s.push(f ?? (g >= 0 ? 1 : -1));
982
+ }
983
+ let u = a.map((e) => ({
984
+ x: g(e),
985
+ y: l[e]
986
+ })), d = u.map((e) => e.x), f = o.reduce((e, t) => e + Math.abs(t || 0), 0), _ = f === 0 ? 1 : f, ee = o.map((e, t) => {
987
+ if (V.value.distributed && !r.standalone) {
988
+ let n = a[t], r = Ci.value[n] || 1;
989
+ return (e || 0) / r;
990
+ }
991
+ return (e || 0) / _;
992
+ });
993
+ return {
994
+ ...r,
995
+ x: d,
996
+ points: u,
997
+ baseY: a.map((e) => c[e]),
998
+ topY: a.map((e) => l[e]),
999
+ series: o,
1000
+ signedSeries: s,
1001
+ proportions: ee,
1002
+ rel: a,
1003
+ fullSeries: Array.isArray(r.fullSeries) ? r.fullSeries : r.series
1004
+ };
1005
+ });
1006
+ }), X = y(() => {
1007
+ let e = (e) => typeof e == "string" ? e.replace(/^M\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*,?\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*/i, "").trim() : "", t = Math.max(...Oi.value.positive, 0), n = Math.min(...Oi.value.negative, 0), r = Math.max(...ki.value.positive, 0), i = Math.min(...ki.value.negative, 0), a = Math.max(t, r), o = Math.min(n, i), s = !V.value.distributed && (B.value.scale.scaleMax !== null || B.value.scale.scaleMin !== null) ? me(B.value.scale.scaleMin === null ? o > 0 ? 0 : o : B.value.scale.scaleMin, B.value.scale.scaleMax === null ? a < 0 ? 0 : a : B.value.scale.scaleMax, B.value.scale.ticks) : ee(B.value.scale.scaleMin === null ? o > 0 ? 0 : o : B.value.scale.scaleMin, B.value.scale.scaleMax === null ? a < 0 ? 0 : a : B.value.scale.scaleMax, B.value.scale.ticks), c = Number(s.min) || 0, u = Number(s.max) || 0, d = Math.abs(c), f = u + d || 1, p = (e) => {
1008
+ if (V.value.distributed) {
1009
+ let t = Math.max(0, Math.min(1, e));
1010
+ return minimapH - minimapH * t;
1011
+ }
1012
+ return clampY(minimapH - minimapH * (((e ?? 0) + d) / f));
1013
+ };
1014
+ return qi.value.map((t) => {
1015
+ let n = t.x.length, r = Array.isArray(t.fullSeries) ? t.fullSeries : t.series, i = ({ left: e = 0, unitW: t }) => {
1016
+ let n = r.length;
1017
+ return !Number.isFinite(t) || t <= 0 || n <= 0 ? [] : n === 1 ? [e + t * .5] : r.map((n, r) => e + r * t);
1018
+ }, a = ({ minimapH: e }) => !Number.isFinite(e) || e <= 0 ? [] : r.map((t) => p(t || 0, e)), o = ({ minimapH: e }) => {
1019
+ if (!Number.isFinite(e) || e <= 0) return [];
1020
+ let t = p(0, e);
1021
+ return r.map(() => t);
1022
+ };
1023
+ if (n === 0) return {
1024
+ ...t,
1025
+ points: [],
1026
+ smoothPath: "",
1027
+ straightPath: "",
1028
+ smoothArea: "",
1029
+ straightArea: "",
1030
+ xMinimap: i,
1031
+ yMinimap: a,
1032
+ yMinimapBase: o
1033
+ };
1034
+ let s = t.x.map((e, n) => ({
1035
+ x: e,
1036
+ y: t.topY[n]
1037
+ })), c = t.x.map((e, n) => ({
1038
+ x: e,
1039
+ y: t.baseY[n]
1040
+ })), u = n >= 2 ? l(s) : `M${s[0].x},${s[0].y}`, d = n >= 2 ? m(s) : `M${s[0].x},${s[0].y}`, f = n >= 2 ? `M${e(u)}` : u, h = n >= 2 ? `M${e(d)}` : d, g = "", _ = "";
1041
+ if (V.value.useArea && n >= 2) {
1042
+ let t = l([...c].reverse()), n = m([...c].reverse()), r = c[c.length - 1];
1043
+ 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`;
1044
+ }
1045
+ return {
1046
+ ...t,
1047
+ points: s,
1048
+ smoothPath: f,
1049
+ straightPath: h,
1050
+ smoothArea: g,
1051
+ straightArea: _,
1052
+ xMinimap: i,
1053
+ yMinimap: a,
1054
+ yMinimapBase: o
1055
+ };
1056
+ });
1057
+ }), Ji = y(() => $.value === null || $.value === void 0 ? null : {
1058
+ timeLabel: Ma($.value),
1059
+ absoluteIndex: $.value + Y.value.start,
1060
+ seriesIndex: $.value,
1061
+ datapoint: ja.value,
1062
+ series: X.value,
1063
+ config: L.value
1064
+ }), Yi = O(!1), Xi = O(!1);
1065
+ function Zi(e, t = Y.value.start) {
1066
+ let n = J.value, r = Number(t);
1067
+ return e > n ? n : e < 0 || e <= r ? Math.min(r + 1, n) : e;
1068
+ }
1069
+ function Qi(e = !0) {
1070
+ if (!Yi.value) {
1071
+ Yi.value = !0;
1072
+ try {
1073
+ let { startIndex: t, endIndex: n, keepState: r } = U.value.zoom, i = r ? Math.max(0, J.value) : J.value;
1074
+ if (r && i <= 0) return;
1075
+ let a = t ?? 0, o = n == null ? i : Math.min(Zi(n + 1, a), i);
1076
+ ra.value = !0, Y.value.start = a, Y.value.end = o, Fr.value.start = a, Fr.value.end = o, vi(), Xi.value = !0, e && N.zoomState && gi(N.zoomState);
1077
+ } finally {
1078
+ queueMicrotask(() => {
1079
+ ra.value = !1;
1080
+ }), Yi.value = !1;
1081
+ }
1082
+ }
1083
+ }
1084
+ function $i(e) {
1085
+ $r = {
1086
+ ...$r,
1087
+ ...e
1088
+ }, Qr && cancelAnimationFrame(Qr), Qr = requestAnimationFrame(() => {
1089
+ let e = {
1090
+ ...Y.value,
1091
+ ...$r
1092
+ };
1093
+ $r = {}, Qr = null, Y.value = e, Fr.value = { ...e }, vi(), ii({
1094
+ start: Number(Y.value.start),
1095
+ end: Number(Y.value.end)
1096
+ });
1097
+ });
1098
+ }
1099
+ function ea(e) {
1100
+ if (Yi.value || ra.value) return;
1101
+ let t = Number(e);
1102
+ Number.isFinite(t) && (P("zoomStart", {
1103
+ index: t,
1104
+ isZoom: t !== 0
1105
+ }), t !== Y.value.start && $i({ start: t }));
1106
+ }
1107
+ function ta(e) {
1108
+ if (Yi.value || ra.value) return;
1109
+ let t = $r.start === void 0 ? Y.value.start : $r.start, n = Zi(Number(e), t);
1110
+ Number.isFinite(n) && (P("zoomEnd", {
1111
+ index: n,
1112
+ isZoom: n !== J.value
1113
+ }), (n !== Y.value.end || $r.start !== void 0) && $i({ end: n }));
1114
+ }
1115
+ let Z = y(() => ({
1116
+ left: K.value.left,
1117
+ right: K.value.right,
1118
+ width: K.value.width
1119
+ })), na = y(() => {
1120
+ let e = B.value.y.axisLabels, { prefix: n, suffix: r } = V.value.dataLabels;
1121
+ return Ni.value.map((i) => String(ce(e.formatter, i.value, t({
1122
+ p: n,
1123
+ v: i.value,
1124
+ s: r,
1125
+ r: e.rounding
1126
+ }), { datapoint: i }) ?? "")).join("|");
1127
+ });
1128
+ st([
1129
+ na,
1130
+ () => B.value.y.axisLabels.show,
1131
+ () => B.value.y.axisLabels.fontSize,
1132
+ () => B.value.y.axisLabels.bold,
1133
+ () => B.value.y.position
1134
+ ], () => {
1135
+ B.value.y.axisLabels.show && Gn();
1136
+ }, { flush: "post" });
1137
+ let ra = O(!1);
1138
+ st([() => N.zoomState, Xi], ([e, t]) => {
1139
+ t && e && gi(e, { transition: !0 });
1140
+ }, {
1141
+ deep: !0,
1142
+ immediate: !0
1143
+ });
1144
+ let ia = y(() => gr.value.width), aa = y(() => gr.value.height);
1145
+ je({
1146
+ timeLabelsEls: Nn,
1147
+ timeLabels: Pi,
1148
+ slicer: Y,
1149
+ configRef: L,
1150
+ rotationPath: [
1151
+ "style",
1152
+ "chart",
1153
+ "grid",
1154
+ "x",
1155
+ "timeLabels",
1156
+ "rotation"
1157
+ ],
1158
+ autoRotatePath: [
1159
+ "style",
1160
+ "chart",
1161
+ "grid",
1162
+ "x",
1163
+ "timeLabels",
1164
+ "autoRotate",
1165
+ "enable"
1166
+ ],
1167
+ isAutoSize: !1,
1168
+ width: ia,
1169
+ height: aa,
1170
+ rotation: z.value.autoRotate.angle
1171
+ });
1172
+ let oa = O(null);
1173
+ function sa(e) {
1174
+ let t = W.value;
1175
+ if (!t) return null;
1176
+ if (t.createSVGPoint && t.getScreenCTM) {
1177
+ let n = t.createSVGPoint();
1178
+ n.x = e.clientX, n.y = e.clientY;
1179
+ let r = t.getScreenCTM();
1180
+ if (r) {
1181
+ let e = n.matrixTransform(r.inverse());
1182
+ return {
1183
+ x: e.x,
1184
+ y: e.y,
1185
+ ok: !0
1186
+ };
1187
+ }
1188
+ }
1189
+ let n = t.getBoundingClientRect(), r = t.viewBox?.baseVal || {
1190
+ x: 0,
1191
+ y: 0,
1192
+ width: n.width,
1193
+ height: n.height
1194
+ }, 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;
1195
+ return {
1196
+ x: (e.clientX - n.left - s) / i + r.x,
1197
+ y: (e.clientY - n.top - c) / i + r.y,
1198
+ ok: !0
1199
+ };
1200
+ }
1201
+ let ca = y(() => !Ir.value || Gr.value == null || Kr.value == null ? null : {
1202
+ x: Math.min(Gr.value, Kr.value),
1203
+ y: K.value.top,
1204
+ width: Math.abs(Kr.value - Gr.value),
1205
+ height: K.value.height
1206
+ }), la = y(() => Xi.value ? Number(Y.value.start) !== 0 || Number(Y.value.end) !== Number(J.value) : !1);
1207
+ function ua(e) {
1208
+ return Math.min(Math.max(e, K.value.left), K.value.right);
1209
+ }
1210
+ function da() {
1211
+ Ca &&= (cancelAnimationFrame(Ca), 0), oa.value = null, Kn.value = null, zn.value = null, $.value = null, Pa(!1, null);
1212
+ }
1213
+ function fa(e) {
1214
+ let t = e?.pointerId == null ? qr.value : e.pointerId;
1215
+ t != null && W.value?.hasPointerCapture?.(t) && W.value.releasePointerCapture(t), Ir.value = !1, Gr.value = null, Kr.value = null, qr.value = null;
1216
+ }
1217
+ function pa() {
1218
+ Jr.value = !0, setTimeout(() => {
1219
+ Jr.value = !1;
1220
+ }, 0);
1221
+ }
1222
+ function ma(e) {
1223
+ if (!Zr.value || !la.value || !e) return !1;
1224
+ let t = Date.now(), n = e.pointerType || "mouse", r = Yr.value, i = n === "touch" ? 450 : 350, a = n === "touch" ? 28 : 10, o = Math.hypot(e.clientX - r.x, e.clientY - r.y);
1225
+ return r.time > 0 && r.pointerType === n && t - r.time <= i && o <= a ? (Yr.value = {
1226
+ time: 0,
1227
+ x: 0,
1228
+ y: 0,
1229
+ pointerType: null
1230
+ }, pa(), fa(e), xi({
1231
+ force: !0,
1232
+ publish: !0
1233
+ }), !0) : (Yr.value = {
1234
+ time: t,
1235
+ x: e.clientX,
1236
+ y: e.clientY,
1237
+ pointerType: n
1238
+ }, !1);
1239
+ }
1240
+ function ha(e) {
1241
+ if (Q.value <= 0) return null;
1242
+ if (Q.value === 1 || wa.value <= 0) return 0;
1243
+ let t = (ua(e) - K.value.left) / wa.value;
1244
+ return Math.max(0, Math.min(Q.value - 1, Math.round(t)));
1245
+ }
1246
+ function ga(e, t) {
1247
+ let n = ha(e), r = ha(t);
1248
+ if (n == null || r == null) return null;
1249
+ let i = Math.min(n, r), a = Math.max(n, r);
1250
+ return a <= i ? null : {
1251
+ start: Number(Y.value.start) + i,
1252
+ end: Number(Y.value.start) + a + 1
1253
+ };
1254
+ }
1255
+ function _a(e) {
1256
+ let t = _i(e, { transition: !0 });
1257
+ return t ? (P("zoomStart", {
1258
+ index: t.start,
1259
+ isZoom: t.start !== 0
1260
+ }), P("zoomEnd", {
1261
+ index: t.end,
1262
+ isZoom: t.end !== J.value
1263
+ }), t) : null;
1264
+ }
1265
+ function va() {
1266
+ Lr.value = !0, W.value?.classList?.add("vue-ui-stackline-chart-zoom-pointer-focus");
1267
+ }
1268
+ function ya() {
1269
+ Lr.value = !1, W.value?.classList?.remove("vue-ui-stackline-chart-zoom-pointer-focus");
1270
+ }
1271
+ function ba(e) {
1272
+ if (!Zr.value || qn.value || e.button !== void 0 && e.button !== 0 || qr.value != null && e.pointerId !== qr.value) return;
1273
+ let t = sa(e);
1274
+ if (!t) return;
1275
+ let { left: n, right: r, top: i, bottom: a } = K.value;
1276
+ t.x < n || t.x > r || t.y < i || t.y > a || Q.value <= 1 || (va(), W.value?.focus?.({ preventScroll: !0 }), da(), qr.value = e.pointerId, Ir.value = !0, Gr.value = ua(t.x), Kr.value = ua(t.x));
1277
+ }
1278
+ function xa(e) {
1279
+ if (!Zr.value || !Ir.value || qr.value != null && e.pointerId !== qr.value) return;
1280
+ let t = sa(e);
1281
+ t && (Kr.value = ua(t.x), Gr.value != null && Math.abs(Kr.value - Gr.value) >= 2 && !W.value?.hasPointerCapture?.(e.pointerId) && W.value?.setPointerCapture?.(e.pointerId));
1282
+ }
1283
+ function Sa(e) {
1284
+ if (!Zr.value || !Ir.value || qr.value != null && e.pointerId !== qr.value) return;
1285
+ let t = sa(e);
1286
+ t && (Kr.value = ua(t.x));
1287
+ let n = Gr.value, r = Kr.value;
1288
+ if ((n == null || r == null ? 0 : Math.abs(r - n)) < Math.max(4, K.value.width * .01)) {
1289
+ if (ma(e)) return;
1290
+ fa(e);
1291
+ return;
1292
+ }
1293
+ let i = ga(Math.min(n, r), Math.max(n, r));
1294
+ if (!i) {
1295
+ fa(e);
1296
+ return;
1297
+ }
1298
+ fa(e), _a(i) && (Yr.value = {
1299
+ time: 0,
1300
+ x: 0,
1301
+ y: 0,
1302
+ pointerType: null
1303
+ }, da(), pa());
1304
+ }
1305
+ let Ca = 0, Q = y(() => Math.max(1, Y.value.end - Y.value.start)), wa = y(() => Q.value > 1 ? K.value.width / (Q.value - 1) : 0);
1306
+ function Ta(e) {
1307
+ return Q.value <= 1 ? K.value.left + K.value.width / 2 : K.value.left + e * wa.value;
1308
+ }
1309
+ function Ea(e) {
1310
+ if (Q.value <= 1) return {
1311
+ x: K.value.left,
1312
+ width: K.value.width
1313
+ };
1314
+ let t = e === 0 ? K.value.left : (Ta(e - 1) + Ta(e)) / 2, n = e === Q.value - 1 ? K.value.left + K.value.width : (Ta(e) + Ta(e + 1)) / 2;
1315
+ return {
1316
+ x: t,
1317
+ width: Math.max(0, n - t)
1318
+ };
1319
+ }
1320
+ function Da(e) {
1321
+ qn.value || Ir.value || (Ca && cancelAnimationFrame(Ca), Ca = requestAnimationFrame(() => {
1322
+ Ca = 0;
1323
+ let t = sa(e);
1324
+ if (!t || !W.value) {
1325
+ Aa();
1326
+ return;
1327
+ }
1328
+ let { left: n, right: r, top: i, bottom: a } = K.value;
1329
+ if (t.x < n || t.x > r || t.y < i || t.y > a) {
1330
+ Aa();
1331
+ return;
1332
+ }
1333
+ let o = 0;
1334
+ if (Q.value > 1) {
1335
+ let e = (t.x - n) / wa.value;
1336
+ o = Math.round(e);
1337
+ } else o = 0;
1338
+ o < 0 && (o = 0), o > Q.value - 1 && (o = Q.value - 1), oa.value !== o && (oa.value = o, Pa(!0, o));
1339
+ }));
1340
+ }
1341
+ function Oa(e) {
1342
+ if (Jr.value) {
1343
+ Jr.value = !1;
1344
+ return;
1345
+ }
1346
+ if (Ir.value) return;
1347
+ let t = sa(e);
1348
+ if (!t || !W.value) return;
1349
+ let { left: n, right: r, top: i, bottom: a } = K.value;
1350
+ if (t.x < n || t.x > r || t.y < i || t.y > a) return;
1351
+ let o = 0;
1352
+ if (Q.value > 1) {
1353
+ let e = (t.x - n) / wa.value;
1354
+ o = Math.round(e);
1355
+ } else o = 0;
1356
+ o < 0 && (o = 0), o > Q.value - 1 && (o = Q.value - 1), go({
1357
+ seriesIndex: o,
1358
+ datapoint: so(o)
1359
+ }), ka(o);
1360
+ }
1361
+ function ka(e) {
1362
+ let t = JSON.parse(JSON.stringify(X.value)).map((t) => ({
1363
+ name: t.name,
1364
+ value: t.series[e] === 0 ? 0 : t.series[e] || null,
1365
+ proportion: t.proportions[e] || null,
1366
+ color: t.color,
1367
+ id: t.id
1368
+ }));
1369
+ L.value.events.datapointClick && L.value.events.datapointClick({
1370
+ datapoint: t,
1371
+ seriesIndex: e + Y.value.start
1372
+ }), P("selectDatapoint", {
1373
+ datapoint: t,
1374
+ period: Pi.value[e]
1375
+ });
1376
+ }
1377
+ st(() => [
1378
+ Y.value.start,
1379
+ Y.value.end,
1380
+ X.value.length
1381
+ ], () => {
1382
+ let e = Q.value;
1383
+ if ($.value != null) {
1384
+ if (e <= 0) {
1385
+ $.value = null;
1386
+ return;
1387
+ }
1388
+ $.value < 0 && ($.value = 0), $.value > e - 1 && ($.value = e - 1);
1389
+ }
1390
+ });
1391
+ function Aa() {
1392
+ Ca &&= (cancelAnimationFrame(Ca), 0), oa.value = null, Pa(!1, null);
1393
+ }
1394
+ let $ = O(null), ja = y(() => {
1395
+ let e = $.value, t = e == null ? null : ei(e);
1396
+ return X.value.map((n) => ({
1397
+ slotAbsoluteIndex: n.absoluteIndex,
1398
+ shape: n.shape || "circle",
1399
+ name: n.name,
1400
+ color: n.color,
1401
+ value: e == null ? null : n.series.find((t, n) => n === e),
1402
+ sourceValue: t == null ? null : n.seriesSource?.[t],
1403
+ comments: n.comments || [],
1404
+ id: n.id,
1405
+ standalone: !!n.standalone
1406
+ }));
1407
+ });
1408
+ function Ma(e) {
1409
+ if (e == null || !H.value.showTimeLabel) return null;
1410
+ let t = Pi.value?.[e]?.text || null, n = Ki.value?.[e]?.text || null, r = Fi.value?.[e]?.text || null;
1411
+ return H.value.useDefaultTimeFormat ? t : n || r;
1412
+ }
1413
+ let Na = y(() => {
1414
+ let e = H.value.customFormat, n = [...ja.value].reverse(), i = n.filter((e) => !e.standalone), a = n.filter((e) => e.standalone), l = i.map((e) => e.value).filter((e) => o(e) && e !== null).reduce((e, t) => Math.abs(e) + Math.abs(t), 0);
1415
+ if (s(e) && ae(() => e({
1416
+ absoluteIndex: $.value + Y.value.start,
1417
+ seriesIndex: $.value,
1418
+ datapoint: ja.value,
1419
+ series: q.value,
1420
+ config: L.value
1421
+ }))) return e({
1422
+ absoluteIndex: $.value + Y.value.start,
1423
+ seriesIndex: $.value,
1424
+ datapoint: ja.value,
1425
+ series: q.value,
1426
+ config: L.value
1427
+ });
1428
+ let { showValue: u, showTotal: d, totalTranslation: f, showPercentage: p, borderColor: m, roundingValue: h, roundingPercentage: g } = H.value, _ = (e) => !e.shape || ![
1429
+ "star",
1430
+ "triangle",
1431
+ "square",
1432
+ "diamond",
1433
+ "pentagon",
1434
+ "hexagon"
1435
+ ].includes(e.shape) ? `<svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="${H.value.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="${H.value.backgroundColor}" stroke-width="1" fill="${e.color}" points="${r({
1436
+ plot: {
1437
+ x: 6,
1438
+ y: 6
1439
+ },
1440
+ radius: 5
1441
+ })}" /></svg>` : e.shape === "triangle" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${c({
1442
+ plot: {
1443
+ x: 6,
1444
+ y: 6
1445
+ },
1446
+ radius: 6,
1447
+ sides: 3,
1448
+ rotation: .52
1449
+ }).path}" fill="${e.color}" stroke="${H.value.backgroundColor}" stroke-width="1" /></svg>` : e.shape === "square" ? `<svg viewBox="0 0 12 12" height="14" width="14"><path d="${c({
1450
+ plot: {
1451
+ x: 6,
1452
+ y: 6
1453
+ },
1454
+ radius: 6,
1455
+ sides: 4,
1456
+ rotation: .8
1457
+ }).path}" fill="${e.color}" stroke="${H.value.backgroundColor}" stroke-width="1" /></svg>` : e.shape === "diamond" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${c({
1458
+ plot: {
1459
+ x: 6,
1460
+ y: 6
1461
+ },
1462
+ radius: 5,
1463
+ sides: 4,
1464
+ rotation: 0
1465
+ }).path}" fill="${e.color}" stroke="${H.value.backgroundColor}" stroke-width="1" /></svg>` : e.shape === "pentagon" ? `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${c({
1466
+ plot: {
1467
+ x: 6,
1468
+ y: 6
1469
+ },
1470
+ radius: 5,
1471
+ sides: 5,
1472
+ rotation: .95
1473
+ }).path}" fill="${e.color}" stroke="${H.value.backgroundColor}" stroke-width="1" /></svg>` : `<svg viewBox="0 0 12 12" height="14" width="14" style="overflow:visible"><path d="${c({
1474
+ plot: {
1475
+ x: 6,
1476
+ y: 6
1477
+ },
1478
+ radius: 5,
1479
+ sides: 6,
1480
+ rotation: 0
1481
+ }).path}" fill="${e.color}" stroke="${H.value.backgroundColor}" stroke-width="1" /></svg>`, ee = (e, n) => {
1482
+ let r = n ? t({
1483
+ v: isNaN((e.value ?? 0) / (l || 1)) ? 0 : Math.abs(e.value ?? 0) / (l || 1) * 100,
1484
+ s: "%",
1485
+ r: g
1486
+ }) : "", i = u && n ? "(" : "", a = u && n ? ")" : "";
1487
+ return `
1488
+ <div style="display:flex;flex-direction:row;align-items:center;gap:4px">
1489
+ <div style="width:20px;height:20px;display:flex;align-items:center;justify-content:center;">${_(e)}</div>
1490
+ ${e.name}${u || n ? ":" : ""}
1491
+ ${u ? ce(V.value.dataLabels.formatter, e.sourceValue, t({
1492
+ p: V.value.dataLabels.prefix,
1493
+ v: e.sourceValue,
1494
+ s: V.value.dataLabels.suffix,
1495
+ r: h
1496
+ }, { datapoint: e })) : ""} ${i}${r}${a}
1497
+ </div>
1498
+ `;
1499
+ }, te = "", ne = Ma($.value);
1500
+ return ne && (te += `<div style="width:100%;text-align:center;border-bottom:1px solid ${m};padding-bottom:6px;margin-bottom:3px;">${ne}</div>`), d && i.length > 1 && (te += `<div class="vue-data-ui-tooltip-total" style="display:flex;flex-direction:row;align-items:center;gap:4px">
1501
+ <span>${f}:</span>
1502
+ <span>${ce(V.value.dataLabels.formatter, pe(l), t({
1503
+ p: V.value.dataLabels.prefix,
1504
+ v: pe(l),
1505
+ s: V.value.dataLabels.suffix,
1506
+ r: h
1507
+ }), { datapoint: {
1508
+ name: f,
1509
+ value: pe(l)
1510
+ } })}</span>
1511
+ </div>`), i.forEach((e) => {
1512
+ te += ee(e, p);
1513
+ }), a.length && (te += `<div style="border-top:1px solid ${Mr.value.length ? m : "transparent"}; margin:${Mr.value.length ? "6px 0" : "0"};"></div>`, a.forEach((e) => {
1514
+ te += ee(e, !1);
1515
+ })), `<div>${te}</div>`;
1516
+ });
1517
+ function Pa(e, t = null, n = "pointer") {
1518
+ if (wi.value) return;
1519
+ Vn.value = n, mn.value = e;
1520
+ let r = X.value.map((e) => ({
1521
+ name: e.name,
1522
+ value: [
1523
+ null,
1524
+ void 0,
1525
+ NaN
1526
+ ].includes(e.series[t]) ? null : e.series[t],
1527
+ color: e.color
1528
+ }));
1529
+ e ? (zn.value = t, $.value = t, go({
1530
+ seriesIndex: t,
1531
+ datapoint: r
1532
+ }), L.value.events.datapointEnter && L.value.events.datapointEnter({
1533
+ datapoint: r,
1534
+ seriesIndex: t + Y.value.start
1535
+ })) : (zn.value = null, $.value = null, P("selectX", {
1536
+ index: null,
1537
+ indexLabel: null,
1538
+ dataset: null
1539
+ }), L.value.events.datapointLeave && L.value.events.datapointLeave({
1540
+ datapoint: r,
1541
+ seriesIndex: t + Y.value.start
1542
+ }));
1543
+ }
1544
+ function Fa(e, t) {
1545
+ let n = JSON.parse(JSON.stringify(X.value)).map((e) => ({
1546
+ name: e.name,
1547
+ value: e.series[t] === 0 ? 0 : (e.signedSeries[t] === -1 && e.series[t] >= 0 ? -e.series[t] : e.series[t]) || null,
1548
+ proportion: e.proportions[t] || null,
1549
+ color: e.color,
1550
+ id: e.id
1551
+ }));
1552
+ P("selectTimeLabel", {
1553
+ datapoint: n,
1554
+ absoluteIndex: e.absoluteIndex,
1555
+ label: e.text
1556
+ });
1557
+ }
1558
+ function Ia() {
1559
+ I.value.length ? I.value = [] : Ra.value.forEach((e) => {
1560
+ I.value.push(e.id);
1561
+ }), P("selectLegend", X.value);
1562
+ }
1563
+ function La(e) {
1564
+ if (I.value.includes(e.id)) I.value = I.value.filter((t) => t !== e.id);
1565
+ else {
1566
+ if (I.value.length === q.value.length - 1) return;
1567
+ I.value.push(e.id);
1568
+ }
1569
+ P("selectLegend", X.value);
1570
+ }
1571
+ let Ra = y(() => q.value.map((e) => ({
1572
+ ...e,
1573
+ opacity: I.value.includes(e.id) ? .5 : 1,
1574
+ segregate: () => La(e),
1575
+ isSegregated: I.value.includes(e.id)
1576
+ }))), za = y(() => ({
1577
+ cy: "stackline-legend",
1578
+ backgroundColor: U.value.legend.backgroundColor,
1579
+ color: U.value.legend.color,
1580
+ fontSize: U.value.legend.fontSize,
1581
+ paddingBottom: 12,
1582
+ fontWeight: U.value.legend.bold ? "bold" : ""
1583
+ }));
1584
+ function Ba(e) {
1585
+ return q.value.length ? q.value.find((t) => t.name === e) || (xr.value && console.warn(`VueUiStackline - Series name not found "${e}"`), null) : (xr.value && console.warn("VueUiStackline - There are no series to show."), null);
1586
+ }
1587
+ function Va(e) {
1588
+ let t = Ba(e);
1589
+ t !== null && I.value.includes(t.id) && La({ id: t.id });
1590
+ }
1591
+ function Ha(e) {
1592
+ let t = Ba(e);
1593
+ t !== null && (I.value.includes(t.id) || La({ id: t.id }));
1594
+ }
1595
+ let Ua = y(() => {
1596
+ if (X.value.length === 0) return {
1597
+ head: [],
1598
+ body: [],
1599
+ config: {},
1600
+ columnNames: []
1601
+ };
1602
+ let e = X.value.map(({ name: e, color: t }) => ({
1603
+ label: e,
1604
+ color: t
1605
+ })), t = [];
1606
+ return Bi.value.forEach((e) => {
1607
+ let n = e.absoluteIndex, r = [z.value.values?.[n] ? e.text : n + 1];
1608
+ q.value.forEach((e) => {
1609
+ let t = e.series?.[n], i = Number((t ?? 0).toFixed(L.value.table.td.roundingValue));
1610
+ r.push(i);
1611
+ }), t.push(r);
1612
+ }), {
1613
+ head: e,
1614
+ body: t
1615
+ };
1616
+ });
1617
+ function Wa(e = null) {
1618
+ let t = [
1619
+ [U.value.title.text],
1620
+ [U.value.title.subtitle.text],
1621
+ [""]
1622
+ ], n = ["", ...Ua.value.head.map((e) => e.label)], r = Ua.value.body, i = t.concat([n]).concat(r), o = a(i);
1623
+ e ? e(o) : le({
1624
+ csvContent: o,
1625
+ title: U.value.title.text || "vue-ui-stackline"
1626
+ });
1627
+ }
1628
+ let Ga = y(() => {
1629
+ let e = [""].concat(X.value.map((e) => e.name), "__SUM__"), t = [], n = Math.max(0, Y.value.end - Y.value.start);
1630
+ for (let e = 0; e < n; e += 1) {
1631
+ let n = ei(e), r = z.value.values?.[n] ? Pi.value?.[e]?.text ?? n + 1 : n + 1, i = X.value.map((t) => {
1632
+ let n = t.series?.[e] ?? 0;
1633
+ return Number(n.toFixed(L.value.table.td.roundingValue));
1634
+ }), a = X.value.filter((e) => !e.standalone).map((t) => t.series?.[e] ?? 0).reduce((e, t) => e + t, 0);
1635
+ t.push([r].concat(i, Number(a.toFixed(L.value.table.td.roundingValue))));
1636
+ }
1637
+ return {
1638
+ head: e,
1639
+ body: t,
1640
+ config: {
1641
+ th: {
1642
+ backgroundColor: L.value.table.th.backgroundColor,
1643
+ color: L.value.table.th.color,
1644
+ outline: L.value.table.th.outline
1645
+ },
1646
+ td: {
1647
+ backgroundColor: L.value.table.td.backgroundColor,
1648
+ color: L.value.table.td.color,
1649
+ outline: L.value.table.td.outline
1650
+ },
1651
+ breakpoint: L.value.table.responsiveBreakpoint
1652
+ },
1653
+ colNames: [L.value.table.columnNames.period].concat(X.value.map((e) => e.name), L.value.table.columnNames.total)
1654
+ };
1655
+ }), Ka = y(() => U.value.backgroundColor), qa = y(() => U.value.legend), Ja = y(() => U.value.title), { isCallbackImaging: Ya, isCallbackSvg: Xa, generateSvg: Za, onGenerateImage: Qa } = Oe({
1656
+ svg: W,
1657
+ title: Ja,
1658
+ legend: qa,
1659
+ legendItems: Ra,
1660
+ backgroundColor: Ka,
1661
+ getSvgCallback: () => L.value.userOptions.callbacks.svg,
1662
+ generateImage: mr
1663
+ });
1664
+ async function $a({ scale: e = 2 } = {}) {
1665
+ if (!pn.value) return;
1666
+ let { imageUri: t, base64: n } = await Me({
1667
+ domElement: pn.value,
1668
+ base64: !0,
1669
+ img: !0,
1670
+ scale: e
1671
+ }), r = pn.value.getBoundingClientRect(), i = {
1672
+ width: r.width,
1673
+ height: r.height,
1674
+ aspectRatio: r.height ? r.width / r.height : 0
1675
+ }, a = await oe(t, e) ?? i;
1676
+ return {
1677
+ imageUri: t,
1678
+ base64: n,
1679
+ title: U.value.title.text,
1680
+ ...a
1681
+ };
1682
+ }
1683
+ let eo = y(() => {
1684
+ let e = L.value.table.useDialog && !L.value.table.show, t = G.value.showTable;
1685
+ return {
1686
+ component: e ? sn : tn,
1687
+ title: `${U.value.title.text}${U.value.title.subtitle.text ? `: ${U.value.title.subtitle.text}` : ""}`,
1688
+ props: e ? {
1689
+ backgroundColor: L.value.table.th.backgroundColor,
1690
+ color: L.value.table.th.color,
1691
+ headerColor: L.value.table.th.color,
1692
+ headerBg: L.value.table.th.backgroundColor,
1693
+ isFullscreen: xn.value,
1694
+ fullscreenParent: pn.value,
1695
+ forcedWidth: Math.min(800, window.innerWidth * .8),
1696
+ isCursorPointer: Xn.value
1697
+ } : {
1698
+ hideDetails: !0,
1699
+ config: {
1700
+ open: t,
1701
+ maxHeight: 1e4,
1702
+ body: {
1703
+ backgroundColor: U.value.backgroundColor,
1704
+ color: U.value.color
1705
+ },
1706
+ head: {
1707
+ backgroundColor: U.value.backgroundColor,
1708
+ color: U.value.color
1709
+ }
1710
+ }
1711
+ }
1712
+ };
1713
+ });
1714
+ st(() => G.value.showTable, (e) => {
1715
+ L.value.table.show || (e && L.value.table.useDialog && Dn.value ? Dn.value.open() : "close" in Dn.value && Dn.value.close());
1716
+ });
1717
+ function to() {
1718
+ G.value.showTable = !1, On.value && On.value.setTableIconState(!1);
1719
+ }
1720
+ function no(e) {
1721
+ xn.value = e, hn.value += 1;
1722
+ }
1723
+ function ro() {
1724
+ G.value.showTable = !G.value.showTable;
1725
+ }
1726
+ function io() {
1727
+ G.value.dataLabels.show = !G.value.dataLabels.show;
1728
+ }
1729
+ function ao() {
1730
+ G.value.showTooltip = !G.value.showTooltip;
1731
+ }
1732
+ function oo() {
1733
+ return X.value;
1734
+ }
1735
+ function so(e) {
1736
+ let t = e ?? 0, n = ei(t);
1737
+ return JSON.parse(JSON.stringify(X.value)).map((e) => {
1738
+ let r = e.series[t], i = e.signedSeries?.[t], a = r === 0 ? 0 : (i === -1 && r >= 0 ? -r : r) || null;
1739
+ return {
1740
+ name: e.name,
1741
+ absoluteIndex: e.absoluteIndex,
1742
+ value: a,
1743
+ proportion: e.proportions?.[t] || null,
1744
+ color: e.color,
1745
+ id: e.id,
1746
+ timeLabel: Fi.value?.[n] || null
1747
+ };
1748
+ });
1749
+ }
1750
+ let co = y(() => Array(J.value).fill(0).map((e, t) => so(t)));
1751
+ st(() => N.selectedXIndex, (e) => {
1752
+ if ([null, void 0].includes(N.selectedXIndex)) {
1753
+ $.value = null;
1754
+ return;
1755
+ }
1756
+ let t = e - Y.value.start;
1757
+ t < 0 || e >= Y.value.end ? $.value = null : $.value = t ?? null;
1758
+ }, { immediate: !0 });
1759
+ let lo = y(() => {
1760
+ if (V.value.distributed) return {
1761
+ min: -1,
1762
+ max: 1
1763
+ };
1764
+ let e = Mr.value, t = Nr.value, n = Math.max(1, ...[...e, ...t].map((e) => e.series?.length || 0)), r = Array(n).fill(0), i = Array(n).fill(0);
1765
+ e.forEach((e) => {
1766
+ for (let t = 0; t < n; t += 1) {
1767
+ let n = e.series[t] ?? 0;
1768
+ n >= 0 ? r[t] += n : i[t] += n;
1769
+ }
1770
+ });
1771
+ let a = Array(n).fill(0), o = Array(n).fill(0);
1772
+ t.forEach((e) => {
1773
+ for (let t = 0; t < n; t += 1) {
1774
+ let n = e.series[t] ?? 0;
1775
+ n > 0 && (a[t] = Math.max(a[t], n)), n < 0 && (o[t] = Math.min(o[t], n));
1776
+ }
1777
+ });
1778
+ let s = Math.max(0, ...r, ...a), c = Math.min(0, ...i, ...o), l = B.value.scale.scaleMin, u = B.value.scale.scaleMax, d = B.value.scale.ticks, f = !V.value.distributed && (l !== null || u !== null) ? me(l === null ? c > 0 ? 0 : c : l, u === null ? s < 0 ? 0 : s : u, d) : ee(l === null ? c > 0 ? 0 : c : l, u === null ? s < 0 ? 0 : s : u, d);
1779
+ return {
1780
+ min: Number(f.min) || 0,
1781
+ max: Number(f.max) || 0
1782
+ };
1783
+ });
1784
+ function uo({ minimapH: e, unitW: t }) {
1785
+ let n = (e) => typeof e == "string" ? e.replace(/^M\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*,?\s*[-+]?[\d.]+(?:e[-+]?\d+)?\s*/i, "").trim() : "";
1786
+ if (!Number.isFinite(e) || e <= 0 || !Number.isFinite(t) || t <= 0) return "";
1787
+ let r = X.value.filter((e) => !e.standalone), i = X.value.filter((e) => e.standalone), a = Math.max(0, ...X.value.map((e) => Array.isArray(e.fullSeries) ? e.fullSeries.length : e.series.length));
1788
+ if (a <= 0) return "";
1789
+ let o = a === 1 ? [t * .5] : Array.from({ length: a }, (e, n) => n * t);
1790
+ if (V.value.distributed) {
1791
+ let t = Array.from({ length: a }, (e, t) => {
1792
+ let n = 0;
1793
+ return r.forEach((e) => {
1794
+ let r = (Array.isArray(e.fullSeries) ? e.fullSeries : e.series)?.[t];
1795
+ r != null && !Number.isNaN(r) && (n += Math.abs(r));
1796
+ }), n || 1;
1797
+ }), s = (t) => e - e * Math.max(0, Math.min(1, t || 0)), c = [], u = Array(a).fill(0);
1798
+ return r.forEach((e) => {
1799
+ let r = Array.isArray(e.fullSeries) ? e.fullSeries : e.series, i = Array(a), d = Array(a);
1800
+ for (let e = 0; e < a; e += 1) {
1801
+ let n = r?.[e], a = n == null || Number.isNaN(n) ? 0 : Math.abs(n) / t[e];
1802
+ d[e] = u[e], u[e] += a, i[e] = u[e];
1803
+ }
1804
+ let f = i.map(s), p = d.map(s), h = o.map((e, t) => ({
1805
+ x: e,
1806
+ y: f[t]
1807
+ })), g = o.map((e, t) => ({
1808
+ x: e,
1809
+ y: p[t]
1810
+ })), _ = l(h), ee = l([...g].reverse()), te = m(h), ne = m([...g].reverse()), re = g[g.length - 1];
1811
+ if (V.value.useArea) {
1812
+ let t = V.value.smooth ? `M${h[0].x},${h[0].y} ${n(_)} L${re.x},${re.y} ${n(ee)} Z` : `M${h[0].x},${h[0].y} ${n(te)} L${re.x},${re.y} ${n(ne)} Z`;
1813
+ c.push(`<path d="${t}"
1814
+ fill="${dn.pattern ? `url(#pattern_${F.value}_${e.absoluteIndex})` : (V.value.gradient.show, e.color)}"
1815
+ opacity="${V.value.areaOpacity}"
1816
+ stroke="none" />`);
1817
+ }
1818
+ let ie = V.value.smooth ? `M${h[0].x},${h[0].y} ${n(_)}` : `M${h[0].x},${h[0].y} ${n(te)}`;
1819
+ c.push(`<path d="${ie}"
1820
+ fill="none"
1821
+ stroke="${e.color}"
1822
+ stroke-width="${V.value.strokeWidth}"
1823
+ stroke-linecap="round" />`);
1824
+ }), i.length && i.forEach((e) => {
1825
+ 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) => ({
1826
+ x: e,
1827
+ y: i[t]
1828
+ })), d = l(u), f = m(u), p = V.value.smooth ? `M${u[0].x},${u[0].y} ${n(d)}` : `M${u[0].x},${u[0].y} ${n(f)}`;
1829
+ c.push(`<path d="${p}"
1830
+ fill="none"
1831
+ stroke="${e.color}"
1832
+ stroke-width="${V.value.strokeWidth}"
1833
+ stroke-linecap="round" />`);
1834
+ }), c.join("");
1835
+ }
1836
+ let s = lo.value.min, c = lo.value.max, u = Math.abs(s), d = c + u || 1, f = (t) => Math.max(0, Math.min(e, t)), p = (t) => f(e - e * (((t ?? 0) + u) / d)), h = [];
1837
+ if (r.length) {
1838
+ let e = Array(a).fill(0), t = Array(a).fill(0);
1839
+ r.forEach((r) => {
1840
+ let i = Array.isArray(r.fullSeries) ? r.fullSeries : r.series, s = Array(a), c = Array(a);
1841
+ for (let n = 0; n < a; n += 1) {
1842
+ let r = i?.[n] ?? 0;
1843
+ r >= 0 ? (c[n] = e[n], e[n] += r, s[n] = e[n]) : (c[n] = t[n], t[n] += r, s[n] = t[n]);
1844
+ }
1845
+ let u = s.map(p), d = c.map(p), f = o.map((e, t) => ({
1846
+ x: e,
1847
+ y: u[t]
1848
+ })), g = o.map((e, t) => ({
1849
+ x: e,
1850
+ y: d[t]
1851
+ })), _ = l(f), ee = l([...g].reverse()), te = m(f), ne = m([...g].reverse()), re = g[g.length - 1];
1852
+ if (V.value.useArea) {
1853
+ let e = V.value.smooth ? `M${f[0].x},${f[0].y} ${n(_)} L${re.x},${re.y} ${n(ee)} Z` : `M${f[0].x},${f[0].y} ${n(te)} L${re.x},${re.y} ${n(ne)} Z`;
1854
+ h.push(`<path d="${e}"
1855
+ fill="${dn.pattern ? `url(#pattern_${F.value}_${r.absoluteIndex})` : (V.value.gradient.show, r.color)}"
1856
+ opacity="${V.value.areaOpacity}"
1857
+ stroke="none" />`);
1858
+ }
1859
+ let ie = V.value.smooth ? `M${f[0].x},${f[0].y} ${n(_)}` : `M${f[0].x},${f[0].y} ${n(te)}`;
1860
+ h.push(`<path d="${ie}"
1861
+ fill="none"
1862
+ stroke="${r.color}"
1863
+ stroke-width="${V.value.strokeWidth}"
1864
+ stroke-linecap="round" />`);
1865
+ });
1866
+ }
1867
+ return i.length && i.forEach((e) => {
1868
+ let t = (Array.isArray(e.fullSeries) ? e.fullSeries : e.series).map(p), r = o.map((e, n) => ({
1869
+ x: e,
1870
+ y: t[n]
1871
+ })), i = l(r), a = m(r), s = V.value.smooth ? `M${r[0].x},${r[0].y} ${n(i)}` : `M${r[0].x},${r[0].y} ${n(a)}`;
1872
+ h.push(`<path d="${s}"
1873
+ fill="none"
1874
+ stroke="${e.color}"
1875
+ stroke-width="${V.value.strokeWidth}"
1876
+ stroke-linecap="round" />`);
1877
+ }), h.join("");
1878
+ }
1879
+ function fo(e, t) {
1880
+ let n = V.value, r = n.dataLabels;
1881
+ return n.showDistributedPercentage && n.distributed ? cr.value ? t === 0 ? !r.hideEmptyPercentages : Math.abs(t) * 100 >= r.hideUnderPercentage : !r.hideEmptyPercentages || Math.abs(t) > 0 : cr.value ? (sr.value && xr.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) > po.value * r.hideUnderPercentage / 100) : sr.value ? Math.abs(e) >= r.hideUnderValue : !r.hideEmptyValues || e !== 0;
1882
+ }
1883
+ let po = y(() => Math.max(...X.value.flatMap((e) => e.series)));
1884
+ function mo(e, n, r, i, a) {
1885
+ let o = a === -1 && e >= 0 ? -e : e;
1886
+ return ce(V.value.dataLabels.formatter, o, t({
1887
+ p: V.value.dataLabels.prefix,
1888
+ v: o,
1889
+ s: V.value.dataLabels.suffix,
1890
+ r: V.value.dataLabels.rounding
1891
+ }), {
1892
+ datapoint: n,
1893
+ seriesIndex: r,
1894
+ datapointIndex: i
1895
+ });
1896
+ }
1897
+ function ho(e, n, r, i) {
1898
+ return ce(V.value.dataLabels.formatter, e, t({
1899
+ v: isNaN(e) ? 0 : e,
1900
+ s: "%",
1901
+ r: V.value.dataLabels.rounding
1902
+ }), {
1903
+ datapoint: n,
1904
+ seriesIndex: r,
1905
+ datapointIndex: i
1906
+ });
1907
+ }
1908
+ function go({ seriesIndex: e, datapoint: t }) {
1909
+ let n = Y.value.start + e;
1910
+ P("selectX", {
1911
+ dataset: t,
1912
+ index: n,
1913
+ indexLabel: z.value.values[n]
1914
+ });
1915
+ }
1916
+ async function _o() {
1917
+ if (P("copyAlt", {
1918
+ config: L.value,
1919
+ dataset: X.value
1920
+ }), !L.value.userOptions.callbacks.altCopy) {
1921
+ console.warn("Vue Data UI - A callback must be set for `altCopy` in userOptions.");
1922
+ return;
1923
+ }
1924
+ await Promise.resolve(L.value.userOptions.callbacks.altCopy({
1925
+ config: L.value,
1926
+ dataset: X.value
1927
+ }));
1928
+ }
1929
+ let vo = O(!1);
1930
+ function yo() {
1931
+ zn.value = null, vo.value = !0;
1932
+ }
1933
+ function bo() {
1934
+ ya(), zn.value = null, Vn.value = "pointer", mn.value = !1, $.value = null, P("selectX", {
1935
+ index: null,
1936
+ indexLabel: null,
1937
+ dataset: null
1938
+ }), vo.value = !1;
1939
+ }
1940
+ function xo(e) {
1941
+ if (!W.value || qn.value || document.activeElement !== W.value || (ya(), wi.value) || !Q.value) return;
1942
+ let t = e.key === "ArrowLeft", n = e.key === "ArrowRight", r = e.key === "Enter" || e.key === " ", i = e.key === "Escape";
1943
+ if (!t && !n && !r && !i) return;
1944
+ if (e.preventDefault(), e.stopPropagation(), i) {
1945
+ if (Zr.value && (la.value || Ir.value)) {
1946
+ fa(), xi({
1947
+ force: !0,
1948
+ publish: !0
1949
+ });
1950
+ return;
1951
+ }
1952
+ zn.value = null, Vn.value = "pointer", mn.value = !1, $.value = null, P("selectX", {
1953
+ index: null,
1954
+ indexLabel: null,
1955
+ dataset: null
1956
+ });
1957
+ return;
1958
+ }
1959
+ if (r) {
1960
+ if (zn.value === null) return;
1961
+ ka(zn.value);
1962
+ return;
1963
+ }
1964
+ let a = zn.value, o = oa.value, s = a !== null && a >= 0 && a < Q.value, c = o !== null && o >= 0 && o < Q.value;
1965
+ s ? n ? (a += 1, a >= Q.value && (a = 0)) : t && (--a, a < 0 && (a = Q.value - 1)) : c ? (a = n ? o + 1 : o - 1, a >= Q.value && (a = 0), a < 0 && (a = Q.value - 1)) : a = n ? 0 : Q.value - 1, zn.value = a, So(a), Pa(!0, a, "keyboard");
1966
+ }
1967
+ function So(e) {
1968
+ if (!Number.isFinite(e) || !W.value) return;
1969
+ let t = K.value.left + e * wa.value, n = K.value.top + K.value.height / 2, r = d(t, n, W.value);
1970
+ r && (Bn.value = r);
1971
+ }
1972
+ let Co = y(() => ({
1973
+ headers: Ga.value?.colNames ?? [],
1974
+ rows: Ga.value?.body ?? []
1975
+ }));
1976
+ return Fe({
1977
+ getData: oo,
1978
+ getImage: $a,
1979
+ generatePdf: pr,
1980
+ generateCsv: Wa,
1981
+ generateImage: mr,
1982
+ generateSvg: Za,
1983
+ hideSeries: Ha,
1984
+ showSeries: Va,
1985
+ toggleTable: ro,
1986
+ toggleLabels: io,
1987
+ toggleTooltip: ao,
1988
+ toggleAnnotator: Jn,
1989
+ toggleFullscreen: no,
1990
+ copyAlt: _o,
1991
+ resetZoom: () => xi({
1992
+ force: !0,
1993
+ publish: !0
1994
+ }),
1995
+ setZoomState: _i
1996
+ }), (n, r) => (D(), S("div", {
1997
+ id: `stackline_${F.value}`,
1998
+ ref_key: "stacklineChart",
1999
+ ref: pn,
2000
+ class: T({
2001
+ "vue-data-ui-component": !0,
2002
+ "vue-ui-stackline": !0,
2003
+ "vue-data-ui-wrapper-fullscreen": xn.value
2004
+ }),
2005
+ style: $e(`background:${U.value.backgroundColor};color:${U.value.color};font-family:${L.value.style.fontFamily}; position: relative; ${L.value.responsive ? "height: 100%" : ""}`),
2006
+ onMouseenter: ir,
2007
+ onMouseleave: ar
2008
+ }, [
2009
+ C("div", {
2010
+ id: `chart-instructions-${F.value}`,
2011
+ class: "sr-only"
2012
+ }, [C("p", null, it(L.value.a11y.translations.keyboardNavigation), 1)], 8, dt),
2013
+ Co.value?.rows?.length ? (D(), b(Ve, {
2014
+ key: 0,
2015
+ uid: F.value,
2016
+ head: Co.value.headers,
2017
+ body: Co.value.rows,
2018
+ notice: L.value.a11y.translations.tableAvailable,
2019
+ caption: L.value.a11y.translations.tableCaption
2020
+ }, null, 8, [
2021
+ "uid",
2022
+ "head",
2023
+ "body",
2024
+ "notice",
2025
+ "caption"
2026
+ ])) : x("", !0),
2027
+ R.value.buttons.annotator ? (D(), b(j(rn), {
2028
+ key: 1,
2029
+ svgRef: j(W),
2030
+ backgroundColor: U.value.backgroundColor,
2031
+ color: U.value.color,
2032
+ active: qn.value,
2033
+ isCursorPointer: Xn.value,
2034
+ palette: R.value.annotatorPalette,
2035
+ onClose: Jn
2036
+ }, {
2037
+ "annotator-action-close": M(() => [A(n.$slots, "annotator-action-close", {}, void 0, !0)]),
2038
+ "annotator-action-color": M(({ color: e }) => [A(n.$slots, "annotator-action-color", E(w({ color: e })), void 0, !0)]),
2039
+ "annotator-action-draw": M(({ mode: e }) => [A(n.$slots, "annotator-action-draw", E(w({ mode: e })), void 0, !0)]),
2040
+ "annotator-action-undo": M(({ disabled: e }) => [A(n.$slots, "annotator-action-undo", E(w({ disabled: e })), void 0, !0)]),
2041
+ "annotator-action-redo": M(({ disabled: e }) => [A(n.$slots, "annotator-action-redo", E(w({ disabled: e })), void 0, !0)]),
2042
+ "annotator-action-delete": M(({ disabled: e }) => [A(n.$slots, "annotator-action-delete", E(w({ disabled: e })), void 0, !0)]),
2043
+ _: 3
2044
+ }, 8, [
2045
+ "svgRef",
2046
+ "backgroundColor",
2047
+ "color",
2048
+ "active",
2049
+ "isCursorPointer",
2050
+ "palette"
2051
+ ])) : x("", !0),
2052
+ A(n.$slots, "userConfig", {}, void 0, !0),
2053
+ hr.value ? (D(), S("div", {
2054
+ key: 2,
2055
+ ref_key: "noTitle",
2056
+ ref: yn,
2057
+ class: "vue-data-ui-no-title-space",
2058
+ style: "height:36px; width: 100%;background:transparent"
2059
+ }, null, 512)) : x("", !0),
2060
+ U.value.title.text ? (D(), S("div", {
2061
+ key: 3,
2062
+ ref_key: "chartTitle",
2063
+ ref: gn,
2064
+ style: "width:100%;background:transparent;"
2065
+ }, [(D(), b(Ne, {
2066
+ key: `title_${Cn.value}`,
2067
+ config: {
2068
+ title: {
2069
+ cy: "stackline-title",
2070
+ ...U.value.title
2071
+ },
2072
+ subtitle: {
2073
+ cy: "stackline-subtitle",
2074
+ ...U.value.title.subtitle
2075
+ }
2076
+ }
2077
+ }, null, 8, ["config"]))], 512)) : x("", !0),
2078
+ C("div", { id: `legend-top-${F.value}` }, null, 8, ft),
2079
+ R.value.show && fn.value && (j(rr) || j(tr)) ? (D(), b(j(an), {
2080
+ ref_key: "userOptionsRef",
2081
+ ref: On,
2082
+ key: `user_option_${hn.value}`,
2083
+ backgroundColor: U.value.backgroundColor,
2084
+ color: U.value.color,
2085
+ isPrinting: j(dr),
2086
+ isImaging: j(fr),
2087
+ uid: F.value,
2088
+ hasTooltip: H.value.show && R.value.buttons.tooltip,
2089
+ hasPdf: R.value.buttons.pdf,
2090
+ hasImg: R.value.buttons.img,
2091
+ hasSvg: R.value.buttons.svg,
2092
+ hasXls: R.value.buttons.csv,
2093
+ hasTable: R.value.buttons.table,
2094
+ hasLabel: R.value.buttons.labels,
2095
+ hasFullscreen: R.value.buttons.fullscreen,
2096
+ hasAltCopy: R.value.buttons.altCopy,
2097
+ isFullscreen: xn.value,
2098
+ chartElement: pn.value,
2099
+ position: R.value.position,
2100
+ isTooltip: G.value.showTooltip,
2101
+ titles: { ...R.value.buttonTitles },
2102
+ hasAnnotator: R.value.buttons.annotator,
2103
+ isAnnotation: qn.value,
2104
+ callbacks: R.value.callbacks,
2105
+ printScale: R.value.print.scale,
2106
+ tableDialog: L.value.table.useDialog,
2107
+ isCursorPointer: Xn.value,
2108
+ onToggleFullscreen: no,
2109
+ onGeneratePdf: j(pr),
2110
+ onGenerateCsv: Wa,
2111
+ onGenerateImage: j(Qa),
2112
+ onGenerateSvg: j(Za),
2113
+ onToggleTable: ro,
2114
+ onToggleLabels: io,
2115
+ onToggleTooltip: ao,
2116
+ onToggleAnnotator: Jn,
2117
+ onCopyAlt: _o,
2118
+ style: $e({ visibility: j(rr) ? j(tr) ? "visible" : "hidden" : "visible" })
2119
+ }, qe({ _: 2 }, [
2120
+ n.$slots.menuIcon ? {
2121
+ name: "menuIcon",
2122
+ fn: M(({ isOpen: e, color: t }) => [A(n.$slots, "menuIcon", E(w({
2123
+ isOpen: e,
2124
+ color: t
2125
+ })), void 0, !0)]),
2126
+ key: "0"
2127
+ } : void 0,
2128
+ n.$slots.optionTooltip ? {
2129
+ name: "optionTooltip",
2130
+ fn: M(() => [A(n.$slots, "optionTooltip", {}, void 0, !0)]),
2131
+ key: "1"
2132
+ } : void 0,
2133
+ n.$slots.optionPdf ? {
2134
+ name: "optionPdf",
2135
+ fn: M(() => [A(n.$slots, "optionPdf", {}, void 0, !0)]),
2136
+ key: "2"
2137
+ } : void 0,
2138
+ n.$slots.optionCsv ? {
2139
+ name: "optionCsv",
2140
+ fn: M(() => [A(n.$slots, "optionCsv", {}, void 0, !0)]),
2141
+ key: "3"
2142
+ } : void 0,
2143
+ n.$slots.optionImg ? {
2144
+ name: "optionImg",
2145
+ fn: M(() => [A(n.$slots, "optionImg", {}, void 0, !0)]),
2146
+ key: "4"
2147
+ } : void 0,
2148
+ n.$slots.optionSvg ? {
2149
+ name: "optionSvg",
2150
+ fn: M(() => [A(n.$slots, "optionSvg", {}, void 0, !0)]),
2151
+ key: "5"
2152
+ } : void 0,
2153
+ n.$slots.optionTable ? {
2154
+ name: "optionTable",
2155
+ fn: M(() => [A(n.$slots, "optionTable", {}, void 0, !0)]),
2156
+ key: "6"
2157
+ } : void 0,
2158
+ n.$slots.optionLabels ? {
2159
+ name: "optionLabels",
2160
+ fn: M(() => [A(n.$slots, "optionLabels", {}, void 0, !0)]),
2161
+ key: "7"
2162
+ } : void 0,
2163
+ n.$slots.optionFullscreen ? {
2164
+ name: "optionFullscreen",
2165
+ fn: M(({ toggleFullscreen: e, isFullscreen: t }) => [A(n.$slots, "optionFullscreen", E(w({
2166
+ toggleFullscreen: e,
2167
+ isFullscreen: t
2168
+ })), void 0, !0)]),
2169
+ key: "8"
2170
+ } : void 0,
2171
+ n.$slots.optionAnnotator ? {
2172
+ name: "optionAnnotator",
2173
+ fn: M(({ toggleAnnotator: e, isAnnotator: t }) => [A(n.$slots, "optionAnnotator", E(w({
2174
+ toggleAnnotator: e,
2175
+ isAnnotator: t
2176
+ })), void 0, !0)]),
2177
+ key: "9"
2178
+ } : void 0,
2179
+ n.$slots.optionAltCopy ? {
2180
+ name: "optionAltCopy",
2181
+ fn: M(({ altCopy: e }) => [A(n.$slots, "optionAltCopy", E(w({ altCopy: e })), void 0, !0)]),
2182
+ key: "10"
2183
+ } : void 0,
2184
+ n.$slots["custom-menu-before"] ? {
2185
+ name: "custom-menu-before",
2186
+ fn: M(() => [A(n.$slots, "custom-menu-before", {}, void 0, !0)]),
2187
+ key: "11"
2188
+ } : void 0,
2189
+ n.$slots["custom-menu-after"] ? {
2190
+ name: "custom-menu-after",
2191
+ fn: M(() => [A(n.$slots, "custom-menu-after", {}, void 0, !0)]),
2192
+ key: "12"
2193
+ } : void 0
2194
+ ]), 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.onGenerateImage.onGenerateSvg.style".split("."))) : x("", !0),
2195
+ C("div", pt, [(D(), S("svg", {
2196
+ ref_key: "svgRef",
2197
+ ref: W,
2198
+ "aria-describedby": `chart-instructions-${F.value}`,
2199
+ xmlns: j(de),
2200
+ viewBox: `0 0 ${K.value.chartWidth <= 0 ? 10 : K.value.chartWidth} ${K.value.chartHeight <= 0 ? 10 : K.value.chartHeight}`,
2201
+ class: T({
2202
+ "vue-data-ui-loading": j(Qn),
2203
+ "vue-data-ui-fullscreen--on": xn.value,
2204
+ "vue-data-ui-fulscreen--off": !xn.value,
2205
+ "vue-data-ui-no-transition": !j(Yn),
2206
+ "vue-ui-stackline-chart-zoom-pointer-focus": Zr.value && Lr.value
2207
+ }),
2208
+ style: $e({
2209
+ maxWidth: "100%",
2210
+ overflow: "visible",
2211
+ background: "transparent",
2212
+ color: U.value.color,
2213
+ cursor: Zr.value ? Ir.value ? "col-resize" : "crosshair" : void 0,
2214
+ touchAction: Zr.value ? "pan-y" : void 0,
2215
+ userSelect: Zr.value ? "none" : void 0
2216
+ }),
2217
+ role: "img",
2218
+ "aria-live": "polite",
2219
+ tabindex: "0",
2220
+ preserveAspectRatio: "xMidYMid",
2221
+ onMousemove: Da,
2222
+ onMouseleave: Aa,
2223
+ onClick: Oa,
2224
+ onPointerdown: ba,
2225
+ onPointermove: xa,
2226
+ onPointerup: Sa,
2227
+ onPointercancel: fa,
2228
+ onFocus: yo,
2229
+ onBlur: bo,
2230
+ onKeydown: xo
2231
+ }, [
2232
+ Ye(j(on)),
2233
+ C("defs", null, [C("clipPath", { id: `vue_ui_stackline_zoom_clip_${F.value}` }, [C("rect", {
2234
+ x: K.value.left,
2235
+ y: K.value.top,
2236
+ width: Math.max(0, K.value.width),
2237
+ height: Math.max(0, K.value.height)
2238
+ }, null, 8, gt)], 8, ht)]),
2239
+ (D(!0), S(v, null, k(Mr.value, (e) => (D(), S(v, null, [n.$slots.pattern ? (D(), S("defs", _t, [A(n.$slots, "pattern", Ze({ ref_for: !0 }, {
2240
+ seriesIndex: e.absoluteIndex,
2241
+ patternId: `pattern_${F.value}_${e.absoluteIndex}`
2242
+ }), void 0, !0)])) : x("", !0)], 64))), 256)),
2243
+ n.$slots["chart-background"] ? (D(), S("foreignObject", {
2244
+ key: 0,
2245
+ x: Z.value.left,
2246
+ y: K.value.top,
2247
+ width: Z.value.width,
2248
+ height: K.value.height,
2249
+ style: { pointerEvents: "none" }
2250
+ }, [A(n.$slots, "chart-background", {}, void 0, !0)], 8, vt)) : x("", !0),
2251
+ V.value.gradient.show ? (D(), S("defs", yt, [(D(!0), S(v, null, k(X.value, (e, t) => (D(), b(Re, {
2252
+ t: "linear",
2253
+ id: `gradient_${e.id}`,
2254
+ key: `gradient_${e.id}_${t}`,
2255
+ x1: "0%",
2256
+ y1: "0%",
2257
+ x2: "0%",
2258
+ y2: "100%",
2259
+ stops: [[
2260
+ "0%",
2261
+ e.color,
2262
+ 1
2263
+ ], [
2264
+ "100%",
2265
+ j(u)(e.color, V.value.gradient.intensity / 100),
2266
+ 1
2267
+ ]]
2268
+ }, null, 8, ["id", "stops"]))), 128))])) : x("", !0),
2269
+ B.value.x.showHorizontalLines ? (D(!0), S(v, { key: 2 }, k(Ni.value, (e, t) => (D(), S("line", {
2270
+ x1: Z.value.left,
2271
+ x2: Z.value.right,
2272
+ y1: e.y,
2273
+ y2: e.y,
2274
+ stroke: B.value.x.linesColor,
2275
+ "stroke-width": B.value.x.linesThickness,
2276
+ "stroke-dasharray": B.value.x.linesStrokeDasharray,
2277
+ "stroke-linecap": "round"
2278
+ }, null, 8, bt))), 256)) : x("", !0),
2279
+ B.value.y.showVerticalLines ? (D(!0), S(v, { key: 3 }, k(Y.value.end - Y.value.start, (e, t) => (D(), S("line", {
2280
+ x1: Ta(t),
2281
+ x2: Ta(t),
2282
+ y1: K.value.top,
2283
+ y2: K.value.bottom,
2284
+ stroke: B.value.y.linesColor,
2285
+ "stroke-width": B.value.y.linesThickness,
2286
+ "stroke-dasharray": B.value.y.linesStrokeDasharray,
2287
+ "stroke-linecap": "round"
2288
+ }, null, 8, xt))), 256)) : x("", !0),
2289
+ B.value.x.showAxis ? (D(), S("line", {
2290
+ key: 4,
2291
+ x1: Z.value.left,
2292
+ x2: Z.value.right,
2293
+ y1: K.value.bottom,
2294
+ y2: K.value.bottom,
2295
+ stroke: B.value.x.axisColor,
2296
+ "stroke-width": B.value.x.axisThickness,
2297
+ "stroke-linecap": "round",
2298
+ "stroke-linejoin": "round"
2299
+ }, null, 8, St)) : x("", !0),
2300
+ B.value.y.showAxis && !V.value.distributed ? (D(), S("line", {
2301
+ key: 5,
2302
+ x1: Cr.value ? Z.value.right : Z.value.left,
2303
+ x2: Cr.value ? Z.value.right : Z.value.left,
2304
+ y1: K.value.top,
2305
+ y2: K.value.bottom,
2306
+ stroke: B.value.y.axisColor,
2307
+ "stroke-width": B.value.y.axisThickness,
2308
+ "stroke-linecap": "round",
2309
+ "stroke-linejoin": "round"
2310
+ }, null, 8, Ct)) : x("", !0),
2311
+ B.value.x.axisName.show && B.value.x.axisName.text ? (D(), S("text", {
2312
+ key: 6,
2313
+ ref_key: "xAxisLabel",
2314
+ ref: An,
2315
+ x: K.value.left + K.value.width / 2,
2316
+ y: K.value.chartHeight - 3,
2317
+ "font-size": B.value.x.axisName.fontSize,
2318
+ fill: B.value.x.axisName.color,
2319
+ "font-weight": B.value.x.axisName.bold ? "bold" : "normal",
2320
+ "text-anchor": "middle"
2321
+ }, it(B.value.x.axisName.text), 9, wt)) : x("", !0),
2322
+ B.value.y.axisName.show && B.value.y.axisName.text ? (D(), S("text", {
2323
+ key: 7,
2324
+ ref_key: "yAxisLabel",
2325
+ ref: jn,
2326
+ transform: `translate(${Cr.value ? K.value.chartWidth - B.value.y.axisName.fontSize / 2 - B.value.y.axisName.offsetX : B.value.y.axisName.fontSize + B.value.y.axisName.offsetX}, ${K.value.top + K.value.height / 2}) rotate(-90)`,
2327
+ "font-size": B.value.y.axisName.fontSize,
2328
+ fill: B.value.y.axisName.color,
2329
+ "font-weight": B.value.y.axisName.bold ? "bold" : "normal",
2330
+ "text-anchor": "middle"
2331
+ }, it(B.value.y.axisName.text), 9, Tt)) : x("", !0),
2332
+ B.value.frame.show ? (D(), S("rect", {
2333
+ key: 8,
2334
+ style: {
2335
+ pointerEvents: "none",
2336
+ transition: "none",
2337
+ animation: "none !important"
2338
+ },
2339
+ x: Z.value.left,
2340
+ y: K.value.top,
2341
+ width: Z.value.width,
2342
+ height: K.value.height,
2343
+ fill: "transparent",
2344
+ stroke: B.value.frame.stroke,
2345
+ "stroke-width": B.value.frame.strokeWidth,
2346
+ "stroke-linecap": B.value.frame.strokeLinecap,
2347
+ "stroke-linejoin": B.value.frame.strokeLinejoin,
2348
+ "stroke-dasharray": B.value.frame.strokeDasharray
2349
+ }, null, 8, Et)) : x("", !0),
2350
+ C("g", { "clip-path": hi.value }, [C("g", {
2351
+ class: T(["vue-ui-stackline-zoom-geometry", { "vue-ui-stackline-zoom-geometry--transitioning": Rr.value }]),
2352
+ style: $e(mi.value)
2353
+ }, [(D(!0), S(v, null, k(X.value, (e) => (D(), S(v, null, [V.value.useArea && !e.standalone ? (D(), S("path", {
2354
+ key: 0,
2355
+ d: V.value.smooth ? e.smoothArea : e.straightArea,
2356
+ fill: n.$slots.pattern ? `url(#pattern_${F.value}_${e.absoluteIndex})` : V.value.gradient.show ? `url(#gradient_${e.id})` : e.color,
2357
+ opacity: V.value.areaOpacity,
2358
+ class: T({ "vue-data-ui-transition": j(Yn) })
2359
+ }, null, 10, Ot)) : x("", !0)], 64))), 256)), (D(!0), S(v, null, k(X.value, (e) => (D(), S("path", {
2360
+ d: V.value.smooth ? e.smoothPath : e.straightPath,
2361
+ stroke: V.value.path.useSerieColor ? e.color : V.value.path.stroke,
2362
+ "stroke-width": V.value.strokeWidth,
2363
+ fill: "none",
2364
+ "stroke-linecap": "round",
2365
+ class: T({ "vue-data-ui-transition": j(Yn) })
2366
+ }, null, 10, kt))), 256))], 6)], 8, Dt),
2367
+ B.value.y.axisLabels.show && !V.value.distributed ? (D(), S("g", {
2368
+ key: 9,
2369
+ ref_key: "scaleLabels",
2370
+ ref: Mn
2371
+ }, [(D(!0), S(v, null, k(Ni.value, (e, t) => (D(), S("line", {
2372
+ key: `ytick_${t}`,
2373
+ class: T({ "vue-data-ui-transition": j(Yn) }),
2374
+ x1: Cr.value ? Z.value.right : Z.value.left,
2375
+ x2: Cr.value ? Z.value.right + 6 : Z.value.left - 6,
2376
+ y1: e.y,
2377
+ y2: e.y,
2378
+ stroke: B.value.x.axisColor,
2379
+ "stroke-width": 1
2380
+ }, null, 10, At))), 128)), (D(!0), S(v, null, k(Ni.value, (e, n) => (D(), S("text", {
2381
+ class: T({ "vue-data-ui-transition": j(Yn) }),
2382
+ transform: `translate(${e.x}, ${e.y + B.value.y.axisLabels.fontSize / 3})`,
2383
+ "font-size": B.value.y.axisLabels.fontSize,
2384
+ "font-weight": B.value.y.axisLabels.bold ? "bold" : "normal",
2385
+ fill: B.value.y.axisLabels.color,
2386
+ "text-anchor": Cr.value ? "start" : "end"
2387
+ }, it(j(ce)(B.value.y.axisLabels.formatter, e.value, j(t)({
2388
+ p: V.value.dataLabels.prefix,
2389
+ v: e.value,
2390
+ s: V.value.dataLabels.suffix,
2391
+ r: B.value.y.axisLabels.rounding
2392
+ }), { datapoint: e })), 11, jt))), 256))], 512)) : x("", !0),
2393
+ z.value.show ? (D(), S("g", {
2394
+ key: 10,
2395
+ ref_key: "timeLabelsEls",
2396
+ ref: Nn
2397
+ }, [n.$slots["time-label"] ? (D(), S("g", Mt, [(D(!0), S(v, null, k(Bi.value, (e, t) => (D(), S("g", null, [A(n.$slots, "time-label", Ze({ ref_for: !0 }, {
2398
+ x: K.value.left + Si.value * t + Si.value / 2,
2399
+ y: K.value.bottom + B.value.x.timeLabels.fontSize * 1.3 + B.value.x.timeLabels.offsetY,
2400
+ fontSize: B.value.x.timeLabels.fontSize,
2401
+ fill: B.value.x.timeLabels.color,
2402
+ transform: `translate(${K.value.left + Si.value * t + Si.value / 2}, ${K.value.bottom + z.value.fontSize * 1.3 + z.value.offsetY}), rotate(${z.value.rotation})`,
2403
+ absoluteIndex: e.absoluteIndex,
2404
+ content: e.text,
2405
+ textAnchor: B.value.x.timeLabels.rotation > 0 ? "start" : B.value.x.timeLabels.rotation < 0 ? "end" : "middle",
2406
+ show: !0
2407
+ }), void 0, !0)]))), 256))])) : (D(), S("g", Nt, [(D(!0), S(v, null, k(Bi.value, (e, t) => (D(), S("g", null, [String(e.text).includes("\n") ? (D(), S("text", {
2408
+ key: t + "-multi",
2409
+ "text-anchor": B.value.x.timeLabels.rotation > 0 ? "start" : B.value.x.timeLabels.rotation < 0 ? "end" : "middle",
2410
+ "font-size": B.value.x.timeLabels.fontSize,
2411
+ fill: B.value.x.timeLabels.color,
2412
+ transform: `
2413
+ translate(
2414
+ ${Ta(t)},
2415
+ ${K.value.bottom + z.value.fontSize * 1.3 + z.value.offsetY}
2416
+ ),
2417
+ rotate(${z.value.rotation})
2418
+ `,
2419
+ style: $e({ cursor: Xn.value ? "pointer" : "default" }),
2420
+ innerHTML: n.createTSpansFromLineBreaksOnX({
2421
+ content: String(e.text),
2422
+ fontSize: B.value.x.timeLabels.fontSize,
2423
+ fill: B.value.x.timeLabels.color,
2424
+ stroke: U.value.backgroundColor,
2425
+ x: 0,
2426
+ y: 0
2427
+ }),
2428
+ onClick: () => Fa(e, t)
2429
+ }, null, 12, Ft)) : (D(), S("text", {
2430
+ class: "vue-data-ui-time-label",
2431
+ key: t,
2432
+ "text-anchor": B.value.x.timeLabels.rotation > 0 ? "start" : B.value.x.timeLabels.rotation < 0 ? "end" : "middle",
2433
+ "font-size": B.value.x.timeLabels.fontSize,
2434
+ "font-weight": B.value.x.timeLabels.bold ? "bold" : "normal",
2435
+ fill: B.value.x.timeLabels.color,
2436
+ stroke: U.value.backgroundColor,
2437
+ "stroke-width": "3",
2438
+ "stroke-linecap": "round",
2439
+ "stroke-linejoin": "round",
2440
+ "paint-order": "stroke fill",
2441
+ transform: `translate(${Ta(t)}, ${K.value.bottom + z.value.fontSize * 1.3 + z.value.offsetY}), rotate(${z.value.rotation})`,
2442
+ style: $e({ cursor: Xn.value ? "pointer" : "default" }),
2443
+ onClick: () => Fa(e, t)
2444
+ }, it(e.text), 13, Pt))]))), 256))]))], 512)) : x("", !0),
2445
+ (kn.value || ![null, void 0].includes($.value)) && !U.value.highlighter.useLine ? (D(!0), S(v, { key: 11 }, k(Y.value.end - Y.value.start, (e, t) => (D(), S("g", { key: `tooltip_trap_highlighter_${t}` }, [C("rect", {
2446
+ x: Ea(t).x,
2447
+ y: K.value.top,
2448
+ height: K.value.height,
2449
+ width: Ea(t).width,
2450
+ fill: [Kn.value, $.value].includes(t) ? j(ue)(U.value.highlighter.color, U.value.highlighter.opacity) : "transparent",
2451
+ style: {
2452
+ transition: "none !important",
2453
+ animation: "none !important"
2454
+ }
2455
+ }, null, 8, It)]))), 128)) : x("", !0),
2456
+ (kn.value || ![null, void 0].includes($.value)) && U.value.highlighter.useLine ? (D(), S(v, { key: 12 }, [![null, void 0].includes($.value) || ![null, void 0].includes(Kn.value) ? (D(), S("g", Lt, [C("line", {
2457
+ x1: Ta(($.value ?? Kn.value) || 0),
2458
+ x2: Ta(($.value ?? Kn.value) || 0),
2459
+ y1: j(pe)(K.value.top),
2460
+ y2: j(pe)(K.value.bottom),
2461
+ stroke: U.value.highlighter.color,
2462
+ "stroke-width": U.value.highlighter.lineWidth,
2463
+ "stroke-dasharray": U.value.highlighter.lineDasharray,
2464
+ "stroke-linecap": "round",
2465
+ style: {
2466
+ transition: "none !important",
2467
+ animation: "none !important",
2468
+ "pointer-events": "none"
2469
+ }
2470
+ }, null, 8, Rt)])) : x("", !0)], 64)) : x("", !0),
2471
+ C("g", { "clip-path": hi.value }, [C("g", {
2472
+ class: T(["vue-ui-stackline-zoom-geometry", { "vue-ui-stackline-zoom-geometry--transitioning": Rr.value }]),
2473
+ style: $e(mi.value)
2474
+ }, [(D(!0), S(v, null, k(X.value, (e) => (D(), S(v, { key: `shp_sel_${e.id}` }, [kn.value && Y.value.end - Y.value.start > V.value.dot.hideAboveMaxSerieLength ? (D(), S("g", Bt, [$.value == null ? x("", !0) : (D(), S(v, { key: 0 }, [e.rel.includes($.value) && e.fullSeries?.[Y.value.start + $.value] != null && !Number.isNaN(e.fullSeries?.[Y.value.start + $.value]) ? (D(), b(Pe, {
2475
+ key: 0,
2476
+ shape: [
2477
+ "triangle",
2478
+ "square",
2479
+ "diamond",
2480
+ "pentagon",
2481
+ "hexagon",
2482
+ "star"
2483
+ ].includes(e.shape) ? e.shape : "circle",
2484
+ color: V.value.dot.useSerieColor ? e.color : V.value.dot.fill,
2485
+ plot: {
2486
+ x: j(ne)(e.points[e.rel.indexOf($.value)].x),
2487
+ y: j(ne)(e.points[e.rel.indexOf($.value)].y)
2488
+ },
2489
+ radius: V.value.dot.radius * 1.3,
2490
+ stroke: V.value.dot.useSerieColor ? V.value.dot.stroke : e.color,
2491
+ strokeWidth: V.value.dot.strokeWidth,
2492
+ still: j(Qn),
2493
+ class: T({ "vue-data-ui-transition": j(Yn) })
2494
+ }, null, 8, [
2495
+ "shape",
2496
+ "color",
2497
+ "plot",
2498
+ "radius",
2499
+ "stroke",
2500
+ "strokeWidth",
2501
+ "still",
2502
+ "class"
2503
+ ])) : x("", !0)], 64))])) : x("", !0)], 64))), 128)), (D(!0), S(v, null, k(X.value, (e) => (D(), S(v, { key: `shp_${e.id}` }, [Y.value.end - Y.value.start < V.value.dot.hideAboveMaxSerieLength ? (D(!0), S(v, { key: 0 }, k(e.points, (t, n) => (D(), S("g", { key: `shp_${e.id}_${Y.value.start + n}` }, [e.fullSeries?.[Y.value.start + e.rel[n]] != null && !Number.isNaN(e.fullSeries?.[Y.value.start + e.rel[n]]) ? (D(), b(Pe, {
2504
+ key: 0,
2505
+ shape: [
2506
+ "triangle",
2507
+ "square",
2508
+ "diamond",
2509
+ "pentagon",
2510
+ "hexagon",
2511
+ "star"
2512
+ ].includes(e.shape) ? e.shape : "circle",
2513
+ color: V.value.dot.useSerieColor ? e.color : V.value.dot.fill,
2514
+ plot: {
2515
+ x: t.x,
2516
+ y: t.y
2517
+ },
2518
+ radius: kn.value && $.value === e.rel[n] ? V.value.dot.radius * 1.3 : V.value.dot.radius,
2519
+ stroke: V.value.dot.useSerieColor ? V.value.dot.stroke : e.color,
2520
+ strokeWidth: V.value.dot.strokeWidth,
2521
+ still: j(Qn),
2522
+ class: T({ "vue-data-ui-transition": j(Yn) })
2523
+ }, null, 8, [
2524
+ "shape",
2525
+ "color",
2526
+ "plot",
2527
+ "radius",
2528
+ "stroke",
2529
+ "strokeWidth",
2530
+ "still",
2531
+ "class"
2532
+ ])) : x("", !0)]))), 128)) : x("", !0)], 64))), 128))], 6)], 8, zt),
2533
+ G.value.dataLabels.show && V.value.dataLabels.hideAboveMaxSerieLength > Y.value.end - Y.value.start ? (D(), S(v, { key: 13 }, [(D(!0), S(v, null, k(X.value, (e, t) => (D(), S("g", { key: `dl_${e.id}` }, [(D(!0), S(v, null, k(e.points, (n, r) => (D(), S(v, { key: `dp_${e.id}_${Y.value.start + r}` }, [fo(e.series[r], e.proportions[r]) ? (D(), S("text", {
2534
+ key: 0,
2535
+ class: T({ "vue-data-ui-transition": j(Yn) }),
2536
+ transform: `translate(${n.x}, ${n.y + (e.series[r] >= 0 ? -V.value.dataLabels.fontSize / 2 + V.value.dataLabels.offsetY : V.value.dataLabels.fontSize * 1.2 - V.value.dataLabels.offsetY)})`,
2537
+ "font-size": V.value.dataLabels.fontSize,
2538
+ fill: V.value.dataLabels.color,
2539
+ "font-weight": V.value.dataLabels.bold ? "bold" : "normal",
2540
+ "text-anchor": "middle"
2541
+ }, it(V.value.showDistributedPercentage && V.value.distributed ? ho(e.proportions[r] * 100, e, t, e.rel[r]) : mo(e.series[r], e, t, e.rel[r], e.signedSeries[r])), 11, Vt)) : x("", !0)], 64))), 128))]))), 128)), V.value.totalValues.show && X.value.length > 1 ? (D(), S("g", {
2542
+ key: 0,
2543
+ ref_key: "sumTop",
2544
+ ref: Pn
2545
+ }, [(D(!0), S(v, null, k(Ai.value, (e, t) => (D(), S(v, { key: `total_l_${t + Y.value.start}` }, [!V.value.dataLabels.hideEmptyValues || e.value !== 0 ? (D(), S("text", {
2546
+ key: 0,
2547
+ class: T({ "vue-data-ui-transition": j(Yn) }),
2548
+ transform: `translate(${Ta(t)}, ${Mi(t)})`,
2549
+ "text-anchor": "middle",
2550
+ "font-size": V.value.totalValues.fontSize,
2551
+ "font-weight": V.value.totalValues.bold ? "bold" : "normal",
2552
+ fill: V.value.totalValues.color
2553
+ }, it(mo(e.value, e, t, t, e.sign)), 11, Ht)) : x("", !0)], 64))), 128))], 512)) : x("", !0)], 64)) : x("", !0),
2554
+ ca.value ? (D(), S("rect", {
2555
+ key: 14,
2556
+ x: ca.value.x,
2557
+ y: ca.value.y,
2558
+ width: ca.value.width,
2559
+ height: ca.value.height,
2560
+ fill: Xr.value.selection.fill,
2561
+ "fill-opacity": Xr.value.selection.fillOpacity,
2562
+ stroke: Xr.value.selection.stroke,
2563
+ "stroke-opacity": Xr.value.selection.strokeOpacity,
2564
+ "stroke-width": Xr.value.selection.strokeWidth,
2565
+ "stroke-dasharray": Xr.value.selection.strokeDasharray,
2566
+ "stroke-linecap": "round",
2567
+ "stroke-linejoin": "round",
2568
+ "pointer-events": "none"
2569
+ }, null, 8, Ut)) : x("", !0),
2570
+ ti.value ? (D(), S("rect", Ze({ key: 15 }, jr.value, {
2571
+ "data-start": Y.value.start,
2572
+ "data-end": Y.value.end
2573
+ }), null, 16, Wt)) : x("", !0),
2574
+ A(n.$slots, "svg", { svg: {
2575
+ drawingArea: K.value,
2576
+ data: X.value,
2577
+ isPrintingImg: j(dr) || j(fr) || j(Ya),
2578
+ isPrintingSvg: j(Xa)
2579
+ } }, void 0, !0)
2580
+ ], 46, mt)), n.$slots.hint ? (D(), S("div", Gt, [A(n.$slots, "hint", E(w({
2581
+ hint: L.value.a11y.translations.keyboardNavigation,
2582
+ isVisible: vo.value
2583
+ })), void 0, !0)])) : x("", !0)]),
2584
+ n.$slots.watermark ? (D(), S("div", Kt, [A(n.$slots, "watermark", E(w({ isPrinting: j(dr) || j(fr) || j(Ya) || j(Xa) })), void 0, !0)])) : x("", !0),
2585
+ En.value && (U.value.legend.show || n.$slots.legend) ? (D(), b(Ke, {
2586
+ key: 6,
2587
+ to: U.value.legend.position === "top" ? `#legend-top-${F.value}` : `#legend-bottom-${F.value}`
2588
+ }, [C("div", {
2589
+ ref_key: "chartLegend",
2590
+ ref: _n
2591
+ }, [A(n.$slots, "legend", { legend: Ra.value }, () => [U.value.legend.show ? (D(), b(We, {
2592
+ key: 0,
2593
+ legendSet: Ra.value,
2594
+ config: za.value,
2595
+ isCursorPointer: Xn.value,
2596
+ onClickMarker: r[0] ||= ({ legend: e }) => e.segregate()
2597
+ }, qe({
2598
+ item: M(({ legend: e }) => [j(Qn) ? x("", !0) : (D(), S("div", {
2599
+ key: 0,
2600
+ onClick: (t) => e.segregate(),
2601
+ style: $e(`opacity:${I.value.includes(e.id) ? .5 : 1}`)
2602
+ }, it(e.name), 13, qt))]),
2603
+ legendToggle: M(() => [Ra.value.length > 2 && U.value.legend.selectAllToggle.show && !j(Qn) ? (D(), b(Be, {
2604
+ key: 0,
2605
+ backgroundColor: U.value.legend.selectAllToggle.backgroundColor,
2606
+ color: U.value.legend.selectAllToggle.color,
2607
+ fontSize: U.value.legend.fontSize,
2608
+ checked: I.value.length > 0,
2609
+ isCursorPointer: Xn.value,
2610
+ onToggle: Ia
2611
+ }, null, 8, [
2612
+ "backgroundColor",
2613
+ "color",
2614
+ "fontSize",
2615
+ "checked",
2616
+ "isCursorPointer"
2617
+ ])) : x("", !0)]),
2618
+ _: 2
2619
+ }, [n.$slots.pattern ? {
2620
+ name: "legend-pattern",
2621
+ fn: M(({ legend: e, index: t }) => [Ye(Pe, {
2622
+ shape: e.shape,
2623
+ radius: 30,
2624
+ stroke: "none",
2625
+ plot: {
2626
+ x: 30,
2627
+ y: 30
2628
+ },
2629
+ fill: `url(#pattern_${F.value}_${t})`
2630
+ }, null, 8, ["shape", "fill"])]),
2631
+ key: "0"
2632
+ } : void 0]), 1032, [
2633
+ "legendSet",
2634
+ "config",
2635
+ "isCursorPointer"
2636
+ ])) : x("", !0)], !0)], 512)], 8, ["to"])) : x("", !0),
2637
+ fn.value && R.value.buttons.table ? (D(), b(nt(eo.value.component), Ze({ key: 7 }, eo.value.props, {
2638
+ ref_key: "tableUnit",
2639
+ ref: Dn,
2640
+ onClose: to
2641
+ }), qe({
2642
+ content: M(() => [Ye(j(nn), {
2643
+ colNames: Ga.value.colNames,
2644
+ head: Ga.value.head,
2645
+ body: Ga.value.body,
2646
+ config: Ga.value.config,
2647
+ title: L.value.table.useDialog ? "" : eo.value.title,
2648
+ withCloseButton: !L.value.table.useDialog,
2649
+ isCursorPointer: Xn.value,
2650
+ onClose: to
2651
+ }, {
2652
+ th: M(({ th: e }) => [e === "__SUM__" ? (D(), S("div", Jt, [Ye(j(en), {
2653
+ name: "sigma",
2654
+ stroke: Ga.value.config.th.color,
2655
+ size: 16
2656
+ }, null, 8, ["stroke"])])) : (D(), S("div", Yt, it(e), 1))]),
2657
+ td: M(({ td: e }) => [Je(it(isNaN(Number(e)) ? e : j(t)({
2658
+ p: V.value.dataLabels.prefix,
2659
+ v: e,
2660
+ s: V.value.dataLabels.suffix,
2661
+ r: L.value.table.td.roundingValue
2662
+ })), 1)]),
2663
+ _: 1
2664
+ }, 8, [
2665
+ "colNames",
2666
+ "head",
2667
+ "body",
2668
+ "config",
2669
+ "title",
2670
+ "withCloseButton",
2671
+ "isCursorPointer"
2672
+ ])]),
2673
+ _: 2
2674
+ }, [L.value.table.useDialog ? {
2675
+ name: "title",
2676
+ fn: M(() => [Je(it(eo.value.title), 1)]),
2677
+ key: "0"
2678
+ } : void 0, L.value.table.useDialog ? {
2679
+ name: "actions",
2680
+ fn: M(() => [C("button", {
2681
+ tabindex: "0",
2682
+ class: "vue-ui-user-options-button",
2683
+ onClick: r[1] ||= (e) => Wa(R.value.callbacks.csv),
2684
+ style: $e({ cursor: Xn.value ? "pointer" : "default" })
2685
+ }, [Ye(j(en), {
2686
+ name: "fileCsv",
2687
+ stroke: eo.value.props.color
2688
+ }, null, 8, ["stroke"])], 4)]),
2689
+ key: "1"
2690
+ } : void 0]), 1040)) : x("", !0),
2691
+ U.value.zoom.show && fn.value && Xi.value && J.value > 6 ? (D(), b(ze, {
2692
+ key: 8,
2693
+ ref_key: "chartSlicer",
2694
+ ref: vn,
2695
+ "data-dom-to-png-ignore-layout": "",
2696
+ allMinimaps: Ei.value,
2697
+ background: U.value.zoom.color,
2698
+ borderColor: U.value.backgroundColor,
2699
+ customFormat: U.value.zoom.customFormat,
2700
+ cutNullValues: !1,
2701
+ enableRangeHandles: U.value.zoom.enableRangeHandles,
2702
+ enableSelectionDrag: U.value.zoom.enableSelectionDrag,
2703
+ end: Y.value.end,
2704
+ focusOnDrag: U.value.zoom.focusOnDrag,
2705
+ focusRangeRatio: U.value.zoom.focusRangeRatio,
2706
+ fontSize: U.value.zoom.fontSize,
2707
+ immediate: !U.value.zoom.preview.enable,
2708
+ inputColor: U.value.zoom.color,
2709
+ isPreview: ti.value,
2710
+ labelLeft: z.value.values[Y.value.start] ? Pi.value?.[0]?.text ?? "" : "",
2711
+ labelRight: z.value.values[Y.value.end - 1] ? Pi.value?.at(-1)?.text ?? "" : "",
2712
+ max: Math.max(...e.dataset.map((e) => e.series.length)),
2713
+ min: 0,
2714
+ minimap: Ti.value,
2715
+ minimapCompact: U.value.zoom.minimap.compact,
2716
+ minimapFrameColor: U.value.zoom.minimap.frameColor,
2717
+ minimapIndicatorColor: U.value.zoom.minimap.indicatorColor,
2718
+ minimapMerged: !1,
2719
+ minimapSelectedColor: U.value.zoom.minimap.selectedColor,
2720
+ minimapSelectedColorOpacity: U.value.zoom.minimap.selectedColorOpacity,
2721
+ minimapSelectedIndex: $.value,
2722
+ minimapSelectionRadius: 1,
2723
+ preciseLabels: Gi.value.length ? Gi.value : Fi.value,
2724
+ refreshEndPoint: U.value.zoom.endIndex === null ? Math.max(...e.dataset.map((e) => e.series.length)) : U.value.zoom.endIndex + 1,
2725
+ refreshStartPoint: U.value.zoom.startIndex === null ? 0 : U.value.zoom.startIndex,
2726
+ selectColor: U.value.zoom.highlightColor,
2727
+ selectedSeries: co.value,
2728
+ smoothMinimap: !1,
2729
+ start: Y.value.start,
2730
+ textColor: U.value.color,
2731
+ timeLabels: Fi.value,
2732
+ usePreciseLabels: z.value.datetimeFormatter.enable && !U.value.zoom.useDefaultFormat,
2733
+ valueEnd: Y.value.end,
2734
+ valueStart: Y.value.start,
2735
+ verticalHandles: U.value.zoom.minimap.verticalHandles,
2736
+ maxWidth: U.value.zoom.maxWidth,
2737
+ minimapLeftInsetRatio: K.value.chartWidth > 0 && U.value.zoom.autoFit ? K.value.left / K.value.chartWidth : null,
2738
+ minimapRightInsetRatio: K.value.chartWidth > 0 && U.value.zoom.autoFit ? (K.value.chartWidth - K.value.right) / K.value.chartWidth : null,
2739
+ isCursorPointer: Xn.value,
2740
+ additionalMinimapHeight: U.value.zoom.minimap.additionalHeight,
2741
+ handleType: U.value.zoom.minimap.handleType,
2742
+ handleIconColor: U.value.zoom.minimap.handleIconColor,
2743
+ handleBorderWidth: U.value.zoom.minimap.handleBorderWidth,
2744
+ handleBorderColor: U.value.zoom.minimap.handleBorderColor,
2745
+ handleFill: U.value.zoom.minimap.handleFill,
2746
+ handleWidth: U.value.zoom.minimap.handleWidth,
2747
+ "onUpdate:end": ta,
2748
+ "onUpdate:start": ea,
2749
+ onTrapMouse: Pr,
2750
+ onReset: r[2] ||= () => xi({
2751
+ force: !0,
2752
+ publish: !0
2753
+ }),
2754
+ onFutureEnd: r[3] ||= (e) => ni("end", e),
2755
+ onFutureStart: r[4] ||= (e) => ni("start", e)
2756
+ }, {
2757
+ "reset-action": M(({ reset: e }) => [A(n.$slots, "reset-action", E(w({ reset: e })), void 0, !0)]),
2758
+ slotMap: M(({ width: e, height: t, unitW: n }) => [C("g", { innerHTML: uo({
2759
+ minimapW: e,
2760
+ minimapH: t,
2761
+ unitW: n
2762
+ }) }, null, 8, Xt)]),
2763
+ _: 3
2764
+ }, 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.minimapLeftInsetRatio.minimapRightInsetRatio.isCursorPointer.additionalMinimapHeight.handleType.handleIconColor.handleBorderWidth.handleBorderColor.handleFill.handleWidth".split("."))) : x("", !0),
2765
+ C("div", { id: `legend-bottom-${F.value}` }, null, 8, Zt),
2766
+ Ye(j($t), {
2767
+ teleportTo: H.value.teleportTo,
2768
+ show: G.value.showTooltip && mn.value,
2769
+ backgroundColor: H.value.backgroundColor,
2770
+ color: H.value.color,
2771
+ fontSize: H.value.fontSize,
2772
+ borderRadius: H.value.borderRadius,
2773
+ borderColor: H.value.borderColor,
2774
+ borderWidth: H.value.borderWidth,
2775
+ backgroundOpacity: H.value.backgroundOpacity,
2776
+ position: H.value.position,
2777
+ offsetX: H.value.offsetX,
2778
+ offsetY: H.value.offsetY,
2779
+ parent: pn.value,
2780
+ content: Na.value,
2781
+ isFullscreen: xn.value,
2782
+ isCustom: H.value.customFormat && typeof H.value.customFormat == "function",
2783
+ smooth: H.value.smooth,
2784
+ backdropFilter: H.value.backdropFilter,
2785
+ smoothForce: H.value.smoothForce,
2786
+ smoothSnapThreshold: H.value.smoothSnapThreshold,
2787
+ isA11yMode: Vn.value === "keyboard",
2788
+ a11yPosition: Bn.value
2789
+ }, {
2790
+ "tooltip-before": M(() => [A(n.$slots, "tooltip-before", E(w({ ...Ji.value })), void 0, !0)]),
2791
+ tooltip: M(() => [A(n.$slots, "tooltip", E(w({ ...Ji.value })), void 0, !0)]),
2792
+ "tooltip-after": M(() => [A(n.$slots, "tooltip-after", E(w({ ...Ji.value })), void 0, !0)]),
2793
+ _: 3
2794
+ }, 8, [
2795
+ "teleportTo",
2796
+ "show",
2797
+ "backgroundColor",
2798
+ "color",
2799
+ "fontSize",
2800
+ "borderRadius",
2801
+ "borderColor",
2802
+ "borderWidth",
2803
+ "backgroundOpacity",
2804
+ "position",
2805
+ "offsetX",
2806
+ "offsetY",
2807
+ "parent",
2808
+ "content",
2809
+ "isFullscreen",
2810
+ "isCustom",
2811
+ "smooth",
2812
+ "backdropFilter",
2813
+ "smoothForce",
2814
+ "smoothSnapThreshold",
2815
+ "isA11yMode",
2816
+ "a11yPosition"
2817
+ ]),
2818
+ n.$slots.source ? (D(), S("div", {
2819
+ key: 9,
2820
+ ref_key: "source",
2821
+ ref: bn,
2822
+ dir: "auto"
2823
+ }, [A(n.$slots, "source", {}, void 0, !0)], 512)) : x("", !0),
2824
+ A(n.$slots, "skeleton", {}, () => [j(Qn) ? (D(), b(Te, { key: 0 })) : x("", !0)], !0)
2825
+ ], 46, ut));
2826
+ }
2827
+ }, [["__scopeId", "data-v-d6f07339"]]);
2828
+ //#endregion
2829
+ export { lt as n, $t as t };