@next-core/brick-kit 2.179.2 → 2.179.4

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.
@@ -10407,15 +10407,16 @@
10407
10407
  }
10408
10408
  }
10409
10409
  }
10410
- yield _this4.mountMenu(route.menu, matched.match, mountRoutesResult);
10411
10410
  if (route.documentId) {
10412
10411
  mountRoutesResult.appBar.documentId = route.documentId;
10413
10412
  }
10414
10413
  if (isRouteConfOfRoutes(route) && Array.isArray(route.routes)) {
10415
10414
  yield _this4.preFetchMenu(route.context);
10415
+ yield _this4.mountMenu(route.menu, matched.match, mountRoutesResult);
10416
10416
  yield _this4.mountRoutes(route.routes, slotId, mountRoutesResult);
10417
10417
  } else if (isRouteConfOfBricks(route) && Array.isArray(route.bricks)) {
10418
10418
  yield _this4.preFetchMenu(route);
10419
+ yield _this4.mountMenu(route.menu, matched.match, mountRoutesResult);
10419
10420
  yield _this4.mountBricks(route.bricks, matched.match, slotId, mountRoutesResult);
10420
10421
 
10421
10422
  // analytics data (page_view event)
@@ -11529,21 +11530,17 @@
11529
11530
  end: triggerHttpCache("http:cache.end")
11530
11531
  };
11531
11532
 
11532
- function setUIClassName() {
11533
- var version = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "8";
11534
- var lastVersion = "";
11535
- document.body.classList.forEach(item => {
11536
- if (item.startsWith("ui")) {
11537
- lastVersion = item;
11538
- }
11539
- });
11540
- if (lastVersion) {
11541
- document.body.classList.remove(lastVersion);
11533
+ function setUIVersion(version) {
11534
+ // 仅允许特定的 UI 版本
11535
+ var ui;
11536
+ switch (version) {
11537
+ case "8.2":
11538
+ ui = "v8-2";
11539
+ break;
11540
+ default:
11541
+ ui = "v8";
11542
11542
  }
11543
- var getUIClassName = version => {
11544
- return "ui-v".concat(version.split(".").join("-"));
11545
- };
11546
- document.body.classList.add(getUIClassName(version));
11543
+ document.documentElement.dataset.ui = ui;
11547
11544
  }
11548
11545
 
11549
11546
  class Router {
@@ -11984,7 +11981,7 @@
11984
11981
  var _this3$kernel$bootstr3, _this3$kernel$bootstr4, _getAuth$license;
11985
11982
  yield pendingTask;
11986
11983
  window.DISABLE_REACT_FLUSH_SYNC = false;
11987
- setUIClassName(currentApp === null || currentApp === void 0 ? void 0 : currentApp.uiVersion);
11984
+ setUIVersion(currentApp === null || currentApp === void 0 ? void 0 : currentApp.uiVersion);
11988
11985
  main.length > 0 && mountTree(main, mountPoints.main);
11989
11986
  portal.length > 0 && mountTree(portal, mountPoints.portal);
11990
11987
  afterMountTree(mountPoints.main);