vue-data-ui 3.0.1 → 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-DQoWnUfD.js → Arrow-CUUMjZed.js} +1 -1
- package/dist/{BaseDraggableDialog-DEw6oieL.js → BaseDraggableDialog-DgADqZE_.js} +2 -2
- package/dist/{BaseIcon-DEl03NUZ.js → BaseIcon-DLm6QTwr.js} +1 -1
- package/dist/{ColorPicker-CrivFZqC.js → ColorPicker-Crz_B792.js} +2 -2
- package/dist/{DataTable-ClgCsiJA.js → DataTable-CWzb1j8d.js} +2 -2
- package/dist/{Legend-CMvJ6X5j.js → Legend-CevCqVZ5.js} +2 -2
- package/dist/{NonSvgPenAndPaper-B2Wvbl3p.js → NonSvgPenAndPaper-DOG92bzo.js} +3 -3
- package/dist/{PackageVersion-CD5VH_Al.js → PackageVersion-n4qokxnx.js} +1 -1
- package/dist/{PenAndPaper-D3WRn-G2.js → PenAndPaper-C_R9vJkU.js} +3 -3
- package/dist/{Shape-Adi9i_-f.js → Shape-BHVN6hj0.js} +1 -1
- package/dist/{Slicer-t6e1t2iM.js → Slicer-BBjJsLlJ.js} +2 -2
- package/dist/{SparkTooltip-B8OnBSvk.js → SparkTooltip-BHlSggBm.js} +1 -1
- package/dist/{Title-xTWR-Vil.js → Title-CINHji0n.js} +1 -1
- package/dist/{Tooltip-BH3CiANh.js → Tooltip-hfdFRoLp.js} +1 -1
- package/dist/{UserOptions-CKKPgDLV.js → UserOptions-r0epwyXR.js} +2 -2
- package/dist/{dom-to-png-C4hj491O.js → dom-to-png-m7MwDfMh.js} +1 -1
- package/dist/{img-Vb4QHAHI.js → img-CBdOMFyn.js} +1 -1
- package/dist/{index-Dzc2Gi60.js → index-DrRiscPm.js} +908 -871
- package/dist/{pdf-ddpqw-dt.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-CN_Jh8Hr.js → useAutoSizeLabelsInsideViewbox-C0d8h29h.js} +1 -1
- package/dist/{useNestedProp-CjnS13nF.js → useNestedProp-BXhArS-K.js} +1 -1
- package/dist/{usePrinter-DBRh8ZvS.js → usePrinter-CZk2ISUm.js} +2 -2
- package/dist/{vue-data-ui-B7ztqj9-.js → vue-data-ui-omyV52aJ.js} +64 -64
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-DUmYPtHl.js → vue-ui-3d-bar-ByS7XX4A.js} +6 -6
- package/dist/{vue-ui-accordion-CPk8wAuj.js → vue-ui-accordion-s_m_NJzJ.js} +3 -3
- package/dist/{vue-ui-age-pyramid-Bv5HmeXj.js → vue-ui-age-pyramid-BJRjKF9G.js} +6 -6
- package/dist/{vue-ui-annotator-KXWlIhtd.js → vue-ui-annotator-BcdnqcBy.js} +2 -2
- package/dist/{vue-ui-bullet-B4N4mBk9.js → vue-ui-bullet-D82pT7tL.js} +199 -186
- package/dist/{vue-ui-candlestick-DENvPnUO.js → vue-ui-candlestick-ThIDj7Q5.js} +7 -7
- package/dist/{vue-ui-carousel-table-vC2bHBaY.js → vue-ui-carousel-table-BHOAO0Gj.js} +4 -4
- package/dist/{vue-ui-chestnut-2nS0StrY.js → vue-ui-chestnut-3sjb4gzU.js} +5 -5
- package/dist/{vue-ui-chord-CyfS6vNM.js → vue-ui-chord-CfVEqNV6.js} +377 -366
- package/dist/{vue-ui-circle-pack-C4JR-0fx.js → vue-ui-circle-pack-u4ABWUZI.js} +6 -6
- package/dist/{vue-ui-cursor-BgeSDtQh.js → vue-ui-cursor-ByfhuSzG.js} +2 -2
- package/dist/{vue-ui-dashboard-9DWUBJ-I.js → vue-ui-dashboard-CBCck-UI.js} +62 -62
- package/dist/{vue-ui-digits-BQO7IBFA.js → vue-ui-digits-BU-8e-1s.js} +2 -2
- package/dist/{vue-ui-donut-evolution-B870IrQA.js → vue-ui-donut-evolution-B4lDDX7G.js} +388 -377
- package/dist/{vue-ui-donut-C-ZJXJ74.js → vue-ui-donut-g5x3IpMV.js} +345 -334
- package/dist/{vue-ui-dumbbell-Cfs2Uotx.js → vue-ui-dumbbell-BJ8qcUud.js} +354 -343
- package/dist/{vue-ui-flow-DnaUVVAD.js → vue-ui-flow-CRwGogHq.js} +299 -288
- package/dist/{vue-ui-funnel-B9s-H5ZG.js → vue-ui-funnel-DzF_UOAJ.js} +6 -6
- package/dist/{vue-ui-galaxy-BoJOczdh.js → vue-ui-galaxy-BqunXfkx.js} +252 -241
- package/dist/{vue-ui-gauge-qjm4BqZR.js → vue-ui-gauge-DPjvYyeF.js} +7 -7
- package/dist/{vue-ui-gizmo-fn7ZaMTI.js → vue-ui-gizmo-CU7HsWOV.js} +3 -3
- package/dist/{vue-ui-heatmap-CIBDKhh8.js → vue-ui-heatmap-CFh-br8X.js} +7 -7
- package/dist/{vue-ui-history-plot-bbNxldYG.js → vue-ui-history-plot-OdhJu988.js} +283 -270
- package/dist/{vue-ui-kpi-BX-2jhLx.js → vue-ui-kpi-CVp3sMeg.js} +3 -3
- package/dist/{vue-ui-mini-loader-Bn1Bb8-J.js → vue-ui-mini-loader-LtGcTTh2.js} +2 -2
- package/dist/{vue-ui-molecule-DQ3qFtBq.js → vue-ui-molecule-DklqwI8c.js} +5 -5
- package/dist/{vue-ui-mood-radar-Cf-ehIo1.js → vue-ui-mood-radar-CGuHZngw.js} +264 -253
- package/dist/{vue-ui-nested-donuts-CWg5BEi-.js → vue-ui-nested-donuts-CHrryP89.js} +377 -366
- package/dist/{vue-ui-onion-sHgQTYfa.js → vue-ui-onion-n74T6frI.js} +265 -254
- package/dist/{vue-ui-parallel-coordinate-plot-Ki3ITp_s.js → vue-ui-parallel-coordinate-plot-DtQi0qWp.js} +276 -265
- package/dist/{vue-ui-quadrant-BIVqW7U7.js → vue-ui-quadrant-CZn3Ab1f.js} +356 -345
- package/dist/{vue-ui-quick-chart-C_hvHc1b.js → vue-ui-quick-chart-CUBOj0Y6.js} +639 -628
- package/dist/{vue-ui-radar-RZUPyPwB.js → vue-ui-radar-BAazL3Qv.js} +254 -243
- package/dist/{vue-ui-rating-BI8Vk7dO.js → vue-ui-rating-CPa7MotU.js} +2 -2
- package/dist/{vue-ui-relation-circle-TVMUEtxK.js → vue-ui-relation-circle-g6pCa6y9.js} +7 -7
- package/dist/{vue-ui-ridgeline-DQeXHQG4.js → vue-ui-ridgeline-C_Mpseru.js} +8 -8
- package/dist/{vue-ui-rings-BH81WmMS.js → vue-ui-rings-grCm0xEc.js} +250 -239
- package/dist/{vue-ui-scatter-Cy7Tz_An.js → vue-ui-scatter-CEr615c-.js} +383 -372
- package/dist/{vue-ui-skeleton-CF50qQxr.js → vue-ui-skeleton-BaqJKjqR.js} +3 -3
- package/dist/{vue-ui-smiley-CrFXEbJs.js → vue-ui-smiley-DyIfQ5KW.js} +2 -2
- package/dist/{vue-ui-spark-trend-DtHArnot.js → vue-ui-spark-trend-CqVF6MXT.js} +3 -3
- package/dist/{vue-ui-sparkbar-CIOwFFgA.js → vue-ui-sparkbar-DwSd_DZu.js} +3 -3
- package/dist/{vue-ui-sparkgauge-E0DdGotz.js → vue-ui-sparkgauge-Bm4UGamr.js} +3 -3
- package/dist/{vue-ui-sparkhistogram-Dm7WoyjY.js → vue-ui-sparkhistogram-DTZK4gCA.js} +4 -4
- package/dist/{vue-ui-sparkline-DoW6DDKT.js → vue-ui-sparkline-DGfIevXQ.js} +3 -3
- package/dist/{vue-ui-sparkstackbar-BJnPUWY4.js → vue-ui-sparkstackbar-RT_LpLKL.js} +3 -3
- package/dist/{vue-ui-stackbar-Du42smPs.js → vue-ui-stackbar-9Yxdd7ko.js} +443 -432
- package/dist/{vue-ui-strip-plot-DnenGI-d.js → vue-ui-strip-plot--2bdwjUL.js} +7 -7
- package/dist/{vue-ui-table-BQOQVlHr.js → vue-ui-table-BSNxwgTV.js} +4 -9
- package/dist/{vue-ui-table-heatmap-BzK4_gsP.js → vue-ui-table-heatmap-BaK9FRE1.js} +5 -5
- package/dist/{vue-ui-table-sparkline-B-IwcT8I.js → vue-ui-table-sparkline-Dbi7H7Xb.js} +4 -4
- package/dist/{vue-ui-thermometer-06ao_Pj5.js → vue-ui-thermometer-9EIYVN0g.js} +7 -7
- package/dist/{vue-ui-timer-CxQq4roK.js → vue-ui-timer-OH8HQjpu.js} +5 -5
- package/dist/{vue-ui-tiremarks-CuTxkByj.js → vue-ui-tiremarks-D6JpH-vv.js} +6 -6
- package/dist/{vue-ui-treemap-BgHhRpiV.js → vue-ui-treemap-DqEQgjj-.js} +356 -345
- package/dist/{vue-ui-vertical-bar-CAcsUUCo.js → vue-ui-vertical-bar-BfnMDmGN.js} +9 -9
- package/dist/{vue-ui-waffle-Ct3Upw3m.js → vue-ui-waffle-BJu7n_i7.js} +306 -295
- package/dist/{vue-ui-wheel-oz06Kt-p.js → vue-ui-wheel-KDWfx0os.js} +6 -6
- package/dist/{vue-ui-word-cloud-BRy7fg4S.js → vue-ui-word-cloud-Dcg3uI2O.js} +6 -6
- package/dist/{vue-ui-world-CTV-YfFN.js → vue-ui-world-SYtMz1jo.js} +343 -329
- package/dist/{vue-ui-xy-canvas-BZdhKUIp.js → vue-ui-xy-canvas-BGJg2doK.js} +305 -294
- package/dist/vue-ui-xy-qzB1oN1A.js +3819 -0
- package/package.json +1 -1
- package/dist/vue-ui-xy-DqCy9dpa.js +0 -3808
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { defineAsyncComponent as
|
|
2
|
-
import { u as
|
|
3
|
-
import { u as
|
|
4
|
-
import { u as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import { t as
|
|
11
|
-
import { u as
|
|
12
|
-
import { _ as
|
|
13
|
-
const
|
|
1
|
+
import { defineAsyncComponent as J, ref as v, computed as m, onMounted as Gt, toRefs as jt, watch as Ie, createElementBlock as p, openBlock as i, unref as r, normalizeStyle as D, normalizeClass as mt, createBlock as U, createCommentVNode as T, createElementVNode as V, createVNode as Le, createSlots as Ut, withCtx as $, renderSlot as C, normalizeProps as Q, guardReactiveProps as ee, Fragment as ie, renderList as ce, toDisplayString as ve, Teleport as Vt, createTextVNode as Xt, nextTick as qt } from "vue";
|
|
2
|
+
import { u as Kt, c as ze, t as Zt, o as yt, f as Jt, a as Qt, p as L, b as eo, d as to, h as x, e as oo, i as de, X as lo, F as bt, L as ao, k as Be, v as no, w as so, y as ro } from "./index-DrRiscPm.js";
|
|
3
|
+
import { u as Ct } from "./useNestedProp-BXhArS-K.js";
|
|
4
|
+
import { u as uo } from "./usePrinter-CZk2ISUm.js";
|
|
5
|
+
import { u as io } from "./useUserOptionState-BIvW1Kz7.js";
|
|
6
|
+
import { u as co } from "./useChartAccessibility-9icAAmYg.js";
|
|
7
|
+
import vo from "./Legend-CevCqVZ5.js";
|
|
8
|
+
import ho from "./Title-CINHji0n.js";
|
|
9
|
+
import fo from "./img-CBdOMFyn.js";
|
|
10
|
+
import { t as po, u as go } from "./useResponsive-DfdjqQps.js";
|
|
11
|
+
import { u as mo, B as yo } from "./useLoading-D7YHNtLX.js";
|
|
12
|
+
import { _ as bo } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
13
|
+
const Co = ["id"], ko = {
|
|
14
14
|
key: 1,
|
|
15
15
|
ref: "noTitle",
|
|
16
16
|
class: "vue-data-ui-no-title-space",
|
|
17
17
|
style: "height:36px; width: 100%;background:transparent"
|
|
18
|
-
},
|
|
18
|
+
}, wo = ["id"], $o = ["xmlns", "viewBox"], Ao = ["width", "height"], To = ["id"], xo = ["stop-color"], _o = ["stop-color"], So = ["d", "fill", "stroke", "stroke-width"], Oo = ["x", "y", "height", "width", "fill", "stroke", "stroke-width", "onMouseenter", "onMouseleave", "onClick"], No = { key: 1 }, Fo = ["x", "y", "font-size", "fill"], Eo = ["x", "y", "font-size", "fill"], Mo = {
|
|
19
19
|
key: 4,
|
|
20
20
|
class: "vue-data-ui-watermark"
|
|
21
|
-
},
|
|
21
|
+
}, Po = ["id"], Io = ["onClick"], Lo = ["innerHTML"], zo = {
|
|
22
22
|
__name: "vue-ui-flow",
|
|
23
23
|
props: {
|
|
24
24
|
config: {
|
|
@@ -34,17 +34,17 @@ const yo = ["id"], bo = {
|
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
36
|
},
|
|
37
|
-
setup(
|
|
38
|
-
const
|
|
39
|
-
|
|
40
|
-
|
|
37
|
+
setup(kt, { expose: wt }) {
|
|
38
|
+
const $t = J(() => import("./vue-ui-accordion-s_m_NJzJ.js")), At = J(() => import("./DataTable-CWzb1j8d.js")), Tt = J(() => import("./PackageVersion-n4qokxnx.js")), xt = J(() => import("./PenAndPaper-C_R9vJkU.js")), _t = J(() => import("./Tooltip-hfdFRoLp.js")), St = J(() => import("./UserOptions-r0epwyXR.js")), { vue_ui_flow: Ot } = Kt(), F = kt, W = v(ze()), z = v(null), He = v(0), Re = v(0), $e = v(!1), Ae = v(""), De = v(null), We = v(null), Ye = v(null), te = v(null), he = v(null), Ge = v(!1), je = m(() => !!F.dataset && F.dataset.length);
|
|
39
|
+
Gt(() => {
|
|
40
|
+
Ge.value = !0, Ve();
|
|
41
41
|
});
|
|
42
|
-
const
|
|
43
|
-
function
|
|
44
|
-
|
|
42
|
+
const X = v(!1);
|
|
43
|
+
function Ue(o) {
|
|
44
|
+
X.value = o, He.value += 1;
|
|
45
45
|
}
|
|
46
|
-
const e = v(Se()), { loading: Te, FINAL_DATASET:
|
|
47
|
-
...
|
|
46
|
+
const e = v(Se()), { loading: Te, FINAL_DATASET: fe, manualLoading: xe } = mo({
|
|
47
|
+
...jt(F),
|
|
48
48
|
FINAL_CONFIG: e,
|
|
49
49
|
prepareConfig: Se,
|
|
50
50
|
skeletonDataset: [
|
|
@@ -55,7 +55,7 @@ const yo = ["id"], bo = {
|
|
|
55
55
|
["F", "G", 0.5, "#AAAAAA"],
|
|
56
56
|
["G", "H", 0.25, "#AAAAAA"]
|
|
57
57
|
],
|
|
58
|
-
skeletonConfig:
|
|
58
|
+
skeletonConfig: Zt({
|
|
59
59
|
defaultConfig: e.value,
|
|
60
60
|
userConfig: {
|
|
61
61
|
userOptions: { show: !1 },
|
|
@@ -87,59 +87,59 @@ const yo = ["id"], bo = {
|
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
})
|
|
90
|
-
}),
|
|
91
|
-
function
|
|
92
|
-
if (
|
|
90
|
+
}), Nt = m(() => !!e.value.debug);
|
|
91
|
+
function Ve() {
|
|
92
|
+
if (yt(F.dataset) && (Jt({
|
|
93
93
|
componentName: "VueUiFlow",
|
|
94
94
|
type: "dataset",
|
|
95
|
-
debug:
|
|
96
|
-
}), xe.value = !0),
|
|
97
|
-
const o =
|
|
98
|
-
const { width: l, height: t } =
|
|
95
|
+
debug: Nt.value
|
|
96
|
+
}), xe.value = !0), yt(F.dataset) || (xe.value = e.value.loading), e.value.responsive) {
|
|
97
|
+
const o = po(() => {
|
|
98
|
+
const { width: l, height: t } = go({
|
|
99
99
|
chart: z.value,
|
|
100
100
|
title: e.value.style.chart.title.text ? We.value : null,
|
|
101
101
|
legend: e.value.style.chart.legend.show ? De.value : null,
|
|
102
102
|
source: Ye.value
|
|
103
103
|
});
|
|
104
104
|
requestAnimationFrame(() => {
|
|
105
|
-
|
|
105
|
+
Ze.value = l, Je.value = t;
|
|
106
106
|
});
|
|
107
107
|
});
|
|
108
|
-
|
|
108
|
+
te.value && (he.value && te.value.unobserve(he.value), te.value.disconnect()), te.value = new ResizeObserver(o), he.value = z.value.parentNode, te.value.observe(he.value);
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
|
-
const { userOptionsVisible: _e, setUserOptionsVisibility:
|
|
111
|
+
const { userOptionsVisible: _e, setUserOptionsVisibility: Xe, keepUserOptionState: qe } = io({ config: e.value }), { svgRef: Ke } = co({
|
|
112
112
|
config: e.value.style.chart.title
|
|
113
113
|
});
|
|
114
114
|
function Se() {
|
|
115
|
-
const o =
|
|
115
|
+
const o = Ct({
|
|
116
116
|
userConfig: F.config,
|
|
117
|
-
defaultConfig:
|
|
117
|
+
defaultConfig: Ot
|
|
118
118
|
});
|
|
119
119
|
let l = o;
|
|
120
120
|
return o.theme ? l = {
|
|
121
|
-
...
|
|
122
|
-
userConfig:
|
|
121
|
+
...Ct({
|
|
122
|
+
userConfig: eo.vue_ui_flow[o.theme] || F.config,
|
|
123
123
|
defaultConfig: o
|
|
124
124
|
}),
|
|
125
|
-
customPalette:
|
|
125
|
+
customPalette: Qt[o.theme] || L
|
|
126
126
|
} : l = o, l.nodeCategories = F.config.nodeCategories || {}, l.nodeCategoryColors = F.config.nodeCategoryColors || {}, l;
|
|
127
127
|
}
|
|
128
|
-
const
|
|
128
|
+
const Ze = v(e.value.style.chart.width), Je = v(e.value.style.chart.height);
|
|
129
129
|
Ie(
|
|
130
130
|
() => F.config,
|
|
131
131
|
(o) => {
|
|
132
|
-
Te.value || (e.value = Se()), _e.value = !e.value.userOptions.showOnChartHover,
|
|
132
|
+
Te.value || (e.value = Se()), _e.value = !e.value.userOptions.showOnChartHover, Ve(), Re.value += 1, M.value.showTable = e.value.table.show;
|
|
133
133
|
},
|
|
134
134
|
{ deep: !0 }
|
|
135
135
|
), Ie(() => F.dataset, (o) => {
|
|
136
136
|
Array.isArray(o) && o.length > 0 && (xe.value = !1);
|
|
137
137
|
}, { deep: !0 });
|
|
138
|
-
const { isPrinting:
|
|
139
|
-
elementId: `flow_${
|
|
138
|
+
const { isPrinting: Qe, isImaging: et, generatePdf: tt, generateImage: ot } = uo({
|
|
139
|
+
elementId: `flow_${W.value}`,
|
|
140
140
|
fileName: e.value.style.chart.title.text || "vue-ui-flow",
|
|
141
141
|
options: e.value.userOptions.print
|
|
142
|
-
}),
|
|
142
|
+
}), Ft = m(() => e.value.userOptions.show && !e.value.style.chart.title.text), pe = m(() => to(e.value.customPalette)), ge = m(() => e.value.style.chart.nodes.width), M = v({
|
|
143
143
|
showTable: e.value.table.show,
|
|
144
144
|
showTooltip: e.value.style.chart.tooltip.show
|
|
145
145
|
});
|
|
@@ -149,13 +149,13 @@ const yo = ["id"], bo = {
|
|
|
149
149
|
showTooltip: e.value.style.chart.tooltip.show
|
|
150
150
|
};
|
|
151
151
|
}, { immediate: !0 });
|
|
152
|
-
const
|
|
152
|
+
const lt = m(() => !fe.value || !fe.value.length ? [] : fe.value.map((o, l) => [
|
|
153
153
|
o[0],
|
|
154
154
|
o[1],
|
|
155
|
-
|
|
156
|
-
o[3] ?
|
|
155
|
+
x(o[2]),
|
|
156
|
+
o[3] ? oo(o[3]) : pe.value[l] || pe.value[l % pe.value.length] || L[l] || L[l % L.length]
|
|
157
157
|
]));
|
|
158
|
-
function
|
|
158
|
+
function Et(o) {
|
|
159
159
|
const l = {}, t = {};
|
|
160
160
|
function n(a, u) {
|
|
161
161
|
l[a] || (l[a] = {
|
|
@@ -168,94 +168,94 @@ const yo = ["id"], bo = {
|
|
|
168
168
|
}), l[a].level === null && (l[a].level = u), t[u] || (t[u] = []), t[u].includes(a) || t[u].push(a);
|
|
169
169
|
}
|
|
170
170
|
o.forEach(([a, u, d]) => {
|
|
171
|
-
const h = l[a]?.level ?? 0,
|
|
172
|
-
n(a, h), n(u,
|
|
171
|
+
const h = l[a]?.level ?? 0, S = h + 1;
|
|
172
|
+
n(a, h), n(u, S), l[a].children.push({ target: u, value: d }), l[a].outflow += d, l[u].inflow += d;
|
|
173
173
|
});
|
|
174
|
-
const s = new Set(o.map(([a]) => a)), w = new Set(o.map(([, a]) => a)),
|
|
175
|
-
|
|
176
|
-
|
|
174
|
+
const s = new Set(o.map(([a]) => a)), w = new Set(o.map(([, a]) => a)), K = Array.from(s).filter((a) => !w.has(a)), ne = {};
|
|
175
|
+
K.forEach((a, u) => {
|
|
176
|
+
ne[a] = pe.value[u] || L[u % L.length];
|
|
177
177
|
});
|
|
178
|
-
const
|
|
178
|
+
const se = {};
|
|
179
179
|
o.forEach(([a, u, d, h]) => {
|
|
180
|
-
h && (
|
|
180
|
+
h && (se[a] = h, se[u] = h);
|
|
181
181
|
}), Object.keys(l).forEach((a, u) => {
|
|
182
182
|
const d = e.value.nodeCategories?.[a], h = d ? e.value.nodeCategoryColors?.[d] : null;
|
|
183
|
-
l[a].color =
|
|
183
|
+
l[a].color = se[a] || h || (K.includes(a) ? ne[a] : null) || L[u % L.length];
|
|
184
184
|
}), Object.keys(l).forEach((a) => {
|
|
185
185
|
l[a].value = Math.max(l[a].inflow, l[a].outflow);
|
|
186
186
|
});
|
|
187
|
-
const
|
|
187
|
+
const Ce = oe.value, Fe = st.value.width, Z = st.value.height, I = Object.keys(t).map(Number).sort((a, u) => a - u), ke = I.length || 1, Ee = ke > 1 ? Fe / (ke - 1) : 0, A = Number(ge.value), P = Number(
|
|
188
188
|
e.value.style.chart.nodes.gapPx ?? e.value.style.chart.nodes.gap ?? 8
|
|
189
|
-
),
|
|
189
|
+
), re = Number(e.value.style.chart.nodes.minHeight || 0);
|
|
190
190
|
function c(a) {
|
|
191
191
|
const u = t[a], d = u.length;
|
|
192
192
|
if (!d) return 1 / 0;
|
|
193
|
-
const h = Math.max(0, (d - 1) * P),
|
|
194
|
-
let b = 0,
|
|
193
|
+
const h = Math.max(0, (d - 1) * P), S = Math.max(0, Z - h), B = Math.min(re, d ? S / d : 0);
|
|
194
|
+
let b = 0, O = u.map((f) => l[f].value || 0), y = O.reduce((f, N) => f + N, 0);
|
|
195
195
|
for (let f = 0; f < 12; f += 1) {
|
|
196
|
-
const
|
|
197
|
-
for (let E = 0; E <
|
|
198
|
-
const R =
|
|
199
|
-
R < 0 || R *
|
|
196
|
+
const N = y > 0 ? (S - b) / y : 0, H = [];
|
|
197
|
+
for (let E = 0; E < O.length; E += 1) {
|
|
198
|
+
const R = O[E];
|
|
199
|
+
R < 0 || R * N < B && H.push(E);
|
|
200
200
|
}
|
|
201
|
-
if (!H.length) return Math.max(0,
|
|
201
|
+
if (!H.length) return Math.max(0, N);
|
|
202
202
|
for (const E of H)
|
|
203
|
-
b += B, y -=
|
|
203
|
+
b += B, y -= O[E], O[E] = -1;
|
|
204
204
|
if (y <= 0) return 0;
|
|
205
205
|
}
|
|
206
|
-
return y > 0 ? Math.max(0, (
|
|
206
|
+
return y > 0 ? Math.max(0, (S - b) / y) : 0;
|
|
207
207
|
}
|
|
208
|
-
const g = I.map(c),
|
|
208
|
+
const g = I.map(c), G = g.length ? Math.min(...g) : 0, j = {};
|
|
209
209
|
I.forEach((a) => {
|
|
210
|
-
const u = t[a], d = u.length, h = Math.max(0, (d - 1) * P),
|
|
211
|
-
(f) => Math.max(B, (l[f].value || 0) *
|
|
212
|
-
),
|
|
213
|
-
let y = Math.max(0, (
|
|
214
|
-
u.forEach((f,
|
|
215
|
-
const H = b[
|
|
216
|
-
|
|
210
|
+
const u = t[a], d = u.length, h = Math.max(0, (d - 1) * P), S = Math.max(0, Z - h), B = Math.min(re, d ? S / d : 0), b = u.map(
|
|
211
|
+
(f) => Math.max(B, (l[f].value || 0) * G)
|
|
212
|
+
), O = b.reduce((f, N) => f + N, 0) + h;
|
|
213
|
+
let y = Math.max(0, (Z - O) / 2);
|
|
214
|
+
u.forEach((f, N) => {
|
|
215
|
+
const H = b[N], E = Ce.left + a * Ee, R = y;
|
|
216
|
+
j[f] = {
|
|
217
217
|
x: E,
|
|
218
218
|
y: R,
|
|
219
219
|
absoluteY: R,
|
|
220
220
|
height: H,
|
|
221
|
-
i:
|
|
221
|
+
i: N,
|
|
222
222
|
color: l[f].color,
|
|
223
223
|
value: l[f].value
|
|
224
|
-
}, y += H,
|
|
224
|
+
}, y += H, N < d - 1 && (y += P);
|
|
225
225
|
});
|
|
226
226
|
});
|
|
227
|
-
const
|
|
227
|
+
const ft = [], ue = Ce.top, Me = {}, Pe = {};
|
|
228
228
|
Object.keys(l).forEach((a) => {
|
|
229
|
-
Me[a] =
|
|
229
|
+
Me[a] = j[a]?.y ?? 0, Pe[a] = 0;
|
|
230
230
|
});
|
|
231
|
-
const
|
|
231
|
+
const Ht = 1e-6, Rt = 0.25;
|
|
232
232
|
return I.forEach((a) => {
|
|
233
233
|
t[a].forEach((d) => {
|
|
234
|
-
const h = l[d],
|
|
234
|
+
const h = l[d], S = j[d];
|
|
235
235
|
if (!h.children || !h.children.length) return;
|
|
236
|
-
let B =
|
|
237
|
-
h.children.forEach(({ target: b, value:
|
|
238
|
-
const y =
|
|
239
|
-
let
|
|
240
|
-
Pe[b] +=
|
|
241
|
-
const
|
|
242
|
-
(
|
|
243
|
-
const
|
|
244
|
-
|
|
236
|
+
let B = S.y;
|
|
237
|
+
h.children.forEach(({ target: b, value: O }) => {
|
|
238
|
+
const y = j[b], f = l[b], N = h.outflow > 0 ? O / h.outflow : 0, H = f.inflow > 0 ? O / f.inflow : 0, E = x(B + ue), R = x(B + N * S.height + ue), pt = Me[b];
|
|
239
|
+
let we = pt + H * y.height;
|
|
240
|
+
Pe[b] += O;
|
|
241
|
+
const Dt = f.inflow > 0 && Pe[b] >= f.inflow - Ht, gt = y.y + y.height;
|
|
242
|
+
(Dt || we > gt - Rt) && (we = gt);
|
|
243
|
+
const Wt = x(pt + ue), Yt = x(we + ue);
|
|
244
|
+
ft.push({
|
|
245
245
|
id: ze(),
|
|
246
246
|
source: d,
|
|
247
247
|
target: b,
|
|
248
|
-
path: `M ${
|
|
249
|
-
value:
|
|
248
|
+
path: `M ${x(S.x + A)} ${E} L ${x(S.x + A)} ${R} L ${x(y.x)} ${Yt} L ${x(y.x)} ${Wt} Z`,
|
|
249
|
+
value: O,
|
|
250
250
|
sourceColor: h.color,
|
|
251
251
|
targetColor: l[b].color
|
|
252
|
-
}), B = R -
|
|
252
|
+
}), B = R - ue, Me[b] = we;
|
|
253
253
|
});
|
|
254
254
|
});
|
|
255
|
-
}), { nodeCoordinates:
|
|
255
|
+
}), { nodeCoordinates: j, links: ft };
|
|
256
256
|
}
|
|
257
|
-
const
|
|
258
|
-
const o =
|
|
257
|
+
const _ = m(() => {
|
|
258
|
+
const o = Et(fe.value);
|
|
259
259
|
return {
|
|
260
260
|
nodes: Object.keys(o.nodeCoordinates).map((l, t) => ({
|
|
261
261
|
...o.nodeCoordinates[l],
|
|
@@ -263,55 +263,55 @@ const yo = ["id"], bo = {
|
|
|
263
263
|
})),
|
|
264
264
|
links: o.links
|
|
265
265
|
};
|
|
266
|
-
}),
|
|
267
|
-
width: Math.max(0,
|
|
268
|
-
height: Math.max(0,
|
|
269
|
-
})),
|
|
270
|
-
width:
|
|
271
|
-
height:
|
|
266
|
+
}), at = m(() => Ze.value), nt = m(() => Je.value), oe = m(() => e.value.style.chart.padding), st = m(() => ({
|
|
267
|
+
width: Math.max(0, at.value - 40 - oe.value.right - oe.value.left),
|
|
268
|
+
height: Math.max(0, nt.value - oe.value.top - oe.value.bottom)
|
|
269
|
+
})), le = m(() => ({
|
|
270
|
+
width: at.value,
|
|
271
|
+
height: nt.value
|
|
272
272
|
}));
|
|
273
|
-
function
|
|
273
|
+
function Mt(o) {
|
|
274
274
|
const l = {}, t = {}, n = /* @__PURE__ */ new Set();
|
|
275
|
-
return
|
|
275
|
+
return lt.value.forEach(([s, w, K]) => {
|
|
276
276
|
l[s] || (l[s] = []), t[w] || (t[w] = []), l[s].push(w), t[w].push(s);
|
|
277
277
|
}), l[o] && l[o].forEach((s) => n.add(s)), t[o] && t[o].forEach((s) => n.add(s)), Array.from(n).concat(o);
|
|
278
278
|
}
|
|
279
|
-
const k = v(null),
|
|
280
|
-
function
|
|
281
|
-
|
|
282
|
-
const t = o.name, n =
|
|
283
|
-
let s = 0, w = 0,
|
|
284
|
-
const
|
|
285
|
-
|
|
279
|
+
const k = v(null), q = v(null), ae = v(null), me = v(!1);
|
|
280
|
+
function Pt(o, l) {
|
|
281
|
+
Y.value = [], k.value = Mt(o.name), q.value = o.name;
|
|
282
|
+
const t = o.name, n = lt.value;
|
|
283
|
+
let s = 0, w = 0, K = [], ne = [];
|
|
284
|
+
const se = new Set(n.map(([c]) => c)), Ce = new Set(n.map(([, c]) => c)), Fe = Array.from(se).filter((c) => !Ce.has(c)), Z = n.filter(([c]) => Fe.includes(c)).reduce((c, [g, G, j]) => c + j, 0), I = {};
|
|
285
|
+
_.value.nodes.forEach((c) => {
|
|
286
286
|
I[c.name] = c.color;
|
|
287
|
-
}), n.forEach(([c, g,
|
|
288
|
-
g === t && (s +=
|
|
287
|
+
}), n.forEach(([c, g, G]) => {
|
|
288
|
+
g === t && (s += G, K.push({ source: c, value: G, color: I[c] })), c === t && (w += G, ne.push({ target: g, value: G, color: I[g] }));
|
|
289
289
|
});
|
|
290
|
-
const
|
|
290
|
+
const ke = Math.max(s, w), Ee = Z > 0 ? ke / Z * 100 : 0, A = {
|
|
291
291
|
name: t,
|
|
292
292
|
inflow: s,
|
|
293
293
|
outflow: w,
|
|
294
|
-
from:
|
|
295
|
-
to:
|
|
294
|
+
from: K,
|
|
295
|
+
to: ne,
|
|
296
296
|
percentOfTotal: Ee,
|
|
297
297
|
color: I[t] || "#000000"
|
|
298
298
|
};
|
|
299
|
-
e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: A, seriesIndex: l }),
|
|
299
|
+
e.value.events.datapointEnter && e.value.events.datapointEnter({ datapoint: A, seriesIndex: l }), ae.value = { datapoint: A }, $e.value = !0;
|
|
300
300
|
let P = "";
|
|
301
|
-
const
|
|
302
|
-
if (
|
|
301
|
+
const re = e.value.style.chart.tooltip.customFormat;
|
|
302
|
+
if (me.value = !1, ro(re))
|
|
303
303
|
try {
|
|
304
|
-
const c =
|
|
304
|
+
const c = re({
|
|
305
305
|
datapoint: A,
|
|
306
|
-
series:
|
|
306
|
+
series: _.value,
|
|
307
307
|
config: e.value
|
|
308
308
|
});
|
|
309
|
-
typeof c == "string" && (Ae.value = c,
|
|
309
|
+
typeof c == "string" && (Ae.value = c, me.value = !0);
|
|
310
310
|
} catch {
|
|
311
311
|
console.warn("Custom format cannot be applied.");
|
|
312
312
|
}
|
|
313
|
-
if (!
|
|
314
|
-
const c = e.value.style.chart.tooltip.showPercentage ? `<div>${
|
|
313
|
+
if (!me.value) {
|
|
314
|
+
const c = e.value.style.chart.tooltip.showPercentage ? `<div>${de({
|
|
315
315
|
p: e.value.style.chart.tooltip.translations.percentOfTotal,
|
|
316
316
|
v: A.percentOfTotal,
|
|
317
317
|
s: "%",
|
|
@@ -321,7 +321,7 @@ const yo = ["id"], bo = {
|
|
|
321
321
|
P += `<div><span style="color:${g.color}">⏹←</span> ${g.source}: ${Be(
|
|
322
322
|
e.value.style.chart.nodes.labels.formatter,
|
|
323
323
|
g.value,
|
|
324
|
-
|
|
324
|
+
de({
|
|
325
325
|
p: e.value.style.chart.nodes.labels.prefix,
|
|
326
326
|
v: g.value,
|
|
327
327
|
s: e.value.style.chart.nodes.labels.suffix,
|
|
@@ -332,7 +332,7 @@ const yo = ["id"], bo = {
|
|
|
332
332
|
P += `<div><span style="color:${g.color}">⏹→</span> ${g.target}: ${Be(
|
|
333
333
|
e.value.style.chart.nodes.labels.formatter,
|
|
334
334
|
g.value,
|
|
335
|
-
|
|
335
|
+
de({
|
|
336
336
|
p: e.value.style.chart.nodes.labels.prefix,
|
|
337
337
|
v: g.value,
|
|
338
338
|
s: e.value.style.chart.nodes.labels.suffix,
|
|
@@ -342,15 +342,15 @@ const yo = ["id"], bo = {
|
|
|
342
342
|
})), Ae.value = P;
|
|
343
343
|
}
|
|
344
344
|
}
|
|
345
|
-
function
|
|
346
|
-
const l =
|
|
347
|
-
e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: l, seriesIndex: o }), k.value = null,
|
|
345
|
+
function rt(o) {
|
|
346
|
+
const l = ae.value;
|
|
347
|
+
e.value.events.datapointLeave && e.value.events.datapointLeave({ datapoint: l, seriesIndex: o }), k.value = null, q.value = null, $e.value = !1;
|
|
348
348
|
}
|
|
349
|
-
function
|
|
350
|
-
const l =
|
|
349
|
+
function It(o) {
|
|
350
|
+
const l = ae.value;
|
|
351
351
|
e.value.events.datapointClick && e.value.events.datapointClick({ datapoint: l, seriesIndex: o });
|
|
352
352
|
}
|
|
353
|
-
const
|
|
353
|
+
const ut = m(() => _.value.links.map(
|
|
354
354
|
({ source: o, target: l, sourceColor: t, targetColor: n, value: s }) => ({
|
|
355
355
|
source: o,
|
|
356
356
|
target: l,
|
|
@@ -359,9 +359,9 @@ const yo = ["id"], bo = {
|
|
|
359
359
|
value: s
|
|
360
360
|
})
|
|
361
361
|
));
|
|
362
|
-
function
|
|
363
|
-
|
|
364
|
-
const l =
|
|
362
|
+
function it(o = null) {
|
|
363
|
+
qt(() => {
|
|
364
|
+
const l = ut.value.map((s, w) => [[s.source], [s.target], [s.value]]), t = [
|
|
365
365
|
[e.value.style.chart.title.text],
|
|
366
366
|
[e.value.style.chart.title.subtitle.text],
|
|
367
367
|
[
|
|
@@ -369,19 +369,19 @@ const yo = ["id"], bo = {
|
|
|
369
369
|
[e.value.table.columnNames.target],
|
|
370
370
|
[e.value.table.columnNames.value]
|
|
371
371
|
]
|
|
372
|
-
].concat(l), n =
|
|
373
|
-
o ? o(n) :
|
|
372
|
+
].concat(l), n = no(t);
|
|
373
|
+
o ? o(n) : so({
|
|
374
374
|
csvContent: n,
|
|
375
375
|
title: e.value.style.chart.title.text || "vue-ui-flow"
|
|
376
376
|
});
|
|
377
377
|
});
|
|
378
378
|
}
|
|
379
|
-
const
|
|
379
|
+
const ye = m(() => {
|
|
380
380
|
const o = [
|
|
381
381
|
e.value.table.columnNames.source,
|
|
382
382
|
e.value.table.columnNames.target,
|
|
383
383
|
e.value.table.columnNames.value
|
|
384
|
-
], l =
|
|
384
|
+
], l = ut.value.map((s, w) => [
|
|
385
385
|
{
|
|
386
386
|
color: s.sourceColor,
|
|
387
387
|
name: s.source
|
|
@@ -390,7 +390,7 @@ const yo = ["id"], bo = {
|
|
|
390
390
|
color: s.targetColor,
|
|
391
391
|
name: s.target
|
|
392
392
|
},
|
|
393
|
-
|
|
393
|
+
de({
|
|
394
394
|
p: e.value.style.chart.nodes.labels.prefix,
|
|
395
395
|
v: s.value,
|
|
396
396
|
s: e.value.style.chart.nodes.labels.suffix,
|
|
@@ -420,22 +420,22 @@ const yo = ["id"], bo = {
|
|
|
420
420
|
config: t
|
|
421
421
|
};
|
|
422
422
|
});
|
|
423
|
-
function
|
|
424
|
-
return
|
|
423
|
+
function Lt() {
|
|
424
|
+
return _.value;
|
|
425
425
|
}
|
|
426
|
-
function
|
|
426
|
+
function ct() {
|
|
427
427
|
M.value.showTable = !M.value.showTable;
|
|
428
428
|
}
|
|
429
|
-
const
|
|
429
|
+
const be = v(!1);
|
|
430
430
|
function Oe() {
|
|
431
|
-
|
|
431
|
+
be.value = !be.value;
|
|
432
432
|
}
|
|
433
|
-
function
|
|
433
|
+
function vt() {
|
|
434
434
|
M.value.showTooltip = !M.value.showTooltip;
|
|
435
435
|
}
|
|
436
|
-
const
|
|
436
|
+
const dt = m(() => {
|
|
437
437
|
const o = new Set(
|
|
438
|
-
|
|
438
|
+
_.value.nodes.map(
|
|
439
439
|
(l) => e.value.nodeCategories[l.name] || "__uncategorized__"
|
|
440
440
|
)
|
|
441
441
|
);
|
|
@@ -443,28 +443,28 @@ const yo = ["id"], bo = {
|
|
|
443
443
|
name: l,
|
|
444
444
|
color: e.value.nodeCategoryColors[l] || L[0],
|
|
445
445
|
shape: "square",
|
|
446
|
-
count:
|
|
446
|
+
count: _.value.nodes.filter(
|
|
447
447
|
(t) => (e.value.nodeCategories[t.name] || "__uncategorized__") === l
|
|
448
448
|
).length
|
|
449
449
|
})).map((l, t) => ({
|
|
450
450
|
...l,
|
|
451
451
|
segregate: () => Ne({ legend: l, i: t }),
|
|
452
|
-
opacity:
|
|
452
|
+
opacity: Y.value.length ? Y.value.includes(t) ? 1 : 0.5 : 1
|
|
453
453
|
}));
|
|
454
|
-
}),
|
|
455
|
-
() =>
|
|
456
|
-
),
|
|
454
|
+
}), ht = m(
|
|
455
|
+
() => dt.value.filter((o) => o.name !== "__uncategorized__")
|
|
456
|
+
), Y = v([]);
|
|
457
457
|
function Ne({ legend: o, i: l }) {
|
|
458
458
|
const t = o.name;
|
|
459
459
|
if (k.value?.every(
|
|
460
460
|
(n) => e.value.nodeCategories[n] === t
|
|
461
461
|
)) {
|
|
462
|
-
k.value = null,
|
|
462
|
+
k.value = null, q.value = null, Y.value = [];
|
|
463
463
|
return;
|
|
464
464
|
}
|
|
465
|
-
|
|
465
|
+
Y.value = [l], k.value = _.value.nodes.filter((n) => e.value.nodeCategories[n.name] === t).map((n) => n.name), q.value = null;
|
|
466
466
|
}
|
|
467
|
-
const
|
|
467
|
+
const zt = m(() => ({
|
|
468
468
|
cy: "flow-legend",
|
|
469
469
|
backgroundColor: e.value.style.chart.legend.backgroundColor,
|
|
470
470
|
color: e.value.style.chart.legend.color,
|
|
@@ -472,9 +472,9 @@ const yo = ["id"], bo = {
|
|
|
472
472
|
paddingBottom: e.value.style.chart.legend.paddingBottom,
|
|
473
473
|
fontWeight: e.value.style.chart.legend.bold ? "bold" : "normal"
|
|
474
474
|
}));
|
|
475
|
-
async function
|
|
475
|
+
async function Bt({ scale: o = 2 } = {}) {
|
|
476
476
|
if (!z.value) return;
|
|
477
|
-
const { width: l, height: t } = z.value.getBoundingClientRect(), n = l / t, { imageUri: s, base64: w } = await
|
|
477
|
+
const { width: l, height: t } = z.value.getBoundingClientRect(), n = l / t, { imageUri: s, base64: w } = await fo({ domElement: z.value, base64: !0, img: !0, scale: o });
|
|
478
478
|
return {
|
|
479
479
|
imageUri: s,
|
|
480
480
|
base64: w,
|
|
@@ -484,43 +484,43 @@ const yo = ["id"], bo = {
|
|
|
484
484
|
aspectRatio: n
|
|
485
485
|
};
|
|
486
486
|
}
|
|
487
|
-
return
|
|
488
|
-
getData:
|
|
489
|
-
getImage:
|
|
490
|
-
generateCsv:
|
|
491
|
-
generateImage:
|
|
492
|
-
generatePdf:
|
|
493
|
-
toggleTable:
|
|
487
|
+
return wt({
|
|
488
|
+
getData: Lt,
|
|
489
|
+
getImage: Bt,
|
|
490
|
+
generateCsv: it,
|
|
491
|
+
generateImage: ot,
|
|
492
|
+
generatePdf: tt,
|
|
493
|
+
toggleTable: ct,
|
|
494
494
|
toggleAnnotator: Oe,
|
|
495
|
-
toggleTooltip:
|
|
495
|
+
toggleTooltip: vt,
|
|
496
496
|
drillCategory: Ne,
|
|
497
|
-
unselectNode:
|
|
498
|
-
toggleFullscreen:
|
|
497
|
+
unselectNode: rt,
|
|
498
|
+
toggleFullscreen: Ue
|
|
499
499
|
}), (o, l) => (i(), p("div", {
|
|
500
500
|
ref_key: "flowChart",
|
|
501
501
|
ref: z,
|
|
502
|
-
class:
|
|
502
|
+
class: mt(`vue-ui-flow ${X.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
|
|
503
503
|
style: D(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;background:${e.value.style.chart.backgroundColor}`),
|
|
504
|
-
id: `flow_${
|
|
505
|
-
onMouseenter: l[2] || (l[2] = () => r(
|
|
506
|
-
onMouseleave: l[3] || (l[3] = () => r(
|
|
504
|
+
id: `flow_${W.value}`,
|
|
505
|
+
onMouseenter: l[2] || (l[2] = () => r(Xe)(!0)),
|
|
506
|
+
onMouseleave: l[3] || (l[3] = () => r(Xe)(!1))
|
|
507
507
|
}, [
|
|
508
|
-
e.value.userOptions.buttons.annotator ? (i(),
|
|
508
|
+
e.value.userOptions.buttons.annotator ? (i(), U(r(xt), {
|
|
509
509
|
key: 0,
|
|
510
|
-
svgRef: r(
|
|
510
|
+
svgRef: r(Ke),
|
|
511
511
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
512
512
|
color: e.value.style.chart.color,
|
|
513
|
-
active:
|
|
513
|
+
active: be.value,
|
|
514
514
|
onClose: Oe
|
|
515
|
-
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) :
|
|
516
|
-
|
|
515
|
+
}, null, 8, ["svgRef", "backgroundColor", "color", "active"])) : T("", !0),
|
|
516
|
+
Ft.value ? (i(), p("div", ko, null, 512)) : T("", !0),
|
|
517
517
|
e.value.style.chart.title.text ? (i(), p("div", {
|
|
518
518
|
key: 2,
|
|
519
519
|
ref_key: "chartTitle",
|
|
520
520
|
ref: We,
|
|
521
521
|
style: "width:100%;background:transparent;padding-bottom:24px"
|
|
522
522
|
}, [
|
|
523
|
-
(i(),
|
|
523
|
+
(i(), U(ho, {
|
|
524
524
|
key: `title_${Re.value}`,
|
|
525
525
|
config: {
|
|
526
526
|
title: {
|
|
@@ -533,45 +533,48 @@ const yo = ["id"], bo = {
|
|
|
533
533
|
}
|
|
534
534
|
}
|
|
535
535
|
}, null, 8, ["config"]))
|
|
536
|
-
], 512)) :
|
|
537
|
-
|
|
536
|
+
], 512)) : T("", !0),
|
|
537
|
+
V("div", {
|
|
538
|
+
id: `legend-top-${W.value}`
|
|
539
|
+
}, null, 8, wo),
|
|
540
|
+
e.value.userOptions.show && je.value && (r(qe) || r(_e)) ? (i(), U(r(St), {
|
|
538
541
|
ref: "details",
|
|
539
542
|
key: `user_option_${He.value}`,
|
|
540
543
|
backgroundColor: e.value.style.chart.backgroundColor,
|
|
541
544
|
color: e.value.style.chart.color,
|
|
542
|
-
isPrinting: r(
|
|
543
|
-
isImaging: r(
|
|
544
|
-
uid:
|
|
545
|
+
isPrinting: r(Qe),
|
|
546
|
+
isImaging: r(et),
|
|
547
|
+
uid: W.value,
|
|
545
548
|
hasPdf: e.value.userOptions.buttons.pdf,
|
|
546
549
|
hasXls: e.value.userOptions.buttons.csv,
|
|
547
550
|
hasImg: e.value.userOptions.buttons.img,
|
|
548
551
|
hasTable: e.value.userOptions.buttons.table,
|
|
549
552
|
callbacks: e.value.userOptions.callbacks,
|
|
550
553
|
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
551
|
-
isFullscreen:
|
|
554
|
+
isFullscreen: X.value,
|
|
552
555
|
titles: { ...e.value.userOptions.buttonTitles },
|
|
553
556
|
chartElement: z.value,
|
|
554
557
|
position: e.value.userOptions.position,
|
|
555
558
|
hasAnnotator: e.value.userOptions.buttons.annotator,
|
|
556
559
|
printScale: e.value.userOptions.print.scale,
|
|
557
|
-
isAnnotation:
|
|
560
|
+
isAnnotation: be.value,
|
|
558
561
|
hasTooltip: e.value.style.chart.tooltip.show && e.value.userOptions.buttons.tooltip,
|
|
559
562
|
isTooltip: M.value.showTooltip,
|
|
560
|
-
onToggleTooltip:
|
|
561
|
-
onToggleFullscreen:
|
|
562
|
-
onGeneratePdf: r(
|
|
563
|
-
onGenerateCsv:
|
|
564
|
-
onGenerateImage: r(
|
|
565
|
-
onToggleTable:
|
|
563
|
+
onToggleTooltip: vt,
|
|
564
|
+
onToggleFullscreen: Ue,
|
|
565
|
+
onGeneratePdf: r(tt),
|
|
566
|
+
onGenerateCsv: it,
|
|
567
|
+
onGenerateImage: r(ot),
|
|
568
|
+
onToggleTable: ct,
|
|
566
569
|
onToggleAnnotator: Oe,
|
|
567
570
|
style: D({
|
|
568
|
-
visibility: r(
|
|
571
|
+
visibility: r(qe) ? r(_e) ? "visible" : "hidden" : "visible"
|
|
569
572
|
})
|
|
570
|
-
},
|
|
573
|
+
}, Ut({ _: 2 }, [
|
|
571
574
|
o.$slots.menuIcon ? {
|
|
572
575
|
name: "menuIcon",
|
|
573
576
|
fn: $(({ isOpen: t, color: n }) => [
|
|
574
|
-
C(o.$slots, "menuIcon",
|
|
577
|
+
C(o.$slots, "menuIcon", Q(ee({ isOpen: t, color: n })), void 0, !0)
|
|
575
578
|
]),
|
|
576
579
|
key: "0"
|
|
577
580
|
} : void 0,
|
|
@@ -613,26 +616,26 @@ const yo = ["id"], bo = {
|
|
|
613
616
|
o.$slots.optionFullscreen ? {
|
|
614
617
|
name: "optionFullscreen",
|
|
615
618
|
fn: $(({ toggleFullscreen: t, isFullscreen: n }) => [
|
|
616
|
-
C(o.$slots, "optionFullscreen",
|
|
619
|
+
C(o.$slots, "optionFullscreen", Q(ee({ toggleFullscreen: t, isFullscreen: n })), void 0, !0)
|
|
617
620
|
]),
|
|
618
621
|
key: "6"
|
|
619
622
|
} : void 0,
|
|
620
623
|
o.$slots.optionAnnotator ? {
|
|
621
624
|
name: "optionAnnotator",
|
|
622
625
|
fn: $(({ toggleAnnotator: t, isAnnotator: n }) => [
|
|
623
|
-
C(o.$slots, "optionAnnotator",
|
|
626
|
+
C(o.$slots, "optionAnnotator", Q(ee({ toggleAnnotator: t, isAnnotator: n })), void 0, !0)
|
|
624
627
|
]),
|
|
625
628
|
key: "7"
|
|
626
629
|
} : void 0
|
|
627
|
-
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasTable", "callbacks", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "hasAnnotator", "printScale", "isAnnotation", "hasTooltip", "isTooltip", "onGeneratePdf", "onGenerateImage", "style"])) :
|
|
630
|
+
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasTable", "callbacks", "hasFullscreen", "isFullscreen", "titles", "chartElement", "position", "hasAnnotator", "printScale", "isAnnotation", "hasTooltip", "isTooltip", "onGeneratePdf", "onGenerateImage", "style"])) : T("", !0),
|
|
628
631
|
(i(), p("svg", {
|
|
629
632
|
ref_key: "svgRef",
|
|
630
|
-
ref:
|
|
631
|
-
xmlns: r(
|
|
632
|
-
viewBox: `0 0 ${
|
|
633
|
-
class:
|
|
634
|
-
"vue-data-ui-fullscreen--on":
|
|
635
|
-
"vue-data-ui-fulscreen--off": !
|
|
633
|
+
ref: Ke,
|
|
634
|
+
xmlns: r(lo),
|
|
635
|
+
viewBox: `0 0 ${le.value.width} ${le.value.height}`,
|
|
636
|
+
class: mt({
|
|
637
|
+
"vue-data-ui-fullscreen--on": X.value,
|
|
638
|
+
"vue-data-ui-fulscreen--off": !X.value
|
|
636
639
|
}),
|
|
637
640
|
style: D({
|
|
638
641
|
maxWidth: "100%",
|
|
@@ -641,38 +644,38 @@ const yo = ["id"], bo = {
|
|
|
641
644
|
color: e.value.style.chart.color
|
|
642
645
|
})
|
|
643
646
|
}, [
|
|
644
|
-
Le(r(
|
|
647
|
+
Le(r(Tt)),
|
|
645
648
|
o.$slots["chart-background"] ? (i(), p("foreignObject", {
|
|
646
649
|
key: 0,
|
|
647
650
|
x: 0,
|
|
648
651
|
y: 0,
|
|
649
|
-
width:
|
|
650
|
-
height:
|
|
652
|
+
width: le.value.width,
|
|
653
|
+
height: le.value.height,
|
|
651
654
|
style: {
|
|
652
655
|
pointerEvents: "none"
|
|
653
656
|
}
|
|
654
657
|
}, [
|
|
655
658
|
C(o.$slots, "chart-background", {}, void 0, !0)
|
|
656
|
-
], 8,
|
|
657
|
-
|
|
658
|
-
(i(!0), p(
|
|
659
|
+
], 8, Ao)) : T("", !0),
|
|
660
|
+
V("defs", null, [
|
|
661
|
+
(i(!0), p(ie, null, ce(_.value.links, (t, n) => (i(), p("linearGradient", {
|
|
659
662
|
id: t.id,
|
|
660
663
|
x1: "0%",
|
|
661
664
|
y1: "0%",
|
|
662
665
|
x2: "100%",
|
|
663
666
|
y2: "0%"
|
|
664
667
|
}, [
|
|
665
|
-
|
|
668
|
+
V("stop", {
|
|
666
669
|
offset: "0%",
|
|
667
670
|
"stop-color": t.sourceColor
|
|
668
|
-
}, null, 8,
|
|
669
|
-
|
|
671
|
+
}, null, 8, xo),
|
|
672
|
+
V("stop", {
|
|
670
673
|
offset: "100%",
|
|
671
674
|
"stop-color": t.targetColor
|
|
672
|
-
}, null, 8,
|
|
673
|
-
], 8,
|
|
675
|
+
}, null, 8, _o)
|
|
676
|
+
], 8, To))), 256))
|
|
674
677
|
]),
|
|
675
|
-
(i(!0), p(
|
|
678
|
+
(i(!0), p(ie, null, ce(_.value.links, (t) => (i(), p("path", {
|
|
676
679
|
class: "vue-ui-flow-link",
|
|
677
680
|
d: t.path,
|
|
678
681
|
"stroke-linejoin": "round",
|
|
@@ -681,93 +684,101 @@ const yo = ["id"], bo = {
|
|
|
681
684
|
stroke: e.value.style.chart.links.stroke,
|
|
682
685
|
"stroke-width": e.value.style.chart.links.strokeWidth,
|
|
683
686
|
style: D(`
|
|
684
|
-
opacity:${k.value ? k.value.includes(t.source) && k.value.includes(t.target) ? 1 : 0.3 :
|
|
687
|
+
opacity:${k.value ? k.value.includes(t.source) && k.value.includes(t.target) ? 1 : 0.3 : q.value ? [t.target, t.source].includes(q.value) ? 1 : 0.3 : e.value.style.chart.links.opacity}
|
|
685
688
|
`)
|
|
686
|
-
}, null, 12,
|
|
687
|
-
(i(!0), p(
|
|
689
|
+
}, null, 12, So))), 256)),
|
|
690
|
+
(i(!0), p(ie, null, ce(_.value.nodes, (t, n) => (i(), p("rect", {
|
|
688
691
|
class: "vue-ui-flow-node",
|
|
689
692
|
x: t.x,
|
|
690
|
-
y: r(
|
|
691
|
-
height: r(
|
|
692
|
-
width:
|
|
693
|
+
y: r(x)(t.absoluteY) + e.value.style.chart.padding.top,
|
|
694
|
+
height: r(x)(t.height),
|
|
695
|
+
width: ge.value,
|
|
693
696
|
fill: t.color,
|
|
694
697
|
stroke: e.value.style.chart.nodes.stroke,
|
|
695
698
|
"stroke-width": e.value.style.chart.nodes.strokeWidth,
|
|
696
|
-
onMouseenter: (s) =>
|
|
697
|
-
onMouseleave: (s) =>
|
|
699
|
+
onMouseenter: (s) => Pt(t, n),
|
|
700
|
+
onMouseleave: (s) => rt(n),
|
|
698
701
|
style: D(`opacity:${k.value ? k.value.includes(t.name) ? 1 : 0.3 : 1}`),
|
|
699
|
-
onClick: (s) =>
|
|
700
|
-
}, null, 44,
|
|
701
|
-
e.value.style.chart.nodes.labels.show ? (i(), p("g",
|
|
702
|
-
(i(!0), p(
|
|
703
|
-
x: t.x +
|
|
704
|
-
y: r(
|
|
702
|
+
onClick: (s) => It(n)
|
|
703
|
+
}, null, 44, Oo))), 256)),
|
|
704
|
+
e.value.style.chart.nodes.labels.show ? (i(), p("g", No, [
|
|
705
|
+
(i(!0), p(ie, null, ce(_.value.nodes, (t, n) => (i(), p("text", {
|
|
706
|
+
x: t.x + ge.value / 2,
|
|
707
|
+
y: r(x)(
|
|
705
708
|
t.absoluteY + t.height / 2 - e.value.style.chart.nodes.labels.fontSize / 4
|
|
706
709
|
) + e.value.style.chart.padding.top,
|
|
707
710
|
"font-size": e.value.style.chart.nodes.labels.fontSize,
|
|
708
|
-
fill: r(
|
|
711
|
+
fill: r(bt)(t.color),
|
|
709
712
|
"text-anchor": "middle",
|
|
710
713
|
style: D(`pointer-events: none; opacity:${k.value ? k.value.includes(t.name) ? 1 : 0 : 1}`)
|
|
711
|
-
},
|
|
714
|
+
}, ve(e.value.style.chart.nodes.labels.abbreviation.use ? r(ao)({
|
|
712
715
|
source: t.name,
|
|
713
716
|
length: e.value.style.chart.nodes.labels.abbreviation.length
|
|
714
|
-
}) : t.name), 13,
|
|
715
|
-
(i(!0), p(
|
|
716
|
-
x: t.x +
|
|
717
|
-
y: r(
|
|
717
|
+
}) : t.name), 13, Fo))), 256)),
|
|
718
|
+
(i(!0), p(ie, null, ce(_.value.nodes, (t, n) => (i(), p("text", {
|
|
719
|
+
x: t.x + ge.value / 2,
|
|
720
|
+
y: r(x)(
|
|
718
721
|
t.absoluteY + t.height / 2 + e.value.style.chart.nodes.labels.fontSize
|
|
719
722
|
) + e.value.style.chart.padding.top,
|
|
720
723
|
"font-size": e.value.style.chart.nodes.labels.fontSize,
|
|
721
|
-
fill: r(
|
|
724
|
+
fill: r(bt)(t.color),
|
|
722
725
|
"text-anchor": "middle",
|
|
723
726
|
style: D(`pointer-events: none; opacity:${k.value ? k.value.includes(t.name) ? 1 : 0 : 1}`)
|
|
724
|
-
},
|
|
727
|
+
}, ve(r(Be)(
|
|
725
728
|
e.value.style.chart.nodes.labels.formatter,
|
|
726
729
|
t.value,
|
|
727
|
-
r(
|
|
730
|
+
r(de)({
|
|
728
731
|
p: e.value.style.chart.nodes.labels.prefix,
|
|
729
732
|
v: t.value,
|
|
730
733
|
s: e.value.style.chart.nodes.labels.suffix,
|
|
731
734
|
r: e.value.style.chart.nodes.labels.rounding
|
|
732
735
|
}),
|
|
733
736
|
{ datapoint: t, seriesIndex: n }
|
|
734
|
-
)), 13,
|
|
735
|
-
])) :
|
|
736
|
-
C(o.$slots, "svg", { svg:
|
|
737
|
-
], 14,
|
|
738
|
-
o.$slots.watermark ? (i(), p("div",
|
|
739
|
-
C(o.$slots, "watermark",
|
|
740
|
-
])) :
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
737
|
+
)), 13, Eo))), 256))
|
|
738
|
+
])) : T("", !0),
|
|
739
|
+
C(o.$slots, "svg", { svg: le.value }, void 0, !0)
|
|
740
|
+
], 14, $o)),
|
|
741
|
+
o.$slots.watermark ? (i(), p("div", Mo, [
|
|
742
|
+
C(o.$slots, "watermark", Q(ee({ isPrinting: r(Qe) || r(et) })), void 0, !0)
|
|
743
|
+
])) : T("", !0),
|
|
744
|
+
V("div", {
|
|
745
|
+
id: `legend-bottom-${W.value}`
|
|
746
|
+
}, null, 8, Po),
|
|
747
|
+
Ge.value ? (i(), U(Vt, {
|
|
748
|
+
key: 5,
|
|
749
|
+
to: e.value.style.chart.legend.position === "top" ? `#legend-top-${W.value}` : `#legend-bottom-${W.value}`
|
|
744
750
|
}, [
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
751
|
+
V("div", {
|
|
752
|
+
ref_key: "chartLegend",
|
|
753
|
+
ref: De
|
|
754
|
+
}, [
|
|
755
|
+
e.value.style.chart.legend.show && ht.value.length ? (i(), U(vo, {
|
|
756
|
+
key: 0,
|
|
757
|
+
legendSet: ht.value,
|
|
758
|
+
config: zt.value,
|
|
759
|
+
onClickMarker: l[0] || (l[0] = (t) => Ne(t))
|
|
760
|
+
}, {
|
|
761
|
+
item: $(({ legend: t, index: n }) => [
|
|
762
|
+
r(Te) ? T("", !0) : (i(), p("div", {
|
|
763
|
+
key: 0,
|
|
764
|
+
onClick: (s) => t.segregate(),
|
|
765
|
+
style: D(`opacity:${Y.value.length ? Y.value.includes(n) ? 1 : 0.5 : 1}`)
|
|
766
|
+
}, ve(t.name) + " (" + ve(t.count) + ") ", 13, Io))
|
|
767
|
+
]),
|
|
768
|
+
_: 1
|
|
769
|
+
}, 8, ["legendSet", "config"])) : T("", !0),
|
|
770
|
+
C(o.$slots, "legend", { legend: dt.value }, void 0, !0)
|
|
771
|
+
], 512)
|
|
772
|
+
], 8, ["to"])) : T("", !0),
|
|
762
773
|
o.$slots.source ? (i(), p("div", {
|
|
763
|
-
key:
|
|
774
|
+
key: 6,
|
|
764
775
|
ref_key: "source",
|
|
765
776
|
ref: Ye,
|
|
766
777
|
dir: "auto"
|
|
767
778
|
}, [
|
|
768
779
|
C(o.$slots, "source", {}, void 0, !0)
|
|
769
|
-
], 512)) :
|
|
770
|
-
Le(r(
|
|
780
|
+
], 512)) : T("", !0),
|
|
781
|
+
Le(r(_t), {
|
|
771
782
|
show: M.value.showTooltip && $e.value,
|
|
772
783
|
backgroundColor: e.value.style.chart.tooltip.backgroundColor,
|
|
773
784
|
color: e.value.style.chart.tooltip.color,
|
|
@@ -780,21 +791,21 @@ const yo = ["id"], bo = {
|
|
|
780
791
|
offsetY: e.value.style.chart.tooltip.offsetY,
|
|
781
792
|
parent: z.value,
|
|
782
793
|
content: Ae.value,
|
|
783
|
-
isCustom:
|
|
784
|
-
isFullscreen:
|
|
794
|
+
isCustom: me.value,
|
|
795
|
+
isFullscreen: X.value,
|
|
785
796
|
smooth: e.value.style.chart.tooltip.smooth,
|
|
786
797
|
backdropFilter: e.value.style.chart.tooltip.backdropFilter
|
|
787
798
|
}, {
|
|
788
799
|
"tooltip-before": $(() => [
|
|
789
|
-
C(o.$slots, "tooltip-before",
|
|
800
|
+
C(o.$slots, "tooltip-before", Q(ee({ ...ae.value })), void 0, !0)
|
|
790
801
|
]),
|
|
791
802
|
"tooltip-after": $(() => [
|
|
792
|
-
C(o.$slots, "tooltip-after",
|
|
803
|
+
C(o.$slots, "tooltip-after", Q(ee({ ...ae.value })), void 0, !0)
|
|
793
804
|
]),
|
|
794
805
|
_: 3
|
|
795
806
|
}, 8, ["show", "backgroundColor", "color", "fontSize", "borderRadius", "borderColor", "borderWidth", "backgroundOpacity", "position", "offsetY", "parent", "content", "isCustom", "isFullscreen", "smooth", "backdropFilter"]),
|
|
796
|
-
|
|
797
|
-
key:
|
|
807
|
+
je.value ? (i(), U(r($t), {
|
|
808
|
+
key: 7,
|
|
798
809
|
hideDetails: "",
|
|
799
810
|
config: {
|
|
800
811
|
open: M.value.showTable,
|
|
@@ -810,32 +821,32 @@ const yo = ["id"], bo = {
|
|
|
810
821
|
}
|
|
811
822
|
}, {
|
|
812
823
|
content: $(() => [
|
|
813
|
-
Le(r(
|
|
814
|
-
colNames:
|
|
815
|
-
head:
|
|
816
|
-
body:
|
|
817
|
-
config:
|
|
824
|
+
Le(r(At), {
|
|
825
|
+
colNames: ye.value.colNames,
|
|
826
|
+
head: ye.value.head,
|
|
827
|
+
body: ye.value.body,
|
|
828
|
+
config: ye.value.config,
|
|
818
829
|
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
819
830
|
onClose: l[1] || (l[1] = (t) => M.value.showTable = !1)
|
|
820
831
|
}, {
|
|
821
832
|
th: $(({ th: t }) => [
|
|
822
|
-
|
|
833
|
+
V("div", {
|
|
823
834
|
innerHTML: t,
|
|
824
835
|
style: { display: "flex", "align-items": "center" }
|
|
825
|
-
}, null, 8,
|
|
836
|
+
}, null, 8, Lo)
|
|
826
837
|
]),
|
|
827
838
|
td: $(({ td: t }) => [
|
|
828
|
-
|
|
839
|
+
Xt(ve(t.name || t), 1)
|
|
829
840
|
]),
|
|
830
841
|
_: 1
|
|
831
842
|
}, 8, ["colNames", "head", "body", "config", "title"])
|
|
832
843
|
]),
|
|
833
844
|
_: 1
|
|
834
|
-
}, 8, ["config"])) :
|
|
835
|
-
r(Te) ? (i(),
|
|
836
|
-
], 46,
|
|
845
|
+
}, 8, ["config"])) : T("", !0),
|
|
846
|
+
r(Te) ? (i(), U(yo, { key: 8 })) : T("", !0)
|
|
847
|
+
], 46, Co));
|
|
837
848
|
}
|
|
838
|
-
},
|
|
849
|
+
}, Ko = /* @__PURE__ */ bo(zo, [["__scopeId", "data-v-8feb3ba3"]]);
|
|
839
850
|
export {
|
|
840
|
-
|
|
851
|
+
Ko as default
|
|
841
852
|
};
|