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