bt-core-app 1.4.155 → 1.4.156

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.
@@ -29834,17 +29834,17 @@ function MM() {
29834
29834
  }, Go;
29835
29835
  }
29836
29836
  const sy = Symbol(), _M = Symbol(), oy = Symbol(), uy = Symbol();
29837
- function U_(e, t) {
29838
- const n = Ne(sy), a = Ne(uy), r = Ne(oy), l = n.findItem(e.meta.nav ?? e.name) ?? void 0, i = e.meta.requiresAuth !== !1 || (l == null ? void 0 : l.requiresAuth) !== !1, s = e.query.isTraining === "true";
29839
- if (n.updateHistory(e, t), !i)
29840
- return n.updateNavigationProperties(l), e;
29841
- if (s)
29842
- return a.logout(), r.startDemo(), e;
29843
- if (r.endDemo(), a.tryLogin()) {
29844
- const u = (l == null ? void 0 : l.subscriptions) ?? [], c = (l == null ? void 0 : l.permissions) ?? [];
29845
- return a.doShow(u, c, "view") ? (n.updateNavigationProperties(l), e) : { name: "restricted" };
29837
+ function U_(e, t, n) {
29838
+ const a = Ne(sy), r = Ne(uy), l = Ne(oy), i = a.findItem(e.meta.nav ?? e.name) ?? void 0, s = e.meta.requiresAuth !== !1 || (i == null ? void 0 : i.requiresAuth) !== !1, u = e.query.isTraining === "true";
29839
+ if (a.updateHistory(e, t), !s)
29840
+ return a.updateNavigationProperties(i), e;
29841
+ if (u)
29842
+ return r.logout(), l.startDemo(), e;
29843
+ if (l.endDemo(), r.tryLogin()) {
29844
+ const c = (i == null ? void 0 : i.subscriptions) ?? [], h = (i == null ? void 0 : i.permissions) ?? [];
29845
+ return r.doShow(c, h, "view") ? (a.updateNavigationProperties(i), e) : n;
29846
29846
  } else
29847
- return a.login(window.location.pathname), n.updateNavigationProperties(l), { name: "restricted" };
29847
+ return r.login(window.location.pathname), a.updateNavigationProperties(i), n;
29848
29848
  }
29849
29849
  function q_(e) {
29850
29850
  const t = [];
package/dist/index.d.ts CHANGED
@@ -555,9 +555,7 @@ export declare interface GroupedHeaderOption {
555
555
  values: TableColumn[];
556
556
  }
557
557
 
558
- export declare function guardRoute(to: RouteLocation, from: RouteLocation): RouteLocation | {
559
- name: string;
560
- };
558
+ export declare function guardRoute(to: RouteLocation, from: RouteLocation, restrictedRoute: RouteLocation): RouteLocation;
561
559
 
562
560
  /**tests for whether string is contains in any of the given props of the given value */
563
561
  export declare function hasSearch(value: any, str?: string, props?: string[]): boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bt-core-app",
3
- "version": "1.4.155",
3
+ "version": "1.4.156",
4
4
  "description": "Core app tools for some basic features like navigation, authentication, server apis, and cosmetics",
5
5
  "homepage": "https://github.com/BlitzItTech/bt-core",
6
6
  "bugs": {