@shiftengineering/folio 0.1.30 → 0.1.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var Js = Object.defineProperty;
|
|
2
|
+
var sn = (t) => {
|
|
3
3
|
throw TypeError(t);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
6
|
-
var tr = (t, e, r) =>
|
|
7
|
-
var a = (t, e, r) => (rr(t, e, "read from private field"), r ? r.call(t) : e.get(t)), w = (t, e, r) => e.has(t) ?
|
|
5
|
+
var Xs = (t, e, r) => e in t ? Js(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r;
|
|
6
|
+
var tr = (t, e, r) => Xs(t, typeof e != "symbol" ? e + "" : e, r), rr = (t, e, r) => e.has(t) || sn("Cannot " + r);
|
|
7
|
+
var a = (t, e, r) => (rr(t, e, "read from private field"), r ? r.call(t) : e.get(t)), w = (t, e, r) => e.has(t) ? sn("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, r), v = (t, e, r, n) => (rr(t, e, "write to private field"), n ? n.call(t, r) : e.set(t, r), r), C = (t, e, r) => (rr(t, e, "access private method"), r);
|
|
8
8
|
var kt = (t, e, r, n) => ({
|
|
9
9
|
set _(s) {
|
|
10
10
|
v(t, e, s, r);
|
|
@@ -13,8 +13,8 @@ var kt = (t, e, r, n) => ({
|
|
|
13
13
|
return a(t, e, n);
|
|
14
14
|
}
|
|
15
15
|
});
|
|
16
|
-
import * as
|
|
17
|
-
import
|
|
16
|
+
import * as K from "react";
|
|
17
|
+
import Vn, { createContext as Zs, useState as ei, useMemo as ti, useEffect as nr, useContext as ri } from "react";
|
|
18
18
|
var ur = { exports: {} }, pt = {};
|
|
19
19
|
/**
|
|
20
20
|
* @license React
|
|
@@ -25,11 +25,11 @@ var ur = { exports: {} }, pt = {};
|
|
|
25
25
|
* This source code is licensed under the MIT license found in the
|
|
26
26
|
* LICENSE file in the root directory of this source tree.
|
|
27
27
|
*/
|
|
28
|
-
var
|
|
29
|
-
function
|
|
30
|
-
if (
|
|
31
|
-
|
|
32
|
-
var t =
|
|
28
|
+
var on;
|
|
29
|
+
function ni() {
|
|
30
|
+
if (on) return pt;
|
|
31
|
+
on = 1;
|
|
32
|
+
var t = Vn, e = Symbol.for("react.element"), r = Symbol.for("react.fragment"), n = Object.prototype.hasOwnProperty, s = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
33
33
|
function u(l, c, y) {
|
|
34
34
|
var f, d = {}, h = null, m = null;
|
|
35
35
|
y !== void 0 && (h = "" + y), c.key !== void 0 && (h = "" + c.key), c.ref !== void 0 && (m = c.ref);
|
|
@@ -49,38 +49,38 @@ var mt = {};
|
|
|
49
49
|
* This source code is licensed under the MIT license found in the
|
|
50
50
|
* LICENSE file in the root directory of this source tree.
|
|
51
51
|
*/
|
|
52
|
-
var
|
|
53
|
-
function
|
|
54
|
-
return
|
|
55
|
-
var t =
|
|
52
|
+
var an;
|
|
53
|
+
function si() {
|
|
54
|
+
return an || (an = 1, process.env.NODE_ENV !== "production" && function() {
|
|
55
|
+
var t = Vn, e = Symbol.for("react.element"), r = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), u = Symbol.for("react.provider"), l = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), y = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), d = Symbol.for("react.memo"), h = Symbol.for("react.lazy"), m = Symbol.for("react.offscreen"), P = Symbol.iterator, g = "@@iterator";
|
|
56
56
|
function O(o) {
|
|
57
57
|
if (o === null || typeof o != "object")
|
|
58
58
|
return null;
|
|
59
|
-
var p =
|
|
59
|
+
var p = P && o[P] || o[g];
|
|
60
60
|
return typeof p == "function" ? p : null;
|
|
61
61
|
}
|
|
62
|
-
var
|
|
63
|
-
function
|
|
62
|
+
var S = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
63
|
+
function E(o) {
|
|
64
64
|
{
|
|
65
65
|
for (var p = arguments.length, b = new Array(p > 1 ? p - 1 : 0), R = 1; R < p; R++)
|
|
66
66
|
b[R - 1] = arguments[R];
|
|
67
|
-
|
|
67
|
+
I("error", o, b);
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
|
-
function
|
|
70
|
+
function I(o, p, b) {
|
|
71
71
|
{
|
|
72
|
-
var R =
|
|
73
|
-
|
|
72
|
+
var R = S.ReactDebugCurrentFrame, D = R.getStackAddendum();
|
|
73
|
+
D !== "" && (p += "%s", b = b.concat([D]));
|
|
74
74
|
var k = b.map(function(x) {
|
|
75
75
|
return String(x);
|
|
76
76
|
});
|
|
77
77
|
k.unshift("Warning: " + p), Function.prototype.apply.call(console[o], console, k);
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
|
-
var
|
|
80
|
+
var q = !1, N = !1, Z = !1, z = !1, U = !1, j;
|
|
81
81
|
j = Symbol.for("react.module.reference");
|
|
82
82
|
function ge(o) {
|
|
83
|
-
return !!(typeof o == "string" || typeof o == "function" || o === n || o === i ||
|
|
83
|
+
return !!(typeof o == "string" || typeof o == "function" || o === n || o === i || U || o === s || o === y || o === f || z || o === m || q || N || Z || typeof o == "object" && o !== null && (o.$$typeof === h || o.$$typeof === d || o.$$typeof === u || o.$$typeof === l || o.$$typeof === c || // This needs to include all possible module reference object
|
|
84
84
|
// types supported by any Flight configuration anywhere since
|
|
85
85
|
// we don't know which Flight build this will end up being used
|
|
86
86
|
// with.
|
|
@@ -90,8 +90,8 @@ function ni() {
|
|
|
90
90
|
var R = o.displayName;
|
|
91
91
|
if (R)
|
|
92
92
|
return R;
|
|
93
|
-
var
|
|
94
|
-
return
|
|
93
|
+
var D = p.displayName || p.name || "";
|
|
94
|
+
return D !== "" ? b + "(" + D + ")" : b;
|
|
95
95
|
}
|
|
96
96
|
function De(o) {
|
|
97
97
|
return o.displayName || "Context";
|
|
@@ -99,7 +99,7 @@ function ni() {
|
|
|
99
99
|
function be(o) {
|
|
100
100
|
if (o == null)
|
|
101
101
|
return null;
|
|
102
|
-
if (typeof o.tag == "number" &&
|
|
102
|
+
if (typeof o.tag == "number" && E("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof o == "function")
|
|
103
103
|
return o.displayName || o.name || null;
|
|
104
104
|
if (typeof o == "string")
|
|
105
105
|
return o;
|
|
@@ -131,7 +131,7 @@ function ni() {
|
|
|
131
131
|
var R = o.displayName || null;
|
|
132
132
|
return R !== null ? R : be(o.type) || "Memo";
|
|
133
133
|
case h: {
|
|
134
|
-
var
|
|
134
|
+
var D = o, k = D._payload, x = D._init;
|
|
135
135
|
try {
|
|
136
136
|
return be(x(k));
|
|
137
137
|
} catch {
|
|
@@ -141,18 +141,18 @@ function ni() {
|
|
|
141
141
|
}
|
|
142
142
|
return null;
|
|
143
143
|
}
|
|
144
|
-
var _e = Object.assign, ht = 0,
|
|
145
|
-
function
|
|
144
|
+
var _e = Object.assign, ht = 0, jr, qr, Ur, Mr, Nr, Lr, Qr;
|
|
145
|
+
function $r() {
|
|
146
146
|
}
|
|
147
|
-
|
|
148
|
-
function
|
|
147
|
+
$r.__reactDisabledLog = !0;
|
|
148
|
+
function Rs() {
|
|
149
149
|
{
|
|
150
150
|
if (ht === 0) {
|
|
151
|
-
|
|
151
|
+
jr = console.log, qr = console.info, Ur = console.warn, Mr = console.error, Nr = console.group, Lr = console.groupCollapsed, Qr = console.groupEnd;
|
|
152
152
|
var o = {
|
|
153
153
|
configurable: !0,
|
|
154
154
|
enumerable: !0,
|
|
155
|
-
value:
|
|
155
|
+
value: $r,
|
|
156
156
|
writable: !0
|
|
157
157
|
};
|
|
158
158
|
Object.defineProperties(console, {
|
|
@@ -168,7 +168,7 @@ function ni() {
|
|
|
168
168
|
ht++;
|
|
169
169
|
}
|
|
170
170
|
}
|
|
171
|
-
function
|
|
171
|
+
function Ss() {
|
|
172
172
|
{
|
|
173
173
|
if (ht--, ht === 0) {
|
|
174
174
|
var o = {
|
|
@@ -178,39 +178,39 @@ function ni() {
|
|
|
178
178
|
};
|
|
179
179
|
Object.defineProperties(console, {
|
|
180
180
|
log: _e({}, o, {
|
|
181
|
-
value:
|
|
181
|
+
value: jr
|
|
182
182
|
}),
|
|
183
183
|
info: _e({}, o, {
|
|
184
|
-
value:
|
|
184
|
+
value: qr
|
|
185
185
|
}),
|
|
186
186
|
warn: _e({}, o, {
|
|
187
|
-
value:
|
|
187
|
+
value: Ur
|
|
188
188
|
}),
|
|
189
189
|
error: _e({}, o, {
|
|
190
|
-
value:
|
|
190
|
+
value: Mr
|
|
191
191
|
}),
|
|
192
192
|
group: _e({}, o, {
|
|
193
|
-
value:
|
|
193
|
+
value: Nr
|
|
194
194
|
}),
|
|
195
195
|
groupCollapsed: _e({}, o, {
|
|
196
|
-
value:
|
|
196
|
+
value: Lr
|
|
197
197
|
}),
|
|
198
198
|
groupEnd: _e({}, o, {
|
|
199
|
-
value:
|
|
199
|
+
value: Qr
|
|
200
200
|
})
|
|
201
201
|
});
|
|
202
202
|
}
|
|
203
|
-
ht < 0 &&
|
|
203
|
+
ht < 0 && E("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
204
204
|
}
|
|
205
205
|
}
|
|
206
|
-
var
|
|
206
|
+
var Ht = S.ReactCurrentDispatcher, Bt;
|
|
207
207
|
function xt(o, p, b) {
|
|
208
208
|
{
|
|
209
209
|
if (Bt === void 0)
|
|
210
210
|
try {
|
|
211
211
|
throw Error();
|
|
212
|
-
} catch (
|
|
213
|
-
var R =
|
|
212
|
+
} catch (D) {
|
|
213
|
+
var R = D.stack.trim().match(/\n( *(at )?)/);
|
|
214
214
|
Bt = R && R[1] || "";
|
|
215
215
|
}
|
|
216
216
|
return `
|
|
@@ -219,10 +219,10 @@ function ni() {
|
|
|
219
219
|
}
|
|
220
220
|
var Gt = !1, It;
|
|
221
221
|
{
|
|
222
|
-
var
|
|
223
|
-
It = new
|
|
222
|
+
var Cs = typeof WeakMap == "function" ? WeakMap : Map;
|
|
223
|
+
It = new Cs();
|
|
224
224
|
}
|
|
225
|
-
function
|
|
225
|
+
function Kr(o, p) {
|
|
226
226
|
if (!o || Gt)
|
|
227
227
|
return "";
|
|
228
228
|
{
|
|
@@ -232,10 +232,10 @@ function ni() {
|
|
|
232
232
|
}
|
|
233
233
|
var R;
|
|
234
234
|
Gt = !0;
|
|
235
|
-
var
|
|
235
|
+
var D = Error.prepareStackTrace;
|
|
236
236
|
Error.prepareStackTrace = void 0;
|
|
237
237
|
var k;
|
|
238
|
-
k =
|
|
238
|
+
k = Ht.current, Ht.current = null, Rs();
|
|
239
239
|
try {
|
|
240
240
|
if (p) {
|
|
241
241
|
var x = function() {
|
|
@@ -271,32 +271,32 @@ function ni() {
|
|
|
271
271
|
} catch (Y) {
|
|
272
272
|
if (Y && R && typeof Y.stack == "string") {
|
|
273
273
|
for (var T = Y.stack.split(`
|
|
274
|
-
`),
|
|
275
|
-
`),
|
|
276
|
-
|
|
277
|
-
for (;
|
|
278
|
-
if (T[
|
|
279
|
-
if (
|
|
274
|
+
`), W = R.stack.split(`
|
|
275
|
+
`), L = T.length - 1, Q = W.length - 1; L >= 1 && Q >= 0 && T[L] !== W[Q]; )
|
|
276
|
+
Q--;
|
|
277
|
+
for (; L >= 1 && Q >= 0; L--, Q--)
|
|
278
|
+
if (T[L] !== W[Q]) {
|
|
279
|
+
if (L !== 1 || Q !== 1)
|
|
280
280
|
do
|
|
281
|
-
if (
|
|
281
|
+
if (L--, Q--, Q < 0 || T[L] !== W[Q]) {
|
|
282
282
|
var ee = `
|
|
283
|
-
` + T[
|
|
283
|
+
` + T[L].replace(" at new ", " at ");
|
|
284
284
|
return o.displayName && ee.includes("<anonymous>") && (ee = ee.replace("<anonymous>", o.displayName)), typeof o == "function" && It.set(o, ee), ee;
|
|
285
285
|
}
|
|
286
|
-
while (
|
|
286
|
+
while (L >= 1 && Q >= 0);
|
|
287
287
|
break;
|
|
288
288
|
}
|
|
289
289
|
}
|
|
290
290
|
} finally {
|
|
291
|
-
Gt = !1,
|
|
291
|
+
Gt = !1, Ht.current = k, Ss(), Error.prepareStackTrace = D;
|
|
292
292
|
}
|
|
293
293
|
var Be = o ? o.displayName || o.name : "", ke = Be ? xt(Be) : "";
|
|
294
294
|
return typeof o == "function" && It.set(o, ke), ke;
|
|
295
295
|
}
|
|
296
|
-
function
|
|
297
|
-
return
|
|
296
|
+
function Ts(o, p, b) {
|
|
297
|
+
return Kr(o, !1);
|
|
298
298
|
}
|
|
299
|
-
function
|
|
299
|
+
function Fs(o) {
|
|
300
300
|
var p = o.prototype;
|
|
301
301
|
return !!(p && p.isReactComponent);
|
|
302
302
|
}
|
|
@@ -304,7 +304,7 @@ function ni() {
|
|
|
304
304
|
if (o == null)
|
|
305
305
|
return "";
|
|
306
306
|
if (typeof o == "function")
|
|
307
|
-
return
|
|
307
|
+
return Kr(o, Fs(o));
|
|
308
308
|
if (typeof o == "string")
|
|
309
309
|
return xt(o);
|
|
310
310
|
switch (o) {
|
|
@@ -316,28 +316,28 @@ function ni() {
|
|
|
316
316
|
if (typeof o == "object")
|
|
317
317
|
switch (o.$$typeof) {
|
|
318
318
|
case c:
|
|
319
|
-
return
|
|
319
|
+
return Ts(o.render);
|
|
320
320
|
case d:
|
|
321
321
|
return Dt(o.type, p, b);
|
|
322
322
|
case h: {
|
|
323
|
-
var R = o,
|
|
323
|
+
var R = o, D = R._payload, k = R._init;
|
|
324
324
|
try {
|
|
325
|
-
return Dt(k(
|
|
325
|
+
return Dt(k(D), p, b);
|
|
326
326
|
} catch {
|
|
327
327
|
}
|
|
328
328
|
}
|
|
329
329
|
}
|
|
330
330
|
return "";
|
|
331
331
|
}
|
|
332
|
-
var yt = Object.prototype.hasOwnProperty,
|
|
332
|
+
var yt = Object.prototype.hasOwnProperty, zr = {}, Vr = S.ReactDebugCurrentFrame;
|
|
333
333
|
function _t(o) {
|
|
334
334
|
if (o) {
|
|
335
335
|
var p = o._owner, b = Dt(o.type, o._source, p ? p.type : null);
|
|
336
|
-
|
|
336
|
+
Vr.setExtraStackFrame(b);
|
|
337
337
|
} else
|
|
338
|
-
|
|
338
|
+
Vr.setExtraStackFrame(null);
|
|
339
339
|
}
|
|
340
|
-
function
|
|
340
|
+
function As(o, p, b, R, D) {
|
|
341
341
|
{
|
|
342
342
|
var k = Function.call.bind(yt);
|
|
343
343
|
for (var x in o)
|
|
@@ -345,48 +345,48 @@ function ni() {
|
|
|
345
345
|
var T = void 0;
|
|
346
346
|
try {
|
|
347
347
|
if (typeof o[x] != "function") {
|
|
348
|
-
var
|
|
349
|
-
throw
|
|
348
|
+
var W = Error((R || "React class") + ": " + b + " type `" + x + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof o[x] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
349
|
+
throw W.name = "Invariant Violation", W;
|
|
350
350
|
}
|
|
351
351
|
T = o[x](p, x, R, b, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
352
|
-
} catch (
|
|
353
|
-
T =
|
|
352
|
+
} catch (L) {
|
|
353
|
+
T = L;
|
|
354
354
|
}
|
|
355
|
-
T && !(T instanceof Error) && (_t(
|
|
355
|
+
T && !(T instanceof Error) && (_t(D), E("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", R || "React class", b, x, typeof T), _t(null)), T instanceof Error && !(T.message in zr) && (zr[T.message] = !0, _t(D), E("Failed %s type: %s", b, T.message), _t(null));
|
|
356
356
|
}
|
|
357
357
|
}
|
|
358
358
|
}
|
|
359
|
-
var
|
|
359
|
+
var xs = Array.isArray;
|
|
360
360
|
function Yt(o) {
|
|
361
|
-
return
|
|
361
|
+
return xs(o);
|
|
362
362
|
}
|
|
363
|
-
function
|
|
363
|
+
function Is(o) {
|
|
364
364
|
{
|
|
365
365
|
var p = typeof Symbol == "function" && Symbol.toStringTag, b = p && o[Symbol.toStringTag] || o.constructor.name || "Object";
|
|
366
366
|
return b;
|
|
367
367
|
}
|
|
368
368
|
}
|
|
369
|
-
function
|
|
369
|
+
function Ds(o) {
|
|
370
370
|
try {
|
|
371
|
-
return
|
|
371
|
+
return Wr(o), !1;
|
|
372
372
|
} catch {
|
|
373
373
|
return !0;
|
|
374
374
|
}
|
|
375
375
|
}
|
|
376
|
-
function
|
|
376
|
+
function Wr(o) {
|
|
377
377
|
return "" + o;
|
|
378
378
|
}
|
|
379
379
|
function Hr(o) {
|
|
380
|
-
if (
|
|
381
|
-
return
|
|
380
|
+
if (Ds(o))
|
|
381
|
+
return E("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Is(o)), Wr(o);
|
|
382
382
|
}
|
|
383
|
-
var
|
|
383
|
+
var Br = S.ReactCurrentOwner, _s = {
|
|
384
384
|
key: !0,
|
|
385
385
|
ref: !0,
|
|
386
386
|
__self: !0,
|
|
387
387
|
__source: !0
|
|
388
|
-
},
|
|
389
|
-
function
|
|
388
|
+
}, Gr, Yr;
|
|
389
|
+
function ks(o) {
|
|
390
390
|
if (yt.call(o, "ref")) {
|
|
391
391
|
var p = Object.getOwnPropertyDescriptor(o, "ref").get;
|
|
392
392
|
if (p && p.isReactWarning)
|
|
@@ -394,7 +394,7 @@ function ni() {
|
|
|
394
394
|
}
|
|
395
395
|
return o.ref !== void 0;
|
|
396
396
|
}
|
|
397
|
-
function
|
|
397
|
+
function js(o) {
|
|
398
398
|
if (yt.call(o, "key")) {
|
|
399
399
|
var p = Object.getOwnPropertyDescriptor(o, "key").get;
|
|
400
400
|
if (p && p.isReactWarning)
|
|
@@ -402,13 +402,13 @@ function ni() {
|
|
|
402
402
|
}
|
|
403
403
|
return o.key !== void 0;
|
|
404
404
|
}
|
|
405
|
-
function js(o, p) {
|
|
406
|
-
typeof o.ref == "string" && Wr.current;
|
|
407
|
-
}
|
|
408
405
|
function qs(o, p) {
|
|
406
|
+
typeof o.ref == "string" && Br.current;
|
|
407
|
+
}
|
|
408
|
+
function Us(o, p) {
|
|
409
409
|
{
|
|
410
410
|
var b = function() {
|
|
411
|
-
|
|
411
|
+
Gr || (Gr = !0, E("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
|
|
412
412
|
};
|
|
413
413
|
b.isReactWarning = !0, Object.defineProperty(o, "key", {
|
|
414
414
|
get: b,
|
|
@@ -416,10 +416,10 @@ function ni() {
|
|
|
416
416
|
});
|
|
417
417
|
}
|
|
418
418
|
}
|
|
419
|
-
function
|
|
419
|
+
function Ms(o, p) {
|
|
420
420
|
{
|
|
421
421
|
var b = function() {
|
|
422
|
-
|
|
422
|
+
Yr || (Yr = !0, E("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
|
|
423
423
|
};
|
|
424
424
|
b.isReactWarning = !0, Object.defineProperty(o, "ref", {
|
|
425
425
|
get: b,
|
|
@@ -427,7 +427,7 @@ function ni() {
|
|
|
427
427
|
});
|
|
428
428
|
}
|
|
429
429
|
}
|
|
430
|
-
var
|
|
430
|
+
var Ns = function(o, p, b, R, D, k, x) {
|
|
431
431
|
var T = {
|
|
432
432
|
// This tag allows us to uniquely identify this as a React Element
|
|
433
433
|
$$typeof: e,
|
|
@@ -453,41 +453,41 @@ function ni() {
|
|
|
453
453
|
configurable: !1,
|
|
454
454
|
enumerable: !1,
|
|
455
455
|
writable: !1,
|
|
456
|
-
value:
|
|
456
|
+
value: D
|
|
457
457
|
}), Object.freeze && (Object.freeze(T.props), Object.freeze(T)), T;
|
|
458
458
|
};
|
|
459
|
-
function
|
|
459
|
+
function Ls(o, p, b, R, D) {
|
|
460
460
|
{
|
|
461
|
-
var k, x = {}, T = null,
|
|
462
|
-
b !== void 0 && (Hr(b), T = "" + b),
|
|
461
|
+
var k, x = {}, T = null, W = null;
|
|
462
|
+
b !== void 0 && (Hr(b), T = "" + b), js(p) && (Hr(p.key), T = "" + p.key), ks(p) && (W = p.ref, qs(p, D));
|
|
463
463
|
for (k in p)
|
|
464
|
-
yt.call(p, k) && !
|
|
464
|
+
yt.call(p, k) && !_s.hasOwnProperty(k) && (x[k] = p[k]);
|
|
465
465
|
if (o && o.defaultProps) {
|
|
466
|
-
var
|
|
467
|
-
for (k in
|
|
468
|
-
x[k] === void 0 && (x[k] =
|
|
466
|
+
var L = o.defaultProps;
|
|
467
|
+
for (k in L)
|
|
468
|
+
x[k] === void 0 && (x[k] = L[k]);
|
|
469
469
|
}
|
|
470
|
-
if (T ||
|
|
471
|
-
var
|
|
472
|
-
T &&
|
|
470
|
+
if (T || W) {
|
|
471
|
+
var Q = typeof o == "function" ? o.displayName || o.name || "Unknown" : o;
|
|
472
|
+
T && Us(x, Q), W && Ms(x, Q);
|
|
473
473
|
}
|
|
474
|
-
return
|
|
474
|
+
return Ns(o, T, W, D, R, Br.current, x);
|
|
475
475
|
}
|
|
476
476
|
}
|
|
477
|
-
var Jt =
|
|
478
|
-
function
|
|
477
|
+
var Jt = S.ReactCurrentOwner, Jr = S.ReactDebugCurrentFrame;
|
|
478
|
+
function He(o) {
|
|
479
479
|
if (o) {
|
|
480
480
|
var p = o._owner, b = Dt(o.type, o._source, p ? p.type : null);
|
|
481
|
-
|
|
481
|
+
Jr.setExtraStackFrame(b);
|
|
482
482
|
} else
|
|
483
|
-
|
|
483
|
+
Jr.setExtraStackFrame(null);
|
|
484
484
|
}
|
|
485
485
|
var Xt;
|
|
486
486
|
Xt = !1;
|
|
487
487
|
function Zt(o) {
|
|
488
488
|
return typeof o == "object" && o !== null && o.$$typeof === e;
|
|
489
489
|
}
|
|
490
|
-
function
|
|
490
|
+
function Xr() {
|
|
491
491
|
{
|
|
492
492
|
if (Jt.current) {
|
|
493
493
|
var o = be(Jt.current.type);
|
|
@@ -499,13 +499,13 @@ Check the render method of \`` + o + "`.";
|
|
|
499
499
|
return "";
|
|
500
500
|
}
|
|
501
501
|
}
|
|
502
|
-
function
|
|
502
|
+
function Qs(o) {
|
|
503
503
|
return "";
|
|
504
504
|
}
|
|
505
|
-
var
|
|
506
|
-
function
|
|
505
|
+
var Zr = {};
|
|
506
|
+
function $s(o) {
|
|
507
507
|
{
|
|
508
|
-
var p =
|
|
508
|
+
var p = Xr();
|
|
509
509
|
if (!p) {
|
|
510
510
|
var b = typeof o == "string" ? o : o.displayName || o.name;
|
|
511
511
|
b && (p = `
|
|
@@ -515,39 +515,39 @@ Check the top-level render call using <` + b + ">.");
|
|
|
515
515
|
return p;
|
|
516
516
|
}
|
|
517
517
|
}
|
|
518
|
-
function
|
|
518
|
+
function en(o, p) {
|
|
519
519
|
{
|
|
520
520
|
if (!o._store || o._store.validated || o.key != null)
|
|
521
521
|
return;
|
|
522
522
|
o._store.validated = !0;
|
|
523
|
-
var b =
|
|
524
|
-
if (
|
|
523
|
+
var b = $s(p);
|
|
524
|
+
if (Zr[b])
|
|
525
525
|
return;
|
|
526
|
-
|
|
526
|
+
Zr[b] = !0;
|
|
527
527
|
var R = "";
|
|
528
|
-
o && o._owner && o._owner !== Jt.current && (R = " It was passed a child from " + be(o._owner.type) + "."),
|
|
528
|
+
o && o._owner && o._owner !== Jt.current && (R = " It was passed a child from " + be(o._owner.type) + "."), He(o), E('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', b, R), He(null);
|
|
529
529
|
}
|
|
530
530
|
}
|
|
531
|
-
function
|
|
531
|
+
function tn(o, p) {
|
|
532
532
|
{
|
|
533
533
|
if (typeof o != "object")
|
|
534
534
|
return;
|
|
535
535
|
if (Yt(o))
|
|
536
536
|
for (var b = 0; b < o.length; b++) {
|
|
537
537
|
var R = o[b];
|
|
538
|
-
Zt(R) &&
|
|
538
|
+
Zt(R) && en(R, p);
|
|
539
539
|
}
|
|
540
540
|
else if (Zt(o))
|
|
541
541
|
o._store && (o._store.validated = !0);
|
|
542
542
|
else if (o) {
|
|
543
|
-
var
|
|
544
|
-
if (typeof
|
|
545
|
-
for (var k =
|
|
546
|
-
Zt(x.value) &&
|
|
543
|
+
var D = O(o);
|
|
544
|
+
if (typeof D == "function" && D !== o.entries)
|
|
545
|
+
for (var k = D.call(o), x; !(x = k.next()).done; )
|
|
546
|
+
Zt(x.value) && en(x.value, p);
|
|
547
547
|
}
|
|
548
548
|
}
|
|
549
549
|
}
|
|
550
|
-
function
|
|
550
|
+
function Ks(o) {
|
|
551
551
|
{
|
|
552
552
|
var p = o.type;
|
|
553
553
|
if (p == null || typeof p == "string")
|
|
@@ -563,97 +563,97 @@ Check the top-level render call using <` + b + ">.");
|
|
|
563
563
|
return;
|
|
564
564
|
if (b) {
|
|
565
565
|
var R = be(p);
|
|
566
|
-
|
|
566
|
+
As(b, o.props, "prop", R, o);
|
|
567
567
|
} else if (p.PropTypes !== void 0 && !Xt) {
|
|
568
568
|
Xt = !0;
|
|
569
|
-
var
|
|
570
|
-
|
|
569
|
+
var D = be(p);
|
|
570
|
+
E("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", D || "Unknown");
|
|
571
571
|
}
|
|
572
|
-
typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved &&
|
|
572
|
+
typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved && E("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
573
573
|
}
|
|
574
574
|
}
|
|
575
|
-
function
|
|
575
|
+
function zs(o) {
|
|
576
576
|
{
|
|
577
577
|
for (var p = Object.keys(o.props), b = 0; b < p.length; b++) {
|
|
578
578
|
var R = p[b];
|
|
579
579
|
if (R !== "children" && R !== "key") {
|
|
580
|
-
|
|
580
|
+
He(o), E("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", R), He(null);
|
|
581
581
|
break;
|
|
582
582
|
}
|
|
583
583
|
}
|
|
584
|
-
o.ref !== null && (
|
|
584
|
+
o.ref !== null && (He(o), E("Invalid attribute `ref` supplied to `React.Fragment`."), He(null));
|
|
585
585
|
}
|
|
586
586
|
}
|
|
587
|
-
var
|
|
588
|
-
function
|
|
587
|
+
var rn = {};
|
|
588
|
+
function nn(o, p, b, R, D, k) {
|
|
589
589
|
{
|
|
590
590
|
var x = ge(o);
|
|
591
591
|
if (!x) {
|
|
592
592
|
var T = "";
|
|
593
593
|
(o === void 0 || typeof o == "object" && o !== null && Object.keys(o).length === 0) && (T += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
594
|
-
var
|
|
595
|
-
|
|
596
|
-
var
|
|
597
|
-
o === null ?
|
|
594
|
+
var W = Qs();
|
|
595
|
+
W ? T += W : T += Xr();
|
|
596
|
+
var L;
|
|
597
|
+
o === null ? L = "null" : Yt(o) ? L = "array" : o !== void 0 && o.$$typeof === e ? (L = "<" + (be(o.type) || "Unknown") + " />", T = " Did you accidentally export a JSX literal instead of a component?") : L = typeof o, E("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", L, T);
|
|
598
598
|
}
|
|
599
|
-
var
|
|
600
|
-
if (
|
|
601
|
-
return
|
|
599
|
+
var Q = Ls(o, p, b, D, k);
|
|
600
|
+
if (Q == null)
|
|
601
|
+
return Q;
|
|
602
602
|
if (x) {
|
|
603
603
|
var ee = p.children;
|
|
604
604
|
if (ee !== void 0)
|
|
605
605
|
if (R)
|
|
606
606
|
if (Yt(ee)) {
|
|
607
607
|
for (var Be = 0; Be < ee.length; Be++)
|
|
608
|
-
|
|
608
|
+
tn(ee[Be], o);
|
|
609
609
|
Object.freeze && Object.freeze(ee);
|
|
610
610
|
} else
|
|
611
|
-
|
|
611
|
+
E("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
612
612
|
else
|
|
613
|
-
|
|
613
|
+
tn(ee, o);
|
|
614
614
|
}
|
|
615
615
|
if (yt.call(p, "key")) {
|
|
616
|
-
var ke = be(o), Y = Object.keys(p).filter(function(
|
|
617
|
-
return
|
|
616
|
+
var ke = be(o), Y = Object.keys(p).filter(function(Ys) {
|
|
617
|
+
return Ys !== "key";
|
|
618
618
|
}), er = Y.length > 0 ? "{key: someKey, " + Y.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
619
|
-
if (!
|
|
620
|
-
var
|
|
621
|
-
|
|
619
|
+
if (!rn[ke + er]) {
|
|
620
|
+
var Gs = Y.length > 0 ? "{" + Y.join(": ..., ") + ": ...}" : "{}";
|
|
621
|
+
E(`A props object containing a "key" prop is being spread into JSX:
|
|
622
622
|
let props = %s;
|
|
623
623
|
<%s {...props} />
|
|
624
624
|
React keys must be passed directly to JSX without using spread:
|
|
625
625
|
let props = %s;
|
|
626
|
-
<%s key={someKey} {...props} />`, er, ke,
|
|
626
|
+
<%s key={someKey} {...props} />`, er, ke, Gs, ke), rn[ke + er] = !0;
|
|
627
627
|
}
|
|
628
628
|
}
|
|
629
|
-
return o === n ?
|
|
629
|
+
return o === n ? zs(Q) : Ks(Q), Q;
|
|
630
630
|
}
|
|
631
631
|
}
|
|
632
|
-
function zs(o, p, b) {
|
|
633
|
-
return rn(o, p, b, !0);
|
|
634
|
-
}
|
|
635
632
|
function Vs(o, p, b) {
|
|
636
|
-
return
|
|
633
|
+
return nn(o, p, b, !0);
|
|
634
|
+
}
|
|
635
|
+
function Ws(o, p, b) {
|
|
636
|
+
return nn(o, p, b, !1);
|
|
637
637
|
}
|
|
638
|
-
var Hs =
|
|
639
|
-
mt.Fragment = n, mt.jsx = Hs, mt.jsxs =
|
|
638
|
+
var Hs = Ws, Bs = Vs;
|
|
639
|
+
mt.Fragment = n, mt.jsx = Hs, mt.jsxs = Bs;
|
|
640
640
|
}()), mt;
|
|
641
641
|
}
|
|
642
|
-
process.env.NODE_ENV === "production" ? ur.exports =
|
|
643
|
-
var wt = ur.exports, cr = /* @__PURE__ */ ((t) => (t.NOT_CHUNKED = "NOT_CHUNKED", t.PROCESSING = "PROCESSING", t.CHUNKED = "CHUNKED", t.ERROR_CHUNKING = "ERROR_CHUNKING", t))(cr || {}),
|
|
644
|
-
const gt = 4e3 * 1024 * 1024,
|
|
642
|
+
process.env.NODE_ENV === "production" ? ur.exports = ni() : ur.exports = si();
|
|
643
|
+
var wt = ur.exports, cr = /* @__PURE__ */ ((t) => (t.NOT_CHUNKED = "NOT_CHUNKED", t.PROCESSING = "PROCESSING", t.CHUNKED = "CHUNKED", t.ERROR_CHUNKING = "ERROR_CHUNKING", t))(cr || {}), xr = /* @__PURE__ */ ((t) => (t.PDF = "application/pdf", t.TXT = "text/plain", t.CSV = "text/csv", t.DIRECTORY = "inode/directory", t.DOCX = "application/vnd.openxmlformats-officedocument.wordprocessingml.document", t))(xr || {});
|
|
644
|
+
const gt = 4e3 * 1024 * 1024, ii = [
|
|
645
645
|
".txt",
|
|
646
646
|
".json",
|
|
647
647
|
".py",
|
|
648
648
|
".ts",
|
|
649
649
|
".tsx"
|
|
650
|
-
],
|
|
650
|
+
], Wn = {
|
|
651
651
|
"application/pdf": {
|
|
652
652
|
extensions: [".pdf"],
|
|
653
653
|
maxSize: gt
|
|
654
654
|
},
|
|
655
655
|
"text/plain": {
|
|
656
|
-
extensions:
|
|
656
|
+
extensions: ii,
|
|
657
657
|
maxSize: gt
|
|
658
658
|
},
|
|
659
659
|
"text/csv": {
|
|
@@ -669,14 +669,14 @@ const gt = 4e3 * 1024 * 1024, si = [
|
|
|
669
669
|
maxSize: gt
|
|
670
670
|
}
|
|
671
671
|
};
|
|
672
|
-
Object.entries(
|
|
672
|
+
Object.entries(Wn).reduce(
|
|
673
673
|
(t, [e, r]) => ({
|
|
674
674
|
...t,
|
|
675
675
|
[e]: r.extensions
|
|
676
676
|
}),
|
|
677
677
|
{}
|
|
678
678
|
);
|
|
679
|
-
const
|
|
679
|
+
const oi = new Set(Object.values(xr));
|
|
680
680
|
var ft = class {
|
|
681
681
|
constructor() {
|
|
682
682
|
this.listeners = /* @__PURE__ */ new Set(), this.subscribe = this.subscribe.bind(this);
|
|
@@ -696,7 +696,7 @@ var ft = class {
|
|
|
696
696
|
}, ze = typeof window > "u" || "Deno" in globalThis;
|
|
697
697
|
function re() {
|
|
698
698
|
}
|
|
699
|
-
function
|
|
699
|
+
function ai(t, e) {
|
|
700
700
|
return typeof t == "function" ? t(e) : t;
|
|
701
701
|
}
|
|
702
702
|
function lr(t) {
|
|
@@ -711,7 +711,7 @@ function Ye(t, e) {
|
|
|
711
711
|
function oe(t, e) {
|
|
712
712
|
return typeof t == "function" ? t(e) : t;
|
|
713
713
|
}
|
|
714
|
-
function
|
|
714
|
+
function un(t, e) {
|
|
715
715
|
const {
|
|
716
716
|
type: r = "all",
|
|
717
717
|
exact: n,
|
|
@@ -722,7 +722,7 @@ function an(t, e) {
|
|
|
722
722
|
} = t;
|
|
723
723
|
if (u) {
|
|
724
724
|
if (n) {
|
|
725
|
-
if (e.queryHash !==
|
|
725
|
+
if (e.queryHash !== Ir(u, e.options))
|
|
726
726
|
return !1;
|
|
727
727
|
} else if (!Et(e.queryKey, u))
|
|
728
728
|
return !1;
|
|
@@ -734,7 +734,7 @@ function an(t, e) {
|
|
|
734
734
|
}
|
|
735
735
|
return !(typeof l == "boolean" && e.isStale() !== l || s && s !== e.state.fetchStatus || i && !i(e));
|
|
736
736
|
}
|
|
737
|
-
function
|
|
737
|
+
function cn(t, e) {
|
|
738
738
|
const { exact: r, status: n, predicate: s, mutationKey: i } = t;
|
|
739
739
|
if (i) {
|
|
740
740
|
if (!e.options.mutationKey)
|
|
@@ -747,7 +747,7 @@ function un(t, e) {
|
|
|
747
747
|
}
|
|
748
748
|
return !(n && e.state.status !== n || s && !s(e));
|
|
749
749
|
}
|
|
750
|
-
function
|
|
750
|
+
function Ir(t, e) {
|
|
751
751
|
return ((e == null ? void 0 : e.queryKeyHashFn) || Ve)(t);
|
|
752
752
|
}
|
|
753
753
|
function Ve(t) {
|
|
@@ -762,7 +762,7 @@ function Et(t, e) {
|
|
|
762
762
|
function fr(t, e) {
|
|
763
763
|
if (t === e)
|
|
764
764
|
return t;
|
|
765
|
-
const r =
|
|
765
|
+
const r = ln(t) && ln(e);
|
|
766
766
|
if (r || dr(t) && dr(e)) {
|
|
767
767
|
const n = r ? t : Object.keys(t), s = n.length, i = r ? e : Object.keys(e), u = i.length, l = r ? [] : {};
|
|
768
768
|
let c = 0;
|
|
@@ -782,22 +782,22 @@ function Nt(t, e) {
|
|
|
782
782
|
return !1;
|
|
783
783
|
return !0;
|
|
784
784
|
}
|
|
785
|
-
function
|
|
785
|
+
function ln(t) {
|
|
786
786
|
return Array.isArray(t) && t.length === Object.keys(t).length;
|
|
787
787
|
}
|
|
788
788
|
function dr(t) {
|
|
789
|
-
if (!
|
|
789
|
+
if (!fn(t))
|
|
790
790
|
return !1;
|
|
791
791
|
const e = t.constructor;
|
|
792
792
|
if (e === void 0)
|
|
793
793
|
return !0;
|
|
794
794
|
const r = e.prototype;
|
|
795
|
-
return !(!
|
|
795
|
+
return !(!fn(r) || !r.hasOwnProperty("isPrototypeOf") || Object.getPrototypeOf(t) !== Object.prototype);
|
|
796
796
|
}
|
|
797
|
-
function
|
|
797
|
+
function fn(t) {
|
|
798
798
|
return Object.prototype.toString.call(t) === "[object Object]";
|
|
799
799
|
}
|
|
800
|
-
function
|
|
800
|
+
function ui(t) {
|
|
801
801
|
return new Promise((e) => {
|
|
802
802
|
setTimeout(e, t);
|
|
803
803
|
});
|
|
@@ -818,21 +818,21 @@ function hr(t, e, r) {
|
|
|
818
818
|
}
|
|
819
819
|
return e;
|
|
820
820
|
}
|
|
821
|
-
function
|
|
821
|
+
function ci(t, e, r = 0) {
|
|
822
822
|
const n = [...t, e];
|
|
823
823
|
return r && n.length > r ? n.slice(1) : n;
|
|
824
824
|
}
|
|
825
|
-
function
|
|
825
|
+
function li(t, e, r = 0) {
|
|
826
826
|
const n = [e, ...t];
|
|
827
827
|
return r && n.length > r ? n.slice(0, -1) : n;
|
|
828
828
|
}
|
|
829
829
|
var Lt = Symbol();
|
|
830
|
-
function
|
|
830
|
+
function Bn(t, e) {
|
|
831
831
|
return process.env.NODE_ENV !== "production" && t.queryFn === Lt && console.error(
|
|
832
832
|
`Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${t.queryHash}'`
|
|
833
833
|
), !t.queryFn && (e != null && e.initialPromise) ? () => e.initialPromise : !t.queryFn || t.queryFn === Lt ? () => Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)) : t.queryFn;
|
|
834
834
|
}
|
|
835
|
-
var qe, Ee, Je,
|
|
835
|
+
var qe, Ee, Je, An, fi = (An = class extends ft {
|
|
836
836
|
constructor() {
|
|
837
837
|
super();
|
|
838
838
|
w(this, qe);
|
|
@@ -873,7 +873,7 @@ var qe, Ee, Je, Fn, li = (Fn = class extends ft {
|
|
|
873
873
|
var e;
|
|
874
874
|
return typeof a(this, qe) == "boolean" ? a(this, qe) : ((e = globalThis.document) == null ? void 0 : e.visibilityState) !== "hidden";
|
|
875
875
|
}
|
|
876
|
-
}, qe = new WeakMap(), Ee = new WeakMap(), Je = new WeakMap(),
|
|
876
|
+
}, qe = new WeakMap(), Ee = new WeakMap(), Je = new WeakMap(), An), Dr = new fi(), Xe, Pe, Ze, xn, di = (xn = class extends ft {
|
|
877
877
|
constructor() {
|
|
878
878
|
super();
|
|
879
879
|
w(this, Xe, !0);
|
|
@@ -907,7 +907,7 @@ var qe, Ee, Je, Fn, li = (Fn = class extends ft {
|
|
|
907
907
|
isOnline() {
|
|
908
908
|
return a(this, Xe);
|
|
909
909
|
}
|
|
910
|
-
}, Xe = new WeakMap(), Pe = new WeakMap(), Ze = new WeakMap(),
|
|
910
|
+
}, Xe = new WeakMap(), Pe = new WeakMap(), Ze = new WeakMap(), xn), Qt = new di();
|
|
911
911
|
function yr() {
|
|
912
912
|
let t, e;
|
|
913
913
|
const r = new Promise((s, i) => {
|
|
@@ -930,30 +930,30 @@ function yr() {
|
|
|
930
930
|
}), e(s);
|
|
931
931
|
}, r;
|
|
932
932
|
}
|
|
933
|
-
function
|
|
933
|
+
function hi(t) {
|
|
934
934
|
return Math.min(1e3 * 2 ** t, 3e4);
|
|
935
935
|
}
|
|
936
|
-
function
|
|
936
|
+
function Gn(t) {
|
|
937
937
|
return (t ?? "online") === "online" ? Qt.isOnline() : !0;
|
|
938
938
|
}
|
|
939
|
-
var
|
|
939
|
+
var Yn = class extends Error {
|
|
940
940
|
constructor(t) {
|
|
941
941
|
super("CancelledError"), this.revert = t == null ? void 0 : t.revert, this.silent = t == null ? void 0 : t.silent;
|
|
942
942
|
}
|
|
943
943
|
};
|
|
944
944
|
function sr(t) {
|
|
945
|
-
return t instanceof
|
|
945
|
+
return t instanceof Yn;
|
|
946
946
|
}
|
|
947
|
-
function
|
|
947
|
+
function Jn(t) {
|
|
948
948
|
let e = !1, r = 0, n = !1, s;
|
|
949
949
|
const i = yr(), u = (g) => {
|
|
950
950
|
var O;
|
|
951
|
-
n || (h(new
|
|
951
|
+
n || (h(new Yn(g)), (O = t.abort) == null || O.call(t));
|
|
952
952
|
}, l = () => {
|
|
953
953
|
e = !0;
|
|
954
954
|
}, c = () => {
|
|
955
955
|
e = !1;
|
|
956
|
-
}, y = () =>
|
|
956
|
+
}, y = () => Dr.isFocused() && (t.networkMode === "always" || Qt.isOnline()) && t.canRun(), f = () => Gn(t.networkMode) && t.canRun(), d = (g) => {
|
|
957
957
|
var O;
|
|
958
958
|
n || (n = !0, (O = t.onSuccess) == null || O.call(t, g), s == null || s(), i.resolve(g));
|
|
959
959
|
}, h = (g) => {
|
|
@@ -961,33 +961,33 @@ function Yn(t) {
|
|
|
961
961
|
n || (n = !0, (O = t.onError) == null || O.call(t, g), s == null || s(), i.reject(g));
|
|
962
962
|
}, m = () => new Promise((g) => {
|
|
963
963
|
var O;
|
|
964
|
-
s = (
|
|
965
|
-
(n || y()) && g(
|
|
964
|
+
s = (S) => {
|
|
965
|
+
(n || y()) && g(S);
|
|
966
966
|
}, (O = t.onPause) == null || O.call(t);
|
|
967
967
|
}).then(() => {
|
|
968
968
|
var g;
|
|
969
969
|
s = void 0, n || (g = t.onContinue) == null || g.call(t);
|
|
970
|
-
}),
|
|
970
|
+
}), P = () => {
|
|
971
971
|
if (n)
|
|
972
972
|
return;
|
|
973
973
|
let g;
|
|
974
974
|
const O = r === 0 ? t.initialPromise : void 0;
|
|
975
975
|
try {
|
|
976
976
|
g = O ?? t.fn();
|
|
977
|
-
} catch (
|
|
978
|
-
g = Promise.reject(
|
|
977
|
+
} catch (S) {
|
|
978
|
+
g = Promise.reject(S);
|
|
979
979
|
}
|
|
980
|
-
Promise.resolve(g).then(d).catch((
|
|
980
|
+
Promise.resolve(g).then(d).catch((S) => {
|
|
981
981
|
var Z;
|
|
982
982
|
if (n)
|
|
983
983
|
return;
|
|
984
|
-
const
|
|
985
|
-
if (e || !
|
|
986
|
-
h(
|
|
984
|
+
const E = t.retry ?? (ze ? 0 : 3), I = t.retryDelay ?? hi, q = typeof I == "function" ? I(r, S) : I, N = E === !0 || typeof E == "number" && r < E || typeof E == "function" && E(r, S);
|
|
985
|
+
if (e || !N) {
|
|
986
|
+
h(S);
|
|
987
987
|
return;
|
|
988
988
|
}
|
|
989
|
-
r++, (Z = t.onFail) == null || Z.call(t, r,
|
|
990
|
-
e ? h(
|
|
989
|
+
r++, (Z = t.onFail) == null || Z.call(t, r, S), ui(q).then(() => y() ? void 0 : m()).then(() => {
|
|
990
|
+
e ? h(S) : P();
|
|
991
991
|
});
|
|
992
992
|
});
|
|
993
993
|
};
|
|
@@ -998,10 +998,10 @@ function Yn(t) {
|
|
|
998
998
|
cancelRetry: l,
|
|
999
999
|
continueRetry: c,
|
|
1000
1000
|
canStart: f,
|
|
1001
|
-
start: () => (f() ?
|
|
1001
|
+
start: () => (f() ? P() : m().then(P), i)
|
|
1002
1002
|
};
|
|
1003
1003
|
}
|
|
1004
|
-
function
|
|
1004
|
+
function yi() {
|
|
1005
1005
|
let t = [], e = 0, r = (l) => {
|
|
1006
1006
|
l();
|
|
1007
1007
|
}, n = (l) => {
|
|
@@ -1060,7 +1060,7 @@ function hi() {
|
|
|
1060
1060
|
}
|
|
1061
1061
|
};
|
|
1062
1062
|
}
|
|
1063
|
-
var
|
|
1063
|
+
var $ = yi(), Ue, In, Xn = (In = class {
|
|
1064
1064
|
constructor() {
|
|
1065
1065
|
w(this, Ue);
|
|
1066
1066
|
}
|
|
@@ -1081,7 +1081,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1081
1081
|
clearGcTimeout() {
|
|
1082
1082
|
a(this, Ue) && (clearTimeout(a(this, Ue)), v(this, Ue, void 0));
|
|
1083
1083
|
}
|
|
1084
|
-
}, Ue = new WeakMap(),
|
|
1084
|
+
}, Ue = new WeakMap(), In), et, tt, te, Me, V, Ct, Ne, se, he, Dn, pi = (Dn = class extends Xn {
|
|
1085
1085
|
constructor(e) {
|
|
1086
1086
|
super();
|
|
1087
1087
|
w(this, se);
|
|
@@ -1092,7 +1092,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1092
1092
|
w(this, V);
|
|
1093
1093
|
w(this, Ct);
|
|
1094
1094
|
w(this, Ne);
|
|
1095
|
-
v(this, Ne, !1), v(this, Ct, e.defaultOptions), this.setOptions(e.options), this.observers = [], v(this, Me, e.client), v(this, te, a(this, Me).getQueryCache()), this.queryKey = e.queryKey, this.queryHash = e.queryHash, v(this, et,
|
|
1095
|
+
v(this, Ne, !1), v(this, Ct, e.defaultOptions), this.setOptions(e.options), this.observers = [], v(this, Me, e.client), v(this, te, a(this, Me).getQueryCache()), this.queryKey = e.queryKey, this.queryHash = e.queryHash, v(this, et, mi(this.options)), this.state = e.state ?? a(this, et), this.scheduleGc();
|
|
1096
1096
|
}
|
|
1097
1097
|
get meta() {
|
|
1098
1098
|
return this.options.meta;
|
|
@@ -1109,7 +1109,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1109
1109
|
}
|
|
1110
1110
|
setData(e, r) {
|
|
1111
1111
|
const n = hr(this.state.data, e, this.options);
|
|
1112
|
-
return
|
|
1112
|
+
return C(this, se, he).call(this, {
|
|
1113
1113
|
data: n,
|
|
1114
1114
|
type: "success",
|
|
1115
1115
|
dataUpdatedAt: r == null ? void 0 : r.updatedAt,
|
|
@@ -1117,7 +1117,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1117
1117
|
}), n;
|
|
1118
1118
|
}
|
|
1119
1119
|
setState(e, r) {
|
|
1120
|
-
|
|
1120
|
+
C(this, se, he).call(this, { type: "setState", state: e, setStateOptions: r });
|
|
1121
1121
|
}
|
|
1122
1122
|
cancel(e) {
|
|
1123
1123
|
var n, s;
|
|
@@ -1166,7 +1166,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1166
1166
|
return this.observers.length;
|
|
1167
1167
|
}
|
|
1168
1168
|
invalidate() {
|
|
1169
|
-
this.state.isInvalidated ||
|
|
1169
|
+
this.state.isInvalidated || C(this, se, he).call(this, { type: "invalidate" });
|
|
1170
1170
|
}
|
|
1171
1171
|
fetch(e, r) {
|
|
1172
1172
|
var c, y, f;
|
|
@@ -1189,7 +1189,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1189
1189
|
get: () => (v(this, Ne, !0), n.signal)
|
|
1190
1190
|
});
|
|
1191
1191
|
}, i = () => {
|
|
1192
|
-
const d =
|
|
1192
|
+
const d = Bn(this.options, r), h = {
|
|
1193
1193
|
client: a(this, Me),
|
|
1194
1194
|
queryKey: this.queryKey,
|
|
1195
1195
|
meta: this.meta
|
|
@@ -1210,29 +1210,29 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1210
1210
|
s(u), (c = this.options.behavior) == null || c.onFetch(
|
|
1211
1211
|
u,
|
|
1212
1212
|
this
|
|
1213
|
-
), v(this, tt, this.state), (this.state.fetchStatus === "idle" || this.state.fetchMeta !== ((y = u.fetchOptions) == null ? void 0 : y.meta)) &&
|
|
1213
|
+
), v(this, tt, this.state), (this.state.fetchStatus === "idle" || this.state.fetchMeta !== ((y = u.fetchOptions) == null ? void 0 : y.meta)) && C(this, se, he).call(this, { type: "fetch", meta: (f = u.fetchOptions) == null ? void 0 : f.meta });
|
|
1214
1214
|
const l = (d) => {
|
|
1215
|
-
var h, m,
|
|
1216
|
-
sr(d) && d.silent ||
|
|
1215
|
+
var h, m, P, g;
|
|
1216
|
+
sr(d) && d.silent || C(this, se, he).call(this, {
|
|
1217
1217
|
type: "error",
|
|
1218
1218
|
error: d
|
|
1219
1219
|
}), sr(d) || ((m = (h = a(this, te).config).onError) == null || m.call(
|
|
1220
1220
|
h,
|
|
1221
1221
|
d,
|
|
1222
1222
|
this
|
|
1223
|
-
), (g = (
|
|
1224
|
-
|
|
1223
|
+
), (g = (P = a(this, te).config).onSettled) == null || g.call(
|
|
1224
|
+
P,
|
|
1225
1225
|
this.state.data,
|
|
1226
1226
|
d,
|
|
1227
1227
|
this
|
|
1228
1228
|
)), this.scheduleGc();
|
|
1229
1229
|
};
|
|
1230
|
-
return v(this, V,
|
|
1230
|
+
return v(this, V, Jn({
|
|
1231
1231
|
initialPromise: r == null ? void 0 : r.initialPromise,
|
|
1232
1232
|
fn: u.fetchFn,
|
|
1233
1233
|
abort: n.abort.bind(n),
|
|
1234
1234
|
onSuccess: (d) => {
|
|
1235
|
-
var h, m,
|
|
1235
|
+
var h, m, P, g;
|
|
1236
1236
|
if (d === void 0) {
|
|
1237
1237
|
process.env.NODE_ENV !== "production" && console.error(
|
|
1238
1238
|
`Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`
|
|
@@ -1245,8 +1245,8 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1245
1245
|
l(O);
|
|
1246
1246
|
return;
|
|
1247
1247
|
}
|
|
1248
|
-
(m = (h = a(this, te).config).onSuccess) == null || m.call(h, d, this), (g = (
|
|
1249
|
-
|
|
1248
|
+
(m = (h = a(this, te).config).onSuccess) == null || m.call(h, d, this), (g = (P = a(this, te).config).onSettled) == null || g.call(
|
|
1249
|
+
P,
|
|
1250
1250
|
d,
|
|
1251
1251
|
this.state.error,
|
|
1252
1252
|
this
|
|
@@ -1254,13 +1254,13 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1254
1254
|
},
|
|
1255
1255
|
onError: l,
|
|
1256
1256
|
onFail: (d, h) => {
|
|
1257
|
-
|
|
1257
|
+
C(this, se, he).call(this, { type: "failed", failureCount: d, error: h });
|
|
1258
1258
|
},
|
|
1259
1259
|
onPause: () => {
|
|
1260
|
-
|
|
1260
|
+
C(this, se, he).call(this, { type: "pause" });
|
|
1261
1261
|
},
|
|
1262
1262
|
onContinue: () => {
|
|
1263
|
-
|
|
1263
|
+
C(this, se, he).call(this, { type: "continue" });
|
|
1264
1264
|
},
|
|
1265
1265
|
retry: u.options.retry,
|
|
1266
1266
|
retryDelay: u.options.retryDelay,
|
|
@@ -1290,7 +1290,7 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1290
1290
|
case "fetch":
|
|
1291
1291
|
return {
|
|
1292
1292
|
...n,
|
|
1293
|
-
...
|
|
1293
|
+
...Zn(n.data, this.options),
|
|
1294
1294
|
fetchMeta: e.meta ?? null
|
|
1295
1295
|
};
|
|
1296
1296
|
case "success":
|
|
@@ -1332,24 +1332,24 @@ var Q = hi(), Ue, xn, Jn = (xn = class {
|
|
|
1332
1332
|
};
|
|
1333
1333
|
}
|
|
1334
1334
|
};
|
|
1335
|
-
this.state = r(this.state),
|
|
1335
|
+
this.state = r(this.state), $.batch(() => {
|
|
1336
1336
|
this.observers.forEach((n) => {
|
|
1337
1337
|
n.onQueryUpdate();
|
|
1338
1338
|
}), a(this, te).notify({ query: this, type: "updated", action: e });
|
|
1339
1339
|
});
|
|
1340
|
-
},
|
|
1341
|
-
function
|
|
1340
|
+
}, Dn);
|
|
1341
|
+
function Zn(t, e) {
|
|
1342
1342
|
return {
|
|
1343
1343
|
fetchFailureCount: 0,
|
|
1344
1344
|
fetchFailureReason: null,
|
|
1345
|
-
fetchStatus:
|
|
1345
|
+
fetchStatus: Gn(e.networkMode) ? "fetching" : "paused",
|
|
1346
1346
|
...t === void 0 && {
|
|
1347
1347
|
error: null,
|
|
1348
1348
|
status: "pending"
|
|
1349
1349
|
}
|
|
1350
1350
|
};
|
|
1351
1351
|
}
|
|
1352
|
-
function
|
|
1352
|
+
function mi(t) {
|
|
1353
1353
|
const e = typeof t.initialData == "function" ? t.initialData() : t.initialData, r = e !== void 0, n = r ? typeof t.initialDataUpdatedAt == "function" ? t.initialDataUpdatedAt() : t.initialDataUpdatedAt : 0;
|
|
1354
1354
|
return {
|
|
1355
1355
|
data: e,
|
|
@@ -1366,16 +1366,16 @@ function pi(t) {
|
|
|
1366
1366
|
fetchStatus: "idle"
|
|
1367
1367
|
};
|
|
1368
1368
|
}
|
|
1369
|
-
var ue,
|
|
1369
|
+
var ue, _n, gi = (_n = class extends ft {
|
|
1370
1370
|
constructor(e = {}) {
|
|
1371
1371
|
super();
|
|
1372
1372
|
w(this, ue);
|
|
1373
1373
|
this.config = e, v(this, ue, /* @__PURE__ */ new Map());
|
|
1374
1374
|
}
|
|
1375
1375
|
build(e, r, n) {
|
|
1376
|
-
const s = r.queryKey, i = r.queryHash ??
|
|
1376
|
+
const s = r.queryKey, i = r.queryHash ?? Ir(s, r);
|
|
1377
1377
|
let u = this.get(i);
|
|
1378
|
-
return u || (u = new
|
|
1378
|
+
return u || (u = new pi({
|
|
1379
1379
|
client: e,
|
|
1380
1380
|
queryKey: s,
|
|
1381
1381
|
queryHash: i,
|
|
@@ -1395,7 +1395,7 @@ var ue, Dn, mi = (Dn = class extends ft {
|
|
|
1395
1395
|
r && (e.destroy(), r === e && a(this, ue).delete(e.queryHash), this.notify({ type: "removed", query: e }));
|
|
1396
1396
|
}
|
|
1397
1397
|
clear() {
|
|
1398
|
-
|
|
1398
|
+
$.batch(() => {
|
|
1399
1399
|
this.getAll().forEach((e) => {
|
|
1400
1400
|
this.remove(e);
|
|
1401
1401
|
});
|
|
@@ -1410,42 +1410,42 @@ var ue, Dn, mi = (Dn = class extends ft {
|
|
|
1410
1410
|
find(e) {
|
|
1411
1411
|
const r = { exact: !0, ...e };
|
|
1412
1412
|
return this.getAll().find(
|
|
1413
|
-
(n) =>
|
|
1413
|
+
(n) => un(r, n)
|
|
1414
1414
|
);
|
|
1415
1415
|
}
|
|
1416
1416
|
findAll(e = {}) {
|
|
1417
1417
|
const r = this.getAll();
|
|
1418
|
-
return Object.keys(e).length > 0 ? r.filter((n) =>
|
|
1418
|
+
return Object.keys(e).length > 0 ? r.filter((n) => un(e, n)) : r;
|
|
1419
1419
|
}
|
|
1420
1420
|
notify(e) {
|
|
1421
|
-
|
|
1421
|
+
$.batch(() => {
|
|
1422
1422
|
this.listeners.forEach((r) => {
|
|
1423
1423
|
r(e);
|
|
1424
1424
|
});
|
|
1425
1425
|
});
|
|
1426
1426
|
}
|
|
1427
1427
|
onFocus() {
|
|
1428
|
-
|
|
1428
|
+
$.batch(() => {
|
|
1429
1429
|
this.getAll().forEach((e) => {
|
|
1430
1430
|
e.onFocus();
|
|
1431
1431
|
});
|
|
1432
1432
|
});
|
|
1433
1433
|
}
|
|
1434
1434
|
onOnline() {
|
|
1435
|
-
|
|
1435
|
+
$.batch(() => {
|
|
1436
1436
|
this.getAll().forEach((e) => {
|
|
1437
1437
|
e.onOnline();
|
|
1438
1438
|
});
|
|
1439
1439
|
});
|
|
1440
1440
|
}
|
|
1441
|
-
}, ue = new WeakMap(),
|
|
1441
|
+
}, ue = new WeakMap(), _n), ce, H, Le, le, we, kn, vi = (kn = class extends Xn {
|
|
1442
1442
|
constructor(e) {
|
|
1443
1443
|
super();
|
|
1444
1444
|
w(this, le);
|
|
1445
1445
|
w(this, ce);
|
|
1446
|
-
w(this,
|
|
1446
|
+
w(this, H);
|
|
1447
1447
|
w(this, Le);
|
|
1448
|
-
this.mutationId = e.mutationId, v(this,
|
|
1448
|
+
this.mutationId = e.mutationId, v(this, H, e.mutationCache), v(this, ce, []), this.state = e.state || es(), this.setOptions(e.options), this.scheduleGc();
|
|
1449
1449
|
}
|
|
1450
1450
|
setOptions(e) {
|
|
1451
1451
|
this.options = e, this.updateGcTime(this.options.gcTime);
|
|
@@ -1454,21 +1454,21 @@ var ue, Dn, mi = (Dn = class extends ft {
|
|
|
1454
1454
|
return this.options.meta;
|
|
1455
1455
|
}
|
|
1456
1456
|
addObserver(e) {
|
|
1457
|
-
a(this, ce).includes(e) || (a(this, ce).push(e), this.clearGcTimeout(), a(this,
|
|
1457
|
+
a(this, ce).includes(e) || (a(this, ce).push(e), this.clearGcTimeout(), a(this, H).notify({
|
|
1458
1458
|
type: "observerAdded",
|
|
1459
1459
|
mutation: this,
|
|
1460
1460
|
observer: e
|
|
1461
1461
|
}));
|
|
1462
1462
|
}
|
|
1463
1463
|
removeObserver(e) {
|
|
1464
|
-
v(this, ce, a(this, ce).filter((r) => r !== e)), this.scheduleGc(), a(this,
|
|
1464
|
+
v(this, ce, a(this, ce).filter((r) => r !== e)), this.scheduleGc(), a(this, H).notify({
|
|
1465
1465
|
type: "observerRemoved",
|
|
1466
1466
|
mutation: this,
|
|
1467
1467
|
observer: e
|
|
1468
1468
|
});
|
|
1469
1469
|
}
|
|
1470
1470
|
optionalRemove() {
|
|
1471
|
-
a(this, ce).length || (this.state.status === "pending" ? this.scheduleGc() : a(this,
|
|
1471
|
+
a(this, ce).length || (this.state.status === "pending" ? this.scheduleGc() : a(this, H).remove(this));
|
|
1472
1472
|
}
|
|
1473
1473
|
continue() {
|
|
1474
1474
|
var e;
|
|
@@ -1476,89 +1476,89 @@ var ue, Dn, mi = (Dn = class extends ft {
|
|
|
1476
1476
|
this.execute(this.state.variables);
|
|
1477
1477
|
}
|
|
1478
1478
|
async execute(e) {
|
|
1479
|
-
var s, i, u, l, c, y, f, d, h, m,
|
|
1480
|
-
v(this, Le,
|
|
1479
|
+
var s, i, u, l, c, y, f, d, h, m, P, g, O, S, E, I, q, N, Z, z;
|
|
1480
|
+
v(this, Le, Jn({
|
|
1481
1481
|
fn: () => this.options.mutationFn ? this.options.mutationFn(e) : Promise.reject(new Error("No mutationFn found")),
|
|
1482
|
-
onFail: (
|
|
1483
|
-
|
|
1482
|
+
onFail: (U, j) => {
|
|
1483
|
+
C(this, le, we).call(this, { type: "failed", failureCount: U, error: j });
|
|
1484
1484
|
},
|
|
1485
1485
|
onPause: () => {
|
|
1486
|
-
|
|
1486
|
+
C(this, le, we).call(this, { type: "pause" });
|
|
1487
1487
|
},
|
|
1488
1488
|
onContinue: () => {
|
|
1489
|
-
|
|
1489
|
+
C(this, le, we).call(this, { type: "continue" });
|
|
1490
1490
|
},
|
|
1491
1491
|
retry: this.options.retry ?? 0,
|
|
1492
1492
|
retryDelay: this.options.retryDelay,
|
|
1493
1493
|
networkMode: this.options.networkMode,
|
|
1494
|
-
canRun: () => a(this,
|
|
1494
|
+
canRun: () => a(this, H).canRun(this)
|
|
1495
1495
|
}));
|
|
1496
1496
|
const r = this.state.status === "pending", n = !a(this, Le).canStart();
|
|
1497
1497
|
try {
|
|
1498
1498
|
if (!r) {
|
|
1499
|
-
|
|
1499
|
+
C(this, le, we).call(this, { type: "pending", variables: e, isPaused: n }), await ((i = (s = a(this, H).config).onMutate) == null ? void 0 : i.call(
|
|
1500
1500
|
s,
|
|
1501
1501
|
e,
|
|
1502
1502
|
this
|
|
1503
1503
|
));
|
|
1504
1504
|
const j = await ((l = (u = this.options).onMutate) == null ? void 0 : l.call(u, e));
|
|
1505
|
-
j !== this.state.context &&
|
|
1505
|
+
j !== this.state.context && C(this, le, we).call(this, {
|
|
1506
1506
|
type: "pending",
|
|
1507
1507
|
context: j,
|
|
1508
1508
|
variables: e,
|
|
1509
1509
|
isPaused: n
|
|
1510
1510
|
});
|
|
1511
1511
|
}
|
|
1512
|
-
const
|
|
1513
|
-
return await ((y = (c = a(this,
|
|
1512
|
+
const U = await a(this, Le).start();
|
|
1513
|
+
return await ((y = (c = a(this, H).config).onSuccess) == null ? void 0 : y.call(
|
|
1514
1514
|
c,
|
|
1515
|
-
|
|
1515
|
+
U,
|
|
1516
1516
|
e,
|
|
1517
1517
|
this.state.context,
|
|
1518
1518
|
this
|
|
1519
|
-
)), await ((d = (f = this.options).onSuccess) == null ? void 0 : d.call(f,
|
|
1519
|
+
)), await ((d = (f = this.options).onSuccess) == null ? void 0 : d.call(f, U, e, this.state.context)), await ((m = (h = a(this, H).config).onSettled) == null ? void 0 : m.call(
|
|
1520
1520
|
h,
|
|
1521
|
-
|
|
1521
|
+
U,
|
|
1522
1522
|
null,
|
|
1523
1523
|
this.state.variables,
|
|
1524
1524
|
this.state.context,
|
|
1525
1525
|
this
|
|
1526
|
-
)), await ((g = (
|
|
1527
|
-
} catch (
|
|
1526
|
+
)), await ((g = (P = this.options).onSettled) == null ? void 0 : g.call(P, U, null, e, this.state.context)), C(this, le, we).call(this, { type: "success", data: U }), U;
|
|
1527
|
+
} catch (U) {
|
|
1528
1528
|
try {
|
|
1529
|
-
throw await ((
|
|
1529
|
+
throw await ((S = (O = a(this, H).config).onError) == null ? void 0 : S.call(
|
|
1530
1530
|
O,
|
|
1531
|
-
|
|
1531
|
+
U,
|
|
1532
1532
|
e,
|
|
1533
1533
|
this.state.context,
|
|
1534
1534
|
this
|
|
1535
|
-
)), await ((
|
|
1536
|
-
|
|
1537
|
-
|
|
1535
|
+
)), await ((I = (E = this.options).onError) == null ? void 0 : I.call(
|
|
1536
|
+
E,
|
|
1537
|
+
U,
|
|
1538
1538
|
e,
|
|
1539
1539
|
this.state.context
|
|
1540
|
-
)), await ((
|
|
1541
|
-
M,
|
|
1542
|
-
void 0,
|
|
1540
|
+
)), await ((N = (q = a(this, H).config).onSettled) == null ? void 0 : N.call(
|
|
1543
1541
|
q,
|
|
1542
|
+
void 0,
|
|
1543
|
+
U,
|
|
1544
1544
|
this.state.variables,
|
|
1545
1545
|
this.state.context,
|
|
1546
1546
|
this
|
|
1547
1547
|
)), await ((z = (Z = this.options).onSettled) == null ? void 0 : z.call(
|
|
1548
1548
|
Z,
|
|
1549
1549
|
void 0,
|
|
1550
|
-
|
|
1550
|
+
U,
|
|
1551
1551
|
e,
|
|
1552
1552
|
this.state.context
|
|
1553
|
-
)),
|
|
1553
|
+
)), U;
|
|
1554
1554
|
} finally {
|
|
1555
|
-
|
|
1555
|
+
C(this, le, we).call(this, { type: "error", error: U });
|
|
1556
1556
|
}
|
|
1557
1557
|
} finally {
|
|
1558
|
-
a(this,
|
|
1558
|
+
a(this, H).runNext(this);
|
|
1559
1559
|
}
|
|
1560
1560
|
}
|
|
1561
|
-
}, ce = new WeakMap(),
|
|
1561
|
+
}, ce = new WeakMap(), H = new WeakMap(), Le = new WeakMap(), le = new WeakSet(), we = function(e) {
|
|
1562
1562
|
const r = (n) => {
|
|
1563
1563
|
switch (e.type) {
|
|
1564
1564
|
case "failed":
|
|
@@ -1612,17 +1612,17 @@ var ue, Dn, mi = (Dn = class extends ft {
|
|
|
1612
1612
|
};
|
|
1613
1613
|
}
|
|
1614
1614
|
};
|
|
1615
|
-
this.state = r(this.state),
|
|
1615
|
+
this.state = r(this.state), $.batch(() => {
|
|
1616
1616
|
a(this, ce).forEach((n) => {
|
|
1617
1617
|
n.onMutationUpdate(e);
|
|
1618
|
-
}), a(this,
|
|
1618
|
+
}), a(this, H).notify({
|
|
1619
1619
|
mutation: this,
|
|
1620
1620
|
type: "updated",
|
|
1621
1621
|
action: e
|
|
1622
1622
|
});
|
|
1623
1623
|
});
|
|
1624
|
-
},
|
|
1625
|
-
function
|
|
1624
|
+
}, kn);
|
|
1625
|
+
function es() {
|
|
1626
1626
|
return {
|
|
1627
1627
|
context: void 0,
|
|
1628
1628
|
data: void 0,
|
|
@@ -1635,7 +1635,7 @@ function Zn() {
|
|
|
1635
1635
|
submittedAt: 0
|
|
1636
1636
|
};
|
|
1637
1637
|
}
|
|
1638
|
-
var ye, ie, Tt,
|
|
1638
|
+
var ye, ie, Tt, jn, bi = (jn = class extends ft {
|
|
1639
1639
|
constructor(e = {}) {
|
|
1640
1640
|
super();
|
|
1641
1641
|
w(this, ye);
|
|
@@ -1644,7 +1644,7 @@ var ye, ie, Tt, kn, vi = (kn = class extends ft {
|
|
|
1644
1644
|
this.config = e, v(this, ye, /* @__PURE__ */ new Set()), v(this, ie, /* @__PURE__ */ new Map()), v(this, Tt, 0);
|
|
1645
1645
|
}
|
|
1646
1646
|
build(e, r, n) {
|
|
1647
|
-
const s = new
|
|
1647
|
+
const s = new vi({
|
|
1648
1648
|
mutationCache: this,
|
|
1649
1649
|
mutationId: ++kt(this, Tt)._,
|
|
1650
1650
|
options: e.defaultMutationOptions(r),
|
|
@@ -1695,7 +1695,7 @@ var ye, ie, Tt, kn, vi = (kn = class extends ft {
|
|
|
1695
1695
|
return Promise.resolve();
|
|
1696
1696
|
}
|
|
1697
1697
|
clear() {
|
|
1698
|
-
|
|
1698
|
+
$.batch(() => {
|
|
1699
1699
|
a(this, ye).forEach((e) => {
|
|
1700
1700
|
this.notify({ type: "removed", mutation: e });
|
|
1701
1701
|
}), a(this, ye).clear(), a(this, ie).clear();
|
|
@@ -1707,14 +1707,14 @@ var ye, ie, Tt, kn, vi = (kn = class extends ft {
|
|
|
1707
1707
|
find(e) {
|
|
1708
1708
|
const r = { exact: !0, ...e };
|
|
1709
1709
|
return this.getAll().find(
|
|
1710
|
-
(n) =>
|
|
1710
|
+
(n) => cn(r, n)
|
|
1711
1711
|
);
|
|
1712
1712
|
}
|
|
1713
1713
|
findAll(e = {}) {
|
|
1714
|
-
return this.getAll().filter((r) =>
|
|
1714
|
+
return this.getAll().filter((r) => cn(e, r));
|
|
1715
1715
|
}
|
|
1716
1716
|
notify(e) {
|
|
1717
|
-
|
|
1717
|
+
$.batch(() => {
|
|
1718
1718
|
this.listeners.forEach((r) => {
|
|
1719
1719
|
r(e);
|
|
1720
1720
|
});
|
|
@@ -1722,67 +1722,67 @@ var ye, ie, Tt, kn, vi = (kn = class extends ft {
|
|
|
1722
1722
|
}
|
|
1723
1723
|
resumePausedMutations() {
|
|
1724
1724
|
const e = this.getAll().filter((r) => r.state.isPaused);
|
|
1725
|
-
return
|
|
1725
|
+
return $.batch(
|
|
1726
1726
|
() => Promise.all(
|
|
1727
1727
|
e.map((r) => r.continue().catch(re))
|
|
1728
1728
|
)
|
|
1729
1729
|
);
|
|
1730
1730
|
}
|
|
1731
|
-
}, ye = new WeakMap(), ie = new WeakMap(), Tt = new WeakMap(),
|
|
1731
|
+
}, ye = new WeakMap(), ie = new WeakMap(), Tt = new WeakMap(), jn);
|
|
1732
1732
|
function jt(t) {
|
|
1733
1733
|
var e;
|
|
1734
1734
|
return (e = t.options.scope) == null ? void 0 : e.id;
|
|
1735
1735
|
}
|
|
1736
|
-
function
|
|
1736
|
+
function dn(t) {
|
|
1737
1737
|
return {
|
|
1738
1738
|
onFetch: (e, r) => {
|
|
1739
|
-
var f, d, h, m,
|
|
1740
|
-
const n = e.options, s = (h = (d = (f = e.fetchOptions) == null ? void 0 : f.meta) == null ? void 0 : d.fetchMore) == null ? void 0 : h.direction, i = ((m = e.state.data) == null ? void 0 : m.pages) || [], u = ((
|
|
1739
|
+
var f, d, h, m, P;
|
|
1740
|
+
const n = e.options, s = (h = (d = (f = e.fetchOptions) == null ? void 0 : f.meta) == null ? void 0 : d.fetchMore) == null ? void 0 : h.direction, i = ((m = e.state.data) == null ? void 0 : m.pages) || [], u = ((P = e.state.data) == null ? void 0 : P.pageParams) || [];
|
|
1741
1741
|
let l = { pages: [], pageParams: [] }, c = 0;
|
|
1742
1742
|
const y = async () => {
|
|
1743
1743
|
let g = !1;
|
|
1744
|
-
const O = (
|
|
1745
|
-
Object.defineProperty(
|
|
1744
|
+
const O = (I) => {
|
|
1745
|
+
Object.defineProperty(I, "signal", {
|
|
1746
1746
|
enumerable: !0,
|
|
1747
1747
|
get: () => (e.signal.aborted ? g = !0 : e.signal.addEventListener("abort", () => {
|
|
1748
1748
|
g = !0;
|
|
1749
1749
|
}), e.signal)
|
|
1750
1750
|
});
|
|
1751
|
-
},
|
|
1751
|
+
}, S = Bn(e.options, e.fetchOptions), E = async (I, q, N) => {
|
|
1752
1752
|
if (g)
|
|
1753
1753
|
return Promise.reject();
|
|
1754
|
-
if (
|
|
1755
|
-
return Promise.resolve(
|
|
1754
|
+
if (q == null && I.pages.length)
|
|
1755
|
+
return Promise.resolve(I);
|
|
1756
1756
|
const Z = {
|
|
1757
1757
|
client: e.client,
|
|
1758
1758
|
queryKey: e.queryKey,
|
|
1759
|
-
pageParam:
|
|
1760
|
-
direction:
|
|
1759
|
+
pageParam: q,
|
|
1760
|
+
direction: N ? "backward" : "forward",
|
|
1761
1761
|
meta: e.options.meta
|
|
1762
1762
|
};
|
|
1763
1763
|
O(Z);
|
|
1764
|
-
const z = await
|
|
1764
|
+
const z = await S(
|
|
1765
1765
|
Z
|
|
1766
|
-
), { maxPages:
|
|
1766
|
+
), { maxPages: U } = e.options, j = N ? li : ci;
|
|
1767
1767
|
return {
|
|
1768
|
-
pages: j(
|
|
1769
|
-
pageParams: j(
|
|
1768
|
+
pages: j(I.pages, z, U),
|
|
1769
|
+
pageParams: j(I.pageParams, q, U)
|
|
1770
1770
|
};
|
|
1771
1771
|
};
|
|
1772
1772
|
if (s && i.length) {
|
|
1773
|
-
const
|
|
1773
|
+
const I = s === "backward", q = I ? wi : hn, N = {
|
|
1774
1774
|
pages: i,
|
|
1775
1775
|
pageParams: u
|
|
1776
|
-
}, Z =
|
|
1777
|
-
l = await
|
|
1776
|
+
}, Z = q(n, N);
|
|
1777
|
+
l = await E(N, Z, I);
|
|
1778
1778
|
} else {
|
|
1779
|
-
const
|
|
1779
|
+
const I = t ?? i.length;
|
|
1780
1780
|
do {
|
|
1781
|
-
const
|
|
1782
|
-
if (c > 0 &&
|
|
1781
|
+
const q = c === 0 ? u[0] ?? n.initialPageParam : hn(n, l);
|
|
1782
|
+
if (c > 0 && q == null)
|
|
1783
1783
|
break;
|
|
1784
|
-
l = await
|
|
1785
|
-
} while (c <
|
|
1784
|
+
l = await E(l, q), c++;
|
|
1785
|
+
} while (c < I);
|
|
1786
1786
|
}
|
|
1787
1787
|
return l;
|
|
1788
1788
|
};
|
|
@@ -1803,7 +1803,7 @@ function fn(t) {
|
|
|
1803
1803
|
}
|
|
1804
1804
|
};
|
|
1805
1805
|
}
|
|
1806
|
-
function
|
|
1806
|
+
function hn(t, { pages: e, pageParams: r }) {
|
|
1807
1807
|
const n = e.length - 1;
|
|
1808
1808
|
return e.length > 0 ? t.getNextPageParam(
|
|
1809
1809
|
e[n],
|
|
@@ -1812,13 +1812,13 @@ function dn(t, { pages: e, pageParams: r }) {
|
|
|
1812
1812
|
r
|
|
1813
1813
|
) : void 0;
|
|
1814
1814
|
}
|
|
1815
|
-
function
|
|
1815
|
+
function wi(t, { pages: e, pageParams: r }) {
|
|
1816
1816
|
var n;
|
|
1817
1817
|
return e.length > 0 ? (n = t.getPreviousPageParam) == null ? void 0 : n.call(t, e[0], e, r[0], r) : void 0;
|
|
1818
1818
|
}
|
|
1819
|
-
var
|
|
1819
|
+
var M, Oe, Re, rt, nt, Se, st, it, qn, Ei = (qn = class {
|
|
1820
1820
|
constructor(t = {}) {
|
|
1821
|
-
w(this,
|
|
1821
|
+
w(this, M);
|
|
1822
1822
|
w(this, Oe);
|
|
1823
1823
|
w(this, Re);
|
|
1824
1824
|
w(this, rt);
|
|
@@ -1826,13 +1826,13 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1826
1826
|
w(this, Se);
|
|
1827
1827
|
w(this, st);
|
|
1828
1828
|
w(this, it);
|
|
1829
|
-
v(this,
|
|
1829
|
+
v(this, M, t.queryCache || new gi()), v(this, Oe, t.mutationCache || new bi()), v(this, Re, t.defaultOptions || {}), v(this, rt, /* @__PURE__ */ new Map()), v(this, nt, /* @__PURE__ */ new Map()), v(this, Se, 0);
|
|
1830
1830
|
}
|
|
1831
1831
|
mount() {
|
|
1832
|
-
kt(this, Se)._++, a(this, Se) === 1 && (v(this, st,
|
|
1833
|
-
t && (await this.resumePausedMutations(), a(this,
|
|
1832
|
+
kt(this, Se)._++, a(this, Se) === 1 && (v(this, st, Dr.subscribe(async (t) => {
|
|
1833
|
+
t && (await this.resumePausedMutations(), a(this, M).onFocus());
|
|
1834
1834
|
})), v(this, it, Qt.subscribe(async (t) => {
|
|
1835
|
-
t && (await this.resumePausedMutations(), a(this,
|
|
1835
|
+
t && (await this.resumePausedMutations(), a(this, M).onOnline());
|
|
1836
1836
|
})));
|
|
1837
1837
|
}
|
|
1838
1838
|
unmount() {
|
|
@@ -1840,7 +1840,7 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1840
1840
|
kt(this, Se)._--, a(this, Se) === 0 && ((t = a(this, st)) == null || t.call(this), v(this, st, void 0), (e = a(this, it)) == null || e.call(this), v(this, it, void 0));
|
|
1841
1841
|
}
|
|
1842
1842
|
isFetching(t) {
|
|
1843
|
-
return a(this,
|
|
1843
|
+
return a(this, M).findAll({ ...t, fetchStatus: "fetching" }).length;
|
|
1844
1844
|
}
|
|
1845
1845
|
isMutating(t) {
|
|
1846
1846
|
return a(this, Oe).findAll({ ...t, status: "pending" }).length;
|
|
@@ -1848,28 +1848,28 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1848
1848
|
getQueryData(t) {
|
|
1849
1849
|
var r;
|
|
1850
1850
|
const e = this.defaultQueryOptions({ queryKey: t });
|
|
1851
|
-
return (r = a(this,
|
|
1851
|
+
return (r = a(this, M).get(e.queryHash)) == null ? void 0 : r.state.data;
|
|
1852
1852
|
}
|
|
1853
1853
|
ensureQueryData(t) {
|
|
1854
|
-
const e = this.defaultQueryOptions(t), r = a(this,
|
|
1854
|
+
const e = this.defaultQueryOptions(t), r = a(this, M).build(this, e), n = r.state.data;
|
|
1855
1855
|
return n === void 0 ? this.fetchQuery(t) : (t.revalidateIfStale && r.isStaleByTime(Ye(e.staleTime, r)) && this.prefetchQuery(e), Promise.resolve(n));
|
|
1856
1856
|
}
|
|
1857
1857
|
getQueriesData(t) {
|
|
1858
|
-
return a(this,
|
|
1858
|
+
return a(this, M).findAll(t).map(({ queryKey: e, state: r }) => {
|
|
1859
1859
|
const n = r.data;
|
|
1860
1860
|
return [e, n];
|
|
1861
1861
|
});
|
|
1862
1862
|
}
|
|
1863
1863
|
setQueryData(t, e, r) {
|
|
1864
|
-
const n = this.defaultQueryOptions({ queryKey: t }), s = a(this,
|
|
1864
|
+
const n = this.defaultQueryOptions({ queryKey: t }), s = a(this, M).get(
|
|
1865
1865
|
n.queryHash
|
|
1866
|
-
), i = s == null ? void 0 : s.state.data, u =
|
|
1866
|
+
), i = s == null ? void 0 : s.state.data, u = ai(e, i);
|
|
1867
1867
|
if (u !== void 0)
|
|
1868
|
-
return a(this,
|
|
1868
|
+
return a(this, M).build(this, n).setData(u, { ...r, manual: !0 });
|
|
1869
1869
|
}
|
|
1870
1870
|
setQueriesData(t, e, r) {
|
|
1871
|
-
return
|
|
1872
|
-
() => a(this,
|
|
1871
|
+
return $.batch(
|
|
1872
|
+
() => a(this, M).findAll(t).map(({ queryKey: n }) => [
|
|
1873
1873
|
n,
|
|
1874
1874
|
this.setQueryData(n, e, r)
|
|
1875
1875
|
])
|
|
@@ -1878,21 +1878,21 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1878
1878
|
getQueryState(t) {
|
|
1879
1879
|
var r;
|
|
1880
1880
|
const e = this.defaultQueryOptions({ queryKey: t });
|
|
1881
|
-
return (r = a(this,
|
|
1881
|
+
return (r = a(this, M).get(
|
|
1882
1882
|
e.queryHash
|
|
1883
1883
|
)) == null ? void 0 : r.state;
|
|
1884
1884
|
}
|
|
1885
1885
|
removeQueries(t) {
|
|
1886
|
-
const e = a(this,
|
|
1887
|
-
|
|
1886
|
+
const e = a(this, M);
|
|
1887
|
+
$.batch(() => {
|
|
1888
1888
|
e.findAll(t).forEach((r) => {
|
|
1889
1889
|
e.remove(r);
|
|
1890
1890
|
});
|
|
1891
1891
|
});
|
|
1892
1892
|
}
|
|
1893
1893
|
resetQueries(t, e) {
|
|
1894
|
-
const r = a(this,
|
|
1895
|
-
return
|
|
1894
|
+
const r = a(this, M);
|
|
1895
|
+
return $.batch(() => (r.findAll(t).forEach((n) => {
|
|
1896
1896
|
n.reset();
|
|
1897
1897
|
}), this.refetchQueries(
|
|
1898
1898
|
{
|
|
@@ -1903,13 +1903,13 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1903
1903
|
)));
|
|
1904
1904
|
}
|
|
1905
1905
|
cancelQueries(t, e = {}) {
|
|
1906
|
-
const r = { revert: !0, ...e }, n =
|
|
1907
|
-
() => a(this,
|
|
1906
|
+
const r = { revert: !0, ...e }, n = $.batch(
|
|
1907
|
+
() => a(this, M).findAll(t).map((s) => s.cancel(r))
|
|
1908
1908
|
);
|
|
1909
1909
|
return Promise.all(n).then(re).catch(re);
|
|
1910
1910
|
}
|
|
1911
1911
|
invalidateQueries(t, e = {}) {
|
|
1912
|
-
return
|
|
1912
|
+
return $.batch(() => (a(this, M).findAll(t).forEach((r) => {
|
|
1913
1913
|
r.invalidate();
|
|
1914
1914
|
}), (t == null ? void 0 : t.refetchType) === "none" ? Promise.resolve() : this.refetchQueries(
|
|
1915
1915
|
{
|
|
@@ -1923,8 +1923,8 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1923
1923
|
const r = {
|
|
1924
1924
|
...e,
|
|
1925
1925
|
cancelRefetch: e.cancelRefetch ?? !0
|
|
1926
|
-
}, n =
|
|
1927
|
-
() => a(this,
|
|
1926
|
+
}, n = $.batch(
|
|
1927
|
+
() => a(this, M).findAll(t).filter((s) => !s.isDisabled()).map((s) => {
|
|
1928
1928
|
let i = s.fetch(void 0, r);
|
|
1929
1929
|
return r.throwOnError || (i = i.catch(re)), s.state.fetchStatus === "paused" ? Promise.resolve() : i;
|
|
1930
1930
|
})
|
|
@@ -1934,7 +1934,7 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1934
1934
|
fetchQuery(t) {
|
|
1935
1935
|
const e = this.defaultQueryOptions(t);
|
|
1936
1936
|
e.retry === void 0 && (e.retry = !1);
|
|
1937
|
-
const r = a(this,
|
|
1937
|
+
const r = a(this, M).build(this, e);
|
|
1938
1938
|
return r.isStaleByTime(
|
|
1939
1939
|
Ye(e.staleTime, r)
|
|
1940
1940
|
) ? r.fetch(e) : Promise.resolve(r.state.data);
|
|
@@ -1943,19 +1943,19 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1943
1943
|
return this.fetchQuery(t).then(re).catch(re);
|
|
1944
1944
|
}
|
|
1945
1945
|
fetchInfiniteQuery(t) {
|
|
1946
|
-
return t.behavior =
|
|
1946
|
+
return t.behavior = dn(t.pages), this.fetchQuery(t);
|
|
1947
1947
|
}
|
|
1948
1948
|
prefetchInfiniteQuery(t) {
|
|
1949
1949
|
return this.fetchInfiniteQuery(t).then(re).catch(re);
|
|
1950
1950
|
}
|
|
1951
1951
|
ensureInfiniteQueryData(t) {
|
|
1952
|
-
return t.behavior =
|
|
1952
|
+
return t.behavior = dn(t.pages), this.ensureQueryData(t);
|
|
1953
1953
|
}
|
|
1954
1954
|
resumePausedMutations() {
|
|
1955
1955
|
return Qt.isOnline() ? a(this, Oe).resumePausedMutations() : Promise.resolve();
|
|
1956
1956
|
}
|
|
1957
1957
|
getQueryCache() {
|
|
1958
|
-
return a(this,
|
|
1958
|
+
return a(this, M);
|
|
1959
1959
|
}
|
|
1960
1960
|
getMutationCache() {
|
|
1961
1961
|
return a(this, Oe);
|
|
@@ -1999,7 +1999,7 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
1999
1999
|
...t,
|
|
2000
2000
|
_defaulted: !0
|
|
2001
2001
|
};
|
|
2002
|
-
return e.queryHash || (e.queryHash =
|
|
2002
|
+
return e.queryHash || (e.queryHash = Ir(
|
|
2003
2003
|
e.queryKey,
|
|
2004
2004
|
e
|
|
2005
2005
|
)), e.refetchOnReconnect === void 0 && (e.refetchOnReconnect = e.networkMode !== "always"), e.throwOnError === void 0 && (e.throwOnError = !!e.suspense), !e.networkMode && e.persister && (e.networkMode = "offlineFirst"), e.queryFn === Lt && (e.enabled = !1), e;
|
|
@@ -2013,12 +2013,12 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2013
2013
|
};
|
|
2014
2014
|
}
|
|
2015
2015
|
clear() {
|
|
2016
|
-
a(this,
|
|
2016
|
+
a(this, M).clear(), a(this, Oe).clear();
|
|
2017
2017
|
}
|
|
2018
|
-
},
|
|
2018
|
+
}, M = new WeakMap(), Oe = new WeakMap(), Re = new WeakMap(), rt = new WeakMap(), nt = new WeakMap(), Se = new WeakMap(), st = new WeakMap(), it = new WeakMap(), qn), J, F, Ft, B, Qe, ot, Ce, fe, At, at, ut, $e, Ke, Te, ct, _, vt, pr, mr, gr, vr, br, wr, Er, ts, Un, Pi = (Un = class extends ft {
|
|
2019
2019
|
constructor(e, r) {
|
|
2020
2020
|
super();
|
|
2021
|
-
w(this,
|
|
2021
|
+
w(this, _);
|
|
2022
2022
|
w(this, J);
|
|
2023
2023
|
w(this, F);
|
|
2024
2024
|
w(this, Ft);
|
|
@@ -2044,7 +2044,7 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2044
2044
|
this.refetch = this.refetch.bind(this);
|
|
2045
2045
|
}
|
|
2046
2046
|
onSubscribe() {
|
|
2047
|
-
this.listeners.size === 1 && (a(this, F).addObserver(this),
|
|
2047
|
+
this.listeners.size === 1 && (a(this, F).addObserver(this), yn(a(this, F), this.options) ? C(this, _, vt).call(this) : this.updateResult(), C(this, _, vr).call(this));
|
|
2048
2048
|
}
|
|
2049
2049
|
onUnsubscribe() {
|
|
2050
2050
|
this.hasListeners() || this.destroy();
|
|
@@ -2064,7 +2064,7 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2064
2064
|
);
|
|
2065
2065
|
}
|
|
2066
2066
|
destroy() {
|
|
2067
|
-
this.listeners = /* @__PURE__ */ new Set(),
|
|
2067
|
+
this.listeners = /* @__PURE__ */ new Set(), C(this, _, br).call(this), C(this, _, wr).call(this), a(this, F).removeObserver(this);
|
|
2068
2068
|
}
|
|
2069
2069
|
setOptions(e, r) {
|
|
2070
2070
|
const n = this.options, s = a(this, F);
|
|
@@ -2072,24 +2072,24 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2072
2072
|
throw new Error(
|
|
2073
2073
|
"Expected enabled to be a boolean or a callback that returns a boolean"
|
|
2074
2074
|
);
|
|
2075
|
-
|
|
2075
|
+
C(this, _, Er).call(this), a(this, F).setOptions(this.options), n._defaulted && !Nt(this.options, n) && a(this, J).getQueryCache().notify({
|
|
2076
2076
|
type: "observerOptionsUpdated",
|
|
2077
2077
|
query: a(this, F),
|
|
2078
2078
|
observer: this
|
|
2079
2079
|
});
|
|
2080
2080
|
const i = this.hasListeners();
|
|
2081
|
-
i &&
|
|
2081
|
+
i && pn(
|
|
2082
2082
|
a(this, F),
|
|
2083
2083
|
s,
|
|
2084
2084
|
this.options,
|
|
2085
2085
|
n
|
|
2086
|
-
) &&
|
|
2087
|
-
const u =
|
|
2088
|
-
i && (a(this, F) !== s || oe(this.options.enabled, a(this, F)) !== oe(n.enabled, a(this, F)) || u !== a(this, Te)) &&
|
|
2086
|
+
) && C(this, _, vt).call(this), this.updateResult(r), i && (a(this, F) !== s || oe(this.options.enabled, a(this, F)) !== oe(n.enabled, a(this, F)) || Ye(this.options.staleTime, a(this, F)) !== Ye(n.staleTime, a(this, F))) && C(this, _, pr).call(this);
|
|
2087
|
+
const u = C(this, _, mr).call(this);
|
|
2088
|
+
i && (a(this, F) !== s || oe(this.options.enabled, a(this, F)) !== oe(n.enabled, a(this, F)) || u !== a(this, Te)) && C(this, _, gr).call(this, u);
|
|
2089
2089
|
}
|
|
2090
2090
|
getOptimisticResult(e) {
|
|
2091
2091
|
const r = a(this, J).getQueryCache().build(a(this, J), e), n = this.createResult(r, e);
|
|
2092
|
-
return
|
|
2092
|
+
return Ri(this, n) && (v(this, B, n), v(this, ot, this.options), v(this, Qe, a(this, F).state)), n;
|
|
2093
2093
|
}
|
|
2094
2094
|
getCurrentResult() {
|
|
2095
2095
|
return a(this, B);
|
|
@@ -2120,23 +2120,23 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2120
2120
|
return n.fetch().then(() => this.createResult(n, r));
|
|
2121
2121
|
}
|
|
2122
2122
|
fetch(e) {
|
|
2123
|
-
return
|
|
2123
|
+
return C(this, _, vt).call(this, {
|
|
2124
2124
|
...e,
|
|
2125
2125
|
cancelRefetch: e.cancelRefetch ?? !0
|
|
2126
2126
|
}).then(() => (this.updateResult(), a(this, B)));
|
|
2127
2127
|
}
|
|
2128
2128
|
createResult(e, r) {
|
|
2129
|
-
var
|
|
2129
|
+
var U;
|
|
2130
2130
|
const n = a(this, F), s = this.options, i = a(this, B), u = a(this, Qe), l = a(this, ot), y = e !== n ? e.state : a(this, Ft), { state: f } = e;
|
|
2131
2131
|
let d = { ...f }, h = !1, m;
|
|
2132
2132
|
if (r._optimisticResults) {
|
|
2133
|
-
const j = this.hasListeners(), ge = !j &&
|
|
2133
|
+
const j = this.hasListeners(), ge = !j && yn(e, r), ve = j && pn(e, n, r, s);
|
|
2134
2134
|
(ge || ve) && (d = {
|
|
2135
2135
|
...d,
|
|
2136
|
-
...
|
|
2136
|
+
...Zn(f.data, e.options)
|
|
2137
2137
|
}), r._optimisticResults === "isRestoring" && (d.fetchStatus = "idle");
|
|
2138
2138
|
}
|
|
2139
|
-
let { error:
|
|
2139
|
+
let { error: P, errorUpdatedAt: g, status: O } = d;
|
|
2140
2140
|
if (r.select && d.data !== void 0)
|
|
2141
2141
|
if (i && d.data === (u == null ? void 0 : u.data) && r.select === a(this, At))
|
|
2142
2142
|
m = a(this, at);
|
|
@@ -2153,7 +2153,7 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2153
2153
|
if (i != null && i.isPlaceholderData && r.placeholderData === (l == null ? void 0 : l.placeholderData))
|
|
2154
2154
|
j = i.data;
|
|
2155
2155
|
else if (j = typeof r.placeholderData == "function" ? r.placeholderData(
|
|
2156
|
-
(
|
|
2156
|
+
(U = a(this, ut)) == null ? void 0 : U.state.data,
|
|
2157
2157
|
a(this, ut)
|
|
2158
2158
|
) : r.placeholderData, r.select && j !== void 0)
|
|
2159
2159
|
try {
|
|
@@ -2167,31 +2167,31 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2167
2167
|
r
|
|
2168
2168
|
), h = !0);
|
|
2169
2169
|
}
|
|
2170
|
-
a(this, fe) && (
|
|
2171
|
-
const
|
|
2170
|
+
a(this, fe) && (P = a(this, fe), m = a(this, at), g = Date.now(), O = "error");
|
|
2171
|
+
const S = d.fetchStatus === "fetching", E = O === "pending", I = O === "error", q = E && S, N = m !== void 0, z = {
|
|
2172
2172
|
status: O,
|
|
2173
2173
|
fetchStatus: d.fetchStatus,
|
|
2174
|
-
isPending:
|
|
2174
|
+
isPending: E,
|
|
2175
2175
|
isSuccess: O === "success",
|
|
2176
|
-
isError:
|
|
2177
|
-
isInitialLoading:
|
|
2178
|
-
isLoading:
|
|
2176
|
+
isError: I,
|
|
2177
|
+
isInitialLoading: q,
|
|
2178
|
+
isLoading: q,
|
|
2179
2179
|
data: m,
|
|
2180
2180
|
dataUpdatedAt: d.dataUpdatedAt,
|
|
2181
|
-
error:
|
|
2181
|
+
error: P,
|
|
2182
2182
|
errorUpdatedAt: g,
|
|
2183
2183
|
failureCount: d.fetchFailureCount,
|
|
2184
2184
|
failureReason: d.fetchFailureReason,
|
|
2185
2185
|
errorUpdateCount: d.errorUpdateCount,
|
|
2186
2186
|
isFetched: d.dataUpdateCount > 0 || d.errorUpdateCount > 0,
|
|
2187
2187
|
isFetchedAfterMount: d.dataUpdateCount > y.dataUpdateCount || d.errorUpdateCount > y.errorUpdateCount,
|
|
2188
|
-
isFetching:
|
|
2189
|
-
isRefetching:
|
|
2190
|
-
isLoadingError:
|
|
2188
|
+
isFetching: S,
|
|
2189
|
+
isRefetching: S && !E,
|
|
2190
|
+
isLoadingError: I && !N,
|
|
2191
2191
|
isPaused: d.fetchStatus === "paused",
|
|
2192
2192
|
isPlaceholderData: h,
|
|
2193
|
-
isRefetchError:
|
|
2194
|
-
isStale:
|
|
2193
|
+
isRefetchError: I && N,
|
|
2194
|
+
isStale: _r(e, r),
|
|
2195
2195
|
refetch: this.refetch,
|
|
2196
2196
|
promise: a(this, Ce)
|
|
2197
2197
|
};
|
|
@@ -2235,20 +2235,20 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2235
2235
|
return a(this, B)[f] !== r[f] && c.has(f);
|
|
2236
2236
|
});
|
|
2237
2237
|
};
|
|
2238
|
-
(e == null ? void 0 : e.listeners) !== !1 && i() && (s.listeners = !0),
|
|
2238
|
+
(e == null ? void 0 : e.listeners) !== !1 && i() && (s.listeners = !0), C(this, _, ts).call(this, { ...s, ...e });
|
|
2239
2239
|
}
|
|
2240
2240
|
onQueryUpdate() {
|
|
2241
|
-
this.updateResult(), this.hasListeners() &&
|
|
2241
|
+
this.updateResult(), this.hasListeners() && C(this, _, vr).call(this);
|
|
2242
2242
|
}
|
|
2243
|
-
}, J = new WeakMap(), F = new WeakMap(), Ft = new WeakMap(), B = new WeakMap(), Qe = new WeakMap(), ot = new WeakMap(), Ce = new WeakMap(), fe = new WeakMap(), At = new WeakMap(), at = new WeakMap(), ut = new WeakMap(), $e = new WeakMap(), Ke = new WeakMap(), Te = new WeakMap(), ct = new WeakMap(),
|
|
2244
|
-
|
|
2243
|
+
}, J = new WeakMap(), F = new WeakMap(), Ft = new WeakMap(), B = new WeakMap(), Qe = new WeakMap(), ot = new WeakMap(), Ce = new WeakMap(), fe = new WeakMap(), At = new WeakMap(), at = new WeakMap(), ut = new WeakMap(), $e = new WeakMap(), Ke = new WeakMap(), Te = new WeakMap(), ct = new WeakMap(), _ = new WeakSet(), vt = function(e) {
|
|
2244
|
+
C(this, _, Er).call(this);
|
|
2245
2245
|
let r = a(this, F).fetch(
|
|
2246
2246
|
this.options,
|
|
2247
2247
|
e
|
|
2248
2248
|
);
|
|
2249
2249
|
return e != null && e.throwOnError || (r = r.catch(re)), r;
|
|
2250
2250
|
}, pr = function() {
|
|
2251
|
-
|
|
2251
|
+
C(this, _, br).call(this);
|
|
2252
2252
|
const e = Ye(
|
|
2253
2253
|
this.options.staleTime,
|
|
2254
2254
|
a(this, F)
|
|
@@ -2262,11 +2262,11 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2262
2262
|
}, mr = function() {
|
|
2263
2263
|
return (typeof this.options.refetchInterval == "function" ? this.options.refetchInterval(a(this, F)) : this.options.refetchInterval) ?? !1;
|
|
2264
2264
|
}, gr = function(e) {
|
|
2265
|
-
|
|
2266
|
-
(this.options.refetchIntervalInBackground ||
|
|
2265
|
+
C(this, _, wr).call(this), v(this, Te, e), !(ze || oe(this.options.enabled, a(this, F)) === !1 || !lr(a(this, Te)) || a(this, Te) === 0) && v(this, Ke, setInterval(() => {
|
|
2266
|
+
(this.options.refetchIntervalInBackground || Dr.isFocused()) && C(this, _, vt).call(this);
|
|
2267
2267
|
}, a(this, Te)));
|
|
2268
2268
|
}, vr = function() {
|
|
2269
|
-
|
|
2269
|
+
C(this, _, pr).call(this), C(this, _, gr).call(this, C(this, _, mr).call(this));
|
|
2270
2270
|
}, br = function() {
|
|
2271
2271
|
a(this, $e) && (clearTimeout(a(this, $e)), v(this, $e, void 0));
|
|
2272
2272
|
}, wr = function() {
|
|
@@ -2277,8 +2277,8 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2277
2277
|
return;
|
|
2278
2278
|
const r = a(this, F);
|
|
2279
2279
|
v(this, F, e), v(this, Ft, e.state), this.hasListeners() && (r == null || r.removeObserver(this), e.addObserver(this));
|
|
2280
|
-
},
|
|
2281
|
-
|
|
2280
|
+
}, ts = function(e) {
|
|
2281
|
+
$.batch(() => {
|
|
2282
2282
|
e.listeners && this.listeners.forEach((r) => {
|
|
2283
2283
|
r(a(this, B));
|
|
2284
2284
|
}), a(this, J).getQueryCache().notify({
|
|
@@ -2286,30 +2286,30 @@ var U, Oe, Re, rt, nt, Se, st, it, jn, wi = (jn = class {
|
|
|
2286
2286
|
type: "observerResultsUpdated"
|
|
2287
2287
|
});
|
|
2288
2288
|
});
|
|
2289
|
-
},
|
|
2290
|
-
function
|
|
2289
|
+
}, Un);
|
|
2290
|
+
function Oi(t, e) {
|
|
2291
2291
|
return oe(e.enabled, t) !== !1 && t.state.data === void 0 && !(t.state.status === "error" && e.retryOnMount === !1);
|
|
2292
2292
|
}
|
|
2293
|
-
function
|
|
2294
|
-
return
|
|
2293
|
+
function yn(t, e) {
|
|
2294
|
+
return Oi(t, e) || t.state.data !== void 0 && Pr(t, e, e.refetchOnMount);
|
|
2295
2295
|
}
|
|
2296
2296
|
function Pr(t, e, r) {
|
|
2297
2297
|
if (oe(e.enabled, t) !== !1) {
|
|
2298
2298
|
const n = typeof r == "function" ? r(t) : r;
|
|
2299
|
-
return n === "always" || n !== !1 &&
|
|
2299
|
+
return n === "always" || n !== !1 && _r(t, e);
|
|
2300
2300
|
}
|
|
2301
2301
|
return !1;
|
|
2302
2302
|
}
|
|
2303
|
-
function
|
|
2304
|
-
return (t !== e || oe(n.enabled, t) === !1) && (!r.suspense || t.state.status !== "error") &&
|
|
2303
|
+
function pn(t, e, r, n) {
|
|
2304
|
+
return (t !== e || oe(n.enabled, t) === !1) && (!r.suspense || t.state.status !== "error") && _r(t, r);
|
|
2305
2305
|
}
|
|
2306
|
-
function
|
|
2306
|
+
function _r(t, e) {
|
|
2307
2307
|
return oe(e.enabled, t) !== !1 && t.isStaleByTime(Ye(e.staleTime, t));
|
|
2308
2308
|
}
|
|
2309
|
-
function
|
|
2309
|
+
function Ri(t, e) {
|
|
2310
2310
|
return !Nt(t.getCurrentResult(), e);
|
|
2311
2311
|
}
|
|
2312
|
-
var Fe, Ae, X, pe, me, Ut, Or,
|
|
2312
|
+
var Fe, Ae, X, pe, me, Ut, Or, Mn, Si = (Mn = class extends ft {
|
|
2313
2313
|
constructor(e, r) {
|
|
2314
2314
|
super();
|
|
2315
2315
|
w(this, me);
|
|
@@ -2317,7 +2317,7 @@ var Fe, Ae, X, pe, me, Ut, Or, Un, Ri = (Un = class extends ft {
|
|
|
2317
2317
|
w(this, Ae);
|
|
2318
2318
|
w(this, X);
|
|
2319
2319
|
w(this, pe);
|
|
2320
|
-
v(this, Fe, e), this.setOptions(r), this.bindMethods(),
|
|
2320
|
+
v(this, Fe, e), this.setOptions(r), this.bindMethods(), C(this, me, Ut).call(this);
|
|
2321
2321
|
}
|
|
2322
2322
|
bindMethods() {
|
|
2323
2323
|
this.mutate = this.mutate.bind(this), this.reset = this.reset.bind(this);
|
|
@@ -2336,14 +2336,14 @@ var Fe, Ae, X, pe, me, Ut, Or, Un, Ri = (Un = class extends ft {
|
|
|
2336
2336
|
this.hasListeners() || (e = a(this, X)) == null || e.removeObserver(this);
|
|
2337
2337
|
}
|
|
2338
2338
|
onMutationUpdate(e) {
|
|
2339
|
-
|
|
2339
|
+
C(this, me, Ut).call(this), C(this, me, Or).call(this, e);
|
|
2340
2340
|
}
|
|
2341
2341
|
getCurrentResult() {
|
|
2342
2342
|
return a(this, Ae);
|
|
2343
2343
|
}
|
|
2344
2344
|
reset() {
|
|
2345
2345
|
var e;
|
|
2346
|
-
(e = a(this, X)) == null || e.removeObserver(this), v(this, X, void 0),
|
|
2346
|
+
(e = a(this, X)) == null || e.removeObserver(this), v(this, X, void 0), C(this, me, Ut).call(this), C(this, me, Or).call(this);
|
|
2347
2347
|
}
|
|
2348
2348
|
mutate(e, r) {
|
|
2349
2349
|
var n;
|
|
@@ -2351,7 +2351,7 @@ var Fe, Ae, X, pe, me, Ut, Or, Un, Ri = (Un = class extends ft {
|
|
|
2351
2351
|
}
|
|
2352
2352
|
}, Fe = new WeakMap(), Ae = new WeakMap(), X = new WeakMap(), pe = new WeakMap(), me = new WeakSet(), Ut = function() {
|
|
2353
2353
|
var r;
|
|
2354
|
-
const e = ((r = a(this, X)) == null ? void 0 : r.state) ??
|
|
2354
|
+
const e = ((r = a(this, X)) == null ? void 0 : r.state) ?? es();
|
|
2355
2355
|
v(this, Ae, {
|
|
2356
2356
|
...e,
|
|
2357
2357
|
isPending: e.status === "pending",
|
|
@@ -2362,7 +2362,7 @@ var Fe, Ae, X, pe, me, Ut, Or, Un, Ri = (Un = class extends ft {
|
|
|
2362
2362
|
reset: this.reset
|
|
2363
2363
|
});
|
|
2364
2364
|
}, Or = function(e) {
|
|
2365
|
-
|
|
2365
|
+
$.batch(() => {
|
|
2366
2366
|
var r, n, s, i, u, l, c, y;
|
|
2367
2367
|
if (a(this, pe) && this.hasListeners()) {
|
|
2368
2368
|
const f = a(this, Ae).variables, d = a(this, Ae).context;
|
|
@@ -2378,21 +2378,21 @@ var Fe, Ae, X, pe, me, Ut, Or, Un, Ri = (Un = class extends ft {
|
|
|
2378
2378
|
f(a(this, Ae));
|
|
2379
2379
|
});
|
|
2380
2380
|
});
|
|
2381
|
-
},
|
|
2381
|
+
}, Mn), rs = K.createContext(
|
|
2382
2382
|
void 0
|
|
2383
2383
|
), dt = (t) => {
|
|
2384
|
-
const e =
|
|
2384
|
+
const e = K.useContext(rs);
|
|
2385
2385
|
if (!e)
|
|
2386
2386
|
throw new Error("No QueryClient set, use QueryClientProvider to set one");
|
|
2387
2387
|
return e;
|
|
2388
|
-
},
|
|
2388
|
+
}, Ci = ({
|
|
2389
2389
|
client: t,
|
|
2390
2390
|
children: e
|
|
2391
|
-
}) => (
|
|
2391
|
+
}) => (K.useEffect(() => (t.mount(), () => {
|
|
2392
2392
|
t.unmount();
|
|
2393
|
-
}), [t]), /* @__PURE__ */ wt.jsx(
|
|
2394
|
-
|
|
2395
|
-
function
|
|
2393
|
+
}), [t]), /* @__PURE__ */ wt.jsx(rs.Provider, { value: t, children: e })), ns = K.createContext(!1), Ti = () => K.useContext(ns);
|
|
2394
|
+
ns.Provider;
|
|
2395
|
+
function Fi() {
|
|
2396
2396
|
let t = !1;
|
|
2397
2397
|
return {
|
|
2398
2398
|
clearReset: () => {
|
|
@@ -2404,64 +2404,64 @@ function Ti() {
|
|
|
2404
2404
|
isReset: () => t
|
|
2405
2405
|
};
|
|
2406
2406
|
}
|
|
2407
|
-
var
|
|
2408
|
-
function
|
|
2407
|
+
var Ai = K.createContext(Fi()), xi = () => K.useContext(Ai);
|
|
2408
|
+
function ss(t, e) {
|
|
2409
2409
|
return typeof t == "function" ? t(...e) : !!t;
|
|
2410
2410
|
}
|
|
2411
2411
|
function Rr() {
|
|
2412
2412
|
}
|
|
2413
|
-
var
|
|
2413
|
+
var Ii = (t, e) => {
|
|
2414
2414
|
(t.suspense || t.throwOnError || t.experimental_prefetchInRender) && (e.isReset() || (t.retryOnMount = !1));
|
|
2415
|
-
},
|
|
2416
|
-
|
|
2415
|
+
}, Di = (t) => {
|
|
2416
|
+
K.useEffect(() => {
|
|
2417
2417
|
t.clearReset();
|
|
2418
2418
|
}, [t]);
|
|
2419
|
-
},
|
|
2419
|
+
}, _i = ({
|
|
2420
2420
|
result: t,
|
|
2421
2421
|
errorResetBoundary: e,
|
|
2422
2422
|
throwOnError: r,
|
|
2423
2423
|
query: n,
|
|
2424
2424
|
suspense: s
|
|
2425
|
-
}) => t.isError && !e.isReset() && !t.isFetching && n && (s && t.data === void 0 ||
|
|
2425
|
+
}) => t.isError && !e.isReset() && !t.isFetching && n && (s && t.data === void 0 || ss(r, [t.error, n])), ki = (t) => {
|
|
2426
2426
|
const e = t.staleTime;
|
|
2427
2427
|
t.suspense && (t.staleTime = typeof e == "function" ? (...r) => Math.max(e(...r), 1e3) : Math.max(e ?? 1e3, 1e3), typeof t.gcTime == "number" && (t.gcTime = Math.max(t.gcTime, 1e3)));
|
|
2428
|
-
},
|
|
2428
|
+
}, ji = (t, e) => t.isLoading && t.isFetching && !e, qi = (t, e) => (t == null ? void 0 : t.suspense) && e.isPending, mn = (t, e, r) => e.fetchOptimistic(t).catch(() => {
|
|
2429
2429
|
r.clearReset();
|
|
2430
2430
|
});
|
|
2431
|
-
function
|
|
2432
|
-
var d, h, m,
|
|
2431
|
+
function Ui(t, e, r) {
|
|
2432
|
+
var d, h, m, P, g;
|
|
2433
2433
|
if (process.env.NODE_ENV !== "production" && (typeof t != "object" || Array.isArray(t)))
|
|
2434
2434
|
throw new Error(
|
|
2435
2435
|
'Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object'
|
|
2436
2436
|
);
|
|
2437
|
-
const n = dt(), s =
|
|
2437
|
+
const n = dt(), s = Ti(), i = xi(), u = n.defaultQueryOptions(t);
|
|
2438
2438
|
(h = (d = n.getDefaultOptions().queries) == null ? void 0 : d._experimental_beforeQuery) == null || h.call(
|
|
2439
2439
|
d,
|
|
2440
2440
|
u
|
|
2441
2441
|
), process.env.NODE_ENV !== "production" && (u.queryFn || console.error(
|
|
2442
2442
|
`[${u.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`
|
|
2443
|
-
)), u._optimisticResults = s ? "isRestoring" : "optimistic",
|
|
2444
|
-
const l = !n.getQueryCache().get(u.queryHash), [c] =
|
|
2443
|
+
)), u._optimisticResults = s ? "isRestoring" : "optimistic", ki(u), Ii(u, i), Di(i);
|
|
2444
|
+
const l = !n.getQueryCache().get(u.queryHash), [c] = K.useState(
|
|
2445
2445
|
() => new e(
|
|
2446
2446
|
n,
|
|
2447
2447
|
u
|
|
2448
2448
|
)
|
|
2449
2449
|
), y = c.getOptimisticResult(u), f = !s && t.subscribed !== !1;
|
|
2450
|
-
if (
|
|
2451
|
-
|
|
2450
|
+
if (K.useSyncExternalStore(
|
|
2451
|
+
K.useCallback(
|
|
2452
2452
|
(O) => {
|
|
2453
|
-
const
|
|
2454
|
-
return c.updateResult(),
|
|
2453
|
+
const S = f ? c.subscribe($.batchCalls(O)) : Rr;
|
|
2454
|
+
return c.updateResult(), S;
|
|
2455
2455
|
},
|
|
2456
2456
|
[c, f]
|
|
2457
2457
|
),
|
|
2458
2458
|
() => c.getCurrentResult(),
|
|
2459
2459
|
() => c.getCurrentResult()
|
|
2460
|
-
),
|
|
2460
|
+
), K.useEffect(() => {
|
|
2461
2461
|
c.setOptions(u, { listeners: !1 });
|
|
2462
|
-
}, [u, c]),
|
|
2463
|
-
throw
|
|
2464
|
-
if (
|
|
2462
|
+
}, [u, c]), qi(u, y))
|
|
2463
|
+
throw mn(u, c, i);
|
|
2464
|
+
if (_i({
|
|
2465
2465
|
result: y,
|
|
2466
2466
|
errorResetBoundary: i,
|
|
2467
2467
|
throwOnError: u.throwOnError,
|
|
@@ -2469,14 +2469,14 @@ function qi(t, e, r) {
|
|
|
2469
2469
|
suspense: u.suspense
|
|
2470
2470
|
}))
|
|
2471
2471
|
throw y.error;
|
|
2472
|
-
if ((
|
|
2472
|
+
if ((P = (m = n.getDefaultOptions().queries) == null ? void 0 : m._experimental_afterQuery) == null || P.call(
|
|
2473
2473
|
m,
|
|
2474
2474
|
u,
|
|
2475
2475
|
y
|
|
2476
|
-
), u.experimental_prefetchInRender && !ze &&
|
|
2476
|
+
), u.experimental_prefetchInRender && !ze && ji(y, s)) {
|
|
2477
2477
|
const O = l ? (
|
|
2478
2478
|
// Fetch immediately on render in order to ensure `.promise` is resolved even if the component is unmounted
|
|
2479
|
-
|
|
2479
|
+
mn(u, c, i)
|
|
2480
2480
|
) : (
|
|
2481
2481
|
// subscribe to the "cache promise" so that we can finalize the currentThenable once data comes in
|
|
2482
2482
|
(g = n.getQueryCache().get(u.queryHash)) == null ? void 0 : g.promise
|
|
@@ -2487,33 +2487,33 @@ function qi(t, e, r) {
|
|
|
2487
2487
|
}
|
|
2488
2488
|
return u.notifyOnChangeProps ? y : c.trackResult(y);
|
|
2489
2489
|
}
|
|
2490
|
-
function
|
|
2491
|
-
return
|
|
2490
|
+
function kr(t, e) {
|
|
2491
|
+
return Ui(t, Pi);
|
|
2492
2492
|
}
|
|
2493
2493
|
function Kt(t, e) {
|
|
2494
|
-
const r = dt(), [n] =
|
|
2495
|
-
() => new
|
|
2494
|
+
const r = dt(), [n] = K.useState(
|
|
2495
|
+
() => new Si(
|
|
2496
2496
|
r,
|
|
2497
2497
|
t
|
|
2498
2498
|
)
|
|
2499
2499
|
);
|
|
2500
|
-
|
|
2500
|
+
K.useEffect(() => {
|
|
2501
2501
|
n.setOptions(t);
|
|
2502
2502
|
}, [n, t]);
|
|
2503
|
-
const s =
|
|
2504
|
-
|
|
2505
|
-
(u) => n.subscribe(
|
|
2503
|
+
const s = K.useSyncExternalStore(
|
|
2504
|
+
K.useCallback(
|
|
2505
|
+
(u) => n.subscribe($.batchCalls(u)),
|
|
2506
2506
|
[n]
|
|
2507
2507
|
),
|
|
2508
2508
|
() => n.getCurrentResult(),
|
|
2509
2509
|
() => n.getCurrentResult()
|
|
2510
|
-
), i =
|
|
2510
|
+
), i = K.useCallback(
|
|
2511
2511
|
(u, l) => {
|
|
2512
2512
|
n.mutate(u, l).catch(Rr);
|
|
2513
2513
|
},
|
|
2514
2514
|
[n]
|
|
2515
2515
|
);
|
|
2516
|
-
if (s.error &&
|
|
2516
|
+
if (s.error && ss(n.options.throwOnError, [s.error]))
|
|
2517
2517
|
throw s.error;
|
|
2518
2518
|
return { ...s, mutate: i, mutateAsync: s.mutate };
|
|
2519
2519
|
}
|
|
@@ -2546,15 +2546,15 @@ function zt(t) {
|
|
|
2546
2546
|
};
|
|
2547
2547
|
},
|
|
2548
2548
|
pipe(...r) {
|
|
2549
|
-
return r.reduce(
|
|
2549
|
+
return r.reduce(Mi, e);
|
|
2550
2550
|
}
|
|
2551
2551
|
};
|
|
2552
2552
|
return e;
|
|
2553
2553
|
}
|
|
2554
|
-
function
|
|
2554
|
+
function Mi(t, e) {
|
|
2555
2555
|
return e(t);
|
|
2556
2556
|
}
|
|
2557
|
-
function
|
|
2557
|
+
function Ni(t) {
|
|
2558
2558
|
const e = new AbortController();
|
|
2559
2559
|
return new Promise((n, s) => {
|
|
2560
2560
|
let i = !1;
|
|
@@ -2577,7 +2577,7 @@ function Mi(t) {
|
|
|
2577
2577
|
});
|
|
2578
2578
|
});
|
|
2579
2579
|
}
|
|
2580
|
-
function
|
|
2580
|
+
function Li(t) {
|
|
2581
2581
|
return (e) => {
|
|
2582
2582
|
let r = 0, n = null;
|
|
2583
2583
|
const s = [];
|
|
@@ -2615,7 +2615,7 @@ function Ni(t) {
|
|
|
2615
2615
|
}));
|
|
2616
2616
|
};
|
|
2617
2617
|
}
|
|
2618
|
-
function
|
|
2618
|
+
function Qi(t) {
|
|
2619
2619
|
let e = t;
|
|
2620
2620
|
const r = [], n = (u) => {
|
|
2621
2621
|
e !== void 0 && u.next(e), r.push(u);
|
|
@@ -2632,7 +2632,7 @@ function Li(t) {
|
|
|
2632
2632
|
}
|
|
2633
2633
|
}, i.get = () => e, i;
|
|
2634
2634
|
}
|
|
2635
|
-
function
|
|
2635
|
+
function $i(t) {
|
|
2636
2636
|
return zt((e) => {
|
|
2637
2637
|
function r(s = 0, i = t.op) {
|
|
2638
2638
|
const u = t.links[s];
|
|
@@ -2648,17 +2648,17 @@ function Qi(t) {
|
|
|
2648
2648
|
return r().subscribe(e);
|
|
2649
2649
|
});
|
|
2650
2650
|
}
|
|
2651
|
-
const
|
|
2652
|
-
},
|
|
2651
|
+
const is = () => {
|
|
2652
|
+
}, gn = (t) => {
|
|
2653
2653
|
Object.freeze && Object.freeze(t);
|
|
2654
2654
|
};
|
|
2655
|
-
function
|
|
2655
|
+
function os(t, e, r) {
|
|
2656
2656
|
var n, s;
|
|
2657
2657
|
const i = e.join(".");
|
|
2658
|
-
return (n = r)[s = i] ?? (n[s] = new Proxy(
|
|
2658
|
+
return (n = r)[s = i] ?? (n[s] = new Proxy(is, {
|
|
2659
2659
|
get(u, l) {
|
|
2660
2660
|
if (!(typeof l != "string" || l === "then"))
|
|
2661
|
-
return
|
|
2661
|
+
return os(t, [
|
|
2662
2662
|
...e,
|
|
2663
2663
|
l
|
|
2664
2664
|
], r);
|
|
@@ -2677,11 +2677,11 @@ function is(t, e, r) {
|
|
|
2677
2677
|
} : y === "apply" && (f = {
|
|
2678
2678
|
args: c.length >= 2 ? c[1] : [],
|
|
2679
2679
|
path: e.slice(0, -1)
|
|
2680
|
-
}),
|
|
2680
|
+
}), gn(f.args), gn(f.path), t(f);
|
|
2681
2681
|
}
|
|
2682
2682
|
})), r[i];
|
|
2683
2683
|
}
|
|
2684
|
-
const
|
|
2684
|
+
const Ki = (t) => os(t, [], /* @__PURE__ */ Object.create(null)), zi = (t) => new Proxy(is, {
|
|
2685
2685
|
get(e, r) {
|
|
2686
2686
|
if (r !== "then")
|
|
2687
2687
|
return t(r);
|
|
@@ -2690,7 +2690,7 @@ const $i = (t) => is(t, [], /* @__PURE__ */ Object.create(null)), Ki = (t) => ne
|
|
|
2690
2690
|
function Pt(t) {
|
|
2691
2691
|
return !!t && !Array.isArray(t) && typeof t == "object";
|
|
2692
2692
|
}
|
|
2693
|
-
function
|
|
2693
|
+
function Vi(t, e) {
|
|
2694
2694
|
if ("error" in t) {
|
|
2695
2695
|
const n = e.deserialize(t.error);
|
|
2696
2696
|
return {
|
|
@@ -2717,10 +2717,10 @@ class ir extends Error {
|
|
|
2717
2717
|
super("Unable to transform response from server");
|
|
2718
2718
|
}
|
|
2719
2719
|
}
|
|
2720
|
-
function
|
|
2720
|
+
function Wi(t, e) {
|
|
2721
2721
|
let r;
|
|
2722
2722
|
try {
|
|
2723
|
-
r =
|
|
2723
|
+
r = Vi(t, e);
|
|
2724
2724
|
} catch {
|
|
2725
2725
|
throw new ir();
|
|
2726
2726
|
}
|
|
@@ -2730,12 +2730,12 @@ function Vi(t, e) {
|
|
|
2730
2730
|
throw new ir();
|
|
2731
2731
|
return r;
|
|
2732
2732
|
}
|
|
2733
|
-
var
|
|
2734
|
-
(
|
|
2735
|
-
(
|
|
2736
|
-
var
|
|
2733
|
+
var vn, bn;
|
|
2734
|
+
(vn = Symbol).dispose ?? (vn.dispose = Symbol());
|
|
2735
|
+
(bn = Symbol).asyncDispose ?? (bn.asyncDispose = Symbol());
|
|
2736
|
+
var Nn, Ln, Qn, $n, Kn, zn;
|
|
2737
2737
|
typeof window > "u" || "Deno" in window || // eslint-disable-next-line @typescript-eslint/dot-notation
|
|
2738
|
-
((
|
|
2738
|
+
((Ln = (Nn = globalThis.process) == null ? void 0 : Nn.env) == null ? void 0 : Ln.NODE_ENV) === "test" || ($n = (Qn = globalThis.process) == null ? void 0 : Qn.env) != null && $n.JEST_WORKER_ID || (zn = (Kn = globalThis.process) == null ? void 0 : Kn.env) != null && zn.VITEST_WORKER_ID;
|
|
2739
2739
|
function qt(t, e, r) {
|
|
2740
2740
|
return e in t ? Object.defineProperty(t, e, {
|
|
2741
2741
|
value: r,
|
|
@@ -2751,10 +2751,10 @@ function Hi(t) {
|
|
|
2751
2751
|
*/
|
|
2752
2752
|
t instanceof Error && t.name === "TRPCClientError";
|
|
2753
2753
|
}
|
|
2754
|
-
function
|
|
2754
|
+
function Bi(t) {
|
|
2755
2755
|
return Pt(t) && Pt(t.error) && typeof t.error.code == "number" && typeof t.error.message == "string";
|
|
2756
2756
|
}
|
|
2757
|
-
function
|
|
2757
|
+
function Gi(t, e) {
|
|
2758
2758
|
return typeof t == "string" ? t : Pt(t) && typeof t.message == "string" ? t.message : e;
|
|
2759
2759
|
}
|
|
2760
2760
|
class xe extends Error {
|
|
@@ -2763,10 +2763,10 @@ class xe extends Error {
|
|
|
2763
2763
|
return Hi(n) ? (r.meta && (n.meta = {
|
|
2764
2764
|
...n.meta,
|
|
2765
2765
|
...r.meta
|
|
2766
|
-
}), n) :
|
|
2766
|
+
}), n) : Bi(n) ? new xe(n.error.message, {
|
|
2767
2767
|
...r,
|
|
2768
2768
|
result: n
|
|
2769
|
-
}) : new xe(
|
|
2769
|
+
}) : new xe(Gi(n, "Unknown error"), {
|
|
2770
2770
|
...r,
|
|
2771
2771
|
cause: n
|
|
2772
2772
|
});
|
|
@@ -2793,21 +2793,21 @@ function or(t, e, r) {
|
|
|
2793
2793
|
writable: !0
|
|
2794
2794
|
}) : t[e] = r, t;
|
|
2795
2795
|
}
|
|
2796
|
-
class
|
|
2796
|
+
class Yi {
|
|
2797
2797
|
$request(e) {
|
|
2798
|
-
return
|
|
2798
|
+
return $i({
|
|
2799
2799
|
links: this.links,
|
|
2800
2800
|
op: {
|
|
2801
2801
|
...e,
|
|
2802
2802
|
context: e.context ?? {},
|
|
2803
2803
|
id: ++this.requestId
|
|
2804
2804
|
}
|
|
2805
|
-
}).pipe(
|
|
2805
|
+
}).pipe(Li());
|
|
2806
2806
|
}
|
|
2807
2807
|
async requestAsPromise(e) {
|
|
2808
2808
|
try {
|
|
2809
2809
|
const r = this.$request(e);
|
|
2810
|
-
return (await
|
|
2810
|
+
return (await Ni(r)).result.data;
|
|
2811
2811
|
} catch (r) {
|
|
2812
2812
|
throw xe.from(r);
|
|
2813
2813
|
}
|
|
@@ -2876,38 +2876,38 @@ class Gi {
|
|
|
2876
2876
|
or(this, "links", void 0), or(this, "runtime", void 0), or(this, "requestId", void 0), this.requestId = 0, this.runtime = {}, this.links = e.links.map((r) => r(this.runtime));
|
|
2877
2877
|
}
|
|
2878
2878
|
}
|
|
2879
|
-
const
|
|
2879
|
+
const Ji = Symbol.for("trpc_untypedClient"), Xi = {
|
|
2880
2880
|
query: "query",
|
|
2881
2881
|
mutate: "mutation",
|
|
2882
2882
|
subscribe: "subscription"
|
|
2883
|
-
},
|
|
2884
|
-
function
|
|
2885
|
-
const e =
|
|
2883
|
+
}, Zi = (t) => Xi[t];
|
|
2884
|
+
function eo(t) {
|
|
2885
|
+
const e = Ki(({ path: r, args: n }) => {
|
|
2886
2886
|
const s = [
|
|
2887
2887
|
...r
|
|
2888
|
-
], i =
|
|
2888
|
+
], i = Zi(s.pop()), u = s.join(".");
|
|
2889
2889
|
return t[i](u, ...n);
|
|
2890
2890
|
});
|
|
2891
|
-
return
|
|
2891
|
+
return zi((r) => r === Ji ? t : e[r]);
|
|
2892
2892
|
}
|
|
2893
|
-
function eo(t) {
|
|
2894
|
-
const e = new Gi(t);
|
|
2895
|
-
return Zi(e);
|
|
2896
|
-
}
|
|
2897
|
-
const bn = (t) => typeof t == "function";
|
|
2898
2893
|
function to(t) {
|
|
2894
|
+
const e = new Yi(t);
|
|
2895
|
+
return eo(e);
|
|
2896
|
+
}
|
|
2897
|
+
const wn = (t) => typeof t == "function";
|
|
2898
|
+
function ro(t) {
|
|
2899
2899
|
if (t)
|
|
2900
2900
|
return t;
|
|
2901
|
-
if (typeof window < "u" &&
|
|
2901
|
+
if (typeof window < "u" && wn(window.fetch))
|
|
2902
2902
|
return window.fetch;
|
|
2903
|
-
if (typeof globalThis < "u" &&
|
|
2903
|
+
if (typeof globalThis < "u" && wn(globalThis.fetch))
|
|
2904
2904
|
return globalThis.fetch;
|
|
2905
2905
|
throw new Error("No fetch implementation found");
|
|
2906
2906
|
}
|
|
2907
|
-
const
|
|
2907
|
+
const En = () => {
|
|
2908
2908
|
throw new Error("Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new");
|
|
2909
2909
|
};
|
|
2910
|
-
function
|
|
2910
|
+
function Pn(t) {
|
|
2911
2911
|
let e = null, r = null;
|
|
2912
2912
|
const n = () => {
|
|
2913
2913
|
clearTimeout(r), r = null, e = null;
|
|
@@ -2952,14 +2952,14 @@ function En(t) {
|
|
|
2952
2952
|
d.batch = y;
|
|
2953
2953
|
t.fetch(y.items.map((d) => d.key)).then(async (d) => {
|
|
2954
2954
|
var h;
|
|
2955
|
-
await Promise.all(d.map(async (m,
|
|
2956
|
-
var O,
|
|
2957
|
-
const g = y.items[
|
|
2955
|
+
await Promise.all(d.map(async (m, P) => {
|
|
2956
|
+
var O, S;
|
|
2957
|
+
const g = y.items[P];
|
|
2958
2958
|
try {
|
|
2959
|
-
const
|
|
2960
|
-
(O = g.resolve) == null || O.call(g,
|
|
2961
|
-
} catch (
|
|
2962
|
-
(
|
|
2959
|
+
const E = await Promise.resolve(m);
|
|
2960
|
+
(O = g.resolve) == null || O.call(g, E);
|
|
2961
|
+
} catch (E) {
|
|
2962
|
+
(S = g.reject) == null || S.call(g, E);
|
|
2963
2963
|
}
|
|
2964
2964
|
g.batch = null, g.reject = null, g.resolve = null;
|
|
2965
2965
|
}));
|
|
@@ -2977,8 +2977,8 @@ function En(t) {
|
|
|
2977
2977
|
aborted: !1,
|
|
2978
2978
|
key: l,
|
|
2979
2979
|
batch: null,
|
|
2980
|
-
resolve:
|
|
2981
|
-
reject:
|
|
2980
|
+
resolve: En,
|
|
2981
|
+
reject: En
|
|
2982
2982
|
}, y = new Promise((f, d) => {
|
|
2983
2983
|
c.reject = d, c.resolve = f, e || (e = []), e.push(c);
|
|
2984
2984
|
});
|
|
@@ -2988,7 +2988,7 @@ function En(t) {
|
|
|
2988
2988
|
load: u
|
|
2989
2989
|
};
|
|
2990
2990
|
}
|
|
2991
|
-
function
|
|
2991
|
+
function no(...t) {
|
|
2992
2992
|
const e = new AbortController(), r = t.length;
|
|
2993
2993
|
let n = 0;
|
|
2994
2994
|
const s = () => {
|
|
@@ -3000,7 +3000,7 @@ function ro(...t) {
|
|
|
3000
3000
|
});
|
|
3001
3001
|
return e.signal;
|
|
3002
3002
|
}
|
|
3003
|
-
function
|
|
3003
|
+
function so(t) {
|
|
3004
3004
|
const e = t;
|
|
3005
3005
|
return e ? "input" in e ? e : {
|
|
3006
3006
|
input: e,
|
|
@@ -3016,15 +3016,15 @@ function no(t) {
|
|
|
3016
3016
|
}
|
|
3017
3017
|
};
|
|
3018
3018
|
}
|
|
3019
|
-
function
|
|
3019
|
+
function io(t) {
|
|
3020
3020
|
return {
|
|
3021
3021
|
url: t.url.toString(),
|
|
3022
3022
|
fetch: t.fetch,
|
|
3023
|
-
transformer:
|
|
3023
|
+
transformer: so(t.transformer),
|
|
3024
3024
|
methodOverride: t.methodOverride
|
|
3025
3025
|
};
|
|
3026
3026
|
}
|
|
3027
|
-
function
|
|
3027
|
+
function oo(t) {
|
|
3028
3028
|
const e = {};
|
|
3029
3029
|
for (let r = 0; r < t.length; r++) {
|
|
3030
3030
|
const n = t[r];
|
|
@@ -3032,47 +3032,47 @@ function io(t) {
|
|
|
3032
3032
|
}
|
|
3033
3033
|
return e;
|
|
3034
3034
|
}
|
|
3035
|
-
const
|
|
3035
|
+
const ao = {
|
|
3036
3036
|
query: "GET",
|
|
3037
3037
|
mutation: "POST",
|
|
3038
3038
|
subscription: "PATCH"
|
|
3039
3039
|
};
|
|
3040
|
-
function
|
|
3041
|
-
return "input" in t ? t.transformer.input.serialize(t.input) :
|
|
3040
|
+
function as(t) {
|
|
3041
|
+
return "input" in t ? t.transformer.input.serialize(t.input) : oo(t.inputs.map((e) => t.transformer.input.serialize(e)));
|
|
3042
3042
|
}
|
|
3043
|
-
const
|
|
3043
|
+
const us = (t) => {
|
|
3044
3044
|
const e = t.url.split("?");
|
|
3045
3045
|
let n = e[0].replace(/\/$/, "") + "/" + t.path;
|
|
3046
3046
|
const s = [];
|
|
3047
3047
|
if (e[1] && s.push(e[1]), "inputs" in t && s.push("batch=1"), t.type === "query" || t.type === "subscription") {
|
|
3048
|
-
const i =
|
|
3048
|
+
const i = as(t);
|
|
3049
3049
|
i !== void 0 && t.methodOverride !== "POST" && s.push(`input=${encodeURIComponent(JSON.stringify(i))}`);
|
|
3050
3050
|
}
|
|
3051
3051
|
return s.length && (n += "?" + s.join("&")), n;
|
|
3052
|
-
},
|
|
3052
|
+
}, uo = (t) => {
|
|
3053
3053
|
if (t.type === "query" && t.methodOverride !== "POST")
|
|
3054
3054
|
return;
|
|
3055
|
-
const e =
|
|
3055
|
+
const e = as(t);
|
|
3056
3056
|
return e !== void 0 ? JSON.stringify(e) : void 0;
|
|
3057
|
-
},
|
|
3057
|
+
}, co = (t) => yo({
|
|
3058
3058
|
...t,
|
|
3059
3059
|
contentTypeHeader: "application/json",
|
|
3060
|
-
getUrl:
|
|
3061
|
-
getBody:
|
|
3060
|
+
getUrl: us,
|
|
3061
|
+
getBody: uo
|
|
3062
3062
|
});
|
|
3063
|
-
class
|
|
3063
|
+
class lo extends Error {
|
|
3064
3064
|
constructor() {
|
|
3065
3065
|
const e = "AbortError";
|
|
3066
3066
|
super(e), this.name = e, this.message = e;
|
|
3067
3067
|
}
|
|
3068
3068
|
}
|
|
3069
|
-
const
|
|
3069
|
+
const fo = (t) => {
|
|
3070
3070
|
var e;
|
|
3071
3071
|
if (t != null && t.aborted)
|
|
3072
|
-
throw (e = t.throwIfAborted) == null || e.call(t), typeof DOMException < "u" ? new DOMException("AbortError", "AbortError") : new
|
|
3072
|
+
throw (e = t.throwIfAborted) == null || e.call(t), typeof DOMException < "u" ? new DOMException("AbortError", "AbortError") : new lo();
|
|
3073
3073
|
};
|
|
3074
|
-
async function
|
|
3075
|
-
|
|
3074
|
+
async function ho(t) {
|
|
3075
|
+
fo(t.signal);
|
|
3076
3076
|
const e = t.getUrl(t), r = t.getBody(t), { type: n } = t, s = await (async () => {
|
|
3077
3077
|
const u = await t.headers();
|
|
3078
3078
|
return Symbol.iterator in u ? Object.fromEntries(u) : u;
|
|
@@ -3085,15 +3085,15 @@ async function fo(t) {
|
|
|
3085
3085
|
} : void 0,
|
|
3086
3086
|
...s
|
|
3087
3087
|
};
|
|
3088
|
-
return
|
|
3089
|
-
method: t.methodOverride ??
|
|
3088
|
+
return ro(t.fetch)(e, {
|
|
3089
|
+
method: t.methodOverride ?? ao[n],
|
|
3090
3090
|
signal: t.signal,
|
|
3091
3091
|
body: r,
|
|
3092
3092
|
headers: i
|
|
3093
3093
|
});
|
|
3094
3094
|
}
|
|
3095
|
-
async function
|
|
3096
|
-
const e = {}, r = await
|
|
3095
|
+
async function yo(t) {
|
|
3096
|
+
const e = {}, r = await ho(t);
|
|
3097
3097
|
e.response = r;
|
|
3098
3098
|
const n = await r.json();
|
|
3099
3099
|
return e.responseJSON = n, {
|
|
@@ -3101,15 +3101,15 @@ async function ho(t) {
|
|
|
3101
3101
|
meta: e
|
|
3102
3102
|
};
|
|
3103
3103
|
}
|
|
3104
|
-
function
|
|
3105
|
-
const e =
|
|
3104
|
+
function po(t) {
|
|
3105
|
+
const e = io(t), r = t.maxURLLength ?? 1 / 0;
|
|
3106
3106
|
return () => {
|
|
3107
3107
|
const n = (l) => ({
|
|
3108
3108
|
validate(c) {
|
|
3109
3109
|
if (r === 1 / 0)
|
|
3110
3110
|
return !0;
|
|
3111
3111
|
const y = c.map((h) => h.path).join(","), f = c.map((h) => h.input);
|
|
3112
|
-
return
|
|
3112
|
+
return us({
|
|
3113
3113
|
...e,
|
|
3114
3114
|
type: l,
|
|
3115
3115
|
path: y,
|
|
@@ -3118,7 +3118,7 @@ function yo(t) {
|
|
|
3118
3118
|
}).length <= r;
|
|
3119
3119
|
},
|
|
3120
3120
|
async fetch(c) {
|
|
3121
|
-
const y = c.map((g) => g.path).join(","), f = c.map((g) => g.input), d =
|
|
3121
|
+
const y = c.map((g) => g.path).join(","), f = c.map((g) => g.input), d = no(...c.map((g) => g.signal)), h = await co({
|
|
3122
3122
|
...e,
|
|
3123
3123
|
path: y,
|
|
3124
3124
|
inputs: f,
|
|
@@ -3135,7 +3135,7 @@ function yo(t) {
|
|
|
3135
3135
|
json: g
|
|
3136
3136
|
}));
|
|
3137
3137
|
}
|
|
3138
|
-
}), s =
|
|
3138
|
+
}), s = Pn(n("query")), i = Pn(n("mutation")), u = {
|
|
3139
3139
|
query: s,
|
|
3140
3140
|
mutation: i
|
|
3141
3141
|
};
|
|
@@ -3147,7 +3147,7 @@ function yo(t) {
|
|
|
3147
3147
|
let d;
|
|
3148
3148
|
return f.then((h) => {
|
|
3149
3149
|
d = h;
|
|
3150
|
-
const m =
|
|
3150
|
+
const m = Wi(h.json, e.transformer.output);
|
|
3151
3151
|
if (!m.ok) {
|
|
3152
3152
|
c.error(xe.from(m.error, {
|
|
3153
3153
|
meta: h.meta
|
|
@@ -3167,8 +3167,8 @@ function yo(t) {
|
|
|
3167
3167
|
});
|
|
3168
3168
|
};
|
|
3169
3169
|
}
|
|
3170
|
-
const
|
|
3171
|
-
function
|
|
3170
|
+
const mo = (t, ...e) => typeof t == "function" ? t(...e) : t;
|
|
3171
|
+
function go() {
|
|
3172
3172
|
let t, e;
|
|
3173
3173
|
return {
|
|
3174
3174
|
promise: new Promise((n, s) => {
|
|
@@ -3178,8 +3178,8 @@ function mo() {
|
|
|
3178
3178
|
reject: e
|
|
3179
3179
|
};
|
|
3180
3180
|
}
|
|
3181
|
-
async function
|
|
3182
|
-
const e = await
|
|
3181
|
+
async function vo(t) {
|
|
3182
|
+
const e = await mo(t.url);
|
|
3183
3183
|
if (!t.connectionParams) return e;
|
|
3184
3184
|
const n = `${e.includes("?") ? "&" : "?"}connectionParams=1`;
|
|
3185
3185
|
return e + n;
|
|
@@ -3192,13 +3192,13 @@ function je(t, e, r) {
|
|
|
3192
3192
|
writable: !0
|
|
3193
3193
|
}) : t[e] = r, t;
|
|
3194
3194
|
}
|
|
3195
|
-
function
|
|
3196
|
-
const { promise: e, resolve: r, reject: n } =
|
|
3195
|
+
function bo(t) {
|
|
3196
|
+
const { promise: e, resolve: r, reject: n } = go();
|
|
3197
3197
|
return t.addEventListener("open", () => {
|
|
3198
3198
|
t.removeEventListener("error", n), r();
|
|
3199
3199
|
}), t.addEventListener("error", n), e;
|
|
3200
3200
|
}
|
|
3201
|
-
function
|
|
3201
|
+
function wo(t, { intervalMs: e, pongTimeoutMs: r }) {
|
|
3202
3202
|
let n, s;
|
|
3203
3203
|
function i() {
|
|
3204
3204
|
n = setTimeout(() => {
|
|
@@ -3241,10 +3241,10 @@ class $t {
|
|
|
3241
3241
|
async open() {
|
|
3242
3242
|
if (this.openPromise) return this.openPromise;
|
|
3243
3243
|
this.id = ++$t.connectCount;
|
|
3244
|
-
const e =
|
|
3245
|
-
this.openPromise = e.then(
|
|
3244
|
+
const e = vo(this.urlOptions).then((r) => new this.WebSocketPonyfill(r));
|
|
3245
|
+
this.openPromise = e.then(bo), this.ws = await e, this.ws.addEventListener("message", function({ data: r }) {
|
|
3246
3246
|
r === "PING" && this.send("PONG");
|
|
3247
|
-
}), this.keepAliveOpts.enabled &&
|
|
3247
|
+
}), this.keepAliveOpts.enabled && wo(this.ws, this.keepAliveOpts), this.ws.addEventListener("close", () => {
|
|
3248
3248
|
this.ws = null;
|
|
3249
3249
|
});
|
|
3250
3250
|
try {
|
|
@@ -3266,13 +3266,13 @@ class $t {
|
|
|
3266
3266
|
}
|
|
3267
3267
|
}
|
|
3268
3268
|
constructor(e) {
|
|
3269
|
-
if (je(this, "id", ++$t.connectCount), je(this, "WebSocketPonyfill", void 0), je(this, "urlOptions", void 0), je(this, "keepAliveOpts", void 0), je(this, "wsObservable",
|
|
3269
|
+
if (je(this, "id", ++$t.connectCount), je(this, "WebSocketPonyfill", void 0), je(this, "urlOptions", void 0), je(this, "keepAliveOpts", void 0), je(this, "wsObservable", Qi(null)), je(this, "openPromise", null), this.WebSocketPonyfill = e.WebSocketPonyfill ?? WebSocket, !this.WebSocketPonyfill)
|
|
3270
3270
|
throw new Error("No WebSocket implementation found - you probably don't want to use this on the server, but if you do you need to pass a `WebSocket`-ponyfill");
|
|
3271
3271
|
this.urlOptions = e.urlOptions, this.keepAliveOpts = e.keepAlive;
|
|
3272
3272
|
}
|
|
3273
3273
|
}
|
|
3274
3274
|
je($t, "connectCount", 0);
|
|
3275
|
-
class
|
|
3275
|
+
class Eo {
|
|
3276
3276
|
constructor() {
|
|
3277
3277
|
this.keyToValue = /* @__PURE__ */ new Map(), this.valueToKey = /* @__PURE__ */ new Map();
|
|
3278
3278
|
}
|
|
@@ -3289,9 +3289,9 @@ class wo {
|
|
|
3289
3289
|
this.keyToValue.clear(), this.valueToKey.clear();
|
|
3290
3290
|
}
|
|
3291
3291
|
}
|
|
3292
|
-
class
|
|
3292
|
+
class cs {
|
|
3293
3293
|
constructor(e) {
|
|
3294
|
-
this.generateIdentifier = e, this.kv = new
|
|
3294
|
+
this.generateIdentifier = e, this.kv = new Eo();
|
|
3295
3295
|
}
|
|
3296
3296
|
register(e, r) {
|
|
3297
3297
|
this.kv.getByValue(e) || (r || (r = this.generateIdentifier(e)), this.kv.set(r, e));
|
|
@@ -3306,7 +3306,7 @@ class us {
|
|
|
3306
3306
|
return this.kv.getByKey(e);
|
|
3307
3307
|
}
|
|
3308
3308
|
}
|
|
3309
|
-
class
|
|
3309
|
+
class Po extends cs {
|
|
3310
3310
|
constructor() {
|
|
3311
3311
|
super((e) => e.name), this.classToAllowedProps = /* @__PURE__ */ new Map();
|
|
3312
3312
|
}
|
|
@@ -3317,7 +3317,7 @@ class Eo extends us {
|
|
|
3317
3317
|
return this.classToAllowedProps.get(e);
|
|
3318
3318
|
}
|
|
3319
3319
|
}
|
|
3320
|
-
function
|
|
3320
|
+
function Oo(t) {
|
|
3321
3321
|
if ("values" in Object)
|
|
3322
3322
|
return Object.values(t);
|
|
3323
3323
|
const e = [];
|
|
@@ -3325,8 +3325,8 @@ function Po(t) {
|
|
|
3325
3325
|
t.hasOwnProperty(r) && e.push(t[r]);
|
|
3326
3326
|
return e;
|
|
3327
3327
|
}
|
|
3328
|
-
function
|
|
3329
|
-
const r =
|
|
3328
|
+
function Ro(t, e) {
|
|
3329
|
+
const r = Oo(t);
|
|
3330
3330
|
if ("find" in r)
|
|
3331
3331
|
return r.find(e);
|
|
3332
3332
|
const n = r;
|
|
@@ -3342,14 +3342,14 @@ function lt(t, e) {
|
|
|
3342
3342
|
function Mt(t, e) {
|
|
3343
3343
|
return t.indexOf(e) !== -1;
|
|
3344
3344
|
}
|
|
3345
|
-
function
|
|
3345
|
+
function On(t, e) {
|
|
3346
3346
|
for (let r = 0; r < t.length; r++) {
|
|
3347
3347
|
const n = t[r];
|
|
3348
3348
|
if (e(n))
|
|
3349
3349
|
return n;
|
|
3350
3350
|
}
|
|
3351
3351
|
}
|
|
3352
|
-
class
|
|
3352
|
+
class So {
|
|
3353
3353
|
constructor() {
|
|
3354
3354
|
this.transfomers = {};
|
|
3355
3355
|
}
|
|
@@ -3357,13 +3357,13 @@ class Ro {
|
|
|
3357
3357
|
this.transfomers[e.name] = e;
|
|
3358
3358
|
}
|
|
3359
3359
|
findApplicable(e) {
|
|
3360
|
-
return
|
|
3360
|
+
return Ro(this.transfomers, (r) => r.isApplicable(e));
|
|
3361
3361
|
}
|
|
3362
3362
|
findByName(e) {
|
|
3363
3363
|
return this.transfomers[e];
|
|
3364
3364
|
}
|
|
3365
3365
|
}
|
|
3366
|
-
const
|
|
3366
|
+
const Co = (t) => Object.prototype.toString.call(t).slice(8, -1), ls = (t) => typeof t > "u", To = (t) => t === null, Ot = (t) => typeof t != "object" || t === null || t === Object.prototype ? !1 : Object.getPrototypeOf(t) === null ? !0 : Object.getPrototypeOf(t) === Object.prototype, Sr = (t) => Ot(t) && Object.keys(t).length === 0, Ie = (t) => Array.isArray(t), Fo = (t) => typeof t == "string", Ao = (t) => typeof t == "number" && !isNaN(t), xo = (t) => typeof t == "boolean", Io = (t) => t instanceof RegExp, Rt = (t) => t instanceof Map, St = (t) => t instanceof Set, fs = (t) => Co(t) === "Symbol", Do = (t) => t instanceof Date && !isNaN(t.valueOf()), _o = (t) => t instanceof Error, Rn = (t) => typeof t == "number" && isNaN(t), ko = (t) => xo(t) || To(t) || ls(t) || Ao(t) || Fo(t) || fs(t), jo = (t) => typeof t == "bigint", qo = (t) => t === 1 / 0 || t === -1 / 0, Uo = (t) => ArrayBuffer.isView(t) && !(t instanceof DataView), Mo = (t) => t instanceof URL, ds = (t) => t.replace(/\./g, "\\."), ar = (t) => t.map(String).map(ds).join("."), bt = (t) => {
|
|
3367
3367
|
const e = [];
|
|
3368
3368
|
let r = "";
|
|
3369
3369
|
for (let s = 0; s < t.length; s++) {
|
|
@@ -3389,12 +3389,12 @@ function ae(t, e, r, n) {
|
|
|
3389
3389
|
untransform: n
|
|
3390
3390
|
};
|
|
3391
3391
|
}
|
|
3392
|
-
const
|
|
3393
|
-
ae(
|
|
3392
|
+
const hs = [
|
|
3393
|
+
ae(ls, "undefined", () => null, () => {
|
|
3394
3394
|
}),
|
|
3395
|
-
ae(
|
|
3396
|
-
ae(
|
|
3397
|
-
ae(
|
|
3395
|
+
ae(jo, "bigint", (t) => t.toString(), (t) => typeof BigInt < "u" ? BigInt(t) : (console.error("Please add a BigInt polyfill."), t)),
|
|
3396
|
+
ae(Do, "Date", (t) => t.toISOString(), (t) => new Date(t)),
|
|
3397
|
+
ae(_o, "Error", (t, e) => {
|
|
3398
3398
|
const r = {
|
|
3399
3399
|
name: t.name,
|
|
3400
3400
|
message: t.message
|
|
@@ -3408,7 +3408,7 @@ const ds = [
|
|
|
3408
3408
|
r[n] = t[n];
|
|
3409
3409
|
}), r;
|
|
3410
3410
|
}),
|
|
3411
|
-
ae(
|
|
3411
|
+
ae(Io, "regexp", (t) => "" + t, (t) => {
|
|
3412
3412
|
const e = t.slice(1, t.lastIndexOf("/")), r = t.slice(t.lastIndexOf("/") + 1);
|
|
3413
3413
|
return new RegExp(e, r);
|
|
3414
3414
|
}),
|
|
@@ -3421,9 +3421,9 @@ const ds = [
|
|
|
3421
3421
|
(t) => new Set(t)
|
|
3422
3422
|
),
|
|
3423
3423
|
ae(Rt, "map", (t) => [...t.entries()], (t) => new Map(t)),
|
|
3424
|
-
ae((t) =>
|
|
3424
|
+
ae((t) => Rn(t) || qo(t), "number", (t) => Rn(t) ? "NaN" : t > 0 ? "Infinity" : "-Infinity", Number),
|
|
3425
3425
|
ae((t) => t === 0 && 1 / t === -1 / 0, "number", () => "-0", Number),
|
|
3426
|
-
ae(
|
|
3426
|
+
ae(Mo, "URL", (t) => t.toString(), (t) => new URL(t))
|
|
3427
3427
|
];
|
|
3428
3428
|
function Vt(t, e, r, n) {
|
|
3429
3429
|
return {
|
|
@@ -3433,12 +3433,12 @@ function Vt(t, e, r, n) {
|
|
|
3433
3433
|
untransform: n
|
|
3434
3434
|
};
|
|
3435
3435
|
}
|
|
3436
|
-
const
|
|
3436
|
+
const ys = Vt((t, e) => fs(t) ? !!e.symbolRegistry.getIdentifier(t) : !1, (t, e) => ["symbol", e.symbolRegistry.getIdentifier(t)], (t) => t.description, (t, e, r) => {
|
|
3437
3437
|
const n = r.symbolRegistry.getValue(e[1]);
|
|
3438
3438
|
if (!n)
|
|
3439
3439
|
throw new Error("Trying to deserialize unknown symbol");
|
|
3440
3440
|
return n;
|
|
3441
|
-
}),
|
|
3441
|
+
}), No = [
|
|
3442
3442
|
Int8Array,
|
|
3443
3443
|
Uint8Array,
|
|
3444
3444
|
Int16Array,
|
|
@@ -3448,16 +3448,16 @@ const hs = Vt((t, e) => ls(t) ? !!e.symbolRegistry.getIdentifier(t) : !1, (t, e)
|
|
|
3448
3448
|
Float32Array,
|
|
3449
3449
|
Float64Array,
|
|
3450
3450
|
Uint8ClampedArray
|
|
3451
|
-
].reduce((t, e) => (t[e.name] = e, t), {}),
|
|
3452
|
-
const r =
|
|
3451
|
+
].reduce((t, e) => (t[e.name] = e, t), {}), ps = Vt(Uo, (t) => ["typed-array", t.constructor.name], (t) => [...t], (t, e) => {
|
|
3452
|
+
const r = No[e[1]];
|
|
3453
3453
|
if (!r)
|
|
3454
3454
|
throw new Error("Trying to deserialize unknown typed array");
|
|
3455
3455
|
return new r(t);
|
|
3456
3456
|
});
|
|
3457
|
-
function
|
|
3457
|
+
function ms(t, e) {
|
|
3458
3458
|
return t != null && t.constructor ? !!e.classRegistry.getIdentifier(t.constructor) : !1;
|
|
3459
3459
|
}
|
|
3460
|
-
const
|
|
3460
|
+
const gs = Vt(ms, (t, e) => ["class", e.classRegistry.getIdentifier(t.constructor)], (t, e) => {
|
|
3461
3461
|
const r = e.classRegistry.getAllowedProps(t.constructor);
|
|
3462
3462
|
if (!r)
|
|
3463
3463
|
return { ...t };
|
|
@@ -3470,44 +3470,44 @@ const ms = Vt(ps, (t, e) => ["class", e.classRegistry.getIdentifier(t.constructo
|
|
|
3470
3470
|
if (!n)
|
|
3471
3471
|
throw new Error(`Trying to deserialize unknown class '${e[1]}' - check https://github.com/blitz-js/superjson/issues/116#issuecomment-773996564`);
|
|
3472
3472
|
return Object.assign(Object.create(n.prototype), t);
|
|
3473
|
-
}),
|
|
3473
|
+
}), vs = Vt((t, e) => !!e.customTransformerRegistry.findApplicable(t), (t, e) => ["custom", e.customTransformerRegistry.findApplicable(t).name], (t, e) => e.customTransformerRegistry.findApplicable(t).serialize(t), (t, e, r) => {
|
|
3474
3474
|
const n = r.customTransformerRegistry.findByName(e[1]);
|
|
3475
3475
|
if (!n)
|
|
3476
3476
|
throw new Error("Trying to deserialize unknown custom value");
|
|
3477
3477
|
return n.deserialize(t);
|
|
3478
|
-
}),
|
|
3479
|
-
const r =
|
|
3478
|
+
}), Lo = [gs, ys, vs, ps], Sn = (t, e) => {
|
|
3479
|
+
const r = On(Lo, (s) => s.isApplicable(t, e));
|
|
3480
3480
|
if (r)
|
|
3481
3481
|
return {
|
|
3482
3482
|
value: r.transform(t, e),
|
|
3483
3483
|
type: r.annotation(t, e)
|
|
3484
3484
|
};
|
|
3485
|
-
const n =
|
|
3485
|
+
const n = On(hs, (s) => s.isApplicable(t, e));
|
|
3486
3486
|
if (n)
|
|
3487
3487
|
return {
|
|
3488
3488
|
value: n.transform(t, e),
|
|
3489
3489
|
type: n.annotation
|
|
3490
3490
|
};
|
|
3491
|
-
},
|
|
3492
|
-
|
|
3493
|
-
|
|
3491
|
+
}, bs = {};
|
|
3492
|
+
hs.forEach((t) => {
|
|
3493
|
+
bs[t.annotation] = t;
|
|
3494
3494
|
});
|
|
3495
|
-
const
|
|
3495
|
+
const Qo = (t, e, r) => {
|
|
3496
3496
|
if (Ie(e))
|
|
3497
3497
|
switch (e[0]) {
|
|
3498
3498
|
case "symbol":
|
|
3499
|
-
return
|
|
3499
|
+
return ys.untransform(t, e, r);
|
|
3500
3500
|
case "class":
|
|
3501
|
-
return ms.untransform(t, e, r);
|
|
3502
|
-
case "custom":
|
|
3503
3501
|
return gs.untransform(t, e, r);
|
|
3502
|
+
case "custom":
|
|
3503
|
+
return vs.untransform(t, e, r);
|
|
3504
3504
|
case "typed-array":
|
|
3505
|
-
return
|
|
3505
|
+
return ps.untransform(t, e, r);
|
|
3506
3506
|
default:
|
|
3507
3507
|
throw new Error("Unknown transformation: " + e);
|
|
3508
3508
|
}
|
|
3509
3509
|
else {
|
|
3510
|
-
const n =
|
|
3510
|
+
const n = bs[e];
|
|
3511
3511
|
if (!n)
|
|
3512
3512
|
throw new Error("Unknown transformation: " + e);
|
|
3513
3513
|
return n.untransform(t, r);
|
|
@@ -3520,7 +3520,7 @@ const Lo = (t, e, r) => {
|
|
|
3520
3520
|
r.next(), e--;
|
|
3521
3521
|
return r.next().value;
|
|
3522
3522
|
};
|
|
3523
|
-
function
|
|
3523
|
+
function ws(t) {
|
|
3524
3524
|
if (Mt(t, "__proto__"))
|
|
3525
3525
|
throw new Error("__proto__ is not allowed as a property");
|
|
3526
3526
|
if (Mt(t, "prototype"))
|
|
@@ -3528,8 +3528,8 @@ function bs(t) {
|
|
|
3528
3528
|
if (Mt(t, "constructor"))
|
|
3529
3529
|
throw new Error("constructor is not allowed as a property");
|
|
3530
3530
|
}
|
|
3531
|
-
const
|
|
3532
|
-
|
|
3531
|
+
const $o = (t, e) => {
|
|
3532
|
+
ws(e);
|
|
3533
3533
|
for (let r = 0; r < e.length; r++) {
|
|
3534
3534
|
const n = e[r];
|
|
3535
3535
|
if (St(t))
|
|
@@ -3549,7 +3549,7 @@ const Qo = (t, e) => {
|
|
|
3549
3549
|
}
|
|
3550
3550
|
return t;
|
|
3551
3551
|
}, Cr = (t, e, r) => {
|
|
3552
|
-
if (
|
|
3552
|
+
if (ws(e), e.length === 0)
|
|
3553
3553
|
return r(t);
|
|
3554
3554
|
let n = t;
|
|
3555
3555
|
for (let i = 0; i < e.length - 1; i++) {
|
|
@@ -3609,14 +3609,14 @@ function Tr(t, e, r = []) {
|
|
|
3609
3609
|
Tr(i, e, [...r, ...bt(u)]);
|
|
3610
3610
|
}), e(n, r);
|
|
3611
3611
|
}
|
|
3612
|
-
function
|
|
3612
|
+
function Ko(t, e, r) {
|
|
3613
3613
|
return Tr(e, (n, s) => {
|
|
3614
|
-
t = Cr(t, s, (i) =>
|
|
3614
|
+
t = Cr(t, s, (i) => Qo(i, n, r));
|
|
3615
3615
|
}), t;
|
|
3616
3616
|
}
|
|
3617
|
-
function
|
|
3617
|
+
function zo(t, e) {
|
|
3618
3618
|
function r(n, s) {
|
|
3619
|
-
const i =
|
|
3619
|
+
const i = $o(t, bt(s));
|
|
3620
3620
|
n.map(bt).forEach((u) => {
|
|
3621
3621
|
t = Cr(t, u, () => i);
|
|
3622
3622
|
});
|
|
@@ -3630,8 +3630,8 @@ function Ko(t, e) {
|
|
|
3630
3630
|
lt(e, r);
|
|
3631
3631
|
return t;
|
|
3632
3632
|
}
|
|
3633
|
-
const
|
|
3634
|
-
function
|
|
3633
|
+
const Vo = (t, e) => Ot(t) || Ie(t) || Rt(t) || St(t) || ms(t, e);
|
|
3634
|
+
function Wo(t, e, r) {
|
|
3635
3635
|
const n = r.get(t);
|
|
3636
3636
|
n ? n.push(e) : r.set(t, [e]);
|
|
3637
3637
|
}
|
|
@@ -3646,36 +3646,36 @@ function Ho(t, e) {
|
|
|
3646
3646
|
i.length === 0 ? n = u.map(ar) : r[ar(i)] = u.map(ar);
|
|
3647
3647
|
}), n ? Sr(r) ? [n] : [n, r] : Sr(r) ? void 0 : r;
|
|
3648
3648
|
}
|
|
3649
|
-
const
|
|
3650
|
-
const l =
|
|
3649
|
+
const Es = (t, e, r, n, s = [], i = [], u = /* @__PURE__ */ new Map()) => {
|
|
3650
|
+
const l = ko(t);
|
|
3651
3651
|
if (!l) {
|
|
3652
|
-
|
|
3652
|
+
Wo(t, s, e);
|
|
3653
3653
|
const m = u.get(t);
|
|
3654
3654
|
if (m)
|
|
3655
3655
|
return n ? {
|
|
3656
3656
|
transformedValue: null
|
|
3657
3657
|
} : m;
|
|
3658
3658
|
}
|
|
3659
|
-
if (!
|
|
3660
|
-
const m =
|
|
3659
|
+
if (!Vo(t, r)) {
|
|
3660
|
+
const m = Sn(t, r), P = m ? {
|
|
3661
3661
|
transformedValue: m.value,
|
|
3662
3662
|
annotations: [m.type]
|
|
3663
3663
|
} : {
|
|
3664
3664
|
transformedValue: t
|
|
3665
3665
|
};
|
|
3666
|
-
return l || u.set(t,
|
|
3666
|
+
return l || u.set(t, P), P;
|
|
3667
3667
|
}
|
|
3668
3668
|
if (Mt(i, t))
|
|
3669
3669
|
return {
|
|
3670
3670
|
transformedValue: null
|
|
3671
3671
|
};
|
|
3672
|
-
const c =
|
|
3673
|
-
lt(y, (m,
|
|
3674
|
-
if (
|
|
3675
|
-
throw new Error(`Detected property ${
|
|
3676
|
-
const g =
|
|
3677
|
-
f[
|
|
3678
|
-
d[
|
|
3672
|
+
const c = Sn(t, r), y = (c == null ? void 0 : c.value) ?? t, f = Ie(y) ? [] : {}, d = {};
|
|
3673
|
+
lt(y, (m, P) => {
|
|
3674
|
+
if (P === "__proto__" || P === "constructor" || P === "prototype")
|
|
3675
|
+
throw new Error(`Detected property ${P}. This is a prototype pollution risk, please remove it from your object.`);
|
|
3676
|
+
const g = Es(m, e, r, n, [...s, P], [...i, t], u);
|
|
3677
|
+
f[P] = g.transformedValue, Ie(g.annotations) ? d[P] = g.annotations : Ot(g.annotations) && lt(g.annotations, (O, S) => {
|
|
3678
|
+
d[ds(P) + "." + S] = O;
|
|
3679
3679
|
});
|
|
3680
3680
|
});
|
|
3681
3681
|
const h = Sr(d) ? {
|
|
@@ -3687,19 +3687,19 @@ const ws = (t, e, r, n, s = [], i = [], u = /* @__PURE__ */ new Map()) => {
|
|
|
3687
3687
|
};
|
|
3688
3688
|
return l || u.set(t, h), h;
|
|
3689
3689
|
};
|
|
3690
|
-
function
|
|
3690
|
+
function Ps(t) {
|
|
3691
3691
|
return Object.prototype.toString.call(t).slice(8, -1);
|
|
3692
3692
|
}
|
|
3693
|
-
function
|
|
3694
|
-
return
|
|
3693
|
+
function Cn(t) {
|
|
3694
|
+
return Ps(t) === "Array";
|
|
3695
3695
|
}
|
|
3696
|
-
function
|
|
3697
|
-
if (
|
|
3696
|
+
function Bo(t) {
|
|
3697
|
+
if (Ps(t) !== "Object")
|
|
3698
3698
|
return !1;
|
|
3699
3699
|
const e = Object.getPrototypeOf(t);
|
|
3700
3700
|
return !!e && e.constructor === Object && e === Object.prototype;
|
|
3701
3701
|
}
|
|
3702
|
-
function
|
|
3702
|
+
function Go(t, e, r, n, s) {
|
|
3703
3703
|
const i = {}.propertyIsEnumerable.call(n, e) ? "enumerable" : "nonenumerable";
|
|
3704
3704
|
i === "enumerable" && (t[e] = r), s && i === "nonenumerable" && Object.defineProperty(t, e, {
|
|
3705
3705
|
value: r,
|
|
@@ -3709,16 +3709,16 @@ function Bo(t, e, r, n, s) {
|
|
|
3709
3709
|
});
|
|
3710
3710
|
}
|
|
3711
3711
|
function Fr(t, e = {}) {
|
|
3712
|
-
if (
|
|
3712
|
+
if (Cn(t))
|
|
3713
3713
|
return t.map((s) => Fr(s, e));
|
|
3714
|
-
if (!
|
|
3714
|
+
if (!Bo(t))
|
|
3715
3715
|
return t;
|
|
3716
3716
|
const r = Object.getOwnPropertyNames(t), n = Object.getOwnPropertySymbols(t);
|
|
3717
3717
|
return [...r, ...n].reduce((s, i) => {
|
|
3718
|
-
if (
|
|
3718
|
+
if (Cn(e.props) && !e.props.includes(i))
|
|
3719
3719
|
return s;
|
|
3720
3720
|
const u = t[i], l = Fr(u, e);
|
|
3721
|
-
return
|
|
3721
|
+
return Go(s, i, l, t, e.nonenumerable), s;
|
|
3722
3722
|
}, {});
|
|
3723
3723
|
}
|
|
3724
3724
|
class A {
|
|
@@ -3726,10 +3726,10 @@ class A {
|
|
|
3726
3726
|
* @param dedupeReferentialEqualities If true, SuperJSON will make sure only one instance of referentially equal objects are serialized and the rest are replaced with `null`.
|
|
3727
3727
|
*/
|
|
3728
3728
|
constructor({ dedupe: e = !1 } = {}) {
|
|
3729
|
-
this.classRegistry = new
|
|
3729
|
+
this.classRegistry = new Po(), this.symbolRegistry = new cs((r) => r.description ?? ""), this.customTransformerRegistry = new So(), this.allowedErrorProps = [], this.dedupe = e;
|
|
3730
3730
|
}
|
|
3731
3731
|
serialize(e) {
|
|
3732
|
-
const r = /* @__PURE__ */ new Map(), n =
|
|
3732
|
+
const r = /* @__PURE__ */ new Map(), n = Es(e, r, this, this.dedupe), s = {
|
|
3733
3733
|
json: n.transformedValue
|
|
3734
3734
|
};
|
|
3735
3735
|
n.annotations && (s.meta = {
|
|
@@ -3745,7 +3745,7 @@ class A {
|
|
|
3745
3745
|
deserialize(e) {
|
|
3746
3746
|
const { json: r, meta: n } = e;
|
|
3747
3747
|
let s = Fr(r);
|
|
3748
|
-
return n != null && n.values && (s =
|
|
3748
|
+
return n != null && n.values && (s = Ko(s, n.values, this)), n != null && n.referentialEqualities && (s = zo(s, n.referentialEqualities)), s;
|
|
3749
3749
|
}
|
|
3750
3750
|
stringify(e) {
|
|
3751
3751
|
return JSON.stringify(this.serialize(e));
|
|
@@ -3786,19 +3786,19 @@ A.registerClass;
|
|
|
3786
3786
|
A.registerCustom;
|
|
3787
3787
|
A.registerSymbol;
|
|
3788
3788
|
A.allowErrorProps;
|
|
3789
|
-
class
|
|
3789
|
+
class Wt extends Error {
|
|
3790
3790
|
constructor(r, n) {
|
|
3791
3791
|
super(r);
|
|
3792
3792
|
tr(this, "context");
|
|
3793
3793
|
tr(this, "originalError");
|
|
3794
|
-
this.name = "FolioError", this.context = n == null ? void 0 : n.context, this.originalError = n == null ? void 0 : n.originalError, Object.setPrototypeOf(this,
|
|
3794
|
+
this.name = "FolioError", this.context = n == null ? void 0 : n.context, this.originalError = n == null ? void 0 : n.originalError, Object.setPrototypeOf(this, Wt.prototype);
|
|
3795
3795
|
}
|
|
3796
3796
|
}
|
|
3797
3797
|
function G(t, e) {
|
|
3798
|
-
return new
|
|
3798
|
+
return new Wt(t, e);
|
|
3799
3799
|
}
|
|
3800
3800
|
function ne(t) {
|
|
3801
|
-
t instanceof
|
|
3801
|
+
t instanceof Wt ? (console.error(`🔴 Folio Error: ${t.message}`), t.context && Object.keys(t.context).length > 0 && console.error("Context:", t.context), t.originalError && console.error("Original error:", t.originalError)) : console.error("🔴 Unexpected error:", t);
|
|
3802
3802
|
}
|
|
3803
3803
|
function de(t, e, r) {
|
|
3804
3804
|
return G(`${t}: ${e}`, {
|
|
@@ -3806,11 +3806,11 @@ function de(t, e, r) {
|
|
|
3806
3806
|
originalError: r
|
|
3807
3807
|
});
|
|
3808
3808
|
}
|
|
3809
|
-
const
|
|
3810
|
-
function
|
|
3811
|
-
const r =
|
|
3809
|
+
const Os = Zs(null);
|
|
3810
|
+
function Yo(t, e) {
|
|
3811
|
+
const r = to({
|
|
3812
3812
|
links: [
|
|
3813
|
-
|
|
3813
|
+
po({
|
|
3814
3814
|
url: `${t}/trpc`,
|
|
3815
3815
|
headers: () => ({
|
|
3816
3816
|
Authorization: `Bearer ${e}`
|
|
@@ -3820,16 +3820,16 @@ function Go(t, e) {
|
|
|
3820
3820
|
]
|
|
3821
3821
|
}), n = async (s, i, u = null) => {
|
|
3822
3822
|
try {
|
|
3823
|
-
const l = Object.entries(
|
|
3824
|
-
(h, [m,
|
|
3823
|
+
const l = Object.entries(Wn).reduce(
|
|
3824
|
+
(h, [m, P]) => (P.extensions.forEach((g) => {
|
|
3825
3825
|
h.set(g, m);
|
|
3826
3826
|
}), h),
|
|
3827
3827
|
/* @__PURE__ */ new Map()
|
|
3828
3828
|
), c = i.map((h) => {
|
|
3829
|
-
const m = h.name.toLowerCase(),
|
|
3829
|
+
const m = h.name.toLowerCase(), P = m.includes(".") ? m.substring(m.lastIndexOf(".")) : "", g = P.startsWith(".") ? P : `.${P}`, O = l.get(g) || null;
|
|
3830
3830
|
return { ...h, mimeType: O };
|
|
3831
3831
|
}).filter(
|
|
3832
|
-
(h) => h.mimeType !== null &&
|
|
3832
|
+
(h) => h.mimeType !== null && oi.has(h.mimeType)
|
|
3833
3833
|
);
|
|
3834
3834
|
if (c.length === 0)
|
|
3835
3835
|
return { filesToCreate: [] };
|
|
@@ -3980,7 +3980,7 @@ function Go(t, e) {
|
|
|
3980
3980
|
const f = await r.fileRouter.createFile.mutate({
|
|
3981
3981
|
file: {
|
|
3982
3982
|
projectId: s,
|
|
3983
|
-
mimeType:
|
|
3983
|
+
mimeType: xr.DIRECTORY,
|
|
3984
3984
|
path: "",
|
|
3985
3985
|
name: i,
|
|
3986
3986
|
size: 0,
|
|
@@ -4086,7 +4086,7 @@ function Go(t, e) {
|
|
|
4086
4086
|
}
|
|
4087
4087
|
};
|
|
4088
4088
|
}
|
|
4089
|
-
function
|
|
4089
|
+
function ra({
|
|
4090
4090
|
children: t,
|
|
4091
4091
|
host: e = "http://localhost",
|
|
4092
4092
|
port: r = 5174,
|
|
@@ -4095,8 +4095,8 @@ function ea({
|
|
|
4095
4095
|
onAnalyticsEvent: i,
|
|
4096
4096
|
passTokenInQueryParam: u = !1
|
|
4097
4097
|
}) {
|
|
4098
|
-
const [l, c] =
|
|
4099
|
-
() => new
|
|
4098
|
+
const [l, c] = ei(null), y = ti(
|
|
4099
|
+
() => new Ei({
|
|
4100
4100
|
defaultOptions: {
|
|
4101
4101
|
queries: {
|
|
4102
4102
|
staleTime: 30 * 1e3,
|
|
@@ -4108,20 +4108,25 @@ function ea({
|
|
|
4108
4108
|
[]
|
|
4109
4109
|
);
|
|
4110
4110
|
return nr(() => {
|
|
4111
|
-
const f = `${e}:${r}`, d =
|
|
4111
|
+
const f = `${e}:${r}`, d = Yo(f, n);
|
|
4112
4112
|
c(d);
|
|
4113
4113
|
}, [e, r, n]), nr(() => {
|
|
4114
|
-
if (!l || !s)
|
|
4114
|
+
if (!l || !s)
|
|
4115
|
+
return;
|
|
4115
4116
|
const f = JSON.stringify(s);
|
|
4116
4117
|
l.updateUserMetadata(f).catch((d) => {
|
|
4117
|
-
|
|
4118
|
+
console.error(
|
|
4119
|
+
"[FolioProvider] Failed to set initial user metadata:",
|
|
4120
|
+
d
|
|
4121
|
+
), ne(
|
|
4118
4122
|
G("Failed to set initial user metadata", {
|
|
4119
4123
|
originalError: d
|
|
4120
4124
|
})
|
|
4121
4125
|
);
|
|
4122
4126
|
});
|
|
4123
4127
|
}, [l, s]), nr(() => {
|
|
4124
|
-
if (!i)
|
|
4128
|
+
if (!i)
|
|
4129
|
+
return;
|
|
4125
4130
|
const f = (h) => {
|
|
4126
4131
|
i(h.detail);
|
|
4127
4132
|
}, d = (h) => {
|
|
@@ -4137,24 +4142,36 @@ function ea({
|
|
|
4137
4142
|
f
|
|
4138
4143
|
), window.removeEventListener("message", d);
|
|
4139
4144
|
};
|
|
4140
|
-
}, [i]), /* @__PURE__ */ wt.jsx(
|
|
4141
|
-
|
|
4145
|
+
}, [i]), /* @__PURE__ */ wt.jsx(Ci, { client: y, children: /* @__PURE__ */ wt.jsx(
|
|
4146
|
+
Os.Provider,
|
|
4142
4147
|
{
|
|
4143
4148
|
value: { host: e, port: r, client: l, token: n, passTokenInQueryParam: u },
|
|
4144
4149
|
children: t
|
|
4145
4150
|
}
|
|
4146
4151
|
) });
|
|
4147
4152
|
}
|
|
4148
|
-
function
|
|
4149
|
-
const t =
|
|
4153
|
+
function We() {
|
|
4154
|
+
const t = ri(Os);
|
|
4150
4155
|
if (!t)
|
|
4151
|
-
throw
|
|
4156
|
+
throw console.error(
|
|
4157
|
+
"[useFolioContext] Context not found - component not wrapped in FolioProvider"
|
|
4158
|
+
), G(
|
|
4152
4159
|
"useFolioContext must be used within a FolioProvider"
|
|
4153
4160
|
);
|
|
4154
4161
|
return t;
|
|
4155
4162
|
}
|
|
4156
|
-
const
|
|
4157
|
-
|
|
4163
|
+
const Ar = "folio-token";
|
|
4164
|
+
let Tn = null;
|
|
4165
|
+
const Jo = () => {
|
|
4166
|
+
const t = (e) => {
|
|
4167
|
+
var r;
|
|
4168
|
+
((r = e.data) == null ? void 0 : r.type) === Ar && typeof e.data.token == "string" && !Tn && (Tn = e.data.token);
|
|
4169
|
+
};
|
|
4170
|
+
return window.addEventListener("message", t), () => window.removeEventListener("message", t);
|
|
4171
|
+
};
|
|
4172
|
+
typeof window < "u" && Jo();
|
|
4173
|
+
const { useEffect: Fn, useRef: Xo, useState: Zo } = K;
|
|
4174
|
+
function na({
|
|
4158
4175
|
width: t = "100%",
|
|
4159
4176
|
height: e = "100vh",
|
|
4160
4177
|
allow: r = "camera; microphone; clipboard-read; clipboard-write; fullscreen",
|
|
@@ -4168,58 +4185,75 @@ function ta({
|
|
|
4168
4185
|
port: c,
|
|
4169
4186
|
token: y,
|
|
4170
4187
|
passTokenInQueryParam: f
|
|
4171
|
-
} =
|
|
4172
|
-
|
|
4188
|
+
} = We(), d = Xo(null), [h, m] = Zo(), P = `${l}:${c}`, g = u !== void 0 ? u : f;
|
|
4189
|
+
Fn(() => {
|
|
4173
4190
|
(() => {
|
|
4174
4191
|
try {
|
|
4175
|
-
let
|
|
4176
|
-
g && (
|
|
4177
|
-
} catch (
|
|
4178
|
-
ne(
|
|
4192
|
+
let E = P;
|
|
4193
|
+
g && (E = `${P}?jwt=${encodeURIComponent(y)}`), m(E);
|
|
4194
|
+
} catch (E) {
|
|
4195
|
+
console.error("[FolioEmbed] Failed to set up iframe URL:", E), ne(
|
|
4179
4196
|
G("Failed to set up iframe URL", {
|
|
4180
4197
|
context: { host: l, port: c },
|
|
4181
|
-
originalError:
|
|
4198
|
+
originalError: E
|
|
4182
4199
|
})
|
|
4183
4200
|
);
|
|
4184
4201
|
}
|
|
4185
4202
|
})();
|
|
4186
|
-
}, [l, c, y,
|
|
4187
|
-
if (g
|
|
4188
|
-
|
|
4189
|
-
|
|
4203
|
+
}, [l, c, y, P, g]), Fn(() => {
|
|
4204
|
+
if (g)
|
|
4205
|
+
return;
|
|
4206
|
+
const S = (E) => {
|
|
4207
|
+
var I, q;
|
|
4190
4208
|
try {
|
|
4191
|
-
if (((
|
|
4209
|
+
if (((I = E.data) == null ? void 0 : I.type) !== "folio-request-token")
|
|
4192
4210
|
return;
|
|
4193
|
-
|
|
4194
|
-
|
|
4211
|
+
if (!E.source || typeof E.source.postMessage != "function") {
|
|
4212
|
+
console.warn("[FolioEmbed] Invalid event source for token request");
|
|
4213
|
+
return;
|
|
4214
|
+
}
|
|
4215
|
+
E.source.postMessage(
|
|
4216
|
+
{ type: Ar, token: y },
|
|
4195
4217
|
"*"
|
|
4196
4218
|
);
|
|
4197
|
-
} catch (
|
|
4198
|
-
ne(
|
|
4219
|
+
} catch (N) {
|
|
4220
|
+
console.error("[FolioEmbed] Failed to handle iframe message:", N), ne(
|
|
4199
4221
|
G("Failed to handle iframe message", {
|
|
4200
|
-
context: { messageType: (
|
|
4201
|
-
originalError:
|
|
4222
|
+
context: { messageType: (q = E == null ? void 0 : E.data) == null ? void 0 : q.type },
|
|
4223
|
+
originalError: N
|
|
4202
4224
|
})
|
|
4203
4225
|
);
|
|
4204
4226
|
}
|
|
4205
4227
|
};
|
|
4206
|
-
return window.addEventListener("message",
|
|
4228
|
+
return window.addEventListener("message", S), () => {
|
|
4229
|
+
window.removeEventListener("message", S);
|
|
4230
|
+
};
|
|
4207
4231
|
}, [y, g]);
|
|
4208
4232
|
const O = () => {
|
|
4209
|
-
var
|
|
4210
|
-
if (
|
|
4211
|
-
|
|
4212
|
-
|
|
4213
|
-
|
|
4214
|
-
|
|
4215
|
-
|
|
4216
|
-
|
|
4217
|
-
|
|
4218
|
-
|
|
4219
|
-
|
|
4220
|
-
|
|
4221
|
-
|
|
4222
|
-
|
|
4233
|
+
var E;
|
|
4234
|
+
if (g || !((E = d.current) != null && E.contentWindow))
|
|
4235
|
+
return;
|
|
4236
|
+
const S = (I = 1) => {
|
|
4237
|
+
var q;
|
|
4238
|
+
if ((q = d.current) != null && q.contentWindow)
|
|
4239
|
+
try {
|
|
4240
|
+
d.current.contentWindow.postMessage(
|
|
4241
|
+
{ type: Ar, token: y },
|
|
4242
|
+
"*"
|
|
4243
|
+
);
|
|
4244
|
+
} catch (N) {
|
|
4245
|
+
console.error(
|
|
4246
|
+
`[FolioEmbed] Failed to post token message to iframe on load (attempt ${I}):`,
|
|
4247
|
+
N
|
|
4248
|
+
), ne(
|
|
4249
|
+
G("Failed to post token message to iframe", {
|
|
4250
|
+
originalError: N,
|
|
4251
|
+
context: { attemptNumber: I }
|
|
4252
|
+
})
|
|
4253
|
+
);
|
|
4254
|
+
}
|
|
4255
|
+
};
|
|
4256
|
+
S(1), setTimeout(() => S(2), 100), setTimeout(() => S(3), 500), setTimeout(() => S(4), 1e3);
|
|
4223
4257
|
};
|
|
4224
4258
|
return h ? /* @__PURE__ */ wt.jsx(
|
|
4225
4259
|
"div",
|
|
@@ -4253,8 +4287,8 @@ function ta({
|
|
|
4253
4287
|
}
|
|
4254
4288
|
) : null;
|
|
4255
4289
|
}
|
|
4256
|
-
function
|
|
4257
|
-
const { client: t } =
|
|
4290
|
+
function sa() {
|
|
4291
|
+
const { client: t } = We(), e = kr({
|
|
4258
4292
|
queryKey: ["folioProjects"],
|
|
4259
4293
|
queryFn: async () => {
|
|
4260
4294
|
if (!t)
|
|
@@ -4278,8 +4312,8 @@ function ra() {
|
|
|
4278
4312
|
refetch: e.refetch
|
|
4279
4313
|
};
|
|
4280
4314
|
}
|
|
4281
|
-
function
|
|
4282
|
-
const { client: t } =
|
|
4315
|
+
function ia() {
|
|
4316
|
+
const { client: t } = We(), e = dt(), r = kr({
|
|
4283
4317
|
queryKey: ["folioUserMetadata"],
|
|
4284
4318
|
queryFn: async () => {
|
|
4285
4319
|
if (!t)
|
|
@@ -4323,8 +4357,8 @@ function na() {
|
|
|
4323
4357
|
refetch: r.refetch
|
|
4324
4358
|
};
|
|
4325
4359
|
}
|
|
4326
|
-
function
|
|
4327
|
-
const { client: e } =
|
|
4360
|
+
function oa(t) {
|
|
4361
|
+
const { client: e } = We(), r = kr({
|
|
4328
4362
|
queryKey: ["folioFiles", t],
|
|
4329
4363
|
queryFn: async () => {
|
|
4330
4364
|
if (!e)
|
|
@@ -4347,8 +4381,8 @@ function sa(t) {
|
|
|
4347
4381
|
refetch: r.refetch
|
|
4348
4382
|
};
|
|
4349
4383
|
}
|
|
4350
|
-
function
|
|
4351
|
-
const { client: t } =
|
|
4384
|
+
function aa() {
|
|
4385
|
+
const { client: t } = We(), e = dt(), r = Kt({
|
|
4352
4386
|
mutationFn: async (n) => {
|
|
4353
4387
|
if (!t)
|
|
4354
4388
|
throw de(
|
|
@@ -4374,8 +4408,8 @@ function ia() {
|
|
|
4374
4408
|
newProject: r.data
|
|
4375
4409
|
};
|
|
4376
4410
|
}
|
|
4377
|
-
function
|
|
4378
|
-
const { client: e } =
|
|
4411
|
+
function ua(t) {
|
|
4412
|
+
const { client: e } = We(), r = dt(), n = Kt({
|
|
4379
4413
|
mutationFn: async (s) => {
|
|
4380
4414
|
if (!e)
|
|
4381
4415
|
throw de(
|
|
@@ -4403,8 +4437,8 @@ function oa(t) {
|
|
|
4403
4437
|
newFiles: n.data
|
|
4404
4438
|
};
|
|
4405
4439
|
}
|
|
4406
|
-
function
|
|
4407
|
-
const { client: e } =
|
|
4440
|
+
function ca(t) {
|
|
4441
|
+
const { client: e } = We(), r = dt(), n = Kt({
|
|
4408
4442
|
mutationFn: async (s) => {
|
|
4409
4443
|
if (!e)
|
|
4410
4444
|
throw de(
|
|
@@ -4446,12 +4480,12 @@ function aa(t) {
|
|
|
4446
4480
|
};
|
|
4447
4481
|
}
|
|
4448
4482
|
export {
|
|
4449
|
-
|
|
4450
|
-
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4454
|
-
|
|
4455
|
-
|
|
4456
|
-
|
|
4483
|
+
na as FolioEmbed,
|
|
4484
|
+
ra as FolioProvider,
|
|
4485
|
+
ca as useAddFolioDirectoriesWithFiles,
|
|
4486
|
+
ua as useAddFolioFiles,
|
|
4487
|
+
aa as useAddFolioProject,
|
|
4488
|
+
oa as useFolioFiles,
|
|
4489
|
+
sa as useFolioProjects,
|
|
4490
|
+
ia as useFolioUserMetadata
|
|
4457
4491
|
};
|