@next-core/brick-kit 2.188.0 → 2.188.2
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/index.bundle.js +18 -5
- package/dist/index.bundle.js.map +1 -1
- package/dist/index.esm.js +18 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/types/core/Kernel.d.ts +1 -0
- package/dist/types/core/Kernel.d.ts.map +1 -1
- package/dist/types/internal/images.d.ts.map +1 -1
- package/package.json +2 -2
package/dist/index.bundle.js
CHANGED
|
@@ -701,7 +701,7 @@
|
|
|
701
701
|
return {
|
|
702
702
|
get(name) {
|
|
703
703
|
var getSuffix = () => {
|
|
704
|
-
var suffix = window.APP_ROOT ? "".concat(window.APP_ROOT).concat(window.PUBLIC_DEPS ? "" : "-/") : "";
|
|
704
|
+
var suffix = window.APP_ROOT ? "".concat(window.APP_ROOT).concat(window.BOOTSTRAP_UNION_FILE && window.PUBLIC_DEPS ? "" : "-/") : "";
|
|
705
705
|
if (!suffix.startsWith("/")) {
|
|
706
706
|
suffix = getBasePath() + suffix;
|
|
707
707
|
}
|
|
@@ -9026,9 +9026,22 @@
|
|
|
9026
9026
|
});
|
|
9027
9027
|
})();
|
|
9028
9028
|
}
|
|
9029
|
+
processPublicDepsPackages() {
|
|
9030
|
+
var brickPackages = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
9031
|
+
var pubDeps = arguments.length > 1 ? arguments[1] : undefined;
|
|
9032
|
+
if (!(pubDeps !== null && pubDeps !== void 0 && pubDeps.length)) return brickPackages;
|
|
9033
|
+
var bricksMap = new Map();
|
|
9034
|
+
|
|
9035
|
+
// bootstrapData 数据和 pubDeps 中可能同时存在同一个包名,需要过滤去重, 以 pubDeps 中的包为准
|
|
9036
|
+
[...brickPackages, ...pubDeps].forEach(pkg => {
|
|
9037
|
+
var pkgName = pkg.filePath.split("/")[1];
|
|
9038
|
+
bricksMap.set(pkgName, pkg);
|
|
9039
|
+
});
|
|
9040
|
+
return Array.from(bricksMap.values());
|
|
9041
|
+
}
|
|
9029
9042
|
getBrickPackages() {
|
|
9030
|
-
var _this$bootstrapData
|
|
9031
|
-
return (_this$bootstrapData = this.bootstrapData) === null || _this$bootstrapData === void 0 ? void 0 :
|
|
9043
|
+
var _this$bootstrapData;
|
|
9044
|
+
return this.processPublicDepsPackages((_this$bootstrapData = this.bootstrapData) === null || _this$bootstrapData === void 0 ? void 0 : _this$bootstrapData.brickPackages, window.PUBLIC_DEPS);
|
|
9032
9045
|
}
|
|
9033
9046
|
reloadMicroApps(params, interceptorParams) {
|
|
9034
9047
|
// There is no need to reload standalone micro-apps.
|
|
@@ -9057,7 +9070,7 @@
|
|
|
9057
9070
|
$$fulfilling: null
|
|
9058
9071
|
});
|
|
9059
9072
|
if (window.BOOTSTRAP_UNION_FILE && !storyboard.$$fullMerged) {
|
|
9060
|
-
var fullBootstrapPath = "".concat(window.APP_ROOT
|
|
9073
|
+
var fullBootstrapPath = "".concat(window.APP_ROOT).concat(window.PUBLIC_DEPS ? "" : "-/").concat(storyboard.bootstrapFile);
|
|
9061
9074
|
var {
|
|
9062
9075
|
storyboards
|
|
9063
9076
|
} = yield brickHttp.http.get(fullBootstrapPath);
|
|
@@ -9077,7 +9090,7 @@
|
|
|
9077
9090
|
var appRuntimeData;
|
|
9078
9091
|
try {
|
|
9079
9092
|
// Note: the request maybe have fired already during bootstrap.
|
|
9080
|
-
appRuntimeData = yield safeGetRuntimeMicroAppStandalone(storyboard.app.id);
|
|
9093
|
+
appRuntimeData = yield safeGetRuntimeMicroAppStandalone(storyboard.app.id, storyboard.app.currentVersion);
|
|
9081
9094
|
} catch (error) {
|
|
9082
9095
|
// make it not crash when the backend service is not updated.
|
|
9083
9096
|
// eslint-disable-next-line no-console
|