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
@@ -0,0 +1,1100 @@
1
+ import { useCssVars as Gt, defineAsyncComponent as W, ref as v, shallowRef as nt, toRefs as Wt, watch as Me, computed as $, onMounted as st, onBeforeUnmount as rt, createElementBlock as i, openBlock as r, unref as d, normalizeStyle as F, normalizeClass as R, createBlock as j, createCommentVNode as h, renderSlot as w, createElementVNode as I, createSlots as xe, withCtx as x, normalizeProps as de, guardReactiveProps as he, withModifiers as ut, createVNode as fe, Fragment as z, renderList as q, mergeProps as it, toDisplayString as H, Teleport as qt, resolveDynamicComponent as Ht, createTextVNode as ct, nextTick as vt } from "vue";
2
+ import { u as Qt, c as Ae, t as Zt, a as Jt, p as ge, b as Kt, o as ea, f as dt, g as ta, d as aa, e as oa, X as la, F as na, i as Ie, a0 as sa, ab as ra, v as ua, w as ia, k as ca } from "./index-CDQbCd41.js";
3
+ import { t as va, u as da } from "./useResponsive-DfdjqQps.js";
4
+ import { u as ha, B as fa } from "./BaseScanner-BgWxam9d.js";
5
+ import { u as ga } from "./usePrinter-Bnl1YeUU.js";
6
+ import { u as ht } from "./useNestedProp-BPEHGiYX.js";
7
+ import { u as ba } from "./useUserOptionState-BIvW1Kz7.js";
8
+ import { u as pa } from "./useChartAccessibility-9icAAmYg.js";
9
+ import ma from "./img-JOqdlnUs.js";
10
+ import { _ as ya } from "./Shape-Dj2Hl33H.js";
11
+ import ka from "./Title-Dq2_Z9kR.js";
12
+ import $a from "./Legend-2-dC7DVb.js";
13
+ import { _ as wa } from "./_plugin-vue_export-helper-CHgC5LLL.js";
14
+ const Ca = ["id"], Ma = ["id"], xa = ["xmlns", "viewBox"], Aa = ["width", "height"], Ia = { key: 1 }, Pa = ["id", "d"], _a = { key: 2 }, Ta = ["transform"], Ba = ["d", "fill", "stroke", "stroke-width", "onMouseenter", "onMouseleave", "onClick"], Sa = ["d", "fill", "stroke", "stroke-width"], Oa = ["d", "fill"], La = ["d", "fill", "stroke", "stroke-width", "onMouseenter", "onClick", "onMouseleave"], Da = ["d", "fill", "stroke", "stroke-width"], Ea = ["d", "fill", "stroke", "stroke-width"], Na = ["d", "fill", "stroke", "stroke-width"], Fa = { key: 0 }, Ra = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], za = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], Ua = ["cx", "cy", "r", "stroke", "stroke-width", "fill"], Xa = ["transform", "fill", "text-anchor", "font-size", "font-weight"], Va = { key: 1 }, ja = ["font-size", "font-weight", "fill"], Ya = ["href"], Ga = ["transform", "text-anchor", "font-size", "font-weight", "fill", "innerHTML"], Wa = {
15
+ key: 4,
16
+ class: "vue-data-ui-watermark"
17
+ }, qa = ["id"], Ha = ["onClick"], Qa = {
18
+ key: 7,
19
+ "data-dom-to-png-ignore": "",
20
+ class: "reset-wrapper"
21
+ }, Za = { style: { "text-align": "right", width: "100%" } }, Ja = {
22
+ __name: "vue-ui-chord",
23
+ props: {
24
+ dataset: {
25
+ type: Object,
26
+ default() {
27
+ return {};
28
+ }
29
+ },
30
+ config: {
31
+ type: Object,
32
+ default() {
33
+ return {};
34
+ }
35
+ }
36
+ },
37
+ emits: ["selectLegend", "selectGroup", "selectRibbon"],
38
+ setup(ft, { expose: gt, emit: bt }) {
39
+ Gt((t) => ({
40
+ "8b4d975e": t.slicerColor
41
+ }));
42
+ const pt = W(() => import("./vue-ui-accordion-Bf_LHFFX.js")), Pe = W(() => import("./BaseIcon-DHtro8us.js")), mt = W(() => import("./DataTable-DJjA2_wf.js")), yt = W(() => import("./PackageVersion-DU12WH3O.js")), kt = W(() => import("./PenAndPaper-B7QEDgx4.js")), $t = W(() => import("./UserOptions-BuGfCdAY.js")), wt = W(() => import("./BaseDraggableDialog-O7900pGp.js")), { vue_ui_chord: Ct } = Qt(), S = ft, ne = bt, E = v(!!S.dataset && Object.hasOwn(S.dataset, "matrix")), k = v(Ae()), C = v(null), p = v(null), g = v(null), _e = v(0), O = v(null), Te = v(null), Be = v(null), Se = v(null), Oe = v(null), be = v(0), pe = v(0), me = v(0), Q = v(!1), U = nt(null), Z = nt(null), Le = v(!1), J = v(null), e = v(ke()), { loading: De, FINAL_DATASET: M, manualLoading: K } = ha({
43
+ ...Wt(S),
44
+ FINAL_CONFIG: e,
45
+ prepareConfig: ke,
46
+ callback: () => {
47
+ Promise.resolve().then(async () => {
48
+ await vt(), X.value.showTable = e.value.table.show;
49
+ });
50
+ },
51
+ skeletonDataset: {
52
+ matrix: [
53
+ [12e3, 6e3, 9e3, 3e3],
54
+ [2e3, 1e4, 2e3, 6001],
55
+ [8e3, 1600, 8e3, 8001],
56
+ [1e3, 1e3, 1e3, 7001]
57
+ ],
58
+ labels: [],
59
+ colors: ["#DBDBDB", "#C4C4C4", "#ADADAD", "#969696"]
60
+ },
61
+ skeletonConfig: Zt({
62
+ defaultConfig: e.value,
63
+ userConfig: {
64
+ useCssAnimation: !1,
65
+ userOptions: { show: !1 },
66
+ table: { show: !1 },
67
+ style: {
68
+ chart: {
69
+ backgroundColor: "#99999930",
70
+ legend: {
71
+ backgroundColor: "transparent"
72
+ },
73
+ arcs: {
74
+ stroke: "#6A6A6A",
75
+ labels: {
76
+ show: !1
77
+ }
78
+ },
79
+ ribbons: {
80
+ stroke: "#6A6A6A",
81
+ underlayerOpacity: 0,
82
+ labels: {
83
+ show: !1
84
+ }
85
+ }
86
+ }
87
+ }
88
+ }
89
+ })
90
+ }), { userOptionsVisible: ye, setUserOptionsVisibility: Ee, keepUserOptionState: Ne } = ba({ config: e.value }), { svgRef: ee } = pa({ config: e.value.style.chart.title }), { isPrinting: Fe, isImaging: Re, generatePdf: ze, generateImage: Ue } = ga({
91
+ elementId: `chord_${k.value}`,
92
+ fileName: e.value.style.chart.title.text || "vue-ui-chord",
93
+ options: e.value.userOptions.print
94
+ }), X = v({
95
+ showTable: e.value.table.show
96
+ });
97
+ function ke() {
98
+ const t = ht({
99
+ userConfig: S.config,
100
+ defaultConfig: Ct
101
+ });
102
+ return t.theme ? {
103
+ ...ht({
104
+ userConfig: Kt.vue_ui_chord[t.theme] || S.config,
105
+ defaultConfig: t
106
+ }),
107
+ customPalette: Jt[t.theme] || ge
108
+ } : t;
109
+ }
110
+ Me(() => S.config, (t) => {
111
+ De.value || (e.value = ke()), ye.value = !e.value.userOptions.showOnChartHover, $e(), be.value += 1, pe.value += 1, me.value += 1, P.value = e.value.initialRotation, X.value.showTable = e.value.table.show;
112
+ }, { deep: !0 });
113
+ const Xe = $(() => e.value.debug);
114
+ Me(() => S.dataset, () => {
115
+ Ve(), $e(), be.value += 1, pe.value += 1, me.value += 1;
116
+ });
117
+ function Ve() {
118
+ if (ea(S.dataset)) {
119
+ dt({
120
+ componentName: "VueUiChord",
121
+ type: "dataset",
122
+ debug: Xe.value
123
+ }), E.value = !1, K.value = !0;
124
+ return;
125
+ }
126
+ const t = ta({
127
+ datasetObject: S.dataset,
128
+ requiredAttributes: ["matrix"]
129
+ });
130
+ if (t.length) {
131
+ t.forEach((s) => {
132
+ dt({
133
+ componentName: "VueUiChord",
134
+ type: "datasetAttribute",
135
+ property: s,
136
+ debug: Xe.value
137
+ });
138
+ }), E.value = !1, K.value = !0;
139
+ return;
140
+ }
141
+ const o = S.dataset.matrix;
142
+ if (!Array.isArray(o) || o.length < 2) {
143
+ console.warn(`VueUiChord: dataset.matrix requires a minimum of 2 datapoints, for example:
144
+
145
+ matrix:[
146
+ [1, 1],
147
+ [1, 1]
148
+ ]`), E.value = !1, K.value = !0;
149
+ return;
150
+ }
151
+ const a = o.length, l = o.findIndex((s) => !Array.isArray(s) || s.length !== a);
152
+ if (l !== -1) {
153
+ console.warn(
154
+ `VueUiChord - Invalid matrix: dataset.matrix at index ${l} has ${Array.isArray(o[l]) ? o[l].length : "NaN"} elements instead of the required ${a}
155
+
156
+ dataset.matrix[${l}] = [${Array.isArray(o[l]) ? o[l].toString() : "invalid"}]`
157
+ ), E.value = !1, K.value = !0;
158
+ return;
159
+ }
160
+ E.value = !0, K.value = !1;
161
+ }
162
+ function $e() {
163
+ if (Ve(), e.value.responsive) {
164
+ const t = va(() => {
165
+ const { width: o, height: a, heightNoTitle: l, heightSource: s, heightTitle: n, heightLegend: u } = da({
166
+ chart: O.value,
167
+ title: e.value.style.chart.title.text ? Te.value : null,
168
+ legend: e.value.style.chart.legend.show ? Be.value : null,
169
+ source: Se.value,
170
+ noTitle: Oe.value
171
+ }), f = n + u + s + l;
172
+ o < a ? O.value.style.width = "100%" : (O.value.style.height = "100%", ee.value.style.height = `calc(100% - ${f}px)`);
173
+ }, 100);
174
+ U.value && (Z.value && U.value.unobserve(Z.value), U.value.disconnect()), U.value = new ResizeObserver(t), Z.value = O.value.parentNode, U.value.observe(Z.value), t();
175
+ }
176
+ je.value = setTimeout(() => {
177
+ Q.value = !0;
178
+ }, 500);
179
+ }
180
+ function Mt() {
181
+ if (!M.value || !Object.hasOwn(M.value, "matrix") || M.value.matrix.length < 2) {
182
+ console.warn(`VueUiChord: dataset.matrix requires a minimum of 2 datapoints, for example:
183
+
184
+ matrix:[
185
+ [1, 1],
186
+ [1, 1]
187
+ ]`), E.value = !1;
188
+ return;
189
+ }
190
+ M.value.matrix.forEach((t, o) => {
191
+ t.length !== M.value.matrix.length && (console.warn(`VueUiChord - Invalid matrix: dataset.matrix at index ${o} has ${t.length} elements instead of the required ${M.value.matrix.length}
192
+
193
+ dataset.matrix[${o}] = [${t.toString()}] has a length of ${t.length} but should have the same length as the matrix itself (${M.value.matrix.length})`), E.value = !1);
194
+ });
195
+ }
196
+ const je = v(null);
197
+ st(() => {
198
+ Le.value = !0, $e();
199
+ });
200
+ const L = v({
201
+ height: 600,
202
+ width: 600
203
+ }), xt = $(() => e.value.userOptions.show && !e.value.style.chart.title.text), At = $(() => aa(e.value.customPalette)), b = $(() => ({
204
+ inner: L.value.width * 0.3 * e.value.style.chart.arcs.innerRadiusRatio,
205
+ outer: L.value.width * 0.34 * e.value.style.chart.arcs.outerRadiusRatio
206
+ })), It = $(() => e.value.style.chart.arcs.padAngle / 100), m = $(() => ({
207
+ matrix: M.value.matrix ?? [[0]],
208
+ labels: M.value.labels ?? [""],
209
+ colors: M.value.colors && Array.isArray(M.value.colors) && M.value.colors.length ? M.value.colors.map((t) => oa(t)) : M.value.matrix.map((t, o) => At.value[o] || ge[o] || ge[o % ge.length])
210
+ }));
211
+ function Pt(t, o) {
212
+ const a = t.length, l = b.value.inner, s = new Array(a).fill(0);
213
+ let n = 0;
214
+ for (let c = 0; c < a; c += 1)
215
+ for (let y = 0; y < a; y += 1)
216
+ s[c] += t[c][y], n += t[c][y];
217
+ const u = (2 * Math.PI - o * a) / n, f = [];
218
+ let _ = 0;
219
+ for (let c = 0; c < a; c += 1) {
220
+ const y = _, B = y + s[c] * u;
221
+ f.push({
222
+ index: c,
223
+ pattern: `pattern_${k.value}_${c}`,
224
+ startAngle: y,
225
+ endAngle: B,
226
+ name: m.value.labels[c],
227
+ id: Ae(),
228
+ color: m.value.colors[c],
229
+ proportion: s[c] / n
230
+ }), _ = B + o;
231
+ }
232
+ const T = [];
233
+ for (let c = 0; c < a; c += 1) {
234
+ const y = t[c].map((D, V) => ({ j: V, v: D }));
235
+ y.sort((D, V) => V.v - D.v);
236
+ let B = f[c].startAngle;
237
+ for (const { j: D, v: V } of y) {
238
+ const G = B, le = G + V * u;
239
+ T.push({
240
+ index: c,
241
+ subIndex: D,
242
+ pattern: `pattern_${k.value}_${c}`,
243
+ startAngle: G,
244
+ endAngle: le,
245
+ value: V,
246
+ groupName: m.value.labels[c],
247
+ groupId: f[c].id,
248
+ groupColor: m.value.colors[c],
249
+ midAngle: (G + le) / 2,
250
+ midBaseX: Math.cos((G + le) / 2 - Math.PI / 2) * l,
251
+ midBaseY: Math.sin((G + le) / 2 - Math.PI / 2) * l
252
+ }), B = le;
253
+ }
254
+ }
255
+ const N = [];
256
+ for (const c of T) {
257
+ const y = T.find(
258
+ (B) => B.index === c.subIndex && B.subIndex === c.index
259
+ );
260
+ N.push({ source: c, target: y, id: Ae() });
261
+ }
262
+ return { groups: f, chords: N };
263
+ }
264
+ const A = $(() => {
265
+ const t = Pt(m.value.matrix, It.value);
266
+ return Mt(), t.chords.sort(
267
+ (o, a) => Math.max(a.source.value, a.target.value) - Math.max(o.source.value, o.target.value)
268
+ ), t;
269
+ }), _t = $(() => {
270
+ const t = b.value.outer + e.value.style.chart.ribbons.labels.offset + 12, a = e.value.style.chart.ribbons.labels.fontSize * 0.6, l = [];
271
+ if (p.value) {
272
+ const n = p.value;
273
+ if (n.source.value) {
274
+ const u = String(n.source.value);
275
+ l.push({
276
+ id: n.id + "-src",
277
+ theta: n.source.midAngle,
278
+ w: u.length * a / t,
279
+ midBaseX: n.source.midBaseX,
280
+ midBaseY: n.source.midBaseY,
281
+ groupColor: n.source.groupColor,
282
+ value: n.source.value
283
+ });
284
+ }
285
+ if (n.target && n.target.value && n.target.value !== n.source.value) {
286
+ const u = String(n.target.value);
287
+ l.push({
288
+ id: n.id + "-tgt",
289
+ theta: n.target.midAngle,
290
+ w: u.length * a / t,
291
+ midBaseX: n.target.midBaseX,
292
+ midBaseY: n.target.midBaseY,
293
+ groupColor: n.target.groupColor,
294
+ value: n.target.value
295
+ });
296
+ }
297
+ return l;
298
+ }
299
+ function s(n) {
300
+ A.value.chords.filter((u) => u.source.groupId === n && u.source.value).forEach((u) => {
301
+ {
302
+ const f = String(u.source.value);
303
+ l.push({
304
+ id: u.id + "-src",
305
+ theta: u.source.midAngle,
306
+ w: f.length * a / t,
307
+ midBaseX: u.source.midBaseX,
308
+ midBaseY: u.source.midBaseY,
309
+ groupColor: u.source.groupColor,
310
+ value: u.source.value
311
+ });
312
+ }
313
+ if (u.target && u.target.value && u.target.value !== u.source.value) {
314
+ const f = String(u.target.value);
315
+ l.push({
316
+ id: u.id + "-tgt",
317
+ theta: u.target.midAngle,
318
+ w: f.length * a / t,
319
+ midBaseX: u.target.midBaseX,
320
+ midBaseY: u.target.midBaseY,
321
+ groupColor: u.target.groupColor,
322
+ value: u.target.value
323
+ });
324
+ }
325
+ });
326
+ }
327
+ return g.value && s(g.value), C.value && s(C.value.id), l;
328
+ }), Tt = $(() => {
329
+ const t = _t.value.map((s) => ({ ...s })).sort((s, n) => s.theta - n.theta), o = e.value.style.chart.ribbons.labels.minSeparationDeg * Math.PI / 180;
330
+ let a = !0, l = 0;
331
+ for (; a && l++ < 10; ) {
332
+ a = !1;
333
+ for (let f = 1; f < t.length; f += 1) {
334
+ const _ = t[f - 1], T = t[f], N = _.theta + _.w + o;
335
+ T.theta < N && (T.theta = N, a = !0);
336
+ }
337
+ const s = t[0], n = t[t.length - 1], u = n.theta + n.w + o - 2 * Math.PI;
338
+ s.theta < u && (s.theta = u, a = !0);
339
+ }
340
+ return t;
341
+ });
342
+ function Ye(t, o, a, l) {
343
+ const s = t - Math.PI / 2, n = o - Math.PI / 2, u = Math.cos(s) * a, f = Math.sin(s) * a, _ = Math.cos(n) * a, T = Math.sin(n) * a, N = Math.cos(n) * l, c = Math.sin(n) * l, y = Math.cos(s) * l, B = Math.sin(s) * l, D = o - t > Math.PI ? 1 : 0;
344
+ return `M${u},${f} A${a},${a} 0 ${D} 1 ${_},${T} L${N},${c} A${l},${l} 0 ${D} 0 ${y},${B} Z`;
345
+ }
346
+ function se(t, o) {
347
+ const a = b.value.inner, l = t.startAngle - Math.PI / 2, s = t.endAngle - Math.PI / 2, n = o.startAngle - Math.PI / 2, u = o.endAngle - Math.PI / 2, f = Math.cos(l) * a, _ = Math.sin(l) * a, T = Math.cos(s) * a, N = Math.sin(s) * a, c = Math.cos(n) * a, y = Math.sin(n) * a, B = Math.cos(u) * a, D = Math.sin(u) * a, V = t.endAngle - t.startAngle > Math.PI ? 1 : 0, G = o.endAngle - o.startAngle > Math.PI ? 1 : 0;
348
+ return `M${f},${_}A${a},${a} 0 ${V} 1 ${T},${N}Q0,0 ${c},${y}A${a},${a} 0 ${G} 1 ${B},${D}Q0,0 ${f},${_}Z`;
349
+ }
350
+ const Ge = $(() => P.value * Math.PI / 180);
351
+ function Bt(t) {
352
+ return (t.startAngle + t.endAngle) / 2;
353
+ }
354
+ function St(t) {
355
+ return ((Bt(t) + Ge.value) % (2 * Math.PI) + 2 * Math.PI) % (2 * Math.PI);
356
+ }
357
+ function Ot(t) {
358
+ let o = t + Ge.value;
359
+ return o = (o % (2 * Math.PI) + 2 * Math.PI) % (2 * Math.PI), o > Math.PI ? "end" : "start";
360
+ }
361
+ function Lt(t) {
362
+ const o = t - Math.PI / 2, a = Math.cos(o) * (b.value.outer + e.value.style.chart.arcs.labels.offset + 24), l = Math.sin(o) * (b.value.outer + e.value.style.chart.arcs.labels.offset + 24);
363
+ return `translate(${a},${l})`;
364
+ }
365
+ function Dt(t, o, a) {
366
+ const l = t - Math.PI / 2, s = o - Math.PI / 2, n = Math.cos(l) * a, u = Math.sin(l) * a, f = Math.cos(s) * a, _ = Math.sin(s) * a, T = o - t > Math.PI ? 1 : 0;
367
+ return `M${n},${u} A${a},${a} 0 ${T} 1 ${f},${_}`;
368
+ }
369
+ const P = v(e.value.initialRotation), te = v(!1);
370
+ let We = 0, qe = 0;
371
+ function He(t) {
372
+ const o = ee.value.getBoundingClientRect(), a = o.left + o.width / 2, l = o.top + o.height / 2, s = t.clientX ?? t.touches[0].clientX, n = t.clientY ?? t.touches[0].clientY;
373
+ return Math.atan2(n - l, s - a);
374
+ }
375
+ function Qe(t) {
376
+ !e.value.enableRotation || ae.value || (t.preventDefault(), te.value = !0, We = P.value, qe = He(t));
377
+ }
378
+ function re(t) {
379
+ if (!te.value) return;
380
+ const o = He(t);
381
+ P.value = We + (o - qe) * 180 / Math.PI;
382
+ }
383
+ function ue() {
384
+ te.value = !1;
385
+ }
386
+ function Ze(t) {
387
+ return ca(
388
+ e.value.style.chart.ribbons.labels.formatter,
389
+ t,
390
+ Ie({
391
+ p: e.value.style.chart.ribbons.labels.prefix,
392
+ v: t,
393
+ s: e.value.style.chart.ribbons.labels.suffix,
394
+ r: e.value.style.chart.ribbons.labels.rounding
395
+ })
396
+ );
397
+ }
398
+ st(() => {
399
+ window.addEventListener("mousemove", re), window.addEventListener("mouseup", ue), window.addEventListener("touchmove", re, { passive: !1 }), window.addEventListener("touchend", ue);
400
+ }), rt(() => {
401
+ window.removeEventListener("mousemove", re), window.removeEventListener("mouseup", ue), window.removeEventListener("touchmove", re), window.removeEventListener("touchend", ue), clearTimeout(je.value), U.value && (Z.value && U.value.unobserve(Z.value), U.value.disconnect());
402
+ });
403
+ const ie = v(!1);
404
+ function Je(t) {
405
+ ie.value = t, _e.value += 1;
406
+ }
407
+ function Et(t, o) {
408
+ e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: o }), !g.value && (C.value = t);
409
+ }
410
+ function Nt(t, o) {
411
+ C.value = null, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: o });
412
+ }
413
+ function Ft(t, o) {
414
+ ne("selectGroup", t), e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: o });
415
+ }
416
+ function Rt(t, o) {
417
+ e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: t, seriesIndex: o }), !g.value && (p.value = t);
418
+ }
419
+ function zt(t, o) {
420
+ p.value = null, e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: t, seriesIndex: o });
421
+ }
422
+ function Ut(t, o) {
423
+ ne("selectRibbon", t), e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: t, seriesIndex: o });
424
+ }
425
+ function Ke(t) {
426
+ return !g.value && !C.value && !p.value ? 0.8 : (g.value ? g.value === t.source.groupId : C.value ? C.value.id === t.source.groupId : p.value?.id === t.id) ? 1 : 0.1;
427
+ }
428
+ function et(t) {
429
+ return !g.value && !C.value && !p.value || (g.value ? g.value === t.id : C.value ? C.value.id === t.id : [p.value?.source.groupId, p.value?.target.groupId].includes(t.id)) ? 1 : 0.3;
430
+ }
431
+ const ae = v(!1);
432
+ function we() {
433
+ ae.value = !ae.value;
434
+ }
435
+ function tt() {
436
+ X.value.showTable = !X.value.showTable;
437
+ }
438
+ function Xt() {
439
+ return A.value;
440
+ }
441
+ const Y = v(null);
442
+ function at() {
443
+ const t = e.value.initialRotation;
444
+ Y.value !== null && cancelAnimationFrame(Y.value);
445
+ const o = () => {
446
+ P.value += (t - P.value) * 0.05, Math.abs(P.value - t) < 0.1 ? (P.value = t, Y.value = null) : Y.value = requestAnimationFrame(o);
447
+ };
448
+ Y.value = requestAnimationFrame(o);
449
+ }
450
+ rt(() => {
451
+ Y.value !== null && cancelAnimationFrame(Y.value);
452
+ });
453
+ function ot(t) {
454
+ t === g.value ? (g.value = null, ne("selectLegend", null)) : (g.value = t, ne("selectLegend", A.value.groups.find((o) => o.id === t)));
455
+ }
456
+ const lt = $(() => A.value.groups.map((t, o) => ({
457
+ name: t.name,
458
+ color: t.color,
459
+ shape: "circle",
460
+ patternIndex: o,
461
+ pattern: `pattern_${k.value}_${o}`,
462
+ id: t.id,
463
+ select: () => ot(t.id),
464
+ opacity: g.value ? g.value === t.id ? 1 : 0.3 : 1
465
+ }))), Vt = $(() => ({
466
+ cy: "chord-div-legend",
467
+ backgroundColor: e.value.style.chart.legend.backgroundColor,
468
+ color: e.value.style.chart.legend.color,
469
+ fontSize: e.value.style.chart.legend.fontSize,
470
+ paddingBottom: 12,
471
+ fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
472
+ })), ce = $(() => {
473
+ const t = A.value.groups.map((a, l) => ({
474
+ name: a.name || l,
475
+ color: a.color
476
+ })), o = m.value.matrix;
477
+ return { head: t, body: o };
478
+ }), ve = $(() => {
479
+ const t = [{ name: "", color: null }, ...ce.value.head], o = ce.value.body.map((s, n) => [
480
+ ce.value.head[n],
481
+ ...ce.value.body[n]
482
+ ]), a = {
483
+ th: {
484
+ backgroundColor: e.value.table.th.backgroundColor,
485
+ color: e.value.table.th.color,
486
+ outline: e.value.table.th.outline
487
+ },
488
+ td: {
489
+ backgroundColor: e.value.table.td.backgroundColor,
490
+ color: e.value.table.td.color,
491
+ outline: e.value.table.td.outline
492
+ },
493
+ breakpoint: e.value.table.responsiveBreakpoint
494
+ };
495
+ return {
496
+ colNames: t,
497
+ head: t,
498
+ body: o,
499
+ config: a
500
+ };
501
+ });
502
+ function Ce(t = null) {
503
+ vt(() => {
504
+ const o = m.value.matrix.map((s, n) => [
505
+ [m.value.labels[n] || n],
506
+ s
507
+ ]), a = [
508
+ [e.value.style.chart.title.text],
509
+ [e.value.style.chart.title.subtitle.text],
510
+ [
511
+ [""],
512
+ ...m.value.labels.map((s, n) => [s || n])
513
+ ]
514
+ ].concat(o), l = ua(a);
515
+ t ? t(l) : ia({ csvContent: l, title: e.value.style.chart.title.text || "vue-ui-chord" });
516
+ });
517
+ }
518
+ async function jt({ scale: t = 2 } = {}) {
519
+ if (!O.value) return;
520
+ const { width: o, height: a } = O.value.getBoundingClientRect(), l = o / a, { imageUri: s, base64: n } = await ma({ domElement: O.value, base64: !0, img: !0, scale: t });
521
+ return {
522
+ imageUri: s,
523
+ base64: n,
524
+ title: e.value.style.chart.title.text,
525
+ width: o,
526
+ height: a,
527
+ aspectRatio: l
528
+ };
529
+ }
530
+ function Yt(t, o) {
531
+ return `${m.value.labels[o]}${e.value.style.chart.arcs.labels.showPercentage ? Ie({
532
+ p: " (",
533
+ v: isNaN(t.proportion) ? 0 : t.proportion * 100,
534
+ s: "%)",
535
+ r: e.value.style.chart.arcs.labels.roundingPercentage
536
+ }) : ""}`;
537
+ }
538
+ const oe = $(() => {
539
+ const t = e.value.table.useDialog && !e.value.table.show, o = X.value.showTable;
540
+ return {
541
+ component: t ? wt : pt,
542
+ title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? `: ${e.value.style.chart.title.subtitle.text}` : ""}`,
543
+ props: t ? {
544
+ backgroundColor: e.value.table.th.backgroundColor,
545
+ color: e.value.table.th.color,
546
+ headerColor: e.value.table.th.color,
547
+ headerBg: e.value.table.th.backgroundColor,
548
+ isFullscreen: ie.value,
549
+ fullscreenParent: O.value,
550
+ forcedWidth: Math.min(800, window.innerWidth * 0.8)
551
+ } : {
552
+ hideDetails: !0,
553
+ config: {
554
+ open: o,
555
+ maxHeight: 1e4,
556
+ body: {
557
+ backgroundColor: e.value.style.chart.backgroundColor,
558
+ color: e.value.style.chart.color
559
+ },
560
+ head: {
561
+ backgroundColor: e.value.style.chart.backgroundColor,
562
+ color: e.value.style.chart.color
563
+ }
564
+ }
565
+ }
566
+ };
567
+ });
568
+ return Me(() => X.value.showTable, (t) => {
569
+ e.value.table.show || (t && e.value.table.useDialog && J.value ? J.value.open() : "close" in J.value && J.value.close());
570
+ }), gt({
571
+ getData: Xt,
572
+ getImage: jt,
573
+ generateCsv: Ce,
574
+ generateImage: Ue,
575
+ generatePdf: ze,
576
+ toggleAnnotator: we,
577
+ toggleTable: tt,
578
+ toggleFullscreen: Je
579
+ }), (t, o) => (r(), i("div", {
580
+ ref_key: "chordChart",
581
+ ref: O,
582
+ class: R({
583
+ "vue-ui-chord": !0,
584
+ "vue-data-ui-wrapper-fullscreen": ie.value,
585
+ "vue-data-ui-responsive": e.value.responsive
586
+ }),
587
+ style: F(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;background:${e.value.style.chart.backgroundColor}`),
588
+ id: `chord_${k.value}`,
589
+ onMouseenter: o[4] || (o[4] = () => d(Ee)(!0)),
590
+ onMouseleave: o[5] || (o[5] = () => d(Ee)(!1))
591
+ }, [
592
+ e.value.userOptions.buttons.annotator && d(ee) ? (r(), j(d(kt), {
593
+ key: 0,
594
+ color: e.value.style.chart.color,
595
+ backgroundColor: e.value.style.chart.backgroundColor,
596
+ active: ae.value,
597
+ svgRef: d(ee),
598
+ onClose: we
599
+ }, null, 8, ["color", "backgroundColor", "active", "svgRef"])) : h("", !0),
600
+ w(t.$slots, "userConfig", {}, void 0, !0),
601
+ xt.value ? (r(), i("div", {
602
+ key: 1,
603
+ ref_key: "noTitle",
604
+ ref: Oe,
605
+ class: "vue-data-ui-no-title-space",
606
+ style: "height:36px; width: 100%;background:transparent"
607
+ }, null, 512)) : h("", !0),
608
+ e.value.style.chart.title.text ? (r(), i("div", {
609
+ key: 2,
610
+ ref_key: "chartTitle",
611
+ ref: Te,
612
+ style: "width:100%;background:transparent;padding-bottom:24px"
613
+ }, [
614
+ (r(), j(ka, {
615
+ key: `title_${be.value}`,
616
+ config: {
617
+ title: {
618
+ cy: "chord-div-title",
619
+ ...e.value.style.chart.title
620
+ },
621
+ subtitle: {
622
+ cy: "chord-div-subtitle",
623
+ ...e.value.style.chart.title.subtitle
624
+ }
625
+ }
626
+ }, null, 8, ["config"]))
627
+ ], 512)) : h("", !0),
628
+ I("div", {
629
+ id: `legend-top-${k.value}`
630
+ }, null, 8, Ma),
631
+ e.value.userOptions.show && E.value && (d(Ne) || d(ye)) ? (r(), j(d($t), {
632
+ ref: "details",
633
+ key: `user_option_${_e.value}`,
634
+ backgroundColor: e.value.style.chart.backgroundColor,
635
+ color: e.value.style.chart.color,
636
+ isPrinting: d(Fe),
637
+ isImaging: d(Re),
638
+ uid: k.value,
639
+ hasTooltip: !1,
640
+ hasPdf: e.value.userOptions.buttons.pdf,
641
+ hasImg: e.value.userOptions.buttons.img,
642
+ hasXls: e.value.userOptions.buttons.csv,
643
+ hasTable: e.value.userOptions.buttons.table,
644
+ hasLabel: !1,
645
+ hasFullscreen: e.value.userOptions.buttons.fullscreen,
646
+ isFullscreen: ie.value,
647
+ chartElement: O.value,
648
+ position: e.value.userOptions.position,
649
+ titles: { ...e.value.userOptions.buttonTitles },
650
+ hasAnnotator: e.value.userOptions.buttons.annotator,
651
+ isAnnotation: ae.value,
652
+ callbacks: e.value.userOptions.callbacks,
653
+ printScale: e.value.userOptions.print.scale,
654
+ onToggleFullscreen: Je,
655
+ onGeneratePdf: d(ze),
656
+ onGenerateCsv: Ce,
657
+ onGenerateImage: d(Ue),
658
+ onToggleTable: tt,
659
+ onToggleAnnotator: we,
660
+ style: F({
661
+ visibility: d(Ne) ? d(ye) ? "visible" : "hidden" : "visible"
662
+ })
663
+ }, xe({ _: 2 }, [
664
+ t.$slots.menuIcon ? {
665
+ name: "menuIcon",
666
+ fn: x(({ isOpen: a, color: l }) => [
667
+ w(t.$slots, "menuIcon", de(he({ isOpen: a, color: l })), void 0, !0)
668
+ ]),
669
+ key: "0"
670
+ } : void 0,
671
+ t.$slots.optionPdf ? {
672
+ name: "optionPdf",
673
+ fn: x(() => [
674
+ w(t.$slots, "optionPdf", {}, void 0, !0)
675
+ ]),
676
+ key: "1"
677
+ } : void 0,
678
+ t.$slots.optionCsv ? {
679
+ name: "optionCsv",
680
+ fn: x(() => [
681
+ w(t.$slots, "optionCsv", {}, void 0, !0)
682
+ ]),
683
+ key: "2"
684
+ } : void 0,
685
+ t.$slots.optionImg ? {
686
+ name: "optionImg",
687
+ fn: x(() => [
688
+ w(t.$slots, "optionImg", {}, void 0, !0)
689
+ ]),
690
+ key: "3"
691
+ } : void 0,
692
+ t.$slots.optionTable ? {
693
+ name: "optionTable",
694
+ fn: x(() => [
695
+ w(t.$slots, "optionTable", {}, void 0, !0)
696
+ ]),
697
+ key: "4"
698
+ } : void 0,
699
+ t.$slots.optionFullscreen ? {
700
+ name: "optionFullscreen",
701
+ fn: x(({ toggleFullscreen: a, isFullscreen: l }) => [
702
+ w(t.$slots, "optionFullscreen", de(he({ toggleFullscreen: a, isFullscreen: l })), void 0, !0)
703
+ ]),
704
+ key: "5"
705
+ } : void 0,
706
+ t.$slots.optionAnnotator ? {
707
+ name: "optionAnnotator",
708
+ fn: x(({ toggleAnnotator: a, isAnnotator: l }) => [
709
+ w(t.$slots, "optionAnnotator", de(he({ toggleAnnotator: a, isAnnotator: l })), void 0, !0)
710
+ ]),
711
+ key: "6"
712
+ } : void 0
713
+ ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "chartElement", "position", "titles", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : h("", !0),
714
+ (r(), i("svg", {
715
+ xmlns: d(la),
716
+ ref_key: "svgRef",
717
+ ref: ee,
718
+ viewBox: `0 0 ${L.value.width} ${L.value.height}`,
719
+ preserveAspectRatio: "xMidYMid meet",
720
+ style: {
721
+ overflow: "visible"
722
+ },
723
+ class: R({ "vue-ui-chord-rotating": te.value, "vue-ui-chord-idle": !te.value }),
724
+ onMousedown: ut(Qe, ["prevent"]),
725
+ onTouchstart: ut(Qe, ["prevent"])
726
+ }, [
727
+ fe(d(yt)),
728
+ t.$slots["chart-background"] ? (r(), i("foreignObject", {
729
+ key: 0,
730
+ x: 0,
731
+ y: 0,
732
+ width: L.value.width <= 0 ? 10 : L.value.width,
733
+ height: L.value.height <= 0 ? 10 : L.value.height,
734
+ style: {
735
+ pointerEvents: "none"
736
+ }
737
+ }, [
738
+ w(t.$slots, "chart-background", {}, void 0, !0)
739
+ ], 8, Aa)) : h("", !0),
740
+ e.value.style.chart.arcs.labels.curved ? (r(), i("defs", Ia, [
741
+ (r(!0), i(z, null, q(A.value.groups, (a, l) => (r(), i("path", {
742
+ key: `labelPath-${l}`,
743
+ id: `labelPath-${l}_${k.value}`,
744
+ d: Dt(
745
+ a.startAngle,
746
+ a.endAngle,
747
+ (b.value.inner + b.value.outer) / 2 + e.value.style.chart.arcs.labels.offset
748
+ ),
749
+ fill: "none"
750
+ }, null, 8, Pa))), 128))
751
+ ])) : h("", !0),
752
+ t.$slots.pattern ? (r(), i("g", _a, [
753
+ (r(!0), i(z, null, q(A.value.groups, (a, l) => (r(), i("defs", null, [
754
+ w(t.$slots, "pattern", it({ ref_for: !0 }, { seriesIndex: a.index, patternId: `pattern_${k.value}_${l}` }), void 0, !0)
755
+ ]))), 256))
756
+ ])) : h("", !0),
757
+ I("g", {
758
+ transform: `translate(${L.value.width / 2}, ${L.value.height / 2}) rotate(${P.value})`
759
+ }, [
760
+ (r(!0), i(z, null, q(A.value.groups, (a, l) => (r(), i("g", null, [
761
+ (r(), i("path", {
762
+ class: R({ "vue-ui-chord-arc": !0, "vue-ui-chord-arc-animated": e.value.useCssAnimation && !Q.value }),
763
+ key: `arc-${l}`,
764
+ d: Ye(
765
+ a.startAngle,
766
+ a.endAngle,
767
+ b.value.outer,
768
+ b.value.inner
769
+ ),
770
+ fill: m.value.colors[l],
771
+ stroke: e.value.style.chart.arcs.stroke,
772
+ "stroke-width": e.value.style.chart.arcs.strokeWidth,
773
+ "stroke-linecap": "round",
774
+ "stroke-linejoin": "round",
775
+ style: F({
776
+ opacity: et(a)
777
+ }),
778
+ onMouseenter: (s) => Et(a, l),
779
+ onMouseleave: (s) => Nt(a, l),
780
+ onClick: (s) => Ft(a, l)
781
+ }, null, 46, Ba)),
782
+ t.$slots.pattern ? (r(), i("path", {
783
+ class: R({ "vue-ui-chord-arc": !0, "vue-ui-chord-arc-animated": e.value.useCssAnimation && !Q.value }),
784
+ key: `arc-${l}`,
785
+ d: Ye(
786
+ a.startAngle,
787
+ a.endAngle,
788
+ b.value.outer,
789
+ b.value.inner
790
+ ),
791
+ fill: `url(#${a.pattern})`,
792
+ stroke: e.value.style.chart.arcs.stroke,
793
+ "stroke-width": e.value.style.chart.arcs.strokeWidth,
794
+ "stroke-linecap": "round",
795
+ "stroke-linejoin": "round",
796
+ style: F({
797
+ opacity: et(a),
798
+ pointerEvents: "none"
799
+ })
800
+ }, null, 14, Sa)) : h("", !0)
801
+ ]))), 256)),
802
+ I("g", null, [
803
+ (r(!0), i(z, null, q(C.value ? A.value.chords.filter((a) => a.source.groupId === C.value.id) : g.value ? A.value.chords.filter((a) => a.source.groupId === g.value) : A.value.chords, (a, l) => (r(), i(z, {
804
+ key: `ribbon-${a.id}`
805
+ }, [
806
+ a.source.value ? (r(), i("path", {
807
+ key: 0,
808
+ class: R({ "vue-ui-chord-ribbon": !0, "vue-ui-chord-ribbon-animated": e.value.useCssAnimation && !Q.value }),
809
+ d: se(a.source, a.target),
810
+ fill: e.value.style.chart.backgroundColor,
811
+ style: F({ opacity: e.value.style.chart.ribbons.underlayerOpacity })
812
+ }, null, 14, Oa)) : h("", !0),
813
+ a.source.value ? (r(), i("path", {
814
+ key: 1,
815
+ class: R({ "vue-ui-chord-ribbon": !0, "vue-ui-chord-ribbon-animated": e.value.useCssAnimation && !Q.value }),
816
+ d: se(a.source, a.target),
817
+ fill: m.value.colors[a.source.index],
818
+ stroke: e.value.style.chart.ribbons.stroke,
819
+ "stroke-width": e.value.style.chart.ribbons.strokeWidth,
820
+ "stroke-linecap": "round",
821
+ "stroke-linejoin": "round",
822
+ style: F({ opacity: Ke(a) }),
823
+ onMouseenter: (s) => Rt({
824
+ ...a,
825
+ path: se(a.source, a.target),
826
+ color: m.value.colors[a.source.index]
827
+ }, l),
828
+ onClick: (s) => Ut({
829
+ ...a,
830
+ color: m.value.colors[a.source.index]
831
+ }, l),
832
+ onMouseleave: (s) => zt({
833
+ ...a,
834
+ color: m.value.colors[a.source.index]
835
+ }, l)
836
+ }, null, 46, La)) : h("", !0),
837
+ a.source.value && t.$slots.pattern ? (r(), i("path", {
838
+ key: 2,
839
+ class: R({ "vue-ui-chord-ribbon": !0, "vue-ui-chord-ribbon-animated": e.value.useCssAnimation && !Q.value }),
840
+ d: se(a.source, a.target),
841
+ fill: `url(#pattern_${k.value}_${a.source.index})`,
842
+ stroke: e.value.style.chart.ribbons.stroke,
843
+ "stroke-width": e.value.style.chart.ribbons.strokeWidth,
844
+ "stroke-linecap": "round",
845
+ "stroke-linejoin": "round",
846
+ style: F({
847
+ opacity: Ke(a),
848
+ pointerEvents: "none"
849
+ })
850
+ }, null, 14, Da)) : h("", !0)
851
+ ], 64))), 128)),
852
+ p.value ? (r(), i("path", {
853
+ key: 0,
854
+ d: p.value.path,
855
+ fill: p.value.color,
856
+ stroke: e.value.style.chart.ribbons.stroke,
857
+ "stroke-width": e.value.style.chart.ribbons.strokeWidth,
858
+ "stroke-linecap": "round",
859
+ "stroke-linejoin": "round",
860
+ class: R({ "vue-ui-chord-ribbon": !0 }),
861
+ style: {
862
+ pointerEvents: "none"
863
+ }
864
+ }, null, 8, Ea)) : h("", !0),
865
+ p.value && t.$slots.pattern ? (r(), i("path", {
866
+ key: 1,
867
+ d: p.value.path,
868
+ fill: `url(#${p.value.source.pattern})`,
869
+ stroke: e.value.style.chart.ribbons.stroke,
870
+ "stroke-width": e.value.style.chart.ribbons.strokeWidth,
871
+ "stroke-linecap": "round",
872
+ "stroke-linejoin": "round",
873
+ class: R({ "vue-ui-chord-ribbon": !0 }),
874
+ style: {
875
+ pointerEvents: "none"
876
+ }
877
+ }, null, 8, Na)) : h("", !0)
878
+ ]),
879
+ (C.value || p.value || g.value) && e.value.style.chart.ribbons.labels.show ? (r(), i("g", Fa, [
880
+ (r(!0), i(z, null, q(Tt.value, (a) => (r(), i(z, {
881
+ key: a.id
882
+ }, [
883
+ I("line", {
884
+ x1: a.midBaseX,
885
+ y1: a.midBaseY,
886
+ x2: Math.cos(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 12),
887
+ y2: Math.sin(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 12),
888
+ stroke: e.value.style.chart.backgroundColor,
889
+ "stroke-width": e.value.style.chart.ribbons.labels.connector.strokeWidth * 3,
890
+ "pointer-events": "none"
891
+ }, null, 8, Ra),
892
+ I("line", {
893
+ x1: a.midBaseX,
894
+ y1: a.midBaseY,
895
+ x2: Math.cos(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 12),
896
+ y2: Math.sin(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 12),
897
+ stroke: e.value.style.chart.ribbons.labels.connector.stroke,
898
+ "stroke-width": e.value.style.chart.ribbons.labels.connector.strokeWidth,
899
+ "pointer-events": "none"
900
+ }, null, 8, za),
901
+ e.value.style.chart.ribbons.labels.marker.show ? (r(), i("circle", {
902
+ key: 0,
903
+ cx: Math.cos(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 12),
904
+ cy: Math.sin(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 12),
905
+ r: e.value.style.chart.ribbons.labels.marker.radius,
906
+ stroke: e.value.style.chart.ribbons.labels.marker.stroke,
907
+ "stroke-width": e.value.style.chart.ribbons.labels.marker.strokeWidth,
908
+ fill: a.groupColor,
909
+ "pointer-events": "none"
910
+ }, null, 8, Ua)) : h("", !0),
911
+ I("text", {
912
+ transform: `
913
+ translate(
914
+ ${Math.cos(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 24)},
915
+ ${Math.sin(a.theta - Math.PI / 2) * (b.value.outer + e.value.style.chart.ribbons.labels.offset + 24)}
916
+ ) rotate(${-P.value})
917
+ `,
918
+ fill: e.value.style.chart.ribbons.labels.useSerieColor ? a.groupColor : e.value.style.chart.ribbons.labels.color,
919
+ "text-anchor": Ot(a.theta),
920
+ "font-size": e.value.style.chart.ribbons.labels.fontSize,
921
+ "font-weight": e.value.style.chart.ribbons.labels.bold ? "bold" : "normal",
922
+ dy: ".35em",
923
+ "pointer-events": "none"
924
+ }, H(Ze(a.value)), 9, Xa)
925
+ ], 64))), 128))
926
+ ])) : h("", !0),
927
+ e.value.style.chart.arcs.labels.show ? (r(), i("g", Va, [
928
+ e.value.style.chart.arcs.labels.curved ? (r(!0), i(z, { key: 0 }, q(A.value.groups, (a, l) => (r(), i("text", {
929
+ class: "vue-ui-chord-label-curved",
930
+ key: `curved-label-${l}`,
931
+ "font-size": e.value.style.chart.arcs.labels.fontSize,
932
+ "font-weight": e.value.style.chart.arcs.labels.bold ? "bold" : "normal",
933
+ fill: e.value.style.chart.arcs.labels.adaptColorToBackground ? d(na)(m.value.colors[l]) : e.value.style.chart.arcs.labels.color
934
+ }, [
935
+ I("textPath", {
936
+ href: `#labelPath-${l}_${k.value}`,
937
+ startOffset: "50%",
938
+ "text-anchor": "middle"
939
+ }, H(m.value.labels[l]) + H(e.value.style.chart.arcs.labels.showPercentage ? d(Ie)({
940
+ p: " (",
941
+ v: isNaN(a.proportion) ? 0 : a.proportion * 100,
942
+ s: "%)",
943
+ r: e.value.style.chart.arcs.labels.roundingPercentage
944
+ }) : ""), 9, Ya)
945
+ ], 8, ja))), 128)) : !C.value && !p.value && !g.value ? (r(!0), i(z, { key: 1 }, q(A.value.groups, (a, l) => (r(), i("text", {
946
+ class: "vue-ui-chord-label-straight",
947
+ key: `label-${l}`,
948
+ transform: `
949
+ ${Lt((a.startAngle + a.endAngle) / 2)}
950
+ rotate(${-P.value})
951
+ `,
952
+ dy: ".35em",
953
+ "text-anchor": St(a) > Math.PI ? "end" : "start",
954
+ "font-size": e.value.style.chart.arcs.labels.fontSize,
955
+ "font-weight": e.value.style.chart.arcs.labels.bold ? "bold" : "normal",
956
+ fill: e.value.style.chart.arcs.labels.color,
957
+ innerHTML: d(sa)({
958
+ content: d(ra)(Yt(a, l)),
959
+ fontSize: e.value.style.chart.arcs.labels.fontSize,
960
+ fill: e.value.style.chart.arcs.labels.color,
961
+ x: 0,
962
+ y: 0
963
+ })
964
+ }, null, 8, Ga))), 128)) : h("", !0)
965
+ ])) : h("", !0)
966
+ ], 8, Ta),
967
+ w(t.$slots, "svg", { svg: { height: 600, width: 600 } }, void 0, !0)
968
+ ], 42, xa)),
969
+ t.$slots.watermark ? (r(), i("div", Wa, [
970
+ w(t.$slots, "watermark", de(he({ isPrinting: d(Fe) || d(Re) })), void 0, !0)
971
+ ])) : h("", !0),
972
+ I("div", {
973
+ id: `legend-bottom-${k.value}`
974
+ }, null, 8, qa),
975
+ Le.value ? (r(), j(qt, {
976
+ key: 5,
977
+ to: e.value.style.chart.legend.position === "top" ? `#legend-top-${k.value}` : `#legend-bottom-${k.value}`
978
+ }, [
979
+ I("div", {
980
+ ref_key: "chartLegend",
981
+ ref: Be
982
+ }, [
983
+ e.value.style.chart.legend.show ? (r(), j($a, {
984
+ key: `legend_${me.value}`,
985
+ legendSet: lt.value,
986
+ config: Vt.value,
987
+ onClickMarker: o[0] || (o[0] = ({ legend: a }) => ot(a.id))
988
+ }, xe({
989
+ item: x(({ legend: a }) => [
990
+ I("div", {
991
+ style: F({
992
+ opacity: g.value ? g.value === a.id ? 1 : 0.3 : 1
993
+ }),
994
+ onClick: (l) => a.select()
995
+ }, H(a.name), 13, Ha)
996
+ ]),
997
+ _: 2
998
+ }, [
999
+ t.$slots.pattern ? {
1000
+ name: "legend-pattern",
1001
+ fn: x(({ legend: a, index: l }) => [
1002
+ fe(ya, {
1003
+ shape: a.shape,
1004
+ radius: 30,
1005
+ stroke: "none",
1006
+ plot: { x: 30, y: 30 },
1007
+ fill: `url(#pattern_${k.value}_${l})`
1008
+ }, null, 8, ["shape", "fill"])
1009
+ ]),
1010
+ key: "0"
1011
+ } : void 0
1012
+ ]), 1032, ["legendSet", "config"])) : h("", !0),
1013
+ w(t.$slots, "legend", { legend: lt.value }, void 0, !0)
1014
+ ], 512)
1015
+ ], 8, ["to"])) : h("", !0),
1016
+ t.$slots.source ? (r(), i("div", {
1017
+ key: 6,
1018
+ ref_key: "source",
1019
+ ref: Se,
1020
+ dir: "auto"
1021
+ }, [
1022
+ w(t.$slots, "source", {}, void 0, !0)
1023
+ ], 512)) : h("", !0),
1024
+ P.value !== e.value.initialRotation ? (r(), i("div", Qa, [
1025
+ w(t.$slots, "reset-action", { reset: at }, () => [
1026
+ I("button", {
1027
+ "data-cy-reset": "",
1028
+ tabindex: "0",
1029
+ role: "button",
1030
+ class: "vue-data-ui-refresh-button",
1031
+ style: F({
1032
+ background: e.value.style.chart.backgroundColor
1033
+ }),
1034
+ onClick: at
1035
+ }, [
1036
+ fe(d(Pe), {
1037
+ name: "refresh",
1038
+ stroke: e.value.style.chart.color
1039
+ }, null, 8, ["stroke"])
1040
+ ], 4)
1041
+ ], !0)
1042
+ ])) : h("", !0),
1043
+ E.value ? (r(), j(Ht(oe.value.component), it({ key: 8 }, oe.value.props, {
1044
+ ref_key: "tableUnit",
1045
+ ref: J,
1046
+ onClose: o[3] || (o[3] = (a) => X.value.showTable = !1)
1047
+ }), xe({
1048
+ content: x(() => [
1049
+ (r(), j(d(mt), {
1050
+ key: `table_${pe.value}`,
1051
+ colNames: ve.value.colNames,
1052
+ head: ve.value.head,
1053
+ body: ve.value.body,
1054
+ config: ve.value.config,
1055
+ title: e.value.table.useDialog ? "" : oe.value.title,
1056
+ withCloseButton: !e.value.table.useDialog,
1057
+ onClose: o[2] || (o[2] = (a) => X.value.showTable = !1)
1058
+ }, {
1059
+ th: x(({ th: a }) => [
1060
+ ct(H(a.name), 1)
1061
+ ]),
1062
+ td: x(({ td: a }) => [
1063
+ I("div", Za, H(a.name ? a.name : Ze(a)), 1)
1064
+ ]),
1065
+ _: 1
1066
+ }, 8, ["colNames", "head", "body", "config", "title", "withCloseButton"]))
1067
+ ]),
1068
+ _: 2
1069
+ }, [
1070
+ e.value.table.useDialog ? {
1071
+ name: "title",
1072
+ fn: x(() => [
1073
+ ct(H(oe.value.title), 1)
1074
+ ]),
1075
+ key: "0"
1076
+ } : void 0,
1077
+ e.value.table.useDialog ? {
1078
+ name: "actions",
1079
+ fn: x(() => [
1080
+ I("button", {
1081
+ tabindex: "0",
1082
+ class: "vue-ui-user-options-button",
1083
+ onClick: o[1] || (o[1] = (a) => Ce(e.value.userOptions.callbacks.csv))
1084
+ }, [
1085
+ fe(d(Pe), {
1086
+ name: "excel",
1087
+ stroke: oe.value.props.color
1088
+ }, null, 8, ["stroke"])
1089
+ ])
1090
+ ]),
1091
+ key: "1"
1092
+ } : void 0
1093
+ ]), 1040)) : h("", !0),
1094
+ d(De) ? (r(), j(fa, { key: 9 })) : h("", !0)
1095
+ ], 46, Ca));
1096
+ }
1097
+ }, ho = /* @__PURE__ */ wa(Ja, [["__scopeId", "data-v-c55191c9"]]);
1098
+ export {
1099
+ ho as default
1100
+ };