vue-data-ui 3.0.2 → 3.0.3
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.
- package/dist/{Arrow-uNlT54JX.js → Arrow-CUUMjZed.js} +1 -1
- package/dist/{BaseDraggableDialog-CujvKo06.js → BaseDraggableDialog-DgADqZE_.js} +2 -2
- package/dist/{BaseIcon-B8CknCYk.js → BaseIcon-DLm6QTwr.js} +1 -1
- package/dist/{ColorPicker-Dmdfq2VV.js → ColorPicker-Crz_B792.js} +2 -2
- package/dist/{DataTable-osx68WLA.js → DataTable-CWzb1j8d.js} +2 -2
- package/dist/{Legend-CQsASoei.js → Legend-CevCqVZ5.js} +2 -2
- package/dist/{NonSvgPenAndPaper-BWz0WtJG.js → NonSvgPenAndPaper-DOG92bzo.js} +3 -3
- package/dist/{PackageVersion-DZGrOKw5.js → PackageVersion-n4qokxnx.js} +1 -1
- package/dist/{PenAndPaper-CdXspg5R.js → PenAndPaper-C_R9vJkU.js} +3 -3
- package/dist/{Shape-0sW2StrO.js → Shape-BHVN6hj0.js} +1 -1
- package/dist/{Slicer-52shR-Vu.js → Slicer-BBjJsLlJ.js} +2 -2
- package/dist/{SparkTooltip-Dxrruu4s.js → SparkTooltip-BHlSggBm.js} +1 -1
- package/dist/{Title-CntvKJss.js → Title-CINHji0n.js} +1 -1
- package/dist/{Tooltip-DF8e4iB9.js → Tooltip-hfdFRoLp.js} +1 -1
- package/dist/{UserOptions-DQyIO0ts.js → UserOptions-r0epwyXR.js} +2 -2
- package/dist/{dom-to-png-KC3tMd8p.js → dom-to-png-m7MwDfMh.js} +1 -1
- package/dist/{img-Cv4nScI0.js → img-CBdOMFyn.js} +1 -1
- package/dist/{index-B9Ct1B_p.js → index-DrRiscPm.js} +908 -871
- package/dist/{pdf-D0GEfQrI.js → pdf-CITAFtf8.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +23 -0
- package/dist/types/vue-data-ui.d.ts +23 -0
- package/dist/{useAutoSizeLabelsInsideViewbox-DvdDLkzw.js → useAutoSizeLabelsInsideViewbox-C0d8h29h.js} +1 -1
- package/dist/{useNestedProp-C0gKxLur.js → useNestedProp-BXhArS-K.js} +1 -1
- package/dist/{usePrinter-DcZXg1hH.js → usePrinter-CZk2ISUm.js} +2 -2
- package/dist/{vue-data-ui-DZMDT7RA.js → vue-data-ui-omyV52aJ.js} +64 -64
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-BnCv2CD_.js → vue-ui-3d-bar-ByS7XX4A.js} +6 -6
- package/dist/{vue-ui-accordion-B31QK9Hj.js → vue-ui-accordion-s_m_NJzJ.js} +3 -3
- package/dist/{vue-ui-age-pyramid-Bc4V0a3k.js → vue-ui-age-pyramid-BJRjKF9G.js} +6 -6
- package/dist/{vue-ui-annotator-D8haGQiH.js → vue-ui-annotator-BcdnqcBy.js} +2 -2
- package/dist/{vue-ui-bullet-n7Y6jYLj.js → vue-ui-bullet-D82pT7tL.js} +199 -186
- package/dist/{vue-ui-candlestick-nCI5GlX7.js → vue-ui-candlestick-ThIDj7Q5.js} +7 -7
- package/dist/{vue-ui-carousel-table-JH2NjnOk.js → vue-ui-carousel-table-BHOAO0Gj.js} +4 -4
- package/dist/{vue-ui-chestnut-CQtV9AR4.js → vue-ui-chestnut-3sjb4gzU.js} +5 -5
- package/dist/{vue-ui-chord-CGi_iSaL.js → vue-ui-chord-CfVEqNV6.js} +377 -366
- package/dist/{vue-ui-circle-pack-C8v3Okle.js → vue-ui-circle-pack-u4ABWUZI.js} +6 -6
- package/dist/{vue-ui-cursor-0DHciy1D.js → vue-ui-cursor-ByfhuSzG.js} +2 -2
- package/dist/{vue-ui-dashboard-CDHJk8sC.js → vue-ui-dashboard-CBCck-UI.js} +62 -62
- package/dist/{vue-ui-digits-Bn1P1K9u.js → vue-ui-digits-BU-8e-1s.js} +2 -2
- package/dist/{vue-ui-donut-evolution-Crn7Nnpy.js → vue-ui-donut-evolution-B4lDDX7G.js} +388 -377
- package/dist/{vue-ui-donut-GqHffshG.js → vue-ui-donut-g5x3IpMV.js} +345 -334
- package/dist/{vue-ui-dumbbell-C__nFV3V.js → vue-ui-dumbbell-BJ8qcUud.js} +354 -343
- package/dist/{vue-ui-flow-7q9o4Jxp.js → vue-ui-flow-CRwGogHq.js} +299 -288
- package/dist/{vue-ui-funnel-DjmlAdRf.js → vue-ui-funnel-DzF_UOAJ.js} +6 -6
- package/dist/{vue-ui-galaxy-Crh7xV6s.js → vue-ui-galaxy-BqunXfkx.js} +252 -241
- package/dist/{vue-ui-gauge-PjjV3JmB.js → vue-ui-gauge-DPjvYyeF.js} +7 -7
- package/dist/{vue-ui-gizmo-DREMjBvZ.js → vue-ui-gizmo-CU7HsWOV.js} +3 -3
- package/dist/{vue-ui-heatmap-D2CF8Vn8.js → vue-ui-heatmap-CFh-br8X.js} +7 -7
- package/dist/{vue-ui-history-plot-DX31nVYa.js → vue-ui-history-plot-OdhJu988.js} +283 -270
- package/dist/{vue-ui-kpi-FtnzfW7L.js → vue-ui-kpi-CVp3sMeg.js} +3 -3
- package/dist/{vue-ui-mini-loader-DaHPhzVf.js → vue-ui-mini-loader-LtGcTTh2.js} +2 -2
- package/dist/{vue-ui-molecule--4MdUCOi.js → vue-ui-molecule-DklqwI8c.js} +5 -5
- package/dist/{vue-ui-mood-radar-Ci416qv5.js → vue-ui-mood-radar-CGuHZngw.js} +264 -253
- package/dist/{vue-ui-nested-donuts-DoVSN0qE.js → vue-ui-nested-donuts-CHrryP89.js} +377 -366
- package/dist/{vue-ui-onion-ChqyoLl8.js → vue-ui-onion-n74T6frI.js} +265 -254
- package/dist/{vue-ui-parallel-coordinate-plot-BPsH_W7X.js → vue-ui-parallel-coordinate-plot-DtQi0qWp.js} +276 -265
- package/dist/{vue-ui-quadrant-CLQqKyzu.js → vue-ui-quadrant-CZn3Ab1f.js} +356 -345
- package/dist/{vue-ui-quick-chart-DogHdO42.js → vue-ui-quick-chart-CUBOj0Y6.js} +639 -628
- package/dist/{vue-ui-radar-B4rGvzKn.js → vue-ui-radar-BAazL3Qv.js} +254 -243
- package/dist/{vue-ui-rating-BvopSHNQ.js → vue-ui-rating-CPa7MotU.js} +2 -2
- package/dist/{vue-ui-relation-circle-C6GEmCiw.js → vue-ui-relation-circle-g6pCa6y9.js} +7 -7
- package/dist/{vue-ui-ridgeline-BJVJ02bA.js → vue-ui-ridgeline-C_Mpseru.js} +8 -8
- package/dist/{vue-ui-rings-BRTxWhKI.js → vue-ui-rings-grCm0xEc.js} +250 -239
- package/dist/{vue-ui-scatter-D_BP7XBR.js → vue-ui-scatter-CEr615c-.js} +383 -372
- package/dist/{vue-ui-skeleton-C_nf6VDZ.js → vue-ui-skeleton-BaqJKjqR.js} +3 -3
- package/dist/{vue-ui-smiley-DHCpzxMs.js → vue-ui-smiley-DyIfQ5KW.js} +2 -2
- package/dist/{vue-ui-spark-trend-DfM5OJIx.js → vue-ui-spark-trend-CqVF6MXT.js} +3 -3
- package/dist/{vue-ui-sparkbar-BrvOwqG_.js → vue-ui-sparkbar-DwSd_DZu.js} +3 -3
- package/dist/{vue-ui-sparkgauge-Dp2OkGrS.js → vue-ui-sparkgauge-Bm4UGamr.js} +3 -3
- package/dist/{vue-ui-sparkhistogram-K_7q57W8.js → vue-ui-sparkhistogram-DTZK4gCA.js} +4 -4
- package/dist/{vue-ui-sparkline-BiEu6kq8.js → vue-ui-sparkline-DGfIevXQ.js} +3 -3
- package/dist/{vue-ui-sparkstackbar-BNlyxt3y.js → vue-ui-sparkstackbar-RT_LpLKL.js} +3 -3
- package/dist/{vue-ui-stackbar-BKb_dgUq.js → vue-ui-stackbar-9Yxdd7ko.js} +443 -432
- package/dist/{vue-ui-strip-plot-D6dwyO-N.js → vue-ui-strip-plot--2bdwjUL.js} +7 -7
- package/dist/{vue-ui-table-B9UWta9o.js → vue-ui-table-BSNxwgTV.js} +4 -9
- package/dist/{vue-ui-table-heatmap-JkwDydPq.js → vue-ui-table-heatmap-BaK9FRE1.js} +5 -5
- package/dist/{vue-ui-table-sparkline-BOKgPT0e.js → vue-ui-table-sparkline-Dbi7H7Xb.js} +4 -4
- package/dist/{vue-ui-thermometer-Dj0CVTk3.js → vue-ui-thermometer-9EIYVN0g.js} +7 -7
- package/dist/{vue-ui-timer-B407nCRd.js → vue-ui-timer-OH8HQjpu.js} +5 -5
- package/dist/{vue-ui-tiremarks-C_betH5B.js → vue-ui-tiremarks-D6JpH-vv.js} +6 -6
- package/dist/{vue-ui-treemap-D0gScsaQ.js → vue-ui-treemap-DqEQgjj-.js} +356 -345
- package/dist/{vue-ui-vertical-bar-D3aoix_0.js → vue-ui-vertical-bar-BfnMDmGN.js} +9 -9
- package/dist/{vue-ui-waffle-hpsuszbt.js → vue-ui-waffle-BJu7n_i7.js} +306 -295
- package/dist/{vue-ui-wheel-0etwsu-o.js → vue-ui-wheel-KDWfx0os.js} +6 -6
- package/dist/{vue-ui-word-cloud-tsEprRhX.js → vue-ui-word-cloud-Dcg3uI2O.js} +6 -6
- package/dist/{vue-ui-world-BCtGvXjy.js → vue-ui-world-SYtMz1jo.js} +343 -329
- package/dist/{vue-ui-xy-canvas-B1s9twtZ.js → vue-ui-xy-canvas-BGJg2doK.js} +305 -294
- package/dist/{vue-ui-xy-BoT_c9bU.js → vue-ui-xy-qzB1oN1A.js} +1356 -1345
- package/package.json +1 -1
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { useCssVars as
|
|
2
|
-
import { u as
|
|
3
|
-
import { u as
|
|
4
|
-
import { u as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as
|
|
7
|
-
import { t as
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import { _ as
|
|
11
|
-
import
|
|
12
|
-
import { u as
|
|
13
|
-
import { _ as
|
|
14
|
-
const
|
|
1
|
+
import { useCssVars as zt, defineAsyncComponent as H, ref as d, shallowRef as et, toRefs as Xt, watch as tt, computed as M, onMounted as at, onBeforeUnmount as ot, createElementBlock as i, openBlock as r, unref as v, normalizeStyle as D, normalizeClass as F, createBlock as V, createCommentVNode as h, renderSlot as $, createElementVNode as T, createSlots as lt, withCtx as S, normalizeProps as ie, guardReactiveProps as ce, withModifiers as nt, createVNode as ke, Fragment as z, renderList as G, mergeProps as Ut, toDisplayString as Q, Teleport as Vt, createTextVNode as jt, nextTick as Yt } from "vue";
|
|
2
|
+
import { u as Gt, c as $e, t as Wt, a as qt, p as ve, b as Ht, o as Qt, f as st, g as Zt, d as Jt, e as Kt, X as ea, F as ta, i as we, a0 as aa, ab as oa, v as la, w as na, k as sa } from "./index-DrRiscPm.js";
|
|
3
|
+
import { u as ra } from "./useUserOptionState-BIvW1Kz7.js";
|
|
4
|
+
import { u as rt } from "./useNestedProp-BXhArS-K.js";
|
|
5
|
+
import { u as ua } from "./useChartAccessibility-9icAAmYg.js";
|
|
6
|
+
import { u as ia } from "./usePrinter-CZk2ISUm.js";
|
|
7
|
+
import { t as ca, u as va } from "./useResponsive-DfdjqQps.js";
|
|
8
|
+
import da from "./Legend-CevCqVZ5.js";
|
|
9
|
+
import ha from "./Title-CINHji0n.js";
|
|
10
|
+
import { _ as fa } from "./Shape-BHVN6hj0.js";
|
|
11
|
+
import ga from "./img-CBdOMFyn.js";
|
|
12
|
+
import { u as pa, B as ba } from "./useLoading-D7YHNtLX.js";
|
|
13
|
+
import { _ as ma } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
14
|
+
const ya = ["id"], ka = ["id"], $a = ["xmlns", "viewBox"], wa = ["width", "height"], Ca = { key: 1 }, Ma = ["id", "d"], xa = { key: 2 }, Aa = ["transform"], Ia = ["d", "fill", "stroke", "stroke-width", "onMouseenter", "onMouseleave", "onClick"], _a = ["d", "fill", "stroke", "stroke-width"], Pa = ["d", "fill"], Ta = ["d", "fill", "stroke", "stroke-width", "onMouseenter", "onClick", "onMouseleave"], Sa = ["d", "fill", "stroke", "stroke-width"], Ba = ["d", "fill", "stroke", "stroke-width"], La = ["d", "fill", "stroke", "stroke-width"], Oa = { key: 0 }, Ea = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], Na = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], Ra = ["cx", "cy", "r", "stroke", "stroke-width", "fill"], Da = ["transform", "fill", "text-anchor", "font-size", "font-weight"], Fa = { key: 1 }, za = ["font-size", "font-weight", "fill"], Xa = ["href"], Ua = ["transform", "text-anchor", "font-size", "font-weight", "fill", "innerHTML"], Va = {
|
|
15
15
|
key: 4,
|
|
16
16
|
class: "vue-data-ui-watermark"
|
|
17
|
-
},
|
|
18
|
-
key:
|
|
17
|
+
}, ja = ["id"], Ya = ["onClick"], Ga = {
|
|
18
|
+
key: 7,
|
|
19
19
|
"data-dom-to-png-ignore": "",
|
|
20
20
|
class: "reset-wrapper"
|
|
21
|
-
},
|
|
21
|
+
}, Wa = { style: { "text-align": "right", width: "100%" } }, qa = {
|
|
22
22
|
__name: "vue-ui-chord",
|
|
23
23
|
props: {
|
|
24
24
|
dataset: {
|
|
@@ -35,12 +35,12 @@ const ba = ["id"], ma = ["xmlns", "viewBox"], ya = ["width", "height"], ka = { k
|
|
|
35
35
|
}
|
|
36
36
|
},
|
|
37
37
|
emits: ["selectLegend", "selectGroup", "selectRibbon"],
|
|
38
|
-
setup(
|
|
39
|
-
|
|
40
|
-
"
|
|
38
|
+
setup(ut, { expose: it, emit: ct }) {
|
|
39
|
+
zt((e) => ({
|
|
40
|
+
"82435eb8": e.slicerColor
|
|
41
41
|
}));
|
|
42
|
-
const
|
|
43
|
-
...
|
|
42
|
+
const vt = H(() => import("./vue-ui-accordion-s_m_NJzJ.js")), dt = H(() => import("./BaseIcon-DLm6QTwr.js")), ht = H(() => import("./DataTable-CWzb1j8d.js")), ft = H(() => import("./PackageVersion-n4qokxnx.js")), gt = H(() => import("./PenAndPaper-C_R9vJkU.js")), pt = H(() => import("./UserOptions-r0epwyXR.js")), { vue_ui_chord: bt } = Gt(), B = ut, oe = ct, E = d(!!B.dataset && Object.hasOwn(B.dataset, "matrix")), k = d($e()), w = d(null), b = d(null), g = d(null), Ce = d(0), N = d(null), Me = d(null), xe = d(null), Ae = d(null), Ie = d(null), de = d(0), he = d(0), fe = d(0), W = d(!1), X = et(null), q = et(null), _e = d(!1), a = d(pe()), { loading: Pe, FINAL_DATASET: C, manualLoading: Z } = pa({
|
|
43
|
+
...Xt(B),
|
|
44
44
|
FINAL_CONFIG: a,
|
|
45
45
|
prepareConfig: pe,
|
|
46
46
|
skeletonDataset: {
|
|
@@ -53,7 +53,7 @@ const ba = ["id"], ma = ["xmlns", "viewBox"], ya = ["width", "height"], ka = { k
|
|
|
53
53
|
labels: [],
|
|
54
54
|
colors: ["#DBDBDB", "#C4C4C4", "#ADADAD", "#969696"]
|
|
55
55
|
},
|
|
56
|
-
skeletonConfig:
|
|
56
|
+
skeletonConfig: Wt({
|
|
57
57
|
defaultConfig: a.value,
|
|
58
58
|
userConfig: {
|
|
59
59
|
useCssAnimation: !1,
|
|
@@ -82,58 +82,58 @@ const ba = ["id"], ma = ["xmlns", "viewBox"], ya = ["width", "height"], ka = { k
|
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
84
|
})
|
|
85
|
-
}), { userOptionsVisible: ge, setUserOptionsVisibility:
|
|
86
|
-
elementId: `chord_${
|
|
85
|
+
}), { userOptionsVisible: ge, setUserOptionsVisibility: Te, keepUserOptionState: Se } = ra({ config: a.value }), { svgRef: J } = ua({ config: a.value.style.chart.title }), { isPrinting: Be, isImaging: Le, generatePdf: Oe, generateImage: Ee } = ia({
|
|
86
|
+
elementId: `chord_${k.value}`,
|
|
87
87
|
fileName: a.value.style.chart.title.text || "vue-ui-chord",
|
|
88
88
|
options: a.value.userOptions.print
|
|
89
89
|
}), K = d({
|
|
90
90
|
showTable: a.value.table.show
|
|
91
91
|
});
|
|
92
92
|
function pe() {
|
|
93
|
-
const e =
|
|
94
|
-
userConfig:
|
|
95
|
-
defaultConfig:
|
|
93
|
+
const e = rt({
|
|
94
|
+
userConfig: B.config,
|
|
95
|
+
defaultConfig: bt
|
|
96
96
|
});
|
|
97
97
|
return e.theme ? {
|
|
98
|
-
...
|
|
99
|
-
userConfig:
|
|
98
|
+
...rt({
|
|
99
|
+
userConfig: Ht.vue_ui_chord[e.theme] || B.config,
|
|
100
100
|
defaultConfig: e
|
|
101
101
|
}),
|
|
102
|
-
customPalette:
|
|
102
|
+
customPalette: qt[e.theme] || ve
|
|
103
103
|
} : e;
|
|
104
104
|
}
|
|
105
|
-
|
|
106
|
-
|
|
105
|
+
tt(() => B.config, (e) => {
|
|
106
|
+
Pe.value || (a.value = pe()), ge.value = !a.value.userOptions.showOnChartHover, be(), de.value += 1, he.value += 1, fe.value += 1, A.value = a.value.initialRotation, K.value.showTable = a.value.table.show;
|
|
107
107
|
}, { deep: !0 });
|
|
108
|
-
const
|
|
109
|
-
|
|
110
|
-
|
|
108
|
+
const Ne = M(() => a.value.debug);
|
|
109
|
+
tt(() => B.dataset, () => {
|
|
110
|
+
Re(), be(), de.value += 1, he.value += 1, fe.value += 1;
|
|
111
111
|
});
|
|
112
|
-
function
|
|
113
|
-
if (
|
|
112
|
+
function Re() {
|
|
113
|
+
if (Qt(B.dataset)) {
|
|
114
114
|
st({
|
|
115
115
|
componentName: "VueUiChord",
|
|
116
116
|
type: "dataset",
|
|
117
|
-
debug:
|
|
117
|
+
debug: Ne.value
|
|
118
118
|
}), E.value = !1, Z.value = !0;
|
|
119
119
|
return;
|
|
120
120
|
}
|
|
121
|
-
const e =
|
|
122
|
-
datasetObject:
|
|
121
|
+
const e = Zt({
|
|
122
|
+
datasetObject: B.dataset,
|
|
123
123
|
requiredAttributes: ["matrix"]
|
|
124
124
|
});
|
|
125
125
|
if (e.length) {
|
|
126
|
-
e.forEach((
|
|
126
|
+
e.forEach((s) => {
|
|
127
127
|
st({
|
|
128
128
|
componentName: "VueUiChord",
|
|
129
129
|
type: "datasetAttribute",
|
|
130
|
-
property:
|
|
131
|
-
debug:
|
|
130
|
+
property: s,
|
|
131
|
+
debug: Ne.value
|
|
132
132
|
});
|
|
133
133
|
}), E.value = !1, Z.value = !0;
|
|
134
134
|
return;
|
|
135
135
|
}
|
|
136
|
-
const o =
|
|
136
|
+
const o = B.dataset.matrix;
|
|
137
137
|
if (!Array.isArray(o) || o.length < 2) {
|
|
138
138
|
console.warn(`VueUiChord: dataset.matrix requires a minimum of 2 datapoints, for example:
|
|
139
139
|
|
|
@@ -143,7 +143,7 @@ matrix:[
|
|
|
143
143
|
]`), E.value = !1, Z.value = !0;
|
|
144
144
|
return;
|
|
145
145
|
}
|
|
146
|
-
const t = o.length, l = o.findIndex((
|
|
146
|
+
const t = o.length, l = o.findIndex((s) => !Array.isArray(s) || s.length !== t);
|
|
147
147
|
if (l !== -1) {
|
|
148
148
|
console.warn(
|
|
149
149
|
`VueUiChord - Invalid matrix: dataset.matrix at index ${l} has ${Array.isArray(o[l]) ? o[l].length : "NaN"} elements instead of the required ${t}
|
|
@@ -155,25 +155,25 @@ dataset.matrix[${l}] = [${Array.isArray(o[l]) ? o[l].toString() : "invalid"}]`
|
|
|
155
155
|
E.value = !0, Z.value = !1;
|
|
156
156
|
}
|
|
157
157
|
function be() {
|
|
158
|
-
if (
|
|
159
|
-
const e =
|
|
160
|
-
const { width: o, height: t, heightNoTitle: l, heightSource:
|
|
158
|
+
if (Re(), a.value.responsive) {
|
|
159
|
+
const e = ca(() => {
|
|
160
|
+
const { width: o, height: t, heightNoTitle: l, heightSource: s, heightTitle: n, heightLegend: u } = va({
|
|
161
161
|
chart: N.value,
|
|
162
162
|
title: a.value.style.chart.title.text ? Me.value : null,
|
|
163
163
|
legend: a.value.style.chart.legend.show ? xe.value : null,
|
|
164
164
|
source: Ae.value,
|
|
165
165
|
noTitle: Ie.value
|
|
166
|
-
}), f =
|
|
166
|
+
}), f = n + u + s + l;
|
|
167
167
|
o < t ? N.value.style.width = "100%" : (N.value.style.height = "100%", J.value.style.height = `calc(100% - ${f}px)`);
|
|
168
168
|
}, 100);
|
|
169
169
|
X.value && (q.value && X.value.unobserve(q.value), X.value.disconnect()), X.value = new ResizeObserver(e), q.value = N.value.parentNode, X.value.observe(q.value), e();
|
|
170
170
|
}
|
|
171
|
-
|
|
171
|
+
De.value = setTimeout(() => {
|
|
172
172
|
W.value = !0;
|
|
173
173
|
}, 500);
|
|
174
174
|
}
|
|
175
|
-
function
|
|
176
|
-
if (!
|
|
175
|
+
function mt() {
|
|
176
|
+
if (!C.value || !Object.hasOwn(C.value, "matrix") || C.value.matrix.length < 2) {
|
|
177
177
|
console.warn(`VueUiChord: dataset.matrix requires a minimum of 2 datapoints, for example:
|
|
178
178
|
|
|
179
179
|
matrix:[
|
|
@@ -182,117 +182,117 @@ matrix:[
|
|
|
182
182
|
]`), E.value = !1;
|
|
183
183
|
return;
|
|
184
184
|
}
|
|
185
|
-
|
|
186
|
-
e.length !==
|
|
185
|
+
C.value.matrix.forEach((e, o) => {
|
|
186
|
+
e.length !== C.value.matrix.length && (console.warn(`VueUiChord - Invalid matrix: dataset.matrix at index ${o} has ${e.length} elements instead of the required ${C.value.matrix.length}
|
|
187
187
|
|
|
188
|
-
dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should have the same length as the matrix itself (${
|
|
188
|
+
dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should have the same length as the matrix itself (${C.value.matrix.length})`), E.value = !1);
|
|
189
189
|
});
|
|
190
190
|
}
|
|
191
|
-
const
|
|
192
|
-
|
|
193
|
-
be();
|
|
191
|
+
const De = d(null);
|
|
192
|
+
at(() => {
|
|
193
|
+
_e.value = !0, be();
|
|
194
194
|
});
|
|
195
|
-
const
|
|
195
|
+
const L = d({
|
|
196
196
|
height: 600,
|
|
197
197
|
width: 600
|
|
198
|
-
}),
|
|
199
|
-
inner:
|
|
200
|
-
outer:
|
|
201
|
-
})),
|
|
202
|
-
matrix:
|
|
203
|
-
labels:
|
|
204
|
-
colors:
|
|
198
|
+
}), yt = M(() => a.value.userOptions.show && !a.value.style.chart.title.text), kt = M(() => Jt(a.value.customPalette)), p = M(() => ({
|
|
199
|
+
inner: L.value.width * 0.3 * a.value.style.chart.arcs.innerRadiusRatio,
|
|
200
|
+
outer: L.value.width * 0.34 * a.value.style.chart.arcs.outerRadiusRatio
|
|
201
|
+
})), $t = M(() => a.value.style.chart.arcs.padAngle / 100), m = M(() => ({
|
|
202
|
+
matrix: C.value.matrix ?? [[0]],
|
|
203
|
+
labels: C.value.labels ?? [""],
|
|
204
|
+
colors: C.value.colors && Array.isArray(C.value.colors) && C.value.colors.length ? C.value.colors.map((e) => Kt(e)) : C.value.matrix.map((e, o) => kt.value[o] || ve[o] || ve[o % ve.length])
|
|
205
205
|
}));
|
|
206
|
-
function
|
|
207
|
-
const t = e.length, l = p.value.inner,
|
|
208
|
-
let
|
|
206
|
+
function wt(e, o) {
|
|
207
|
+
const t = e.length, l = p.value.inner, s = new Array(t).fill(0);
|
|
208
|
+
let n = 0;
|
|
209
209
|
for (let c = 0; c < t; c += 1)
|
|
210
210
|
for (let y = 0; y < t; y += 1)
|
|
211
|
-
|
|
212
|
-
const u = (2 * Math.PI - o * t) /
|
|
213
|
-
let
|
|
211
|
+
s[c] += e[c][y], n += e[c][y];
|
|
212
|
+
const u = (2 * Math.PI - o * t) / n, f = [];
|
|
213
|
+
let I = 0;
|
|
214
214
|
for (let c = 0; c < t; c += 1) {
|
|
215
|
-
const y =
|
|
215
|
+
const y = I, P = y + s[c] * u;
|
|
216
216
|
f.push({
|
|
217
217
|
index: c,
|
|
218
|
-
pattern: `pattern_${
|
|
218
|
+
pattern: `pattern_${k.value}_${c}`,
|
|
219
219
|
startAngle: y,
|
|
220
|
-
endAngle:
|
|
220
|
+
endAngle: P,
|
|
221
221
|
name: m.value.labels[c],
|
|
222
222
|
id: $e(),
|
|
223
223
|
color: m.value.colors[c],
|
|
224
|
-
proportion:
|
|
225
|
-
}),
|
|
224
|
+
proportion: s[c] / n
|
|
225
|
+
}), I = P + o;
|
|
226
226
|
}
|
|
227
|
-
const
|
|
227
|
+
const _ = [];
|
|
228
228
|
for (let c = 0; c < t; c += 1) {
|
|
229
|
-
const y = e[c].map((
|
|
230
|
-
y.sort((
|
|
231
|
-
let
|
|
232
|
-
for (const { j:
|
|
233
|
-
const
|
|
234
|
-
|
|
229
|
+
const y = e[c].map((O, U) => ({ j: U, v: O }));
|
|
230
|
+
y.sort((O, U) => U.v - O.v);
|
|
231
|
+
let P = f[c].startAngle;
|
|
232
|
+
for (const { j: O, v: U } of y) {
|
|
233
|
+
const Y = P, ae = Y + U * u;
|
|
234
|
+
_.push({
|
|
235
235
|
index: c,
|
|
236
|
-
subIndex:
|
|
237
|
-
pattern: `pattern_${
|
|
238
|
-
startAngle:
|
|
236
|
+
subIndex: O,
|
|
237
|
+
pattern: `pattern_${k.value}_${c}`,
|
|
238
|
+
startAngle: Y,
|
|
239
239
|
endAngle: ae,
|
|
240
240
|
value: U,
|
|
241
241
|
groupName: m.value.labels[c],
|
|
242
242
|
groupId: f[c].id,
|
|
243
243
|
groupColor: m.value.colors[c],
|
|
244
|
-
midAngle: (
|
|
245
|
-
midBaseX: Math.cos((
|
|
246
|
-
midBaseY: Math.sin((
|
|
247
|
-
}),
|
|
244
|
+
midAngle: (Y + ae) / 2,
|
|
245
|
+
midBaseX: Math.cos((Y + ae) / 2 - Math.PI / 2) * l,
|
|
246
|
+
midBaseY: Math.sin((Y + ae) / 2 - Math.PI / 2) * l
|
|
247
|
+
}), P = ae;
|
|
248
248
|
}
|
|
249
249
|
}
|
|
250
250
|
const R = [];
|
|
251
|
-
for (const c of
|
|
252
|
-
const y =
|
|
253
|
-
(
|
|
251
|
+
for (const c of _) {
|
|
252
|
+
const y = _.find(
|
|
253
|
+
(P) => P.index === c.subIndex && P.subIndex === c.index
|
|
254
254
|
);
|
|
255
255
|
R.push({ source: c, target: y, id: $e() });
|
|
256
256
|
}
|
|
257
257
|
return { groups: f, chords: R };
|
|
258
258
|
}
|
|
259
|
-
const
|
|
260
|
-
const e =
|
|
261
|
-
return
|
|
259
|
+
const x = M(() => {
|
|
260
|
+
const e = wt(m.value.matrix, $t.value);
|
|
261
|
+
return mt(), e.chords.sort(
|
|
262
262
|
(o, t) => Math.max(t.source.value, t.target.value) - Math.max(o.source.value, o.target.value)
|
|
263
263
|
), e;
|
|
264
|
-
}),
|
|
264
|
+
}), Ct = M(() => {
|
|
265
265
|
const e = p.value.outer + a.value.style.chart.ribbons.labels.offset + 12, t = a.value.style.chart.ribbons.labels.fontSize * 0.6, l = [];
|
|
266
266
|
if (b.value) {
|
|
267
|
-
const
|
|
268
|
-
if (
|
|
269
|
-
const u = String(
|
|
267
|
+
const n = b.value;
|
|
268
|
+
if (n.source.value) {
|
|
269
|
+
const u = String(n.source.value);
|
|
270
270
|
l.push({
|
|
271
|
-
id:
|
|
272
|
-
theta:
|
|
271
|
+
id: n.id + "-src",
|
|
272
|
+
theta: n.source.midAngle,
|
|
273
273
|
w: u.length * t / e,
|
|
274
|
-
midBaseX:
|
|
275
|
-
midBaseY:
|
|
276
|
-
groupColor:
|
|
277
|
-
value:
|
|
274
|
+
midBaseX: n.source.midBaseX,
|
|
275
|
+
midBaseY: n.source.midBaseY,
|
|
276
|
+
groupColor: n.source.groupColor,
|
|
277
|
+
value: n.source.value
|
|
278
278
|
});
|
|
279
279
|
}
|
|
280
|
-
if (
|
|
281
|
-
const u = String(
|
|
280
|
+
if (n.target && n.target.value && n.target.value !== n.source.value) {
|
|
281
|
+
const u = String(n.target.value);
|
|
282
282
|
l.push({
|
|
283
|
-
id:
|
|
284
|
-
theta:
|
|
283
|
+
id: n.id + "-tgt",
|
|
284
|
+
theta: n.target.midAngle,
|
|
285
285
|
w: u.length * t / e,
|
|
286
|
-
midBaseX:
|
|
287
|
-
midBaseY:
|
|
288
|
-
groupColor:
|
|
289
|
-
value:
|
|
286
|
+
midBaseX: n.target.midBaseX,
|
|
287
|
+
midBaseY: n.target.midBaseY,
|
|
288
|
+
groupColor: n.target.groupColor,
|
|
289
|
+
value: n.target.value
|
|
290
290
|
});
|
|
291
291
|
}
|
|
292
292
|
return l;
|
|
293
293
|
}
|
|
294
|
-
function n
|
|
295
|
-
|
|
294
|
+
function s(n) {
|
|
295
|
+
x.value.chords.filter((u) => u.source.groupId === n && u.source.value).forEach((u) => {
|
|
296
296
|
{
|
|
297
297
|
const f = String(u.source.value);
|
|
298
298
|
l.push({
|
|
@@ -319,67 +319,67 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
319
319
|
}
|
|
320
320
|
});
|
|
321
321
|
}
|
|
322
|
-
return g.value &&
|
|
323
|
-
}),
|
|
324
|
-
const e =
|
|
322
|
+
return g.value && s(g.value), w.value && s(w.value.id), l;
|
|
323
|
+
}), Mt = M(() => {
|
|
324
|
+
const e = Ct.value.map((s) => ({ ...s })).sort((s, n) => s.theta - n.theta), o = a.value.style.chart.ribbons.labels.minSeparationDeg * Math.PI / 180;
|
|
325
325
|
let t = !0, l = 0;
|
|
326
326
|
for (; t && l++ < 10; ) {
|
|
327
327
|
t = !1;
|
|
328
328
|
for (let f = 1; f < e.length; f += 1) {
|
|
329
|
-
const
|
|
330
|
-
|
|
329
|
+
const I = e[f - 1], _ = e[f], R = I.theta + I.w + o;
|
|
330
|
+
_.theta < R && (_.theta = R, t = !0);
|
|
331
331
|
}
|
|
332
|
-
const
|
|
333
|
-
|
|
332
|
+
const s = e[0], n = e[e.length - 1], u = n.theta + n.w + o - 2 * Math.PI;
|
|
333
|
+
s.theta < u && (s.theta = u, t = !0);
|
|
334
334
|
}
|
|
335
335
|
return e;
|
|
336
336
|
});
|
|
337
|
-
function
|
|
338
|
-
const
|
|
339
|
-
return `M${u},${f} A${t},${t} 0 ${
|
|
337
|
+
function Fe(e, o, t, l) {
|
|
338
|
+
const s = e - Math.PI / 2, n = o - Math.PI / 2, u = Math.cos(s) * t, f = Math.sin(s) * t, I = Math.cos(n) * t, _ = Math.sin(n) * t, R = Math.cos(n) * l, c = Math.sin(n) * l, y = Math.cos(s) * l, P = Math.sin(s) * l, O = o - e > Math.PI ? 1 : 0;
|
|
339
|
+
return `M${u},${f} A${t},${t} 0 ${O} 1 ${I},${_} L${R},${c} A${l},${l} 0 ${O} 0 ${y},${P} Z`;
|
|
340
340
|
}
|
|
341
341
|
function le(e, o) {
|
|
342
|
-
const t = p.value.inner, l = e.startAngle - Math.PI / 2,
|
|
343
|
-
return `M${f},${
|
|
344
|
-
}
|
|
345
|
-
const Fe = C(() => x.value * Math.PI / 180);
|
|
346
|
-
function Mt(e) {
|
|
347
|
-
return (e.startAngle + e.endAngle) / 2;
|
|
342
|
+
const t = p.value.inner, l = e.startAngle - Math.PI / 2, s = e.endAngle - Math.PI / 2, n = o.startAngle - Math.PI / 2, u = o.endAngle - Math.PI / 2, f = Math.cos(l) * t, I = Math.sin(l) * t, _ = Math.cos(s) * t, R = Math.sin(s) * t, c = Math.cos(n) * t, y = Math.sin(n) * t, P = Math.cos(u) * t, O = Math.sin(u) * t, U = e.endAngle - e.startAngle > Math.PI ? 1 : 0, Y = o.endAngle - o.startAngle > Math.PI ? 1 : 0;
|
|
343
|
+
return `M${f},${I}A${t},${t} 0 ${U} 1 ${_},${R}Q0,0 ${c},${y}A${t},${t} 0 ${Y} 1 ${P},${O}Q0,0 ${f},${I}Z`;
|
|
348
344
|
}
|
|
345
|
+
const ze = M(() => A.value * Math.PI / 180);
|
|
349
346
|
function xt(e) {
|
|
350
|
-
return (
|
|
347
|
+
return (e.startAngle + e.endAngle) / 2;
|
|
351
348
|
}
|
|
352
349
|
function At(e) {
|
|
353
|
-
|
|
354
|
-
return o = (o % (2 * Math.PI) + 2 * Math.PI) % (2 * Math.PI), o > Math.PI ? "end" : "start";
|
|
350
|
+
return ((xt(e) + ze.value) % (2 * Math.PI) + 2 * Math.PI) % (2 * Math.PI);
|
|
355
351
|
}
|
|
356
352
|
function It(e) {
|
|
353
|
+
let o = e + ze.value;
|
|
354
|
+
return o = (o % (2 * Math.PI) + 2 * Math.PI) % (2 * Math.PI), o > Math.PI ? "end" : "start";
|
|
355
|
+
}
|
|
356
|
+
function _t(e) {
|
|
357
357
|
const o = e - Math.PI / 2, t = Math.cos(o) * (p.value.outer + a.value.style.chart.arcs.labels.offset + 24), l = Math.sin(o) * (p.value.outer + a.value.style.chart.arcs.labels.offset + 24);
|
|
358
358
|
return `translate(${t},${l})`;
|
|
359
359
|
}
|
|
360
|
-
function
|
|
361
|
-
const l = e - Math.PI / 2,
|
|
362
|
-
return `M${
|
|
363
|
-
}
|
|
364
|
-
const x = d(a.value.initialRotation), ee = d(!1);
|
|
365
|
-
let ze = 0, Xe = 0;
|
|
366
|
-
function Ue(e) {
|
|
367
|
-
const o = J.value.getBoundingClientRect(), t = o.left + o.width / 2, l = o.top + o.height / 2, n = e.clientX ?? e.touches[0].clientX, s = e.clientY ?? e.touches[0].clientY;
|
|
368
|
-
return Math.atan2(s - l, n - t);
|
|
360
|
+
function Pt(e, o, t) {
|
|
361
|
+
const l = e - Math.PI / 2, s = o - Math.PI / 2, n = Math.cos(l) * t, u = Math.sin(l) * t, f = Math.cos(s) * t, I = Math.sin(s) * t, _ = o - e > Math.PI ? 1 : 0;
|
|
362
|
+
return `M${n},${u} A${t},${t} 0 ${_} 1 ${f},${I}`;
|
|
369
363
|
}
|
|
364
|
+
const A = d(a.value.initialRotation), ee = d(!1);
|
|
365
|
+
let Xe = 0, Ue = 0;
|
|
370
366
|
function Ve(e) {
|
|
371
|
-
|
|
367
|
+
const o = J.value.getBoundingClientRect(), t = o.left + o.width / 2, l = o.top + o.height / 2, s = e.clientX ?? e.touches[0].clientX, n = e.clientY ?? e.touches[0].clientY;
|
|
368
|
+
return Math.atan2(n - l, s - t);
|
|
369
|
+
}
|
|
370
|
+
function je(e) {
|
|
371
|
+
!a.value.enableRotation || te.value || (e.preventDefault(), ee.value = !0, Xe = A.value, Ue = Ve(e));
|
|
372
372
|
}
|
|
373
|
-
function
|
|
373
|
+
function ne(e) {
|
|
374
374
|
if (!ee.value) return;
|
|
375
|
-
const o =
|
|
376
|
-
|
|
375
|
+
const o = Ve(e);
|
|
376
|
+
A.value = Xe + (o - Ue) * 180 / Math.PI;
|
|
377
377
|
}
|
|
378
|
-
function
|
|
378
|
+
function se() {
|
|
379
379
|
ee.value = !1;
|
|
380
380
|
}
|
|
381
|
-
function
|
|
382
|
-
return
|
|
381
|
+
function Ye(e) {
|
|
382
|
+
return sa(
|
|
383
383
|
a.value.style.chart.ribbons.labels.formatter,
|
|
384
384
|
e,
|
|
385
385
|
we({
|
|
@@ -390,90 +390,90 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
390
390
|
})
|
|
391
391
|
);
|
|
392
392
|
}
|
|
393
|
-
|
|
394
|
-
window.addEventListener("mousemove",
|
|
395
|
-
}),
|
|
396
|
-
window.removeEventListener("mousemove",
|
|
393
|
+
at(() => {
|
|
394
|
+
window.addEventListener("mousemove", ne), window.addEventListener("mouseup", se), window.addEventListener("touchmove", ne, { passive: !1 }), window.addEventListener("touchend", se);
|
|
395
|
+
}), ot(() => {
|
|
396
|
+
window.removeEventListener("mousemove", ne), window.removeEventListener("mouseup", se), window.removeEventListener("touchmove", ne), window.removeEventListener("touchend", se), clearTimeout(De.value), X.value && (q.value && X.value.unobserve(q.value), X.value.disconnect());
|
|
397
397
|
});
|
|
398
398
|
const me = d(!1);
|
|
399
|
-
function
|
|
399
|
+
function Ge(e) {
|
|
400
400
|
me.value = e, Ce.value += 1;
|
|
401
401
|
}
|
|
402
|
-
function
|
|
403
|
-
a.value.events.datapointEnter && a.value.events.datapointEnter({ datapoint: e, seriesIndex: o }), !g.value && (
|
|
402
|
+
function Tt(e, o) {
|
|
403
|
+
a.value.events.datapointEnter && a.value.events.datapointEnter({ datapoint: e, seriesIndex: o }), !g.value && (w.value = e);
|
|
404
404
|
}
|
|
405
405
|
function St(e, o) {
|
|
406
|
-
|
|
406
|
+
w.value = null, a.value.events.datapointLeave && a.value.events.datapointLeave({ datapoint: e, seriesIndex: o });
|
|
407
407
|
}
|
|
408
|
-
function
|
|
408
|
+
function Bt(e, o) {
|
|
409
409
|
oe("selectGroup", e), a.value.events.datapointClick && a.value.events.datapointClick({ datapoint: e, seriesIndex: o });
|
|
410
410
|
}
|
|
411
|
-
function
|
|
411
|
+
function Lt(e, o) {
|
|
412
412
|
a.value.events.datapointEnter && a.value.events.datapointEnter({ datapoint: e, seriesIndex: o }), !g.value && (b.value = e);
|
|
413
413
|
}
|
|
414
|
-
function
|
|
414
|
+
function Ot(e, o) {
|
|
415
415
|
b.value = null, a.value.events.datapointLeave && a.value.events.datapointLeave({ datapoint: e, seriesIndex: o });
|
|
416
416
|
}
|
|
417
|
-
function
|
|
417
|
+
function Et(e, o) {
|
|
418
418
|
oe("selectRibbon", e), a.value.events.datapointClick && a.value.events.datapointClick({ datapoint: e, seriesIndex: o });
|
|
419
419
|
}
|
|
420
|
-
function Ge(e) {
|
|
421
|
-
return !g.value && !$.value && !b.value ? 0.8 : (g.value ? g.value === e.source.groupId : $.value ? $.value.id === e.source.groupId : b.value?.id === e.id) ? 1 : 0.1;
|
|
422
|
-
}
|
|
423
420
|
function We(e) {
|
|
424
|
-
return !g.value &&
|
|
421
|
+
return !g.value && !w.value && !b.value ? 0.8 : (g.value ? g.value === e.source.groupId : w.value ? w.value.id === e.source.groupId : b.value?.id === e.id) ? 1 : 0.1;
|
|
422
|
+
}
|
|
423
|
+
function qe(e) {
|
|
424
|
+
return !g.value && !w.value && !b.value || (g.value ? g.value === e.id : w.value ? w.value.id === e.id : [b.value?.source.groupId, b.value?.target.groupId].includes(e.id)) ? 1 : 0.3;
|
|
425
425
|
}
|
|
426
426
|
const te = d(!1);
|
|
427
427
|
function ye() {
|
|
428
428
|
te.value = !te.value;
|
|
429
429
|
}
|
|
430
|
-
function
|
|
430
|
+
function He() {
|
|
431
431
|
K.value.showTable = !K.value.showTable;
|
|
432
432
|
}
|
|
433
|
-
function
|
|
434
|
-
return
|
|
433
|
+
function Nt() {
|
|
434
|
+
return x.value;
|
|
435
435
|
}
|
|
436
|
-
const
|
|
437
|
-
function
|
|
436
|
+
const j = d(null);
|
|
437
|
+
function Qe() {
|
|
438
438
|
const e = a.value.initialRotation;
|
|
439
|
-
|
|
439
|
+
j.value !== null && cancelAnimationFrame(j.value);
|
|
440
440
|
const o = () => {
|
|
441
|
-
|
|
441
|
+
A.value += (e - A.value) * 0.05, Math.abs(A.value - e) < 0.1 ? (A.value = e, j.value = null) : j.value = requestAnimationFrame(o);
|
|
442
442
|
};
|
|
443
|
-
|
|
443
|
+
j.value = requestAnimationFrame(o);
|
|
444
444
|
}
|
|
445
|
-
|
|
446
|
-
|
|
445
|
+
ot(() => {
|
|
446
|
+
j.value !== null && cancelAnimationFrame(j.value);
|
|
447
447
|
});
|
|
448
|
-
function
|
|
449
|
-
e === g.value ? (g.value = null, oe("selectLegend", null)) : (g.value = e, oe("selectLegend",
|
|
448
|
+
function Ze(e) {
|
|
449
|
+
e === g.value ? (g.value = null, oe("selectLegend", null)) : (g.value = e, oe("selectLegend", x.value.groups.find((o) => o.id === e)));
|
|
450
450
|
}
|
|
451
|
-
const
|
|
451
|
+
const Je = M(() => x.value.groups.map((e, o) => ({
|
|
452
452
|
name: e.name,
|
|
453
453
|
color: e.color,
|
|
454
454
|
shape: "circle",
|
|
455
455
|
patternIndex: o,
|
|
456
|
-
pattern: `pattern_${
|
|
456
|
+
pattern: `pattern_${k.value}_${o}`,
|
|
457
457
|
id: e.id,
|
|
458
|
-
select: () =>
|
|
458
|
+
select: () => Ze(e.id),
|
|
459
459
|
opacity: g.value ? g.value === e.id ? 1 : 0.3 : 1
|
|
460
|
-
}))),
|
|
460
|
+
}))), Rt = M(() => ({
|
|
461
461
|
cy: "chord-div-legend",
|
|
462
462
|
backgroundColor: a.value.style.chart.legend.backgroundColor,
|
|
463
463
|
color: a.value.style.chart.legend.color,
|
|
464
464
|
fontSize: a.value.style.chart.legend.fontSize,
|
|
465
465
|
paddingBottom: 12,
|
|
466
466
|
fontWeight: a.value.style.chart.legend.bold ? "bold" : ""
|
|
467
|
-
})), re =
|
|
468
|
-
const e =
|
|
467
|
+
})), re = M(() => {
|
|
468
|
+
const e = x.value.groups.map((t, l) => ({
|
|
469
469
|
name: t.name || l,
|
|
470
470
|
color: t.color
|
|
471
471
|
})), o = m.value.matrix;
|
|
472
472
|
return { head: e, body: o };
|
|
473
|
-
}), ue =
|
|
474
|
-
const e = [{ name: "", color: null }, ...re.value.head], o = re.value.body.map((
|
|
475
|
-
re.value.head[
|
|
476
|
-
...re.value.body[
|
|
473
|
+
}), ue = M(() => {
|
|
474
|
+
const e = [{ name: "", color: null }, ...re.value.head], o = re.value.body.map((s, n) => [
|
|
475
|
+
re.value.head[n],
|
|
476
|
+
...re.value.body[n]
|
|
477
477
|
]), t = {
|
|
478
478
|
th: {
|
|
479
479
|
backgroundColor: a.value.table.th.backgroundColor,
|
|
@@ -494,35 +494,35 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
494
494
|
config: t
|
|
495
495
|
};
|
|
496
496
|
});
|
|
497
|
-
function
|
|
498
|
-
|
|
499
|
-
const o = m.value.matrix.map((
|
|
500
|
-
[m.value.labels[
|
|
501
|
-
|
|
497
|
+
function Ke(e = null) {
|
|
498
|
+
Yt(() => {
|
|
499
|
+
const o = m.value.matrix.map((s, n) => [
|
|
500
|
+
[m.value.labels[n] || n],
|
|
501
|
+
s
|
|
502
502
|
]), t = [
|
|
503
503
|
[a.value.style.chart.title.text],
|
|
504
504
|
[a.value.style.chart.title.subtitle.text],
|
|
505
505
|
[
|
|
506
506
|
[""],
|
|
507
|
-
...m.value.labels.map((
|
|
507
|
+
...m.value.labels.map((s, n) => [s || n])
|
|
508
508
|
]
|
|
509
|
-
].concat(o), l =
|
|
510
|
-
e ? e(l) :
|
|
509
|
+
].concat(o), l = la(t);
|
|
510
|
+
e ? e(l) : na({ csvContent: l, title: a.value.style.chart.title.text || "vue-ui-chord" });
|
|
511
511
|
});
|
|
512
512
|
}
|
|
513
|
-
async function
|
|
513
|
+
async function Dt({ scale: e = 2 } = {}) {
|
|
514
514
|
if (!N.value) return;
|
|
515
|
-
const { width: o, height: t } = N.value.getBoundingClientRect(), l = o / t, { imageUri:
|
|
515
|
+
const { width: o, height: t } = N.value.getBoundingClientRect(), l = o / t, { imageUri: s, base64: n } = await ga({ domElement: N.value, base64: !0, img: !0, scale: e });
|
|
516
516
|
return {
|
|
517
|
-
imageUri:
|
|
518
|
-
base64:
|
|
517
|
+
imageUri: s,
|
|
518
|
+
base64: n,
|
|
519
519
|
title: a.value.style.chart.title.text,
|
|
520
520
|
width: o,
|
|
521
521
|
height: t,
|
|
522
522
|
aspectRatio: l
|
|
523
523
|
};
|
|
524
524
|
}
|
|
525
|
-
function
|
|
525
|
+
function Ft(e, o) {
|
|
526
526
|
return `${m.value.labels[o]}${a.value.style.chart.arcs.labels.showPercentage ? we({
|
|
527
527
|
p: " (",
|
|
528
528
|
v: isNaN(e.proportion) ? 0 : e.proportion * 100,
|
|
@@ -530,15 +530,15 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
530
530
|
r: a.value.style.chart.arcs.labels.roundingPercentage
|
|
531
531
|
}) : ""}`;
|
|
532
532
|
}
|
|
533
|
-
return
|
|
534
|
-
getData:
|
|
535
|
-
getImage:
|
|
536
|
-
generateCsv:
|
|
537
|
-
generateImage:
|
|
538
|
-
generatePdf:
|
|
533
|
+
return it({
|
|
534
|
+
getData: Nt,
|
|
535
|
+
getImage: Dt,
|
|
536
|
+
generateCsv: Ke,
|
|
537
|
+
generateImage: Ee,
|
|
538
|
+
generatePdf: Oe,
|
|
539
539
|
toggleAnnotator: ye,
|
|
540
|
-
toggleTable:
|
|
541
|
-
toggleFullscreen:
|
|
540
|
+
toggleTable: He,
|
|
541
|
+
toggleFullscreen: Ge
|
|
542
542
|
}), (e, o) => (r(), i("div", {
|
|
543
543
|
ref_key: "chordChart",
|
|
544
544
|
ref: N,
|
|
@@ -548,11 +548,11 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
548
548
|
"vue-data-ui-responsive": a.value.responsive
|
|
549
549
|
}),
|
|
550
550
|
style: D(`font-family:${a.value.style.fontFamily};width:100%; text-align:center;background:${a.value.style.chart.backgroundColor}`),
|
|
551
|
-
id: `chord_${
|
|
552
|
-
onMouseenter: o[2] || (o[2] = () => v(
|
|
553
|
-
onMouseleave: o[3] || (o[3] = () => v(
|
|
551
|
+
id: `chord_${k.value}`,
|
|
552
|
+
onMouseenter: o[2] || (o[2] = () => v(Te)(!0)),
|
|
553
|
+
onMouseleave: o[3] || (o[3] = () => v(Te)(!1))
|
|
554
554
|
}, [
|
|
555
|
-
a.value.userOptions.buttons.annotator && v(J) ? (r(),
|
|
555
|
+
a.value.userOptions.buttons.annotator && v(J) ? (r(), V(v(gt), {
|
|
556
556
|
key: 0,
|
|
557
557
|
color: a.value.style.chart.color,
|
|
558
558
|
backgroundColor: a.value.style.chart.backgroundColor,
|
|
@@ -560,8 +560,8 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
560
560
|
svgRef: v(J),
|
|
561
561
|
onClose: ye
|
|
562
562
|
}, null, 8, ["color", "backgroundColor", "active", "svgRef"])) : h("", !0),
|
|
563
|
-
|
|
564
|
-
|
|
563
|
+
$(e.$slots, "userConfig", {}, void 0, !0),
|
|
564
|
+
yt.value ? (r(), i("div", {
|
|
565
565
|
key: 1,
|
|
566
566
|
ref_key: "noTitle",
|
|
567
567
|
ref: Ie,
|
|
@@ -574,7 +574,7 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
574
574
|
ref: Me,
|
|
575
575
|
style: "width:100%;background:transparent;padding-bottom:24px"
|
|
576
576
|
}, [
|
|
577
|
-
(r(),
|
|
577
|
+
(r(), V(ha, {
|
|
578
578
|
key: `title_${de.value}`,
|
|
579
579
|
config: {
|
|
580
580
|
title: {
|
|
@@ -588,14 +588,17 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
588
588
|
}
|
|
589
589
|
}, null, 8, ["config"]))
|
|
590
590
|
], 512)) : h("", !0),
|
|
591
|
-
|
|
591
|
+
T("div", {
|
|
592
|
+
id: `legend-top-${k.value}`
|
|
593
|
+
}, null, 8, ka),
|
|
594
|
+
a.value.userOptions.show && E.value && (v(Se) || v(ge)) ? (r(), V(v(pt), {
|
|
592
595
|
ref: "details",
|
|
593
596
|
key: `user_option_${Ce.value}`,
|
|
594
597
|
backgroundColor: a.value.style.chart.backgroundColor,
|
|
595
598
|
color: a.value.style.chart.color,
|
|
596
|
-
isPrinting: v(
|
|
597
|
-
isImaging: v(
|
|
598
|
-
uid:
|
|
599
|
+
isPrinting: v(Be),
|
|
600
|
+
isImaging: v(Le),
|
|
601
|
+
uid: k.value,
|
|
599
602
|
hasTooltip: !1,
|
|
600
603
|
hasPdf: a.value.userOptions.buttons.pdf,
|
|
601
604
|
hasImg: a.value.userOptions.buttons.img,
|
|
@@ -611,117 +614,117 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
611
614
|
isAnnotation: te.value,
|
|
612
615
|
callbacks: a.value.userOptions.callbacks,
|
|
613
616
|
printScale: a.value.userOptions.print.scale,
|
|
614
|
-
onToggleFullscreen:
|
|
615
|
-
onGeneratePdf: v(
|
|
616
|
-
onGenerateCsv:
|
|
617
|
-
onGenerateImage: v(
|
|
618
|
-
onToggleTable:
|
|
617
|
+
onToggleFullscreen: Ge,
|
|
618
|
+
onGeneratePdf: v(Oe),
|
|
619
|
+
onGenerateCsv: Ke,
|
|
620
|
+
onGenerateImage: v(Ee),
|
|
621
|
+
onToggleTable: He,
|
|
619
622
|
onToggleAnnotator: ye,
|
|
620
623
|
style: D({
|
|
621
624
|
visibility: v(Se) ? v(ge) ? "visible" : "hidden" : "visible"
|
|
622
625
|
})
|
|
623
|
-
},
|
|
626
|
+
}, lt({ _: 2 }, [
|
|
624
627
|
e.$slots.menuIcon ? {
|
|
625
628
|
name: "menuIcon",
|
|
626
|
-
fn:
|
|
627
|
-
|
|
629
|
+
fn: S(({ isOpen: t, color: l }) => [
|
|
630
|
+
$(e.$slots, "menuIcon", ie(ce({ isOpen: t, color: l })), void 0, !0)
|
|
628
631
|
]),
|
|
629
632
|
key: "0"
|
|
630
633
|
} : void 0,
|
|
631
634
|
e.$slots.optionPdf ? {
|
|
632
635
|
name: "optionPdf",
|
|
633
|
-
fn:
|
|
634
|
-
|
|
636
|
+
fn: S(() => [
|
|
637
|
+
$(e.$slots, "optionPdf", {}, void 0, !0)
|
|
635
638
|
]),
|
|
636
639
|
key: "1"
|
|
637
640
|
} : void 0,
|
|
638
641
|
e.$slots.optionCsv ? {
|
|
639
642
|
name: "optionCsv",
|
|
640
|
-
fn:
|
|
641
|
-
|
|
643
|
+
fn: S(() => [
|
|
644
|
+
$(e.$slots, "optionCsv", {}, void 0, !0)
|
|
642
645
|
]),
|
|
643
646
|
key: "2"
|
|
644
647
|
} : void 0,
|
|
645
648
|
e.$slots.optionImg ? {
|
|
646
649
|
name: "optionImg",
|
|
647
|
-
fn:
|
|
648
|
-
|
|
650
|
+
fn: S(() => [
|
|
651
|
+
$(e.$slots, "optionImg", {}, void 0, !0)
|
|
649
652
|
]),
|
|
650
653
|
key: "3"
|
|
651
654
|
} : void 0,
|
|
652
655
|
e.$slots.optionTable ? {
|
|
653
656
|
name: "optionTable",
|
|
654
|
-
fn:
|
|
655
|
-
|
|
657
|
+
fn: S(() => [
|
|
658
|
+
$(e.$slots, "optionTable", {}, void 0, !0)
|
|
656
659
|
]),
|
|
657
660
|
key: "4"
|
|
658
661
|
} : void 0,
|
|
659
662
|
e.$slots.optionFullscreen ? {
|
|
660
663
|
name: "optionFullscreen",
|
|
661
|
-
fn:
|
|
662
|
-
|
|
664
|
+
fn: S(({ toggleFullscreen: t, isFullscreen: l }) => [
|
|
665
|
+
$(e.$slots, "optionFullscreen", ie(ce({ toggleFullscreen: t, isFullscreen: l })), void 0, !0)
|
|
663
666
|
]),
|
|
664
667
|
key: "5"
|
|
665
668
|
} : void 0,
|
|
666
669
|
e.$slots.optionAnnotator ? {
|
|
667
670
|
name: "optionAnnotator",
|
|
668
|
-
fn:
|
|
669
|
-
|
|
671
|
+
fn: S(({ toggleAnnotator: t, isAnnotator: l }) => [
|
|
672
|
+
$(e.$slots, "optionAnnotator", ie(ce({ toggleAnnotator: t, isAnnotator: l })), void 0, !0)
|
|
670
673
|
]),
|
|
671
674
|
key: "6"
|
|
672
675
|
} : void 0
|
|
673
676
|
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "chartElement", "position", "titles", "hasAnnotator", "isAnnotation", "callbacks", "printScale", "onGeneratePdf", "onGenerateImage", "style"])) : h("", !0),
|
|
674
677
|
(r(), i("svg", {
|
|
675
|
-
xmlns: v(
|
|
678
|
+
xmlns: v(ea),
|
|
676
679
|
ref_key: "svgRef",
|
|
677
680
|
ref: J,
|
|
678
|
-
viewBox: `0 0 ${
|
|
681
|
+
viewBox: `0 0 ${L.value.width} ${L.value.height}`,
|
|
679
682
|
preserveAspectRatio: "xMidYMid meet",
|
|
680
683
|
style: {
|
|
681
684
|
overflow: "visible"
|
|
682
685
|
},
|
|
683
686
|
class: F({ "vue-ui-chord-rotating": ee.value, "vue-ui-chord-idle": !ee.value }),
|
|
684
|
-
onMousedown:
|
|
685
|
-
onTouchstart:
|
|
687
|
+
onMousedown: nt(je, ["prevent"]),
|
|
688
|
+
onTouchstart: nt(je, ["prevent"])
|
|
686
689
|
}, [
|
|
687
|
-
ke(v(
|
|
690
|
+
ke(v(ft)),
|
|
688
691
|
e.$slots["chart-background"] ? (r(), i("foreignObject", {
|
|
689
692
|
key: 0,
|
|
690
693
|
x: 0,
|
|
691
694
|
y: 0,
|
|
692
|
-
width:
|
|
693
|
-
height:
|
|
695
|
+
width: L.value.width <= 0 ? 10 : L.value.width,
|
|
696
|
+
height: L.value.height <= 0 ? 10 : L.value.height,
|
|
694
697
|
style: {
|
|
695
698
|
pointerEvents: "none"
|
|
696
699
|
}
|
|
697
700
|
}, [
|
|
698
|
-
|
|
699
|
-
], 8,
|
|
700
|
-
a.value.style.chart.arcs.labels.curved ? (r(), i("defs",
|
|
701
|
-
(r(!0), i(z, null, G(
|
|
701
|
+
$(e.$slots, "chart-background", {}, void 0, !0)
|
|
702
|
+
], 8, wa)) : h("", !0),
|
|
703
|
+
a.value.style.chart.arcs.labels.curved ? (r(), i("defs", Ca, [
|
|
704
|
+
(r(!0), i(z, null, G(x.value.groups, (t, l) => (r(), i("path", {
|
|
702
705
|
key: `labelPath-${l}`,
|
|
703
|
-
id: `labelPath-${l}_${
|
|
704
|
-
d:
|
|
706
|
+
id: `labelPath-${l}_${k.value}`,
|
|
707
|
+
d: Pt(
|
|
705
708
|
t.startAngle,
|
|
706
709
|
t.endAngle,
|
|
707
710
|
(p.value.inner + p.value.outer) / 2 + a.value.style.chart.arcs.labels.offset
|
|
708
711
|
),
|
|
709
712
|
fill: "none"
|
|
710
|
-
}, null, 8,
|
|
713
|
+
}, null, 8, Ma))), 128))
|
|
711
714
|
])) : h("", !0),
|
|
712
|
-
e.$slots.pattern ? (r(), i("g",
|
|
713
|
-
(r(!0), i(z, null, G(
|
|
714
|
-
|
|
715
|
+
e.$slots.pattern ? (r(), i("g", xa, [
|
|
716
|
+
(r(!0), i(z, null, G(x.value.groups, (t, l) => (r(), i("defs", null, [
|
|
717
|
+
$(e.$slots, "pattern", Ut({ ref_for: !0 }, { seriesIndex: t.index, patternId: `pattern_${k.value}_${l}` }), void 0, !0)
|
|
715
718
|
]))), 256))
|
|
716
719
|
])) : h("", !0),
|
|
717
|
-
|
|
718
|
-
transform: `translate(${
|
|
720
|
+
T("g", {
|
|
721
|
+
transform: `translate(${L.value.width / 2}, ${L.value.height / 2}) rotate(${A.value})`
|
|
719
722
|
}, [
|
|
720
|
-
(r(!0), i(z, null, G(
|
|
723
|
+
(r(!0), i(z, null, G(x.value.groups, (t, l) => (r(), i("g", null, [
|
|
721
724
|
(r(), i("path", {
|
|
722
725
|
class: F({ "vue-ui-chord-arc": !0, "vue-ui-chord-arc-animated": a.value.useCssAnimation && !W.value }),
|
|
723
726
|
key: `arc-${l}`,
|
|
724
|
-
d:
|
|
727
|
+
d: Fe(
|
|
725
728
|
t.startAngle,
|
|
726
729
|
t.endAngle,
|
|
727
730
|
p.value.outer,
|
|
@@ -733,16 +736,16 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
733
736
|
"stroke-linecap": "round",
|
|
734
737
|
"stroke-linejoin": "round",
|
|
735
738
|
style: D({
|
|
736
|
-
opacity:
|
|
739
|
+
opacity: qe(t)
|
|
737
740
|
}),
|
|
738
|
-
onMouseenter: (
|
|
739
|
-
onMouseleave: (
|
|
740
|
-
onClick: (
|
|
741
|
-
}, null, 46,
|
|
741
|
+
onMouseenter: (s) => Tt(t, l),
|
|
742
|
+
onMouseleave: (s) => St(t, l),
|
|
743
|
+
onClick: (s) => Bt(t, l)
|
|
744
|
+
}, null, 46, Ia)),
|
|
742
745
|
e.$slots.pattern ? (r(), i("path", {
|
|
743
746
|
class: F({ "vue-ui-chord-arc": !0, "vue-ui-chord-arc-animated": a.value.useCssAnimation && !W.value }),
|
|
744
747
|
key: `arc-${l}`,
|
|
745
|
-
d:
|
|
748
|
+
d: Fe(
|
|
746
749
|
t.startAngle,
|
|
747
750
|
t.endAngle,
|
|
748
751
|
p.value.outer,
|
|
@@ -754,13 +757,13 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
754
757
|
"stroke-linecap": "round",
|
|
755
758
|
"stroke-linejoin": "round",
|
|
756
759
|
style: D({
|
|
757
|
-
opacity:
|
|
760
|
+
opacity: qe(t),
|
|
758
761
|
pointerEvents: "none"
|
|
759
762
|
})
|
|
760
|
-
}, null, 14,
|
|
763
|
+
}, null, 14, _a)) : h("", !0)
|
|
761
764
|
]))), 256)),
|
|
762
|
-
|
|
763
|
-
(r(!0), i(z, null, G(
|
|
765
|
+
T("g", null, [
|
|
766
|
+
(r(!0), i(z, null, G(w.value ? x.value.chords.filter((t) => t.source.groupId === w.value.id) : g.value ? x.value.chords.filter((t) => t.source.groupId === g.value) : x.value.chords, (t, l) => (r(), i(z, {
|
|
764
767
|
key: `ribbon-${t.id}`
|
|
765
768
|
}, [
|
|
766
769
|
t.source.value ? (r(), i("path", {
|
|
@@ -769,7 +772,7 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
769
772
|
d: le(t.source, t.target),
|
|
770
773
|
fill: a.value.style.chart.backgroundColor,
|
|
771
774
|
style: D({ opacity: a.value.style.chart.ribbons.underlayerOpacity })
|
|
772
|
-
}, null, 14,
|
|
775
|
+
}, null, 14, Pa)) : h("", !0),
|
|
773
776
|
t.source.value ? (r(), i("path", {
|
|
774
777
|
key: 1,
|
|
775
778
|
class: F({ "vue-ui-chord-ribbon": !0, "vue-ui-chord-ribbon-animated": a.value.useCssAnimation && !W.value }),
|
|
@@ -779,35 +782,35 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
779
782
|
"stroke-width": a.value.style.chart.ribbons.strokeWidth,
|
|
780
783
|
"stroke-linecap": "round",
|
|
781
784
|
"stroke-linejoin": "round",
|
|
782
|
-
style: D({ opacity:
|
|
783
|
-
onMouseenter: (
|
|
785
|
+
style: D({ opacity: We(t) }),
|
|
786
|
+
onMouseenter: (s) => Lt({
|
|
784
787
|
...t,
|
|
785
788
|
path: le(t.source, t.target),
|
|
786
789
|
color: m.value.colors[t.source.index]
|
|
787
790
|
}, l),
|
|
788
|
-
onClick: (
|
|
791
|
+
onClick: (s) => Et({
|
|
789
792
|
...t,
|
|
790
793
|
color: m.value.colors[t.source.index]
|
|
791
794
|
}, l),
|
|
792
|
-
onMouseleave: (
|
|
795
|
+
onMouseleave: (s) => Ot({
|
|
793
796
|
...t,
|
|
794
797
|
color: m.value.colors[t.source.index]
|
|
795
798
|
}, l)
|
|
796
|
-
}, null, 46,
|
|
799
|
+
}, null, 46, Ta)) : h("", !0),
|
|
797
800
|
t.source.value && e.$slots.pattern ? (r(), i("path", {
|
|
798
801
|
key: 2,
|
|
799
802
|
class: F({ "vue-ui-chord-ribbon": !0, "vue-ui-chord-ribbon-animated": a.value.useCssAnimation && !W.value }),
|
|
800
803
|
d: le(t.source, t.target),
|
|
801
|
-
fill: `url(#pattern_${
|
|
804
|
+
fill: `url(#pattern_${k.value}_${t.source.index})`,
|
|
802
805
|
stroke: a.value.style.chart.ribbons.stroke,
|
|
803
806
|
"stroke-width": a.value.style.chart.ribbons.strokeWidth,
|
|
804
807
|
"stroke-linecap": "round",
|
|
805
808
|
"stroke-linejoin": "round",
|
|
806
809
|
style: D({
|
|
807
|
-
opacity:
|
|
810
|
+
opacity: We(t),
|
|
808
811
|
pointerEvents: "none"
|
|
809
812
|
})
|
|
810
|
-
}, null, 14,
|
|
813
|
+
}, null, 14, Sa)) : h("", !0)
|
|
811
814
|
], 64))), 128)),
|
|
812
815
|
b.value ? (r(), i("path", {
|
|
813
816
|
key: 0,
|
|
@@ -821,7 +824,7 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
821
824
|
style: {
|
|
822
825
|
pointerEvents: "none"
|
|
823
826
|
}
|
|
824
|
-
}, null, 8,
|
|
827
|
+
}, null, 8, Ba)) : h("", !0),
|
|
825
828
|
b.value && e.$slots.pattern ? (r(), i("path", {
|
|
826
829
|
key: 1,
|
|
827
830
|
d: b.value.path,
|
|
@@ -834,13 +837,13 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
834
837
|
style: {
|
|
835
838
|
pointerEvents: "none"
|
|
836
839
|
}
|
|
837
|
-
}, null, 8,
|
|
840
|
+
}, null, 8, La)) : h("", !0)
|
|
838
841
|
]),
|
|
839
|
-
(
|
|
840
|
-
(r(!0), i(z, null, G(
|
|
842
|
+
(w.value || b.value || g.value) && a.value.style.chart.ribbons.labels.show ? (r(), i("g", Oa, [
|
|
843
|
+
(r(!0), i(z, null, G(Mt.value, (t) => (r(), i(z, {
|
|
841
844
|
key: t.id
|
|
842
845
|
}, [
|
|
843
|
-
|
|
846
|
+
T("line", {
|
|
844
847
|
x1: t.midBaseX,
|
|
845
848
|
y1: t.midBaseY,
|
|
846
849
|
x2: Math.cos(t.theta - Math.PI / 2) * (p.value.outer + a.value.style.chart.ribbons.labels.offset + 12),
|
|
@@ -848,8 +851,8 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
848
851
|
stroke: a.value.style.chart.backgroundColor,
|
|
849
852
|
"stroke-width": a.value.style.chart.ribbons.labels.connector.strokeWidth * 3,
|
|
850
853
|
"pointer-events": "none"
|
|
851
|
-
}, null, 8,
|
|
852
|
-
|
|
854
|
+
}, null, 8, Ea),
|
|
855
|
+
T("line", {
|
|
853
856
|
x1: t.midBaseX,
|
|
854
857
|
y1: t.midBaseY,
|
|
855
858
|
x2: Math.cos(t.theta - Math.PI / 2) * (p.value.outer + a.value.style.chart.ribbons.labels.offset + 12),
|
|
@@ -857,7 +860,7 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
857
860
|
stroke: a.value.style.chart.ribbons.labels.connector.stroke,
|
|
858
861
|
"stroke-width": a.value.style.chart.ribbons.labels.connector.strokeWidth,
|
|
859
862
|
"pointer-events": "none"
|
|
860
|
-
}, null, 8,
|
|
863
|
+
}, null, 8, Na),
|
|
861
864
|
a.value.style.chart.ribbons.labels.marker.show ? (r(), i("circle", {
|
|
862
865
|
key: 0,
|
|
863
866
|
cx: Math.cos(t.theta - Math.PI / 2) * (p.value.outer + a.value.style.chart.ribbons.labels.offset + 12),
|
|
@@ -867,33 +870,33 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
867
870
|
"stroke-width": a.value.style.chart.ribbons.labels.marker.strokeWidth,
|
|
868
871
|
fill: t.groupColor,
|
|
869
872
|
"pointer-events": "none"
|
|
870
|
-
}, null, 8,
|
|
871
|
-
|
|
873
|
+
}, null, 8, Ra)) : h("", !0),
|
|
874
|
+
T("text", {
|
|
872
875
|
transform: `
|
|
873
876
|
translate(
|
|
874
877
|
${Math.cos(t.theta - Math.PI / 2) * (p.value.outer + a.value.style.chart.ribbons.labels.offset + 24)},
|
|
875
878
|
${Math.sin(t.theta - Math.PI / 2) * (p.value.outer + a.value.style.chart.ribbons.labels.offset + 24)}
|
|
876
|
-
) rotate(${-
|
|
879
|
+
) rotate(${-A.value})
|
|
877
880
|
`,
|
|
878
881
|
fill: a.value.style.chart.ribbons.labels.useSerieColor ? t.groupColor : a.value.style.chart.ribbons.labels.color,
|
|
879
|
-
"text-anchor":
|
|
882
|
+
"text-anchor": It(t.theta),
|
|
880
883
|
"font-size": a.value.style.chart.ribbons.labels.fontSize,
|
|
881
884
|
"font-weight": a.value.style.chart.ribbons.labels.bold ? "bold" : "normal",
|
|
882
885
|
dy: ".35em",
|
|
883
886
|
"pointer-events": "none"
|
|
884
|
-
}, Q(
|
|
887
|
+
}, Q(Ye(t.value)), 9, Da)
|
|
885
888
|
], 64))), 128))
|
|
886
889
|
])) : h("", !0),
|
|
887
|
-
a.value.style.chart.arcs.labels.show ? (r(), i("g",
|
|
888
|
-
a.value.style.chart.arcs.labels.curved ? (r(!0), i(z, { key: 0 }, G(
|
|
890
|
+
a.value.style.chart.arcs.labels.show ? (r(), i("g", Fa, [
|
|
891
|
+
a.value.style.chart.arcs.labels.curved ? (r(!0), i(z, { key: 0 }, G(x.value.groups, (t, l) => (r(), i("text", {
|
|
889
892
|
class: "vue-ui-chord-label-curved",
|
|
890
893
|
key: `curved-label-${l}`,
|
|
891
894
|
"font-size": a.value.style.chart.arcs.labels.fontSize,
|
|
892
895
|
"font-weight": a.value.style.chart.arcs.labels.bold ? "bold" : "normal",
|
|
893
|
-
fill: a.value.style.chart.arcs.labels.adaptColorToBackground ? v(
|
|
896
|
+
fill: a.value.style.chart.arcs.labels.adaptColorToBackground ? v(ta)(m.value.colors[l]) : a.value.style.chart.arcs.labels.color
|
|
894
897
|
}, [
|
|
895
|
-
|
|
896
|
-
href: `#labelPath-${l}_${
|
|
898
|
+
T("textPath", {
|
|
899
|
+
href: `#labelPath-${l}_${k.value}`,
|
|
897
900
|
startOffset: "50%",
|
|
898
901
|
"text-anchor": "middle"
|
|
899
902
|
}, Q(m.value.labels[l]) + Q(a.value.style.chart.arcs.labels.showPercentage ? v(we)({
|
|
@@ -901,81 +904,89 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
901
904
|
v: isNaN(t.proportion) ? 0 : t.proportion * 100,
|
|
902
905
|
s: "%)",
|
|
903
906
|
r: a.value.style.chart.arcs.labels.roundingPercentage
|
|
904
|
-
}) : ""), 9,
|
|
905
|
-
], 8,
|
|
907
|
+
}) : ""), 9, Xa)
|
|
908
|
+
], 8, za))), 128)) : !w.value && !b.value && !g.value ? (r(!0), i(z, { key: 1 }, G(x.value.groups, (t, l) => (r(), i("text", {
|
|
906
909
|
class: "vue-ui-chord-label-straight",
|
|
907
910
|
key: `label-${l}`,
|
|
908
911
|
transform: `
|
|
909
|
-
${
|
|
910
|
-
rotate(${-
|
|
912
|
+
${_t((t.startAngle + t.endAngle) / 2)}
|
|
913
|
+
rotate(${-A.value})
|
|
911
914
|
`,
|
|
912
915
|
dy: ".35em",
|
|
913
|
-
"text-anchor":
|
|
916
|
+
"text-anchor": At(t) > Math.PI ? "end" : "start",
|
|
914
917
|
"font-size": a.value.style.chart.arcs.labels.fontSize,
|
|
915
918
|
"font-weight": a.value.style.chart.arcs.labels.bold ? "bold" : "normal",
|
|
916
919
|
fill: a.value.style.chart.arcs.labels.color,
|
|
917
|
-
innerHTML: v(
|
|
918
|
-
content: v(
|
|
920
|
+
innerHTML: v(aa)({
|
|
921
|
+
content: v(oa)(Ft(t, l)),
|
|
919
922
|
fontSize: a.value.style.chart.arcs.labels.fontSize,
|
|
920
923
|
fill: a.value.style.chart.arcs.labels.color,
|
|
921
924
|
x: 0,
|
|
922
925
|
y: 0
|
|
923
926
|
})
|
|
924
|
-
}, null, 8,
|
|
927
|
+
}, null, 8, Ua))), 128)) : h("", !0)
|
|
925
928
|
])) : h("", !0)
|
|
926
|
-
], 8,
|
|
927
|
-
|
|
928
|
-
], 42,
|
|
929
|
-
e.$slots.watermark ? (r(), i("div",
|
|
930
|
-
|
|
929
|
+
], 8, Aa),
|
|
930
|
+
$(e.$slots, "svg", { svg: { height: 600, width: 600 } }, void 0, !0)
|
|
931
|
+
], 42, $a)),
|
|
932
|
+
e.$slots.watermark ? (r(), i("div", Va, [
|
|
933
|
+
$(e.$slots, "watermark", ie(ce({ isPrinting: v(Be) || v(Le) })), void 0, !0)
|
|
931
934
|
])) : h("", !0),
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
+
T("div", {
|
|
936
|
+
id: `legend-bottom-${k.value}`
|
|
937
|
+
}, null, 8, ja),
|
|
938
|
+
_e.value ? (r(), V(Vt, {
|
|
939
|
+
key: 5,
|
|
940
|
+
to: a.value.style.chart.legend.position === "top" ? `#legend-top-${k.value}` : `#legend-bottom-${k.value}`
|
|
935
941
|
}, [
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
config: Nt.value,
|
|
940
|
-
onClickMarker: o[0] || (o[0] = ({ legend: t }) => Qe(t.id))
|
|
941
|
-
}, ot({
|
|
942
|
-
item: P(({ legend: t }) => [
|
|
943
|
-
O("div", {
|
|
944
|
-
style: D({
|
|
945
|
-
opacity: g.value ? g.value === t.id ? 1 : 0.3 : 1
|
|
946
|
-
}),
|
|
947
|
-
onClick: (l) => t.select()
|
|
948
|
-
}, Q(t.name), 13, Xa)
|
|
949
|
-
]),
|
|
950
|
-
_: 2
|
|
942
|
+
T("div", {
|
|
943
|
+
ref_key: "chartLegend",
|
|
944
|
+
ref: xe
|
|
951
945
|
}, [
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
946
|
+
a.value.style.chart.legend.show ? (r(), V(da, {
|
|
947
|
+
key: `legend_${fe.value}`,
|
|
948
|
+
legendSet: Je.value,
|
|
949
|
+
config: Rt.value,
|
|
950
|
+
onClickMarker: o[0] || (o[0] = ({ legend: t }) => Ze(t.id))
|
|
951
|
+
}, lt({
|
|
952
|
+
item: S(({ legend: t }) => [
|
|
953
|
+
T("div", {
|
|
954
|
+
style: D({
|
|
955
|
+
opacity: g.value ? g.value === t.id ? 1 : 0.3 : 1
|
|
956
|
+
}),
|
|
957
|
+
onClick: (l) => t.select()
|
|
958
|
+
}, Q(t.name), 13, Ya)
|
|
962
959
|
]),
|
|
963
|
-
|
|
964
|
-
}
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
960
|
+
_: 2
|
|
961
|
+
}, [
|
|
962
|
+
e.$slots.pattern ? {
|
|
963
|
+
name: "legend-pattern",
|
|
964
|
+
fn: S(({ legend: t, index: l }) => [
|
|
965
|
+
ke(fa, {
|
|
966
|
+
shape: t.shape,
|
|
967
|
+
radius: 30,
|
|
968
|
+
stroke: "none",
|
|
969
|
+
plot: { x: 30, y: 30 },
|
|
970
|
+
fill: `url(#pattern_${k.value}_${l})`
|
|
971
|
+
}, null, 8, ["shape", "fill"])
|
|
972
|
+
]),
|
|
973
|
+
key: "0"
|
|
974
|
+
} : void 0
|
|
975
|
+
]), 1032, ["legendSet", "config"])) : h("", !0),
|
|
976
|
+
$(e.$slots, "legend", { legend: Je.value }, void 0, !0)
|
|
977
|
+
], 512)
|
|
978
|
+
], 8, ["to"])) : h("", !0),
|
|
968
979
|
e.$slots.source ? (r(), i("div", {
|
|
969
|
-
key:
|
|
980
|
+
key: 6,
|
|
970
981
|
ref_key: "source",
|
|
971
982
|
ref: Ae,
|
|
972
983
|
dir: "auto"
|
|
973
984
|
}, [
|
|
974
|
-
|
|
985
|
+
$(e.$slots, "source", {}, void 0, !0)
|
|
975
986
|
], 512)) : h("", !0),
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
987
|
+
A.value !== a.value.initialRotation ? (r(), i("div", Ga, [
|
|
988
|
+
$(e.$slots, "reset-action", { reset: Qe }, () => [
|
|
989
|
+
T("button", {
|
|
979
990
|
"data-cy-reset": "",
|
|
980
991
|
tabindex: "0",
|
|
981
992
|
role: "button",
|
|
@@ -983,17 +994,17 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
983
994
|
style: D({
|
|
984
995
|
background: a.value.style.chart.backgroundColor
|
|
985
996
|
}),
|
|
986
|
-
onClick:
|
|
997
|
+
onClick: Qe
|
|
987
998
|
}, [
|
|
988
|
-
ke(v(
|
|
999
|
+
ke(v(dt), {
|
|
989
1000
|
name: "refresh",
|
|
990
1001
|
stroke: a.value.style.chart.color
|
|
991
1002
|
}, null, 8, ["stroke"])
|
|
992
1003
|
], 4)
|
|
993
1004
|
], !0)
|
|
994
1005
|
])) : h("", !0),
|
|
995
|
-
E.value ? (r(),
|
|
996
|
-
key:
|
|
1006
|
+
E.value ? (r(), V(v(vt), {
|
|
1007
|
+
key: 8,
|
|
997
1008
|
hideDetails: "",
|
|
998
1009
|
config: {
|
|
999
1010
|
open: K.value.showTable,
|
|
@@ -1008,8 +1019,8 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
1008
1019
|
}
|
|
1009
1020
|
}
|
|
1010
1021
|
}, {
|
|
1011
|
-
content:
|
|
1012
|
-
(r(),
|
|
1022
|
+
content: S(() => [
|
|
1023
|
+
(r(), V(v(ht), {
|
|
1013
1024
|
key: `table_${he.value}`,
|
|
1014
1025
|
colNames: ue.value.colNames,
|
|
1015
1026
|
head: ue.value.head,
|
|
@@ -1018,21 +1029,21 @@ dataset.matrix[${o}] = [${e.toString()}] has a length of ${e.length} but should
|
|
|
1018
1029
|
title: `${a.value.style.chart.title.text}${a.value.style.chart.title.subtitle.text ? ` : ${a.value.style.chart.title.subtitle.text}` : ""}`,
|
|
1019
1030
|
onClose: o[1] || (o[1] = (t) => K.value.showTable = !1)
|
|
1020
1031
|
}, {
|
|
1021
|
-
th:
|
|
1022
|
-
|
|
1032
|
+
th: S(({ th: t }) => [
|
|
1033
|
+
jt(Q(t.name), 1)
|
|
1023
1034
|
]),
|
|
1024
|
-
td:
|
|
1025
|
-
|
|
1035
|
+
td: S(({ td: t }) => [
|
|
1036
|
+
T("div", Wa, Q(t.name ? t.name : Ye(t)), 1)
|
|
1026
1037
|
]),
|
|
1027
1038
|
_: 1
|
|
1028
1039
|
}, 8, ["colNames", "head", "body", "config", "title"]))
|
|
1029
1040
|
]),
|
|
1030
1041
|
_: 1
|
|
1031
1042
|
}, 8, ["config"])) : h("", !0),
|
|
1032
|
-
v(
|
|
1033
|
-
], 46,
|
|
1043
|
+
v(Pe) ? (r(), V(ba, { key: 9 })) : h("", !0)
|
|
1044
|
+
], 46, ya));
|
|
1034
1045
|
}
|
|
1035
|
-
},
|
|
1046
|
+
}, uo = /* @__PURE__ */ ma(qa, [["__scopeId", "data-v-a189383f"]]);
|
|
1036
1047
|
export {
|
|
1037
|
-
|
|
1048
|
+
uo as default
|
|
1038
1049
|
};
|