@next-core/brick-kit 2.93.0 → 2.93.1

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.esm.js CHANGED
@@ -6101,14 +6101,6 @@ class Kernel {
6101
6101
 
6102
6102
  _defineProperty$1(this, "loadingBar", void 0);
6103
6103
 
6104
- _defineProperty$1(this, "navBar", void 0);
6105
-
6106
- _defineProperty$1(this, "sideBar", void 0);
6107
-
6108
- _defineProperty$1(this, "footer", void 0);
6109
-
6110
- _defineProperty$1(this, "breadcrumb", void 0);
6111
-
6112
6104
  _defineProperty$1(this, "router", void 0);
6113
6105
 
6114
6106
  _defineProperty$1(this, "currentApp", void 0);
@@ -6125,8 +6117,6 @@ class Kernel {
6125
6117
 
6126
6118
  _defineProperty$1(this, "currentLayout", void 0);
6127
6119
 
6128
- _defineProperty$1(this, "enableUiV8", false);
6129
-
6130
6120
  _defineProperty$1(this, "allUserMapPromise", Promise.resolve(new Map()));
6131
6121
 
6132
6122
  _defineProperty$1(this, "allMagicBrickConfigMapPromise", Promise.resolve(new Map()));
@@ -6153,20 +6143,13 @@ class Kernel {
6153
6143
  throw new Error("No storyboard were found.");
6154
6144
  }
6155
6145
 
6156
- _this.setUiVersion();
6157
-
6158
6146
  if (isLoggedIn()) {
6159
6147
  _this.loadSharedData();
6160
6148
  }
6161
6149
 
6162
6150
  _this.menuBar = new MenuBar(_this, "menuBar");
6163
6151
  _this.appBar = new AppBar(_this, "appBar");
6164
- _this.loadingBar = new BaseBar(_this, "loadingBar"); // Todo(nlicro): 这里需要新写对应的NavBar...
6165
-
6166
- _this.navBar = new BaseBar(_this, "navBar");
6167
- _this.sideBar = new BaseBar(_this, "sideBar");
6168
- _this.breadcrumb = new BaseBar(_this, "breadcrumb");
6169
- _this.footer = new BaseBar(_this, "footer");
6152
+ _this.loadingBar = new BaseBar(_this, "loadingBar");
6170
6153
  _this.router = new Router(_this);
6171
6154
  initAnalytics();
6172
6155
  yield _this.router.bootstrap();
@@ -6194,13 +6177,7 @@ class Kernel {
6194
6177
  loadingBar: "business-website.loading-bar",
6195
6178
  pageNotFound: "business-website.page-not-found",
6196
6179
  pageError: "business-website.page-error"
6197
- } : _objectSpread(_objectSpread({}, _this2.enableUiV8 ? {
6198
- loadingBar: _this2.bootstrapData.navbar.loadingBar,
6199
- navBar: "frame-bricks.nav-bar",
6200
- sideBar: "frame-bricks.side-bar",
6201
- breadcrumb: null,
6202
- footer: null
6203
- } : _this2.bootstrapData.navbar), {}, {
6180
+ } : _objectSpread(_objectSpread({}, _this2.bootstrapData.navbar), {}, {
6204
6181
  pageNotFound: "basic-bricks.page-not-found",
6205
6182
  pageError: "basic-bricks.page-error"
6206
6183
  });
@@ -6215,7 +6192,7 @@ class Kernel {
6215
6192
 
6216
6193
  yield Promise.all([_this2.menuBar.bootstrap(_this2.presetBricks.menuBar, {
6217
6194
  testid: "brick-next-menu-bar"
6218
- }), _this2.appBar.bootstrap(_this2.presetBricks.appBar), _this2.navBar.bootstrap(_this2.presetBricks.navBar), _this2.sideBar.bootstrap(_this2.presetBricks.sideBar), _this2.footer.bootstrap(_this2.presetBricks.footer), _this2.breadcrumb.bootstrap(_this2.presetBricks.breadcrumb), _this2.loadingBar.bootstrap(_this2.presetBricks.loadingBar)]);
6195
+ }), _this2.appBar.bootstrap(_this2.presetBricks.appBar), _this2.loadingBar.bootstrap(_this2.presetBricks.loadingBar)]);
6219
6196
  })();
6220
6197
  }
6221
6198
 
@@ -6767,16 +6744,6 @@ class Kernel {
6767
6744
  })();
6768
6745
  }
6769
6746
 
6770
- setUiVersion() {
6771
- // get from localStorage fot test
6772
- // this.enableUiV8 = this.getFeatureFlags()["ui-v8"];
6773
- this.enableUiV8 = !!localStorage.getItem("test-ui-v8");
6774
-
6775
- if (this.enableUiV8) {
6776
- document.documentElement.dataset.ui = "v8";
6777
- }
6778
- }
6779
-
6780
6747
  } // Since `@next-dll/editor-bricks-helper` depends on `@next-dll/react-dnd`,
6781
6748
  // always load react-dnd before loading editor-bricks-helper.
6782
6749
 
@@ -6981,8 +6948,6 @@ var PropertyDisplayType;
6981
6948
 
6982
6949
  /** @internal */
6983
6950
 
6984
- /** @internal */
6985
-
6986
6951
  /**
6987
6952
  * 应用的 Storyboard 配置。
6988
6953
  */
@@ -9449,33 +9414,30 @@ class Router {
9449
9414
  if (barsHidden || getRuntimeMisc().isInIframeOfLegacyConsole) {
9450
9415
  _this3.kernel.toggleBars(false);
9451
9416
  } else if (_this3.kernel.currentLayout === "console") {
9452
- /* istanbul ignore next */
9453
- if (!_this3.kernel.enableUiV8) {
9454
- var _menuBar$menu, _menuBar$menu2;
9417
+ var _menuBar$menu, _menuBar$menu2;
9455
9418
 
9456
- yield constructMenu(menuBar, _this3.locationContext.getCurrentContext(), _this3.kernel);
9419
+ yield constructMenu(menuBar, _this3.locationContext.getCurrentContext(), _this3.kernel);
9457
9420
 
9458
- if (shouldBeDefaultCollapsed((_menuBar$menu = menuBar.menu) === null || _menuBar$menu === void 0 ? void 0 : _menuBar$menu.defaultCollapsed, (_menuBar$menu2 = menuBar.menu) === null || _menuBar$menu2 === void 0 ? void 0 : _menuBar$menu2.defaultCollapsedBreakpoint)) {
9459
- _this3.kernel.menuBar.collapse(true);
9460
-
9461
- _this3.defaultCollapsed = true;
9462
- } else {
9463
- if (_this3.defaultCollapsed) {
9464
- _this3.kernel.menuBar.collapse(false);
9465
- }
9421
+ if (shouldBeDefaultCollapsed((_menuBar$menu = menuBar.menu) === null || _menuBar$menu === void 0 ? void 0 : _menuBar$menu.defaultCollapsed, (_menuBar$menu2 = menuBar.menu) === null || _menuBar$menu2 === void 0 ? void 0 : _menuBar$menu2.defaultCollapsedBreakpoint)) {
9422
+ _this3.kernel.menuBar.collapse(true);
9466
9423
 
9467
- _this3.defaultCollapsed = false;
9424
+ _this3.defaultCollapsed = true;
9425
+ } else {
9426
+ if (_this3.defaultCollapsed) {
9427
+ _this3.kernel.menuBar.collapse(false);
9468
9428
  }
9469
9429
 
9470
- if (actualLegacy === "iframe") {
9471
- // Do not modify breadcrumb in iframe mode,
9472
- // it will be *popped* from iframe automatically.
9473
- delete appBar.breadcrumb;
9474
- }
9430
+ _this3.defaultCollapsed = false;
9431
+ }
9475
9432
 
9476
- mountStaticNode(_this3.kernel.menuBar.element, menuBar);
9477
- mountStaticNode(_this3.kernel.appBar.element, appBar);
9433
+ if (actualLegacy === "iframe") {
9434
+ // Do not modify breadcrumb in iframe mode,
9435
+ // it will be *popped* from iframe automatically.
9436
+ delete appBar.breadcrumb;
9478
9437
  }
9438
+
9439
+ mountStaticNode(_this3.kernel.menuBar.element, menuBar);
9440
+ mountStaticNode(_this3.kernel.appBar.element, appBar);
9479
9441
  }
9480
9442
 
9481
9443
  _this3.kernel.toggleLegacyIframe(actualLegacy === "iframe");