vue-data-ui 3.17.11 → 3.17.13

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 (145) hide show
  1. package/dist/{PackageVersion-CHNfLQ9Q.js → PackageVersion-BfrCAH6_.js} +1 -1
  2. package/dist/components/vue-ui-3d-bar.js +1 -1
  3. package/dist/components/vue-ui-accordion.js +1 -1
  4. package/dist/components/vue-ui-age-pyramid.js +1 -1
  5. package/dist/components/vue-ui-annotator.js +1 -1
  6. package/dist/components/vue-ui-bullet.js +1 -1
  7. package/dist/components/vue-ui-bump.js +1 -1
  8. package/dist/components/vue-ui-candlestick.js +1 -1
  9. package/dist/components/vue-ui-carousel-table.js +1 -1
  10. package/dist/components/vue-ui-chestnut.js +1 -1
  11. package/dist/components/vue-ui-chord.js +1 -1
  12. package/dist/components/vue-ui-circle-pack.js +1 -1
  13. package/dist/components/vue-ui-cursor.js +1 -1
  14. package/dist/components/vue-ui-dag.js +1 -1
  15. package/dist/components/vue-ui-dashboard.js +1 -1
  16. package/dist/components/vue-ui-digits.js +1 -1
  17. package/dist/components/vue-ui-donut-evolution.js +1 -1
  18. package/dist/components/vue-ui-donut.js +1 -1
  19. package/dist/components/vue-ui-dumbbell.js +1 -1
  20. package/dist/components/vue-ui-flow.js +1 -1
  21. package/dist/components/vue-ui-funnel.js +1 -1
  22. package/dist/components/vue-ui-galaxy.js +1 -1
  23. package/dist/components/vue-ui-gauge.js +1 -1
  24. package/dist/components/vue-ui-geo.js +1 -1
  25. package/dist/components/vue-ui-gizmo.js +1 -1
  26. package/dist/components/vue-ui-heatmap.js +1 -1
  27. package/dist/components/vue-ui-history-plot.js +1 -1
  28. package/dist/components/vue-ui-horizontal-bar.js +1 -1
  29. package/dist/components/vue-ui-kpi.js +1 -1
  30. package/dist/components/vue-ui-mini-loader.js +1 -1
  31. package/dist/components/vue-ui-molecule.js +1 -1
  32. package/dist/components/vue-ui-mood-radar.js +1 -1
  33. package/dist/components/vue-ui-nested-donuts.js +1 -1
  34. package/dist/components/vue-ui-onion.js +1 -1
  35. package/dist/components/vue-ui-parallel-coordinate-plot.js +1 -1
  36. package/dist/components/vue-ui-quadrant.js +1 -1
  37. package/dist/components/vue-ui-quick-chart.js +1 -1
  38. package/dist/components/vue-ui-radar.js +1 -1
  39. package/dist/components/vue-ui-rating.js +1 -1
  40. package/dist/components/vue-ui-relation-circle.js +1 -1
  41. package/dist/components/vue-ui-ridgeline.js +1 -1
  42. package/dist/components/vue-ui-rings.js +1 -1
  43. package/dist/components/vue-ui-scatter.js +1 -1
  44. package/dist/components/vue-ui-skeleton.js +1 -1
  45. package/dist/components/vue-ui-smiley.js +1 -1
  46. package/dist/components/vue-ui-spark-trend.js +1 -1
  47. package/dist/components/vue-ui-sparkbar.js +1 -1
  48. package/dist/components/vue-ui-sparkgauge.js +1 -1
  49. package/dist/components/vue-ui-sparkhistogram.js +1 -1
  50. package/dist/components/vue-ui-sparkline.js +1 -1
  51. package/dist/components/vue-ui-sparkstackbar.js +1 -1
  52. package/dist/components/vue-ui-stackbar.js +1 -1
  53. package/dist/components/vue-ui-stackline.js +1 -1
  54. package/dist/components/vue-ui-strip-plot.js +1 -1
  55. package/dist/components/vue-ui-table-heatmap.js +1 -1
  56. package/dist/components/vue-ui-table-sparkline.js +1 -1
  57. package/dist/components/vue-ui-table.js +1 -1
  58. package/dist/components/vue-ui-thermometer.js +1 -1
  59. package/dist/components/vue-ui-timer.js +1 -1
  60. package/dist/components/vue-ui-tiremarks.js +1 -1
  61. package/dist/components/vue-ui-treemap.js +1 -1
  62. package/dist/components/vue-ui-vertical-bar.js +1 -1
  63. package/dist/components/vue-ui-waffle.js +1 -1
  64. package/dist/components/vue-ui-wheel.js +1 -1
  65. package/dist/components/vue-ui-word-cloud.js +1 -1
  66. package/dist/components/vue-ui-world.js +1 -1
  67. package/dist/components/vue-ui-xy-canvas.js +1 -1
  68. package/dist/components/vue-ui-xy.js +1 -1
  69. package/dist/style.css +1 -1
  70. package/dist/types/vue-data-ui.d.ts +53 -1
  71. package/dist/{useConfig-B70q17MC.js → useConfig-CG4HT3wS.js} +74 -27
  72. package/dist/{useObjectBindings-CIy6RtGn.js → useObjectBindings-Dixg-RIe.js} +2 -2
  73. package/dist/utils.js +1 -1
  74. package/dist/{vue-data-ui-BhpgB8UJ.js → vue-data-ui-D1ZI7Y4l.js} +67 -67
  75. package/dist/vue-data-ui.js +68 -68
  76. package/dist/{vue-ui-3d-bar-DlLiXS6Z.js → vue-ui-3d-bar-DEjKYzI5.js} +3 -3
  77. package/dist/{vue-ui-accordion-_zwPlx0H.js → vue-ui-accordion-DFtpH_16.js} +1 -1
  78. package/dist/{vue-ui-age-pyramid-DraVdYRy.js → vue-ui-age-pyramid-LiC9hTjP.js} +3 -3
  79. package/dist/{vue-ui-annotator-CveKE2KC.js → vue-ui-annotator-DrKnQoHf.js} +2 -2
  80. package/dist/{vue-ui-bullet-WnD9rJbc.js → vue-ui-bullet-DdxEINdq.js} +2 -2
  81. package/dist/{vue-ui-bump-DwgahfiC.js → vue-ui-bump-CdgO1V7z.js} +3 -3
  82. package/dist/{vue-ui-candlestick-BleQTpuq.js → vue-ui-candlestick-DxJnPwto.js} +3 -3
  83. package/dist/{vue-ui-carousel-table-BjXxtjCZ.js → vue-ui-carousel-table-CMefu5TI.js} +2 -2
  84. package/dist/{vue-ui-chestnut-xBDbJ9su.js → vue-ui-chestnut-BnGN72PO.js} +3 -3
  85. package/dist/{vue-ui-chord-D_pGtRHt.js → vue-ui-chord-DWyar45U.js} +3 -3
  86. package/dist/{vue-ui-circle-pack-C7-wxx3Y.js → vue-ui-circle-pack-CQ8vF2XH.js} +3 -3
  87. package/dist/{vue-ui-cursor-DBvL5KTg.js → vue-ui-cursor-HHOdkmyB.js} +2 -2
  88. package/dist/{vue-ui-dag-BKGTFMQK.js → vue-ui-dag-BDWPBElq.js} +2 -2
  89. package/dist/{vue-ui-dashboard-CEtNOoBY.js → vue-ui-dashboard-Dg_I3X2a.js} +65 -65
  90. package/dist/{vue-ui-digits-BeIq6BVd.js → vue-ui-digits-CZmdir8V.js} +2 -2
  91. package/dist/{vue-ui-donut-BjV5_nf1.js → vue-ui-donut-BKegKHxj.js} +3 -3
  92. package/dist/{vue-ui-donut-evolution-B7hCGAIO.js → vue-ui-donut-evolution-047dE4Lu.js} +4 -4
  93. package/dist/{vue-ui-dumbbell-ZMLefa9v.js → vue-ui-dumbbell-BL4ZMChj.js} +3 -3
  94. package/dist/{vue-ui-flow-BYjkId4Z.js → vue-ui-flow-BAqtyunQ.js} +3 -3
  95. package/dist/{vue-ui-funnel-BZtpP-Of.js → vue-ui-funnel-Pl2sEOZs.js} +3 -3
  96. package/dist/{vue-ui-galaxy-bdIj6ERd.js → vue-ui-galaxy-CBF5Wsax.js} +3 -3
  97. package/dist/{vue-ui-gauge-DT5-qFXl.js → vue-ui-gauge-COV_S0Vp.js} +2 -2
  98. package/dist/{vue-ui-geo-nXp15sZ5.js → vue-ui-geo-CaPXElPf.js} +2 -2
  99. package/dist/{vue-ui-gizmo-J5MTo522.js → vue-ui-gizmo-Csn7up96.js} +2 -2
  100. package/dist/{vue-ui-heatmap-G7DzkGq2.js → vue-ui-heatmap-Cpb0BYLa.js} +3 -3
  101. package/dist/{vue-ui-history-plot-BLoxv5uS.js → vue-ui-history-plot-ZZEdzFCE.js} +3 -3
  102. package/dist/{vue-ui-horizontal-bar-B8wbIiWo.js → vue-ui-horizontal-bar-BonPYUZf.js} +3 -3
  103. package/dist/{vue-ui-kpi-AT8jIXnu.js → vue-ui-kpi-DoHhSsDK.js} +2 -2
  104. package/dist/{vue-ui-mini-loader-Ch3pABN3.js → vue-ui-mini-loader-DOTBVCLE.js} +1 -1
  105. package/dist/{vue-ui-molecule-j5opFMNQ.js → vue-ui-molecule-mVYnXouV.js} +3 -3
  106. package/dist/{vue-ui-mood-radar-Opwn9CwC.js → vue-ui-mood-radar-DPvwnc3z.js} +3 -3
  107. package/dist/{vue-ui-nested-donuts-Cc_5aNFc.js → vue-ui-nested-donuts-C7E6TXrZ.js} +3 -3
  108. package/dist/{vue-ui-onion-CjDIGb68.js → vue-ui-onion-BGIlFhGB.js} +3 -3
  109. package/dist/{vue-ui-parallel-coordinate-plot-CcQZTqNS.js → vue-ui-parallel-coordinate-plot-C6G_A9ua.js} +3 -3
  110. package/dist/{vue-ui-quadrant-FoV76r7G.js → vue-ui-quadrant-CVpIeYOB.js} +3 -3
  111. package/dist/{vue-ui-quick-chart-BPu7QR35.js → vue-ui-quick-chart-CcV8qn9-.js} +2 -2
  112. package/dist/{vue-ui-radar-C60tBqYo.js → vue-ui-radar-G4AV1rBo.js} +3 -3
  113. package/dist/{vue-ui-rating-CIXRuv3M.js → vue-ui-rating-CqPlP88P.js} +1 -1
  114. package/dist/{vue-ui-relation-circle-CaeT1NKV.js → vue-ui-relation-circle-CkZ8oFVV.js} +2 -2
  115. package/dist/{vue-ui-ridgeline-DpLnKVx2.js → vue-ui-ridgeline-CBTyYn6Q.js} +3 -3
  116. package/dist/{vue-ui-rings-Bp1MqbOV.js → vue-ui-rings-CSIOqFiP.js} +3 -3
  117. package/dist/vue-ui-scatter-AuC46ufT.js +2345 -0
  118. package/dist/{vue-ui-skeleton-BSR3VLyw.js → vue-ui-skeleton-YD6rZjY_.js} +2 -2
  119. package/dist/{vue-ui-smiley-D_oAUZR1.js → vue-ui-smiley-CY0WFv2j.js} +1 -1
  120. package/dist/{vue-ui-spark-trend-BqlM3vP7.js → vue-ui-spark-trend-D8KGIt-R.js} +2 -2
  121. package/dist/{vue-ui-sparkbar-DqtEGBj9.js → vue-ui-sparkbar-BjWGJjzN.js} +2 -2
  122. package/dist/{vue-ui-sparkgauge-DWOru6YE.js → vue-ui-sparkgauge-Dab5mss7.js} +2 -2
  123. package/dist/{vue-ui-sparkhistogram-DfYv2pHk.js → vue-ui-sparkhistogram-D0rsmiPh.js} +2 -2
  124. package/dist/{vue-ui-sparkline-Bu5xssk9.js → vue-ui-sparkline-BCaauQuX.js} +2 -2
  125. package/dist/{vue-ui-sparkstackbar-D-a14Bay.js → vue-ui-sparkstackbar-NT5yD6xA.js} +2 -2
  126. package/dist/{vue-ui-stackbar-BB-KLlR-.js → vue-ui-stackbar-ChBk_A1c.js} +3 -3
  127. package/dist/{vue-ui-stackline-fWtYk_Aa.js → vue-ui-stackline-Cujamlze.js} +3 -3
  128. package/dist/{vue-ui-strip-plot-D0QC2wVw.js → vue-ui-strip-plot-CGBumG6I.js} +3 -3
  129. package/dist/{vue-ui-table-Rk5HCqBr.js → vue-ui-table-BX2iMku4.js} +3 -3
  130. package/dist/{vue-ui-table-heatmap-DXuKkXsE.js → vue-ui-table-heatmap-KXgXYVXm.js} +1 -1
  131. package/dist/{vue-ui-table-sparkline-Cb6fl-Ux.js → vue-ui-table-sparkline-C3NWnry0.js} +2 -2
  132. package/dist/{vue-ui-thermometer-ConedyG6.js → vue-ui-thermometer-DvdceZB1.js} +2 -2
  133. package/dist/{vue-ui-timer-B-GcfZX7.js → vue-ui-timer-XWAbvuAY.js} +2 -2
  134. package/dist/{vue-ui-tiremarks-BGyILItf.js → vue-ui-tiremarks-B-YI1RlT.js} +2 -2
  135. package/dist/{vue-ui-treemap-C4PiafoY.js → vue-ui-treemap-AzorGfmd.js} +3 -3
  136. package/dist/{vue-ui-waffle-DvHrxSIL.js → vue-ui-waffle-CKtUvdTE.js} +3 -3
  137. package/dist/{vue-ui-wheel-DeKJJliu.js → vue-ui-wheel-CnsLEArZ.js} +2 -2
  138. package/dist/{vue-ui-word-cloud-IAom94Mg.js → vue-ui-word-cloud-iAme2ihe.js} +3 -3
  139. package/dist/{vue-ui-world-CH9uc5uY.js → vue-ui-world-D5rrC9rw.js} +3 -3
  140. package/dist/{vue-ui-xy-C11EO1Ja.js → vue-ui-xy-C_Q9chQe.js} +4 -4
  141. package/dist/{vue-ui-xy-canvas-DLvVyHZO.js → vue-ui-xy-canvas-DG0299qE.js} +2 -2
  142. package/dist/vue_ui_scatter-Bu1EAy9H.js +22 -0
  143. package/package.json +2 -2
  144. package/dist/vue-ui-scatter-C73P-oBq.js +0 -2013
  145. package/dist/vue_ui_scatter-CO5Iq9ai.js +0 -22
@@ -1,2013 +0,0 @@
1
- import { defineAsyncComponent as ye, computed as T, ref as w, toRefs as Ul, watch as je, shallowRef as Gt, onMounted as jl, onBeforeUnmount as Gl, openBlock as v, createElementBlock as c, unref as h, normalizeStyle as ue, normalizeClass as qt, createElementVNode as k, toDisplayString as V, createCommentVNode as m, createBlock as ae, withCtx as P, renderSlot as z, normalizeProps as q, guardReactiveProps as H, createSlots as Ht, createVNode as Oe, Fragment as Q, renderList as oe, Teleport as ql, resolveDynamicComponent as Hl, mergeProps as Kl, createTextVNode as Kt, nextTick as yt } from "vue";
2
- import { j as Zl, t as Zt, m as Jl, p as ge, o as Jt, q as dt, n as Ql, r as Qt, ak as ea, s as ht, am as ta, c as la, u as Ge, k as se, l as ee, X as aa, al as oa, K as Z, a0 as sa, a1 as na, T as ua, U as ia, a3 as ra } from "./lib-DMzrGQHK.js";
3
- import { t as va, u as ca } from "./useResponsive-DfdjqQps.js";
4
- import { u as ya } from "./useConfig-B70q17MC.js";
5
- import { u as da, B as ha } from "./BaseScanner-C2j3TsSY.js";
6
- import { u as fa } from "./usePrinter-C4t8DdQ-.js";
7
- import { u as pa } from "./useSvgExport-BTG4hVPO.js";
8
- import { u as ft } from "./useNestedProp-DH0BEVVS.js";
9
- import { u as ga } from "./useThemeCheck-C9Ccl7U9.js";
10
- import { u as ma } from "./useUserOptionState-B7Ej974k.js";
11
- import { u as xa } from "./useChartAccessibility-cp6XQtqi.js";
12
- import ba from "./img-CjTQXS0U.js";
13
- import { _ as pt } from "./Shape-CxJ5_Rre.js";
14
- import ka from "./Title-BbKoiBk2.js";
15
- import wa from "./vue_ui_scatter-CO5Iq9ai.js";
16
- import $a from "./Legend-DGN5lY60.js";
17
- import { A as Ma } from "./A11yDataTable-BpmuNomI.js";
18
- import { B as _a } from "./BaseLegendToggle-cMP8M2u0.js";
19
- import { _ as Ca } from "./_plugin-vue_export-helper-CHgC5LLL.js";
20
- const Aa = ["id"], Sa = ["id"], Ta = {
21
- key: 0,
22
- class: "sr-only",
23
- "aria-live": "polite",
24
- "aria-atomic": "true"
25
- }, La = ["id"], Pa = { style: { position: "relative" } }, Ba = ["xmlns", "aria-describedby", "viewBox"], za = ["width", "height"], Ia = { key: 1 }, Oa = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Da = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Ea = { key: 2 }, Na = ["id"], Fa = ["stop-color"], Wa = ["stop-color"], Xa = ["id"], Ya = ["stop-color"], Ra = ["stop-color"], Va = ["x", "y", "width", "height", "fill", "stroke", "stroke-width", "rx"], Ua = ["x", "y", "width", "height", "onMouseenter"], ja = {
26
- key: 2,
27
- style: { "pointer-events": "none" }
28
- }, Ga = ["x", "y", "width", "height", "fill", "fill-opacity"], qa = ["x1", "x2", "y2", "stroke", "stroke-dasharray", "stroke-width"], Ha = ["x1", "x2", "y2", "stroke", "stroke-dasharray", "stroke-width"], Ka = ["x", "y", "height", "width", "fill", "stroke", "stroke-width", "rx"], Za = ["x", "y", "width", "height", "onMouseenter"], Ja = {
29
- key: 2,
30
- style: { "pointer-events": "none" }
31
- }, Qa = ["x", "y", "width", "height", "fill", "fill-opacity"], eo = ["x1", "x2", "y1", "y2", "stroke", "stroke-dasharray", "stroke-width"], to = ["x1", "x2", "y1", "y2", "stroke", "stroke-dasharray", "stroke-width"], lo = {
32
- key: 0,
33
- style: { "pointer-events": "none" }
34
- }, ao = ["d", "stroke", "stroke-width"], oo = ["d", "stroke", "stroke-width"], so = ["d", "stroke", "stroke-width"], no = ["d", "stroke", "stroke-width"], uo = { key: 3 }, io = ["points", "fill", "stroke-width", "stroke-dasharray", "stroke"], ro = { key: 0 }, vo = ["cx", "cy", "r", "fill", "stroke", "stroke-width", "onMouseover", "onMouseleave", "onClick"], co = { key: 1 }, yo = ["clip-path"], ho = ["d", "fill", "stroke", "stroke-width", "stroke-opacity"], fo = {
35
- key: 0,
36
- style: { "pointer-events": "none" }
37
- }, po = ["x", "y", "width", "height"], go = {
38
- key: 6,
39
- style: { "pointer-events": "none !important" }
40
- }, mo = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], xo = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], bo = ["x", "y", "font-size", "fill", "font-weight", "text-anchor"], ko = ["x", "y", "font-size", "fill", "font-weight"], wo = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], $o = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], Mo = ["x", "y", "font-size", "fill", "font-weight", "text-anchor"], _o = ["id", "transform", "font-size", "font-weight", "fill"], Co = ["font-size", "fill", "transform"], Ao = ["transform", "font-size", "fill"], So = ["x", "y", "font-size", "fill"], To = ["x", "y", "font-size", "fill"], Lo = ["font-size", "font-weight", "fill", "x", "y"], Po = ["id"], Bo = ["x", "y", "width", "height"], zo = {
41
- key: 11,
42
- style: { pointerEvents: "none" }
43
- }, Io = ["x1", "x2", "y1", "y2", "stroke-dasharray", "stroke", "stroke-width", "clip-path"], Oo = ["x", "y", "fill", "font-size", "font-weight"], Do = {
44
- key: 0,
45
- style: { position: "absolute", top: "100%", left: "0", width: "100%" },
46
- "data-dom-to-png-ignore": "",
47
- "aria-hidden": "true"
48
- }, Eo = {
49
- key: 6,
50
- class: "vue-data-ui-watermark"
51
- }, No = ["id"], Fo = ["onClick"], Wo = {
52
- key: 0,
53
- style: { width: "100%", display: "flex", "align-items": "center", "justify-content": "center" }
54
- }, Xo = {
55
- viewBox: "0 0 20 20",
56
- height: "20",
57
- width: "20",
58
- style: { overflow: "hidden", background: "transparent" }
59
- }, Yo = { key: 0 }, Ro = ["innerHTML"], Vo = {
60
- __name: "vue-ui-scatter",
61
- props: {
62
- config: {
63
- type: Object,
64
- default() {
65
- return {};
66
- }
67
- },
68
- dataset: {
69
- type: Array,
70
- default() {
71
- return [];
72
- }
73
- }
74
- },
75
- emits: ["copyAlt"],
76
- setup(el, { expose: tl, emit: ll }) {
77
- const al = ye(() => import("./Tooltip-Cvt7Fi0Q.js")), ol = ye(() => import("./BaseIcon-DX0hTWa-.js")), sl = ye(() => import("./vue-ui-accordion-_zwPlx0H.js")), nl = ye(() => import("./DataTable-cMnb68Ik.js")), ul = ye(
78
- () => import("./PenAndPaper-CJDoB5H9.js")
79
- ), il = ye(
80
- () => import("./UserOptions-DVduN6X7.js")
81
- ), rl = ye(
82
- () => import("./PackageVersion-CHNfLQ9Q.js")
83
- ), vl = ye(
84
- () => import("./BaseDraggableDialog-Di8Hlru3.js")
85
- ), { vue_ui_scatter: cl } = ya(), { isThemeValid: yl, warnInvalidTheme: dl } = ga(), te = el, hl = ll, gt = T(() => !!te.dataset && te.dataset.length), N = w(Zl()), De = w(!1), qe = w(""), mt = w(0), ne = w(null), xt = w(null), bt = w(null), kt = w(null), wt = w(null), $t = w(0), Mt = w(0), _t = w(0), I = w([]), Ct = w(!1), _e = w(null), Ce = w(null), Ae = w(null), He = w(null), Ee = w(!1), Ne = w(!1), Ke = w(null), fl = w(null), pl = w(null), Ze = w(null), me = w(null), At = w({ x: 0, y: 0 }), Se = w("pointer"), Fe = w(!1), Te = w(null), e = w(lt()), de = T(
86
- () => e.value.userOptions.useCursorPointer
87
- );
88
- function gl(t = 100, a = 0.8, l = {}) {
89
- const { meanX: s = 0, sdX: o = 1, meanY: n = 0, sdY: i = 1, seed: y } = l;
90
- let r = (y ?? Math.floor(Math.random() * 2 ** 31)) >>> 0;
91
- const f = () => (r = r * 1664525 + 1013904223 >>> 0, r / 2 ** 32), A = () => {
92
- let b = 0, X = 0;
93
- for (; b === 0; ) b = f();
94
- for (; X === 0; ) X = f();
95
- return Math.sqrt(-2 * Math.log(b)) * Math.cos(2 * Math.PI * X);
96
- }, d = t / 2, x = Array.from({ length: d }, A), E = Array.from({ length: d }, A), _ = (b) => b.reduce((X, Ie) => X + Ie, 0) / b.length, O = _(x), D = _(E);
97
- for (let b = 0; b < d; b += 1)
98
- x[b] -= O, E[b] -= D;
99
- const L = (b, X) => b.reduce((Ie, Ue, ct) => Ie + Ue * X[ct], 0), C = (b) => L(b, b), p = L(E, x) / C(x), B = E.map((b, X) => b - p * x[X]), G = C(x) / d, le = C(B) / d, ce = Math.sqrt((1 - a * a) * G / le), j = x.map((b, X) => a * b + ce * B[X]), pe = x.concat(x.map((b) => -b)), vt = j.concat(j.map((b) => -b)), Be = (b) => Math.sqrt(C(b) / b.length), $e = (b, X, Ie) => {
100
- const Ue = Be(b);
101
- return b.map((ct) => Ie + (Ue ? ct / Ue * X : 0));
102
- }, Me = $e(pe, o, s), ze = $e(vt, i, n);
103
- for (let b = Me.length - 1; b > 0; b -= 1) {
104
- const X = Math.floor(f() * (b + 1));
105
- [Me[b], Me[X]] = [Me[X], Me[b]], [ze[b], ze[X]] = [ze[X], ze[b]];
106
- }
107
- return Me.map((b, X) => ({ x: b, y: ze[X] }));
108
- }
109
- const ml = T(() => Zt({
110
- defaultConfig: {
111
- userOptions: { show: !1 },
112
- table: { show: !1 },
113
- useCssAnimation: !1,
114
- style: {
115
- backgroundColor: "#99999930",
116
- layout: {
117
- axis: {
118
- stroke: "#6A6A6A"
119
- },
120
- correlation: {
121
- label: { show: !1 }
122
- },
123
- dataLabels: {
124
- xAxis: { show: !1 },
125
- yAxis: { show: !1 }
126
- },
127
- marginalBars: {
128
- fill: "#99999960"
129
- },
130
- padding: { top: 12, right: 12, bottom: 12, left: 12 },
131
- plots: {
132
- stroke: "#6A6A6A"
133
- }
134
- },
135
- legend: {
136
- backgroundColor: "transparent"
137
- }
138
- }
139
- },
140
- userConfig: e.value.skeletonConfig ?? {}
141
- })), { loading: Je, FINAL_DATASET: Qe, manualLoading: et } = da({
142
- ...Ul(te),
143
- FINAL_CONFIG: e,
144
- prepareConfig: lt,
145
- skeletonDataset: te.config?.skeletonDataset ?? [
146
- {
147
- name: "",
148
- color: "#999999",
149
- values: gl(100, 0.5, { seed: 42 })
150
- }
151
- ],
152
- skeletonConfig: Zt({
153
- defaultConfig: e.value,
154
- userConfig: ml.value
155
- })
156
- }), { userOptionsVisible: tt, setUserOptionsVisibility: St, keepUserOptionState: Tt } = ma({ config: e.value }), { svgRef: ie } = xa({
157
- config: e.value.style.title
158
- });
159
- function lt() {
160
- const t = ft({
161
- userConfig: te.config,
162
- defaultConfig: cl
163
- }), a = t.theme;
164
- if (!a) return t;
165
- if (!yl.value(t))
166
- return dl(t), t;
167
- const l = ft({
168
- userConfig: wa[a] || te.config,
169
- defaultConfig: t
170
- }), s = ft({
171
- userConfig: te.config,
172
- defaultConfig: l
173
- });
174
- return {
175
- ...s,
176
- customPalette: s.customPalette.length ? s.customPalette : Jl[a] || ge
177
- };
178
- }
179
- je(
180
- () => te.config,
181
- (t) => {
182
- Je.value || (e.value = lt()), tt.value = !e.value.userOptions.showOnChartHover, Pt(), $t.value += 1, Mt.value += 1, _t.value += 1, K.value.showTable = e.value.table.show, K.value.showTooltip = e.value.style.tooltip.show, Lt.value && e.value.usePerformanceMode && console.warn(
183
- `VueUiScatter : You are using performance mode
184
-
185
- - downsampling is disabled in this mode, all plots are rendered
186
-
187
- - plot significance is not active in this mode (all plots have the same opacity)
188
-
189
- - Depending on plot density, shapes might not display a border (stroke) to avoid fuzziness
190
-
191
- ℹ️ To remove this warning, set config.debug to false.`
192
- );
193
- },
194
- { deep: !0 }
195
- ), je(
196
- () => te.dataset,
197
- (t) => {
198
- Array.isArray(t) && t.length > 0 && (et.value = !1);
199
- },
200
- { deep: !0 }
201
- );
202
- const re = Gt(null), xe = Gt(null);
203
- jl(() => {
204
- Ct.value = !0, Pt();
205
- });
206
- const Lt = T(() => !!e.value.debug);
207
- function Pt() {
208
- if (Jt(te.dataset) && (dt({
209
- componentName: "VueUiScatter",
210
- type: "dataset",
211
- debug: Lt.value
212
- }), et.value = !0), Jt(te.dataset) || (et.value = e.value.loading), e.value.responsive) {
213
- const t = va(() => {
214
- const { width: a, height: l } = ca({
215
- chart: ne.value,
216
- title: e.value.style.title.text ? xt.value : null,
217
- legend: e.value.style.legend.show ? bt.value : null,
218
- source: kt.value,
219
- noTitle: wt.value
220
- });
221
- requestAnimationFrame(() => {
222
- Y.value.width = a, Y.value.height = l;
223
- });
224
- });
225
- re.value && (xe.value && re.value.unobserve(xe.value), re.value.disconnect()), re.value = new ResizeObserver(t), xe.value = ne.value.parentNode, re.value.observe(xe.value);
226
- }
227
- }
228
- Gl(() => {
229
- re.value && (xe.value && re.value.unobserve(xe.value), re.value.disconnect());
230
- });
231
- const { isPrinting: at, isImaging: ot, generatePdf: Bt, generateImage: zt } = fa({
232
- elementId: `vue-ui-scatter_${N.value}`,
233
- fileName: e.value.style.title.text || "vue-ui-scatter",
234
- options: e.value.userOptions.print
235
- }), xl = T(() => e.value.userOptions.show && !e.value.style.title.text), It = T(() => Ql(e.value.customPalette)), K = w({
236
- showTable: e.value.table.show,
237
- showTooltip: e.value.style.tooltip.show
238
- });
239
- je(
240
- e,
241
- () => {
242
- K.value = {
243
- showTable: e.value.table.show,
244
- showTooltip: e.value.style.tooltip.show
245
- };
246
- },
247
- { immediate: !0 }
248
- );
249
- const Y = w({
250
- height: e.value.style.layout.height,
251
- width: e.value.style.layout.width
252
- }), We = T(() => e.value.style.layout.marginalBars.show ? e.value.style.layout.marginalBars.size + e.value.style.layout.marginalBars.offset : 0), u = T(() => {
253
- let t = 0, a = 0;
254
- return Ke.value && (t = Ke.value.getBBox().width + 6), Ze.value && (a = Ze.value.getBBox().height + 6), {
255
- top: e.value.style.layout.padding.top + We.value + e.value.style.layout.dataLabels.yAxis.fontSize * 2,
256
- right: Y.value.width - e.value.style.layout.padding.right - We.value - 6,
257
- bottom: Y.value.height - e.value.style.layout.padding.bottom - a,
258
- left: e.value.style.layout.padding.left + t,
259
- height: Y.value.height - e.value.style.layout.padding.top - e.value.style.layout.padding.bottom - We.value - a - e.value.style.layout.dataLabels.yAxis.fontSize * 2,
260
- width: Y.value.width - e.value.style.layout.padding.left - e.value.style.layout.padding.right - We.value - t - 6
261
- };
262
- }), F = T(() => {
263
- Qe.value.forEach((o, n) => {
264
- Qt({
265
- datasetObject: o,
266
- requiredAttributes: ["values"]
267
- }).forEach((i) => {
268
- dt({
269
- componentName: "VueUiScatter",
270
- type: "datasetSerieAttribute",
271
- property: i,
272
- index: n
273
- });
274
- }), o.values && o.values.forEach((i, y) => {
275
- Qt({
276
- datasetObject: i,
277
- requiredAttributes: ["x", "y"]
278
- }).forEach((r) => {
279
- dt({
280
- componentName: "VueUiScatter",
281
- type: "datasetSerieAttribute",
282
- property: `values.${r}`,
283
- index: `${n} - ${y}`
284
- });
285
- });
286
- });
287
- });
288
- const t = Math.min(
289
- ...J.value.filter((o) => !I.value.includes(o.id)).flatMap((o) => o.values.map((n) => n.x))
290
- ), a = Math.max(
291
- ...J.value.filter((o) => !I.value.includes(o.id)).flatMap((o) => o.values.map((n) => n.x))
292
- ), l = Math.min(
293
- ...J.value.filter((o) => !I.value.includes(o.id)).flatMap((o) => o.values.map((n) => n.y))
294
- ), s = Math.max(
295
- ...J.value.filter((o) => !I.value.includes(o.id)).flatMap((o) => o.values.map((n) => n.y))
296
- );
297
- return {
298
- xMin: t >= 0 ? 0 : t,
299
- xMax: a,
300
- yMin: l >= 0 ? 0 : l,
301
- yMax: s
302
- };
303
- }), W = T(() => ({
304
- x: u.value.left + Math.abs(F.value.xMin) / (F.value.xMax + Math.abs(F.value.xMin)) * u.value.width,
305
- y: u.value.bottom - Math.abs(F.value.yMin) / (F.value.yMax + Math.abs(F.value.yMin)) * u.value.height
306
- })), J = T(() => Qe.value.map((t, a) => {
307
- const l = `cluster_${N.value}_${a}`;
308
- return {
309
- ...t,
310
- values: ea({
311
- data: t.values,
312
- threshold: e.value.usePerformanceMode ? t.values.length + 1 : e.value.downsample.threshold
313
- }),
314
- id: l,
315
- color: t.color ? t.color : It.value[a] || ge[a] || ge[a % ge.length],
316
- opacity: I.value.includes(l) ? 0.5 : 1,
317
- shape: t.shape ?? "circle",
318
- segregate: () => Ve(l),
319
- isSegregated: I.value.includes(l)
320
- };
321
- })), bl = T(() => ({
322
- cy: "scatter-div-legend",
323
- backgroundColor: e.value.style.legend.backgroundColor,
324
- color: e.value.style.legend.color,
325
- fontSize: e.value.style.legend.fontSize,
326
- paddingBottom: 12,
327
- fontWeight: e.value.style.legend.bold ? "bold" : ""
328
- })), be = T(() => J.value.map((t, a) => ({
329
- ...t,
330
- plots: t.values.map((l) => ({
331
- x: u.value.left + (l.x + Math.abs(F.value.xMin)) / (F.value.xMax + Math.abs(F.value.xMin)) * u.value.width,
332
- y: u.value.bottom - (l.y + Math.abs(F.value.yMin)) / (F.value.yMax + Math.abs(F.value.yMin)) * u.value.height,
333
- v: {
334
- ...l,
335
- name: l.name || ""
336
- },
337
- clusterName: t.name,
338
- clusterId: t.id,
339
- color: t.color ? t.color : It.value[a] || ge[a] || ge[a % ge.length],
340
- id: `plot_${N.value}_${Math.random()}`,
341
- weight: l.weight ?? e.value.style.layout.plots.radius
342
- }))
343
- })).filter((t) => !I.value.includes(t.id))), U = T(() => {
344
- const a = ({ m: l, b: s, rect: o, verticalX: n = null }) => {
345
- const { left: i, right: y, top: r, bottom: f } = o, A = [], d = (C, p) => {
346
- Number.isFinite(C) && Number.isFinite(p) && A.push({ x: C, y: p });
347
- }, x = ({ x: C, y: p }) => C >= i - 1e-9 && C <= y + 1e-9 && p >= r - 1e-9 && p <= f + 1e-9;
348
- n !== null ? n >= i - 1e-9 && n <= y + 1e-9 && (d(n, r), d(n, f)) : Number.isFinite(l) && (d(i, l * i + s), d(y, l * y + s), Math.abs(l) > 1e-9 ? (d((r - s) / l, r), d((f - s) / l, f)) : s >= r - 1e-9 && s <= f + 1e-9 && (d(i, s), d(y, s)));
349
- const E = A.filter(x), _ = [];
350
- for (const C of E)
351
- _.some(
352
- (p) => Math.abs(p.x - C.x) < 1e-6 && Math.abs(p.y - C.y) < 1e-6
353
- ) || _.push(C);
354
- if (_.length < 2) return null;
355
- let O = _[0], D = _[1], L = 0;
356
- for (let C = 0; C < _.length; C += 1)
357
- for (let p = C + 1; p < _.length; p += 1) {
358
- const B = _[C].x - _[p].x, G = _[C].y - _[p].y, le = B * B + G * G;
359
- le > L && (L = le, O = _[C], D = _[p]);
360
- }
361
- return { x1: O.x, y1: O.y, x2: D.x, y2: D.y };
362
- };
363
- return be.value.map((l) => {
364
- const s = l.plots.length, o = l.plots.reduce((p, B) => p + B.x, 0) / s, n = l.plots.reduce((p, B) => p + B.y, 0) / s;
365
- let i = 0, y = 0;
366
- for (const p of l.plots) {
367
- const B = p.x - o, G = p.y - n;
368
- i += B * G, y += B * B;
369
- }
370
- let r, f, A = null;
371
- y < 1e-9 ? (A = o, r = 1 / 0, f = null) : (r = i / y, f = n - r * o);
372
- let d, x;
373
- A !== null ? (d = 1 / 0, x = null) : (d = r, x = f);
374
- const E = l.plots.every(
375
- (p) => p.v && typeof p.v.x == "number" && typeof p.v.y == "number"
376
- );
377
- let _ = NaN;
378
- if (s >= 2) {
379
- let p = 0, B = 0;
380
- E ? (p = l.plots.reduce((j, pe) => j + pe.v.x, 0) / s, B = l.plots.reduce((j, pe) => j + pe.v.y, 0) / s) : (p = o, B = -n);
381
- let G = 0, le = 0, ce = 0;
382
- for (const j of l.plots) {
383
- const pe = E ? j.v.x : j.x, vt = E ? j.v.y : -j.y, Be = pe - p, $e = vt - B;
384
- G += Be * $e, le += Be * Be, ce += $e * $e;
385
- }
386
- if (le >= 1e-9 && ce >= 1e-9) {
387
- const j = G / Math.sqrt(le * ce);
388
- _ = Math.max(-1, Math.min(1, j));
389
- }
390
- }
391
- const O = a({
392
- m: d,
393
- b: x,
394
- rect: u.value,
395
- verticalX: A
396
- });
397
- if (!O)
398
- return {
399
- ...l,
400
- correlation: null,
401
- label: null,
402
- plots: l.plots.map((p) => ({
403
- ...p,
404
- deviation: 0,
405
- shape: l.shape,
406
- color: ht(l.color)
407
- }))
408
- };
409
- const D = (O.x1 + O.x2) / 2, L = (O.y1 + O.y2) / 2, C = { x: D, y: L };
410
- return {
411
- ...l,
412
- color: ht(l.color),
413
- correlation: {
414
- ...O,
415
- coefficient: _
416
- },
417
- label: C,
418
- plots: l.plots.map((p) => {
419
- let B, G;
420
- A !== null ? (B = A, G = p.y) : Math.abs(d) < 1e-9 ? (B = p.x, G = x) : (B = (p.x + d * p.y - d * x) / (1 + d * d), G = (d * p.x + d * d * p.y + x) / (1 + d * d));
421
- const le = p.x - B, ce = p.y - G, j = Math.sqrt(le * le + ce * ce);
422
- return {
423
- ...p,
424
- deviation: j,
425
- shape: l.shape,
426
- color: ht(l.color)
427
- };
428
- })
429
- };
430
- });
431
- }), Ot = T(() => Math.max(
432
- ...U.value.flatMap(
433
- (t) => t.plots.map((a) => Math.abs(a.deviation))
434
- )
435
- ));
436
- function kl() {
437
- return U.value;
438
- }
439
- function Dt(t, a) {
440
- const l = Array.isArray(t) ? t.flatMap((L) => L.plots.map((C) => ({
441
- x: C.x,
442
- y: C.y
443
- }))) : t.plots.map((L) => ({
444
- x: L.x,
445
- y: L.y
446
- }));
447
- let s = 1 / 0, o = -1 / 0, n = 1 / 0, i = -1 / 0;
448
- l.forEach(({ x: L, y: C }) => {
449
- s = Math.min(s, L), o = Math.max(o, L), n = Math.min(n, C), i = Math.max(i, C);
450
- });
451
- const y = o - s, r = i - n, f = y / a, A = r / a, d = Array(a).fill(0), x = Array(a).fill(0);
452
- l.forEach(({ x: L, y: C }) => {
453
- const p = Math.floor((L - s) / f), B = Math.floor((C - n) / A);
454
- d[p] || (d[p] = 0), x[B] || (x[B] = 0), d[p] += 1, x[B] += 1;
455
- });
456
- const E = [], _ = [];
457
- for (let L = 0; L < a; L += 1)
458
- E.push(s + (L + 0.5) * f), _.push(n + (L + 0.5) * A);
459
- const O = Math.max(...d), D = Math.max(...x);
460
- return { x: d, y: x, avgX: E, avgY: _, maxX: O, maxY: D };
461
- }
462
- const $ = T(
463
- () => e.value.style.layout.marginalBars.tranches
464
- ), S = T(() => Dt(be.value, $.value)), wl = T(() => {
465
- const t = u.value.top - e.value.style.layout.marginalBars.offset, a = u.value.right + e.value.style.layout.marginalBars.offset;
466
- return be.value.map((l) => {
467
- const s = Dt(l, $.value);
468
- return {
469
- coords: s,
470
- dX: la(
471
- s.avgX.map((o, n) => ({
472
- x: o,
473
- y: t - s.x[n] / s.maxX * e.value.style.layout.marginalBars.size
474
- }))
475
- ),
476
- dY: ta(
477
- s.avgY.map((o, n) => ({
478
- y: o,
479
- x: a + e.value.style.layout.marginalBars.size * s.y[n] / s.maxY
480
- }))
481
- ),
482
- color: l.color,
483
- id: l.id
484
- };
485
- });
486
- }), R = w(void 0), g = w(null), Xe = w(null);
487
- function st() {
488
- De.value = !1, R.value = void 0, g.value = null, Te.value = null, me.value = null;
489
- }
490
- function $l(t) {
491
- if (!ie.value || !t) return;
492
- const a = ra(t.x, t.y, ie.value);
493
- a && (At.value = a);
494
- }
495
- function he(t, a, l = "pointer", s = null) {
496
- R.value = t.id, g.value = t, Se.value = l, Te.value = s, me.value = t.id;
497
- let o = "";
498
- e.value.events.datapointEnter && e.value.events.datapointEnter({
499
- datapoint: t,
500
- seriesIndex: a
501
- }), Xe.value = {
502
- datapoint: t,
503
- seriesIndex: a,
504
- series: U.value,
505
- config: e.value
506
- };
507
- const n = e.value.style.tooltip.customFormat;
508
- ua(n) && ia(
509
- () => n({
510
- datapoint: t,
511
- seriesIndex: a,
512
- series: U.value,
513
- config: e.value
514
- })
515
- ) ? qe.value = n({
516
- datapoint: t,
517
- seriesIndex: a,
518
- series: U.value,
519
- config: e.value
520
- }) : (t.clusterName && (o += `<div style="display:flex;gap:3px;align-items:center">${t.clusterName}</div>`), t.v.name && (o += `<div>${t.v.name}</div>`), o += `<div style="text-align:left;margin-top:6px;padding-top:6px;border-top:1px solid ${e.value.style.tooltip.borderColor}">`, o += `<div>${e.value.style.layout.dataLabels.xAxis.name}: <b>${isNaN(t.v.x) ? "-" : se(
521
- e.value.style.layout.plots.selectors.labels.x.formatter,
522
- t.v.x,
523
- ee({
524
- p: e.value.style.tooltip.prefix,
525
- v: t.v.x,
526
- s: e.value.style.tooltip.suffix,
527
- r: e.value.style.tooltip.roundingValue
528
- }),
529
- { datapoint: t, seriesIndex: a }
530
- )}</b></div>`, o += `<div>${e.value.style.layout.dataLabels.yAxis.name}: <b>${isNaN(t.v.y) ? "-" : se(
531
- e.value.style.layout.plots.selectors.labels.y.formatter,
532
- t.v.y,
533
- ee({
534
- p: e.value.style.tooltip.prefix,
535
- v: t.v.y,
536
- s: e.value.style.tooltip.suffix,
537
- r: e.value.style.tooltip.roundingValue
538
- }),
539
- { datapoint: t, seriesIndex: a }
540
- )}</b></div>`, o += `${e.value.style.layout.plots.deviation.translation}: <b>${ee(
541
- {
542
- v: t.deviation,
543
- r: e.value.style.layout.plots.deviation.roundingValue
544
- }
545
- )}</b>`, o += "</div>", qe.value = `<div>${o}</div>`), De.value = !0, l === "keyboard" && yt(() => {
546
- $l(t);
547
- });
548
- }
549
- function Ye(t, a) {
550
- e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: a }), !(Se.value === "keyboard" && me.value === t?.id) && (De.value = !1, R.value = void 0, g.value = null);
551
- }
552
- function Re(t, a) {
553
- e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: a });
554
- }
555
- function Ml() {
556
- I.value.length ? I.value = [] : J.value.forEach((t) => {
557
- I.value.push(t.id);
558
- });
559
- }
560
- function Ve(t) {
561
- I.value.includes(t) ? I.value = I.value.filter((a) => a !== t) : I.value.length < Qe.value.length - 1 && I.value.push(t);
562
- }
563
- function Et(t) {
564
- if (!J.value.length)
565
- return e.value.debug && console.warn("VueUiScatter - There are no series to show."), null;
566
- const a = J.value.find((l) => l.name === t);
567
- return a || (e.value.debug && console.warn(`VueUiScatter - Series name not found "${t}"`), null);
568
- }
569
- function _l(t) {
570
- const a = Et(t);
571
- a !== null && I.value.includes(a.id) && Ve(a.id);
572
- }
573
- function Cl(t) {
574
- const a = Et(t);
575
- a !== null && (I.value.includes(a.id) || Ve(a.id));
576
- }
577
- function nt(t = null) {
578
- yt(() => {
579
- const a = [
580
- "",
581
- e.value.table.translations.correlationCoefficient,
582
- e.value.table.translations.nbrPlots,
583
- `${e.value.style.layout.dataLabels.xAxis.name} ${e.value.table.translations.average}`,
584
- `${e.value.style.layout.dataLabels.yAxis.name} ${e.value.table.translations.average}`
585
- ], l = U.value.map((n) => [
586
- n.name,
587
- n.correlation.coefficient,
588
- n.plots.length,
589
- n.plots.map((i) => i.v.x).reduce((i, y) => i + y, 0) / n.plots.length,
590
- n.plots.map((i) => i.v.y).reduce((i, y) => i + y, 0) / n.plots.length
591
- ]), s = [
592
- [e.value.style.title.text],
593
- [e.value.style.title.subtitle.text],
594
- [[""], [""], [""]]
595
- ].concat([a]).concat(l), o = sa(s);
596
- t ? t(o) : na({
597
- csvContent: o,
598
- title: e.value.style.title.text || "vue-ui-heatmap"
599
- });
600
- });
601
- }
602
- const ke = T(() => {
603
- const t = [
604
- e.value.table.translations.series,
605
- e.value.table.translations.correlationCoefficient,
606
- e.value.table.translations.nbrPlots,
607
- `${e.value.style.layout.dataLabels.xAxis.name} ${e.value.table.translations.average}`,
608
- `${e.value.style.layout.dataLabels.yAxis.name} ${e.value.table.translations.average}`
609
- ], a = U.value.map((o) => [
610
- {
611
- shape: o.shape,
612
- content: o.name,
613
- color: o.color
614
- },
615
- Number(
616
- (o.correlation.coefficient ?? 0).toFixed(
617
- e.value.table.td.roundingValue
618
- )
619
- ).toLocaleString(),
620
- o.plots.length.toLocaleString(),
621
- Number(
622
- (o.plots.map((n) => n.v.x ?? 0).reduce((n, i) => n + i, 0) / o.plots.length).toFixed(e.value.table.td.roundingAverage)
623
- ).toLocaleString(),
624
- Number(
625
- (o.plots.map((n) => n.v.y ?? 0).reduce((n, i) => n + i, 0) / o.plots.length).toFixed(e.value.table.td.roundingAverage)
626
- ).toLocaleString()
627
- ]), l = a.map((o) => o.map((n, i) => i === 0 ? n.content : n)), s = {
628
- th: {
629
- backgroundColor: e.value.table.th.backgroundColor,
630
- color: e.value.table.th.color,
631
- outline: e.value.table.th.outline
632
- },
633
- td: {
634
- backgroundColor: e.value.table.td.backgroundColor,
635
- color: e.value.table.td.color,
636
- outline: e.value.table.td.outline
637
- },
638
- breakpoint: e.value.table.responsiveBreakpoint
639
- };
640
- return { head: t, body: a, a11yBody: l, config: s, colNames: t };
641
- }), fe = w(!1);
642
- function Nt(t) {
643
- fe.value = t, mt.value += 1;
644
- }
645
- function Ft() {
646
- K.value.showTable = !K.value.showTable;
647
- }
648
- function Wt() {
649
- K.value.showTooltip = !K.value.showTooltip;
650
- }
651
- const Le = w(!1);
652
- function ut() {
653
- Le.value = !Le.value;
654
- }
655
- async function Al({ scale: t = 2 } = {}) {
656
- if (!ne.value) return;
657
- const { width: a, height: l } = ne.value.getBoundingClientRect(), s = a / l, { imageUri: o, base64: n } = await ba({
658
- domElement: ne.value,
659
- base64: !0,
660
- img: !0,
661
- scale: t
662
- });
663
- return {
664
- imageUri: o,
665
- base64: n,
666
- title: e.value.style.title.text,
667
- width: a,
668
- height: l,
669
- aspectRatio: s
670
- };
671
- }
672
- function Sl(t) {
673
- _e.value = t, e.value.style.layout.marginalBars.highlighter.highlightBothAxes && (Ce.value = S.value.y.length - 2 - t);
674
- }
675
- function Tl(t) {
676
- Ce.value = t, e.value.style.layout.marginalBars.highlighter.highlightBothAxes && (_e.value = t);
677
- }
678
- function it() {
679
- _e.value = null, Ce.value = null;
680
- }
681
- const Xt = {
682
- circle: 1,
683
- square: 1,
684
- diamond: 1,
685
- triangle: 1.2,
686
- star: 1.3,
687
- pentagon: 1.3,
688
- hexagon: 1.3
689
- }, M = (t) => t.toFixed(3);
690
- function Ll({ shape: t = "circle", cx: a, cy: l, r: s }) {
691
- if (!e.value.usePerformanceMode) return "";
692
- const o = Xt[t] * s;
693
- switch (t) {
694
- case "circle": {
695
- const n = M(a - o), i = M(l), y = M(a + o), r = M(o);
696
- return `M ${n} ${i} A ${r} ${r} 0 1 0 ${y} ${i} A ${r} ${r} 0 1 0 ${n} ${i} Z`;
697
- }
698
- case "square": {
699
- const n = M(a - o), i = M(l - o), y = M(a + o), r = M(l + o);
700
- return `M ${n} ${i} L ${y} ${i} L ${y} ${r} L ${n} ${r} Z`;
701
- }
702
- case "diamond": {
703
- const n = M(a), i = M(l);
704
- return `M ${n} ${M(l - o)} L ${M(a + o)} ${i} L ${n} ${M(l + o)} L ${M(a - o)} ${i} Z`;
705
- }
706
- case "triangle": {
707
- const n = o * Math.sqrt(3), i = a, y = l - 2 / 3 * n, r = a - o, f = l + 1 / 3 * n, A = a + o, d = f;
708
- return `M ${M(i)} ${M(y)} L ${M(r)} ${M(f)} L ${M(A)} ${M(d)} Z`;
709
- }
710
- case "star": {
711
- const n = o, i = o * 0.5, y = [];
712
- for (let f = 0; f < 10; f += 1) {
713
- const A = (-90 + f * 36) * Math.PI / 180, d = f % 2 === 0 ? n : i;
714
- y.push([a + d * Math.cos(A), l + d * Math.sin(A)]);
715
- }
716
- let r = `M ${M(y[0][0])} ${M(y[0][1])}`;
717
- for (let f = 1; f < y.length; f += 1)
718
- r += ` L ${M(y[f][0])} ${M(y[f][1])}`;
719
- return r + " Z";
720
- }
721
- case "pentagon": {
722
- const i = [];
723
- for (let r = 0; r < 5; r += 1) {
724
- const f = (-90 + r * 72) * Math.PI / 180;
725
- i.push([
726
- a + o * Math.cos(f),
727
- l + o * Math.sin(f)
728
- ]);
729
- }
730
- let y = `M ${M(i[0][0])} ${M(i[0][1])}`;
731
- for (let r = 1; r < 5; r += 1)
732
- y += ` L ${M(i[r][0])} ${M(i[r][1])}`;
733
- return y + " Z";
734
- }
735
- case "hexagon": {
736
- const i = [];
737
- for (let r = 0; r < 6; r += 1) {
738
- const f = (-60 + r * 60) * Math.PI / 180;
739
- i.push([
740
- a + o * Math.cos(f),
741
- l + o * Math.sin(f)
742
- ]);
743
- }
744
- let y = `M ${M(i[0][0])} ${M(i[0][1])}`;
745
- for (let r = 1; r < 6; r += 1)
746
- y += ` L ${M(i[r][0])} ${M(i[r][1])}`;
747
- return y + " Z";
748
- }
749
- default: {
750
- const n = M(a - o), i = M(l), y = M(a + o), r = M(o);
751
- return `M ${n} ${i} A ${r} ${r} 0 1 0 ${y} ${i} A ${r} ${r} 0 1 0 ${n} ${i} Z`;
752
- }
753
- }
754
- }
755
- const Pl = T(() => {
756
- if (!e.value.usePerformanceMode) return [""];
757
- const { left: t, right: a, top: l, bottom: s } = u.value, o = Math.max(1, (a - t) * (s - l)), n = (d) => d / o * 1e4, i = 2.5, y = 1e3, r = e.value.style.layout.plots.stroke, f = e.value.style.layout.plots.strokeWidth, A = e.value.style.layout.plots.opacity;
758
- return U.value.map((d) => {
759
- const x = [];
760
- for (const _ of d.plots) {
761
- const O = _.x, D = _.y;
762
- if (O < t || O > a || D < l || D > s) continue;
763
- const L = Math.max(
764
- e.value.style.layout.plots.radius,
765
- _.weight
766
- );
767
- x.push(
768
- Ll({
769
- shape: d.shape || "circle",
770
- cx: O,
771
- cy: D,
772
- r: L
773
- })
774
- );
775
- }
776
- if (!x.length) return null;
777
- const E = n(d.plots.length) > i || d.plots.length > y;
778
- return {
779
- id: d.id,
780
- d: x.join(""),
781
- fill: Ge(d.color, A * 100),
782
- stroke: E ? "none" : r,
783
- strokeWidth: E ? 0 : f,
784
- strokeOpacity: 1
785
- };
786
- }).filter(Boolean);
787
- });
788
- function Bl() {
789
- return e.value.usePerformanceMode ? (t) => {
790
- const a = ie.value;
791
- if (!a) return;
792
- const l = a.createSVGPoint();
793
- l.x = t.clientX, l.y = t.clientY;
794
- const s = a.getScreenCTM();
795
- if (!s) return;
796
- const o = s.inverse(), n = l.matrixTransform(o), i = 8, y = i * i;
797
- let r = null, f = 1 / 0, A = -1;
798
- if (U.value.forEach((d, x) => {
799
- d.plots.forEach((E) => {
800
- const _ = E.x - n.x, O = E.y - n.y, D = _ * _ + O * O;
801
- D <= y && D < f && (f = D, r = E, A = x);
802
- });
803
- }), r)
804
- R.value !== r.id && (R.value = r.id, he(
805
- r,
806
- A,
807
- "pointer",
808
- ve.value.get(r.id) ?? null
809
- ));
810
- else if (R.value) {
811
- const d = g.value;
812
- R.value = void 0, Ye(d, A);
813
- }
814
- } : () => null;
815
- }
816
- const Yt = Bl();
817
- function zl() {
818
- if (R.value) {
819
- const t = g.value;
820
- R.value = void 0, Ye(t, null);
821
- }
822
- }
823
- function Il(t) {
824
- const a = g.value;
825
- if (a) {
826
- const l = U.value.findIndex(
827
- (s) => s.id === a.clusterId
828
- );
829
- Re(a, l >= 0 ? l : 0);
830
- }
831
- }
832
- const Pe = T(() => {
833
- const t = e.value.table.useDialog && !e.value.table.show, a = K.value.showTable;
834
- return {
835
- component: t ? vl : sl,
836
- title: `${e.value.style.title.text}${e.value.style.title.subtitle.text ? `: ${e.value.style.title.subtitle.text}` : ""}`,
837
- props: t ? {
838
- backgroundColor: e.value.table.th.backgroundColor,
839
- color: e.value.table.th.color,
840
- headerColor: e.value.table.th.color,
841
- headerBg: e.value.table.th.backgroundColor,
842
- isFullscreen: fe.value,
843
- fullscreenParent: ne.value,
844
- forcedWidth: Math.min(800, window.innerWidth * 0.8),
845
- isCursorPointer: de.value
846
- } : {
847
- hideDetails: !0,
848
- config: {
849
- open: a,
850
- maxHeight: 1e4,
851
- body: {
852
- backgroundColor: e.value.style.backgroundColor,
853
- color: e.value.style.color
854
- },
855
- head: {
856
- backgroundColor: e.value.style.backgroundColor,
857
- color: e.value.style.color
858
- }
859
- }
860
- }
861
- };
862
- });
863
- je(
864
- () => K.value.showTable,
865
- (t) => {
866
- e.value.table.show || (t && e.value.table.useDialog && Ae.value ? Ae.value.open() : "close" in Ae.value && Ae.value.close());
867
- }
868
- );
869
- function Rt() {
870
- K.value.showTable = !1, He.value && He.value.setTableIconState(!1);
871
- }
872
- const Ol = T(() => e.value.style.backgroundColor), Dl = T(() => e.value.style.legend), El = T(() => e.value.style.title), { exportSvg: Nl, getSvg: Fl } = pa({
873
- svg: ie,
874
- title: El,
875
- legend: Dl,
876
- legendItems: J,
877
- backgroundColor: Ol
878
- });
879
- async function Vt({ isCb: t }) {
880
- Ne.value = !0, await yt();
881
- try {
882
- if (t) {
883
- const { blob: a, url: l, text: s, dataUrl: o } = await Fl();
884
- await Promise.resolve(
885
- e.value.userOptions.callbacks.svg({
886
- blob: a,
887
- url: l,
888
- text: s,
889
- dataUrl: o
890
- })
891
- );
892
- } else
893
- await Promise.resolve(Nl());
894
- } finally {
895
- Ne.value = !1;
896
- }
897
- }
898
- function Wl(t) {
899
- if (t?.stage === "start") {
900
- Ee.value = !0;
901
- return;
902
- }
903
- if (t?.stage === "end") {
904
- Ee.value = !1;
905
- return;
906
- }
907
- zt();
908
- }
909
- async function Ut() {
910
- if (hl("copyAlt", {
911
- config: e.value,
912
- dataset: be.value
913
- }), !e.value.userOptions.callbacks.altCopy) {
914
- console.warn(
915
- "Vue Data UI - A callback must be set for `altCopy` in userOptions."
916
- );
917
- return;
918
- }
919
- await Promise.resolve(
920
- e.value.userOptions.callbacks.altCopy({
921
- config: e.value,
922
- dataset: be.value
923
- })
924
- );
925
- }
926
- function jt(t, a) {
927
- const l = we.value.filter((n) => n.id === t.id ? !1 : a === "right" ? n.x > t.x : a === "left" ? n.x < t.x : a === "down" ? n.y > t.y : a === "up" ? n.y < t.y : !1);
928
- if (!l.length) return null;
929
- let s = null, o = 1 / 0;
930
- return l.forEach((n) => {
931
- const i = n.x - t.x, y = n.y - t.y;
932
- let r = 0, f = 0;
933
- a === "right" || a === "left" ? (r = Math.abs(i), f = Math.abs(y)) : (r = Math.abs(y), f = Math.abs(i));
934
- const A = r * 1e3 + f;
935
- A < o && (s = n, o = A);
936
- }), s;
937
- }
938
- function Xl() {
939
- Te.value = null, me.value = null, Fe.value = !0;
940
- }
941
- function Yl() {
942
- st(), Se.value = "pointer", Fe.value = !1;
943
- }
944
- function Rl(t) {
945
- if (!ie.value || Le.value || document.activeElement !== ie.value || !we.value.length) return;
946
- const a = t.key === "ArrowLeft", l = t.key === "ArrowRight", s = t.key === "ArrowUp", o = t.key === "ArrowDown", n = t.key === "Enter" || t.key === " ", i = t.key === "Escape";
947
- if (!a && !l && !s && !o && !n && !i)
948
- return;
949
- if (t.preventDefault(), t.stopPropagation(), i) {
950
- st(), Se.value = "pointer";
951
- return;
952
- }
953
- if (n) {
954
- if (Te.value === null) return;
955
- const x = we.value[Te.value];
956
- if (!x) return;
957
- Re(x, x.seriesIndex);
958
- return;
959
- }
960
- let y = null;
961
- if (l && (y = "right"), a && (y = "left"), o && (y = "down"), s && (y = "up"), me.value === null) {
962
- const x = g.value;
963
- if (x && x.id) {
964
- const D = jt(x, y);
965
- if (!D) {
966
- const C = ve.value.get(x.id);
967
- if (C === void 0) return;
968
- he(
969
- x,
970
- x.seriesIndex,
971
- "keyboard",
972
- C
973
- );
974
- return;
975
- }
976
- const L = ve.value.get(D.id);
977
- if (L === void 0) return;
978
- he(D, D.seriesIndex, "keyboard", L);
979
- return;
980
- }
981
- const _ = we.value[0];
982
- if (!_) return;
983
- const O = ve.value.get(_.id) ?? 0;
984
- he(_, _.seriesIndex, "keyboard", O);
985
- return;
986
- }
987
- const r = ve.value.get(me.value);
988
- if (r === void 0) return;
989
- const f = we.value[r];
990
- if (!f) return;
991
- const A = jt(f, y);
992
- if (!A) return;
993
- const d = ve.value.get(A.id);
994
- d !== void 0 && he(A, A.seriesIndex, "keyboard", d);
995
- }
996
- const Vl = T(() => {
997
- if (!g.value)
998
- return "";
999
- const t = g.value, a = isNaN(t.v.x) ? "-" : se(
1000
- e.value.style.layout.plots.selectors.labels.x.formatter,
1001
- t.v.x,
1002
- ee({
1003
- p: e.value.style.tooltip.prefix,
1004
- v: t.v.x,
1005
- s: e.value.style.tooltip.suffix,
1006
- r: e.value.style.tooltip.roundingValue
1007
- }),
1008
- { datapoint: t, seriesIndex: t.seriesIndex }
1009
- ), l = isNaN(t.v.y) ? "-" : se(
1010
- e.value.style.layout.plots.selectors.labels.y.formatter,
1011
- t.v.y,
1012
- ee({
1013
- p: e.value.style.tooltip.prefix,
1014
- v: t.v.y,
1015
- s: e.value.style.tooltip.suffix,
1016
- r: e.value.style.tooltip.roundingValue
1017
- }),
1018
- { datapoint: t, seriesIndex: t.seriesIndex }
1019
- );
1020
- return [
1021
- t.clusterName || "",
1022
- t.v.name || "",
1023
- `${e.value.style.layout.dataLabels.xAxis.name}: ${a}`,
1024
- `${e.value.style.layout.dataLabels.yAxis.name}: ${l}`
1025
- ].filter(Boolean).join(". ");
1026
- }), we = T(() => U.value.flatMap((t, a) => t.plots.map((l) => ({
1027
- ...l,
1028
- seriesIndex: a,
1029
- seriesId: t.id,
1030
- seriesName: t.name,
1031
- shape: t.shape || "circle",
1032
- color: t.color
1033
- })))), ve = T(() => {
1034
- const t = /* @__PURE__ */ new Map();
1035
- return we.value.forEach((a, l) => {
1036
- t.set(a.id, l);
1037
- }), t;
1038
- }), rt = T(() => {
1039
- const t = ke.value?.colNames ?? [], a = ke.value?.a11yBody ?? [];
1040
- return { headers: t, rows: a };
1041
- });
1042
- return tl({
1043
- getData: kl,
1044
- getImage: Al,
1045
- generatePdf: Bt,
1046
- generateCsv: nt,
1047
- generateImage: zt,
1048
- generateSvg: Vt,
1049
- hideSeries: Cl,
1050
- showSeries: _l,
1051
- toggleTable: Ft,
1052
- toggleTooltip: Wt,
1053
- toggleAnnotator: ut,
1054
- toggleFullscreen: Nt,
1055
- copyAlt: Ut
1056
- }), (t, a) => (v(), c("div", {
1057
- class: qt(`vue-data-ui-component vue-ui-scatter ${fe.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
1058
- ref_key: "scatterChart",
1059
- ref: ne,
1060
- id: `vue-ui-scatter_${N.value}`,
1061
- style: ue(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;background:${e.value.style.backgroundColor};${e.value.responsive ? "height: 100%" : ""}`),
1062
- onMouseenter: a[5] || (a[5] = () => h(St)(!0)),
1063
- onMouseleave: a[6] || (a[6] = () => {
1064
- h(St)(!1), Fe.value || st();
1065
- })
1066
- }, [
1067
- k("div", {
1068
- id: `chart-instructions-${N.value}`,
1069
- class: "sr-only"
1070
- }, [
1071
- k("p", null, V(e.value.a11y.translations.keyboardNavigation), 1)
1072
- ], 8, Sa),
1073
- K.value.showTooltip ? m("", !0) : (v(), c("div", Ta, V(Vl.value), 1)),
1074
- rt.value?.rows?.length ? (v(), ae(Ma, {
1075
- key: 1,
1076
- uid: N.value,
1077
- head: rt.value.headers,
1078
- body: rt.value.rows,
1079
- notice: e.value.a11y.translations.tableAvailable,
1080
- caption: e.value.a11y.translations.tableCaption
1081
- }, null, 8, ["uid", "head", "body", "notice", "caption"])) : m("", !0),
1082
- e.value.userOptions.buttons.annotator ? (v(), ae(h(ul), {
1083
- key: 2,
1084
- svgRef: h(ie),
1085
- backgroundColor: e.value.style.backgroundColor,
1086
- color: e.value.style.color,
1087
- active: Le.value,
1088
- isCursorPointer: de.value,
1089
- onClose: ut
1090
- }, {
1091
- "annotator-action-close": P(() => [
1092
- z(t.$slots, "annotator-action-close", {}, void 0, !0)
1093
- ]),
1094
- "annotator-action-color": P(({ color: l }) => [
1095
- z(t.$slots, "annotator-action-color", q(H({ color: l })), void 0, !0)
1096
- ]),
1097
- "annotator-action-draw": P(({ mode: l }) => [
1098
- z(t.$slots, "annotator-action-draw", q(H({ mode: l })), void 0, !0)
1099
- ]),
1100
- "annotator-action-undo": P(({ disabled: l }) => [
1101
- z(t.$slots, "annotator-action-undo", q(H({ disabled: l })), void 0, !0)
1102
- ]),
1103
- "annotator-action-redo": P(({ disabled: l }) => [
1104
- z(t.$slots, "annotator-action-redo", q(H({ disabled: l })), void 0, !0)
1105
- ]),
1106
- "annotator-action-delete": P(({ disabled: l }) => [
1107
- z(t.$slots, "annotator-action-delete", q(H({ disabled: l })), void 0, !0)
1108
- ]),
1109
- _: 3
1110
- }, 8, ["svgRef", "backgroundColor", "color", "active", "isCursorPointer"])) : m("", !0),
1111
- xl.value ? (v(), c("div", {
1112
- key: 3,
1113
- ref_key: "noTitle",
1114
- ref: wt,
1115
- class: "vue-data-ui-no-title-space",
1116
- style: "height:36px; width: 100%;background:transparent"
1117
- }, null, 512)) : m("", !0),
1118
- e.value.style.title.text ? (v(), c("div", {
1119
- key: 4,
1120
- ref_key: "chartTitle",
1121
- ref: xt,
1122
- style: "width:100%;background:transparent"
1123
- }, [
1124
- (v(), ae(ka, {
1125
- key: `title_${$t.value}`,
1126
- config: {
1127
- title: {
1128
- cy: "scatter-div-title",
1129
- ...e.value.style.title
1130
- },
1131
- subtitle: {
1132
- cy: "scatter-div-subtitle",
1133
- ...e.value.style.title.subtitle
1134
- }
1135
- }
1136
- }, null, 8, ["config"]))
1137
- ], 512)) : m("", !0),
1138
- k("div", {
1139
- id: `legend-top-${N.value}`
1140
- }, null, 8, La),
1141
- e.value.userOptions.show && gt.value && (h(Tt) || h(tt)) ? (v(), ae(h(il), {
1142
- ref_key: "userOptionsRef",
1143
- ref: He,
1144
- key: `user_options_${mt.value}`,
1145
- backgroundColor: e.value.style.backgroundColor,
1146
- color: e.value.style.color,
1147
- isImaging: h(ot),
1148
- isPrinting: h(at),
1149
- uid: N.value,
1150
- hasTooltip: e.value.userOptions.buttons.tooltip && e.value.style.tooltip.show,
1151
- hasPdf: e.value.userOptions.buttons.pdf,
1152
- hasImg: e.value.userOptions.buttons.img,
1153
- hasSvg: e.value.userOptions.buttons.svg,
1154
- hasXls: e.value.userOptions.buttons.csv,
1155
- hasTable: e.value.userOptions.buttons.table,
1156
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
1157
- hasAltCopy: e.value.userOptions.buttons.altCopy,
1158
- isTooltip: K.value.showTooltip,
1159
- isFullscreen: fe.value,
1160
- titles: { ...e.value.userOptions.buttonTitles },
1161
- chartElement: ne.value,
1162
- position: e.value.userOptions.position,
1163
- hasAnnotator: e.value.userOptions.buttons.annotator,
1164
- isAnnotation: Le.value,
1165
- callbacks: e.value.userOptions.callbacks,
1166
- printScale: e.value.userOptions.print.scale,
1167
- tableDialog: e.value.table.useDialog,
1168
- isCursorPointer: de.value,
1169
- onToggleFullscreen: Nt,
1170
- onGeneratePdf: h(Bt),
1171
- onGenerateCsv: nt,
1172
- onGenerateImage: Wl,
1173
- onGenerateSvg: Vt,
1174
- onToggleTable: Ft,
1175
- onToggleTooltip: Wt,
1176
- onToggleAnnotator: ut,
1177
- onCopyAlt: Ut,
1178
- style: ue({
1179
- visibility: h(Tt) ? h(tt) ? "visible" : "hidden" : "visible"
1180
- })
1181
- }, Ht({ _: 2 }, [
1182
- t.$slots.menuIcon ? {
1183
- name: "menuIcon",
1184
- fn: P(({ isOpen: l, color: s }) => [
1185
- z(t.$slots, "menuIcon", q(H({ isOpen: l, color: s })), void 0, !0)
1186
- ]),
1187
- key: "0"
1188
- } : void 0,
1189
- t.$slots.optionTooltip ? {
1190
- name: "optionTooltip",
1191
- fn: P(() => [
1192
- z(t.$slots, "optionTooltip", {}, void 0, !0)
1193
- ]),
1194
- key: "1"
1195
- } : void 0,
1196
- t.$slots.optionPdf ? {
1197
- name: "optionPdf",
1198
- fn: P(() => [
1199
- z(t.$slots, "optionPdf", {}, void 0, !0)
1200
- ]),
1201
- key: "2"
1202
- } : void 0,
1203
- t.$slots.optionCsv ? {
1204
- name: "optionCsv",
1205
- fn: P(() => [
1206
- z(t.$slots, "optionCsv", {}, void 0, !0)
1207
- ]),
1208
- key: "3"
1209
- } : void 0,
1210
- t.$slots.optionImg ? {
1211
- name: "optionImg",
1212
- fn: P(() => [
1213
- z(t.$slots, "optionImg", {}, void 0, !0)
1214
- ]),
1215
- key: "4"
1216
- } : void 0,
1217
- t.$slots.optionSvg ? {
1218
- name: "optionSvg",
1219
- fn: P(() => [
1220
- z(t.$slots, "optionSvg", {}, void 0, !0)
1221
- ]),
1222
- key: "5"
1223
- } : void 0,
1224
- t.$slots.optionTable ? {
1225
- name: "optionTable",
1226
- fn: P(() => [
1227
- z(t.$slots, "optionTable", {}, void 0, !0)
1228
- ]),
1229
- key: "6"
1230
- } : void 0,
1231
- t.$slots.optionFullscreen ? {
1232
- name: "optionFullscreen",
1233
- fn: P(({ toggleFullscreen: l, isFullscreen: s }) => [
1234
- z(t.$slots, "optionFullscreen", q(H({ toggleFullscreen: l, isFullscreen: s })), void 0, !0)
1235
- ]),
1236
- key: "7"
1237
- } : void 0,
1238
- t.$slots.optionAnnotator ? {
1239
- name: "optionAnnotator",
1240
- fn: P(({ toggleAnnotator: l, isAnnotator: s }) => [
1241
- z(t.$slots, "optionAnnotator", q(H({ toggleAnnotator: l, isAnnotator: s })), void 0, !0)
1242
- ]),
1243
- key: "8"
1244
- } : void 0,
1245
- t.$slots.optionAltCopy ? {
1246
- name: "optionAltCopy",
1247
- fn: P(({ altCopy: l }) => [
1248
- z(t.$slots, "optionAltCopy", q(H({ altCopy: l })), void 0, !0)
1249
- ]),
1250
- key: "9"
1251
- } : void 0
1252
- ]), 1032, ["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"])) : m("", !0),
1253
- k("div", Pa, [
1254
- (v(), c("svg", {
1255
- ref_key: "svgRef",
1256
- ref: ie,
1257
- xmlns: h(aa),
1258
- "aria-describedby": `chart-instructions-${N.value}`,
1259
- class: qt({
1260
- "vue-data-ui-fullscreen--on": fe.value,
1261
- "vue-data-ui-fulscreen--off": !fe.value,
1262
- animated: e.value.useCssAnimation
1263
- }),
1264
- viewBox: `0 0 ${Y.value.width <= 0 ? 10 : Y.value.width} ${Y.value.height <= 0 ? 10 : Y.value.height}`,
1265
- style: ue(`max-width:100%;overflow:visible;background:transparent;color:${e.value.style.color}`),
1266
- onMouseleave: it,
1267
- tabindex: "0",
1268
- onFocus: Xl,
1269
- onBlur: Yl,
1270
- onKeydown: Rl
1271
- }, [
1272
- Oe(h(rl)),
1273
- t.$slots["chart-background"] ? (v(), c("foreignObject", {
1274
- key: 0,
1275
- x: 0,
1276
- y: 0,
1277
- width: Y.value.width <= 0 ? 10 : Y.value.width,
1278
- height: Y.value.height <= 0 ? 10 : Y.value.height,
1279
- style: {
1280
- pointerEvents: "none"
1281
- }
1282
- }, [
1283
- z(t.$slots, "chart-background", {}, void 0, !0)
1284
- ], 8, za)) : m("", !0),
1285
- e.value.style.layout.axis.show ? (v(), c("g", Ia, [
1286
- k("line", {
1287
- x1: W.value.x,
1288
- x2: W.value.x,
1289
- y1: u.value.top,
1290
- y2: u.value.bottom,
1291
- stroke: e.value.style.layout.axis.stroke,
1292
- "stroke-width": e.value.style.layout.axis.strokeWidth,
1293
- "stroke-linecap": "round"
1294
- }, null, 8, Oa),
1295
- k("line", {
1296
- x1: u.value.left,
1297
- x2: u.value.right,
1298
- y1: W.value.y,
1299
- y2: W.value.y,
1300
- stroke: e.value.style.layout.axis.stroke,
1301
- "stroke-width": e.value.style.layout.axis.strokeWidth,
1302
- "stroke-linecap": "round"
1303
- }, null, 8, Da)
1304
- ])) : m("", !0),
1305
- e.value.style.layout.marginalBars.show ? (v(), c("g", Ea, [
1306
- k("defs", null, [
1307
- k("linearGradient", {
1308
- id: `marginal_x_${N.value}`,
1309
- x1: "0%",
1310
- y1: "0%",
1311
- x2: "0%",
1312
- y2: "100%"
1313
- }, [
1314
- k("stop", {
1315
- offset: "0%",
1316
- "stop-color": e.value.style.layout.marginalBars.fill
1317
- }, null, 8, Fa),
1318
- k("stop", {
1319
- offset: "100%",
1320
- "stop-color": e.value.style.backgroundColor
1321
- }, null, 8, Wa)
1322
- ], 8, Na),
1323
- k("linearGradient", {
1324
- id: `marginal_y_${N.value}`,
1325
- x1: "0%",
1326
- x2: "100%",
1327
- y1: "0%",
1328
- y2: "0%"
1329
- }, [
1330
- k("stop", {
1331
- offset: "0%",
1332
- "stop-color": e.value.style.backgroundColor
1333
- }, null, 8, Ya),
1334
- k("stop", {
1335
- offset: "100%",
1336
- "stop-color": e.value.style.layout.marginalBars.fill
1337
- }, null, 8, Ra)
1338
- ], 8, Xa)
1339
- ]),
1340
- (v(!0), c(Q, null, oe(S.value.x, (l, s) => (v(), c("g", null, [
1341
- l && S.value.avgX[s] ? (v(), c("rect", {
1342
- key: 0,
1343
- x: S.value.avgX[s] - u.value.width / $.value / 2,
1344
- y: u.value.top - e.value.style.layout.marginalBars.offset - l / S.value.maxX * e.value.style.layout.marginalBars.size,
1345
- width: u.value.width / $.value <= 0 ? 1e-4 : u.value.width / $.value,
1346
- height: l / S.value.maxX * e.value.style.layout.marginalBars.size <= 0 ? 1e-4 : l / S.value.maxX * e.value.style.layout.marginalBars.size,
1347
- fill: e.value.style.layout.marginalBars.useGradient ? `url(#marginal_x_${N.value})` : e.value.style.layout.marginalBars.fill,
1348
- style: ue([`opacity:${e.value.style.layout.marginalBars.opacity}`, { "pointer-events": "none" }]),
1349
- stroke: e.value.style.backgroundColor,
1350
- "stroke-width": e.value.style.layout.marginalBars.strokeWidth,
1351
- rx: e.value.style.layout.marginalBars.borderRadius
1352
- }, null, 12, Va)) : m("", !0),
1353
- S.value.avgX[s] ? (v(), c("rect", {
1354
- key: 1,
1355
- x: S.value.avgX[s] - u.value.width / $.value / 2,
1356
- y: u.value.top - e.value.style.layout.marginalBars.offset - e.value.style.layout.marginalBars.size,
1357
- width: u.value.width / $.value <= 0 ? 1e-4 : u.value.width / $.value,
1358
- height: Math.max(
1359
- 0.1,
1360
- e.value.style.layout.marginalBars.size
1361
- ),
1362
- fill: "transparent",
1363
- onMouseenter: (o) => Sl(s),
1364
- onMouseleave: a[0] || (a[0] = (o) => it())
1365
- }, null, 40, Ua)) : m("", !0),
1366
- S.value.avgX[s] && _e.value != null && _e.value === s ? (v(), c("g", ja, [
1367
- k("rect", {
1368
- x: S.value.avgX[s] - u.value.width / $.value / 2,
1369
- y: u.value.top,
1370
- width: u.value.width / $.value <= 0 ? 1e-4 : u.value.width / $.value,
1371
- height: u.value.height,
1372
- fill: e.value.style.layout.marginalBars.highlighter.color,
1373
- "fill-opacity": e.value.style.layout.marginalBars.highlighter.opacity
1374
- }, null, 8, Ga),
1375
- k("line", {
1376
- x1: S.value.avgX[s] - u.value.width / $.value / 2,
1377
- x2: S.value.avgX[s] - u.value.width / $.value / 2,
1378
- y1: 0,
1379
- y2: u.value.top + u.value.height,
1380
- stroke: e.value.style.layout.marginalBars.highlighter.stroke,
1381
- "stroke-dasharray": e.value.style.layout.marginalBars.highlighter.strokeDasharray,
1382
- "stroke-width": e.value.style.layout.marginalBars.highlighter.strokeWidth,
1383
- style: {
1384
- transition: "none !important",
1385
- animation: "none !important"
1386
- }
1387
- }, null, 8, qa),
1388
- k("line", {
1389
- x1: S.value.avgX[s] - u.value.width / $.value / 2 + (u.value.width / $.value <= 0 ? 1e-4 : u.value.width / $.value),
1390
- x2: S.value.avgX[s] - u.value.width / $.value / 2 + (u.value.width / $.value <= 0 ? 1e-4 : u.value.width / $.value),
1391
- y1: 0,
1392
- y2: u.value.top + u.value.height,
1393
- stroke: e.value.style.layout.marginalBars.highlighter.stroke,
1394
- "stroke-dasharray": e.value.style.layout.marginalBars.highlighter.strokeDasharray,
1395
- "stroke-width": e.value.style.layout.marginalBars.highlighter.strokeWidth,
1396
- style: {
1397
- transition: "none !important",
1398
- animation: "none !important"
1399
- }
1400
- }, null, 8, Ha)
1401
- ])) : m("", !0)
1402
- ]))), 256)),
1403
- (v(!0), c(Q, null, oe(S.value.y, (l, s) => (v(), c("g", null, [
1404
- l && S.value.avgY[s] ? (v(), c("rect", {
1405
- key: 0,
1406
- x: u.value.right + e.value.style.layout.marginalBars.offset,
1407
- y: S.value.avgY[s] - u.value.height / $.value / 2,
1408
- height: u.value.height / $.value <= 0 ? 1e-4 : u.value.height / $.value,
1409
- width: l / S.value.maxY * e.value.style.layout.marginalBars.size <= 0 ? 1e-4 : l / S.value.maxY * e.value.style.layout.marginalBars.size,
1410
- fill: e.value.style.layout.marginalBars.useGradient ? `url(#marginal_y_${N.value})` : e.value.style.layout.marginalBars.fill,
1411
- style: ue([`opacity:${e.value.style.layout.marginalBars.opacity}`, { "pointer-events": "none" }]),
1412
- stroke: e.value.style.backgroundColor,
1413
- "stroke-width": e.value.style.layout.marginalBars.strokeWidth,
1414
- rx: e.value.style.layout.marginalBars.borderRadius
1415
- }, null, 12, Ka)) : m("", !0),
1416
- S.value.avgY[s] ? (v(), c("rect", {
1417
- key: 1,
1418
- x: u.value.right + e.value.style.layout.marginalBars.offset,
1419
- y: S.value.avgY[s] - u.value.height / $.value / 2,
1420
- width: Math.max(
1421
- 0.1,
1422
- e.value.style.layout.marginalBars.size
1423
- ),
1424
- height: u.value.height / $.value <= 0 ? 1e-4 : u.value.height / $.value,
1425
- fill: "transparent",
1426
- onMouseenter: (o) => Tl(s),
1427
- onMouseleave: a[1] || (a[1] = (o) => it())
1428
- }, null, 40, Za)) : m("", !0),
1429
- S.value.avgY[s] && Ce.value != null && Ce.value === s ? (v(), c("g", Ja, [
1430
- k("rect", {
1431
- x: u.value.left,
1432
- y: S.value.avgY[s] - u.value.height / $.value / 2,
1433
- width: u.value.width,
1434
- height: u.value.height / $.value <= 0 ? 1e-4 : u.value.height / $.value,
1435
- fill: e.value.style.layout.marginalBars.highlighter.color,
1436
- "fill-opacity": e.value.style.layout.marginalBars.highlighter.opacity
1437
- }, null, 8, Qa),
1438
- k("line", {
1439
- x1: u.value.left,
1440
- x2: Y.value.width,
1441
- y1: S.value.avgY[s] - u.value.height / $.value / 2,
1442
- y2: S.value.avgY[s] - u.value.height / $.value / 2,
1443
- stroke: e.value.style.layout.marginalBars.highlighter.stroke,
1444
- "stroke-dasharray": e.value.style.layout.marginalBars.highlighter.strokeDasharray,
1445
- "stroke-width": e.value.style.layout.marginalBars.highlighter.strokeWidth,
1446
- style: {
1447
- transition: "none !important",
1448
- animation: "none !important"
1449
- }
1450
- }, null, 8, eo),
1451
- k("line", {
1452
- x1: u.value.left,
1453
- x2: Y.value.width,
1454
- y1: S.value.avgY[s] - u.value.height / $.value / 2 + (u.value.height / $.value <= 0 ? 1e-4 : u.value.height / $.value),
1455
- y2: S.value.avgY[s] - u.value.height / $.value / 2 + (u.value.height / $.value <= 0 ? 1e-4 : u.value.height / $.value),
1456
- stroke: e.value.style.layout.marginalBars.highlighter.stroke,
1457
- "stroke-dasharray": e.value.style.layout.marginalBars.highlighter.strokeDasharray,
1458
- "stroke-width": e.value.style.layout.marginalBars.highlighter.strokeWidth,
1459
- style: {
1460
- transition: "none !important",
1461
- animation: "none !important"
1462
- }
1463
- }, null, 8, to)
1464
- ])) : m("", !0)
1465
- ]))), 256)),
1466
- e.value.style.layout.marginalBars.showLines ? (v(), c("g", lo, [
1467
- (v(!0), c(Q, null, oe(wl.value, (l) => (v(), c(Q, null, [
1468
- I.value.includes(l.id) ? m("", !0) : (v(), c("path", {
1469
- key: 0,
1470
- d: `M ${l.dX}`,
1471
- stroke: e.value.style.backgroundColor,
1472
- "stroke-width": e.value.style.layout.marginalBars.linesStrokeWidth + 1,
1473
- "stroke-linecap": "round",
1474
- "stroke-linejoin": "round",
1475
- fill: "none"
1476
- }, null, 8, ao)),
1477
- I.value.includes(l.id) ? m("", !0) : (v(), c("path", {
1478
- key: 1,
1479
- d: `M ${l.dX}`,
1480
- stroke: l.color,
1481
- "stroke-width": e.value.style.layout.marginalBars.linesStrokeWidth,
1482
- "stroke-linecap": "round",
1483
- "stroke-linejoin": "round",
1484
- fill: "none"
1485
- }, null, 8, oo)),
1486
- I.value.includes(l.id) ? m("", !0) : (v(), c("path", {
1487
- key: 2,
1488
- d: `M ${l.dY}`,
1489
- stroke: e.value.style.backgroundColor,
1490
- "stroke-width": e.value.style.layout.marginalBars.linesStrokeWidth + 1,
1491
- "stroke-linecap": "round",
1492
- "stroke-linejoin": "round",
1493
- fill: "none"
1494
- }, null, 8, so)),
1495
- I.value.includes(l.id) ? m("", !0) : (v(), c("path", {
1496
- key: 3,
1497
- d: `M ${l.dY}`,
1498
- stroke: l.color,
1499
- "stroke-width": e.value.style.layout.marginalBars.linesStrokeWidth,
1500
- "stroke-linecap": "round",
1501
- "stroke-linejoin": "round",
1502
- fill: "none"
1503
- }, null, 8, no))
1504
- ], 64))), 256))
1505
- ])) : m("", !0)
1506
- ])) : m("", !0),
1507
- e.value.style.layout.plots.giftWrap.show ? (v(), c("g", uo, [
1508
- (v(!0), c(Q, null, oe(U.value, (l, s) => (v(), c("g", null, [
1509
- l.plots.length > 2 ? (v(), c("polygon", {
1510
- key: 0,
1511
- points: h(oa)({ series: l.plots }),
1512
- fill: h(Ge)(
1513
- l.color,
1514
- e.value.style.layout.plots.giftWrap.fillOpacity * 100
1515
- ),
1516
- "stroke-width": e.value.style.layout.plots.giftWrap.strokeWidth,
1517
- "stroke-dasharray": e.value.style.layout.plots.giftWrap.strokeDasharray,
1518
- stroke: l.color,
1519
- "stroke-linejoin": "round",
1520
- "stroke-linecap": "round"
1521
- }, null, 8, io)) : m("", !0)
1522
- ]))), 256))
1523
- ])) : m("", !0),
1524
- e.value.usePerformanceMode ? m("", !0) : (v(!0), c(Q, { key: 4 }, oe(U.value, (l, s) => (v(), c("g", null, [
1525
- !l.shape || l.shape === "circle" ? (v(), c("g", ro, [
1526
- (v(!0), c(Q, null, oe(l.plots, (o, n) => (v(), c("circle", {
1527
- cx: o.x,
1528
- cy: o.y,
1529
- r: R.value && R.value === o.id ? o.weight * 2 : o.weight,
1530
- fill: h(Ge)(
1531
- l.color,
1532
- e.value.style.layout.plots.opacity * 100
1533
- ),
1534
- stroke: e.value.style.layout.plots.stroke,
1535
- "stroke-width": e.value.style.layout.plots.strokeWidth,
1536
- style: ue(`opacity:${R.value && R.value === o.id ? 1 : e.value.style.layout.plots.significance.useDistanceOpacity ? 1 - Math.abs(o.deviation) / Ot.value : e.value.style.layout.plots.significance.show && Math.abs(o.deviation) > e.value.style.layout.plots.significance.deviationThreshold ? e.value.style.layout.plots.significance.opacity : 1}`),
1537
- onMouseover: (i) => he(
1538
- o,
1539
- s,
1540
- "pointer",
1541
- ve.value.get(o.id)
1542
- ),
1543
- onMouseleave: (i) => Ye(o, s),
1544
- onClick: (i) => Re(o, s)
1545
- }, null, 44, vo))), 256))
1546
- ])) : (v(), c("g", co, [
1547
- (v(!0), c(Q, null, oe(l.plots, (o, n) => (v(), ae(pt, {
1548
- plot: { x: o.x, y: o.y },
1549
- radius: R.value && R.value === o.id ? o.weight * 2 : o.weight,
1550
- shape: l.shape,
1551
- color: h(Ge)(
1552
- l.color,
1553
- e.value.style.layout.plots.opacity * 100
1554
- ),
1555
- stroke: e.value.style.layout.plots.stroke,
1556
- strokeWidth: e.value.style.layout.plots.strokeWidth,
1557
- style: ue(`opacity:${R.value && R.value === o.id ? 1 : e.value.style.layout.plots.significance.useDistanceOpacity ? 1 - Math.abs(o.deviation) / Ot.value : e.value.style.layout.plots.significance.show && Math.abs(o.deviation) > e.value.style.layout.plots.significance.deviationThreshold ? e.value.style.layout.plots.significance.opacity : 1}`),
1558
- onMouseover: (i) => he(
1559
- o,
1560
- s,
1561
- "pointer",
1562
- ve.value.get(o.id)
1563
- ),
1564
- onMouseleave: (i) => Ye(o, s),
1565
- onClick: (i) => Re(o, s)
1566
- }, null, 8, ["plot", "radius", "shape", "color", "stroke", "strokeWidth", "style", "onMouseover", "onMouseleave", "onClick"]))), 256))
1567
- ]))
1568
- ]))), 256)),
1569
- e.value.usePerformanceMode ? (v(), c(Q, { key: 5 }, [
1570
- k("g", {
1571
- "clip-path": `url(#clip_path_${N.value})`
1572
- }, [
1573
- (v(!0), c(Q, null, oe(Pl.value, (l) => (v(), c("path", {
1574
- key: l.id,
1575
- d: l.d,
1576
- fill: l.fill,
1577
- stroke: l.stroke,
1578
- "stroke-width": l.strokeWidth,
1579
- "stroke-opacity": l.strokeOpacity,
1580
- "vector-effect": "non-scaling-stroke",
1581
- "paint-order": "fill"
1582
- }, null, 8, ho))), 128))
1583
- ], 8, yo),
1584
- g.value && e.value.style.layout.plots.selectors.show ? (v(), c("g", fo, [
1585
- Oe(pt, {
1586
- shape: g.value.shape || "circle",
1587
- color: g.value.color,
1588
- plot: { x: g.value.x, y: g.value.y },
1589
- radius: Math.max(
1590
- 4 * Xt[g.value.shape || "circle"],
1591
- g.value.weight * 2
1592
- ),
1593
- stroke: e.value.style.layout.plots.stroke,
1594
- strokeWidth: e.value.style.layout.plots.strokeWidth
1595
- }, null, 8, ["shape", "color", "plot", "radius", "stroke", "strokeWidth"])
1596
- ])) : m("", !0),
1597
- k("rect", {
1598
- x: u.value.left,
1599
- y: u.value.top,
1600
- width: Math.max(1e-4, u.value.width),
1601
- height: Math.max(1e-4, u.value.height),
1602
- fill: "transparent",
1603
- onMousemove: a[2] || (a[2] = (...l) => h(Yt) && h(Yt)(...l)),
1604
- onMouseleave: zl,
1605
- onClick: Il
1606
- }, null, 40, po)
1607
- ], 64)) : m("", !0),
1608
- g.value && e.value.style.layout.plots.selectors.show ? (v(), c("g", go, [
1609
- k("line", {
1610
- x1: W.value.x,
1611
- x2: g.value.x,
1612
- y1: g.value.y,
1613
- y2: g.value.y,
1614
- stroke: e.value.style.layout.plots.selectors.stroke,
1615
- "stroke-width": e.value.style.layout.plots.selectors.strokeWidth,
1616
- "stroke-dasharray": e.value.style.layout.plots.selectors.strokeDasharray,
1617
- "stroke-linecap": "round",
1618
- class: "line-pointer"
1619
- }, null, 8, mo),
1620
- k("line", {
1621
- x1: g.value.x,
1622
- x2: g.value.x,
1623
- y1: W.value.y,
1624
- y2: g.value.y,
1625
- stroke: e.value.style.layout.plots.selectors.stroke,
1626
- "stroke-width": e.value.style.layout.plots.selectors.strokeWidth,
1627
- "stroke-dasharray": e.value.style.layout.plots.selectors.strokeDasharray,
1628
- "stroke-linecap": "round",
1629
- class: "line-pointer"
1630
- }, null, 8, xo),
1631
- k("text", {
1632
- x: W.value.x + (g.value.x > W.value.x ? -6 : 6),
1633
- y: g.value.y + e.value.style.layout.plots.selectors.labels.fontSize / 3,
1634
- "font-size": e.value.style.layout.plots.selectors.labels.fontSize,
1635
- fill: e.value.style.layout.plots.selectors.labels.color,
1636
- "font-weight": e.value.style.layout.plots.selectors.labels.bold ? "bold" : "normal",
1637
- "text-anchor": g.value.x > W.value.x ? "end" : "start"
1638
- }, V(h(se)(
1639
- e.value.style.layout.plots.selectors.labels.y.formatter,
1640
- h(Z)(g.value.v.y),
1641
- h(ee)({
1642
- p: e.value.style.layout.plots.selectors.labels.prefix,
1643
- v: h(Z)(g.value.v.y),
1644
- s: e.value.style.layout.plots.selectors.labels.suffix,
1645
- r: e.value.style.layout.plots.selectors.labels.rounding
1646
- }),
1647
- { datapoint: g.value }
1648
- )), 9, bo),
1649
- k("text", {
1650
- x: g.value.x,
1651
- y: W.value.y + (g.value.y > W.value.y ? -6 : e.value.style.layout.plots.selectors.labels.fontSize + 6),
1652
- "font-size": e.value.style.layout.plots.selectors.labels.fontSize,
1653
- fill: e.value.style.layout.plots.selectors.labels.color,
1654
- "font-weight": e.value.style.layout.plots.selectors.labels.bold ? "bold" : "normal",
1655
- "text-anchor": "middle"
1656
- }, V(h(se)(
1657
- e.value.style.layout.plots.selectors.labels.y.formatter,
1658
- h(Z)(g.value.v.x),
1659
- h(ee)({
1660
- p: e.value.style.layout.plots.selectors.labels.prefix,
1661
- v: h(Z)(g.value.v.x),
1662
- s: e.value.style.layout.plots.selectors.labels.suffix,
1663
- r: e.value.style.layout.plots.selectors.labels.rounding
1664
- }),
1665
- { datapoint: g.value }
1666
- )), 9, ko),
1667
- k("circle", {
1668
- cx: W.value.x,
1669
- cy: g.value.y,
1670
- r: e.value.style.layout.plots.selectors.markers.radius,
1671
- fill: e.value.style.layout.plots.selectors.markers.fill,
1672
- stroke: e.value.style.layout.plots.selectors.markers.stroke,
1673
- "stroke-width": e.value.style.layout.plots.selectors.markers.strokeWidth,
1674
- class: "line-pointer"
1675
- }, null, 8, wo),
1676
- k("circle", {
1677
- cx: g.value.x,
1678
- cy: W.value.y,
1679
- r: e.value.style.layout.plots.selectors.markers.radius,
1680
- fill: e.value.style.layout.plots.selectors.markers.fill,
1681
- stroke: e.value.style.layout.plots.selectors.markers.stroke,
1682
- "stroke-width": e.value.style.layout.plots.selectors.markers.strokeWidth,
1683
- class: "line-pointer"
1684
- }, null, 8, $o),
1685
- e.value.style.layout.plots.selectors.labels.showName ? (v(), c("text", {
1686
- key: 0,
1687
- x: g.value.x,
1688
- y: g.value.y + (g.value.y < W.value.y ? -e.value.style.layout.plots.selectors.labels.fontSize / 2 : e.value.style.layout.plots.selectors.labels.fontSize),
1689
- "font-size": e.value.style.layout.plots.selectors.labels.fontSize,
1690
- fill: e.value.style.layout.plots.selectors.labels.color,
1691
- "font-weight": e.value.style.layout.plots.selectors.labels.bold ? "bold" : "normal",
1692
- "text-anchor": g.value.x < u.value.left + 100 ? "start" : g.value.x > u.value.right - 100 ? "end" : g.value.x > W.value.x ? "start" : "end"
1693
- }, V(g.value.v.name), 9, Mo)) : m("", !0)
1694
- ])) : m("", !0),
1695
- e.value.style.layout.dataLabels.xAxis.show ? (v(), c("g", {
1696
- key: 7,
1697
- ref_key: "xAxisLabelLeft",
1698
- ref: Ke
1699
- }, [
1700
- k("text", {
1701
- id: `vue-ui-scatter-xAxis-label-${N.value}`,
1702
- transform: `translate(${e.value.style.layout.dataLabels.xAxis.fontSize}, ${u.value.top + u.value.height / 2}), rotate(-90)`,
1703
- "text-anchor": "middle",
1704
- "font-size": e.value.style.layout.dataLabels.xAxis.fontSize,
1705
- "font-weight": e.value.style.layout.dataLabels.xAxis.bold ? "bold" : "normal",
1706
- fill: e.value.style.layout.dataLabels.xAxis.color
1707
- }, V(e.value.style.layout.dataLabels.xAxis.name), 9, _o),
1708
- k("text", {
1709
- "text-anchor": "middle",
1710
- "font-size": e.value.style.layout.dataLabels.xAxis.fontSize,
1711
- fill: e.value.style.layout.dataLabels.xAxis.color,
1712
- transform: `translate(${e.value.style.layout.dataLabels.xAxis.name ? e.value.style.layout.dataLabels.xAxis.fontSize * 3 : 0}, ${W.value.y + e.value.style.layout.dataLabels.xAxis.fontSize / 3}), rotate(-90)`
1713
- }, V(h(se)(
1714
- e.value.style.layout.plots.selectors.labels.x.formatter,
1715
- h(Z)(F.value.xMin),
1716
- h(ee)({
1717
- p: e.value.style.layout.plots.selectors.labels.prefix,
1718
- v: h(Z)(F.value.xMin),
1719
- s: e.value.style.layout.plots.selectors.labels.suffix,
1720
- r: e.value.style.layout.dataLabels.xAxis.rounding
1721
- })
1722
- )), 9, Co)
1723
- ], 512)) : m("", !0),
1724
- e.value.style.layout.dataLabels.xAxis.show ? (v(), c("text", {
1725
- key: 8,
1726
- ref_key: "xAxisLabelRight",
1727
- ref: fl,
1728
- "text-anchor": "middle",
1729
- transform: `translate(${u.value.right + e.value.style.layout.padding.right + 6}, ${W.value.y + e.value.style.layout.dataLabels.xAxis.fontSize / 3}), rotate(-90)`,
1730
- "font-size": e.value.style.layout.dataLabels.xAxis.fontSize,
1731
- fill: e.value.style.layout.dataLabels.xAxis.color
1732
- }, V(h(se)(
1733
- e.value.style.layout.plots.selectors.labels.x.formatter,
1734
- h(Z)(F.value.xMax),
1735
- h(ee)({
1736
- p: e.value.style.layout.plots.selectors.labels.prefix,
1737
- v: h(Z)(F.value.xMax),
1738
- s: e.value.style.layout.plots.selectors.labels.suffix,
1739
- r: e.value.style.layout.dataLabels.xAxis.rounding
1740
- })
1741
- )), 9, Ao)) : m("", !0),
1742
- e.value.style.layout.dataLabels.yAxis.show ? (v(), c("text", {
1743
- key: 9,
1744
- ref_key: "yAxisLabelTop",
1745
- ref: pl,
1746
- x: W.value.x,
1747
- y: u.value.top - e.value.style.layout.dataLabels.yAxis.fontSize,
1748
- "text-anchor": "middle",
1749
- "font-size": e.value.style.layout.dataLabels.yAxis.fontSize,
1750
- fill: e.value.style.layout.dataLabels.yAxis.color
1751
- }, V(h(se)(
1752
- e.value.style.layout.plots.selectors.labels.y.formatter,
1753
- h(Z)(F.value.yMax),
1754
- h(ee)({
1755
- p: e.value.style.layout.plots.selectors.labels.prefix,
1756
- v: h(Z)(F.value.yMax),
1757
- s: e.value.style.layout.plots.selectors.labels.suffix,
1758
- r: e.value.style.layout.dataLabels.yAxis.rounding
1759
- })
1760
- )), 9, So)) : m("", !0),
1761
- e.value.style.layout.dataLabels.yAxis.show ? (v(), c("g", {
1762
- key: 10,
1763
- ref_key: "yAxisLabelBottom",
1764
- ref: Ze
1765
- }, [
1766
- k("text", {
1767
- x: W.value.x,
1768
- y: Y.value.height - e.value.style.layout.dataLabels.yAxis.fontSize * 2,
1769
- "text-anchor": "middle",
1770
- "font-size": e.value.style.layout.dataLabels.yAxis.fontSize,
1771
- fill: e.value.style.layout.dataLabels.yAxis.color
1772
- }, V(h(se)(
1773
- e.value.style.layout.plots.selectors.labels.y.formatter,
1774
- h(Z)(F.value.yMin),
1775
- h(ee)({
1776
- p: e.value.style.layout.plots.selectors.labels.prefix,
1777
- v: h(Z)(F.value.yMin),
1778
- s: e.value.style.layout.plots.selectors.labels.suffix,
1779
- r: e.value.style.layout.dataLabels.yAxis.rounding
1780
- })
1781
- )), 9, To),
1782
- k("text", {
1783
- "text-anchor": "middle",
1784
- "font-size": e.value.style.layout.dataLabels.yAxis.fontSize,
1785
- "font-weight": e.value.style.layout.dataLabels.yAxis.bold ? "bold" : "normal",
1786
- fill: e.value.style.layout.dataLabels.yAxis.color,
1787
- x: u.value.left + u.value.width / 2,
1788
- y: Y.value.height
1789
- }, V(e.value.style.layout.dataLabels.yAxis.name), 9, Lo)
1790
- ], 512)) : m("", !0),
1791
- k("clipPath", {
1792
- id: `clip_path_${N.value}`
1793
- }, [
1794
- k("rect", {
1795
- x: u.value.left,
1796
- y: u.value.top,
1797
- width: u.value.width <= 0 ? 1e-4 : u.value.width,
1798
- height: u.value.height <= 0 ? 1e-4 : u.value.height
1799
- }, null, 8, Bo)
1800
- ], 8, Po),
1801
- e.value.style.layout.correlation.show ? (v(), c("g", zo, [
1802
- (v(!0), c(Q, null, oe(U.value, (l, s) => (v(), c("line", {
1803
- x1: l.correlation.x1,
1804
- x2: l.correlation.x2,
1805
- y1: l.correlation.y1,
1806
- y2: l.correlation.y2,
1807
- "stroke-dasharray": e.value.style.layout.correlation.strokeDasharray,
1808
- stroke: l.color,
1809
- "stroke-width": e.value.style.layout.correlation.strokeWidth,
1810
- "clip-path": `url(#clip_path_${N.value})`
1811
- }, null, 8, Io))), 256)),
1812
- (v(!0), c(Q, null, oe(U.value, (l, s) => (v(), c("g", null, [
1813
- e.value.style.layout.correlation.label.show ? (v(), c("text", {
1814
- key: 0,
1815
- x: l.correlation.x2,
1816
- y: l.correlation.y2,
1817
- fill: e.value.style.layout.correlation.label.useSerieColor ? l.color : e.value.style.layout.correlation.label.color,
1818
- "text-anchor": "end",
1819
- "font-size": e.value.style.layout.correlation.label.fontSize,
1820
- "font-weight": e.value.style.layout.correlation.label.bold ? "bold" : "normal"
1821
- }, V(h(ee)({
1822
- v: h(Z)(l.correlation.coefficient),
1823
- r: e.value.style.layout.correlation.label.roundingValue
1824
- })), 9, Oo)) : m("", !0)
1825
- ]))), 256))
1826
- ])) : m("", !0),
1827
- z(t.$slots, "svg", {
1828
- svg: {
1829
- ...Y.value,
1830
- drawingArea: {
1831
- ...u.value,
1832
- zero: W.value
1833
- },
1834
- data: be.value,
1835
- isPrintingImg: h(at) | h(ot) | Ee.value,
1836
- isPrintingSvg: Ne.value
1837
- }
1838
- }, void 0, !0)
1839
- ], 46, Ba)),
1840
- t.$slots.hint ? (v(), c("div", Do, [
1841
- z(t.$slots, "hint", q(H({
1842
- hint: e.value.a11y.translations.keyboardNavigation,
1843
- isVisible: Fe.value
1844
- })), void 0, !0)
1845
- ])) : m("", !0)
1846
- ]),
1847
- t.$slots.watermark ? (v(), c("div", Eo, [
1848
- z(t.$slots, "watermark", q(H({
1849
- isPrinting: h(at) || h(ot) || Ee.value || Ne.value
1850
- })), void 0, !0)
1851
- ])) : m("", !0),
1852
- k("div", {
1853
- id: `legend-bottom-${N.value}`
1854
- }, null, 8, No),
1855
- Ct.value && (e.value.style.legend.show || t.$slots.legend) ? (v(), ae(ql, {
1856
- key: 7,
1857
- to: e.value.style.legend.position === "top" ? `#legend-top-${N.value}` : `#legend-bottom-${N.value}`
1858
- }, [
1859
- k("div", {
1860
- ref_key: "chartLegend",
1861
- ref: bt
1862
- }, [
1863
- z(t.$slots, "legend", { legend: J.value }, () => [
1864
- e.value.style.legend.show ? (v(), ae($a, {
1865
- key: `legend_${_t.value}`,
1866
- legendSet: J.value,
1867
- config: bl.value,
1868
- isCursorPointer: de.value,
1869
- onClickMarker: a[3] || (a[3] = ({ legend: l }) => Ve(l.id))
1870
- }, {
1871
- item: P(({ legend: l }) => [
1872
- k("div", {
1873
- onClick: (s) => l.segregate(),
1874
- style: ue(`opacity:${I.value.includes(l.id) ? 0.5 : 1}`)
1875
- }, V(l.name), 13, Fo)
1876
- ]),
1877
- legendToggle: P(() => [
1878
- J.value.length > 2 && e.value.style.legend.selectAllToggle.show && !h(Je) ? (v(), ae(_a, {
1879
- key: 0,
1880
- backgroundColor: e.value.style.legend.selectAllToggle.backgroundColor,
1881
- color: e.value.style.legend.selectAllToggle.color,
1882
- fontSize: e.value.style.legend.fontSize,
1883
- checked: I.value.length > 0,
1884
- isCursorPointer: de.value,
1885
- onToggle: Ml
1886
- }, null, 8, ["backgroundColor", "color", "fontSize", "checked", "isCursorPointer"])) : m("", !0)
1887
- ]),
1888
- _: 1
1889
- }, 8, ["legendSet", "config", "isCursorPointer"])) : m("", !0)
1890
- ], !0)
1891
- ], 512)
1892
- ], 8, ["to"])) : m("", !0),
1893
- t.$slots.source ? (v(), c("div", {
1894
- key: 8,
1895
- ref_key: "source",
1896
- ref: kt,
1897
- dir: "auto"
1898
- }, [
1899
- z(t.$slots, "source", {}, void 0, !0)
1900
- ], 512)) : m("", !0),
1901
- Oe(h(al), {
1902
- teleportTo: e.value.style.tooltip.teleportTo,
1903
- show: K.value.showTooltip && De.value,
1904
- backgroundColor: e.value.style.tooltip.backgroundColor,
1905
- color: e.value.style.tooltip.color,
1906
- borderRadius: e.value.style.tooltip.borderRadius,
1907
- borderColor: e.value.style.tooltip.borderColor,
1908
- borderWidth: e.value.style.tooltip.borderWidth,
1909
- fontSize: e.value.style.tooltip.fontSize,
1910
- backgroundOpacity: e.value.style.tooltip.backgroundOpacity,
1911
- position: e.value.style.tooltip.position,
1912
- offsetY: e.value.style.tooltip.offsetY,
1913
- parent: ne.value,
1914
- content: qe.value,
1915
- isFullscreen: fe.value,
1916
- isCustom: e.value.style.tooltip.customFormat && typeof e.value.style.tooltip.customFormat == "function",
1917
- smooth: e.value.style.tooltip.smooth,
1918
- backdropFilter: e.value.style.tooltip.backdropFilter,
1919
- smoothForce: e.value.style.tooltip.smoothForce,
1920
- smoothSnapThreshold: e.value.style.tooltip.smoothSnapThreshold,
1921
- isA11yMode: Se.value === "keyboard",
1922
- a11yPosition: At.value
1923
- }, {
1924
- "tooltip-before": P(() => [
1925
- z(t.$slots, "tooltip-before", q(H({ ...Xe.value })), void 0, !0)
1926
- ]),
1927
- tooltip: P(() => [
1928
- z(t.$slots, "tooltip", q(H({ ...Xe.value })), void 0, !0)
1929
- ]),
1930
- "tooltip-after": P(() => [
1931
- z(t.$slots, "tooltip-after", q(H({ ...Xe.value })), void 0, !0)
1932
- ]),
1933
- default: P(() => [
1934
- e.value.style.tooltip.showShape ? (v(), c("div", Wo, [
1935
- (v(), c("svg", Xo, [
1936
- Oe(pt, {
1937
- shape: g.value.shape,
1938
- color: g.value.color,
1939
- plot: { x: 10, y: 10 },
1940
- radius: 7
1941
- }, null, 8, ["shape", "color"])
1942
- ]))
1943
- ])) : m("", !0)
1944
- ]),
1945
- _: 3
1946
- }, 8, ["teleportTo", "show", "backgroundColor", "color", "borderRadius", "borderColor", "borderWidth", "fontSize", "backgroundOpacity", "position", "offsetY", "parent", "content", "isFullscreen", "isCustom", "smooth", "backdropFilter", "smoothForce", "smoothSnapThreshold", "isA11yMode", "a11yPosition"]),
1947
- gt.value && e.value.userOptions.buttons.table ? (v(), ae(Hl(Pe.value.component), Kl({ key: 9 }, Pe.value.props, {
1948
- ref_key: "tableUnit",
1949
- ref: Ae,
1950
- onClose: Rt
1951
- }), Ht({
1952
- content: P(() => [
1953
- (v(), ae(h(nl), {
1954
- key: `table_${Mt.value}`,
1955
- colNames: ke.value.colNames,
1956
- head: ke.value.head,
1957
- body: ke.value.body,
1958
- config: ke.value.config,
1959
- title: e.value.table.useDialog ? "" : Pe.value.title,
1960
- withCloseButton: !e.value.table.useDialog,
1961
- isCursorPointer: de.value,
1962
- onClose: Rt
1963
- }, {
1964
- th: P(({ th: l }) => [
1965
- Kt(V(l), 1)
1966
- ]),
1967
- td: P(({ td: l }) => [
1968
- l.shape ? (v(), c("div", Yo, [
1969
- k("span", null, V(l.content), 1)
1970
- ])) : (v(), c("div", {
1971
- key: 1,
1972
- innerHTML: l
1973
- }, null, 8, Ro))
1974
- ]),
1975
- _: 1
1976
- }, 8, ["colNames", "head", "body", "config", "title", "withCloseButton", "isCursorPointer"]))
1977
- ]),
1978
- _: 2
1979
- }, [
1980
- e.value.table.useDialog ? {
1981
- name: "title",
1982
- fn: P(() => [
1983
- Kt(V(Pe.value.title), 1)
1984
- ]),
1985
- key: "0"
1986
- } : void 0,
1987
- e.value.table.useDialog ? {
1988
- name: "actions",
1989
- fn: P(() => [
1990
- k("button", {
1991
- tabindex: "0",
1992
- class: "vue-ui-user-options-button",
1993
- onClick: a[4] || (a[4] = (l) => nt(e.value.userOptions.callbacks.csv)),
1994
- style: ue({ cursor: de.value ? "pointer" : "default" })
1995
- }, [
1996
- Oe(h(ol), {
1997
- name: "fileCsv",
1998
- stroke: Pe.value.props.color
1999
- }, null, 8, ["stroke"])
2000
- ], 4)
2001
- ]),
2002
- key: "1"
2003
- } : void 0
2004
- ]), 1040)) : m("", !0),
2005
- z(t.$slots, "skeleton", {}, () => [
2006
- h(Je) ? (v(), ae(ha, { key: 0 })) : m("", !0)
2007
- ], !0)
2008
- ], 46, Aa));
2009
- }
2010
- }, vs = /* @__PURE__ */ Ca(Vo, [["__scopeId", "data-v-9948c677"]]);
2011
- export {
2012
- vs as default
2013
- };