@das-fed/upf-ui 6.4.0-dev.195 → 6.4.0-dev.197
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@das-fed/upf-ui",
|
|
3
|
-
"version": "6.4.0-dev.
|
|
3
|
+
"version": "6.4.0-dev.197",
|
|
4
4
|
"description": "",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./index.js",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"@antv/x6-plugin-snapline": "^2.1.7",
|
|
27
27
|
"@antv/x6-plugin-transform": "^2.1.8",
|
|
28
28
|
"@antv/x6-vue-shape": "^2.1.2",
|
|
29
|
-
"@das-fed/upf-ui": "6.4.0-dev.
|
|
29
|
+
"@das-fed/upf-ui": "6.4.0-dev.197",
|
|
30
30
|
"@element-plus/icons-vue": "^2.3.1",
|
|
31
31
|
"@types/lodash": "^4.14.194",
|
|
32
32
|
"@types/lodash-es": "^4.17.9",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"vue-tsc": "^2.0.29"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@das-fed/upf-cli": "6.4.0-dev.
|
|
60
|
-
"@das-fed/upf-utils": "6.4.0-dev.
|
|
61
|
-
"@das-fed/upf-web": "6.4.0-dev.
|
|
59
|
+
"@das-fed/upf-cli": "6.4.0-dev.197",
|
|
60
|
+
"@das-fed/upf-utils": "6.4.0-dev.197",
|
|
61
|
+
"@das-fed/upf-web": "6.4.0-dev.197",
|
|
62
62
|
"@types/markdown-it": "^14.1.2",
|
|
63
63
|
"@wangeditor-next/editor": "5.6.31",
|
|
64
64
|
"@wangeditor-next/editor-for-vue": "5.1.14",
|
|
@@ -1,110 +1,99 @@
|
|
|
1
1
|
import '@das-fed/upf-ui/packages/business-components/layout-breadcrumb/style.css';
|
|
2
|
-
import { ref as
|
|
3
|
-
import { withInstall as
|
|
4
|
-
import { DasBreadCrumb as
|
|
5
|
-
import { useRouter as
|
|
6
|
-
import { flatTree as
|
|
7
|
-
import { getSubApps as
|
|
8
|
-
import { setThemeRule as
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
12
|
-
var
|
|
13
|
-
const { app:
|
|
14
|
-
if (
|
|
15
|
-
setTimeout(() =>
|
|
2
|
+
import { ref as k, computed as L, watch as C, nextTick as M, defineComponent as B, openBlock as S, createElementBlock as v, createVNode as A, unref as y, createCommentVNode as N } from "vue";
|
|
3
|
+
import { withInstall as q } from "@das-fed/upf-utils/with-install/index";
|
|
4
|
+
import { DasBreadCrumb as R } from "@das-fed/upf-ui/packages/components/breadcrumb/index";
|
|
5
|
+
import { useRouter as T, useRoute as x } from "vue-router";
|
|
6
|
+
import { flatTree as D } from "@das-fed/upf-utils/common-tools";
|
|
7
|
+
import { getSubApps as g, getMenuItemInfo as O, getMenuListnfo as P } from "@das-fed/upf-utils/common-info";
|
|
8
|
+
import { setThemeRule as $ } from "@das-fed/upf-web/packages/theme/index";
|
|
9
|
+
const E = (a, i) => {
|
|
10
|
+
const p = k([]), m = L(() => [...p.value, ...a.data || []]), f = () => new Promise((e) => {
|
|
11
|
+
const t = () => {
|
|
12
|
+
var r, o;
|
|
13
|
+
const { app: n = "" } = (u == null ? void 0 : u.query) || {}, c = ((o = (r = g()) == null ? void 0 : r.currentSubApp) == null ? void 0 : o.menus) ?? [];
|
|
14
|
+
if (n === g().currentSubAppCode && c.length) return e();
|
|
15
|
+
setTimeout(() => t(), 50);
|
|
16
16
|
};
|
|
17
|
-
|
|
18
|
-
}),
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
const m = t.code.split(".");
|
|
27
|
-
if (m.length === 3) {
|
|
28
|
-
const A = m.slice(0, 2).join("."), _ = r.find((L) => L.code === A || L.originalCode === A);
|
|
29
|
-
o.push({ name: (_ == null ? void 0 : _.name) ?? "", isMenu: !0, disabled: !0 });
|
|
17
|
+
t();
|
|
18
|
+
}), l = (...e) => {
|
|
19
|
+
const t = O(), n = P(), c = [], r = n.find((o) => o.appId === t.appId);
|
|
20
|
+
if (r && r.children && r.children.length)
|
|
21
|
+
if (t.parentId === r.id)
|
|
22
|
+
c.push({ name: t.showName || "", isMenu: !0 });
|
|
23
|
+
else {
|
|
24
|
+
const o = r.children.find((s) => s.id === t.parentId);
|
|
25
|
+
o && (c.push({ name: o.showName || "", isMenu: !0, disabled: !0 }), c.push({ name: t.showName || "", isMenu: !0 }));
|
|
30
26
|
}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}
|
|
38
|
-
i.value = o;
|
|
39
|
-
}, C = (e) => {
|
|
40
|
-
e.disabled || l("click-item", e);
|
|
41
|
-
}, y = $(), u = j();
|
|
42
|
-
v(
|
|
43
|
-
() => y.currentRoute.value,
|
|
27
|
+
p.value = c;
|
|
28
|
+
}, h = (e) => {
|
|
29
|
+
e.disabled || i("click-item", e);
|
|
30
|
+
}, b = T(), u = x();
|
|
31
|
+
C(
|
|
32
|
+
() => b.currentRoute.value,
|
|
44
33
|
(e) => {
|
|
45
|
-
const
|
|
46
|
-
|
|
34
|
+
const t = (e == null ? void 0 : e.path) ?? "", n = (e == null ? void 0 : e.query) ?? {};
|
|
35
|
+
l(t, n);
|
|
47
36
|
}
|
|
48
|
-
),
|
|
49
|
-
const
|
|
50
|
-
return
|
|
37
|
+
), l(u.path, u.query);
|
|
38
|
+
const _ = k(!1);
|
|
39
|
+
return C(
|
|
51
40
|
() => a.data,
|
|
52
41
|
() => {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
var
|
|
56
|
-
const e =
|
|
57
|
-
let
|
|
58
|
-
if (!
|
|
59
|
-
const
|
|
60
|
-
(
|
|
42
|
+
M(() => {
|
|
43
|
+
f().then(() => {
|
|
44
|
+
var o;
|
|
45
|
+
const e = g(), t = u.query.app || e.currentSubApp.code || "";
|
|
46
|
+
let n = u.query.menu || "";
|
|
47
|
+
if (!n) {
|
|
48
|
+
const s = ((o = e.currentSubApp) == null ? void 0 : o.menus) ?? [], I = D(s).find(
|
|
49
|
+
(d) => `/${(d == null ? void 0 : d.applicationPath) ?? ""}${(d == null ? void 0 : d.routeUrl) ?? ""}`.replace(/\/\//g, "/") === location.pathname
|
|
61
50
|
);
|
|
62
|
-
|
|
51
|
+
I && (n = I.code);
|
|
63
52
|
}
|
|
64
|
-
const
|
|
65
|
-
for (let
|
|
66
|
-
|
|
53
|
+
const c = JSON.parse(sessionStorage.getItem("breadcrumb") || "{}")[t], r = [];
|
|
54
|
+
for (let s in c) c[s] && r.push(s);
|
|
55
|
+
_.value = !!r.find((s) => n === s);
|
|
67
56
|
});
|
|
68
57
|
});
|
|
69
58
|
},
|
|
70
59
|
{ deep: !0, immediate: !0 }
|
|
71
60
|
), {
|
|
72
|
-
isShow:
|
|
73
|
-
breadcrumbList:
|
|
74
|
-
clickItem:
|
|
61
|
+
isShow: _,
|
|
62
|
+
breadcrumbList: m,
|
|
63
|
+
clickItem: h
|
|
75
64
|
};
|
|
76
|
-
},
|
|
65
|
+
}, J = {
|
|
77
66
|
key: 0,
|
|
78
67
|
class: "layout-breadcrumb"
|
|
79
|
-
},
|
|
68
|
+
}, U = {
|
|
80
69
|
name: "LayoutBreadCrumb"
|
|
81
|
-
},
|
|
82
|
-
...
|
|
70
|
+
}, j = /* @__PURE__ */ B({
|
|
71
|
+
...U,
|
|
83
72
|
props: {
|
|
84
73
|
data: { default: () => [] }
|
|
85
74
|
},
|
|
86
75
|
emits: ["click-item"],
|
|
87
|
-
setup(a, { emit:
|
|
88
|
-
const
|
|
89
|
-
return (
|
|
90
|
-
|
|
91
|
-
data:
|
|
92
|
-
onClickItem:
|
|
76
|
+
setup(a, { emit: i }) {
|
|
77
|
+
const p = a, m = i, { isShow: f, breadcrumbList: l, clickItem: h } = E(p, m);
|
|
78
|
+
return (b, u) => b.data && b.data.length ? (S(), v("div", J, [
|
|
79
|
+
A(y(R), {
|
|
80
|
+
data: y(l),
|
|
81
|
+
onClickItem: y(h)
|
|
93
82
|
}, null, 8, ["data", "onClickItem"])
|
|
94
|
-
])) :
|
|
83
|
+
])) : N("", !0);
|
|
95
84
|
}
|
|
96
|
-
}),
|
|
97
|
-
const
|
|
98
|
-
for (const [
|
|
99
|
-
|
|
100
|
-
return
|
|
101
|
-
},
|
|
85
|
+
}), w = (a, i) => {
|
|
86
|
+
const p = a.__vccOpts || a;
|
|
87
|
+
for (const [m, f] of i)
|
|
88
|
+
p[m] = f;
|
|
89
|
+
return p;
|
|
90
|
+
}, z = /* @__PURE__ */ w(j, [["__scopeId", "data-v-511908ae"]]), F = {
|
|
102
91
|
"--das-layout-micro-container-bg-color": "#e2e7ef",
|
|
103
92
|
"--das-layout-breadcrumb-bg-color": "#ffffff"
|
|
104
93
|
};
|
|
105
|
-
|
|
106
|
-
const
|
|
94
|
+
$(F);
|
|
95
|
+
const Z = q(z), V = () => k(null);
|
|
107
96
|
export {
|
|
108
|
-
|
|
109
|
-
|
|
97
|
+
Z as DasLayoutBreadcrumb,
|
|
98
|
+
V as DasLayoutBreadcrumbRef
|
|
110
99
|
};
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.layout-breadcrumb[data-v-
|
|
1
|
+
.layout-breadcrumb[data-v-511908ae]{height:40px;flex-shrink:0;display:flex;align-items:center;background-color:var(--das-layout-breadcrumb-bg-color);padding-left:18px}
|