vue-data-ui 2.3.74 → 2.3.76
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-DK6F5Fq3.cjs → Arrow-D7M4-bW7.cjs} +1 -1
- package/dist/{Arrow-CYCrAySW.js → Arrow-DY9RKUmG.js} +1 -1
- package/dist/{BaseIcon-DBHVtm3A.cjs → BaseIcon-DB7Apwv_.cjs} +1 -1
- package/dist/{BaseIcon-kBIAYqUO.js → BaseIcon-rwm-10Hu.js} +1 -1
- package/dist/{DataTable-BNFSPjhv.cjs → DataTable-CsNozyz7.cjs} +1 -1
- package/dist/{DataTable-CKdV-L0e.js → DataTable-e2fnfjXV.js} +2 -2
- package/dist/{Legend-Cj7T-DqJ.js → Legend-5cQ0xZjK.js} +1 -1
- package/dist/{Legend-Do2kcWFT.cjs → Legend-DgFd-O0m.cjs} +1 -1
- package/dist/{Shape-Bo8ZjViG.js → Shape-CiTElr_0.js} +1 -1
- package/dist/{Shape-DRDUAe_o.cjs → Shape-yPECDLiP.cjs} +1 -1
- package/dist/{Slicer-D8jHSP7U.cjs → Slicer-DaZgCKV7.cjs} +1 -1
- package/dist/{Slicer-4nGKvUYF.js → Slicer-DwBBu3kB.js} +2 -2
- package/dist/{Title-D5cATWsL.cjs → Title-3EduyW4p.cjs} +1 -1
- package/dist/{Title-DZjnxQdN.js → Title-gUz6GDA3.js} +1 -1
- package/dist/{Tooltip-B8yLaegk.cjs → Tooltip-DScSrYXJ.cjs} +1 -1
- package/dist/{Tooltip--kgFEVZs.js → Tooltip-DfSM1mNP.js} +1 -1
- package/dist/{index-D_32ZGWd.cjs → index-BTgtr0F8.cjs} +1 -1
- package/dist/{index-C8SH0f2u.js → index-CaV1s-yZ.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{useNestedProp-BvvH633N.cjs → useNestedProp-CisbRRo_.cjs} +1 -1
- package/dist/{useNestedProp-lS_T5lM3.js → useNestedProp-tWCzZrLx.js} +1 -1
- package/dist/{usePrinter-BouFNHWR.cjs → usePrinter-DzTaA1eh.cjs} +1 -1
- package/dist/{usePrinter-Dj50NAxo.js → usePrinter-rvJyT65A.js} +1 -1
- package/dist/{vue-data-ui-v_BbbLtJ.cjs → vue-data-ui-BGkWRPUY.cjs} +1 -1
- package/dist/{vue-data-ui-DoXqU7xC.js → vue-data-ui-BO89gTtq.js} +57 -57
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-CnoPOJHm.js → vue-ui-3d-bar-CcTMIHiB.js} +499 -486
- package/dist/vue-ui-3d-bar-DzmcGuqh.cjs +19 -0
- package/dist/{vue-ui-accordion-Cka6b_Up.cjs → vue-ui-accordion-7e4Myhcg.cjs} +1 -1
- package/dist/{vue-ui-accordion-YHleIgkV.js → vue-ui-accordion-CpzGQ63y.js} +3 -3
- package/dist/vue-ui-age-pyramid-C7qr9EwB.cjs +1 -0
- package/dist/{vue-ui-age-pyramid-CENg8fDg.js → vue-ui-age-pyramid-D71ZLkVV.js} +182 -169
- package/dist/{vue-ui-annotator-VJOLUkqJ.js → vue-ui-annotator-B8Iu6cYt.js} +1 -1
- package/dist/{vue-ui-annotator-ByYg6QMs.cjs → vue-ui-annotator-BKQrweqm.cjs} +1 -1
- package/dist/{vue-ui-candlestick-CHsGD3bx.js → vue-ui-candlestick-Bx4QVkY0.js} +295 -279
- package/dist/vue-ui-candlestick-DAc1FQ-i.cjs +2 -0
- package/dist/vue-ui-carousel-table-uFRqkghO.cjs +1 -0
- package/dist/{vue-ui-carousel-table-RAtX3VBu.js → vue-ui-carousel-table-xuQG6bcH.js} +146 -129
- package/dist/{vue-ui-chestnut-B5GQX0J_.js → vue-ui-chestnut-Bo6rDcU7.js} +215 -204
- package/dist/vue-ui-chestnut-DJkm72oD.cjs +6 -0
- package/dist/{vue-ui-cursor-DnZqLj21.cjs → vue-ui-cursor-BQbeuW-k.cjs} +1 -1
- package/dist/{vue-ui-cursor-CMm7XSSG.js → vue-ui-cursor-C0KOqEOq.js} +2 -2
- package/dist/{vue-ui-dashboard-DgEQJnLr.cjs → vue-ui-dashboard-0Hsjx-bO.cjs} +1 -1
- package/dist/{vue-ui-dashboard-Ck_5L3eu.js → vue-ui-dashboard-BT71xS7P.js} +2 -2
- package/dist/{vue-ui-digits--ULH35um.js → vue-ui-digits-BRqpKYvD.js} +2 -2
- package/dist/{vue-ui-digits-UvwUdi6U.cjs → vue-ui-digits-C2ReH6w0.cjs} +1 -1
- package/dist/{vue-ui-donut-QQ1fWWvc.js → vue-ui-donut-NQW-3prf.js} +376 -362
- package/dist/vue-ui-donut-evolution-DOe-cwLi.cjs +1 -0
- package/dist/{vue-ui-donut-evolution-Cx8kBB_7.js → vue-ui-donut-evolution-jbXQQGTc.js} +270 -255
- package/dist/vue-ui-donut-v81suIOX.cjs +1 -0
- package/dist/vue-ui-dumbbell-DXQSg6wa.cjs +9 -0
- package/dist/{vue-ui-dumbbell-BYvwHpU8.js → vue-ui-dumbbell-Dyz8xdtC.js} +232 -213
- package/dist/vue-ui-flow-BL3JWW1m.js +481 -0
- package/dist/vue-ui-flow-UqSNwH9d.cjs +1 -0
- package/dist/vue-ui-galaxy-DTQWGvRH.cjs +1 -0
- package/dist/{vue-ui-galaxy-B0L57aec.js → vue-ui-galaxy-Dx9nsOuM.js} +175 -162
- package/dist/vue-ui-gauge-BUB7H0qA.cjs +1 -0
- package/dist/vue-ui-gauge-CLaKGi0-.js +500 -0
- package/dist/vue-ui-gizmo-Kitfqu0J.cjs +1 -0
- package/dist/{vue-ui-gizmo-D2RfM55X.js → vue-ui-gizmo-of-4s5HG.js} +66 -53
- package/dist/{vue-ui-heatmap-DKM0DH41.js → vue-ui-heatmap-BIzjOMXO.js} +157 -143
- package/dist/vue-ui-heatmap-DUw2350O.cjs +1 -0
- package/dist/vue-ui-kpi-By3YPwgo.js +98 -0
- package/dist/vue-ui-kpi-DyL2Hcz-.cjs +1 -0
- package/dist/{vue-ui-mini-loader-CLP19Txv.cjs → vue-ui-mini-loader-C048-8Kd.cjs} +1 -1
- package/dist/{vue-ui-mini-loader-MywnWlYI.js → vue-ui-mini-loader-DnK3V2z2.js} +2 -2
- package/dist/{vue-ui-molecule-CLI9iTRE.js → vue-ui-molecule-BfhbIqa5.js} +177 -167
- package/dist/vue-ui-molecule-D-ahly6R.cjs +1 -0
- package/dist/vue-ui-mood-radar-DD8R9BpJ.cjs +1 -0
- package/dist/{vue-ui-mood-radar-O30wZo9a.js → vue-ui-mood-radar-DXxEKr3x.js} +172 -161
- package/dist/{vue-ui-nested-donuts-D8o4TqTt.js → vue-ui-nested-donuts-BdUdHFd-.js} +377 -364
- package/dist/vue-ui-nested-donuts-C7qM_FRw.cjs +17 -0
- package/dist/{vue-ui-onion-Hmcke6xB.js → vue-ui-onion-D0vF5jBt.js} +191 -177
- package/dist/vue-ui-onion-DX3gofXZ.cjs +5 -0
- package/dist/{vue-ui-parallel-coordinate-plot-CyChE3NP.js → vue-ui-parallel-coordinate-plot-CTZY-pY8.js} +298 -284
- package/dist/vue-ui-parallel-coordinate-plot-DEx5kFYd.cjs +8 -0
- package/dist/{vue-ui-quadrant-DimTQdAj.js → vue-ui-quadrant-ByY8GP3y.js} +347 -334
- package/dist/vue-ui-quadrant-CgApzie6.cjs +1 -0
- package/dist/{vue-ui-quick-chart-DxJvENid.js → vue-ui-quick-chart-DTxJ__7j.js} +483 -469
- package/dist/vue-ui-quick-chart-DWZEgUJF.cjs +15 -0
- package/dist/{vue-ui-radar-D_FieunT.js → vue-ui-radar-5UBmAU6W.js} +202 -189
- package/dist/vue-ui-radar-DEED0rTz.cjs +1 -0
- package/dist/{vue-ui-rating-BHW2Onru.cjs → vue-ui-rating-Ce_Ewqtl.cjs} +1 -1
- package/dist/{vue-ui-rating-DF1BpH4E.js → vue-ui-rating-Dr6jquxh.js} +2 -2
- package/dist/vue-ui-relation-circle-BU8i2miI.js +322 -0
- package/dist/vue-ui-relation-circle-CRcQ6Zcy.cjs +1 -0
- package/dist/{vue-ui-rings-BqS-iece.js → vue-ui-rings-Ctl3Jywh.js} +203 -189
- package/dist/vue-ui-rings-OQ8a1Ruw.cjs +2 -0
- package/dist/vue-ui-scatter-B8StSjt8.cjs +1 -0
- package/dist/{vue-ui-scatter-Dns49Nht.js → vue-ui-scatter-BwJ_koWT.js} +284 -270
- package/dist/{vue-ui-screenshot-5Gsnd0Wr.js → vue-ui-screenshot-BS3L5vhN.js} +1 -1
- package/dist/{vue-ui-screenshot---q062Kd.cjs → vue-ui-screenshot-bAVk3EPl.cjs} +1 -1
- package/dist/{vue-ui-skeleton-fVPw-oIR.cjs → vue-ui-skeleton-CMQzFTs9.cjs} +1 -1
- package/dist/{vue-ui-skeleton-B4eWLjH3.js → vue-ui-skeleton-CvFX_ExX.js} +2 -2
- package/dist/{vue-ui-smiley-B8Tyunn3.js → vue-ui-smiley-CGYZpNt9.js} +2 -2
- package/dist/{vue-ui-smiley-YfHmv0rQ.cjs → vue-ui-smiley-sF8QIso1.cjs} +1 -1
- package/dist/vue-ui-spark-trend-B4XSSKl9.js +263 -0
- package/dist/vue-ui-spark-trend-CdIoxaqb.cjs +1 -0
- package/dist/{vue-ui-sparkbar-9DBvdYn7.js → vue-ui-sparkbar-BbsJGDMZ.js} +95 -87
- package/dist/vue-ui-sparkbar-C3i1K7hi.cjs +1 -0
- package/dist/vue-ui-sparkgauge-BKyQoI7C.cjs +1 -0
- package/dist/vue-ui-sparkgauge-D4w_i_QJ.js +178 -0
- package/dist/{vue-ui-sparkhistogram-BBUVmco4.js → vue-ui-sparkhistogram-CYybrW-6.js} +79 -68
- package/dist/vue-ui-sparkhistogram-CvTYEmbz.cjs +1 -0
- package/dist/vue-ui-sparkline-CDowaDRS.cjs +1 -0
- package/dist/{vue-ui-sparkline-CeqNV6Re.js → vue-ui-sparkline-DjN1SVdO.js} +142 -123
- package/dist/{vue-ui-sparkstackbar-C3GMC1eW.js → vue-ui-sparkstackbar-BLMhJxaN.js} +120 -104
- package/dist/vue-ui-sparkstackbar-BZ2bESBi.cjs +1 -0
- package/dist/{vue-ui-stackbar-DyGPrFxi.js → vue-ui-stackbar-BTKOHUYc.js} +235 -222
- package/dist/vue-ui-stackbar-DRHaJFR8.cjs +6 -0
- package/dist/vue-ui-strip-plot-DxQxFbWg.cjs +1 -0
- package/dist/{vue-ui-strip-plot-y1AnVJmq.js → vue-ui-strip-plot-o6GTsGAT.js} +246 -232
- package/dist/{vue-ui-table-xWvAQS-s.cjs → vue-ui-table-BFIj1Rgh.cjs} +1 -1
- package/dist/{vue-ui-table-B4kfykAO.js → vue-ui-table-CnquiTpr.js} +1 -1
- package/dist/vue-ui-table-heatmap-CCGK12Fa.cjs +1 -0
- package/dist/{vue-ui-table-heatmap-YZRSzwRM.js → vue-ui-table-heatmap-CZRIwv-Q.js} +106 -95
- package/dist/{vue-ui-table-sparkline-C0v2r4Kf.js → vue-ui-table-sparkline-B3zEeq6Z.js} +151 -138
- package/dist/vue-ui-table-sparkline-DYmgfHz4.cjs +1 -0
- package/dist/{vue-ui-thermometer-D5qurIy7.js → vue-ui-thermometer-BopiohUh.js} +116 -104
- package/dist/vue-ui-thermometer-CzPRBt6c.cjs +1 -0
- package/dist/vue-ui-timer-Bonw69Lt.cjs +64 -0
- package/dist/{vue-ui-timer-VWjovnKL.js → vue-ui-timer-C7WkW8hK.js} +191 -176
- package/dist/{vue-ui-tiremarks-jH6cdQOJ.js → vue-ui-tiremarks-BurRtFv4.js} +115 -103
- package/dist/vue-ui-tiremarks-DkIGfq8t.cjs +1 -0
- package/dist/vue-ui-treemap-CalhJmnp.cjs +1 -0
- package/dist/{vue-ui-treemap-BCc5sQLB.js → vue-ui-treemap-DWy4voIr.js} +251 -237
- package/dist/{vue-ui-vertical-bar-2In_g5iC.js → vue-ui-vertical-bar-CJW1YhtY.js} +314 -299
- package/dist/vue-ui-vertical-bar-rwWp-sai.cjs +4 -0
- package/dist/{vue-ui-waffle-OzU830VX.js → vue-ui-waffle-DB7X6nTS.js} +285 -265
- package/dist/vue-ui-waffle-faQMBYNx.cjs +1 -0
- package/dist/vue-ui-wheel-BzjbGP6a.cjs +1 -0
- package/dist/vue-ui-wheel-CryKap2E.js +255 -0
- package/dist/vue-ui-word-cloud-COqUkvei.js +512 -0
- package/dist/vue-ui-word-cloud-DJN9I4q4.cjs +1 -0
- package/dist/vue-ui-xy-BmA0tspd.cjs +3 -0
- package/dist/{vue-ui-xy-DuJtYXKl.js → vue-ui-xy-b1Z_HPsx.js} +300 -274
- package/dist/{vue-ui-xy-canvas-CKibMJHh.js → vue-ui-xy-canvas-BgbLnY5B.js} +345 -327
- package/dist/vue-ui-xy-canvas-DOM2Kq_s.cjs +9 -0
- package/package.json +1 -1
- package/dist/vue-ui-3d-bar-CwCEoPX-.cjs +0 -19
- package/dist/vue-ui-age-pyramid-GqCNpd_h.cjs +0 -1
- package/dist/vue-ui-candlestick-TdNVq_FX.cjs +0 -2
- package/dist/vue-ui-carousel-table-yXUSFk2u.cjs +0 -1
- package/dist/vue-ui-chestnut-EJj-dQSY.cjs +0 -6
- package/dist/vue-ui-donut-BqUBysA_.cjs +0 -1
- package/dist/vue-ui-donut-evolution-BXtEnop4.cjs +0 -1
- package/dist/vue-ui-dumbbell-CjIh7KTm.cjs +0 -9
- package/dist/vue-ui-flow-hp0Hpuhn.js +0 -469
- package/dist/vue-ui-flow-u29zqSQj.cjs +0 -1
- package/dist/vue-ui-galaxy-DE1HbBi-.cjs +0 -1
- package/dist/vue-ui-gauge-B_IZrsfj.cjs +0 -1
- package/dist/vue-ui-gauge-CPyyn7cL.js +0 -488
- package/dist/vue-ui-gizmo-DR4gacOL.cjs +0 -1
- package/dist/vue-ui-heatmap-DMB_eUpA.cjs +0 -1
- package/dist/vue-ui-kpi-BAxAY13T.js +0 -84
- package/dist/vue-ui-kpi-BD21xshi.cjs +0 -1
- package/dist/vue-ui-molecule-BNsWckH-.cjs +0 -1
- package/dist/vue-ui-mood-radar-BsWE1f8R.cjs +0 -1
- package/dist/vue-ui-nested-donuts-CYyUtXs2.cjs +0 -17
- package/dist/vue-ui-onion-D7TXJu5w.cjs +0 -5
- package/dist/vue-ui-parallel-coordinate-plot-BqZB7xKn.cjs +0 -8
- package/dist/vue-ui-quadrant-BPDTvxlT.cjs +0 -1
- package/dist/vue-ui-quick-chart-C_-ut0if.cjs +0 -15
- package/dist/vue-ui-radar-C5Kq19hg.cjs +0 -1
- package/dist/vue-ui-relation-circle-4kIYttRI.js +0 -310
- package/dist/vue-ui-relation-circle-DHMHHsqY.cjs +0 -1
- package/dist/vue-ui-rings-BqPS8NKl.cjs +0 -2
- package/dist/vue-ui-scatter-BLVcdf3d.cjs +0 -1
- package/dist/vue-ui-spark-trend-Dpv6am0Z.cjs +0 -1
- package/dist/vue-ui-spark-trend-Em9OqYyG.js +0 -251
- package/dist/vue-ui-sparkbar-BuSuwQYl.cjs +0 -1
- package/dist/vue-ui-sparkgauge-BN5feBzp.js +0 -167
- package/dist/vue-ui-sparkgauge-DKtUZMv1.cjs +0 -1
- package/dist/vue-ui-sparkhistogram-BmuusW02.cjs +0 -1
- package/dist/vue-ui-sparkline-Blzv-tIQ.cjs +0 -1
- package/dist/vue-ui-sparkstackbar-D__WDEMv.cjs +0 -1
- package/dist/vue-ui-stackbar-DFqJ5K_q.cjs +0 -6
- package/dist/vue-ui-strip-plot-z9fjJ6Dj.cjs +0 -1
- package/dist/vue-ui-table-heatmap-CGKecjtm.cjs +0 -1
- package/dist/vue-ui-table-sparkline-CHFZG3Tg.cjs +0 -1
- package/dist/vue-ui-thermometer-DoOxxVW1.cjs +0 -1
- package/dist/vue-ui-timer-D63zHe-I.cjs +0 -64
- package/dist/vue-ui-tiremarks-Cp8YEmXh.cjs +0 -1
- package/dist/vue-ui-treemap-DJrdEFW5.cjs +0 -1
- package/dist/vue-ui-vertical-bar-BfJJqN_z.cjs +0 -4
- package/dist/vue-ui-waffle-A2gmRbq0.cjs +0 -1
- package/dist/vue-ui-wheel-C9QXzWu1.js +0 -242
- package/dist/vue-ui-wheel-DGSh9VKq.cjs +0 -1
- package/dist/vue-ui-word-cloud-C2ZaVlfO.js +0 -498
- package/dist/vue-ui-word-cloud-DPFB1MYk.cjs +0 -1
- package/dist/vue-ui-xy-C-2-aijE.cjs +0 -3
- package/dist/vue-ui-xy-canvas-D7wf3xab.cjs +0 -9
|
@@ -1,469 +0,0 @@
|
|
|
1
|
-
import { computed as m, onMounted as Fe, ref as w, openBlock as r, createElementBlock as h, normalizeClass as ue, normalizeStyle as C, createVNode as re, createCommentVNode as T, createBlock as A, unref as i, createSlots as Ie, withCtx as y, renderSlot as x, normalizeProps as ie, guardReactiveProps as ce, createElementVNode as O, Fragment as P, renderList as F, toDisplayString as U, createTextVNode as He, nextTick as Le } from "vue";
|
|
2
|
-
import { u as Ee, o as Oe, e as Me, c as de, t as Se, a as ze, p as V, b as Ye, s as v, f as ve, X as De, E as fe, H as Ge, i as Be, q as Ae, r as Ue } from "./index-C8SH0f2u.js";
|
|
3
|
-
import { _ as Ve } from "./Title-DZjnxQdN.js";
|
|
4
|
-
import { u as je, U as Xe } from "./usePrinter-Dj50NAxo.js";
|
|
5
|
-
import { D as We } from "./DataTable-CKdV-L0e.js";
|
|
6
|
-
import qe from "./vue-ui-accordion-YHleIgkV.js";
|
|
7
|
-
import Re from "./vue-ui-skeleton-B4eWLjH3.js";
|
|
8
|
-
import { u as he } from "./useNestedProp-lS_T5lM3.js";
|
|
9
|
-
import { _ as Ze } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
10
|
-
const Je = ["id"], Ke = ["xmlns", "viewBox"], Qe = ["id"], et = ["stop-color"], tt = ["stop-color"], lt = ["d", "fill", "stroke", "stroke-width"], ot = ["x", "y", "height", "width", "fill", "stroke", "stroke-width", "onMouseenter"], at = ["x", "y", "font-size", "fill"], nt = ["x", "y", "font-size", "fill"], st = {
|
|
11
|
-
key: 2,
|
|
12
|
-
class: "vue-data-ui-watermark"
|
|
13
|
-
}, ut = ["innerHTML"], rt = {
|
|
14
|
-
__name: "vue-ui-flow",
|
|
15
|
-
props: {
|
|
16
|
-
config: {
|
|
17
|
-
type: Object,
|
|
18
|
-
default() {
|
|
19
|
-
return {};
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
dataset: {
|
|
23
|
-
type: Array,
|
|
24
|
-
default() {
|
|
25
|
-
return [];
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
},
|
|
29
|
-
setup(me, { expose: ge }) {
|
|
30
|
-
const g = me, { vue_ui_flow: pe } = Ee(), M = m(() => !!g.dataset && g.dataset.length);
|
|
31
|
-
Fe(() => {
|
|
32
|
-
Oe(g.dataset) && Me({
|
|
33
|
-
componentName: "VueUiFlow",
|
|
34
|
-
type: "dataset"
|
|
35
|
-
});
|
|
36
|
-
});
|
|
37
|
-
const S = w(de()), j = w(null), X = w(0), N = w(!1);
|
|
38
|
-
function be(l) {
|
|
39
|
-
N.value = l, X.value += 1;
|
|
40
|
-
}
|
|
41
|
-
const e = m(() => {
|
|
42
|
-
const l = he({
|
|
43
|
-
userConfig: g.config,
|
|
44
|
-
defaultConfig: pe
|
|
45
|
-
});
|
|
46
|
-
return l.theme ? {
|
|
47
|
-
...he({
|
|
48
|
-
userConfig: Se.vue_ui_flow[l.theme] || g.config,
|
|
49
|
-
defaultConfig: l
|
|
50
|
-
}),
|
|
51
|
-
customPalette: ze[l.theme] || V
|
|
52
|
-
} : l;
|
|
53
|
-
}), { isPrinting: W, isImaging: q, generatePdf: R, generateImage: Z } = je({
|
|
54
|
-
elementId: `flow_${S.value}`,
|
|
55
|
-
fileName: e.value.style.chart.title.text || "vue-ui-flow"
|
|
56
|
-
}), z = m(() => Ye(e.value.customPalette)), J = m(() => e.value.style.chart.nodes.gap), $ = m(() => e.value.style.chart.nodes.width), I = w({
|
|
57
|
-
showTable: e.value.table.show
|
|
58
|
-
}), K = m(() => e.value.style.chart.links.width), Y = m(() => !g.dataset || !g.dataset.length ? [] : g.dataset.map((l) => [
|
|
59
|
-
l[0],
|
|
60
|
-
l[1],
|
|
61
|
-
v(l[2])
|
|
62
|
-
])), Q = m(() => {
|
|
63
|
-
const l = {};
|
|
64
|
-
function o(n) {
|
|
65
|
-
l[n] || (l[n] = { inflow: 0, outflow: 0 });
|
|
66
|
-
}
|
|
67
|
-
Y.value.forEach(([n, a, c]) => {
|
|
68
|
-
o(n), o(a), l[n].outflow += c, l[a].inflow += c;
|
|
69
|
-
});
|
|
70
|
-
let t = 0;
|
|
71
|
-
for (const n in l) {
|
|
72
|
-
const a = Math.max(l[n].inflow, l[n].outflow);
|
|
73
|
-
t = Math.max(t, a);
|
|
74
|
-
}
|
|
75
|
-
return t;
|
|
76
|
-
});
|
|
77
|
-
function ye(l) {
|
|
78
|
-
return l / Q.value * 100 + e.value.style.chart.nodes.minHeight;
|
|
79
|
-
}
|
|
80
|
-
function ke(l) {
|
|
81
|
-
const o = e.value.style.chart.nodes.minHeight;
|
|
82
|
-
return (l - o) / 100 * Q.value;
|
|
83
|
-
}
|
|
84
|
-
function we(l) {
|
|
85
|
-
const o = {}, t = {};
|
|
86
|
-
function n(s, u) {
|
|
87
|
-
o[s] || (o[s] = { height: 0, level: null, inflow: 0, outflow: 0 }), o[s].level === null && (o[s].level = u), t[u] || (t[u] = []), t[u].includes(s) || t[u].push(s);
|
|
88
|
-
}
|
|
89
|
-
l.forEach(([s, u, f], _) => {
|
|
90
|
-
const k = o[s] ? o[s].level : 0, E = k + 1;
|
|
91
|
-
n(s, k), n(u, E), o[s].children || (o[s].children = []), o[s].children.push({ target: u, value: f }), o[s].outflow += f, o[u].inflow += f;
|
|
92
|
-
}), Object.keys(o).forEach((s, u) => {
|
|
93
|
-
o[s].color = z.value[u] || z.value[u % z.value.length] || V[u] || V[u % d.length];
|
|
94
|
-
});
|
|
95
|
-
for (const s in o)
|
|
96
|
-
o[s].height = ye(Math.max(o[s].inflow, o[s].outflow)), o[s].name = s;
|
|
97
|
-
const a = {};
|
|
98
|
-
for (const s in t) {
|
|
99
|
-
let u = 0;
|
|
100
|
-
t[s].forEach((f, _) => {
|
|
101
|
-
const k = o[f].height;
|
|
102
|
-
a[f] = {
|
|
103
|
-
x: parseInt(s, 10) * K.value + e.value.style.chart.padding.left,
|
|
104
|
-
y: u,
|
|
105
|
-
absoluteY: u,
|
|
106
|
-
height: k,
|
|
107
|
-
i: _,
|
|
108
|
-
color: o[f].color,
|
|
109
|
-
value: ke(k)
|
|
110
|
-
}, u += k + J.value;
|
|
111
|
-
});
|
|
112
|
-
}
|
|
113
|
-
const c = [];
|
|
114
|
-
for (const s in o) {
|
|
115
|
-
let u = a[s].absoluteY;
|
|
116
|
-
o[s].children && o[s].children.forEach(({ target: f, value: _ }, k) => {
|
|
117
|
-
const E = a[f].y, G = a[s], B = a[f], oe = v(u), ae = v(u + _ / o[s].outflow * G.height), ne = v(E), se = v(E + _ / o[f].inflow * B.height), Pe = {
|
|
118
|
-
id: de(),
|
|
119
|
-
source: s,
|
|
120
|
-
target: f,
|
|
121
|
-
path: `M ${v(G.x) + v($.value)} ${oe} L ${v(G.x) + v($.value)} ${ae} L ${v(B.x)} ${se} L ${v(B.x)} ${ne} Z`,
|
|
122
|
-
value: _,
|
|
123
|
-
sourceColor: o[s].color,
|
|
124
|
-
targetColor: o[f].color
|
|
125
|
-
};
|
|
126
|
-
c.push(Pe), u += ae - oe, a[f].y += se - ne;
|
|
127
|
-
});
|
|
128
|
-
}
|
|
129
|
-
return { nodeCoordinates: a, links: c };
|
|
130
|
-
}
|
|
131
|
-
const p = m(() => {
|
|
132
|
-
const l = we(g.dataset);
|
|
133
|
-
return {
|
|
134
|
-
nodes: Object.keys(l.nodeCoordinates).map((o, t) => ({
|
|
135
|
-
...l.nodeCoordinates[o],
|
|
136
|
-
name: o
|
|
137
|
-
})),
|
|
138
|
-
links: l.links
|
|
139
|
-
};
|
|
140
|
-
}), Ce = m(() => xe(p.value.nodes));
|
|
141
|
-
function xe(l) {
|
|
142
|
-
const o = {};
|
|
143
|
-
for (const n in l) {
|
|
144
|
-
const { x: a, height: c } = l[n];
|
|
145
|
-
o[a] || (o[a] = 0), o[a] += c + J.value;
|
|
146
|
-
}
|
|
147
|
-
return Math.max(...Object.values(o));
|
|
148
|
-
}
|
|
149
|
-
const D = m(() => {
|
|
150
|
-
const { top: l, right: o, left: t, bottom: n } = e.value.style.chart.padding, a = Y.value.length * K.value;
|
|
151
|
-
return {
|
|
152
|
-
height: Ce.value + l + n,
|
|
153
|
-
width: o + Math.max(...p.value.nodes.map((c) => c.x)) + $.value,
|
|
154
|
-
left: t,
|
|
155
|
-
top: l,
|
|
156
|
-
right: a - o,
|
|
157
|
-
p_top: l,
|
|
158
|
-
p_bottom: n
|
|
159
|
-
};
|
|
160
|
-
});
|
|
161
|
-
function $e(l) {
|
|
162
|
-
const o = {}, t = {}, n = /* @__PURE__ */ new Set();
|
|
163
|
-
return Y.value.forEach(([a, c, s]) => {
|
|
164
|
-
o[a] || (o[a] = []), t[c] || (t[c] = []), o[a].push(c), t[c].push(a);
|
|
165
|
-
}), o[l] && o[l].forEach((a) => n.add(a)), t[l] && t[l].forEach((a) => n.add(a)), Array.from(n).concat(l);
|
|
166
|
-
}
|
|
167
|
-
const b = w(null), H = w(null);
|
|
168
|
-
function _e(l) {
|
|
169
|
-
b.value = $e(l.name), H.value = l.name;
|
|
170
|
-
}
|
|
171
|
-
function Ne() {
|
|
172
|
-
b.value = null, H.value = null;
|
|
173
|
-
}
|
|
174
|
-
const ee = m(() => p.value.links.map(({ source: l, target: o, sourceColor: t, targetColor: n, value: a }) => ({
|
|
175
|
-
source: l,
|
|
176
|
-
target: o,
|
|
177
|
-
sourceColor: t,
|
|
178
|
-
targetColor: n,
|
|
179
|
-
value: a
|
|
180
|
-
})));
|
|
181
|
-
function te() {
|
|
182
|
-
Le(() => {
|
|
183
|
-
const l = ee.value.map((n, a) => [
|
|
184
|
-
[n.source],
|
|
185
|
-
[n.target],
|
|
186
|
-
[n.value]
|
|
187
|
-
]), o = [
|
|
188
|
-
[e.value.style.chart.title.text],
|
|
189
|
-
[e.value.style.chart.title.subtitle.text],
|
|
190
|
-
[
|
|
191
|
-
[e.value.table.columnNames.source],
|
|
192
|
-
[e.value.table.columnNames.target],
|
|
193
|
-
[e.value.table.columnNames.value]
|
|
194
|
-
]
|
|
195
|
-
].concat(l), t = Ae(o);
|
|
196
|
-
Ue({
|
|
197
|
-
csvContent: t,
|
|
198
|
-
title: e.value.style.chart.title.text || "vue-ui-flow"
|
|
199
|
-
});
|
|
200
|
-
});
|
|
201
|
-
}
|
|
202
|
-
const L = m(() => {
|
|
203
|
-
const l = [
|
|
204
|
-
e.value.table.columnNames.source,
|
|
205
|
-
e.value.table.columnNames.target,
|
|
206
|
-
e.value.table.columnNames.value
|
|
207
|
-
], o = ee.value.map((a, c) => [
|
|
208
|
-
{
|
|
209
|
-
color: a.sourceColor,
|
|
210
|
-
name: a.source
|
|
211
|
-
},
|
|
212
|
-
{
|
|
213
|
-
color: a.targetColor,
|
|
214
|
-
name: a.target
|
|
215
|
-
},
|
|
216
|
-
ve({
|
|
217
|
-
p: e.value.style.chart.nodes.labels.prefix,
|
|
218
|
-
v: a.value,
|
|
219
|
-
s: e.value.style.chart.nodes.labels.suffix,
|
|
220
|
-
r: e.value.style.chart.nodes.labels.rounding
|
|
221
|
-
})
|
|
222
|
-
]), t = {
|
|
223
|
-
th: {
|
|
224
|
-
backgroundColor: e.value.table.th.backgroundColor,
|
|
225
|
-
color: e.value.table.th.color,
|
|
226
|
-
outline: e.value.table.th.outline
|
|
227
|
-
},
|
|
228
|
-
td: {
|
|
229
|
-
backgroundColor: e.value.table.td.backgroundColor,
|
|
230
|
-
color: e.value.table.td.color,
|
|
231
|
-
outline: e.value.table.td.outline
|
|
232
|
-
},
|
|
233
|
-
breakpoint: e.value.table.responsiveBreakpoint
|
|
234
|
-
};
|
|
235
|
-
return {
|
|
236
|
-
colNames: [
|
|
237
|
-
e.value.table.columnNames.source,
|
|
238
|
-
e.value.table.columnNames.target,
|
|
239
|
-
e.value.table.columnNames.value
|
|
240
|
-
],
|
|
241
|
-
head: l,
|
|
242
|
-
body: o,
|
|
243
|
-
config: t
|
|
244
|
-
};
|
|
245
|
-
});
|
|
246
|
-
function Te() {
|
|
247
|
-
return p.value;
|
|
248
|
-
}
|
|
249
|
-
function le() {
|
|
250
|
-
I.value.showTable = !I.value.showTable;
|
|
251
|
-
}
|
|
252
|
-
return ge({
|
|
253
|
-
getData: Te,
|
|
254
|
-
generateCsv: te,
|
|
255
|
-
generateImage: Z,
|
|
256
|
-
generatePdf: R,
|
|
257
|
-
toggleTable: le
|
|
258
|
-
}), (l, o) => (r(), h("div", {
|
|
259
|
-
ref_key: "flowChart",
|
|
260
|
-
ref: j,
|
|
261
|
-
class: ue(`vue-ui-flow ${N.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
|
|
262
|
-
style: C(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;${e.value.style.chart.title.text ? "" : "padding-top:36px"};background:${e.value.style.chart.backgroundColor}`),
|
|
263
|
-
id: `flow_${S.value}`
|
|
264
|
-
}, [
|
|
265
|
-
e.value.style.chart.title.text ? (r(), h("div", {
|
|
266
|
-
key: 0,
|
|
267
|
-
style: C(`width:100%;background:${e.value.style.chart.backgroundColor};padding-bottom:24px`)
|
|
268
|
-
}, [
|
|
269
|
-
re(Ve, {
|
|
270
|
-
config: {
|
|
271
|
-
title: {
|
|
272
|
-
cy: "flow-title",
|
|
273
|
-
...e.value.style.chart.title
|
|
274
|
-
},
|
|
275
|
-
subtitle: {
|
|
276
|
-
cy: "flow-subtitle",
|
|
277
|
-
...e.value.style.chart.title.subtitle
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
|
-
}, null, 8, ["config"])
|
|
281
|
-
], 4)) : T("", !0),
|
|
282
|
-
e.value.userOptions.show && M.value ? (r(), A(Xe, {
|
|
283
|
-
ref: "details",
|
|
284
|
-
key: `user_option_${X.value}`,
|
|
285
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
286
|
-
color: e.value.style.chart.color,
|
|
287
|
-
isPrinting: i(W),
|
|
288
|
-
isImaging: i(q),
|
|
289
|
-
uid: S.value,
|
|
290
|
-
hasPdf: e.value.userOptions.buttons.pdf,
|
|
291
|
-
hasXls: e.value.userOptions.buttons.csv,
|
|
292
|
-
hasImg: e.value.userOptions.buttons.img,
|
|
293
|
-
hasTable: e.value.userOptions.buttons.table,
|
|
294
|
-
hasFullscreen: e.value.userOptions.buttons.fullscreen,
|
|
295
|
-
isFullscreen: N.value,
|
|
296
|
-
titles: { ...e.value.userOptions.buttonTitles },
|
|
297
|
-
chartElement: j.value,
|
|
298
|
-
onToggleFullscreen: be,
|
|
299
|
-
onGeneratePdf: i(R),
|
|
300
|
-
onGenerateCsv: te,
|
|
301
|
-
onGenerateImage: i(Z),
|
|
302
|
-
onToggleTable: le
|
|
303
|
-
}, Ie({ _: 2 }, [
|
|
304
|
-
l.$slots.optionPdf ? {
|
|
305
|
-
name: "optionPdf",
|
|
306
|
-
fn: y(() => [
|
|
307
|
-
x(l.$slots, "optionPdf", {}, void 0, !0)
|
|
308
|
-
]),
|
|
309
|
-
key: "0"
|
|
310
|
-
} : void 0,
|
|
311
|
-
l.$slots.optionCsv ? {
|
|
312
|
-
name: "optionCsv",
|
|
313
|
-
fn: y(() => [
|
|
314
|
-
x(l.$slots, "optionCsv", {}, void 0, !0)
|
|
315
|
-
]),
|
|
316
|
-
key: "1"
|
|
317
|
-
} : void 0,
|
|
318
|
-
l.$slots.optionImg ? {
|
|
319
|
-
name: "optionImg",
|
|
320
|
-
fn: y(() => [
|
|
321
|
-
x(l.$slots, "optionImg", {}, void 0, !0)
|
|
322
|
-
]),
|
|
323
|
-
key: "2"
|
|
324
|
-
} : void 0,
|
|
325
|
-
l.$slots.optionTable ? {
|
|
326
|
-
name: "optionTable",
|
|
327
|
-
fn: y(() => [
|
|
328
|
-
x(l.$slots, "optionTable", {}, void 0, !0)
|
|
329
|
-
]),
|
|
330
|
-
key: "3"
|
|
331
|
-
} : void 0,
|
|
332
|
-
l.$slots.optionFullscreen ? {
|
|
333
|
-
name: "optionFullscreen",
|
|
334
|
-
fn: y(({ toggleFullscreen: t, isFullscreen: n }) => [
|
|
335
|
-
x(l.$slots, "optionFullscreen", ie(ce({ toggleFullscreen: t, isFullscreen: n })), void 0, !0)
|
|
336
|
-
]),
|
|
337
|
-
key: "4"
|
|
338
|
-
} : void 0
|
|
339
|
-
]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasXls", "hasImg", "hasTable", "hasFullscreen", "isFullscreen", "titles", "chartElement", "onGeneratePdf", "onGenerateImage"])) : T("", !0),
|
|
340
|
-
(r(), h("svg", {
|
|
341
|
-
xmlns: i(De),
|
|
342
|
-
viewBox: `0 0 ${D.value.width} ${D.value.height}`,
|
|
343
|
-
class: ue({ "vue-data-ui-fullscreen--on": N.value, "vue-data-ui-fulscreen--off": !N.value }),
|
|
344
|
-
style: C(`max-width:100%; overflow: visible; background:${e.value.style.chart.backgroundColor};color:${e.value.style.chart.color}`)
|
|
345
|
-
}, [
|
|
346
|
-
O("defs", null, [
|
|
347
|
-
(r(!0), h(P, null, F(p.value.links, (t, n) => (r(), h("linearGradient", {
|
|
348
|
-
id: t.id,
|
|
349
|
-
x1: "0%",
|
|
350
|
-
y1: "0%",
|
|
351
|
-
x2: "100%",
|
|
352
|
-
y2: "0%"
|
|
353
|
-
}, [
|
|
354
|
-
O("stop", {
|
|
355
|
-
offset: "0%",
|
|
356
|
-
"stop-color": t.sourceColor
|
|
357
|
-
}, null, 8, et),
|
|
358
|
-
O("stop", {
|
|
359
|
-
offset: "100%",
|
|
360
|
-
"stop-color": t.targetColor
|
|
361
|
-
}, null, 8, tt)
|
|
362
|
-
], 8, Qe))), 256))
|
|
363
|
-
]),
|
|
364
|
-
(r(!0), h(P, null, F(p.value.links, (t) => (r(), h("path", {
|
|
365
|
-
class: "vue-ui-flow-link",
|
|
366
|
-
d: t.path,
|
|
367
|
-
fill: `url(#${t.id})`,
|
|
368
|
-
stroke: e.value.style.chart.links.stroke,
|
|
369
|
-
"stroke-width": e.value.style.chart.links.strokeWidth,
|
|
370
|
-
style: C(`opacity:${H.value ? [t.target, t.source].includes(H.value) ? 1 : 0.3 : e.value.style.chart.links.opacity}`)
|
|
371
|
-
}, null, 12, lt))), 256)),
|
|
372
|
-
(r(!0), h(P, null, F(p.value.nodes, (t, n) => (r(), h("rect", {
|
|
373
|
-
class: "vue-ui-flow-node",
|
|
374
|
-
x: t.x,
|
|
375
|
-
y: i(v)(t.absoluteY),
|
|
376
|
-
height: i(v)(t.height),
|
|
377
|
-
width: $.value,
|
|
378
|
-
fill: t.color,
|
|
379
|
-
stroke: e.value.style.chart.nodes.stroke,
|
|
380
|
-
"stroke-width": e.value.style.chart.nodes.strokeWidth,
|
|
381
|
-
onMouseenter: (a) => _e(t),
|
|
382
|
-
onMouseleave: o[0] || (o[0] = (a) => Ne()),
|
|
383
|
-
style: C(`opacity:${b.value ? b.value.includes(t.name) ? 1 : 0.2 : 1}`)
|
|
384
|
-
}, null, 44, ot))), 256)),
|
|
385
|
-
(r(!0), h(P, null, F(p.value.nodes, (t, n) => (r(), h("text", {
|
|
386
|
-
x: t.x + $.value / 2,
|
|
387
|
-
y: i(v)(t.absoluteY + t.height / 2 - e.value.style.chart.nodes.labels.fontSize / 4),
|
|
388
|
-
"font-size": e.value.style.chart.nodes.labels.fontSize,
|
|
389
|
-
fill: i(fe)(t.color),
|
|
390
|
-
"text-anchor": "middle",
|
|
391
|
-
style: C(`pointer-events: none; opacity:${b.value ? b.value.includes(t.name) ? 1 : 0 : 1}`)
|
|
392
|
-
}, U(e.value.style.chart.nodes.labels.abbreviation.use ? i(Ge)({ source: t.name, length: e.value.style.chart.nodes.labels.abbreviation.length }) : t.name), 13, at))), 256)),
|
|
393
|
-
(r(!0), h(P, null, F(p.value.nodes, (t, n) => (r(), h("text", {
|
|
394
|
-
x: t.x + $.value / 2,
|
|
395
|
-
y: i(v)(t.absoluteY + t.height / 2 + e.value.style.chart.nodes.labels.fontSize),
|
|
396
|
-
"font-size": e.value.style.chart.nodes.labels.fontSize,
|
|
397
|
-
fill: i(fe)(t.color),
|
|
398
|
-
"text-anchor": "middle",
|
|
399
|
-
style: C(`pointer-events: none; opacity:${b.value ? b.value.includes(t.name) ? 1 : 0 : 1}`)
|
|
400
|
-
}, U(i(Be)(
|
|
401
|
-
e.value.style.chart.nodes.labels.formatter,
|
|
402
|
-
t.value,
|
|
403
|
-
i(ve)({
|
|
404
|
-
p: e.value.style.chart.nodes.labels.prefix,
|
|
405
|
-
v: t.value,
|
|
406
|
-
s: e.value.style.chart.nodes.labels.suffix,
|
|
407
|
-
r: e.value.style.chart.nodes.labels.rounding
|
|
408
|
-
}),
|
|
409
|
-
{ datapoint: t, seriesIndex: n }
|
|
410
|
-
)), 13, nt))), 256)),
|
|
411
|
-
x(l.$slots, "svg", { svg: D.value }, void 0, !0)
|
|
412
|
-
], 14, Ke)),
|
|
413
|
-
l.$slots.watermark ? (r(), h("div", st, [
|
|
414
|
-
x(l.$slots, "watermark", ie(ce({ isPrinting: i(W) || i(q) })), void 0, !0)
|
|
415
|
-
])) : T("", !0),
|
|
416
|
-
M.value ? T("", !0) : (r(), A(Re, {
|
|
417
|
-
key: 3,
|
|
418
|
-
config: {
|
|
419
|
-
type: "flow",
|
|
420
|
-
style: {
|
|
421
|
-
backgroundColor: e.value.style.chart.backgroundColor
|
|
422
|
-
}
|
|
423
|
-
}
|
|
424
|
-
}, null, 8, ["config"])),
|
|
425
|
-
M.value ? (r(), A(qe, {
|
|
426
|
-
key: 4,
|
|
427
|
-
hideDetails: "",
|
|
428
|
-
config: {
|
|
429
|
-
open: I.value.showTable,
|
|
430
|
-
maxHeight: 1e4,
|
|
431
|
-
body: {
|
|
432
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
433
|
-
color: e.value.style.chart.color
|
|
434
|
-
},
|
|
435
|
-
head: {
|
|
436
|
-
backgroundColor: e.value.style.chart.backgroundColor,
|
|
437
|
-
color: e.value.style.chart.color
|
|
438
|
-
}
|
|
439
|
-
}
|
|
440
|
-
}, {
|
|
441
|
-
content: y(() => [
|
|
442
|
-
re(We, {
|
|
443
|
-
colNames: L.value.colNames,
|
|
444
|
-
head: L.value.head,
|
|
445
|
-
body: L.value.body,
|
|
446
|
-
config: L.value.config,
|
|
447
|
-
title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
|
|
448
|
-
onClose: o[1] || (o[1] = (t) => I.value.showTable = !1)
|
|
449
|
-
}, {
|
|
450
|
-
th: y(({ th: t }) => [
|
|
451
|
-
O("div", {
|
|
452
|
-
innerHTML: t,
|
|
453
|
-
style: { display: "flex", "align-items": "center" }
|
|
454
|
-
}, null, 8, ut)
|
|
455
|
-
]),
|
|
456
|
-
td: y(({ td: t }) => [
|
|
457
|
-
He(U(t.name || t), 1)
|
|
458
|
-
]),
|
|
459
|
-
_: 1
|
|
460
|
-
}, 8, ["colNames", "head", "body", "config", "title"])
|
|
461
|
-
]),
|
|
462
|
-
_: 1
|
|
463
|
-
}, 8, ["config"])) : T("", !0)
|
|
464
|
-
], 14, Je));
|
|
465
|
-
}
|
|
466
|
-
}, bt = /* @__PURE__ */ Ze(rt, [["__scopeId", "data-v-c5ae33a6"]]);
|
|
467
|
-
export {
|
|
468
|
-
bt as default
|
|
469
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=require("./index-D_32ZGWd.cjs"),ce=require("./Title-D5cATWsL.cjs"),W=require("./usePrinter-BouFNHWR.cjs"),ie=require("./DataTable-BNFSPjhv.cjs"),de=require("./vue-ui-accordion-Cka6b_Up.cjs"),he=require("./vue-ui-skeleton-fVPw-oIR.cjs"),X=require("./useNestedProp-BvvH633N.cjs"),ve=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),fe=["id"],me=["xmlns","viewBox"],pe=["id"],ge=["stop-color"],ke=["stop-color"],ye=["d","fill","stroke","stroke-width"],be=["x","y","height","width","fill","stroke","stroke-width","onMouseenter"],we=["x","y","font-size","fill"],Ne=["x","y","font-size","fill"],Ce={key:2,class:"vue-data-ui-watermark"},xe=["innerHTML"],$e={__name:"vue-ui-flow",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},setup(R,{expose:Z}){const v=R,{vue_ui_flow:J}=s.useConfig(),x=e.computed(()=>!!v.dataset&&v.dataset.length);e.onMounted(()=>{s.objectIsEmpty(v.dataset)&&s.error({componentName:"VueUiFlow",type:"dataset"})});const $=e.ref(s.createUid()),P=e.ref(null),F=e.ref(0),y=e.ref(!1);function K(o){y.value=o,F.value+=1}const t=e.computed(()=>{const o=X.useNestedProp({userConfig:v.config,defaultConfig:J});return o.theme?{...X.useNestedProp({userConfig:s.themes.vue_ui_flow[o.theme]||v.config,defaultConfig:o}),customPalette:s.themePalettes[o.theme]||s.palette}:o}),{isPrinting:L,isImaging:z,generatePdf:I,generateImage:H}=W.usePrinter({elementId:`flow_${$.value}`,fileName:t.value.style.chart.title.text||"vue-ui-flow"}),B=e.computed(()=>s.convertCustomPalette(t.value.customPalette)),O=e.computed(()=>t.value.style.chart.nodes.gap),g=e.computed(()=>t.value.style.chart.nodes.width),b=e.ref({showTable:t.value.table.show}),V=e.computed(()=>t.value.style.chart.links.width),_=e.computed(()=>!v.dataset||!v.dataset.length?[]:v.dataset.map(o=>[o[0],o[1],s.checkNaN(o[2])])),M=e.computed(()=>{const o={};function n(r){o[r]||(o[r]={inflow:0,outflow:0})}_.value.forEach(([r,a,i])=>{n(r),n(a),o[r].outflow+=i,o[a].inflow+=i});let l=0;for(const r in o){const a=Math.max(o[r].inflow,o[r].outflow);l=Math.max(l,a)}return l});function Q(o){return o/M.value*100+t.value.style.chart.nodes.minHeight}function ee(o){const n=t.value.style.chart.nodes.minHeight;return(o-n)/100*M.value}function te(o){const n={},l={};function r(u,c){n[u]||(n[u]={height:0,level:null,inflow:0,outflow:0}),n[u].level===null&&(n[u].level=c),l[c]||(l[c]=[]),l[c].includes(u)||l[c].push(u)}o.forEach(([u,c,h],k)=>{const p=n[u]?n[u].level:0,C=p+1;r(u,p),r(c,C),n[u].children||(n[u].children=[]),n[u].children.push({target:c,value:h}),n[u].outflow+=h,n[c].inflow+=h}),Object.keys(n).forEach((u,c)=>{n[u].color=B.value[c]||B.value[c%B.value.length]||s.palette[c]||s.palette[c%d.length]});for(const u in n)n[u].height=Q(Math.max(n[u].inflow,n[u].outflow)),n[u].name=u;const a={};for(const u in l){let c=0;l[u].forEach((h,k)=>{const p=n[h].height;a[h]={x:parseInt(u,10)*V.value+t.value.style.chart.padding.left,y:c,absoluteY:c,height:p,i:k,color:n[h].color,value:ee(p)},c+=p+O.value})}const i=[];for(const u in n){let c=a[u].absoluteY;n[u].children&&n[u].children.forEach(({target:h,value:k},p)=>{const C=a[h].y,S=a[u],T=a[h],G=s.checkNaN(c),U=s.checkNaN(c+k/n[u].outflow*S.height),j=s.checkNaN(C),A=s.checkNaN(C+k/n[h].inflow*T.height),ue={id:s.createUid(),source:u,target:h,path:`M ${s.checkNaN(S.x)+s.checkNaN(g.value)} ${G} L ${s.checkNaN(S.x)+s.checkNaN(g.value)} ${U} L ${s.checkNaN(T.x)} ${A} L ${s.checkNaN(T.x)} ${j} Z`,value:k,sourceColor:n[u].color,targetColor:n[h].color};i.push(ue),c+=U-G,a[h].y+=A-j})}return{nodeCoordinates:a,links:i}}const f=e.computed(()=>{const o=te(v.dataset);return{nodes:Object.keys(o.nodeCoordinates).map((n,l)=>({...o.nodeCoordinates[n],name:n})),links:o.links}}),le=e.computed(()=>oe(f.value.nodes));function oe(o){const n={};for(const r in o){const{x:a,height:i}=o[r];n[a]||(n[a]=0),n[a]+=i+O.value}return Math.max(...Object.values(n))}const E=e.computed(()=>{const{top:o,right:n,left:l,bottom:r}=t.value.style.chart.padding,a=_.value.length*V.value;return{height:le.value+o+r,width:n+Math.max(...f.value.nodes.map(i=>i.x))+g.value,left:l,top:o,right:a-n,p_top:o,p_bottom:r}});function ne(o){const n={},l={},r=new Set;return _.value.forEach(([a,i,u])=>{n[a]||(n[a]=[]),l[i]||(l[i]=[]),n[a].push(i),l[i].push(a)}),n[o]&&n[o].forEach(a=>r.add(a)),l[o]&&l[o].forEach(a=>r.add(a)),Array.from(r).concat(o)}const m=e.ref(null),w=e.ref(null);function ae(o){m.value=ne(o.name),w.value=o.name}function se(){m.value=null,w.value=null}const D=e.computed(()=>f.value.links.map(({source:o,target:n,sourceColor:l,targetColor:r,value:a})=>({source:o,target:n,sourceColor:l,targetColor:r,value:a})));function Y(){e.nextTick(()=>{const o=D.value.map((r,a)=>[[r.source],[r.target],[r.value]]),n=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[t.value.table.columnNames.source],[t.value.table.columnNames.target],[t.value.table.columnNames.value]]].concat(o),l=s.createCsvContent(n);s.downloadCsv({csvContent:l,title:t.value.style.chart.title.text||"vue-ui-flow"})})}const N=e.computed(()=>{const o=[t.value.table.columnNames.source,t.value.table.columnNames.target,t.value.table.columnNames.value],n=D.value.map((a,i)=>[{color:a.sourceColor,name:a.source},{color:a.targetColor,name:a.target},s.dataLabel({p:t.value.style.chart.nodes.labels.prefix,v:a.value,s:t.value.style.chart.nodes.labels.suffix,r:t.value.style.chart.nodes.labels.rounding})]),l={th:{backgroundColor:t.value.table.th.backgroundColor,color:t.value.table.th.color,outline:t.value.table.th.outline},td:{backgroundColor:t.value.table.td.backgroundColor,color:t.value.table.td.color,outline:t.value.table.td.outline},breakpoint:t.value.table.responsiveBreakpoint};return{colNames:[t.value.table.columnNames.source,t.value.table.columnNames.target,t.value.table.columnNames.value],head:o,body:n,config:l}});function re(){return f.value}function q(){b.value.showTable=!b.value.showTable}return Z({getData:re,generateCsv:Y,generateImage:H,generatePdf:I,toggleTable:q}),(o,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"flowChart",ref:P,class:e.normalizeClass(`vue-ui-flow ${y.value?"vue-data-ui-wrapper-fullscreen":""}`),style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;${t.value.style.chart.title.text?"":"padding-top:36px"};background:${t.value.style.chart.backgroundColor}`),id:`flow_${$.value}`},[t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:24px`)},[e.createVNode(ce._sfc_main,{config:{title:{cy:"flow-title",...t.value.style.chart.title},subtitle:{cy:"flow-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"])],4)):e.createCommentVNode("",!0),t.value.userOptions.show&&x.value?(e.openBlock(),e.createBlock(W.UserOptions,{ref:"details",key:`user_option_${F.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(L),isImaging:e.unref(z),uid:$.value,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:y.value,titles:{...t.value.userOptions.buttonTitles},chartElement:P.value,onToggleFullscreen:K,onGeneratePdf:e.unref(I),onGenerateCsv:Y,onGenerateImage:e.unref(H),onToggleTable:q},e.createSlots({_:2},[o.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,o.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,o.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,o.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,o.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:r})=>[e.renderSlot(o.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:r})),void 0,!0)]),key:"4"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{xmlns:e.unref(s.XMLNS),viewBox:`0 0 ${E.value.width} ${E.value.height}`,class:e.normalizeClass({"vue-data-ui-fullscreen--on":y.value,"vue-data-ui-fulscreen--off":!y.value}),style:e.normalizeStyle(`max-width:100%; overflow: visible; background:${t.value.style.chart.backgroundColor};color:${t.value.style.chart.color}`)},[e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value.links,(l,r)=>(e.openBlock(),e.createElementBlock("linearGradient",{id:l.id,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[e.createElementVNode("stop",{offset:"0%","stop-color":l.sourceColor},null,8,ge),e.createElementVNode("stop",{offset:"100%","stop-color":l.targetColor},null,8,ke)],8,pe))),256))]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value.links,l=>(e.openBlock(),e.createElementBlock("path",{class:"vue-ui-flow-link",d:l.path,fill:`url(#${l.id})`,stroke:t.value.style.chart.links.stroke,"stroke-width":t.value.style.chart.links.strokeWidth,style:e.normalizeStyle(`opacity:${w.value?[l.target,l.source].includes(w.value)?1:.3:t.value.style.chart.links.opacity}`)},null,12,ye))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value.nodes,(l,r)=>(e.openBlock(),e.createElementBlock("rect",{class:"vue-ui-flow-node",x:l.x,y:e.unref(s.checkNaN)(l.absoluteY),height:e.unref(s.checkNaN)(l.height),width:g.value,fill:l.color,stroke:t.value.style.chart.nodes.stroke,"stroke-width":t.value.style.chart.nodes.strokeWidth,onMouseenter:a=>ae(l),onMouseleave:n[0]||(n[0]=a=>se()),style:e.normalizeStyle(`opacity:${m.value?m.value.includes(l.name)?1:.2:1}`)},null,44,be))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value.nodes,(l,r)=>(e.openBlock(),e.createElementBlock("text",{x:l.x+g.value/2,y:e.unref(s.checkNaN)(l.absoluteY+l.height/2-t.value.style.chart.nodes.labels.fontSize/4),"font-size":t.value.style.chart.nodes.labels.fontSize,fill:e.unref(s.adaptColorToBackground)(l.color),"text-anchor":"middle",style:e.normalizeStyle(`pointer-events: none; opacity:${m.value?m.value.includes(l.name)?1:0:1}`)},e.toDisplayString(t.value.style.chart.nodes.labels.abbreviation.use?e.unref(s.abbreviate)({source:l.name,length:t.value.style.chart.nodes.labels.abbreviation.length}):l.name),13,we))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value.nodes,(l,r)=>(e.openBlock(),e.createElementBlock("text",{x:l.x+g.value/2,y:e.unref(s.checkNaN)(l.absoluteY+l.height/2+t.value.style.chart.nodes.labels.fontSize),"font-size":t.value.style.chart.nodes.labels.fontSize,fill:e.unref(s.adaptColorToBackground)(l.color),"text-anchor":"middle",style:e.normalizeStyle(`pointer-events: none; opacity:${m.value?m.value.includes(l.name)?1:0:1}`)},e.toDisplayString(e.unref(s.applyDataLabel)(t.value.style.chart.nodes.labels.formatter,l.value,e.unref(s.dataLabel)({p:t.value.style.chart.nodes.labels.prefix,v:l.value,s:t.value.style.chart.nodes.labels.suffix,r:t.value.style.chart.nodes.labels.rounding}),{datapoint:l,seriesIndex:r})),13,Ne))),256)),e.renderSlot(o.$slots,"svg",{svg:E.value},void 0,!0)],14,me)),o.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Ce,[e.renderSlot(o.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(L)||e.unref(z)})),void 0,!0)])):e.createCommentVNode("",!0),x.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(he.default,{key:3,config:{type:"flow",style:{backgroundColor:t.value.style.chart.backgroundColor}}},null,8,["config"])),x.value?(e.openBlock(),e.createBlock(de.default,{key:4,hideDetails:"",config:{open:b.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:e.withCtx(()=>[e.createVNode(ie.DataTable,{colNames:N.value.colNames,head:N.value.head,body:N.value.body,config:N.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:n[1]||(n[1]=l=>b.value.showTable=!1)},{th:e.withCtx(({th:l})=>[e.createElementVNode("div",{innerHTML:l,style:{display:"flex","align-items":"center"}},null,8,xe)]),td:e.withCtx(({td:l})=>[e.createTextVNode(e.toDisplayString(l.name||l),1)]),_:1},8,["colNames","head","body","config","title"])]),_:1},8,["config"])):e.createCommentVNode("",!0)],14,fe))}},Be=ve._export_sfc($e,[["__scopeId","data-v-c5ae33a6"]]);exports.default=Be;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-D_32ZGWd.cjs"),K=require("./Legend-Do2kcWFT.cjs"),Q=require("./Title-D5cATWsL.cjs"),Z=require("./Tooltip-B8yLaegk.cjs"),ee=require("./DataTable-BNFSPjhv.cjs"),D=require("./usePrinter-BouFNHWR.cjs"),te=require("./vue-ui-skeleton-fVPw-oIR.cjs"),le=require("./vue-ui-accordion-Cka6b_Up.cjs"),q=require("./useNestedProp-BvvH633N.cjs"),oe=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),ae=["id"],re=["xmlns","viewBox"],se=["id"],ne=["stdDeviation"],ue=["d","stroke","stroke-width"],ie=["d","stroke","stroke-width"],ce=["filter"],de=["d","stroke","stroke-width"],ve=["d","stroke-width","onMouseenter","onClick"],he={key:3,class:"vue-data-ui-watermark"},pe=["onClick"],ye={key:0},fe={key:1},ge=["innerHTML"],me={__name:"vue-ui-galaxy",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(G,{expose:M,emit:B}){const d=G,{vue_ui_galaxy:A}=r.useConfig(),b=e.computed(()=>!!d.dataset&&d.dataset.length);e.onMounted(()=>{r.objectIsEmpty(d.dataset)?r.error({componentName:"VueUiGalaxy",type:"dataset"}):d.dataset.forEach((l,a)=>{r.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","values"]}).forEach(o=>{r.error({componentName:"VueUiGalaxy",type:"datasetSerieAttribute",property:o,index:a})})})});const f=e.ref(r.createUid()),C=e.ref(null),W=e.ref(null),w=e.ref(!1),x=e.ref(""),i=e.ref(null),S=e.ref(0),t=e.computed(()=>{const l=q.useNestedProp({userConfig:d.config,defaultConfig:A});return l.theme?{...q.useNestedProp({userConfig:r.themes.vue_ui_galaxy[l.theme]||d.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}),{isPrinting:_,isImaging:P,generatePdf:L,generateImage:E}=D.usePrinter({elementId:`galaxy_${f.value}`,fileName:t.value.style.chart.title.text||"vue-ui-galaxy"}),U=e.computed(()=>r.convertCustomPalette(t.value.customPalette)),v=e.ref({dataLabels:{show:t.value.style.chart.layout.labels.dataLabels.show},showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),$=e.ref({height:180,width:250}),u=e.ref([]);function N(l){u.value.includes(l.id)?u.value=u.value.filter(a=>a!==l.id):u.value.push(l.id),B("selectLegend",g.value.map(a=>({name:a.name,color:a.color,value:a.value})))}const p=e.computed(()=>d.dataset.map((l,a)=>({name:l.name,color:r.convertColorToHex(l.color)||U.value[a]||r.palette[a]||r.palette[a%r.palette.length],value:l.values?r.sanitizeArray(l.values).reduce((o,s)=>o+s,0):0,absoluteValues:r.sanitizeArray(l.values),id:r.createUid(),seriesIndex:a})).sort((l,a)=>a.value-l.value));function H(){return p.value.map(l=>({name:l.name,color:l.color,value:l.value}))}const c=e.computed(()=>p.value.filter(l=>!u.value.includes(l.id)).map(l=>l.value).reduce((l,a)=>l+a,0)),R=e.ref(190),V=e.computed(()=>p.value.filter(l=>!u.value.includes(l.id))),g=e.computed(()=>{const l=[];for(let a=0;a<V.value.length;a+=1){const o=V.value[a];let s=o.value/c.value*R.value;a>0&&l.length&&(s+=l[a-1].points),l.push({points:s,...o,seriesIndex:a,proportion:o.value/c.value,path:r.createSpiralPath({points:s,startX:115+t.value.style.chart.layout.arcs.offsetX,startY:90+t.value.style.chart.layout.arcs.offsetY})})}return l.filter((a,o)=>!u.value.includes(a.id)).toSorted((a,o)=>o.points-a.points)}),m=e.ref(!1);function X(l){m.value=l,S.value+=1}const T=e.ref(null);function j({datapoint:l,_relativeIndex:a,seriesIndex:o,show:s=!1}){T.value={datapoint:l,seriesIndex:o,series:p.value,config:t.value},w.value=s,i.value=l.id;let n="";const y=t.value.style.chart.tooltip.customFormat;r.isFunction(y)&&r.functionReturnsString(()=>y({seriesIndex:o,datapoint:l,series:p.value,config:t.value}))?x.value=y({seriesIndex:o,datapoint:l,series:p.value,config:t.value}):(n+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${l.name}</div>`,n+=`<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${l.color}"/></svg>`,t.value.style.chart.tooltip.showValue&&(n+=`<b>${r.applyDataLabel(t.value.style.chart.layout.labels.dataLabels.formatter,l.value,r.dataLabel({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:l.value,s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.style.chart.tooltip.roundingValue}),{datapoint:l,seriesIndex:o})}</b>`),t.value.style.chart.tooltip.showPercentage&&(t.value.style.chart.tooltip.showValue?n+=`<span>(${r.dataLabel({v:l.proportion*100,s:"%",r:t.value.style.chart.tooltip.roundingPercentage})})</span></div>`:n+=`<b>${r.dataLabel({v:l.proportion*100,s:"%",r:t.value.style.chart.tooltip.roundingPercentage})}</b></div>`),x.value=`<div>${n}</div>`)}const F=e.computed(()=>p.value.map((l,a)=>({...l,proportion:(l.value||0)/d.dataset.map(o=>(o.values||[]).reduce((s,n)=>s+n,0)).reduce((o,s)=>o+s,0),opacity:u.value.includes(l.id)?.5:1,shape:l.shape||"circle",segregate:()=>N(l),isSegregated:u.value.includes(l.id)}))),Y=e.computed(()=>({cy:"galaxy-div-legend",backgroundColor:t.value.style.chart.legend.backgroundColor,color:t.value.style.chart.legend.color,fontSize:t.value.style.chart.legend.fontSize,paddingBottom:12,fontWeight:t.value.style.chart.legend.bold?"bold":""})),h=e.computed(()=>{const l=g.value.map(o=>({name:o.name,color:o.color})),a=g.value.map(o=>o.value);return{head:l,body:a}});function I(){e.nextTick(()=>{const l=h.value.head.map((s,n)=>[[s.name],[h.value.body[n]],[isNaN(h.value.body[n]/c.value)?"-":h.value.body[n]/c.value*100]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],["val"],["%"]]].concat(l),o=r.createCsvContent(a);r.downloadCsv({csvContent:o,title:t.value.style.chart.title.text||"vue-ui-galaxy"})})}const k=e.computed(()=>{const l=[' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>',r.dataLabel({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:c.value,s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.table.td.roundingValue}),"100%"],a=h.value.head.map((n,y)=>{const J=r.dataLabel({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:h.value.body[y],s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.table.td.roundingValue});return[{color:n.color,name:n.name},J,isNaN(h.value.body[y]/c.value)?"-":r.dataLabel({v:h.value.body[y]/c.value*100,s:"%",r:t.value.table.td.roundingPercentage})]}),o={th:{backgroundColor:t.value.table.th.backgroundColor,color:t.value.table.th.color,outline:t.value.table.th.outline},td:{backgroundColor:t.value.table.td.backgroundColor,color:t.value.table.td.color,outline:t.value.table.td.outline},breakpoint:t.value.table.responsiveBreakpoint};return{colNames:[t.value.table.columnNames.series,t.value.table.columnNames.value,t.value.table.columnNames.percentage],head:l,body:a,config:o}});function z(){v.value.showTable=!v.value.showTable}function O(){v.value.showTooltip=!v.value.showTooltip}return M({getData:H,generatePdf:L,generateCsv:I,generateImage:E,toggleTable:z,toggleTooltip:O}),(l,a)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"galaxyChart",ref:C,class:e.normalizeClass(`vue-ui-galaxy ${m.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;${t.value.style.chart.title.text?"":"padding-top:36px"};background:${t.value.style.chart.backgroundColor}`),id:`galaxy_${f.value}`},[t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:24px`)},[e.createVNode(Q._sfc_main,{config:{title:{cy:"galaxy-div-title",...t.value.style.chart.title},subtitle:{cy:"galaxy-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"])],4)):e.createCommentVNode("",!0),t.value.userOptions.show&&b.value?(e.openBlock(),e.createBlock(D.UserOptions,{ref_key:"details",ref:W,key:`user_option_${S.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(_),isImaging:e.unref(P),uid:f.value,hasTooltip:t.value.userOptions.buttons.tooltip&&t.value.style.chart.tooltip.show,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isTooltip:v.value.showTooltip,isFullscreen:m.value,titles:{...t.value.userOptions.buttonTitles},chartElement:C.value,onToggleFullscreen:X,onGeneratePdf:e.unref(L),onGenerateCsv:I,onGenerateImage:e.unref(E),onToggleTable:z,onToggleTooltip:O},e.createSlots({_:2},[l.$slots.optionTooltip?{name:"optionTooltip",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:o,isFullscreen:s})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:s})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","isTooltip","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),b.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(r.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":m.value,"vue-data-ui-fulscreen--off":!m.value}),viewBox:`0 0 ${$.value.width} ${$.value.height}`,style:e.normalizeStyle(`max-width:100%; overflow: visible; background:${t.value.style.chart.backgroundColor};color:${t.value.style.chart.color}`)},[e.createElementVNode("defs",null,[e.createElementVNode("filter",{id:`blur_${f.value}`,x:"-50%",y:"-50%",width:"200%",height:"200%"},[e.createElementVNode("feGaussianBlur",{in:"SourceGraphic",stdDeviation:100/t.value.style.chart.layout.arcs.gradient.intensity},null,8,ne)],8,se)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,o=>(e.openBlock(),e.createElementBlock("g",null,[o.value?(e.openBlock(),e.createElementBlock("path",{key:0,d:o.path,fill:"none",stroke:t.value.style.chart.backgroundColor,"stroke-width":(t.value.style.chart.layout.arcs.strokeWidth+t.value.style.chart.layout.arcs.borderWidth)*(i.value===o.id&&t.value.style.chart.layout.arcs.hoverEffect.show?t.value.style.chart.layout.arcs.hoverEffect.multiplicator:1),"stroke-linecap":"round"},null,8,ue)):e.createCommentVNode("",!0),o.value?(e.openBlock(),e.createElementBlock("path",{key:1,d:o.path,fill:"none",stroke:o.color,"stroke-width":t.value.style.chart.layout.arcs.strokeWidth*(i.value===o.id&&t.value.style.chart.layout.arcs.hoverEffect.show?t.value.style.chart.layout.arcs.hoverEffect.multiplicator:1),"stroke-linecap":"round",class:e.normalizeClass(`${i.value&&i.value!==o.id&&t.value.useBlurOnHover?"vue-ui-galaxy-blur":""}`)},null,10,ie)):e.createCommentVNode("",!0),o.value&&t.value.style.chart.layout.arcs.gradient.show?(e.openBlock(),e.createElementBlock("g",{key:2,filter:`url(#blur_${f.value})`},[e.createElementVNode("path",{d:o.path,fill:"none",stroke:t.value.style.chart.layout.arcs.gradient.color,"stroke-width":t.value.style.chart.layout.arcs.strokeWidth/2*(i.value===o.id&&t.value.style.chart.layout.arcs.hoverEffect.show?t.value.style.chart.layout.arcs.hoverEffect.multiplicator:1),"stroke-linecap":"round",class:e.normalizeClass(`vue-ui-galaxy-gradient ${i.value&&i.value!==o.id&&t.value.useBlurOnHover?"vue-ui-galaxy-blur":""}`)},null,10,de)],8,ce)):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(o,s)=>(e.openBlock(),e.createElementBlock("g",null,[o.value?(e.openBlock(),e.createElementBlock("path",{key:0,d:o.path,fill:"none",stroke:"transparent","stroke-width":t.value.style.chart.layout.arcs.strokeWidth+t.value.style.chart.layout.arcs.borderWidth,"stroke-linecap":"round",onMouseenter:n=>j({datapoint:o,relativeIndex:s,seriesIndex:o.seriesIndex,show:!0}),onMouseleave:a[0]||(a[0]=n=>{w.value=!1,i.value=null}),onClick:n=>B("selectDatapoint",o)},null,40,ve)):e.createCommentVNode("",!0)]))),256)),e.renderSlot(l.$slots,"svg",{svg:$.value},void 0,!0)],14,re)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",he,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(_)||e.unref(P)})),void 0,!0)])):e.createCommentVNode("",!0),b.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(te.default,{key:4,config:{type:"galaxy",style:{backgroundColor:t.value.style.chart.backgroundColor,galaxy:{color:"#CCCCCC"}}}},null,8,["config"])),t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(K.Legend,{key:5,legendSet:F.value,config:Y.value,onClickMarker:a[1]||(a[1]=({legend:o})=>N(o))},{item:e.withCtx(({legend:o,index:s})=>[e.createElementVNode("div",{onClick:n=>N(o),style:e.normalizeStyle(`opacity:${u.value.includes(o.id)?.5:1}`)},[e.createTextVNode(e.toDisplayString(o.name)+": "+e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.labels.dataLabels.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:o.value,s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.style.chart.legend.roundingValue}),{datapoint:o,seriesIndex:s}))+" ",1),u.value.includes(o.id)?(e.openBlock(),e.createElementBlock("span",fe," ( - % ) ")):(e.openBlock(),e.createElementBlock("span",ye," ("+e.toDisplayString(isNaN(o.value/c.value)?"-":e.unref(r.dataLabel)({v:o.value/c.value*100,s:"%",r:t.value.style.chart.legend.roundingPercentage}))+") ",1))],12,pe)]),_:1},8,["legendSet","config"])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"legend",{legend:F.value},void 0,!0),e.createVNode(Z._sfc_main,{show:v.value.showTooltip&&w.value,backgroundColor:t.value.style.chart.tooltip.backgroundColor,color:t.value.style.chart.tooltip.color,borderRadius:t.value.style.chart.tooltip.borderRadius,borderColor:t.value.style.chart.tooltip.borderColor,borderWidth:t.value.style.chart.tooltip.borderWidth,fontSize:t.value.style.chart.tooltip.fontSize,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,position:t.value.style.chart.tooltip.position,offsetY:t.value.style.chart.tooltip.offsetY,parent:C.value,content:x.value,isCustom:e.unref(r.isFunction)(t.value.style.chart.tooltip.customFormat)},{"tooltip-before":e.withCtx(()=>[e.renderSlot(l.$slots,"tooltip-before",e.normalizeProps(e.guardReactiveProps({...T.value})),void 0,!0)]),"tooltip-after":e.withCtx(()=>[e.renderSlot(l.$slots,"tooltip-after",e.normalizeProps(e.guardReactiveProps({...T.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","borderRadius","borderColor","borderWidth","fontSize","backgroundOpacity","position","offsetY","parent","content","isCustom"]),b.value?(e.openBlock(),e.createBlock(le.default,{key:6,hideDetails:"",config:{open:v.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:e.withCtx(()=>[e.createVNode(ee.DataTable,{colNames:k.value.colNames,head:k.value.head,body:k.value.body,config:k.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:a[2]||(a[2]=o=>v.value.showTable=!1)},{th:e.withCtx(({th:o})=>[e.createElementVNode("div",{innerHTML:o,style:{display:"flex","align-items":"center"}},null,8,ge)]),td:e.withCtx(({td:o})=>[e.createTextVNode(e.toDisplayString(o.name||o),1)]),_:1},8,["colNames","head","body","config","title"])]),_:1},8,["config"])):e.createCommentVNode("",!0)],14,ae))}},be=oe._export_sfc(me,[["__scopeId","data-v-57d0334c"]]);exports.default=be;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-D_32ZGWd.cjs"),O=require("./useResponsive-B3TrDDIG.cjs"),X=require("./usePrinter-BouFNHWR.cjs"),T=require("./vue-ui-skeleton-fVPw-oIR.cjs"),H=require("./Title-D5cATWsL.cjs"),Y=require("./useNestedProp-BvvH633N.cjs"),Z=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),J=["id"],K={key:0},Q=["xmlns","viewBox"],ee=["id"],te=["stop-color"],ae=["stop-color"],le=["stop-color"],re=["id"],oe=["stdDeviation"],ne=["d","fill","stroke"],se=["d","filter"],ue=["y","width","height","fill"],ie=["x","y","text-anchor","font-size","font-weight","fill"],ce=["x","y","font-size","font-weight","fill"],de={key:1},ve=["x1","y1","x2","y2","stroke","stroke-width"],he=["x1","y1","x2","y2","stroke","stroke-width"],fe=["x1","y1","x2","y2","stroke-width","filter"],me={key:2},ye=["d","fill","stroke","stroke-width"],pe=["cx","cy","fill","r","stroke-width","stroke"],ge=["x","y","font-size","fill"],ke={key:3,class:"vue-data-ui-watermark"},be={__name:"vue-ui-gauge",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(S,{expose:R}){const s=S,{vue_ui_gauge:D}=o.useConfig(),b=e.computed(()=>!!s.dataset&&Object.keys(s.dataset).length>0&&s.dataset.series&&s.dataset.series.length),h=e.ref(o.createUid()),G=e.ref(null),z=e.ref(0),_=e.ref(null),B=e.ref(null),N=e.ref(null),t=e.computed(()=>{const r=Y.useNestedProp({userConfig:s.config,defaultConfig:D});return r.theme?{...Y.useNestedProp({userConfig:o.themes.vue_ui_gauge[r.theme]||s.config,defaultConfig:r}),customPalette:o.themePalettes[r.theme]||o.palette}:r}),{isPrinting:E,isImaging:P,generatePdf:$,generateImage:M}=X.usePrinter({elementId:`vue-ui-gauge_${h.value}`,fileName:t.value.style.chart.title.text||"vue-ui-gauge"}),j=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),m=e.computed(()=>{if(!b.value||o.objectIsEmpty(s.dataset.series||{}))return{value:0,series:[{from:0,to:0}]};const r=[];(s.dataset.series||[]).forEach(l=>{r.push(l.from||0),r.push(l.to||0)});const n=Math.max(...r);return{...s.dataset,series:(s.dataset.series||[]).map((l,i)=>({...l,color:o.convertColorToHex(l.color)||j.value[i]||o.palette[i],value:((l.to||0)-(l.from||0))/n*100}))}}),v=e.ref(512),a=e.ref({height:358.4,width:v.value,top:0,bottom:358.4,centerX:179.2,centerY:v.value/2,labelFontSize:18,legendFontSize:t.value.style.chart.legend.fontSize,pointerRadius:t.value.style.chart.layout.pointer.circle.radius,trackSize:t.value.style.chart.layout.track.size,pointerSize:t.value.style.chart.layout.pointer.size,pointerStrokeWidth:t.value.style.chart.layout.pointer.strokeWidth,markerOffset:t.value.style.chart.layout.markers.offsetY+3}),g=e.ref(0),y=e.ref(0),d=e.ref(t.value.style.chart.animation.use?0:s.dataset.value);e.watch(()=>s.dataset.value,()=>{d.value=t.value.style.chart.animation.use?0:s.dataset.value,I()});const c=e.computed(()=>{const r=a.value.width/2,n=u.value.base,l=Math.PI*((d.value+0-y.value)/(g.value-y.value))+Math.PI;return{x1:r,y1:n,x2:r+u.value.pointerSize*a.value.pointerSize*.9*Math.cos(l),y2:n+u.value.pointerSize*a.value.pointerSize*.9*Math.sin(l)}}),V=e.computed(()=>{const r=a.value.width/2,n=u.value.base,l=Math.PI*((d.value+0-y.value)/(g.value-y.value))+Math.PI,i=r+u.value.pointerSize*a.value.pointerSize*.9*Math.cos(l),C=n+u.value.pointerSize*a.value.pointerSize*.9*Math.sin(l),f=a.value.pointerRadius,w=r+f*Math.cos(l+Math.PI/2),q=n+f*Math.sin(l+Math.PI/2),U=r+f*Math.cos(l-Math.PI/2),W=n+f*Math.sin(l-Math.PI/2);return isNaN(i)?null:`M ${i},${C} ${w},${q} ${U},${W} Z`}),F=e.computed(()=>{for(let r=0;r<m.value.series.length;r+=1){const{color:n,from:l,to:i}=m.value.series[r];if(d.value>=l&&d.value<=i)return n}return"#2D353C"}),x=e.ref(null);e.onMounted(()=>{if(o.objectIsEmpty(s.dataset)?o.error({componentName:"VueUiGauge",type:"dataset"}):(o.getMissingDatasetAttributes({datasetObject:s.dataset,requiredAttributes:["value","series"]}).forEach(r=>{o.error({componentName:"VueUiGauge",type:"datasetAttribute",property:r})}),Object.hasOwn(s.dataset,"series")&&(s.dataset.series.length?s.dataset.series.forEach((r,n)=>{o.getMissingDatasetAttributes({datasetObject:r,requiredAttributes:["from","to"]}).forEach(l=>{o.error({componentName:"VueUiGauge",type:"datasetSerieAttribute",property:l,index:n})})}):o.error({componentName:"VueUiGauge",type:"datasetAttributeEmpty",property:"series"}))),I(),t.value.responsive){const r=O.throttle(()=>{const{width:n,height:l}=O.useResponsive({chart:_.value,title:t.value.style.chart.title.text?B.value:null,legend:N.value});a.value.width=n,a.value.height=l,a.value.centerX=n/2,a.value.centerY=v.value/2/358.4*l,a.value.bottom=l,a.value.labelFontSize=18/v.value*Math.min(l,n)<10?10:18/v.value*Math.min(l,n),a.value.legendFontSize=t.value.style.chart.legend.fontSize/v.value*Math.min(l,n)<14?14:t.value.style.chart.legend.fontSize/v.value*Math.min(l,n),a.value.pointerRadius=t.value.style.chart.layout.pointer.circle.radius/v.value*Math.min(l,n),a.value.trackSize=t.value.style.chart.layout.track.size/v.value*Math.min(l,n),a.value.pointerStrokeWidth=o.translateSize({relator:Math.min(n,l),adjuster:v.value,source:t.value.style.chart.layout.pointer.strokeWidth,threshold:2,fallback:2}),a.value.markerOffset=o.translateSize({relator:Math.max(n,l),adjuster:v.value,source:t.value.style.chart.layout.markers.offsetY+3,threshold:2,fallback:2})});x.value=new ResizeObserver(r),x.value.observe(_.value.parentNode)}}),e.onBeforeUnmount(()=>{x.value&&x.value.disconnect()});function I(){const r=[];(m.value.series||[]).forEach(w=>{r.push(w.from||0),r.push(w.to||0)}),g.value=Math.max(...r),y.value=Math.min(...r);const n=String(g.value).length;let l=0,i=(n>2?.01:.001)*t.value.style.chart.animation.speed,C=(n>2?.05:.005)*t.value.style.chart.animation.acceleration;function f(){d.value+=i+l,l+=C,d.value<s.dataset.value?requestAnimationFrame(f):d.value=s.dataset.value}t.value.style.chart.animation.use&&(d.value=y.value,f())}const u=e.computed(()=>{const r=t.value.responsive?Math.min(a.value.width,a.value.height):a.value.width;return{arcs:r/2.5,gradients:r/2.75,base:t.value.responsive?a.value.height/2:a.value.height*.7,ratingBase:t.value.responsive?a.value.height/2+a.value.height/4:a.value.height*.9,pointerSize:t.value.responsive?Math.min(a.value.width,a.value.height)/3:a.value.width/3.2}}),p=e.computed(()=>o.makeDonut({series:m.value.series},a.value.width/2,u.value.base,u.value.arcs,u.value.arcs,1,1,1,180,109.9495,40*a.value.trackSize)),A=e.computed(()=>o.makeDonut({series:m.value.series},a.value.width/2,u.value.base,u.value.gradients,u.value.gradients,1,1,1,180,109.9495,2*a.value.trackSize)),k=e.ref(!1);function L(r){k.value=r,z.value+=1}return R({generatePdf:$,generateImage:M}),(r,n)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-gauge ${k.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"gaugeChart",ref:_,id:`vue-ui-gauge_${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor};${t.value.responsive?"height: 100%":""}`)},[t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:B,style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:12px`)},[e.createVNode(H._sfc_main,{config:{title:{cy:"gauge-div-title",...t.value.style.chart.title},subtitle:{cy:"gauge-div-subtitle",...t.value.style.chart.title.subtitle}}},{default:e.withCtx(()=>[t.value.translations.base&&S.dataset.base?(e.openBlock(),e.createElementBlock("span",K,e.toDisplayString(t.value.translations.base)+": "+e.toDisplayString(S.dataset.base),1)):e.createCommentVNode("",!0)]),_:1},8,["config"])],4)):e.createCommentVNode("",!0),t.value.userOptions.show&&b.value?(e.openBlock(),e.createBlock(X.UserOptions,{ref_key:"details",ref:G,key:`user_options_${z.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(P),isPrinting:e.unref(E),uid:h.value,hasXls:!1,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:k.value,titles:{...t.value.userOptions.buttonTitles},chartElement:_.value,onToggleFullscreen:L,onGeneratePdf:e.unref($),onGenerateImage:e.unref(M)},e.createSlots({_:2},[r.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(r.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,r.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(r.$slots,"optionImg",{},void 0,!0)]),key:"1"}:void 0,r.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:i})=>[e.renderSlot(r.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:i})),void 0,!0)]),key:"2"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasFullscreen","isFullscreen","titles","chartElement","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),b.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(o.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":k.value,"vue-data-ui-fulscreen--off":!k.value}),viewBox:`0 0 ${a.value.width<=0?10:a.value.width} ${a.value.height<=0?10:a.value.height}`,style:e.normalizeStyle(`max-width:100%;overflow:hidden !important;background:${t.value.style.chart.backgroundColor};color:${t.value.style.chart.color}`)},[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{id:`gradient_${h.value}`,cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`#FFFFFF${e.unref(o.opacity)[1]}`},null,8,te),e.createElementVNode("stop",{offset:"80%","stop-color":`#FFFFFF${e.unref(o.opacity)[t.value.style.chart.layout.track.gradientIntensity]}`},null,8,ae),e.createElementVNode("stop",{offset:"100%","stop-color":`#FFFFFF${e.unref(o.opacity)[1]}`},null,8,le)],8,ee)]),e.createElementVNode("defs",null,[e.createElementVNode("filter",{id:`blur_${h.value}`,x:"-50%",y:"-50%",width:"200%",height:"200%"},[e.createElementVNode("feGaussianBlur",{in:"SourceGraphic",stdDeviation:100/t.value.style.chart.layout.track.gradientIntensity},null,8,oe)],8,re)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(l,i)=>(e.openBlock(),e.createElementBlock("path",{key:`arc_${i}`,d:l.arcSlice,fill:l.color,stroke:t.value.style.chart.backgroundColor,"stroke-linecap":"round"},null,8,ne))),128)),t.value.style.chart.layout.track.useGradient?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(A.value,(l,i)=>(e.openBlock(),e.createElementBlock("path",{key:`arc_${i}`,d:l.arcSlice,fill:"#FFFFFF",stroke:"none","stroke-linecap":"round",filter:`url(#blur_${h.value})`},null,8,se))),128)),e.createElementVNode("rect",{x:0,y:u.value.base,width:a.value.width<=0?1e-4:a.value.width,height:a.value.height*.3<=0?1e-4:a.value.height*.3,fill:t.value.style.chart.backgroundColor},null,8,ue)],64)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(l,i)=>(e.openBlock(),e.createElementBlock("text",{x:e.unref(o.offsetFromCenterPoint)({centerX:a.value.width/2,centerY:u.value.base,initX:l.center.startX,initY:l.center.startY,offset:a.value.markerOffset}).x,y:e.unref(o.offsetFromCenterPoint)({centerX:a.value.width/2,centerY:u.value.base,initX:l.center.startX,initY:l.center.startY,offset:a.value.markerOffset}).y,"text-anchor":l.center.startX<a.value.width/2-5?"end":l.center.startX>a.value.width/2+5?"start":"middle","font-size":a.value.labelFontSize*t.value.style.chart.layout.markers.fontSizeRatio,"font-weight":`${t.value.style.chart.layout.markers.bold?"bold":"normal"}`,fill:t.value.style.chart.layout.markers.color},e.toDisplayString(l.from.toFixed(t.value.style.chart.layout.markers.roundingValue)),9,ie))),256)),e.createElementVNode("text",{x:e.unref(o.offsetFromCenterPoint)({centerX:a.value.width/2,centerY:u.value.base,initX:p.value.at(-1).endX,initY:p.value.at(-1).endY,offset:a.value.markerOffset}).x,y:e.unref(o.offsetFromCenterPoint)({centerX:a.value.width/2,centerY:u.value.base,initX:p.value.at(-1).endX,initY:p.value.at(-1).endY,offset:a.value.markerOffset}).y,"text-anchor":"start","font-size":a.value.labelFontSize*t.value.style.chart.layout.markers.fontSizeRatio,"font-weight":`${t.value.style.chart.layout.markers.bold?"bold":"normal"}`,fill:t.value.style.chart.layout.markers.color},e.toDisplayString(g.value.toFixed(t.value.style.chart.layout.markers.roundingValue)),9,ce),t.value.style.chart.layout.pointer.type==="rounded"?(e.openBlock(),e.createElementBlock("g",de,[isNaN(c.value.x2)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("line",{key:0,x1:c.value.x1,y1:c.value.y1,x2:c.value.x2,y2:c.value.y2,stroke:t.value.style.chart.layout.pointer.stroke,"stroke-width":a.value.pointerStrokeWidth,"stroke-linecap":"round"},null,8,ve)),isNaN(c.value.x2)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("line",{key:1,x1:c.value.x1,y1:c.value.y1,x2:c.value.x2,y2:c.value.y2,stroke:t.value.style.chart.layout.pointer.useRatingColor?F.value:t.value.style.chart.layout.pointer.color,"stroke-linecap":"round","stroke-width":a.value.pointerStrokeWidth*.7},null,8,he)),!isNaN(c.value.x2)&&t.value.style.chart.layout.track.useGradient?(e.openBlock(),e.createElementBlock("line",{key:2,x1:c.value.x1,y1:c.value.y1,x2:c.value.x2,y2:c.value.y2,stroke:"white","stroke-linecap":"round","stroke-width":a.value.pointerStrokeWidth*.3,filter:`url(#blur_${h.value})`},null,8,fe)):e.createCommentVNode("",!0)])):(e.openBlock(),e.createElementBlock("g",me,[V.value?(e.openBlock(),e.createElementBlock("path",{key:0,d:V.value,fill:t.value.style.chart.layout.pointer.useRatingColor?F.value:t.value.style.chart.layout.pointer.color,stroke:t.value.style.chart.layout.pointer.stroke,"stroke-width":t.value.style.chart.layout.pointer.circle.strokeWidth,"stroke-linejoin":"round"},null,8,ye)):e.createCommentVNode("",!0)])),e.createElementVNode("circle",{cx:a.value.width/2,cy:u.value.base,fill:t.value.style.chart.layout.pointer.circle.color,r:a.value.pointerRadius<=0?1e-4:a.value.pointerRadius,"stroke-width":t.value.style.chart.layout.pointer.circle.strokeWidth,stroke:t.value.style.chart.layout.pointer.circle.stroke},null,8,pe),e.createElementVNode("text",{x:a.value.width/2,y:u.value.ratingBase,"text-anchor":"middle","font-size":a.value.legendFontSize,"font-weight":"bold",fill:t.value.style.chart.legend.useRatingColor?F.value:t.value.style.chart.legend.color},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.legend.formatter,d.value,e.unref(o.dataLabel)({p:t.value.style.chart.legend.prefix+(t.value.style.chart.legend.showPlusSymbol&&d.value>0?"+":""),v:d.value,s:t.value.style.chart.legend.suffix,r:t.value.style.chart.legend.roundingValue}))),9,ge),e.renderSlot(r.$slots,"svg",{svg:a.value},void 0,!0)],14,Q)):e.createCommentVNode("",!0),r.$slots.watermark?(e.openBlock(),e.createElementBlock("div",ke,[e.renderSlot(r.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(E)||e.unref(P)})),void 0,!0)])):e.createCommentVNode("",!0),b.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(T.default,{key:4,config:{type:"gauge",style:{backgroundColor:t.value.style.chart.backgroundColor,gauge:{color:"#CCCCCC"}}}},null,8,["config"])),e.createElementVNode("div",{ref_key:"chartLegend",ref:N},[e.renderSlot(r.$slots,"legend",{legend:m.value},void 0,!0)],512)],14,J))}},_e=Z._export_sfc(be,[["__scopeId","data-v-1e268f4d"]]);exports.default=_e;
|