vue-data-ui 3.23.0 → 3.23.2

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