@argon-router/core 0.3.2 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +23 -5
- package/dist/index.js +580 -440
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { createEffect as
|
|
2
|
-
import { spread as
|
|
1
|
+
import { createEffect as V, createStore as _, createEvent as $, sample as x, split as ue, attach as J, scopeBind as Oe, withFactory as xe } from "effector";
|
|
2
|
+
import { spread as $e } from "patronum";
|
|
3
3
|
function Z(e, t) {
|
|
4
4
|
var r = Object.keys(e);
|
|
5
5
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -14,14 +14,14 @@ function H(e) {
|
|
|
14
14
|
for (var t = 1; t < arguments.length; t++) {
|
|
15
15
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
16
16
|
t % 2 ? Z(Object(r), !0).forEach(function(n) {
|
|
17
|
-
|
|
17
|
+
Fe(e, n, r[n]);
|
|
18
18
|
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : Z(Object(r)).forEach(function(n) {
|
|
19
19
|
Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
22
|
return e;
|
|
23
23
|
}
|
|
24
|
-
function
|
|
24
|
+
function Fe(e, t, r) {
|
|
25
25
|
return (t = je(t)) in e ? Object.defineProperty(e, t, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = r, e;
|
|
26
26
|
}
|
|
27
27
|
function je(e) {
|
|
@@ -38,26 +38,26 @@ function Se(e, t) {
|
|
|
38
38
|
}
|
|
39
39
|
return (t === "string" ? String : Number)(e);
|
|
40
40
|
}
|
|
41
|
-
function
|
|
41
|
+
function Ge(e) {
|
|
42
42
|
let t;
|
|
43
|
-
const r =
|
|
43
|
+
const r = V(() => {
|
|
44
44
|
var y;
|
|
45
45
|
return (y = t) === null || y === void 0 ? void 0 : y();
|
|
46
46
|
}, {
|
|
47
47
|
name: "waitForAsyncBundleFx",
|
|
48
48
|
sid: "tw7mq7"
|
|
49
|
-
}), n =
|
|
50
|
-
for (const
|
|
49
|
+
}), n = V(async () => {
|
|
50
|
+
for (const R of (y = e.beforeOpen) !== null && y !== void 0 ? y : []) {
|
|
51
51
|
var y;
|
|
52
|
-
await
|
|
52
|
+
await R();
|
|
53
53
|
}
|
|
54
54
|
}, {
|
|
55
55
|
name: "beforeOpenFx",
|
|
56
56
|
sid: "ls74w9"
|
|
57
|
-
}), a =
|
|
57
|
+
}), a = V(async (y) => {
|
|
58
58
|
await r(), await n();
|
|
59
|
-
const
|
|
60
|
-
return
|
|
59
|
+
const R = e.parent;
|
|
60
|
+
return R && await R.internal.openFx(H(H({}, y ?? {
|
|
61
61
|
params: {}
|
|
62
62
|
}), {}, {
|
|
63
63
|
historyIgnore: !0
|
|
@@ -65,51 +65,51 @@ function We(e) {
|
|
|
65
65
|
}, {
|
|
66
66
|
name: "openFx",
|
|
67
67
|
sid: "-hz9h5i"
|
|
68
|
-
}),
|
|
68
|
+
}), u = _({}, {
|
|
69
69
|
name: "$params",
|
|
70
70
|
sid: "rstqrf"
|
|
71
|
-
}),
|
|
71
|
+
}), s = _(!1, {
|
|
72
72
|
name: "$isOpened",
|
|
73
73
|
sid: "-zgx6q9"
|
|
74
|
-
}),
|
|
74
|
+
}), f = a.pending, w = $({
|
|
75
75
|
name: "open",
|
|
76
76
|
sid: "-cby6lj"
|
|
77
|
-
}),
|
|
77
|
+
}), E = $({
|
|
78
78
|
name: "close",
|
|
79
79
|
sid: "7uwhl1"
|
|
80
|
-
}),
|
|
80
|
+
}), k = $({
|
|
81
81
|
name: "opened",
|
|
82
82
|
sid: "44ryfn"
|
|
83
|
-
}), P =
|
|
83
|
+
}), P = $({
|
|
84
84
|
name: "openedOnServer",
|
|
85
85
|
sid: "-prk6y1"
|
|
86
|
-
}), A =
|
|
86
|
+
}), A = $({
|
|
87
87
|
name: "openedOnClient",
|
|
88
88
|
sid: "-fw2mlz"
|
|
89
|
-
}),
|
|
89
|
+
}), S = $({
|
|
90
90
|
name: "closed",
|
|
91
91
|
sid: "10jxi5"
|
|
92
92
|
});
|
|
93
|
-
|
|
93
|
+
x({
|
|
94
94
|
and: [{
|
|
95
|
-
clock:
|
|
95
|
+
clock: w,
|
|
96
96
|
target: a
|
|
97
97
|
}],
|
|
98
98
|
or: {
|
|
99
99
|
sid: "t7vx9v"
|
|
100
100
|
}
|
|
101
101
|
});
|
|
102
|
-
const
|
|
103
|
-
return
|
|
102
|
+
const v = {};
|
|
103
|
+
return x({
|
|
104
104
|
and: [{
|
|
105
105
|
clock: a.doneData,
|
|
106
|
-
fn: (y) => y && "params" in y ? H({}, y.params) :
|
|
107
|
-
target:
|
|
106
|
+
fn: (y) => y && "params" in y ? H({}, y.params) : v,
|
|
107
|
+
target: u
|
|
108
108
|
}],
|
|
109
109
|
or: {
|
|
110
110
|
sid: "tna5vz"
|
|
111
111
|
}
|
|
112
|
-
}),
|
|
112
|
+
}), ue({
|
|
113
113
|
and: [{
|
|
114
114
|
source: a.doneData,
|
|
115
115
|
match: () => typeof window > "u" ? "server" : "client",
|
|
@@ -121,69 +121,69 @@ function We(e) {
|
|
|
121
121
|
or: {
|
|
122
122
|
sid: "u5fdgw"
|
|
123
123
|
}
|
|
124
|
-
}),
|
|
124
|
+
}), x({
|
|
125
125
|
and: [{
|
|
126
126
|
clock: [A, P],
|
|
127
|
-
target:
|
|
127
|
+
target: k
|
|
128
128
|
}],
|
|
129
129
|
or: {
|
|
130
130
|
sid: "ylqojg"
|
|
131
131
|
}
|
|
132
|
-
}),
|
|
132
|
+
}), x({
|
|
133
133
|
and: [{
|
|
134
|
-
clock:
|
|
134
|
+
clock: k,
|
|
135
135
|
fn: () => !0,
|
|
136
|
-
target:
|
|
136
|
+
target: s
|
|
137
137
|
}],
|
|
138
138
|
or: {
|
|
139
139
|
sid: "yohni9"
|
|
140
140
|
}
|
|
141
|
-
}),
|
|
141
|
+
}), x({
|
|
142
142
|
and: [{
|
|
143
|
-
clock:
|
|
144
|
-
target:
|
|
143
|
+
clock: E,
|
|
144
|
+
target: S
|
|
145
145
|
}],
|
|
146
146
|
or: {
|
|
147
147
|
sid: "z3c3j0"
|
|
148
148
|
}
|
|
149
|
-
}),
|
|
149
|
+
}), x({
|
|
150
150
|
and: [{
|
|
151
|
-
clock:
|
|
151
|
+
clock: S,
|
|
152
152
|
fn: () => !1,
|
|
153
|
-
target:
|
|
153
|
+
target: s
|
|
154
154
|
}],
|
|
155
155
|
or: {
|
|
156
156
|
sid: "z632ht"
|
|
157
157
|
}
|
|
158
158
|
}), {
|
|
159
|
-
$params:
|
|
160
|
-
$isOpened:
|
|
161
|
-
$isPending:
|
|
162
|
-
open:
|
|
163
|
-
closed:
|
|
164
|
-
opened:
|
|
159
|
+
$params: u,
|
|
160
|
+
$isOpened: s,
|
|
161
|
+
$isPending: f,
|
|
162
|
+
open: w,
|
|
163
|
+
closed: S,
|
|
164
|
+
opened: k,
|
|
165
165
|
openedOnClient: A,
|
|
166
166
|
openedOnServer: P,
|
|
167
167
|
internal: H({
|
|
168
|
-
close:
|
|
168
|
+
close: E,
|
|
169
169
|
openFx: a,
|
|
170
170
|
setAsyncImport: (y) => t = y
|
|
171
171
|
}, e),
|
|
172
172
|
"@@unitShape": () => ({
|
|
173
|
-
params:
|
|
174
|
-
isPending:
|
|
175
|
-
isOpened:
|
|
176
|
-
onOpen:
|
|
173
|
+
params: u,
|
|
174
|
+
isPending: f,
|
|
175
|
+
isOpened: s,
|
|
176
|
+
onOpen: w
|
|
177
177
|
})
|
|
178
178
|
};
|
|
179
179
|
}
|
|
180
180
|
var C = {}, ee;
|
|
181
|
-
function
|
|
181
|
+
function ve() {
|
|
182
182
|
if (ee) return C;
|
|
183
183
|
ee = 1, Object.defineProperty(C, "__esModule", {
|
|
184
184
|
value: !0
|
|
185
|
-
}), C.TokenData = void 0, C.parse = P, C.compile = A, C.match = y, C.pathToRegexp =
|
|
186
|
-
const e = "/", t = (
|
|
185
|
+
}), C.TokenData = void 0, C.parse = P, C.compile = A, C.match = y, C.pathToRegexp = R, C.stringify = F;
|
|
186
|
+
const e = "/", t = (c) => c, r = /^[$_\p{ID_Start}]$/u, n = /^[$\u200c\u200d\p{ID_Continue}]$/u, a = "https://git.new/pathToRegexpError", u = {
|
|
187
187
|
// Groups.
|
|
188
188
|
"{": "{",
|
|
189
189
|
"}": "}",
|
|
@@ -196,309 +196,309 @@ function Ee() {
|
|
|
196
196
|
"?": "?",
|
|
197
197
|
"!": "!"
|
|
198
198
|
};
|
|
199
|
-
function c
|
|
200
|
-
return
|
|
199
|
+
function s(c) {
|
|
200
|
+
return c.replace(/[{}()\[\]+?!:*]/g, "\\$&");
|
|
201
201
|
}
|
|
202
|
-
function
|
|
203
|
-
return
|
|
202
|
+
function f(c) {
|
|
203
|
+
return c.replace(/[.+*?^${}()[\]|/\\]/g, "\\$&");
|
|
204
204
|
}
|
|
205
|
-
function*
|
|
206
|
-
const
|
|
207
|
-
let
|
|
205
|
+
function* w(c) {
|
|
206
|
+
const i = [...c];
|
|
207
|
+
let o = 0;
|
|
208
208
|
function p() {
|
|
209
209
|
let l = "";
|
|
210
|
-
if (r.test(
|
|
211
|
-
for (l += o
|
|
212
|
-
l += o
|
|
213
|
-
else if (o
|
|
214
|
-
let d =
|
|
215
|
-
for (;
|
|
216
|
-
if (
|
|
217
|
-
|
|
210
|
+
if (r.test(i[++o]))
|
|
211
|
+
for (l += i[o]; n.test(i[++o]); )
|
|
212
|
+
l += i[o];
|
|
213
|
+
else if (i[o] === '"') {
|
|
214
|
+
let d = o;
|
|
215
|
+
for (; o < i.length; ) {
|
|
216
|
+
if (i[++o] === '"') {
|
|
217
|
+
o++, d = 0;
|
|
218
218
|
break;
|
|
219
219
|
}
|
|
220
|
-
o
|
|
220
|
+
i[o] === "\\" ? l += i[++o] : l += i[o];
|
|
221
221
|
}
|
|
222
222
|
if (d)
|
|
223
223
|
throw new TypeError(`Unterminated quote at ${d}: ${a}`);
|
|
224
224
|
}
|
|
225
225
|
if (!l)
|
|
226
|
-
throw new TypeError(`Missing parameter name at ${
|
|
226
|
+
throw new TypeError(`Missing parameter name at ${o}: ${a}`);
|
|
227
227
|
return l;
|
|
228
228
|
}
|
|
229
|
-
for (;
|
|
230
|
-
const l = o
|
|
229
|
+
for (; o < i.length; ) {
|
|
230
|
+
const l = i[o], d = u[l];
|
|
231
231
|
if (d)
|
|
232
232
|
yield {
|
|
233
233
|
type: d,
|
|
234
|
-
index:
|
|
234
|
+
index: o++,
|
|
235
235
|
value: l
|
|
236
236
|
};
|
|
237
237
|
else if (l === "\\")
|
|
238
238
|
yield {
|
|
239
239
|
type: "ESCAPED",
|
|
240
|
-
index:
|
|
241
|
-
value: o
|
|
240
|
+
index: o++,
|
|
241
|
+
value: i[o++]
|
|
242
242
|
};
|
|
243
243
|
else if (l === ":") {
|
|
244
|
-
const
|
|
244
|
+
const O = p();
|
|
245
245
|
yield {
|
|
246
246
|
type: "PARAM",
|
|
247
|
-
index:
|
|
248
|
-
value:
|
|
247
|
+
index: o,
|
|
248
|
+
value: O
|
|
249
249
|
};
|
|
250
250
|
} else if (l === "*") {
|
|
251
|
-
const
|
|
251
|
+
const O = p();
|
|
252
252
|
yield {
|
|
253
253
|
type: "WILDCARD",
|
|
254
|
-
index:
|
|
255
|
-
value:
|
|
254
|
+
index: o,
|
|
255
|
+
value: O
|
|
256
256
|
};
|
|
257
257
|
} else
|
|
258
258
|
yield {
|
|
259
259
|
type: "CHAR",
|
|
260
|
-
index:
|
|
261
|
-
value: o
|
|
260
|
+
index: o,
|
|
261
|
+
value: i[o++]
|
|
262
262
|
};
|
|
263
263
|
}
|
|
264
264
|
return {
|
|
265
265
|
type: "END",
|
|
266
|
-
index:
|
|
266
|
+
index: o,
|
|
267
267
|
value: ""
|
|
268
268
|
};
|
|
269
269
|
}
|
|
270
|
-
class
|
|
271
|
-
constructor(
|
|
272
|
-
this.tokens =
|
|
270
|
+
class E {
|
|
271
|
+
constructor(i) {
|
|
272
|
+
this.tokens = i;
|
|
273
273
|
}
|
|
274
274
|
peek() {
|
|
275
275
|
if (!this._peek) {
|
|
276
|
-
const
|
|
277
|
-
this._peek =
|
|
276
|
+
const i = this.tokens.next();
|
|
277
|
+
this._peek = i.value;
|
|
278
278
|
}
|
|
279
279
|
return this._peek;
|
|
280
280
|
}
|
|
281
|
-
tryConsume(
|
|
282
|
-
const
|
|
283
|
-
if (
|
|
284
|
-
return this._peek = void 0,
|
|
281
|
+
tryConsume(i) {
|
|
282
|
+
const o = this.peek();
|
|
283
|
+
if (o.type === i)
|
|
284
|
+
return this._peek = void 0, o.value;
|
|
285
285
|
}
|
|
286
|
-
consume(
|
|
287
|
-
const
|
|
288
|
-
if (
|
|
286
|
+
consume(i) {
|
|
287
|
+
const o = this.tryConsume(i);
|
|
288
|
+
if (o !== void 0) return o;
|
|
289
289
|
const {
|
|
290
290
|
type: p,
|
|
291
291
|
index: l
|
|
292
292
|
} = this.peek();
|
|
293
|
-
throw new TypeError(`Unexpected ${p} at ${l}, expected ${
|
|
293
|
+
throw new TypeError(`Unexpected ${p} at ${l}, expected ${i}: ${a}`);
|
|
294
294
|
}
|
|
295
295
|
text() {
|
|
296
|
-
let
|
|
297
|
-
for (;
|
|
298
|
-
|
|
299
|
-
return
|
|
296
|
+
let i = "", o;
|
|
297
|
+
for (; o = this.tryConsume("CHAR") || this.tryConsume("ESCAPED"); )
|
|
298
|
+
i += o;
|
|
299
|
+
return i;
|
|
300
300
|
}
|
|
301
301
|
}
|
|
302
|
-
class
|
|
303
|
-
constructor(
|
|
304
|
-
this.tokens =
|
|
302
|
+
class k {
|
|
303
|
+
constructor(i) {
|
|
304
|
+
this.tokens = i;
|
|
305
305
|
}
|
|
306
306
|
}
|
|
307
|
-
C.TokenData =
|
|
308
|
-
function P(
|
|
307
|
+
C.TokenData = k;
|
|
308
|
+
function P(c, i = {}) {
|
|
309
309
|
const {
|
|
310
|
-
encodePath:
|
|
311
|
-
} =
|
|
312
|
-
function l(
|
|
313
|
-
const
|
|
310
|
+
encodePath: o = t
|
|
311
|
+
} = i, p = new E(w(c));
|
|
312
|
+
function l(O) {
|
|
313
|
+
const g = [];
|
|
314
314
|
for (; ; ) {
|
|
315
315
|
const N = p.text();
|
|
316
|
-
N &&
|
|
316
|
+
N && g.push({
|
|
317
317
|
type: "text",
|
|
318
|
-
value:
|
|
318
|
+
value: o(N)
|
|
319
319
|
});
|
|
320
|
-
const
|
|
321
|
-
if (
|
|
322
|
-
|
|
320
|
+
const D = p.tryConsume("PARAM");
|
|
321
|
+
if (D) {
|
|
322
|
+
g.push({
|
|
323
323
|
type: "param",
|
|
324
|
-
name:
|
|
324
|
+
name: D
|
|
325
325
|
});
|
|
326
326
|
continue;
|
|
327
327
|
}
|
|
328
|
-
const
|
|
329
|
-
if (
|
|
330
|
-
|
|
328
|
+
const B = p.tryConsume("WILDCARD");
|
|
329
|
+
if (B) {
|
|
330
|
+
g.push({
|
|
331
331
|
type: "wildcard",
|
|
332
|
-
name:
|
|
332
|
+
name: B
|
|
333
333
|
});
|
|
334
334
|
continue;
|
|
335
335
|
}
|
|
336
336
|
if (p.tryConsume("{")) {
|
|
337
|
-
|
|
337
|
+
g.push({
|
|
338
338
|
type: "group",
|
|
339
339
|
tokens: l("}")
|
|
340
340
|
});
|
|
341
341
|
continue;
|
|
342
342
|
}
|
|
343
|
-
return p.consume(
|
|
343
|
+
return p.consume(O), g;
|
|
344
344
|
}
|
|
345
345
|
}
|
|
346
346
|
const d = l("END");
|
|
347
|
-
return new
|
|
347
|
+
return new k(d);
|
|
348
348
|
}
|
|
349
|
-
function A(
|
|
349
|
+
function A(c, i = {}) {
|
|
350
350
|
const {
|
|
351
|
-
encode:
|
|
351
|
+
encode: o = encodeURIComponent,
|
|
352
352
|
delimiter: p = e
|
|
353
|
-
} =
|
|
354
|
-
return function(
|
|
355
|
-
const [N, ...
|
|
356
|
-
if (
|
|
357
|
-
throw new TypeError(`Missing parameters: ${
|
|
353
|
+
} = i, l = c instanceof k ? c : P(c, i), d = S(l.tokens, p, o);
|
|
354
|
+
return function(g = {}) {
|
|
355
|
+
const [N, ...D] = d(g);
|
|
356
|
+
if (D.length)
|
|
357
|
+
throw new TypeError(`Missing parameters: ${D.join(", ")}`);
|
|
358
358
|
return N;
|
|
359
359
|
};
|
|
360
360
|
}
|
|
361
|
-
function
|
|
362
|
-
const p =
|
|
361
|
+
function S(c, i, o) {
|
|
362
|
+
const p = c.map((l) => v(l, i, o));
|
|
363
363
|
return (l) => {
|
|
364
364
|
const d = [""];
|
|
365
|
-
for (const
|
|
366
|
-
const [
|
|
367
|
-
d[0] +=
|
|
365
|
+
for (const O of p) {
|
|
366
|
+
const [g, ...N] = O(l);
|
|
367
|
+
d[0] += g, d.push(...N);
|
|
368
368
|
}
|
|
369
369
|
return d;
|
|
370
370
|
};
|
|
371
371
|
}
|
|
372
|
-
function
|
|
373
|
-
if (
|
|
374
|
-
if (
|
|
375
|
-
const l =
|
|
372
|
+
function v(c, i, o) {
|
|
373
|
+
if (c.type === "text") return () => [c.value];
|
|
374
|
+
if (c.type === "group") {
|
|
375
|
+
const l = S(c.tokens, i, o);
|
|
376
376
|
return (d) => {
|
|
377
|
-
const [
|
|
378
|
-
return
|
|
377
|
+
const [O, ...g] = l(d);
|
|
378
|
+
return g.length ? [""] : [O];
|
|
379
379
|
};
|
|
380
380
|
}
|
|
381
|
-
const p =
|
|
382
|
-
return
|
|
383
|
-
const d = l[
|
|
384
|
-
if (d == null) return ["",
|
|
381
|
+
const p = o || t;
|
|
382
|
+
return c.type === "wildcard" && o !== !1 ? (l) => {
|
|
383
|
+
const d = l[c.name];
|
|
384
|
+
if (d == null) return ["", c.name];
|
|
385
385
|
if (!Array.isArray(d) || d.length === 0)
|
|
386
|
-
throw new TypeError(`Expected "${
|
|
387
|
-
return [d.map((
|
|
388
|
-
if (typeof
|
|
389
|
-
throw new TypeError(`Expected "${
|
|
390
|
-
return p(
|
|
391
|
-
}).join(
|
|
386
|
+
throw new TypeError(`Expected "${c.name}" to be a non-empty array`);
|
|
387
|
+
return [d.map((O, g) => {
|
|
388
|
+
if (typeof O != "string")
|
|
389
|
+
throw new TypeError(`Expected "${c.name}/${g}" to be a string`);
|
|
390
|
+
return p(O);
|
|
391
|
+
}).join(i)];
|
|
392
392
|
} : (l) => {
|
|
393
|
-
const d = l[
|
|
394
|
-
if (d == null) return ["",
|
|
393
|
+
const d = l[c.name];
|
|
394
|
+
if (d == null) return ["", c.name];
|
|
395
395
|
if (typeof d != "string")
|
|
396
|
-
throw new TypeError(`Expected "${
|
|
396
|
+
throw new TypeError(`Expected "${c.name}" to be a string`);
|
|
397
397
|
return [p(d)];
|
|
398
398
|
};
|
|
399
399
|
}
|
|
400
|
-
function y(
|
|
400
|
+
function y(c, i = {}) {
|
|
401
401
|
const {
|
|
402
|
-
decode:
|
|
402
|
+
decode: o = decodeURIComponent,
|
|
403
403
|
delimiter: p = e
|
|
404
|
-
} =
|
|
404
|
+
} = i, {
|
|
405
405
|
regexp: l,
|
|
406
406
|
keys: d
|
|
407
|
-
} =
|
|
407
|
+
} = R(c, i), O = d.map((g) => o === !1 ? t : g.type === "param" ? o : (N) => N.split(p).map(o));
|
|
408
408
|
return function(N) {
|
|
409
|
-
const
|
|
410
|
-
if (!
|
|
411
|
-
const
|
|
412
|
-
for (let L = 1; L <
|
|
413
|
-
if (
|
|
414
|
-
const M = d[L - 1],
|
|
415
|
-
|
|
409
|
+
const D = l.exec(N);
|
|
410
|
+
if (!D) return !1;
|
|
411
|
+
const B = D[0], z = /* @__PURE__ */ Object.create(null);
|
|
412
|
+
for (let L = 1; L < D.length; L++) {
|
|
413
|
+
if (D[L] === void 0) continue;
|
|
414
|
+
const M = d[L - 1], K = O[L - 1];
|
|
415
|
+
z[M.name] = K(D[L]);
|
|
416
416
|
}
|
|
417
417
|
return {
|
|
418
|
-
path:
|
|
419
|
-
params:
|
|
418
|
+
path: B,
|
|
419
|
+
params: z
|
|
420
420
|
};
|
|
421
421
|
};
|
|
422
422
|
}
|
|
423
|
-
function
|
|
423
|
+
function R(c, i = {}) {
|
|
424
424
|
const {
|
|
425
|
-
delimiter:
|
|
425
|
+
delimiter: o = e,
|
|
426
426
|
end: p = !0,
|
|
427
427
|
sensitive: l = !1,
|
|
428
428
|
trailing: d = !0
|
|
429
|
-
} =
|
|
429
|
+
} = i, O = [], g = [], N = l ? "" : "i", B = (Array.isArray(c) ? c : [c]).map((M) => M instanceof k ? M : P(M, i));
|
|
430
430
|
for (const {
|
|
431
431
|
tokens: M
|
|
432
|
-
} of
|
|
433
|
-
for (const
|
|
434
|
-
const
|
|
435
|
-
|
|
432
|
+
} of B)
|
|
433
|
+
for (const K of h(M, 0, [])) {
|
|
434
|
+
const we = b(K, o, O);
|
|
435
|
+
g.push(we);
|
|
436
436
|
}
|
|
437
|
-
let
|
|
438
|
-
return d && (
|
|
439
|
-
regexp: new RegExp(
|
|
440
|
-
keys:
|
|
437
|
+
let z = `^(?:${g.join("|")})`;
|
|
438
|
+
return d && (z += `(?:${f(o)}$)?`), z += p ? "$" : `(?=${f(o)}|$)`, {
|
|
439
|
+
regexp: new RegExp(z, N),
|
|
440
|
+
keys: O
|
|
441
441
|
};
|
|
442
442
|
}
|
|
443
|
-
function*
|
|
444
|
-
if (
|
|
445
|
-
return yield
|
|
446
|
-
const p = i
|
|
443
|
+
function* h(c, i, o) {
|
|
444
|
+
if (i === c.length)
|
|
445
|
+
return yield o;
|
|
446
|
+
const p = c[i];
|
|
447
447
|
if (p.type === "group") {
|
|
448
|
-
const l =
|
|
449
|
-
for (const d of
|
|
450
|
-
yield*
|
|
448
|
+
const l = o.slice();
|
|
449
|
+
for (const d of h(p.tokens, 0, l))
|
|
450
|
+
yield* h(c, i + 1, d);
|
|
451
451
|
} else
|
|
452
|
-
|
|
453
|
-
yield*
|
|
452
|
+
o.push(p);
|
|
453
|
+
yield* h(c, i + 1, o);
|
|
454
454
|
}
|
|
455
|
-
function b(i, o
|
|
455
|
+
function b(c, i, o) {
|
|
456
456
|
let p = "", l = "", d = !0;
|
|
457
|
-
for (let
|
|
458
|
-
const
|
|
459
|
-
if (
|
|
460
|
-
p +=
|
|
457
|
+
for (let O = 0; O < c.length; O++) {
|
|
458
|
+
const g = c[O];
|
|
459
|
+
if (g.type === "text") {
|
|
460
|
+
p += f(g.value), l += g.value, d || (d = g.value.includes(i));
|
|
461
461
|
continue;
|
|
462
462
|
}
|
|
463
|
-
if (
|
|
463
|
+
if (g.type === "param" || g.type === "wildcard") {
|
|
464
464
|
if (!d && !l)
|
|
465
|
-
throw new TypeError(`Missing text after "${
|
|
466
|
-
|
|
465
|
+
throw new TypeError(`Missing text after "${g.name}": ${a}`);
|
|
466
|
+
g.type === "param" ? p += `(${m(i, d ? "" : l)}+)` : p += "([\\s\\S]+)", o.push(g), l = "", d = !1;
|
|
467
467
|
continue;
|
|
468
468
|
}
|
|
469
469
|
}
|
|
470
470
|
return p;
|
|
471
471
|
}
|
|
472
|
-
function m(
|
|
473
|
-
return
|
|
472
|
+
function m(c, i) {
|
|
473
|
+
return i.length < 2 ? c.length < 2 ? `[^${f(c + i)}]` : `(?:(?!${f(c)})[^${f(i)}])` : c.length < 2 ? `(?:(?!${f(i)})[^${f(c)}])` : `(?:(?!${f(i)}|${f(c)})[\\s\\S])`;
|
|
474
474
|
}
|
|
475
|
-
function
|
|
476
|
-
return
|
|
477
|
-
if (
|
|
478
|
-
if (
|
|
479
|
-
return `{${
|
|
480
|
-
const
|
|
481
|
-
if (
|
|
482
|
-
if (
|
|
483
|
-
throw new TypeError(`Unexpected token: ${
|
|
475
|
+
function F(c) {
|
|
476
|
+
return c.tokens.map(function i(o, p, l) {
|
|
477
|
+
if (o.type === "text") return s(o.value);
|
|
478
|
+
if (o.type === "group")
|
|
479
|
+
return `{${o.tokens.map(i).join("")}}`;
|
|
480
|
+
const O = q(o.name) && I(l[p + 1]) ? o.name : JSON.stringify(o.name);
|
|
481
|
+
if (o.type === "param") return `:${O}`;
|
|
482
|
+
if (o.type === "wildcard") return `*${O}`;
|
|
483
|
+
throw new TypeError(`Unexpected token: ${o}`);
|
|
484
484
|
}).join("");
|
|
485
485
|
}
|
|
486
|
-
function
|
|
487
|
-
const [
|
|
488
|
-
return r.test(
|
|
486
|
+
function q(c) {
|
|
487
|
+
const [i, ...o] = c;
|
|
488
|
+
return r.test(i) ? o.every((p) => n.test(p)) : !1;
|
|
489
489
|
}
|
|
490
|
-
function I(
|
|
491
|
-
return (
|
|
490
|
+
function I(c) {
|
|
491
|
+
return (c == null ? void 0 : c.type) !== "text" ? !0 : !n.test(c.value[0]);
|
|
492
492
|
}
|
|
493
493
|
return C;
|
|
494
494
|
}
|
|
495
|
-
var re =
|
|
496
|
-
const
|
|
497
|
-
any:
|
|
498
|
-
number:
|
|
499
|
-
string:
|
|
500
|
-
array:
|
|
501
|
-
boolean:
|
|
495
|
+
var re = ve();
|
|
496
|
+
const Ee = Symbol("any"), ke = Symbol("number"), Pe = Symbol("string"), Ae = Symbol("array"), Re = Symbol("boolean"), T = {
|
|
497
|
+
any: Ee,
|
|
498
|
+
number: ke,
|
|
499
|
+
string: Pe,
|
|
500
|
+
array: Ae,
|
|
501
|
+
boolean: Re
|
|
502
502
|
};
|
|
503
503
|
function te(e, t) {
|
|
504
504
|
for (const r of e)
|
|
@@ -563,28 +563,28 @@ function ne(e, t) {
|
|
|
563
563
|
}
|
|
564
564
|
return !0;
|
|
565
565
|
}
|
|
566
|
-
function
|
|
566
|
+
function Ne(e, t) {
|
|
567
567
|
const r = {};
|
|
568
568
|
for (const n in t) {
|
|
569
|
-
const a = t[n],
|
|
569
|
+
const a = t[n], u = e[n];
|
|
570
570
|
if (Array.isArray(a)) {
|
|
571
|
-
const
|
|
572
|
-
r[n] =
|
|
571
|
+
const s = e[n];
|
|
572
|
+
r[n] = s;
|
|
573
573
|
continue;
|
|
574
574
|
}
|
|
575
575
|
switch (typeof a) {
|
|
576
576
|
case "number": {
|
|
577
|
-
r[n] = isNaN(parseInt(
|
|
577
|
+
r[n] = isNaN(parseInt(u)) ? parseFloat(u) : parseInt(u);
|
|
578
578
|
break;
|
|
579
579
|
}
|
|
580
580
|
case "object": {
|
|
581
|
-
r[n] = JSON.parse(
|
|
581
|
+
r[n] = JSON.parse(u);
|
|
582
582
|
break;
|
|
583
583
|
}
|
|
584
584
|
case "string":
|
|
585
|
-
r[n] =
|
|
585
|
+
r[n] = u;
|
|
586
586
|
case "boolean": {
|
|
587
|
-
r[n] =
|
|
587
|
+
r[n] = u === "1" || u === "true";
|
|
588
588
|
break;
|
|
589
589
|
}
|
|
590
590
|
}
|
|
@@ -596,13 +596,13 @@ function Re(e, t) {
|
|
|
596
596
|
break;
|
|
597
597
|
}
|
|
598
598
|
case T.number: {
|
|
599
|
-
const
|
|
600
|
-
r[n] = isNaN(parseInt(
|
|
599
|
+
const s = e[n];
|
|
600
|
+
r[n] = isNaN(parseInt(s)) ? parseFloat(s) : parseInt(s);
|
|
601
601
|
break;
|
|
602
602
|
}
|
|
603
603
|
case T.boolean: {
|
|
604
|
-
const
|
|
605
|
-
r[n] =
|
|
604
|
+
const s = e[n];
|
|
605
|
+
r[n] = s === "1" || s === "true";
|
|
606
606
|
break;
|
|
607
607
|
}
|
|
608
608
|
}
|
|
@@ -616,97 +616,97 @@ function De(e) {
|
|
|
616
616
|
$query: n,
|
|
617
617
|
navigateFx: a
|
|
618
618
|
} = e;
|
|
619
|
-
return (
|
|
619
|
+
return (u) => {
|
|
620
620
|
const {
|
|
621
|
-
parameters:
|
|
622
|
-
forRoutes:
|
|
623
|
-
} =
|
|
621
|
+
parameters: s,
|
|
622
|
+
forRoutes: f
|
|
623
|
+
} = u, w = _(!1, {
|
|
624
624
|
name: "$entered",
|
|
625
625
|
sid: "jh7pkx"
|
|
626
|
-
}),
|
|
626
|
+
}), E = $({
|
|
627
627
|
name: "entered",
|
|
628
628
|
sid: "-savym4"
|
|
629
|
-
}),
|
|
629
|
+
}), k = $({
|
|
630
630
|
name: "exited",
|
|
631
631
|
sid: "m5ggn3"
|
|
632
|
-
}), P =
|
|
632
|
+
}), P = $({
|
|
633
633
|
name: "exit",
|
|
634
634
|
sid: "-bgcxp1"
|
|
635
|
-
}), A =
|
|
635
|
+
}), A = $({
|
|
636
636
|
name: "changeEntered",
|
|
637
637
|
sid: "-2ei1v0"
|
|
638
638
|
});
|
|
639
|
-
return
|
|
639
|
+
return x({
|
|
640
640
|
and: [{
|
|
641
641
|
clock: A,
|
|
642
|
-
target:
|
|
642
|
+
target: w
|
|
643
643
|
}],
|
|
644
644
|
or: {
|
|
645
645
|
sid: "-hckvl5"
|
|
646
646
|
}
|
|
647
|
-
}),
|
|
647
|
+
}), x({
|
|
648
648
|
and: [{
|
|
649
649
|
source: {
|
|
650
650
|
activeRoutes: t,
|
|
651
651
|
query: n
|
|
652
652
|
},
|
|
653
|
-
filter: (
|
|
653
|
+
filter: (S) => {
|
|
654
654
|
let {
|
|
655
|
-
activeRoutes:
|
|
655
|
+
activeRoutes: v,
|
|
656
656
|
query: y
|
|
657
|
-
} =
|
|
658
|
-
return (!
|
|
657
|
+
} = S;
|
|
658
|
+
return (!f || te(f, v)) && ne(y, s);
|
|
659
659
|
},
|
|
660
|
-
fn: (
|
|
660
|
+
fn: (S) => {
|
|
661
661
|
let {
|
|
662
|
-
query:
|
|
663
|
-
} =
|
|
664
|
-
return
|
|
662
|
+
query: v
|
|
663
|
+
} = S;
|
|
664
|
+
return Ne(v, s);
|
|
665
665
|
},
|
|
666
|
-
target: [
|
|
666
|
+
target: [E, A.prepend(() => !0)]
|
|
667
667
|
}],
|
|
668
668
|
or: {
|
|
669
669
|
sid: "-h9twmc"
|
|
670
670
|
}
|
|
671
|
-
}),
|
|
671
|
+
}), x({
|
|
672
672
|
and: [{
|
|
673
673
|
source: {
|
|
674
674
|
activeRoutes: t,
|
|
675
675
|
query: n,
|
|
676
|
-
entered:
|
|
676
|
+
entered: w
|
|
677
677
|
},
|
|
678
|
-
filter: (
|
|
678
|
+
filter: (S) => {
|
|
679
679
|
let {
|
|
680
|
-
activeRoutes:
|
|
680
|
+
activeRoutes: v,
|
|
681
681
|
query: y,
|
|
682
|
-
entered:
|
|
683
|
-
} =
|
|
684
|
-
return
|
|
682
|
+
entered: R
|
|
683
|
+
} = S;
|
|
684
|
+
return R && !((!f || te(f, v)) && ne(y, s));
|
|
685
685
|
},
|
|
686
|
-
target: [
|
|
686
|
+
target: [k.prepend(() => {
|
|
687
687
|
}), A.prepend(() => !1)]
|
|
688
688
|
}],
|
|
689
689
|
or: {
|
|
690
690
|
sid: "-gtc2ti"
|
|
691
691
|
}
|
|
692
|
-
}),
|
|
692
|
+
}), x({
|
|
693
693
|
and: [{
|
|
694
694
|
clock: P,
|
|
695
695
|
source: {
|
|
696
696
|
path: r,
|
|
697
697
|
query: n
|
|
698
698
|
},
|
|
699
|
-
fn: (
|
|
699
|
+
fn: (S, v) => {
|
|
700
700
|
let {
|
|
701
701
|
path: y,
|
|
702
|
-
query:
|
|
703
|
-
} =
|
|
704
|
-
if (
|
|
705
|
-
const
|
|
706
|
-
for (const b of
|
|
707
|
-
|
|
702
|
+
query: R
|
|
703
|
+
} = S;
|
|
704
|
+
if (v && v.ignoreParams) {
|
|
705
|
+
const h = {};
|
|
706
|
+
for (const b of v.ignoreParams)
|
|
707
|
+
R[b] && (h[b] = R[b]);
|
|
708
708
|
return {
|
|
709
|
-
query:
|
|
709
|
+
query: h,
|
|
710
710
|
path: y
|
|
711
711
|
};
|
|
712
712
|
}
|
|
@@ -721,8 +721,8 @@ function De(e) {
|
|
|
721
721
|
sid: "-fyjlla"
|
|
722
722
|
}
|
|
723
723
|
}), {
|
|
724
|
-
entered:
|
|
725
|
-
exited:
|
|
724
|
+
entered: E,
|
|
725
|
+
exited: k,
|
|
726
726
|
exit: P
|
|
727
727
|
};
|
|
728
728
|
};
|
|
@@ -790,13 +790,13 @@ function Ue(e, t) {
|
|
|
790
790
|
for (const n of Reflect.ownKeys(e)) {
|
|
791
791
|
const a = Object.getOwnPropertyDescriptor(e, n);
|
|
792
792
|
if (a.enumerable) {
|
|
793
|
-
const
|
|
794
|
-
t(n,
|
|
793
|
+
const u = e[n];
|
|
794
|
+
t(n, u, e) && Object.defineProperty(r, n, a);
|
|
795
795
|
}
|
|
796
796
|
}
|
|
797
797
|
return r;
|
|
798
798
|
}
|
|
799
|
-
function
|
|
799
|
+
function le(e, t) {
|
|
800
800
|
if (!(typeof e == "string" && typeof t == "string"))
|
|
801
801
|
throw new TypeError("Expected the arguments to be of type `string`");
|
|
802
802
|
if (e === "" || t === "")
|
|
@@ -805,28 +805,28 @@ function ue(e, t) {
|
|
|
805
805
|
return r === -1 ? [] : [e.slice(0, r), e.slice(r + t.length)];
|
|
806
806
|
}
|
|
807
807
|
const _e = (e) => e == null, qe = (e) => encodeURIComponent(e).replaceAll(/[!'()*]/g, (t) => `%${t.charCodeAt(0).toString(16).toUpperCase()}`), G = Symbol("encodeFragmentIdentifier");
|
|
808
|
-
function
|
|
808
|
+
function ze(e) {
|
|
809
809
|
switch (e.arrayFormat) {
|
|
810
810
|
case "index":
|
|
811
811
|
return (t) => (r, n) => {
|
|
812
812
|
const a = r.length;
|
|
813
|
-
return n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [
|
|
813
|
+
return n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [j(t, e), "[", a, "]"].join("")] : [...r, [j(t, e), "[", j(a, e), "]=", j(n, e)].join("")];
|
|
814
814
|
};
|
|
815
815
|
case "bracket":
|
|
816
|
-
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [
|
|
816
|
+
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [j(t, e), "[]"].join("")] : [...r, [j(t, e), "[]=", j(n, e)].join("")];
|
|
817
817
|
case "colon-list-separator":
|
|
818
|
-
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [
|
|
818
|
+
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, [j(t, e), ":list="].join("")] : [...r, [j(t, e), ":list=", j(n, e)].join("")];
|
|
819
819
|
case "comma":
|
|
820
820
|
case "separator":
|
|
821
821
|
case "bracket-separator": {
|
|
822
822
|
const t = e.arrayFormat === "bracket-separator" ? "[]=" : "=";
|
|
823
|
-
return (r) => (n, a) => a === void 0 || e.skipNull && a === null || e.skipEmptyString && a === "" ? n : (a = a === null ? "" : a, n.length === 0 ? [[
|
|
823
|
+
return (r) => (n, a) => a === void 0 || e.skipNull && a === null || e.skipEmptyString && a === "" ? n : (a = a === null ? "" : a, n.length === 0 ? [[j(r, e), t, j(a, e)].join("")] : [[n, j(a, e)].join(e.arrayFormatSeparator)]);
|
|
824
824
|
}
|
|
825
825
|
default:
|
|
826
|
-
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r,
|
|
826
|
+
return (t) => (r, n) => n === void 0 || e.skipNull && n === null || e.skipEmptyString && n === "" ? r : n === null ? [...r, j(t, e)] : [...r, [j(t, e), "=", j(n, e)].join("")];
|
|
827
827
|
}
|
|
828
828
|
}
|
|
829
|
-
function
|
|
829
|
+
function Le(e) {
|
|
830
830
|
let t;
|
|
831
831
|
switch (e.arrayFormat) {
|
|
832
832
|
case "index":
|
|
@@ -864,24 +864,24 @@ function Me(e) {
|
|
|
864
864
|
case "comma":
|
|
865
865
|
case "separator":
|
|
866
866
|
return (r, n, a) => {
|
|
867
|
-
const
|
|
868
|
-
n =
|
|
869
|
-
const
|
|
870
|
-
a[r] =
|
|
867
|
+
const u = typeof n == "string" && n.includes(e.arrayFormatSeparator), s = typeof n == "string" && !u && U(n, e).includes(e.arrayFormatSeparator);
|
|
868
|
+
n = s ? U(n, e) : n;
|
|
869
|
+
const f = u || s ? n.split(e.arrayFormatSeparator).map((w) => U(w, e)) : n === null ? n : U(n, e);
|
|
870
|
+
a[r] = f;
|
|
871
871
|
};
|
|
872
872
|
case "bracket-separator":
|
|
873
873
|
return (r, n, a) => {
|
|
874
|
-
const
|
|
875
|
-
if (r = r.replace(/\[]$/, ""), !
|
|
874
|
+
const u = /(\[])$/.test(r);
|
|
875
|
+
if (r = r.replace(/\[]$/, ""), !u) {
|
|
876
876
|
a[r] = n && U(n, e);
|
|
877
877
|
return;
|
|
878
878
|
}
|
|
879
|
-
const
|
|
879
|
+
const s = n === null ? [] : U(n, e).split(e.arrayFormatSeparator);
|
|
880
880
|
if (a[r] === void 0) {
|
|
881
|
-
a[r] =
|
|
881
|
+
a[r] = s;
|
|
882
882
|
return;
|
|
883
883
|
}
|
|
884
|
-
a[r] = [...a[r], ...
|
|
884
|
+
a[r] = [...a[r], ...s];
|
|
885
885
|
};
|
|
886
886
|
default:
|
|
887
887
|
return (r, n, a) => {
|
|
@@ -893,24 +893,24 @@ function Me(e) {
|
|
|
893
893
|
};
|
|
894
894
|
}
|
|
895
895
|
}
|
|
896
|
-
function
|
|
896
|
+
function de(e) {
|
|
897
897
|
if (typeof e != "string" || e.length !== 1)
|
|
898
898
|
throw new TypeError("arrayFormatSeparator must be single character string");
|
|
899
899
|
}
|
|
900
|
-
function
|
|
900
|
+
function j(e, t) {
|
|
901
901
|
return t.encode ? t.strict ? qe(e) : encodeURIComponent(e) : e;
|
|
902
902
|
}
|
|
903
903
|
function U(e, t) {
|
|
904
904
|
return t.decode ? Te(e) : e;
|
|
905
905
|
}
|
|
906
|
-
function de(e) {
|
|
907
|
-
return Array.isArray(e) ? e.sort() : typeof e == "object" ? de(Object.keys(e)).sort((t, r) => Number(t) - Number(r)).map((t) => e[t]) : e;
|
|
908
|
-
}
|
|
909
906
|
function pe(e) {
|
|
907
|
+
return Array.isArray(e) ? e.sort() : typeof e == "object" ? pe(Object.keys(e)).sort((t, r) => Number(t) - Number(r)).map((t) => e[t]) : e;
|
|
908
|
+
}
|
|
909
|
+
function me(e) {
|
|
910
910
|
const t = e.indexOf("#");
|
|
911
911
|
return t !== -1 && (e = e.slice(0, t)), e;
|
|
912
912
|
}
|
|
913
|
-
function
|
|
913
|
+
function Me(e) {
|
|
914
914
|
let t = "";
|
|
915
915
|
const r = e.indexOf("#");
|
|
916
916
|
return r !== -1 && (t = e.slice(r)), t;
|
|
@@ -919,7 +919,7 @@ function oe(e, t, r) {
|
|
|
919
919
|
return r === "string" && typeof e == "string" ? e : typeof r == "function" && typeof e == "string" ? r(e) : t.parseBooleans && e !== null && (e.toLowerCase() === "true" || e.toLowerCase() === "false") ? e.toLowerCase() === "true" : r === "number" && !Number.isNaN(Number(e)) && typeof e == "string" && e.trim() !== "" || t.parseNumbers && !Number.isNaN(Number(e)) && typeof e == "string" && e.trim() !== "" ? Number(e) : e;
|
|
920
920
|
}
|
|
921
921
|
function X(e) {
|
|
922
|
-
e =
|
|
922
|
+
e = me(e);
|
|
923
923
|
const t = e.indexOf("?");
|
|
924
924
|
return t === -1 ? "" : e.slice(t + 1);
|
|
925
925
|
}
|
|
@@ -933,30 +933,30 @@ function Y(e, t) {
|
|
|
933
933
|
parseBooleans: !1,
|
|
934
934
|
types: /* @__PURE__ */ Object.create(null),
|
|
935
935
|
...t
|
|
936
|
-
},
|
|
937
|
-
const r =
|
|
936
|
+
}, de(t.arrayFormatSeparator);
|
|
937
|
+
const r = Le(t), n = /* @__PURE__ */ Object.create(null);
|
|
938
938
|
if (typeof e != "string" || (e = e.trim().replace(/^[?#&]/, ""), !e))
|
|
939
939
|
return n;
|
|
940
940
|
for (const a of e.split("&")) {
|
|
941
941
|
if (a === "")
|
|
942
942
|
continue;
|
|
943
|
-
const
|
|
944
|
-
let [
|
|
945
|
-
|
|
943
|
+
const u = t.decode ? a.replaceAll("+", " ") : a;
|
|
944
|
+
let [s, f] = le(u, "=");
|
|
945
|
+
s === void 0 && (s = u), f = f === void 0 ? null : ["comma", "separator", "bracket-separator"].includes(t.arrayFormat) ? f : U(f, t), r(U(s, t), f, n);
|
|
946
946
|
}
|
|
947
|
-
for (const [a,
|
|
948
|
-
if (typeof
|
|
949
|
-
for (const [
|
|
950
|
-
const
|
|
951
|
-
|
|
947
|
+
for (const [a, u] of Object.entries(n))
|
|
948
|
+
if (typeof u == "object" && u !== null && t.types[a] !== "string")
|
|
949
|
+
for (const [s, f] of Object.entries(u)) {
|
|
950
|
+
const w = t.types[a] ? t.types[a].replace("[]", "") : void 0;
|
|
951
|
+
u[s] = oe(f, t, w);
|
|
952
952
|
}
|
|
953
|
-
else typeof
|
|
954
|
-
return t.sort === !1 ? n : (t.sort === !0 ? Object.keys(n).sort() : Object.keys(n).sort(t.sort)).reduce((a,
|
|
955
|
-
const
|
|
956
|
-
return a[
|
|
953
|
+
else typeof u == "object" && u !== null && t.types[a] === "string" ? n[a] = Object.values(u).join(t.arrayFormatSeparator) : n[a] = oe(u, t, t.types[a]);
|
|
954
|
+
return t.sort === !1 ? n : (t.sort === !0 ? Object.keys(n).sort() : Object.keys(n).sort(t.sort)).reduce((a, u) => {
|
|
955
|
+
const s = n[u];
|
|
956
|
+
return a[u] = s && typeof s == "object" && !Array.isArray(s) ? pe(s) : s, a;
|
|
957
957
|
}, /* @__PURE__ */ Object.create(null));
|
|
958
958
|
}
|
|
959
|
-
function
|
|
959
|
+
function ye(e, t) {
|
|
960
960
|
if (!e)
|
|
961
961
|
return "";
|
|
962
962
|
t = {
|
|
@@ -965,23 +965,23 @@ function me(e, t) {
|
|
|
965
965
|
arrayFormat: "none",
|
|
966
966
|
arrayFormatSeparator: ",",
|
|
967
967
|
...t
|
|
968
|
-
},
|
|
969
|
-
const r = (
|
|
970
|
-
for (const [
|
|
971
|
-
r(
|
|
972
|
-
const
|
|
973
|
-
return t.sort !== !1 &&
|
|
974
|
-
const
|
|
975
|
-
return
|
|
976
|
-
}).filter((
|
|
968
|
+
}, de(t.arrayFormatSeparator);
|
|
969
|
+
const r = (s) => t.skipNull && _e(e[s]) || t.skipEmptyString && e[s] === "", n = ze(t), a = {};
|
|
970
|
+
for (const [s, f] of Object.entries(e))
|
|
971
|
+
r(s) || (a[s] = f);
|
|
972
|
+
const u = Object.keys(a);
|
|
973
|
+
return t.sort !== !1 && u.sort(t.sort), u.map((s) => {
|
|
974
|
+
const f = e[s];
|
|
975
|
+
return f === void 0 ? "" : f === null ? j(s, t) : Array.isArray(f) ? f.length === 0 && t.arrayFormat === "bracket-separator" ? j(s, t) + "[]" : f.reduce(n(s), []).join("&") : j(s, t) + "=" + j(f, t);
|
|
976
|
+
}).filter((s) => s.length > 0).join("&");
|
|
977
977
|
}
|
|
978
|
-
function
|
|
978
|
+
function ge(e, t) {
|
|
979
979
|
var a;
|
|
980
980
|
t = {
|
|
981
981
|
decode: !0,
|
|
982
982
|
...t
|
|
983
983
|
};
|
|
984
|
-
let [r, n] =
|
|
984
|
+
let [r, n] = le(e, "#");
|
|
985
985
|
return r === void 0 && (r = e), {
|
|
986
986
|
url: ((a = r == null ? void 0 : r.split("?")) == null ? void 0 : a[0]) ?? "",
|
|
987
987
|
query: Y(X(e), t),
|
|
@@ -997,22 +997,22 @@ function he(e, t) {
|
|
|
997
997
|
[G]: !0,
|
|
998
998
|
...t
|
|
999
999
|
};
|
|
1000
|
-
const r =
|
|
1000
|
+
const r = me(e.url).split("?")[0] || "", n = X(e.url), a = {
|
|
1001
1001
|
...Y(n, {
|
|
1002
1002
|
sort: !1
|
|
1003
1003
|
}),
|
|
1004
1004
|
...e.query
|
|
1005
1005
|
};
|
|
1006
|
-
let
|
|
1007
|
-
|
|
1008
|
-
let
|
|
1006
|
+
let u = ye(a, t);
|
|
1007
|
+
u && (u = `?${u}`);
|
|
1008
|
+
let s = Me(e.url);
|
|
1009
1009
|
if (typeof e.fragmentIdentifier == "string") {
|
|
1010
|
-
const
|
|
1011
|
-
|
|
1010
|
+
const f = new URL(r);
|
|
1011
|
+
f.hash = e.fragmentIdentifier, s = t[G] ? f.hash : `#${e.fragmentIdentifier}`;
|
|
1012
1012
|
}
|
|
1013
|
-
return `${r}${
|
|
1013
|
+
return `${r}${u}${s}`;
|
|
1014
1014
|
}
|
|
1015
|
-
function
|
|
1015
|
+
function be(e, t, r) {
|
|
1016
1016
|
r = {
|
|
1017
1017
|
parseFragmentIdentifier: !0,
|
|
1018
1018
|
[G]: !1,
|
|
@@ -1021,26 +1021,26 @@ function ge(e, t, r) {
|
|
|
1021
1021
|
const {
|
|
1022
1022
|
url: n,
|
|
1023
1023
|
query: a,
|
|
1024
|
-
fragmentIdentifier:
|
|
1025
|
-
} =
|
|
1024
|
+
fragmentIdentifier: u
|
|
1025
|
+
} = ge(e, r);
|
|
1026
1026
|
return he({
|
|
1027
1027
|
url: n,
|
|
1028
1028
|
query: Ue(a, t),
|
|
1029
|
-
fragmentIdentifier:
|
|
1029
|
+
fragmentIdentifier: u
|
|
1030
1030
|
}, r);
|
|
1031
1031
|
}
|
|
1032
|
-
function
|
|
1033
|
-
const n = Array.isArray(t) ? (a) => !t.includes(a) : (a,
|
|
1034
|
-
return
|
|
1032
|
+
function Be(e, t, r) {
|
|
1033
|
+
const n = Array.isArray(t) ? (a) => !t.includes(a) : (a, u) => !t(a, u);
|
|
1034
|
+
return be(e, n, r);
|
|
1035
1035
|
}
|
|
1036
1036
|
const Q = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1037
1037
|
__proto__: null,
|
|
1038
|
-
exclude:
|
|
1038
|
+
exclude: Be,
|
|
1039
1039
|
extract: X,
|
|
1040
1040
|
parse: Y,
|
|
1041
|
-
parseUrl:
|
|
1042
|
-
pick:
|
|
1043
|
-
stringify:
|
|
1041
|
+
parseUrl: ge,
|
|
1042
|
+
pick: be,
|
|
1043
|
+
stringify: ye,
|
|
1044
1044
|
stringifyUrl: he
|
|
1045
1045
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
1046
1046
|
function ie(e, t) {
|
|
@@ -1081,88 +1081,88 @@ function Ke(e, t) {
|
|
|
1081
1081
|
}
|
|
1082
1082
|
return (t === "string" ? String : Number)(e);
|
|
1083
1083
|
}
|
|
1084
|
-
function
|
|
1084
|
+
function Xe(e) {
|
|
1085
1085
|
const {
|
|
1086
1086
|
base: t = "/",
|
|
1087
1087
|
routes: r
|
|
1088
|
-
} = e, n =
|
|
1088
|
+
} = e, n = _({
|
|
1089
1089
|
skipUpdate: !1
|
|
1090
1090
|
}, {
|
|
1091
1091
|
name: "$meta",
|
|
1092
1092
|
sid: "ku65ys"
|
|
1093
|
-
}), a =
|
|
1093
|
+
}), a = _(null, {
|
|
1094
1094
|
and: {
|
|
1095
1095
|
serialize: "ignore"
|
|
1096
1096
|
},
|
|
1097
1097
|
name: "$history",
|
|
1098
1098
|
sid: "23j1rc"
|
|
1099
|
-
}),
|
|
1099
|
+
}), u = _({}, {
|
|
1100
1100
|
name: "$query",
|
|
1101
1101
|
sid: "3deub8"
|
|
1102
|
-
}),
|
|
1102
|
+
}), s = _(null, {
|
|
1103
1103
|
name: "$path",
|
|
1104
1104
|
sid: "ld3nhr"
|
|
1105
|
-
}),
|
|
1105
|
+
}), f = $({
|
|
1106
1106
|
name: "setHistory",
|
|
1107
1107
|
sid: "hzl7xm"
|
|
1108
|
-
}),
|
|
1108
|
+
}), w = $({
|
|
1109
1109
|
name: "navigate",
|
|
1110
1110
|
sid: "-82vbjo"
|
|
1111
|
-
}),
|
|
1111
|
+
}), E = $({
|
|
1112
1112
|
name: "back",
|
|
1113
1113
|
sid: "-icnnoo"
|
|
1114
|
-
}),
|
|
1114
|
+
}), k = $({
|
|
1115
1115
|
name: "forward",
|
|
1116
1116
|
sid: "-72o1my"
|
|
1117
|
-
}), P =
|
|
1117
|
+
}), P = $({
|
|
1118
1118
|
name: "locationUpdated",
|
|
1119
1119
|
sid: "d8lu52"
|
|
1120
|
-
}), A = r.map((
|
|
1121
|
-
let b =
|
|
1120
|
+
}), A = r.map((h) => {
|
|
1121
|
+
let b = h;
|
|
1122
1122
|
const m = [];
|
|
1123
1123
|
for (m.unshift(b.internal.path); b.internal.parent; )
|
|
1124
1124
|
b = b.internal.parent, b.internal.path !== "/" && m.unshift(b.internal.path);
|
|
1125
|
-
const
|
|
1125
|
+
const F = t === "/" ? m.join("") : [t, ...m].join("");
|
|
1126
1126
|
return {
|
|
1127
|
-
route:
|
|
1128
|
-
path:
|
|
1129
|
-
toPath: re.compile(
|
|
1130
|
-
fromPath: re.match(
|
|
1127
|
+
route: h,
|
|
1128
|
+
path: F,
|
|
1129
|
+
toPath: re.compile(F),
|
|
1130
|
+
fromPath: re.match(F)
|
|
1131
1131
|
};
|
|
1132
|
-
}),
|
|
1132
|
+
}), S = s.map((h) => {
|
|
1133
1133
|
const b = [];
|
|
1134
1134
|
for (const {
|
|
1135
1135
|
route: m,
|
|
1136
|
-
fromPath:
|
|
1136
|
+
fromPath: F
|
|
1137
1137
|
} of A)
|
|
1138
|
-
|
|
1138
|
+
F(h) && b.push(m);
|
|
1139
1139
|
return b;
|
|
1140
|
-
}),
|
|
1140
|
+
}), v = J({
|
|
1141
1141
|
and: {
|
|
1142
1142
|
source: {
|
|
1143
1143
|
history: a,
|
|
1144
1144
|
meta: n
|
|
1145
1145
|
},
|
|
1146
|
-
effect: async (
|
|
1146
|
+
effect: async (h, b) => {
|
|
1147
1147
|
let {
|
|
1148
1148
|
history: m,
|
|
1149
|
-
meta:
|
|
1150
|
-
} =
|
|
1151
|
-
path:
|
|
1149
|
+
meta: F
|
|
1150
|
+
} = h, {
|
|
1151
|
+
path: q,
|
|
1152
1152
|
query: I,
|
|
1153
|
-
replace:
|
|
1153
|
+
replace: c
|
|
1154
1154
|
} = b;
|
|
1155
1155
|
if (!m)
|
|
1156
1156
|
throw new Error("history not found");
|
|
1157
|
-
if (
|
|
1158
|
-
|
|
1157
|
+
if (F.skipUpdate) {
|
|
1158
|
+
F.skipUpdate = !1;
|
|
1159
1159
|
return;
|
|
1160
1160
|
}
|
|
1161
|
-
const
|
|
1162
|
-
pathname:
|
|
1161
|
+
const i = {
|
|
1162
|
+
pathname: q,
|
|
1163
1163
|
search: "?".concat(Q.stringify(I))
|
|
1164
1164
|
};
|
|
1165
|
-
|
|
1165
|
+
c ? m.replace(i) : m.push(i, {
|
|
1166
1166
|
skipUpdate: !0
|
|
1167
1167
|
});
|
|
1168
1168
|
}
|
|
@@ -1174,25 +1174,25 @@ function Ge(e) {
|
|
|
1174
1174
|
}), y = J({
|
|
1175
1175
|
and: {
|
|
1176
1176
|
source: n,
|
|
1177
|
-
effect: (
|
|
1177
|
+
effect: (h, b) => {
|
|
1178
1178
|
var m;
|
|
1179
|
-
const
|
|
1180
|
-
if (
|
|
1179
|
+
const F = Oe(P);
|
|
1180
|
+
if (F({
|
|
1181
1181
|
pathname: b.location.pathname,
|
|
1182
1182
|
query: ce({}, Q.parse(b.location.search)),
|
|
1183
1183
|
state: (m = b.location.state) !== null && m !== void 0 ? m : {}
|
|
1184
1184
|
}), !b)
|
|
1185
1185
|
throw new Error();
|
|
1186
|
-
b.listen((
|
|
1186
|
+
b.listen((q) => {
|
|
1187
1187
|
var I;
|
|
1188
1188
|
let {
|
|
1189
|
-
location:
|
|
1190
|
-
} =
|
|
1191
|
-
const
|
|
1192
|
-
|
|
1193
|
-
pathname:
|
|
1194
|
-
query: ce({}, Q.parse(
|
|
1195
|
-
state:
|
|
1189
|
+
location: c
|
|
1190
|
+
} = q;
|
|
1191
|
+
const i = (I = c.state) !== null && I !== void 0 ? I : {};
|
|
1192
|
+
i.skipUpdate && (h.skipUpdate = !0), F({
|
|
1193
|
+
pathname: c.pathname,
|
|
1194
|
+
query: ce({}, Q.parse(c.search)),
|
|
1195
|
+
state: i
|
|
1196
1196
|
});
|
|
1197
1197
|
});
|
|
1198
1198
|
}
|
|
@@ -1201,30 +1201,30 @@ function Ge(e) {
|
|
|
1201
1201
|
name: "subscribeHistoryFx",
|
|
1202
1202
|
sid: "-9srjw2"
|
|
1203
1203
|
}
|
|
1204
|
-
}),
|
|
1204
|
+
}), R = J({
|
|
1205
1205
|
and: {
|
|
1206
1206
|
source: {
|
|
1207
|
-
query:
|
|
1208
|
-
path:
|
|
1207
|
+
query: u,
|
|
1208
|
+
path: s
|
|
1209
1209
|
},
|
|
1210
|
-
effect: async (
|
|
1210
|
+
effect: async (h) => {
|
|
1211
1211
|
let {
|
|
1212
1212
|
query: b,
|
|
1213
1213
|
path: m
|
|
1214
|
-
} =
|
|
1214
|
+
} = h;
|
|
1215
1215
|
for (const {
|
|
1216
|
-
route:
|
|
1217
|
-
fromPath:
|
|
1216
|
+
route: F,
|
|
1217
|
+
fromPath: q
|
|
1218
1218
|
} of A) {
|
|
1219
|
-
const I =
|
|
1219
|
+
const I = q(m);
|
|
1220
1220
|
if (I)
|
|
1221
|
-
await
|
|
1221
|
+
await F.internal.openFx({
|
|
1222
1222
|
query: b,
|
|
1223
1223
|
params: I.params,
|
|
1224
1224
|
historyIgnore: !0
|
|
1225
1225
|
});
|
|
1226
1226
|
else {
|
|
1227
|
-
|
|
1227
|
+
F.internal.close();
|
|
1228
1228
|
continue;
|
|
1229
1229
|
}
|
|
1230
1230
|
}
|
|
@@ -1236,36 +1236,36 @@ function Ge(e) {
|
|
|
1236
1236
|
}
|
|
1237
1237
|
});
|
|
1238
1238
|
for (const {
|
|
1239
|
-
route:
|
|
1239
|
+
route: h,
|
|
1240
1240
|
toPath: b
|
|
1241
1241
|
} of A)
|
|
1242
|
-
|
|
1242
|
+
x({
|
|
1243
1243
|
and: [{
|
|
1244
|
-
clock:
|
|
1244
|
+
clock: h.opened,
|
|
1245
1245
|
filter: (m) => !(m != null && m.historyIgnore),
|
|
1246
1246
|
fn: (m) => {
|
|
1247
|
-
var
|
|
1247
|
+
var F;
|
|
1248
1248
|
return {
|
|
1249
1249
|
path: b(m && "params" in m ? m.params : void 0),
|
|
1250
|
-
query: (
|
|
1250
|
+
query: (F = m == null ? void 0 : m.query) !== null && F !== void 0 ? F : {},
|
|
1251
1251
|
replace: m == null ? void 0 : m.replace
|
|
1252
1252
|
};
|
|
1253
1253
|
},
|
|
1254
|
-
target:
|
|
1254
|
+
target: w
|
|
1255
1255
|
}],
|
|
1256
1256
|
or: {
|
|
1257
1257
|
sid: "gfvtvu"
|
|
1258
1258
|
}
|
|
1259
1259
|
});
|
|
1260
|
-
return
|
|
1260
|
+
return x({
|
|
1261
1261
|
and: [{
|
|
1262
|
-
clock:
|
|
1262
|
+
clock: f,
|
|
1263
1263
|
target: a
|
|
1264
1264
|
}],
|
|
1265
1265
|
or: {
|
|
1266
1266
|
sid: "hbrw92"
|
|
1267
1267
|
}
|
|
1268
|
-
}),
|
|
1268
|
+
}), x({
|
|
1269
1269
|
and: [{
|
|
1270
1270
|
clock: a,
|
|
1271
1271
|
filter: Boolean,
|
|
@@ -1274,19 +1274,19 @@ function Ge(e) {
|
|
|
1274
1274
|
or: {
|
|
1275
1275
|
sid: "heiv7v"
|
|
1276
1276
|
}
|
|
1277
|
-
}),
|
|
1277
|
+
}), x({
|
|
1278
1278
|
and: [{
|
|
1279
1279
|
clock: P,
|
|
1280
|
-
fn: (
|
|
1281
|
-
path:
|
|
1282
|
-
query:
|
|
1280
|
+
fn: (h) => ({
|
|
1281
|
+
path: h.pathname,
|
|
1282
|
+
query: h.query
|
|
1283
1283
|
}),
|
|
1284
|
-
target:
|
|
1284
|
+
target: xe({
|
|
1285
1285
|
sid: "-f70n8p",
|
|
1286
|
-
fn: () =>
|
|
1286
|
+
fn: () => $e({
|
|
1287
1287
|
targets: {
|
|
1288
|
-
path:
|
|
1289
|
-
query:
|
|
1288
|
+
path: s,
|
|
1289
|
+
query: u
|
|
1290
1290
|
}
|
|
1291
1291
|
}),
|
|
1292
1292
|
name: "target",
|
|
@@ -1296,67 +1296,207 @@ function Ge(e) {
|
|
|
1296
1296
|
or: {
|
|
1297
1297
|
sid: "htdb8m"
|
|
1298
1298
|
}
|
|
1299
|
-
}),
|
|
1299
|
+
}), x({
|
|
1300
1300
|
and: [{
|
|
1301
1301
|
clock: P,
|
|
1302
|
-
fn: (
|
|
1303
|
-
path:
|
|
1304
|
-
query:
|
|
1302
|
+
fn: (h) => ({
|
|
1303
|
+
path: h.pathname,
|
|
1304
|
+
query: h.query
|
|
1305
1305
|
}),
|
|
1306
|
-
target:
|
|
1306
|
+
target: R
|
|
1307
1307
|
}],
|
|
1308
1308
|
or: {
|
|
1309
1309
|
sid: "icm409"
|
|
1310
1310
|
}
|
|
1311
|
-
}),
|
|
1311
|
+
}), x({
|
|
1312
1312
|
and: [{
|
|
1313
|
-
clock:
|
|
1314
|
-
target:
|
|
1313
|
+
clock: w,
|
|
1314
|
+
target: v
|
|
1315
1315
|
}],
|
|
1316
1316
|
or: {
|
|
1317
1317
|
sid: "sr2036"
|
|
1318
1318
|
}
|
|
1319
|
-
}),
|
|
1319
|
+
}), x({
|
|
1320
1320
|
and: [{
|
|
1321
|
-
clock: [
|
|
1321
|
+
clock: [u, s],
|
|
1322
1322
|
source: {
|
|
1323
|
-
query:
|
|
1324
|
-
path:
|
|
1323
|
+
query: u,
|
|
1324
|
+
path: s
|
|
1325
1325
|
},
|
|
1326
|
-
fn: (
|
|
1327
|
-
target:
|
|
1326
|
+
fn: (h) => h,
|
|
1327
|
+
target: w
|
|
1328
1328
|
}],
|
|
1329
1329
|
or: {
|
|
1330
1330
|
sid: "t5cnik"
|
|
1331
1331
|
}
|
|
1332
1332
|
}), {
|
|
1333
|
-
$query:
|
|
1334
|
-
$path:
|
|
1335
|
-
$activeRoutes:
|
|
1336
|
-
back:
|
|
1337
|
-
forward:
|
|
1338
|
-
navigate:
|
|
1333
|
+
$query: u,
|
|
1334
|
+
$path: s,
|
|
1335
|
+
$activeRoutes: S,
|
|
1336
|
+
back: E,
|
|
1337
|
+
forward: k,
|
|
1338
|
+
navigate: w,
|
|
1339
1339
|
routes: r,
|
|
1340
|
-
setHistory:
|
|
1340
|
+
setHistory: f,
|
|
1341
1341
|
mappedRoutes: A,
|
|
1342
1342
|
trackQuery: De({
|
|
1343
|
-
$activeRoutes:
|
|
1344
|
-
$path:
|
|
1345
|
-
$query:
|
|
1346
|
-
navigateFx:
|
|
1343
|
+
$activeRoutes: S,
|
|
1344
|
+
$path: s,
|
|
1345
|
+
$query: u,
|
|
1346
|
+
navigateFx: v
|
|
1347
1347
|
}),
|
|
1348
1348
|
"@@unitShape": () => ({
|
|
1349
|
-
query:
|
|
1350
|
-
path:
|
|
1351
|
-
activeRoutes:
|
|
1352
|
-
onBack:
|
|
1353
|
-
onForward:
|
|
1354
|
-
onNavigate:
|
|
1349
|
+
query: u,
|
|
1350
|
+
path: s,
|
|
1351
|
+
activeRoutes: S,
|
|
1352
|
+
onBack: E,
|
|
1353
|
+
onForward: k,
|
|
1354
|
+
onNavigate: w
|
|
1355
1355
|
})
|
|
1356
1356
|
};
|
|
1357
1357
|
}
|
|
1358
|
+
function Je(e) {
|
|
1359
|
+
const t = _(null, {
|
|
1360
|
+
name: "$params",
|
|
1361
|
+
sid: "-ui6zqo"
|
|
1362
|
+
}), r = _(!1, {
|
|
1363
|
+
name: "$isOpened",
|
|
1364
|
+
sid: "p6gokr"
|
|
1365
|
+
}), n = e, a = $({
|
|
1366
|
+
name: "open",
|
|
1367
|
+
sid: "55xtzu"
|
|
1368
|
+
}), u = $({
|
|
1369
|
+
name: "opened",
|
|
1370
|
+
sid: "tidivr"
|
|
1371
|
+
}), s = $({
|
|
1372
|
+
name: "openedOnServer",
|
|
1373
|
+
sid: "8drh93"
|
|
1374
|
+
}), f = $({
|
|
1375
|
+
name: "openedOnClient",
|
|
1376
|
+
sid: "-pj4ssy"
|
|
1377
|
+
}), w = $({
|
|
1378
|
+
name: "close",
|
|
1379
|
+
sid: "-9osjjv"
|
|
1380
|
+
}), E = $({
|
|
1381
|
+
name: "closed",
|
|
1382
|
+
sid: "hnb5jj"
|
|
1383
|
+
});
|
|
1384
|
+
return x({
|
|
1385
|
+
and: [{
|
|
1386
|
+
clock: a,
|
|
1387
|
+
target: u
|
|
1388
|
+
}],
|
|
1389
|
+
or: {
|
|
1390
|
+
sid: "-v1zz6f"
|
|
1391
|
+
}
|
|
1392
|
+
}), ue({
|
|
1393
|
+
and: [{
|
|
1394
|
+
source: u,
|
|
1395
|
+
match: () => typeof window > "u" ? "server" : "client",
|
|
1396
|
+
cases: {
|
|
1397
|
+
server: s,
|
|
1398
|
+
client: f
|
|
1399
|
+
}
|
|
1400
|
+
}],
|
|
1401
|
+
or: {
|
|
1402
|
+
sid: "-unpbr1"
|
|
1403
|
+
}
|
|
1404
|
+
}), x({
|
|
1405
|
+
and: [{
|
|
1406
|
+
clock: w,
|
|
1407
|
+
target: E
|
|
1408
|
+
}],
|
|
1409
|
+
or: {
|
|
1410
|
+
sid: "-u77hy7"
|
|
1411
|
+
}
|
|
1412
|
+
}), x({
|
|
1413
|
+
and: [{
|
|
1414
|
+
clock: [u.map(() => !0), E.map(() => !1)],
|
|
1415
|
+
target: r
|
|
1416
|
+
}],
|
|
1417
|
+
or: {
|
|
1418
|
+
sid: "-u4gize"
|
|
1419
|
+
}
|
|
1420
|
+
}), {
|
|
1421
|
+
$params: t,
|
|
1422
|
+
$isOpened: r,
|
|
1423
|
+
$isPending: n,
|
|
1424
|
+
open: a,
|
|
1425
|
+
opened: u,
|
|
1426
|
+
openedOnClient: f,
|
|
1427
|
+
openedOnServer: s,
|
|
1428
|
+
close: w,
|
|
1429
|
+
closed: E,
|
|
1430
|
+
"@@unitShape": () => ({
|
|
1431
|
+
params: t,
|
|
1432
|
+
isOpened: r,
|
|
1433
|
+
isPending: n,
|
|
1434
|
+
onOpen: a
|
|
1435
|
+
})
|
|
1436
|
+
};
|
|
1437
|
+
}
|
|
1438
|
+
function Ye(e) {
|
|
1439
|
+
const {
|
|
1440
|
+
route: t,
|
|
1441
|
+
beforeOpen: r,
|
|
1442
|
+
openOn: n,
|
|
1443
|
+
cancelOn: a
|
|
1444
|
+
} = e, u = V(async (f) => {
|
|
1445
|
+
for (const w of [].concat(r))
|
|
1446
|
+
await w(f);
|
|
1447
|
+
}, {
|
|
1448
|
+
name: "openFx",
|
|
1449
|
+
sid: "14ykg2"
|
|
1450
|
+
}), s = Je(u.pending);
|
|
1451
|
+
return x({
|
|
1452
|
+
and: [{
|
|
1453
|
+
clock: t.opened,
|
|
1454
|
+
target: u
|
|
1455
|
+
}],
|
|
1456
|
+
or: {
|
|
1457
|
+
sid: "-s8ttzz"
|
|
1458
|
+
}
|
|
1459
|
+
}), x({
|
|
1460
|
+
and: [{
|
|
1461
|
+
clock: t.opened,
|
|
1462
|
+
fn: (f) => f && "params" in f ? f.params : null,
|
|
1463
|
+
target: s.$params
|
|
1464
|
+
}],
|
|
1465
|
+
or: {
|
|
1466
|
+
sid: "-1t3nrm"
|
|
1467
|
+
}
|
|
1468
|
+
}), n && x({
|
|
1469
|
+
and: [{
|
|
1470
|
+
clock: n,
|
|
1471
|
+
source: {
|
|
1472
|
+
params: s.$params
|
|
1473
|
+
},
|
|
1474
|
+
fn: (f) => {
|
|
1475
|
+
let {
|
|
1476
|
+
params: w
|
|
1477
|
+
} = f;
|
|
1478
|
+
return {
|
|
1479
|
+
params: w
|
|
1480
|
+
};
|
|
1481
|
+
},
|
|
1482
|
+
target: s.open
|
|
1483
|
+
}],
|
|
1484
|
+
or: {
|
|
1485
|
+
sid: "-1cltx2"
|
|
1486
|
+
}
|
|
1487
|
+
}), a && x({
|
|
1488
|
+
and: [{
|
|
1489
|
+
clock: [t.closed].concat(a),
|
|
1490
|
+
target: s.close
|
|
1491
|
+
}],
|
|
1492
|
+
or: {
|
|
1493
|
+
sid: "-w4048"
|
|
1494
|
+
}
|
|
1495
|
+
}), s;
|
|
1496
|
+
}
|
|
1358
1497
|
export {
|
|
1359
|
-
|
|
1360
|
-
Ge as
|
|
1498
|
+
Ye as chainRoute,
|
|
1499
|
+
Ge as createRoute,
|
|
1500
|
+
Xe as createRouter,
|
|
1361
1501
|
T as parameters
|
|
1362
1502
|
};
|