@kitbag/router 0.20.2 → 0.20.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.
@@ -1,14 +1,14 @@
1
- var Vr = Object.defineProperty;
2
- var Zr = (t, e, r) => e in t ? Vr(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r;
3
- var T = (t, e, r) => Zr(t, typeof e != "symbol" ? e + "" : e, r);
4
- import { inject as it, markRaw as Ut, reactive as _t, defineAsyncComponent as Or, watch as nt, onUnmounted as qt, computed as Z, ref as Pt, toValue as $, toRefs as jr, defineComponent as vt, createElementBlock as $r, openBlock as Oe, normalizeClass as Hr, renderSlot as je, normalizeProps as $e, guardReactiveProps as _r, unref as X, h as dt, getCurrentInstance as qr, provide as Ir, createCommentVNode as Dr, mergeProps as Jr, createBlock as Fr, resolveDynamicComponent as Tr } from "vue";
1
+ var Zr = Object.defineProperty;
2
+ var Or = (t, e, r) => e in t ? Zr(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r;
3
+ var T = (t, e, r) => Or(t, typeof e != "symbol" ? e + "" : e, r);
4
+ import { inject as it, markRaw as Ut, reactive as qt, defineAsyncComponent as jr, watch as ot, onUnmounted as Ht, computed as O, ref as Pt, toValue as V, toRefs as $r, defineComponent as vt, createElementBlock as _r, openBlock as $e, normalizeClass as qr, renderSlot as _e, normalizeProps as qe, guardReactiveProps as Hr, unref as tt, h as dt, getCurrentInstance as Ir, onServerPrefetch as Dr, provide as Jr, createCommentVNode as Fr, mergeProps as Tr, createBlock as Mr, resolveDynamicComponent as Wr } from "vue";
5
5
  function M(t) {
6
6
  return typeof t != "string" ? !1 : /^(https?:\/\/|\/).*/g.test(t);
7
7
  }
8
8
  function He(t) {
9
9
  return M(t) ? t : `/${t}`;
10
10
  }
11
- class Mr extends Error {
11
+ class Gr extends Error {
12
12
  /**
13
13
  * Constructs a new DuplicateParamsError instance with a message indicating the problematic parameter.
14
14
  * @param paramName - The name of the parameter that was duplicated.
@@ -17,7 +17,7 @@ class Mr extends Error {
17
17
  super(`Invalid Param "${e}": Router does not support multiple params by the same name. All param names must be unique.`);
18
18
  }
19
19
  }
20
- class Wr extends Error {
20
+ class Qr extends Error {
21
21
  constructor(e) {
22
22
  super(`Child property on meta for ${e} conflicts with the parent meta.`);
23
23
  }
@@ -27,7 +27,7 @@ class Et extends Error {
27
27
  super("Router not installed");
28
28
  }
29
29
  }
30
- class Gr extends Error {
30
+ class zr extends Error {
31
31
  /**
32
32
  * Constructs a new UseRouteInvalidError instance with a message that specifies both the given and expected route names.
33
33
  * This detailed error message aids in quickly identifying and resolving mismatches in route usage.
@@ -38,9 +38,9 @@ class Gr extends Error {
38
38
  super(`useRoute called with incorrect route. Given ${e}, expected ${r}`);
39
39
  }
40
40
  }
41
- const _e = Symbol();
41
+ const Ie = Symbol();
42
42
  function It() {
43
- const t = it(_e);
43
+ const t = it(Ie);
44
44
  if (!t)
45
45
  throw new Et();
46
46
  return t;
@@ -48,44 +48,44 @@ function It() {
48
48
  function ht(t) {
49
49
  return Array.isArray(t) ? t : [t];
50
50
  }
51
- function qe(t, e) {
51
+ function De(t, e) {
52
52
  return t.filter((r) => e === r).length;
53
53
  }
54
54
  function bt(...t) {
55
55
  const e = t.flatMap((r) => Array.isArray(r) ? r : Object.keys(r));
56
56
  for (const r of e)
57
- if (qe(e, r) > 1)
58
- throw new Mr(r);
57
+ if (De(e, r) > 1)
58
+ throw new Gr(r);
59
59
  }
60
- class z extends Error {
60
+ class Q extends Error {
61
61
  }
62
62
  const At = "[", Dt = "]";
63
- function zr(t) {
63
+ function Kr(t) {
64
64
  return t !== String && t !== Boolean && t !== Number && t !== Date;
65
65
  }
66
- function Qr(t) {
67
- return typeof t == "function" && zr(t);
66
+ function Yr(t) {
67
+ return typeof t == "function" && Kr(t);
68
68
  }
69
69
  function Jt(t) {
70
70
  return typeof t == "object" && "get" in t && typeof t.get == "function" && "set" in t && typeof t.set == "function";
71
71
  }
72
- function Ie(t) {
72
+ function Je(t) {
73
73
  return typeof t == "string" || typeof t == "number" || typeof t == "boolean";
74
74
  }
75
- function Kr(t, e) {
75
+ function Xr(t, e) {
76
76
  return Jt(t) ? { ...t, defaultValue: e ?? t.defaultValue } : {
77
- get: (r) => ot(r, t),
78
- set: (r) => at(r, t),
77
+ get: (r) => at(r, t),
78
+ set: (r) => z(r, t),
79
79
  defaultValue: e
80
80
  };
81
81
  }
82
- function Yr(t) {
82
+ function tn(t) {
83
83
  return Jt(t) && t.defaultValue !== void 0;
84
84
  }
85
- function Ho(t, e) {
86
- return Kr(t, e);
85
+ function Io(t, e) {
86
+ return Xr(t, e);
87
87
  }
88
- function Xr(t) {
88
+ function en(t) {
89
89
  return t !== void 0;
90
90
  }
91
91
  function mt(t) {
@@ -95,7 +95,7 @@ function W(t) {
95
95
  return typeof t == "string" && t.length > 0;
96
96
  }
97
97
  let w = null;
98
- async function tn() {
98
+ async function rn() {
99
99
  const {
100
100
  ZodSchema: t,
101
101
  ZodString: e,
@@ -139,23 +139,23 @@ async function tn() {
139
139
  ZodFunction: c
140
140
  };
141
141
  }
142
- function en(t) {
142
+ function nn(t) {
143
143
  return Object.values(t).some((e) => Object.values(e.host.params).some((r) => Gt(r)) || Object.values(e.path.params).some((r) => Gt(r)) || Object.values(e.query.params).some((r) => Gt(r)));
144
144
  }
145
145
  function Gt(t) {
146
146
  return mt(t) && "parse" in t && typeof t.parse == "function" && "~standard" in t && mt(t["~standard"]) && "vendor" in t["~standard"] && t["~standard"].vendor === "zod";
147
147
  }
148
- async function rn() {
148
+ async function on() {
149
149
  try {
150
- w = await tn();
150
+ w = await rn();
151
151
  } catch {
152
152
  throw new Error("Failed to initialize Zod");
153
153
  }
154
154
  }
155
- function De(t) {
155
+ function Fe(t) {
156
156
  return w ? t instanceof w.ZodSchema : !1;
157
157
  }
158
- function Je(t) {
158
+ function Te(t) {
159
159
  return {
160
160
  get: (e, { invalid: r }) => {
161
161
  try {
@@ -173,9 +173,9 @@ function Je(t) {
173
173
  }
174
174
  };
175
175
  }
176
- const nn = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/;
176
+ const an = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/;
177
177
  function ct(t, e) {
178
- if (typeof e == "string" && nn.test(e)) {
178
+ if (typeof e == "string" && an.test(e)) {
179
179
  const r = new Date(e);
180
180
  return isNaN(r.getTime()) ? e : r;
181
181
  }
@@ -290,24 +290,24 @@ function Yt(t, e) {
290
290
  throw new Error("Function schemas are not supported");
291
291
  return JSON.stringify(e.parse(t));
292
292
  }
293
- function ne(t) {
293
+ function oe(t) {
294
294
  return typeof t == "object" && t !== null && "then" in t;
295
295
  }
296
296
  function N(t, e) {
297
297
  const r = t["~standard"].validate(e);
298
- if (ne(r))
298
+ if (oe(r))
299
299
  throw new Error("Promise schemas are not supported");
300
300
  if (r.issues)
301
301
  throw new Error("Validation failed");
302
302
  return r.value;
303
303
  }
304
- function on(t) {
304
+ function sn(t) {
305
305
  return mt(t) && "type" in t && typeof t.type == "string" && "~standard" in t && mt(t["~standard"]) && "vendor" in t["~standard"] && t["~standard"].vendor === "valibot";
306
306
  }
307
- function Fe(t) {
308
- return on(t);
307
+ function Me(t) {
308
+ return sn(t);
309
309
  }
310
- function Te(t) {
310
+ function We(t) {
311
311
  return {
312
312
  get: (e, { invalid: r }) => {
313
313
  try {
@@ -325,9 +325,9 @@ function Te(t) {
325
325
  }
326
326
  };
327
327
  }
328
- const an = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/;
328
+ const cn = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/;
329
329
  function ut(t, e) {
330
- if (typeof e == "string" && an.test(e)) {
330
+ if (typeof e == "string" && cn.test(e)) {
331
331
  const r = new Date(e);
332
332
  return isNaN(r.getTime()) ? e : r;
333
333
  }
@@ -431,21 +431,21 @@ function te(t, e) {
431
431
  throw new Error("Function schemas are not supported");
432
432
  return JSON.stringify(N(e, t));
433
433
  }
434
- function sn(t, e) {
434
+ function un(t, e) {
435
435
  return t[e] ?? String;
436
436
  }
437
- const V = {
437
+ const Z = {
438
438
  invalid: (t) => {
439
- throw new z(t);
439
+ throw new Q(t);
440
440
  }
441
- }, Me = {
441
+ }, Ge = {
442
442
  get: (t) => t,
443
443
  set: (t, { invalid: e }) => {
444
444
  if (typeof t != "string")
445
445
  throw e();
446
446
  return t;
447
447
  }
448
- }, oe = {
448
+ }, ae = {
449
449
  get: (t, { invalid: e }) => {
450
450
  if (t === "true")
451
451
  return !0;
@@ -458,7 +458,7 @@ const V = {
458
458
  throw e();
459
459
  return t.toString();
460
460
  }
461
- }, ae = {
461
+ }, se = {
462
462
  get: (t, { invalid: e }) => {
463
463
  const r = Number(t);
464
464
  if (isNaN(r))
@@ -470,7 +470,7 @@ const V = {
470
470
  throw e();
471
471
  return t.toString();
472
472
  }
473
- }, We = {
473
+ }, Qe = {
474
474
  get: (t, { invalid: e }) => {
475
475
  const r = new Date(t);
476
476
  if (isNaN(r.getTime()))
@@ -482,7 +482,7 @@ const V = {
482
482
  throw e();
483
483
  return t.toISOString();
484
484
  }
485
- }, Ge = {
485
+ }, ze = {
486
486
  get: (t, { invalid: e }) => {
487
487
  try {
488
488
  return JSON.parse(t);
@@ -498,235 +498,235 @@ const V = {
498
498
  }
499
499
  }
500
500
  };
501
- function cn(t, e) {
501
+ function fn(t, e) {
502
502
  switch (typeof e) {
503
503
  case "string":
504
- return Me.get(t, V) === e;
504
+ return Ge.get(t, Z) === e;
505
505
  case "number":
506
- return ae.get(t, V) === e;
506
+ return se.get(t, Z) === e;
507
507
  case "boolean":
508
- return oe.get(t, V) === e;
508
+ return ae.get(t, Z) === e;
509
509
  default:
510
510
  return !1;
511
511
  }
512
512
  }
513
- function ot(t, e, r = !1) {
513
+ function at(t, e, r = !1) {
514
514
  if (t === void 0 || !W(t)) {
515
- if (Yr(e))
515
+ if (tn(e))
516
516
  return e.defaultValue;
517
517
  if (r)
518
518
  return;
519
- throw new z();
519
+ throw new Q();
520
520
  }
521
521
  if (e === String)
522
- return Me.get(t, V);
522
+ return Ge.get(t, Z);
523
523
  if (e === Boolean)
524
- return oe.get(t, V);
524
+ return ae.get(t, Z);
525
525
  if (e === Number)
526
- return ae.get(t, V);
526
+ return se.get(t, Z);
527
527
  if (e === Date)
528
- return We.get(t, V);
528
+ return Qe.get(t, Z);
529
529
  if (e === JSON)
530
- return Ge.get(t, V);
531
- if (Qr(e))
532
- return e(t, V);
530
+ return ze.get(t, Z);
531
+ if (Yr(e))
532
+ return e(t, Z);
533
533
  if (Jt(e))
534
- return e.get(t, V);
534
+ return e.get(t, Z);
535
535
  if (e instanceof RegExp) {
536
536
  if (e.test(t))
537
537
  return t;
538
- throw new z();
538
+ throw new Q();
539
539
  }
540
- if (Ie(e)) {
541
- if (cn(t, e))
540
+ if (Je(e)) {
541
+ if (fn(t, e))
542
542
  return e;
543
- throw new z();
543
+ throw new Q();
544
544
  }
545
- return De(e) ? Je(e).get(t, V) : Fe(e) ? Te(e).get(t, V) : t;
545
+ return Fe(e) ? Te(e).get(t, Z) : Me(e) ? We(e).get(t, Z) : t;
546
546
  }
547
- function un(t, e, r = !1) {
547
+ function ee(t, e, r = !1) {
548
548
  try {
549
- return ot(t, e, r);
549
+ return at(t, e, r);
550
550
  } catch (n) {
551
- if (n instanceof z)
551
+ if (n instanceof Q)
552
552
  return;
553
553
  throw n;
554
554
  }
555
555
  }
556
- function fn(t, e, r = !1) {
556
+ function ln(t, e, r = !1) {
557
557
  try {
558
- return at(t, e, r);
558
+ return z(t, e, r);
559
559
  } catch (n) {
560
- if (n instanceof z)
560
+ if (n instanceof Q)
561
561
  return;
562
562
  throw n;
563
563
  }
564
564
  }
565
- function at(t, e, r = !1) {
565
+ function z(t, e, r = !1) {
566
566
  if (t === void 0) {
567
567
  if (r)
568
568
  return "";
569
- throw new z();
569
+ throw new Q();
570
570
  }
571
571
  if (e === Boolean)
572
- return oe.set(t, V);
572
+ return ae.set(t, Z);
573
573
  if (e === Number)
574
- return ae.set(t, V);
574
+ return se.set(t, Z);
575
575
  if (e === Date)
576
- return We.set(t, V);
576
+ return Qe.set(t, Z);
577
577
  if (e === JSON)
578
- return Ge.set(t, V);
578
+ return ze.set(t, Z);
579
579
  if (Jt(e))
580
- return e.set(t, V);
581
- if (Ie(e)) {
580
+ return e.set(t, Z);
581
+ if (Je(e)) {
582
582
  if (e !== t)
583
- throw new z();
583
+ throw new Q();
584
584
  return t.toString();
585
585
  }
586
- if (De(e))
587
- return Je(e).set(t, V);
588
586
  if (Fe(e))
589
- return Te(e).set(t, V);
587
+ return Te(e).set(t, Z);
588
+ if (Me(e))
589
+ return We(e).set(t, Z);
590
590
  try {
591
591
  return t.toString();
592
592
  } catch {
593
- throw new z();
593
+ throw new Q();
594
594
  }
595
595
  }
596
- function se(t) {
596
+ function ie(t) {
597
597
  return t.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
598
598
  }
599
- function ln(t, e) {
599
+ function pn(t, e) {
600
600
  const r = Array.from(t.matchAll(e));
601
601
  if (r.length === 0)
602
602
  return [t];
603
603
  let n = 0;
604
604
  const o = r.reduce((s, p) => {
605
- const h = se(t.slice(n, p.index));
605
+ const h = ie(t.slice(n, p.index));
606
606
  h.length && s.push(h);
607
607
  const [u] = p;
608
608
  return s.push(u), n = p.index + u.length, s;
609
609
  }, []), a = t.slice(n);
610
610
  return a && o.push(a), o;
611
611
  }
612
- function pn(t) {
613
- const e = ze(t.path.value);
612
+ function dn(t) {
613
+ const e = Ke(t.path.value);
614
614
  return new RegExp(`^${e}$`, "i");
615
615
  }
616
- function dn(t) {
616
+ function hn(t) {
617
617
  const e = new URLSearchParams(t.query.value);
618
- return Array.from(e.entries()).filter(([, r]) => !ce(r)).map(([r, n]) => {
619
- const o = ze(n);
620
- return new RegExp(`${se(r)}=${o}(&|$)`, "i");
618
+ return Array.from(e.entries()).filter(([, r]) => !ue(r)).map(([r, n]) => {
619
+ const o = Ke(n);
620
+ return new RegExp(`${ie(r)}=${o}(&|$)`, "i");
621
621
  });
622
622
  }
623
- function ze(t) {
624
- return ln(t, new RegExp(Ft, "g")).map((e) => e.startsWith(At) ? Qe(e) : se(e)).join("");
623
+ function Ke(t) {
624
+ return pn(t, new RegExp(Ft, "g")).map((e) => e.startsWith(At) ? Ye(e) : ie(e)).join("");
625
625
  }
626
- function Qe(t) {
626
+ function Ye(t) {
627
627
  return t.replace(new RegExp(Ft, "g"), ".+");
628
628
  }
629
- function hn(t, e) {
630
- const r = Ke(e);
629
+ function yn(t, e) {
630
+ const r = Xe(e);
631
631
  return t.replace(r, "(.*)");
632
632
  }
633
- function ie(t, e) {
634
- return mn(e).test(t.value);
633
+ function ce(t, e) {
634
+ return gn(e).test(t.value);
635
635
  }
636
- function ce(t) {
637
- return new RegExp(yn, "g").test(t);
638
- }
639
- const Ft = `\\${At}\\??([\\w-_]+)\\${Dt}`, yn = `\\${At}\\?([\\w-_]+)\\${Dt}`;
640
636
  function ue(t) {
641
- const [e] = Ye(t, new RegExp(Ft, "g"));
637
+ return new RegExp(mn, "g").test(t);
638
+ }
639
+ const Ft = `\\${At}\\??([\\w-_]+)\\${Dt}`, mn = `\\${At}\\?([\\w-_]+)\\${Dt}`;
640
+ function fe(t) {
641
+ const [e] = tr(t, new RegExp(Ft, "g"));
642
642
  return e;
643
643
  }
644
- function Ke(t) {
644
+ function Xe(t) {
645
645
  return new RegExp(`\\${At}\\??${t}\\${Dt}`, "g");
646
646
  }
647
- function mn(t) {
647
+ function gn(t) {
648
648
  return new RegExp(`\\${At}\\?${t}\\${Dt}`, "g");
649
649
  }
650
- function Ye(t, e) {
650
+ function tr(t, e) {
651
651
  return Array.from(t.matchAll(e)).flatMap(([, ...n]) => n.map((o) => W(o) ? o : ""));
652
652
  }
653
- function gn(t = "", e = {}) {
653
+ function Rn(t = "", e = {}) {
654
654
  return W(t) ? Array.from(t.matchAll(new RegExp(Ft, "g"))).reduce((n, [o, a]) => {
655
- const s = ue(o);
655
+ const s = fe(o);
656
656
  if (!s)
657
657
  return n;
658
- const p = sn(e, s);
658
+ const p = un(e, s);
659
659
  return bt([s], n), n[a] = p, n;
660
660
  }, {}) : {};
661
661
  }
662
- function Rn(t) {
662
+ function wn(t) {
663
663
  return mt(t) && typeof t.value == "string";
664
664
  }
665
- function tt(t) {
666
- return t === void 0 ? Q() : Rn(t) ? t : Q(t, {});
665
+ function et(t) {
666
+ return t === void 0 ? K() : wn(t) ? t : K(t, {});
667
667
  }
668
- function Q(t, e) {
668
+ function K(t, e) {
669
669
  return {
670
670
  value: t ?? "",
671
- params: gn(t, e)
671
+ params: Rn(t, e)
672
672
  };
673
673
  }
674
- function Xe(t, e) {
674
+ function er(t, e) {
675
675
  bt(t.params, e.params);
676
676
  const r = `${t.value}${e.value}`;
677
- return Q(r, { ...t.params, ...e.params });
678
- }
679
- function wn(t, e) {
680
- return Xe(t, e);
677
+ return K(r, { ...t.params, ...e.params });
681
678
  }
682
679
  function vn(t, e) {
683
- return En(t, e), { ...t, ...e };
680
+ return er(t, e);
684
681
  }
685
682
  function En(t, e) {
683
+ return bn(t, e), { ...t, ...e };
684
+ }
685
+ function bn(t, e) {
686
686
  const r = Object.keys(t).find((n) => n in e && typeof e[n] != typeof t[n]);
687
687
  if (r)
688
- throw new Wr(r);
688
+ throw new Qr(r);
689
689
  }
690
- function bn(t, e) {
690
+ function Sn(t, e) {
691
691
  bt(t.params, e.params);
692
692
  const r = [t.value, e.value].filter(W).join("&");
693
- return Q(r, { ...t.params, ...e.params });
693
+ return K(r, { ...t.params, ...e.params });
694
694
  }
695
- function Sn(t, e) {
695
+ function Pn(t, e) {
696
696
  return bt(t, e), { ...t, ...e };
697
697
  }
698
- function tr(t) {
698
+ function rr(t) {
699
699
  return "parent" in t && !!t.parent;
700
700
  }
701
- function er(t) {
701
+ function nr(t) {
702
702
  return "component" in t && !!t.component;
703
703
  }
704
- function ve(t) {
704
+ function be(t) {
705
705
  return "props" in t && typeof t.props == "function";
706
706
  }
707
- function rr(t) {
707
+ function or(t) {
708
708
  return "components" in t && !!t.components;
709
709
  }
710
- function Ee(t) {
710
+ function Se(t) {
711
711
  return "props" in t && typeof t.props == "object";
712
712
  }
713
- function nr(t, e) {
713
+ function ar(t, e) {
714
714
  return {
715
715
  ...e,
716
- path: Xe(t.path, e.path),
717
- query: bn(t.query, e.query),
718
- meta: vn(t.meta, e.meta),
719
- state: Sn(t.state, e.state),
720
- hash: wn(t.hash, e.hash),
716
+ path: er(t.path, e.path),
717
+ query: Sn(t.query, e.query),
718
+ meta: En(t.meta, e.meta),
719
+ state: Pn(t.state, e.state),
720
+ hash: vn(t.hash, e.hash),
721
721
  matches: [...t.matches, e.matched],
722
722
  host: t.host,
723
723
  depth: t.depth + 1
724
724
  };
725
725
  }
726
- function fe() {
726
+ function le() {
727
727
  return typeof window < "u" && typeof window.document < "u";
728
728
  }
729
- function le(t) {
729
+ function pe(t) {
730
730
  const e = new URLSearchParams(t);
731
731
  return {
732
732
  get: (...r) => e.get(...r),
@@ -755,20 +755,20 @@ function le(t) {
755
755
  [Symbol.iterator]: () => e[Symbol.iterator]()
756
756
  };
757
757
  }
758
- function pe() {
758
+ function de() {
759
759
  let t = 0;
760
760
  return () => (++t).toString();
761
761
  }
762
- const Pn = pe()();
763
- function An(t) {
764
- return t === Pn;
762
+ const An = de()();
763
+ function kn(t) {
764
+ return t === An;
765
765
  }
766
- const de = pe();
767
- function or(t) {
766
+ const he = de();
767
+ function sr(t) {
768
768
  return t === void 0 ? "" : t;
769
769
  }
770
770
  function gt(t, e) {
771
- const r = de(), n = or(t.name), o = tt(t.path), a = tt(t.query), s = tt(t.hash), p = t.meta ?? {}, h = t.state ?? {}, u = Ut({ id: r, meta: p, state: h, ...t, props: e }), m = {
771
+ const r = he(), n = sr(t.name), o = et(t.path), a = et(t.query), s = et(t.hash), p = t.meta ?? {}, h = t.state ?? {}, u = Ut({ id: r, meta: p, state: h, ...t, props: e }), m = {
772
772
  id: r,
773
773
  matched: u,
774
774
  matches: [u],
@@ -779,25 +779,25 @@ function gt(t, e) {
779
779
  meta: p,
780
780
  state: h,
781
781
  depth: 1,
782
- host: Q(),
782
+ host: K(),
783
783
  prefetch: t.prefetch
784
- }, R = tr(t) ? nr(t.parent, m) : m;
784
+ }, R = rr(t) ? ar(t.parent, m) : m;
785
785
  return bt(R.path.params, R.query.params, R.hash.params), R;
786
786
  }
787
- const Vt = { template: "<div>This is component</div>" }, he = gt({
787
+ const Vt = { template: "<div>This is component</div>" }, ye = gt({
788
788
  name: "parentA",
789
789
  path: "/parentA/[paramA]"
790
- }), ar = gt({
791
- parent: he,
790
+ }), ir = gt({
791
+ parent: ye,
792
792
  name: "parentA.childA",
793
793
  path: "/childA/[?paramB]"
794
- }), kn = gt({
795
- parent: he,
794
+ }), xn = gt({
795
+ parent: ye,
796
796
  name: "parentA.childB",
797
797
  path: "/childB/[paramD]",
798
798
  component: Vt
799
- }), xn = gt({
800
- parent: ar,
799
+ }), Nn = gt({
800
+ parent: ir,
801
801
  name: "parentA.childA.grandChildA",
802
802
  path: "/[paramC]",
803
803
  component: Vt
@@ -811,27 +811,27 @@ gt({
811
811
  path: "/",
812
812
  component: Vt
813
813
  });
814
- const Nn = "lazy", Ln = {
814
+ const Ln = "lazy", Un = {
815
815
  components: !0,
816
816
  props: !1
817
817
  };
818
818
  function Lt(t) {
819
819
  return ["eager", "lazy", "intent"].includes(t);
820
820
  }
821
- function sr({ routerPrefetch: t, routePrefetch: e, linkPrefetch: r }, n) {
822
- const o = zt(r, n), a = zt(e, n), s = zt(t, n), p = [
821
+ function cr({ routerPrefetch: t, routePrefetch: e, linkPrefetch: r }, n) {
822
+ const o = Qt(r, n), a = Qt(e, n), s = Qt(t, n), p = [
823
823
  o,
824
824
  a,
825
825
  s,
826
- Ln[n],
827
- Nn
826
+ Un[n],
827
+ Ln
828
828
  ].reduce((h, u) => Lt(h) ? h : h === !0 && Lt(u) ? u : h === !0 && !Lt(u) ? h : h === void 0 ? u : h, void 0);
829
829
  return Lt(p) ? p : !1;
830
830
  }
831
- function zt(t, e) {
831
+ function Qt(t, e) {
832
832
  return mt(t) ? t[e] : t;
833
833
  }
834
- class ir extends Error {
834
+ class ur extends Error {
835
835
  constructor() {
836
836
  super("Uncaught CallbackContextAbortError");
837
837
  T(this, "response");
@@ -852,7 +852,7 @@ class Zt extends Error {
852
852
  this.response = { status: "REJECT", type: r };
853
853
  }
854
854
  }
855
- function cr() {
855
+ function fr() {
856
856
  return { reject: (o) => {
857
857
  throw new Zt(o);
858
858
  }, push: (...o) => {
@@ -865,18 +865,18 @@ function cr() {
865
865
  const p = a, h = s ?? {};
866
866
  throw new yt([o, p, { ...h, replace: !0 }]);
867
867
  }, abort: () => {
868
- throw new ir();
868
+ throw new ur();
869
869
  } };
870
870
  }
871
- function be(t) {
871
+ function Pe(t) {
872
872
  try {
873
873
  const e = t();
874
- return ne(e) ? e.catch((r) => r) : e;
874
+ return oe(e) ? e.catch((r) => r) : e;
875
875
  } catch (e) {
876
876
  return e;
877
877
  }
878
878
  }
879
- function ur() {
879
+ function lr() {
880
880
  let t = null;
881
881
  function e(n) {
882
882
  t = n;
@@ -889,12 +889,12 @@ function ur() {
889
889
  runWithContext: r
890
890
  };
891
891
  }
892
- const fr = Symbol();
893
- function Un() {
894
- const { setVueApp: t, runWithContext: e } = ur(), r = _t(/* @__PURE__ */ new Map()), { push: n, replace: o, reject: a } = cr(), s = (v, i, f) => i.matches.filter((c) => sr({ ...f, routePrefetch: c.prefetch }, "props") === v).flatMap((c) => S(c)).reduce((c, { id: l, name: E, props: A }) => {
892
+ const pr = Symbol();
893
+ function Bn() {
894
+ const { setVueApp: t, runWithContext: e } = lr(), r = qt(/* @__PURE__ */ new Map()), { push: n, replace: o, reject: a } = fr(), s = (v, i, f) => i.matches.filter((c) => cr({ ...f, routePrefetch: c.prefetch }, "props") === v).flatMap((c) => S(c)).reduce((c, { id: l, name: E, props: A }) => {
895
895
  if (!A)
896
896
  return c;
897
- const P = L(l, E, i), g = e(() => be(() => A(i, {
897
+ const P = L(l, E, i), g = e(() => Pe(() => A(i, {
898
898
  push: n,
899
899
  replace: o,
900
900
  reject: a,
@@ -912,7 +912,7 @@ function Un() {
912
912
  continue;
913
913
  const P = L(l, E, v);
914
914
  if (f.push(P), !r.has(P)) {
915
- const g = e(() => be(() => A(v, {
915
+ const g = e(() => Pe(() => A(v, {
916
916
  push: n,
917
917
  replace: o,
918
918
  reject: a,
@@ -941,12 +941,12 @@ function Un() {
941
941
  function m(v, i = !1) {
942
942
  const f = v.matches.at(-2);
943
943
  if (f)
944
- return ve(f) ? {
944
+ return be(f) ? {
945
945
  name: f.name ?? "",
946
946
  get props() {
947
947
  return R(f, "default", v, i);
948
948
  }
949
- } : Ee(f) ? {
949
+ } : Se(f) ? {
950
950
  name: f.name ?? "",
951
951
  props: new Proxy({}, {
952
952
  get(c, l) {
@@ -973,13 +973,13 @@ function Un() {
973
973
  return [v, i, f.id, JSON.stringify(f.params)].join("-");
974
974
  }
975
975
  function S(v) {
976
- return ve(v) ? [
976
+ return be(v) ? [
977
977
  {
978
978
  id: v.id,
979
979
  name: "default",
980
980
  props: v.props
981
981
  }
982
- ] : Ee(v) ? Object.entries(v.props).map(([i, f]) => ({ id: v.id, name: i, props: f })) : [];
982
+ ] : Se(v) ? Object.entries(v.props).map(([i, f]) => ({ id: v.id, name: i, props: f })) : [];
983
983
  }
984
984
  function U(v) {
985
985
  for (const i of r.keys())
@@ -993,76 +993,76 @@ function Un() {
993
993
  setVueApp: t
994
994
  };
995
995
  }
996
- function lr() {
997
- const t = it(fr);
996
+ function dr() {
997
+ const t = it(pr);
998
998
  if (!t)
999
999
  throw new Et();
1000
1000
  return t;
1001
1001
  }
1002
- const Bn = Or(() => new Promise((t) => {
1002
+ const Cn = jr(() => new Promise((t) => {
1003
1003
  t({ default: { template: "foo" } });
1004
1004
  }));
1005
- function Se(t) {
1006
- return t.name === Bn.name && "__asyncLoader" in t;
1005
+ function Ae(t) {
1006
+ return t.name === Cn.name && "__asyncLoader" in t;
1007
1007
  }
1008
- const pr = Symbol("visibilityObserver");
1009
- function Cn(t) {
1010
- const e = it(pr);
1008
+ const hr = Symbol("visibilityObserver");
1009
+ function Vn(t) {
1010
+ const e = it(hr);
1011
1011
  if (!e)
1012
1012
  throw new Et();
1013
- return nt(t, (n, o) => {
1013
+ return ot(t, (n, o) => {
1014
1014
  n && e.observe(n), o && e.unobserve(o);
1015
- }, { immediate: !0 }), qt(() => {
1015
+ }, { immediate: !0 }), Ht(() => {
1016
1016
  t.value && e.unobserve(t.value);
1017
1017
  }), {
1018
- isElementVisible: Z(() => t.value ? e.isElementVisible(t.value) : !1)
1018
+ isElementVisible: O(() => t.value ? e.isElementVisible(t.value) : !1)
1019
1019
  };
1020
1020
  }
1021
- function Pe(t, e, r) {
1022
- nt(t, (n, o) => {
1021
+ function ke(t, e, r) {
1022
+ ot(t, (n, o) => {
1023
1023
  n && n.addEventListener(e, r), o && o.removeEventListener(e, r);
1024
- }, { immediate: !0 }), qt(() => {
1024
+ }, { immediate: !0 }), Ht(() => {
1025
1025
  t.value && t.value.removeEventListener(e, r);
1026
1026
  });
1027
1027
  }
1028
- function Vn(t) {
1029
- const e = /* @__PURE__ */ new Map(), r = Pt(), { getPrefetchProps: n, setPrefetchProps: o } = lr(), { isElementVisible: a } = Cn(r), s = () => {
1028
+ function Zn(t) {
1029
+ const e = /* @__PURE__ */ new Map(), r = Pt(), { getPrefetchProps: n, setPrefetchProps: o } = dr(), { isElementVisible: a } = Vn(r), s = () => {
1030
1030
  const u = Array.from(e.values()).reduce((m, R) => (Object.assign(m, R), m), {});
1031
1031
  o(u);
1032
1032
  };
1033
- nt(() => $(t), ({ route: u, ...m }) => {
1033
+ ot(() => V(t), ({ route: u, ...m }) => {
1034
1034
  e.clear(), u && h("eager", u, m);
1035
- }, { immediate: !0 }), nt(a, (u) => {
1036
- const { route: m, ...R } = $(t);
1035
+ }, { immediate: !0 }), ot(a, (u) => {
1036
+ const { route: m, ...R } = V(t);
1037
1037
  !m || !u || h("lazy", m, R);
1038
- }, { immediate: !0 }), Pe(r, "focusin", p), Pe(r, "mouseover", p);
1038
+ }, { immediate: !0 }), ke(r, "focusin", p), ke(r, "mouseover", p);
1039
1039
  function p() {
1040
- const { route: u, ...m } = $(t);
1040
+ const { route: u, ...m } = V(t);
1041
1041
  u && h("intent", u, m);
1042
1042
  }
1043
1043
  function h(u, m, R) {
1044
- Zn(u, m, R), e.has(u) || e.set(u, n(u, m, R));
1044
+ On(u, m, R), e.has(u) || e.set(u, n(u, m, R));
1045
1045
  }
1046
1046
  return {
1047
1047
  element: r,
1048
1048
  commit: s
1049
1049
  };
1050
1050
  }
1051
- function Zn(t, e, r) {
1051
+ function On(t, e, r) {
1052
1052
  e.matches.forEach((n) => {
1053
- sr({
1053
+ cr({
1054
1054
  ...r,
1055
1055
  routePrefetch: n.prefetch
1056
- }, "components") === t && (er(n) && Se(n.component) && n.component.__asyncLoader(), rr(n) && Object.values(n.components).forEach((a) => {
1057
- Se(a) && a.__asyncLoader();
1056
+ }, "components") === t && (nr(n) && Ae(n.component) && n.component.__asyncLoader(), or(n) && Object.values(n.components).forEach((a) => {
1057
+ Ae(a) && a.__asyncLoader();
1058
1058
  }));
1059
1059
  });
1060
1060
  }
1061
- const dr = Symbol("isRouterRouteSymbol");
1062
- function On(t) {
1063
- return typeof t == "object" && t !== null && dr in t;
1061
+ const yr = Symbol("isRouterRouteSymbol");
1062
+ function jn(t) {
1063
+ return typeof t == "object" && t !== null && yr in t;
1064
1064
  }
1065
- function jn(t, e) {
1065
+ function $n(t, e) {
1066
1066
  function r(i, f, c) {
1067
1067
  if (typeof i == "object") {
1068
1068
  const E = {
@@ -1086,7 +1086,7 @@ function jn(t, e) {
1086
1086
  }, a = (...i) => {
1087
1087
  const f = new URLSearchParams(t.query);
1088
1088
  f.delete(...i), r({}, { query: f });
1089
- }, { id: s, matched: p, matches: h, name: u, hash: m, href: R } = jr(t), L = Z({
1089
+ }, { id: s, matched: p, matches: h, name: u, hash: m, href: R } = $r(t), L = O({
1090
1090
  get() {
1091
1091
  return new Proxy(t.params, {
1092
1092
  set(i, f, c) {
@@ -1097,7 +1097,7 @@ function jn(t, e) {
1097
1097
  set(i) {
1098
1098
  r(i);
1099
1099
  }
1100
- }), S = Z({
1100
+ }), S = O({
1101
1101
  get() {
1102
1102
  return new Proxy(t.query, {
1103
1103
  get(i, f, c) {
@@ -1117,7 +1117,7 @@ function jn(t, e) {
1117
1117
  set(i) {
1118
1118
  r({}, { query: i });
1119
1119
  }
1120
- }), U = Z({
1120
+ }), U = O({
1121
1121
  get() {
1122
1122
  return new Proxy(t.state, {
1123
1123
  set(i, f, c) {
@@ -1129,7 +1129,7 @@ function jn(t, e) {
1129
1129
  r({}, { state: i });
1130
1130
  }
1131
1131
  });
1132
- return _t({
1132
+ return qt({
1133
1133
  id: s,
1134
1134
  matched: p,
1135
1135
  matches: h,
@@ -1140,13 +1140,13 @@ function jn(t, e) {
1140
1140
  name: u,
1141
1141
  href: R,
1142
1142
  update: r,
1143
- [dr]: !0
1143
+ [yr]: !0
1144
1144
  });
1145
1145
  }
1146
- function ee(t, e, { exact: r } = {}) {
1147
- return On(t) ? e === void 0 ? !0 : r ? t.matched.name === e : t.matches.map((n) => n.name).includes(e) : !1;
1146
+ function re(t, e, { exact: r } = {}) {
1147
+ return jn(t) ? e === void 0 ? !0 : r ? t.matched.name === e : t.matches.map((n) => n.name).includes(e) : !1;
1148
1148
  }
1149
- function ye(...t) {
1149
+ function me(...t) {
1150
1150
  const e = new URLSearchParams();
1151
1151
  for (const r of t) {
1152
1152
  const n = new URLSearchParams(r);
@@ -1155,30 +1155,30 @@ function ye(...t) {
1155
1155
  }
1156
1156
  return e;
1157
1157
  }
1158
- function $n(t, e = {}, r = {}) {
1159
- const n = It(), o = Z(() => {
1160
- const i = $(t);
1161
- return typeof i != "string" ? i : M(i) ? n.find(i, $(r)) : n.resolve(i, $(e), $(r));
1162
- }), a = Z(() => {
1158
+ function _n(t, e = {}, r = {}) {
1159
+ const n = It(), o = O(() => {
1160
+ const i = V(t);
1161
+ return typeof i != "string" ? i : M(i) ? n.find(i, V(r)) : n.resolve(i, V(e), V(r));
1162
+ }), a = O(() => {
1163
1163
  if (o.value)
1164
1164
  return o.value.href;
1165
- const i = $(t);
1165
+ const i = V(t);
1166
1166
  if (M(i))
1167
1167
  return i;
1168
1168
  console.error(new Error("Failed to resolve route in RouterLink."));
1169
- }), s = Z(() => ee(n.route) && n.route.matches.some((i) => {
1169
+ }), s = O(() => re(n.route) && n.route.matches.some((i) => {
1170
1170
  var f;
1171
1171
  return i.id === ((f = o.value) == null ? void 0 : f.id);
1172
- })), p = Z(() => {
1172
+ })), p = O(() => {
1173
1173
  var i;
1174
1174
  return n.route.id === ((i = o.value) == null ? void 0 : i.id);
1175
- }), h = Z(() => ee(n.route) && Xr(o.value) && n.route.href.startsWith(o.value.href)), u = Z(() => {
1175
+ }), h = O(() => re(n.route) && en(o.value) && n.route.href.startsWith(o.value.href)), u = O(() => {
1176
1176
  var i;
1177
1177
  return n.route.href === ((i = o.value) == null ? void 0 : i.href);
1178
- }), m = Z(() => !!a.value && n.isExternal(a.value)), R = Z(() => {
1179
- const i = $(t);
1180
- return typeof i != "string" || M(i) ? $(e) : $(r);
1181
- }), { element: L, commit: S } = Vn(() => ({
1178
+ }), m = O(() => !!a.value && n.isExternal(a.value)), R = O(() => {
1179
+ const i = V(t);
1180
+ return typeof i != "string" || M(i) ? V(e) : V(r);
1181
+ }), { element: L, commit: S } = Zn(() => ({
1182
1182
  route: o.value,
1183
1183
  routerPrefetch: n.prefetch,
1184
1184
  linkPrefetch: R.value.prefetch
@@ -1186,11 +1186,11 @@ function $n(t, e = {}, r = {}) {
1186
1186
  S();
1187
1187
  const f = {
1188
1188
  replace: (i == null ? void 0 : i.replace) ?? R.value.replace,
1189
- query: ye(R.value.query, i == null ? void 0 : i.query),
1189
+ query: me(R.value.query, i == null ? void 0 : i.query),
1190
1190
  hash: (i == null ? void 0 : i.hash) ?? R.value.hash,
1191
1191
  state: { ...R.value.state, ...i == null ? void 0 : i.state }
1192
- }, c = $(t);
1193
- return M(c) || typeof c == "object" ? n.push(c, f) : n.push(c, $(e), f);
1192
+ }, c = V(t);
1193
+ return M(c) || typeof c == "object" ? n.push(c, f) : n.push(c, V(e), f);
1194
1194
  };
1195
1195
  return {
1196
1196
  element: L,
@@ -1205,8 +1205,10 @@ function $n(t, e = {}, r = {}) {
1205
1205
  replace: (i) => U({ ...i, replace: !0 })
1206
1206
  };
1207
1207
  }
1208
- const Hn = ["href"], _n = /* @__PURE__ */ vt({
1209
- __name: "routerLink",
1208
+ const qn = ["href"], Hn = {
1209
+ name: "RouterLink"
1210
+ }, In = /* @__PURE__ */ vt({
1211
+ ...Hn,
1210
1212
  props: {
1211
1213
  to: {},
1212
1214
  prefetch: { type: [Boolean, String, Object], default: void 0 },
@@ -1216,10 +1218,10 @@ const Hn = ["href"], _n = /* @__PURE__ */ vt({
1216
1218
  state: {}
1217
1219
  },
1218
1220
  setup(t) {
1219
- const e = t, r = It(), n = Z(() => U(e.to)), o = Z(() => v(e.to)), a = Z(() => {
1221
+ const e = t, r = It(), n = O(() => U(e.to)), o = O(() => v(e.to)), a = O(() => {
1220
1222
  const { to: f, ...c } = e;
1221
1223
  return c;
1222
- }), { element: s, isMatch: p, isExactMatch: h, isActive: u, isExactActive: m, isExternal: R, push: L } = $n(() => typeof e.to == "function" ? e.to(r.resolve) : e.to, a), S = Z(() => ({
1224
+ }), { element: s, isMatch: p, isExactMatch: h, isActive: u, isExactActive: m, isExternal: R, push: L } = _n(() => typeof e.to == "function" ? e.to(r.resolve) : e.to, a), S = O(() => ({
1223
1225
  "router-link--match": p.value,
1224
1226
  "router-link--exact-match": h.value,
1225
1227
  "router-link--active": u.value,
@@ -1242,112 +1244,146 @@ const Hn = ["href"], _n = /* @__PURE__ */ vt({
1242
1244
  function i(f) {
1243
1245
  f.preventDefault(), L();
1244
1246
  }
1245
- return (f, c) => (Oe(), $r("a", {
1247
+ return (f, c) => ($e(), _r("a", {
1246
1248
  ref_key: "element",
1247
1249
  ref: s,
1248
1250
  href: o.value,
1249
- class: Hr(["router-link", S.value]),
1251
+ class: qr(["router-link", S.value]),
1250
1252
  onClick: i
1251
1253
  }, [
1252
- je(f.$slots, "default", $e(_r({ route: n.value, isMatch: X(p), isExactMatch: X(h), isActive: X(u), isExactActive: X(m), isExternal: X(R) })))
1253
- ], 10, Hn));
1254
+ _e(f.$slots, "default", qe(Hr({ route: n.value, isMatch: tt(p), isExactMatch: tt(h), isActive: tt(u), isExactActive: tt(m), isExternal: tt(R) })))
1255
+ ], 10, qn));
1254
1256
  }
1255
- }), hr = Symbol();
1256
- function qn() {
1257
- const t = it(hr);
1257
+ }), mr = Symbol();
1258
+ function Dn() {
1259
+ const t = it(mr);
1258
1260
  if (!t)
1259
1261
  throw new Et();
1260
1262
  return t;
1261
1263
  }
1262
- function yr(t, e) {
1264
+ function ge(t, e) {
1263
1265
  const r = It();
1264
1266
  function n() {
1265
1267
  if (!t)
1266
1268
  return;
1267
- if (!ee(r.route, t, e))
1268
- throw new Gr(t, r.route.name);
1269
+ if (!re(r.route, t, e))
1270
+ throw new zr(t, r.route.name);
1269
1271
  }
1270
- return nt(r.route, n, { immediate: !0, deep: !0 }), r.route;
1272
+ return ot(r.route, n, { immediate: !0, deep: !0 }), r.route;
1271
1273
  }
1272
- const mr = Symbol();
1273
- function me() {
1274
- return it(mr, 0);
1274
+ const gr = Symbol();
1275
+ function Re() {
1276
+ return it(gr, 0);
1275
1277
  }
1276
- function In(t, e, r) {
1278
+ function Jn(t, e, r) {
1277
1279
  return vt({
1278
1280
  name: "PropsWrapper",
1279
1281
  expose: [],
1280
1282
  setup() {
1281
- const n = qr(), o = lr(), a = yr();
1283
+ const n = Ir(), o = dr(), a = ge();
1282
1284
  return () => {
1283
1285
  const s = o.getProps(t.id, e, a);
1284
- return s instanceof Error ? "" : ne(s) ? n != null && n.suspense ? dt(Jn, { component: r, props: s }) : dt(Dn, { component: r, props: s }) : dt(r, s);
1286
+ return s instanceof Error ? "" : oe(s) ? n != null && n.suspense ? dt(Tn, { component: r, props: s }) : dt(Fn, { component: r, props: s }) : dt(r, s);
1285
1287
  };
1286
1288
  }
1287
1289
  });
1288
1290
  }
1289
- const Dn = vt((t) => {
1291
+ const Fn = vt((t) => {
1290
1292
  const e = Pt();
1291
- return nt(() => t.props, async (r) => {
1293
+ return ot(() => t.props, async (r) => {
1292
1294
  e.value = await r;
1293
1295
  }, { immediate: !0, deep: !0 }), () => e.value instanceof Error ? "" : e.value ? dt(t.component, e.value) : "";
1294
1296
  }, {
1295
1297
  props: ["component", "props"]
1296
- }), Jn = vt(async (t) => {
1298
+ }), Tn = vt(async (t) => {
1297
1299
  const e = Pt();
1298
- return e.value = await t.props, nt(() => e.value, async (r) => {
1300
+ return e.value = await t.props, ot(() => e.value, async (r) => {
1299
1301
  e.value = await r;
1300
1302
  }, { deep: !0 }), () => e.value instanceof Error ? "" : e.value ? dt(t.component, e.value) : "";
1301
1303
  }, {
1302
1304
  props: ["component", "props"]
1303
- }), gr = Symbol();
1304
- function Fn() {
1305
+ }), Rr = Symbol();
1306
+ function Mn() {
1305
1307
  const t = /* @__PURE__ */ new Map();
1306
1308
  return {
1307
1309
  getRouteComponents: (r) => {
1308
1310
  const n = t.get(r.id);
1309
1311
  if (n)
1310
1312
  return n;
1311
- const o = Tn(r);
1313
+ const o = Wn(r);
1312
1314
  return t.set(r.id, o), o;
1313
1315
  }
1314
1316
  };
1315
1317
  }
1316
- function Tn(t) {
1317
- return rr(t) ? Ae(t, t.components) : er(t) ? Ae(t, { default: t.component }) : { default: Rr };
1318
+ function Wn(t) {
1319
+ return or(t) ? xe(t, t.components) : nr(t) ? xe(t, { default: t.component }) : { default: wr };
1318
1320
  }
1319
- function Ae(t, e) {
1321
+ function xe(t, e) {
1320
1322
  return Object.fromEntries(
1321
- Object.entries(e).map(([r, n]) => [r, In(t, r, n)])
1323
+ Object.entries(e).map(([r, n]) => [r, Jn(t, r, n)])
1322
1324
  );
1323
1325
  }
1324
- function Mn() {
1325
- const t = it(gr);
1326
+ function Gn() {
1327
+ const t = it(Rr);
1326
1328
  if (!t)
1327
1329
  throw new Et();
1328
1330
  return t;
1329
1331
  }
1330
- const Rr = /* @__PURE__ */ vt({
1331
- __name: "routerView",
1332
+ const Qn = {
1333
+ name: "RouterView"
1334
+ }, wr = /* @__PURE__ */ vt({
1335
+ ...Qn,
1332
1336
  props: {
1333
1337
  name: { default: "default" }
1334
1338
  },
1335
1339
  setup(t) {
1336
- const e = yr(), { started: r } = It(), n = qn(), o = me(), { getRouteComponents: a } = Mn();
1337
- Ir(mr, o + 1);
1338
- const s = Z(() => {
1339
- if (!r.value)
1340
+ const e = ge(), r = It(), n = Dn(), o = Re();
1341
+ Dr(async () => {
1342
+ await r.start();
1343
+ });
1344
+ const { getRouteComponents: a } = Gn();
1345
+ Jr(gr, o + 1);
1346
+ const s = O(() => {
1347
+ if (!r.started.value)
1340
1348
  return null;
1341
1349
  if (n.value)
1342
1350
  return n.value.component;
1343
1351
  const p = e.matches.at(o);
1344
1352
  return p ? a(p)[t.name] : null;
1345
1353
  });
1346
- return (p, h) => s.value ? je(p.$slots, "default", $e(Jr({ key: 0 }, { route: X(e), component: s.value, rejection: X(n) })), () => [
1347
- (Oe(), Fr(Tr(s.value)))
1348
- ]) : Dr("", !0);
1354
+ return (p, h) => s.value ? _e(p.$slots, "default", qe(Tr({ key: 0 }, { route: tt(e), component: s.value, rejection: tt(n) })), () => [
1355
+ ($e(), Mr(Wr(s.value)))
1356
+ ]) : Fr("", !0);
1349
1357
  }
1350
1358
  });
1359
+ function Do(t, e = String) {
1360
+ const r = ge(), n = O({
1361
+ get() {
1362
+ const a = r.query.get(V(t));
1363
+ return a === null ? null : ee(a, e);
1364
+ },
1365
+ set(a) {
1366
+ r.query.set(V(t), z(a, e));
1367
+ }
1368
+ }), o = O({
1369
+ get() {
1370
+ return r.query.getAll(V(t)).map((s) => ee(s, e)).filter((s) => s !== null);
1371
+ },
1372
+ set(a) {
1373
+ const s = new URLSearchParams(r.query);
1374
+ s.delete(V(t)), a.forEach((p) => {
1375
+ s.append(V(t), z(p, e));
1376
+ }), r.query = s;
1377
+ }
1378
+ });
1379
+ return {
1380
+ value: n,
1381
+ values: o,
1382
+ remove: () => {
1383
+ r.query.delete(V(t));
1384
+ }
1385
+ };
1386
+ }
1351
1387
  class st {
1352
1388
  constructor() {
1353
1389
  T(this, "onBeforeRouteEnter", /* @__PURE__ */ new Set());
@@ -1370,7 +1406,7 @@ const kt = (t, e, r) => {
1370
1406
  var n, o;
1371
1407
  return ((n = t.matches.at(r)) == null ? void 0 : n.id) === ((o = e == null ? void 0 : e.matches.at(r)) == null ? void 0 : o.id);
1372
1408
  };
1373
- function ke(t) {
1409
+ function Ne(t) {
1374
1410
  switch (t) {
1375
1411
  case "onBeforeRouteEnter":
1376
1412
  case "onAfterRouteEnter":
@@ -1385,7 +1421,7 @@ function ke(t) {
1385
1421
  throw new Error(`Switch is not exhaustive for lifecycle: ${t}`);
1386
1422
  }
1387
1423
  }
1388
- function Wn(t, e) {
1424
+ function zn(t, e) {
1389
1425
  const r = new st();
1390
1426
  return t.matches.forEach((n, o) => {
1391
1427
  n.onBeforeRouteEnter && kt(t, e, o) && ht(n.onBeforeRouteEnter).forEach((a) => r.onBeforeRouteEnter.add(a)), n.onBeforeRouteUpdate && Nt(t, e, o) && ht(n.onBeforeRouteUpdate).forEach((a) => r.onBeforeRouteUpdate.add(a));
@@ -1393,7 +1429,7 @@ function Wn(t, e) {
1393
1429
  n.onBeforeRouteLeave && xt(t, e, o) && ht(n.onBeforeRouteLeave).forEach((a) => r.onBeforeRouteLeave.add(a));
1394
1430
  }), r;
1395
1431
  }
1396
- function Gn(t, e) {
1432
+ function Kn(t, e) {
1397
1433
  const r = new st();
1398
1434
  return t.matches.forEach((n, o) => {
1399
1435
  n.onAfterRouteEnter && kt(t, e, o) && ht(n.onAfterRouteEnter).forEach((a) => r.onAfterRouteEnter.add(a)), n.onAfterRouteUpdate && Nt(t, e, o) && ht(n.onAfterRouteUpdate).forEach((a) => r.onAfterRouteUpdate.add(a));
@@ -1401,7 +1437,7 @@ function Gn(t, e) {
1401
1437
  n.onAfterRouteLeave && xt(t, e, o) && ht(n.onAfterRouteLeave).forEach((a) => r.onAfterRouteLeave.add(a));
1402
1438
  }), r;
1403
1439
  }
1404
- function zn(t, e, r) {
1440
+ function Yn(t, e, r) {
1405
1441
  const n = new st();
1406
1442
  return t.matches.forEach((o, a) => {
1407
1443
  kt(t, e, a) && r.onBeforeRouteEnter.forEach((s) => n.onBeforeRouteEnter.add(s)), Nt(t, e, a) && r.onBeforeRouteUpdate.forEach((s) => n.onBeforeRouteUpdate.add(s));
@@ -1409,7 +1445,7 @@ function zn(t, e, r) {
1409
1445
  xt(t, e, a) && r.onBeforeRouteLeave.forEach((s) => n.onBeforeRouteLeave.add(s));
1410
1446
  }), n;
1411
1447
  }
1412
- function Qn(t, e, r) {
1448
+ function Xn(t, e, r) {
1413
1449
  const n = new st();
1414
1450
  return t.matches.forEach((o, a) => {
1415
1451
  kt(t, e, a) && r.onAfterRouteEnter.forEach((s) => n.onAfterRouteEnter.add(s)), Nt(t, e, a) && r.onAfterRouteUpdate.forEach((s) => n.onAfterRouteUpdate.add(s));
@@ -1417,14 +1453,14 @@ function Qn(t, e, r) {
1417
1453
  xt(t, e, a) && r.onAfterRouteLeave.forEach((s) => n.onAfterRouteLeave.add(s));
1418
1454
  }), n;
1419
1455
  }
1420
- const wr = Symbol();
1421
- function Kn() {
1422
- const { setVueApp: t, runWithContext: e } = ur(), r = {
1456
+ const vr = Symbol();
1457
+ function to() {
1458
+ const { setVueApp: t, runWithContext: e } = lr(), r = {
1423
1459
  global: new st(),
1424
1460
  component: new st()
1425
- }, { reject: n, push: o, replace: a, abort: s } = cr(), p = (c) => (r.global.onBeforeRouteEnter.add(c), () => r.global.onBeforeRouteEnter.delete(c)), h = (c) => (r.global.onBeforeRouteUpdate.add(c), () => r.global.onBeforeRouteUpdate.delete(c)), u = (c) => (r.global.onBeforeRouteLeave.add(c), () => r.global.onBeforeRouteLeave.delete(c)), m = (c) => (r.global.onAfterRouteEnter.add(c), () => r.global.onAfterRouteEnter.delete(c)), R = (c) => (r.global.onAfterRouteUpdate.add(c), () => r.global.onAfterRouteUpdate.delete(c)), L = (c) => (r.global.onAfterRouteLeave.add(c), () => r.global.onAfterRouteLeave.delete(c));
1461
+ }, { reject: n, push: o, replace: a, abort: s } = fr(), p = (c) => (r.global.onBeforeRouteEnter.add(c), () => r.global.onBeforeRouteEnter.delete(c)), h = (c) => (r.global.onBeforeRouteUpdate.add(c), () => r.global.onBeforeRouteUpdate.delete(c)), u = (c) => (r.global.onBeforeRouteLeave.add(c), () => r.global.onBeforeRouteLeave.delete(c)), m = (c) => (r.global.onAfterRouteEnter.add(c), () => r.global.onAfterRouteEnter.delete(c)), R = (c) => (r.global.onAfterRouteUpdate.add(c), () => r.global.onAfterRouteUpdate.delete(c)), L = (c) => (r.global.onAfterRouteLeave.add(c), () => r.global.onAfterRouteLeave.delete(c));
1426
1462
  async function S({ to: c, from: l }) {
1427
- const { global: E, component: A } = r, P = Wn(c, l), g = zn(c, l, E), d = [
1463
+ const { global: E, component: A } = r, P = zn(c, l), g = Yn(c, l, E), d = [
1428
1464
  ...g.onBeforeRouteEnter,
1429
1465
  ...P.onBeforeRouteEnter,
1430
1466
  ...g.onBeforeRouteUpdate,
@@ -1444,7 +1480,7 @@ function Kn() {
1444
1480
  })));
1445
1481
  await Promise.all(y);
1446
1482
  } catch (y) {
1447
- if (y instanceof yt || y instanceof Zt || y instanceof ir)
1483
+ if (y instanceof yt || y instanceof Zt || y instanceof ur)
1448
1484
  return y.response;
1449
1485
  throw y;
1450
1486
  }
@@ -1453,7 +1489,7 @@ function Kn() {
1453
1489
  };
1454
1490
  }
1455
1491
  async function U({ to: c, from: l }) {
1456
- const { global: E, component: A } = r, P = Gn(c, l), g = Qn(c, l, E), d = [
1492
+ const { global: E, component: A } = r, P = Kn(c, l), g = Xn(c, l, E), d = [
1457
1493
  ...A.onAfterRouteLeave,
1458
1494
  ...P.onAfterRouteLeave,
1459
1495
  ...g.onAfterRouteLeave,
@@ -1485,14 +1521,14 @@ function Kn() {
1485
1521
  runBeforeRouteHooks: S,
1486
1522
  runAfterRouteHooks: U,
1487
1523
  addComponentBeforeRouteHook: ({ lifecycle: c, depth: l, hook: E }) => {
1488
- const A = ke(c), P = r.component[c], g = (d, y) => {
1524
+ const A = Ne(c), P = r.component[c], g = (d, y) => {
1489
1525
  if (A(d, y.from, l))
1490
1526
  return E(d, y);
1491
1527
  };
1492
1528
  return P.add(g), () => P.delete(g);
1493
1529
  },
1494
1530
  addComponentAfterRouteHook: ({ lifecycle: c, depth: l, hook: E }) => {
1495
- const A = ke(c), P = r.component[c], g = (d, y) => {
1531
+ const A = Ne(c), P = r.component[c], g = (d, y) => {
1496
1532
  if (A(d, y.from, l))
1497
1533
  return E(d, y);
1498
1534
  };
@@ -1510,44 +1546,44 @@ function Kn() {
1510
1546
  setVueApp: t
1511
1547
  };
1512
1548
  }
1513
- function vr() {
1514
- const t = it(wr);
1549
+ function Er() {
1550
+ const t = it(vr);
1515
1551
  if (!t)
1516
1552
  throw new Et();
1517
1553
  return t;
1518
1554
  }
1519
- function Er(t) {
1555
+ function br(t) {
1520
1556
  return (e) => {
1521
- const r = me(), o = vr().addComponentBeforeRouteHook({ lifecycle: t, hook: e, depth: r - 1 });
1522
- return qt(o), o;
1557
+ const r = Re(), o = Er().addComponentBeforeRouteHook({ lifecycle: t, hook: e, depth: r - 1 });
1558
+ return Ht(o), o;
1523
1559
  };
1524
1560
  }
1525
- function br(t) {
1561
+ function Sr(t) {
1526
1562
  return (e) => {
1527
- const r = me(), o = vr().addComponentAfterRouteHook({ lifecycle: t, hook: e, depth: r - 1 });
1528
- return qt(o), o;
1563
+ const r = Re(), o = Er().addComponentAfterRouteHook({ lifecycle: t, hook: e, depth: r - 1 });
1564
+ return Ht(o), o;
1529
1565
  };
1530
1566
  }
1531
- const _o = Er("onBeforeRouteLeave"), qo = Er("onBeforeRouteUpdate"), Io = br("onAfterRouteLeave"), Do = br("onAfterRouteUpdate");
1532
- function Y() {
1533
- return Y = Object.assign ? Object.assign.bind() : function(t) {
1567
+ const Jo = br("onBeforeRouteLeave"), Fo = br("onBeforeRouteUpdate"), To = Sr("onAfterRouteLeave"), Mo = Sr("onAfterRouteUpdate");
1568
+ function X() {
1569
+ return X = Object.assign ? Object.assign.bind() : function(t) {
1534
1570
  for (var e = 1; e < arguments.length; e++) {
1535
1571
  var r = arguments[e];
1536
1572
  for (var n in r) ({}).hasOwnProperty.call(r, n) && (t[n] = r[n]);
1537
1573
  }
1538
1574
  return t;
1539
- }, Y.apply(null, arguments);
1575
+ }, X.apply(null, arguments);
1540
1576
  }
1541
- var j;
1577
+ var $;
1542
1578
  (function(t) {
1543
1579
  t.Pop = "POP", t.Push = "PUSH", t.Replace = "REPLACE";
1544
- })(j || (j = {}));
1580
+ })($ || ($ = {}));
1545
1581
  var Rt = process.env.NODE_ENV !== "production" ? function(t) {
1546
1582
  return Object.freeze(t);
1547
1583
  } : function(t) {
1548
1584
  return t;
1549
1585
  };
1550
- function et(t, e) {
1586
+ function rt(t, e) {
1551
1587
  if (!t) {
1552
1588
  typeof console < "u" && console.warn(e);
1553
1589
  try {
@@ -1556,8 +1592,8 @@ function et(t, e) {
1556
1592
  }
1557
1593
  }
1558
1594
  }
1559
- var Ot = "beforeunload", Yn = "hashchange", Sr = "popstate";
1560
- function xe(t) {
1595
+ var Ot = "beforeunload", eo = "hashchange", Pr = "popstate";
1596
+ function Le(t) {
1561
1597
  t === void 0 && (t = {});
1562
1598
  var e = t, r = e.window, n = r === void 0 ? document.defaultView : r, o = n.history;
1563
1599
  function a() {
@@ -1575,7 +1611,7 @@ function xe(t) {
1575
1611
  if (s)
1576
1612
  S.call(s), s = null;
1577
1613
  else {
1578
- var g = j.Pop, d = a(), y = d[0], k = d[1];
1614
+ var g = $.Pop, d = a(), y = d[0], k = d[1];
1579
1615
  if (S.length)
1580
1616
  if (y != null) {
1581
1617
  var x = m - y;
@@ -1587,7 +1623,7 @@ function xe(t) {
1587
1623
  }
1588
1624
  }, A(x));
1589
1625
  } else
1590
- process.env.NODE_ENV !== "production" && et(
1626
+ process.env.NODE_ENV !== "production" && rt(
1591
1627
  !1,
1592
1628
  // TODO: Write up a doc that explains our blocking strategy in
1593
1629
  // detail and link to it here so people can understand better what
@@ -1598,16 +1634,16 @@ function xe(t) {
1598
1634
  c(g);
1599
1635
  }
1600
1636
  }
1601
- n.addEventListener(Sr, p);
1602
- var h = j.Pop, u = a(), m = u[0], R = u[1], L = wt(), S = wt();
1603
- m == null && (m = 0, o.replaceState(Y({}, o.state, {
1637
+ n.addEventListener(Pr, p);
1638
+ var h = $.Pop, u = a(), m = u[0], R = u[1], L = wt(), S = wt();
1639
+ m == null && (m = 0, o.replaceState(X({}, o.state, {
1604
1640
  idx: m
1605
1641
  }), ""));
1606
1642
  function U(g) {
1607
- return typeof g == "string" ? g : rt(g);
1643
+ return typeof g == "string" ? g : nt(g);
1608
1644
  }
1609
1645
  function v(g, d) {
1610
- return d === void 0 && (d = null), Rt(Y({
1646
+ return d === void 0 && (d = null), Rt(X({
1611
1647
  pathname: R.pathname,
1612
1648
  hash: "",
1613
1649
  search: ""
@@ -1639,28 +1675,28 @@ function xe(t) {
1639
1675
  });
1640
1676
  }
1641
1677
  function l(g, d) {
1642
- var y = j.Push, k = v(g, d);
1678
+ var y = $.Push, k = v(g, d);
1643
1679
  function x() {
1644
1680
  l(g, d);
1645
1681
  }
1646
1682
  if (f(y, k, x)) {
1647
- var C = i(k, m + 1), O = C[0], H = C[1];
1683
+ var C = i(k, m + 1), j = C[0], _ = C[1];
1648
1684
  try {
1649
- o.pushState(O, "", H);
1685
+ o.pushState(j, "", _);
1650
1686
  } catch {
1651
- n.location.assign(H);
1687
+ n.location.assign(_);
1652
1688
  }
1653
1689
  c(y);
1654
1690
  }
1655
1691
  }
1656
1692
  function E(g, d) {
1657
- var y = j.Replace, k = v(g, d);
1693
+ var y = $.Replace, k = v(g, d);
1658
1694
  function x() {
1659
1695
  E(g, d);
1660
1696
  }
1661
1697
  if (f(y, k, x)) {
1662
- var C = i(k, m), O = C[0], H = C[1];
1663
- o.replaceState(O, "", H), c(y);
1698
+ var C = i(k, m), j = C[0], _ = C[1];
1699
+ o.replaceState(j, "", _), c(y);
1664
1700
  }
1665
1701
  }
1666
1702
  function A(g) {
@@ -1695,17 +1731,17 @@ function xe(t) {
1695
1731
  };
1696
1732
  return P;
1697
1733
  }
1698
- function Xn(t) {
1734
+ function ro(t) {
1699
1735
  t === void 0 && (t = {});
1700
1736
  var e = t, r = e.window, n = r === void 0 ? document.defaultView : r, o = n.history;
1701
1737
  function a() {
1702
- var d = St(n.location.hash.substr(1)), y = d.pathname, k = y === void 0 ? "/" : y, x = d.search, C = x === void 0 ? "" : x, O = d.hash, H = O === void 0 ? "" : O, _ = o.state || {};
1703
- return [_.idx, Rt({
1738
+ var d = St(n.location.hash.substr(1)), y = d.pathname, k = y === void 0 ? "/" : y, x = d.search, C = x === void 0 ? "" : x, j = d.hash, _ = j === void 0 ? "" : j, q = o.state || {};
1739
+ return [q.idx, Rt({
1704
1740
  pathname: k,
1705
1741
  search: C,
1706
- hash: H,
1707
- state: _.usr || null,
1708
- key: _.key || "default"
1742
+ hash: _,
1743
+ state: q.usr || null,
1744
+ key: q.key || "default"
1709
1745
  })];
1710
1746
  }
1711
1747
  var s = null;
@@ -1713,7 +1749,7 @@ function Xn(t) {
1713
1749
  if (s)
1714
1750
  S.call(s), s = null;
1715
1751
  else {
1716
- var d = j.Pop, y = a(), k = y[0], x = y[1];
1752
+ var d = $.Pop, y = a(), k = y[0], x = y[1];
1717
1753
  if (S.length)
1718
1754
  if (k != null) {
1719
1755
  var C = m - k;
@@ -1725,7 +1761,7 @@ function Xn(t) {
1725
1761
  }
1726
1762
  }, P(C));
1727
1763
  } else
1728
- process.env.NODE_ENV !== "production" && et(
1764
+ process.env.NODE_ENV !== "production" && rt(
1729
1765
  !1,
1730
1766
  // TODO: Write up a doc that explains our blocking strategy in
1731
1767
  // detail and link to it here so people can understand better
@@ -1736,12 +1772,12 @@ function Xn(t) {
1736
1772
  l(d);
1737
1773
  }
1738
1774
  }
1739
- n.addEventListener(Sr, p), n.addEventListener(Yn, function() {
1775
+ n.addEventListener(Pr, p), n.addEventListener(eo, function() {
1740
1776
  var d = a(), y = d[1];
1741
- rt(y) !== rt(R) && p();
1777
+ nt(y) !== nt(R) && p();
1742
1778
  });
1743
- var h = j.Pop, u = a(), m = u[0], R = u[1], L = wt(), S = wt();
1744
- m == null && (m = 0, o.replaceState(Y({}, o.state, {
1779
+ var h = $.Pop, u = a(), m = u[0], R = u[1], L = wt(), S = wt();
1780
+ m == null && (m = 0, o.replaceState(X({}, o.state, {
1745
1781
  idx: m
1746
1782
  }), ""));
1747
1783
  function U() {
@@ -1753,10 +1789,10 @@ function Xn(t) {
1753
1789
  return y;
1754
1790
  }
1755
1791
  function v(d) {
1756
- return U() + "#" + (typeof d == "string" ? d : rt(d));
1792
+ return U() + "#" + (typeof d == "string" ? d : nt(d));
1757
1793
  }
1758
1794
  function i(d, y) {
1759
- return y === void 0 && (y = null), Rt(Y({
1795
+ return y === void 0 && (y = null), Rt(X({
1760
1796
  pathname: R.pathname,
1761
1797
  hash: "",
1762
1798
  search: ""
@@ -1788,28 +1824,28 @@ function Xn(t) {
1788
1824
  });
1789
1825
  }
1790
1826
  function E(d, y) {
1791
- var k = j.Push, x = i(d, y);
1827
+ var k = $.Push, x = i(d, y);
1792
1828
  function C() {
1793
1829
  E(d, y);
1794
1830
  }
1795
- if (process.env.NODE_ENV !== "production" && et(x.pathname.charAt(0) === "/", "Relative pathnames are not supported in hash history.push(" + JSON.stringify(d) + ")"), c(k, x, C)) {
1796
- var O = f(x, m + 1), H = O[0], _ = O[1];
1831
+ if (process.env.NODE_ENV !== "production" && rt(x.pathname.charAt(0) === "/", "Relative pathnames are not supported in hash history.push(" + JSON.stringify(d) + ")"), c(k, x, C)) {
1832
+ var j = f(x, m + 1), _ = j[0], q = j[1];
1797
1833
  try {
1798
- o.pushState(H, "", _);
1834
+ o.pushState(_, "", q);
1799
1835
  } catch {
1800
- n.location.assign(_);
1836
+ n.location.assign(q);
1801
1837
  }
1802
1838
  l(k);
1803
1839
  }
1804
1840
  }
1805
1841
  function A(d, y) {
1806
- var k = j.Replace, x = i(d, y);
1842
+ var k = $.Replace, x = i(d, y);
1807
1843
  function C() {
1808
1844
  A(d, y);
1809
1845
  }
1810
- if (process.env.NODE_ENV !== "production" && et(x.pathname.charAt(0) === "/", "Relative pathnames are not supported in hash history.replace(" + JSON.stringify(d) + ")"), c(k, x, C)) {
1811
- var O = f(x, m), H = O[0], _ = O[1];
1812
- o.replaceState(H, "", _), l(k);
1846
+ if (process.env.NODE_ENV !== "production" && rt(x.pathname.charAt(0) === "/", "Relative pathnames are not supported in hash history.replace(" + JSON.stringify(d) + ")"), c(k, x, C)) {
1847
+ var j = f(x, m), _ = j[0], q = j[1];
1848
+ o.replaceState(_, "", q), l(k);
1813
1849
  }
1814
1850
  }
1815
1851
  function P(d) {
@@ -1844,23 +1880,23 @@ function Xn(t) {
1844
1880
  };
1845
1881
  return g;
1846
1882
  }
1847
- function Ne(t) {
1883
+ function Ue(t) {
1848
1884
  t === void 0 && (t = {});
1849
1885
  var e = t, r = e.initialEntries, n = r === void 0 ? ["/"] : r, o = e.initialIndex, a = n.map(function(l) {
1850
- var E = Rt(Y({
1886
+ var E = Rt(X({
1851
1887
  pathname: "/",
1852
1888
  search: "",
1853
1889
  hash: "",
1854
1890
  state: null,
1855
1891
  key: $t()
1856
1892
  }, typeof l == "string" ? St(l) : l));
1857
- return process.env.NODE_ENV !== "production" && et(E.pathname.charAt(0) === "/", "Relative pathnames are not supported in createMemoryHistory({ initialEntries }) (invalid entry: " + JSON.stringify(l) + ")"), E;
1858
- }), s = Le(o ?? a.length - 1, 0, a.length - 1), p = j.Pop, h = a[s], u = wt(), m = wt();
1893
+ return process.env.NODE_ENV !== "production" && rt(E.pathname.charAt(0) === "/", "Relative pathnames are not supported in createMemoryHistory({ initialEntries }) (invalid entry: " + JSON.stringify(l) + ")"), E;
1894
+ }), s = Be(o ?? a.length - 1, 0, a.length - 1), p = $.Pop, h = a[s], u = wt(), m = wt();
1859
1895
  function R(l) {
1860
- return typeof l == "string" ? l : rt(l);
1896
+ return typeof l == "string" ? l : nt(l);
1861
1897
  }
1862
1898
  function L(l, E) {
1863
- return E === void 0 && (E = null), Rt(Y({
1899
+ return E === void 0 && (E = null), Rt(X({
1864
1900
  pathname: h.pathname,
1865
1901
  search: "",
1866
1902
  hash: ""
@@ -1883,21 +1919,21 @@ function Ne(t) {
1883
1919
  });
1884
1920
  }
1885
1921
  function v(l, E) {
1886
- var A = j.Push, P = L(l, E);
1922
+ var A = $.Push, P = L(l, E);
1887
1923
  function g() {
1888
1924
  v(l, E);
1889
1925
  }
1890
- process.env.NODE_ENV !== "production" && et(h.pathname.charAt(0) === "/", "Relative pathnames are not supported in memory history.push(" + JSON.stringify(l) + ")"), S(A, P, g) && (s += 1, a.splice(s, a.length, P), U(A, P));
1926
+ process.env.NODE_ENV !== "production" && rt(h.pathname.charAt(0) === "/", "Relative pathnames are not supported in memory history.push(" + JSON.stringify(l) + ")"), S(A, P, g) && (s += 1, a.splice(s, a.length, P), U(A, P));
1891
1927
  }
1892
1928
  function i(l, E) {
1893
- var A = j.Replace, P = L(l, E);
1929
+ var A = $.Replace, P = L(l, E);
1894
1930
  function g() {
1895
1931
  i(l, E);
1896
1932
  }
1897
- process.env.NODE_ENV !== "production" && et(h.pathname.charAt(0) === "/", "Relative pathnames are not supported in memory history.replace(" + JSON.stringify(l) + ")"), S(A, P, g) && (a[s] = P, U(A, P));
1933
+ process.env.NODE_ENV !== "production" && rt(h.pathname.charAt(0) === "/", "Relative pathnames are not supported in memory history.replace(" + JSON.stringify(l) + ")"), S(A, P, g) && (a[s] = P, U(A, P));
1898
1934
  }
1899
1935
  function f(l) {
1900
- var E = Le(s + l, 0, a.length - 1), A = j.Pop, P = a[E];
1936
+ var E = Be(s + l, 0, a.length - 1), A = $.Pop, P = a[E];
1901
1937
  function g() {
1902
1938
  f(l);
1903
1939
  }
@@ -1932,7 +1968,7 @@ function Ne(t) {
1932
1968
  };
1933
1969
  return c;
1934
1970
  }
1935
- function Le(t, e, r) {
1971
+ function Be(t, e, r) {
1936
1972
  return Math.min(Math.max(t, e), r);
1937
1973
  }
1938
1974
  function jt(t) {
@@ -1961,7 +1997,7 @@ function wt() {
1961
1997
  function $t() {
1962
1998
  return Math.random().toString(36).substr(2, 8);
1963
1999
  }
1964
- function rt(t) {
2000
+ function nt(t) {
1965
2001
  var e = t.pathname, r = e === void 0 ? "/" : e, n = t.search, o = n === void 0 ? "" : n, a = t.hash, s = a === void 0 ? "" : a;
1966
2002
  return o && o !== "?" && (r += o.charAt(0) === "?" ? o : "?" + o), s && s !== "#" && (r += s.charAt(0) === "#" ? s : "#" + s), r;
1967
2003
  }
@@ -1975,14 +2011,14 @@ function St(t) {
1975
2011
  }
1976
2012
  return e;
1977
2013
  }
1978
- const Pr = Symbol();
1979
- function to(t, e) {
1980
- const r = _t({ ...t }), n = (s) => {
2014
+ const Ar = Symbol();
2015
+ function no(t, e) {
2016
+ const r = qt({ ...t }), n = (s) => {
1981
2017
  Object.assign(r, {
1982
- [Pr]: !1,
2018
+ [Ar]: !1,
1983
2019
  ...s
1984
2020
  });
1985
- }, o = r, a = jn(o, e);
2021
+ }, o = r, a = $n(o, e);
1986
2022
  return {
1987
2023
  currentRoute: o,
1988
2024
  routerRoute: a,
@@ -1990,9 +2026,9 @@ function to(t, e) {
1990
2026
  };
1991
2027
  }
1992
2028
  function I(t) {
1993
- return !t.startsWith("http") ? ro(t) : eo(t);
2029
+ return !t.startsWith("http") ? ao(t) : oo(t);
1994
2030
  }
1995
- function eo(t) {
2031
+ function oo(t) {
1996
2032
  const { protocol: e, host: r, pathname: n, search: o, searchParams: a, hash: s } = new URL(t, t);
1997
2033
  return {
1998
2034
  protocol: e,
@@ -2003,7 +2039,7 @@ function eo(t) {
2003
2039
  hash: s
2004
2040
  };
2005
2041
  }
2006
- function ro(t) {
2042
+ function ao(t) {
2007
2043
  const { pathname: e, search: r, searchParams: n, hash: o } = new URL(t, "https://localhost");
2008
2044
  return {
2009
2045
  pathname: e,
@@ -2012,21 +2048,21 @@ function ro(t) {
2012
2048
  hash: o
2013
2049
  };
2014
2050
  }
2015
- function no(t) {
2051
+ function so(t) {
2016
2052
  return (e) => {
2017
2053
  const { host: r } = I(e);
2018
2054
  return !(r === void 0 || r === t);
2019
2055
  };
2020
2056
  }
2021
- function oo({ mode: t, listener: e }) {
2022
- const r = ao(t), n = (h, u) => {
2057
+ function io({ mode: t, listener: e }) {
2058
+ const r = co(t), n = (h, u) => {
2023
2059
  if (u != null && u.replace) {
2024
2060
  r.replace(h, u.state);
2025
2061
  return;
2026
2062
  }
2027
2063
  r.push(h, u == null ? void 0 : u.state);
2028
2064
  }, o = () => {
2029
- const h = rt(r.location);
2065
+ const h = nt(r.location);
2030
2066
  r.replace(h);
2031
2067
  };
2032
2068
  let a;
@@ -2042,31 +2078,31 @@ function oo({ mode: t, listener: e }) {
2042
2078
  }
2043
2079
  };
2044
2080
  }
2045
- function ao(t = "auto") {
2081
+ function co(t = "auto") {
2046
2082
  switch (t) {
2047
2083
  case "auto":
2048
- return fe() ? xe() : Ne();
2084
+ return le() ? Le() : Ue();
2049
2085
  case "browser":
2050
- return xe();
2086
+ return Le();
2051
2087
  case "memory":
2052
- return Ne();
2088
+ return Ue();
2053
2089
  case "hash":
2054
- return Xn();
2090
+ return ro();
2055
2091
  default:
2056
2092
  const e = t;
2057
2093
  throw new Error(`Switch is not exhaustive for mode: ${e}`);
2058
2094
  }
2059
2095
  }
2060
- function so(t) {
2096
+ function uo(t) {
2061
2097
  return vt(() => () => dt("h1", t), {
2062
2098
  name: t,
2063
2099
  props: []
2064
2100
  });
2065
2101
  }
2066
- function io(t) {
2067
- const e = (a) => Ut(t[a] ?? so(a)), r = (a) => {
2102
+ function fo(t) {
2103
+ const e = (a) => Ut(t[a] ?? uo(a)), r = (a) => {
2068
2104
  const s = Ut(e(a)), p = {
2069
- id: de(),
2105
+ id: he(),
2070
2106
  component: s,
2071
2107
  meta: {},
2072
2108
  state: {}
@@ -2076,12 +2112,12 @@ function io(t) {
2076
2112
  matched: p,
2077
2113
  matches: [p],
2078
2114
  name: a,
2079
- query: le(""),
2115
+ query: pe(""),
2080
2116
  params: {},
2081
2117
  state: {},
2082
2118
  href: "/",
2083
2119
  hash: "",
2084
- [Pr]: !0
2120
+ [Ar]: !0
2085
2121
  };
2086
2122
  }, n = (a) => {
2087
2123
  if (!a) {
@@ -2097,54 +2133,54 @@ function io(t) {
2097
2133
  getRejectionRoute: r
2098
2134
  };
2099
2135
  }
2100
- class co extends Error {
2136
+ class lo extends Error {
2101
2137
  constructor() {
2102
2138
  super("initialUrl must be set if window.location is unavailable");
2103
2139
  }
2104
2140
  }
2105
- function uo(t) {
2141
+ function po(t) {
2106
2142
  if (t)
2107
2143
  return t;
2108
- if (fe())
2144
+ if (le())
2109
2145
  return window.location.toString();
2110
- throw new co();
2146
+ throw new lo();
2111
2147
  }
2112
- function Ar(t) {
2148
+ function kr(t) {
2113
2149
  return !!t && typeof t == "object";
2114
2150
  }
2115
- const Ht = !0;
2116
- function fo(t, e, r) {
2117
- if (Ar(t) && e in t) {
2151
+ const _t = !0;
2152
+ function ho(t, e, r) {
2153
+ if (kr(t) && e in t) {
2118
2154
  const n = t[e];
2119
- return typeof n == "string" ? ot(n, r, Ht) : n;
2155
+ return typeof n == "string" ? at(n, r, _t) : n;
2120
2156
  }
2121
- return ot(void 0, r, Ht);
2157
+ return at(void 0, r, _t);
2122
2158
  }
2123
- function kr(t, e) {
2159
+ function xr(t, e) {
2124
2160
  const r = {};
2125
2161
  for (const [n, o] of Object.entries(t)) {
2126
- const a = fo(e, n, o);
2162
+ const a = ho(e, n, o);
2127
2163
  r[n] = a;
2128
2164
  }
2129
2165
  return r;
2130
2166
  }
2131
- function lo(t, e, r) {
2132
- if (Ar(t) && e in t) {
2167
+ function yo(t, e, r) {
2168
+ if (kr(t) && e in t) {
2133
2169
  const n = t[e];
2134
- return at(n, r, Ht);
2170
+ return z(n, r, _t);
2135
2171
  }
2136
- return at(void 0, r, Ht);
2172
+ return z(void 0, r, _t);
2137
2173
  }
2138
- const Ue = (t, e) => {
2174
+ const Ce = (t, e) => {
2139
2175
  const r = {};
2140
2176
  for (const [n, o] of Object.entries(t)) {
2141
- const a = lo(e, n, o);
2177
+ const a = yo(e, n, o);
2142
2178
  r[n] = a;
2143
2179
  }
2144
2180
  return r;
2145
2181
  };
2146
- function po() {
2147
- const t = _t(/* @__PURE__ */ new Map()), e = fe() ? s() : null, r = (p) => {
2182
+ function mo() {
2183
+ const t = qt(/* @__PURE__ */ new Map()), e = le() ? s() : null, r = (p) => {
2148
2184
  t.set(p, !1), e == null || e.observe(p);
2149
2185
  }, n = (p) => {
2150
2186
  t.delete(p), e == null || e.unobserve(p);
@@ -2165,86 +2201,86 @@ function po() {
2165
2201
  isElementVisible: a
2166
2202
  };
2167
2203
  }
2168
- class ho extends Error {
2204
+ class go extends Error {
2169
2205
  constructor(e) {
2170
2206
  super(`Route not found: "${e}"`);
2171
2207
  }
2172
2208
  }
2173
- function xr(t, e, r) {
2174
- const n = hn(e.value, r), o = Qe(n), [a] = Ye(t, new RegExp(o, "g"));
2209
+ function Nr(t, e, r) {
2210
+ const n = yn(e.value, r), o = Ye(n), [a] = tr(t, new RegExp(o, "g"));
2175
2211
  return a;
2176
2212
  }
2177
- function Nr(t, e, r, n) {
2178
- const o = ie(e, r), a = at(n, e.params[r], o);
2179
- return t.replace(Ke(r), a);
2213
+ function Lr(t, e, r, n) {
2214
+ const o = ce(e, r), a = z(n, e.params[r], o);
2215
+ return t.replace(Xe(r), a);
2180
2216
  }
2181
- function Lr({ protocol: t, host: e, pathname: r, search: n, searchParams: o, hash: a }) {
2217
+ function Ur({ protocol: t, host: e, pathname: r, search: n, searchParams: o, hash: a }) {
2182
2218
  const s = new URL("https://localhost");
2183
2219
  t && (s.protocol = t), e && (s.host = e), r && (s.pathname = r), o ? s.search = new URLSearchParams(o).toString() : n && (s.search = n), a && (s.hash = a);
2184
2220
  const p = s.toString().replace(/^https:\/\/localhost\/*/, "/");
2185
2221
  return He(p);
2186
2222
  }
2187
- function yo(t, e = {}) {
2188
- const { params: r = {}, query: n } = e, o = go(t.query, r), a = ye(o, n), s = Be(t.path, r), p = t.hash.value ? Be(t.hash, r) : e.hash, h = mo(t.host, r), { protocol: u, host: m } = I(h);
2189
- return Lr({ protocol: u, host: m, pathname: s, searchParams: a, hash: p });
2223
+ function Ro(t, e = {}) {
2224
+ const { params: r = {}, query: n } = e, o = vo(t.query, r), a = me(o, n), s = Ve(t.path, r), p = t.hash.value ? Ve(t.hash, r) : e.hash, h = wo(t.host, r), { protocol: u, host: m } = I(h);
2225
+ return Ur({ protocol: u, host: m, pathname: s, searchParams: a, hash: p });
2190
2226
  }
2191
- function mo(t, e) {
2227
+ function wo(t, e) {
2192
2228
  const r = t.value && !t.value.startsWith("http") ? `https://${t.value}` : t.value;
2193
- return Object.keys(t.params).reduce((n, o) => Nr(n, t, o, e[o]), r);
2229
+ return Object.keys(t.params).reduce((n, o) => Lr(n, t, o, e[o]), r);
2194
2230
  }
2195
- function Be(t, e) {
2196
- return Object.keys(t.params).reduce((r, n) => Nr(r, t, n, e[n]), t.value);
2231
+ function Ve(t, e) {
2232
+ return Object.keys(t.params).reduce((r, n) => Lr(r, t, n, e[n]), t.value);
2197
2233
  }
2198
- function go(t, e) {
2234
+ function vo(t, e) {
2199
2235
  const r = new URLSearchParams(t.value);
2200
2236
  if (!t.value)
2201
2237
  return r;
2202
2238
  for (const [n, o] of Array.from(r.entries())) {
2203
- const a = ue(o);
2239
+ const a = fe(o);
2204
2240
  if (!a)
2205
2241
  continue;
2206
- const p = ce(o), h = at(e[a], t.params[a], p), u = e[a] === void 0 && h === "";
2242
+ const p = ue(o), h = z(e[a], t.params[a], p), u = e[a] === void 0 && h === "";
2207
2243
  p && u ? r.delete(n, o) : r.set(n, h);
2208
2244
  }
2209
2245
  return r;
2210
2246
  }
2211
- const Ro = (t, e) => {
2247
+ const Eo = (t, e) => {
2212
2248
  try {
2213
- ge(t, e);
2249
+ we(t, e);
2214
2250
  } catch {
2215
2251
  return !1;
2216
2252
  }
2217
2253
  return !0;
2218
- }, ge = (t, e) => {
2254
+ }, we = (t, e) => {
2219
2255
  const { protocol: r, host: n, pathname: o, search: a, hash: s } = I(e);
2220
2256
  return {
2221
- ...Qt(t.host, `${r}//${n}`),
2222
- ...Qt(t.path, o),
2223
- ...wo(t.query, a),
2224
- ...Qt(t.hash, s)
2257
+ ...zt(t.host, `${r}//${n}`),
2258
+ ...zt(t.path, o),
2259
+ ...bo(t.query, a),
2260
+ ...zt(t.hash, s)
2225
2261
  };
2226
2262
  };
2227
- function Qt(t, e) {
2263
+ function zt(t, e) {
2228
2264
  const r = {}, n = decodeURIComponent(e);
2229
2265
  for (const [o, a] of Object.entries(t.params)) {
2230
- const s = xr(n, t, o), p = ie(t, o), h = ot(s, a, p);
2266
+ const s = Nr(n, t, o), p = ce(t, o), h = at(s, a, p);
2231
2267
  r[o] = h;
2232
2268
  }
2233
2269
  return r;
2234
2270
  }
2235
- function wo(t, e) {
2271
+ function bo(t, e) {
2236
2272
  const r = {}, n = new URLSearchParams(t.value), o = new URLSearchParams(e);
2237
2273
  for (const [a, s] of Array.from(n.entries())) {
2238
- const p = ue(s);
2274
+ const p = fe(s);
2239
2275
  if (!p)
2240
2276
  continue;
2241
- const u = ce(s), m = o.get(a) ?? void 0, R = ot(m, t.params[p], u);
2277
+ const u = ue(s), m = o.get(a) ?? void 0, R = at(m, t.params[p], u);
2242
2278
  r[p] = R;
2243
2279
  }
2244
2280
  return r;
2245
2281
  }
2246
- function vo(t, e = {}, r = {}) {
2247
- const n = yo(t, {
2282
+ function So(t, e = {}, r = {}) {
2283
+ const n = Ro(t, {
2248
2284
  params: e,
2249
2285
  query: r.query,
2250
2286
  hash: r.hash
@@ -2254,51 +2290,51 @@ function vo(t, e = {}, r = {}) {
2254
2290
  matched: t.matched,
2255
2291
  matches: t.matches,
2256
2292
  name: t.name,
2257
- query: le(o),
2258
- params: ge(t, n),
2259
- state: kr(t.state, r.state),
2293
+ query: pe(o),
2294
+ params: we(t, n),
2295
+ state: xr(t.state, r.state),
2260
2296
  hash: a,
2261
2297
  href: n
2262
2298
  };
2263
2299
  }
2264
- const Eo = (t) => "name" in t.matched && !!t.matched.name, bo = (t, e) => {
2300
+ const Po = (t) => "name" in t.matched && !!t.matched.name, Ao = (t, e) => {
2265
2301
  const { pathname: r } = I(e);
2266
- return pn(t).test(r);
2267
- }, So = (t, e) => {
2302
+ return dn(t).test(r);
2303
+ }, ko = (t, e) => {
2268
2304
  const { search: r } = I(e);
2269
- return dn(t).every((o) => o.test(r));
2270
- }, re = (t, e) => {
2305
+ return hn(t).every((o) => o.test(r));
2306
+ }, ne = (t, e) => {
2271
2307
  const { hash: r } = I(e), { value: n } = t.hash;
2272
2308
  return W(n) ? `#${n.replace(/^#*/, "")}`.toLowerCase() === r.toLowerCase() : !0;
2273
2309
  };
2274
- function Po(t) {
2310
+ function xo(t) {
2275
2311
  const { searchParams: e, pathname: r } = I(t), n = -1, o = 1;
2276
2312
  return (a, s) => {
2277
- const p = Ve(a, e), h = Ce(a, r), u = Ve(s, e), m = Ce(s, r);
2278
- return a.depth > s.depth ? n : a.depth < s.depth ? o : p + h > u + m ? n : p + h < u + m ? o : re(a, t) ? n : re(s, t) ? o : 0;
2313
+ const p = Oe(a, e), h = Ze(a, r), u = Oe(s, e), m = Ze(s, r);
2314
+ return a.depth > s.depth ? n : a.depth < s.depth ? o : p + h > u + m ? n : p + h < u + m ? o : ne(a, t) ? n : ne(s, t) ? o : 0;
2279
2315
  };
2280
2316
  }
2281
- function Ce(t, e) {
2282
- const r = Object.keys(t.path.params).filter((o) => ie(t.path, o)).map((o) => o), n = r.filter((o) => xr(e, t.path, o) === void 0);
2317
+ function Ze(t, e) {
2318
+ const r = Object.keys(t.path.params).filter((o) => ce(t.path, o)).map((o) => o), n = r.filter((o) => Nr(e, t.path, o) === void 0);
2283
2319
  return r.length - n.length;
2284
2320
  }
2285
- function Ve(t, e) {
2321
+ function Oe(t, e) {
2286
2322
  const r = new URLSearchParams(e), n = new URLSearchParams(t.query.value), o = Array.from(n.keys()), a = o.filter((s) => !r.has(s));
2287
2323
  return o.length - a.length;
2288
2324
  }
2289
- const Ao = [
2290
- Eo,
2291
- bo,
2292
- So,
2293
- re,
2294
- Ro
2325
+ const No = [
2326
+ Po,
2327
+ Ao,
2328
+ ko,
2329
+ ne,
2330
+ Eo
2295
2331
  ];
2296
- function ko(t, e) {
2297
- const r = Po(e);
2298
- return t.filter((n) => Ao.every((o) => o(n, e))).sort(r);
2332
+ function Lo(t, e) {
2333
+ const r = xo(e);
2334
+ return t.filter((n) => No.every((o) => o(n, e))).sort(r);
2299
2335
  }
2300
- function xo(t, e, r) {
2301
- const n = ko(t, e);
2336
+ function Uo(t, e, r) {
2337
+ const n = Lo(t, e);
2302
2338
  if (!n.length)
2303
2339
  return;
2304
2340
  const [o] = n, { searchParams: a, hash: s } = I(e);
@@ -2307,33 +2343,33 @@ function xo(t, e, r) {
2307
2343
  matched: o.matched,
2308
2344
  matches: o.matches,
2309
2345
  name: o.name,
2310
- query: le(a),
2311
- params: ge(o, e),
2312
- state: kr(o.state, r),
2346
+ query: pe(a),
2347
+ params: we(o, e),
2348
+ state: xr(o.state, r),
2313
2349
  hash: s,
2314
2350
  href: He(e)
2315
2351
  };
2316
2352
  }
2317
- function Ze(t, e) {
2353
+ function je(t, e) {
2318
2354
  const r = typeof t == "string" ? I(t) : t, n = typeof e == "string" ? I(e) : e, o = r.searchParams ?? new URLSearchParams(r.search), a = n.searchParams ?? new URLSearchParams(n.search);
2319
- return Lr({
2355
+ return Ur({
2320
2356
  protocol: W(n.protocol) ? n.protocol : r.protocol,
2321
2357
  host: W(n.host) ? n.host : r.host,
2322
2358
  pathname: W(n.pathname) ? n.pathname : r.pathname,
2323
- searchParams: ye(a, o),
2359
+ searchParams: me(a, o),
2324
2360
  hash: W(n.hash) ? n.hash : r.hash
2325
2361
  });
2326
2362
  }
2327
- function No(t, e) {
2363
+ function Bo(t, e) {
2328
2364
  return W(e) ? t.map((r) => {
2329
2365
  const n = `${e}${r.path.value}`;
2330
2366
  return {
2331
2367
  ...r,
2332
- path: Q(n, r.path.params)
2368
+ path: K(n, r.path.params)
2333
2369
  };
2334
2370
  }) : t;
2335
2371
  }
2336
- class Lo extends Error {
2372
+ class Co extends Error {
2337
2373
  /**
2338
2374
  * Constructs a new DuplicateNamesError instance with a message indicating the problematic name.
2339
2375
  * @param name - The name of the name that was duplicated.
@@ -2342,20 +2378,20 @@ class Lo extends Error {
2342
2378
  super(`Invalid Name "${e}": Router does not support multiple routes with the same name. All name names must be unique.`);
2343
2379
  }
2344
2380
  }
2345
- function Uo(t) {
2381
+ function Vo(t) {
2346
2382
  const e = t.map(({ name: r }) => r);
2347
2383
  for (const r of e)
2348
- if (qe(e, r) > 1)
2349
- throw new Lo(r);
2384
+ if (De(e, r) > 1)
2385
+ throw new Co(r);
2350
2386
  }
2351
- function Bo(t, e = [], r) {
2387
+ function Zo(t, e = [], r) {
2352
2388
  const n = [
2353
2389
  ...t,
2354
2390
  ...e.map((o) => o.routes)
2355
2391
  ].flat();
2356
- return Uo(n), No(n, r);
2392
+ return Vo(n), Bo(n, r);
2357
2393
  }
2358
- function Co(t = {}, e = []) {
2394
+ function Oo(t = {}, e = []) {
2359
2395
  const r = new st();
2360
2396
  return ft("onBeforeRouteEnter", t, e).forEach((n) => r.onBeforeRouteEnter.add(n)), ft("onBeforeRouteUpdate", t, e).forEach((n) => r.onBeforeRouteUpdate.add(n)), ft("onBeforeRouteLeave", t, e).forEach((n) => r.onBeforeRouteLeave.add(n)), ft("onAfterRouteEnter", t, e).forEach((n) => r.onAfterRouteEnter.add(n)), ft("onAfterRouteUpdate", t, e).forEach((n) => r.onAfterRouteUpdate.add(n)), ft("onAfterRouteLeave", t, e).forEach((n) => r.onAfterRouteLeave.add(n)), r;
2361
2397
  }
@@ -2365,18 +2401,18 @@ function ft(t, e, r) {
2365
2401
  ...r.map((o) => o[t])
2366
2402
  ].flat().filter((o) => o !== void 0);
2367
2403
  }
2368
- function Jo(t, e, r = []) {
2369
- const n = Bo(t, r, e == null ? void 0 : e.base), o = Kn();
2370
- o.addGlobalRouteHooks(Co(e, r));
2371
- const a = pe(), s = Un(), p = Fn(), h = po(), u = oo({
2404
+ function Wo(t, e, r = []) {
2405
+ const n = Zo(t, r, e == null ? void 0 : e.base), o = to();
2406
+ o.addGlobalRouteHooks(Oo(e, r));
2407
+ const a = de(), s = Bn(), p = Mn(), h = mo(), u = io({
2372
2408
  mode: e == null ? void 0 : e.historyMode,
2373
2409
  listener: ({ location: b }) => {
2374
- const B = rt(b);
2410
+ const B = nt(b);
2375
2411
  R(B, { state: b.state, replace: !0 });
2376
2412
  }
2377
2413
  });
2378
2414
  function m(b, B = {}) {
2379
- return xo(n, b, B.state);
2415
+ return Uo(n, b, B.state);
2380
2416
  }
2381
2417
  async function R(b, B = {}) {
2382
2418
  const G = a();
@@ -2384,25 +2420,25 @@ function Jo(t, e, r = []) {
2384
2420
  u.update(b, B);
2385
2421
  return;
2386
2422
  }
2387
- const D = m(b, B) ?? c("NotFound"), q = Ur(G), K = await o.runBeforeRouteHooks({ to: D, from: q });
2388
- switch (K.status) {
2423
+ const D = m(b, B) ?? c("NotFound"), H = Br(G), Y = await o.runBeforeRouteHooks({ to: D, from: H });
2424
+ switch (Y.status) {
2389
2425
  // On abort do nothing
2390
2426
  case "ABORT":
2391
2427
  return;
2392
2428
  // On push update the history, and push new route, and return
2393
2429
  case "PUSH":
2394
- u.update(b, B), await S(...K.to);
2430
+ u.update(b, B), await S(...Y.to);
2395
2431
  return;
2396
2432
  // On reject update the history, the route, and set the rejection type
2397
2433
  case "REJECT":
2398
- u.update(b, B), i(K.type);
2434
+ u.update(b, B), i(Y.type);
2399
2435
  break;
2400
2436
  // On success update history, set the route, and clear the rejection
2401
2437
  case "SUCCESS":
2402
2438
  u.update(b, B), i(null);
2403
2439
  break;
2404
2440
  default:
2405
- throw new Error(`Switch is not exhaustive for before hook response status: ${JSON.stringify(K)}`);
2441
+ throw new Error(`Switch is not exhaustive for before hook response status: ${JSON.stringify(Y)}`);
2406
2442
  }
2407
2443
  const Tt = G;
2408
2444
  s.setProps(D).then((J) => {
@@ -2421,7 +2457,7 @@ function Jo(t, e, r = []) {
2421
2457
  throw new Error(`Switch is not exhaustive for prop store response status: ${JSON.stringify(Mt)}`);
2422
2458
  }
2423
2459
  }), P(D);
2424
- const F = await o.runAfterRouteHooks({ to: D, from: q });
2460
+ const F = await o.runAfterRouteHooks({ to: D, from: H });
2425
2461
  switch (F.status) {
2426
2462
  case "PUSH":
2427
2463
  await S(...F.to);
@@ -2438,61 +2474,61 @@ function Jo(t, e, r = []) {
2438
2474
  u.startListening();
2439
2475
  }
2440
2476
  const L = (b, B = {}, G = {}) => {
2441
- const D = n.find((q) => q.name === b);
2477
+ const D = n.find((H) => H.name === b);
2442
2478
  if (!D)
2443
- throw new ho(String(b));
2444
- return vo(D, B, G);
2479
+ throw new go(String(b));
2480
+ return So(D, B, G);
2445
2481
  }, S = (b, B, G) => {
2446
2482
  if (M(b)) {
2447
- const F = { ...B }, J = Ze(b, {
2483
+ const F = { ...B }, J = je(b, {
2448
2484
  searchParams: F.query,
2449
2485
  hash: F.hash
2450
2486
  });
2451
2487
  return R(J, F);
2452
2488
  }
2453
2489
  if (typeof b == "string") {
2454
- const { replace: F, ...J } = { ...G }, Mt = { ...B }, Wt = L(b, Mt, J), Cr = Ue({ ...Wt.matched.state }, { ...Wt.state, ...J.state });
2455
- return R(Wt.href, { replace: F, state: Cr });
2490
+ const { replace: F, ...J } = { ...G }, Mt = { ...B }, Wt = L(b, Mt, J), Vr = Ce({ ...Wt.matched.state }, { ...Wt.state, ...J.state });
2491
+ return R(Wt.href, { replace: F, state: Vr });
2456
2492
  }
2457
- const { replace: D, ...q } = { ...B }, K = Ue({ ...b.matched.state }, { ...b.state, ...q.state }), Tt = Ze(b.href, {
2458
- searchParams: q.query,
2459
- hash: q.hash
2493
+ const { replace: D, ...H } = { ...B }, Y = Ce({ ...b.matched.state }, { ...b.state, ...H.state }), Tt = je(b.href, {
2494
+ searchParams: H.query,
2495
+ hash: H.hash
2460
2496
  });
2461
- return R(Tt, { replace: D, state: K });
2497
+ return R(Tt, { replace: D, state: Y });
2462
2498
  }, U = (b, B, G) => {
2463
2499
  if (M(b)) {
2464
- const q = { ...B, replace: !0 };
2465
- return S(b, q);
2500
+ const H = { ...B, replace: !0 };
2501
+ return S(b, H);
2466
2502
  }
2467
2503
  if (typeof b == "string") {
2468
- const q = { ...G, replace: !0 }, K = { ...B };
2469
- return S(b, K, q);
2504
+ const H = { ...G, replace: !0 }, Y = { ...B };
2505
+ return S(b, Y, H);
2470
2506
  }
2471
2507
  const D = { ...B, replace: !0 };
2472
2508
  return S(b, D);
2473
2509
  }, v = (b) => {
2474
2510
  i(b);
2475
- }, { setRejection: i, rejection: f, getRejectionRoute: c } = io({
2511
+ }, { setRejection: i, rejection: f, getRejectionRoute: c } = fo({
2476
2512
  ...r.reduce((b, B) => ({ ...b, ...B.rejections }), {}),
2477
2513
  ...e == null ? void 0 : e.rejections
2478
- }), l = c("NotFound"), { currentRoute: E, routerRoute: A, updateRoute: P } = to(l, S), g = uo(e == null ? void 0 : e.initialUrl), d = u.location.state, { host: y } = I(g), k = no(y);
2514
+ }), l = c("NotFound"), { currentRoute: E, routerRoute: A, updateRoute: P } = no(l, S), g = po(e == null ? void 0 : e.initialUrl), d = u.location.state, { host: y } = I(g), k = so(y);
2479
2515
  let x = !1;
2480
- const C = Pt(!1), { promise: O, resolve: H } = Promise.withResolvers();
2481
- async function _() {
2516
+ const C = Pt(!1), { promise: j, resolve: _ } = Promise.withResolvers();
2517
+ async function q() {
2482
2518
  if (x)
2483
- return O;
2484
- x = !0, en(n) && await rn(), await R(g, { replace: !0, state: d }), u.startListening(), H(), C.value = !0;
2519
+ return j;
2520
+ x = !0, nn(n) && await on(), await R(g, { replace: !0, state: d }), u.startListening(), _(), C.value = !0;
2485
2521
  }
2486
- function Re() {
2522
+ function ve() {
2487
2523
  u.stopListening();
2488
2524
  }
2489
- function Ur(b) {
2490
- return An(b) ? null : { ...E };
2491
- }
2492
2525
  function Br(b) {
2493
- o.setVueApp(b), s.setVueApp(b), b.component("RouterView", Rr), b.component("RouterLink", _n), b.provide(hr, f), b.provide(wr, o), b.provide(fr, s), b.provide(gr, p), b.provide(pr, h), b.provide(_e, we), _();
2526
+ return kn(b) ? null : { ...E };
2494
2527
  }
2495
- const we = {
2528
+ function Cr(b) {
2529
+ o.setVueApp(b), s.setVueApp(b), b.component("RouterView", wr), b.component("RouterLink", In), b.provide(mr, f), b.provide(vr, o), b.provide(pr, s), b.provide(Rr, p), b.provide(hr, h), b.provide(Ie, Ee), q();
2530
+ }
2531
+ const Ee = {
2496
2532
  route: A,
2497
2533
  resolve: L,
2498
2534
  find: m,
@@ -2503,7 +2539,7 @@ function Jo(t, e, r = []) {
2503
2539
  forward: u.forward,
2504
2540
  back: u.back,
2505
2541
  go: u.go,
2506
- install: Br,
2542
+ install: Cr,
2507
2543
  isExternal: k,
2508
2544
  onBeforeRouteEnter: o.onBeforeRouteEnter,
2509
2545
  onBeforeRouteUpdate: o.onBeforeRouteUpdate,
@@ -2512,24 +2548,24 @@ function Jo(t, e, r = []) {
2512
2548
  onAfterRouteUpdate: o.onAfterRouteUpdate,
2513
2549
  onAfterRouteLeave: o.onAfterRouteLeave,
2514
2550
  prefetch: e == null ? void 0 : e.prefetch,
2515
- start: _,
2551
+ start: q,
2516
2552
  started: C,
2517
- stop: Re
2553
+ stop: ve
2518
2554
  };
2519
- return we;
2555
+ return Ee;
2520
2556
  }
2521
- function Fo(t) {
2557
+ function Go(t) {
2522
2558
  return {
2523
2559
  routes: t.routes ?? [],
2524
2560
  rejections: t.rejections ?? {},
2525
2561
  ...t
2526
2562
  };
2527
2563
  }
2528
- function Vo(t) {
2564
+ function jo(t) {
2529
2565
  return {
2530
2566
  get: (e, { invalid: r }) => {
2531
2567
  for (const n of t) {
2532
- const o = un(e, n);
2568
+ const o = ee(e, n);
2533
2569
  if (o !== void 0)
2534
2570
  return o;
2535
2571
  }
@@ -2537,7 +2573,7 @@ function Vo(t) {
2537
2573
  },
2538
2574
  set: (e, { invalid: r }) => {
2539
2575
  for (const n of t) {
2540
- const o = fn(e, n);
2576
+ const o = ln(e, n);
2541
2577
  if (o !== void 0)
2542
2578
  return o;
2543
2579
  }
@@ -2545,11 +2581,11 @@ function Vo(t) {
2545
2581
  }
2546
2582
  };
2547
2583
  }
2548
- const Zo = {
2584
+ const $o = {
2549
2585
  separator: ","
2550
2586
  };
2551
- function To(t, e = {}) {
2552
- const { separator: r } = { ...Zo, ...e }, n = Vo(t);
2587
+ function Qo(t, e = {}) {
2588
+ const { separator: r } = { ...$o, ...e }, n = jo(t);
2553
2589
  return {
2554
2590
  get: (o, a) => o.split(r).map((s) => n.get(s, a)),
2555
2591
  set: (o, a) => {
@@ -2559,28 +2595,28 @@ function To(t, e = {}) {
2559
2595
  }
2560
2596
  };
2561
2597
  }
2562
- const Oo = {
2598
+ const _o = {
2563
2599
  separator: ","
2564
2600
  };
2565
- function Mo(t, e = {}) {
2566
- const { separator: r } = { ...Oo, ...e };
2601
+ function zo(t, e = {}) {
2602
+ const { separator: r } = { ..._o, ...e };
2567
2603
  return {
2568
2604
  get: (n) => {
2569
2605
  const o = n.split(r);
2570
- return t.map((a, s) => ot(o.at(s), a));
2606
+ return t.map((a, s) => at(o.at(s), a));
2571
2607
  },
2572
2608
  set: (n, { invalid: o }) => {
2573
2609
  if (!Array.isArray(n))
2574
2610
  throw o("Expected a tuple");
2575
2611
  if (n.length !== t.length)
2576
2612
  throw o(`Expected tuple with ${t.length} values but received ${n.length} values`);
2577
- return t.map((a, s) => at(n.at(s), a)).join(r);
2613
+ return t.map((a, s) => z(n.at(s), a)).join(r);
2578
2614
  }
2579
2615
  };
2580
2616
  }
2581
- const Wo = Q, Go = Q, zo = Q;
2582
- function Qo(t) {
2583
- const e = de(), r = or(t.name), n = tt(t.path), o = tt(t.query), a = tt(t.hash), s = t.meta ?? {}, p = tt(t.host), h = Ut({ id: e, meta: {}, state: {}, ...t }), u = {
2617
+ const Ko = K, Yo = K, Xo = K;
2618
+ function ta(t) {
2619
+ const e = he(), r = sr(t.name), n = et(t.path), o = et(t.query), a = et(t.hash), s = t.meta ?? {}, p = et(t.host), h = Ut({ id: e, meta: {}, state: {}, ...t }), u = {
2584
2620
  id: e,
2585
2621
  matched: h,
2586
2622
  matches: [h],
@@ -2592,37 +2628,38 @@ function Qo(t) {
2592
2628
  meta: s,
2593
2629
  depth: 1,
2594
2630
  state: {}
2595
- }, m = tr(t) ? nr(t.parent, u) : u;
2631
+ }, m = rr(t) ? ar(t.parent, u) : u;
2596
2632
  return bt(m.path.params, m.query.params, m.host.params, m.hash.params), m;
2597
2633
  }
2598
2634
  export {
2599
- Mr as DuplicateParamsError,
2600
- Wr as MetaPropertyConflict,
2601
- _n as RouterLink,
2635
+ Gr as DuplicateParamsError,
2636
+ Qr as MetaPropertyConflict,
2637
+ In as RouterLink,
2602
2638
  Et as RouterNotInstalledError,
2603
- Rr as RouterView,
2604
- Gr as UseRouteInvalidError,
2605
- To as arrayOf,
2639
+ wr as RouterView,
2640
+ zr as UseRouteInvalidError,
2641
+ Qo as arrayOf,
2606
2642
  He as asUrl,
2607
- Qo as createExternalRoute,
2608
- Kr as createParam,
2643
+ ta as createExternalRoute,
2644
+ Xr as createParam,
2609
2645
  gt as createRoute,
2610
- Jo as createRouter,
2611
- Fo as createRouterPlugin,
2612
- Go as host,
2613
- ee as isRoute,
2646
+ Wo as createRouter,
2647
+ Go as createRouterPlugin,
2648
+ Yo as host,
2649
+ re as isRoute,
2614
2650
  M as isUrl,
2615
- Io as onAfterRouteLeave,
2616
- Do as onAfterRouteUpdate,
2617
- _o as onBeforeRouteLeave,
2618
- qo as onBeforeRouteUpdate,
2619
- Wo as path,
2620
- zo as query,
2621
- Mo as tupleOf,
2622
- Vo as unionOf,
2623
- $n as useLink,
2624
- yr as useRoute,
2651
+ To as onAfterRouteLeave,
2652
+ Mo as onAfterRouteUpdate,
2653
+ Jo as onBeforeRouteLeave,
2654
+ Fo as onBeforeRouteUpdate,
2655
+ Ko as path,
2656
+ Xo as query,
2657
+ zo as tupleOf,
2658
+ jo as unionOf,
2659
+ _n as useLink,
2660
+ Do as useQueryValue,
2661
+ ge as useRoute,
2625
2662
  It as useRouter,
2626
- Ho as withDefault,
2627
- Q as withParams
2663
+ Io as withDefault,
2664
+ K as withParams
2628
2665
  };