vue-data-ui 3.0.22 → 3.1.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 (109) hide show
  1. package/dist/{Arrow-C3_2GkYQ.js → Arrow-DvG07exK.js} +1 -1
  2. package/dist/{BaseDraggableDialog-BhxUDwEm.js → BaseDraggableDialog-O7900pGp.js} +72 -59
  3. package/dist/{BaseIcon-B717hnWR.js → BaseIcon-DHtro8us.js} +1 -1
  4. package/dist/{useLoading-D7YHNtLX.js → BaseScanner-BgWxam9d.js} +11 -11
  5. package/dist/{ColorPicker-CH5_RNaK.js → ColorPicker-CpWzNn4r.js} +2 -2
  6. package/dist/DataTable-DJjA2_wf.js +140 -0
  7. package/dist/Legend-2-dC7DVb.js +72 -0
  8. package/dist/{NonSvgPenAndPaper-DCJGSteM.js → NonSvgPenAndPaper-DHeE4Yuv.js} +3 -3
  9. package/dist/{PackageVersion-CE7HSich.js → PackageVersion-DU12WH3O.js} +1 -1
  10. package/dist/{PenAndPaper-BMHsOtT8.js → PenAndPaper-B7QEDgx4.js} +3 -3
  11. package/dist/{Shape-C3J8aKNH.js → Shape-Dj2Hl33H.js} +1 -1
  12. package/dist/{Slicer-BEBDljWA.js → Slicer-D99HytqX.js} +2 -2
  13. package/dist/{SparkTooltip-CVSZQtoP.js → SparkTooltip-B-wL07rI.js} +1 -1
  14. package/dist/{Title-BL-IjQmj.js → Title-Dq2_Z9kR.js} +1 -1
  15. package/dist/{Tooltip-CCnDaboi.js → Tooltip-Y219DXZO.js} +1 -1
  16. package/dist/{UserOptions-BWMV0_Ze.js → UserOptions-BuGfCdAY.js} +2 -2
  17. package/dist/{dom-to-png-DwUGURhV.js → dom-to-png-BhciAKaM.js} +1 -1
  18. package/dist/{img-DsVqerdt.js → img-JOqdlnUs.js} +1 -1
  19. package/dist/{index-BHb_mcWF.js → index-CDQbCd41.js} +37 -2
  20. package/dist/{pdf-Ckt8JtYf.js → pdf-Dd-LIJqz.js} +1 -1
  21. package/dist/style.css +1 -1
  22. package/dist/types/vue-data-ui.d.cts +35 -0
  23. package/dist/types/vue-data-ui.d.ts +35 -0
  24. package/dist/{useAutoSizeLabelsInsideViewbox-Cy946l1e.js → useAutoSizeLabelsInsideViewbox-Bky5KGFZ.js} +1 -1
  25. package/dist/{useNestedProp-aC9S6EFJ.js → useNestedProp-BPEHGiYX.js} +1 -1
  26. package/dist/{usePrinter-B7rhbRrT.js → usePrinter-Bnl1YeUU.js} +2 -2
  27. package/dist/{vue-data-ui-Bu7qDtf0.js → vue-data-ui-DcNYz3cZ.js} +64 -64
  28. package/dist/vue-data-ui.js +1 -1
  29. package/dist/vue-ui-3d-bar-BNIFAeN-.js +1369 -0
  30. package/dist/{vue-ui-accordion-DsnF0JuK.js → vue-ui-accordion-Bf_LHFFX.js} +3 -3
  31. package/dist/{vue-ui-age-pyramid-s8xyb3Gf.js → vue-ui-age-pyramid-Bz-l1afR.js} +333 -286
  32. package/dist/{vue-ui-annotator-DRacM62z.js → vue-ui-annotator-BcfRH2BF.js} +2 -2
  33. package/dist/{vue-ui-bullet-DdDrdyOJ.js → vue-ui-bullet-DK1aM9fX.js} +8 -8
  34. package/dist/{vue-ui-candlestick-BsNnInNt.js → vue-ui-candlestick-D6mMjvtu.js} +453 -406
  35. package/dist/{vue-ui-carousel-table-Ci9mrUBd.js → vue-ui-carousel-table-Vp5f238W.js} +4 -4
  36. package/dist/{vue-ui-chestnut-fHfJNK0V.js → vue-ui-chestnut-BKc4v-lf.js} +509 -459
  37. package/dist/vue-ui-chord-CquhRjf0.js +1100 -0
  38. package/dist/vue-ui-circle-pack-D6zLgxa3.js +755 -0
  39. package/dist/{vue-ui-cursor-Bk5LHg5V.js → vue-ui-cursor-DIXb2S93.js} +2 -2
  40. package/dist/{vue-ui-dashboard-CjZMEYs6.js → vue-ui-dashboard-DmiriAK7.js} +62 -62
  41. package/dist/{vue-ui-digits-nDIvHyRB.js → vue-ui-digits-CLAIo9gW.js} +2 -2
  42. package/dist/{vue-ui-donut-CF9FdxfC.js → vue-ui-donut-C8h_tCSO.js} +477 -431
  43. package/dist/{vue-ui-donut-evolution-f5k-Yu3N.js → vue-ui-donut-evolution-C3r0YhKz.js} +482 -435
  44. package/dist/{vue-ui-dumbbell-Dm3gsrzi.js → vue-ui-dumbbell-D-t4M00E.js} +443 -398
  45. package/dist/vue-ui-flow-D7_D_UNm.js +900 -0
  46. package/dist/vue-ui-funnel-B0QOfZRz.js +666 -0
  47. package/dist/vue-ui-galaxy-Ccw5uNes.js +744 -0
  48. package/dist/{vue-ui-gauge-DkDpUAN7.js → vue-ui-gauge-DvW7nFmK.js} +8 -8
  49. package/dist/{vue-ui-gizmo-BD5fLs8r.js → vue-ui-gizmo-WGQxvGPy.js} +4 -4
  50. package/dist/vue-ui-heatmap-BQkLujyp.js +1127 -0
  51. package/dist/{vue-ui-history-plot-ICoBBO-y.js → vue-ui-history-plot-eU33r_Ot.js} +408 -361
  52. package/dist/{vue-ui-kpi-Dp2M2EFo.js → vue-ui-kpi-CKg2i71M.js} +3 -3
  53. package/dist/{vue-ui-mini-loader-C5672jjA.js → vue-ui-mini-loader-BmkGQsm_.js} +2 -2
  54. package/dist/vue-ui-molecule-Dlu0hjSg.js +702 -0
  55. package/dist/{vue-ui-mood-radar-B-qhYUcB.js → vue-ui-mood-radar-DQaxfw9R.js} +342 -291
  56. package/dist/{vue-ui-nested-donuts-V6BvP3pF.js → vue-ui-nested-donuts-Djj9Aw_i.js} +548 -502
  57. package/dist/{vue-ui-onion-BKqqbWbg.js → vue-ui-onion-ZgsErXis.js} +363 -317
  58. package/dist/vue-ui-parallel-coordinate-plot-B5fB22Jc.js +979 -0
  59. package/dist/vue-ui-quadrant-CMevCtXH.js +1483 -0
  60. package/dist/{vue-ui-quick-chart-BVZSdQeT.js → vue-ui-quick-chart-DcparKSX.js} +7 -7
  61. package/dist/vue-ui-radar-DFbxoKCK.js +858 -0
  62. package/dist/{vue-ui-rating-CncrxDCY.js → vue-ui-rating-ZUpxCWrk.js} +2 -2
  63. package/dist/{vue-ui-relation-circle-VYM1dclx.js → vue-ui-relation-circle-eNKJY4Sx.js} +8 -8
  64. package/dist/vue-ui-ridgeline-D4shpQZd.js +1204 -0
  65. package/dist/vue-ui-rings-TdTHMbsa.js +785 -0
  66. package/dist/{vue-ui-scatter-D2b-u5dv.js → vue-ui-scatter-CVuV9ljU.js} +594 -548
  67. package/dist/{vue-ui-skeleton-BTuBaaE_.js → vue-ui-skeleton-CFxBU2-p.js} +3 -3
  68. package/dist/{vue-ui-smiley-D1UxJNbV.js → vue-ui-smiley-Har3B3aQ.js} +2 -2
  69. package/dist/{vue-ui-spark-trend-BCP0BWMI.js → vue-ui-spark-trend-FPk-XEwI.js} +4 -4
  70. package/dist/{vue-ui-sparkbar-eBo-RSvE.js → vue-ui-sparkbar-V3eJ0w0t.js} +4 -4
  71. package/dist/{vue-ui-sparkgauge-DberOXWX.js → vue-ui-sparkgauge-DKTGkWnJ.js} +4 -4
  72. package/dist/{vue-ui-sparkhistogram-CoKQGG5X.js → vue-ui-sparkhistogram-DJsgFwHs.js} +5 -5
  73. package/dist/{vue-ui-sparkline-B_L4UNES.js → vue-ui-sparkline-Dmrm5SL5.js} +4 -4
  74. package/dist/{vue-ui-sparkstackbar-iAaRIyqb.js → vue-ui-sparkstackbar-B0Pl7VMI.js} +4 -4
  75. package/dist/{vue-ui-stackbar-B_0PJ7R2.js → vue-ui-stackbar-CNsgBPhj.js} +525 -479
  76. package/dist/{vue-ui-strip-plot-CWkA4l9P.js → vue-ui-strip-plot-CYAWwYOM.js} +390 -343
  77. package/dist/{vue-ui-table-CILVy7YP.js → vue-ui-table-Dn6H98rP.js} +3 -3
  78. package/dist/{vue-ui-table-heatmap-DL2n2Z7p.js → vue-ui-table-heatmap-COI9LRqC.js} +5 -5
  79. package/dist/{vue-ui-table-sparkline-DOt2EKpe.js → vue-ui-table-sparkline-B7Gg5FfJ.js} +4 -4
  80. package/dist/{vue-ui-thermometer-BTP1ic_T.js → vue-ui-thermometer-Bgynq5El.js} +8 -8
  81. package/dist/{vue-ui-timer-Bc-zJH9j.js → vue-ui-timer-CXng51v5.js} +5 -5
  82. package/dist/{vue-ui-tiremarks-B9n528e1.js → vue-ui-tiremarks-Cy1U3hO1.js} +7 -7
  83. package/dist/vue-ui-treemap-BsvIvRmE.js +1092 -0
  84. package/dist/{vue-ui-vertical-bar-CK2j09gJ.js → vue-ui-vertical-bar-DHqWeDIf.js} +512 -464
  85. package/dist/{vue-ui-waffle-DJkqgqlR.js → vue-ui-waffle-D1Mscj3N.js} +416 -370
  86. package/dist/{vue-ui-wheel-CcbgpIUr.js → vue-ui-wheel-DpV-N5tF.js} +7 -7
  87. package/dist/vue-ui-word-cloud-MaNQ3Kdk.js +811 -0
  88. package/dist/{vue-ui-world-DLmB_Z96.js → vue-ui-world-DYz6zw3x.js} +512 -466
  89. package/dist/{vue-ui-xy-KmrNT6qh.js → vue-ui-xy-B1nqNbzw.js} +1559 -1508
  90. package/dist/vue-ui-xy-canvas-D4wd-Asd.js +1291 -0
  91. package/package.json +1 -1
  92. package/dist/DataTable-Y5T9UxMO.js +0 -133
  93. package/dist/Legend-DkU3at-b.js +0 -72
  94. package/dist/vue-ui-3d-bar-CBfQ3Pcb.js +0 -1323
  95. package/dist/vue-ui-chord-0wf798ls.js +0 -1049
  96. package/dist/vue-ui-circle-pack-CuRHG8gr.js +0 -709
  97. package/dist/vue-ui-flow-K7UBguES.js +0 -852
  98. package/dist/vue-ui-funnel-DoDZbsTp.js +0 -620
  99. package/dist/vue-ui-galaxy-BsDlHxzE.js +0 -691
  100. package/dist/vue-ui-heatmap-DOT2tBy_.js +0 -1078
  101. package/dist/vue-ui-molecule-DgqVh2k0.js +0 -656
  102. package/dist/vue-ui-parallel-coordinate-plot-BZf24Zur.js +0 -927
  103. package/dist/vue-ui-quadrant-S58B2LrQ.js +0 -1432
  104. package/dist/vue-ui-radar-Dh67mQ9E.js +0 -807
  105. package/dist/vue-ui-ridgeline-CsByERvm.js +0 -1157
  106. package/dist/vue-ui-rings-CR2UfgnV.js +0 -739
  107. package/dist/vue-ui-treemap-Cl9qo9O-.js +0 -1046
  108. package/dist/vue-ui-word-cloud-CZ_TRf4o.js +0 -765
  109. package/dist/vue-ui-xy-canvas-6VYNyX6a.js +0 -1243
@@ -1,1157 +0,0 @@
1
- import { defineAsyncComponent as N, computed as d, ref as u, shallowRef as Je, toRefs as jt, onBeforeUnmount as Qe, watch as Z, nextTick as ke, watchEffect as qt, createElementBlock as n, openBlock as r, unref as i, normalizeStyle as w, normalizeClass as ee, createBlock as _, createCommentVNode as v, renderSlot as m, createElementVNode as y, createSlots as Ze, withCtx as p, normalizeProps as te, guardReactiveProps as ae, createVNode as et, Fragment as g, renderList as k, mergeProps as tt, toDisplayString as B, createTextVNode as at } from "vue";
2
- import { u as Kt, c as Ae, t as Jt, d as Qt, e as Zt, p as le, ap as lt, ah as ea, U as st, V as ta, W as aa, X as la, F as sa, I as oa, k as se, i as oe, a as ra, b as na, f as Ce, g as ot, o as ia, v as ua, w as ca, K as va } from "./index-BHb_mcWF.js";
3
- import { t as rt, u as ha } from "./useResponsive-DfdjqQps.js";
4
- import { u as da, B as ya } from "./useLoading-D7YHNtLX.js";
5
- import { u as fa } from "./usePrinter-B7rhbRrT.js";
6
- import { u as nt } from "./useNestedProp-aC9S6EFJ.js";
7
- import { u as ga } from "./useTimeLabels-BGFjWgrv.js";
8
- import { u as ma } from "./useUserOptionState-BIvW1Kz7.js";
9
- import { u as pa } from "./useChartAccessibility-9icAAmYg.js";
10
- import { u as ba } from "./useTimeLabelCollider-CIsgDrl9.js";
11
- import xa from "./Legend-DkU3at-b.js";
12
- import ka from "./Title-BL-IjQmj.js";
13
- import { _ as Aa } from "./Shape-C3J8aKNH.js";
14
- import Ca from "./img-DsVqerdt.js";
15
- import { _ as wa } from "./_plugin-vue_export-helper-CHgC5LLL.js";
16
- const $a = ["id"], _a = ["xmlns", "viewBox"], Ta = ["id"], Pa = ["stop-color"], Sa = ["stop-color"], Ma = ["stop-color"], La = ["stop-color"], Oa = ["id"], za = ["stop-color"], Ia = ["stop-color"], Na = ["stop-color"], Fa = ["stop-color"], Da = { key: 0 }, Ra = ["fill", "d"], Ea = ["stroke", "stroke-width", "d"], Ha = ["fill", "d"], Xa = ["stroke", "stroke-dasharray", "stroke-width", "d"], Ba = ["x1", "y1", "x2", "y2", "stroke", "stroke-width", "stroke-dasharray"], Va = ["cx", "cy", "stroke", "stroke-width", "r", "fill"], Ua = ["x", "y", "font-size", "font-weight", "fill", "text-decoration", "onMouseenter", "onClick"], Ga = { key: 0 }, Wa = ["font-size", "fill", "font-weight", "transform", "text-anchor"], Ya = ["font-size", "fill", "font-weight", "transform", "text-anchor", "innerHTML"], ja = ["x", "y", "width", "height", "onMouseenter", "onMouseleave", "onClick"], qa = ["x1", "x2", "y1", "y2", "stroke", "stroke-width", "stroke-dasharray"], Ka = ["cx", "cy", "stroke", "stroke-width", "r", "fill"], Ja = ["x", "y", "text-anchor", "font-size", "fill"], Qa = {
17
- key: 4,
18
- class: "vue-data-ui-watermark"
19
- }, Za = ["onClick"], el = ["innerHTML"], tl = {
20
- __name: "vue-ui-ridgeline",
21
- props: {
22
- config: {
23
- type: Object,
24
- default() {
25
- return {};
26
- }
27
- },
28
- dataset: {
29
- type: Array,
30
- default() {
31
- return [];
32
- }
33
- }
34
- },
35
- emits: ["selectLegend", "selectDatapoint", "selectX"],
36
- setup(it, { expose: ut, emit: ct }) {
37
- const vt = N(() => import("./vue-ui-accordion-DsnF0JuK.js")), ht = N(() => import("./BaseDraggableDialog-BhxUDwEm.js")), dt = N(() => import("./DataTable-Y5T9UxMO.js")), yt = N(() => import("./PackageVersion-CE7HSich.js")), ft = N(() => import("./PenAndPaper-BMHsOtT8.js")), gt = N(() => import("./UserOptions-BWMV0_Ze.js")), mt = N(() => import("./vue-ui-xy-KmrNT6qh.js")), { vue_ui_ridgeline: pt } = Kt(), F = it, V = d({
38
- get() {
39
- return Array.isArray(O.value) && O.value.length > 0;
40
- },
41
- set(a) {
42
- return a;
43
- }
44
- }), re = ct, T = u(null), we = u(null), $e = u(null), P = Je(null), L = Je(null), _e = u(null), Te = u(null), ne = u(0), bt = u(0), ie = u(0), A = u(Ae()), Pe = u(0), xt = u(0), Se = u(512), h = u(null), D = u(null), ue = u(null), Me = u(0), ce = u(null);
45
- function ve() {
46
- const a = nt({
47
- userConfig: F.config,
48
- defaultConfig: pt
49
- });
50
- return a.theme ? {
51
- ...nt({
52
- userConfig: na.vue_ui_ridgeline[a.theme] || F.config,
53
- defaultConfig: a
54
- }),
55
- customPalette: ra[a.theme] || le
56
- } : a;
57
- }
58
- const e = u(ve()), { loading: U, FINAL_DATASET: O, manualLoading: he } = da({
59
- ...jt(F),
60
- FINAL_CONFIG: e,
61
- prepareConfig: ve,
62
- skeletonDataset: [
63
- {
64
- name: "_",
65
- datapoints: [
66
- {
67
- name: "__",
68
- color: "#999999",
69
- values: [28.639, 32.04, 41.134, 44.525, 21.151, 2.436, 0.218, 0.024, 2e-3, 0, 0, 0]
70
- },
71
- {
72
- name: "_",
73
- color: "#CACACA",
74
- values: [13.253, 15.621, 23.36, 33.698, 29.935, 10.874, 2.364, 0.561, 0.107, 0.02, 6e-3, 4e-3]
75
- }
76
- ]
77
- },
78
- {
79
- name: "_",
80
- datapoints: [
81
- {
82
- name: "_",
83
- color: "#999999",
84
- values: [10.851, 13.195, 21.617, 36.556, 42.292, 21.006, 3.398, 0.223, 0.013, 1e-3, 0, 0]
85
- },
86
- {
87
- name: "_",
88
- color: "#CACACA",
89
- values: [3.171, 4.115, 8.108, 18.248, 31.641, 29.063, 12.031, 2.742, 0.504, 0.102, 0.032, 0.021]
90
- }
91
- ]
92
- },
93
- {
94
- name: "_",
95
- datapoints: [
96
- {
97
- name: "_",
98
- color: "#999999",
99
- values: [1.731, 2.334, 5.125, 13.626, 29.911, 38.524, 24.168, 7.646, 1.575, 0.317, 0.097, 0.063]
100
- },
101
- {
102
- name: "_",
103
- color: "#CACACA",
104
- values: [0.25, 0.367, 1.026, 3.944, 13.635, 28.891, 30.149, 15.419, 4.714, 1.246, 0.442, 0.299]
105
- }
106
- ]
107
- },
108
- {
109
- name: "_",
110
- datapoints: [
111
- {
112
- name: "_",
113
- color: "#999999",
114
- values: [0.034, 0.054, 0.194, 1.065, 5.747, 20.735, 38.306, 32.899, 15.318, 5.566, 2.422, 1.76]
115
- },
116
- {
117
- name: "_",
118
- color: "#CACACA",
119
- values: [1e-3, 2e-3, 9e-3, 0.095, 1.124, 8.342, 27.115, 35.08, 21.449, 9.093, 4.243, 3.143]
120
- }
121
- ]
122
- },
123
- {
124
- name: "_",
125
- datapoints: [
126
- {
127
- name: "_",
128
- color: "#999999",
129
- values: [0, 1e-3, 4e-3, 0.051, 0.567, 3.322, 14.215, 44.783, 40.351, 20.377, 9.866, 7.378]
130
- },
131
- {
132
- name: "_",
133
- color: "#CACACA",
134
- values: [0, 0, 0, 0, 1e-3, 0.11, 4.136, 27.498, 43.24, 29.807, 17.345, 13.678]
135
- }
136
- ]
137
- },
138
- {
139
- name: "_",
140
- datapoints: [
141
- {
142
- name: "_",
143
- color: "#999999",
144
- values: [0, 0, 0, 0, 0.025, 0.598, 3.886, 10.645, 54.479, 45.953, 30.814, 24.55]
145
- },
146
- {
147
- name: "_",
148
- color: "#CACACA",
149
- values: [0, 0, 0, 0, 0, 0, 7e-3, 1.655, 26.63, 52.017, 45.192, 39.651]
150
- }
151
- ]
152
- }
153
- ],
154
- skeletonConfig: Jt({
155
- defaultConfig: e.value,
156
- userConfig: {
157
- userOptions: { show: !1 },
158
- table: { show: !1 },
159
- style: {
160
- chart: {
161
- backgroundColor: "#99999930",
162
- areas: {
163
- maxPoint: {
164
- show: !1
165
- },
166
- opacity: 0.9,
167
- stroke: {
168
- useSerieColor: !0
169
- }
170
- },
171
- legend: {
172
- backgroundColor: "transparent"
173
- },
174
- padding: {
175
- right: -24,
176
- left: 0
177
- },
178
- xAxis: {
179
- labels: {
180
- values: []
181
- }
182
- },
183
- yAxis: {
184
- labels: {
185
- fontSize: 0
186
- }
187
- },
188
- zeroLine: { show: !1 }
189
- }
190
- }
191
- }
192
- })
193
- }), C = u(Math.min(
194
- e.value.style.chart.areas.height,
195
- e.value.style.chart.areas.rowHeight
196
- )), {
197
- userOptionsVisible: K,
198
- setUserOptionsVisibility: Le,
199
- keepUserOptionState: Oe
200
- } = ma({ config: e.value }), { svgRef: de } = pa({ config: e.value.style.chart.title }), ye = d(() => !!e.value.debug);
201
- function ze() {
202
- const a = O.value || [];
203
- if (!Array.isArray(a) || a.length === 0) {
204
- Ce({ componentName: "VueUiRidgeline", type: "dataset", debug: ye.value }), he.value = !0;
205
- return;
206
- }
207
- if (a.forEach((s, t) => {
208
- ot({
209
- datasetObject: s,
210
- requiredAttributes: ["name", "datapoints"]
211
- }).forEach((o) => {
212
- V.value = !1, Ce({
213
- componentName: "VueUiRidgeline",
214
- type: "datasetSerieAttribute",
215
- property: o,
216
- index: t,
217
- debug: ye.value
218
- });
219
- }), Array.isArray(s.datapoints) && s.datapoints.length && s.datapoints.forEach((o, l) => {
220
- ot({
221
- datasetObject: o,
222
- requiredAttributes: ["name", "values"]
223
- }).forEach((c) => {
224
- V.value = !1, Ce({
225
- componentName: "VueUiRidgeline",
226
- type: "datasetSerieAttribute",
227
- property: `datapoint.${c}`,
228
- index: `${t}-${l}`,
229
- debug: ye.value
230
- });
231
- });
232
- });
233
- }), xt.value = a.length, C.value = Math.min(
234
- e.value.style.chart.areas.height,
235
- e.value.style.chart.areas.rowHeight
236
- ), ia(F.dataset) || (he.value = e.value.loading), e.value.responsive) {
237
- const s = rt(() => {
238
- const { width: t, height: o } = ha({
239
- chart: T.value,
240
- title: e.value.style.chart.title.text ? we.value : null,
241
- legend: e.value.style.chart.legend.show ? $e.value : null,
242
- source: _e.value,
243
- noTitle: Te.value,
244
- padding: e.value.style.chart.padding
245
- });
246
- requestAnimationFrame(() => {
247
- Se.value = t, C.value = a.length ? o / a.length : 0, Me.value = o - 12;
248
- });
249
- });
250
- P.value && (L.value && P.value.unobserve(L.value), P.value.disconnect()), P.value = new ResizeObserver(s), L.value = T.value?.parentNode || null, L.value && P.value.observe(L.value);
251
- }
252
- }
253
- Qe(() => {
254
- P.value && (L.value && P.value.unobserve(L.value), P.value.disconnect());
255
- });
256
- const { isPrinting: Ie, isImaging: Ne, generatePdf: Fe, generateImage: De } = fa({
257
- elementId: `vue-ui-ridgeline_${A.value}`,
258
- fileName: e.value.style.chart.title.text || "vue-ui-ridgeline",
259
- options: e.value.userOptions.print
260
- }), kt = d(() => e.value.userOptions.show && !e.value.style.chart.title.text), At = d(() => Qt(e.value.customPalette)), R = u({
261
- showTable: e.value.table.show
262
- });
263
- Z(
264
- () => O.value,
265
- async (a) => {
266
- Array.isArray(a) && a.length && (K.value = !e.value.userOptions.showOnChartHover, await ke(), ze(), ne.value += 1, ie.value += 1, R.value.showTable = e.value.table.show);
267
- },
268
- { deep: !0, immediate: !0 }
269
- ), Z(() => F.dataset, (a) => {
270
- Array.isArray(a) && a.length > 0 && (he.value = !1);
271
- }, { deep: !0 }), Z(
272
- () => U.value,
273
- async (a) => {
274
- a || (await ke(), ze());
275
- },
276
- { immediate: !0 }
277
- ), Z(
278
- () => F.config,
279
- () => {
280
- e.value = ve(O.value || null), K.value = !e.value.userOptions.showOnChartHover, C.value = Math.min(e.value.style.chart.areas.height, e.value.style.chart.areas.rowHeight), R.value.showTable = e.value.table.show, ne.value += 1, ie.value += 1;
281
- },
282
- { deep: !0 }
283
- );
284
- const fe = d(() => e.value.style.chart.areas.height / e.value.style.chart.areas.rowHeight);
285
- function Re(a) {
286
- M.value.includes(a) ? M.value = M.value.filter((s) => s !== a) : M.value.push(a), re("selectLegend", H.value);
287
- }
288
- const S = d(() => V.value ? (O.value || []).map((a) => ({
289
- ...a,
290
- labelLen: Mt(a.name, e.value.style.chart.yAxis.labels.fontSize),
291
- uid: Ae(),
292
- datapoints: a.datapoints.map((s, t) => {
293
- const o = s.color ? Zt(s.color) : At.value[t] || le[t] || le[t % le.length], l = lt(s.name);
294
- return { ...s, color: o, id: l };
295
- })
296
- })) : []), Ee = d(() => e.value.style.chart.padding.top + C.value * (O.value || []).length + C.value * fe.value + e.value.style.chart.padding.bottom), f = d(() => {
297
- const a = e.value.style.chart.padding;
298
- return {
299
- width: Se.value,
300
- height: Ee.value,
301
- padding: a
302
- };
303
- }), Ct = d(() => f.value.width), wt = d(() => f.value.height), ge = u(0), $t = rt((a) => {
304
- ge.value = a;
305
- }, 100);
306
- qt((a) => {
307
- const s = ce.value;
308
- if (!s) return;
309
- const t = new ResizeObserver((o) => {
310
- $t(o[0].contentRect.height);
311
- });
312
- t.observe(s), a(() => t.disconnect());
313
- }), Qe(() => {
314
- ge.value = 0;
315
- });
316
- const b = d(() => ({
317
- fullHeight: f.value.height + ge.value,
318
- top: f.value.padding.top,
319
- left: f.value.padding.left,
320
- right: f.value.width - f.value.padding.right,
321
- bottom: f.value.height - e.value.style.chart.padding.bottom,
322
- width: f.value.width - (f.value.padding.left + f.value.padding.right)
323
- })), G = d(() => Math.max(...S.value.flatMap((a) => a.datapoints.map((s) => s.values.length)))), W = d(() => ga({
324
- values: e.value.style.chart.xAxis.labels.values,
325
- maxDatapoints: G.value,
326
- formatter: e.value.style.chart.xAxis.labels.datetimeFormatter,
327
- start: 0,
328
- end: e.value.style.chart.xAxis.labels.values.length
329
- })), E = d(() => {
330
- const a = Math.max(...S.value.map((l) => l.labelLen)), s = f.value.padding.left + a + 16 + e.value.style.chart.yAxis.labels.offsetX, t = (b.value.width - s) / G.value, o = [];
331
- for (let l = 0; l < G.value; l += 1)
332
- o.push({
333
- selectorX: s + t * l,
334
- x: s + t * l - t / 2,
335
- y: b.value.top,
336
- label: e.value.style.chart.xAxis.labels.values[l] ? W.value[l].text : "",
337
- index: l,
338
- width: t,
339
- height: Ee.value
340
- });
341
- return o;
342
- });
343
- function me(a) {
344
- return S.value.map((s) => s.datapoints.map((t) => ({
345
- dp: t,
346
- selected: t.values[a.index]
347
- })));
348
- }
349
- function _t(a) {
350
- h.value = a;
351
- const s = me(a);
352
- e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: s, seriesIndex: a.index });
353
- }
354
- function Tt(a) {
355
- h.value = null;
356
- const s = me(a);
357
- e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: s, seriesIndex: a.index });
358
- }
359
- function Pt(a) {
360
- const s = me(a);
361
- e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: s, seriesIndex: a.index }), re("selectX", s);
362
- }
363
- function St(a, s) {
364
- return a.length * s / 2 + s;
365
- }
366
- function He(a, s, t) {
367
- const o = St(s, t);
368
- return a + o > b.value.right;
369
- }
370
- function Mt(a, s, t = "sans-serif") {
371
- const l = document.createElement("canvas").getContext("2d"), c = typeof s == "number" ? `${s}px` : s;
372
- return l.font = `${c} ${t}`, l.measureText(a).width;
373
- }
374
- const H = d(() => {
375
- C.value;
376
- const a = Math.max(...S.value.map((x) => x.labelLen)), s = Math.max(...S.value.flatMap((x) => x.datapoints.flatMap((Y) => Y.values))), t = Math.min(...S.value.flatMap((x) => x.datapoints.flatMap((Y) => Y.values))), o = f.value.padding.left + a + 16 + e.value.style.chart.yAxis.labels.offsetX, l = (b.value.width - o) / G.value, c = Math.abs(Math.min(t, 0)), $ = s + c;
377
- function Ye(x) {
378
- return isNaN(x / $) ? 0 : x / $;
379
- }
380
- return S.value.map((x, Y) => {
381
- const je = b.value.top + C.value * Y, z = b.value.top + je + C.value * fe.value * (1 - Ye(c));
382
- return {
383
- ...x,
384
- label: {
385
- x: o - e.value.style.chart.yAxis.labels.fontSize,
386
- y: z
387
- },
388
- datapoints: x.datapoints.map((j) => {
389
- const I = j.values.map((q, Vt) => {
390
- const Ut = isNaN(q) || [void 0, null, "NaN", NaN, 1 / 0, -1 / 0].includes(q) ? 0 : q || 0, Gt = o + l * Vt, Wt = b.value.top + je + C.value * fe.value * (1 - Ye(Ut + c)), Yt = q === Math.max(...j.values);
391
- return {
392
- x: Gt,
393
- y: Wt,
394
- value: q,
395
- isMaxPoint: Yt,
396
- zero: z
397
- };
398
- }), Et = `${ea(I, z, !1, !1)}`, Ht = `M ${o},${z} ${st(I)} ${I.at(-1).x},${z}`, Xt = `M ${o},${z} ${I.at(-1).x},${z}`, qe = `M ${ta(I)}`, Ke = `M ${st(I)}`, Bt = aa(
399
- e.value.style.chart.areas.smooth ? qe : Ke
400
- );
401
- return {
402
- ...j,
403
- uid: Ae(),
404
- plots: I,
405
- smoothPath: Et,
406
- straightPath: Ht,
407
- zeroPath: Xt,
408
- pathLength: Bt,
409
- smoothPathRidge: qe,
410
- straightPathRidge: Ke
411
- };
412
- }).filter((j) => !M.value.includes(j.id))
413
- };
414
- });
415
- }), M = u([]);
416
- function Lt(a) {
417
- const s = /* @__PURE__ */ new Map();
418
- return a.forEach((t) => {
419
- t.datapoints.forEach((o, l) => {
420
- const c = lt(o.name);
421
- s.has(c) || s.set(c, {
422
- id: c,
423
- name: o.name,
424
- color: o.color,
425
- shape: "circle",
426
- segregate: () => Re(c),
427
- isSegregated: M.value.includes(c),
428
- opacity: M.value.includes(c) ? 0.5 : 1
429
- });
430
- });
431
- }), Array.from(s.values());
432
- }
433
- const pe = d(() => Lt(S.value)), Ot = d(() => ({
434
- cy: "donut-div-legend",
435
- backgroundColor: e.value.style.chart.legend.backgroundColor,
436
- color: e.value.style.chart.legend.color,
437
- fontSize: e.value.style.chart.legend.fontSize,
438
- paddingBottom: 12,
439
- fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
440
- })), X = u(!1);
441
- function Xe(a) {
442
- X.value = a, Pe.value += 1;
443
- }
444
- const Be = u({}), Ve = u([]);
445
- function zt(a) {
446
- re("selectDatapoint", a), e.value.style.chart.dialog.show && (Ve.value = a.datapoints.map((s) => ({
447
- name: s.name,
448
- color: s.color,
449
- type: "line",
450
- useArea: !0,
451
- smooth: e.value.style.chart.areas.smooth,
452
- series: s.values
453
- })), D.value = a, Be.value = va({
454
- ...e.value.style.chart.dialog.xyChart,
455
- responsive: !0,
456
- // Overriding
457
- chart: {
458
- ...e.value.style.chart.dialog.xyChart.chart,
459
- grid: {
460
- ...e.value.style.chart.dialog.xyChart.chart.grid,
461
- labels: {
462
- ...e.value.style.chart.dialog.xyChart.chart.grid.labels,
463
- xAxisLabels: {
464
- ...e.value.style.chart.dialog.xyChart.chart.grid.labels.xAxisLabels,
465
- values: e.value.style.chart.xAxis.labels.values,
466
- // Overriding
467
- autoRotate: {
468
- enable: !0,
469
- angle: e.value.style.chart.dialog.xyChart.chart.grid.labels.xAxisLabels.autoRotate.angle
470
- },
471
- // overriding
472
- datetimeFormatter: e.value.style.chart.xAxis.labels.datetimeFormatter
473
- // Overriding
474
- }
475
- }
476
- },
477
- tooltip: {
478
- ...e.value.style.chart.dialog.xyChart.chart.tooltip,
479
- showTimeLabel: e.value.style.chart.xAxis.labels.values.length > 0
480
- // Overriding
481
- }
482
- }
483
- }), ue.value && ue.value.open());
484
- }
485
- const be = u(null);
486
- function It(a) {
487
- be.value = a;
488
- }
489
- function Nt() {
490
- be.value = null;
491
- }
492
- const J = u(!1);
493
- function xe() {
494
- J.value = !J.value;
495
- }
496
- function Ue() {
497
- R.value.showTable = !R.value.showTable;
498
- }
499
- const Ge = d(() => ({ body: H.value.flatMap((t) => t.datapoints.flatMap((o) => ({
500
- ...o,
501
- rowName: `${t.name}: ${o.name}`
502
- }))).map((t) => [
503
- {
504
- name: t.rowName,
505
- color: t.color
506
- },
507
- ...t.values
508
- ]) })), Q = d(() => {
509
- const a = [
510
- e.value.table.columnNames.series,
511
- ...W.value.map((o) => o.text)
512
- ], s = {
513
- th: {
514
- backgroundColor: e.value.table.th.backgroundColor,
515
- color: e.value.table.th.color,
516
- outline: e.value.table.th.outline
517
- },
518
- td: {
519
- backgroundColor: e.value.table.td.backgroundColor,
520
- color: e.value.table.td.color,
521
- outline: e.value.table.td.outline
522
- },
523
- breakpoint: e.value.table.responsiveBreakpoint
524
- };
525
- return {
526
- colNames: [
527
- e.value.table.columnNames.series,
528
- ...W.value.map((o) => o.text)
529
- ],
530
- head: a,
531
- body: Ge.value.body,
532
- config: s
533
- };
534
- });
535
- function We(a = null) {
536
- ke(() => {
537
- const s = [
538
- [e.value.table.columnNames.series, ...W.map((l) => [l.text])],
539
- ...Ge.value.body.map((l, c) => [l[0].name, ...l.slice(1)])
540
- ], t = [
541
- [e.value.style.chart.title.text],
542
- [e.value.style.chart.title.subtitle.text]
543
- ].concat(s), o = ua(t);
544
- a ? a(o) : ca({
545
- csvContent: o,
546
- title: e.value.style.chart.title.text || "vue-ui-ridgeline"
547
- });
548
- });
549
- }
550
- function Ft() {
551
- return H.value;
552
- }
553
- async function Dt({ scale: a = 2 } = {}) {
554
- if (!T.value) return;
555
- const { width: s, height: t } = T.value.getBoundingClientRect(), o = s / t, { imageUri: l, base64: c } = await Ca({ domElement: T.value, base64: !0, img: !0, scale: a });
556
- return {
557
- imageUri: l,
558
- base64: c,
559
- title: e.value.style.chart.title.text,
560
- width: s,
561
- height: t,
562
- aspectRatio: o
563
- };
564
- }
565
- const Rt = d(() => ({ min: 0, max: G.value }));
566
- return ba({
567
- timeLabelsEls: ce,
568
- timeLabels: W,
569
- slicer: Rt,
570
- configRef: e,
571
- rotationPath: ["style", "chart", "xAxis", "labels", "rotation"],
572
- autoRotatePath: ["style", "chart", "xAxis", "labels", "autoRotate", "enable"],
573
- isAutoSize: !1,
574
- width: Ct,
575
- height: wt,
576
- targetClass: ".vue-ui-ridgeline-x-axis-label",
577
- angle: e.value.style.chart.xAxis.labels.autoRotate.angle
578
- }), ut({
579
- getData: Ft,
580
- getImage: Dt,
581
- generateImage: De,
582
- generatePdf: Fe,
583
- generateCsv: We,
584
- toggleAnnotator: xe,
585
- toggleTable: Ue,
586
- toggleFullscreen: Xe
587
- }), (a, s) => (r(), n("div", {
588
- ref_key: "ridgelineChart",
589
- ref: T,
590
- class: ee(`vue-ui-ridgeline ${X.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
591
- id: `vue-ui-ridgeline_${A.value}`,
592
- style: w({
593
- fontFamily: e.value.style.fontFamily,
594
- width: "100%",
595
- textAlign: "center",
596
- background: e.value.style.chart.backgroundColor,
597
- height: e.value.responsive ? "100%" : void 0
598
- }),
599
- onMouseenter: s[3] || (s[3] = () => i(Le)(!0)),
600
- onMouseleave: s[4] || (s[4] = () => i(Le)(!1))
601
- }, [
602
- e.value.userOptions.buttons.annotator && i(de) ? (r(), _(i(ft), {
603
- key: 0,
604
- color: e.value.style.chart.color,
605
- backgroundColor: e.value.style.chart.backgroundColor,
606
- active: J.value,
607
- svgRef: i(de),
608
- onClose: xe
609
- }, null, 8, ["color", "backgroundColor", "active", "svgRef"])) : v("", !0),
610
- m(a.$slots, "userConfig", {}, void 0, !0),
611
- kt.value ? (r(), n("div", {
612
- key: 1,
613
- ref_key: "noTitle",
614
- ref: Te,
615
- class: "vue-data-ui-no-title-space",
616
- style: "height:36px; width: 100%;background:transparent"
617
- }, null, 512)) : v("", !0),
618
- e.value.style.chart.title.text ? (r(), n("div", {
619
- key: 2,
620
- ref_key: "chartTitle",
621
- ref: we,
622
- style: "width:100%;background:transparent;padding-bottom:24px"
623
- }, [
624
- (r(), _(ka, {
625
- key: `title_${ne.value}`,
626
- config: {
627
- title: {
628
- cy: "ridgeline-div-title",
629
- ...e.value.style.chart.title
630
- },
631
- subtitle: {
632
- cy: "ridgeline-div-subtitle",
633
- ...e.value.style.chart.title.subtitle
634
- }
635
- }
636
- }, null, 8, ["config"]))
637
- ], 512)) : v("", !0),
638
- e.value.userOptions.show && V.value && (i(Oe) || i(K)) ? (r(), _(i(gt), {
639
- ref: "details",
640
- key: `user_option_${Pe.value}`,
641
- backgroundColor: e.value.style.chart.backgroundColor,
642
- color: e.value.style.chart.color,
643
- isPrinting: i(Ie),
644
- isImaging: i(Ne),
645
- uid: A.value,
646
- hasTooltip: !1,
647
- callbacks: e.value.userOptions.callbacks,
648
- hasPdf: e.value.userOptions.buttons.pdf,
649
- hasImg: e.value.userOptions.buttons.img,
650
- hasXls: e.value.userOptions.buttons.csv,
651
- hasTable: e.value.userOptions.buttons.table,
652
- hasLabel: !1,
653
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
654
- isFullscreen: X.value,
655
- printScale: e.value.userOptions.print.scale,
656
- chartElement: T.value,
657
- position: e.value.userOptions.position,
658
- isTooltip: !1,
659
- titles: { ...e.value.userOptions.buttonTitles },
660
- hasAnnotator: e.value.userOptions.buttons.annotator,
661
- isAnnotation: J.value,
662
- style: w({
663
- visibility: i(Oe) ? i(K) ? "visible" : "hidden" : "visible"
664
- }),
665
- onToggleFullscreen: Xe,
666
- onGeneratePdf: i(Fe),
667
- onGenerateCsv: We,
668
- onGenerateImage: i(De),
669
- onToggleTable: Ue,
670
- onToggleAnnotator: xe
671
- }, Ze({ _: 2 }, [
672
- a.$slots.menuIcon ? {
673
- name: "menuIcon",
674
- fn: p(({ isOpen: t, color: o }) => [
675
- m(a.$slots, "menuIcon", te(ae({ isOpen: t, color: o })), void 0, !0)
676
- ]),
677
- key: "0"
678
- } : void 0,
679
- a.$slots.optionTooltip ? {
680
- name: "optionTooltip",
681
- fn: p(() => [
682
- m(a.$slots, "optionTooltip", {}, void 0, !0)
683
- ]),
684
- key: "1"
685
- } : void 0,
686
- a.$slots.optionPdf ? {
687
- name: "optionPdf",
688
- fn: p(() => [
689
- m(a.$slots, "optionPdf", {}, void 0, !0)
690
- ]),
691
- key: "2"
692
- } : void 0,
693
- a.$slots.optionCsv ? {
694
- name: "optionCsv",
695
- fn: p(() => [
696
- m(a.$slots, "optionCsv", {}, void 0, !0)
697
- ]),
698
- key: "3"
699
- } : void 0,
700
- a.$slots.optionImg ? {
701
- name: "optionImg",
702
- fn: p(() => [
703
- m(a.$slots, "optionImg", {}, void 0, !0)
704
- ]),
705
- key: "4"
706
- } : void 0,
707
- a.$slots.optionTable ? {
708
- name: "optionTable",
709
- fn: p(() => [
710
- m(a.$slots, "optionTable", {}, void 0, !0)
711
- ]),
712
- key: "5"
713
- } : void 0,
714
- a.$slots.optionFullscreen ? {
715
- name: "optionFullscreen",
716
- fn: p(({ toggleFullscreen: t, isFullscreen: o }) => [
717
- m(a.$slots, "optionFullscreen", te(ae({ toggleFullscreen: t, isFullscreen: o })), void 0, !0)
718
- ]),
719
- key: "6"
720
- } : void 0,
721
- a.$slots.optionAnnotator ? {
722
- name: "optionAnnotator",
723
- fn: p(({ toggleAnnotator: t, isAnnotator: o }) => [
724
- m(a.$slots, "optionAnnotator", te(ae({ toggleAnnotator: t, isAnnotator: o })), void 0, !0)
725
- ]),
726
- key: "7"
727
- } : void 0
728
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "callbacks", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "printScale", "chartElement", "position", "titles", "hasAnnotator", "isAnnotation", "style", "onGeneratePdf", "onGenerateImage"])) : v("", !0),
729
- (r(), n("svg", {
730
- ref_key: "svgRef",
731
- ref: de,
732
- xmlns: i(la),
733
- class: ee({ "vue-data-ui-fullscreen--on": X.value, "vue-data-ui-fulscreen--off": !X.value }),
734
- viewBox: `0 0 ${f.value.width <= 0 ? 10 : f.value.width} ${b.value.fullHeight <= 0 ? 10 : b.value.fullHeight}`,
735
- style: w(`max-width:100%;overflow:visible;background:transparent;color:${e.value.style.chart.color};${e.value.responsive ? `height: ${Me.value}px; width: 100%;` : ""}`)
736
- }, [
737
- et(i(yt)),
738
- y("defs", null, [
739
- (r(!0), n(g, null, k(pe.value, (t, o) => (r(), n("linearGradient", {
740
- id: `gradient-${t.id}-${A.value}`,
741
- x1: "50%",
742
- y1: "0%",
743
- x2: "50%",
744
- y2: "100%"
745
- }, [
746
- y("stop", {
747
- offset: "0%",
748
- "stop-color": t.color,
749
- "stop-opacity": "1"
750
- }, null, 8, Pa),
751
- y("stop", {
752
- offset: "30%",
753
- "stop-color": t.color,
754
- "stop-opacity": "0.7"
755
- }, null, 8, Sa),
756
- y("stop", {
757
- offset: "70%",
758
- "stop-color": t.color,
759
- "stop-opacity": "0.3"
760
- }, null, 8, Ma),
761
- y("stop", {
762
- offset: "100%",
763
- "stop-color": t.color,
764
- "stop-opacity": "0.1"
765
- }, null, 8, La)
766
- ], 8, Ta))), 256)),
767
- (r(!0), n(g, null, k(H.value, (t, o) => (r(), n(g, null, [
768
- (r(!0), n(g, null, k(t.datapoints, (l, c) => (r(), n("linearGradient", {
769
- key: `grad${l.id}`,
770
- id: `gradient-single-${A.value}-${l.uid}`,
771
- x1: "50%",
772
- y1: "0%",
773
- x2: "50%",
774
- y2: "100%"
775
- }, [
776
- y("stop", {
777
- offset: "0%",
778
- "stop-color": l.color,
779
- "stop-opacity": "1"
780
- }, null, 8, za),
781
- y("stop", {
782
- offset: "30%",
783
- "stop-color": l.color,
784
- "stop-opacity": "0.7"
785
- }, null, 8, Ia),
786
- y("stop", {
787
- offset: "70%",
788
- "stop-color": l.color,
789
- "stop-opacity": "0.3"
790
- }, null, 8, Na),
791
- y("stop", {
792
- offset: "100%",
793
- "stop-color": l.color,
794
- "stop-opacity": "0.1"
795
- }, null, 8, Fa)
796
- ], 8, Oa))), 128))
797
- ], 64))), 256))
798
- ]),
799
- (r(!0), n(g, null, k(H.value, (t, o) => (r(), n("g", {
800
- key: `ds-${o}`
801
- }, [
802
- (r(!0), n(g, null, k(t.datapoints, (l, c) => (r(), n("g", {
803
- key: l.id
804
- }, [
805
- a.$slots.pattern ? (r(), n("g", Da, [
806
- y("defs", null, [
807
- m(a.$slots, "pattern", tt({ ref_for: !0 }, { datapointIndex: o, seriesIndex: c, patternId: `pattern_${A.value}_${l.uid}` }), void 0, !0)
808
- ])
809
- ])) : v("", !0),
810
- y("path", {
811
- fill: a.$slots.pattern ? `url(#pattern_${A.value}_${l.uid})` : e.value.style.chart.backgroundColor,
812
- stroke: "none",
813
- "stroke-linecap": "round",
814
- d: e.value.style.chart.areas.smooth ? l.smoothPath : l.straightPath,
815
- style: w({
816
- opacity: e.value.style.chart.areas.opacity
817
- })
818
- }, null, 12, Ra),
819
- y("path", {
820
- fill: "none",
821
- stroke: e.value.style.chart.areas.stroke.useSerieColor ? l.color : e.value.style.chart.areas.stroke.color,
822
- "stroke-width": e.value.style.chart.areas.strokeWidth,
823
- d: e.value.style.chart.areas.smooth ? l.smoothPathRidge : l.straightPathRidge,
824
- "stroke-linecap": "round",
825
- "stroke-linejoin": "round",
826
- class: ee({ "vue-ui-ridgeline-animate": e.value.useCssAnimation && !i(U) }),
827
- style: w({
828
- strokeDasharray: l.pathLength,
829
- strokeDashoffset: e.value.useCssAnimation ? l.pathLength : 0
830
- })
831
- }, null, 14, Ea),
832
- y("path", {
833
- fill: e.value.style.chart.areas.useGradient ? e.value.style.chart.areas.useCommonColor ? `url(#gradient-${l.id}-${A.value})` : `url(#gradient-single-${A.value}-${l.uid})` : l.color,
834
- stroke: "none",
835
- d: e.value.style.chart.areas.smooth ? l.smoothPath : l.straightPath,
836
- "stroke-linecap": "round",
837
- "stroke-linejoin": "round",
838
- class: ee({ "vue-ui-ridgeline-animate": e.value.useCssAnimation && !i(U) }),
839
- style: w({
840
- strokeDasharray: l.pathLength,
841
- strokeDashoffset: e.value.useCssAnimation ? l.pathLength : 0
842
- })
843
- }, null, 14, Ha),
844
- e.value.style.chart.zeroLine.show ? (r(), n("path", {
845
- key: 1,
846
- stroke: e.value.style.chart.zeroLine.useSerieColor ? l.color : e.value.style.chart.zeroLine.stroke,
847
- "stroke-dasharray": e.value.style.chart.zeroLine.strokeDasharray,
848
- "stroke-width": e.value.style.chart.zeroLine.strokeWidth,
849
- d: l.zeroPath,
850
- "stroke-linecap": "round"
851
- }, null, 8, Xa)) : v("", !0),
852
- e.value.style.chart.areas.maxPoint.show && l.plots.length > 1 ? (r(!0), n(g, { key: 2 }, k(l.plots, ($) => (r(), n(g, null, [
853
- $.isMaxPoint ? (r(), n("line", {
854
- key: 0,
855
- x1: $.x,
856
- y1: $.y,
857
- x2: $.x,
858
- y2: $.zero,
859
- stroke: e.value.style.chart.areas.maxPoint.adaptStrokeToBackground ? i(sa)(l.color) : e.value.style.chart.areas.maxPoint.stroke,
860
- "stroke-width": e.value.style.chart.areas.maxPoint.strokeWidth,
861
- "stroke-linecap": "round",
862
- "stroke-dasharray": e.value.style.chart.areas.maxPoint.strokeDasharray
863
- }, null, 8, Ba)) : v("", !0)
864
- ], 64))), 256)) : v("", !0),
865
- l.plots.length === 1 ? (r(), n("circle", {
866
- key: 3,
867
- cx: l.plots[0].x,
868
- cy: l.plots[0].y,
869
- stroke: e.value.style.chart.selector.dot.stroke,
870
- "stroke-width": e.value.style.chart.selector.dot.strokeWidth,
871
- r: e.value.style.chart.selector.dot.radius,
872
- fill: e.value.style.chart.selector.dot.useDatapointColor ? l.color : e.value.style.chart.selector.dot.fill,
873
- style: {
874
- pointerEvents: "none"
875
- }
876
- }, null, 8, Va)) : v("", !0)
877
- ]))), 128)),
878
- y("text", {
879
- x: t.label.x,
880
- y: t.label.y,
881
- "text-anchor": "end",
882
- "font-size": e.value.style.chart.yAxis.labels.fontSize,
883
- "font-weight": e.value.style.chart.yAxis.labels.bold ? "bold" : "normal",
884
- fill: e.value.style.chart.yAxis.labels.color,
885
- style: w({
886
- cursor: e.value.style.chart.dialog.show ? "pointer" : "default"
887
- }),
888
- "text-decoration": e.value.style.chart.dialog.show && (be.value === o || D.value && t.uid === D.value.uid) ? "underline" : "",
889
- onMouseenter: (l) => It(o),
890
- onMouseleave: Nt,
891
- onClick: (l) => zt(t)
892
- }, B(t.name), 45, Ua)
893
- ]))), 128)),
894
- e.value.style.chart.xAxis.labels.values.length ? (r(), n("g", {
895
- key: 0,
896
- ref_key: "timeLabelsEls",
897
- ref: ce
898
- }, [
899
- (r(!0), n(g, null, k(E.value, (t, o) => m(a.$slots, "time-label", tt({ ref_for: !0 }, {
900
- show: t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && !e.value.style.chart.xAxis.labels.showOnlyAtModulo || t && e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && (o === 0 || o === E.value.length - 1) || t && h.value && h.value.index === o || t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && e.value.style.chart.xAxis.labels.showOnlyAtModulo && o % Math.floor(E.value.length / e.value.style.chart.xAxis.labels.modulo) === 0,
901
- fontSize: e.value.style.chart.xAxis.labels.fontSize,
902
- content: t.label,
903
- textAnchor: e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
904
- fill: e.value.style.chart.xAxis.labels.color,
905
- transform: `translate(${t.selectorX}, ${b.value.top + t.height + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
906
- x: t.selectorX,
907
- y: b.value.bottom + e.value.style.chart.xAxis.labels.offsetY
908
- }), () => [
909
- t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && !e.value.style.chart.xAxis.labels.showOnlyAtModulo || t && e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && (o === 0 || o === E.value.length - 1) || t && h.value && h.value.index === o || t && !e.value.style.chart.xAxis.labels.showOnlyFirstAndLast && e.value.style.chart.xAxis.labels.showOnlyAtModulo && o % Math.floor(E.value.length / e.value.style.chart.xAxis.labels.modulo) === 0 ? (r(), n("g", Ga, [
910
- String(t.label).includes(`
911
- `) ? (r(), n("text", {
912
- key: 1,
913
- class: "vue-ui-ridgeline-x-axis-label",
914
- "font-size": e.value.style.chart.xAxis.labels.fontSize,
915
- fill: e.value.style.chart.xAxis.labels.color,
916
- "font-weight": e.value.style.chart.xAxis.labels.bold ? "bold" : "normal",
917
- transform: `translate(${t.selectorX}, ${b.value.bottom + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
918
- "text-anchor": e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
919
- style: w({
920
- opacity: h.value ? h.value.index === o ? 1 : 0.2 : 1
921
- }),
922
- innerHTML: i(oa)({
923
- content: String(t.label),
924
- fontSize: e.value.style.chart.xAxis.labels.fontSize,
925
- fill: e.value.style.chart.xAxis.labels.color,
926
- x: 0,
927
- y: 0
928
- })
929
- }, null, 12, Ya)) : (r(), n("text", {
930
- key: 0,
931
- class: "vue-ui-ridgeline-x-axis-label",
932
- "font-size": e.value.style.chart.xAxis.labels.fontSize,
933
- fill: e.value.style.chart.xAxis.labels.color,
934
- "font-weight": e.value.style.chart.xAxis.labels.bold ? "bold" : "normal",
935
- transform: `translate(${t.selectorX}, ${b.value.bottom + e.value.style.chart.xAxis.labels.offsetY}), rotate(${e.value.style.chart.xAxis.labels.rotation})`,
936
- "text-anchor": e.value.style.chart.xAxis.labels.rotation > 0 ? "start" : e.value.style.chart.xAxis.labels.rotation < 0 ? "end" : "middle",
937
- style: w({
938
- opacity: h.value ? h.value.index === o ? 1 : 0.2 : 1
939
- })
940
- }, B(t.label), 13, Wa))
941
- ])) : v("", !0)
942
- ], !0)), 256))
943
- ], 512)) : v("", !0),
944
- y("g", null, [
945
- (r(!0), n(g, null, k(E.value, (t, o) => (r(), n("rect", {
946
- x: t.x,
947
- y: t.y,
948
- width: t.width < 0 ? 0.1 : t.width,
949
- height: t.height < 0 ? 0.1 : t.height,
950
- fill: "transparent",
951
- onMouseenter: (l) => _t(t),
952
- onMouseleave: (l) => Tt(t),
953
- onClick: () => Pt(t)
954
- }, null, 40, ja))), 256)),
955
- e.value.style.chart.selector.show && h.value ? (r(), n("line", {
956
- key: 0,
957
- x1: h.value.selectorX,
958
- x2: h.value.selectorX,
959
- y1: h.value.y,
960
- y2: h.value.y + h.value.height - C.value / 2,
961
- stroke: e.value.style.chart.selector.stroke,
962
- "stroke-width": e.value.style.chart.selector.strokeWidth,
963
- "stroke-dasharray": e.value.style.chart.selector.strokeDasharray,
964
- "stroke-linecap": "round",
965
- style: { pointerEvents: "none" }
966
- }, null, 8, qa)) : v("", !0),
967
- h.value ? (r(!0), n(g, { key: 1 }, k(H.value, (t) => (r(), n(g, null, [
968
- (r(!0), n(g, null, k(t.datapoints, (o) => (r(), n(g, null, [
969
- (r(!0), n(g, null, k(o.plots, (l, c) => (r(), n(g, null, [
970
- h.value && h.value.index === c ? (r(), n("circle", {
971
- key: 0,
972
- cx: l.x,
973
- cy: l.y,
974
- stroke: e.value.style.chart.selector.dot.stroke,
975
- "stroke-width": e.value.style.chart.selector.dot.strokeWidth,
976
- r: e.value.style.chart.selector.dot.radius,
977
- fill: e.value.style.chart.selector.dot.useDatapointColor ? o.color : e.value.style.chart.selector.dot.fill,
978
- style: {
979
- pointerEvents: "none"
980
- }
981
- }, null, 8, Ka)) : v("", !0),
982
- h.value && h.value.index === c ? (r(), n("text", {
983
- key: 1,
984
- x: He(
985
- l.x,
986
- i(se)(
987
- e.value.style.chart.selector.labels.formatter,
988
- l.value,
989
- i(oe)({
990
- p: e.value.style.chart.xAxis.labels.prefix,
991
- v: l.value,
992
- s: e.value.style.chart.xAxis.labels.suffix,
993
- r: e.value.style.chart.selector.labels.rounding
994
- })
995
- ),
996
- e.value.style.chart.selector.labels.fontSize
997
- ) ? l.x - e.value.style.chart.selector.labels.fontSize / 2 : l.x + e.value.style.chart.selector.labels.fontSize / 2,
998
- y: l.y + e.value.style.chart.selector.labels.fontSize / 3,
999
- "text-anchor": He(
1000
- l.x,
1001
- i(se)(
1002
- e.value.style.chart.selector.labels.formatter,
1003
- l.value,
1004
- i(oe)({
1005
- p: e.value.style.chart.xAxis.labels.prefix,
1006
- v: l.value,
1007
- s: e.value.style.chart.xAxis.labels.suffix,
1008
- r: e.value.style.chart.selector.labels.rounding
1009
- })
1010
- ),
1011
- e.value.style.chart.selector.labels.fontSize
1012
- ) ? "end" : "start",
1013
- "font-size": e.value.style.chart.selector.labels.fontSize,
1014
- fill: e.value.style.chart.selector.labels.color,
1015
- style: {
1016
- pointerEvents: "none"
1017
- }
1018
- }, B(i(se)(
1019
- e.value.style.chart.selector.labels.formatter,
1020
- l.value,
1021
- i(oe)({
1022
- p: e.value.style.chart.xAxis.labels.prefix,
1023
- v: l.value,
1024
- s: e.value.style.chart.xAxis.labels.suffix,
1025
- r: e.value.style.chart.selector.labels.rounding
1026
- })
1027
- )), 9, Ja)) : v("", !0)
1028
- ], 64))), 256))
1029
- ], 64))), 256))
1030
- ], 64))), 256)) : v("", !0)
1031
- ]),
1032
- m(a.$slots, "svg", { svg: f.value }, void 0, !0)
1033
- ], 14, _a)),
1034
- a.$slots.watermark ? (r(), n("div", Qa, [
1035
- m(a.$slots, "watermark", te(ae({ isPrinting: i(Ie) || i(Ne) })), void 0, !0)
1036
- ])) : v("", !0),
1037
- y("div", {
1038
- ref_key: "chartLegend",
1039
- ref: $e
1040
- }, [
1041
- e.value.style.chart.legend.show ? (r(), _(xa, {
1042
- key: `legend_${ie.value}`,
1043
- legendSet: pe.value,
1044
- config: Ot.value,
1045
- onClickMarker: s[0] || (s[0] = ({ legend: t }) => Re(t.id))
1046
- }, Ze({
1047
- item: p(({ legend: t }) => [
1048
- i(U) ? v("", !0) : (r(), n("div", {
1049
- key: 0,
1050
- style: w(`opacity:${M.value.includes(t.id) ? 0.5 : 1}`),
1051
- onClick: (o) => t.segregate()
1052
- }, B(t.name), 13, Za))
1053
- ]),
1054
- _: 2
1055
- }, [
1056
- a.$slots.pattern ? {
1057
- name: "legend-pattern",
1058
- fn: p(({ legend: t, index: o }) => [
1059
- et(Aa, {
1060
- shape: t.shape,
1061
- radius: 30,
1062
- stroke: "none",
1063
- plot: { x: 30, y: 30 },
1064
- fill: `url(#pattern_${A.value}_${o})`
1065
- }, null, 8, ["shape", "fill"])
1066
- ]),
1067
- key: "0"
1068
- } : void 0
1069
- ]), 1032, ["legendSet", "config"])) : v("", !0),
1070
- m(a.$slots, "legend", { legend: pe.value }, void 0, !0)
1071
- ], 512),
1072
- a.$slots.source ? (r(), n("div", {
1073
- key: 5,
1074
- ref_key: "source",
1075
- ref: _e,
1076
- dir: "auto"
1077
- }, [
1078
- m(a.$slots, "source", {}, void 0, !0)
1079
- ], 512)) : v("", !0),
1080
- V.value ? (r(), _(i(vt), {
1081
- key: 6,
1082
- hideDetails: "",
1083
- config: {
1084
- open: R.value.showTable,
1085
- maxHeight: 1e4,
1086
- body: {
1087
- backgroundColor: e.value.style.chart.backgroundColor,
1088
- color: e.value.style.chart.color
1089
- },
1090
- head: {
1091
- backgroundColor: e.value.style.chart.backgroundColor,
1092
- color: e.value.style.chart.color
1093
- }
1094
- }
1095
- }, {
1096
- content: p(() => [
1097
- (r(), _(i(dt), {
1098
- key: `table_${bt.value}`,
1099
- colNames: Q.value.colNames,
1100
- head: Q.value.head,
1101
- body: Q.value.body,
1102
- config: Q.value.config,
1103
- title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` :${e.value.style.chart.title.subtitle.text}` : ""}`,
1104
- onClose: s[1] || (s[1] = (t) => R.value.showTable = !1)
1105
- }, {
1106
- th: p(({ th: t }) => [
1107
- y("div", { innerHTML: t }, null, 8, el)
1108
- ]),
1109
- td: p(({ td: t }) => [
1110
- at(B(t.name ? t.name : i(se)(
1111
- e.value.style.chart.selector.labels.formatter,
1112
- t,
1113
- i(oe)({
1114
- p: e.value.style.chart.xAxis.labels.prefix,
1115
- v: t,
1116
- s: e.value.style.chart.xAxis.labels.suffix,
1117
- r: e.value.table.td.roundingValue
1118
- })
1119
- )), 1)
1120
- ]),
1121
- _: 1
1122
- }, 8, ["colNames", "head", "body", "config", "title"]))
1123
- ]),
1124
- _: 1
1125
- }, 8, ["config"])) : v("", !0),
1126
- e.value.style.chart.dialog.show ? (r(), _(i(ht), {
1127
- key: 7,
1128
- ref_key: "dialog",
1129
- ref: ue,
1130
- onClose: s[2] || (s[2] = (t) => D.value = null),
1131
- backgroundColor: e.value.style.chart.dialog.backgroundColor,
1132
- color: e.value.style.chart.dialog.color,
1133
- headerBg: e.value.style.chart.dialog.header.backgroundColor,
1134
- headerColor: e.value.style.chart.dialog.header.color,
1135
- isFullscreen: X.value,
1136
- fullscreenParent: T.value,
1137
- withPadding: ""
1138
- }, {
1139
- title: p(() => [
1140
- at(B(D.value.name), 1)
1141
- ]),
1142
- default: p(() => [
1143
- D.value ? (r(), _(i(mt), {
1144
- key: 0,
1145
- config: Be.value,
1146
- dataset: Ve.value
1147
- }, null, 8, ["config", "dataset"])) : v("", !0)
1148
- ]),
1149
- _: 1
1150
- }, 8, ["backgroundColor", "color", "headerBg", "headerColor", "isFullscreen", "fullscreenParent"])) : v("", !0),
1151
- i(U) ? (r(), _(ya, { key: 8 })) : v("", !0)
1152
- ], 46, $a));
1153
- }
1154
- }, ml = /* @__PURE__ */ wa(tl, [["__scopeId", "data-v-e3880d82"]]);
1155
- export {
1156
- ml as default
1157
- };