reactjrx 1.117.1 → 1.120.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +0 -3
- package/dist/index.js +347 -323
- package/dist/index.js.map +1 -1
- package/dist/lib/binding/useLiveBehaviorSubject.d.ts +2 -1
- package/dist/lib/queries/useMutation$.d.ts +5 -5
- package/dist/lib/queries/useSwitchMutation$.d.ts +31 -7
- package/dist/lib/queries/useSwitchMutation$.test.d.ts +1 -0
- package/dist/lib/state/SignalContext.d.ts +5 -0
- package/dist/lib/utils/react/useConstant.d.ts +1 -3
- package/dist/lib/utils/react/useRefOnce.d.ts +3 -0
- package/dist/lib/utils/react/useUnmountObservable.d.ts +2 -3
- package/dist/lib/utils/shallowEqual.d.ts +1 -1
- package/package.json +1 -1
- package/dist/lib/binding/useBehaviorSubject.d.ts +0 -21
- package/dist/lib/binding/useObservableCallback.d.ts +0 -5
- package/dist/lib/binding/useSubject.d.ts +0 -11
package/dist/index.js
CHANGED
|
@@ -1,133 +1,111 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { useRef as
|
|
5
|
-
import { isObservable as
|
|
6
|
-
import { catchError as
|
|
7
|
-
import { jsx as
|
|
8
|
-
import { hashKey as
|
|
9
|
-
function
|
|
1
|
+
var Se = Object.defineProperty;
|
|
2
|
+
var he = (e, t, r) => t in e ? Se(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
|
+
var I = (e, t, r) => he(e, typeof t != "symbol" ? t + "" : t, r);
|
|
4
|
+
import { useRef as $, useMemo as B, useCallback as h, useSyncExternalStore as ve, useEffect as v, useState as Q, createContext as ee, memo as te, useContext as re } from "react";
|
|
5
|
+
import { isObservable as J, from as V, of as g, defer as D, startWith as be, identity as ne, distinctUntilChanged as se, tap as T, catchError as F, EMPTY as _, BehaviorSubject as E, retry as we, ReplaySubject as Y, merge as C, throwError as P, timer as Ie, map as N, switchMap as M, zip as Ee, share as ue, throttleTime as xe, asyncScheduler as Ve, concatMap as Ce, scan as Me, takeUntil as Fe, fromEvent as ae, take as ce, delay as Ne, ignoreElements as $e, first as oe, defaultIfEmpty as Re, filter as Pe, noop as j } from "rxjs";
|
|
6
|
+
import { catchError as U, mergeMap as A, retryWhen as Ae, concatMap as Oe, first as qe, tap as Qe } from "rxjs/operators";
|
|
7
|
+
import { jsx as ie } from "react/jsx-runtime";
|
|
8
|
+
import { hashKey as le, useQueryClient as fe, useQuery as De, useMutation as Te } from "@tanstack/react-query";
|
|
9
|
+
function G(e) {
|
|
10
10
|
return e instanceof Promise || e && typeof e == "object" && "then" in e && typeof e.then == "function" && "catch" in e && e.catch === "function";
|
|
11
11
|
}
|
|
12
|
-
function
|
|
13
|
-
if (
|
|
14
|
-
if (
|
|
15
|
-
if (typeof e != "function") return () =>
|
|
12
|
+
function k(e) {
|
|
13
|
+
if (J(e)) return () => e;
|
|
14
|
+
if (G(e)) return () => V(e);
|
|
15
|
+
if (typeof e != "function") return () => g(e);
|
|
16
16
|
const t = e;
|
|
17
|
-
return (r) =>
|
|
17
|
+
return (r) => D(() => {
|
|
18
18
|
const n = t(r);
|
|
19
|
-
return
|
|
19
|
+
return G(n) ? V(n) : J(n) ? n : g(n);
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
|
-
const
|
|
23
|
-
const t =
|
|
24
|
-
return
|
|
22
|
+
const b = (e) => {
|
|
23
|
+
const t = $(e);
|
|
24
|
+
return B(() => {
|
|
25
25
|
t.current = e;
|
|
26
26
|
}, [e]), t;
|
|
27
27
|
};
|
|
28
|
-
function
|
|
28
|
+
function H(e, t, r) {
|
|
29
29
|
const n = t != null && !Array.isArray(t) ? t : {
|
|
30
30
|
defaultValue: void 0,
|
|
31
31
|
unsubscribeOnUnmount: !0,
|
|
32
32
|
compareFn: void 0
|
|
33
|
-
},
|
|
33
|
+
}, u = !r && Array.isArray(t) ? t : typeof e == "function" ? r ?? [] : [e], c = $(
|
|
34
34
|
"getValue" in e && typeof e.getValue == "function" ? e.getValue() : n.defaultValue
|
|
35
|
-
),
|
|
35
|
+
), a = b(e), l = b(n), s = h(() => c.current, []), o = h(
|
|
36
36
|
(i) => {
|
|
37
|
-
const
|
|
38
|
-
l.current.defaultValue ?
|
|
37
|
+
const d = a.current, p = k(d)().pipe(
|
|
38
|
+
l.current.defaultValue ? be(l.current.defaultValue) : ne,
|
|
39
39
|
/**
|
|
40
40
|
* @important there is already a Object.is comparison in place from react
|
|
41
41
|
* so we only add a custom compareFn if provided
|
|
42
42
|
*/
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
c.current =
|
|
43
|
+
se((m, y) => l.current.compareFn ? m === void 0 || y === void 0 ? !1 : l.current.compareFn(m, y) : !1),
|
|
44
|
+
T((m) => {
|
|
45
|
+
c.current = m;
|
|
46
46
|
}),
|
|
47
|
-
|
|
47
|
+
F((m) => (console.error(m), _))
|
|
48
48
|
).subscribe(i);
|
|
49
49
|
return () => {
|
|
50
|
-
l.current.unsubscribeOnUnmount !== !1 &&
|
|
50
|
+
l.current.unsubscribeOnUnmount !== !1 && p.unsubscribe();
|
|
51
51
|
};
|
|
52
52
|
},
|
|
53
|
-
[...
|
|
53
|
+
[...u]
|
|
54
54
|
);
|
|
55
|
-
return
|
|
55
|
+
return ve(o, s, s);
|
|
56
56
|
}
|
|
57
|
-
function
|
|
58
|
-
const r =
|
|
59
|
-
|
|
60
|
-
const n =
|
|
61
|
-
|
|
57
|
+
function _e(e, t = []) {
|
|
58
|
+
const r = b(e);
|
|
59
|
+
v(() => {
|
|
60
|
+
const n = k(r.current)().pipe(
|
|
61
|
+
F((u) => (console.error(u), _))
|
|
62
62
|
).subscribe();
|
|
63
63
|
return () => {
|
|
64
64
|
n.unsubscribe();
|
|
65
65
|
};
|
|
66
66
|
}, [...t, r]);
|
|
67
67
|
}
|
|
68
|
-
const
|
|
69
|
-
const t =
|
|
70
|
-
return t.current || (t.current = e()),
|
|
68
|
+
const K = (e) => {
|
|
69
|
+
const t = $(void 0);
|
|
70
|
+
return t.current || (t.current = e()), v(() => {
|
|
71
71
|
process.env.NODE_ENV;
|
|
72
72
|
}, []), t;
|
|
73
|
-
},
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
const r = _(() => new z()), n = E(!1), s = v(e), c = v(t);
|
|
78
|
-
return b(() => (n.current && (r.current = new z(), n.current = !1), () => {
|
|
79
|
-
if (!c.current) {
|
|
80
|
-
n.current = !0;
|
|
81
|
-
return;
|
|
82
|
-
}
|
|
83
|
-
n.current || (s.current != null && s.current(), r.current.complete(), n.current = !0);
|
|
84
|
-
}), [c, s, r]), r;
|
|
85
|
-
}, ke = () => {
|
|
86
|
-
const e = ie(), t = h((r) => {
|
|
87
|
-
e.current.next(r);
|
|
88
|
-
}, []);
|
|
89
|
-
return [e.current, t];
|
|
90
|
-
}, j = (e) => {
|
|
91
|
-
const t = _(() => new F(e)), r = E(!1), n = E(e);
|
|
92
|
-
return r.current && (t.current = new F(n.current), r.current = !1), b(() => () => {
|
|
93
|
-
r.current || (t.current.complete(), r.current = !0);
|
|
94
|
-
}, [t]), t.current;
|
|
95
|
-
}, ot = (e) => {
|
|
96
|
-
const t = j(e), r = v(t), n = h(
|
|
97
|
-
(s) => {
|
|
98
|
-
t.next(s);
|
|
73
|
+
}, z = (e) => K(e).current, ot = (e) => {
|
|
74
|
+
const t = z(() => new E(e)), r = b(t), n = h(
|
|
75
|
+
(u) => {
|
|
76
|
+
t.next(u);
|
|
99
77
|
},
|
|
100
78
|
[t]
|
|
101
79
|
);
|
|
102
80
|
return [r.current, n, t.getValue()];
|
|
103
|
-
},
|
|
104
|
-
const t =
|
|
105
|
-
return
|
|
81
|
+
}, W = (e) => {
|
|
82
|
+
const t = z(() => new E(e));
|
|
83
|
+
return v(() => {
|
|
106
84
|
t.next(e);
|
|
107
85
|
}, [e, t]), t;
|
|
108
86
|
};
|
|
109
87
|
function it(e, t, r = []) {
|
|
110
|
-
const n = t != null && !Array.isArray(t) ? t : {},
|
|
111
|
-
n.onError ?? ((
|
|
112
|
-
console.error(
|
|
88
|
+
const n = t != null && !Array.isArray(t) ? t : {}, u = n.retry ?? !0, c = b(
|
|
89
|
+
n.onError ?? ((s) => {
|
|
90
|
+
console.error(s);
|
|
113
91
|
})
|
|
114
|
-
),
|
|
115
|
-
() =>
|
|
116
|
-
|
|
117
|
-
throw c.current(
|
|
92
|
+
), a = h(() => k(e)(), r), l = h(
|
|
93
|
+
() => a().pipe(
|
|
94
|
+
F((s) => {
|
|
95
|
+
throw c.current(s), s;
|
|
118
96
|
}),
|
|
119
|
-
|
|
97
|
+
u ? we() : ne
|
|
120
98
|
),
|
|
121
|
-
[
|
|
99
|
+
[a, u, c]
|
|
122
100
|
);
|
|
123
|
-
|
|
101
|
+
_e(l, r);
|
|
124
102
|
}
|
|
125
|
-
const
|
|
126
|
-
class
|
|
103
|
+
const ke = Symbol("SIGNAL_RESET");
|
|
104
|
+
class ye extends E {
|
|
127
105
|
constructor(r) {
|
|
128
106
|
super(r.default);
|
|
129
|
-
|
|
130
|
-
if (r ===
|
|
107
|
+
I(this, "update", (r) => {
|
|
108
|
+
if (r === ke)
|
|
131
109
|
super.next(this.config.default);
|
|
132
110
|
else if (typeof r == "function") {
|
|
133
111
|
const n = r;
|
|
@@ -138,7 +116,7 @@ class le extends F {
|
|
|
138
116
|
/**
|
|
139
117
|
* @deprecated Use `next` instead
|
|
140
118
|
*/
|
|
141
|
-
|
|
119
|
+
I(this, "setValue", this.update.bind(this));
|
|
142
120
|
this.config = r;
|
|
143
121
|
}
|
|
144
122
|
/**
|
|
@@ -151,39 +129,37 @@ class le extends F {
|
|
|
151
129
|
return this.config.key;
|
|
152
130
|
}
|
|
153
131
|
}
|
|
154
|
-
class
|
|
132
|
+
class q {
|
|
155
133
|
constructor(t) {
|
|
156
134
|
this.config = t;
|
|
157
135
|
}
|
|
158
136
|
}
|
|
159
137
|
function lt(e = {}) {
|
|
160
|
-
return new
|
|
138
|
+
return new ye({
|
|
161
139
|
key: void 0,
|
|
162
140
|
...e,
|
|
163
141
|
default: e.default ?? void 0
|
|
164
142
|
});
|
|
165
143
|
}
|
|
166
144
|
function ft(e) {
|
|
167
|
-
return new
|
|
145
|
+
return new q(e);
|
|
168
146
|
}
|
|
169
147
|
const yt = () => {
|
|
170
|
-
const e =
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
}, je = (e) => {
|
|
177
|
-
b(e, []);
|
|
148
|
+
const e = K(() => new Y(1)), [t, r] = Q(!1);
|
|
149
|
+
return t && (e.current = new Y(1), r(!1)), v(() => () => {
|
|
150
|
+
e.current.next(void 0), r(!0);
|
|
151
|
+
}, [e]), e.current;
|
|
152
|
+
}, He = (e) => {
|
|
153
|
+
v(e, []);
|
|
178
154
|
}, dt = (e) => {
|
|
179
|
-
|
|
155
|
+
He(() => {
|
|
180
156
|
e();
|
|
181
157
|
});
|
|
182
158
|
};
|
|
183
|
-
function
|
|
159
|
+
function Ke(e, t) {
|
|
184
160
|
return Math.min(e, t);
|
|
185
161
|
}
|
|
186
|
-
function
|
|
162
|
+
function ze(e, t) {
|
|
187
163
|
return 2 ** e * t;
|
|
188
164
|
}
|
|
189
165
|
function mt(e) {
|
|
@@ -191,79 +167,84 @@ function mt(e) {
|
|
|
191
167
|
retry: t,
|
|
192
168
|
retryDelay: r,
|
|
193
169
|
retryAfterDelay: n,
|
|
194
|
-
retryAfter:
|
|
195
|
-
} = e, c = typeof t != "function" ? t === !1 ? 0 : t === !0 ? Number.POSITIVE_INFINITY : t ?? Number.POSITIVE_INFINITY : Number.POSITIVE_INFINITY,
|
|
170
|
+
retryAfter: u = () => g(!0)
|
|
171
|
+
} = e, c = typeof t != "function" ? t === !1 ? 0 : t === !0 ? Number.POSITIVE_INFINITY : t ?? Number.POSITIVE_INFINITY : Number.POSITIVE_INFINITY, a = typeof t == "function" ? (
|
|
196
172
|
// ? (attempt: number, error: TError) => of(retry(attempt, error))
|
|
197
173
|
t
|
|
198
|
-
) : () => !0, l = typeof r == "number" ? r : 100,
|
|
174
|
+
) : () => !0, l = typeof r == "number" ? r : 100, s = {
|
|
199
175
|
...e
|
|
200
176
|
}, {
|
|
201
177
|
maxInterval: o = Number.POSITIVE_INFINITY,
|
|
202
178
|
resetOnSuccess: f = !1,
|
|
203
|
-
backoffDelay: i =
|
|
204
|
-
} =
|
|
205
|
-
return (
|
|
206
|
-
let
|
|
207
|
-
const
|
|
208
|
-
return
|
|
209
|
-
|
|
210
|
-
var
|
|
211
|
-
if (
|
|
212
|
-
const S = (
|
|
179
|
+
backoffDelay: i = ze
|
|
180
|
+
} = s;
|
|
181
|
+
return (d) => D(() => {
|
|
182
|
+
let p = 0;
|
|
183
|
+
const m = (y, S) => y < c ? a(y, S) : !1;
|
|
184
|
+
return d.pipe(
|
|
185
|
+
U((y) => {
|
|
186
|
+
var w;
|
|
187
|
+
if (p++, !m(p - 1, y)) throw y;
|
|
188
|
+
const S = (w = e.caughtError) == null ? void 0 : w.call(e, p, y);
|
|
213
189
|
if (!S) throw y;
|
|
214
190
|
return S.pipe(
|
|
215
|
-
|
|
216
|
-
(
|
|
217
|
-
|
|
218
|
-
|
|
191
|
+
A(
|
|
192
|
+
(R) => C(
|
|
193
|
+
g(R),
|
|
194
|
+
P(() => y)
|
|
219
195
|
)
|
|
220
196
|
)
|
|
221
197
|
);
|
|
222
198
|
}),
|
|
223
|
-
|
|
199
|
+
Ae((y) => y.pipe(
|
|
224
200
|
Oe((S) => {
|
|
225
|
-
const
|
|
226
|
-
return
|
|
201
|
+
const w = p - 1;
|
|
202
|
+
return u().pipe(
|
|
227
203
|
qe(),
|
|
228
|
-
|
|
229
|
-
() =>
|
|
230
|
-
|
|
231
|
-
i(
|
|
204
|
+
A(
|
|
205
|
+
() => m(w, S) ? Ie(
|
|
206
|
+
Ke(
|
|
207
|
+
i(w, l),
|
|
232
208
|
o
|
|
233
209
|
)
|
|
234
210
|
).pipe(
|
|
235
|
-
|
|
236
|
-
) :
|
|
211
|
+
A((R) => n && !n(w, S) ? P(() => S) : g(R))
|
|
212
|
+
) : P(() => S)
|
|
237
213
|
)
|
|
238
214
|
);
|
|
239
215
|
})
|
|
240
216
|
)),
|
|
241
|
-
|
|
217
|
+
U((y) => {
|
|
242
218
|
if (e.catchError)
|
|
243
|
-
return e.catchError(
|
|
219
|
+
return e.catchError(p, y);
|
|
244
220
|
throw y;
|
|
245
221
|
}),
|
|
246
|
-
|
|
247
|
-
f && (
|
|
222
|
+
Qe(() => {
|
|
223
|
+
f && (p = 0);
|
|
248
224
|
})
|
|
249
225
|
);
|
|
250
226
|
});
|
|
251
227
|
}
|
|
252
|
-
function
|
|
228
|
+
function gt(e) {
|
|
253
229
|
return e != null;
|
|
254
230
|
}
|
|
255
|
-
const
|
|
256
|
-
class
|
|
231
|
+
const pt = (e, t) => e.length === t.length && e.every((r, n) => r === t[n]), St = typeof window > "u" || "Deno" in window;
|
|
232
|
+
class X {
|
|
257
233
|
constructor() {
|
|
234
|
+
/**
|
|
235
|
+
* items only get added as they are created. The only time we should cleanup
|
|
236
|
+
* are on context destroy. This is to ensure later re-use of virtual signals
|
|
237
|
+
* return the same persisted state.
|
|
238
|
+
*/
|
|
258
239
|
// biome-ignore lint/suspicious/noExplicitAny: <explanation>
|
|
259
|
-
|
|
260
|
-
|
|
240
|
+
I(this, "signals", new E(/* @__PURE__ */ new Map()));
|
|
241
|
+
I(this, "isDestroyed", !1);
|
|
261
242
|
}
|
|
262
243
|
getOrCreateSignal(t) {
|
|
263
244
|
const r = this.signals.value.get(t);
|
|
264
245
|
if (r)
|
|
265
246
|
return r;
|
|
266
|
-
const n = new
|
|
247
|
+
const n = new ye({ ...t.config, key: void 0 });
|
|
267
248
|
return this.signals.value.set(t, n), this.signals.next(this.signals.value), n;
|
|
268
249
|
}
|
|
269
250
|
destroy() {
|
|
@@ -272,17 +253,20 @@ class G {
|
|
|
272
253
|
}), this.signals.value.clear(), this.signals.complete(), this.isDestroyed = !0;
|
|
273
254
|
}
|
|
274
255
|
}
|
|
275
|
-
const
|
|
256
|
+
const de = ee(void 0), ht = te(
|
|
276
257
|
({ children: e }) => {
|
|
277
|
-
const t =
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
258
|
+
const t = K(
|
|
259
|
+
() => new X()
|
|
260
|
+
), r = t.current, [n, u] = Q(!1);
|
|
261
|
+
n && (t.current = new X(), u(!1));
|
|
262
|
+
const c = B(() => r, [r]);
|
|
263
|
+
return v(() => () => {
|
|
264
|
+
var a;
|
|
265
|
+
(a = t.current) == null || a.destroy(), u(!0);
|
|
266
|
+
}, [t]), /* @__PURE__ */ ie(de.Provider, { value: c, children: e });
|
|
283
267
|
}
|
|
284
|
-
),
|
|
285
|
-
const t =
|
|
268
|
+
), me = () => re(de), Le = (e) => {
|
|
269
|
+
const t = me();
|
|
286
270
|
if (!t) {
|
|
287
271
|
if (e)
|
|
288
272
|
throw new Error(
|
|
@@ -291,7 +275,7 @@ const fe = X(void 0), St = Z(
|
|
|
291
275
|
return;
|
|
292
276
|
}
|
|
293
277
|
const r = t.signals;
|
|
294
|
-
return
|
|
278
|
+
return H(
|
|
295
279
|
() => r.pipe(
|
|
296
280
|
N(
|
|
297
281
|
() => e ? t.getOrCreateSignal(e) : void 0
|
|
@@ -303,24 +287,24 @@ const fe = X(void 0), St = Z(
|
|
|
303
287
|
[r]
|
|
304
288
|
);
|
|
305
289
|
};
|
|
306
|
-
function
|
|
307
|
-
const t =
|
|
308
|
-
if (e instanceof
|
|
290
|
+
function L(e) {
|
|
291
|
+
const t = me();
|
|
292
|
+
if (e instanceof q && !t)
|
|
309
293
|
throw new Error(
|
|
310
294
|
"useSignalValue must be used within a SignalContextProvider"
|
|
311
295
|
);
|
|
312
|
-
return
|
|
313
|
-
e instanceof
|
|
296
|
+
return Le(
|
|
297
|
+
e instanceof q ? e : void 0
|
|
314
298
|
) ?? e;
|
|
315
299
|
}
|
|
316
|
-
function
|
|
317
|
-
const r =
|
|
318
|
-
return
|
|
300
|
+
function Je(e, t) {
|
|
301
|
+
const r = b(t), n = L(e);
|
|
302
|
+
return H(
|
|
319
303
|
() => {
|
|
320
|
-
const
|
|
304
|
+
const u = r.current ?? ((a) => a);
|
|
321
305
|
return n.pipe(
|
|
322
|
-
N(
|
|
323
|
-
|
|
306
|
+
N(u),
|
|
307
|
+
se()
|
|
324
308
|
);
|
|
325
309
|
},
|
|
326
310
|
{
|
|
@@ -329,11 +313,11 @@ function Le(e, t) {
|
|
|
329
313
|
[n]
|
|
330
314
|
);
|
|
331
315
|
}
|
|
332
|
-
function
|
|
333
|
-
return
|
|
316
|
+
function Ye(e) {
|
|
317
|
+
return L(e).update;
|
|
334
318
|
}
|
|
335
319
|
function vt(e) {
|
|
336
|
-
const t =
|
|
320
|
+
const t = L(e), r = Je(e), n = Ye(e);
|
|
337
321
|
return [r, n, t];
|
|
338
322
|
}
|
|
339
323
|
const bt = (e) => ({
|
|
@@ -349,33 +333,33 @@ const bt = (e) => ({
|
|
|
349
333
|
},
|
|
350
334
|
clear: async () => {
|
|
351
335
|
}
|
|
352
|
-
}),
|
|
336
|
+
}), O = (e) => {
|
|
353
337
|
if (!(!e || typeof e != "object"))
|
|
354
338
|
return e;
|
|
355
|
-
},
|
|
339
|
+
}, je = ({
|
|
356
340
|
adapter: e,
|
|
357
341
|
key: t
|
|
358
342
|
}) => ({
|
|
359
343
|
clear: async () => await e.removeItem(t),
|
|
360
344
|
removeItem: async (r) => {
|
|
361
|
-
const n = await e.getItem(t), { [r]:
|
|
345
|
+
const n = await e.getItem(t), { [r]: u, ...c } = (
|
|
362
346
|
// biome-ignore lint/suspicious/noExplicitAny: <explanation>
|
|
363
|
-
|
|
347
|
+
O(n) ?? {}
|
|
364
348
|
);
|
|
365
349
|
await e.setItem(t, c);
|
|
366
350
|
},
|
|
367
351
|
getItem: async (r) => {
|
|
368
|
-
const n = await e.getItem(t),
|
|
369
|
-
if (r in
|
|
370
|
-
return
|
|
352
|
+
const n = await e.getItem(t), u = O(n) ?? {};
|
|
353
|
+
if (r in u)
|
|
354
|
+
return u[r];
|
|
371
355
|
},
|
|
372
356
|
setItem: async (r, n) => {
|
|
373
|
-
const
|
|
357
|
+
const u = await e.getItem(t), c = O(u) ?? {};
|
|
374
358
|
await e.setItem(t, { ...c, [r]: n });
|
|
375
359
|
}
|
|
376
360
|
}), Ue = ({
|
|
377
361
|
key: e
|
|
378
|
-
} = {}) => e ?
|
|
362
|
+
} = {}) => e ? je({
|
|
379
363
|
adapter: Ue(),
|
|
380
364
|
key: e
|
|
381
365
|
}) : {
|
|
@@ -402,13 +386,13 @@ function Ge(e, t) {
|
|
|
402
386
|
const r = Object.keys(e), n = Object.keys(t);
|
|
403
387
|
if (r.length !== n.length)
|
|
404
388
|
return !1;
|
|
405
|
-
for (const
|
|
406
|
-
if (!t.hasOwnProperty(
|
|
389
|
+
for (const u of r)
|
|
390
|
+
if (!t.hasOwnProperty(u) || e[u] !== t[u])
|
|
407
391
|
return !1;
|
|
408
392
|
return !0;
|
|
409
393
|
}
|
|
410
|
-
const
|
|
411
|
-
if (typeof e == "object" && e !== null &&
|
|
394
|
+
const x = "__reactjrx", We = (e) => {
|
|
395
|
+
if (typeof e == "object" && e !== null && x in e && e[x] === x)
|
|
412
396
|
return e;
|
|
413
397
|
}, Xe = ({
|
|
414
398
|
adapter: e,
|
|
@@ -416,7 +400,7 @@ const V = "__reactjrx", We = (e) => {
|
|
|
416
400
|
}) => {
|
|
417
401
|
const { signal: r, version: n } = t, c = {
|
|
418
402
|
value: r.getValue(),
|
|
419
|
-
[
|
|
403
|
+
[x]: x,
|
|
420
404
|
migrationVersion: n
|
|
421
405
|
};
|
|
422
406
|
return process.env.NODE_ENV === "development" && console.log(
|
|
@@ -424,29 +408,29 @@ const V = "__reactjrx", We = (e) => {
|
|
|
424
408
|
"Persist value",
|
|
425
409
|
c,
|
|
426
410
|
`for signal ${r.config.key}`
|
|
427
|
-
),
|
|
428
|
-
|
|
411
|
+
), V(e.setItem(r.config.key, c)).pipe(
|
|
412
|
+
F((a) => (console.error(a), g(null)))
|
|
429
413
|
);
|
|
430
414
|
};
|
|
431
415
|
function Ze({
|
|
432
416
|
adapter: e,
|
|
433
417
|
config: t
|
|
434
418
|
}) {
|
|
435
|
-
const { hydrate: r = ({ value: c }) => c, signal: n, version:
|
|
436
|
-
return
|
|
437
|
-
|
|
438
|
-
const
|
|
439
|
-
if (!
|
|
440
|
-
const l = typeof
|
|
441
|
-
if (l ||
|
|
442
|
-
return
|
|
443
|
-
const o =
|
|
419
|
+
const { hydrate: r = ({ value: c }) => c, signal: n, version: u } = t;
|
|
420
|
+
return V(e.getItem(n.config.key)).pipe(
|
|
421
|
+
M((c) => {
|
|
422
|
+
const a = We(c);
|
|
423
|
+
if (!a) return g(c);
|
|
424
|
+
const l = typeof a.migrationVersion != "number", s = a.migrationVersion !== void 0 && u > a.migrationVersion;
|
|
425
|
+
if (l || s || a.value === void 0)
|
|
426
|
+
return g(c);
|
|
427
|
+
const o = a.value;
|
|
444
428
|
return process.env.NODE_ENV === "development" && console.log(
|
|
445
429
|
"[reactjrx][state][persistance]:",
|
|
446
430
|
"Hydrate value",
|
|
447
|
-
|
|
431
|
+
a,
|
|
448
432
|
`for signal ${n.config.key}`
|
|
449
|
-
), n.setValue(r({ value: o, version:
|
|
433
|
+
), n.setValue(r({ value: o, version: u })), g(c);
|
|
450
434
|
})
|
|
451
435
|
);
|
|
452
436
|
}
|
|
@@ -455,30 +439,30 @@ function Be({
|
|
|
455
439
|
onHydrated: t,
|
|
456
440
|
adapter: r
|
|
457
441
|
}) {
|
|
458
|
-
const
|
|
442
|
+
const u = (e.length === 0 ? g([]) : Ee(
|
|
459
443
|
...e.map(
|
|
460
|
-
(
|
|
444
|
+
(a) => Ze({
|
|
461
445
|
adapter: r,
|
|
462
|
-
config:
|
|
446
|
+
config: a
|
|
463
447
|
})
|
|
464
448
|
)
|
|
465
449
|
)).pipe(
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
), c =
|
|
470
|
-
|
|
471
|
-
() =>
|
|
450
|
+
T(t),
|
|
451
|
+
F((a) => (console.error("Unable to hydrate", a), _)),
|
|
452
|
+
ue()
|
|
453
|
+
), c = u.pipe(
|
|
454
|
+
M(
|
|
455
|
+
() => C(
|
|
472
456
|
...e.map(
|
|
473
|
-
(
|
|
474
|
-
|
|
457
|
+
(a) => a.signal.pipe(
|
|
458
|
+
xe(500, Ve, {
|
|
475
459
|
trailing: !0
|
|
476
460
|
}),
|
|
477
|
-
|
|
478
|
-
() =>
|
|
461
|
+
M(
|
|
462
|
+
() => V(
|
|
479
463
|
Xe({
|
|
480
464
|
adapter: r,
|
|
481
|
-
config:
|
|
465
|
+
config: a
|
|
482
466
|
})
|
|
483
467
|
)
|
|
484
468
|
)
|
|
@@ -487,8 +471,8 @@ function Be({
|
|
|
487
471
|
)
|
|
488
472
|
)
|
|
489
473
|
);
|
|
490
|
-
return
|
|
491
|
-
|
|
474
|
+
return C(
|
|
475
|
+
u.pipe(
|
|
492
476
|
N(() => ({
|
|
493
477
|
type: "hydrated"
|
|
494
478
|
}))
|
|
@@ -500,21 +484,21 @@ function Be({
|
|
|
500
484
|
)
|
|
501
485
|
);
|
|
502
486
|
}
|
|
503
|
-
function
|
|
487
|
+
function wt({
|
|
504
488
|
entries: e = [],
|
|
505
489
|
onHydrated: t,
|
|
506
490
|
adapter: r
|
|
507
491
|
}) {
|
|
508
|
-
const n =
|
|
509
|
-
return
|
|
510
|
-
() =>
|
|
511
|
-
|
|
512
|
-
|
|
492
|
+
const n = b(t), u = W(r), c = W(e);
|
|
493
|
+
return H(
|
|
494
|
+
() => u.pipe(
|
|
495
|
+
M((l) => l ? C(
|
|
496
|
+
g({ type: "reset" }),
|
|
513
497
|
c.pipe(
|
|
514
|
-
|
|
515
|
-
(
|
|
498
|
+
Ce(
|
|
499
|
+
(s) => Be({
|
|
516
500
|
adapter: l,
|
|
517
|
-
entries:
|
|
501
|
+
entries: s,
|
|
518
502
|
onHydrated: () => {
|
|
519
503
|
var o;
|
|
520
504
|
(o = n.current) == null || o.call(n);
|
|
@@ -522,52 +506,52 @@ function It({
|
|
|
522
506
|
})
|
|
523
507
|
)
|
|
524
508
|
)
|
|
525
|
-
) :
|
|
509
|
+
) : g({ type: "reset" }))
|
|
526
510
|
).pipe(
|
|
527
|
-
|
|
528
|
-
(l,
|
|
511
|
+
Me(
|
|
512
|
+
(l, s) => s.type === "reset" ? { isHydrated: !1 } : s.type === "hydrated" ? { isHydrated: !0 } : l,
|
|
529
513
|
{ isHydrated: !1 }
|
|
530
514
|
)
|
|
531
515
|
),
|
|
532
516
|
{ defaultValue: { isHydrated: !1 }, compareFn: Ge },
|
|
533
|
-
[
|
|
517
|
+
[u, c]
|
|
534
518
|
);
|
|
535
519
|
}
|
|
536
520
|
class et {
|
|
537
521
|
constructor() {
|
|
538
|
-
|
|
522
|
+
I(this, "queryMap", /* @__PURE__ */ new Map());
|
|
539
523
|
}
|
|
540
524
|
getQuery(t) {
|
|
541
525
|
return this.queryMap.get(t);
|
|
542
526
|
}
|
|
543
527
|
setQuery(t, r, n) {
|
|
544
|
-
const
|
|
528
|
+
const u = le(t), c = r.pipe(
|
|
545
529
|
/**
|
|
546
530
|
* abort signal is triggered on:
|
|
547
531
|
* - manual cancellation from user
|
|
548
532
|
* - unmounting the component
|
|
549
533
|
* @see https://tanstack.com/query/latest/docs/framework/react/guides/query-cancellation
|
|
550
534
|
*/
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
),
|
|
535
|
+
Fe(ae(n, "abort")),
|
|
536
|
+
ue()
|
|
537
|
+
), a = {
|
|
554
538
|
query$: c,
|
|
555
539
|
signal: n,
|
|
556
540
|
sub: void 0,
|
|
557
541
|
isCompleted: !1,
|
|
558
542
|
lastData: void 0
|
|
559
543
|
};
|
|
560
|
-
this.queryMap.set(
|
|
544
|
+
this.queryMap.set(u, a);
|
|
561
545
|
const l = c.subscribe({
|
|
562
|
-
next: (
|
|
563
|
-
const o = this.queryMap.get(
|
|
564
|
-
o && (o.lastData = { value:
|
|
546
|
+
next: (s) => {
|
|
547
|
+
const o = this.queryMap.get(u);
|
|
548
|
+
o && (o.lastData = { value: s });
|
|
565
549
|
},
|
|
566
550
|
complete: () => {
|
|
567
|
-
this.deleteQuery(
|
|
551
|
+
this.deleteQuery(u);
|
|
568
552
|
}
|
|
569
553
|
});
|
|
570
|
-
return
|
|
554
|
+
return a.sub = l, a;
|
|
571
555
|
}
|
|
572
556
|
deleteQuery(t) {
|
|
573
557
|
const r = this.queryMap.get(t);
|
|
@@ -579,18 +563,18 @@ class et {
|
|
|
579
563
|
});
|
|
580
564
|
}
|
|
581
565
|
}
|
|
582
|
-
const
|
|
566
|
+
const ge = ee(void 0), It = te(
|
|
583
567
|
({
|
|
584
568
|
children: e,
|
|
585
569
|
client: t
|
|
586
570
|
}) => {
|
|
587
|
-
const [r] =
|
|
588
|
-
return
|
|
571
|
+
const [r] = Q(() => t ?? new et());
|
|
572
|
+
return v(() => () => {
|
|
589
573
|
r.destroy();
|
|
590
|
-
}, [r]), /* @__PURE__ */
|
|
574
|
+
}, [r]), /* @__PURE__ */ ie(ge.Provider, { value: r, children: e });
|
|
591
575
|
}
|
|
592
576
|
), tt = () => {
|
|
593
|
-
const e =
|
|
577
|
+
const e = re(ge);
|
|
594
578
|
if (!e)
|
|
595
579
|
throw new Error(
|
|
596
580
|
"useReactJrxQueryClient must be used within a ReactJrxQueryProvider"
|
|
@@ -598,36 +582,36 @@ const de = X(void 0), wt = Z(
|
|
|
598
582
|
return e;
|
|
599
583
|
};
|
|
600
584
|
function Et(e, t) {
|
|
601
|
-
const r =
|
|
602
|
-
return
|
|
585
|
+
const r = fe(t), n = tt();
|
|
586
|
+
return De(
|
|
603
587
|
{
|
|
604
588
|
...e,
|
|
605
|
-
queryFn: (
|
|
606
|
-
const o = () =>
|
|
607
|
-
() => typeof e.queryFn == "function" ? e.queryFn(
|
|
608
|
-
), f =
|
|
589
|
+
queryFn: (a) => new Promise((l, s) => {
|
|
590
|
+
const o = () => D(
|
|
591
|
+
() => typeof e.queryFn == "function" ? e.queryFn(a) : e.queryFn
|
|
592
|
+
), f = le(a.queryKey), i = n.getQuery(f) ?? n.setQuery(a.queryKey, o(), a.signal);
|
|
609
593
|
i.query$.pipe(
|
|
610
|
-
|
|
594
|
+
ce(1),
|
|
611
595
|
/**
|
|
612
596
|
* If several values are emitted during this delay, we will only
|
|
613
597
|
* keep the last value. This is unfortunate but it's the best we can do
|
|
614
598
|
* for now.
|
|
615
599
|
*/
|
|
616
|
-
|
|
600
|
+
Ne(1)
|
|
617
601
|
).subscribe({
|
|
618
|
-
error: (
|
|
602
|
+
error: (p) => s(p),
|
|
619
603
|
complete: () => {
|
|
620
604
|
if ((i == null ? void 0 : i.lastData) === void 0)
|
|
621
605
|
return i.signal.aborted || (console.log(
|
|
622
606
|
`cancelled due to stream completing without data for query ${f}`,
|
|
623
607
|
i == null ? void 0 : i.lastData
|
|
624
608
|
), r.cancelQueries({
|
|
625
|
-
queryKey:
|
|
609
|
+
queryKey: a.queryKey,
|
|
626
610
|
exact: !0
|
|
627
611
|
})), l(void 0);
|
|
628
612
|
l(i.lastData.value), (i == null ? void 0 : i.isCompleted) === !1 && setTimeout(() => {
|
|
629
613
|
r == null || r.refetchQueries({
|
|
630
|
-
queryKey:
|
|
614
|
+
queryKey: a.queryKey,
|
|
631
615
|
exact: !0
|
|
632
616
|
});
|
|
633
617
|
});
|
|
@@ -638,29 +622,31 @@ function Et(e, t) {
|
|
|
638
622
|
t
|
|
639
623
|
);
|
|
640
624
|
}
|
|
641
|
-
function
|
|
642
|
-
const r =
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
625
|
+
function pe(e, t) {
|
|
626
|
+
const r = z(
|
|
627
|
+
() => new E({
|
|
628
|
+
status: "idle",
|
|
629
|
+
isPending: !1,
|
|
630
|
+
isError: !1,
|
|
631
|
+
isSuccess: !1,
|
|
632
|
+
isIdle: !0
|
|
633
|
+
})
|
|
634
|
+
), n = Te(
|
|
649
635
|
{
|
|
650
636
|
...e,
|
|
651
637
|
mutationFn: (o) => {
|
|
652
638
|
let f;
|
|
653
|
-
return new Promise((i,
|
|
654
|
-
(typeof e.mutationFn == "function" ? e.mutationFn(o) : e.mutationFn).pipe(
|
|
655
|
-
next: (
|
|
656
|
-
f = { value:
|
|
639
|
+
return new Promise((i, d) => {
|
|
640
|
+
(typeof e.mutationFn == "function" ? e.mutationFn(o) : e.mutationFn).pipe(ce(1)).subscribe({
|
|
641
|
+
next: (m) => {
|
|
642
|
+
f = { value: m };
|
|
657
643
|
},
|
|
658
|
-
error: (
|
|
659
|
-
m
|
|
644
|
+
error: (m) => {
|
|
645
|
+
d(m);
|
|
660
646
|
},
|
|
661
647
|
complete: () => {
|
|
662
648
|
if (f === void 0)
|
|
663
|
-
return
|
|
649
|
+
return d(new Error("Stream completed without any data"));
|
|
664
650
|
i(f.value);
|
|
665
651
|
}
|
|
666
652
|
});
|
|
@@ -668,125 +654,163 @@ function me(e, t) {
|
|
|
668
654
|
}
|
|
669
655
|
},
|
|
670
656
|
t
|
|
671
|
-
), { status:
|
|
672
|
-
return
|
|
657
|
+
), { status: u, isPending: c, isError: a, isSuccess: l, isIdle: s } = n;
|
|
658
|
+
return v(() => {
|
|
673
659
|
r.next({
|
|
674
|
-
status:
|
|
660
|
+
status: u,
|
|
675
661
|
isPending: c,
|
|
676
|
-
isError:
|
|
662
|
+
isError: a,
|
|
677
663
|
isSuccess: l,
|
|
678
|
-
isIdle:
|
|
664
|
+
isIdle: s
|
|
679
665
|
});
|
|
680
|
-
}, [
|
|
666
|
+
}, [u, c, a, l, s, r]), { ...n, state$: r };
|
|
681
667
|
}
|
|
682
|
-
|
|
683
|
-
|
|
668
|
+
class Z extends Error {
|
|
669
|
+
constructor(t = "Mutation canceled") {
|
|
670
|
+
super(t), this.name = "SwitchMutationCancelError";
|
|
671
|
+
}
|
|
672
|
+
}
|
|
673
|
+
function xt(e, t) {
|
|
674
|
+
const r = $(new AbortController()), { mutate: n, mutateAsync: u, ...c } = pe(
|
|
684
675
|
{
|
|
685
676
|
...e,
|
|
686
|
-
mutationFn: (
|
|
677
|
+
mutationFn: ({ variables: s, abort: o }) => {
|
|
678
|
+
if (o.aborted)
|
|
679
|
+
throw new Z();
|
|
680
|
+
const f = typeof e.mutationFn == "function" ? e.mutationFn(s) : e.mutationFn;
|
|
681
|
+
return C(
|
|
682
|
+
f,
|
|
683
|
+
ae(o, "abort").pipe(
|
|
684
|
+
T(() => {
|
|
685
|
+
throw new Z();
|
|
686
|
+
}),
|
|
687
|
+
$e()
|
|
688
|
+
)
|
|
689
|
+
).pipe(oe(), Re(null));
|
|
690
|
+
},
|
|
691
|
+
onMutate: ({ variables: s }) => {
|
|
692
|
+
var o;
|
|
693
|
+
return (o = e.onMutate) == null ? void 0 : o.call(e, s);
|
|
694
|
+
},
|
|
695
|
+
onSuccess: (s, { variables: o }, f) => {
|
|
696
|
+
var i;
|
|
697
|
+
return (i = e.onSuccess) == null ? void 0 : i.call(e, s, o, f);
|
|
698
|
+
},
|
|
699
|
+
onError: (s, { variables: o }, ...f) => {
|
|
700
|
+
var i;
|
|
701
|
+
return (i = e.onError) == null ? void 0 : i.call(e, s, o, ...f);
|
|
702
|
+
},
|
|
703
|
+
onSettled: (s, o, { variables: f }, i) => {
|
|
704
|
+
var d;
|
|
705
|
+
return (d = e.onSettled) == null ? void 0 : d.call(e, s, o, f, i);
|
|
706
|
+
}
|
|
687
707
|
},
|
|
688
708
|
t
|
|
689
|
-
), l = h(
|
|
690
|
-
(o) => (n(), s(o)),
|
|
691
|
-
[s, n]
|
|
692
709
|
), a = h(
|
|
693
|
-
(
|
|
694
|
-
|
|
710
|
+
(s) => (r.current.abort(), r.current = new AbortController(), n({
|
|
711
|
+
variables: s,
|
|
712
|
+
abort: r.current.signal
|
|
713
|
+
})),
|
|
714
|
+
[n]
|
|
715
|
+
), l = h(
|
|
716
|
+
(s) => (r.current.abort(), r.current = new AbortController(), u({
|
|
717
|
+
variables: s,
|
|
718
|
+
abort: r.current.signal
|
|
719
|
+
})),
|
|
720
|
+
[u]
|
|
695
721
|
);
|
|
696
|
-
return { ...
|
|
722
|
+
return { ...c, mutate: a, mutateAsync: l };
|
|
697
723
|
}
|
|
698
|
-
function
|
|
699
|
-
const r =
|
|
724
|
+
function Vt(e, t) {
|
|
725
|
+
const r = fe(t), n = e.mutationKey, { mutateAsync: u, ...c } = pe(
|
|
700
726
|
{
|
|
701
727
|
...e,
|
|
702
|
-
onMutate({ variables:
|
|
728
|
+
onMutate({ variables: s }) {
|
|
703
729
|
var o;
|
|
704
|
-
return (o = e.onMutate) == null ? void 0 : o.call(e,
|
|
730
|
+
return (o = e.onMutate) == null ? void 0 : o.call(e, s);
|
|
705
731
|
},
|
|
706
|
-
onSuccess(
|
|
732
|
+
onSuccess(s, o, f) {
|
|
707
733
|
var i;
|
|
708
|
-
return (i = e.onSuccess) == null ? void 0 : i.call(e,
|
|
734
|
+
return (i = e.onSuccess) == null ? void 0 : i.call(e, s, o.variables, f);
|
|
709
735
|
},
|
|
710
|
-
onError(
|
|
736
|
+
onError(s, o, f) {
|
|
711
737
|
var i;
|
|
712
|
-
return (i = e.onError) == null ? void 0 : i.call(e,
|
|
738
|
+
return (i = e.onError) == null ? void 0 : i.call(e, s, o.variables, f);
|
|
713
739
|
},
|
|
714
|
-
onSettled(
|
|
715
|
-
var
|
|
716
|
-
return (
|
|
740
|
+
onSettled(s, o, f, i) {
|
|
741
|
+
var d;
|
|
742
|
+
return (d = e.onSettled) == null ? void 0 : d.call(e, s, o, f.variables, i);
|
|
717
743
|
},
|
|
718
|
-
mutationFn: ({ ready$:
|
|
744
|
+
mutationFn: ({ ready$: s, variables: o }) => {
|
|
719
745
|
const f = typeof e.mutationFn == "function" ? e.mutationFn(o) : e.mutationFn;
|
|
720
|
-
return
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
746
|
+
return s.pipe(
|
|
747
|
+
Pe((i) => i),
|
|
748
|
+
oe(),
|
|
749
|
+
M(() => f)
|
|
724
750
|
);
|
|
725
751
|
}
|
|
726
752
|
},
|
|
727
753
|
t
|
|
728
|
-
),
|
|
729
|
-
async (
|
|
754
|
+
), a = h(
|
|
755
|
+
async (s) => {
|
|
730
756
|
const o = r.getMutationCache().findAll({
|
|
731
757
|
mutationKey: n,
|
|
732
758
|
exact: !0
|
|
733
|
-
}), f = new
|
|
759
|
+
}), f = new E(!1), i = u({ variables: s, ready$: f });
|
|
734
760
|
return await Promise.all(
|
|
735
|
-
o.map((
|
|
761
|
+
o.map((d) => d.continue().catch(j))
|
|
736
762
|
), f.next(!0), await i.finally(() => {
|
|
737
763
|
f.complete();
|
|
738
764
|
});
|
|
739
765
|
},
|
|
740
|
-
[
|
|
766
|
+
[u, r, n]
|
|
741
767
|
), l = h(
|
|
742
|
-
(
|
|
743
|
-
|
|
768
|
+
(s) => {
|
|
769
|
+
a(s).catch(j);
|
|
744
770
|
},
|
|
745
|
-
[
|
|
771
|
+
[a]
|
|
746
772
|
);
|
|
747
|
-
return { ...c, mutate: l, mutateAsync:
|
|
773
|
+
return { ...c, mutate: l, mutateAsync: a };
|
|
748
774
|
}
|
|
749
775
|
export {
|
|
750
|
-
|
|
776
|
+
ge as Context,
|
|
751
777
|
et as QueryClient$,
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
778
|
+
It as QueryClientProvider$,
|
|
779
|
+
ke as SIGNAL_RESET,
|
|
780
|
+
ye as Signal,
|
|
781
|
+
ht as SignalContextProvider,
|
|
782
|
+
de as SignalReactContext,
|
|
783
|
+
Z as SwitchMutationCancelError,
|
|
784
|
+
q as VirtualSignal,
|
|
785
|
+
pt as arrayEqual,
|
|
759
786
|
Ue as createLocalStorageAdapter,
|
|
760
787
|
bt as createLocalforageAdapter,
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
788
|
+
ze as exponentialBackoffDelay,
|
|
789
|
+
Ke as getDelay,
|
|
790
|
+
gt as isDefined,
|
|
791
|
+
G as isPromiseLike,
|
|
792
|
+
St as isServer,
|
|
766
793
|
mt as retryBackoff,
|
|
767
794
|
lt as signal,
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
ze as useMakeOrRetrieveSignal,
|
|
795
|
+
Vt as useContactMutation$,
|
|
796
|
+
He as useEffectOnce,
|
|
797
|
+
W as useLiveBehaviorSubject,
|
|
798
|
+
b as useLiveRef,
|
|
799
|
+
Le as useMakeOrRetrieveSignal,
|
|
774
800
|
dt as useMount,
|
|
775
|
-
|
|
776
|
-
ke as useObservableCallback,
|
|
801
|
+
pe as useMutation$,
|
|
777
802
|
ot as useObservableState,
|
|
778
|
-
|
|
779
|
-
|
|
803
|
+
H as useObserve,
|
|
804
|
+
wt as usePersistSignals,
|
|
780
805
|
Et as useQuery$,
|
|
781
806
|
tt as useQueryClient$,
|
|
782
|
-
|
|
807
|
+
Ye as useSetSignal,
|
|
783
808
|
vt as useSignal,
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
De as useSubscribe,
|
|
809
|
+
me as useSignalContext,
|
|
810
|
+
Je as useSignalValue,
|
|
811
|
+
_e as useSubscribe,
|
|
788
812
|
it as useSubscribeEffect,
|
|
789
|
-
|
|
813
|
+
xt as useSwitchMutation$,
|
|
790
814
|
yt as useUnmountObservable,
|
|
791
815
|
ft as virtualSignal
|
|
792
816
|
};
|