@das-fed/web 6.4.0-hot.36 → 6.4.0-hot.38
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-pa8JpqiR.js → index-Do-hi0sT.js} +6392 -5785
- package/index-Do-hi0sT.js.gz +0 -0
- package/index-Ho3juDFP.js +10 -0
- package/index-ybkIe7Qx.js +87 -0
- package/index-ybkIe7Qx.js.gz +0 -0
- package/index.js +1 -1
- package/package.json +6 -6
- package/packages/i18n/index.js +17 -17
- package/packages/i18n/index.js.gz +0 -0
- package/packages/layout/index.js +321 -232
- package/packages/layout/index.js.gz +0 -0
- package/packages/main-app-framework/{index-PIgnnyL3.js → index-By_I7kxF.js} +4148 -3649
- package/packages/main-app-framework/index-By_I7kxF.js.gz +0 -0
- package/packages/main-app-framework/index-D6tSxSCm.js +10 -0
- package/packages/main-app-framework/index-uy_tfCFy.js +87 -0
- package/packages/main-app-framework/index-uy_tfCFy.js.gz +0 -0
- package/packages/main-app-framework/index.js +1 -1
- package/packages/main-app-framework/style.css +1 -1
- package/packages/main-app-framework/style.css.gz +0 -0
- package/packages/micro-frontend/index.js +111 -97
- package/packages/micro-frontend/index.js.gz +0 -0
- package/packages/style/style.css +1 -1
- package/packages/style/style.css.gz +0 -0
- package/style.css +1 -1
- package/style.css.gz +0 -0
- package/types/create-das-web-app/index.d.ts +1 -1
- package/types/i18n/index.d.ts +3 -3
- package/types/layout/store/index.d.ts +1 -1
- package/types/main-app-framework/business/alarm/use-alarm.d.ts +4 -4
- package/types/main-app-framework/business/message-notify/index.d.ts +1 -0
- package/types/main-app-framework/business/remote-control/apis.d.ts +2 -0
- package/types/main-app-framework/business/remote-control/utils.d.ts +7 -0
- package/types/main-app-framework/business/video-link/index.d.ts +3 -3
- package/types/main-app-framework/business/video-link/video-dialog/hooks/PlayerProvider.d.ts +3 -3
- package/types/main-app-framework/components/person-set-dialog/index.d.ts +1 -1
- package/types/main-app-framework/components/person-set-dialog/src/api.d.ts +2 -0
- package/types/main-app-framework/components/person-set-dialog/src/components/index.d.ts +1 -0
- package/types/main-app-framework/components/person-set-dialog/src/components/set-home/use-link-form/hooks/use-builtIn-dialog.d.ts +6 -6
- package/types/main-app-framework/components/person-set-dialog/src/components/set-home/use-link-form/hooks/use-notBuiltIn-dialog.d.ts +10 -10
- package/types/main-app-framework/i18n/index.d.ts +20 -0
- package/types/main-app-framework/index.d.ts +2 -2
- package/types/main-app-framework/init-config/get-nav-config/index.d.ts +4 -3
- package/types/main-app-framework/init-config/get-system-config/api.d.ts +2 -0
- package/types/main-app-framework/init-config/get-system-config/index.d.ts +6 -4
- package/types/main-app-framework/init-config/get-tenant-config/api.d.ts +3 -1
- package/types/main-app-framework/init-config/get-tenant-config/index.d.ts +2 -0
- package/types/main-app-framework/init-layout/hooks/nav-slots/index.d.ts +1 -0
- package/types/main-app-framework/init-layout/hooks/nav-slots/use-ai-helper.d.ts +4 -0
- package/types/main-app-framework/init-layout/hooks/nav-slots/use-change-enterprises.d.ts +3 -3
- package/types/main-app-framework/init-layout/hooks/nav-slots/use-user-command.d.ts +2 -2
- package/types/main-app-framework/init-layout/hooks/use-initialization.d.ts +5 -5
- package/types/main-app-framework/init-layout/hooks/use-tabs.d.ts +3 -3
- package/types/main-app-framework/init-platform/index.d.ts +1 -1
- package/types/main-app-framework/utils/src/set-common-info.d.ts +2 -0
- package/types/micro-frontend/store.d.ts +5 -5
- package/types/theme/index.d.ts +1 -1
- package/index-BR2K2L20.js +0 -10
- package/index-CqHbFeJ4.js +0 -81
- package/index-CqHbFeJ4.js.gz +0 -0
- package/index-pa8JpqiR.js.gz +0 -0
- package/packages/main-app-framework/index-D-yLFNAt.js +0 -10
- package/packages/main-app-framework/index-PIgnnyL3.js.gz +0 -0
- package/packages/main-app-framework/index-gbopgvrS.js +0 -81
- package/packages/main-app-framework/index-gbopgvrS.js.gz +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import '@das-fed/web/packages/micro-frontend/style.css';
|
|
2
|
-
import { ref as w, watch as M, reactive as
|
|
3
|
-
import { DasWebLayout as ye,
|
|
4
|
-
const
|
|
2
|
+
import { ref as w, watch as M, reactive as P, getCurrentScope as ue, onScopeDispose as de, getCurrentInstance as pe, onMounted as me, nextTick as ne, unref as I, defineComponent as x, computed as N, createElementBlock as D, openBlock as E, Fragment as $, renderList as fe, withDirectives as ve, createCommentVNode as he, createBlock as se, vShow as Ae, mergeProps as we, withCtx as T, createVNode as C, renderSlot as V, onActivated as ge } from "vue";
|
|
3
|
+
import { DasWebLayout as ye, DasWebTabs as Me, DasWebMenu as Le, DasWebNav as _e } from "@das-fed/web/packages/layout/index";
|
|
4
|
+
const z = w("/das-micro-app"), f = w([]), k = w(!1), O = w([]), F = w(!0);
|
|
5
5
|
let v = null, h = null, _ = null;
|
|
6
6
|
const be = (e) => new Promise((t) => {
|
|
7
7
|
const n = () => {
|
|
@@ -189,7 +189,7 @@ const be = (e) => new Promise((t) => {
|
|
|
189
189
|
setMainAppLayoutVisible: (e) => {
|
|
190
190
|
q("layoutVisible", { visible: e });
|
|
191
191
|
}
|
|
192
|
-
},
|
|
192
|
+
}, u = P({
|
|
193
193
|
visible: !1,
|
|
194
194
|
theme: "default",
|
|
195
195
|
logo: "",
|
|
@@ -201,54 +201,54 @@ const be = (e) => new Promise((t) => {
|
|
|
201
201
|
// activeItem: '',
|
|
202
202
|
// activeProject: {},
|
|
203
203
|
eventListeners: {}
|
|
204
|
-
}),
|
|
204
|
+
}), W = {
|
|
205
205
|
show: () => {
|
|
206
|
-
|
|
206
|
+
u.visible = !0;
|
|
207
207
|
},
|
|
208
208
|
hide: () => {
|
|
209
|
-
|
|
209
|
+
u.visible = !1;
|
|
210
210
|
},
|
|
211
211
|
setLogo: (e) => {
|
|
212
|
-
|
|
212
|
+
u.logo = e;
|
|
213
213
|
},
|
|
214
214
|
setTheme: (e) => {
|
|
215
|
-
|
|
215
|
+
u.theme = e;
|
|
216
216
|
},
|
|
217
217
|
setItems: (e) => {
|
|
218
|
-
|
|
218
|
+
u.visible || (u.visible = !0), u.items = e;
|
|
219
219
|
},
|
|
220
|
-
getItems: () =>
|
|
220
|
+
getItems: () => u.items,
|
|
221
221
|
removeItem: (e) => {
|
|
222
|
-
const t =
|
|
223
|
-
|
|
222
|
+
const t = u.items.filter((n) => n.value !== e);
|
|
223
|
+
u.items = t;
|
|
224
224
|
},
|
|
225
225
|
appendItem: (e) => {
|
|
226
|
-
|
|
226
|
+
u.visible || (u.visible = !0), !u.items.find((n) => n.value == e.value) && u.items.push(e);
|
|
227
227
|
},
|
|
228
228
|
setActiveItem: (e) => {
|
|
229
|
-
|
|
229
|
+
u.activeItem = e;
|
|
230
230
|
},
|
|
231
231
|
setConfig: (e) => {
|
|
232
|
-
|
|
232
|
+
u.config = e;
|
|
233
233
|
},
|
|
234
234
|
setProjects: (e) => {
|
|
235
|
-
|
|
235
|
+
u.projects = e;
|
|
236
236
|
},
|
|
237
237
|
setProjectConfig: (e) => {
|
|
238
|
-
|
|
238
|
+
u.projectConfig = e;
|
|
239
239
|
},
|
|
240
240
|
setActiveProject: (e) => {
|
|
241
|
-
|
|
241
|
+
u.activeProject = e;
|
|
242
242
|
},
|
|
243
243
|
setUserInfo: (e) => {
|
|
244
|
-
|
|
244
|
+
u.userInfo = e;
|
|
245
245
|
},
|
|
246
246
|
setSearchConfig: (e) => {
|
|
247
|
-
|
|
247
|
+
u.searchConfig = e;
|
|
248
248
|
},
|
|
249
249
|
triggerEventListener: (e, t, n) => {
|
|
250
250
|
var i;
|
|
251
|
-
const s =
|
|
251
|
+
const s = u.eventListeners, { autoRemove: c = !1 } = n || {}, a = [];
|
|
252
252
|
for (const r in s) {
|
|
253
253
|
const o = s[r];
|
|
254
254
|
o.type === e && a.push(
|
|
@@ -261,9 +261,9 @@ const be = (e) => new Promise((t) => {
|
|
|
261
261
|
},
|
|
262
262
|
addEventListener: (e, t) => {
|
|
263
263
|
const n = (/* @__PURE__ */ new Date()).getTime() + Math.random().toString(36).slice(-8), s = () => {
|
|
264
|
-
|
|
264
|
+
u.eventListeners[n] && delete u.eventListeners[n];
|
|
265
265
|
};
|
|
266
|
-
return
|
|
266
|
+
return u.eventListeners[n] = {
|
|
267
267
|
type: e,
|
|
268
268
|
handler: async (c) => {
|
|
269
269
|
try {
|
|
@@ -277,12 +277,12 @@ const be = (e) => new Promise((t) => {
|
|
|
277
277
|
remove: s
|
|
278
278
|
};
|
|
279
279
|
}
|
|
280
|
-
}, g =
|
|
280
|
+
}, g = P({
|
|
281
281
|
theme: "default",
|
|
282
282
|
items: [],
|
|
283
283
|
collapse: !1,
|
|
284
284
|
eventListeners: {}
|
|
285
|
-
}),
|
|
285
|
+
}), j = {
|
|
286
286
|
setItems: (e) => {
|
|
287
287
|
g.items = e;
|
|
288
288
|
},
|
|
@@ -330,11 +330,11 @@ const be = (e) => new Promise((t) => {
|
|
|
330
330
|
remove: s
|
|
331
331
|
};
|
|
332
332
|
}
|
|
333
|
-
}, A =
|
|
333
|
+
}, A = P({
|
|
334
334
|
theme: "default",
|
|
335
335
|
items: [],
|
|
336
336
|
eventListeners: {}
|
|
337
|
-
}),
|
|
337
|
+
}), H = {
|
|
338
338
|
setItems: (e) => {
|
|
339
339
|
A.items = e;
|
|
340
340
|
},
|
|
@@ -384,12 +384,12 @@ const be = (e) => new Promise((t) => {
|
|
|
384
384
|
remove: s
|
|
385
385
|
};
|
|
386
386
|
}
|
|
387
|
-
},
|
|
387
|
+
}, R = P({
|
|
388
388
|
eventListeners: {}
|
|
389
389
|
}), Ce = {
|
|
390
390
|
triggerEventListener: (e, t, n) => {
|
|
391
391
|
var i;
|
|
392
|
-
const s =
|
|
392
|
+
const s = R.eventListeners, { autoRemove: c = !1 } = n || {}, a = [];
|
|
393
393
|
for (const r in s) {
|
|
394
394
|
const o = s[r];
|
|
395
395
|
o.type === e && a.push(
|
|
@@ -402,9 +402,9 @@ const be = (e) => new Promise((t) => {
|
|
|
402
402
|
},
|
|
403
403
|
addEventListener: (e, t) => {
|
|
404
404
|
const n = (/* @__PURE__ */ new Date()).getTime() + Math.random().toString(36).slice(-8), s = () => {
|
|
405
|
-
|
|
405
|
+
R.eventListeners[n] && delete R.eventListeners[n];
|
|
406
406
|
};
|
|
407
|
-
return
|
|
407
|
+
return R.eventListeners[n] = {
|
|
408
408
|
type: e,
|
|
409
409
|
handler: async (c) => {
|
|
410
410
|
try {
|
|
@@ -418,29 +418,24 @@ const be = (e) => new Promise((t) => {
|
|
|
418
418
|
remove: s
|
|
419
419
|
};
|
|
420
420
|
}
|
|
421
|
-
},
|
|
421
|
+
}, U = P({
|
|
422
422
|
visible: !1,
|
|
423
423
|
style: {}
|
|
424
424
|
}), Oe = {
|
|
425
425
|
set: (e, t) => {
|
|
426
|
-
|
|
426
|
+
U.visible = e, t || (t = {}), t.transition || (t.transition = "all 0.3s"), t && (U.style = t);
|
|
427
427
|
}
|
|
428
428
|
}, Fe = {
|
|
429
|
-
nav: l,
|
|
430
|
-
menu: g,
|
|
431
|
-
tab: A,
|
|
432
|
-
overlay: B,
|
|
433
|
-
iframeView: P,
|
|
434
429
|
visible: w(!0)
|
|
435
430
|
}, G = {
|
|
436
|
-
nav:
|
|
437
|
-
menu:
|
|
438
|
-
tab:
|
|
431
|
+
nav: W,
|
|
432
|
+
menu: j,
|
|
433
|
+
tab: H,
|
|
439
434
|
overlay: Oe,
|
|
440
435
|
iframeView: Ce,
|
|
441
436
|
setVisible: (e) => Fe.visible.value = e,
|
|
442
437
|
setTheme: (e) => {
|
|
443
|
-
|
|
438
|
+
W.setTheme(e), j.setTheme(e), H.setTheme(e);
|
|
444
439
|
}
|
|
445
440
|
}, re = (e, t) => {
|
|
446
441
|
const n = e.__vccOpts || e;
|
|
@@ -449,9 +444,9 @@ const be = (e) => new Promise((t) => {
|
|
|
449
444
|
return n;
|
|
450
445
|
};
|
|
451
446
|
var J;
|
|
452
|
-
const
|
|
447
|
+
const B = typeof window < "u", Re = (e) => typeof e == "string", Ne = () => {
|
|
453
448
|
};
|
|
454
|
-
|
|
449
|
+
B && ((J = window == null ? void 0 : window.navigator) != null && J.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
|
|
455
450
|
function ae(e) {
|
|
456
451
|
return typeof e == "function" ? e() : I(e);
|
|
457
452
|
}
|
|
@@ -469,16 +464,16 @@ function oe(e) {
|
|
|
469
464
|
const n = ae(e);
|
|
470
465
|
return (t = n == null ? void 0 : n.$el) != null ? t : n;
|
|
471
466
|
}
|
|
472
|
-
const xe =
|
|
467
|
+
const xe = B ? window : void 0, Ve = B ? window.document : void 0;
|
|
473
468
|
function qe(...e) {
|
|
474
469
|
let t, n, s, c;
|
|
475
470
|
if (Re(e[0]) || Array.isArray(e[0]) ? ([n, s, c] = e, t = xe) : [t, n, s, c] = e, !t)
|
|
476
471
|
return Ne;
|
|
477
472
|
Array.isArray(n) || (n = [n]), Array.isArray(s) || (s = [s]);
|
|
478
473
|
const a = [], i = () => {
|
|
479
|
-
a.forEach((
|
|
480
|
-
}, r = (
|
|
481
|
-
i(),
|
|
474
|
+
a.forEach((l) => l()), a.length = 0;
|
|
475
|
+
}, r = (l, y, m, L) => (l.addEventListener(y, m, L), () => l.removeEventListener(y, m, L)), o = M(() => [oe(t), ae(c)], ([l, y]) => {
|
|
476
|
+
i(), l && a.push(...n.flatMap((m) => s.map((L) => r(l, m, L, y))));
|
|
482
477
|
}, { immediate: !0, flush: "post" }), p = () => {
|
|
483
478
|
o(), i();
|
|
484
479
|
};
|
|
@@ -543,9 +538,9 @@ function Be(e, t = {}) {
|
|
|
543
538
|
} else
|
|
544
539
|
return !1;
|
|
545
540
|
return !1;
|
|
546
|
-
}), [o, p,
|
|
541
|
+
}), [o, p, l, , y] = i;
|
|
547
542
|
async function m() {
|
|
548
|
-
r.value && (n != null && n[
|
|
543
|
+
r.value && (n != null && n[l] && await n[p](), a.value = !1);
|
|
549
544
|
}
|
|
550
545
|
async function L() {
|
|
551
546
|
if (!r.value)
|
|
@@ -558,7 +553,7 @@ function Be(e, t = {}) {
|
|
|
558
553
|
a.value ? await m() : await L();
|
|
559
554
|
}
|
|
560
555
|
return n && qe(n, y, () => {
|
|
561
|
-
a.value = !!(n != null && n[
|
|
556
|
+
a.value = !!(n != null && n[l]);
|
|
562
557
|
}, !1), s && ie(m), {
|
|
563
558
|
isSupported: r,
|
|
564
559
|
isFullscreen: a,
|
|
@@ -648,40 +643,58 @@ const Ue = ["src", "entry", "name"], Ge = /* @__PURE__ */ x({
|
|
|
648
643
|
entry: r.entry,
|
|
649
644
|
name: r.name
|
|
650
645
|
});
|
|
651
|
-
const { dom: p, ...
|
|
652
|
-
d.triggerMicroAppLifeCycleListener("onLoaded",
|
|
646
|
+
const { dom: p, ...l } = r;
|
|
647
|
+
d.triggerMicroAppLifeCycleListener("onLoaded", l), new ResizeObserver(() => {
|
|
653
648
|
d.sendMessageToMicroApp(i, "resize", o());
|
|
654
649
|
}).observe(t.value), d.sendMessageToMicroApp(i, "setProxyMessageStatus", { visible: !0, parentHref: location.href }), d.sendMessageToMicroApp(i, "setProxSsoStatus", { visible: !0, parentHref: location.href });
|
|
655
650
|
}, s = (a, i) => {
|
|
656
|
-
const r = f.value.find((
|
|
651
|
+
const r = f.value.find((l) => l.name === i);
|
|
657
652
|
if (!r) return;
|
|
658
653
|
const { dom: o, ...p } = r;
|
|
659
654
|
d.sendMessageToMicroApp(i, "onActivated"), d.triggerMicroAppLifeCycleListener("onActivated", p);
|
|
660
655
|
}, c = (a, i) => {
|
|
661
|
-
const r = f.value.find((
|
|
656
|
+
const r = f.value.find((l) => l.name === i);
|
|
662
657
|
if (!r) return;
|
|
663
658
|
const { dom: o, ...p } = r;
|
|
664
659
|
d.sendMessageToMicroApp(i, "onDeactivated"), d.triggerMicroAppLifeCycleListener("onDeactivated", p);
|
|
665
660
|
};
|
|
666
|
-
return (a, i) => (E(), D(
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
661
|
+
return (a, i) => (E(), D(
|
|
662
|
+
"div",
|
|
663
|
+
{
|
|
664
|
+
ref_key: "containerRef",
|
|
665
|
+
ref: t,
|
|
666
|
+
class: "das-micro-app-container"
|
|
667
|
+
},
|
|
668
|
+
[
|
|
669
|
+
(E(!0), D(
|
|
670
|
+
$,
|
|
671
|
+
null,
|
|
672
|
+
fe(I(f), (r) => (E(), D(
|
|
673
|
+
$,
|
|
674
|
+
null,
|
|
675
|
+
[
|
|
676
|
+
r.loaded ? ve((E(), se(Je, {
|
|
677
|
+
key: 0,
|
|
678
|
+
src: r.src || "",
|
|
679
|
+
name: r.name,
|
|
680
|
+
actived: r.actived,
|
|
681
|
+
onOnLoaded: (o) => n(o, r.name),
|
|
682
|
+
onOnActivated: (o) => s(o, r.name),
|
|
683
|
+
onOnDeactivated: (o) => c(o, r.name)
|
|
684
|
+
}, null, 8, ["src", "name", "actived", "onOnLoaded", "onOnActivated", "onOnDeactivated"])), [
|
|
685
|
+
[Ae, r.actived]
|
|
686
|
+
]) : he("v-if", !0)
|
|
687
|
+
],
|
|
688
|
+
64
|
|
689
|
+
/* STABLE_FRAGMENT */
|
|
690
|
+
))),
|
|
691
|
+
256
|
|
692
|
+
/* UNKEYED_FRAGMENT */
|
|
693
|
+
))
|
|
694
|
+
],
|
|
695
|
+
512
|
|
696
|
+
/* NEED_PATCH */
|
|
697
|
+
));
|
|
685
698
|
}
|
|
686
699
|
}), Xe = /* @__PURE__ */ re(Ke, [["__scopeId", "data-v-3abdb1e9"]]), tt = /* @__PURE__ */ x({
|
|
687
700
|
__name: "das-main-app-layout",
|
|
@@ -705,25 +718,26 @@ const Ue = ["src", "entry", "name"], Ge = /* @__PURE__ */ x({
|
|
|
705
718
|
"transition-config": s.value,
|
|
706
719
|
"router-view-visible": n.value
|
|
707
720
|
}, c.value), {
|
|
708
|
-
header:
|
|
721
|
+
header: T(() => [
|
|
709
722
|
V(a.$slots, "header", {}, () => [
|
|
710
|
-
|
|
723
|
+
C(I(_e))
|
|
711
724
|
])
|
|
712
725
|
]),
|
|
713
|
-
aside:
|
|
726
|
+
aside: T(() => [
|
|
714
727
|
V(a.$slots, "aside", {}, () => [
|
|
715
|
-
|
|
728
|
+
C(I(Le), { menuAttr: a.menuAttr }, null, 8, ["menuAttr"])
|
|
716
729
|
])
|
|
717
730
|
]),
|
|
718
|
-
tab:
|
|
731
|
+
tab: T(() => [
|
|
719
732
|
V(a.$slots, "tab", {}, () => [
|
|
720
|
-
|
|
733
|
+
C(I(Me), { tabsAttr: a.tabsAttr }, null, 8, ["tabsAttr"])
|
|
721
734
|
])
|
|
722
735
|
]),
|
|
723
|
-
default:
|
|
724
|
-
|
|
736
|
+
default: T(() => [
|
|
737
|
+
C(Xe)
|
|
725
738
|
]),
|
|
726
739
|
_: 3
|
|
740
|
+
/* FORWARDED */
|
|
727
741
|
}, 16, ["transition-config", "router-view-visible"]));
|
|
728
742
|
}
|
|
729
743
|
}), ce = /* @__PURE__ */ x({
|
|
@@ -737,9 +751,9 @@ const Ue = ["src", "entry", "name"], Ge = /* @__PURE__ */ x({
|
|
|
737
751
|
}
|
|
738
752
|
}), Ye = (e) => ["http://", "https://", "ws://", "wss://", "/"].find((n) => e.startsWith(n)) ? e : `/${e}`, nt = (e, t) => {
|
|
739
753
|
if (!(e != null && e.microApps) || !Array.isArray(e.microApps)) return;
|
|
740
|
-
window.__IN_DAS_MAIN_APP = !0, e != null && e.microAppRouterPrefix && (
|
|
754
|
+
window.__IN_DAS_MAIN_APP = !0, e != null && e.microAppRouterPrefix && (z.value = e.microAppRouterPrefix), f.value = (e.microApps || []).filter((c) => !!c.name).map((c) => ({ ...c, entry: Ye(c.entry || c.name) })), t == null || t.addRoute({
|
|
741
755
|
name: "das-micro-app",
|
|
742
|
-
path: `${
|
|
756
|
+
path: `${z.value}/:pathMatch(.*)*`,
|
|
743
757
|
component: ce,
|
|
744
758
|
meta: { isMicroApp: !0, keepAlive: !0 }
|
|
745
759
|
}), d.addEventListenerFromMicroApp("bodyOverlay", (c) => {
|
|
@@ -782,7 +796,7 @@ const Ue = ["src", "entry", "name"], Ge = /* @__PURE__ */ x({
|
|
|
782
796
|
c.value = !1;
|
|
783
797
|
return;
|
|
784
798
|
}
|
|
785
|
-
const { path: r, query: o, params: p, meta:
|
|
799
|
+
const { path: r, query: o, params: p, meta: l } = i;
|
|
786
800
|
if (a.value.includes(i.path)) {
|
|
787
801
|
a.value = "";
|
|
788
802
|
return;
|
|
@@ -793,36 +807,36 @@ const Ue = ["src", "entry", "name"], Ge = /* @__PURE__ */ x({
|
|
|
793
807
|
path: r,
|
|
794
808
|
query: { ...o, microAppName: e.microAppName },
|
|
795
809
|
params: p,
|
|
796
|
-
meta:
|
|
810
|
+
meta: l
|
|
797
811
|
}
|
|
798
812
|
});
|
|
799
813
|
}
|
|
800
814
|
), d.addEventListenerFromMainApp("router", async (i) => {
|
|
801
|
-
var
|
|
815
|
+
var l;
|
|
802
816
|
const { cmd: r, route: o, microAppName: p = "" } = i.data;
|
|
803
|
-
a.value = ("/" + p + o.path).replace(/\/\//g, "/"), (
|
|
817
|
+
a.value = ("/" + p + o.path).replace(/\/\//g, "/"), (l = t == null ? void 0 : t[r]) == null || l.call(t, o);
|
|
804
818
|
}), d.addEventListenerFromMainApp("onLoaded", (i) => {
|
|
805
819
|
const { href: r, microAppContainerRect: o } = i.data;
|
|
806
820
|
window.__IN_DAS_MICRO_APP = !0, window.__DAS_MICRO_APP_NAME = e.microAppName, window.__DAS_MAIN_APP_HREF = r, window.__DAS_MICRO_APP_CONTAINER_RECT = o;
|
|
807
821
|
}), d.addEventListenerFromMainApp("onDeactivated", (i) => {
|
|
808
|
-
const { name: r = "", path: o, params: p = {}, query:
|
|
822
|
+
const { name: r = "", path: o, params: p = {}, query: l = {} } = t.currentRoute.value;
|
|
809
823
|
c.value = !0, t == null || t.push({
|
|
810
824
|
name: n,
|
|
811
|
-
query: { microAppName: e.microAppName, fromQuery: JSON.stringify(
|
|
825
|
+
query: { microAppName: e.microAppName, fromQuery: JSON.stringify(l), fromPath: o },
|
|
812
826
|
params: p
|
|
813
827
|
});
|
|
814
828
|
}), d.addEventListenerFromMainApp("onActivated", (i) => {
|
|
815
|
-
const { name: r = "", params: o = {}, query: p = {} } = t.currentRoute.value, { fromPath:
|
|
816
|
-
s.value = !0, t == null || t.push({ path:
|
|
829
|
+
const { name: r = "", params: o = {}, query: p = {} } = t.currentRoute.value, { fromPath: l = "", fromQuery: y = "{}" } = p || {};
|
|
830
|
+
s.value = !0, t == null || t.push({ path: l, query: JSON.parse(y), params: o });
|
|
817
831
|
}), d.addEventListenerFromMainApp("sessionStorage", (i) => {
|
|
818
832
|
const { cmd: r, key: o, value: p } = i.data;
|
|
819
833
|
r === "setItem" && window.sessionStorage.setItem(o, p), r === "getItem" && window.sessionStorage.getItem(o), r === "removeItem" && window.sessionStorage.removeItem(o), r === "clear" && window.sessionStorage.clear();
|
|
820
834
|
}), d.addEventListenerFromMainApp("route", (i) => {
|
|
821
835
|
const { cmd: r, path: o } = i.data;
|
|
822
|
-
r === "reload" && (
|
|
823
|
-
|
|
824
|
-
}, 300)), r === "unload" && (
|
|
825
|
-
|
|
836
|
+
r === "reload" && (O.value.push(o), F.value = !1, setTimeout(() => {
|
|
837
|
+
F.value = !0, O.value = [];
|
|
838
|
+
}, 300)), r === "unload" && (O.value.push(o), F.value = !1, setTimeout(() => {
|
|
839
|
+
F.value = !0, O.value = [];
|
|
826
840
|
}, 100));
|
|
827
841
|
});
|
|
828
842
|
};
|
|
Binary file
|
package/packages/style/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@charset "UTF-8";*,:before,:after{border-width:0;border-style:solid;border-color:currentColor}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;height:100%;overflow:auto}body{height:100%;margin:0;line-height:inherit;word-break:normal!important;word-wrap:normal!important;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;text-rendering:optimizelegibility;font-family:Helvetica Neue,Helvetica,PingFang SC,Hiragino Sans GB,
|
|
1
|
+
@charset "UTF-8";*,:before,:after{border-width:0;border-style:solid;border-color:currentColor}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;height:100%;overflow:auto}body{height:100%;margin:0;line-height:inherit;word-break:normal!important;word-wrap:normal!important;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;text-rendering:optimizelegibility;font-family:Microsoft YaHei,微软雅黑,San Francisco,Helvetica Neue,Helvetica,Arial,PingFang SC,Hiragino Sans GB,Heiti SC,WenQuanYi Micro Hei,sans-serif}#app{width:100%;height:100%}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){text-decoration:underline dotted}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0!important;padding:0}textarea{resize:vertical}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,canvas,iframe,embed,object{display:block}audio{display:inline-block}img{max-width:100%;height:auto}[hidden]{display:none}.dark{color-scheme:dark}label{font-weight:700}*,*:before,*:after{box-sizing:inherit}a:focus,a:active{outline:none}a,a:focus,a:hover{cursor:pointer;color:inherit;text-decoration:none}div:focus{outline:none}*::-webkit-scrollbar-track,*::-webkit-scrollbar-corner{background:transparent}*::-webkit-scrollbar{width:calc(var(--das-ui-scrollbar-thumb-size) + var(--das-ui-scrollbar-padding) * 2);height:calc(var(--das-ui-scrollbar-thumb-size) + var(--das-ui-scrollbar-padding) * 2);background-color:transparent}*::-webkit-scrollbar-thumb{border-radius:calc(var(--das-ui-scrollbar-thumb-size) + var(--das-ui-scrollbar-padding) * 2);border:var(--das-ui-scrollbar-padding) solid transparent;transition:border .15s;background-clip:content-box;background-color:var(--das-ui-scrollbar-thumb-color);cursor:pointer}*::-webkit-scrollbar-thumb:hover{border-left:none;border-right:none;background-color:var(--das-ui-scrollbar-thumb-hover-color)}.clearfix:after{visibility:hidden;display:block;font-size:0;content:" ";clear:both;height:0}.flex-center__y{display:flex;align-items:center}.is-hide{display:none!important}.overflow-hide{overflow:hidden!important}.overflow-visible{overflow:visible!important}.text-break{word-break:break-all}
|
|
Binary file
|