@kitbag/router 0.13.3 → 0.14.0
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/README.md +1 -1
- package/dist/kitbag-router.d.ts +22 -21
- package/dist/kitbag-router.js +1095 -1052
- package/dist/kitbag-router.umd.cjs +1 -1
- package/package.json +3 -3
package/dist/kitbag-router.js
CHANGED
|
@@ -1,145 +1,169 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { inject as
|
|
5
|
-
|
|
1
|
+
var ln = Object.defineProperty;
|
|
2
|
+
var hn = (e, t, n) => t in e ? ln(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var M = (e, t, n) => hn(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { inject as ae, toRefs as pn, computed as N, reactive as Ue, defineComponent as se, h as Z, ref as Oe, markRaw as ve, watch as Re, defineAsyncComponent as dn, toValue as T, openBlock as yt, createElementBlock as mn, normalizeClass as yn, renderSlot as gt, normalizeProps as vt, guardReactiveProps as gn, unref as ue, getCurrentInstance as vn, resolveComponent as Rn, provide as wn, mergeProps as Pn, createBlock as En, resolveDynamicComponent as bn, createCommentVNode as Sn, onUnmounted as Rt } from "vue";
|
|
5
|
+
function I(e) {
|
|
6
|
+
return typeof e != "string" ? !1 : /^(https?:\/\/|\/).*/g.test(e);
|
|
7
|
+
}
|
|
8
|
+
function wt(e) {
|
|
9
|
+
return I(e) ? e : `/${e}`;
|
|
10
|
+
}
|
|
11
|
+
class kn extends Error {
|
|
12
|
+
/**
|
|
13
|
+
* Constructs a new DuplicateParamsError instance with a message indicating the problematic parameter.
|
|
14
|
+
* @param paramName - The name of the parameter that was duplicated.
|
|
15
|
+
*/
|
|
16
|
+
constructor(t) {
|
|
17
|
+
super(`Invalid Param "${t}": Router does not support multiple params by the same name. All param names must be unique.`);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
class An extends Error {
|
|
21
|
+
constructor(t) {
|
|
22
|
+
super(`Child property on meta for ${t} conflicts with the parent meta.`);
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
class pe extends Error {
|
|
6
26
|
constructor() {
|
|
7
27
|
super("Router not installed");
|
|
8
28
|
}
|
|
9
29
|
}
|
|
10
|
-
|
|
30
|
+
class xn extends Error {
|
|
31
|
+
/**
|
|
32
|
+
* Constructs a new UseRouteInvalidError instance with a message that specifies both the given and expected route names.
|
|
33
|
+
* This detailed error message aids in quickly identifying and resolving mismatches in route usage.
|
|
34
|
+
* @param routeName - The route name that was incorrectly used.
|
|
35
|
+
* @param actualRouteName - The expected route name that should have been used.
|
|
36
|
+
*/
|
|
37
|
+
constructor(t, n) {
|
|
38
|
+
super(`useRoute called with incorrect route. Given ${t}, expected ${n}`);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
const Pt = Symbol();
|
|
42
|
+
function qe() {
|
|
43
|
+
const e = ae(Pt);
|
|
44
|
+
if (!e)
|
|
45
|
+
throw new pe();
|
|
46
|
+
return e;
|
|
47
|
+
}
|
|
48
|
+
function de(e) {
|
|
11
49
|
return typeof e == "object" && e !== null && !Array.isArray(e);
|
|
12
50
|
}
|
|
13
|
-
function
|
|
51
|
+
function Ln(e) {
|
|
14
52
|
return e.every((t) => Array.isArray(t));
|
|
15
53
|
}
|
|
16
|
-
function
|
|
54
|
+
function me(e) {
|
|
17
55
|
return typeof e == "string" && e.length > 0;
|
|
18
56
|
}
|
|
19
|
-
function
|
|
57
|
+
function we(e) {
|
|
20
58
|
return {
|
|
21
|
-
value:
|
|
59
|
+
value: me(e) ? e.replace(/^#*/, "") : void 0
|
|
22
60
|
};
|
|
23
61
|
}
|
|
24
|
-
function
|
|
25
|
-
return
|
|
62
|
+
function Un(e, t) {
|
|
63
|
+
return we(`${e.value ?? ""}${t.value ?? ""}`);
|
|
26
64
|
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
super(`Child property on meta for ${t} conflicts with the parent meta.`);
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
function An(e, t) {
|
|
33
|
-
return xn(e, t), { ...e, ...t };
|
|
65
|
+
function Cn(e, t) {
|
|
66
|
+
return Bn(e, t), { ...e, ...t };
|
|
34
67
|
}
|
|
35
|
-
function
|
|
68
|
+
function Bn(e, t) {
|
|
36
69
|
const n = Object.keys(e).find((r) => r in t && typeof t[r] != typeof e[r]);
|
|
37
70
|
if (n)
|
|
38
|
-
throw new
|
|
71
|
+
throw new An(n);
|
|
39
72
|
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Constructs a new DuplicateParamsError instance with a message indicating the problematic parameter.
|
|
43
|
-
* @param paramName - The name of the parameter that was duplicated.
|
|
44
|
-
*/
|
|
45
|
-
constructor(t) {
|
|
46
|
-
super(`Invalid Param "${t}": Router does not support multiple params by the same name. All param names must be unique.`);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
function Y(e) {
|
|
73
|
+
function ee(e) {
|
|
50
74
|
return Array.isArray(e) ? e : [e];
|
|
51
75
|
}
|
|
52
|
-
function
|
|
76
|
+
function Et(e, t) {
|
|
53
77
|
return e.filter((n) => t === n).length;
|
|
54
78
|
}
|
|
55
|
-
function
|
|
56
|
-
const t = e.flatMap((n) => Array.isArray(n) ? n : Object.keys(n).map(
|
|
79
|
+
function ce(...e) {
|
|
80
|
+
const t = e.flatMap((n) => Array.isArray(n) ? n : Object.keys(n).map(Nn));
|
|
57
81
|
for (const n of t)
|
|
58
|
-
if (
|
|
59
|
-
throw new
|
|
82
|
+
if (Et(t, n) > 1)
|
|
83
|
+
throw new kn(n);
|
|
60
84
|
}
|
|
61
|
-
function
|
|
85
|
+
function Nn(e) {
|
|
62
86
|
return e.startsWith("?") ? e.slice(1) : e;
|
|
63
87
|
}
|
|
64
|
-
function
|
|
65
|
-
return
|
|
88
|
+
function Vn(e, t) {
|
|
89
|
+
return ce(e.params, t.params), {
|
|
66
90
|
value: `${e.value}${t.value}`,
|
|
67
91
|
params: { ...e.params, ...t.params }
|
|
68
92
|
};
|
|
69
93
|
}
|
|
70
|
-
function
|
|
71
|
-
return
|
|
72
|
-
value: [e.value, t.value].filter(
|
|
94
|
+
function Hn(e, t) {
|
|
95
|
+
return ce(e.params, t.params), {
|
|
96
|
+
value: [e.value, t.value].filter(me).join("&"),
|
|
73
97
|
params: { ...e.params, ...t.params }
|
|
74
98
|
};
|
|
75
99
|
}
|
|
76
|
-
function
|
|
77
|
-
return
|
|
100
|
+
function jn(e, t) {
|
|
101
|
+
return ce(e, t), { ...e, ...t };
|
|
78
102
|
}
|
|
79
|
-
function
|
|
103
|
+
function $n(e) {
|
|
80
104
|
return "host" in e && !!e.host;
|
|
81
105
|
}
|
|
82
|
-
function
|
|
106
|
+
function bt(e) {
|
|
83
107
|
return "parent" in e && !!e.parent;
|
|
84
108
|
}
|
|
85
109
|
function _e(e) {
|
|
86
110
|
return "component" in e && !!e.component;
|
|
87
111
|
}
|
|
88
|
-
function
|
|
112
|
+
function We(e) {
|
|
89
113
|
return "components" in e && !!e.components;
|
|
90
114
|
}
|
|
91
|
-
function
|
|
115
|
+
function On(e) {
|
|
92
116
|
return "state" in e && !!e.state;
|
|
93
117
|
}
|
|
94
|
-
function
|
|
118
|
+
function St(e, t) {
|
|
95
119
|
return {
|
|
96
120
|
...t,
|
|
97
|
-
path:
|
|
98
|
-
query:
|
|
99
|
-
meta:
|
|
100
|
-
state:
|
|
101
|
-
hash:
|
|
121
|
+
path: Vn(e.path, t.path),
|
|
122
|
+
query: Hn(e.query, t.query),
|
|
123
|
+
meta: Cn(e.meta, t.meta),
|
|
124
|
+
state: jn(e.state, t.state),
|
|
125
|
+
hash: Un(e.hash, t.hash),
|
|
102
126
|
matches: [...e.matches, t.matched],
|
|
103
127
|
host: e.host,
|
|
104
128
|
depth: e.depth + 1
|
|
105
129
|
};
|
|
106
130
|
}
|
|
107
|
-
function
|
|
131
|
+
function De() {
|
|
108
132
|
return typeof window < "u" && typeof window.document < "u";
|
|
109
133
|
}
|
|
110
|
-
class
|
|
134
|
+
class ie extends Error {
|
|
111
135
|
}
|
|
112
|
-
const
|
|
113
|
-
function
|
|
136
|
+
const F = "[", K = "]";
|
|
137
|
+
function qn(e) {
|
|
114
138
|
return e !== String && e !== Boolean && e !== Number && e !== Date;
|
|
115
139
|
}
|
|
116
|
-
function
|
|
117
|
-
return typeof e == "function" &&
|
|
140
|
+
function _n(e) {
|
|
141
|
+
return typeof e == "function" && qn(e);
|
|
118
142
|
}
|
|
119
|
-
function
|
|
143
|
+
function Ce(e) {
|
|
120
144
|
return typeof e == "object" && "get" in e && typeof e.get == "function" && "set" in e && typeof e.set == "function";
|
|
121
145
|
}
|
|
122
|
-
function
|
|
123
|
-
return
|
|
146
|
+
function Wn(e) {
|
|
147
|
+
return Ce(e) && e.defaultValue !== void 0;
|
|
124
148
|
}
|
|
125
|
-
function
|
|
126
|
-
return
|
|
149
|
+
function so(e, t) {
|
|
150
|
+
return Tn(e, t);
|
|
127
151
|
}
|
|
128
|
-
function
|
|
152
|
+
function Dn(e, t) {
|
|
129
153
|
return e[t] ?? String;
|
|
130
154
|
}
|
|
131
|
-
const
|
|
155
|
+
const _ = {
|
|
132
156
|
invalid: (e) => {
|
|
133
|
-
throw new
|
|
157
|
+
throw new ie(e);
|
|
134
158
|
}
|
|
135
|
-
},
|
|
159
|
+
}, Mn = {
|
|
136
160
|
get: (e) => e,
|
|
137
161
|
set: (e, { invalid: t }) => {
|
|
138
162
|
if (typeof e != "string")
|
|
139
163
|
throw t();
|
|
140
164
|
return e;
|
|
141
165
|
}
|
|
142
|
-
},
|
|
166
|
+
}, kt = {
|
|
143
167
|
get: (e, { invalid: t }) => {
|
|
144
168
|
if (e === "true")
|
|
145
169
|
return !0;
|
|
@@ -152,7 +176,7 @@ const O = {
|
|
|
152
176
|
throw t();
|
|
153
177
|
return e.toString();
|
|
154
178
|
}
|
|
155
|
-
},
|
|
179
|
+
}, At = {
|
|
156
180
|
get: (e, { invalid: t }) => {
|
|
157
181
|
const n = Number(e);
|
|
158
182
|
if (isNaN(n))
|
|
@@ -164,7 +188,7 @@ const O = {
|
|
|
164
188
|
throw t();
|
|
165
189
|
return e.toString();
|
|
166
190
|
}
|
|
167
|
-
},
|
|
191
|
+
}, xt = {
|
|
168
192
|
get: (e, { invalid: t }) => {
|
|
169
193
|
const n = new Date(e);
|
|
170
194
|
if (isNaN(n.getTime()))
|
|
@@ -176,7 +200,7 @@ const O = {
|
|
|
176
200
|
throw t();
|
|
177
201
|
return e.toISOString();
|
|
178
202
|
}
|
|
179
|
-
},
|
|
203
|
+
}, Lt = {
|
|
180
204
|
get: (e, { invalid: t }) => {
|
|
181
205
|
try {
|
|
182
206
|
return JSON.parse(e);
|
|
@@ -192,84 +216,84 @@ const O = {
|
|
|
192
216
|
}
|
|
193
217
|
}
|
|
194
218
|
};
|
|
195
|
-
function
|
|
196
|
-
if (e === void 0 || !
|
|
197
|
-
if (
|
|
219
|
+
function fe(e, t, n = !1) {
|
|
220
|
+
if (e === void 0 || !me(e)) {
|
|
221
|
+
if (Wn(t))
|
|
198
222
|
return t.defaultValue;
|
|
199
223
|
if (n)
|
|
200
224
|
return;
|
|
201
|
-
throw new
|
|
225
|
+
throw new ie();
|
|
202
226
|
}
|
|
203
227
|
if (t === String)
|
|
204
|
-
return
|
|
228
|
+
return Mn.get(e, _);
|
|
205
229
|
if (t === Boolean)
|
|
206
|
-
return
|
|
230
|
+
return kt.get(e, _);
|
|
207
231
|
if (t === Number)
|
|
208
|
-
return
|
|
232
|
+
return At.get(e, _);
|
|
209
233
|
if (t === Date)
|
|
210
|
-
return
|
|
234
|
+
return xt.get(e, _);
|
|
211
235
|
if (t === JSON)
|
|
212
|
-
return
|
|
213
|
-
if (
|
|
214
|
-
return t(e,
|
|
215
|
-
if (
|
|
216
|
-
return t.get(e,
|
|
236
|
+
return Lt.get(e, _);
|
|
237
|
+
if (_n(t))
|
|
238
|
+
return t(e, _);
|
|
239
|
+
if (Ce(t))
|
|
240
|
+
return t.get(e, _);
|
|
217
241
|
if (t instanceof RegExp) {
|
|
218
242
|
if (t.test(e))
|
|
219
243
|
return e;
|
|
220
|
-
throw new
|
|
244
|
+
throw new ie();
|
|
221
245
|
}
|
|
222
246
|
return e;
|
|
223
247
|
}
|
|
224
|
-
function
|
|
248
|
+
function le(e, t, n = !1) {
|
|
225
249
|
if (e === void 0) {
|
|
226
250
|
if (n)
|
|
227
251
|
return "";
|
|
228
|
-
throw new
|
|
252
|
+
throw new ie();
|
|
229
253
|
}
|
|
230
254
|
if (t === Boolean)
|
|
231
|
-
return
|
|
255
|
+
return kt.set(e, _);
|
|
232
256
|
if (t === Number)
|
|
233
|
-
return
|
|
257
|
+
return At.set(e, _);
|
|
234
258
|
if (t === Date)
|
|
235
|
-
return
|
|
259
|
+
return xt.set(e, _);
|
|
236
260
|
if (t === JSON)
|
|
237
|
-
return
|
|
238
|
-
if (
|
|
239
|
-
return t.set(e,
|
|
261
|
+
return Lt.set(e, _);
|
|
262
|
+
if (Ce(t))
|
|
263
|
+
return t.set(e, _);
|
|
240
264
|
try {
|
|
241
265
|
return e.toString();
|
|
242
266
|
} catch {
|
|
243
|
-
throw new
|
|
267
|
+
throw new ie();
|
|
244
268
|
}
|
|
245
269
|
}
|
|
246
|
-
function
|
|
247
|
-
return
|
|
248
|
-
get: (n) =>
|
|
249
|
-
set: (n) =>
|
|
270
|
+
function Tn(e, t) {
|
|
271
|
+
return Ce(e) ? { ...e, defaultValue: t ?? e.defaultValue } : {
|
|
272
|
+
get: (n) => fe(n, e),
|
|
273
|
+
set: (n) => le(n, e),
|
|
250
274
|
defaultValue: t
|
|
251
275
|
};
|
|
252
276
|
}
|
|
253
|
-
function
|
|
254
|
-
return
|
|
277
|
+
function G() {
|
|
278
|
+
return G = Object.assign ? Object.assign.bind() : function(e) {
|
|
255
279
|
for (var t = 1; t < arguments.length; t++) {
|
|
256
280
|
var n = arguments[t];
|
|
257
281
|
for (var r in n)
|
|
258
282
|
Object.prototype.hasOwnProperty.call(n, r) && (e[r] = n[r]);
|
|
259
283
|
}
|
|
260
284
|
return e;
|
|
261
|
-
},
|
|
285
|
+
}, G.apply(this, arguments);
|
|
262
286
|
}
|
|
263
|
-
var
|
|
287
|
+
var j;
|
|
264
288
|
(function(e) {
|
|
265
289
|
e.Pop = "POP", e.Push = "PUSH", e.Replace = "REPLACE";
|
|
266
|
-
})(
|
|
267
|
-
var
|
|
290
|
+
})(j || (j = {}));
|
|
291
|
+
var ne = process.env.NODE_ENV !== "production" ? function(e) {
|
|
268
292
|
return Object.freeze(e);
|
|
269
293
|
} : function(e) {
|
|
270
294
|
return e;
|
|
271
295
|
};
|
|
272
|
-
function
|
|
296
|
+
function Y(e, t) {
|
|
273
297
|
if (!e) {
|
|
274
298
|
typeof console < "u" && console.warn(t);
|
|
275
299
|
try {
|
|
@@ -278,38 +302,38 @@ function K(e, t) {
|
|
|
278
302
|
}
|
|
279
303
|
}
|
|
280
304
|
}
|
|
281
|
-
var
|
|
282
|
-
function
|
|
305
|
+
var Pe = "beforeunload", In = "hashchange", Ut = "popstate";
|
|
306
|
+
function rt(e) {
|
|
283
307
|
e === void 0 && (e = {});
|
|
284
308
|
var t = e, n = t.window, r = n === void 0 ? document.defaultView : n, o = r.history;
|
|
285
309
|
function a() {
|
|
286
|
-
var
|
|
287
|
-
return [
|
|
288
|
-
pathname:
|
|
289
|
-
search:
|
|
290
|
-
hash:
|
|
291
|
-
state:
|
|
292
|
-
key:
|
|
310
|
+
var g = r.location, l = g.pathname, y = g.search, S = g.hash, k = o.state || {};
|
|
311
|
+
return [k.idx, ne({
|
|
312
|
+
pathname: l,
|
|
313
|
+
search: y,
|
|
314
|
+
hash: S,
|
|
315
|
+
state: k.usr || null,
|
|
316
|
+
key: k.key || "default"
|
|
293
317
|
})];
|
|
294
318
|
}
|
|
295
|
-
var
|
|
296
|
-
function
|
|
297
|
-
if (
|
|
298
|
-
|
|
319
|
+
var c = null;
|
|
320
|
+
function s() {
|
|
321
|
+
if (c)
|
|
322
|
+
h.call(c), c = null;
|
|
299
323
|
else {
|
|
300
|
-
var
|
|
301
|
-
if (
|
|
302
|
-
if (
|
|
303
|
-
var
|
|
304
|
-
|
|
305
|
-
action:
|
|
306
|
-
location:
|
|
324
|
+
var g = j.Pop, l = a(), y = l[0], S = l[1];
|
|
325
|
+
if (h.length)
|
|
326
|
+
if (y != null) {
|
|
327
|
+
var k = f - y;
|
|
328
|
+
k && (c = {
|
|
329
|
+
action: g,
|
|
330
|
+
location: S,
|
|
307
331
|
retry: function() {
|
|
308
|
-
|
|
332
|
+
L(k * -1);
|
|
309
333
|
}
|
|
310
|
-
},
|
|
334
|
+
}, L(k));
|
|
311
335
|
} else
|
|
312
|
-
process.env.NODE_ENV !== "production" &&
|
|
336
|
+
process.env.NODE_ENV !== "production" && Y(
|
|
313
337
|
!1,
|
|
314
338
|
// TODO: Write up a doc that explains our blocking strategy in
|
|
315
339
|
// detail and link to it here so people can understand better what
|
|
@@ -317,137 +341,137 @@ function ot(e) {
|
|
|
317
341
|
"You are trying to block a POP navigation to a location that was not created by the history library. The block will fail silently in production, but in general you should do all navigation with the history library (instead of using window.history.pushState directly) to avoid this situation."
|
|
318
342
|
);
|
|
319
343
|
else
|
|
320
|
-
A(
|
|
344
|
+
A(g);
|
|
321
345
|
}
|
|
322
346
|
}
|
|
323
|
-
r.addEventListener(
|
|
324
|
-
var u =
|
|
325
|
-
f == null && (f = 0, o.replaceState(
|
|
347
|
+
r.addEventListener(Ut, s);
|
|
348
|
+
var u = j.Pop, i = a(), f = i[0], p = i[1], P = re(), h = re();
|
|
349
|
+
f == null && (f = 0, o.replaceState(G({}, o.state, {
|
|
326
350
|
idx: f
|
|
327
351
|
}), ""));
|
|
328
|
-
function
|
|
329
|
-
return typeof
|
|
352
|
+
function m(g) {
|
|
353
|
+
return typeof g == "string" ? g : X(g);
|
|
330
354
|
}
|
|
331
|
-
function
|
|
332
|
-
return
|
|
333
|
-
pathname:
|
|
355
|
+
function v(g, l) {
|
|
356
|
+
return l === void 0 && (l = null), ne(G({
|
|
357
|
+
pathname: p.pathname,
|
|
334
358
|
hash: "",
|
|
335
359
|
search: ""
|
|
336
|
-
}, typeof
|
|
337
|
-
state:
|
|
338
|
-
key:
|
|
360
|
+
}, typeof g == "string" ? he(g) : g, {
|
|
361
|
+
state: l,
|
|
362
|
+
key: be()
|
|
339
363
|
}));
|
|
340
364
|
}
|
|
341
|
-
function
|
|
365
|
+
function w(g, l) {
|
|
342
366
|
return [{
|
|
343
|
-
usr:
|
|
344
|
-
key:
|
|
345
|
-
idx:
|
|
346
|
-
},
|
|
347
|
-
}
|
|
348
|
-
function
|
|
349
|
-
return !
|
|
350
|
-
action:
|
|
351
|
-
location:
|
|
352
|
-
retry:
|
|
367
|
+
usr: g.state,
|
|
368
|
+
key: g.key,
|
|
369
|
+
idx: l
|
|
370
|
+
}, m(g)];
|
|
371
|
+
}
|
|
372
|
+
function R(g, l, y) {
|
|
373
|
+
return !h.length || (h.call({
|
|
374
|
+
action: g,
|
|
375
|
+
location: l,
|
|
376
|
+
retry: y
|
|
353
377
|
}), !1);
|
|
354
378
|
}
|
|
355
|
-
function A(
|
|
356
|
-
u =
|
|
357
|
-
var
|
|
358
|
-
f =
|
|
379
|
+
function A(g) {
|
|
380
|
+
u = g;
|
|
381
|
+
var l = a();
|
|
382
|
+
f = l[0], p = l[1], P.call({
|
|
359
383
|
action: u,
|
|
360
|
-
location:
|
|
384
|
+
location: p
|
|
361
385
|
});
|
|
362
386
|
}
|
|
363
|
-
function d(
|
|
364
|
-
var
|
|
365
|
-
function
|
|
366
|
-
d(
|
|
387
|
+
function d(g, l) {
|
|
388
|
+
var y = j.Push, S = v(g, l);
|
|
389
|
+
function k() {
|
|
390
|
+
d(g, l);
|
|
367
391
|
}
|
|
368
|
-
if (
|
|
369
|
-
var
|
|
392
|
+
if (R(y, S, k)) {
|
|
393
|
+
var U = w(S, f + 1), C = U[0], O = U[1];
|
|
370
394
|
try {
|
|
371
|
-
o.pushState(C, "",
|
|
395
|
+
o.pushState(C, "", O);
|
|
372
396
|
} catch {
|
|
373
|
-
r.location.assign(
|
|
397
|
+
r.location.assign(O);
|
|
374
398
|
}
|
|
375
|
-
A(
|
|
399
|
+
A(y);
|
|
376
400
|
}
|
|
377
401
|
}
|
|
378
|
-
function
|
|
379
|
-
var
|
|
380
|
-
function
|
|
381
|
-
|
|
402
|
+
function b(g, l) {
|
|
403
|
+
var y = j.Replace, S = v(g, l);
|
|
404
|
+
function k() {
|
|
405
|
+
b(g, l);
|
|
382
406
|
}
|
|
383
|
-
if (
|
|
384
|
-
var
|
|
385
|
-
o.replaceState(C, "",
|
|
407
|
+
if (R(y, S, k)) {
|
|
408
|
+
var U = w(S, f), C = U[0], O = U[1];
|
|
409
|
+
o.replaceState(C, "", O), A(y);
|
|
386
410
|
}
|
|
387
411
|
}
|
|
388
|
-
function
|
|
389
|
-
o.go(
|
|
412
|
+
function L(g) {
|
|
413
|
+
o.go(g);
|
|
390
414
|
}
|
|
391
|
-
var
|
|
415
|
+
var x = {
|
|
392
416
|
get action() {
|
|
393
417
|
return u;
|
|
394
418
|
},
|
|
395
419
|
get location() {
|
|
396
|
-
return
|
|
420
|
+
return p;
|
|
397
421
|
},
|
|
398
|
-
createHref:
|
|
422
|
+
createHref: m,
|
|
399
423
|
push: d,
|
|
400
|
-
replace:
|
|
401
|
-
go:
|
|
424
|
+
replace: b,
|
|
425
|
+
go: L,
|
|
402
426
|
back: function() {
|
|
403
|
-
|
|
427
|
+
L(-1);
|
|
404
428
|
},
|
|
405
429
|
forward: function() {
|
|
406
|
-
|
|
430
|
+
L(1);
|
|
407
431
|
},
|
|
408
|
-
listen: function(
|
|
409
|
-
return
|
|
432
|
+
listen: function(l) {
|
|
433
|
+
return P.push(l);
|
|
410
434
|
},
|
|
411
|
-
block: function(
|
|
412
|
-
var
|
|
413
|
-
return
|
|
414
|
-
|
|
435
|
+
block: function(l) {
|
|
436
|
+
var y = h.push(l);
|
|
437
|
+
return h.length === 1 && r.addEventListener(Pe, Ee), function() {
|
|
438
|
+
y(), h.length || r.removeEventListener(Pe, Ee);
|
|
415
439
|
};
|
|
416
440
|
}
|
|
417
441
|
};
|
|
418
|
-
return
|
|
442
|
+
return x;
|
|
419
443
|
}
|
|
420
|
-
function
|
|
444
|
+
function Fn(e) {
|
|
421
445
|
e === void 0 && (e = {});
|
|
422
446
|
var t = e, n = t.window, r = n === void 0 ? document.defaultView : n, o = r.history;
|
|
423
447
|
function a() {
|
|
424
|
-
var
|
|
425
|
-
return [
|
|
426
|
-
pathname:
|
|
427
|
-
search:
|
|
428
|
-
hash:
|
|
429
|
-
state:
|
|
430
|
-
key:
|
|
448
|
+
var l = he(r.location.hash.substr(1)), y = l.pathname, S = y === void 0 ? "/" : y, k = l.search, U = k === void 0 ? "" : k, C = l.hash, O = C === void 0 ? "" : C, W = o.state || {};
|
|
449
|
+
return [W.idx, ne({
|
|
450
|
+
pathname: S,
|
|
451
|
+
search: U,
|
|
452
|
+
hash: O,
|
|
453
|
+
state: W.usr || null,
|
|
454
|
+
key: W.key || "default"
|
|
431
455
|
})];
|
|
432
456
|
}
|
|
433
|
-
var
|
|
434
|
-
function
|
|
435
|
-
if (
|
|
436
|
-
|
|
457
|
+
var c = null;
|
|
458
|
+
function s() {
|
|
459
|
+
if (c)
|
|
460
|
+
h.call(c), c = null;
|
|
437
461
|
else {
|
|
438
|
-
var
|
|
439
|
-
if (
|
|
440
|
-
if (
|
|
441
|
-
var
|
|
442
|
-
|
|
443
|
-
action:
|
|
444
|
-
location:
|
|
462
|
+
var l = j.Pop, y = a(), S = y[0], k = y[1];
|
|
463
|
+
if (h.length)
|
|
464
|
+
if (S != null) {
|
|
465
|
+
var U = f - S;
|
|
466
|
+
U && (c = {
|
|
467
|
+
action: l,
|
|
468
|
+
location: k,
|
|
445
469
|
retry: function() {
|
|
446
|
-
U
|
|
470
|
+
x(U * -1);
|
|
447
471
|
}
|
|
448
|
-
}, U
|
|
472
|
+
}, x(U));
|
|
449
473
|
} else
|
|
450
|
-
process.env.NODE_ENV !== "production" &&
|
|
474
|
+
process.env.NODE_ENV !== "production" && Y(
|
|
451
475
|
!1,
|
|
452
476
|
// TODO: Write up a doc that explains our blocking strategy in
|
|
453
477
|
// detail and link to it here so people can understand better
|
|
@@ -455,212 +479,212 @@ function Dn(e) {
|
|
|
455
479
|
"You are trying to block a POP navigation to a location that was not created by the history library. The block will fail silently in production, but in general you should do all navigation with the history library (instead of using window.history.pushState directly) to avoid this situation."
|
|
456
480
|
);
|
|
457
481
|
else
|
|
458
|
-
d(
|
|
482
|
+
d(l);
|
|
459
483
|
}
|
|
460
484
|
}
|
|
461
|
-
r.addEventListener(
|
|
462
|
-
var
|
|
463
|
-
|
|
485
|
+
r.addEventListener(Ut, s), r.addEventListener(In, function() {
|
|
486
|
+
var l = a(), y = l[1];
|
|
487
|
+
X(y) !== X(p) && s();
|
|
464
488
|
});
|
|
465
|
-
var u =
|
|
466
|
-
f == null && (f = 0, o.replaceState(
|
|
489
|
+
var u = j.Pop, i = a(), f = i[0], p = i[1], P = re(), h = re();
|
|
490
|
+
f == null && (f = 0, o.replaceState(G({}, o.state, {
|
|
467
491
|
idx: f
|
|
468
492
|
}), ""));
|
|
469
|
-
function
|
|
470
|
-
var
|
|
471
|
-
if (
|
|
472
|
-
var
|
|
473
|
-
|
|
493
|
+
function m() {
|
|
494
|
+
var l = document.querySelector("base"), y = "";
|
|
495
|
+
if (l && l.getAttribute("href")) {
|
|
496
|
+
var S = r.location.href, k = S.indexOf("#");
|
|
497
|
+
y = k === -1 ? S : S.slice(0, k);
|
|
474
498
|
}
|
|
475
|
-
return
|
|
499
|
+
return y;
|
|
476
500
|
}
|
|
477
|
-
function
|
|
478
|
-
return
|
|
501
|
+
function v(l) {
|
|
502
|
+
return m() + "#" + (typeof l == "string" ? l : X(l));
|
|
479
503
|
}
|
|
480
|
-
function
|
|
481
|
-
return
|
|
482
|
-
pathname:
|
|
504
|
+
function w(l, y) {
|
|
505
|
+
return y === void 0 && (y = null), ne(G({
|
|
506
|
+
pathname: p.pathname,
|
|
483
507
|
hash: "",
|
|
484
508
|
search: ""
|
|
485
|
-
}, typeof
|
|
486
|
-
state:
|
|
487
|
-
key:
|
|
509
|
+
}, typeof l == "string" ? he(l) : l, {
|
|
510
|
+
state: y,
|
|
511
|
+
key: be()
|
|
488
512
|
}));
|
|
489
513
|
}
|
|
490
|
-
function
|
|
514
|
+
function R(l, y) {
|
|
491
515
|
return [{
|
|
492
|
-
usr:
|
|
493
|
-
key:
|
|
494
|
-
idx:
|
|
495
|
-
},
|
|
496
|
-
}
|
|
497
|
-
function A(
|
|
498
|
-
return !
|
|
499
|
-
action:
|
|
500
|
-
location:
|
|
501
|
-
retry:
|
|
516
|
+
usr: l.state,
|
|
517
|
+
key: l.key,
|
|
518
|
+
idx: y
|
|
519
|
+
}, v(l)];
|
|
520
|
+
}
|
|
521
|
+
function A(l, y, S) {
|
|
522
|
+
return !h.length || (h.call({
|
|
523
|
+
action: l,
|
|
524
|
+
location: y,
|
|
525
|
+
retry: S
|
|
502
526
|
}), !1);
|
|
503
527
|
}
|
|
504
|
-
function d(
|
|
505
|
-
u =
|
|
506
|
-
var
|
|
507
|
-
f =
|
|
528
|
+
function d(l) {
|
|
529
|
+
u = l;
|
|
530
|
+
var y = a();
|
|
531
|
+
f = y[0], p = y[1], P.call({
|
|
508
532
|
action: u,
|
|
509
|
-
location:
|
|
533
|
+
location: p
|
|
510
534
|
});
|
|
511
535
|
}
|
|
512
|
-
function
|
|
513
|
-
var
|
|
514
|
-
function
|
|
515
|
-
|
|
536
|
+
function b(l, y) {
|
|
537
|
+
var S = j.Push, k = w(l, y);
|
|
538
|
+
function U() {
|
|
539
|
+
b(l, y);
|
|
516
540
|
}
|
|
517
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
518
|
-
var C = k
|
|
541
|
+
if (process.env.NODE_ENV !== "production" && Y(k.pathname.charAt(0) === "/", "Relative pathnames are not supported in hash history.push(" + JSON.stringify(l) + ")"), A(S, k, U)) {
|
|
542
|
+
var C = R(k, f + 1), O = C[0], W = C[1];
|
|
519
543
|
try {
|
|
520
|
-
o.pushState(
|
|
544
|
+
o.pushState(O, "", W);
|
|
521
545
|
} catch {
|
|
522
|
-
r.location.assign(
|
|
546
|
+
r.location.assign(W);
|
|
523
547
|
}
|
|
524
|
-
d(
|
|
548
|
+
d(S);
|
|
525
549
|
}
|
|
526
550
|
}
|
|
527
|
-
function
|
|
528
|
-
var
|
|
529
|
-
function
|
|
530
|
-
|
|
551
|
+
function L(l, y) {
|
|
552
|
+
var S = j.Replace, k = w(l, y);
|
|
553
|
+
function U() {
|
|
554
|
+
L(l, y);
|
|
531
555
|
}
|
|
532
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
533
|
-
var C = k
|
|
534
|
-
o.replaceState(
|
|
556
|
+
if (process.env.NODE_ENV !== "production" && Y(k.pathname.charAt(0) === "/", "Relative pathnames are not supported in hash history.replace(" + JSON.stringify(l) + ")"), A(S, k, U)) {
|
|
557
|
+
var C = R(k, f), O = C[0], W = C[1];
|
|
558
|
+
o.replaceState(O, "", W), d(S);
|
|
535
559
|
}
|
|
536
560
|
}
|
|
537
|
-
function
|
|
538
|
-
o.go(
|
|
561
|
+
function x(l) {
|
|
562
|
+
o.go(l);
|
|
539
563
|
}
|
|
540
|
-
var
|
|
564
|
+
var g = {
|
|
541
565
|
get action() {
|
|
542
566
|
return u;
|
|
543
567
|
},
|
|
544
568
|
get location() {
|
|
545
|
-
return
|
|
569
|
+
return p;
|
|
546
570
|
},
|
|
547
|
-
createHref:
|
|
548
|
-
push:
|
|
549
|
-
replace:
|
|
550
|
-
go:
|
|
571
|
+
createHref: v,
|
|
572
|
+
push: b,
|
|
573
|
+
replace: L,
|
|
574
|
+
go: x,
|
|
551
575
|
back: function() {
|
|
552
|
-
|
|
576
|
+
x(-1);
|
|
553
577
|
},
|
|
554
578
|
forward: function() {
|
|
555
|
-
|
|
579
|
+
x(1);
|
|
556
580
|
},
|
|
557
|
-
listen: function(
|
|
558
|
-
return
|
|
581
|
+
listen: function(y) {
|
|
582
|
+
return P.push(y);
|
|
559
583
|
},
|
|
560
|
-
block: function(
|
|
561
|
-
var
|
|
562
|
-
return
|
|
563
|
-
|
|
584
|
+
block: function(y) {
|
|
585
|
+
var S = h.push(y);
|
|
586
|
+
return h.length === 1 && r.addEventListener(Pe, Ee), function() {
|
|
587
|
+
S(), h.length || r.removeEventListener(Pe, Ee);
|
|
564
588
|
};
|
|
565
589
|
}
|
|
566
590
|
};
|
|
567
|
-
return
|
|
591
|
+
return g;
|
|
568
592
|
}
|
|
569
|
-
function
|
|
593
|
+
function ot(e) {
|
|
570
594
|
e === void 0 && (e = {});
|
|
571
595
|
var t = e, n = t.initialEntries, r = n === void 0 ? ["/"] : n, o = t.initialIndex, a = r.map(function(d) {
|
|
572
|
-
var
|
|
596
|
+
var b = ne(G({
|
|
573
597
|
pathname: "/",
|
|
574
598
|
search: "",
|
|
575
599
|
hash: "",
|
|
576
600
|
state: null,
|
|
577
|
-
key:
|
|
578
|
-
}, typeof d == "string" ?
|
|
579
|
-
return process.env.NODE_ENV !== "production" &&
|
|
580
|
-
}),
|
|
581
|
-
function
|
|
582
|
-
return typeof d == "string" ? d :
|
|
583
|
-
}
|
|
584
|
-
function
|
|
585
|
-
return
|
|
601
|
+
key: be()
|
|
602
|
+
}, typeof d == "string" ? he(d) : d));
|
|
603
|
+
return process.env.NODE_ENV !== "production" && Y(b.pathname.charAt(0) === "/", "Relative pathnames are not supported in createMemoryHistory({ initialEntries }) (invalid entry: " + JSON.stringify(d) + ")"), b;
|
|
604
|
+
}), c = at(o ?? a.length - 1, 0, a.length - 1), s = j.Pop, u = a[c], i = re(), f = re();
|
|
605
|
+
function p(d) {
|
|
606
|
+
return typeof d == "string" ? d : X(d);
|
|
607
|
+
}
|
|
608
|
+
function P(d, b) {
|
|
609
|
+
return b === void 0 && (b = null), ne(G({
|
|
586
610
|
pathname: u.pathname,
|
|
587
611
|
search: "",
|
|
588
612
|
hash: ""
|
|
589
|
-
}, typeof d == "string" ?
|
|
590
|
-
state:
|
|
591
|
-
key:
|
|
613
|
+
}, typeof d == "string" ? he(d) : d, {
|
|
614
|
+
state: b,
|
|
615
|
+
key: be()
|
|
592
616
|
}));
|
|
593
617
|
}
|
|
594
|
-
function
|
|
618
|
+
function h(d, b, L) {
|
|
595
619
|
return !f.length || (f.call({
|
|
596
620
|
action: d,
|
|
597
|
-
location:
|
|
598
|
-
retry:
|
|
621
|
+
location: b,
|
|
622
|
+
retry: L
|
|
599
623
|
}), !1);
|
|
600
624
|
}
|
|
601
|
-
function
|
|
602
|
-
|
|
603
|
-
action:
|
|
625
|
+
function m(d, b) {
|
|
626
|
+
s = d, u = b, i.call({
|
|
627
|
+
action: s,
|
|
604
628
|
location: u
|
|
605
629
|
});
|
|
606
630
|
}
|
|
607
|
-
function
|
|
608
|
-
var
|
|
609
|
-
function
|
|
610
|
-
|
|
631
|
+
function v(d, b) {
|
|
632
|
+
var L = j.Push, x = P(d, b);
|
|
633
|
+
function g() {
|
|
634
|
+
v(d, b);
|
|
611
635
|
}
|
|
612
|
-
process.env.NODE_ENV !== "production" &&
|
|
636
|
+
process.env.NODE_ENV !== "production" && Y(u.pathname.charAt(0) === "/", "Relative pathnames are not supported in memory history.push(" + JSON.stringify(d) + ")"), h(L, x, g) && (c += 1, a.splice(c, a.length, x), m(L, x));
|
|
613
637
|
}
|
|
614
|
-
function
|
|
615
|
-
var
|
|
616
|
-
function
|
|
617
|
-
|
|
638
|
+
function w(d, b) {
|
|
639
|
+
var L = j.Replace, x = P(d, b);
|
|
640
|
+
function g() {
|
|
641
|
+
w(d, b);
|
|
618
642
|
}
|
|
619
|
-
process.env.NODE_ENV !== "production" &&
|
|
643
|
+
process.env.NODE_ENV !== "production" && Y(u.pathname.charAt(0) === "/", "Relative pathnames are not supported in memory history.replace(" + JSON.stringify(d) + ")"), h(L, x, g) && (a[c] = x, m(L, x));
|
|
620
644
|
}
|
|
621
|
-
function
|
|
622
|
-
var
|
|
623
|
-
function
|
|
624
|
-
|
|
645
|
+
function R(d) {
|
|
646
|
+
var b = at(c + d, 0, a.length - 1), L = j.Pop, x = a[b];
|
|
647
|
+
function g() {
|
|
648
|
+
R(d);
|
|
625
649
|
}
|
|
626
|
-
|
|
650
|
+
h(L, x, g) && (c = b, m(L, x));
|
|
627
651
|
}
|
|
628
652
|
var A = {
|
|
629
653
|
get index() {
|
|
630
|
-
return
|
|
654
|
+
return c;
|
|
631
655
|
},
|
|
632
656
|
get action() {
|
|
633
|
-
return
|
|
657
|
+
return s;
|
|
634
658
|
},
|
|
635
659
|
get location() {
|
|
636
660
|
return u;
|
|
637
661
|
},
|
|
638
|
-
createHref:
|
|
639
|
-
push:
|
|
640
|
-
replace:
|
|
641
|
-
go:
|
|
662
|
+
createHref: p,
|
|
663
|
+
push: v,
|
|
664
|
+
replace: w,
|
|
665
|
+
go: R,
|
|
642
666
|
back: function() {
|
|
643
|
-
|
|
667
|
+
R(-1);
|
|
644
668
|
},
|
|
645
669
|
forward: function() {
|
|
646
|
-
|
|
670
|
+
R(1);
|
|
647
671
|
},
|
|
648
|
-
listen: function(
|
|
649
|
-
return i.push(
|
|
672
|
+
listen: function(b) {
|
|
673
|
+
return i.push(b);
|
|
650
674
|
},
|
|
651
|
-
block: function(
|
|
652
|
-
return f.push(
|
|
675
|
+
block: function(b) {
|
|
676
|
+
return f.push(b);
|
|
653
677
|
}
|
|
654
678
|
};
|
|
655
679
|
return A;
|
|
656
680
|
}
|
|
657
|
-
function
|
|
681
|
+
function at(e, t, n) {
|
|
658
682
|
return Math.min(Math.max(e, t), n);
|
|
659
683
|
}
|
|
660
|
-
function
|
|
684
|
+
function Ee(e) {
|
|
661
685
|
e.preventDefault(), e.returnValue = "";
|
|
662
686
|
}
|
|
663
|
-
function
|
|
687
|
+
function re() {
|
|
664
688
|
var e = [];
|
|
665
689
|
return {
|
|
666
690
|
get length() {
|
|
@@ -680,14 +704,14 @@ function te() {
|
|
|
680
704
|
}
|
|
681
705
|
};
|
|
682
706
|
}
|
|
683
|
-
function
|
|
707
|
+
function be() {
|
|
684
708
|
return Math.random().toString(36).substr(2, 8);
|
|
685
709
|
}
|
|
686
|
-
function
|
|
687
|
-
var t = e.pathname, n = t === void 0 ? "/" : t, r = e.search, o = r === void 0 ? "" : r, a = e.hash,
|
|
688
|
-
return o && o !== "?" && (n += o.charAt(0) === "?" ? o : "?" + o),
|
|
710
|
+
function X(e) {
|
|
711
|
+
var t = e.pathname, n = t === void 0 ? "/" : t, r = e.search, o = r === void 0 ? "" : r, a = e.hash, c = a === void 0 ? "" : a;
|
|
712
|
+
return o && o !== "?" && (n += o.charAt(0) === "?" ? o : "?" + o), c && c !== "#" && (n += c.charAt(0) === "#" ? c : "#" + c), n;
|
|
689
713
|
}
|
|
690
|
-
function
|
|
714
|
+
function he(e) {
|
|
691
715
|
var t = {};
|
|
692
716
|
if (e) {
|
|
693
717
|
var n = e.indexOf("#");
|
|
@@ -697,74 +721,56 @@ function fe(e) {
|
|
|
697
721
|
}
|
|
698
722
|
return t;
|
|
699
723
|
}
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
* This detailed error message aids in quickly identifying and resolving mismatches in route usage.
|
|
704
|
-
* @param routeName - The route name that was incorrectly used.
|
|
705
|
-
* @param actualRouteName - The expected route name that should have been used.
|
|
706
|
-
*/
|
|
707
|
-
constructor(t, n) {
|
|
708
|
-
super(`useRoute called with incorrect route. Given ${t}, expected ${n}`);
|
|
709
|
-
}
|
|
710
|
-
}
|
|
711
|
-
const xt = Symbol();
|
|
712
|
-
function In() {
|
|
713
|
-
const e = re(xt);
|
|
724
|
+
const Ct = Symbol();
|
|
725
|
+
function Jn() {
|
|
726
|
+
const e = ae(Ct);
|
|
714
727
|
if (!e)
|
|
715
|
-
throw new
|
|
716
|
-
return e;
|
|
717
|
-
}
|
|
718
|
-
const Ut = Symbol();
|
|
719
|
-
function De() {
|
|
720
|
-
const e = re(Ut);
|
|
721
|
-
if (!e)
|
|
722
|
-
throw new he();
|
|
728
|
+
throw new pe();
|
|
723
729
|
return e;
|
|
724
730
|
}
|
|
725
731
|
const Bt = Symbol("isRouterRouteSymbol");
|
|
726
|
-
function
|
|
732
|
+
function Qn(e) {
|
|
727
733
|
return typeof e == "object" && e !== null && Bt in e;
|
|
728
734
|
}
|
|
729
|
-
function
|
|
730
|
-
function n(
|
|
731
|
-
if (typeof
|
|
732
|
-
const
|
|
735
|
+
function Gn(e, t) {
|
|
736
|
+
function n(w, R, A) {
|
|
737
|
+
if (typeof w == "object") {
|
|
738
|
+
const b = {
|
|
733
739
|
...e.params,
|
|
734
|
-
...
|
|
740
|
+
...w
|
|
735
741
|
};
|
|
736
|
-
return t(e.name,
|
|
742
|
+
return t(e.name, b, R);
|
|
737
743
|
}
|
|
738
|
-
const
|
|
744
|
+
const d = {
|
|
739
745
|
...e.params,
|
|
740
|
-
[
|
|
746
|
+
[w]: R
|
|
741
747
|
};
|
|
742
|
-
return t(e.name,
|
|
748
|
+
return t(e.name, d, A);
|
|
743
749
|
}
|
|
744
|
-
const r = (...
|
|
750
|
+
const r = (...w) => {
|
|
745
751
|
const R = new URLSearchParams(e.query.toString());
|
|
746
|
-
R.set(...
|
|
747
|
-
}, o = (...
|
|
752
|
+
R.set(...w), n({}, { query: R });
|
|
753
|
+
}, o = (...w) => {
|
|
748
754
|
const R = new URLSearchParams(e.query.toString());
|
|
749
|
-
R.append(...
|
|
750
|
-
}, a = (...
|
|
755
|
+
R.append(...w), n({}, { query: R });
|
|
756
|
+
}, a = (...w) => {
|
|
751
757
|
const R = new URLSearchParams(e.query.toString());
|
|
752
|
-
R.delete(...
|
|
753
|
-
}, { id:
|
|
758
|
+
R.delete(...w), n({}, { query: R });
|
|
759
|
+
}, { id: c, matched: s, matches: u, name: i, hash: f, href: p } = pn(e), P = N({
|
|
754
760
|
get() {
|
|
755
761
|
return new Proxy(e.params, {
|
|
756
|
-
set(
|
|
757
|
-
return n(R,
|
|
762
|
+
set(w, R, A) {
|
|
763
|
+
return n(R, A), !0;
|
|
758
764
|
}
|
|
759
765
|
});
|
|
760
766
|
},
|
|
761
|
-
set(
|
|
762
|
-
n(
|
|
767
|
+
set(w) {
|
|
768
|
+
n(w);
|
|
763
769
|
}
|
|
764
|
-
}),
|
|
770
|
+
}), h = N({
|
|
765
771
|
get() {
|
|
766
772
|
return new Proxy(e.query, {
|
|
767
|
-
get(
|
|
773
|
+
get(w, R, A) {
|
|
768
774
|
switch (R) {
|
|
769
775
|
case "append":
|
|
770
776
|
return o;
|
|
@@ -773,68 +779,69 @@ function Jn(e, t) {
|
|
|
773
779
|
case "delete":
|
|
774
780
|
return a;
|
|
775
781
|
default:
|
|
776
|
-
return Reflect.get(
|
|
782
|
+
return Reflect.get(w, R, A);
|
|
777
783
|
}
|
|
778
784
|
}
|
|
779
785
|
});
|
|
780
786
|
},
|
|
781
|
-
set(
|
|
782
|
-
n({}, { query:
|
|
787
|
+
set(w) {
|
|
788
|
+
n({}, { query: w });
|
|
783
789
|
}
|
|
784
|
-
}),
|
|
790
|
+
}), m = N({
|
|
785
791
|
get() {
|
|
786
792
|
return new Proxy(e.state, {
|
|
787
|
-
set(
|
|
788
|
-
return n({}, { state: { ...e.state, [R]:
|
|
793
|
+
set(w, R, A) {
|
|
794
|
+
return n({}, { state: { ...e.state, [R]: A } }), !0;
|
|
789
795
|
}
|
|
790
796
|
});
|
|
791
797
|
},
|
|
792
|
-
set(
|
|
793
|
-
n({}, { state:
|
|
798
|
+
set(w) {
|
|
799
|
+
n({}, { state: w });
|
|
794
800
|
}
|
|
795
801
|
});
|
|
796
802
|
return Ue({
|
|
797
|
-
id:
|
|
798
|
-
matched:
|
|
803
|
+
id: c,
|
|
804
|
+
matched: s,
|
|
799
805
|
matches: u,
|
|
800
|
-
state:
|
|
801
|
-
query:
|
|
806
|
+
state: m,
|
|
807
|
+
query: h,
|
|
802
808
|
hash: f,
|
|
803
|
-
params:
|
|
809
|
+
params: P,
|
|
804
810
|
name: i,
|
|
811
|
+
href: p,
|
|
805
812
|
update: n,
|
|
806
813
|
[Bt]: !0
|
|
807
814
|
});
|
|
808
815
|
}
|
|
809
|
-
const
|
|
810
|
-
function
|
|
811
|
-
const n = Ue({ ...e }), r = (
|
|
816
|
+
const Nt = Symbol();
|
|
817
|
+
function Kn(e, t) {
|
|
818
|
+
const n = Ue({ ...e }), r = (c) => {
|
|
812
819
|
Object.assign(n, {
|
|
813
|
-
[
|
|
814
|
-
...
|
|
820
|
+
[Nt]: !1,
|
|
821
|
+
...c
|
|
815
822
|
});
|
|
816
|
-
}, o = n, a =
|
|
823
|
+
}, o = n, a = Gn(o, t);
|
|
817
824
|
return {
|
|
818
825
|
currentRoute: o,
|
|
819
826
|
routerRoute: a,
|
|
820
827
|
updateRoute: r
|
|
821
828
|
};
|
|
822
829
|
}
|
|
823
|
-
function
|
|
824
|
-
return !e.startsWith("http") ?
|
|
830
|
+
function D(e) {
|
|
831
|
+
return !e.startsWith("http") ? Yn(e) : zn(e);
|
|
825
832
|
}
|
|
826
|
-
function
|
|
827
|
-
const { protocol: t, host: n, pathname: r, search: o, searchParams: a, hash:
|
|
833
|
+
function zn(e) {
|
|
834
|
+
const { protocol: t, host: n, pathname: r, search: o, searchParams: a, hash: c } = new URL(e, e);
|
|
828
835
|
return {
|
|
829
836
|
protocol: t,
|
|
830
837
|
host: n,
|
|
831
838
|
pathname: r,
|
|
832
839
|
search: o,
|
|
833
840
|
searchParams: a,
|
|
834
|
-
hash:
|
|
841
|
+
hash: c
|
|
835
842
|
};
|
|
836
843
|
}
|
|
837
|
-
function
|
|
844
|
+
function Yn(e) {
|
|
838
845
|
const { pathname: t, search: n, searchParams: r, hash: o } = new URL(e, "https://localhost");
|
|
839
846
|
return {
|
|
840
847
|
pathname: t,
|
|
@@ -843,21 +850,21 @@ function Kn(e) {
|
|
|
843
850
|
hash: o
|
|
844
851
|
};
|
|
845
852
|
}
|
|
846
|
-
function
|
|
853
|
+
function Xn(e) {
|
|
847
854
|
return (t) => {
|
|
848
|
-
const { host: n } =
|
|
855
|
+
const { host: n } = D(t);
|
|
849
856
|
return !(n === void 0 || n === e);
|
|
850
857
|
};
|
|
851
858
|
}
|
|
852
|
-
function
|
|
853
|
-
const n =
|
|
859
|
+
function Zn({ mode: e, listener: t }) {
|
|
860
|
+
const n = er(e), r = (u, i) => {
|
|
854
861
|
if (i != null && i.replace) {
|
|
855
862
|
n.replace(u, i.state);
|
|
856
863
|
return;
|
|
857
864
|
}
|
|
858
865
|
n.push(u, i == null ? void 0 : i.state);
|
|
859
866
|
}, o = () => {
|
|
860
|
-
const u =
|
|
867
|
+
const u = X(n.location);
|
|
861
868
|
n.replace(u);
|
|
862
869
|
};
|
|
863
870
|
let a;
|
|
@@ -873,145 +880,139 @@ function Yn({ mode: e, listener: t }) {
|
|
|
873
880
|
}
|
|
874
881
|
};
|
|
875
882
|
}
|
|
876
|
-
function
|
|
883
|
+
function er(e = "auto") {
|
|
877
884
|
switch (e) {
|
|
878
885
|
case "auto":
|
|
879
|
-
return
|
|
886
|
+
return De() ? rt() : ot();
|
|
880
887
|
case "browser":
|
|
881
|
-
return
|
|
888
|
+
return rt();
|
|
882
889
|
case "memory":
|
|
883
|
-
return
|
|
890
|
+
return ot();
|
|
884
891
|
case "hash":
|
|
885
|
-
return
|
|
892
|
+
return Fn();
|
|
886
893
|
default:
|
|
887
894
|
const t = e;
|
|
888
895
|
throw new Error(`Switch is not exhaustive for mode: ${t}`);
|
|
889
896
|
}
|
|
890
897
|
}
|
|
891
|
-
class
|
|
898
|
+
class Se {
|
|
892
899
|
constructor() {
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
900
|
+
M(this, "onBeforeRouteEnter", /* @__PURE__ */ new Set());
|
|
901
|
+
M(this, "onBeforeRouteUpdate", /* @__PURE__ */ new Set());
|
|
902
|
+
M(this, "onBeforeRouteLeave", /* @__PURE__ */ new Set());
|
|
903
|
+
M(this, "onAfterRouteEnter", /* @__PURE__ */ new Set());
|
|
904
|
+
M(this, "onAfterRouteUpdate", /* @__PURE__ */ new Set());
|
|
905
|
+
M(this, "onAfterRouteLeave", /* @__PURE__ */ new Set());
|
|
899
906
|
}
|
|
900
907
|
}
|
|
901
|
-
class
|
|
908
|
+
class Vt extends Error {
|
|
902
909
|
constructor() {
|
|
903
910
|
super("Uncaught CallbackContextAbortError");
|
|
904
|
-
|
|
911
|
+
M(this, "response");
|
|
905
912
|
this.response = { status: "ABORT" };
|
|
906
913
|
}
|
|
907
914
|
}
|
|
908
|
-
class
|
|
915
|
+
class te extends Error {
|
|
909
916
|
constructor(n) {
|
|
910
917
|
super("Uncaught CallbackContextPushError");
|
|
911
|
-
|
|
918
|
+
M(this, "response");
|
|
912
919
|
this.response = { status: "PUSH", to: n };
|
|
913
920
|
}
|
|
914
921
|
}
|
|
915
|
-
class
|
|
922
|
+
class ke extends Error {
|
|
916
923
|
constructor(n) {
|
|
917
924
|
super("Uncaught CallbackContextRejectionError");
|
|
918
|
-
|
|
925
|
+
M(this, "response");
|
|
919
926
|
this.response = { status: "REJECT", type: n };
|
|
920
927
|
}
|
|
921
928
|
}
|
|
922
|
-
function
|
|
923
|
-
const n = new
|
|
929
|
+
function tr(e, t) {
|
|
930
|
+
const n = new Se();
|
|
924
931
|
return e.matches.forEach((r, o) => {
|
|
925
|
-
r.onBeforeRouteEnter &&
|
|
932
|
+
r.onBeforeRouteEnter && Me(e, t, o) && ee(r.onBeforeRouteEnter).forEach((a) => n.onBeforeRouteEnter.add(a)), r.onBeforeRouteUpdate && Ie(e, t, o) && ee(r.onBeforeRouteUpdate).forEach((a) => n.onBeforeRouteUpdate.add(a));
|
|
926
933
|
}), t.matches.forEach((r, o) => {
|
|
927
|
-
r.onBeforeRouteLeave &&
|
|
934
|
+
r.onBeforeRouteLeave && Te(e, t, o) && ee(r.onBeforeRouteLeave).forEach((a) => n.onBeforeRouteLeave.add(a));
|
|
928
935
|
}), n;
|
|
929
936
|
}
|
|
930
|
-
function
|
|
931
|
-
const n = new
|
|
937
|
+
function nr(e, t) {
|
|
938
|
+
const n = new Se();
|
|
932
939
|
return e.matches.forEach((r, o) => {
|
|
933
|
-
r.onAfterRouteEnter &&
|
|
940
|
+
r.onAfterRouteEnter && Me(e, t, o) && ee(r.onAfterRouteEnter).forEach((a) => n.onAfterRouteEnter.add(a)), r.onAfterRouteUpdate && Ie(e, t, o) && ee(r.onAfterRouteUpdate).forEach((a) => n.onAfterRouteUpdate.add(a));
|
|
934
941
|
}), t.matches.forEach((r, o) => {
|
|
935
|
-
r.onAfterRouteLeave &&
|
|
942
|
+
r.onAfterRouteLeave && Te(e, t, o) && ee(r.onAfterRouteLeave).forEach((a) => n.onAfterRouteLeave.add(a));
|
|
936
943
|
}), n;
|
|
937
944
|
}
|
|
938
|
-
function
|
|
939
|
-
return typeof e != "string" ? !1 : /^(https?:\/\/|\/).*/g.test(e);
|
|
940
|
-
}
|
|
941
|
-
function tr(e) {
|
|
942
|
-
return M(e) ? e : `/${e}`;
|
|
943
|
-
}
|
|
944
|
-
function Nt() {
|
|
945
|
+
function Ht() {
|
|
945
946
|
return { reject: (o) => {
|
|
946
|
-
throw new
|
|
947
|
+
throw new ke(o);
|
|
947
948
|
}, push: (...o) => {
|
|
948
|
-
throw new
|
|
949
|
-
}, replace: (o, a,
|
|
950
|
-
if (
|
|
949
|
+
throw new te(o);
|
|
950
|
+
}, replace: (o, a, c) => {
|
|
951
|
+
if (I(o)) {
|
|
951
952
|
const i = a ?? {};
|
|
952
|
-
throw new
|
|
953
|
+
throw new te([o, { ...i, replace: !0 }]);
|
|
953
954
|
}
|
|
954
|
-
const
|
|
955
|
-
throw new
|
|
955
|
+
const s = a, u = c ?? {};
|
|
956
|
+
throw new te([o, s, { ...u, replace: !0 }]);
|
|
956
957
|
}, abort: () => {
|
|
957
|
-
throw new
|
|
958
|
+
throw new Vt();
|
|
958
959
|
} };
|
|
959
960
|
}
|
|
960
|
-
function
|
|
961
|
-
const { reject: e, push: t, replace: n, abort: r } =
|
|
962
|
-
async function o({ to:
|
|
963
|
-
const { global: i, component: f } = u,
|
|
961
|
+
function rr() {
|
|
962
|
+
const { reject: e, push: t, replace: n, abort: r } = Ht();
|
|
963
|
+
async function o({ to: c, from: s, hooks: u }) {
|
|
964
|
+
const { global: i, component: f } = u, p = tr(c, s), P = [
|
|
964
965
|
...i.onBeforeRouteEnter,
|
|
965
|
-
...
|
|
966
|
+
...p.onBeforeRouteEnter,
|
|
966
967
|
...i.onBeforeRouteUpdate,
|
|
967
|
-
...
|
|
968
|
+
...p.onBeforeRouteUpdate,
|
|
968
969
|
...f.onBeforeRouteUpdate,
|
|
969
970
|
...i.onBeforeRouteLeave,
|
|
970
|
-
...
|
|
971
|
+
...p.onBeforeRouteLeave,
|
|
971
972
|
...f.onBeforeRouteLeave
|
|
972
973
|
];
|
|
973
974
|
try {
|
|
974
|
-
const
|
|
975
|
-
from:
|
|
975
|
+
const h = P.map((m) => m(c, {
|
|
976
|
+
from: s,
|
|
976
977
|
reject: e,
|
|
977
978
|
push: t,
|
|
978
979
|
replace: n,
|
|
979
980
|
abort: r
|
|
980
981
|
}));
|
|
981
|
-
await Promise.all(
|
|
982
|
-
} catch (
|
|
983
|
-
if (
|
|
984
|
-
return
|
|
985
|
-
throw
|
|
982
|
+
await Promise.all(h);
|
|
983
|
+
} catch (h) {
|
|
984
|
+
if (h instanceof te || h instanceof ke || h instanceof Vt)
|
|
985
|
+
return h.response;
|
|
986
|
+
throw h;
|
|
986
987
|
}
|
|
987
988
|
return {
|
|
988
989
|
status: "SUCCESS"
|
|
989
990
|
};
|
|
990
991
|
}
|
|
991
|
-
async function a({ to:
|
|
992
|
-
const { global: i, component: f } = u,
|
|
992
|
+
async function a({ to: c, from: s, hooks: u }) {
|
|
993
|
+
const { global: i, component: f } = u, p = nr(c, s), P = [
|
|
993
994
|
...f.onAfterRouteLeave,
|
|
994
|
-
...
|
|
995
|
+
...p.onAfterRouteLeave,
|
|
995
996
|
...i.onAfterRouteLeave,
|
|
996
997
|
...f.onAfterRouteUpdate,
|
|
997
|
-
...
|
|
998
|
+
...p.onAfterRouteUpdate,
|
|
998
999
|
...i.onAfterRouteUpdate,
|
|
999
1000
|
...f.onAfterRouteEnter,
|
|
1000
|
-
...
|
|
1001
|
+
...p.onAfterRouteEnter,
|
|
1001
1002
|
...i.onAfterRouteEnter
|
|
1002
1003
|
];
|
|
1003
1004
|
try {
|
|
1004
|
-
const
|
|
1005
|
-
from:
|
|
1005
|
+
const h = P.map((m) => m(c, {
|
|
1006
|
+
from: s,
|
|
1006
1007
|
reject: e,
|
|
1007
1008
|
push: t,
|
|
1008
1009
|
replace: n
|
|
1009
1010
|
}));
|
|
1010
|
-
await Promise.all(
|
|
1011
|
-
} catch (
|
|
1012
|
-
if (
|
|
1013
|
-
return
|
|
1014
|
-
throw
|
|
1011
|
+
await Promise.all(h);
|
|
1012
|
+
} catch (h) {
|
|
1013
|
+
if (h instanceof te || h instanceof ke)
|
|
1014
|
+
return h.response;
|
|
1015
|
+
throw h;
|
|
1015
1016
|
}
|
|
1016
1017
|
return {
|
|
1017
1018
|
status: "SUCCESS"
|
|
@@ -1022,74 +1023,74 @@ function nr() {
|
|
|
1022
1023
|
runAfterRouteHooks: a
|
|
1023
1024
|
};
|
|
1024
1025
|
}
|
|
1025
|
-
const
|
|
1026
|
+
const Me = (e, t, n) => {
|
|
1026
1027
|
var a;
|
|
1027
1028
|
const r = e.matches, o = (t == null ? void 0 : t.matches) ?? [];
|
|
1028
1029
|
return r.length < n || r[n].id !== ((a = o[n]) == null ? void 0 : a.id);
|
|
1029
|
-
},
|
|
1030
|
+
}, Te = (e, t, n) => {
|
|
1030
1031
|
var a;
|
|
1031
1032
|
const r = e.matches, o = (t == null ? void 0 : t.matches) ?? [];
|
|
1032
1033
|
return r.length < n || r[n].id !== ((a = o[n]) == null ? void 0 : a.id);
|
|
1033
|
-
},
|
|
1034
|
+
}, Ie = (e, t, n) => {
|
|
1034
1035
|
var r;
|
|
1035
1036
|
return e.matches[n].id === ((r = t == null ? void 0 : t.matches[n]) == null ? void 0 : r.id);
|
|
1036
1037
|
};
|
|
1037
|
-
function
|
|
1038
|
+
function st(e) {
|
|
1038
1039
|
switch (e) {
|
|
1039
1040
|
case "onBeforeRouteEnter":
|
|
1040
1041
|
case "onAfterRouteEnter":
|
|
1041
|
-
return
|
|
1042
|
+
return Me;
|
|
1042
1043
|
case "onBeforeRouteUpdate":
|
|
1043
1044
|
case "onAfterRouteUpdate":
|
|
1044
|
-
return
|
|
1045
|
+
return Ie;
|
|
1045
1046
|
case "onBeforeRouteLeave":
|
|
1046
1047
|
case "onAfterRouteLeave":
|
|
1047
|
-
return
|
|
1048
|
+
return Te;
|
|
1048
1049
|
default:
|
|
1049
1050
|
throw new Error(`Switch is not exhaustive for lifecycle: ${e}`);
|
|
1050
1051
|
}
|
|
1051
1052
|
}
|
|
1052
|
-
function
|
|
1053
|
+
function or() {
|
|
1053
1054
|
const e = {
|
|
1054
|
-
global: new
|
|
1055
|
-
component: new
|
|
1055
|
+
global: new Se(),
|
|
1056
|
+
component: new Se()
|
|
1056
1057
|
};
|
|
1057
|
-
function t({ lifecycle: r, timing: o, depth: a, hook:
|
|
1058
|
-
const
|
|
1059
|
-
if (
|
|
1060
|
-
return
|
|
1058
|
+
function t({ lifecycle: r, timing: o, depth: a, hook: c }) {
|
|
1059
|
+
const s = st(r), u = e[o][r], i = (f, p) => {
|
|
1060
|
+
if (s(f, p.from, a))
|
|
1061
|
+
return c(f, p);
|
|
1061
1062
|
};
|
|
1062
1063
|
return u.add(i), () => u.delete(i);
|
|
1063
1064
|
}
|
|
1064
|
-
function n({ lifecycle: r, timing: o, depth: a, hook:
|
|
1065
|
-
const
|
|
1066
|
-
if (
|
|
1067
|
-
return
|
|
1065
|
+
function n({ lifecycle: r, timing: o, depth: a, hook: c }) {
|
|
1066
|
+
const s = st(r), u = e[o][r], i = (f, p) => {
|
|
1067
|
+
if (s(f, p.from, a))
|
|
1068
|
+
return c(f, p);
|
|
1068
1069
|
};
|
|
1069
1070
|
return u.add(i), () => u.delete(i);
|
|
1070
1071
|
}
|
|
1071
1072
|
return { ...e, addBeforeRouteHook: t, addAfterRouteHook: n };
|
|
1072
1073
|
}
|
|
1073
|
-
const
|
|
1074
|
-
function
|
|
1075
|
-
const e =
|
|
1074
|
+
const jt = Symbol();
|
|
1075
|
+
function ar() {
|
|
1076
|
+
const e = or();
|
|
1076
1077
|
return {
|
|
1077
|
-
onBeforeRouteEnter: (
|
|
1078
|
-
onBeforeRouteUpdate: (
|
|
1079
|
-
onBeforeRouteLeave: (
|
|
1080
|
-
onAfterRouteEnter: (
|
|
1081
|
-
onAfterRouteUpdate: (
|
|
1082
|
-
onAfterRouteLeave: (
|
|
1078
|
+
onBeforeRouteEnter: (s) => e.addBeforeRouteHook({ lifecycle: "onBeforeRouteEnter", hook: s, timing: "global", depth: 0 }),
|
|
1079
|
+
onBeforeRouteUpdate: (s) => e.addBeforeRouteHook({ lifecycle: "onBeforeRouteUpdate", hook: s, timing: "global", depth: 0 }),
|
|
1080
|
+
onBeforeRouteLeave: (s) => e.addBeforeRouteHook({ lifecycle: "onBeforeRouteLeave", hook: s, timing: "global", depth: 0 }),
|
|
1081
|
+
onAfterRouteEnter: (s) => e.addAfterRouteHook({ lifecycle: "onAfterRouteEnter", hook: s, timing: "global", depth: 0 }),
|
|
1082
|
+
onAfterRouteUpdate: (s) => e.addAfterRouteHook({ lifecycle: "onAfterRouteUpdate", hook: s, timing: "global", depth: 0 }),
|
|
1083
|
+
onAfterRouteLeave: (s) => e.addAfterRouteHook({ lifecycle: "onAfterRouteLeave", hook: s, timing: "global", depth: 0 }),
|
|
1083
1084
|
hooks: e
|
|
1084
1085
|
};
|
|
1085
1086
|
}
|
|
1086
|
-
function
|
|
1087
|
-
return
|
|
1087
|
+
function sr(e) {
|
|
1088
|
+
return se(() => () => Z("h1", e), {
|
|
1088
1089
|
name: e,
|
|
1089
1090
|
props: []
|
|
1090
1091
|
});
|
|
1091
1092
|
}
|
|
1092
|
-
function
|
|
1093
|
+
function Fe(e) {
|
|
1093
1094
|
const t = new URLSearchParams(e);
|
|
1094
1095
|
return {
|
|
1095
1096
|
get: (...n) => t.get(...n),
|
|
@@ -1113,348 +1114,285 @@ function jt(e) {
|
|
|
1113
1114
|
has: (...n) => t.has(...n)
|
|
1114
1115
|
};
|
|
1115
1116
|
}
|
|
1116
|
-
function
|
|
1117
|
+
function $t() {
|
|
1117
1118
|
let e = 0;
|
|
1118
1119
|
return () => (++e).toString();
|
|
1119
1120
|
}
|
|
1120
|
-
const Je =
|
|
1121
|
-
function
|
|
1121
|
+
const Je = $t();
|
|
1122
|
+
function cr({
|
|
1122
1123
|
rejections: e
|
|
1123
1124
|
}) {
|
|
1124
1125
|
const t = (a) => {
|
|
1125
|
-
const
|
|
1126
|
+
const c = {
|
|
1126
1127
|
...e
|
|
1127
1128
|
};
|
|
1128
|
-
return
|
|
1129
|
+
return ve(c[a] ?? sr(a));
|
|
1129
1130
|
}, n = (a) => {
|
|
1130
|
-
const
|
|
1131
|
+
const c = ve(t(a)), s = {
|
|
1131
1132
|
id: Je(),
|
|
1132
|
-
component:
|
|
1133
|
+
component: c,
|
|
1133
1134
|
meta: {},
|
|
1134
1135
|
state: {}
|
|
1135
1136
|
};
|
|
1136
1137
|
return {
|
|
1137
|
-
id:
|
|
1138
|
-
matched:
|
|
1139
|
-
matches: [
|
|
1138
|
+
id: s.id,
|
|
1139
|
+
matched: s,
|
|
1140
|
+
matches: [s],
|
|
1140
1141
|
name: a,
|
|
1141
|
-
query:
|
|
1142
|
+
query: Fe(""),
|
|
1142
1143
|
params: {},
|
|
1143
1144
|
state: {},
|
|
1144
|
-
|
|
1145
|
+
href: "/",
|
|
1146
|
+
[Nt]: !0
|
|
1145
1147
|
};
|
|
1146
1148
|
}, r = (a) => {
|
|
1147
1149
|
if (!a) {
|
|
1148
1150
|
o.value = null;
|
|
1149
1151
|
return;
|
|
1150
1152
|
}
|
|
1151
|
-
const
|
|
1152
|
-
o.value = { type: a, component:
|
|
1153
|
-
}, o =
|
|
1153
|
+
const c = t(a);
|
|
1154
|
+
o.value = { type: a, component: c };
|
|
1155
|
+
}, o = Oe(null);
|
|
1154
1156
|
return {
|
|
1155
1157
|
setRejection: r,
|
|
1156
1158
|
rejection: o,
|
|
1157
1159
|
getRejectionRoute: n
|
|
1158
1160
|
};
|
|
1159
1161
|
}
|
|
1160
|
-
class
|
|
1161
|
-
constructor(
|
|
1162
|
-
super(
|
|
1162
|
+
class ur extends Error {
|
|
1163
|
+
constructor() {
|
|
1164
|
+
super("initialUrl must be set if window.location is unavailable");
|
|
1163
1165
|
}
|
|
1164
1166
|
}
|
|
1167
|
+
function ir(e) {
|
|
1168
|
+
if (e)
|
|
1169
|
+
return e;
|
|
1170
|
+
if (De())
|
|
1171
|
+
return window.location.toString();
|
|
1172
|
+
throw new ur();
|
|
1173
|
+
}
|
|
1165
1174
|
function Qe(e) {
|
|
1166
1175
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
1167
1176
|
}
|
|
1168
|
-
function
|
|
1177
|
+
function fr(e, t) {
|
|
1169
1178
|
const n = Array.from(e.matchAll(t));
|
|
1170
1179
|
if (n.length === 0)
|
|
1171
1180
|
return [e];
|
|
1172
1181
|
let r = 0;
|
|
1173
|
-
const o = n.reduce((
|
|
1174
|
-
const u = Qe(e.slice(r,
|
|
1175
|
-
u.length &&
|
|
1176
|
-
const [i] =
|
|
1177
|
-
return
|
|
1182
|
+
const o = n.reduce((c, s) => {
|
|
1183
|
+
const u = Qe(e.slice(r, s.index));
|
|
1184
|
+
u.length && c.push(u);
|
|
1185
|
+
const [i] = s;
|
|
1186
|
+
return c.push(i), r = s.index + i.length, c;
|
|
1178
1187
|
}, []), a = e.slice(r);
|
|
1179
1188
|
return a && o.push(a), o;
|
|
1180
1189
|
}
|
|
1181
|
-
function
|
|
1182
|
-
const t =
|
|
1190
|
+
function lr(e) {
|
|
1191
|
+
const t = Ot(e.path.value);
|
|
1183
1192
|
return new RegExp(`^${t}$`, "i");
|
|
1184
1193
|
}
|
|
1185
|
-
function
|
|
1194
|
+
function hr(e) {
|
|
1186
1195
|
const t = new URLSearchParams(e.query.value);
|
|
1187
|
-
return Array.from(t.entries()).filter(([, n]) => !
|
|
1188
|
-
const o =
|
|
1196
|
+
return Array.from(t.entries()).filter(([, n]) => !He(n)).map(([n, r]) => {
|
|
1197
|
+
const o = Ot(r);
|
|
1189
1198
|
return new RegExp(`${Qe(n)}=${o}(&|$)`, "i");
|
|
1190
1199
|
});
|
|
1191
1200
|
}
|
|
1192
|
-
function $t(e) {
|
|
1193
|
-
return ur(e, new RegExp(lr, "g")).map((t) => t.startsWith(W) ? Ot(t) : Qe(t)).join("");
|
|
1194
|
-
}
|
|
1195
1201
|
function Ot(e) {
|
|
1202
|
+
return fr(e, new RegExp(pr, "g")).map((t) => t.startsWith(F) ? qt(t) : Qe(t)).join("");
|
|
1203
|
+
}
|
|
1204
|
+
function qt(e) {
|
|
1196
1205
|
return [
|
|
1197
|
-
|
|
1198
|
-
|
|
1206
|
+
dr,
|
|
1207
|
+
mr
|
|
1199
1208
|
].reduce((t, n) => n(t), e);
|
|
1200
1209
|
}
|
|
1201
|
-
const
|
|
1202
|
-
function
|
|
1210
|
+
const pr = `\\${F}\\??([\\w-_]+)\\${K}`, Ge = `\\${F}\\?([\\w-_]+)\\${K}`, _t = `\\${F}([\\w-_]+)\\${K}`;
|
|
1211
|
+
function dr(e) {
|
|
1203
1212
|
return e.replace(new RegExp(Ge, "g"), ".*");
|
|
1204
1213
|
}
|
|
1205
|
-
function
|
|
1214
|
+
function He(e) {
|
|
1206
1215
|
return new RegExp(Ge, "g").test(e);
|
|
1207
1216
|
}
|
|
1208
|
-
function
|
|
1209
|
-
return e.replace(new RegExp(
|
|
1217
|
+
function mr(e) {
|
|
1218
|
+
return e.replace(new RegExp(_t, "g"), ".+");
|
|
1210
1219
|
}
|
|
1211
|
-
function
|
|
1212
|
-
const [t] =
|
|
1220
|
+
function Be(e) {
|
|
1221
|
+
const [t] = Ae(e, new RegExp(Ge, "g")), [n] = Ae(e, new RegExp(_t, "g"));
|
|
1213
1222
|
return t ?? n;
|
|
1214
1223
|
}
|
|
1215
|
-
function
|
|
1216
|
-
return Array.from(e.matchAll(t)).flatMap(([, ...r]) => r.map((o) =>
|
|
1224
|
+
function Ae(e, t) {
|
|
1225
|
+
return Array.from(e.matchAll(t)).flatMap(([, ...r]) => r.map((o) => me(o) ? o : ""));
|
|
1217
1226
|
}
|
|
1218
|
-
function
|
|
1219
|
-
const r =
|
|
1227
|
+
function Wt(e, t, n) {
|
|
1228
|
+
const r = Mt(t, n), [o] = Ae(e, r);
|
|
1220
1229
|
return o;
|
|
1221
1230
|
}
|
|
1222
|
-
function
|
|
1231
|
+
function Dt(e, t) {
|
|
1223
1232
|
if (!t)
|
|
1224
1233
|
return e;
|
|
1225
|
-
const { name: n, param: r, value: o } = t, a =
|
|
1226
|
-
return
|
|
1234
|
+
const { name: n, param: r, value: o } = t, a = Mt(e, n);
|
|
1235
|
+
return Ae(e, a).reduce((s, u) => u === void 0 ? s : s.replace(u, () => le(o, r, n.startsWith("?"))), e);
|
|
1227
1236
|
}
|
|
1228
|
-
function
|
|
1237
|
+
function Mt(e, t) {
|
|
1229
1238
|
const n = [
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1239
|
+
yr,
|
|
1240
|
+
gr,
|
|
1241
|
+
qt
|
|
1233
1242
|
].reduce((r, o) => o(r, t), e);
|
|
1234
1243
|
return new RegExp(n, "g");
|
|
1235
1244
|
}
|
|
1236
|
-
function
|
|
1245
|
+
function yr(e, t) {
|
|
1237
1246
|
if (!t.startsWith("?"))
|
|
1238
1247
|
return e;
|
|
1239
|
-
const n = new RegExp(`\\${
|
|
1248
|
+
const n = new RegExp(`\\${F}\\${t}\\${K}`, "g");
|
|
1240
1249
|
return e.replace(n, "(.*)");
|
|
1241
1250
|
}
|
|
1242
|
-
function
|
|
1251
|
+
function gr(e, t) {
|
|
1243
1252
|
if (t.startsWith("?"))
|
|
1244
1253
|
return e;
|
|
1245
|
-
const n = new RegExp(`\\${
|
|
1254
|
+
const n = new RegExp(`\\${F}${t}\\${K}`, "g");
|
|
1246
1255
|
return e.replace(n, "(.+)");
|
|
1247
1256
|
}
|
|
1248
|
-
|
|
1249
|
-
const s = new URL("https://localhost");
|
|
1250
|
-
e && (s.protocol = e), t && (s.host = t), n && (s.pathname = n), o ? s.search = o.toString() : r && (s.search = r), a && (s.hash = a);
|
|
1251
|
-
const c = s.toString().replace(/^https:\/\/localhost\/*/, "/");
|
|
1252
|
-
return tr(c);
|
|
1253
|
-
}
|
|
1254
|
-
function gr(e, t) {
|
|
1255
|
-
const n = new URLSearchParams(e), r = new URLSearchParams(t);
|
|
1256
|
-
for (const [o, a] of r.entries())
|
|
1257
|
-
n.append(o, a);
|
|
1258
|
-
return n;
|
|
1259
|
-
}
|
|
1260
|
-
function vr(e, t = {}) {
|
|
1261
|
-
const { params: n = {}, query: r } = t, o = wr(e.query, n), a = gr(o, r), s = Rr(e.path, n), c = Re(e.hash.value ?? t.hash).value, u = yr(e.host, n), { protocol: i, host: f } = T(u);
|
|
1262
|
-
return Dt({ protocol: i, host: f, pathname: s, searchParams: a, hash: c });
|
|
1263
|
-
}
|
|
1264
|
-
function yr(e, t) {
|
|
1265
|
-
const n = e.value && !e.value.startsWith("http") ? `https://${e.value}` : e.value;
|
|
1266
|
-
return Object.entries(e.params).reduce((r, [o, a]) => {
|
|
1267
|
-
const s = Le(`${W}${o}${G}`);
|
|
1268
|
-
return s ? Mt(r, { name: o, param: a, value: t[s] }) : r;
|
|
1269
|
-
}, n);
|
|
1270
|
-
}
|
|
1271
|
-
function Rr(e, t) {
|
|
1272
|
-
return Object.entries(e.params).reduce((n, [r, o]) => {
|
|
1273
|
-
const a = Le(`${W}${r}${G}`);
|
|
1274
|
-
return a ? Mt(n, { name: r, param: o, value: t[a] }) : n;
|
|
1275
|
-
}, e.value);
|
|
1276
|
-
}
|
|
1277
|
-
function wr(e, t) {
|
|
1278
|
-
const n = new URLSearchParams(e.value);
|
|
1279
|
-
if (!e.value)
|
|
1280
|
-
return n;
|
|
1281
|
-
for (const [r, o] of Array.from(n.entries())) {
|
|
1282
|
-
const a = Le(o);
|
|
1283
|
-
if (!a)
|
|
1284
|
-
continue;
|
|
1285
|
-
const c = ie(t[a], e.params[a], Ve(o)), u = t[a] === void 0 && c === "";
|
|
1286
|
-
Ve(o) && u ? n.delete(r, o) : n.set(r, c);
|
|
1287
|
-
}
|
|
1288
|
-
return n;
|
|
1289
|
-
}
|
|
1290
|
-
function Pr(e) {
|
|
1291
|
-
return (t, n, r) => {
|
|
1292
|
-
if (M(t)) {
|
|
1293
|
-
const u = n ?? {}, { searchParams: i, ...f } = T(t);
|
|
1294
|
-
return Object.entries(u.query ?? {}).forEach(([l, m]) => {
|
|
1295
|
-
i.append(l, m);
|
|
1296
|
-
}), Dt({ ...f, searchParams: i });
|
|
1297
|
-
}
|
|
1298
|
-
const o = n ?? {}, a = r ?? {}, s = e.find((u) => u.name === t);
|
|
1299
|
-
if (!s)
|
|
1300
|
-
throw new cr(String(t));
|
|
1301
|
-
return vr(s, {
|
|
1302
|
-
params: o,
|
|
1303
|
-
query: a.query,
|
|
1304
|
-
hash: a.hash
|
|
1305
|
-
});
|
|
1306
|
-
};
|
|
1307
|
-
}
|
|
1308
|
-
class Er extends Error {
|
|
1309
|
-
constructor() {
|
|
1310
|
-
super("initialUrl must be set if window.location is unavailable");
|
|
1311
|
-
}
|
|
1312
|
-
}
|
|
1313
|
-
function br(e) {
|
|
1314
|
-
if (e)
|
|
1315
|
-
return e;
|
|
1316
|
-
if (Te())
|
|
1317
|
-
return window.location.toString();
|
|
1318
|
-
throw new Er();
|
|
1319
|
-
}
|
|
1320
|
-
const Sr = (e, t) => {
|
|
1257
|
+
const vr = (e, t) => {
|
|
1321
1258
|
try {
|
|
1322
|
-
|
|
1259
|
+
Ke(e, t);
|
|
1323
1260
|
} catch {
|
|
1324
1261
|
return !1;
|
|
1325
1262
|
}
|
|
1326
1263
|
return !0;
|
|
1327
|
-
},
|
|
1328
|
-
const { pathname: n, search: r } =
|
|
1264
|
+
}, Ke = (e, t) => {
|
|
1265
|
+
const { pathname: n, search: r } = D(t);
|
|
1329
1266
|
return {
|
|
1330
|
-
...
|
|
1331
|
-
...
|
|
1267
|
+
...Rr(e.path, n),
|
|
1268
|
+
...wr(e.query, r)
|
|
1332
1269
|
};
|
|
1333
1270
|
};
|
|
1334
|
-
function
|
|
1271
|
+
function Rr(e, t) {
|
|
1335
1272
|
const n = {}, r = decodeURIComponent(t);
|
|
1336
1273
|
for (const [o, a] of Object.entries(e.params)) {
|
|
1337
|
-
const
|
|
1338
|
-
n[
|
|
1274
|
+
const c = o.startsWith("?"), s = c ? o.slice(1) : o, u = Wt(r, e.value, o), i = fe(u, a, c);
|
|
1275
|
+
n[s] = i;
|
|
1339
1276
|
}
|
|
1340
1277
|
return n;
|
|
1341
1278
|
}
|
|
1342
|
-
function
|
|
1279
|
+
function wr(e, t) {
|
|
1343
1280
|
const n = {}, r = new URLSearchParams(t);
|
|
1344
1281
|
for (const [o, a] of Object.entries(e.params)) {
|
|
1345
|
-
const
|
|
1346
|
-
n[
|
|
1282
|
+
const c = o.startsWith("?"), s = c ? o.slice(1) : o, u = r.get(s) ?? void 0, i = fe(u, a, c);
|
|
1283
|
+
n[s] = i;
|
|
1347
1284
|
}
|
|
1348
1285
|
return n;
|
|
1349
1286
|
}
|
|
1350
|
-
const
|
|
1351
|
-
const { pathname: n } =
|
|
1352
|
-
return
|
|
1353
|
-
},
|
|
1354
|
-
const { search: n } =
|
|
1355
|
-
return
|
|
1356
|
-
},
|
|
1357
|
-
const { hash: n } =
|
|
1287
|
+
const Pr = (e) => "name" in e.matched && !!e.matched.name, Er = (e, t) => {
|
|
1288
|
+
const { pathname: n } = D(t);
|
|
1289
|
+
return lr(e).test(n);
|
|
1290
|
+
}, br = (e, t) => {
|
|
1291
|
+
const { search: n } = D(t);
|
|
1292
|
+
return hr(e).every((o) => o.test(n));
|
|
1293
|
+
}, je = (e, t) => {
|
|
1294
|
+
const { hash: n } = D(t), { value: r } = e.hash;
|
|
1358
1295
|
return r === void 0 || `#${r.toLowerCase()}` === n.toLowerCase();
|
|
1359
1296
|
};
|
|
1360
|
-
function
|
|
1361
|
-
const { searchParams: t, pathname: n } =
|
|
1362
|
-
return (a,
|
|
1363
|
-
const
|
|
1364
|
-
return a.depth >
|
|
1297
|
+
function Sr(e) {
|
|
1298
|
+
const { searchParams: t, pathname: n } = D(e), r = -1, o = 1;
|
|
1299
|
+
return (a, c) => {
|
|
1300
|
+
const s = ut(a, t), u = ct(a, n), i = ut(c, t), f = ct(c, n);
|
|
1301
|
+
return a.depth > c.depth ? r : a.depth < c.depth ? o : s + u > i + f ? r : s + u < i + f ? o : je(a, e) ? r : je(c, e) ? o : 0;
|
|
1365
1302
|
};
|
|
1366
1303
|
}
|
|
1367
|
-
function
|
|
1368
|
-
const n = Object.keys(e.path.params).filter((o) => o.startsWith("?")).map((o) => o), r = n.filter((o) =>
|
|
1304
|
+
function ct(e, t) {
|
|
1305
|
+
const n = Object.keys(e.path.params).filter((o) => o.startsWith("?")).map((o) => o), r = n.filter((o) => Wt(t, e.path.value, o) === void 0);
|
|
1369
1306
|
return n.length - r.length;
|
|
1370
1307
|
}
|
|
1371
|
-
function
|
|
1308
|
+
function ut(e, t) {
|
|
1372
1309
|
const n = new URLSearchParams(e.query.value), r = Array.from(n.keys()), o = r.filter((a) => !t.has(a));
|
|
1373
1310
|
return r.length - o.length;
|
|
1374
1311
|
}
|
|
1375
|
-
function
|
|
1312
|
+
function Tt(e) {
|
|
1376
1313
|
return !!e && typeof e == "object";
|
|
1377
1314
|
}
|
|
1378
|
-
const
|
|
1379
|
-
function
|
|
1380
|
-
if (
|
|
1315
|
+
const xe = !0;
|
|
1316
|
+
function kr(e, t, n) {
|
|
1317
|
+
if (Tt(e) && t in e) {
|
|
1381
1318
|
const r = e[t];
|
|
1382
1319
|
if (typeof r == "string")
|
|
1383
|
-
return
|
|
1320
|
+
return fe(r, n, xe);
|
|
1384
1321
|
}
|
|
1385
|
-
return
|
|
1322
|
+
return fe(void 0, n, xe);
|
|
1386
1323
|
}
|
|
1387
|
-
function
|
|
1324
|
+
function It(e, t) {
|
|
1388
1325
|
const n = {};
|
|
1389
1326
|
for (const [r, o] of Object.entries(e)) {
|
|
1390
|
-
const a =
|
|
1327
|
+
const a = kr(t, r, o);
|
|
1391
1328
|
n[r] = a;
|
|
1392
1329
|
}
|
|
1393
1330
|
return n;
|
|
1394
1331
|
}
|
|
1395
|
-
function
|
|
1396
|
-
if (
|
|
1332
|
+
function Ar(e, t, n) {
|
|
1333
|
+
if (Tt(e) && t in e) {
|
|
1397
1334
|
const r = e[t];
|
|
1398
|
-
return
|
|
1335
|
+
return le(r, n, xe);
|
|
1399
1336
|
}
|
|
1400
|
-
return
|
|
1337
|
+
return le(void 0, n, xe);
|
|
1401
1338
|
}
|
|
1402
|
-
const
|
|
1339
|
+
const it = (e, t) => {
|
|
1403
1340
|
const n = {};
|
|
1404
1341
|
for (const [r, o] of Object.entries(e)) {
|
|
1405
|
-
const a =
|
|
1342
|
+
const a = Ar(t, r, o);
|
|
1406
1343
|
n[r] = a;
|
|
1407
1344
|
}
|
|
1408
1345
|
return n;
|
|
1409
|
-
},
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1346
|
+
}, xr = [
|
|
1347
|
+
Pr,
|
|
1348
|
+
Er,
|
|
1349
|
+
br,
|
|
1350
|
+
je,
|
|
1351
|
+
vr
|
|
1415
1352
|
];
|
|
1416
|
-
function
|
|
1417
|
-
const r =
|
|
1353
|
+
function ft(e, t, n) {
|
|
1354
|
+
const r = Sr(t), o = e.filter((u) => xr.every((i) => i(u, t))).sort(r);
|
|
1418
1355
|
if (o.length === 0)
|
|
1419
1356
|
return;
|
|
1420
|
-
const [a] = o, { search:
|
|
1357
|
+
const [a] = o, { search: c, hash: s } = D(t);
|
|
1421
1358
|
return {
|
|
1422
1359
|
id: a.id,
|
|
1423
1360
|
matched: a.matched,
|
|
1424
1361
|
matches: a.matches,
|
|
1425
1362
|
name: a.name,
|
|
1426
|
-
query:
|
|
1427
|
-
params:
|
|
1428
|
-
state:
|
|
1429
|
-
hash:
|
|
1363
|
+
query: Fe(c),
|
|
1364
|
+
params: Ke(a, t),
|
|
1365
|
+
state: It(a.state, n),
|
|
1366
|
+
hash: s,
|
|
1367
|
+
href: wt(t)
|
|
1430
1368
|
};
|
|
1431
1369
|
}
|
|
1432
|
-
function
|
|
1433
|
-
const n = new RegExp(`\\${
|
|
1434
|
-
return Array.from(e.matchAll(n)).reduce((o, [a,
|
|
1435
|
-
const
|
|
1436
|
-
if (!
|
|
1370
|
+
function ze(e, t) {
|
|
1371
|
+
const n = new RegExp(`\\${F}(\\??[\\w-_]+)\\${K}`, "g");
|
|
1372
|
+
return Array.from(e.matchAll(n)).reduce((o, [a, c]) => {
|
|
1373
|
+
const s = Be(a);
|
|
1374
|
+
if (!s)
|
|
1437
1375
|
return o;
|
|
1438
|
-
const u =
|
|
1439
|
-
return
|
|
1376
|
+
const u = Dn(t, s);
|
|
1377
|
+
return ce([s], o), o[c] = u, o;
|
|
1440
1378
|
}, {});
|
|
1441
1379
|
}
|
|
1442
|
-
function
|
|
1380
|
+
function $e(e, t) {
|
|
1443
1381
|
return {
|
|
1444
1382
|
value: e,
|
|
1445
|
-
params:
|
|
1383
|
+
params: ze(e, t)
|
|
1446
1384
|
};
|
|
1447
1385
|
}
|
|
1448
|
-
function
|
|
1449
|
-
return
|
|
1386
|
+
function Lr(e, t) {
|
|
1387
|
+
return me(t) ? e.map((n) => {
|
|
1450
1388
|
const r = `${t}${n.path.value}`;
|
|
1451
1389
|
return {
|
|
1452
1390
|
...n,
|
|
1453
|
-
path:
|
|
1391
|
+
path: $e(r, n.path.params)
|
|
1454
1392
|
};
|
|
1455
1393
|
}) : e;
|
|
1456
1394
|
}
|
|
1457
|
-
class
|
|
1395
|
+
class Ur extends Error {
|
|
1458
1396
|
/**
|
|
1459
1397
|
* Constructs a new DuplicateNamesError instance with a message indicating the problematic name.
|
|
1460
1398
|
* @param name - The name of the name that was duplicated.
|
|
@@ -1463,23 +1401,23 @@ class $r extends Error {
|
|
|
1463
1401
|
super(`Invalid Name "${t}": Router does not support multiple routes with the same name. All name names must be unique.`);
|
|
1464
1402
|
}
|
|
1465
1403
|
}
|
|
1466
|
-
function
|
|
1404
|
+
function Cr(e) {
|
|
1467
1405
|
const t = e.map(({ name: n }) => n);
|
|
1468
1406
|
for (const n of t)
|
|
1469
|
-
if (
|
|
1470
|
-
throw new
|
|
1471
|
-
}
|
|
1472
|
-
function
|
|
1473
|
-
const e = Ue(/* @__PURE__ */ new Map()), t =
|
|
1474
|
-
e.set(
|
|
1475
|
-
}, r = (
|
|
1476
|
-
e.delete(
|
|
1407
|
+
if (Et(t, n) > 1)
|
|
1408
|
+
throw new Ur(n);
|
|
1409
|
+
}
|
|
1410
|
+
function Br() {
|
|
1411
|
+
const e = Ue(/* @__PURE__ */ new Map()), t = De() ? c() : null, n = (s) => {
|
|
1412
|
+
e.set(s, !1), t == null || t.observe(s);
|
|
1413
|
+
}, r = (s) => {
|
|
1414
|
+
e.delete(s), t == null || t.unobserve(s);
|
|
1477
1415
|
}, o = () => {
|
|
1478
1416
|
t == null || t.disconnect();
|
|
1479
|
-
}, a = (
|
|
1480
|
-
function
|
|
1481
|
-
return new IntersectionObserver((
|
|
1482
|
-
|
|
1417
|
+
}, a = (s) => e.get(s) ?? !1;
|
|
1418
|
+
function c() {
|
|
1419
|
+
return new IntersectionObserver((s) => {
|
|
1420
|
+
s.forEach((u) => {
|
|
1483
1421
|
e.set(u.target, u.isIntersecting);
|
|
1484
1422
|
});
|
|
1485
1423
|
});
|
|
@@ -1492,184 +1430,261 @@ function qr() {
|
|
|
1492
1430
|
};
|
|
1493
1431
|
}
|
|
1494
1432
|
const Ft = Symbol("visibilityObserver");
|
|
1495
|
-
function
|
|
1496
|
-
const
|
|
1497
|
-
if (!
|
|
1498
|
-
throw new
|
|
1499
|
-
return e
|
|
1433
|
+
function Nr(e) {
|
|
1434
|
+
const t = ae(Ft);
|
|
1435
|
+
if (!t)
|
|
1436
|
+
throw new pe();
|
|
1437
|
+
return Re(e, (r, o) => {
|
|
1438
|
+
r && t.observe(r), o && t.unobserve(o);
|
|
1439
|
+
}, { immediate: !0 }), {
|
|
1440
|
+
isElementVisible: N(() => e.value ? t.isElementVisible(e.value) : !1)
|
|
1441
|
+
};
|
|
1442
|
+
}
|
|
1443
|
+
class lt extends Error {
|
|
1444
|
+
constructor(t) {
|
|
1445
|
+
super(`Route not found: "${t}"`);
|
|
1446
|
+
}
|
|
1447
|
+
}
|
|
1448
|
+
function Jt({ protocol: e, host: t, pathname: n, search: r, searchParams: o, hash: a }) {
|
|
1449
|
+
const c = new URL("https://localhost");
|
|
1450
|
+
e && (c.protocol = e), t && (c.host = t), n && (c.pathname = n), o ? c.search = o.toString() : r && (c.search = r), a && (c.hash = a);
|
|
1451
|
+
const s = c.toString().replace(/^https:\/\/localhost\/*/, "/");
|
|
1452
|
+
return wt(s);
|
|
1453
|
+
}
|
|
1454
|
+
function Qt(e, t) {
|
|
1455
|
+
const n = new URLSearchParams(e), r = new URLSearchParams(t);
|
|
1456
|
+
for (const [o, a] of r.entries())
|
|
1457
|
+
n.append(o, a);
|
|
1458
|
+
return n;
|
|
1459
|
+
}
|
|
1460
|
+
function Ne(e, t) {
|
|
1461
|
+
const { searchParams: n, ...r } = D(e);
|
|
1462
|
+
return Jt({ ...r, searchParams: Qt(n, t) });
|
|
1463
|
+
}
|
|
1464
|
+
function Vr(e, t = {}) {
|
|
1465
|
+
const { params: n = {}, query: r } = t, o = $r(e.query, n), a = Qt(o, r), c = jr(e.path, n), s = we(e.hash.value ?? t.hash).value, u = Hr(e.host, n), { protocol: i, host: f } = D(u);
|
|
1466
|
+
return Jt({ protocol: i, host: f, pathname: c, searchParams: a, hash: s });
|
|
1467
|
+
}
|
|
1468
|
+
function Hr(e, t) {
|
|
1469
|
+
const n = e.value && !e.value.startsWith("http") ? `https://${e.value}` : e.value;
|
|
1470
|
+
return Object.entries(e.params).reduce((r, [o, a]) => {
|
|
1471
|
+
const c = Be(`${F}${o}${K}`);
|
|
1472
|
+
return c ? Dt(r, { name: o, param: a, value: t[c] }) : r;
|
|
1473
|
+
}, n);
|
|
1500
1474
|
}
|
|
1501
|
-
function
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1475
|
+
function jr(e, t) {
|
|
1476
|
+
return Object.entries(e.params).reduce((n, [r, o]) => {
|
|
1477
|
+
const a = Be(`${F}${r}${K}`);
|
|
1478
|
+
return a ? Dt(n, { name: r, param: o, value: t[a] }) : n;
|
|
1479
|
+
}, e.value);
|
|
1480
|
+
}
|
|
1481
|
+
function $r(e, t) {
|
|
1482
|
+
const n = new URLSearchParams(e.value);
|
|
1483
|
+
if (!e.value)
|
|
1484
|
+
return n;
|
|
1485
|
+
for (const [r, o] of Array.from(n.entries())) {
|
|
1486
|
+
const a = Be(o);
|
|
1487
|
+
if (!a)
|
|
1488
|
+
continue;
|
|
1489
|
+
const s = le(t[a], e.params[a], He(o)), u = t[a] === void 0 && s === "";
|
|
1490
|
+
He(o) && u ? n.delete(r, o) : n.set(r, s);
|
|
1491
|
+
}
|
|
1492
|
+
return n;
|
|
1493
|
+
}
|
|
1494
|
+
function Or(e, t = {}, n = {}) {
|
|
1495
|
+
const r = Vr(e, {
|
|
1496
|
+
params: t,
|
|
1497
|
+
query: n.query,
|
|
1498
|
+
hash: n.hash
|
|
1499
|
+
}), { search: o, hash: a } = D(r);
|
|
1500
|
+
return {
|
|
1501
|
+
id: e.id,
|
|
1502
|
+
matched: e.matched,
|
|
1503
|
+
matches: e.matches,
|
|
1504
|
+
name: e.name,
|
|
1505
|
+
query: Fe(o),
|
|
1506
|
+
params: Ke(e, r),
|
|
1507
|
+
state: It(e.state, n.state),
|
|
1508
|
+
hash: a,
|
|
1509
|
+
href: r
|
|
1510
|
+
};
|
|
1511
|
+
}
|
|
1512
|
+
function co(e, t) {
|
|
1513
|
+
const n = Ln(e) ? e.flat() : e, r = Lr(n, t == null ? void 0 : t.base);
|
|
1514
|
+
Cr(r);
|
|
1515
|
+
const o = $t(), a = Fr(), c = Br(), s = Zn({
|
|
1505
1516
|
mode: t == null ? void 0 : t.historyMode,
|
|
1506
|
-
listener: ({ location:
|
|
1507
|
-
const
|
|
1508
|
-
|
|
1517
|
+
listener: ({ location: E }) => {
|
|
1518
|
+
const B = X(E);
|
|
1519
|
+
R(B, { state: E.state, replace: !0 });
|
|
1509
1520
|
}
|
|
1510
|
-
}), { runBeforeRouteHooks:
|
|
1511
|
-
hooks:
|
|
1512
|
-
onBeforeRouteEnter:
|
|
1513
|
-
onAfterRouteUpdate:
|
|
1514
|
-
onBeforeRouteLeave:
|
|
1515
|
-
onAfterRouteEnter:
|
|
1516
|
-
onBeforeRouteUpdate:
|
|
1517
|
-
onAfterRouteLeave:
|
|
1518
|
-
} =
|
|
1519
|
-
async function
|
|
1520
|
-
const
|
|
1521
|
-
if (
|
|
1522
|
-
|
|
1521
|
+
}), { runBeforeRouteHooks: u, runAfterRouteHooks: i } = rr(), {
|
|
1522
|
+
hooks: f,
|
|
1523
|
+
onBeforeRouteEnter: p,
|
|
1524
|
+
onAfterRouteUpdate: P,
|
|
1525
|
+
onBeforeRouteLeave: h,
|
|
1526
|
+
onAfterRouteEnter: m,
|
|
1527
|
+
onBeforeRouteUpdate: v,
|
|
1528
|
+
onAfterRouteLeave: w
|
|
1529
|
+
} = ar();
|
|
1530
|
+
async function R(E, B = {}) {
|
|
1531
|
+
const J = o();
|
|
1532
|
+
if (s.stopListening(), ye(E)) {
|
|
1533
|
+
s.update(E, B);
|
|
1523
1534
|
return;
|
|
1524
1535
|
}
|
|
1525
|
-
const V =
|
|
1526
|
-
switch (
|
|
1536
|
+
const V = ft(r, E, B.state) ?? l("NotFound"), Q = { ...S }, H = await u({ to: V, from: Q, hooks: f });
|
|
1537
|
+
switch (H.status) {
|
|
1527
1538
|
// On abort do nothing
|
|
1528
1539
|
case "ABORT":
|
|
1529
1540
|
return;
|
|
1530
1541
|
// On push update the history, and push new route, and return
|
|
1531
1542
|
case "PUSH":
|
|
1532
|
-
|
|
1543
|
+
s.update(E, B), await d(...H.to);
|
|
1533
1544
|
return;
|
|
1534
1545
|
// On reject update the history, the route, and set the rejection type
|
|
1535
1546
|
case "REJECT":
|
|
1536
|
-
|
|
1547
|
+
s.update(E, B), x(H.type);
|
|
1537
1548
|
break;
|
|
1538
1549
|
// On success update history, set the route, and clear the rejection
|
|
1539
1550
|
case "SUCCESS":
|
|
1540
|
-
|
|
1551
|
+
s.update(E, B), x(null);
|
|
1541
1552
|
break;
|
|
1542
1553
|
default:
|
|
1543
|
-
throw new Error(`Switch is not exhaustive for before hook response status: ${JSON.stringify(
|
|
1554
|
+
throw new Error(`Switch is not exhaustive for before hook response status: ${JSON.stringify(H)}`);
|
|
1544
1555
|
}
|
|
1545
|
-
const
|
|
1546
|
-
a.setProps(V).then((
|
|
1547
|
-
if (
|
|
1548
|
-
switch (
|
|
1556
|
+
const z = J;
|
|
1557
|
+
a.setProps(V).then((q) => {
|
|
1558
|
+
if (z === J)
|
|
1559
|
+
switch (q.status) {
|
|
1549
1560
|
case "SUCCESS":
|
|
1550
1561
|
break;
|
|
1551
1562
|
case "PUSH":
|
|
1552
|
-
d(
|
|
1563
|
+
d(...q.to);
|
|
1553
1564
|
break;
|
|
1554
1565
|
case "REJECT":
|
|
1555
|
-
|
|
1566
|
+
x(q.type);
|
|
1556
1567
|
break;
|
|
1557
1568
|
default:
|
|
1558
|
-
const
|
|
1559
|
-
throw new Error(`Switch is not exhaustive for prop store response status: ${JSON.stringify(
|
|
1569
|
+
const fn = q;
|
|
1570
|
+
throw new Error(`Switch is not exhaustive for prop store response status: ${JSON.stringify(fn)}`);
|
|
1560
1571
|
}
|
|
1561
|
-
}),
|
|
1562
|
-
const
|
|
1563
|
-
switch (
|
|
1572
|
+
}), U(V);
|
|
1573
|
+
const $ = await i({ to: V, from: Q, hooks: f });
|
|
1574
|
+
switch ($.status) {
|
|
1564
1575
|
case "PUSH":
|
|
1565
|
-
await d(
|
|
1576
|
+
await d(...$.to);
|
|
1566
1577
|
break;
|
|
1567
1578
|
case "REJECT":
|
|
1568
|
-
|
|
1579
|
+
x($.type);
|
|
1569
1580
|
break;
|
|
1570
1581
|
case "SUCCESS":
|
|
1571
1582
|
break;
|
|
1572
1583
|
default:
|
|
1573
|
-
const
|
|
1574
|
-
throw new Error(`Switch is not exhaustive for after hook response status: ${JSON.stringify(
|
|
1584
|
+
const q = $;
|
|
1585
|
+
throw new Error(`Switch is not exhaustive for after hook response status: ${JSON.stringify(q)}`);
|
|
1575
1586
|
}
|
|
1576
|
-
|
|
1587
|
+
s.startListening();
|
|
1577
1588
|
}
|
|
1578
|
-
const
|
|
1579
|
-
if (
|
|
1580
|
-
const
|
|
1581
|
-
return
|
|
1589
|
+
const A = (E, B, J) => {
|
|
1590
|
+
if (!I(E)) {
|
|
1591
|
+
const H = B ?? {}, z = J ?? {}, $ = r.find((q) => q.name === E);
|
|
1592
|
+
return $ ? Or($, H, z) : void 0;
|
|
1582
1593
|
}
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1594
|
+
if (ye(E))
|
|
1595
|
+
return;
|
|
1596
|
+
const V = { ...B }, Q = Ne(E, V.query);
|
|
1597
|
+
return ft(r, Q);
|
|
1598
|
+
}, d = (E, B, J) => {
|
|
1599
|
+
if (I(E)) {
|
|
1600
|
+
const $ = { ...B }, q = Ne(E, $.query);
|
|
1601
|
+
return R(q, $);
|
|
1589
1602
|
}
|
|
1590
|
-
const V = { ...
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1603
|
+
const V = { ...J }, Q = { ...B }, H = A(E, Q, V);
|
|
1604
|
+
if (!H)
|
|
1605
|
+
throw new lt(String(E));
|
|
1606
|
+
const z = it({ ...H.state }, V.state);
|
|
1607
|
+
return R(H.href, { ...V, state: z });
|
|
1608
|
+
}, b = (E, B, J) => {
|
|
1609
|
+
if (I(E)) {
|
|
1610
|
+
const $ = { ...B, replace: !0 }, q = Ne(E, $.query);
|
|
1611
|
+
return R(q, $);
|
|
1598
1612
|
}
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1613
|
+
const V = { ...J, replace: !0 }, Q = { ...B }, H = A(E, Q, V);
|
|
1614
|
+
if (!H)
|
|
1615
|
+
throw new lt(String(E));
|
|
1616
|
+
const z = it({ ...H.state }, V.state);
|
|
1617
|
+
return R(H.href, { ...V, state: z });
|
|
1618
|
+
}, L = (E) => {
|
|
1619
|
+
x(E);
|
|
1620
|
+
}, { setRejection: x, rejection: g, getRejectionRoute: l } = cr(t ?? {}), y = l("NotFound"), { currentRoute: S, routerRoute: k, updateRoute: U } = Kn(y, d);
|
|
1621
|
+
s.startListening();
|
|
1622
|
+
const C = ir(t == null ? void 0 : t.initialUrl), O = s.location.state, { host: W } = D(C), ye = Xn(W);
|
|
1604
1623
|
let et = !1;
|
|
1605
1624
|
async function tt() {
|
|
1606
|
-
et || (await
|
|
1625
|
+
et || (await R(C, { replace: !0, state: O }), et = !0);
|
|
1607
1626
|
}
|
|
1608
|
-
function
|
|
1609
|
-
|
|
1627
|
+
function un(E) {
|
|
1628
|
+
E.component("RouterView", no), E.component("RouterLink", Yr), E.provide(Ct, g), E.provide(jt, f), E.provide(nn, a), E.provide(Ft, c), E.provide(Pt, nt), tt();
|
|
1610
1629
|
}
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
const rt = {
|
|
1615
|
-
route: B,
|
|
1616
|
-
resolve: c,
|
|
1630
|
+
const nt = {
|
|
1631
|
+
route: k,
|
|
1632
|
+
resolve: A,
|
|
1617
1633
|
push: d,
|
|
1618
|
-
replace:
|
|
1619
|
-
reject:
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
onAfterRouteLeave: k,
|
|
1634
|
+
replace: b,
|
|
1635
|
+
reject: L,
|
|
1636
|
+
refresh: s.refresh,
|
|
1637
|
+
forward: s.forward,
|
|
1638
|
+
back: s.back,
|
|
1639
|
+
go: s.go,
|
|
1640
|
+
install: un,
|
|
1641
|
+
isExternal: ye,
|
|
1642
|
+
onBeforeRouteEnter: p,
|
|
1643
|
+
onAfterRouteUpdate: P,
|
|
1644
|
+
onBeforeRouteLeave: h,
|
|
1645
|
+
onAfterRouteEnter: m,
|
|
1646
|
+
onBeforeRouteUpdate: v,
|
|
1647
|
+
onAfterRouteLeave: w,
|
|
1633
1648
|
prefetch: t == null ? void 0 : t.prefetch,
|
|
1634
1649
|
start: tt
|
|
1635
1650
|
};
|
|
1636
|
-
return
|
|
1651
|
+
return nt;
|
|
1637
1652
|
}
|
|
1638
|
-
function
|
|
1653
|
+
function ht(e, t) {
|
|
1639
1654
|
return {
|
|
1640
1655
|
value: e,
|
|
1641
|
-
params:
|
|
1656
|
+
params: ze(e, t)
|
|
1642
1657
|
};
|
|
1643
1658
|
}
|
|
1644
|
-
function
|
|
1659
|
+
function Gt(e, t) {
|
|
1645
1660
|
return {
|
|
1646
1661
|
value: e,
|
|
1647
|
-
params:
|
|
1662
|
+
params: ze(e, t)
|
|
1648
1663
|
};
|
|
1649
1664
|
}
|
|
1650
|
-
function
|
|
1651
|
-
return
|
|
1665
|
+
function qr(e) {
|
|
1666
|
+
return de(e) && typeof e.hash == "string";
|
|
1652
1667
|
}
|
|
1653
|
-
function
|
|
1654
|
-
return e === void 0 ?
|
|
1668
|
+
function Kt(e) {
|
|
1669
|
+
return e === void 0 ? we() : qr(e) ? e : we(e);
|
|
1655
1670
|
}
|
|
1656
|
-
function
|
|
1671
|
+
function zt(e) {
|
|
1657
1672
|
return e === void 0 ? "" : e;
|
|
1658
1673
|
}
|
|
1659
|
-
function
|
|
1660
|
-
return
|
|
1674
|
+
function _r(e) {
|
|
1675
|
+
return de(e) && typeof e.value == "string";
|
|
1661
1676
|
}
|
|
1662
|
-
function
|
|
1663
|
-
return e === void 0 ?
|
|
1677
|
+
function Yt(e) {
|
|
1678
|
+
return e === void 0 ? $e("", {}) : _r(e) ? e : $e(e, {});
|
|
1664
1679
|
}
|
|
1665
|
-
function
|
|
1666
|
-
return
|
|
1680
|
+
function Wr(e) {
|
|
1681
|
+
return de(e) && typeof e.value == "string";
|
|
1667
1682
|
}
|
|
1668
|
-
function
|
|
1669
|
-
return e === void 0 ?
|
|
1683
|
+
function Xt(e) {
|
|
1684
|
+
return e === void 0 ? ht("", {}) : Wr(e) ? e : ht(e, {});
|
|
1670
1685
|
}
|
|
1671
|
-
function
|
|
1672
|
-
const t = Je(), n =
|
|
1686
|
+
function oe(e) {
|
|
1687
|
+
const t = Je(), n = zt(e.name), r = Yt(e.path), o = Xt(e.query), a = Kt(e.hash), c = e.meta ?? {}, s = On(e) ? e.state : {}, u = ve({ id: t, meta: {}, state: {}, ...e }), i = {
|
|
1673
1688
|
id: t,
|
|
1674
1689
|
matched: u,
|
|
1675
1690
|
matches: [u],
|
|
@@ -1677,252 +1692,223 @@ function ne(e) {
|
|
|
1677
1692
|
path: r,
|
|
1678
1693
|
query: o,
|
|
1679
1694
|
hash: a,
|
|
1680
|
-
meta:
|
|
1681
|
-
state:
|
|
1695
|
+
meta: c,
|
|
1696
|
+
state: s,
|
|
1682
1697
|
depth: 1,
|
|
1683
|
-
host:
|
|
1698
|
+
host: Gt("", {}),
|
|
1684
1699
|
prefetch: e.prefetch
|
|
1685
|
-
}, f =
|
|
1686
|
-
return
|
|
1700
|
+
}, f = bt(e) ? St(e.parent, i) : i;
|
|
1701
|
+
return ce(f.path.params, f.query.params), f;
|
|
1687
1702
|
}
|
|
1688
|
-
const
|
|
1703
|
+
const Le = { template: "<div>This is component</div>" }, Ye = oe({
|
|
1689
1704
|
name: "parentA",
|
|
1690
1705
|
path: "/parentA/[paramA]"
|
|
1691
|
-
}),
|
|
1692
|
-
parent:
|
|
1706
|
+
}), Zt = oe({
|
|
1707
|
+
parent: Ye,
|
|
1693
1708
|
name: "parentA.childA",
|
|
1694
1709
|
path: "/[?paramB]"
|
|
1695
|
-
}),
|
|
1696
|
-
parent:
|
|
1710
|
+
}), Dr = oe({
|
|
1711
|
+
parent: Ye,
|
|
1697
1712
|
name: "parentA.childB",
|
|
1698
1713
|
path: "/[paramD]",
|
|
1699
|
-
component:
|
|
1700
|
-
}),
|
|
1701
|
-
parent:
|
|
1714
|
+
component: Le
|
|
1715
|
+
}), Mr = oe({
|
|
1716
|
+
parent: Zt,
|
|
1702
1717
|
name: "parentA.childA.grandChildA",
|
|
1703
1718
|
path: "/[paramC]",
|
|
1704
|
-
component:
|
|
1719
|
+
component: Le
|
|
1705
1720
|
});
|
|
1706
|
-
|
|
1721
|
+
oe({
|
|
1707
1722
|
name: "parentB",
|
|
1708
1723
|
path: "/parentB",
|
|
1709
|
-
component:
|
|
1710
|
-
}),
|
|
1724
|
+
component: Le
|
|
1725
|
+
}), oe({
|
|
1711
1726
|
name: "parentC",
|
|
1712
1727
|
path: "/",
|
|
1713
|
-
component:
|
|
1728
|
+
component: Le
|
|
1714
1729
|
});
|
|
1715
|
-
const
|
|
1730
|
+
const Tr = "lazy", Ir = {
|
|
1716
1731
|
components: !0,
|
|
1717
1732
|
props: !1
|
|
1718
1733
|
};
|
|
1719
1734
|
function ge(e) {
|
|
1720
1735
|
return ["eager", "lazy"].includes(e);
|
|
1721
1736
|
}
|
|
1722
|
-
function
|
|
1723
|
-
const o =
|
|
1737
|
+
function en({ routerPrefetch: e, routePrefetch: t, linkPrefetch: n }, r) {
|
|
1738
|
+
const o = Ve(n, r), a = Ve(t, r), c = Ve(e, r), s = [
|
|
1724
1739
|
o,
|
|
1725
1740
|
a,
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1741
|
+
c,
|
|
1742
|
+
Ir[r],
|
|
1743
|
+
Tr
|
|
1729
1744
|
].reduce((u, i) => ge(u) ? u : u === !0 && ge(i) ? i : u === !0 && !ge(i) ? u : u === void 0 ? i : u, void 0);
|
|
1730
|
-
return ge(
|
|
1745
|
+
return ge(s) ? s : !1;
|
|
1731
1746
|
}
|
|
1732
|
-
function
|
|
1733
|
-
return
|
|
1747
|
+
function Ve(e, t) {
|
|
1748
|
+
return de(e) ? e[t] : e;
|
|
1734
1749
|
}
|
|
1735
|
-
function
|
|
1750
|
+
function tn(e) {
|
|
1736
1751
|
return typeof e == "object" && e !== null && "then" in e;
|
|
1737
1752
|
}
|
|
1738
|
-
function
|
|
1753
|
+
function pt(e) {
|
|
1739
1754
|
try {
|
|
1740
1755
|
const t = e();
|
|
1741
|
-
return
|
|
1756
|
+
return tn(t) ? t.catch((n) => n) : t;
|
|
1742
1757
|
} catch (t) {
|
|
1743
1758
|
return t;
|
|
1744
1759
|
}
|
|
1745
1760
|
}
|
|
1746
|
-
const
|
|
1747
|
-
function
|
|
1748
|
-
const e = Ue(/* @__PURE__ */ new Map()), { push: t, replace: n, reject: r } =
|
|
1749
|
-
if (!
|
|
1750
|
-
return
|
|
1751
|
-
const A = u(
|
|
1761
|
+
const nn = Symbol();
|
|
1762
|
+
function Fr() {
|
|
1763
|
+
const e = Ue(/* @__PURE__ */ new Map()), { push: t, replace: n, reject: r } = Ht(), o = (p, P, h) => P.matches.filter((m) => en({ ...h, routePrefetch: m.prefetch }, "props") === p).flatMap((m) => i(m)).reduce((m, { id: v, name: w, props: R }) => {
|
|
1764
|
+
if (!R)
|
|
1765
|
+
return m;
|
|
1766
|
+
const A = u(v, w, P), d = pt(() => R(P, {
|
|
1752
1767
|
push: t,
|
|
1753
1768
|
replace: n,
|
|
1754
1769
|
reject: r
|
|
1755
1770
|
}));
|
|
1756
|
-
return
|
|
1757
|
-
}, {}), a = (
|
|
1758
|
-
Object.entries(
|
|
1759
|
-
e.set(
|
|
1771
|
+
return m[A] = d, m;
|
|
1772
|
+
}, {}), a = (p) => {
|
|
1773
|
+
Object.entries(p).forEach(([P, h]) => {
|
|
1774
|
+
e.set(P, h);
|
|
1760
1775
|
});
|
|
1761
|
-
},
|
|
1762
|
-
const
|
|
1763
|
-
for (const { id:
|
|
1764
|
-
if (!
|
|
1776
|
+
}, c = async (p) => {
|
|
1777
|
+
const P = p.matches.flatMap(i), h = [], m = [];
|
|
1778
|
+
for (const { id: v, name: w, props: R } of P) {
|
|
1779
|
+
if (!R)
|
|
1765
1780
|
continue;
|
|
1766
|
-
const A = u(
|
|
1767
|
-
if (
|
|
1768
|
-
const d =
|
|
1781
|
+
const A = u(v, w, p);
|
|
1782
|
+
if (h.push(A), !e.has(A)) {
|
|
1783
|
+
const d = pt(() => R(p, {
|
|
1769
1784
|
push: t,
|
|
1770
1785
|
replace: n,
|
|
1771
1786
|
reject: r
|
|
1772
1787
|
}));
|
|
1773
1788
|
e.set(A, d);
|
|
1774
1789
|
}
|
|
1775
|
-
|
|
1790
|
+
m.push((async () => {
|
|
1776
1791
|
const d = await e.get(A);
|
|
1777
1792
|
if (d instanceof Error)
|
|
1778
1793
|
throw d;
|
|
1779
1794
|
})());
|
|
1780
1795
|
}
|
|
1781
|
-
f(
|
|
1796
|
+
f(h);
|
|
1782
1797
|
try {
|
|
1783
|
-
return await Promise.all(
|
|
1784
|
-
} catch (
|
|
1785
|
-
if (
|
|
1786
|
-
return
|
|
1787
|
-
throw
|
|
1798
|
+
return await Promise.all(m), { status: "SUCCESS" };
|
|
1799
|
+
} catch (v) {
|
|
1800
|
+
if (v instanceof te || v instanceof ke)
|
|
1801
|
+
return v.response;
|
|
1802
|
+
throw v;
|
|
1788
1803
|
}
|
|
1789
|
-
},
|
|
1790
|
-
const
|
|
1791
|
-
return e.get(
|
|
1804
|
+
}, s = (p, P, h) => {
|
|
1805
|
+
const m = u(p, P, h);
|
|
1806
|
+
return e.get(m);
|
|
1792
1807
|
};
|
|
1793
|
-
function u(
|
|
1794
|
-
return [
|
|
1808
|
+
function u(p, P, h) {
|
|
1809
|
+
return [p, P, h.id, JSON.stringify(h.params)].join("-");
|
|
1795
1810
|
}
|
|
1796
|
-
function i(
|
|
1797
|
-
return
|
|
1811
|
+
function i(p) {
|
|
1812
|
+
return We(p) ? Object.entries(p.props ?? {}).map(([P, h]) => ({ id: p.id, name: P, props: h })) : _e(p) ? [
|
|
1798
1813
|
{
|
|
1799
|
-
id:
|
|
1814
|
+
id: p.id,
|
|
1800
1815
|
name: "default",
|
|
1801
|
-
props:
|
|
1816
|
+
props: p.props
|
|
1802
1817
|
}
|
|
1803
1818
|
] : [];
|
|
1804
1819
|
}
|
|
1805
|
-
function f(
|
|
1806
|
-
for (const
|
|
1807
|
-
|
|
1820
|
+
function f(p) {
|
|
1821
|
+
for (const P in e.keys())
|
|
1822
|
+
p.includes(P) || e.delete(P);
|
|
1808
1823
|
}
|
|
1809
1824
|
return {
|
|
1810
1825
|
getPrefetchProps: o,
|
|
1811
1826
|
setPrefetchProps: a,
|
|
1812
|
-
getProps:
|
|
1813
|
-
setProps:
|
|
1827
|
+
getProps: s,
|
|
1828
|
+
setProps: c
|
|
1814
1829
|
};
|
|
1815
1830
|
}
|
|
1816
|
-
function
|
|
1817
|
-
const e =
|
|
1831
|
+
function rn() {
|
|
1832
|
+
const e = ae(nn);
|
|
1818
1833
|
if (!e)
|
|
1819
|
-
throw new
|
|
1834
|
+
throw new pe();
|
|
1820
1835
|
return e;
|
|
1821
1836
|
}
|
|
1822
|
-
const
|
|
1837
|
+
const Jr = dn(() => new Promise((e) => {
|
|
1823
1838
|
e({ default: { template: "foo" } });
|
|
1824
1839
|
}));
|
|
1825
|
-
function
|
|
1826
|
-
return e.name ===
|
|
1840
|
+
function dt(e) {
|
|
1841
|
+
return e.name === Jr.name && "__asyncLoader" in e;
|
|
1827
1842
|
}
|
|
1828
|
-
function
|
|
1829
|
-
const t = /* @__PURE__ */ new Map(), n =
|
|
1830
|
-
const
|
|
1831
|
-
o(
|
|
1843
|
+
function Qr(e) {
|
|
1844
|
+
const t = /* @__PURE__ */ new Map(), n = Oe(), { getPrefetchProps: r, setPrefetchProps: o } = rn(), { isElementVisible: a } = Nr(n), c = () => {
|
|
1845
|
+
const u = Array.from(t.values()).reduce((i, f) => (Object.assign(i, f), i), {});
|
|
1846
|
+
o(u);
|
|
1832
1847
|
};
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
a(n.value);
|
|
1839
|
-
}), hn(() => {
|
|
1840
|
-
n.value && s(n.value);
|
|
1841
|
-
}), je(() => se(e), ({ route: f, ...l }) => {
|
|
1842
|
-
t.clear(), f && i("eager", f, l);
|
|
1843
|
-
}, { immediate: !0 }), je(() => !!(n.value && c(n.value)), (f) => {
|
|
1844
|
-
const { route: l, ...m } = se(e);
|
|
1845
|
-
!l || !f || i("lazy", l, m);
|
|
1848
|
+
Re(() => T(e), ({ route: u, ...i }) => {
|
|
1849
|
+
t.clear(), u && s("eager", u, i);
|
|
1850
|
+
}, { immediate: !0 }), Re(a, (u) => {
|
|
1851
|
+
const { route: i, ...f } = T(e);
|
|
1852
|
+
!i || !u || s("lazy", i, f);
|
|
1846
1853
|
}, { immediate: !0 });
|
|
1847
|
-
function
|
|
1848
|
-
|
|
1854
|
+
function s(u, i, f) {
|
|
1855
|
+
Gr(u, i, f), t.has(u) || t.set(u, r(u, i, f));
|
|
1849
1856
|
}
|
|
1850
1857
|
return {
|
|
1851
1858
|
element: n,
|
|
1852
|
-
commit:
|
|
1859
|
+
commit: c
|
|
1853
1860
|
};
|
|
1854
1861
|
}
|
|
1855
|
-
function
|
|
1862
|
+
function Gr(e, t, n) {
|
|
1856
1863
|
t.matches.forEach((r) => {
|
|
1857
|
-
|
|
1864
|
+
en({
|
|
1858
1865
|
...n,
|
|
1859
1866
|
routePrefetch: r.prefetch
|
|
1860
|
-
}, "components") === e && (_e(r) &&
|
|
1861
|
-
|
|
1867
|
+
}, "components") === e && (_e(r) && dt(r.component) && r.component.__asyncLoader(), We(r) && Object.values(r.components).forEach((a) => {
|
|
1868
|
+
dt(a) && a.__asyncLoader();
|
|
1862
1869
|
}));
|
|
1863
1870
|
});
|
|
1864
1871
|
}
|
|
1865
|
-
function
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1872
|
+
function on(e, t, { exact: n } = {}) {
|
|
1873
|
+
return Qn(e) ? t === void 0 ? !0 : n ? e.matched.name === t : e.matches.map((r) => r.name).includes(t) : !1;
|
|
1874
|
+
}
|
|
1875
|
+
function Kr(e, t = {}, n = {}) {
|
|
1876
|
+
const r = qe(), o = N(() => {
|
|
1877
|
+
const m = T(e);
|
|
1878
|
+
return typeof m != "string" ? m : r.resolve(m, T(t), T(n));
|
|
1879
|
+
}), a = N(() => {
|
|
1880
|
+
if (o.value)
|
|
1881
|
+
return o.value.href;
|
|
1882
|
+
const m = T(e);
|
|
1883
|
+
if (I(m))
|
|
1884
|
+
return m;
|
|
1885
|
+
console.error(new Error("Failed to resolve route in RouterLink."));
|
|
1886
|
+
}), c = N(() => on(r.route) && r.route.matches.some((m) => {
|
|
1887
|
+
var v;
|
|
1888
|
+
return m.id === ((v = o.value) == null ? void 0 : v.id);
|
|
1889
|
+
})), s = N(() => {
|
|
1890
|
+
var m;
|
|
1891
|
+
return r.route.id === ((m = o.value) == null ? void 0 : m.id);
|
|
1892
|
+
}), u = N(() => !!a.value && r.isExternal(a.value)), i = N(() => {
|
|
1893
|
+
const m = T(e);
|
|
1894
|
+
return typeof m != "string" || I(m) ? T(t) : T(n);
|
|
1895
|
+
}), { element: f, commit: p } = Qr(() => ({
|
|
1896
|
+
route: o.value,
|
|
1876
1897
|
routerPrefetch: r.prefetch,
|
|
1877
|
-
linkPrefetch:
|
|
1878
|
-
})), P = (
|
|
1898
|
+
linkPrefetch: i.value.prefetch
|
|
1899
|
+
})), P = (m) => (p(), r.push(a.value, { ...i.value, ...m }));
|
|
1879
1900
|
return {
|
|
1880
|
-
element:
|
|
1881
|
-
route:
|
|
1882
|
-
href:
|
|
1883
|
-
isMatch:
|
|
1884
|
-
isExactMatch:
|
|
1885
|
-
isExternal:
|
|
1901
|
+
element: f,
|
|
1902
|
+
route: o,
|
|
1903
|
+
href: a,
|
|
1904
|
+
isMatch: c,
|
|
1905
|
+
isExactMatch: s,
|
|
1906
|
+
isExternal: u,
|
|
1886
1907
|
push: P,
|
|
1887
|
-
replace: (
|
|
1888
|
-
};
|
|
1889
|
-
}
|
|
1890
|
-
function Xr(e, t, { exact: n } = {}) {
|
|
1891
|
-
return Fn(e) ? t === void 0 ? !0 : n ? e.matched.name === t : e.matches.map((r) => r.name).includes(t) : !1;
|
|
1892
|
-
}
|
|
1893
|
-
function Zr(e, t) {
|
|
1894
|
-
const n = De();
|
|
1895
|
-
function r() {
|
|
1896
|
-
if (!e)
|
|
1897
|
-
return;
|
|
1898
|
-
if (!Xr(n.route, e, t))
|
|
1899
|
-
throw new Wn(e, n.route.name);
|
|
1900
|
-
}
|
|
1901
|
-
return je(n.route, r, { immediate: !0, deep: !0 }), n.route;
|
|
1902
|
-
}
|
|
1903
|
-
const nn = Symbol();
|
|
1904
|
-
function Ye() {
|
|
1905
|
-
return re(nn, 0);
|
|
1906
|
-
}
|
|
1907
|
-
function rn() {
|
|
1908
|
-
const e = re(Ht);
|
|
1909
|
-
if (!e)
|
|
1910
|
-
throw new he();
|
|
1911
|
-
return e;
|
|
1912
|
-
}
|
|
1913
|
-
function on(e) {
|
|
1914
|
-
return (t) => {
|
|
1915
|
-
const n = Ye(), o = rn().addBeforeRouteHook({ lifecycle: e, hook: t, depth: n, timing: "component" });
|
|
1916
|
-
return mt(o), o;
|
|
1908
|
+
replace: (m) => P(m)
|
|
1917
1909
|
};
|
|
1918
1910
|
}
|
|
1919
|
-
|
|
1920
|
-
return (t) => {
|
|
1921
|
-
const n = Ye(), o = rn().addAfterRouteHook({ lifecycle: e, hook: t, depth: n, timing: "component" });
|
|
1922
|
-
return mt(o), o;
|
|
1923
|
-
};
|
|
1924
|
-
}
|
|
1925
|
-
const fo = on("onBeforeRouteUpdate"), lo = on("onBeforeRouteLeave"), ho = Xe("onAfterRouteEnter"), po = Xe("onAfterRouteUpdate"), mo = Xe("onAfterRouteLeave"), eo = ["href"], to = /* @__PURE__ */ le({
|
|
1911
|
+
const zr = ["href"], Yr = /* @__PURE__ */ se({
|
|
1926
1912
|
__name: "routerLink",
|
|
1927
1913
|
props: {
|
|
1928
1914
|
to: {},
|
|
@@ -1933,120 +1919,177 @@ const fo = on("onBeforeRouteUpdate"), lo = on("onBeforeRouteLeave"), ho = Xe("on
|
|
|
1933
1919
|
state: {}
|
|
1934
1920
|
},
|
|
1935
1921
|
setup(e) {
|
|
1936
|
-
const t = e, n =
|
|
1937
|
-
const { to:
|
|
1938
|
-
return
|
|
1939
|
-
}), { element:
|
|
1922
|
+
const t = e, n = qe(), r = N(() => P(t.to)), o = N(() => h(t.to)), a = N(() => {
|
|
1923
|
+
const { to: v, ...w } = t;
|
|
1924
|
+
return w;
|
|
1925
|
+
}), { element: c, isMatch: s, isExactMatch: u, isExternal: i, push: f } = Kr(() => typeof t.to == "function" ? t.to(n.resolve) : t.to, a), p = N(() => ({
|
|
1940
1926
|
"router-link--match": s.value,
|
|
1941
|
-
"router-link--exact-match":
|
|
1927
|
+
"router-link--exact-match": u.value
|
|
1942
1928
|
}));
|
|
1943
|
-
function
|
|
1944
|
-
|
|
1929
|
+
function P(v) {
|
|
1930
|
+
if (typeof v == "function") {
|
|
1931
|
+
const w = v(n.resolve);
|
|
1932
|
+
return P(w);
|
|
1933
|
+
}
|
|
1934
|
+
return I(v) ? n.resolve(v) : v;
|
|
1935
|
+
}
|
|
1936
|
+
function h(v) {
|
|
1937
|
+
if (typeof v == "function") {
|
|
1938
|
+
const w = v(n.resolve);
|
|
1939
|
+
return h(w);
|
|
1940
|
+
}
|
|
1941
|
+
return I(v) ? v : v == null ? void 0 : v.href;
|
|
1942
|
+
}
|
|
1943
|
+
function m(v) {
|
|
1944
|
+
v.preventDefault(), f();
|
|
1945
1945
|
}
|
|
1946
|
-
return (
|
|
1946
|
+
return (v, w) => (yt(), mn("a", {
|
|
1947
1947
|
ref_key: "element",
|
|
1948
|
-
ref:
|
|
1949
|
-
href:
|
|
1950
|
-
class:
|
|
1951
|
-
onClick:
|
|
1948
|
+
ref: c,
|
|
1949
|
+
href: o.value,
|
|
1950
|
+
class: yn(["router-link", p.value]),
|
|
1951
|
+
onClick: m
|
|
1952
1952
|
}, [
|
|
1953
|
-
|
|
1954
|
-
], 10,
|
|
1953
|
+
gt(v.$slots, "default", vt(gn({ route: r.value, isMatch: ue(s), isExactMatch: ue(u), isExternal: ue(i) })))
|
|
1954
|
+
], 10, zr));
|
|
1955
1955
|
}
|
|
1956
1956
|
});
|
|
1957
|
-
function
|
|
1958
|
-
|
|
1957
|
+
function Xr(e, t) {
|
|
1958
|
+
const n = qe();
|
|
1959
|
+
function r() {
|
|
1960
|
+
if (!e)
|
|
1961
|
+
return;
|
|
1962
|
+
if (!on(n.route, e, t))
|
|
1963
|
+
throw new xn(e, n.route.name);
|
|
1964
|
+
}
|
|
1965
|
+
return Re(n.route, r, { immediate: !0, deep: !0 }), n.route;
|
|
1966
|
+
}
|
|
1967
|
+
const an = Symbol();
|
|
1968
|
+
function Xe() {
|
|
1969
|
+
return ae(an, 0);
|
|
1970
|
+
}
|
|
1971
|
+
function Zr(e, t) {
|
|
1972
|
+
return se({
|
|
1959
1973
|
name: "PropsWrapper",
|
|
1960
1974
|
expose: [],
|
|
1961
1975
|
setup() {
|
|
1962
|
-
const n = t();
|
|
1963
|
-
return () => n instanceof Error ? "" :
|
|
1976
|
+
const n = t(), r = vn();
|
|
1977
|
+
return () => n instanceof Error ? "" : tn(n) ? r != null && r.suspense ? Z(to(e, n)) : Z(eo(e, n)) : Z(e, n);
|
|
1964
1978
|
}
|
|
1965
1979
|
});
|
|
1966
1980
|
}
|
|
1967
|
-
function
|
|
1968
|
-
return
|
|
1981
|
+
function eo(e, t) {
|
|
1982
|
+
return se({
|
|
1969
1983
|
name: "AsyncPropsWrapper",
|
|
1970
1984
|
expose: [],
|
|
1971
1985
|
setup() {
|
|
1972
|
-
const n =
|
|
1973
|
-
return (async () => n.value = await t)(), () => n.value instanceof Error ? "" : n.value ?
|
|
1986
|
+
const n = Oe();
|
|
1987
|
+
return (async () => n.value = await t)(), () => n.value instanceof Error ? "" : n.value ? Z(e, n.value) : "";
|
|
1974
1988
|
}
|
|
1975
1989
|
});
|
|
1976
1990
|
}
|
|
1977
|
-
|
|
1991
|
+
function to(e, t) {
|
|
1992
|
+
return se({
|
|
1993
|
+
name: "SuspenseAsyncPropsWrapper",
|
|
1994
|
+
expose: [],
|
|
1995
|
+
async setup() {
|
|
1996
|
+
const n = await t;
|
|
1997
|
+
return () => Z(e, n);
|
|
1998
|
+
}
|
|
1999
|
+
});
|
|
2000
|
+
}
|
|
2001
|
+
const no = /* @__PURE__ */ se({
|
|
1978
2002
|
__name: "routerView",
|
|
1979
2003
|
props: {
|
|
1980
2004
|
name: { default: "default" }
|
|
1981
2005
|
},
|
|
1982
2006
|
setup(e) {
|
|
1983
|
-
const t =
|
|
1984
|
-
|
|
1985
|
-
const
|
|
2007
|
+
const t = Xr(), n = Jn(), r = Xe(), { getProps: o } = rn(), a = Rn("RouterView", !0);
|
|
2008
|
+
wn(an, r + 1);
|
|
2009
|
+
const c = N(() => {
|
|
1986
2010
|
if (n.value)
|
|
1987
2011
|
return n.value.component;
|
|
1988
2012
|
const i = t.matches.at(r);
|
|
1989
2013
|
if (!i)
|
|
1990
2014
|
return null;
|
|
1991
|
-
const f =
|
|
1992
|
-
return f ?
|
|
2015
|
+
const f = s(i), p = o(i.id, e.name, t);
|
|
2016
|
+
return f ? p ? Zr(f, () => p) : f : null;
|
|
1993
2017
|
});
|
|
1994
|
-
function
|
|
2018
|
+
function s(i) {
|
|
1995
2019
|
return u(i)[e.name];
|
|
1996
2020
|
}
|
|
1997
2021
|
function u(i) {
|
|
1998
|
-
return
|
|
2022
|
+
return We(i) ? i.components : _e(i) ? { default: i.component } : typeof a == "string" ? {} : { default: a };
|
|
1999
2023
|
}
|
|
2000
|
-
return (i, f) =>
|
|
2001
|
-
(
|
|
2002
|
-
]) :
|
|
2024
|
+
return (i, f) => c.value ? gt(i.$slots, "default", vt(Pn({ key: 0 }, { route: ue(t), component: c.value, rejection: ue(n) })), () => [
|
|
2025
|
+
(yt(), En(bn(c.value)))
|
|
2026
|
+
]) : Sn("", !0);
|
|
2003
2027
|
}
|
|
2004
2028
|
});
|
|
2005
|
-
function
|
|
2006
|
-
|
|
2029
|
+
function sn() {
|
|
2030
|
+
const e = ae(jt);
|
|
2031
|
+
if (!e)
|
|
2032
|
+
throw new pe();
|
|
2033
|
+
return e;
|
|
2007
2034
|
}
|
|
2008
|
-
function
|
|
2009
|
-
return
|
|
2035
|
+
function cn(e) {
|
|
2036
|
+
return (t) => {
|
|
2037
|
+
const n = Xe(), o = sn().addBeforeRouteHook({ lifecycle: e, hook: t, depth: n, timing: "component" });
|
|
2038
|
+
return Rt(o), o;
|
|
2039
|
+
};
|
|
2040
|
+
}
|
|
2041
|
+
function Ze(e) {
|
|
2042
|
+
return (t) => {
|
|
2043
|
+
const n = Xe(), o = sn().addAfterRouteHook({ lifecycle: e, hook: t, depth: n, timing: "component" });
|
|
2044
|
+
return Rt(o), o;
|
|
2045
|
+
};
|
|
2046
|
+
}
|
|
2047
|
+
const uo = cn("onBeforeRouteUpdate"), io = cn("onBeforeRouteLeave"), fo = Ze("onAfterRouteEnter"), lo = Ze("onAfterRouteUpdate"), ho = Ze("onAfterRouteLeave");
|
|
2048
|
+
function ro(e) {
|
|
2049
|
+
return de(e) && typeof e.value == "string";
|
|
2050
|
+
}
|
|
2051
|
+
function mt(e) {
|
|
2052
|
+
return ro(e) ? e : Gt(e, {});
|
|
2010
2053
|
}
|
|
2011
|
-
function
|
|
2012
|
-
const t = Je(), n =
|
|
2054
|
+
function po(e) {
|
|
2055
|
+
const t = Je(), n = zt(e.name), r = Yt(e.path), o = Xt(e.query), a = Kt(e.hash), c = e.meta ?? {}, s = $n(e) ? mt(e.host) : mt(""), u = ve({ id: t, meta: {}, state: {}, ...e }), i = {
|
|
2013
2056
|
id: t,
|
|
2014
2057
|
matched: u,
|
|
2015
2058
|
matches: [u],
|
|
2016
2059
|
name: n,
|
|
2017
|
-
host:
|
|
2060
|
+
host: s,
|
|
2018
2061
|
path: r,
|
|
2019
2062
|
query: o,
|
|
2020
2063
|
hash: a,
|
|
2021
|
-
meta:
|
|
2064
|
+
meta: c,
|
|
2022
2065
|
depth: 1,
|
|
2023
2066
|
state: {}
|
|
2024
|
-
}, f =
|
|
2025
|
-
return
|
|
2067
|
+
}, f = bt(e) ? St(e.parent, i) : i;
|
|
2068
|
+
return ce(f.path.params, f.query.params, f.host.params), f;
|
|
2026
2069
|
}
|
|
2027
2070
|
export {
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2071
|
+
kn as DuplicateParamsError,
|
|
2072
|
+
An as MetaPropertyConflict,
|
|
2073
|
+
Yr as RouterLink,
|
|
2074
|
+
pe as RouterNotInstalledError,
|
|
2075
|
+
no as RouterView,
|
|
2076
|
+
xn as UseRouteInvalidError,
|
|
2077
|
+
wt as asUrl,
|
|
2078
|
+
po as createExternalRoute,
|
|
2079
|
+
Tn as createParam,
|
|
2080
|
+
oe as createRoute,
|
|
2081
|
+
co as createRouter,
|
|
2082
|
+
on as isRoute,
|
|
2083
|
+
I as isUrl,
|
|
2084
|
+
fo as onAfterRouteEnter,
|
|
2085
|
+
lo as onAfterRouteLeave,
|
|
2086
|
+
ho as onAfterRouteUpdate,
|
|
2087
|
+
uo as onBeforeRouteLeave,
|
|
2088
|
+
io as onBeforeRouteUpdate,
|
|
2089
|
+
$e as path,
|
|
2090
|
+
ht as query,
|
|
2091
|
+
Kr as useLink,
|
|
2092
|
+
Xr as useRoute,
|
|
2093
|
+
qe as useRouter,
|
|
2094
|
+
so as withDefault
|
|
2052
2095
|
};
|