@shiftengineering/folio 0.1.13 → 0.1.15

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.
@@ -2,18 +2,18 @@ var Jr = (t) => {
2
2
  throw TypeError(t);
3
3
  };
4
4
  var Yt = (t, e, r) => e.has(t) || Jr("Cannot " + r);
5
- var o = (t, e, r) => (Yt(t, e, "read from private field"), r ? r.call(t) : e.get(t)), w = (t, e, r) => e.has(t) ? Jr("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, r), g = (t, e, r, n) => (Yt(t, e, "write to private field"), n ? n.call(t, r) : e.set(t, r), r), P = (t, e, r) => (Yt(t, e, "access private method"), r);
5
+ var o = (t, e, r) => (Yt(t, e, "read from private field"), r ? r.call(t) : e.get(t)), E = (t, e, r) => e.has(t) ? Jr("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, r), b = (t, e, r, n) => (Yt(t, e, "write to private field"), n ? n.call(t, r) : e.set(t, r), r), P = (t, e, r) => (Yt(t, e, "access private method"), r);
6
6
  var _t = (t, e, r, n) => ({
7
7
  set _(s) {
8
- g(t, e, s, r);
8
+ b(t, e, s, r);
9
9
  },
10
10
  get _() {
11
11
  return o(t, e, n);
12
12
  }
13
13
  });
14
14
  import * as $ from "react";
15
- import Mn, { createContext as Vs, useState as zs, useMemo as Hs, useEffect as Xr, useContext as Ws } from "react";
16
- var rr = { exports: {} }, ht = {};
15
+ import Nn, { createContext as Ws, useState as Hs, useMemo as Bs, useEffect as Xr, useContext as Gs } from "react";
16
+ var rr = { exports: {} }, dt = {};
17
17
  /**
18
18
  * @license React
19
19
  * react-jsx-runtime.production.min.js
@@ -24,20 +24,20 @@ var rr = { exports: {} }, ht = {};
24
24
  * LICENSE file in the root directory of this source tree.
25
25
  */
26
26
  var Zr;
27
- function Bs() {
28
- if (Zr) return ht;
27
+ function Ys() {
28
+ if (Zr) return dt;
29
29
  Zr = 1;
30
- var t = Mn, 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, a = { key: !0, ref: !0, __self: !0, __source: !0 };
30
+ var t = Nn, 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, a = { key: !0, ref: !0, __self: !0, __source: !0 };
31
31
  function u(l, c, d) {
32
- var f, h = {}, p = null, m = null;
33
- d !== void 0 && (p = "" + d), c.key !== void 0 && (p = "" + c.key), c.ref !== void 0 && (m = c.ref);
32
+ var f, h = {}, y = null, m = null;
33
+ d !== void 0 && (y = "" + d), c.key !== void 0 && (y = "" + c.key), c.ref !== void 0 && (m = c.ref);
34
34
  for (f in c) n.call(c, f) && !a.hasOwnProperty(f) && (h[f] = c[f]);
35
35
  if (l && l.defaultProps) for (f in c = l.defaultProps, c) h[f] === void 0 && (h[f] = c[f]);
36
- return { $$typeof: e, type: l, key: p, ref: m, props: h, _owner: s.current };
36
+ return { $$typeof: e, type: l, key: y, ref: m, props: h, _owner: s.current };
37
37
  }
38
- return ht.Fragment = r, ht.jsx = u, ht.jsxs = u, ht;
38
+ return dt.Fragment = r, dt.jsx = u, dt.jsxs = u, dt;
39
39
  }
40
- var dt = {};
40
+ var yt = {};
41
41
  /**
42
42
  * @license React
43
43
  * react-jsx-runtime.development.js
@@ -48,47 +48,47 @@ var dt = {};
48
48
  * LICENSE file in the root directory of this source tree.
49
49
  */
50
50
  var en;
51
- function Gs() {
51
+ function Js() {
52
52
  return en || (en = 1, process.env.NODE_ENV !== "production" && function() {
53
- var t = Mn, e = Symbol.for("react.element"), r = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), a = Symbol.for("react.profiler"), u = Symbol.for("react.provider"), l = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), p = Symbol.for("react.lazy"), m = Symbol.for("react.offscreen"), E = Symbol.iterator, b = "@@iterator";
54
- function R(i) {
53
+ var t = Nn, e = Symbol.for("react.element"), r = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), a = Symbol.for("react.profiler"), u = Symbol.for("react.provider"), l = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), y = Symbol.for("react.lazy"), m = Symbol.for("react.offscreen"), R = Symbol.iterator, g = "@@iterator";
54
+ function w(i) {
55
55
  if (i === null || typeof i != "object")
56
56
  return null;
57
- var y = E && i[E] || i[b];
58
- return typeof y == "function" ? y : null;
57
+ var p = R && i[R] || i[g];
58
+ return typeof p == "function" ? p : null;
59
59
  }
60
60
  var A = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
61
- function C(i) {
61
+ function S(i) {
62
62
  {
63
- for (var y = arguments.length, v = new Array(y > 1 ? y - 1 : 0), O = 1; O < y; O++)
63
+ for (var p = arguments.length, v = new Array(p > 1 ? p - 1 : 0), O = 1; O < p; O++)
64
64
  v[O - 1] = arguments[O];
65
65
  j("error", i, v);
66
66
  }
67
67
  }
68
- function j(i, y, v) {
68
+ function j(i, p, v) {
69
69
  {
70
70
  var O = A.ReactDebugCurrentFrame, D = O.getStackAddendum();
71
- D !== "" && (y += "%s", v = v.concat([D]));
71
+ D !== "" && (p += "%s", v = v.concat([D]));
72
72
  var I = v.map(function(F) {
73
73
  return String(F);
74
74
  });
75
- I.unshift("Warning: " + y), Function.prototype.apply.call(console[i], console, I);
75
+ I.unshift("Warning: " + p), Function.prototype.apply.call(console[i], console, I);
76
76
  }
77
77
  }
78
78
  var Q = !1, z = !1, X = !1, K = !1, q = !1, k;
79
79
  k = Symbol.for("react.module.reference");
80
80
  function ye(i) {
81
- return !!(typeof i == "string" || typeof i == "function" || i === n || i === a || q || i === s || i === d || i === f || K || i === m || Q || z || X || typeof i == "object" && i !== null && (i.$$typeof === p || i.$$typeof === h || i.$$typeof === u || i.$$typeof === l || i.$$typeof === c || // This needs to include all possible module reference object
81
+ return !!(typeof i == "string" || typeof i == "function" || i === n || i === a || q || i === s || i === d || i === f || K || i === m || Q || z || X || typeof i == "object" && i !== null && (i.$$typeof === y || i.$$typeof === h || i.$$typeof === u || i.$$typeof === l || i.$$typeof === c || // This needs to include all possible module reference object
82
82
  // types supported by any Flight configuration anywhere since
83
83
  // we don't know which Flight build this will end up being used
84
84
  // with.
85
85
  i.$$typeof === k || i.getModuleId !== void 0));
86
86
  }
87
- function pe(i, y, v) {
87
+ function pe(i, p, v) {
88
88
  var O = i.displayName;
89
89
  if (O)
90
90
  return O;
91
- var D = y.displayName || y.name || "";
91
+ var D = p.displayName || p.name || "";
92
92
  return D !== "" ? v + "(" + D + ")" : v;
93
93
  }
94
94
  function Fe(i) {
@@ -97,7 +97,7 @@ function Gs() {
97
97
  function me(i) {
98
98
  if (i == null)
99
99
  return null;
100
- if (typeof i.tag == "number" && C("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof i == "function")
100
+ if (typeof i.tag == "number" && S("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof i == "function")
101
101
  return i.displayName || i.name || null;
102
102
  if (typeof i == "string")
103
103
  return i;
@@ -118,8 +118,8 @@ function Gs() {
118
118
  if (typeof i == "object")
119
119
  switch (i.$$typeof) {
120
120
  case l:
121
- var y = i;
122
- return Fe(y) + ".Consumer";
121
+ var p = i;
122
+ return Fe(p) + ".Consumer";
123
123
  case u:
124
124
  var v = i;
125
125
  return Fe(v._context) + ".Provider";
@@ -128,7 +128,7 @@ function Gs() {
128
128
  case h:
129
129
  var O = i.displayName || null;
130
130
  return O !== null ? O : me(i.type) || "Memo";
131
- case p: {
131
+ case y: {
132
132
  var D = i, I = D._payload, F = D._init;
133
133
  try {
134
134
  return me(F(I));
@@ -139,13 +139,13 @@ function Gs() {
139
139
  }
140
140
  return null;
141
141
  }
142
- var Ae = Object.assign, lt = 0, xr, Fr, Ar, Dr, _r, Ir, kr;
142
+ var Ae = Object.assign, ft = 0, xr, Fr, Ar, Dr, _r, Ir, kr;
143
143
  function jr() {
144
144
  }
145
145
  jr.__reactDisabledLog = !0;
146
- function gs() {
146
+ function vs() {
147
147
  {
148
- if (lt === 0) {
148
+ if (ft === 0) {
149
149
  xr = console.log, Fr = console.info, Ar = console.warn, Dr = console.error, _r = console.group, Ir = console.groupCollapsed, kr = console.groupEnd;
150
150
  var i = {
151
151
  configurable: !0,
@@ -163,12 +163,12 @@ function Gs() {
163
163
  groupEnd: i
164
164
  });
165
165
  }
166
- lt++;
166
+ ft++;
167
167
  }
168
168
  }
169
- function bs() {
169
+ function ws() {
170
170
  {
171
- if (lt--, lt === 0) {
171
+ if (ft--, ft === 0) {
172
172
  var i = {
173
173
  configurable: !0,
174
174
  enumerable: !0,
@@ -198,11 +198,11 @@ function Gs() {
198
198
  })
199
199
  });
200
200
  }
201
- lt < 0 && C("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
201
+ ft < 0 && S("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
202
202
  }
203
203
  }
204
204
  var $t = A.ReactCurrentDispatcher, Kt;
205
- function xt(i, y, v) {
205
+ function xt(i, p, v) {
206
206
  {
207
207
  if (Kt === void 0)
208
208
  try {
@@ -217,10 +217,10 @@ function Gs() {
217
217
  }
218
218
  var Vt = !1, Ft;
219
219
  {
220
- var vs = typeof WeakMap == "function" ? WeakMap : Map;
221
- Ft = new vs();
220
+ var Es = typeof WeakMap == "function" ? WeakMap : Map;
221
+ Ft = new Es();
222
222
  }
223
- function qr(i, y) {
223
+ function qr(i, p) {
224
224
  if (!i || Vt)
225
225
  return "";
226
226
  {
@@ -233,9 +233,9 @@ function Gs() {
233
233
  var D = Error.prepareStackTrace;
234
234
  Error.prepareStackTrace = void 0;
235
235
  var I;
236
- I = $t.current, $t.current = null, gs();
236
+ I = $t.current, $t.current = null, vs();
237
237
  try {
238
- if (y) {
238
+ if (p) {
239
239
  var F = function() {
240
240
  throw Error();
241
241
  };
@@ -268,17 +268,17 @@ function Gs() {
268
268
  }
269
269
  } catch (G) {
270
270
  if (G && O && typeof G.stack == "string") {
271
- for (var S = G.stack.split(`
272
- `), H = O.stack.split(`
273
- `), U = S.length - 1, N = H.length - 1; U >= 1 && N >= 0 && S[U] !== H[N]; )
271
+ for (var C = G.stack.split(`
272
+ `), W = O.stack.split(`
273
+ `), U = C.length - 1, N = W.length - 1; U >= 1 && N >= 0 && C[U] !== W[N]; )
274
274
  N--;
275
275
  for (; U >= 1 && N >= 0; U--, N--)
276
- if (S[U] !== H[N]) {
276
+ if (C[U] !== W[N]) {
277
277
  if (U !== 1 || N !== 1)
278
278
  do
279
- if (U--, N--, N < 0 || S[U] !== H[N]) {
279
+ if (U--, N--, N < 0 || C[U] !== W[N]) {
280
280
  var Z = `
281
- ` + S[U].replace(" at new ", " at ");
281
+ ` + C[U].replace(" at new ", " at ");
282
282
  return i.displayName && Z.includes("<anonymous>") && (Z = Z.replace("<anonymous>", i.displayName)), typeof i == "function" && Ft.set(i, Z), Z;
283
283
  }
284
284
  while (U >= 1 && N >= 0);
@@ -286,23 +286,23 @@ function Gs() {
286
286
  }
287
287
  }
288
288
  } finally {
289
- Vt = !1, $t.current = I, bs(), Error.prepareStackTrace = D;
289
+ Vt = !1, $t.current = I, ws(), Error.prepareStackTrace = D;
290
290
  }
291
291
  var Ve = i ? i.displayName || i.name : "", De = Ve ? xt(Ve) : "";
292
292
  return typeof i == "function" && Ft.set(i, De), De;
293
293
  }
294
- function ws(i, y, v) {
294
+ function Rs(i, p, v) {
295
295
  return qr(i, !1);
296
296
  }
297
- function Es(i) {
298
- var y = i.prototype;
299
- return !!(y && y.isReactComponent);
297
+ function Os(i) {
298
+ var p = i.prototype;
299
+ return !!(p && p.isReactComponent);
300
300
  }
301
- function At(i, y, v) {
301
+ function At(i, p, v) {
302
302
  if (i == null)
303
303
  return "";
304
304
  if (typeof i == "function")
305
- return qr(i, Es(i));
305
+ return qr(i, Os(i));
306
306
  if (typeof i == "string")
307
307
  return xt(i);
308
308
  switch (i) {
@@ -314,57 +314,57 @@ function Gs() {
314
314
  if (typeof i == "object")
315
315
  switch (i.$$typeof) {
316
316
  case c:
317
- return ws(i.render);
317
+ return Rs(i.render);
318
318
  case h:
319
- return At(i.type, y, v);
320
- case p: {
319
+ return At(i.type, p, v);
320
+ case y: {
321
321
  var O = i, D = O._payload, I = O._init;
322
322
  try {
323
- return At(I(D), y, v);
323
+ return At(I(D), p, v);
324
324
  } catch {
325
325
  }
326
326
  }
327
327
  }
328
328
  return "";
329
329
  }
330
- var ft = Object.prototype.hasOwnProperty, Mr = {}, Ur = A.ReactDebugCurrentFrame;
330
+ var ht = Object.prototype.hasOwnProperty, Mr = {}, Ur = A.ReactDebugCurrentFrame;
331
331
  function Dt(i) {
332
332
  if (i) {
333
- var y = i._owner, v = At(i.type, i._source, y ? y.type : null);
333
+ var p = i._owner, v = At(i.type, i._source, p ? p.type : null);
334
334
  Ur.setExtraStackFrame(v);
335
335
  } else
336
336
  Ur.setExtraStackFrame(null);
337
337
  }
338
- function Rs(i, y, v, O, D) {
338
+ function Ps(i, p, v, O, D) {
339
339
  {
340
- var I = Function.call.bind(ft);
340
+ var I = Function.call.bind(ht);
341
341
  for (var F in i)
342
342
  if (I(i, F)) {
343
- var S = void 0;
343
+ var C = void 0;
344
344
  try {
345
345
  if (typeof i[F] != "function") {
346
- var H = Error((O || "React class") + ": " + v + " type `" + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[F] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
347
- throw H.name = "Invariant Violation", H;
346
+ var W = Error((O || "React class") + ": " + v + " type `" + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[F] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
347
+ throw W.name = "Invariant Violation", W;
348
348
  }
349
- S = i[F](y, F, O, v, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
349
+ C = i[F](p, F, O, v, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
350
350
  } catch (U) {
351
- S = U;
351
+ C = U;
352
352
  }
353
- S && !(S instanceof Error) && (Dt(D), C("%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).", O || "React class", v, F, typeof S), Dt(null)), S instanceof Error && !(S.message in Mr) && (Mr[S.message] = !0, Dt(D), C("Failed %s type: %s", v, S.message), Dt(null));
353
+ C && !(C instanceof Error) && (Dt(D), S("%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).", O || "React class", v, F, typeof C), Dt(null)), C instanceof Error && !(C.message in Mr) && (Mr[C.message] = !0, Dt(D), S("Failed %s type: %s", v, C.message), Dt(null));
354
354
  }
355
355
  }
356
356
  }
357
- var Os = Array.isArray;
357
+ var Ss = Array.isArray;
358
358
  function zt(i) {
359
- return Os(i);
359
+ return Ss(i);
360
360
  }
361
- function Ps(i) {
361
+ function Cs(i) {
362
362
  {
363
- var y = typeof Symbol == "function" && Symbol.toStringTag, v = y && i[Symbol.toStringTag] || i.constructor.name || "Object";
363
+ var p = typeof Symbol == "function" && Symbol.toStringTag, v = p && i[Symbol.toStringTag] || i.constructor.name || "Object";
364
364
  return v;
365
365
  }
366
366
  }
367
- function Ss(i) {
367
+ function Ts(i) {
368
368
  try {
369
369
  return Nr(i), !1;
370
370
  } catch {
@@ -375,38 +375,38 @@ function Gs() {
375
375
  return "" + i;
376
376
  }
377
377
  function Lr(i) {
378
- if (Ss(i))
379
- return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Ps(i)), Nr(i);
378
+ if (Ts(i))
379
+ return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Cs(i)), Nr(i);
380
380
  }
381
- var Qr = A.ReactCurrentOwner, Cs = {
381
+ var Qr = A.ReactCurrentOwner, xs = {
382
382
  key: !0,
383
383
  ref: !0,
384
384
  __self: !0,
385
385
  __source: !0
386
386
  }, $r, Kr;
387
- function Ts(i) {
388
- if (ft.call(i, "ref")) {
389
- var y = Object.getOwnPropertyDescriptor(i, "ref").get;
390
- if (y && y.isReactWarning)
387
+ function Fs(i) {
388
+ if (ht.call(i, "ref")) {
389
+ var p = Object.getOwnPropertyDescriptor(i, "ref").get;
390
+ if (p && p.isReactWarning)
391
391
  return !1;
392
392
  }
393
393
  return i.ref !== void 0;
394
394
  }
395
- function xs(i) {
396
- if (ft.call(i, "key")) {
397
- var y = Object.getOwnPropertyDescriptor(i, "key").get;
398
- if (y && y.isReactWarning)
395
+ function As(i) {
396
+ if (ht.call(i, "key")) {
397
+ var p = Object.getOwnPropertyDescriptor(i, "key").get;
398
+ if (p && p.isReactWarning)
399
399
  return !1;
400
400
  }
401
401
  return i.key !== void 0;
402
402
  }
403
- function Fs(i, y) {
403
+ function Ds(i, p) {
404
404
  typeof i.ref == "string" && Qr.current;
405
405
  }
406
- function As(i, y) {
406
+ function _s(i, p) {
407
407
  {
408
408
  var v = function() {
409
- $r || ($r = !0, C("%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)", y));
409
+ $r || ($r = !0, S("%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));
410
410
  };
411
411
  v.isReactWarning = !0, Object.defineProperty(i, "key", {
412
412
  get: v,
@@ -414,10 +414,10 @@ function Gs() {
414
414
  });
415
415
  }
416
416
  }
417
- function Ds(i, y) {
417
+ function Is(i, p) {
418
418
  {
419
419
  var v = function() {
420
- Kr || (Kr = !0, C("%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)", y));
420
+ Kr || (Kr = !0, S("%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));
421
421
  };
422
422
  v.isReactWarning = !0, Object.defineProperty(i, "ref", {
423
423
  get: v,
@@ -425,70 +425,70 @@ function Gs() {
425
425
  });
426
426
  }
427
427
  }
428
- var _s = function(i, y, v, O, D, I, F) {
429
- var S = {
428
+ var ks = function(i, p, v, O, D, I, F) {
429
+ var C = {
430
430
  // This tag allows us to uniquely identify this as a React Element
431
431
  $$typeof: e,
432
432
  // Built-in properties that belong on the element
433
433
  type: i,
434
- key: y,
434
+ key: p,
435
435
  ref: v,
436
436
  props: F,
437
437
  // Record the component responsible for creating this element.
438
438
  _owner: I
439
439
  };
440
- return S._store = {}, Object.defineProperty(S._store, "validated", {
440
+ return C._store = {}, Object.defineProperty(C._store, "validated", {
441
441
  configurable: !1,
442
442
  enumerable: !1,
443
443
  writable: !0,
444
444
  value: !1
445
- }), Object.defineProperty(S, "_self", {
445
+ }), Object.defineProperty(C, "_self", {
446
446
  configurable: !1,
447
447
  enumerable: !1,
448
448
  writable: !1,
449
449
  value: O
450
- }), Object.defineProperty(S, "_source", {
450
+ }), Object.defineProperty(C, "_source", {
451
451
  configurable: !1,
452
452
  enumerable: !1,
453
453
  writable: !1,
454
454
  value: D
455
- }), Object.freeze && (Object.freeze(S.props), Object.freeze(S)), S;
455
+ }), Object.freeze && (Object.freeze(C.props), Object.freeze(C)), C;
456
456
  };
457
- function Is(i, y, v, O, D) {
457
+ function js(i, p, v, O, D) {
458
458
  {
459
- var I, F = {}, S = null, H = null;
460
- v !== void 0 && (Lr(v), S = "" + v), xs(y) && (Lr(y.key), S = "" + y.key), Ts(y) && (H = y.ref, Fs(y, D));
461
- for (I in y)
462
- ft.call(y, I) && !Cs.hasOwnProperty(I) && (F[I] = y[I]);
459
+ var I, F = {}, C = null, W = null;
460
+ v !== void 0 && (Lr(v), C = "" + v), As(p) && (Lr(p.key), C = "" + p.key), Fs(p) && (W = p.ref, Ds(p, D));
461
+ for (I in p)
462
+ ht.call(p, I) && !xs.hasOwnProperty(I) && (F[I] = p[I]);
463
463
  if (i && i.defaultProps) {
464
464
  var U = i.defaultProps;
465
465
  for (I in U)
466
466
  F[I] === void 0 && (F[I] = U[I]);
467
467
  }
468
- if (S || H) {
468
+ if (C || W) {
469
469
  var N = typeof i == "function" ? i.displayName || i.name || "Unknown" : i;
470
- S && As(F, N), H && Ds(F, N);
470
+ C && _s(F, N), W && Is(F, N);
471
471
  }
472
- return _s(i, S, H, D, O, Qr.current, F);
472
+ return ks(i, C, W, D, O, Qr.current, F);
473
473
  }
474
474
  }
475
- var Ht = A.ReactCurrentOwner, Vr = A.ReactDebugCurrentFrame;
475
+ var Wt = A.ReactCurrentOwner, Vr = A.ReactDebugCurrentFrame;
476
476
  function Ke(i) {
477
477
  if (i) {
478
- var y = i._owner, v = At(i.type, i._source, y ? y.type : null);
478
+ var p = i._owner, v = At(i.type, i._source, p ? p.type : null);
479
479
  Vr.setExtraStackFrame(v);
480
480
  } else
481
481
  Vr.setExtraStackFrame(null);
482
482
  }
483
- var Wt;
484
- Wt = !1;
483
+ var Ht;
484
+ Ht = !1;
485
485
  function Bt(i) {
486
486
  return typeof i == "object" && i !== null && i.$$typeof === e;
487
487
  }
488
488
  function zr() {
489
489
  {
490
- if (Ht.current) {
491
- var i = me(Ht.current.type);
490
+ if (Wt.current) {
491
+ var i = me(Wt.current.type);
492
492
  if (i)
493
493
  return `
494
494
 
@@ -497,108 +497,108 @@ Check the render method of \`` + i + "`.";
497
497
  return "";
498
498
  }
499
499
  }
500
- function ks(i) {
500
+ function qs(i) {
501
501
  return "";
502
502
  }
503
- var Hr = {};
504
- function js(i) {
503
+ var Wr = {};
504
+ function Ms(i) {
505
505
  {
506
- var y = zr();
507
- if (!y) {
506
+ var p = zr();
507
+ if (!p) {
508
508
  var v = typeof i == "string" ? i : i.displayName || i.name;
509
- v && (y = `
509
+ v && (p = `
510
510
 
511
511
  Check the top-level render call using <` + v + ">.");
512
512
  }
513
- return y;
513
+ return p;
514
514
  }
515
515
  }
516
- function Wr(i, y) {
516
+ function Hr(i, p) {
517
517
  {
518
518
  if (!i._store || i._store.validated || i.key != null)
519
519
  return;
520
520
  i._store.validated = !0;
521
- var v = js(y);
522
- if (Hr[v])
521
+ var v = Ms(p);
522
+ if (Wr[v])
523
523
  return;
524
- Hr[v] = !0;
524
+ Wr[v] = !0;
525
525
  var O = "";
526
- i && i._owner && i._owner !== Ht.current && (O = " It was passed a child from " + me(i._owner.type) + "."), Ke(i), C('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', v, O), Ke(null);
526
+ i && i._owner && i._owner !== Wt.current && (O = " It was passed a child from " + me(i._owner.type) + "."), Ke(i), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', v, O), Ke(null);
527
527
  }
528
528
  }
529
- function Br(i, y) {
529
+ function Br(i, p) {
530
530
  {
531
531
  if (typeof i != "object")
532
532
  return;
533
533
  if (zt(i))
534
534
  for (var v = 0; v < i.length; v++) {
535
535
  var O = i[v];
536
- Bt(O) && Wr(O, y);
536
+ Bt(O) && Hr(O, p);
537
537
  }
538
538
  else if (Bt(i))
539
539
  i._store && (i._store.validated = !0);
540
540
  else if (i) {
541
- var D = R(i);
541
+ var D = w(i);
542
542
  if (typeof D == "function" && D !== i.entries)
543
543
  for (var I = D.call(i), F; !(F = I.next()).done; )
544
- Bt(F.value) && Wr(F.value, y);
544
+ Bt(F.value) && Hr(F.value, p);
545
545
  }
546
546
  }
547
547
  }
548
- function qs(i) {
548
+ function Us(i) {
549
549
  {
550
- var y = i.type;
551
- if (y == null || typeof y == "string")
550
+ var p = i.type;
551
+ if (p == null || typeof p == "string")
552
552
  return;
553
553
  var v;
554
- if (typeof y == "function")
555
- v = y.propTypes;
556
- else if (typeof y == "object" && (y.$$typeof === c || // Note: Memo only checks outer props here.
554
+ if (typeof p == "function")
555
+ v = p.propTypes;
556
+ else if (typeof p == "object" && (p.$$typeof === c || // Note: Memo only checks outer props here.
557
557
  // Inner props are checked in the reconciler.
558
- y.$$typeof === h))
559
- v = y.propTypes;
558
+ p.$$typeof === h))
559
+ v = p.propTypes;
560
560
  else
561
561
  return;
562
562
  if (v) {
563
- var O = me(y);
564
- Rs(v, i.props, "prop", O, i);
565
- } else if (y.PropTypes !== void 0 && !Wt) {
566
- Wt = !0;
567
- var D = me(y);
568
- C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", D || "Unknown");
563
+ var O = me(p);
564
+ Ps(v, i.props, "prop", O, i);
565
+ } else if (p.PropTypes !== void 0 && !Ht) {
566
+ Ht = !0;
567
+ var D = me(p);
568
+ S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", D || "Unknown");
569
569
  }
570
- typeof y.getDefaultProps == "function" && !y.getDefaultProps.isReactClassApproved && C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
570
+ typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
571
571
  }
572
572
  }
573
- function Ms(i) {
573
+ function Ns(i) {
574
574
  {
575
- for (var y = Object.keys(i.props), v = 0; v < y.length; v++) {
576
- var O = y[v];
575
+ for (var p = Object.keys(i.props), v = 0; v < p.length; v++) {
576
+ var O = p[v];
577
577
  if (O !== "children" && O !== "key") {
578
- Ke(i), C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", O), Ke(null);
578
+ Ke(i), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", O), Ke(null);
579
579
  break;
580
580
  }
581
581
  }
582
- i.ref !== null && (Ke(i), C("Invalid attribute `ref` supplied to `React.Fragment`."), Ke(null));
582
+ i.ref !== null && (Ke(i), S("Invalid attribute `ref` supplied to `React.Fragment`."), Ke(null));
583
583
  }
584
584
  }
585
585
  var Gr = {};
586
- function Yr(i, y, v, O, D, I) {
586
+ function Yr(i, p, v, O, D, I) {
587
587
  {
588
588
  var F = ye(i);
589
589
  if (!F) {
590
- var S = "";
591
- (i === void 0 || typeof i == "object" && i !== null && Object.keys(i).length === 0) && (S += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
592
- var H = ks();
593
- H ? S += H : S += zr();
590
+ var C = "";
591
+ (i === void 0 || typeof i == "object" && i !== null && Object.keys(i).length === 0) && (C += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
592
+ var W = qs();
593
+ W ? C += W : C += zr();
594
594
  var U;
595
- i === null ? U = "null" : zt(i) ? U = "array" : i !== void 0 && i.$$typeof === e ? (U = "<" + (me(i.type) || "Unknown") + " />", S = " Did you accidentally export a JSX literal instead of a component?") : U = typeof i, C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", U, S);
595
+ i === null ? U = "null" : zt(i) ? U = "array" : i !== void 0 && i.$$typeof === e ? (U = "<" + (me(i.type) || "Unknown") + " />", C = " Did you accidentally export a JSX literal instead of a component?") : U = typeof i, S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", U, C);
596
596
  }
597
- var N = Is(i, y, v, D, I);
597
+ var N = js(i, p, v, D, I);
598
598
  if (N == null)
599
599
  return N;
600
600
  if (F) {
601
- var Z = y.children;
601
+ var Z = p.children;
602
602
  if (Z !== void 0)
603
603
  if (O)
604
604
  if (zt(Z)) {
@@ -606,76 +606,76 @@ Check the top-level render call using <` + v + ">.");
606
606
  Br(Z[Ve], i);
607
607
  Object.freeze && Object.freeze(Z);
608
608
  } else
609
- C("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
609
+ S("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
610
610
  else
611
611
  Br(Z, i);
612
612
  }
613
- if (ft.call(y, "key")) {
614
- var De = me(i), G = Object.keys(y).filter(function(Ks) {
615
- return Ks !== "key";
613
+ if (ht.call(p, "key")) {
614
+ var De = me(i), G = Object.keys(p).filter(function(zs) {
615
+ return zs !== "key";
616
616
  }), Gt = G.length > 0 ? "{key: someKey, " + G.join(": ..., ") + ": ...}" : "{key: someKey}";
617
617
  if (!Gr[De + Gt]) {
618
- var $s = G.length > 0 ? "{" + G.join(": ..., ") + ": ...}" : "{}";
619
- C(`A props object containing a "key" prop is being spread into JSX:
618
+ var Vs = G.length > 0 ? "{" + G.join(": ..., ") + ": ...}" : "{}";
619
+ S(`A props object containing a "key" prop is being spread into JSX:
620
620
  let props = %s;
621
621
  <%s {...props} />
622
622
  React keys must be passed directly to JSX without using spread:
623
623
  let props = %s;
624
- <%s key={someKey} {...props} />`, Gt, De, $s, De), Gr[De + Gt] = !0;
624
+ <%s key={someKey} {...props} />`, Gt, De, Vs, De), Gr[De + Gt] = !0;
625
625
  }
626
626
  }
627
- return i === n ? Ms(N) : qs(N), N;
627
+ return i === n ? Ns(N) : Us(N), N;
628
628
  }
629
629
  }
630
- function Us(i, y, v) {
631
- return Yr(i, y, v, !0);
630
+ function Ls(i, p, v) {
631
+ return Yr(i, p, v, !0);
632
632
  }
633
- function Ns(i, y, v) {
634
- return Yr(i, y, v, !1);
633
+ function Qs(i, p, v) {
634
+ return Yr(i, p, v, !1);
635
635
  }
636
- var Ls = Ns, Qs = Us;
637
- dt.Fragment = n, dt.jsx = Ls, dt.jsxs = Qs;
638
- }()), dt;
636
+ var $s = Qs, Ks = Ls;
637
+ yt.Fragment = n, yt.jsx = $s, yt.jsxs = Ks;
638
+ }()), yt;
639
639
  }
640
- process.env.NODE_ENV === "production" ? rr.exports = Bs() : rr.exports = Gs();
641
- var gt = rr.exports, nr = /* @__PURE__ */ ((t) => (t.NOT_CHUNKED = "NOT_CHUNKED", t.PROCESSING = "PROCESSING", t.CHUNKED = "CHUNKED", t.ERROR_CHUNKING = "ERROR_CHUNKING", t))(nr || {}), Or = /* @__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))(Or || {});
642
- const yt = 4e3 * 1024 * 1024, Ys = [
640
+ process.env.NODE_ENV === "production" ? rr.exports = Ys() : rr.exports = Js();
641
+ var We = rr.exports, nr = /* @__PURE__ */ ((t) => (t.NOT_CHUNKED = "NOT_CHUNKED", t.PROCESSING = "PROCESSING", t.CHUNKED = "CHUNKED", t.ERROR_CHUNKING = "ERROR_CHUNKING", t))(nr || {}), Or = /* @__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))(Or || {});
642
+ const pt = 4e3 * 1024 * 1024, Xs = [
643
643
  ".txt",
644
644
  ".json",
645
645
  ".py",
646
646
  ".ts",
647
647
  ".tsx"
648
- ], Un = {
648
+ ], Ln = {
649
649
  "application/pdf": {
650
650
  extensions: [".pdf"],
651
- maxSize: yt
651
+ maxSize: pt
652
652
  },
653
653
  "text/plain": {
654
- extensions: Ys,
655
- maxSize: yt
654
+ extensions: Xs,
655
+ maxSize: pt
656
656
  },
657
657
  "text/csv": {
658
658
  extensions: [".csv"],
659
- maxSize: yt
659
+ maxSize: pt
660
660
  },
661
661
  "inode/directory": {
662
662
  extensions: [],
663
- maxSize: yt
663
+ maxSize: pt
664
664
  },
665
665
  "application/vnd.openxmlformats-officedocument.wordprocessingml.document": {
666
666
  extensions: [".docx"],
667
- maxSize: yt
667
+ maxSize: pt
668
668
  }
669
669
  };
670
- Object.entries(Un).reduce(
670
+ Object.entries(Ln).reduce(
671
671
  (t, [e, r]) => ({
672
672
  ...t,
673
673
  [e]: r.extensions
674
674
  }),
675
675
  {}
676
676
  );
677
- const Js = new Set(Object.values(Or));
678
- var at = class {
677
+ const Zs = new Set(Object.values(Or));
678
+ var ut = class {
679
679
  constructor() {
680
680
  this.listeners = /* @__PURE__ */ new Set(), this.subscribe = this.subscribe.bind(this);
681
681
  }
@@ -694,13 +694,13 @@ var at = class {
694
694
  }, Qe = typeof window > "u" || "Deno" in globalThis;
695
695
  function te() {
696
696
  }
697
- function Xs(t, e) {
697
+ function ei(t, e) {
698
698
  return typeof t == "function" ? t(e) : t;
699
699
  }
700
700
  function sr(t) {
701
701
  return typeof t == "number" && t >= 0 && t !== 1 / 0;
702
702
  }
703
- function Nn(t, e) {
703
+ function Qn(t, e) {
704
704
  return Math.max(t + (e || 0) - Date.now(), 0);
705
705
  }
706
706
  function He(t, e) {
@@ -795,7 +795,7 @@ function or(t) {
795
795
  function sn(t) {
796
796
  return Object.prototype.toString.call(t) === "[object Object]";
797
797
  }
798
- function Zs(t) {
798
+ function ti(t) {
799
799
  return new Promise((e) => {
800
800
  setTimeout(e, t);
801
801
  });
@@ -816,27 +816,27 @@ function ar(t, e, r) {
816
816
  }
817
817
  return e;
818
818
  }
819
- function ei(t, e, r = 0) {
819
+ function ri(t, e, r = 0) {
820
820
  const n = [...t, e];
821
821
  return r && n.length > r ? n.slice(1) : n;
822
822
  }
823
- function ti(t, e, r = 0) {
823
+ function ni(t, e, r = 0) {
824
824
  const n = [e, ...t];
825
825
  return r && n.length > r ? n.slice(0, -1) : n;
826
826
  }
827
827
  var Ut = Symbol();
828
- function Ln(t, e) {
828
+ function $n(t, e) {
829
829
  return process.env.NODE_ENV !== "production" && t.queryFn === Ut && console.error(
830
830
  `Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${t.queryHash}'`
831
831
  ), !t.queryFn && (e != null && e.initialPromise) ? () => e.initialPromise : !t.queryFn || t.queryFn === Ut ? () => Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)) : t.queryFn;
832
832
  }
833
- var Ie, be, We, En, ri = (En = class extends at {
833
+ var Ie, be, Be, On, si = (On = class extends ut {
834
834
  constructor() {
835
835
  super();
836
- w(this, Ie);
837
- w(this, be);
838
- w(this, We);
839
- g(this, We, (e) => {
836
+ E(this, Ie);
837
+ E(this, be);
838
+ E(this, Be);
839
+ b(this, Be, (e) => {
840
840
  if (!Qe && window.addEventListener) {
841
841
  const r = () => e();
842
842
  return window.addEventListener("visibilitychange", r, !1), () => {
@@ -846,20 +846,20 @@ var Ie, be, We, En, ri = (En = class extends at {
846
846
  });
847
847
  }
848
848
  onSubscribe() {
849
- o(this, be) || this.setEventListener(o(this, We));
849
+ o(this, be) || this.setEventListener(o(this, Be));
850
850
  }
851
851
  onUnsubscribe() {
852
852
  var e;
853
- this.hasListeners() || ((e = o(this, be)) == null || e.call(this), g(this, be, void 0));
853
+ this.hasListeners() || ((e = o(this, be)) == null || e.call(this), b(this, be, void 0));
854
854
  }
855
855
  setEventListener(e) {
856
856
  var r;
857
- g(this, We, e), (r = o(this, be)) == null || r.call(this), g(this, be, e((n) => {
857
+ b(this, Be, e), (r = o(this, be)) == null || r.call(this), b(this, be, e((n) => {
858
858
  typeof n == "boolean" ? this.setFocused(n) : this.onFocus();
859
859
  }));
860
860
  }
861
861
  setFocused(e) {
862
- o(this, Ie) !== e && (g(this, Ie, e), this.onFocus());
862
+ o(this, Ie) !== e && (b(this, Ie, e), this.onFocus());
863
863
  }
864
864
  onFocus() {
865
865
  const e = this.isFocused();
@@ -871,13 +871,13 @@ var Ie, be, We, En, ri = (En = class extends at {
871
871
  var e;
872
872
  return typeof o(this, Ie) == "boolean" ? o(this, Ie) : ((e = globalThis.document) == null ? void 0 : e.visibilityState) !== "hidden";
873
873
  }
874
- }, Ie = new WeakMap(), be = new WeakMap(), We = new WeakMap(), En), Sr = new ri(), Be, ve, Ge, Rn, ni = (Rn = class extends at {
874
+ }, Ie = new WeakMap(), be = new WeakMap(), Be = new WeakMap(), On), Sr = new si(), Ge, ve, Ye, Pn, ii = (Pn = class extends ut {
875
875
  constructor() {
876
876
  super();
877
- w(this, Be, !0);
878
- w(this, ve);
879
- w(this, Ge);
880
- g(this, Ge, (e) => {
877
+ E(this, Ge, !0);
878
+ E(this, ve);
879
+ E(this, Ye);
880
+ b(this, Ye, (e) => {
881
881
  if (!Qe && window.addEventListener) {
882
882
  const r = () => e(!0), n = () => e(!1);
883
883
  return window.addEventListener("online", r, !1), window.addEventListener("offline", n, !1), () => {
@@ -887,25 +887,25 @@ var Ie, be, We, En, ri = (En = class extends at {
887
887
  });
888
888
  }
889
889
  onSubscribe() {
890
- o(this, ve) || this.setEventListener(o(this, Ge));
890
+ o(this, ve) || this.setEventListener(o(this, Ye));
891
891
  }
892
892
  onUnsubscribe() {
893
893
  var e;
894
- this.hasListeners() || ((e = o(this, ve)) == null || e.call(this), g(this, ve, void 0));
894
+ this.hasListeners() || ((e = o(this, ve)) == null || e.call(this), b(this, ve, void 0));
895
895
  }
896
896
  setEventListener(e) {
897
897
  var r;
898
- g(this, Ge, e), (r = o(this, ve)) == null || r.call(this), g(this, ve, e(this.setOnline.bind(this)));
898
+ b(this, Ye, e), (r = o(this, ve)) == null || r.call(this), b(this, ve, e(this.setOnline.bind(this)));
899
899
  }
900
900
  setOnline(e) {
901
- o(this, Be) !== e && (g(this, Be, e), this.listeners.forEach((n) => {
901
+ o(this, Ge) !== e && (b(this, Ge, e), this.listeners.forEach((n) => {
902
902
  n(e);
903
903
  }));
904
904
  }
905
905
  isOnline() {
906
- return o(this, Be);
906
+ return o(this, Ge);
907
907
  }
908
- }, Be = new WeakMap(), ve = new WeakMap(), Ge = new WeakMap(), Rn), Nt = new ni();
908
+ }, Ge = new WeakMap(), ve = new WeakMap(), Ye = new WeakMap(), Pn), Nt = new ii();
909
909
  function ur() {
910
910
  let t, e;
911
911
  const r = new Promise((s, a) => {
@@ -928,64 +928,64 @@ function ur() {
928
928
  }), e(s);
929
929
  }, r;
930
930
  }
931
- function si(t) {
931
+ function oi(t) {
932
932
  return Math.min(1e3 * 2 ** t, 3e4);
933
933
  }
934
- function Qn(t) {
934
+ function Kn(t) {
935
935
  return (t ?? "online") === "online" ? Nt.isOnline() : !0;
936
936
  }
937
- var $n = class extends Error {
937
+ var Vn = class extends Error {
938
938
  constructor(t) {
939
939
  super("CancelledError"), this.revert = t == null ? void 0 : t.revert, this.silent = t == null ? void 0 : t.silent;
940
940
  }
941
941
  };
942
942
  function Jt(t) {
943
- return t instanceof $n;
943
+ return t instanceof Vn;
944
944
  }
945
- function Kn(t) {
945
+ function zn(t) {
946
946
  let e = !1, r = 0, n = !1, s;
947
- const a = ur(), u = (b) => {
948
- var R;
949
- n || (p(new $n(b)), (R = t.abort) == null || R.call(t));
947
+ const a = ur(), u = (g) => {
948
+ var w;
949
+ n || (y(new Vn(g)), (w = t.abort) == null || w.call(t));
950
950
  }, l = () => {
951
951
  e = !0;
952
952
  }, c = () => {
953
953
  e = !1;
954
- }, d = () => Sr.isFocused() && (t.networkMode === "always" || Nt.isOnline()) && t.canRun(), f = () => Qn(t.networkMode) && t.canRun(), h = (b) => {
955
- var R;
956
- n || (n = !0, (R = t.onSuccess) == null || R.call(t, b), s == null || s(), a.resolve(b));
957
- }, p = (b) => {
958
- var R;
959
- n || (n = !0, (R = t.onError) == null || R.call(t, b), s == null || s(), a.reject(b));
960
- }, m = () => new Promise((b) => {
961
- var R;
954
+ }, d = () => Sr.isFocused() && (t.networkMode === "always" || Nt.isOnline()) && t.canRun(), f = () => Kn(t.networkMode) && t.canRun(), h = (g) => {
955
+ var w;
956
+ n || (n = !0, (w = t.onSuccess) == null || w.call(t, g), s == null || s(), a.resolve(g));
957
+ }, y = (g) => {
958
+ var w;
959
+ n || (n = !0, (w = t.onError) == null || w.call(t, g), s == null || s(), a.reject(g));
960
+ }, m = () => new Promise((g) => {
961
+ var w;
962
962
  s = (A) => {
963
- (n || d()) && b(A);
964
- }, (R = t.onPause) == null || R.call(t);
963
+ (n || d()) && g(A);
964
+ }, (w = t.onPause) == null || w.call(t);
965
965
  }).then(() => {
966
- var b;
967
- s = void 0, n || (b = t.onContinue) == null || b.call(t);
968
- }), E = () => {
966
+ var g;
967
+ s = void 0, n || (g = t.onContinue) == null || g.call(t);
968
+ }), R = () => {
969
969
  if (n)
970
970
  return;
971
- let b;
972
- const R = r === 0 ? t.initialPromise : void 0;
971
+ let g;
972
+ const w = r === 0 ? t.initialPromise : void 0;
973
973
  try {
974
- b = R ?? t.fn();
974
+ g = w ?? t.fn();
975
975
  } catch (A) {
976
- b = Promise.reject(A);
976
+ g = Promise.reject(A);
977
977
  }
978
- Promise.resolve(b).then(h).catch((A) => {
978
+ Promise.resolve(g).then(h).catch((A) => {
979
979
  var X;
980
980
  if (n)
981
981
  return;
982
- const C = t.retry ?? (Qe ? 0 : 3), j = t.retryDelay ?? si, Q = typeof j == "function" ? j(r, A) : j, z = C === !0 || typeof C == "number" && r < C || typeof C == "function" && C(r, A);
982
+ const S = t.retry ?? (Qe ? 0 : 3), j = t.retryDelay ?? oi, Q = typeof j == "function" ? j(r, A) : j, z = S === !0 || typeof S == "number" && r < S || typeof S == "function" && S(r, A);
983
983
  if (e || !z) {
984
- p(A);
984
+ y(A);
985
985
  return;
986
986
  }
987
- r++, (X = t.onFail) == null || X.call(t, r, A), Zs(Q).then(() => d() ? void 0 : m()).then(() => {
988
- e ? p(A) : E();
987
+ r++, (X = t.onFail) == null || X.call(t, r, A), ti(Q).then(() => d() ? void 0 : m()).then(() => {
988
+ e ? y(A) : R();
989
989
  });
990
990
  });
991
991
  };
@@ -996,10 +996,10 @@ function Kn(t) {
996
996
  cancelRetry: l,
997
997
  continueRetry: c,
998
998
  canStart: f,
999
- start: () => (f() ? E() : m().then(E), a)
999
+ start: () => (f() ? R() : m().then(R), a)
1000
1000
  };
1001
1001
  }
1002
- function ii() {
1002
+ function ai() {
1003
1003
  let t = [], e = 0, r = (l) => {
1004
1004
  l();
1005
1005
  }, n = (l) => {
@@ -1058,15 +1058,15 @@ function ii() {
1058
1058
  }
1059
1059
  };
1060
1060
  }
1061
- var L = ii(), ke, On, Vn = (On = class {
1061
+ var L = ai(), ke, Sn, Wn = (Sn = class {
1062
1062
  constructor() {
1063
- w(this, ke);
1063
+ E(this, ke);
1064
1064
  }
1065
1065
  destroy() {
1066
1066
  this.clearGcTimeout();
1067
1067
  }
1068
1068
  scheduleGc() {
1069
- this.clearGcTimeout(), sr(this.gcTime) && g(this, ke, setTimeout(() => {
1069
+ this.clearGcTimeout(), sr(this.gcTime) && b(this, ke, setTimeout(() => {
1070
1070
  this.optionalRemove();
1071
1071
  }, this.gcTime));
1072
1072
  }
@@ -1077,20 +1077,20 @@ var L = ii(), ke, On, Vn = (On = class {
1077
1077
  );
1078
1078
  }
1079
1079
  clearGcTimeout() {
1080
- o(this, ke) && (clearTimeout(o(this, ke)), g(this, ke, void 0));
1080
+ o(this, ke) && (clearTimeout(o(this, ke)), b(this, ke, void 0));
1081
1081
  }
1082
- }, ke = new WeakMap(), On), Ye, Je, ee, je, V, Ot, qe, re, le, Pn, oi = (Pn = class extends Vn {
1082
+ }, ke = new WeakMap(), Sn), Je, Xe, ee, je, V, Ot, qe, re, le, Cn, ui = (Cn = class extends Wn {
1083
1083
  constructor(e) {
1084
1084
  super();
1085
- w(this, re);
1086
- w(this, Ye);
1087
- w(this, Je);
1088
- w(this, ee);
1089
- w(this, je);
1090
- w(this, V);
1091
- w(this, Ot);
1092
- w(this, qe);
1093
- g(this, qe, !1), g(this, Ot, e.defaultOptions), this.setOptions(e.options), this.observers = [], g(this, je, e.client), g(this, ee, o(this, je).getQueryCache()), this.queryKey = e.queryKey, this.queryHash = e.queryHash, g(this, Ye, ai(this.options)), this.state = e.state ?? o(this, Ye), this.scheduleGc();
1085
+ E(this, re);
1086
+ E(this, Je);
1087
+ E(this, Xe);
1088
+ E(this, ee);
1089
+ E(this, je);
1090
+ E(this, V);
1091
+ E(this, Ot);
1092
+ E(this, qe);
1093
+ b(this, qe, !1), b(this, Ot, e.defaultOptions), this.setOptions(e.options), this.observers = [], b(this, je, e.client), b(this, ee, o(this, je).getQueryCache()), this.queryKey = e.queryKey, this.queryHash = e.queryHash, b(this, Je, ci(this.options)), this.state = e.state ?? o(this, Je), this.scheduleGc();
1094
1094
  }
1095
1095
  get meta() {
1096
1096
  return this.options.meta;
@@ -1126,7 +1126,7 @@ var L = ii(), ke, On, Vn = (On = class {
1126
1126
  super.destroy(), this.cancel({ silent: !0 });
1127
1127
  }
1128
1128
  reset() {
1129
- this.destroy(), this.setState(o(this, Ye));
1129
+ this.destroy(), this.setState(o(this, Je));
1130
1130
  }
1131
1131
  isActive() {
1132
1132
  return this.observers.some(
@@ -1142,7 +1142,7 @@ var L = ii(), ke, On, Vn = (On = class {
1142
1142
  ) : this.state.data === void 0;
1143
1143
  }
1144
1144
  isStaleByTime(e = 0) {
1145
- return this.state.isInvalidated || this.state.data === void 0 || !Nn(this.state.dataUpdatedAt, e);
1145
+ return this.state.isInvalidated || this.state.data === void 0 || !Qn(this.state.dataUpdatedAt, e);
1146
1146
  }
1147
1147
  onFocus() {
1148
1148
  var r;
@@ -1175,7 +1175,7 @@ var L = ii(), ke, On, Vn = (On = class {
1175
1175
  return o(this, V).continueRetry(), o(this, V).promise;
1176
1176
  }
1177
1177
  if (e && this.setOptions(e), !this.options.queryFn) {
1178
- const h = this.observers.find((p) => p.options.queryFn);
1178
+ const h = this.observers.find((y) => y.options.queryFn);
1179
1179
  h && this.setOptions(h.options);
1180
1180
  }
1181
1181
  process.env.NODE_ENV !== "production" && (Array.isArray(this.options.queryKey) || console.error(
@@ -1184,19 +1184,19 @@ var L = ii(), ke, On, Vn = (On = class {
1184
1184
  const n = new AbortController(), s = (h) => {
1185
1185
  Object.defineProperty(h, "signal", {
1186
1186
  enumerable: !0,
1187
- get: () => (g(this, qe, !0), n.signal)
1187
+ get: () => (b(this, qe, !0), n.signal)
1188
1188
  });
1189
1189
  }, a = () => {
1190
- const h = Ln(this.options, r), p = {
1190
+ const h = $n(this.options, r), y = {
1191
1191
  client: o(this, je),
1192
1192
  queryKey: this.queryKey,
1193
1193
  meta: this.meta
1194
1194
  };
1195
- return s(p), g(this, qe, !1), this.options.persister ? this.options.persister(
1195
+ return s(y), b(this, qe, !1), this.options.persister ? this.options.persister(
1196
1196
  h,
1197
- p,
1197
+ y,
1198
1198
  this
1199
- ) : h(p);
1199
+ ) : h(y);
1200
1200
  }, u = {
1201
1201
  fetchOptions: r,
1202
1202
  options: this.options,
@@ -1208,29 +1208,29 @@ var L = ii(), ke, On, Vn = (On = class {
1208
1208
  s(u), (c = this.options.behavior) == null || c.onFetch(
1209
1209
  u,
1210
1210
  this
1211
- ), g(this, Je, this.state), (this.state.fetchStatus === "idle" || this.state.fetchMeta !== ((d = u.fetchOptions) == null ? void 0 : d.meta)) && P(this, re, le).call(this, { type: "fetch", meta: (f = u.fetchOptions) == null ? void 0 : f.meta });
1211
+ ), b(this, Xe, this.state), (this.state.fetchStatus === "idle" || this.state.fetchMeta !== ((d = u.fetchOptions) == null ? void 0 : d.meta)) && P(this, re, le).call(this, { type: "fetch", meta: (f = u.fetchOptions) == null ? void 0 : f.meta });
1212
1212
  const l = (h) => {
1213
- var p, m, E, b;
1213
+ var y, m, R, g;
1214
1214
  Jt(h) && h.silent || P(this, re, le).call(this, {
1215
1215
  type: "error",
1216
1216
  error: h
1217
- }), Jt(h) || ((m = (p = o(this, ee).config).onError) == null || m.call(
1218
- p,
1217
+ }), Jt(h) || ((m = (y = o(this, ee).config).onError) == null || m.call(
1218
+ y,
1219
1219
  h,
1220
1220
  this
1221
- ), (b = (E = o(this, ee).config).onSettled) == null || b.call(
1222
- E,
1221
+ ), (g = (R = o(this, ee).config).onSettled) == null || g.call(
1222
+ R,
1223
1223
  this.state.data,
1224
1224
  h,
1225
1225
  this
1226
1226
  )), this.scheduleGc();
1227
1227
  };
1228
- return g(this, V, Kn({
1228
+ return b(this, V, zn({
1229
1229
  initialPromise: r == null ? void 0 : r.initialPromise,
1230
1230
  fn: u.fetchFn,
1231
1231
  abort: n.abort.bind(n),
1232
1232
  onSuccess: (h) => {
1233
- var p, m, E, b;
1233
+ var y, m, R, g;
1234
1234
  if (h === void 0) {
1235
1235
  process.env.NODE_ENV !== "production" && console.error(
1236
1236
  `Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`
@@ -1239,20 +1239,20 @@ var L = ii(), ke, On, Vn = (On = class {
1239
1239
  }
1240
1240
  try {
1241
1241
  this.setData(h);
1242
- } catch (R) {
1243
- l(R);
1242
+ } catch (w) {
1243
+ l(w);
1244
1244
  return;
1245
1245
  }
1246
- (m = (p = o(this, ee).config).onSuccess) == null || m.call(p, h, this), (b = (E = o(this, ee).config).onSettled) == null || b.call(
1247
- E,
1246
+ (m = (y = o(this, ee).config).onSuccess) == null || m.call(y, h, this), (g = (R = o(this, ee).config).onSettled) == null || g.call(
1247
+ R,
1248
1248
  h,
1249
1249
  this.state.error,
1250
1250
  this
1251
1251
  ), this.scheduleGc();
1252
1252
  },
1253
1253
  onError: l,
1254
- onFail: (h, p) => {
1255
- P(this, re, le).call(this, { type: "failed", failureCount: h, error: p });
1254
+ onFail: (h, y) => {
1255
+ P(this, re, le).call(this, { type: "failed", failureCount: h, error: y });
1256
1256
  },
1257
1257
  onPause: () => {
1258
1258
  P(this, re, le).call(this, { type: "pause" });
@@ -1266,7 +1266,7 @@ var L = ii(), ke, On, Vn = (On = class {
1266
1266
  canRun: () => !0
1267
1267
  })), o(this, V).start();
1268
1268
  }
1269
- }, Ye = new WeakMap(), Je = new WeakMap(), ee = new WeakMap(), je = new WeakMap(), V = new WeakMap(), Ot = new WeakMap(), qe = new WeakMap(), re = new WeakSet(), le = function(e) {
1269
+ }, Je = new WeakMap(), Xe = new WeakMap(), ee = new WeakMap(), je = new WeakMap(), V = new WeakMap(), Ot = new WeakMap(), qe = new WeakMap(), re = new WeakSet(), le = function(e) {
1270
1270
  const r = (n) => {
1271
1271
  switch (e.type) {
1272
1272
  case "failed":
@@ -1288,7 +1288,7 @@ var L = ii(), ke, On, Vn = (On = class {
1288
1288
  case "fetch":
1289
1289
  return {
1290
1290
  ...n,
1291
- ...zn(n.data, this.options),
1291
+ ...Hn(n.data, this.options),
1292
1292
  fetchMeta: e.meta ?? null
1293
1293
  };
1294
1294
  case "success":
@@ -1308,7 +1308,7 @@ var L = ii(), ke, On, Vn = (On = class {
1308
1308
  };
1309
1309
  case "error":
1310
1310
  const s = e.error;
1311
- return Jt(s) && s.revert && o(this, Je) ? { ...o(this, Je), fetchStatus: "idle" } : {
1311
+ return Jt(s) && s.revert && o(this, Xe) ? { ...o(this, Xe), fetchStatus: "idle" } : {
1312
1312
  ...n,
1313
1313
  error: s,
1314
1314
  errorUpdateCount: n.errorUpdateCount + 1,
@@ -1335,19 +1335,19 @@ var L = ii(), ke, On, Vn = (On = class {
1335
1335
  n.onQueryUpdate();
1336
1336
  }), o(this, ee).notify({ query: this, type: "updated", action: e });
1337
1337
  });
1338
- }, Pn);
1339
- function zn(t, e) {
1338
+ }, Cn);
1339
+ function Hn(t, e) {
1340
1340
  return {
1341
1341
  fetchFailureCount: 0,
1342
1342
  fetchFailureReason: null,
1343
- fetchStatus: Qn(e.networkMode) ? "fetching" : "paused",
1343
+ fetchStatus: Kn(e.networkMode) ? "fetching" : "paused",
1344
1344
  ...t === void 0 && {
1345
1345
  error: null,
1346
1346
  status: "pending"
1347
1347
  }
1348
1348
  };
1349
1349
  }
1350
- function ai(t) {
1350
+ function ci(t) {
1351
1351
  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;
1352
1352
  return {
1353
1353
  data: e,
@@ -1364,16 +1364,16 @@ function ai(t) {
1364
1364
  fetchStatus: "idle"
1365
1365
  };
1366
1366
  }
1367
- var oe, Sn, ui = (Sn = class extends at {
1367
+ var oe, Tn, li = (Tn = class extends ut {
1368
1368
  constructor(e = {}) {
1369
1369
  super();
1370
- w(this, oe);
1371
- this.config = e, g(this, oe, /* @__PURE__ */ new Map());
1370
+ E(this, oe);
1371
+ this.config = e, b(this, oe, /* @__PURE__ */ new Map());
1372
1372
  }
1373
1373
  build(e, r, n) {
1374
1374
  const s = r.queryKey, a = r.queryHash ?? Pr(s, r);
1375
1375
  let u = this.get(a);
1376
- return u || (u = new oi({
1376
+ return u || (u = new ui({
1377
1377
  client: e,
1378
1378
  queryKey: s,
1379
1379
  queryHash: a,
@@ -1436,14 +1436,14 @@ var oe, Sn, ui = (Sn = class extends at {
1436
1436
  });
1437
1437
  });
1438
1438
  }
1439
- }, oe = new WeakMap(), Sn), ae, W, Me, ue, ge, Cn, ci = (Cn = class extends Vn {
1439
+ }, oe = new WeakMap(), Tn), ae, H, Me, ue, ge, xn, fi = (xn = class extends Wn {
1440
1440
  constructor(e) {
1441
1441
  super();
1442
- w(this, ue);
1443
- w(this, ae);
1444
- w(this, W);
1445
- w(this, Me);
1446
- this.mutationId = e.mutationId, g(this, W, e.mutationCache), g(this, ae, []), this.state = e.state || Hn(), this.setOptions(e.options), this.scheduleGc();
1442
+ E(this, ue);
1443
+ E(this, ae);
1444
+ E(this, H);
1445
+ E(this, Me);
1446
+ this.mutationId = e.mutationId, b(this, H, e.mutationCache), b(this, ae, []), this.state = e.state || Bn(), this.setOptions(e.options), this.scheduleGc();
1447
1447
  }
1448
1448
  setOptions(e) {
1449
1449
  this.options = e, this.updateGcTime(this.options.gcTime);
@@ -1452,21 +1452,21 @@ var oe, Sn, ui = (Sn = class extends at {
1452
1452
  return this.options.meta;
1453
1453
  }
1454
1454
  addObserver(e) {
1455
- o(this, ae).includes(e) || (o(this, ae).push(e), this.clearGcTimeout(), o(this, W).notify({
1455
+ o(this, ae).includes(e) || (o(this, ae).push(e), this.clearGcTimeout(), o(this, H).notify({
1456
1456
  type: "observerAdded",
1457
1457
  mutation: this,
1458
1458
  observer: e
1459
1459
  }));
1460
1460
  }
1461
1461
  removeObserver(e) {
1462
- g(this, ae, o(this, ae).filter((r) => r !== e)), this.scheduleGc(), o(this, W).notify({
1462
+ b(this, ae, o(this, ae).filter((r) => r !== e)), this.scheduleGc(), o(this, H).notify({
1463
1463
  type: "observerRemoved",
1464
1464
  mutation: this,
1465
1465
  observer: e
1466
1466
  });
1467
1467
  }
1468
1468
  optionalRemove() {
1469
- o(this, ae).length || (this.state.status === "pending" ? this.scheduleGc() : o(this, W).remove(this));
1469
+ o(this, ae).length || (this.state.status === "pending" ? this.scheduleGc() : o(this, H).remove(this));
1470
1470
  }
1471
1471
  continue() {
1472
1472
  var e;
@@ -1474,8 +1474,8 @@ var oe, Sn, ui = (Sn = class extends at {
1474
1474
  this.execute(this.state.variables);
1475
1475
  }
1476
1476
  async execute(e) {
1477
- var s, a, u, l, c, d, f, h, p, m, E, b, R, A, C, j, Q, z, X, K;
1478
- g(this, Me, Kn({
1477
+ var s, a, u, l, c, d, f, h, y, m, R, g, w, A, S, j, Q, z, X, K;
1478
+ b(this, Me, zn({
1479
1479
  fn: () => this.options.mutationFn ? this.options.mutationFn(e) : Promise.reject(new Error("No mutationFn found")),
1480
1480
  onFail: (q, k) => {
1481
1481
  P(this, ue, ge).call(this, { type: "failed", failureCount: q, error: k });
@@ -1489,12 +1489,12 @@ var oe, Sn, ui = (Sn = class extends at {
1489
1489
  retry: this.options.retry ?? 0,
1490
1490
  retryDelay: this.options.retryDelay,
1491
1491
  networkMode: this.options.networkMode,
1492
- canRun: () => o(this, W).canRun(this)
1492
+ canRun: () => o(this, H).canRun(this)
1493
1493
  }));
1494
1494
  const r = this.state.status === "pending", n = !o(this, Me).canStart();
1495
1495
  try {
1496
1496
  if (!r) {
1497
- P(this, ue, ge).call(this, { type: "pending", variables: e, isPaused: n }), await ((a = (s = o(this, W).config).onMutate) == null ? void 0 : a.call(
1497
+ P(this, ue, ge).call(this, { type: "pending", variables: e, isPaused: n }), await ((a = (s = o(this, H).config).onMutate) == null ? void 0 : a.call(
1498
1498
  s,
1499
1499
  e,
1500
1500
  this
@@ -1508,34 +1508,34 @@ var oe, Sn, ui = (Sn = class extends at {
1508
1508
  });
1509
1509
  }
1510
1510
  const q = await o(this, Me).start();
1511
- return await ((d = (c = o(this, W).config).onSuccess) == null ? void 0 : d.call(
1511
+ return await ((d = (c = o(this, H).config).onSuccess) == null ? void 0 : d.call(
1512
1512
  c,
1513
1513
  q,
1514
1514
  e,
1515
1515
  this.state.context,
1516
1516
  this
1517
- )), await ((h = (f = this.options).onSuccess) == null ? void 0 : h.call(f, q, e, this.state.context)), await ((m = (p = o(this, W).config).onSettled) == null ? void 0 : m.call(
1518
- p,
1517
+ )), await ((h = (f = this.options).onSuccess) == null ? void 0 : h.call(f, q, e, this.state.context)), await ((m = (y = o(this, H).config).onSettled) == null ? void 0 : m.call(
1518
+ y,
1519
1519
  q,
1520
1520
  null,
1521
1521
  this.state.variables,
1522
1522
  this.state.context,
1523
1523
  this
1524
- )), await ((b = (E = this.options).onSettled) == null ? void 0 : b.call(E, q, null, e, this.state.context)), P(this, ue, ge).call(this, { type: "success", data: q }), q;
1524
+ )), await ((g = (R = this.options).onSettled) == null ? void 0 : g.call(R, q, null, e, this.state.context)), P(this, ue, ge).call(this, { type: "success", data: q }), q;
1525
1525
  } catch (q) {
1526
1526
  try {
1527
- throw await ((A = (R = o(this, W).config).onError) == null ? void 0 : A.call(
1528
- R,
1527
+ throw await ((A = (w = o(this, H).config).onError) == null ? void 0 : A.call(
1528
+ w,
1529
1529
  q,
1530
1530
  e,
1531
1531
  this.state.context,
1532
1532
  this
1533
- )), await ((j = (C = this.options).onError) == null ? void 0 : j.call(
1534
- C,
1533
+ )), await ((j = (S = this.options).onError) == null ? void 0 : j.call(
1534
+ S,
1535
1535
  q,
1536
1536
  e,
1537
1537
  this.state.context
1538
- )), await ((z = (Q = o(this, W).config).onSettled) == null ? void 0 : z.call(
1538
+ )), await ((z = (Q = o(this, H).config).onSettled) == null ? void 0 : z.call(
1539
1539
  Q,
1540
1540
  void 0,
1541
1541
  q,
@@ -1553,10 +1553,10 @@ var oe, Sn, ui = (Sn = class extends at {
1553
1553
  P(this, ue, ge).call(this, { type: "error", error: q });
1554
1554
  }
1555
1555
  } finally {
1556
- o(this, W).runNext(this);
1556
+ o(this, H).runNext(this);
1557
1557
  }
1558
1558
  }
1559
- }, ae = new WeakMap(), W = new WeakMap(), Me = new WeakMap(), ue = new WeakSet(), ge = function(e) {
1559
+ }, ae = new WeakMap(), H = new WeakMap(), Me = new WeakMap(), ue = new WeakSet(), ge = function(e) {
1560
1560
  const r = (n) => {
1561
1561
  switch (e.type) {
1562
1562
  case "failed":
@@ -1613,14 +1613,14 @@ var oe, Sn, ui = (Sn = class extends at {
1613
1613
  this.state = r(this.state), L.batch(() => {
1614
1614
  o(this, ae).forEach((n) => {
1615
1615
  n.onMutationUpdate(e);
1616
- }), o(this, W).notify({
1616
+ }), o(this, H).notify({
1617
1617
  mutation: this,
1618
1618
  type: "updated",
1619
1619
  action: e
1620
1620
  });
1621
1621
  });
1622
- }, Cn);
1623
- function Hn() {
1622
+ }, xn);
1623
+ function Bn() {
1624
1624
  return {
1625
1625
  context: void 0,
1626
1626
  data: void 0,
@@ -1633,16 +1633,16 @@ function Hn() {
1633
1633
  submittedAt: 0
1634
1634
  };
1635
1635
  }
1636
- var fe, ne, Pt, Tn, li = (Tn = class extends at {
1636
+ var fe, ne, Pt, Fn, hi = (Fn = class extends ut {
1637
1637
  constructor(e = {}) {
1638
1638
  super();
1639
- w(this, fe);
1640
- w(this, ne);
1641
- w(this, Pt);
1642
- this.config = e, g(this, fe, /* @__PURE__ */ new Set()), g(this, ne, /* @__PURE__ */ new Map()), g(this, Pt, 0);
1639
+ E(this, fe);
1640
+ E(this, ne);
1641
+ E(this, Pt);
1642
+ this.config = e, b(this, fe, /* @__PURE__ */ new Set()), b(this, ne, /* @__PURE__ */ new Map()), b(this, Pt, 0);
1643
1643
  }
1644
1644
  build(e, r, n) {
1645
- const s = new ci({
1645
+ const s = new fi({
1646
1646
  mutationCache: this,
1647
1647
  mutationId: ++_t(this, Pt)._,
1648
1648
  options: e.defaultMutationOptions(r),
@@ -1726,7 +1726,7 @@ var fe, ne, Pt, Tn, li = (Tn = class extends at {
1726
1726
  )
1727
1727
  );
1728
1728
  }
1729
- }, fe = new WeakMap(), ne = new WeakMap(), Pt = new WeakMap(), Tn);
1729
+ }, fe = new WeakMap(), ne = new WeakMap(), Pt = new WeakMap(), Fn);
1730
1730
  function It(t) {
1731
1731
  var e;
1732
1732
  return (e = t.options.scope) == null ? void 0 : e.id;
@@ -1734,20 +1734,20 @@ function It(t) {
1734
1734
  function on(t) {
1735
1735
  return {
1736
1736
  onFetch: (e, r) => {
1737
- var f, h, p, m, E;
1738
- const n = e.options, s = (p = (h = (f = e.fetchOptions) == null ? void 0 : f.meta) == null ? void 0 : h.fetchMore) == null ? void 0 : p.direction, a = ((m = e.state.data) == null ? void 0 : m.pages) || [], u = ((E = e.state.data) == null ? void 0 : E.pageParams) || [];
1737
+ var f, h, y, m, R;
1738
+ const n = e.options, s = (y = (h = (f = e.fetchOptions) == null ? void 0 : f.meta) == null ? void 0 : h.fetchMore) == null ? void 0 : y.direction, a = ((m = e.state.data) == null ? void 0 : m.pages) || [], u = ((R = e.state.data) == null ? void 0 : R.pageParams) || [];
1739
1739
  let l = { pages: [], pageParams: [] }, c = 0;
1740
1740
  const d = async () => {
1741
- let b = !1;
1742
- const R = (j) => {
1741
+ let g = !1;
1742
+ const w = (j) => {
1743
1743
  Object.defineProperty(j, "signal", {
1744
1744
  enumerable: !0,
1745
- get: () => (e.signal.aborted ? b = !0 : e.signal.addEventListener("abort", () => {
1746
- b = !0;
1745
+ get: () => (e.signal.aborted ? g = !0 : e.signal.addEventListener("abort", () => {
1746
+ g = !0;
1747
1747
  }), e.signal)
1748
1748
  });
1749
- }, A = Ln(e.options, e.fetchOptions), C = async (j, Q, z) => {
1750
- if (b)
1749
+ }, A = $n(e.options, e.fetchOptions), S = async (j, Q, z) => {
1750
+ if (g)
1751
1751
  return Promise.reject();
1752
1752
  if (Q == null && j.pages.length)
1753
1753
  return Promise.resolve(j);
@@ -1758,36 +1758,36 @@ function on(t) {
1758
1758
  direction: z ? "backward" : "forward",
1759
1759
  meta: e.options.meta
1760
1760
  };
1761
- R(X);
1761
+ w(X);
1762
1762
  const K = await A(
1763
1763
  X
1764
- ), { maxPages: q } = e.options, k = z ? ti : ei;
1764
+ ), { maxPages: q } = e.options, k = z ? ni : ri;
1765
1765
  return {
1766
1766
  pages: k(j.pages, K, q),
1767
1767
  pageParams: k(j.pageParams, Q, q)
1768
1768
  };
1769
1769
  };
1770
1770
  if (s && a.length) {
1771
- const j = s === "backward", Q = j ? fi : an, z = {
1771
+ const j = s === "backward", Q = j ? di : an, z = {
1772
1772
  pages: a,
1773
1773
  pageParams: u
1774
1774
  }, X = Q(n, z);
1775
- l = await C(z, X, j);
1775
+ l = await S(z, X, j);
1776
1776
  } else {
1777
1777
  const j = t ?? a.length;
1778
1778
  do {
1779
1779
  const Q = c === 0 ? u[0] ?? n.initialPageParam : an(n, l);
1780
1780
  if (c > 0 && Q == null)
1781
1781
  break;
1782
- l = await C(l, Q), c++;
1782
+ l = await S(l, Q), c++;
1783
1783
  } while (c < j);
1784
1784
  }
1785
1785
  return l;
1786
1786
  };
1787
1787
  e.options.persister ? e.fetchFn = () => {
1788
- var b, R;
1789
- return (R = (b = e.options).persister) == null ? void 0 : R.call(
1790
- b,
1788
+ var g, w;
1789
+ return (w = (g = e.options).persister) == null ? void 0 : w.call(
1790
+ g,
1791
1791
  d,
1792
1792
  {
1793
1793
  client: e.client,
@@ -1810,32 +1810,32 @@ function an(t, { pages: e, pageParams: r }) {
1810
1810
  r
1811
1811
  ) : void 0;
1812
1812
  }
1813
- function fi(t, { pages: e, pageParams: r }) {
1813
+ function di(t, { pages: e, pageParams: r }) {
1814
1814
  var n;
1815
1815
  return e.length > 0 ? (n = t.getPreviousPageParam) == null ? void 0 : n.call(t, e[0], e, r[0], r) : void 0;
1816
1816
  }
1817
- var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
1817
+ var M, we, Ee, Ze, et, Re, tt, rt, An, yi = (An = class {
1818
1818
  constructor(t = {}) {
1819
- w(this, M);
1820
- w(this, we);
1821
- w(this, Ee);
1822
- w(this, Xe);
1823
- w(this, Ze);
1824
- w(this, Re);
1825
- w(this, et);
1826
- w(this, tt);
1827
- g(this, M, t.queryCache || new ui()), g(this, we, t.mutationCache || new li()), g(this, Ee, t.defaultOptions || {}), g(this, Xe, /* @__PURE__ */ new Map()), g(this, Ze, /* @__PURE__ */ new Map()), g(this, Re, 0);
1819
+ E(this, M);
1820
+ E(this, we);
1821
+ E(this, Ee);
1822
+ E(this, Ze);
1823
+ E(this, et);
1824
+ E(this, Re);
1825
+ E(this, tt);
1826
+ E(this, rt);
1827
+ b(this, M, t.queryCache || new li()), b(this, we, t.mutationCache || new hi()), b(this, Ee, t.defaultOptions || {}), b(this, Ze, /* @__PURE__ */ new Map()), b(this, et, /* @__PURE__ */ new Map()), b(this, Re, 0);
1828
1828
  }
1829
1829
  mount() {
1830
- _t(this, Re)._++, o(this, Re) === 1 && (g(this, et, Sr.subscribe(async (t) => {
1830
+ _t(this, Re)._++, o(this, Re) === 1 && (b(this, tt, Sr.subscribe(async (t) => {
1831
1831
  t && (await this.resumePausedMutations(), o(this, M).onFocus());
1832
- })), g(this, tt, Nt.subscribe(async (t) => {
1832
+ })), b(this, rt, Nt.subscribe(async (t) => {
1833
1833
  t && (await this.resumePausedMutations(), o(this, M).onOnline());
1834
1834
  })));
1835
1835
  }
1836
1836
  unmount() {
1837
1837
  var t, e;
1838
- _t(this, Re)._--, o(this, Re) === 0 && ((t = o(this, et)) == null || t.call(this), g(this, et, void 0), (e = o(this, tt)) == null || e.call(this), g(this, tt, void 0));
1838
+ _t(this, Re)._--, o(this, Re) === 0 && ((t = o(this, tt)) == null || t.call(this), b(this, tt, void 0), (e = o(this, rt)) == null || e.call(this), b(this, rt, void 0));
1839
1839
  }
1840
1840
  isFetching(t) {
1841
1841
  return o(this, M).findAll({ ...t, fetchStatus: "fetching" }).length;
@@ -1861,7 +1861,7 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
1861
1861
  setQueryData(t, e, r) {
1862
1862
  const n = this.defaultQueryOptions({ queryKey: t }), s = o(this, M).get(
1863
1863
  n.queryHash
1864
- ), a = s == null ? void 0 : s.state.data, u = Xs(e, a);
1864
+ ), a = s == null ? void 0 : s.state.data, u = ei(e, a);
1865
1865
  if (u !== void 0)
1866
1866
  return o(this, M).build(this, n).setData(u, { ...r, manual: !0 });
1867
1867
  }
@@ -1962,28 +1962,28 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
1962
1962
  return o(this, Ee);
1963
1963
  }
1964
1964
  setDefaultOptions(t) {
1965
- g(this, Ee, t);
1965
+ b(this, Ee, t);
1966
1966
  }
1967
1967
  setQueryDefaults(t, e) {
1968
- o(this, Xe).set($e(t), {
1968
+ o(this, Ze).set($e(t), {
1969
1969
  queryKey: t,
1970
1970
  defaultOptions: e
1971
1971
  });
1972
1972
  }
1973
1973
  getQueryDefaults(t) {
1974
- const e = [...o(this, Xe).values()], r = {};
1974
+ const e = [...o(this, Ze).values()], r = {};
1975
1975
  return e.forEach((n) => {
1976
1976
  bt(t, n.queryKey) && Object.assign(r, n.defaultOptions);
1977
1977
  }), r;
1978
1978
  }
1979
1979
  setMutationDefaults(t, e) {
1980
- o(this, Ze).set($e(t), {
1980
+ o(this, et).set($e(t), {
1981
1981
  mutationKey: t,
1982
1982
  defaultOptions: e
1983
1983
  });
1984
1984
  }
1985
1985
  getMutationDefaults(t) {
1986
- const e = [...o(this, Ze).values()], r = {};
1986
+ const e = [...o(this, et).values()], r = {};
1987
1987
  return e.forEach((n) => {
1988
1988
  bt(t, n.mutationKey) && Object.assign(r, n.defaultOptions);
1989
1989
  }), r;
@@ -2013,28 +2013,28 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2013
2013
  clear() {
2014
2014
  o(this, M).clear(), o(this, we).clear();
2015
2015
  }
2016
- }, M = new WeakMap(), we = new WeakMap(), Ee = new WeakMap(), Xe = new WeakMap(), Ze = new WeakMap(), Re = new WeakMap(), et = new WeakMap(), tt = new WeakMap(), xn), Y, T, St, B, Ue, rt, Oe, ce, Ct, nt, st, Ne, Le, Pe, it, _, pt, cr, lr, fr, hr, dr, yr, pr, Wn, Fn, di = (Fn = class extends at {
2016
+ }, M = new WeakMap(), we = new WeakMap(), Ee = new WeakMap(), Ze = new WeakMap(), et = new WeakMap(), Re = new WeakMap(), tt = new WeakMap(), rt = new WeakMap(), An), Y, T, St, B, Ue, nt, Oe, ce, Ct, st, it, Ne, Le, Pe, ot, _, mt, cr, lr, fr, hr, dr, yr, pr, Gn, Dn, pi = (Dn = class extends ut {
2017
2017
  constructor(e, r) {
2018
2018
  super();
2019
- w(this, _);
2020
- w(this, Y);
2021
- w(this, T);
2022
- w(this, St);
2023
- w(this, B);
2024
- w(this, Ue);
2025
- w(this, rt);
2026
- w(this, Oe);
2027
- w(this, ce);
2028
- w(this, Ct);
2029
- w(this, nt);
2019
+ E(this, _);
2020
+ E(this, Y);
2021
+ E(this, T);
2022
+ E(this, St);
2023
+ E(this, B);
2024
+ E(this, Ue);
2025
+ E(this, nt);
2026
+ E(this, Oe);
2027
+ E(this, ce);
2028
+ E(this, Ct);
2029
+ E(this, st);
2030
2030
  // This property keeps track of the last query with defined data.
2031
2031
  // It will be used to pass the previous data and query to the placeholder function between renders.
2032
- w(this, st);
2033
- w(this, Ne);
2034
- w(this, Le);
2035
- w(this, Pe);
2036
- w(this, it, /* @__PURE__ */ new Set());
2037
- this.options = r, g(this, Y, e), g(this, ce, null), g(this, Oe, ur()), this.options.experimental_prefetchInRender || o(this, Oe).reject(
2032
+ E(this, it);
2033
+ E(this, Ne);
2034
+ E(this, Le);
2035
+ E(this, Pe);
2036
+ E(this, ot, /* @__PURE__ */ new Set());
2037
+ this.options = r, b(this, Y, e), b(this, ce, null), b(this, Oe, ur()), this.options.experimental_prefetchInRender || o(this, Oe).reject(
2038
2038
  new Error("experimental_prefetchInRender feature flag is not enabled")
2039
2039
  ), this.bindMethods(), this.setOptions(r);
2040
2040
  }
@@ -2042,7 +2042,7 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2042
2042
  this.refetch = this.refetch.bind(this);
2043
2043
  }
2044
2044
  onSubscribe() {
2045
- this.listeners.size === 1 && (o(this, T).addObserver(this), un(o(this, T), this.options) ? P(this, _, pt).call(this) : this.updateResult(), P(this, _, hr).call(this));
2045
+ this.listeners.size === 1 && (o(this, T).addObserver(this), un(o(this, T), this.options) ? P(this, _, mt).call(this) : this.updateResult(), P(this, _, hr).call(this));
2046
2046
  }
2047
2047
  onUnsubscribe() {
2048
2048
  this.hasListeners() || this.destroy();
@@ -2081,13 +2081,13 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2081
2081
  s,
2082
2082
  this.options,
2083
2083
  n
2084
- ) && P(this, _, pt).call(this), this.updateResult(r), a && (o(this, T) !== s || se(this.options.enabled, o(this, T)) !== se(n.enabled, o(this, T)) || He(this.options.staleTime, o(this, T)) !== He(n.staleTime, o(this, T))) && P(this, _, cr).call(this);
2084
+ ) && P(this, _, mt).call(this), this.updateResult(r), a && (o(this, T) !== s || se(this.options.enabled, o(this, T)) !== se(n.enabled, o(this, T)) || He(this.options.staleTime, o(this, T)) !== He(n.staleTime, o(this, T))) && P(this, _, cr).call(this);
2085
2085
  const u = P(this, _, lr).call(this);
2086
2086
  a && (o(this, T) !== s || se(this.options.enabled, o(this, T)) !== se(n.enabled, o(this, T)) || u !== o(this, Pe)) && P(this, _, fr).call(this, u);
2087
2087
  }
2088
2088
  getOptimisticResult(e) {
2089
2089
  const r = o(this, Y).getQueryCache().build(o(this, Y), e), n = this.createResult(r, e);
2090
- return pi(this, n) && (g(this, B, n), g(this, rt, this.options), g(this, Ue, o(this, T).state)), n;
2090
+ return gi(this, n) && (b(this, B, n), b(this, nt, this.options), b(this, Ue, o(this, T).state)), n;
2091
2091
  }
2092
2092
  getCurrentResult() {
2093
2093
  return o(this, B);
@@ -2103,7 +2103,7 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2103
2103
  }), n;
2104
2104
  }
2105
2105
  trackProp(e) {
2106
- o(this, it).add(e);
2106
+ o(this, ot).add(e);
2107
2107
  }
2108
2108
  getCurrentQuery() {
2109
2109
  return o(this, T);
@@ -2118,76 +2118,76 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2118
2118
  return n.fetch().then(() => this.createResult(n, r));
2119
2119
  }
2120
2120
  fetch(e) {
2121
- return P(this, _, pt).call(this, {
2121
+ return P(this, _, mt).call(this, {
2122
2122
  ...e,
2123
2123
  cancelRefetch: e.cancelRefetch ?? !0
2124
2124
  }).then(() => (this.updateResult(), o(this, B)));
2125
2125
  }
2126
2126
  createResult(e, r) {
2127
2127
  var q;
2128
- const n = o(this, T), s = this.options, a = o(this, B), u = o(this, Ue), l = o(this, rt), d = e !== n ? e.state : o(this, St), { state: f } = e;
2129
- let h = { ...f }, p = !1, m;
2128
+ const n = o(this, T), s = this.options, a = o(this, B), u = o(this, Ue), l = o(this, nt), d = e !== n ? e.state : o(this, St), { state: f } = e;
2129
+ let h = { ...f }, y = !1, m;
2130
2130
  if (r._optimisticResults) {
2131
2131
  const k = this.hasListeners(), ye = !k && un(e, r), pe = k && cn(e, n, r, s);
2132
2132
  (ye || pe) && (h = {
2133
2133
  ...h,
2134
- ...zn(f.data, e.options)
2134
+ ...Hn(f.data, e.options)
2135
2135
  }), r._optimisticResults === "isRestoring" && (h.fetchStatus = "idle");
2136
2136
  }
2137
- let { error: E, errorUpdatedAt: b, status: R } = h;
2137
+ let { error: R, errorUpdatedAt: g, status: w } = h;
2138
2138
  if (r.select && h.data !== void 0)
2139
2139
  if (a && h.data === (u == null ? void 0 : u.data) && r.select === o(this, Ct))
2140
- m = o(this, nt);
2140
+ m = o(this, st);
2141
2141
  else
2142
2142
  try {
2143
- g(this, Ct, r.select), m = r.select(h.data), m = ar(a == null ? void 0 : a.data, m, r), g(this, nt, m), g(this, ce, null);
2143
+ b(this, Ct, r.select), m = r.select(h.data), m = ar(a == null ? void 0 : a.data, m, r), b(this, st, m), b(this, ce, null);
2144
2144
  } catch (k) {
2145
- g(this, ce, k);
2145
+ b(this, ce, k);
2146
2146
  }
2147
2147
  else
2148
2148
  m = h.data;
2149
- if (r.placeholderData !== void 0 && m === void 0 && R === "pending") {
2149
+ if (r.placeholderData !== void 0 && m === void 0 && w === "pending") {
2150
2150
  let k;
2151
2151
  if (a != null && a.isPlaceholderData && r.placeholderData === (l == null ? void 0 : l.placeholderData))
2152
2152
  k = a.data;
2153
2153
  else if (k = typeof r.placeholderData == "function" ? r.placeholderData(
2154
- (q = o(this, st)) == null ? void 0 : q.state.data,
2155
- o(this, st)
2154
+ (q = o(this, it)) == null ? void 0 : q.state.data,
2155
+ o(this, it)
2156
2156
  ) : r.placeholderData, r.select && k !== void 0)
2157
2157
  try {
2158
- k = r.select(k), g(this, ce, null);
2158
+ k = r.select(k), b(this, ce, null);
2159
2159
  } catch (ye) {
2160
- g(this, ce, ye);
2160
+ b(this, ce, ye);
2161
2161
  }
2162
- k !== void 0 && (R = "success", m = ar(
2162
+ k !== void 0 && (w = "success", m = ar(
2163
2163
  a == null ? void 0 : a.data,
2164
2164
  k,
2165
2165
  r
2166
- ), p = !0);
2166
+ ), y = !0);
2167
2167
  }
2168
- o(this, ce) && (E = o(this, ce), m = o(this, nt), b = Date.now(), R = "error");
2169
- const A = h.fetchStatus === "fetching", C = R === "pending", j = R === "error", Q = C && A, z = m !== void 0, K = {
2170
- status: R,
2168
+ o(this, ce) && (R = o(this, ce), m = o(this, st), g = Date.now(), w = "error");
2169
+ const A = h.fetchStatus === "fetching", S = w === "pending", j = w === "error", Q = S && A, z = m !== void 0, K = {
2170
+ status: w,
2171
2171
  fetchStatus: h.fetchStatus,
2172
- isPending: C,
2173
- isSuccess: R === "success",
2172
+ isPending: S,
2173
+ isSuccess: w === "success",
2174
2174
  isError: j,
2175
2175
  isInitialLoading: Q,
2176
2176
  isLoading: Q,
2177
2177
  data: m,
2178
2178
  dataUpdatedAt: h.dataUpdatedAt,
2179
- error: E,
2180
- errorUpdatedAt: b,
2179
+ error: R,
2180
+ errorUpdatedAt: g,
2181
2181
  failureCount: h.fetchFailureCount,
2182
2182
  failureReason: h.fetchFailureReason,
2183
2183
  errorUpdateCount: h.errorUpdateCount,
2184
2184
  isFetched: h.dataUpdateCount > 0 || h.errorUpdateCount > 0,
2185
2185
  isFetchedAfterMount: h.dataUpdateCount > d.dataUpdateCount || h.errorUpdateCount > d.errorUpdateCount,
2186
2186
  isFetching: A,
2187
- isRefetching: A && !C,
2187
+ isRefetching: A && !S,
2188
2188
  isLoadingError: j && !z,
2189
2189
  isPaused: h.fetchStatus === "paused",
2190
- isPlaceholderData: p,
2190
+ isPlaceholderData: y,
2191
2191
  isRefetchError: j && z,
2192
2192
  isStale: Cr(e, r),
2193
2193
  refetch: this.refetch,
@@ -2197,7 +2197,7 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2197
2197
  const k = (Fe) => {
2198
2198
  K.status === "error" ? Fe.reject(K.error) : K.data !== void 0 && Fe.resolve(K.data);
2199
2199
  }, ye = () => {
2200
- const Fe = g(this, Oe, K.promise = ur());
2200
+ const Fe = b(this, Oe, K.promise = ur());
2201
2201
  k(Fe);
2202
2202
  }, pe = o(this, Oe);
2203
2203
  switch (pe.status) {
@@ -2216,29 +2216,29 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2216
2216
  }
2217
2217
  updateResult(e) {
2218
2218
  const r = o(this, B), n = this.createResult(o(this, T), this.options);
2219
- if (g(this, Ue, o(this, T).state), g(this, rt, this.options), o(this, Ue).data !== void 0 && g(this, st, o(this, T)), Mt(n, r))
2219
+ if (b(this, Ue, o(this, T).state), b(this, nt, this.options), o(this, Ue).data !== void 0 && b(this, it, o(this, T)), Mt(n, r))
2220
2220
  return;
2221
- g(this, B, n);
2221
+ b(this, B, n);
2222
2222
  const s = {}, a = () => {
2223
2223
  if (!r)
2224
2224
  return !0;
2225
2225
  const { notifyOnChangeProps: u } = this.options, l = typeof u == "function" ? u() : u;
2226
- if (l === "all" || !l && !o(this, it).size)
2226
+ if (l === "all" || !l && !o(this, ot).size)
2227
2227
  return !0;
2228
2228
  const c = new Set(
2229
- l ?? o(this, it)
2229
+ l ?? o(this, ot)
2230
2230
  );
2231
2231
  return this.options.throwOnError && c.add("error"), Object.keys(o(this, B)).some((d) => {
2232
2232
  const f = d;
2233
2233
  return o(this, B)[f] !== r[f] && c.has(f);
2234
2234
  });
2235
2235
  };
2236
- (e == null ? void 0 : e.listeners) !== !1 && a() && (s.listeners = !0), P(this, _, Wn).call(this, { ...s, ...e });
2236
+ (e == null ? void 0 : e.listeners) !== !1 && a() && (s.listeners = !0), P(this, _, Gn).call(this, { ...s, ...e });
2237
2237
  }
2238
2238
  onQueryUpdate() {
2239
2239
  this.updateResult(), this.hasListeners() && P(this, _, hr).call(this);
2240
2240
  }
2241
- }, Y = new WeakMap(), T = new WeakMap(), St = new WeakMap(), B = new WeakMap(), Ue = new WeakMap(), rt = new WeakMap(), Oe = new WeakMap(), ce = new WeakMap(), Ct = new WeakMap(), nt = new WeakMap(), st = new WeakMap(), Ne = new WeakMap(), Le = new WeakMap(), Pe = new WeakMap(), it = new WeakMap(), _ = new WeakSet(), pt = function(e) {
2241
+ }, Y = new WeakMap(), T = new WeakMap(), St = new WeakMap(), B = new WeakMap(), Ue = new WeakMap(), nt = new WeakMap(), Oe = new WeakMap(), ce = new WeakMap(), Ct = new WeakMap(), st = new WeakMap(), it = new WeakMap(), Ne = new WeakMap(), Le = new WeakMap(), Pe = new WeakMap(), ot = new WeakMap(), _ = new WeakSet(), mt = function(e) {
2242
2242
  P(this, _, pr).call(this);
2243
2243
  let r = o(this, T).fetch(
2244
2244
  this.options,
@@ -2253,29 +2253,29 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2253
2253
  );
2254
2254
  if (Qe || o(this, B).isStale || !sr(e))
2255
2255
  return;
2256
- const n = Nn(o(this, B).dataUpdatedAt, e) + 1;
2257
- g(this, Ne, setTimeout(() => {
2256
+ const n = Qn(o(this, B).dataUpdatedAt, e) + 1;
2257
+ b(this, Ne, setTimeout(() => {
2258
2258
  o(this, B).isStale || this.updateResult();
2259
2259
  }, n));
2260
2260
  }, lr = function() {
2261
2261
  return (typeof this.options.refetchInterval == "function" ? this.options.refetchInterval(o(this, T)) : this.options.refetchInterval) ?? !1;
2262
2262
  }, fr = function(e) {
2263
- P(this, _, yr).call(this), g(this, Pe, e), !(Qe || se(this.options.enabled, o(this, T)) === !1 || !sr(o(this, Pe)) || o(this, Pe) === 0) && g(this, Le, setInterval(() => {
2264
- (this.options.refetchIntervalInBackground || Sr.isFocused()) && P(this, _, pt).call(this);
2263
+ P(this, _, yr).call(this), b(this, Pe, e), !(Qe || se(this.options.enabled, o(this, T)) === !1 || !sr(o(this, Pe)) || o(this, Pe) === 0) && b(this, Le, setInterval(() => {
2264
+ (this.options.refetchIntervalInBackground || Sr.isFocused()) && P(this, _, mt).call(this);
2265
2265
  }, o(this, Pe)));
2266
2266
  }, hr = function() {
2267
2267
  P(this, _, cr).call(this), P(this, _, fr).call(this, P(this, _, lr).call(this));
2268
2268
  }, dr = function() {
2269
- o(this, Ne) && (clearTimeout(o(this, Ne)), g(this, Ne, void 0));
2269
+ o(this, Ne) && (clearTimeout(o(this, Ne)), b(this, Ne, void 0));
2270
2270
  }, yr = function() {
2271
- o(this, Le) && (clearInterval(o(this, Le)), g(this, Le, void 0));
2271
+ o(this, Le) && (clearInterval(o(this, Le)), b(this, Le, void 0));
2272
2272
  }, pr = function() {
2273
2273
  const e = o(this, Y).getQueryCache().build(o(this, Y), this.options);
2274
2274
  if (e === o(this, T))
2275
2275
  return;
2276
2276
  const r = o(this, T);
2277
- g(this, T, e), g(this, St, e.state), this.hasListeners() && (r == null || r.removeObserver(this), e.addObserver(this));
2278
- }, Wn = function(e) {
2277
+ b(this, T, e), b(this, St, e.state), this.hasListeners() && (r == null || r.removeObserver(this), e.addObserver(this));
2278
+ }, Gn = function(e) {
2279
2279
  L.batch(() => {
2280
2280
  e.listeners && this.listeners.forEach((r) => {
2281
2281
  r(o(this, B));
@@ -2284,12 +2284,12 @@ var M, we, Ee, Xe, Ze, Re, et, tt, xn, hi = (xn = class {
2284
2284
  type: "observerResultsUpdated"
2285
2285
  });
2286
2286
  });
2287
- }, Fn);
2288
- function yi(t, e) {
2287
+ }, Dn);
2288
+ function mi(t, e) {
2289
2289
  return se(e.enabled, t) !== !1 && t.state.data === void 0 && !(t.state.status === "error" && e.retryOnMount === !1);
2290
2290
  }
2291
2291
  function un(t, e) {
2292
- return yi(t, e) || t.state.data !== void 0 && mr(t, e, e.refetchOnMount);
2292
+ return mi(t, e) || t.state.data !== void 0 && mr(t, e, e.refetchOnMount);
2293
2293
  }
2294
2294
  function mr(t, e, r) {
2295
2295
  if (se(e.enabled, t) !== !1) {
@@ -2304,18 +2304,18 @@ function cn(t, e, r, n) {
2304
2304
  function Cr(t, e) {
2305
2305
  return se(e.enabled, t) !== !1 && t.isStaleByTime(He(e.staleTime, t));
2306
2306
  }
2307
- function pi(t, e) {
2307
+ function gi(t, e) {
2308
2308
  return !Mt(t.getCurrentResult(), e);
2309
2309
  }
2310
- var Se, Ce, J, he, de, jt, gr, An, mi = (An = class extends at {
2310
+ var Se, Ce, J, he, de, jt, gr, _n, bi = (_n = class extends ut {
2311
2311
  constructor(e, r) {
2312
2312
  super();
2313
- w(this, de);
2314
- w(this, Se);
2315
- w(this, Ce);
2316
- w(this, J);
2317
- w(this, he);
2318
- g(this, Se, e), this.setOptions(r), this.bindMethods(), P(this, de, jt).call(this);
2313
+ E(this, de);
2314
+ E(this, Se);
2315
+ E(this, Ce);
2316
+ E(this, J);
2317
+ E(this, he);
2318
+ b(this, Se, e), this.setOptions(r), this.bindMethods(), P(this, de, jt).call(this);
2319
2319
  }
2320
2320
  bindMethods() {
2321
2321
  this.mutate = this.mutate.bind(this), this.reset = this.reset.bind(this);
@@ -2341,16 +2341,16 @@ var Se, Ce, J, he, de, jt, gr, An, mi = (An = class extends at {
2341
2341
  }
2342
2342
  reset() {
2343
2343
  var e;
2344
- (e = o(this, J)) == null || e.removeObserver(this), g(this, J, void 0), P(this, de, jt).call(this), P(this, de, gr).call(this);
2344
+ (e = o(this, J)) == null || e.removeObserver(this), b(this, J, void 0), P(this, de, jt).call(this), P(this, de, gr).call(this);
2345
2345
  }
2346
2346
  mutate(e, r) {
2347
2347
  var n;
2348
- return g(this, he, r), (n = o(this, J)) == null || n.removeObserver(this), g(this, J, o(this, Se).getMutationCache().build(o(this, Se), this.options)), o(this, J).addObserver(this), o(this, J).execute(e);
2348
+ return b(this, he, r), (n = o(this, J)) == null || n.removeObserver(this), b(this, J, o(this, Se).getMutationCache().build(o(this, Se), this.options)), o(this, J).addObserver(this), o(this, J).execute(e);
2349
2349
  }
2350
2350
  }, Se = new WeakMap(), Ce = new WeakMap(), J = new WeakMap(), he = new WeakMap(), de = new WeakSet(), jt = function() {
2351
2351
  var r;
2352
- const e = ((r = o(this, J)) == null ? void 0 : r.state) ?? Hn();
2353
- g(this, Ce, {
2352
+ const e = ((r = o(this, J)) == null ? void 0 : r.state) ?? Bn();
2353
+ b(this, Ce, {
2354
2354
  ...e,
2355
2355
  isPending: e.status === "pending",
2356
2356
  isSuccess: e.status === "success",
@@ -2376,21 +2376,21 @@ var Se, Ce, J, he, de, jt, gr, An, mi = (An = class extends at {
2376
2376
  f(o(this, Ce));
2377
2377
  });
2378
2378
  });
2379
- }, An), Bn = $.createContext(
2379
+ }, _n), Yn = $.createContext(
2380
2380
  void 0
2381
2381
  ), Tt = (t) => {
2382
- const e = $.useContext(Bn);
2382
+ const e = $.useContext(Yn);
2383
2383
  if (!e)
2384
2384
  throw new Error("No QueryClient set, use QueryClientProvider to set one");
2385
2385
  return e;
2386
- }, gi = ({
2386
+ }, vi = ({
2387
2387
  client: t,
2388
2388
  children: e
2389
2389
  }) => ($.useEffect(() => (t.mount(), () => {
2390
2390
  t.unmount();
2391
- }), [t]), /* @__PURE__ */ gt.jsx(Bn.Provider, { value: t, children: e })), Gn = $.createContext(!1), bi = () => $.useContext(Gn);
2392
- Gn.Provider;
2393
- function vi() {
2391
+ }), [t]), /* @__PURE__ */ We.jsx(Yn.Provider, { value: t, children: e })), Jn = $.createContext(!1), wi = () => $.useContext(Jn);
2392
+ Jn.Provider;
2393
+ function Ei() {
2394
2394
  let t = !1;
2395
2395
  return {
2396
2396
  clearReset: () => {
@@ -2402,43 +2402,43 @@ function vi() {
2402
2402
  isReset: () => t
2403
2403
  };
2404
2404
  }
2405
- var wi = $.createContext(vi()), Ei = () => $.useContext(wi);
2406
- function Yn(t, e) {
2405
+ var Ri = $.createContext(Ei()), Oi = () => $.useContext(Ri);
2406
+ function Xn(t, e) {
2407
2407
  return typeof t == "function" ? t(...e) : !!t;
2408
2408
  }
2409
2409
  function br() {
2410
2410
  }
2411
- var Ri = (t, e) => {
2411
+ var Pi = (t, e) => {
2412
2412
  (t.suspense || t.throwOnError || t.experimental_prefetchInRender) && (e.isReset() || (t.retryOnMount = !1));
2413
- }, Oi = (t) => {
2413
+ }, Si = (t) => {
2414
2414
  $.useEffect(() => {
2415
2415
  t.clearReset();
2416
2416
  }, [t]);
2417
- }, Pi = ({
2417
+ }, Ci = ({
2418
2418
  result: t,
2419
2419
  errorResetBoundary: e,
2420
2420
  throwOnError: r,
2421
2421
  query: n,
2422
2422
  suspense: s
2423
- }) => t.isError && !e.isReset() && !t.isFetching && n && (s && t.data === void 0 || Yn(r, [t.error, n])), Si = (t) => {
2423
+ }) => t.isError && !e.isReset() && !t.isFetching && n && (s && t.data === void 0 || Xn(r, [t.error, n])), Ti = (t) => {
2424
2424
  const e = t.staleTime;
2425
2425
  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)));
2426
- }, Ci = (t, e) => t.isLoading && t.isFetching && !e, Ti = (t, e) => (t == null ? void 0 : t.suspense) && e.isPending, ln = (t, e, r) => e.fetchOptimistic(t).catch(() => {
2426
+ }, xi = (t, e) => t.isLoading && t.isFetching && !e, Fi = (t, e) => (t == null ? void 0 : t.suspense) && e.isPending, ln = (t, e, r) => e.fetchOptimistic(t).catch(() => {
2427
2427
  r.clearReset();
2428
2428
  });
2429
- function xi(t, e, r) {
2430
- var h, p, m, E, b;
2429
+ function Ai(t, e, r) {
2430
+ var h, y, m, R, g;
2431
2431
  if (process.env.NODE_ENV !== "production" && (typeof t != "object" || Array.isArray(t)))
2432
2432
  throw new Error(
2433
2433
  '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'
2434
2434
  );
2435
- const n = Tt(), s = bi(), a = Ei(), u = n.defaultQueryOptions(t);
2436
- (p = (h = n.getDefaultOptions().queries) == null ? void 0 : h._experimental_beforeQuery) == null || p.call(
2435
+ const n = Tt(), s = wi(), a = Oi(), u = n.defaultQueryOptions(t);
2436
+ (y = (h = n.getDefaultOptions().queries) == null ? void 0 : h._experimental_beforeQuery) == null || y.call(
2437
2437
  h,
2438
2438
  u
2439
2439
  ), process.env.NODE_ENV !== "production" && (u.queryFn || console.error(
2440
2440
  `[${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`
2441
- )), u._optimisticResults = s ? "isRestoring" : "optimistic", Si(u), Ri(u, a), Oi(a);
2441
+ )), u._optimisticResults = s ? "isRestoring" : "optimistic", Ti(u), Pi(u, a), Si(a);
2442
2442
  const l = !n.getQueryCache().get(u.queryHash), [c] = $.useState(
2443
2443
  () => new e(
2444
2444
  n,
@@ -2447,8 +2447,8 @@ function xi(t, e, r) {
2447
2447
  ), d = c.getOptimisticResult(u), f = !s && t.subscribed !== !1;
2448
2448
  if ($.useSyncExternalStore(
2449
2449
  $.useCallback(
2450
- (R) => {
2451
- const A = f ? c.subscribe(L.batchCalls(R)) : br;
2450
+ (w) => {
2451
+ const A = f ? c.subscribe(L.batchCalls(w)) : br;
2452
2452
  return c.updateResult(), A;
2453
2453
  },
2454
2454
  [c, f]
@@ -2457,9 +2457,9 @@ function xi(t, e, r) {
2457
2457
  () => c.getCurrentResult()
2458
2458
  ), $.useEffect(() => {
2459
2459
  c.setOptions(u, { listeners: !1 });
2460
- }, [u, c]), Ti(u, d))
2460
+ }, [u, c]), Fi(u, d))
2461
2461
  throw ln(u, c, a);
2462
- if (Pi({
2462
+ if (Ci({
2463
2463
  result: d,
2464
2464
  errorResetBoundary: a,
2465
2465
  throwOnError: u.throwOnError,
@@ -2467,30 +2467,30 @@ function xi(t, e, r) {
2467
2467
  suspense: u.suspense
2468
2468
  }))
2469
2469
  throw d.error;
2470
- if ((E = (m = n.getDefaultOptions().queries) == null ? void 0 : m._experimental_afterQuery) == null || E.call(
2470
+ if ((R = (m = n.getDefaultOptions().queries) == null ? void 0 : m._experimental_afterQuery) == null || R.call(
2471
2471
  m,
2472
2472
  u,
2473
2473
  d
2474
- ), u.experimental_prefetchInRender && !Qe && Ci(d, s)) {
2475
- const R = l ? (
2474
+ ), u.experimental_prefetchInRender && !Qe && xi(d, s)) {
2475
+ const w = l ? (
2476
2476
  // Fetch immediately on render in order to ensure `.promise` is resolved even if the component is unmounted
2477
2477
  ln(u, c, a)
2478
2478
  ) : (
2479
2479
  // subscribe to the "cache promise" so that we can finalize the currentThenable once data comes in
2480
- (b = n.getQueryCache().get(u.queryHash)) == null ? void 0 : b.promise
2480
+ (g = n.getQueryCache().get(u.queryHash)) == null ? void 0 : g.promise
2481
2481
  );
2482
- R == null || R.catch(br).finally(() => {
2482
+ w == null || w.catch(br).finally(() => {
2483
2483
  c.updateResult();
2484
2484
  });
2485
2485
  }
2486
2486
  return u.notifyOnChangeProps ? d : c.trackResult(d);
2487
2487
  }
2488
- function Jn(t, e) {
2489
- return xi(t, di);
2488
+ function Zn(t, e) {
2489
+ return Ai(t, pi);
2490
2490
  }
2491
2491
  function Tr(t, e) {
2492
2492
  const r = Tt(), [n] = $.useState(
2493
- () => new mi(
2493
+ () => new bi(
2494
2494
  r,
2495
2495
  t
2496
2496
  )
@@ -2511,11 +2511,11 @@ function Tr(t, e) {
2511
2511
  },
2512
2512
  [n]
2513
2513
  );
2514
- if (s.error && Yn(n.options.throwOnError, [s.error]))
2514
+ if (s.error && Xn(n.options.throwOnError, [s.error]))
2515
2515
  throw s.error;
2516
2516
  return { ...s, mutate: a, mutateAsync: s.mutate };
2517
2517
  }
2518
- function ut(t) {
2518
+ function ct(t) {
2519
2519
  const e = {
2520
2520
  subscribe(r) {
2521
2521
  let n = null, s = !1, a = !1, u = !1;
@@ -2544,15 +2544,15 @@ function ut(t) {
2544
2544
  };
2545
2545
  },
2546
2546
  pipe(...r) {
2547
- return r.reduce(Fi, e);
2547
+ return r.reduce(Di, e);
2548
2548
  }
2549
2549
  };
2550
2550
  return e;
2551
2551
  }
2552
- function Fi(t, e) {
2552
+ function Di(t, e) {
2553
2553
  return e(t);
2554
2554
  }
2555
- function Ai(t) {
2555
+ function _i(t) {
2556
2556
  const e = new AbortController();
2557
2557
  return new Promise((n, s) => {
2558
2558
  let a = !1;
@@ -2575,7 +2575,7 @@ function Ai(t) {
2575
2575
  });
2576
2576
  });
2577
2577
  }
2578
- function Di(t) {
2578
+ function Ii(t) {
2579
2579
  return (e) => {
2580
2580
  let r = 0, n = null;
2581
2581
  const s = [];
@@ -2604,7 +2604,7 @@ function Di(t) {
2604
2604
  n = null, l.unsubscribe();
2605
2605
  }
2606
2606
  }
2607
- return ut((l) => (r++, s.push(l), a(), {
2607
+ return ct((l) => (r++, s.push(l), a(), {
2608
2608
  unsubscribe() {
2609
2609
  r--, u();
2610
2610
  const c = s.findIndex((d) => d === l);
@@ -2613,8 +2613,8 @@ function Di(t) {
2613
2613
  }));
2614
2614
  };
2615
2615
  }
2616
- function _i(t) {
2617
- return (e) => ut((r) => e.subscribe({
2616
+ function ki(t) {
2617
+ return (e) => ct((r) => e.subscribe({
2618
2618
  next(n) {
2619
2619
  var s;
2620
2620
  (s = t.next) == null || s.call(t, n), r.next(n);
@@ -2629,13 +2629,13 @@ function _i(t) {
2629
2629
  }
2630
2630
  }));
2631
2631
  }
2632
- function Ii(t) {
2632
+ function ji(t) {
2633
2633
  let e = t;
2634
2634
  const r = [], n = (u) => {
2635
2635
  e !== void 0 && u.next(e), r.push(u);
2636
2636
  }, s = (u) => {
2637
2637
  r.splice(r.indexOf(u), 1);
2638
- }, a = ut((u) => (n(u), () => {
2638
+ }, a = ct((u) => (n(u), () => {
2639
2639
  s(u);
2640
2640
  }));
2641
2641
  return a.next = (u) => {
@@ -2646,8 +2646,8 @@ function Ii(t) {
2646
2646
  }
2647
2647
  }, a.get = () => e, a;
2648
2648
  }
2649
- function ki(t) {
2650
- return ut((e) => {
2649
+ function qi(t) {
2650
+ return ct((e) => {
2651
2651
  function r(s = 0, a = t.op) {
2652
2652
  const u = t.links[s];
2653
2653
  if (!u)
@@ -2662,17 +2662,17 @@ function ki(t) {
2662
2662
  return r().subscribe(e);
2663
2663
  });
2664
2664
  }
2665
- const Xn = () => {
2665
+ const es = () => {
2666
2666
  }, fn = (t) => {
2667
2667
  Object.freeze && Object.freeze(t);
2668
2668
  };
2669
- function Zn(t, e, r) {
2669
+ function ts(t, e, r) {
2670
2670
  var n, s;
2671
2671
  const a = e.join(".");
2672
- return (n = r)[s = a] ?? (n[s] = new Proxy(Xn, {
2672
+ return (n = r)[s = a] ?? (n[s] = new Proxy(es, {
2673
2673
  get(u, l) {
2674
2674
  if (!(typeof l != "string" || l === "then"))
2675
- return Zn(t, [
2675
+ return ts(t, [
2676
2676
  ...e,
2677
2677
  l
2678
2678
  ], r);
@@ -2695,7 +2695,7 @@ function Zn(t, e, r) {
2695
2695
  }
2696
2696
  })), r[a];
2697
2697
  }
2698
- const ji = (t) => Zn(t, [], /* @__PURE__ */ Object.create(null)), qi = (t) => new Proxy(Xn, {
2698
+ const Mi = (t) => ts(t, [], /* @__PURE__ */ Object.create(null)), Ui = (t) => new Proxy(es, {
2699
2699
  get(e, r) {
2700
2700
  if (r !== "then")
2701
2701
  return t(r);
@@ -2704,7 +2704,7 @@ const ji = (t) => Zn(t, [], /* @__PURE__ */ Object.create(null)), qi = (t) => ne
2704
2704
  function vt(t) {
2705
2705
  return !!t && !Array.isArray(t) && typeof t == "object";
2706
2706
  }
2707
- function Mi(t, e) {
2707
+ function Ni(t, e) {
2708
2708
  if ("error" in t) {
2709
2709
  const n = e.deserialize(t.error);
2710
2710
  return {
@@ -2731,10 +2731,10 @@ class Xt extends Error {
2731
2731
  super("Unable to transform response from server");
2732
2732
  }
2733
2733
  }
2734
- function Ui(t, e) {
2734
+ function Li(t, e) {
2735
2735
  let r;
2736
2736
  try {
2737
- r = Mi(t, e);
2737
+ r = Ni(t, e);
2738
2738
  } catch {
2739
2739
  throw new Xt();
2740
2740
  }
@@ -2747,9 +2747,9 @@ function Ui(t, e) {
2747
2747
  var hn, dn;
2748
2748
  (hn = Symbol).dispose ?? (hn.dispose = Symbol());
2749
2749
  (dn = Symbol).asyncDispose ?? (dn.asyncDispose = Symbol());
2750
- var Dn, _n, In, kn, jn, qn;
2750
+ var In, kn, jn, qn, Mn, Un;
2751
2751
  typeof window > "u" || "Deno" in window || // eslint-disable-next-line @typescript-eslint/dot-notation
2752
- ((_n = (Dn = globalThis.process) == null ? void 0 : Dn.env) == null ? void 0 : _n.NODE_ENV) === "test" || (kn = (In = globalThis.process) == null ? void 0 : In.env) != null && kn.JEST_WORKER_ID || (qn = (jn = globalThis.process) == null ? void 0 : jn.env) != null && qn.VITEST_WORKER_ID;
2752
+ ((kn = (In = globalThis.process) == null ? void 0 : In.env) == null ? void 0 : kn.NODE_ENV) === "test" || (qn = (jn = globalThis.process) == null ? void 0 : jn.env) != null && qn.JEST_WORKER_ID || (Un = (Mn = globalThis.process) == null ? void 0 : Mn.env) != null && Un.VITEST_WORKER_ID;
2753
2753
  function kt(t, e, r) {
2754
2754
  return e in t ? Object.defineProperty(t, e, {
2755
2755
  value: r,
@@ -2758,29 +2758,29 @@ function kt(t, e, r) {
2758
2758
  writable: !0
2759
2759
  }) : t[e] = r, t;
2760
2760
  }
2761
- function Ni(t) {
2761
+ function Qi(t) {
2762
2762
  return t instanceof Te || /**
2763
2763
  * @deprecated
2764
2764
  * Delete in next major
2765
2765
  */
2766
2766
  t instanceof Error && t.name === "TRPCClientError";
2767
2767
  }
2768
- function Li(t) {
2768
+ function $i(t) {
2769
2769
  return vt(t) && vt(t.error) && typeof t.error.code == "number" && typeof t.error.message == "string";
2770
2770
  }
2771
- function Qi(t, e) {
2771
+ function Ki(t, e) {
2772
2772
  return typeof t == "string" ? t : vt(t) && typeof t.message == "string" ? t.message : e;
2773
2773
  }
2774
2774
  class Te extends Error {
2775
2775
  static from(e, r = {}) {
2776
2776
  const n = e;
2777
- return Ni(n) ? (r.meta && (n.meta = {
2777
+ return Qi(n) ? (r.meta && (n.meta = {
2778
2778
  ...n.meta,
2779
2779
  ...r.meta
2780
- }), n) : Li(n) ? new Te(n.error.message, {
2780
+ }), n) : $i(n) ? new Te(n.error.message, {
2781
2781
  ...r,
2782
2782
  result: n
2783
- }) : new Te(Qi(n, "Unknown error"), {
2783
+ }) : new Te(Ki(n, "Unknown error"), {
2784
2784
  ...r,
2785
2785
  cause: n
2786
2786
  });
@@ -2807,21 +2807,21 @@ function Zt(t, e, r) {
2807
2807
  writable: !0
2808
2808
  }) : t[e] = r, t;
2809
2809
  }
2810
- class $i {
2810
+ class Vi {
2811
2811
  $request(e) {
2812
- return ki({
2812
+ return qi({
2813
2813
  links: this.links,
2814
2814
  op: {
2815
2815
  ...e,
2816
2816
  context: e.context ?? {},
2817
2817
  id: ++this.requestId
2818
2818
  }
2819
- }).pipe(Di());
2819
+ }).pipe(Ii());
2820
2820
  }
2821
2821
  async requestAsPromise(e) {
2822
2822
  try {
2823
2823
  const r = this.$request(e);
2824
- return (await Ai(r)).result.data;
2824
+ return (await _i(r)).result.data;
2825
2825
  } catch (r) {
2826
2826
  throw Te.from(r);
2827
2827
  }
@@ -2890,26 +2890,26 @@ class $i {
2890
2890
  Zt(this, "links", void 0), Zt(this, "runtime", void 0), Zt(this, "requestId", void 0), this.requestId = 0, this.runtime = {}, this.links = e.links.map((r) => r(this.runtime));
2891
2891
  }
2892
2892
  }
2893
- const Ki = Symbol.for("trpc_untypedClient"), Vi = {
2893
+ const zi = Symbol.for("trpc_untypedClient"), Wi = {
2894
2894
  query: "query",
2895
2895
  mutate: "mutation",
2896
2896
  subscribe: "subscription"
2897
- }, zi = (t) => Vi[t];
2898
- function Hi(t) {
2899
- const e = ji(({ path: r, args: n }) => {
2897
+ }, Hi = (t) => Wi[t];
2898
+ function Bi(t) {
2899
+ const e = Mi(({ path: r, args: n }) => {
2900
2900
  const s = [
2901
2901
  ...r
2902
- ], a = zi(s.pop()), u = s.join(".");
2902
+ ], a = Hi(s.pop()), u = s.join(".");
2903
2903
  return t[a](u, ...n);
2904
2904
  });
2905
- return qi((r) => r === Ki ? t : e[r]);
2905
+ return Ui((r) => r === zi ? t : e[r]);
2906
2906
  }
2907
- function Wi(t) {
2908
- const e = new $i(t);
2909
- return Hi(e);
2907
+ function Gi(t) {
2908
+ const e = new Vi(t);
2909
+ return Bi(e);
2910
2910
  }
2911
2911
  const yn = (t) => typeof t == "function";
2912
- function Bi(t) {
2912
+ function Yi(t) {
2913
2913
  if (t)
2914
2914
  return t;
2915
2915
  if (typeof window < "u" && yn(window.fetch))
@@ -2933,20 +2933,20 @@ function mn(t) {
2933
2933
  ];
2934
2934
  let d = 0;
2935
2935
  for (; ; ) {
2936
- const p = l[d];
2937
- if (!p)
2936
+ const y = l[d];
2937
+ if (!y)
2938
2938
  break;
2939
2939
  const m = c[c.length - 1];
2940
- if (p.aborted) {
2941
- (f = p.reject) == null || f.call(p, new Error("Aborted")), d++;
2940
+ if (y.aborted) {
2941
+ (f = y.reject) == null || f.call(y, new Error("Aborted")), d++;
2942
2942
  continue;
2943
2943
  }
2944
- if (t.validate(m.concat(p).map((b) => b.key))) {
2945
- m.push(p), d++;
2944
+ if (t.validate(m.concat(y).map((g) => g.key))) {
2945
+ m.push(y), d++;
2946
2946
  continue;
2947
2947
  }
2948
2948
  if (m.length === 0) {
2949
- (h = p.reject) == null || h.call(p, new Error("Input is too big for a single dispatch")), d++;
2949
+ (h = y.reject) == null || h.call(y, new Error("Input is too big for a single dispatch")), d++;
2950
2950
  continue;
2951
2951
  }
2952
2952
  c.push([]);
@@ -2965,24 +2965,24 @@ function mn(t) {
2965
2965
  for (const h of c)
2966
2966
  h.batch = d;
2967
2967
  t.fetch(d.items.map((h) => h.key)).then(async (h) => {
2968
- var p;
2969
- await Promise.all(h.map(async (m, E) => {
2970
- var R, A;
2971
- const b = d.items[E];
2968
+ var y;
2969
+ await Promise.all(h.map(async (m, R) => {
2970
+ var w, A;
2971
+ const g = d.items[R];
2972
2972
  try {
2973
- const C = await Promise.resolve(m);
2974
- (R = b.resolve) == null || R.call(b, C);
2975
- } catch (C) {
2976
- (A = b.reject) == null || A.call(b, C);
2973
+ const S = await Promise.resolve(m);
2974
+ (w = g.resolve) == null || w.call(g, S);
2975
+ } catch (S) {
2976
+ (A = g.reject) == null || A.call(g, S);
2977
2977
  }
2978
- b.batch = null, b.reject = null, b.resolve = null;
2978
+ g.batch = null, g.reject = null, g.resolve = null;
2979
2979
  }));
2980
2980
  for (const m of d.items)
2981
- (p = m.reject) == null || p.call(m, new Error("Missing result")), m.batch = null;
2981
+ (y = m.reject) == null || y.call(m, new Error("Missing result")), m.batch = null;
2982
2982
  }).catch((h) => {
2983
- var p;
2983
+ var y;
2984
2984
  for (const m of d.items)
2985
- (p = m.reject) == null || p.call(m, h), m.batch = null;
2985
+ (y = m.reject) == null || y.call(m, h), m.batch = null;
2986
2986
  });
2987
2987
  }
2988
2988
  }
@@ -3002,7 +3002,7 @@ function mn(t) {
3002
3002
  load: u
3003
3003
  };
3004
3004
  }
3005
- function Gi(...t) {
3005
+ function Ji(...t) {
3006
3006
  const e = new AbortController(), r = t.length;
3007
3007
  let n = 0;
3008
3008
  const s = () => {
@@ -3014,7 +3014,7 @@ function Gi(...t) {
3014
3014
  });
3015
3015
  return e.signal;
3016
3016
  }
3017
- function Yi(t) {
3017
+ function Xi(t) {
3018
3018
  const e = t;
3019
3019
  return e ? "input" in e ? e : {
3020
3020
  input: e,
@@ -3030,15 +3030,15 @@ function Yi(t) {
3030
3030
  }
3031
3031
  };
3032
3032
  }
3033
- function Ji(t) {
3033
+ function Zi(t) {
3034
3034
  return {
3035
3035
  url: t.url.toString(),
3036
3036
  fetch: t.fetch,
3037
- transformer: Yi(t.transformer),
3037
+ transformer: Xi(t.transformer),
3038
3038
  methodOverride: t.methodOverride
3039
3039
  };
3040
3040
  }
3041
- function Xi(t) {
3041
+ function eo(t) {
3042
3042
  const e = {};
3043
3043
  for (let r = 0; r < t.length; r++) {
3044
3044
  const n = t[r];
@@ -3046,47 +3046,47 @@ function Xi(t) {
3046
3046
  }
3047
3047
  return e;
3048
3048
  }
3049
- const Zi = {
3049
+ const to = {
3050
3050
  query: "GET",
3051
3051
  mutation: "POST",
3052
3052
  subscription: "PATCH"
3053
3053
  };
3054
- function es(t) {
3055
- return "input" in t ? t.transformer.input.serialize(t.input) : Xi(t.inputs.map((e) => t.transformer.input.serialize(e)));
3054
+ function rs(t) {
3055
+ return "input" in t ? t.transformer.input.serialize(t.input) : eo(t.inputs.map((e) => t.transformer.input.serialize(e)));
3056
3056
  }
3057
- const ts = (t) => {
3057
+ const ns = (t) => {
3058
3058
  const e = t.url.split("?");
3059
3059
  let n = e[0].replace(/\/$/, "") + "/" + t.path;
3060
3060
  const s = [];
3061
3061
  if (e[1] && s.push(e[1]), "inputs" in t && s.push("batch=1"), t.type === "query" || t.type === "subscription") {
3062
- const a = es(t);
3062
+ const a = rs(t);
3063
3063
  a !== void 0 && t.methodOverride !== "POST" && s.push(`input=${encodeURIComponent(JSON.stringify(a))}`);
3064
3064
  }
3065
3065
  return s.length && (n += "?" + s.join("&")), n;
3066
- }, eo = (t) => {
3066
+ }, ro = (t) => {
3067
3067
  if (t.type === "query" && t.methodOverride !== "POST")
3068
3068
  return;
3069
- const e = es(t);
3069
+ const e = rs(t);
3070
3070
  return e !== void 0 ? JSON.stringify(e) : void 0;
3071
- }, to = (t) => io({
3071
+ }, no = (t) => ao({
3072
3072
  ...t,
3073
3073
  contentTypeHeader: "application/json",
3074
- getUrl: ts,
3075
- getBody: eo
3074
+ getUrl: ns,
3075
+ getBody: ro
3076
3076
  });
3077
- class ro extends Error {
3077
+ class so extends Error {
3078
3078
  constructor() {
3079
3079
  const e = "AbortError";
3080
3080
  super(e), this.name = e, this.message = e;
3081
3081
  }
3082
3082
  }
3083
- const no = (t) => {
3083
+ const io = (t) => {
3084
3084
  var e;
3085
3085
  if (t != null && t.aborted)
3086
- throw (e = t.throwIfAborted) == null || e.call(t), typeof DOMException < "u" ? new DOMException("AbortError", "AbortError") : new ro();
3086
+ throw (e = t.throwIfAborted) == null || e.call(t), typeof DOMException < "u" ? new DOMException("AbortError", "AbortError") : new so();
3087
3087
  };
3088
- async function so(t) {
3089
- no(t.signal);
3088
+ async function oo(t) {
3089
+ io(t.signal);
3090
3090
  const e = t.getUrl(t), r = t.getBody(t), { type: n } = t, s = await (async () => {
3091
3091
  const u = await t.headers();
3092
3092
  return Symbol.iterator in u ? Object.fromEntries(u) : u;
@@ -3099,15 +3099,15 @@ async function so(t) {
3099
3099
  } : void 0,
3100
3100
  ...s
3101
3101
  };
3102
- return Bi(t.fetch)(e, {
3103
- method: t.methodOverride ?? Zi[n],
3102
+ return Yi(t.fetch)(e, {
3103
+ method: t.methodOverride ?? to[n],
3104
3104
  signal: t.signal,
3105
3105
  body: r,
3106
3106
  headers: a
3107
3107
  });
3108
3108
  }
3109
- async function io(t) {
3110
- const e = {}, r = await so(t);
3109
+ async function ao(t) {
3110
+ const e = {}, r = await oo(t);
3111
3111
  e.response = r;
3112
3112
  const n = await r.json();
3113
3113
  return e.responseJSON = n, {
@@ -3115,15 +3115,15 @@ async function io(t) {
3115
3115
  meta: e
3116
3116
  };
3117
3117
  }
3118
- function oo(t) {
3119
- const e = Ji(t), r = t.maxURLLength ?? 1 / 0;
3118
+ function uo(t) {
3119
+ const e = Zi(t), r = t.maxURLLength ?? 1 / 0;
3120
3120
  return () => {
3121
3121
  const n = (l) => ({
3122
3122
  validate(c) {
3123
3123
  if (r === 1 / 0)
3124
3124
  return !0;
3125
- const d = c.map((p) => p.path).join(","), f = c.map((p) => p.input);
3126
- return ts({
3125
+ const d = c.map((y) => y.path).join(","), f = c.map((y) => y.input);
3126
+ return ns({
3127
3127
  ...e,
3128
3128
  type: l,
3129
3129
  path: d,
@@ -3132,7 +3132,7 @@ function oo(t) {
3132
3132
  }).length <= r;
3133
3133
  },
3134
3134
  async fetch(c) {
3135
- const d = c.map((b) => b.path).join(","), f = c.map((b) => b.input), h = Gi(...c.map((b) => b.signal)), p = await to({
3135
+ const d = c.map((g) => g.path).join(","), f = c.map((g) => g.input), h = Ji(...c.map((g) => g.signal)), y = await no({
3136
3136
  ...e,
3137
3137
  path: d,
3138
3138
  inputs: f,
@@ -3144,36 +3144,36 @@ function oo(t) {
3144
3144
  },
3145
3145
  signal: h
3146
3146
  });
3147
- return (Array.isArray(p.json) ? p.json : c.map(() => p.json)).map((b) => ({
3148
- meta: p.meta,
3149
- json: b
3147
+ return (Array.isArray(y.json) ? y.json : c.map(() => y.json)).map((g) => ({
3148
+ meta: y.meta,
3149
+ json: g
3150
3150
  }));
3151
3151
  }
3152
3152
  }), s = mn(n("query")), a = mn(n("mutation")), u = {
3153
3153
  query: s,
3154
3154
  mutation: a
3155
3155
  };
3156
- return ({ op: l }) => ut((c) => {
3156
+ return ({ op: l }) => ct((c) => {
3157
3157
  /* istanbul ignore if -- @preserve */
3158
3158
  if (l.type === "subscription")
3159
3159
  throw new Error("Subscriptions are unsupported by `httpLink` - use `httpSubscriptionLink` or `wsLink`");
3160
3160
  const f = u[l.type].load(l);
3161
3161
  let h;
3162
- return f.then((p) => {
3163
- h = p;
3164
- const m = Ui(p.json, e.transformer.output);
3162
+ return f.then((y) => {
3163
+ h = y;
3164
+ const m = Li(y.json, e.transformer.output);
3165
3165
  if (!m.ok) {
3166
3166
  c.error(Te.from(m.error, {
3167
- meta: p.meta
3167
+ meta: y.meta
3168
3168
  }));
3169
3169
  return;
3170
3170
  }
3171
3171
  c.next({
3172
- context: p.meta,
3172
+ context: y.meta,
3173
3173
  result: m.result
3174
3174
  }), c.complete();
3175
- }).catch((p) => {
3176
- c.error(Te.from(p, {
3175
+ }).catch((y) => {
3176
+ c.error(Te.from(y, {
3177
3177
  meta: h == null ? void 0 : h.meta
3178
3178
  }));
3179
3179
  }), () => {
@@ -3181,7 +3181,7 @@ function oo(t) {
3181
3181
  });
3182
3182
  };
3183
3183
  }
3184
- function ao(t) {
3184
+ function co(t) {
3185
3185
  return typeof FormData > "u" ? !1 : t instanceof FormData;
3186
3186
  }
3187
3187
  const er = {
@@ -3233,13 +3233,13 @@ const er = {
3233
3233
  }
3234
3234
  }
3235
3235
  };
3236
- function uo(t) {
3236
+ function lo(t) {
3237
3237
  const { direction: e, type: r, withContext: n, path: s, id: a, input: u } = t, l = [], c = [];
3238
3238
  if (t.colorMode === "none")
3239
3239
  l.push(e === "up" ? ">>" : "<<", r, `#${a}`, s);
3240
3240
  else if (t.colorMode === "ansi") {
3241
- const [d, f] = er.ansi.regular[r], [h, p] = er.ansi.bold[r];
3242
- l.push(e === "up" ? d : f, e === "up" ? ">>" : "<<", r, e === "up" ? h : p, `#${a}`, s, "\x1B[0m");
3241
+ const [d, f] = er.ansi.regular[r], [h, y] = er.ansi.bold[r];
3242
+ l.push(e === "up" ? d : f, e === "up" ? ">>" : "<<", r, e === "up" ? h : y, `#${a}`, s, "\x1B[0m");
3243
3243
  } else {
3244
3244
  const [d, f] = er.css[r], h = `
3245
3245
  background-color: #${e === "up" ? d : f};
@@ -3265,8 +3265,8 @@ function uo(t) {
3265
3265
  args: c
3266
3266
  };
3267
3267
  }
3268
- const co = ({ c: t = console, colorMode: e = "css", withContext: r }) => (n) => {
3269
- const s = n.input, a = ao(s) ? Object.fromEntries(s) : s, { parts: u, args: l } = uo({
3268
+ const fo = ({ c: t = console, colorMode: e = "css", withContext: r }) => (n) => {
3269
+ const s = n.input, a = co(s) ? Object.fromEntries(s) : s, { parts: u, args: l } = lo({
3270
3270
  ...n,
3271
3271
  colorMode: e,
3272
3272
  input: a,
@@ -3276,13 +3276,13 @@ const co = ({ c: t = console, colorMode: e = "css", withContext: r }) => (n) =>
3276
3276
  u.join(" ")
3277
3277
  ].concat(l));
3278
3278
  };
3279
- function lo(t = {}) {
3280
- const { enabled: e = () => !0 } = t, r = t.colorMode ?? (typeof window > "u" ? "ansi" : "css"), n = t.withContext ?? r === "css", { logger: s = co({
3279
+ function ho(t = {}) {
3280
+ const { enabled: e = () => !0 } = t, r = t.colorMode ?? (typeof window > "u" ? "ansi" : "css"), n = t.withContext ?? r === "css", { logger: s = fo({
3281
3281
  c: t.console,
3282
3282
  colorMode: r,
3283
3283
  withContext: n
3284
3284
  }) } = t;
3285
- return () => ({ op: a, next: u }) => ut((l) => {
3285
+ return () => ({ op: a, next: u }) => ct((l) => {
3286
3286
  e({
3287
3287
  ...a,
3288
3288
  direction: "up"
@@ -3304,7 +3304,7 @@ function lo(t = {}) {
3304
3304
  result: f
3305
3305
  });
3306
3306
  }
3307
- return u(a).pipe(_i({
3307
+ return u(a).pipe(ki({
3308
3308
  next(f) {
3309
3309
  d(f);
3310
3310
  },
@@ -3314,8 +3314,8 @@ function lo(t = {}) {
3314
3314
  })).subscribe(l);
3315
3315
  });
3316
3316
  }
3317
- const fo = (t, ...e) => typeof t == "function" ? t(...e) : t;
3318
- function ho() {
3317
+ const yo = (t, ...e) => typeof t == "function" ? t(...e) : t;
3318
+ function po() {
3319
3319
  let t, e;
3320
3320
  return {
3321
3321
  promise: new Promise((n, s) => {
@@ -3325,8 +3325,8 @@ function ho() {
3325
3325
  reject: e
3326
3326
  };
3327
3327
  }
3328
- async function yo(t) {
3329
- const e = await fo(t.url);
3328
+ async function mo(t) {
3329
+ const e = await yo(t.url);
3330
3330
  if (!t.connectionParams) return e;
3331
3331
  const n = `${e.includes("?") ? "&" : "?"}connectionParams=1`;
3332
3332
  return e + n;
@@ -3339,13 +3339,13 @@ function _e(t, e, r) {
3339
3339
  writable: !0
3340
3340
  }) : t[e] = r, t;
3341
3341
  }
3342
- function po(t) {
3343
- const { promise: e, resolve: r, reject: n } = ho();
3342
+ function go(t) {
3343
+ const { promise: e, resolve: r, reject: n } = po();
3344
3344
  return t.addEventListener("open", () => {
3345
3345
  t.removeEventListener("error", n), r();
3346
3346
  }), t.addEventListener("error", n), e;
3347
3347
  }
3348
- function mo(t, { intervalMs: e, pongTimeoutMs: r }) {
3348
+ function bo(t, { intervalMs: e, pongTimeoutMs: r }) {
3349
3349
  let n, s;
3350
3350
  function a() {
3351
3351
  n = setTimeout(() => {
@@ -3388,10 +3388,10 @@ class Lt {
3388
3388
  async open() {
3389
3389
  if (this.openPromise) return this.openPromise;
3390
3390
  this.id = ++Lt.connectCount;
3391
- const e = yo(this.urlOptions).then((r) => new this.WebSocketPonyfill(r));
3392
- this.openPromise = e.then(po), this.ws = await e, this.ws.addEventListener("message", function({ data: r }) {
3391
+ const e = mo(this.urlOptions).then((r) => new this.WebSocketPonyfill(r));
3392
+ this.openPromise = e.then(go), this.ws = await e, this.ws.addEventListener("message", function({ data: r }) {
3393
3393
  r === "PING" && this.send("PONG");
3394
- }), this.keepAliveOpts.enabled && mo(this.ws, this.keepAliveOpts), this.ws.addEventListener("close", () => {
3394
+ }), this.keepAliveOpts.enabled && bo(this.ws, this.keepAliveOpts), this.ws.addEventListener("close", () => {
3395
3395
  this.ws = null;
3396
3396
  });
3397
3397
  try {
@@ -3413,13 +3413,13 @@ class Lt {
3413
3413
  }
3414
3414
  }
3415
3415
  constructor(e) {
3416
- if (_e(this, "id", ++Lt.connectCount), _e(this, "WebSocketPonyfill", void 0), _e(this, "urlOptions", void 0), _e(this, "keepAliveOpts", void 0), _e(this, "wsObservable", Ii(null)), _e(this, "openPromise", null), this.WebSocketPonyfill = e.WebSocketPonyfill ?? WebSocket, !this.WebSocketPonyfill)
3416
+ if (_e(this, "id", ++Lt.connectCount), _e(this, "WebSocketPonyfill", void 0), _e(this, "urlOptions", void 0), _e(this, "keepAliveOpts", void 0), _e(this, "wsObservable", ji(null)), _e(this, "openPromise", null), this.WebSocketPonyfill = e.WebSocketPonyfill ?? WebSocket, !this.WebSocketPonyfill)
3417
3417
  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");
3418
3418
  this.urlOptions = e.urlOptions, this.keepAliveOpts = e.keepAlive;
3419
3419
  }
3420
3420
  }
3421
3421
  _e(Lt, "connectCount", 0);
3422
- class go {
3422
+ class vo {
3423
3423
  constructor() {
3424
3424
  this.keyToValue = /* @__PURE__ */ new Map(), this.valueToKey = /* @__PURE__ */ new Map();
3425
3425
  }
@@ -3436,9 +3436,9 @@ class go {
3436
3436
  this.keyToValue.clear(), this.valueToKey.clear();
3437
3437
  }
3438
3438
  }
3439
- class rs {
3439
+ class ss {
3440
3440
  constructor(e) {
3441
- this.generateIdentifier = e, this.kv = new go();
3441
+ this.generateIdentifier = e, this.kv = new vo();
3442
3442
  }
3443
3443
  register(e, r) {
3444
3444
  this.kv.getByValue(e) || (r || (r = this.generateIdentifier(e)), this.kv.set(r, e));
@@ -3453,7 +3453,7 @@ class rs {
3453
3453
  return this.kv.getByKey(e);
3454
3454
  }
3455
3455
  }
3456
- class bo extends rs {
3456
+ class wo extends ss {
3457
3457
  constructor() {
3458
3458
  super((e) => e.name), this.classToAllowedProps = /* @__PURE__ */ new Map();
3459
3459
  }
@@ -3464,7 +3464,7 @@ class bo extends rs {
3464
3464
  return this.classToAllowedProps.get(e);
3465
3465
  }
3466
3466
  }
3467
- function vo(t) {
3467
+ function Eo(t) {
3468
3468
  if ("values" in Object)
3469
3469
  return Object.values(t);
3470
3470
  const e = [];
@@ -3472,8 +3472,8 @@ function vo(t) {
3472
3472
  t.hasOwnProperty(r) && e.push(t[r]);
3473
3473
  return e;
3474
3474
  }
3475
- function wo(t, e) {
3476
- const r = vo(t);
3475
+ function Ro(t, e) {
3476
+ const r = Eo(t);
3477
3477
  if ("find" in r)
3478
3478
  return r.find(e);
3479
3479
  const n = r;
@@ -3483,7 +3483,7 @@ function wo(t, e) {
3483
3483
  return a;
3484
3484
  }
3485
3485
  }
3486
- function ot(t, e) {
3486
+ function at(t, e) {
3487
3487
  Object.entries(t).forEach(([r, n]) => e(n, r));
3488
3488
  }
3489
3489
  function qt(t, e) {
@@ -3496,7 +3496,7 @@ function gn(t, e) {
3496
3496
  return n;
3497
3497
  }
3498
3498
  }
3499
- class Eo {
3499
+ class Oo {
3500
3500
  constructor() {
3501
3501
  this.transfomers = {};
3502
3502
  }
@@ -3504,13 +3504,13 @@ class Eo {
3504
3504
  this.transfomers[e.name] = e;
3505
3505
  }
3506
3506
  findApplicable(e) {
3507
- return wo(this.transfomers, (r) => r.isApplicable(e));
3507
+ return Ro(this.transfomers, (r) => r.isApplicable(e));
3508
3508
  }
3509
3509
  findByName(e) {
3510
3510
  return this.transfomers[e];
3511
3511
  }
3512
3512
  }
3513
- const Ro = (t) => Object.prototype.toString.call(t).slice(8, -1), ns = (t) => typeof t > "u", Oo = (t) => t === null, wt = (t) => typeof t != "object" || t === null || t === Object.prototype ? !1 : Object.getPrototypeOf(t) === null ? !0 : Object.getPrototypeOf(t) === Object.prototype, vr = (t) => wt(t) && Object.keys(t).length === 0, xe = (t) => Array.isArray(t), Po = (t) => typeof t == "string", So = (t) => typeof t == "number" && !isNaN(t), Co = (t) => typeof t == "boolean", To = (t) => t instanceof RegExp, Et = (t) => t instanceof Map, Rt = (t) => t instanceof Set, ss = (t) => Ro(t) === "Symbol", xo = (t) => t instanceof Date && !isNaN(t.valueOf()), Fo = (t) => t instanceof Error, bn = (t) => typeof t == "number" && isNaN(t), Ao = (t) => Co(t) || Oo(t) || ns(t) || So(t) || Po(t) || ss(t), Do = (t) => typeof t == "bigint", _o = (t) => t === 1 / 0 || t === -1 / 0, Io = (t) => ArrayBuffer.isView(t) && !(t instanceof DataView), ko = (t) => t instanceof URL, is = (t) => t.replace(/\./g, "\\."), tr = (t) => t.map(String).map(is).join("."), mt = (t) => {
3513
+ const Po = (t) => Object.prototype.toString.call(t).slice(8, -1), is = (t) => typeof t > "u", So = (t) => t === null, wt = (t) => typeof t != "object" || t === null || t === Object.prototype ? !1 : Object.getPrototypeOf(t) === null ? !0 : Object.getPrototypeOf(t) === Object.prototype, vr = (t) => wt(t) && Object.keys(t).length === 0, xe = (t) => Array.isArray(t), Co = (t) => typeof t == "string", To = (t) => typeof t == "number" && !isNaN(t), xo = (t) => typeof t == "boolean", Fo = (t) => t instanceof RegExp, Et = (t) => t instanceof Map, Rt = (t) => t instanceof Set, os = (t) => Po(t) === "Symbol", Ao = (t) => t instanceof Date && !isNaN(t.valueOf()), Do = (t) => t instanceof Error, bn = (t) => typeof t == "number" && isNaN(t), _o = (t) => xo(t) || So(t) || is(t) || To(t) || Co(t) || os(t), Io = (t) => typeof t == "bigint", ko = (t) => t === 1 / 0 || t === -1 / 0, jo = (t) => ArrayBuffer.isView(t) && !(t instanceof DataView), qo = (t) => t instanceof URL, as = (t) => t.replace(/\./g, "\\."), tr = (t) => t.map(String).map(as).join("."), gt = (t) => {
3514
3514
  const e = [];
3515
3515
  let r = "";
3516
3516
  for (let s = 0; s < t.length; s++) {
@@ -3536,12 +3536,12 @@ function ie(t, e, r, n) {
3536
3536
  untransform: n
3537
3537
  };
3538
3538
  }
3539
- const os = [
3540
- ie(ns, "undefined", () => null, () => {
3539
+ const us = [
3540
+ ie(is, "undefined", () => null, () => {
3541
3541
  }),
3542
- ie(Do, "bigint", (t) => t.toString(), (t) => typeof BigInt < "u" ? BigInt(t) : (console.error("Please add a BigInt polyfill."), t)),
3543
- ie(xo, "Date", (t) => t.toISOString(), (t) => new Date(t)),
3544
- ie(Fo, "Error", (t, e) => {
3542
+ ie(Io, "bigint", (t) => t.toString(), (t) => typeof BigInt < "u" ? BigInt(t) : (console.error("Please add a BigInt polyfill."), t)),
3543
+ ie(Ao, "Date", (t) => t.toISOString(), (t) => new Date(t)),
3544
+ ie(Do, "Error", (t, e) => {
3545
3545
  const r = {
3546
3546
  name: t.name,
3547
3547
  message: t.message
@@ -3555,7 +3555,7 @@ const os = [
3555
3555
  r[n] = t[n];
3556
3556
  }), r;
3557
3557
  }),
3558
- ie(To, "regexp", (t) => "" + t, (t) => {
3558
+ ie(Fo, "regexp", (t) => "" + t, (t) => {
3559
3559
  const e = t.slice(1, t.lastIndexOf("/")), r = t.slice(t.lastIndexOf("/") + 1);
3560
3560
  return new RegExp(e, r);
3561
3561
  }),
@@ -3568,9 +3568,9 @@ const os = [
3568
3568
  (t) => new Set(t)
3569
3569
  ),
3570
3570
  ie(Et, "map", (t) => [...t.entries()], (t) => new Map(t)),
3571
- ie((t) => bn(t) || _o(t), "number", (t) => bn(t) ? "NaN" : t > 0 ? "Infinity" : "-Infinity", Number),
3571
+ ie((t) => bn(t) || ko(t), "number", (t) => bn(t) ? "NaN" : t > 0 ? "Infinity" : "-Infinity", Number),
3572
3572
  ie((t) => t === 0 && 1 / t === -1 / 0, "number", () => "-0", Number),
3573
- ie(ko, "URL", (t) => t.toString(), (t) => new URL(t))
3573
+ ie(qo, "URL", (t) => t.toString(), (t) => new URL(t))
3574
3574
  ];
3575
3575
  function Qt(t, e, r, n) {
3576
3576
  return {
@@ -3580,12 +3580,12 @@ function Qt(t, e, r, n) {
3580
3580
  untransform: n
3581
3581
  };
3582
3582
  }
3583
- const as = Qt((t, e) => ss(t) ? !!e.symbolRegistry.getIdentifier(t) : !1, (t, e) => ["symbol", e.symbolRegistry.getIdentifier(t)], (t) => t.description, (t, e, r) => {
3583
+ const cs = Qt((t, e) => os(t) ? !!e.symbolRegistry.getIdentifier(t) : !1, (t, e) => ["symbol", e.symbolRegistry.getIdentifier(t)], (t) => t.description, (t, e, r) => {
3584
3584
  const n = r.symbolRegistry.getValue(e[1]);
3585
3585
  if (!n)
3586
3586
  throw new Error("Trying to deserialize unknown symbol");
3587
3587
  return n;
3588
- }), jo = [
3588
+ }), Mo = [
3589
3589
  Int8Array,
3590
3590
  Uint8Array,
3591
3591
  Int16Array,
@@ -3595,16 +3595,16 @@ const as = Qt((t, e) => ss(t) ? !!e.symbolRegistry.getIdentifier(t) : !1, (t, e)
3595
3595
  Float32Array,
3596
3596
  Float64Array,
3597
3597
  Uint8ClampedArray
3598
- ].reduce((t, e) => (t[e.name] = e, t), {}), us = Qt(Io, (t) => ["typed-array", t.constructor.name], (t) => [...t], (t, e) => {
3599
- const r = jo[e[1]];
3598
+ ].reduce((t, e) => (t[e.name] = e, t), {}), ls = Qt(jo, (t) => ["typed-array", t.constructor.name], (t) => [...t], (t, e) => {
3599
+ const r = Mo[e[1]];
3600
3600
  if (!r)
3601
3601
  throw new Error("Trying to deserialize unknown typed array");
3602
3602
  return new r(t);
3603
3603
  });
3604
- function cs(t, e) {
3604
+ function fs(t, e) {
3605
3605
  return t != null && t.constructor ? !!e.classRegistry.getIdentifier(t.constructor) : !1;
3606
3606
  }
3607
- const ls = Qt(cs, (t, e) => ["class", e.classRegistry.getIdentifier(t.constructor)], (t, e) => {
3607
+ const hs = Qt(fs, (t, e) => ["class", e.classRegistry.getIdentifier(t.constructor)], (t, e) => {
3608
3608
  const r = e.classRegistry.getAllowedProps(t.constructor);
3609
3609
  if (!r)
3610
3610
  return { ...t };
@@ -3617,44 +3617,44 @@ const ls = Qt(cs, (t, e) => ["class", e.classRegistry.getIdentifier(t.constructo
3617
3617
  if (!n)
3618
3618
  throw new Error(`Trying to deserialize unknown class '${e[1]}' - check https://github.com/blitz-js/superjson/issues/116#issuecomment-773996564`);
3619
3619
  return Object.assign(Object.create(n.prototype), t);
3620
- }), fs = Qt((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) => {
3620
+ }), ds = Qt((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) => {
3621
3621
  const n = r.customTransformerRegistry.findByName(e[1]);
3622
3622
  if (!n)
3623
3623
  throw new Error("Trying to deserialize unknown custom value");
3624
3624
  return n.deserialize(t);
3625
- }), qo = [ls, as, fs, us], vn = (t, e) => {
3626
- const r = gn(qo, (s) => s.isApplicable(t, e));
3625
+ }), Uo = [hs, cs, ds, ls], vn = (t, e) => {
3626
+ const r = gn(Uo, (s) => s.isApplicable(t, e));
3627
3627
  if (r)
3628
3628
  return {
3629
3629
  value: r.transform(t, e),
3630
3630
  type: r.annotation(t, e)
3631
3631
  };
3632
- const n = gn(os, (s) => s.isApplicable(t, e));
3632
+ const n = gn(us, (s) => s.isApplicable(t, e));
3633
3633
  if (n)
3634
3634
  return {
3635
3635
  value: n.transform(t, e),
3636
3636
  type: n.annotation
3637
3637
  };
3638
- }, hs = {};
3639
- os.forEach((t) => {
3640
- hs[t.annotation] = t;
3638
+ }, ys = {};
3639
+ us.forEach((t) => {
3640
+ ys[t.annotation] = t;
3641
3641
  });
3642
- const Mo = (t, e, r) => {
3642
+ const No = (t, e, r) => {
3643
3643
  if (xe(e))
3644
3644
  switch (e[0]) {
3645
3645
  case "symbol":
3646
- return as.untransform(t, e, r);
3646
+ return cs.untransform(t, e, r);
3647
3647
  case "class":
3648
- return ls.untransform(t, e, r);
3648
+ return hs.untransform(t, e, r);
3649
3649
  case "custom":
3650
- return fs.untransform(t, e, r);
3650
+ return ds.untransform(t, e, r);
3651
3651
  case "typed-array":
3652
- return us.untransform(t, e, r);
3652
+ return ls.untransform(t, e, r);
3653
3653
  default:
3654
3654
  throw new Error("Unknown transformation: " + e);
3655
3655
  }
3656
3656
  else {
3657
- const n = hs[e];
3657
+ const n = ys[e];
3658
3658
  if (!n)
3659
3659
  throw new Error("Unknown transformation: " + e);
3660
3660
  return n.untransform(t, r);
@@ -3667,7 +3667,7 @@ const Mo = (t, e, r) => {
3667
3667
  r.next(), e--;
3668
3668
  return r.next().value;
3669
3669
  };
3670
- function ds(t) {
3670
+ function ps(t) {
3671
3671
  if (qt(t, "__proto__"))
3672
3672
  throw new Error("__proto__ is not allowed as a property");
3673
3673
  if (qt(t, "prototype"))
@@ -3675,8 +3675,8 @@ function ds(t) {
3675
3675
  if (qt(t, "constructor"))
3676
3676
  throw new Error("constructor is not allowed as a property");
3677
3677
  }
3678
- const Uo = (t, e) => {
3679
- ds(e);
3678
+ const Lo = (t, e) => {
3679
+ ps(e);
3680
3680
  for (let r = 0; r < e.length; r++) {
3681
3681
  const n = e[r];
3682
3682
  if (Rt(t))
@@ -3696,7 +3696,7 @@ const Uo = (t, e) => {
3696
3696
  }
3697
3697
  return t;
3698
3698
  }, wr = (t, e, r) => {
3699
- if (ds(e), e.length === 0)
3699
+ if (ps(e), e.length === 0)
3700
3700
  return r(t);
3701
3701
  let n = t;
3702
3702
  for (let a = 0; a < e.length - 1; a++) {
@@ -3748,41 +3748,41 @@ function Er(t, e, r = []) {
3748
3748
  if (!t)
3749
3749
  return;
3750
3750
  if (!xe(t)) {
3751
- ot(t, (a, u) => Er(a, e, [...r, ...mt(u)]));
3751
+ at(t, (a, u) => Er(a, e, [...r, ...gt(u)]));
3752
3752
  return;
3753
3753
  }
3754
3754
  const [n, s] = t;
3755
- s && ot(s, (a, u) => {
3756
- Er(a, e, [...r, ...mt(u)]);
3755
+ s && at(s, (a, u) => {
3756
+ Er(a, e, [...r, ...gt(u)]);
3757
3757
  }), e(n, r);
3758
3758
  }
3759
- function No(t, e, r) {
3759
+ function Qo(t, e, r) {
3760
3760
  return Er(e, (n, s) => {
3761
- t = wr(t, s, (a) => Mo(a, n, r));
3761
+ t = wr(t, s, (a) => No(a, n, r));
3762
3762
  }), t;
3763
3763
  }
3764
- function Lo(t, e) {
3764
+ function $o(t, e) {
3765
3765
  function r(n, s) {
3766
- const a = Uo(t, mt(s));
3767
- n.map(mt).forEach((u) => {
3766
+ const a = Lo(t, gt(s));
3767
+ n.map(gt).forEach((u) => {
3768
3768
  t = wr(t, u, () => a);
3769
3769
  });
3770
3770
  }
3771
3771
  if (xe(e)) {
3772
3772
  const [n, s] = e;
3773
3773
  n.forEach((a) => {
3774
- t = wr(t, mt(a), () => t);
3775
- }), s && ot(s, r);
3774
+ t = wr(t, gt(a), () => t);
3775
+ }), s && at(s, r);
3776
3776
  } else
3777
- ot(e, r);
3777
+ at(e, r);
3778
3778
  return t;
3779
3779
  }
3780
- const Qo = (t, e) => wt(t) || xe(t) || Et(t) || Rt(t) || cs(t, e);
3781
- function $o(t, e, r) {
3780
+ const Ko = (t, e) => wt(t) || xe(t) || Et(t) || Rt(t) || fs(t, e);
3781
+ function Vo(t, e, r) {
3782
3782
  const n = r.get(t);
3783
3783
  n ? n.push(e) : r.set(t, [e]);
3784
3784
  }
3785
- function Ko(t, e) {
3785
+ function zo(t, e) {
3786
3786
  const r = {};
3787
3787
  let n;
3788
3788
  return t.forEach((s) => {
@@ -3793,60 +3793,60 @@ function Ko(t, e) {
3793
3793
  a.length === 0 ? n = u.map(tr) : r[tr(a)] = u.map(tr);
3794
3794
  }), n ? vr(r) ? [n] : [n, r] : vr(r) ? void 0 : r;
3795
3795
  }
3796
- const ys = (t, e, r, n, s = [], a = [], u = /* @__PURE__ */ new Map()) => {
3797
- const l = Ao(t);
3796
+ const ms = (t, e, r, n, s = [], a = [], u = /* @__PURE__ */ new Map()) => {
3797
+ const l = _o(t);
3798
3798
  if (!l) {
3799
- $o(t, s, e);
3799
+ Vo(t, s, e);
3800
3800
  const m = u.get(t);
3801
3801
  if (m)
3802
3802
  return n ? {
3803
3803
  transformedValue: null
3804
3804
  } : m;
3805
3805
  }
3806
- if (!Qo(t, r)) {
3807
- const m = vn(t, r), E = m ? {
3806
+ if (!Ko(t, r)) {
3807
+ const m = vn(t, r), R = m ? {
3808
3808
  transformedValue: m.value,
3809
3809
  annotations: [m.type]
3810
3810
  } : {
3811
3811
  transformedValue: t
3812
3812
  };
3813
- return l || u.set(t, E), E;
3813
+ return l || u.set(t, R), R;
3814
3814
  }
3815
3815
  if (qt(a, t))
3816
3816
  return {
3817
3817
  transformedValue: null
3818
3818
  };
3819
3819
  const c = vn(t, r), d = (c == null ? void 0 : c.value) ?? t, f = xe(d) ? [] : {}, h = {};
3820
- ot(d, (m, E) => {
3821
- if (E === "__proto__" || E === "constructor" || E === "prototype")
3822
- throw new Error(`Detected property ${E}. This is a prototype pollution risk, please remove it from your object.`);
3823
- const b = ys(m, e, r, n, [...s, E], [...a, t], u);
3824
- f[E] = b.transformedValue, xe(b.annotations) ? h[E] = b.annotations : wt(b.annotations) && ot(b.annotations, (R, A) => {
3825
- h[is(E) + "." + A] = R;
3820
+ at(d, (m, R) => {
3821
+ if (R === "__proto__" || R === "constructor" || R === "prototype")
3822
+ throw new Error(`Detected property ${R}. This is a prototype pollution risk, please remove it from your object.`);
3823
+ const g = ms(m, e, r, n, [...s, R], [...a, t], u);
3824
+ f[R] = g.transformedValue, xe(g.annotations) ? h[R] = g.annotations : wt(g.annotations) && at(g.annotations, (w, A) => {
3825
+ h[as(R) + "." + A] = w;
3826
3826
  });
3827
3827
  });
3828
- const p = vr(h) ? {
3828
+ const y = vr(h) ? {
3829
3829
  transformedValue: f,
3830
3830
  annotations: c ? [c.type] : void 0
3831
3831
  } : {
3832
3832
  transformedValue: f,
3833
3833
  annotations: c ? [c.type, h] : h
3834
3834
  };
3835
- return l || u.set(t, p), p;
3835
+ return l || u.set(t, y), y;
3836
3836
  };
3837
- function ps(t) {
3837
+ function gs(t) {
3838
3838
  return Object.prototype.toString.call(t).slice(8, -1);
3839
3839
  }
3840
3840
  function wn(t) {
3841
- return ps(t) === "Array";
3841
+ return gs(t) === "Array";
3842
3842
  }
3843
- function Vo(t) {
3844
- if (ps(t) !== "Object")
3843
+ function Wo(t) {
3844
+ if (gs(t) !== "Object")
3845
3845
  return !1;
3846
3846
  const e = Object.getPrototypeOf(t);
3847
3847
  return !!e && e.constructor === Object && e === Object.prototype;
3848
3848
  }
3849
- function zo(t, e, r, n, s) {
3849
+ function Ho(t, e, r, n, s) {
3850
3850
  const a = {}.propertyIsEnumerable.call(n, e) ? "enumerable" : "nonenumerable";
3851
3851
  a === "enumerable" && (t[e] = r), s && a === "nonenumerable" && Object.defineProperty(t, e, {
3852
3852
  value: r,
@@ -3858,14 +3858,14 @@ function zo(t, e, r, n, s) {
3858
3858
  function Rr(t, e = {}) {
3859
3859
  if (wn(t))
3860
3860
  return t.map((s) => Rr(s, e));
3861
- if (!Vo(t))
3861
+ if (!Wo(t))
3862
3862
  return t;
3863
3863
  const r = Object.getOwnPropertyNames(t), n = Object.getOwnPropertySymbols(t);
3864
3864
  return [...r, ...n].reduce((s, a) => {
3865
3865
  if (wn(e.props) && !e.props.includes(a))
3866
3866
  return s;
3867
3867
  const u = t[a], l = Rr(u, e);
3868
- return zo(s, a, l, t, e.nonenumerable), s;
3868
+ return Ho(s, a, l, t, e.nonenumerable), s;
3869
3869
  }, {});
3870
3870
  }
3871
3871
  class x {
@@ -3873,17 +3873,17 @@ class x {
3873
3873
  * @param dedupeReferentialEqualities If true, SuperJSON will make sure only one instance of referentially equal objects are serialized and the rest are replaced with `null`.
3874
3874
  */
3875
3875
  constructor({ dedupe: e = !1 } = {}) {
3876
- this.classRegistry = new bo(), this.symbolRegistry = new rs((r) => r.description ?? ""), this.customTransformerRegistry = new Eo(), this.allowedErrorProps = [], this.dedupe = e;
3876
+ this.classRegistry = new wo(), this.symbolRegistry = new ss((r) => r.description ?? ""), this.customTransformerRegistry = new Oo(), this.allowedErrorProps = [], this.dedupe = e;
3877
3877
  }
3878
3878
  serialize(e) {
3879
- const r = /* @__PURE__ */ new Map(), n = ys(e, r, this, this.dedupe), s = {
3879
+ const r = /* @__PURE__ */ new Map(), n = ms(e, r, this, this.dedupe), s = {
3880
3880
  json: n.transformedValue
3881
3881
  };
3882
3882
  n.annotations && (s.meta = {
3883
3883
  ...s.meta,
3884
3884
  values: n.annotations
3885
3885
  });
3886
- const a = Ko(r, this.dedupe);
3886
+ const a = zo(r, this.dedupe);
3887
3887
  return a && (s.meta = {
3888
3888
  ...s.meta,
3889
3889
  referentialEqualities: a
@@ -3892,7 +3892,7 @@ class x {
3892
3892
  deserialize(e) {
3893
3893
  const { json: r, meta: n } = e;
3894
3894
  let s = Rr(r);
3895
- return n != null && n.values && (s = No(s, n.values, this)), n != null && n.referentialEqualities && (s = Lo(s, n.referentialEqualities)), s;
3895
+ return n != null && n.values && (s = Qo(s, n.values, this)), n != null && n.referentialEqualities && (s = $o(s, n.referentialEqualities)), s;
3896
3896
  }
3897
3897
  stringify(e) {
3898
3898
  return JSON.stringify(this.serialize(e));
@@ -3933,14 +3933,14 @@ x.registerClass;
3933
3933
  x.registerCustom;
3934
3934
  x.registerSymbol;
3935
3935
  x.allowErrorProps;
3936
- const ms = Vs(null);
3937
- function Ho(t, e) {
3938
- const r = Wi({
3936
+ const bs = Ws(null);
3937
+ function Bo(t, e) {
3938
+ const r = Gi({
3939
3939
  links: [
3940
- lo({
3940
+ ho({
3941
3941
  enabled: (s) => process.env.NODE_ENV === "development" && typeof window < "u" || s.direction === "down" && s.result instanceof Error
3942
3942
  }),
3943
- oo({
3943
+ uo({
3944
3944
  url: `${t}/trpc`,
3945
3945
  headers: () => ({
3946
3946
  Authorization: `Bearer ${e}`
@@ -3949,32 +3949,32 @@ function Ho(t, e) {
3949
3949
  })
3950
3950
  ]
3951
3951
  }), n = async (s, a, u = null) => {
3952
- const l = Object.entries(Un).reduce(
3953
- (p, [m, E]) => (E.extensions.forEach((b) => {
3954
- p.set(b, m);
3955
- }), p),
3952
+ const l = Object.entries(Ln).reduce(
3953
+ (y, [m, R]) => (R.extensions.forEach((g) => {
3954
+ y.set(g, m);
3955
+ }), y),
3956
3956
  /* @__PURE__ */ new Map()
3957
- ), c = a.map((p) => {
3958
- const m = p.name.toLowerCase(), E = m.includes(".") ? m.substring(m.lastIndexOf(".")) : "", b = E.startsWith(".") ? E : `.${E}`, R = l.get(b) || null;
3959
- return { ...p, mimeType: R };
3957
+ ), c = a.map((y) => {
3958
+ const m = y.name.toLowerCase(), R = m.includes(".") ? m.substring(m.lastIndexOf(".")) : "", g = R.startsWith(".") ? R : `.${R}`, w = l.get(g) || null;
3959
+ return { ...y, mimeType: w };
3960
3960
  }).filter(
3961
- (p) => p.mimeType !== null && Js.has(p.mimeType)
3961
+ (y) => y.mimeType !== null && Zs.has(y.mimeType)
3962
3962
  );
3963
3963
  if (c.length === 0)
3964
3964
  return { filesToCreate: [] };
3965
3965
  const d = await r.fileRouter.getFilesByProject.query({
3966
3966
  projectId: s
3967
- }), f = c.filter((p) => u === null ? !d.some(
3968
- (m) => m.path === p.blobUrl
3967
+ }), f = c.filter((y) => u === null ? !d.some(
3968
+ (m) => m.path === y.blobUrl
3969
3969
  ) : !d.some(
3970
- (m) => m.path === p.blobUrl && m.parentId === u
3970
+ (m) => m.path === y.blobUrl && m.parentId === u
3971
3971
  ));
3972
- return f.length === 0 ? { filesToCreate: [] } : { filesToCreate: f.map((p) => ({
3972
+ return f.length === 0 ? { filesToCreate: [] } : { filesToCreate: f.map((y) => ({
3973
3973
  projectId: s,
3974
- mimeType: p.mimeType,
3975
- path: p.blobUrl,
3974
+ mimeType: y.mimeType,
3975
+ path: y.blobUrl,
3976
3976
  // Map blobUrl back to path for API
3977
- name: p.name,
3977
+ name: y.name,
3978
3978
  size: 0,
3979
3979
  // You might need to calculate or pass size
3980
3980
  metadata: null,
@@ -4094,7 +4094,7 @@ function Ho(t, e) {
4094
4094
  },
4095
4095
  files: []
4096
4096
  };
4097
- const p = await r.fileRouter.createFiles.mutate({
4097
+ const y = await r.fileRouter.createFiles.mutate({
4098
4098
  files: h
4099
4099
  });
4100
4100
  return {
@@ -4105,7 +4105,7 @@ function Ho(t, e) {
4105
4105
  parentId: f.parentId,
4106
4106
  isDirectory: f.isDirectory
4107
4107
  } : null,
4108
- files: p.map((m) => ({
4108
+ files: y.map((m) => ({
4109
4109
  blobUrl: m.path,
4110
4110
  name: m.name,
4111
4111
  id: m.id,
@@ -4123,8 +4123,8 @@ function Xo({
4123
4123
  token: n,
4124
4124
  onAnalyticsEvent: s
4125
4125
  }) {
4126
- const [a, u] = zs(null), l = Hs(
4127
- () => new hi({
4126
+ const [a, u] = Hs(null), l = Bs(
4127
+ () => new yi({
4128
4128
  defaultOptions: {
4129
4129
  queries: {
4130
4130
  staleTime: 30 * 1e3,
@@ -4136,7 +4136,7 @@ function Xo({
4136
4136
  []
4137
4137
  );
4138
4138
  return Xr(() => {
4139
- const c = `${e}:${r}`, d = Ho(c, n);
4139
+ const c = `${e}:${r}`, d = Bo(c, n);
4140
4140
  u(d);
4141
4141
  }, [e, r, n]), Xr(() => {
4142
4142
  if (!s) return;
@@ -4155,30 +4155,54 @@ function Xo({
4155
4155
  c
4156
4156
  ), window.removeEventListener("message", d);
4157
4157
  };
4158
- }, [s]), /* @__PURE__ */ gt.jsx(gi, { client: l, children: /* @__PURE__ */ gt.jsx(ms.Provider, { value: { host: e, port: r, client: a, token: n }, children: t }) });
4158
+ }, [s]), /* @__PURE__ */ We.jsx(vi, { client: l, children: /* @__PURE__ */ We.jsx(bs.Provider, { value: { host: e, port: r, client: a, token: n }, children: t }) });
4159
4159
  }
4160
- function ct() {
4161
- const t = Ws(ms);
4160
+ function lt() {
4161
+ const t = Gs(bs);
4162
4162
  if (!t)
4163
4163
  throw new Error("useFolioContext must be used within a FolioProvider");
4164
4164
  return t;
4165
4165
  }
4166
- const { useEffect: Wo, useRef: Bo, useState: Go } = $;
4166
+ const { useEffect: En, useRef: Go, useState: Rn } = $;
4167
4167
  function Zo({
4168
4168
  width: t = "100%",
4169
4169
  height: e = "100vh",
4170
4170
  allow: r = "camera; microphone; clipboard-read; clipboard-write; fullscreen",
4171
4171
  style: n,
4172
4172
  className: s = "",
4173
- iframeProps: a = {}
4173
+ iframeProps: a = {},
4174
+ authMethod: u = "postMessage"
4174
4175
  }) {
4175
- const { host: u, port: l, token: c } = ct(), d = Bo(null), [f, h] = Go();
4176
- return Wo(() => {
4176
+ const { host: l, port: c, token: d } = lt(), f = Go(null), [h, y] = Rn(), [m, R] = Rn(!1);
4177
+ return En(() => {
4177
4178
  (() => {
4178
- const E = `${`${u}:${l}`}?jwt=${encodeURIComponent(c)}`;
4179
- h(E);
4179
+ const w = `${l}:${c}`;
4180
+ u === "url" ? (console.warn(
4181
+ "URL-based authentication is less secure. Consider using postMessage instead."
4182
+ ), y(`${w}?jwt=${encodeURIComponent(d)}`)) : y(w);
4180
4183
  })();
4181
- }, [u, l, c]), f ? /* @__PURE__ */ gt.jsx(
4184
+ }, [l, c, d, u]), En(() => {
4185
+ if (!f.current || !d || u === "url") return;
4186
+ const g = (w) => {
4187
+ if (![
4188
+ `${l}:${c}`,
4189
+ l,
4190
+ // Without port for flexibility
4191
+ l.replace("://", "://www.")
4192
+ // With www prefix
4193
+ ].includes(w.origin) && !w.origin.startsWith(l.replace("://", "://www."))) {
4194
+ console.warn(`Ignored message from unexpected origin: ${w.origin}`);
4195
+ return;
4196
+ }
4197
+ w.data && w.data.type === "REQUEST_JWT_TOKEN" && f.current && f.current.contentWindow && (f.current.contentWindow.postMessage(
4198
+ { type: "JWT_TOKEN", token: d },
4199
+ w.origin
4200
+ ), R(!0)), w.data && w.data.type === "FOLIO_IFRAME_READY" && R(!0);
4201
+ };
4202
+ return window.addEventListener("message", g), () => {
4203
+ window.removeEventListener("message", g);
4204
+ };
4205
+ }, [l, c, d, u, f.current]), h ? /* @__PURE__ */ We.jsxs(
4182
4206
  "div",
4183
4207
  {
4184
4208
  className: `folio-embed-container ${s}`,
@@ -4188,29 +4212,50 @@ function Zo({
4188
4212
  overflow: "hidden",
4189
4213
  ...n
4190
4214
  },
4191
- children: /* @__PURE__ */ gt.jsx(
4192
- "iframe",
4193
- {
4194
- ref: d,
4195
- src: f,
4196
- width: "100%",
4197
- height: "100%",
4198
- style: {
4199
- border: "none",
4215
+ children: [
4216
+ /* @__PURE__ */ We.jsx(
4217
+ "iframe",
4218
+ {
4219
+ ref: f,
4220
+ src: h,
4200
4221
  width: "100%",
4201
4222
  height: "100%",
4202
- overflow: "auto"
4203
- },
4204
- allow: r,
4205
- allowFullScreen: !0,
4206
- ...a
4207
- }
4208
- )
4223
+ style: {
4224
+ border: "none",
4225
+ width: "100%",
4226
+ height: "100%",
4227
+ overflow: "auto",
4228
+ opacity: m ? 1 : 0.3,
4229
+ // Visual indication of loading state
4230
+ transition: "opacity 0.3s ease-in-out"
4231
+ },
4232
+ allow: r,
4233
+ allowFullScreen: !0,
4234
+ ...a
4235
+ }
4236
+ ),
4237
+ !m && u !== "url" && /* @__PURE__ */ We.jsx(
4238
+ "div",
4239
+ {
4240
+ style: {
4241
+ position: "absolute",
4242
+ top: "50%",
4243
+ left: "50%",
4244
+ transform: "translate(-50%, -50%)",
4245
+ textAlign: "center",
4246
+ fontFamily: "system-ui, -apple-system, sans-serif",
4247
+ fontSize: "14px",
4248
+ color: "#333"
4249
+ },
4250
+ children: "Loading Folio..."
4251
+ }
4252
+ )
4253
+ ]
4209
4254
  }
4210
4255
  ) : null;
4211
4256
  }
4212
4257
  function ea() {
4213
- const { client: t } = ct(), e = Jn({
4258
+ const { client: t } = lt(), e = Zn({
4214
4259
  queryKey: ["folioProjects"],
4215
4260
  queryFn: async () => {
4216
4261
  if (!t) throw new Error("Folio client not initialized");
@@ -4227,7 +4272,7 @@ function ea() {
4227
4272
  };
4228
4273
  }
4229
4274
  function ta(t) {
4230
- const { client: e } = ct(), r = Jn({
4275
+ const { client: e } = lt(), r = Zn({
4231
4276
  queryKey: ["folioFiles", t],
4232
4277
  queryFn: async () => {
4233
4278
  if (!e) throw new Error("Folio client not initialized");
@@ -4245,7 +4290,7 @@ function ta(t) {
4245
4290
  };
4246
4291
  }
4247
4292
  function ra() {
4248
- const { client: t } = ct(), e = Tt(), r = Tr({
4293
+ const { client: t } = lt(), e = Tt(), r = Tr({
4249
4294
  mutationFn: async (n) => {
4250
4295
  if (!t) throw new Error("Folio client not initialized");
4251
4296
  return t.addProjectForUser(n);
@@ -4264,7 +4309,7 @@ function ra() {
4264
4309
  };
4265
4310
  }
4266
4311
  function na(t) {
4267
- const { client: e } = ct(), r = Tt(), n = Tr({
4312
+ const { client: e } = lt(), r = Tt(), n = Tr({
4268
4313
  mutationFn: async (s) => {
4269
4314
  if (!e) throw new Error("Folio client not initialized");
4270
4315
  if (!t) throw new Error("Project ID is required");
@@ -4284,7 +4329,7 @@ function na(t) {
4284
4329
  };
4285
4330
  }
4286
4331
  function sa(t) {
4287
- const { client: e } = ct(), r = Tt(), n = Tr({
4332
+ const { client: e } = lt(), r = Tt(), n = Tr({
4288
4333
  mutationFn: async (s) => {
4289
4334
  if (!e) throw new Error("Folio client not initialized");
4290
4335
  if (!t) throw new Error("Project ID is required");