vue-data-ui 3.0.0-next.8 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (144) hide show
  1. package/README.md +32 -30
  2. package/dist/{Arrow-BRtNjitS.js → Arrow-r2f8Bpd-.js} +1 -1
  3. package/dist/{BaseDraggableDialog-CO9ok1PR.js → BaseDraggableDialog-CGGcf8d8.js} +4 -4
  4. package/dist/{BaseIcon-BuOIF6t5.js → BaseIcon-CXtL10fo.js} +1 -1
  5. package/dist/{ColorPicker-FH6oc0mS.js → ColorPicker-H91bBsqM.js} +2 -2
  6. package/dist/{DataTable-D36ZRtpU.js → DataTable-BSSXpM7w.js} +2 -2
  7. package/dist/{Legend-DInM-hku.js → Legend-BUk0WvWJ.js} +2 -2
  8. package/dist/{NonSvgPenAndPaper-B60MxEaz.js → NonSvgPenAndPaper-DQDgPoW8.js} +3 -3
  9. package/dist/{PackageVersion-CGQlqnmq.js → PackageVersion-CJ6Vd7V5.js} +3 -3
  10. package/dist/{PenAndPaper-B5slIHlh.js → PenAndPaper-D3zudcNI.js} +32 -32
  11. package/dist/{RecursiveCircles-Dn3TGoL6.js → RecursiveCircles-BcLb1aRS.js} +15 -13
  12. package/dist/RecursiveLabels-Bgcv0pzu.js +50 -0
  13. package/dist/{RecursiveLinks-ld_gDZH4.js → RecursiveLinks-00zGWPf9.js} +20 -18
  14. package/dist/{Shape-BGr3dQKt.js → Shape-BRzOzubn.js} +43 -37
  15. package/dist/Slicer-MID8pgT3.js +602 -0
  16. package/dist/{SparkTooltip-BWA23VgJ.js → SparkTooltip-DATI1fGZ.js} +7 -7
  17. package/dist/{Title-BSlAPr_H.js → Title-BGu6gEd2.js} +1 -1
  18. package/dist/{Tooltip-lPcsweXz.js → Tooltip-Bh2zYSoM.js} +23 -19
  19. package/dist/{UserOptions-Dn5TCQxg.js → UserOptions-Ck8fz9f4.js} +2 -2
  20. package/dist/{dom-to-png-Br-eVhJZ.js → dom-to-png-DhIh24Ti.js} +1 -1
  21. package/dist/{img-CgMUOQnb.js → img-DrR839Ot.js} +1 -1
  22. package/dist/{index-Cfm5-hMQ.js → index-BtNwOUja.js} +2885 -2010
  23. package/dist/{pdf-BMVHBLq5.js → pdf-DoShrdT5.js} +1 -1
  24. package/dist/style.css +1 -1
  25. package/dist/types/vue-data-ui.d.cts +753 -65
  26. package/dist/types/vue-data-ui.d.ts +753 -65
  27. package/dist/useAutoSizeLabelsInsideViewbox-FmDQyX4z.js +81 -0
  28. package/dist/useFitSvgText-2crs6Fv5.js +69 -0
  29. package/dist/useLoading-D7YHNtLX.js +29 -0
  30. package/dist/useNestedProp-f2H3m6Yj.js +13 -0
  31. package/dist/usePanZoom-BVca3eMk.js +122 -0
  32. package/dist/{usePrinter-B1Hgs47c.js → usePrinter-DUNjpQNe.js} +2 -2
  33. package/dist/useTimeLabelCollider-CIsgDrl9.js +78 -0
  34. package/dist/{useTimeLabels-Mrr0jrpL.js → useTimeLabels-DkzmKfZn.js} +211 -152
  35. package/dist/{vue-data-ui-CD674-M3.js → vue-data-ui-D7QVxNhO.js} +105 -100
  36. package/dist/vue-data-ui.js +26 -25
  37. package/dist/vue-ui-3d-bar-ITaF-6Kn.js +1323 -0
  38. package/dist/{vue-ui-accordion-CEDGlyKI.js → vue-ui-accordion-BKUrAowe.js} +3 -3
  39. package/dist/vue-ui-age-pyramid-DxsuDr6o.js +835 -0
  40. package/dist/{vue-ui-annotator-CosgP-Fl.js → vue-ui-annotator-B06QtxgJ.js} +12 -12
  41. package/dist/vue-ui-bullet-B7Fy45tA.js +571 -0
  42. package/dist/vue-ui-candlestick-Dw0U4uIQ.js +1000 -0
  43. package/dist/{vue-ui-carousel-table-BG1ItsAb.js → vue-ui-carousel-table-DGz0nw28.js} +29 -29
  44. package/dist/{vue-ui-chestnut-6uKesZW9.js → vue-ui-chestnut-CFfKYm9i.js} +664 -536
  45. package/dist/vue-ui-chord-EhlQhMSs.js +1038 -0
  46. package/dist/vue-ui-circle-pack-BHrrEUUd.js +709 -0
  47. package/dist/{vue-ui-cursor-CkVnNEGn.js → vue-ui-cursor-Dd-HtWzG.js} +2 -2
  48. package/dist/{vue-ui-dashboard-D07ivGS7.js → vue-ui-dashboard-6R8udDY3.js} +64 -64
  49. package/dist/{vue-ui-digits-Doidl3Lz.js → vue-ui-digits-zKn3uhGN.js} +2 -2
  50. package/dist/{vue-ui-donut-CWvzqAAa.js → vue-ui-donut-BtnIwS_E.js} +433 -424
  51. package/dist/vue-ui-donut-evolution-DHo1MuMM.js +1076 -0
  52. package/dist/vue-ui-dumbbell-Czi9r9Na.js +1120 -0
  53. package/dist/vue-ui-flow-jOfM0RZY.js +841 -0
  54. package/dist/{vue-ui-funnel-D1pFzjJa.js → vue-ui-funnel-tBvVpdhy.js} +16 -16
  55. package/dist/vue-ui-galaxy-IdoY2oqG.js +680 -0
  56. package/dist/vue-ui-gauge-DR6Xm_Hz.js +791 -0
  57. package/dist/vue-ui-gizmo-Dto73UsB.js +210 -0
  58. package/dist/vue-ui-heatmap-zmFv-0z1.js +1078 -0
  59. package/dist/vue-ui-history-plot-ILemyyYw.js +1074 -0
  60. package/dist/{vue-ui-kpi-DTeZbrJk.js → vue-ui-kpi-hmqSCvxr.js} +26 -26
  61. package/dist/{vue-ui-mini-loader-itpDcfZU.js → vue-ui-mini-loader-CbD-E8ci.js} +2 -2
  62. package/dist/vue-ui-molecule-mTy6YIm6.js +656 -0
  63. package/dist/vue-ui-mood-radar-BEnSYV3Q.js +785 -0
  64. package/dist/vue-ui-nested-donuts-CGE9dmJK.js +1284 -0
  65. package/dist/vue-ui-onion-Dh2J9GV0.js +776 -0
  66. package/dist/vue-ui-parallel-coordinate-plot-xsgmMIJK.js +916 -0
  67. package/dist/{vue-ui-quadrant-0milmSNS.js → vue-ui-quadrant-DA0Kw6eq.js} +512 -459
  68. package/dist/vue-ui-quick-chart-DKbxF5Yt.js +1762 -0
  69. package/dist/vue-ui-radar-BFY9bN_h.js +796 -0
  70. package/dist/{vue-ui-rating-C3QUdrMw.js → vue-ui-rating-Bh35aujf.js} +2 -2
  71. package/dist/vue-ui-relation-circle-B-05kQ_l.js +598 -0
  72. package/dist/vue-ui-ridgeline-CuGfF83t.js +1157 -0
  73. package/dist/vue-ui-rings-DrQXXzAM.js +728 -0
  74. package/dist/vue-ui-scatter-CWn9c7e9.js +1178 -0
  75. package/dist/{vue-ui-skeleton-P-1SRvsT.js → vue-ui-skeleton-oG4Bm5nL.js} +13 -13
  76. package/dist/{vue-ui-smiley-Cd1bhDuU.js → vue-ui-smiley-Cnwba_gV.js} +46 -46
  77. package/dist/vue-ui-spark-trend-D9iNCf4o.js +315 -0
  78. package/dist/vue-ui-sparkbar-iJkiubZC.js +351 -0
  79. package/dist/vue-ui-sparkgauge-BH3uA5rh.js +232 -0
  80. package/dist/vue-ui-sparkhistogram-B3kR62pf.js +380 -0
  81. package/dist/vue-ui-sparkline-DczR2ZAf.js +513 -0
  82. package/dist/vue-ui-sparkstackbar-Cg0ItRGH.js +421 -0
  83. package/dist/vue-ui-stackbar-d4PrzcGS.js +1371 -0
  84. package/dist/vue-ui-strip-plot-BXBpN5rl.js +916 -0
  85. package/dist/{vue-ui-table-B1tjuVi0.js → vue-ui-table-BXOLZXuz.js} +17 -17
  86. package/dist/{vue-ui-table-heatmap-BI8eIQG7.js → vue-ui-table-heatmap-7YT7VF2H.js} +5 -5
  87. package/dist/{vue-ui-table-sparkline-CqBD7xhZ.js → vue-ui-table-sparkline-BfgqajJ2.js} +19 -16
  88. package/dist/vue-ui-thermometer-C7Tg6HLz.js +541 -0
  89. package/dist/{vue-ui-timer-sgO_Z6ja.js → vue-ui-timer-Ch5JP1pQ.js} +5 -5
  90. package/dist/vue-ui-tiremarks-fY-4pWAK.js +406 -0
  91. package/dist/vue-ui-treemap-DTSX6suB.js +1035 -0
  92. package/dist/{vue-ui-vertical-bar-BPay31_q.js → vue-ui-vertical-bar-C-i2dRnU.js} +107 -105
  93. package/dist/vue-ui-waffle-BbgLlhGH.js +910 -0
  94. package/dist/vue-ui-wheel-waZf462K.js +379 -0
  95. package/dist/vue-ui-word-cloud-DtLK91Dk.js +765 -0
  96. package/dist/{vue-ui-world-DWskeHfE.js → vue-ui-world-Cx4uuwTY.js} +364 -327
  97. package/dist/vue-ui-xy-DDOT8cyx.js +3808 -0
  98. package/dist/{vue-ui-xy-canvas-Dkmsguo1.js → vue-ui-xy-canvas-CUCsC8vD.js} +265 -264
  99. package/package.json +4 -4
  100. package/dist/RecursiveLabels-NTMB9w5C.js +0 -49
  101. package/dist/Slicer-O07lQwRC.js +0 -577
  102. package/dist/useLoading-Bt5Doa8m.js +0 -28
  103. package/dist/useNestedProp-Hh7nGEjp.js +0 -13
  104. package/dist/usePanZoom-BQMvRXEQ.js +0 -115
  105. package/dist/vue-ui-3d-bar-DWtJoryQ.js +0 -1227
  106. package/dist/vue-ui-age-pyramid-DbrA1G0r.js +0 -746
  107. package/dist/vue-ui-bullet-9IB3mGon.js +0 -513
  108. package/dist/vue-ui-candlestick-CWqPF_zW.js +0 -873
  109. package/dist/vue-ui-chord-Crd3l1b6.js +0 -949
  110. package/dist/vue-ui-circle-pack-CAm2gxBi.js +0 -673
  111. package/dist/vue-ui-donut-evolution-Djp_eBqw.js +0 -903
  112. package/dist/vue-ui-dumbbell-B7GySnYf.js +0 -753
  113. package/dist/vue-ui-flow-XDpZAYWI.js +0 -765
  114. package/dist/vue-ui-galaxy-DBQy21se.js +0 -617
  115. package/dist/vue-ui-gauge-FBZaUrBD.js +0 -738
  116. package/dist/vue-ui-gizmo-CDbPxUzE.js +0 -192
  117. package/dist/vue-ui-heatmap-DsDWxYOS.js +0 -877
  118. package/dist/vue-ui-history-plot-CzO1Z1FH.js +0 -924
  119. package/dist/vue-ui-molecule-Ddd3FgID.js +0 -597
  120. package/dist/vue-ui-mood-radar-24XAq8mg.js +0 -670
  121. package/dist/vue-ui-nested-donuts-DjWASp62.js +0 -1212
  122. package/dist/vue-ui-onion-B9thdF_c.js +0 -701
  123. package/dist/vue-ui-parallel-coordinate-plot-DT-GhOaA.js +0 -807
  124. package/dist/vue-ui-quick-chart-D0DukVN6.js +0 -1612
  125. package/dist/vue-ui-radar-DY8y6oRc.js +0 -741
  126. package/dist/vue-ui-relation-circle-8Gd7_fxt.js +0 -542
  127. package/dist/vue-ui-ridgeline-iPtG1McW.js +0 -969
  128. package/dist/vue-ui-rings-BXPo4MMo.js +0 -685
  129. package/dist/vue-ui-scatter-26d0eebx.js +0 -1045
  130. package/dist/vue-ui-spark-trend-Dt3ctzpl.js +0 -291
  131. package/dist/vue-ui-sparkbar-RrxErqrU.js +0 -301
  132. package/dist/vue-ui-sparkgauge-CyNi1b0O.js +0 -201
  133. package/dist/vue-ui-sparkhistogram-DPpZCPuE.js +0 -313
  134. package/dist/vue-ui-sparkline-BMjQ_uYx.js +0 -459
  135. package/dist/vue-ui-sparkstackbar-CjO8pfE-.js +0 -381
  136. package/dist/vue-ui-stackbar-wgyvMlE6.js +0 -1207
  137. package/dist/vue-ui-strip-plot-BF1o8lvY.js +0 -761
  138. package/dist/vue-ui-thermometer-CtuxuYVt.js +0 -495
  139. package/dist/vue-ui-tiremarks-DOwj4ZE-.js +0 -358
  140. package/dist/vue-ui-treemap-C4LtyFug.js +0 -965
  141. package/dist/vue-ui-waffle-D8mzGTeo.js +0 -863
  142. package/dist/vue-ui-wheel-C6uAotal.js +0 -352
  143. package/dist/vue-ui-word-cloud-Bge2211V.js +0 -659
  144. package/dist/vue-ui-xy-UzQacbnA.js +0 -2982
@@ -1,969 +0,0 @@
1
- import { defineAsyncComponent as O, computed as f, ref as u, shallowRef as Be, onMounted as Nt, onBeforeUnmount as Ft, watch as Ue, createElementBlock as n, openBlock as r, unref as i, normalizeStyle as _, normalizeClass as q, createBlock as P, createCommentVNode as c, renderSlot as p, createElementVNode as d, createSlots as Ge, withCtx as m, normalizeProps as K, guardReactiveProps as J, createVNode as We, Fragment as g, renderList as A, mergeProps as je, toDisplayString as V, createTextVNode as Ye, nextTick as Dt } from "vue";
2
- import { u as It, c as ve, o as Rt, e as he, g as qe, b as Xt, d as Et, p as Q, an as Ke, ag as Ht, U as Je, V as Vt, W as Bt, X as Ut, F as Gt, I as Wt, i as Z, f as ee, t as jt, a as Yt, q as qt, r as Kt, K as Jt } from "./index-Cfm5-hMQ.js";
3
- import { u as Qt } from "./useUserOptionState-BIvW1Kz7.js";
4
- import { u as Zt } from "./useChartAccessibility-9icAAmYg.js";
5
- import { u as el } from "./usePrinter-B1Hgs47c.js";
6
- import { t as tl, u as ll } from "./useResponsive-DfdjqQps.js";
7
- import { u as Qe } from "./useNestedProp-Hh7nGEjp.js";
8
- import al from "./Legend-DInM-hku.js";
9
- import sl from "./Title-BSlAPr_H.js";
10
- import { _ as ol } from "./Shape-BGr3dQKt.js";
11
- import { u as rl } from "./useTimeLabels-Mrr0jrpL.js";
12
- import nl from "./img-CgMUOQnb.js";
13
- import { _ as il } from "./_plugin-vue_export-helper-CHgC5LLL.js";
14
- const ul = ["id"], cl = ["xmlns", "viewBox"], vl = ["id"], hl = ["stop-color"], dl = ["stop-color"], yl = ["stop-color"], fl = ["stop-color"], gl = ["id"], pl = ["stop-color"], ml = ["stop-color"], bl = ["stop-color"], xl = ["stop-color"], kl = { key: 0 }, Al = ["fill", "d"], wl = ["stroke", "stroke-width", "d"], $l = ["fill", "d"], Cl = ["stroke", "stroke-dasharray", "stroke-width", "d"], _l = ["x1", "y1", "x2", "y2", "stroke", "stroke-width", "stroke-dasharray"], Ml = ["cx", "cy", "stroke", "stroke-width", "r", "fill"], Pl = ["x", "y", "font-size", "font-weight", "fill", "text-decoration", "onMouseenter", "onClick"], Tl = { key: 0 }, Sl = { key: 0 }, zl = ["font-size", "fill", "font-weight", "transform", "text-anchor"], Ol = ["font-size", "fill", "font-weight", "transform", "text-anchor", "innerHTML"], Ll = ["x", "y", "width", "height", "onMouseenter", "onClick"], Nl = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Fl = ["cx", "cy", "stroke", "stroke-width", "r", "fill"], Dl = ["x", "y", "text-anchor", "font-size", "fill"], Il = {
15
- key: 5,
16
- class: "vue-data-ui-watermark"
17
- }, Rl = ["onClick"], Xl = ["innerHTML"], El = {
18
- __name: "vue-ui-ridgeline",
19
- props: {
20
- config: {
21
- type: Object,
22
- default() {
23
- return {};
24
- }
25
- },
26
- dataset: {
27
- type: Array,
28
- default() {
29
- return [];
30
- }
31
- }
32
- },
33
- emits: ["selectLegend", "selectDatapoint", "selectX"],
34
- setup(Ze, { expose: et, emit: tt }) {
35
- const lt = O(() => import("./vue-ui-accordion-CEDGlyKI.js")), at = O(() => import("./BaseDraggableDialog-CO9ok1PR.js")), st = O(() => import("./DataTable-D36ZRtpU.js")), ot = O(() => import("./PackageVersion-CGQlqnmq.js")), rt = O(() => import("./PenAndPaper-B5slIHlh.js")), nt = O(() => import("./vue-ui-skeleton-P-1SRvsT.js")), it = O(() => import("./UserOptions-Dn5TCQxg.js")), ut = O(() => import("./vue-ui-xy-UzQacbnA.js")), { vue_ui_ridgeline: ct } = It(), k = Ze, L = f({
36
- get() {
37
- return !!k.dataset && k.dataset.length;
38
- },
39
- set(l) {
40
- return l;
41
- }
42
- }), te = tt, T = u(null), de = u(null), ye = u(null), S = Be(null), I = Be(null), fe = u(null), ge = u(null), pe = u(0), vt = u(0), me = u(0), w = u(ve()), be = u(0), ht = u(0), xe = u(512), v = u(null), R = u(null), le = u(null), ke = u(0);
43
- function Ae() {
44
- const l = Qe({
45
- userConfig: k.config,
46
- defaultConfig: ct
47
- });
48
- return l.theme ? {
49
- ...Qe({
50
- userConfig: Yt.vue_ui_ridgeline[l.theme] || k.config,
51
- defaultConfig: l
52
- }),
53
- customPalette: jt[l.theme] || Q
54
- } : l;
55
- }
56
- const e = f({
57
- get: () => Ae(),
58
- set: (l) => l
59
- }), $ = u(Math.min(
60
- e.value.style.chart.areas.height,
61
- e.value.style.chart.areas.rowHeight
62
- )), {
63
- userOptionsVisible: ae,
64
- setUserOptionsVisibility: we,
65
- keepUserOptionState: $e
66
- } = Qt({ config: e.value }), { svgRef: se } = Zt({ config: e.value.style.chart.title });
67
- Nt(oe);
68
- function oe() {
69
- if (Rt(k.dataset) ? he({
70
- componentName: "VueUiRidgeline",
71
- type: "dataset"
72
- }) : k.dataset.forEach((l, o) => {
73
- qe({
74
- datasetObject: l,
75
- requiredAttributes: ["name", "datapoints"]
76
- }).forEach((t) => {
77
- L.value = !1, he({
78
- componentName: "VueUiRidgeline",
79
- type: "datasetSerieAttribute",
80
- property: t,
81
- index: o
82
- });
83
- }), l.datapoints.length && l.datapoints.forEach((t, s) => {
84
- qe({
85
- datasetObject: t,
86
- requiredAttributes: ["name", "values"]
87
- }).forEach((a) => {
88
- L.value = !1, he({
89
- componentName: "VueUiRidgeline",
90
- type: "datasetSerieAttribute",
91
- property: `datapoint.${a}`,
92
- index: `${o}-${s}`
93
- });
94
- });
95
- });
96
- }), ht.value = k.dataset.length, $.value = Math.min(
97
- e.value.style.chart.areas.height,
98
- e.value.style.chart.areas.rowHeight
99
- ), e.value.responsive) {
100
- const l = tl(() => {
101
- const { width: o, height: t } = ll({
102
- chart: T.value,
103
- title: e.value.style.chart.title.text ? de.value : null,
104
- legend: e.value.style.chart.legend.show ? ye.value : null,
105
- source: fe.value,
106
- noTitle: ge.value,
107
- padding: e.value.style.chart.padding
108
- });
109
- requestAnimationFrame(() => {
110
- xe.value = o, $.value = t / k.dataset.length, ke.value = t;
111
- });
112
- });
113
- S.value && (I.value && S.value.unobserve(I.value), S.value.disconnect()), S.value = new ResizeObserver(l), I.value = T.value.parentNode, S.value.observe(I.value);
114
- }
115
- }
116
- Ft(() => {
117
- S.value && (I.value && S.value.unobserve(I.value), S.value.disconnect());
118
- });
119
- const { isPrinting: Ce, isImaging: _e, generatePdf: Me, generateImage: Pe } = el({
120
- elementId: `vue-ui-ridgeline_${w.value}`,
121
- fileName: e.value.style.chart.title.text || "vue-ui-ridgeline",
122
- options: e.value.userOptions.print
123
- }), dt = f(() => e.value.userOptions.show && !e.value.style.chart.title.text), yt = f(() => Xt(e.value.customPalette)), B = u({
124
- showTable: e.value.table.show
125
- });
126
- Ue(() => k.config, (l) => {
127
- e.value = Ae(), ae.value = !e.value.userOptions.showOnChartHover, oe(), pe.value += 1, me.value += 1, $.value = Math.min(
128
- e.value.style.chart.areas.height,
129
- e.value.style.chart.areas.rowHeight
130
- ), B.value.showTable = e.value.table.show;
131
- }, { deep: !0 }), Ue(() => k.dataset, oe, { deep: !0 });
132
- const re = f(() => e.value.style.chart.areas.height / e.value.style.chart.areas.rowHeight);
133
- function Te(l) {
134
- z.value.includes(l) ? z.value = z.value.filter((o) => o !== l) : z.value.push(l), te("selectLegend", E.value);
135
- }
136
- const M = f(() => L.value ? k.dataset.map((l, o) => ({
137
- ...l,
138
- labelLen: pt(l.name, e.value.style.chart.yAxis.labels.fontSize),
139
- uid: ve(),
140
- datapoints: l.datapoints.map((t, s) => {
141
- const a = t.color ? Et(t.color) : yt.value[s] || Q[s] || Q[s % Q.length], h = Ke(t.name);
142
- return {
143
- ...t,
144
- color: a,
145
- id: h
146
- };
147
- })
148
- })) : []), Se = f(() => e.value.style.chart.padding.top + $.value * k.dataset.length + $.value * re.value), b = f(() => ({
149
- fullHeight: y.value.padding.top + y.value.padding.bottom + y.value.height,
150
- top: y.value.padding.top,
151
- left: y.value.padding.left,
152
- right: y.value.width - y.value.padding.right,
153
- bottom: y.value.padding.top + y.value.height,
154
- width: y.value.width - (y.value.padding.left + y.value.padding.right)
155
- })), y = f(() => {
156
- const l = e.value.style.chart.padding;
157
- return {
158
- width: xe.value,
159
- height: Se.value,
160
- padding: l
161
- };
162
- }), ne = f(() => Math.max(...M.value.flatMap((l) => l.datapoints.map((o) => o.values.length)))), W = f(() => rl({
163
- values: e.value.style.chart.xAxis.labels.values,
164
- maxDatapoints: ne.value,
165
- formatter: e.value.style.chart.xAxis.labels.datetimeFormatter,
166
- start: 0,
167
- end: e.value.style.chart.xAxis.labels.values.length
168
- })), X = f(() => {
169
- const l = Math.max(...M.value.map((a) => a.labelLen)), o = y.value.padding.left + l + 16 + e.value.style.chart.yAxis.labels.offsetX, t = (b.value.width - o) / ne.value, s = [];
170
- for (let a = 0; a < ne.value; a += 1)
171
- s.push({
172
- selectorX: o + t * a,
173
- x: o + t * a - t / 2,
174
- y: b.value.top,
175
- label: e.value.style.chart.xAxis.labels.values[a] ? W.value[a].text : "",
176
- index: a,
177
- width: t,
178
- height: Se.value
179
- });
180
- return s;
181
- });
182
- function ft(l) {
183
- te("selectX", M.value.map((o) => o.datapoints.map((t) => ({
184
- dp: t,
185
- selected: t.values[l.index]
186
- }))));
187
- }
188
- function gt(l, o) {
189
- return l.length * o / 2 + o;
190
- }
191
- function ze(l, o, t) {
192
- const s = gt(o, t);
193
- return l + s > b.value.right;
194
- }
195
- function pt(l, o, t = "sans-serif") {
196
- const a = document.createElement("canvas").getContext("2d"), h = typeof o == "number" ? `${o}px` : o;
197
- return a.font = `${h} ${t}`, a.measureText(l).width;
198
- }
199
- const E = f(() => {
200
- $.value;
201
- const l = Math.max(...M.value.map((x) => x.labelLen)), o = Math.max(...M.value.flatMap((x) => x.datapoints.map((N) => N.values.length))), t = Math.max(...M.value.flatMap((x) => x.datapoints.flatMap((N) => N.values))), s = Math.min(...M.value.flatMap((x) => x.datapoints.flatMap((N) => N.values))), a = y.value.padding.left + l + 16 + e.value.style.chart.yAxis.labels.offsetX, h = (b.value.width - a) / o, C = Math.abs(Math.min(s, 0)), Re = t + C;
202
- function Xe(x) {
203
- return isNaN(x / Re) ? 0 : x / Re;
204
- }
205
- return M.value.map((x, N) => {
206
- const Ee = b.value.top + $.value * N, F = b.value.top + Ee + $.value * re.value * (1 - Xe(C));
207
- return {
208
- ...x,
209
- label: {
210
- x: a - e.value.style.chart.yAxis.labels.fontSize,
211
- y: F
212
- },
213
- datapoints: x.datapoints.map((U) => {
214
- const D = U.values.map((G, Tt) => {
215
- const St = isNaN(G) || [void 0, null, "NaN", NaN, 1 / 0, -1 / 0].includes(G) ? 0 : G || 0, zt = a + h * Tt, Ot = b.value.top + Ee + $.value * re.value * (1 - Xe(St + C)), Lt = G === Math.max(...U.values);
216
- return {
217
- x: zt,
218
- y: Ot,
219
- value: G,
220
- isMaxPoint: Lt,
221
- zero: F
222
- };
223
- }), Ct = `${Ht(D, F, !1, !1)}`, _t = `M ${a},${F} ${Je(D)} ${D.at(-1).x},${F}`, Mt = `M ${a},${F} ${D.at(-1).x},${F}`, He = `M ${Vt(D)}`, Ve = `M ${Je(D)}`, Pt = Bt(
224
- e.value.style.chart.areas.smooth ? He : Ve
225
- );
226
- return {
227
- ...U,
228
- uid: ve(),
229
- plots: D,
230
- smoothPath: Ct,
231
- straightPath: _t,
232
- zeroPath: Mt,
233
- pathLength: Pt,
234
- smoothPathRidge: He,
235
- straightPathRidge: Ve
236
- };
237
- }).filter((U) => !z.value.includes(U.id))
238
- };
239
- });
240
- }), z = u([]);
241
- function mt(l) {
242
- const o = /* @__PURE__ */ new Map();
243
- return l.forEach((t) => {
244
- t.datapoints.forEach((s, a) => {
245
- const h = Ke(s.name);
246
- o.has(h) || o.set(h, {
247
- id: h,
248
- name: s.name,
249
- color: s.color,
250
- shape: "circle",
251
- segregate: () => Te(h),
252
- isSegregated: z.value.includes(h),
253
- opacity: z.value.includes(h) ? 0.5 : 1
254
- });
255
- });
256
- }), Array.from(o.values());
257
- }
258
- const ie = f(() => mt(M.value)), bt = f(() => ({
259
- cy: "donut-div-legend",
260
- backgroundColor: e.value.style.chart.legend.backgroundColor,
261
- color: e.value.style.chart.legend.color,
262
- fontSize: e.value.style.chart.legend.fontSize,
263
- paddingBottom: 12,
264
- fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
265
- })), H = u(!1);
266
- function Oe(l) {
267
- H.value = l, be.value += 1;
268
- }
269
- const Le = u({}), Ne = u([]);
270
- function xt(l) {
271
- te("selectDatapoint", l), e.value.style.chart.dialog.show && (Ne.value = l.datapoints.map((o) => ({
272
- name: o.name,
273
- color: o.color,
274
- type: "line",
275
- useArea: !0,
276
- smooth: e.value.style.chart.areas.smooth,
277
- series: o.values
278
- })), R.value = l, Le.value = Jt({
279
- ...e.value.style.chart.dialog.xyChart,
280
- responsive: !0,
281
- // Overriding
282
- chart: {
283
- ...e.value.style.chart.dialog.xyChart.chart,
284
- grid: {
285
- ...e.value.style.chart.dialog.xyChart.chart.grid,
286
- labels: {
287
- ...e.value.style.chart.dialog.xyChart.chart.grid.labels,
288
- xAxisLabels: {
289
- ...e.value.style.chart.dialog.xyChart.chart.grid.labels.xAxisLabels,
290
- values: e.value.style.chart.xAxis.labels.values,
291
- // Overriding
292
- datetimeFormatter: e.value.style.chart.xAxis.labels.datetimeFormatter
293
- // Overriding
294
- }
295
- }
296
- },
297
- tooltip: {
298
- ...e.value.style.chart.dialog.xyChart.chart.tooltip,
299
- showTimeLabel: e.value.style.chart.xAxis.labels.values.length > 0
300
- // Overriding
301
- }
302
- }
303
- }), le.value && le.value.open());
304
- }
305
- const ue = u(null);
306
- function kt(l) {
307
- ue.value = l;
308
- }
309
- function At() {
310
- ue.value = null;
311
- }
312
- const j = u(!1);
313
- function ce() {
314
- j.value = !j.value;
315
- }
316
- function Fe() {
317
- B.value.showTable = !B.value.showTable;
318
- }
319
- const De = f(() => ({ body: E.value.flatMap((t) => t.datapoints.flatMap((s) => ({
320
- ...s,
321
- rowName: `${t.name}: ${s.name}`
322
- }))).map((t) => [
323
- {
324
- name: t.rowName,
325
- color: t.color
326
- },
327
- ...t.values
328
- ]) })), Y = f(() => {
329
- const l = [
330
- e.value.table.columnNames.series,
331
- ...W.value.map((s) => s.text)
332
- ], o = {
333
- th: {
334
- backgroundColor: e.value.table.th.backgroundColor,
335
- color: e.value.table.th.color,
336
- outline: e.value.table.th.outline
337
- },
338
- td: {
339
- backgroundColor: e.value.table.td.backgroundColor,
340
- color: e.value.table.td.color,
341
- outline: e.value.table.td.outline
342
- },
343
- breakpoint: e.value.table.responsiveBreakpoint
344
- };
345
- return {
346
- colNames: [
347
- e.value.table.columnNames.series,
348
- ...W.value.map((s) => s.text)
349
- ],
350
- head: l,
351
- body: De.value.body,
352
- config: o
353
- };
354
- });
355
- function Ie(l = null) {
356
- Dt(() => {
357
- const o = [
358
- [e.value.table.columnNames.series, ...W.map((a) => [a.text])],
359
- ...De.value.body.map((a, h) => [a[0].name, ...a.slice(1)])
360
- ], t = [
361
- [e.value.style.chart.title.text],
362
- [e.value.style.chart.title.subtitle.text]
363
- ].concat(o), s = qt(t);
364
- l ? l(s) : Kt({
365
- csvContent: s,
366
- title: e.value.style.chart.title.text || "vue-ui-ridgeline"
367
- });
368
- });
369
- }
370
- function wt() {
371
- return E.value;
372
- }
373
- async function $t({ scale: l = 2 } = {}) {
374
- if (!T.value) return;
375
- const { width: o, height: t } = T.value.getBoundingClientRect(), s = o / t, { imageUri: a, base64: h } = await nl({ domElement: T.value, base64: !0, img: !0, scale: l });
376
- return {
377
- imageUri: a,
378
- base64: h,
379
- title: e.value.style.chart.title.text,
380
- width: o,
381
- height: t,
382
- aspectRatio: s
383
- };
384
- }
385
- return et({
386
- getData: wt,
387
- getImage: $t,
388
- generateImage: Pe,
389
- generatePdf: Me,
390
- generateCsv: Ie,
391
- toggleAnnotator: ce,
392
- toggleTable: Fe,
393
- toggleFullscreen: Oe
394
- }), (l, o) => (r(), n("div", {
395
- ref_key: "ridgelineChart",
396
- ref: T,
397
- class: q(`vue-ui-ridgeline ${H.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
398
- id: `vue-ui-ridgeline_${w.value}`,
399
- style: _({
400
- fontFamily: e.value.style.fontFamily,
401
- width: "100%",
402
- textAlign: "center",
403
- background: e.value.style.chart.backgroundColor,
404
- height: e.value.responsive ? "100%" : void 0
405
- }),
406
- onMouseenter: o[4] || (o[4] = () => i(we)(!0)),
407
- onMouseleave: o[5] || (o[5] = () => i(we)(!1))
408
- }, [
409
- e.value.userOptions.buttons.annotator && i(se) ? (r(), P(i(rt), {
410
- key: 0,
411
- color: e.value.style.chart.color,
412
- backgroundColor: e.value.style.chart.backgroundColor,
413
- active: j.value,
414
- svgRef: i(se),
415
- onClose: ce
416
- }, null, 8, ["color", "backgroundColor", "active", "svgRef"])) : c("", !0),
417
- p(l.$slots, "userConfig", {}, void 0, !0),
418
- dt.value ? (r(), n("div", {
419
- key: 1,
420
- ref_key: "noTitle",
421
- ref: ge,
422
- class: "vue-data-ui-no-title-space",
423
- style: "height:36px; width: 100%;background:transparent"
424
- }, null, 512)) : c("", !0),
425
- e.value.style.chart.title.text ? (r(), n("div", {
426
- key: 2,
427
- ref_key: "chartTitle",
428
- ref: de,
429
- style: "width:100%;background:transparent;padding-bottom:24px"
430
- }, [
431
- (r(), P(sl, {
432
- key: `title_${pe.value}`,
433
- config: {
434
- title: {
435
- cy: "ridgeline-div-title",
436
- ...e.value.style.chart.title
437
- },
438
- subtitle: {
439
- cy: "ridgeline-div-subtitle",
440
- ...e.value.style.chart.title.subtitle
441
- }
442
- }
443
- }, null, 8, ["config"]))
444
- ], 512)) : c("", !0),
445
- e.value.userOptions.show && L.value && (i($e) || i(ae)) ? (r(), P(i(it), {
446
- ref: "details",
447
- key: `user_option_${be.value}`,
448
- backgroundColor: e.value.style.chart.backgroundColor,
449
- color: e.value.style.chart.color,
450
- isPrinting: i(Ce),
451
- isImaging: i(_e),
452
- uid: w.value,
453
- hasTooltip: !1,
454
- callbacks: e.value.userOptions.callbacks,
455
- hasPdf: e.value.userOptions.buttons.pdf,
456
- hasImg: e.value.userOptions.buttons.img,
457
- hasXls: e.value.userOptions.buttons.csv,
458
- hasTable: e.value.userOptions.buttons.table,
459
- hasLabel: !1,
460
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
461
- isFullscreen: H.value,
462
- printScale: e.value.userOptions.print.scale,
463
- chartElement: T.value,
464
- position: e.value.userOptions.position,
465
- isTooltip: !1,
466
- titles: { ...e.value.userOptions.buttonTitles },
467
- hasAnnotator: e.value.userOptions.buttons.annotator,
468
- isAnnotation: j.value,
469
- style: _({
470
- visibility: i($e) ? i(ae) ? "visible" : "hidden" : "visible"
471
- }),
472
- onToggleFullscreen: Oe,
473
- onGeneratePdf: i(Me),
474
- onGenerateCsv: Ie,
475
- onGenerateImage: i(Pe),
476
- onToggleTable: Fe,
477
- onToggleAnnotator: ce
478
- }, Ge({ _: 2 }, [
479
- l.$slots.menuIcon ? {
480
- name: "menuIcon",
481
- fn: m(({ isOpen: t, color: s }) => [
482
- p(l.$slots, "menuIcon", K(J({ isOpen: t, color: s })), void 0, !0)
483
- ]),
484
- key: "0"
485
- } : void 0,
486
- l.$slots.optionTooltip ? {
487
- name: "optionTooltip",
488
- fn: m(() => [
489
- p(l.$slots, "optionTooltip", {}, void 0, !0)
490
- ]),
491
- key: "1"
492
- } : void 0,
493
- l.$slots.optionPdf ? {
494
- name: "optionPdf",
495
- fn: m(() => [
496
- p(l.$slots, "optionPdf", {}, void 0, !0)
497
- ]),
498
- key: "2"
499
- } : void 0,
500
- l.$slots.optionCsv ? {
501
- name: "optionCsv",
502
- fn: m(() => [
503
- p(l.$slots, "optionCsv", {}, void 0, !0)
504
- ]),
505
- key: "3"
506
- } : void 0,
507
- l.$slots.optionImg ? {
508
- name: "optionImg",
509
- fn: m(() => [
510
- p(l.$slots, "optionImg", {}, void 0, !0)
511
- ]),
512
- key: "4"
513
- } : void 0,
514
- l.$slots.optionTable ? {
515
- name: "optionTable",
516
- fn: m(() => [
517
- p(l.$slots, "optionTable", {}, void 0, !0)
518
- ]),
519
- key: "5"
520
- } : void 0,
521
- l.$slots.optionFullscreen ? {
522
- name: "optionFullscreen",
523
- fn: m(({ toggleFullscreen: t, isFullscreen: s }) => [
524
- p(l.$slots, "optionFullscreen", K(J({ toggleFullscreen: t, isFullscreen: s })), void 0, !0)
525
- ]),
526
- key: "6"
527
- } : void 0,
528
- l.$slots.optionAnnotator ? {
529
- name: "optionAnnotator",
530
- fn: m(({ toggleAnnotator: t, isAnnotator: s }) => [
531
- p(l.$slots, "optionAnnotator", K(J({ toggleAnnotator: t, isAnnotator: s })), void 0, !0)
532
- ]),
533
- key: "7"
534
- } : void 0
535
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "callbacks", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "printScale", "chartElement", "position", "titles", "hasAnnotator", "isAnnotation", "style", "onGeneratePdf", "onGenerateImage"])) : c("", !0),
536
- L.value ? (r(), n("svg", {
537
- key: 4,
538
- ref_key: "svgRef",
539
- ref: se,
540
- xmlns: i(Ut),
541
- class: q({ "vue-data-ui-fullscreen--on": H.value, "vue-data-ui-fulscreen--off": !H.value }),
542
- viewBox: `0 0 ${y.value.width <= 0 ? 10 : y.value.width} ${b.value.fullHeight <= 0 ? 10 : b.value.fullHeight}`,
543
- style: _(`max-width:100%;overflow:visible;background:transparent;color:${e.value.style.chart.color};${e.value.responsive ? `height: ${ke.value}px; width: 100%;` : ""}`)
544
- }, [
545
- We(i(ot)),
546
- d("defs", null, [
547
- (r(!0), n(g, null, A(ie.value, (t, s) => (r(), n("linearGradient", {
548
- id: `gradient-${t.id}-${w.value}`,
549
- x1: "50%",
550
- y1: "0%",
551
- x2: "50%",
552
- y2: "100%"
553
- }, [
554
- d("stop", {
555
- offset: "0%",
556
- "stop-color": t.color,
557
- "stop-opacity": "1"
558
- }, null, 8, hl),
559
- d("stop", {
560
- offset: "30%",
561
- "stop-color": t.color,
562
- "stop-opacity": "0.7"
563
- }, null, 8, dl),
564
- d("stop", {
565
- offset: "70%",
566
- "stop-color": t.color,
567
- "stop-opacity": "0.3"
568
- }, null, 8, yl),
569
- d("stop", {
570
- offset: "100%",
571
- "stop-color": t.color,
572
- "stop-opacity": "0.1"
573
- }, null, 8, fl)
574
- ], 8, vl))), 256)),
575
- (r(!0), n(g, null, A(E.value, (t, s) => (r(), n(g, null, [
576
- (r(!0), n(g, null, A(t.datapoints, (a, h) => (r(), n("linearGradient", {
577
- key: `grad${a.id}`,
578
- id: `gradient-single-${w.value}-${a.uid}`,
579
- x1: "50%",
580
- y1: "0%",
581
- x2: "50%",
582
- y2: "100%"
583
- }, [
584
- d("stop", {
585
- offset: "0%",
586
- "stop-color": a.color,
587
- "stop-opacity": "1"
588
- }, null, 8, pl),
589
- d("stop", {
590
- offset: "30%",
591
- "stop-color": a.color,
592
- "stop-opacity": "0.7"
593
- }, null, 8, ml),
594
- d("stop", {
595
- offset: "70%",
596
- "stop-color": a.color,
597
- "stop-opacity": "0.3"
598
- }, null, 8, bl),
599
- d("stop", {
600
- offset: "100%",
601
- "stop-color": a.color,
602
- "stop-opacity": "0.1"
603
- }, null, 8, xl)
604
- ], 8, gl))), 128))
605
- ], 64))), 256))
606
- ]),
607
- (r(!0), n(g, null, A(E.value, (t, s) => (r(), n("g", {
608
- key: `ds-${s}`
609
- }, [
610
- (r(!0), n(g, null, A(t.datapoints, (a, h) => (r(), n("g", {
611
- key: a.id
612
- }, [
613
- l.$slots.pattern ? (r(), n("g", kl, [
614
- d("defs", null, [
615
- p(l.$slots, "pattern", je({ ref_for: !0 }, { datapointIndex: s, seriesIndex: h, patternId: `pattern_${w.value}_${a.uid}` }), void 0, !0)
616
- ])
617
- ])) : c("", !0),
618
- d("path", {
619
- fill: l.$slots.pattern ? `url(#pattern_${w.value}_${a.uid})` : e.value.style.chart.backgroundColor,
620
- stroke: "none",
621
- "stroke-linecap": "round",
622
- d: e.value.style.chart.areas.smooth ? a.smoothPath : a.straightPath,
623
- style: _({
624
- opacity: e.value.style.chart.areas.opacity
625
- })
626
- }, null, 12, Al),
627
- d("path", {
628
- fill: "none",
629
- stroke: e.value.style.chart.areas.stroke.useSerieColor ? a.color : e.value.style.chart.areas.stroke.color,
630
- "stroke-width": e.value.style.chart.areas.strokeWidth,
631
- d: e.value.style.chart.areas.smooth ? a.smoothPathRidge : a.straightPathRidge,
632
- "stroke-linecap": "round",
633
- "stroke-linejoin": "round",
634
- class: q({ "vue-ui-ridgeline-animate": e.value.useCssAnimation }),
635
- style: _({
636
- strokeDasharray: a.pathLength,
637
- strokeDashoffset: e.value.useCssAnimation ? a.pathLength : 0
638
- })
639
- }, null, 14, wl),
640
- d("path", {
641
- fill: e.value.style.chart.areas.useGradient ? e.value.style.chart.areas.useCommonColor ? `url(#gradient-${a.id}-${w.value})` : `url(#gradient-single-${w.value}-${a.uid})` : a.color,
642
- stroke: "none",
643
- d: e.value.style.chart.areas.smooth ? a.smoothPath : a.straightPath,
644
- "stroke-linecap": "round",
645
- "stroke-linejoin": "round",
646
- class: q({ "vue-ui-ridgeline-animate": e.value.useCssAnimation }),
647
- style: _({
648
- strokeDasharray: a.pathLength,
649
- strokeDashoffset: e.value.useCssAnimation ? a.pathLength : 0
650
- })
651
- }, null, 14, $l),
652
- e.value.style.chart.zeroLine.show ? (r(), n("path", {
653
- key: 1,
654
- stroke: e.value.style.chart.zeroLine.useSerieColor ? a.color : e.value.style.chart.zeroLine.stroke,
655
- "stroke-dasharray": e.value.style.chart.zeroLine.strokeDasharray,
656
- "stroke-width": e.value.style.chart.zeroLine.strokeWidth,
657
- d: a.zeroPath,
658
- "stroke-linecap": "round"
659
- }, null, 8, Cl)) : c("", !0),
660
- e.value.style.chart.areas.maxPoint.show && a.plots.length > 1 ? (r(!0), n(g, { key: 2 }, A(a.plots, (C) => (r(), n(g, null, [
661
- C.isMaxPoint ? (r(), n("line", {
662
- key: 0,
663
- x1: C.x,
664
- y1: C.y,
665
- x2: C.x,
666
- y2: C.zero,
667
- stroke: e.value.style.chart.areas.maxPoint.adaptStrokeToBackground ? i(Gt)(a.color) : e.value.style.chart.areas.maxPoint.stroke,
668
- "stroke-width": e.value.style.chart.areas.maxPoint.strokeWidth,
669
- "stroke-linecap": "round",
670
- "stroke-dasharray": e.value.style.chart.areas.maxPoint.strokeDasharray
671
- }, null, 8, _l)) : c("", !0)
672
- ], 64))), 256)) : c("", !0),
673
- a.plots.length === 1 ? (r(), n("circle", {
674
- key: 3,
675
- cx: a.plots[0].x,
676
- cy: a.plots[0].y,
677
- stroke: e.value.style.chart.selector.dot.stroke,
678
- "stroke-width": e.value.style.chart.selector.dot.strokeWidth,
679
- r: e.value.style.chart.selector.dot.radius,
680
- fill: e.value.style.chart.selector.dot.useDatapointColor ? a.color : e.value.style.chart.selector.dot.fill,
681
- style: {
682
- pointerEvents: "none"
683
- }
684
- }, null, 8, Ml)) : c("", !0)
685
- ]))), 128)),
686
- d("text", {
687
- x: t.label.x,
688
- y: t.label.y,
689
- "text-anchor": "end",
690
- "font-size": e.value.style.chart.yAxis.labels.fontSize,
691
- "font-weight": e.value.style.chart.yAxis.labels.bold ? "bold" : "normal",
692
- fill: e.value.style.chart.yAxis.labels.color,
693
- style: _({
694
- cursor: e.value.style.chart.dialog.show ? "pointer" : "default"
695
- }),
696
- "text-decoration": e.value.style.chart.dialog.show && (ue.value === s || R.value && t.uid === R.value.uid) ? "underline" : "",
697
- onMouseenter: (a) => kt(s),
698
- onMouseleave: At,
699
- onClick: (a) => xt(t)
700
- }, V(t.name), 45, Pl)
701
- ]))), 128)),
702
- e.value.style.chart.xAxis.labels.values.length ? (r(), n("g", Tl, [
703
- (r(!0), n(g, null, A(X.value, (t, s) => p(l.$slots, "time-label", je({ ref_for: !0 }, {
704
- show: t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && !e.value.style.chart.xAxis.labels.showOnlyAtModulo || t && e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && (s === 0 || s === X.value.length - 1) || t && v.value && v.value.index === s || t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && e.value.style.chart.xAxis.labels.showOnlyAtModulo && s % Math.floor(X.value.length / e.value.style.chart.xAxis.labels.modulo) === 0,
705
- fontSize: e.value.style.chart.xAxis.labels.fontSize,
706
- content: t.label,
707
- textAnchor: e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
708
- fill: e.value.style.chart.xAxis.labels.color,
709
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
710
- x: t.selectorX,
711
- y: b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY
712
- }), () => [
713
- t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && !e.value.style.chart.xAxis.labels.showOnlyAtModulo || t && e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && (s === 0 || s === X.value.length - 1) || t && v.value && v.value.index === s || t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && e.value.style.chart.xAxis.labels.showOnlyAtModulo && s % Math.floor(X.value.length / e.value.style.chart.xAxis.labels.modulo) === 0 ? (r(), n("g", Sl, [
714
- String(t.label).includes(`
715
- `) ? (r(), n("text", {
716
- key: 1,
717
- "font-size": e.value.style.chart.xAxis.labels.fontSize,
718
- fill: e.value.style.chart.xAxis.labels.color,
719
- "font-weight": e.value.style.chart.xAxis.labels.bold ? "bold" : "normal",
720
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
721
- "text-anchor": e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
722
- style: _({
723
- opacity: v.value ? v.value.index === s ? 1 : 0.2 : 1
724
- }),
725
- innerHTML: i(Wt)({
726
- content: String(t.label),
727
- fontSize: e.value.style.chart.xAxis.labels.fontSize,
728
- fill: e.value.style.chart.xAxis.labels.color,
729
- x: 0,
730
- y: 0
731
- })
732
- }, null, 12, Ol)) : (r(), n("text", {
733
- key: 0,
734
- "font-size": e.value.style.chart.xAxis.labels.fontSize,
735
- fill: e.value.style.chart.xAxis.labels.color,
736
- "font-weight": e.value.style.chart.xAxis.labels.bold ? "bold" : "normal",
737
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
738
- "text-anchor": e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
739
- style: _({
740
- opacity: v.value ? v.value.index === s ? 1 : 0.2 : 1
741
- })
742
- }, V(t.label), 13, zl))
743
- ])) : c("", !0)
744
- ], !0)), 256))
745
- ])) : c("", !0),
746
- d("g", null, [
747
- (r(!0), n(g, null, A(X.value, (t, s) => (r(), n("rect", {
748
- x: t.x,
749
- y: t.y,
750
- width: t.width < 0 ? 0.1 : t.width,
751
- height: t.height < 0 ? 0.1 : t.height,
752
- fill: "transparent",
753
- onMouseenter: (a) => v.value = t,
754
- onMouseleave: o[0] || (o[0] = (a) => v.value = null),
755
- onClick: () => ft(t)
756
- }, null, 40, Ll))), 256)),
757
- e.value.style.chart.selector.show && v.value ? (r(), n("line", {
758
- key: 0,
759
- x1: v.value.selectorX,
760
- x2: v.value.selectorX,
761
- y1: v.value.y,
762
- y2: v.value.y + v.value.height - $.value / 2,
763
- stroke: e.value.style.chart.selector.stroke,
764
- "stroke-width": e.value.style.chart.selector.strokeWidth,
765
- "stroke-dasharray": e.value.style.chart.selector.strokeDasharray,
766
- "stroke-linecap": "round",
767
- style: { pointerEvents: "none" }
768
- }, null, 8, Nl)) : c("", !0),
769
- v.value ? (r(!0), n(g, { key: 1 }, A(E.value, (t) => (r(), n(g, null, [
770
- (r(!0), n(g, null, A(t.datapoints, (s) => (r(), n(g, null, [
771
- (r(!0), n(g, null, A(s.plots, (a, h) => (r(), n(g, null, [
772
- v.value && v.value.index === h ? (r(), n("circle", {
773
- key: 0,
774
- cx: a.x,
775
- cy: a.y,
776
- stroke: e.value.style.chart.selector.dot.stroke,
777
- "stroke-width": e.value.style.chart.selector.dot.strokeWidth,
778
- r: e.value.style.chart.selector.dot.radius,
779
- fill: e.value.style.chart.selector.dot.useDatapointColor ? s.color : e.value.style.chart.selector.dot.fill,
780
- style: {
781
- pointerEvents: "none"
782
- }
783
- }, null, 8, Fl)) : c("", !0),
784
- v.value && v.value.index === h ? (r(), n("text", {
785
- key: 1,
786
- x: ze(
787
- a.x,
788
- i(Z)(
789
- e.value.style.chart.selector.labels.formatter,
790
- a.value,
791
- i(ee)({
792
- p: e.value.style.chart.xAxis.labels.prefix,
793
- v: a.value,
794
- s: e.value.style.chart.xAxis.labels.suffix,
795
- r: e.value.style.chart.selector.labels.rounding
796
- })
797
- ),
798
- e.value.style.chart.selector.labels.fontSize
799
- ) ? a.x - e.value.style.chart.selector.labels.fontSize / 2 : a.x + e.value.style.chart.selector.labels.fontSize / 2,
800
- y: a.y + e.value.style.chart.selector.labels.fontSize / 3,
801
- "text-anchor": ze(
802
- a.x,
803
- i(Z)(
804
- e.value.style.chart.selector.labels.formatter,
805
- a.value,
806
- i(ee)({
807
- p: e.value.style.chart.xAxis.labels.prefix,
808
- v: a.value,
809
- s: e.value.style.chart.xAxis.labels.suffix,
810
- r: e.value.style.chart.selector.labels.rounding
811
- })
812
- ),
813
- e.value.style.chart.selector.labels.fontSize
814
- ) ? "end" : "start",
815
- "font-size": e.value.style.chart.selector.labels.fontSize,
816
- fill: e.value.style.chart.selector.labels.color,
817
- style: {
818
- pointerEvents: "none"
819
- }
820
- }, V(i(Z)(
821
- e.value.style.chart.selector.labels.formatter,
822
- a.value,
823
- i(ee)({
824
- p: e.value.style.chart.xAxis.labels.prefix,
825
- v: a.value,
826
- s: e.value.style.chart.xAxis.labels.suffix,
827
- r: e.value.style.chart.selector.labels.rounding
828
- })
829
- )), 9, Dl)) : c("", !0)
830
- ], 64))), 256))
831
- ], 64))), 256))
832
- ], 64))), 256)) : c("", !0)
833
- ]),
834
- p(l.$slots, "svg", { svg: y.value }, void 0, !0)
835
- ], 14, cl)) : c("", !0),
836
- l.$slots.watermark ? (r(), n("div", Il, [
837
- p(l.$slots, "watermark", K(J({ isPrinting: i(Ce) || i(_e) })), void 0, !0)
838
- ])) : c("", !0),
839
- L.value ? c("", !0) : (r(), P(i(nt), {
840
- key: 6,
841
- config: {
842
- type: "ridgeline",
843
- style: {
844
- backgroundColor: e.value.style.chart.backgroundColor,
845
- ridgeline: {
846
- color: "#CCCCCC"
847
- }
848
- }
849
- }
850
- }, null, 8, ["config"])),
851
- d("div", {
852
- ref_key: "chartLegend",
853
- ref: ye
854
- }, [
855
- e.value.style.chart.legend.show ? (r(), P(al, {
856
- key: `legend_${me.value}`,
857
- legendSet: ie.value,
858
- config: bt.value,
859
- onClickMarker: o[1] || (o[1] = ({ legend: t }) => Te(t.id))
860
- }, Ge({
861
- item: m(({ legend: t }) => [
862
- d("div", {
863
- style: _(`opacity:${z.value.includes(t.id) ? 0.5 : 1}`),
864
- onClick: (s) => t.segregate()
865
- }, V(t.name), 13, Rl)
866
- ]),
867
- _: 2
868
- }, [
869
- l.$slots.pattern ? {
870
- name: "legend-pattern",
871
- fn: m(({ legend: t, index: s }) => [
872
- We(ol, {
873
- shape: t.shape,
874
- radius: 30,
875
- stroke: "none",
876
- plot: { x: 30, y: 30 },
877
- fill: `url(#pattern_${w.value}_${s})`
878
- }, null, 8, ["shape", "fill"])
879
- ]),
880
- key: "0"
881
- } : void 0
882
- ]), 1032, ["legendSet", "config"])) : c("", !0),
883
- p(l.$slots, "legend", { legend: ie.value }, void 0, !0)
884
- ], 512),
885
- l.$slots.source ? (r(), n("div", {
886
- key: 7,
887
- ref_key: "source",
888
- ref: fe,
889
- dir: "auto"
890
- }, [
891
- p(l.$slots, "source", {}, void 0, !0)
892
- ], 512)) : c("", !0),
893
- L.value ? (r(), P(i(lt), {
894
- key: 8,
895
- hideDetails: "",
896
- config: {
897
- open: B.value.showTable,
898
- maxHeight: 1e4,
899
- body: {
900
- backgroundColor: e.value.style.chart.backgroundColor,
901
- color: e.value.style.chart.color
902
- },
903
- head: {
904
- backgroundColor: e.value.style.chart.backgroundColor,
905
- color: e.value.style.chart.color
906
- }
907
- }
908
- }, {
909
- content: m(() => [
910
- (r(), P(i(st), {
911
- key: `table_${vt.value}`,
912
- colNames: Y.value.colNames,
913
- head: Y.value.head,
914
- body: Y.value.body,
915
- config: Y.value.config,
916
- title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` :${e.value.style.chart.title.subtitle.text}` : ""}`,
917
- onClose: o[2] || (o[2] = (t) => B.value.showTable = !1)
918
- }, {
919
- th: m(({ th: t }) => [
920
- d("div", { innerHTML: t }, null, 8, Xl)
921
- ]),
922
- td: m(({ td: t }) => [
923
- Ye(V(t.name ? t.name : i(Z)(
924
- e.value.style.chart.selector.labels.formatter,
925
- t,
926
- i(ee)({
927
- p: e.value.style.chart.xAxis.labels.prefix,
928
- v: t,
929
- s: e.value.style.chart.xAxis.labels.suffix,
930
- r: e.value.table.td.roundingValue
931
- })
932
- )), 1)
933
- ]),
934
- _: 1
935
- }, 8, ["colNames", "head", "body", "config", "title"]))
936
- ]),
937
- _: 1
938
- }, 8, ["config"])) : c("", !0),
939
- e.value.style.chart.dialog.show ? (r(), P(i(at), {
940
- key: 9,
941
- ref_key: "dialog",
942
- ref: le,
943
- onClose: o[3] || (o[3] = (t) => R.value = null),
944
- backgroundColor: e.value.style.chart.dialog.backgroundColor,
945
- color: e.value.style.chart.dialog.color,
946
- headerBg: e.value.style.chart.dialog.header.backgroundColor,
947
- headerColor: e.value.style.chart.dialog.header.color,
948
- isFullscreen: H.value,
949
- fullscreenParent: T.value,
950
- withPadding: ""
951
- }, {
952
- title: m(() => [
953
- Ye(V(R.value.name), 1)
954
- ]),
955
- default: m(() => [
956
- R.value ? (r(), P(i(ut), {
957
- key: 0,
958
- config: Le.value,
959
- dataset: Ne.value
960
- }, null, 8, ["config", "dataset"])) : c("", !0)
961
- ]),
962
- _: 1
963
- }, 8, ["backgroundColor", "color", "headerBg", "headerColor", "isFullscreen", "fullscreenParent"])) : c("", !0)
964
- ], 46, ul));
965
- }
966
- }, ea = /* @__PURE__ */ il(El, [["__scopeId", "data-v-eede0a56"]]);
967
- export {
968
- ea as default
969
- };