@airpower/web 1.10.10 → 1.10.12

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.
Files changed (2) hide show
  1. package/dist/main.js +7 -5
  2. package/package.json +1 -1
package/dist/main.js CHANGED
@@ -19317,6 +19317,12 @@ class RouterUtil {
19317
19317
  if (this.router.hasRoute(item.id.toString())) {
19318
19318
  return;
19319
19319
  }
19320
+ if (item.children && item.children.length > 0) {
19321
+ this.registerRoute(item.children, parentRouter);
19322
+ }
19323
+ if (!item.path) {
19324
+ return;
19325
+ }
19320
19326
  if (item.redirect) {
19321
19327
  this.addRoute(parentRouter, item);
19322
19328
  return;
@@ -19324,11 +19330,6 @@ class RouterUtil {
19324
19330
  const componentPath = item.component || item.path;
19325
19331
  if (componentPath) {
19326
19332
  this.addRoute(parentRouter, item, componentPath);
19327
- return;
19328
- }
19329
- if (item.children && item.children.length > 0) {
19330
- this.registerRoute(item.children, parentRouter);
19331
- this.addRoute(parentRouter, item.children[0]);
19332
19333
  }
19333
19334
  });
19334
19335
  }
@@ -19362,6 +19363,7 @@ class RouterUtil {
19362
19363
  };
19363
19364
  this.router.addRoute(parentRouter, route);
19364
19365
  }
19366
+ throw new Error("路由添加失败,不太能走到这里");
19365
19367
  }
19366
19368
  /**
19367
19369
  * ### 重载缓存中的路由
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@airpower/web",
3
3
  "type": "module",
4
- "version": "1.10.10",
4
+ "version": "1.10.12",
5
5
  "description": "AirPower-Web",
6
6
  "author": {
7
7
  "name": "Hamm",