@das-fed/web 7.0.7-hot.77 → 7.0.7-hot.78
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/{index-C0V1mmhY.js → index-BZRBK6ha.js} +5728 -6217
- package/index-BZRBK6ha.js.gz +0 -0
- package/{packages/main-app-framework/index-mcZhp5kH.js → index-TpHHnTvN.js} +1 -1
- package/{index-B0B38Zrc.js → index-zXPXiFJr.js} +1 -2
- package/index-zXPXiFJr.js.gz +0 -0
- package/index.js +1 -1
- package/package.json +6 -6
- package/packages/create-das-web-app/index.js +44 -44
- package/packages/create-das-web-app/index.js.gz +0 -0
- package/packages/layout/index.js +118 -197
- package/packages/layout/index.js.gz +0 -0
- package/{index-B4nLIEw7.js → packages/main-app-framework/index-Cc0OYUtI.js} +1 -1
- package/packages/main-app-framework/{index-TlWCq0Vp.js → index-DjKNqLYL.js} +6260 -6651
- package/packages/main-app-framework/index-DjKNqLYL.js.gz +0 -0
- package/packages/main-app-framework/{index-KrpfKz6n.js → index-tz1GckQe.js} +1 -2
- package/packages/main-app-framework/index-tz1GckQe.js.gz +0 -0
- package/packages/main-app-framework/index.js +1 -1
- package/packages/micro-frontend/index.js +19 -38
- package/packages/micro-frontend/index.js.gz +0 -0
- package/types/main-app-framework/init-config/get-project-config/api.d.ts +3 -0
- package/types/main-app-framework/init-config/get-project-config/index.d.ts +5 -0
- package/types/main-app-framework/init-config/get-project-config/station-reserve-entry.d.ts +66 -0
- package/index-B0B38Zrc.js.gz +0 -0
- package/index-C0V1mmhY.js.gz +0 -0
- package/packages/main-app-framework/index-KrpfKz6n.js.gz +0 -0
- package/packages/main-app-framework/index-TlWCq0Vp.js.gz +0 -0
|
Binary file
|
|
@@ -6,7 +6,7 @@ import { DasSpin as T } from "@das-fed/ui/packages/components/spin/index";
|
|
|
6
6
|
import { getTabInfo as b } from "@das-fed/utils/common-info";
|
|
7
7
|
import { setShowLayout as E } from "@das-fed/utils/common-tools";
|
|
8
8
|
import { createService as L } from "@das-fed/utils/create-api-service";
|
|
9
|
-
import { u as P, p as q, a as u, c as d, b as B, l as K, g as M, d as N } from "./index-
|
|
9
|
+
import { u as P, p as q, a as u, c as d, b as B, l as K, g as M, d as N } from "./index-BZRBK6ha.js";
|
|
10
10
|
const O = "v1", V = L(`/api/justauth/client/${O}`), F = V.get("/visitor/kingdee/auth/user/auth_code"), ee = /* @__PURE__ */ v({
|
|
11
11
|
__name: "index",
|
|
12
12
|
setup(G) {
|
|
@@ -77,7 +77,6 @@ const O = "v1", V = L(`/api/justauth/client/${O}`), F = V.get("/visitor/kingdee/
|
|
|
77
77
|
}, null, 8, ["theme", "appCategorys"])
|
|
78
78
|
]),
|
|
79
79
|
_: 1
|
|
80
|
-
/* STABLE */
|
|
81
80
|
}, 8, ["spinning"])), [
|
|
82
81
|
[j, !w.value]
|
|
83
82
|
]);
|
|
Binary file
|
package/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { J as e, A as t, C as n, B as i, D as r, e as u, m as o, w as m, o as p, f as g, k as D, v as l, y as L, z as b, h as c, i as h, G as A, H as T, q as y, E as R, F as W, K as I, I as M, s as F, j as V, n as f, r as k, x as v, t as w } from "./index-
|
|
1
|
+
import { J as e, A as t, C as n, B as i, D as r, e as u, m as o, w as m, o as p, f as g, k as D, v as l, y as L, z as b, h as c, i as h, G as A, H as T, q as y, E as R, F as W, K as I, I as M, s as F, j as V, n as f, r as k, x as v, t as w } from "./index-BZRBK6ha.js";
|
|
2
2
|
export {
|
|
3
3
|
e as DasMainAppLayout,
|
|
4
4
|
t as DasWebLayout,
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@das-fed/web",
|
|
3
|
-
"version": "7.0.7-hot.
|
|
3
|
+
"version": "7.0.7-hot.78",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"dependencies": {
|
|
7
|
-
"@das-fed/ui": "7.0.7-hot.
|
|
8
|
-
"@das-fed/utils": "7.0.7-hot.
|
|
9
|
-
"@das-fed/web": "7.0.7-hot.
|
|
10
|
-
"@das-fed/web-components": "7.0.7-hot.
|
|
7
|
+
"@das-fed/ui": "7.0.7-hot.78",
|
|
8
|
+
"@das-fed/utils": "7.0.7-hot.78",
|
|
9
|
+
"@das-fed/web": "7.0.7-hot.78",
|
|
10
|
+
"@das-fed/web-components": "7.0.7-hot.78",
|
|
11
11
|
"@microsoft/signalr": "^8.0.7",
|
|
12
12
|
"@vueuse/core": "^9.13.0",
|
|
13
13
|
"animate.css": "^4.1.1",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"vue-router": "^4.4.0"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@das-fed/cli": "7.0.7-hot.
|
|
22
|
+
"@das-fed/cli": "7.0.7-hot.78",
|
|
23
23
|
"@types/crypto-js": "^4.2.2",
|
|
24
24
|
"@types/lodash": "^4.14.194",
|
|
25
25
|
"@types/lodash-es": "^4.17.12",
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { ref as
|
|
1
|
+
import { ref as L, createApp as D } from "vue";
|
|
2
2
|
import { initTheme as H } from "@das-fed/web/packages/theme/index";
|
|
3
|
-
import { initI18n as
|
|
4
|
-
import { DasWebLayout as
|
|
5
|
-
import { createPinia as
|
|
6
|
-
import
|
|
3
|
+
import { initI18n as T } from "@das-fed/web/packages/i18n/index";
|
|
4
|
+
import { DasWebLayout as G } from "@das-fed/web/packages/layout/index";
|
|
5
|
+
import { createPinia as N } from "pinia";
|
|
6
|
+
import Q from "pinia-plugin-persistedstate";
|
|
7
7
|
import { createRouter as U, createWebHistory as _ } from "vue-router";
|
|
8
8
|
const C = {
|
|
9
9
|
install: (e, s) => {
|
|
@@ -13,8 +13,8 @@ const C = {
|
|
|
13
13
|
n.default && n.default.install && e.use(n.default, s), n.install && e.use(n, s);
|
|
14
14
|
});
|
|
15
15
|
}
|
|
16
|
-
}, A =
|
|
17
|
-
A.use(
|
|
16
|
+
}, A = N();
|
|
17
|
+
A.use(Q);
|
|
18
18
|
const d = "::", f = (e) => {
|
|
19
19
|
if (!e) return "";
|
|
20
20
|
const r = (e.startsWith("/") ? e : `/${e}`).replace(/\/{2,}/g, "/");
|
|
@@ -22,10 +22,10 @@ const d = "::", f = (e) => {
|
|
|
22
22
|
}, O = (e) => `/${e.replace(/^\/+|\/+$/g, "")}`, $ = (e, s) => {
|
|
23
23
|
const r = O(s), a = f(e);
|
|
24
24
|
return a === r || a.startsWith(`${r}/`);
|
|
25
|
-
},
|
|
25
|
+
}, o = (e, s) => {
|
|
26
26
|
const r = O(e), a = f(s);
|
|
27
27
|
return !a || a === "/" ? r : $(a, e) ? a : `${r}${a}`;
|
|
28
|
-
},
|
|
28
|
+
}, B = (e, s) => {
|
|
29
29
|
const r = f(e).split("/").filter(Boolean), a = f(s).split("/").filter(Boolean);
|
|
30
30
|
let n = 0;
|
|
31
31
|
for (let t = 0; t < r.length; t++) {
|
|
@@ -42,12 +42,12 @@ const d = "::", f = (e) => {
|
|
|
42
42
|
n += 1;
|
|
43
43
|
}
|
|
44
44
|
return n === a.length;
|
|
45
|
-
},
|
|
45
|
+
}, I = (e, s = "") => {
|
|
46
46
|
const r = [];
|
|
47
47
|
return e.forEach((a) => {
|
|
48
48
|
const n = typeof (a == null ? void 0 : a.path) == "string" ? a.path : "";
|
|
49
49
|
let t = s;
|
|
50
|
-
n.startsWith("/") ? t = f(n) : n && (t = f(`${s}/${n}`)), t && r.push(t), Array.isArray(a == null ? void 0 : a.children) && a.children.length && r.push(...
|
|
50
|
+
n.startsWith("/") ? t = f(n) : n && (t = f(`${s}/${n}`)), t && r.push(t), Array.isArray(a == null ? void 0 : a.children) && a.children.length && r.push(...I(a.children, t));
|
|
51
51
|
}), r;
|
|
52
52
|
}, F = (e) => {
|
|
53
53
|
const s = /* @__PURE__ */ new Set(), r = (a) => {
|
|
@@ -58,13 +58,13 @@ const d = "::", f = (e) => {
|
|
|
58
58
|
return r(e), s;
|
|
59
59
|
}, b = (e, s, r, a) => {
|
|
60
60
|
if (typeof e == "string")
|
|
61
|
-
return !e.startsWith("/") || $(e, s) || !r.some((t) =>
|
|
61
|
+
return !e.startsWith("/") || $(e, s) || !r.some((t) => B(t, e)) ? e : o(s, e);
|
|
62
62
|
if (!e || typeof e != "object") return e;
|
|
63
63
|
const n = { ...e };
|
|
64
64
|
return typeof n.name == "string" && a.has(n.name) && !n.name.includes(d) && (n.name = `${s}${d}${n.name}`), typeof n.path == "string" && (n.path = b(n.path, s, r, a)), n;
|
|
65
|
-
},
|
|
65
|
+
}, R = (e, s, r, a) => {
|
|
66
66
|
const n = { ...e }, t = typeof e.path == "string" ? e.path : "";
|
|
67
|
-
t.startsWith("/") && (n.path =
|
|
67
|
+
t.startsWith("/") && (n.path = o(s, t));
|
|
68
68
|
const i = typeof e.name == "string" ? e.name : void 0;
|
|
69
69
|
if (i && !i.includes(d) && (n.name = `${s}${d}${i}`), n.meta = {
|
|
70
70
|
...e.meta || {},
|
|
@@ -75,34 +75,34 @@ const d = "::", f = (e) => {
|
|
|
75
75
|
const c = Array.isArray(e.alias) ? e.alias : [e.alias];
|
|
76
76
|
n.alias = c.map((h) => b(h, s, r, a));
|
|
77
77
|
}
|
|
78
|
-
return Array.isArray(e.children) && (n.children = e.children.map((c) =>
|
|
79
|
-
}, J = (e, s) => {
|
|
80
|
-
const r =
|
|
78
|
+
return Array.isArray(e.children) && (n.children = e.children.map((c) => R(c, s, r, a))), n;
|
|
79
|
+
}, J = (e) => typeof e != "string" || e.trim() === "", K = (e, s) => {
|
|
80
|
+
const r = e.filter((t) => !J(t == null ? void 0 : t.path)), a = I(r), n = F(r);
|
|
81
81
|
return {
|
|
82
|
-
routes:
|
|
83
|
-
patterns:
|
|
84
|
-
names:
|
|
82
|
+
routes: r.map((t) => R(t, s, a, n)),
|
|
83
|
+
patterns: a,
|
|
84
|
+
names: n
|
|
85
85
|
};
|
|
86
|
-
},
|
|
86
|
+
}, V = (e) => {
|
|
87
87
|
const s = e.indexOf("#"), r = s >= 0 ? e.slice(s) : "", a = s >= 0 ? e.slice(0, s) : e, n = a.indexOf("?"), t = n >= 0 ? a.slice(0, n) : a, i = n >= 0 ? a.slice(n) : "";
|
|
88
88
|
return { path: t, search: i, hash: r };
|
|
89
|
-
},
|
|
89
|
+
}, k = (e) => (e == null ? void 0 : e.isMainApp) === !0 || (e == null ? void 0 : e.isMainApp) === "true", X = (e) => e ? new URLSearchParams(e.startsWith("?") ? e.slice(1) : e).get("isMainApp") === "true" : !1, z = (e, s) => {
|
|
90
90
|
const r = f(e);
|
|
91
91
|
return s.find((a) => $(r, a.name));
|
|
92
92
|
}, j = (e, s, r, a) => {
|
|
93
|
-
if (!e || !e.startsWith("/") ||
|
|
93
|
+
if (!e || !e.startsWith("/") || k(a) || z(e, s) || !r) return e;
|
|
94
94
|
const n = f(e);
|
|
95
|
-
return r.patterns.some((t) =>
|
|
95
|
+
return r.patterns.some((t) => B(t, n)) ? o(r.name, n) : e;
|
|
96
96
|
}, y = (e, s, r) => {
|
|
97
97
|
var t;
|
|
98
|
-
const a = (t = r == null ? void 0 : r.meta) == null ? void 0 : t.microAppName, n = s.find((i) => i.name === a) ||
|
|
98
|
+
const a = (t = r == null ? void 0 : r.meta) == null ? void 0 : t.microAppName, n = s.find((i) => i.name === a) || z((r == null ? void 0 : r.path) || "", s);
|
|
99
99
|
if (typeof e == "string") {
|
|
100
|
-
const { path: i, search: c, hash: h } =
|
|
101
|
-
if (
|
|
102
|
-
const
|
|
103
|
-
return
|
|
100
|
+
const { path: i, search: c, hash: h } = V(e);
|
|
101
|
+
if (X(c)) return e;
|
|
102
|
+
const m = j(i, s, n);
|
|
103
|
+
return m === i ? e : `${m}${c}${h}`;
|
|
104
104
|
}
|
|
105
|
-
if (!e || typeof e != "object" ||
|
|
105
|
+
if (!e || typeof e != "object" || k(e.query)) return e;
|
|
106
106
|
if (typeof e.name == "string")
|
|
107
107
|
return e.name.includes(d) ? e : n != null && n.names.has(e.name) ? { ...e, name: `${n.name}${d}${e.name}` } : e;
|
|
108
108
|
if (typeof e.path == "string") {
|
|
@@ -110,18 +110,18 @@ const d = "::", f = (e) => {
|
|
|
110
110
|
return i === e.path ? e : { ...e, path: i };
|
|
111
111
|
}
|
|
112
112
|
return e;
|
|
113
|
-
},
|
|
113
|
+
}, Y = (e, s) => {
|
|
114
114
|
const r = e.push.bind(e), a = e.replace.bind(e), n = e.resolve.bind(e);
|
|
115
115
|
e.push = (t) => r(y(t, s, e.currentRoute.value)), e.replace = (t) => a(y(t, s, e.currentRoute.value)), e.resolve = (t, i) => n(y(t, s, i || e.currentRoute.value), i);
|
|
116
|
-
},
|
|
117
|
-
var
|
|
118
|
-
const s = ((
|
|
116
|
+
}, Z = (e) => {
|
|
117
|
+
var v, P, W, w, M;
|
|
118
|
+
const s = ((v = e == null ? void 0 : e.router) == null ? void 0 : v.routerBase) ?? "/", r = ((P = e == null ? void 0 : e.router) == null ? void 0 : P.options) || {};
|
|
119
119
|
let a = Object.assign(((W = e == null ? void 0 : e.router) == null ? void 0 : W.glob) || {});
|
|
120
|
-
const n = Object.values(a).filter((l) => !!l).flat().sort((l,
|
|
120
|
+
const n = Object.values(a).filter((l) => !!l).flat().sort((l, u) => (l.index ?? 0) - (u.index ?? 0)), t = [], i = [];
|
|
121
121
|
(w = e == null ? void 0 : e.microApps) == null || w.map((l) => {
|
|
122
122
|
var S;
|
|
123
123
|
if (!(l != null && l.microAppName)) return;
|
|
124
|
-
const
|
|
124
|
+
const u = Object.values(((S = l.router) == null ? void 0 : S.glob) || {}).filter((g) => !!g).flat().sort((g, E) => (g.index ?? 0) - (E.index ?? 0)), p = K(u, l.microAppName);
|
|
125
125
|
t.push(...p.routes), i.push({
|
|
126
126
|
name: l.microAppName,
|
|
127
127
|
patterns: p.patterns,
|
|
@@ -132,22 +132,22 @@ const d = "::", f = (e) => {
|
|
|
132
132
|
...x(n, e),
|
|
133
133
|
...x(c, e),
|
|
134
134
|
...x(t, e)
|
|
135
|
-
],
|
|
136
|
-
return i.length &&
|
|
135
|
+
], m = U({ history: _(s), routes: h, ...r });
|
|
136
|
+
return i.length && Y(m, i), { router: m };
|
|
137
137
|
}, x = (e, s) => e.map((r) => {
|
|
138
138
|
const a = r.meta || {};
|
|
139
139
|
return a.keepAlive = a.keepAlive ?? (s == null ? void 0 : s.keepAlive) ?? !0, { ...r, meta: a };
|
|
140
|
-
}),
|
|
140
|
+
}), ie = (e) => {
|
|
141
141
|
e || (e = {});
|
|
142
|
-
const s =
|
|
143
|
-
Promise.all([H(e),
|
|
142
|
+
const s = L(!0);
|
|
143
|
+
Promise.all([H(e), T(e)]).then(() => {
|
|
144
144
|
s.value = !1;
|
|
145
145
|
});
|
|
146
|
-
const { container: r, component: a, props: n } = (e == null ? void 0 : e.root) || {}, t =
|
|
146
|
+
const { container: r, component: a, props: n } = (e == null ? void 0 : e.root) || {}, t = D(a || G, n);
|
|
147
147
|
t.use(C, e), t.use(A);
|
|
148
|
-
const { router: i } =
|
|
148
|
+
const { router: i } = Z(e);
|
|
149
149
|
return t.use(i), t.mount(r || "#app"), { app: t, router: i, loading: s, store: A };
|
|
150
150
|
};
|
|
151
151
|
export {
|
|
152
|
-
|
|
152
|
+
ie as createDasWebApp
|
|
153
153
|
};
|
|
Binary file
|