@argon-router/core 0.1.4 → 0.2.1
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/dist/index.cjs +1 -1
- package/dist/index.d.ts +10 -5
- package/dist/index.js +316 -320
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { createEffect as
|
|
1
|
+
import { createEffect as N, createStore as j, createEvent as x, sample as F, split as fe, attach as H, scopeBind as ue, withFactory as le } from "effector";
|
|
2
2
|
import { spread as de } from "patronum";
|
|
3
|
-
function
|
|
3
|
+
function V(e, t) {
|
|
4
4
|
var r = Object.keys(e);
|
|
5
5
|
if (Object.getOwnPropertySymbols) {
|
|
6
6
|
var n = Object.getOwnPropertySymbols(e);
|
|
@@ -13,9 +13,9 @@ function z(e, t) {
|
|
|
13
13
|
function C(e) {
|
|
14
14
|
for (var t = 1; t < arguments.length; t++) {
|
|
15
15
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
16
|
-
t % 2 ?
|
|
16
|
+
t % 2 ? V(Object(r), !0).forEach(function(n) {
|
|
17
17
|
pe(e, n, r[n]);
|
|
18
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) :
|
|
18
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : V(Object(r)).forEach(function(n) {
|
|
19
19
|
Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
|
|
20
20
|
});
|
|
21
21
|
}
|
|
@@ -40,57 +40,59 @@ function ye(e, t) {
|
|
|
40
40
|
}
|
|
41
41
|
function Qe(e) {
|
|
42
42
|
let t;
|
|
43
|
-
const r =
|
|
44
|
-
var
|
|
45
|
-
return (
|
|
43
|
+
const r = N(() => {
|
|
44
|
+
var p;
|
|
45
|
+
return (p = t) === null || p === void 0 ? void 0 : p();
|
|
46
46
|
}, {
|
|
47
47
|
name: "waitForAsyncBundleFx",
|
|
48
|
-
sid: "
|
|
49
|
-
}), n =
|
|
50
|
-
for (const
|
|
51
|
-
var
|
|
52
|
-
await
|
|
48
|
+
sid: "tw7mq7"
|
|
49
|
+
}), n = N(async () => {
|
|
50
|
+
for (const l of (p = e.beforeOpen) !== null && p !== void 0 ? p : []) {
|
|
51
|
+
var p;
|
|
52
|
+
await l();
|
|
53
53
|
}
|
|
54
54
|
}, {
|
|
55
55
|
name: "beforeOpenFx",
|
|
56
|
-
sid: "
|
|
57
|
-
}), a =
|
|
56
|
+
sid: "ls74w9"
|
|
57
|
+
}), a = N(async (p) => (await r(), await n(), e.parent && await e.parent.internal.openFx(C(C({}, p ?? {
|
|
58
|
+
params: {}
|
|
59
|
+
}), {}, {
|
|
58
60
|
historyIgnore: !0
|
|
59
|
-
})),
|
|
61
|
+
})), p), {
|
|
60
62
|
name: "openFx",
|
|
61
|
-
sid: "-
|
|
62
|
-
}), s =
|
|
63
|
+
sid: "-hz9h5i"
|
|
64
|
+
}), s = j({}, {
|
|
63
65
|
name: "$params",
|
|
64
|
-
sid: "
|
|
65
|
-
}),
|
|
66
|
+
sid: "fyp6wk"
|
|
67
|
+
}), i = j(!1, {
|
|
66
68
|
name: "$isOpened",
|
|
67
|
-
sid: "
|
|
68
|
-
}),
|
|
69
|
+
sid: "nq2be0"
|
|
70
|
+
}), o = a.pending, f = x({
|
|
69
71
|
name: "open",
|
|
70
|
-
sid: "-
|
|
71
|
-
}),
|
|
72
|
+
sid: "-e84o6b"
|
|
73
|
+
}), u = x({
|
|
72
74
|
name: "close",
|
|
73
|
-
sid: "
|
|
74
|
-
}),
|
|
75
|
+
sid: "5yq009"
|
|
76
|
+
}), y = x({
|
|
75
77
|
name: "opened",
|
|
76
|
-
sid: "
|
|
78
|
+
sid: "28lguv"
|
|
77
79
|
}), d = x({
|
|
78
80
|
name: "openedOnServer",
|
|
79
|
-
sid: "-
|
|
81
|
+
sid: "-rnqoit"
|
|
80
82
|
}), b = x({
|
|
81
83
|
name: "openedOnClient",
|
|
82
|
-
sid: "-
|
|
84
|
+
sid: "-rq76gu"
|
|
83
85
|
}), w = x({
|
|
84
86
|
name: "closed",
|
|
85
|
-
sid: "-
|
|
87
|
+
sid: "-atkmcq"
|
|
86
88
|
});
|
|
87
89
|
return F({
|
|
88
90
|
and: [{
|
|
89
|
-
clock:
|
|
91
|
+
clock: f,
|
|
90
92
|
target: a
|
|
91
93
|
}],
|
|
92
94
|
or: {
|
|
93
|
-
sid: "
|
|
95
|
+
sid: "t5oqwf"
|
|
94
96
|
}
|
|
95
97
|
}), fe({
|
|
96
98
|
and: [{
|
|
@@ -102,75 +104,75 @@ function Qe(e) {
|
|
|
102
104
|
}
|
|
103
105
|
}],
|
|
104
106
|
or: {
|
|
105
|
-
sid: "
|
|
107
|
+
sid: "t8fpv8"
|
|
106
108
|
}
|
|
107
109
|
}), F({
|
|
108
110
|
and: [{
|
|
109
111
|
clock: [b, d],
|
|
110
|
-
target:
|
|
112
|
+
target: y
|
|
111
113
|
}],
|
|
112
114
|
or: {
|
|
113
|
-
sid: "
|
|
115
|
+
sid: "tphc9f"
|
|
114
116
|
}
|
|
115
117
|
}), F({
|
|
116
118
|
and: [{
|
|
117
|
-
clock:
|
|
119
|
+
clock: y,
|
|
118
120
|
fn: () => !0,
|
|
119
|
-
target:
|
|
121
|
+
target: i
|
|
120
122
|
}],
|
|
121
123
|
or: {
|
|
122
|
-
sid: "
|
|
124
|
+
sid: "u3rzot"
|
|
123
125
|
}
|
|
124
126
|
}), F({
|
|
125
127
|
and: [{
|
|
126
|
-
clock:
|
|
128
|
+
clock: u,
|
|
127
129
|
target: w
|
|
128
130
|
}],
|
|
129
131
|
or: {
|
|
130
|
-
sid: "
|
|
132
|
+
sid: "u72r8z"
|
|
131
133
|
}
|
|
132
134
|
}), F({
|
|
133
135
|
and: [{
|
|
134
136
|
clock: w,
|
|
135
137
|
fn: () => !1,
|
|
136
|
-
target:
|
|
138
|
+
target: i
|
|
137
139
|
}],
|
|
138
140
|
or: {
|
|
139
|
-
sid: "
|
|
141
|
+
sid: "ykn3cq"
|
|
140
142
|
}
|
|
141
143
|
}), {
|
|
142
144
|
$params: s,
|
|
143
|
-
$isOpened:
|
|
144
|
-
$isPending:
|
|
145
|
-
open:
|
|
145
|
+
$isOpened: i,
|
|
146
|
+
$isPending: o,
|
|
147
|
+
open: f,
|
|
146
148
|
closed: w,
|
|
147
|
-
opened:
|
|
149
|
+
opened: y,
|
|
148
150
|
openedOnClient: b,
|
|
149
151
|
openedOnServer: d,
|
|
150
152
|
internal: C({
|
|
151
153
|
index: !1,
|
|
152
|
-
close:
|
|
154
|
+
close: u,
|
|
153
155
|
openFx: a,
|
|
154
|
-
setAsyncImport: (
|
|
156
|
+
setAsyncImport: (p) => t = p
|
|
155
157
|
}, e),
|
|
156
158
|
"@@unitShape": () => ({
|
|
157
159
|
params: s,
|
|
158
|
-
isPending:
|
|
159
|
-
isOpened:
|
|
160
|
-
onOpen:
|
|
160
|
+
isPending: o,
|
|
161
|
+
isOpened: i,
|
|
162
|
+
onOpen: f
|
|
161
163
|
})
|
|
162
164
|
};
|
|
163
165
|
}
|
|
164
|
-
var
|
|
165
|
-
Object.defineProperty(
|
|
166
|
+
var E = {};
|
|
167
|
+
Object.defineProperty(E, "__esModule", {
|
|
166
168
|
value: !0
|
|
167
169
|
});
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
var he =
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
const
|
|
170
|
+
E.TokenData = void 0;
|
|
171
|
+
E.parse = L;
|
|
172
|
+
var he = E.compile = $e, ge = E.match = Oe;
|
|
173
|
+
E.pathToRegexp = Z;
|
|
174
|
+
E.stringify = Ae;
|
|
175
|
+
const U = "/", _ = (e) => e, X = /^[$_\p{ID_Start}]$/u, q = /^[$\u200c\u200d\p{ID_Continue}]$/u, I = "https://git.new/pathToRegexpError", be = {
|
|
174
176
|
// Groups.
|
|
175
177
|
"{": "{",
|
|
176
178
|
"}": "}",
|
|
@@ -228,18 +230,18 @@ function* xe(e) {
|
|
|
228
230
|
value: t[r++]
|
|
229
231
|
};
|
|
230
232
|
else if (a === ":") {
|
|
231
|
-
const
|
|
233
|
+
const i = n();
|
|
232
234
|
yield {
|
|
233
235
|
type: "PARAM",
|
|
234
236
|
index: r,
|
|
235
|
-
value:
|
|
237
|
+
value: i
|
|
236
238
|
};
|
|
237
239
|
} else if (a === "*") {
|
|
238
|
-
const
|
|
240
|
+
const i = n();
|
|
239
241
|
yield {
|
|
240
242
|
type: "WILDCARD",
|
|
241
243
|
index: r,
|
|
242
|
-
value:
|
|
244
|
+
value: i
|
|
243
245
|
};
|
|
244
246
|
} else
|
|
245
247
|
yield {
|
|
@@ -286,72 +288,72 @@ class Fe {
|
|
|
286
288
|
return t;
|
|
287
289
|
}
|
|
288
290
|
}
|
|
289
|
-
class
|
|
291
|
+
class k {
|
|
290
292
|
constructor(t) {
|
|
291
293
|
this.tokens = t;
|
|
292
294
|
}
|
|
293
295
|
}
|
|
294
|
-
|
|
296
|
+
E.TokenData = k;
|
|
295
297
|
function L(e, t = {}) {
|
|
296
298
|
const {
|
|
297
|
-
encodePath: r =
|
|
299
|
+
encodePath: r = _
|
|
298
300
|
} = t, n = new Fe(xe(e));
|
|
299
|
-
function a(
|
|
300
|
-
const
|
|
301
|
+
function a(i) {
|
|
302
|
+
const o = [];
|
|
301
303
|
for (; ; ) {
|
|
302
|
-
const
|
|
303
|
-
|
|
304
|
+
const f = n.text();
|
|
305
|
+
f && o.push({
|
|
304
306
|
type: "text",
|
|
305
|
-
value: r(
|
|
307
|
+
value: r(f)
|
|
306
308
|
});
|
|
307
|
-
const
|
|
308
|
-
if (
|
|
309
|
-
|
|
309
|
+
const u = n.tryConsume("PARAM");
|
|
310
|
+
if (u) {
|
|
311
|
+
o.push({
|
|
310
312
|
type: "param",
|
|
311
|
-
name:
|
|
313
|
+
name: u
|
|
312
314
|
});
|
|
313
315
|
continue;
|
|
314
316
|
}
|
|
315
|
-
const
|
|
316
|
-
if (
|
|
317
|
-
|
|
317
|
+
const y = n.tryConsume("WILDCARD");
|
|
318
|
+
if (y) {
|
|
319
|
+
o.push({
|
|
318
320
|
type: "wildcard",
|
|
319
|
-
name:
|
|
321
|
+
name: y
|
|
320
322
|
});
|
|
321
323
|
continue;
|
|
322
324
|
}
|
|
323
325
|
if (n.tryConsume("{")) {
|
|
324
|
-
|
|
326
|
+
o.push({
|
|
325
327
|
type: "group",
|
|
326
328
|
tokens: a("}")
|
|
327
329
|
});
|
|
328
330
|
continue;
|
|
329
331
|
}
|
|
330
|
-
return n.consume(
|
|
332
|
+
return n.consume(i), o;
|
|
331
333
|
}
|
|
332
334
|
}
|
|
333
335
|
const s = a("END");
|
|
334
|
-
return new
|
|
336
|
+
return new k(s);
|
|
335
337
|
}
|
|
336
338
|
function $e(e, t = {}) {
|
|
337
339
|
const {
|
|
338
340
|
encode: r = encodeURIComponent,
|
|
339
|
-
delimiter: n =
|
|
340
|
-
} = t, a = e instanceof
|
|
341
|
-
return function(
|
|
342
|
-
const [
|
|
343
|
-
if (
|
|
344
|
-
throw new TypeError(`Missing parameters: ${
|
|
345
|
-
return
|
|
341
|
+
delimiter: n = U
|
|
342
|
+
} = t, a = e instanceof k ? e : L(e, t), s = Y(a.tokens, n, r);
|
|
343
|
+
return function(o = {}) {
|
|
344
|
+
const [f, ...u] = s(o);
|
|
345
|
+
if (u.length)
|
|
346
|
+
throw new TypeError(`Missing parameters: ${u.join(", ")}`);
|
|
347
|
+
return f;
|
|
346
348
|
};
|
|
347
349
|
}
|
|
348
350
|
function Y(e, t, r) {
|
|
349
351
|
const n = e.map((a) => Se(a, t, r));
|
|
350
352
|
return (a) => {
|
|
351
353
|
const s = [""];
|
|
352
|
-
for (const
|
|
353
|
-
const [
|
|
354
|
-
s[0] +=
|
|
354
|
+
for (const i of n) {
|
|
355
|
+
const [o, ...f] = i(a);
|
|
356
|
+
s[0] += o, s.push(...f);
|
|
355
357
|
}
|
|
356
358
|
return s;
|
|
357
359
|
};
|
|
@@ -361,20 +363,20 @@ function Se(e, t, r) {
|
|
|
361
363
|
if (e.type === "group") {
|
|
362
364
|
const a = Y(e.tokens, t, r);
|
|
363
365
|
return (s) => {
|
|
364
|
-
const [
|
|
365
|
-
return
|
|
366
|
+
const [i, ...o] = a(s);
|
|
367
|
+
return o.length ? [""] : [i];
|
|
366
368
|
};
|
|
367
369
|
}
|
|
368
|
-
const n = r ||
|
|
370
|
+
const n = r || _;
|
|
369
371
|
return e.type === "wildcard" && r !== !1 ? (a) => {
|
|
370
372
|
const s = a[e.name];
|
|
371
373
|
if (s == null) return ["", e.name];
|
|
372
374
|
if (!Array.isArray(s) || s.length === 0)
|
|
373
375
|
throw new TypeError(`Expected "${e.name}" to be a non-empty array`);
|
|
374
|
-
return [s.map((
|
|
375
|
-
if (typeof
|
|
376
|
-
throw new TypeError(`Expected "${e.name}/${
|
|
377
|
-
return n(
|
|
376
|
+
return [s.map((i, o) => {
|
|
377
|
+
if (typeof i != "string")
|
|
378
|
+
throw new TypeError(`Expected "${e.name}/${o}" to be a string`);
|
|
379
|
+
return n(i);
|
|
378
380
|
}).join(t)];
|
|
379
381
|
} : (a) => {
|
|
380
382
|
const s = a[e.name];
|
|
@@ -387,76 +389,76 @@ function Se(e, t, r) {
|
|
|
387
389
|
function Oe(e, t = {}) {
|
|
388
390
|
const {
|
|
389
391
|
decode: r = decodeURIComponent,
|
|
390
|
-
delimiter: n =
|
|
392
|
+
delimiter: n = U
|
|
391
393
|
} = t, {
|
|
392
394
|
regexp: a,
|
|
393
395
|
keys: s
|
|
394
|
-
} = Z(e, t),
|
|
395
|
-
return function(
|
|
396
|
-
const
|
|
397
|
-
if (!
|
|
398
|
-
const
|
|
399
|
-
for (let b = 1; b <
|
|
400
|
-
if (
|
|
401
|
-
const w = s[b - 1],
|
|
402
|
-
d[w.name] =
|
|
396
|
+
} = Z(e, t), i = s.map((o) => r === !1 ? _ : o.type === "param" ? r : (f) => f.split(n).map(r));
|
|
397
|
+
return function(f) {
|
|
398
|
+
const u = a.exec(f);
|
|
399
|
+
if (!u) return !1;
|
|
400
|
+
const y = u[0], d = /* @__PURE__ */ Object.create(null);
|
|
401
|
+
for (let b = 1; b < u.length; b++) {
|
|
402
|
+
if (u[b] === void 0) continue;
|
|
403
|
+
const w = s[b - 1], p = i[b - 1];
|
|
404
|
+
d[w.name] = p(u[b]);
|
|
403
405
|
}
|
|
404
406
|
return {
|
|
405
|
-
path:
|
|
407
|
+
path: y,
|
|
406
408
|
params: d
|
|
407
409
|
};
|
|
408
410
|
};
|
|
409
411
|
}
|
|
410
412
|
function Z(e, t = {}) {
|
|
411
413
|
const {
|
|
412
|
-
delimiter: r =
|
|
414
|
+
delimiter: r = U,
|
|
413
415
|
end: n = !0,
|
|
414
416
|
sensitive: a = !1,
|
|
415
417
|
trailing: s = !0
|
|
416
|
-
} = t,
|
|
418
|
+
} = t, i = [], o = [], f = a ? "" : "i", y = (Array.isArray(e) ? e : [e]).map((w) => w instanceof k ? w : L(w, t));
|
|
417
419
|
for (const {
|
|
418
420
|
tokens: w
|
|
419
|
-
} of
|
|
420
|
-
for (const
|
|
421
|
-
const
|
|
422
|
-
|
|
421
|
+
} of y)
|
|
422
|
+
for (const p of R(w, 0, [])) {
|
|
423
|
+
const l = Ee(p, r, i);
|
|
424
|
+
o.push(l);
|
|
423
425
|
}
|
|
424
|
-
let d = `^(?:${
|
|
426
|
+
let d = `^(?:${o.join("|")})`;
|
|
425
427
|
return s && (d += `(?:${$(r)}$)?`), d += n ? "$" : `(?=${$(r)}|$)`, {
|
|
426
|
-
regexp: new RegExp(d,
|
|
427
|
-
keys:
|
|
428
|
+
regexp: new RegExp(d, f),
|
|
429
|
+
keys: i
|
|
428
430
|
};
|
|
429
431
|
}
|
|
430
|
-
function*
|
|
432
|
+
function* R(e, t, r) {
|
|
431
433
|
if (t === e.length)
|
|
432
434
|
return yield r;
|
|
433
435
|
const n = e[t];
|
|
434
436
|
if (n.type === "group") {
|
|
435
437
|
const a = r.slice();
|
|
436
|
-
for (const s of
|
|
437
|
-
yield*
|
|
438
|
+
for (const s of R(n.tokens, 0, a))
|
|
439
|
+
yield* R(e, t + 1, s);
|
|
438
440
|
} else
|
|
439
441
|
r.push(n);
|
|
440
|
-
yield*
|
|
442
|
+
yield* R(e, t + 1, r);
|
|
441
443
|
}
|
|
442
|
-
function
|
|
444
|
+
function Ee(e, t, r) {
|
|
443
445
|
let n = "", a = "", s = !0;
|
|
444
|
-
for (let
|
|
445
|
-
const
|
|
446
|
-
if (
|
|
447
|
-
n += $(
|
|
446
|
+
for (let i = 0; i < e.length; i++) {
|
|
447
|
+
const o = e[i];
|
|
448
|
+
if (o.type === "text") {
|
|
449
|
+
n += $(o.value), a += o.value, s || (s = o.value.includes(t));
|
|
448
450
|
continue;
|
|
449
451
|
}
|
|
450
|
-
if (
|
|
452
|
+
if (o.type === "param" || o.type === "wildcard") {
|
|
451
453
|
if (!s && !a)
|
|
452
|
-
throw new TypeError(`Missing text after "${
|
|
453
|
-
|
|
454
|
+
throw new TypeError(`Missing text after "${o.name}": ${I}`);
|
|
455
|
+
o.type === "param" ? n += `(${je(t, s ? "" : a)}+)` : n += "([\\s\\S]+)", r.push(o), a = "", s = !1;
|
|
454
456
|
continue;
|
|
455
457
|
}
|
|
456
458
|
}
|
|
457
459
|
return n;
|
|
458
460
|
}
|
|
459
|
-
function
|
|
461
|
+
function je(e, t) {
|
|
460
462
|
return t.length < 2 ? e.length < 2 ? `[^${$(e + t)}]` : `(?:(?!${$(e)})[^${$(t)}])` : e.length < 2 ? `(?:(?!${$(t)})[^${$(e)}])` : `(?:(?!${$(t)}|${$(e)})[\\s\\S])`;
|
|
461
463
|
}
|
|
462
464
|
function Ae(e) {
|
|
@@ -464,9 +466,9 @@ function Ae(e) {
|
|
|
464
466
|
if (r.type === "text") return we(r.value);
|
|
465
467
|
if (r.type === "group")
|
|
466
468
|
return `{${r.tokens.map(t).join("")}}`;
|
|
467
|
-
const
|
|
468
|
-
if (r.type === "param") return `:${
|
|
469
|
-
if (r.type === "wildcard") return `*${
|
|
469
|
+
const i = Ne(r.name) && Re(a[n + 1]) ? r.name : JSON.stringify(r.name);
|
|
470
|
+
if (r.type === "param") return `:${i}`;
|
|
471
|
+
if (r.type === "wildcard") return `*${i}`;
|
|
470
472
|
throw new TypeError(`Unexpected token: ${r}`);
|
|
471
473
|
}).join("");
|
|
472
474
|
}
|
|
@@ -477,9 +479,9 @@ function Ne(e) {
|
|
|
477
479
|
function Re(e) {
|
|
478
480
|
return (e == null ? void 0 : e.type) !== "text" ? !0 : !q.test(e.value[0]);
|
|
479
481
|
}
|
|
480
|
-
const
|
|
481
|
-
any:
|
|
482
|
-
number:
|
|
482
|
+
const Ie = Symbol("any"), ke = Symbol("number"), Pe = Symbol("string"), Ce = Symbol("array"), O = {
|
|
483
|
+
any: Ie,
|
|
484
|
+
number: ke,
|
|
483
485
|
string: Pe,
|
|
484
486
|
array: Ce
|
|
485
487
|
};
|
|
@@ -551,8 +553,8 @@ function Te(e, t) {
|
|
|
551
553
|
}
|
|
552
554
|
switch (typeof a) {
|
|
553
555
|
case "number": {
|
|
554
|
-
const
|
|
555
|
-
r[n] = isNaN(parseInt(
|
|
556
|
+
const i = e[n];
|
|
557
|
+
r[n] = isNaN(parseInt(i)) ? parseFloat(i) : parseInt(i);
|
|
556
558
|
break;
|
|
557
559
|
}
|
|
558
560
|
case "object": {
|
|
@@ -562,8 +564,8 @@ function Te(e, t) {
|
|
|
562
564
|
case "string":
|
|
563
565
|
r[n] = e[n];
|
|
564
566
|
case "boolean": {
|
|
565
|
-
const
|
|
566
|
-
r[n] =
|
|
567
|
+
const i = e[n];
|
|
568
|
+
r[n] = i === "0" ? parseFloat(i) : parseInt(i);
|
|
567
569
|
break;
|
|
568
570
|
}
|
|
569
571
|
}
|
|
@@ -575,8 +577,8 @@ function Te(e, t) {
|
|
|
575
577
|
break;
|
|
576
578
|
}
|
|
577
579
|
case O.number: {
|
|
578
|
-
const
|
|
579
|
-
r[n] = isNaN(parseInt(
|
|
580
|
+
const i = e[n];
|
|
581
|
+
r[n] = isNaN(parseInt(i)) ? parseFloat(i) : parseInt(i);
|
|
580
582
|
break;
|
|
581
583
|
}
|
|
582
584
|
}
|
|
@@ -591,10 +593,10 @@ function De(e, t) {
|
|
|
591
593
|
} = r, s = x({
|
|
592
594
|
name: "entered",
|
|
593
595
|
sid: "-d3obu6"
|
|
594
|
-
}),
|
|
596
|
+
}), i = x({
|
|
595
597
|
name: "exited",
|
|
596
598
|
sid: "-xofyk3"
|
|
597
|
-
}),
|
|
599
|
+
}), o = x({
|
|
598
600
|
name: "exit",
|
|
599
601
|
sid: "-673d76"
|
|
600
602
|
});
|
|
@@ -604,18 +606,18 @@ function De(e, t) {
|
|
|
604
606
|
activeRoutes: e,
|
|
605
607
|
query: t
|
|
606
608
|
},
|
|
607
|
-
filter: (
|
|
609
|
+
filter: (f) => {
|
|
608
610
|
let {
|
|
609
|
-
activeRoutes:
|
|
610
|
-
query:
|
|
611
|
-
} =
|
|
612
|
-
return (!a || K(a,
|
|
611
|
+
activeRoutes: u,
|
|
612
|
+
query: y
|
|
613
|
+
} = f;
|
|
614
|
+
return (!a || K(a, u)) && J(y, n);
|
|
613
615
|
},
|
|
614
|
-
fn: (
|
|
616
|
+
fn: (f) => {
|
|
615
617
|
let {
|
|
616
|
-
query:
|
|
617
|
-
} =
|
|
618
|
-
return Te(
|
|
618
|
+
query: u
|
|
619
|
+
} = f;
|
|
620
|
+
return Te(u, n);
|
|
619
621
|
}
|
|
620
622
|
}],
|
|
621
623
|
or: {
|
|
@@ -627,25 +629,25 @@ function De(e, t) {
|
|
|
627
629
|
activeRoutes: e,
|
|
628
630
|
query: t
|
|
629
631
|
},
|
|
630
|
-
filter: (
|
|
632
|
+
filter: (f) => {
|
|
631
633
|
let {
|
|
632
|
-
activeRoutes:
|
|
633
|
-
query:
|
|
634
|
-
} =
|
|
635
|
-
return !((!a || K(a,
|
|
634
|
+
activeRoutes: u,
|
|
635
|
+
query: y
|
|
636
|
+
} = f;
|
|
637
|
+
return !((!a || K(a, u)) && J(y, n));
|
|
636
638
|
},
|
|
637
|
-
target:
|
|
639
|
+
target: i
|
|
638
640
|
}],
|
|
639
641
|
or: {
|
|
640
642
|
sid: "-s82e29"
|
|
641
643
|
}
|
|
642
644
|
}), {
|
|
643
645
|
entered: s,
|
|
644
|
-
exited:
|
|
645
|
-
exit:
|
|
646
|
-
getPayload: (
|
|
647
|
-
let [d, b] =
|
|
648
|
-
return typeof n[d] == "symbol" ?
|
|
646
|
+
exited: i,
|
|
647
|
+
exit: o,
|
|
648
|
+
getPayload: (f) => Object.entries(f).reduce((u, y) => {
|
|
649
|
+
let [d, b] = y;
|
|
650
|
+
return typeof n[d] == "symbol" ? u[d] = b : u[d] = n[d], u;
|
|
649
651
|
}, {})
|
|
650
652
|
};
|
|
651
653
|
};
|
|
@@ -662,7 +664,7 @@ function D(e, t) {
|
|
|
662
664
|
const r = e.slice(0, t), n = e.slice(t);
|
|
663
665
|
return Array.prototype.concat.call([], D(r), D(n));
|
|
664
666
|
}
|
|
665
|
-
function
|
|
667
|
+
function ve(e) {
|
|
666
668
|
try {
|
|
667
669
|
return decodeURIComponent(e);
|
|
668
670
|
} catch {
|
|
@@ -672,7 +674,7 @@ function Ue(e) {
|
|
|
672
674
|
return e;
|
|
673
675
|
}
|
|
674
676
|
}
|
|
675
|
-
function
|
|
677
|
+
function Ue(e) {
|
|
676
678
|
const t = {
|
|
677
679
|
"%FE%FF": "��",
|
|
678
680
|
"%FF%FE": "��"
|
|
@@ -682,7 +684,7 @@ function _e(e) {
|
|
|
682
684
|
try {
|
|
683
685
|
t[r[0]] = decodeURIComponent(r[0]);
|
|
684
686
|
} catch {
|
|
685
|
-
const a =
|
|
687
|
+
const a = ve(r[0]);
|
|
686
688
|
a !== r[0] && (t[r[0]] = a);
|
|
687
689
|
}
|
|
688
690
|
r = W.exec(e);
|
|
@@ -693,13 +695,13 @@ function _e(e) {
|
|
|
693
695
|
e = e.replace(new RegExp(a, "g"), t[a]);
|
|
694
696
|
return e;
|
|
695
697
|
}
|
|
696
|
-
function
|
|
698
|
+
function _e(e) {
|
|
697
699
|
if (typeof e != "string")
|
|
698
700
|
throw new TypeError("Expected `encodedURI` to be of type `string`, got `" + typeof e + "`");
|
|
699
701
|
try {
|
|
700
702
|
return decodeURIComponent(e);
|
|
701
703
|
} catch {
|
|
702
|
-
return
|
|
704
|
+
return Ue(e);
|
|
703
705
|
}
|
|
704
706
|
}
|
|
705
707
|
function qe(e, t) {
|
|
@@ -727,29 +729,29 @@ function re(e, t) {
|
|
|
727
729
|
const r = e.indexOf(t);
|
|
728
730
|
return r === -1 ? [] : [e.slice(0, r), e.slice(r + t.length)];
|
|
729
731
|
}
|
|
730
|
-
const Le = (e) => e == null, Me = (e) => encodeURIComponent(e).replaceAll(/[!'()*]/g, (t) => `%${t.charCodeAt(0).toString(16).toUpperCase()}`),
|
|
731
|
-
function
|
|
732
|
+
const Le = (e) => e == null, Me = (e) => encodeURIComponent(e).replaceAll(/[!'()*]/g, (t) => `%${t.charCodeAt(0).toString(16).toUpperCase()}`), v = Symbol("encodeFragmentIdentifier");
|
|
733
|
+
function ze(e) {
|
|
732
734
|
switch (e.arrayFormat) {
|
|
733
735
|
case "index":
|
|
734
736
|
return (t) => (r, n) => {
|
|
735
737
|
const a = r.length;
|
|
736
|
-
return n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [
|
|
738
|
+
return n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [m(t, e), "[", a, "]"].join("")] : [...r, [m(t, e), "[", m(a, e), "]=", m(n, e)].join("")];
|
|
737
739
|
};
|
|
738
740
|
case "bracket":
|
|
739
|
-
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [
|
|
741
|
+
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [m(t, e), "[]"].join("")] : [...r, [m(t, e), "[]=", m(n, e)].join("")];
|
|
740
742
|
case "colon-list-separator":
|
|
741
|
-
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [
|
|
743
|
+
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [m(t, e), ":list="].join("")] : [...r, [m(t, e), ":list=", m(n, e)].join("")];
|
|
742
744
|
case "comma":
|
|
743
745
|
case "separator":
|
|
744
746
|
case "bracket-separator": {
|
|
745
747
|
const t = e.arrayFormat === "bracket-separator" ? "[]=" : "=";
|
|
746
|
-
return (r) => (n, a) => a === void 0 || e.skipNull && a === null || e.skipEmptyString && a === "" ? n : (a = a === null ? "" : a, n.length === 0 ? [[
|
|
748
|
+
return (r) => (n, a) => a === void 0 || e.skipNull && a === null || e.skipEmptyString && a === "" ? n : (a = a === null ? "" : a, n.length === 0 ? [[m(r, e), t, m(a, e)].join("")] : [[n, m(a, e)].join(e.arrayFormatSeparator)]);
|
|
747
749
|
}
|
|
748
750
|
default:
|
|
749
|
-
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r,
|
|
751
|
+
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, m(t, e)] : [...r, [m(t, e), "=", m(n, e)].join("")];
|
|
750
752
|
}
|
|
751
753
|
}
|
|
752
|
-
function
|
|
754
|
+
function Be(e) {
|
|
753
755
|
let t;
|
|
754
756
|
switch (e.arrayFormat) {
|
|
755
757
|
case "index":
|
|
@@ -787,10 +789,10 @@ function He(e) {
|
|
|
787
789
|
case "comma":
|
|
788
790
|
case "separator":
|
|
789
791
|
return (r, n, a) => {
|
|
790
|
-
const s = typeof n == "string" && n.includes(e.arrayFormatSeparator),
|
|
791
|
-
n =
|
|
792
|
-
const
|
|
793
|
-
a[r] =
|
|
792
|
+
const s = typeof n == "string" && n.includes(e.arrayFormatSeparator), i = typeof n == "string" && !s && S(n, e).includes(e.arrayFormatSeparator);
|
|
793
|
+
n = i ? S(n, e) : n;
|
|
794
|
+
const o = s || i ? n.split(e.arrayFormatSeparator).map((f) => S(f, e)) : n === null ? n : S(n, e);
|
|
795
|
+
a[r] = o;
|
|
794
796
|
};
|
|
795
797
|
case "bracket-separator":
|
|
796
798
|
return (r, n, a) => {
|
|
@@ -799,12 +801,12 @@ function He(e) {
|
|
|
799
801
|
a[r] = n && S(n, e);
|
|
800
802
|
return;
|
|
801
803
|
}
|
|
802
|
-
const
|
|
804
|
+
const i = n === null ? [] : S(n, e).split(e.arrayFormatSeparator);
|
|
803
805
|
if (a[r] === void 0) {
|
|
804
|
-
a[r] =
|
|
806
|
+
a[r] = i;
|
|
805
807
|
return;
|
|
806
808
|
}
|
|
807
|
-
a[r] = [...a[r], ...
|
|
809
|
+
a[r] = [...a[r], ...i];
|
|
808
810
|
};
|
|
809
811
|
default:
|
|
810
812
|
return (r, n, a) => {
|
|
@@ -820,11 +822,11 @@ function te(e) {
|
|
|
820
822
|
if (typeof e != "string" || e.length !== 1)
|
|
821
823
|
throw new TypeError("arrayFormatSeparator must be single character string");
|
|
822
824
|
}
|
|
823
|
-
function
|
|
825
|
+
function m(e, t) {
|
|
824
826
|
return t.encode ? t.strict ? Me(e) : encodeURIComponent(e) : e;
|
|
825
827
|
}
|
|
826
828
|
function S(e, t) {
|
|
827
|
-
return t.decode ?
|
|
829
|
+
return t.decode ? _e(e) : e;
|
|
828
830
|
}
|
|
829
831
|
function ne(e) {
|
|
830
832
|
return Array.isArray(e) ? e.sort() : typeof e == "object" ? ne(Object.keys(e)).sort((t, r) => Number(t) - Number(r)).map((t) => e[t]) : e;
|
|
@@ -833,7 +835,7 @@ function ae(e) {
|
|
|
833
835
|
const t = e.indexOf("#");
|
|
834
836
|
return t !== -1 && (e = e.slice(0, t)), e;
|
|
835
837
|
}
|
|
836
|
-
function
|
|
838
|
+
function He(e) {
|
|
837
839
|
let t = "";
|
|
838
840
|
const r = e.indexOf("#");
|
|
839
841
|
return r !== -1 && (t = e.slice(r)), t;
|
|
@@ -846,7 +848,7 @@ function M(e) {
|
|
|
846
848
|
const t = e.indexOf("?");
|
|
847
849
|
return t === -1 ? "" : e.slice(t + 1);
|
|
848
850
|
}
|
|
849
|
-
function
|
|
851
|
+
function z(e, t) {
|
|
850
852
|
t = {
|
|
851
853
|
decode: !0,
|
|
852
854
|
sort: !0,
|
|
@@ -857,26 +859,26 @@ function B(e, t) {
|
|
|
857
859
|
types: /* @__PURE__ */ Object.create(null),
|
|
858
860
|
...t
|
|
859
861
|
}, te(t.arrayFormatSeparator);
|
|
860
|
-
const r =
|
|
862
|
+
const r = Be(t), n = /* @__PURE__ */ Object.create(null);
|
|
861
863
|
if (typeof e != "string" || (e = e.trim().replace(/^[?#&]/, ""), !e))
|
|
862
864
|
return n;
|
|
863
865
|
for (const a of e.split("&")) {
|
|
864
866
|
if (a === "")
|
|
865
867
|
continue;
|
|
866
868
|
const s = t.decode ? a.replaceAll("+", " ") : a;
|
|
867
|
-
let [
|
|
868
|
-
|
|
869
|
+
let [i, o] = re(s, "=");
|
|
870
|
+
i === void 0 && (i = s), o = o === void 0 ? null : ["comma", "separator", "bracket-separator"].includes(t.arrayFormat) ? o : S(o, t), r(S(i, t), o, n);
|
|
869
871
|
}
|
|
870
872
|
for (const [a, s] of Object.entries(n))
|
|
871
873
|
if (typeof s == "object" && s !== null && t.types[a] !== "string")
|
|
872
|
-
for (const [
|
|
873
|
-
const
|
|
874
|
-
s[
|
|
874
|
+
for (const [i, o] of Object.entries(s)) {
|
|
875
|
+
const f = t.types[a] ? t.types[a].replace("[]", "") : void 0;
|
|
876
|
+
s[i] = G(o, t, f);
|
|
875
877
|
}
|
|
876
878
|
else typeof s == "object" && s !== null && t.types[a] === "string" ? n[a] = Object.values(s).join(t.arrayFormatSeparator) : n[a] = G(s, t, t.types[a]);
|
|
877
879
|
return t.sort === !1 ? n : (t.sort === !0 ? Object.keys(n).sort() : Object.keys(n).sort(t.sort)).reduce((a, s) => {
|
|
878
|
-
const
|
|
879
|
-
return a[s] =
|
|
880
|
+
const i = n[s];
|
|
881
|
+
return a[s] = i && typeof i == "object" && !Array.isArray(i) ? ne(i) : i, a;
|
|
880
882
|
}, /* @__PURE__ */ Object.create(null));
|
|
881
883
|
}
|
|
882
884
|
function se(e, t) {
|
|
@@ -889,16 +891,16 @@ function se(e, t) {
|
|
|
889
891
|
arrayFormatSeparator: ",",
|
|
890
892
|
...t
|
|
891
893
|
}, te(t.arrayFormatSeparator);
|
|
892
|
-
const r = (
|
|
893
|
-
for (const [
|
|
894
|
-
r(
|
|
894
|
+
const r = (i) => t.skipNull && Le(e[i]) || t.skipEmptyString && e[i] === "", n = ze(t), a = {};
|
|
895
|
+
for (const [i, o] of Object.entries(e))
|
|
896
|
+
r(i) || (a[i] = o);
|
|
895
897
|
const s = Object.keys(a);
|
|
896
|
-
return t.sort !== !1 && s.sort(t.sort), s.map((
|
|
897
|
-
const
|
|
898
|
-
return
|
|
899
|
-
}).filter((
|
|
898
|
+
return t.sort !== !1 && s.sort(t.sort), s.map((i) => {
|
|
899
|
+
const o = e[i];
|
|
900
|
+
return o === void 0 ? "" : o === null ? m(i, t) : Array.isArray(o) ? o.length === 0 && t.arrayFormat === "bracket-separator" ? m(i, t) + "[]" : o.reduce(n(i), []).join("&") : m(i, t) + "=" + m(o, t);
|
|
901
|
+
}).filter((i) => i.length > 0).join("&");
|
|
900
902
|
}
|
|
901
|
-
function
|
|
903
|
+
function ie(e, t) {
|
|
902
904
|
var a;
|
|
903
905
|
t = {
|
|
904
906
|
decode: !0,
|
|
@@ -907,176 +909,176 @@ function oe(e, t) {
|
|
|
907
909
|
let [r, n] = re(e, "#");
|
|
908
910
|
return r === void 0 && (r = e), {
|
|
909
911
|
url: ((a = r == null ? void 0 : r.split("?")) == null ? void 0 : a[0]) ?? "",
|
|
910
|
-
query:
|
|
912
|
+
query: z(M(e), t),
|
|
911
913
|
...t && t.parseFragmentIdentifier && n ? {
|
|
912
914
|
fragmentIdentifier: S(n, t)
|
|
913
915
|
} : {}
|
|
914
916
|
};
|
|
915
917
|
}
|
|
916
|
-
function
|
|
918
|
+
function oe(e, t) {
|
|
917
919
|
t = {
|
|
918
920
|
encode: !0,
|
|
919
921
|
strict: !0,
|
|
920
|
-
[
|
|
922
|
+
[v]: !0,
|
|
921
923
|
...t
|
|
922
924
|
};
|
|
923
925
|
const r = ae(e.url).split("?")[0] || "", n = M(e.url), a = {
|
|
924
|
-
...
|
|
926
|
+
...z(n, {
|
|
925
927
|
sort: !1
|
|
926
928
|
}),
|
|
927
929
|
...e.query
|
|
928
930
|
};
|
|
929
931
|
let s = se(a, t);
|
|
930
932
|
s && (s = `?${s}`);
|
|
931
|
-
let
|
|
933
|
+
let i = He(e.url);
|
|
932
934
|
if (typeof e.fragmentIdentifier == "string") {
|
|
933
|
-
const
|
|
934
|
-
|
|
935
|
+
const o = new URL(r);
|
|
936
|
+
o.hash = e.fragmentIdentifier, i = t[v] ? o.hash : `#${e.fragmentIdentifier}`;
|
|
935
937
|
}
|
|
936
|
-
return `${r}${s}${
|
|
938
|
+
return `${r}${s}${i}`;
|
|
937
939
|
}
|
|
938
940
|
function ce(e, t, r) {
|
|
939
941
|
r = {
|
|
940
942
|
parseFragmentIdentifier: !0,
|
|
941
|
-
[
|
|
943
|
+
[v]: !1,
|
|
942
944
|
...r
|
|
943
945
|
};
|
|
944
946
|
const {
|
|
945
947
|
url: n,
|
|
946
948
|
query: a,
|
|
947
949
|
fragmentIdentifier: s
|
|
948
|
-
} =
|
|
949
|
-
return
|
|
950
|
+
} = ie(e, r);
|
|
951
|
+
return oe({
|
|
950
952
|
url: n,
|
|
951
953
|
query: qe(a, t),
|
|
952
954
|
fragmentIdentifier: s
|
|
953
955
|
}, r);
|
|
954
956
|
}
|
|
955
|
-
function
|
|
957
|
+
function Ve(e, t, r) {
|
|
956
958
|
const n = Array.isArray(t) ? (a) => !t.includes(a) : (a, s) => !t(a, s);
|
|
957
959
|
return ce(e, n, r);
|
|
958
960
|
}
|
|
959
961
|
const T = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
960
962
|
__proto__: null,
|
|
961
|
-
exclude:
|
|
963
|
+
exclude: Ve,
|
|
962
964
|
extract: M,
|
|
963
|
-
parse:
|
|
964
|
-
parseUrl:
|
|
965
|
+
parse: z,
|
|
966
|
+
parseUrl: ie,
|
|
965
967
|
pick: ce,
|
|
966
968
|
stringify: se,
|
|
967
|
-
stringifyUrl:
|
|
969
|
+
stringifyUrl: oe
|
|
968
970
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
969
971
|
function We(e) {
|
|
970
972
|
const {
|
|
971
973
|
base: t = "/",
|
|
972
974
|
routes: r
|
|
973
|
-
} = e, n =
|
|
975
|
+
} = e, n = j(null, {
|
|
974
976
|
and: {
|
|
975
977
|
serialize: "ignore"
|
|
976
978
|
},
|
|
977
979
|
name: "$history",
|
|
978
|
-
sid: "
|
|
979
|
-
}), a =
|
|
980
|
+
sid: "ftu36z"
|
|
981
|
+
}), a = j([], {
|
|
980
982
|
and: {
|
|
981
983
|
serialize: "ignore"
|
|
982
984
|
},
|
|
983
985
|
name: "$activeRoutes",
|
|
984
|
-
sid: "
|
|
985
|
-
}), s =
|
|
986
|
+
sid: "z30ma4"
|
|
987
|
+
}), s = j({}, {
|
|
986
988
|
name: "$query",
|
|
987
|
-
sid: "
|
|
988
|
-
}),
|
|
989
|
+
sid: "hkri52"
|
|
990
|
+
}), i = j(null, {
|
|
989
991
|
name: "$path",
|
|
990
|
-
sid: "
|
|
991
|
-
}),
|
|
992
|
+
sid: "-zgnqnj"
|
|
993
|
+
}), o = x({
|
|
992
994
|
name: "setHistory",
|
|
993
|
-
sid: "
|
|
994
|
-
}), c = x({
|
|
995
|
-
name: "back",
|
|
996
|
-
sid: "-hekewa"
|
|
995
|
+
sid: "w6xvrg"
|
|
997
996
|
}), f = x({
|
|
997
|
+
name: "back",
|
|
998
|
+
sid: "-4mcm91"
|
|
999
|
+
}), u = x({
|
|
998
1000
|
name: "forward",
|
|
999
|
-
sid: "
|
|
1000
|
-
}),
|
|
1001
|
+
sid: "6nmzsp"
|
|
1002
|
+
}), y = x({
|
|
1001
1003
|
name: "locationUpdated",
|
|
1002
|
-
sid: "
|
|
1003
|
-
}), d = r.map((
|
|
1004
|
-
let
|
|
1005
|
-
const
|
|
1006
|
-
for (
|
|
1007
|
-
|
|
1008
|
-
const g = t === "/" ?
|
|
1004
|
+
sid: "qywvkp"
|
|
1005
|
+
}), d = r.map((l) => {
|
|
1006
|
+
let h = l;
|
|
1007
|
+
const c = [];
|
|
1008
|
+
for (c.unshift(h.internal.path); h.internal.parent; )
|
|
1009
|
+
h = h.internal.parent, h.internal.path !== "/" && c.unshift(h.internal.path);
|
|
1010
|
+
const g = t === "/" ? c.join("") : [t, ...c].join("");
|
|
1009
1011
|
return {
|
|
1010
|
-
route:
|
|
1012
|
+
route: l,
|
|
1011
1013
|
path: g,
|
|
1012
1014
|
toPath: he(g),
|
|
1013
1015
|
fromPath: ge(g)
|
|
1014
1016
|
};
|
|
1015
|
-
}), b =
|
|
1017
|
+
}), b = H({
|
|
1016
1018
|
and: {
|
|
1017
1019
|
source: {
|
|
1018
1020
|
history: n
|
|
1019
1021
|
},
|
|
1020
|
-
effect: async (
|
|
1022
|
+
effect: async (l, h) => {
|
|
1021
1023
|
let {
|
|
1022
|
-
history:
|
|
1023
|
-
} =
|
|
1024
|
+
history: c
|
|
1025
|
+
} = l, {
|
|
1024
1026
|
path: g,
|
|
1025
|
-
query:
|
|
1026
|
-
replace:
|
|
1027
|
-
} =
|
|
1028
|
-
if (!
|
|
1027
|
+
query: P,
|
|
1028
|
+
replace: A
|
|
1029
|
+
} = h;
|
|
1030
|
+
if (!c)
|
|
1029
1031
|
throw new Error("history not found");
|
|
1030
|
-
const
|
|
1032
|
+
const B = {
|
|
1031
1033
|
pathname: g,
|
|
1032
|
-
search: "?".concat(T.stringify(
|
|
1034
|
+
search: "?".concat(T.stringify(P))
|
|
1033
1035
|
};
|
|
1034
|
-
|
|
1036
|
+
A ? c.replace(B) : c.push(B);
|
|
1035
1037
|
}
|
|
1036
1038
|
},
|
|
1037
1039
|
or: {
|
|
1038
1040
|
name: "navigateFx",
|
|
1039
|
-
sid: "
|
|
1041
|
+
sid: "qepxid"
|
|
1040
1042
|
}
|
|
1041
|
-
}), w =
|
|
1042
|
-
const
|
|
1043
|
-
if (
|
|
1044
|
-
pathname:
|
|
1045
|
-
query: T.parse(
|
|
1046
|
-
}), !
|
|
1043
|
+
}), w = N((l) => {
|
|
1044
|
+
const h = ue(y);
|
|
1045
|
+
if (h({
|
|
1046
|
+
pathname: l.location.pathname,
|
|
1047
|
+
query: T.parse(l.location.search)
|
|
1048
|
+
}), !l)
|
|
1047
1049
|
throw new Error();
|
|
1048
|
-
|
|
1050
|
+
l.listen((c) => {
|
|
1049
1051
|
let {
|
|
1050
1052
|
location: g
|
|
1051
|
-
} =
|
|
1052
|
-
|
|
1053
|
+
} = c;
|
|
1054
|
+
h({
|
|
1053
1055
|
pathname: g.pathname,
|
|
1054
1056
|
query: T.parse(g.search)
|
|
1055
1057
|
});
|
|
1056
1058
|
});
|
|
1057
1059
|
}, {
|
|
1058
1060
|
name: "subscribeHistoryFx",
|
|
1059
|
-
sid: "
|
|
1060
|
-
}),
|
|
1061
|
+
sid: "es8v7q"
|
|
1062
|
+
}), p = H({
|
|
1061
1063
|
and: {
|
|
1062
1064
|
source: {
|
|
1063
1065
|
query: s,
|
|
1064
|
-
path:
|
|
1066
|
+
path: i
|
|
1065
1067
|
},
|
|
1066
|
-
effect: async (
|
|
1068
|
+
effect: async (l) => {
|
|
1067
1069
|
let {
|
|
1068
|
-
query:
|
|
1069
|
-
path:
|
|
1070
|
-
} =
|
|
1070
|
+
query: h,
|
|
1071
|
+
path: c
|
|
1072
|
+
} = l;
|
|
1071
1073
|
for (const {
|
|
1072
1074
|
route: g,
|
|
1073
|
-
fromPath:
|
|
1075
|
+
fromPath: P
|
|
1074
1076
|
} of d) {
|
|
1075
|
-
const
|
|
1076
|
-
if (
|
|
1077
|
+
const A = P(c);
|
|
1078
|
+
if (A)
|
|
1077
1079
|
await g.internal.openFx({
|
|
1078
|
-
query:
|
|
1079
|
-
params:
|
|
1080
|
+
query: h,
|
|
1081
|
+
params: A.params,
|
|
1080
1082
|
historyIgnore: !0
|
|
1081
1083
|
});
|
|
1082
1084
|
else {
|
|
@@ -1088,65 +1090,59 @@ function We(e) {
|
|
|
1088
1090
|
},
|
|
1089
1091
|
or: {
|
|
1090
1092
|
name: "openRoutesByPathFx",
|
|
1091
|
-
sid: "
|
|
1093
|
+
sid: "bmwb4p"
|
|
1092
1094
|
}
|
|
1093
1095
|
});
|
|
1094
1096
|
for (const {
|
|
1095
|
-
route:
|
|
1096
|
-
toPath:
|
|
1097
|
+
route: l,
|
|
1098
|
+
toPath: h
|
|
1097
1099
|
} of d)
|
|
1098
1100
|
F({
|
|
1099
1101
|
and: [{
|
|
1100
|
-
clock:
|
|
1102
|
+
clock: l.opened,
|
|
1101
1103
|
source: a,
|
|
1102
|
-
filter: (
|
|
1103
|
-
fn: (
|
|
1104
|
+
filter: (c) => !c.includes(l),
|
|
1105
|
+
fn: (c) => [...c, l],
|
|
1104
1106
|
target: a
|
|
1105
1107
|
}],
|
|
1106
1108
|
or: {
|
|
1107
|
-
sid: "
|
|
1109
|
+
sid: "ff1m4n"
|
|
1108
1110
|
}
|
|
1109
1111
|
}), F({
|
|
1110
1112
|
and: [{
|
|
1111
|
-
clock:
|
|
1112
|
-
filter: (
|
|
1113
|
-
fn:
|
|
1114
|
-
|
|
1115
|
-
params: l,
|
|
1116
|
-
query: g,
|
|
1117
|
-
replace: A
|
|
1118
|
-
} = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {
|
|
1119
|
-
params: {}
|
|
1120
|
-
};
|
|
1113
|
+
clock: l.opened,
|
|
1114
|
+
filter: (c) => !(c != null && c.historyIgnore),
|
|
1115
|
+
fn: (c) => {
|
|
1116
|
+
var g;
|
|
1121
1117
|
return {
|
|
1122
|
-
path:
|
|
1123
|
-
query: g
|
|
1124
|
-
replace:
|
|
1118
|
+
path: h(c && "params" in c ? c.params : void 0),
|
|
1119
|
+
query: (g = c == null ? void 0 : c.query) !== null && g !== void 0 ? g : {},
|
|
1120
|
+
replace: c == null ? void 0 : c.replace
|
|
1125
1121
|
};
|
|
1126
1122
|
},
|
|
1127
1123
|
target: b
|
|
1128
1124
|
}],
|
|
1129
1125
|
or: {
|
|
1130
|
-
sid: "
|
|
1126
|
+
sid: "fuznc4"
|
|
1131
1127
|
}
|
|
1132
1128
|
}), F({
|
|
1133
1129
|
and: [{
|
|
1134
|
-
clock:
|
|
1130
|
+
clock: l.closed,
|
|
1135
1131
|
source: a,
|
|
1136
|
-
fn: (
|
|
1132
|
+
fn: (c) => c.filter((g) => g !== l),
|
|
1137
1133
|
target: a
|
|
1138
1134
|
}],
|
|
1139
1135
|
or: {
|
|
1140
|
-
sid: "
|
|
1136
|
+
sid: "ges8p4"
|
|
1141
1137
|
}
|
|
1142
1138
|
});
|
|
1143
1139
|
return F({
|
|
1144
1140
|
and: [{
|
|
1145
|
-
clock:
|
|
1141
|
+
clock: o,
|
|
1146
1142
|
target: n
|
|
1147
1143
|
}],
|
|
1148
1144
|
or: {
|
|
1149
|
-
sid: "
|
|
1145
|
+
sid: "guq9uv"
|
|
1150
1146
|
}
|
|
1151
1147
|
}), F({
|
|
1152
1148
|
and: [{
|
|
@@ -1155,49 +1151,49 @@ function We(e) {
|
|
|
1155
1151
|
target: w
|
|
1156
1152
|
}],
|
|
1157
1153
|
or: {
|
|
1158
|
-
sid: "
|
|
1154
|
+
sid: "gxh8to"
|
|
1159
1155
|
}
|
|
1160
1156
|
}), F({
|
|
1161
1157
|
and: [{
|
|
1162
|
-
clock:
|
|
1163
|
-
fn: (
|
|
1164
|
-
var
|
|
1158
|
+
clock: y,
|
|
1159
|
+
fn: (l) => {
|
|
1160
|
+
var h;
|
|
1165
1161
|
return {
|
|
1166
|
-
path:
|
|
1167
|
-
query: (
|
|
1162
|
+
path: l.pathname,
|
|
1163
|
+
query: (h = l.query) !== null && h !== void 0 ? h : {}
|
|
1168
1164
|
};
|
|
1169
1165
|
},
|
|
1170
1166
|
target: [le({
|
|
1171
|
-
sid: "-
|
|
1167
|
+
sid: "-38mmc2",
|
|
1172
1168
|
fn: () => de({
|
|
1173
1169
|
targets: {
|
|
1174
|
-
path:
|
|
1170
|
+
path: i,
|
|
1175
1171
|
query: s
|
|
1176
1172
|
}
|
|
1177
1173
|
}),
|
|
1178
1174
|
name: "target",
|
|
1179
1175
|
method: "spread"
|
|
1180
|
-
}),
|
|
1176
|
+
}), p]
|
|
1181
1177
|
}],
|
|
1182
1178
|
or: {
|
|
1183
|
-
sid: "
|
|
1179
|
+
sid: "hcbouf"
|
|
1184
1180
|
}
|
|
1185
1181
|
}), {
|
|
1186
1182
|
$query: s,
|
|
1187
|
-
$path:
|
|
1183
|
+
$path: i,
|
|
1188
1184
|
$activeRoutes: a,
|
|
1189
|
-
back:
|
|
1190
|
-
forward:
|
|
1185
|
+
back: f,
|
|
1186
|
+
forward: u,
|
|
1191
1187
|
routes: r,
|
|
1192
|
-
setHistory:
|
|
1188
|
+
setHistory: o,
|
|
1193
1189
|
mappedRoutes: d,
|
|
1194
1190
|
trackQuery: De(a, s),
|
|
1195
1191
|
"@@unitShape": () => ({
|
|
1196
1192
|
query: s,
|
|
1197
|
-
path:
|
|
1193
|
+
path: i,
|
|
1198
1194
|
activeRoutes: a,
|
|
1199
|
-
onBack:
|
|
1200
|
-
onForward:
|
|
1195
|
+
onBack: f,
|
|
1196
|
+
onForward: u
|
|
1201
1197
|
})
|
|
1202
1198
|
};
|
|
1203
1199
|
}
|