@fewangsit/wangsvue-fats 1.0.0-alpha.76 → 1.0.0-alpha.77

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/wangsvue-fats.js CHANGED
@@ -29657,9 +29657,11 @@ let XH = (fr = class {
29657
29657
  */
29658
29658
  normalizePath(e) {
29659
29659
  const n = this.getNavigationBaseUrl();
29660
+ debugger;
29660
29661
  if (!n)
29661
29662
  return e;
29662
29663
  const i = e.startsWith("/") ? e.slice(1) : e;
29664
+ debugger;
29663
29665
  return `${n}${i}`;
29664
29666
  }
29665
29667
  /**
@@ -29705,16 +29707,17 @@ let XH = (fr = class {
29705
29707
  * Router.replace('/login', { reason: 'session expired' });
29706
29708
  */
29707
29709
  replace(e, n = {}, i = "") {
29710
+ debugger;
29708
29711
  window.history.replaceState(n, i, e);
29709
29712
  }
29710
29713
  /**
29711
- * Dispatches a custom event before navigation occurs.
29712
- * Used to notify subscribers of an upcoming route change.
29713
- *
29714
- * @param route - The route that will be navigated to.
29715
- * @param mode - The navigation mode ('push' or 'replace').
29716
- * @param data - Optional state object for the navigation.
29717
- */
29714
+ * Dispatches a custom event before navigation occurs.
29715
+ * Used to notify subscribers of an upcoming route change.
29716
+ *
29717
+ * @param route - The route that will be navigated to.
29718
+ * @param mode - The navigation mode ('push' or 'replace').
29719
+ * @param data - Optional state object for the navigation.
29720
+ */
29718
29721
  dispatchBeforeNavigationEvent(e, n, i) {
29719
29722
  window.dispatchEvent(new CustomEvent("wangs-ui-core:before-navigation-event", {
29720
29723
  detail: { route: e, mode: n, state: i }
@@ -29756,7 +29759,9 @@ let XH = (fr = class {
29756
29759
  const o = typeof e == "string" ? e : e.toString(), s = this.normalizePath(o);
29757
29760
  if (s === location.pathname)
29758
29761
  return console.warn("[WangsUIRouter] Navigation aborted: target route is the same as the current route.");
29759
- this.dispatchBeforeNavigationEvent(s, n, i), n === "push" ? this.push(s, i, r) : this.replace(s, i, r), this.dispatchNavigationEvent(s, n, i);
29762
+ this.dispatchBeforeNavigationEvent(s, n, i);
29763
+ debugger;
29764
+ n === "push" ? this.push(s, i, r) : this.replace(s, i, r), this.dispatchNavigationEvent(s, n, i);
29760
29765
  }
29761
29766
  }, Zt(fr, "SINGLETON_KEY", "__WANGS_UI_ROUTER_INSTANCE__"), fr);
29762
29767
  new XH();
@@ -30586,9 +30591,11 @@ const vs = class vs {
30586
30591
  */
30587
30592
  normalizePath(e) {
30588
30593
  const n = this.getNavigationBaseUrl();
30594
+ debugger;
30589
30595
  if (!n)
30590
30596
  return e;
30591
30597
  const i = e.startsWith("/") ? e.slice(1) : e;
30598
+ debugger;
30592
30599
  return `${n}${i}`;
30593
30600
  }
30594
30601
  /**
@@ -30634,16 +30641,17 @@ const vs = class vs {
30634
30641
  * Router.replace('/login', { reason: 'session expired' });
30635
30642
  */
30636
30643
  replace(e, n = {}, i = "") {
30644
+ debugger;
30637
30645
  window.history.replaceState(n, i, e);
30638
30646
  }
30639
30647
  /**
30640
- * Dispatches a custom event before navigation occurs.
30641
- * Used to notify subscribers of an upcoming route change.
30642
- *
30643
- * @param route - The route that will be navigated to.
30644
- * @param mode - The navigation mode ('push' or 'replace').
30645
- * @param data - Optional state object for the navigation.
30646
- */
30648
+ * Dispatches a custom event before navigation occurs.
30649
+ * Used to notify subscribers of an upcoming route change.
30650
+ *
30651
+ * @param route - The route that will be navigated to.
30652
+ * @param mode - The navigation mode ('push' or 'replace').
30653
+ * @param data - Optional state object for the navigation.
30654
+ */
30647
30655
  dispatchBeforeNavigationEvent(e, n, i) {
30648
30656
  window.dispatchEvent(new CustomEvent("wangs-ui-core:before-navigation-event", {
30649
30657
  detail: { route: e, mode: n, state: i }
@@ -30685,7 +30693,9 @@ const vs = class vs {
30685
30693
  const o = typeof e == "string" ? e : e.toString(), s = this.normalizePath(o);
30686
30694
  if (s === location.pathname)
30687
30695
  return console.warn("[WangsUIRouter] Navigation aborted: target route is the same as the current route.");
30688
- this.dispatchBeforeNavigationEvent(s, n, i), n === "push" ? this.push(s, i, r) : this.replace(s, i, r), this.dispatchNavigationEvent(s, n, i);
30696
+ this.dispatchBeforeNavigationEvent(s, n, i);
30697
+ debugger;
30698
+ n === "push" ? this.push(s, i, r) : this.replace(s, i, r), this.dispatchNavigationEvent(s, n, i);
30689
30699
  }
30690
30700
  };
30691
30701
  Zt(vs, "SINGLETON_KEY", "__WANGS_UI_ROUTER_INSTANCE__");