@ahoo-wang/fetcher-react 3.5.1 → 3.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,5 @@
1
1
  import { TokenStorage, CompositeToken, CoSecJwtPayload } from '@ahoo-wang/fetcher-cosec';
2
+ export declare const ANONYMOUS_USER: CoSecJwtPayload;
2
3
  /**
3
4
  * Return type for the useSecurity hook.
4
5
  */
@@ -7,7 +8,7 @@ export interface UseSecurityReturn {
7
8
  * The current authenticated user's JWT payload, or null if not authenticated.
8
9
  * Contains user information extracted from the access token.
9
10
  */
10
- currentUser: CoSecJwtPayload | null;
11
+ currentUser: CoSecJwtPayload;
11
12
  /**
12
13
  * Boolean indicating whether the user is currently authenticated.
13
14
  * True if a valid token exists and the user is signed in, false otherwise.
@@ -1 +1 @@
1
- {"version":3,"file":"useSecurity.d.ts","sourceRoot":"","sources":["../../src/cosec/useSecurity.ts"],"names":[],"mappings":"AAeA,OAAO,EACL,YAAY,EACZ,cAAc,EACd,eAAe,EAChB,MAAM,0BAA0B,CAAC;AAElC;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,WAAW,EAAE,eAAe,GAAG,IAAI,CAAC;IAEpC;;;OAGG;IACH,aAAa,EAAE,OAAO,CAAC;IAEvB;;;OAGG;IACH,MAAM,EAAE,CAAC,cAAc,EAAE,cAAc,KAAK,IAAI,CAAC;IAEjD;;OAEG;IACH,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AACH,wBAAgB,WAAW,CAAC,YAAY,EAAE,YAAY,GAAG,iBAAiB,CAezE"}
1
+ {"version":3,"file":"useSecurity.d.ts","sourceRoot":"","sources":["../../src/cosec/useSecurity.ts"],"names":[],"mappings":"AAeA,OAAO,EACL,YAAY,EACZ,cAAc,EACd,eAAe,EAChB,MAAM,0BAA0B,CAAC;AAElC,eAAO,MAAM,cAAc,EAAE,eAE5B,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,WAAW,EAAE,eAAe,CAAC;IAE7B;;;OAGG;IACH,aAAa,EAAE,OAAO,CAAC;IAEvB;;;OAGG;IACH,MAAM,EAAE,CAAC,cAAc,EAAE,cAAc,KAAK,IAAI,CAAC;IAEjD;;OAEG;IACH,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AACH,wBAAgB,WAAW,CAAC,YAAY,EAAE,YAAY,GAAG,iBAAiB,CAezE"}
package/dist/index.es.js CHANGED
@@ -1,13 +1,13 @@
1
- var B = Object.defineProperty;
2
- var l = (r, e) => B(r, "name", { value: e, configurable: !0 });
3
- import { useRef as I, useEffect as $, useState as D, useCallback as _, useMemo as T, useReducer as H, useSyncExternalStore as X, createContext as Y, useContext as Z } from "react";
1
+ var Y = Object.defineProperty;
2
+ var l = (r, e) => Y(r, "name", { value: e, configurable: !0 });
3
+ import { useRef as I, useEffect as O, useState as D, useCallback as _, useMemo as M, useReducer as B, useSyncExternalStore as H, createContext as X, useContext as Z } from "react";
4
4
  import { c as w } from "react/compiler-runtime";
5
5
  import { jsx as ee } from "react/jsx-runtime";
6
6
  import { nameGenerator as te } from "@ahoo-wang/fetcher-eventbus";
7
7
  import { produce as re } from "immer";
8
8
  import { fetcherRegistrar as ne, getFetcher as ce, JsonResultExtractor as se } from "@ahoo-wang/fetcher";
9
9
  import { JsonEventStreamResultExtractor as oe } from "@ahoo-wang/fetcher-eventstream";
10
- function G() {
10
+ function z() {
11
11
  const r = w(3), e = I(!1);
12
12
  let t;
13
13
  r[0] === Symbol.for("react.memo_cache_sentinel") ? (t = /* @__PURE__ */ l(() => e.current, "t0"), r[0] = t) : t = r[0];
@@ -15,9 +15,9 @@ function G() {
15
15
  let s, c;
16
16
  return r[1] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ l(() => (e.current = !0, () => {
17
17
  e.current = !1;
18
- }), "t1"), c = [], r[1] = s, r[2] = c) : (s = r[1], c = r[2]), $(s, c), n;
18
+ }), "t1"), c = [], r[1] = s, r[2] = c) : (s = r[1], c = r[2]), O(s, c), n;
19
19
  }
20
- l(G, "useMounted");
20
+ l(z, "useMounted");
21
21
  function P(r) {
22
22
  const e = I(r);
23
23
  return e.current = r, e;
@@ -28,7 +28,7 @@ function le(r) {
28
28
  const [e, t] = D(
29
29
  r?.initialStatus ?? "idle"
30
30
  /* IDLE */
31
- ), [n, s] = D(void 0), [c, i] = D(void 0), o = G(), u = P(r), d = _(() => {
31
+ ), [n, s] = D(void 0), [c, i] = D(void 0), o = z(), u = P(r), d = _(() => {
32
32
  o() && (t(
33
33
  "loading"
34
34
  /* LOADING */
@@ -63,7 +63,7 @@ function le(r) {
63
63
  /* IDLE */
64
64
  ), i(void 0), s(void 0));
65
65
  }, [o]);
66
- return T(() => ({
66
+ return M(() => ({
67
67
  status: e,
68
68
  loading: e === "loading",
69
69
  result: n,
@@ -116,7 +116,7 @@ function q(r) {
116
116
  setSuccess: i,
117
117
  setError: o,
118
118
  setIdle: u
119
- } = le(r), d = G(), a = ie(), f = I(void 0), m = r?.propagateError, b = P(r?.onAbort), y = _(async () => {
119
+ } = le(r), d = z(), a = ie(), f = I(void 0), m = r?.propagateError, b = P(r?.onAbort), y = _(async () => {
120
120
  try {
121
121
  await b.current?.();
122
122
  } catch (Q) {
@@ -146,9 +146,9 @@ function q(r) {
146
146
  }, [u, d]), x = _(async () => {
147
147
  E(), f.current && (f.current.abort(), f.current = void 0, await y());
148
148
  }, [E, y]);
149
- return $(() => () => {
149
+ return O(() => () => {
150
150
  x();
151
- }, [x]), T(() => ({
151
+ }, [x]), M(() => ({
152
152
  loading: e,
153
153
  result: t,
154
154
  error: n,
@@ -159,13 +159,13 @@ function q(r) {
159
159
  }), [e, t, n, s, h, E, x]);
160
160
  }
161
161
  l(q, "useExecutePromise");
162
- function Qe() {
162
+ function Se() {
163
163
  const r = I(/* @__PURE__ */ new Map()), e = _((f) => r.current.get(f), []), t = _((f, m) => r.current.set(f, m), []), n = _((f) => r.current.has(f), []), s = _((f) => r.current.delete(f), []), c = _(() => r.current.clear(), []), i = _(() => r.current.keys(), []), o = _(() => r.current.values(), []), u = _(() => r.current.entries(), []), d = _(() => r.current[Symbol.iterator](), []), a = _((f) => (m) => {
164
164
  m ? r.current.set(f, m) : r.current.delete(f);
165
165
  }, []);
166
- return $(() => () => {
166
+ return O(() => () => {
167
167
  r.current.clear();
168
- }, []), T(() => ({
168
+ }, []), M(() => ({
169
169
  register: a,
170
170
  get: e,
171
171
  set: t,
@@ -181,8 +181,8 @@ function Qe() {
181
181
  [Symbol.iterator]: d
182
182
  }), [a, e, t, n, s, c, i, o, u, d]);
183
183
  }
184
- l(Qe, "useRefs");
185
- function M(r, e) {
184
+ l(Se, "useRefs");
185
+ function T(r, e) {
186
186
  const t = w(19);
187
187
  if (e.leading === !1 && e.trailing === !1)
188
188
  throw new Error("useDebouncedCallback: at least one of leading or trailing must be true");
@@ -216,19 +216,19 @@ function M(r, e) {
216
216
  const C = R;
217
217
  d();
218
218
  const {
219
- leading: k,
220
- trailing: U
221
- } = o.current, K = k === void 0 ? !1 : k, V = U === void 0 ? !0 : U;
222
- if (s.current = C, V && !K) {
219
+ leading: U,
220
+ trailing: k
221
+ } = o.current, K = U === void 0 ? !1 : U, N = k === void 0 ? !0 : k;
222
+ if (s.current = C, N && !K) {
223
223
  h();
224
224
  return;
225
225
  }
226
- const z = Date.now();
227
- if (K && f(z)) {
228
- b(z, C);
226
+ const V = Date.now();
227
+ if (K && f(V)) {
228
+ b(V, C);
229
229
  return;
230
230
  }
231
- V && h();
231
+ N && h();
232
232
  }, "t4"), t[8] = b, t[9] = o, t[10] = h, t[11] = f, t[12] = E) : E = t[12];
233
233
  const x = E;
234
234
  let Q;
@@ -242,16 +242,16 @@ function M(r, e) {
242
242
  let F, L;
243
243
  t[15] === Symbol.for("react.memo_cache_sentinel") ? (F = /* @__PURE__ */ l(() => () => {
244
244
  g();
245
- }, "t7"), L = [g], t[15] = F, t[16] = L) : (F = t[15], L = t[16]), $(F, L);
246
- let O;
247
- return t[17] !== x ? (O = {
245
+ }, "t7"), L = [g], t[15] = F, t[16] = L) : (F = t[15], L = t[16]), O(F, L);
246
+ let $;
247
+ return t[17] !== x ? ($ = {
248
248
  run: x,
249
249
  cancel: g,
250
250
  isPending: v
251
- }, t[17] = x, t[18] = O) : O = t[18], O;
251
+ }, t[17] = x, t[18] = $) : $ = t[18], $;
252
252
  }
253
- l(M, "useDebouncedCallback");
254
- function Se(r) {
253
+ l(T, "useDebouncedCallback");
254
+ function _e(r) {
255
255
  const e = w(10), {
256
256
  loading: t,
257
257
  result: n,
@@ -264,7 +264,7 @@ function Se(r) {
264
264
  run: d,
265
265
  cancel: a,
266
266
  isPending: f
267
- } = M(c, r.debounce);
267
+ } = T(c, r.debounce);
268
268
  let m;
269
269
  return e[0] !== o || e[1] !== a || e[2] !== s || e[3] !== f || e[4] !== t || e[5] !== i || e[6] !== n || e[7] !== d || e[8] !== u ? (m = {
270
270
  loading: t,
@@ -278,17 +278,17 @@ function Se(r) {
278
278
  isPending: f
279
279
  }, e[0] = o, e[1] = a, e[2] = s, e[3] = f, e[4] = t, e[5] = i, e[6] = n, e[7] = d, e[8] = u, e[9] = m) : m = e[9], m;
280
280
  }
281
- l(Se, "useDebouncedExecutePromise");
282
- function _e() {
283
- const [, r] = H(ae, 0);
281
+ l(_e, "useDebouncedExecutePromise");
282
+ function we() {
283
+ const [, r] = B(ae, 0);
284
284
  return r;
285
285
  }
286
- l(_e, "useForceUpdate");
286
+ l(we, "useForceUpdate");
287
287
  function ae(r) {
288
288
  return r + 1;
289
289
  }
290
290
  l(ae, "_temp");
291
- function J(r, e) {
291
+ function G(r, e) {
292
292
  const t = w(13);
293
293
  let n;
294
294
  t[0] !== r ? (n = /* @__PURE__ */ l((b) => r.addListener({
@@ -301,7 +301,7 @@ function J(r, e) {
301
301
  const b = r.get();
302
302
  return b !== null ? b : e ?? null;
303
303
  }, "t1"), t[2] = e, t[3] = r, t[4] = c) : c = t[4];
304
- const i = c, o = X(s, i, i);
304
+ const i = c, o = H(s, i, i);
305
305
  let u;
306
306
  t[5] !== r ? (u = /* @__PURE__ */ l((b) => r.set(b), "t2"), t[5] = r, t[6] = u) : u = t[6];
307
307
  const d = u;
@@ -311,9 +311,9 @@ function J(r, e) {
311
311
  let m;
312
312
  return t[9] !== f || t[10] !== d || t[11] !== o ? (m = [o, d, f], t[9] = f, t[10] = d, t[11] = o, t[12] = m) : m = t[12], m;
313
313
  }
314
- l(J, "useKeyStorage");
315
- function we(r, e) {
316
- const t = w(8), [n, s, c] = J(r, e);
314
+ l(G, "useKeyStorage");
315
+ function Fe(r, e) {
316
+ const t = w(8), [n, s, c] = G(r, e);
317
317
  let i;
318
318
  t[0] !== c || t[1] !== s || t[2] !== n ? (i = /* @__PURE__ */ l((d) => {
319
319
  const a = re(n, d);
@@ -327,14 +327,17 @@ function we(r, e) {
327
327
  let u;
328
328
  return t[4] !== c || t[5] !== o || t[6] !== n ? (u = [n, o, c], t[4] = c, t[5] = o, t[6] = n, t[7] = u) : u = t[7], u;
329
329
  }
330
- l(we, "useImmerKeyStorage");
331
- function fe(r) {
332
- const e = w(7), [t, , n] = J(r);
330
+ l(Fe, "useImmerKeyStorage");
331
+ const fe = {
332
+ sub: "anonymous"
333
+ };
334
+ function de(r) {
335
+ const e = w(7), [t, , n] = G(r);
333
336
  let s;
334
337
  e[0] !== r ? (s = /* @__PURE__ */ l((d) => {
335
338
  r.signIn(d);
336
339
  }, "t0"), e[0] = r, e[1] = s) : s = e[1];
337
- const c = s, i = t?.access?.payload ?? null, o = t?.authenticated ?? !1;
340
+ const c = s, i = t?.access?.payload ?? fe, o = t?.authenticated ?? !1;
338
341
  let u;
339
342
  return e[2] !== n || e[3] !== c || e[4] !== i || e[5] !== o ? (u = {
340
343
  currentUser: i,
@@ -343,25 +346,25 @@ function fe(r) {
343
346
  signOut: n
344
347
  }, e[2] = n, e[3] = c, e[4] = i, e[5] = o, e[6] = u) : u = e[6], u;
345
348
  }
346
- l(fe, "useSecurity");
347
- const W = Y(void 0);
348
- function Fe(r) {
349
+ l(de, "useSecurity");
350
+ const J = X(void 0);
351
+ function Re(r) {
349
352
  const e = w(3), {
350
353
  tokenStorage: t,
351
354
  children: n
352
- } = r, s = fe(t);
355
+ } = r, s = de(t);
353
356
  let c;
354
- return e[0] !== n || e[1] !== s ? (c = /* @__PURE__ */ ee(W.Provider, { value: s, children: n }), e[0] = n, e[1] = s, e[2] = c) : c = e[2], c;
357
+ return e[0] !== n || e[1] !== s ? (c = /* @__PURE__ */ ee(J.Provider, { value: s, children: n }), e[0] = n, e[1] = s, e[2] = c) : c = e[2], c;
355
358
  }
356
- l(Fe, "SecurityProvider");
357
- function Re() {
358
- const r = Z(W);
359
+ l(Re, "SecurityProvider");
360
+ function Ce() {
361
+ const r = Z(J);
359
362
  if (!r)
360
363
  throw new Error("useSecurityContext must be used within a SecurityProvider");
361
364
  return r;
362
365
  }
363
- l(Re, "useSecurityContext");
364
- function j(r) {
366
+ l(Ce, "useSecurityContext");
367
+ function W(r) {
365
368
  const e = w(21);
366
369
  let t;
367
370
  e[0] !== r ? (t = r || {}, e[0] = r, e[1] = t) : t = e[1];
@@ -380,11 +383,11 @@ function j(r) {
380
383
  e[2] !== s ? (h = ce(s), e[2] = s, e[3] = h) : h = e[3];
381
384
  const E = h;
382
385
  let x;
383
- e[4] !== E || e[5] !== y || e[6] !== d ? (x = /* @__PURE__ */ l(async (O) => {
386
+ e[4] !== E || e[5] !== y || e[6] !== d ? (x = /* @__PURE__ */ l(async ($) => {
384
387
  try {
385
388
  await d(async (R) => {
386
- O.abortController = R;
387
- const C = await E.exchange(O, y.current);
389
+ $.abortController = R;
390
+ const C = await E.exchange($, y.current);
388
391
  return b(C), await C.extractResult();
389
392
  });
390
393
  } catch (R) {
@@ -415,8 +418,8 @@ function j(r) {
415
418
  abort: F
416
419
  }, e[12] = F, e[13] = o, e[14] = m, e[15] = Q, e[16] = c, e[17] = S, e[18] = i, e[19] = u, e[20] = L) : L = e[20], L;
417
420
  }
418
- l(j, "useFetcher");
419
- function Ce(r) {
421
+ l(W, "useFetcher");
422
+ function Le(r) {
420
423
  const e = w(11), {
421
424
  loading: t,
422
425
  result: n,
@@ -426,11 +429,11 @@ function Ce(r) {
426
429
  execute: o,
427
430
  reset: u,
428
431
  abort: d
429
- } = j(r), {
432
+ } = W(r), {
430
433
  run: a,
431
434
  cancel: f,
432
435
  isPending: m
433
- } = M(o, r.debounce);
436
+ } = T(o, r.debounce);
434
437
  let b;
435
438
  return e[0] !== d || e[1] !== f || e[2] !== s || e[3] !== i || e[4] !== m || e[5] !== t || e[6] !== u || e[7] !== n || e[8] !== a || e[9] !== c ? (b = {
436
439
  loading: t,
@@ -445,8 +448,8 @@ function Ce(r) {
445
448
  isPending: m
446
449
  }, e[0] = d, e[1] = f, e[2] = s, e[3] = i, e[4] = m, e[5] = t, e[6] = u, e[7] = n, e[8] = a, e[9] = c, e[10] = b) : b = e[10], b;
447
450
  }
448
- l(Ce, "useDebouncedFetcher");
449
- function N(r) {
451
+ l(Le, "useDebouncedFetcher");
452
+ function j(r) {
450
453
  const e = w(10), {
451
454
  initialQuery: t,
452
455
  autoExecute: n,
@@ -463,14 +466,14 @@ function N(r) {
463
466
  let f, m;
464
467
  e[4] !== c || e[5] !== s ? (f = /* @__PURE__ */ l(() => {
465
468
  c && s(i.current);
466
- }, "t2"), m = [c, s], e[4] = c, e[5] = s, e[6] = f, e[7] = m) : (f = e[6], m = e[7]), $(f, m);
469
+ }, "t2"), m = [c, s], e[4] = c, e[5] = s, e[6] = f, e[7] = m) : (f = e[6], m = e[7]), O(f, m);
467
470
  let b;
468
471
  return e[8] !== a ? (b = {
469
472
  getQuery: u,
470
473
  setQuery: a
471
474
  }, e[8] = a, e[9] = b) : b = e[9], b;
472
475
  }
473
- l(N, "useQueryState");
476
+ l(j, "useQueryState");
474
477
  function p(r) {
475
478
  const e = P(r), {
476
479
  loading: t,
@@ -483,12 +486,12 @@ function p(r) {
483
486
  } = q(e.current), d = _((b) => i(/* @__PURE__ */ l(async (h) => e.current.execute(b, e.current.attributes, h), "queryExecutor")), [i, e]), {
484
487
  getQuery: a,
485
488
  setQuery: f
486
- } = N({
489
+ } = j({
487
490
  initialQuery: r.initialQuery,
488
491
  autoExecute: e.current.autoExecute,
489
492
  execute: d
490
493
  }), m = _(() => d(a()), [d, a]);
491
- return T(() => ({
494
+ return M(() => ({
492
495
  loading: t,
493
496
  result: n,
494
497
  error: s,
@@ -501,10 +504,10 @@ function p(r) {
501
504
  }), [t, n, s, c, m, o, u, a, f]);
502
505
  }
503
506
  l(p, "useQuery");
504
- function Le(r) {
507
+ function Ie(r) {
505
508
  return p(r);
506
509
  }
507
- l(Le, "useCountQuery");
510
+ l(Ie, "useCountQuery");
508
511
  function A(r) {
509
512
  const e = w(22);
510
513
  let t;
@@ -520,7 +523,7 @@ function A(r) {
520
523
  execute: d,
521
524
  reset: a,
522
525
  abort: f
523
- } = j(n);
526
+ } = W(n);
524
527
  let m;
525
528
  e[2] !== d || e[3] !== s ? (m = /* @__PURE__ */ l((S) => {
526
529
  const v = {
@@ -540,7 +543,7 @@ function A(r) {
540
543
  const {
541
544
  getQuery: h,
542
545
  setQuery: E
543
- } = N(y);
546
+ } = j(y);
544
547
  let x;
545
548
  e[9] !== b || e[10] !== h ? (x = /* @__PURE__ */ l(() => b(h()), "t3"), e[9] = b, e[10] = h, e[11] = x) : x = e[11];
546
549
  const Q = x;
@@ -558,15 +561,15 @@ function A(r) {
558
561
  }, e[12] = f, e[13] = o, e[14] = Q, e[15] = h, e[16] = c, e[17] = a, e[18] = i, e[19] = E, e[20] = u, e[21] = g) : g = e[21], g;
559
562
  }
560
563
  l(A, "useFetcherQuery");
561
- function Ie(r) {
564
+ function Oe(r) {
562
565
  return A(r);
563
566
  }
564
- l(Ie, "useFetcherCountQuery");
567
+ l(Oe, "useFetcherCountQuery");
565
568
  function $e(r) {
566
569
  return A(r);
567
570
  }
568
571
  l($e, "useFetcherListQuery");
569
- function Oe(r) {
572
+ function Pe(r) {
570
573
  const e = w(2);
571
574
  let t;
572
575
  return e[0] !== r ? (t = {
@@ -574,32 +577,32 @@ function Oe(r) {
574
577
  resultExtractor: oe
575
578
  }, e[0] = r, e[1] = t) : t = e[1], A(t);
576
579
  }
577
- l(Oe, "useFetcherListStreamQuery");
578
- function Pe(r) {
579
- return A(r);
580
- }
581
- l(Pe, "useFetcherPagedQuery");
580
+ l(Pe, "useFetcherListStreamQuery");
582
581
  function pe(r) {
583
582
  return A(r);
584
583
  }
585
- l(pe, "useFetcherSingleQuery");
584
+ l(pe, "useFetcherPagedQuery");
586
585
  function Ae(r) {
587
- return p(r);
586
+ return A(r);
588
587
  }
589
- l(Ae, "useListQuery");
588
+ l(Ae, "useFetcherSingleQuery");
590
589
  function De(r) {
591
590
  return p(r);
592
591
  }
593
- l(De, "useListStreamQuery");
592
+ l(De, "useListQuery");
593
+ function Me(r) {
594
+ return p(r);
595
+ }
596
+ l(Me, "useListStreamQuery");
594
597
  function Te(r) {
595
598
  return p(r);
596
599
  }
597
600
  l(Te, "usePagedQuery");
598
- function Me(r) {
601
+ function qe(r) {
599
602
  return p(r);
600
603
  }
601
- l(Me, "useSingleQuery");
602
- function qe(r) {
604
+ l(qe, "useSingleQuery");
605
+ function Ue(r) {
603
606
  const e = w(22), t = r.autoExecute;
604
607
  let n;
605
608
  e[0] !== r ? (n = {
@@ -620,7 +623,7 @@ function qe(r) {
620
623
  run: y,
621
624
  cancel: h,
622
625
  isPending: E
623
- } = M(d, r.debounce);
626
+ } = T(d, r.debounce);
624
627
  let x;
625
628
  e[2] !== t || e[3] !== y || e[4] !== b ? (x = /* @__PURE__ */ l((F) => {
626
629
  b(F), t && y();
@@ -629,7 +632,7 @@ function qe(r) {
629
632
  let g, S;
630
633
  e[6] !== t || e[7] !== y ? (g = /* @__PURE__ */ l(() => {
631
634
  t && y();
632
- }, "t2"), S = [y, t], e[6] = t, e[7] = y, e[8] = g, e[9] = S) : (g = e[8], S = e[9]), $(g, S);
635
+ }, "t2"), S = [y, t], e[6] = t, e[7] = y, e[8] = g, e[9] = S) : (g = e[8], S = e[9]), O(g, S);
633
636
  let v;
634
637
  return e[10] !== f || e[11] !== h || e[12] !== o || e[13] !== m || e[14] !== E || e[15] !== c || e[16] !== a || e[17] !== i || e[18] !== y || e[19] !== Q || e[20] !== u ? (v = {
635
638
  loading: c,
@@ -645,7 +648,7 @@ function qe(r) {
645
648
  isPending: E
646
649
  }, e[10] = f, e[11] = h, e[12] = o, e[13] = m, e[14] = E, e[15] = c, e[16] = a, e[17] = i, e[18] = y, e[19] = Q, e[20] = u, e[21] = v) : v = e[21], v;
647
650
  }
648
- l(qe, "useDebouncedFetcherQuery");
651
+ l(Ue, "useDebouncedFetcherQuery");
649
652
  function ke(r) {
650
653
  const e = w(22), t = r.autoExecute;
651
654
  let n;
@@ -667,7 +670,7 @@ function ke(r) {
667
670
  run: y,
668
671
  cancel: h,
669
672
  isPending: E
670
- } = M(d, r.debounce);
673
+ } = T(d, r.debounce);
671
674
  let x;
672
675
  e[2] !== t || e[3] !== y || e[4] !== b ? (x = /* @__PURE__ */ l((F) => {
673
676
  b(F), t && y();
@@ -676,7 +679,7 @@ function ke(r) {
676
679
  let g, S;
677
680
  e[6] !== t || e[7] !== y ? (g = /* @__PURE__ */ l(() => {
678
681
  t && y();
679
- }, "t2"), S = [y, t], e[6] = t, e[7] = y, e[8] = g, e[9] = S) : (g = e[8], S = e[9]), $(g, S);
682
+ }, "t2"), S = [y, t], e[6] = t, e[7] = y, e[8] = g, e[9] = S) : (g = e[8], S = e[9]), O(g, S);
680
683
  let v;
681
684
  return e[10] !== f || e[11] !== h || e[12] !== o || e[13] !== m || e[14] !== E || e[15] !== c || e[16] !== a || e[17] !== i || e[18] !== y || e[19] !== Q || e[20] !== u ? (v = {
682
685
  loading: c,
@@ -693,7 +696,7 @@ function ke(r) {
693
696
  }, e[10] = f, e[11] = h, e[12] = o, e[13] = m, e[14] = E, e[15] = c, e[16] = a, e[17] = i, e[18] = y, e[19] = Q, e[20] = u, e[21] = v) : v = e[21], v;
694
697
  }
695
698
  l(ke, "useDebouncedQuery");
696
- function Ue(r) {
699
+ function Ke(r) {
697
700
  const e = w(13), {
698
701
  bus: t,
699
702
  handler: n
@@ -707,48 +710,49 @@ function Ue(r) {
707
710
  let u, d;
708
711
  e[6] !== t || e[7] !== n ? (u = /* @__PURE__ */ l(() => (t.on(n) || console.warn(`Failed to subscribe to event bus with handler: ${n.name}`), () => {
709
712
  t.off(n.name);
710
- }), "t2"), d = [t, n], e[6] = t, e[7] = n, e[8] = u, e[9] = d) : (u = e[8], d = e[9]), $(u, d);
713
+ }), "t2"), d = [t, n], e[6] = t, e[7] = n, e[8] = u, e[9] = d) : (u = e[8], d = e[9]), O(u, d);
711
714
  let a;
712
715
  return e[10] !== c || e[11] !== o ? (a = {
713
716
  subscribe: c,
714
717
  unsubscribe: o
715
718
  }, e[10] = c, e[11] = o, e[12] = a) : a = e[12], a;
716
719
  }
717
- l(Ue, "useEventSubscription");
720
+ l(Ke, "useEventSubscription");
718
721
  export {
722
+ fe as ANONYMOUS_USER,
719
723
  ue as PromiseStatus,
720
- W as SecurityContext,
721
- Fe as SecurityProvider,
722
- Le as useCountQuery,
723
- M as useDebouncedCallback,
724
- Se as useDebouncedExecutePromise,
725
- Ce as useDebouncedFetcher,
726
- qe as useDebouncedFetcherQuery,
724
+ J as SecurityContext,
725
+ Re as SecurityProvider,
726
+ Ie as useCountQuery,
727
+ T as useDebouncedCallback,
728
+ _e as useDebouncedExecutePromise,
729
+ Le as useDebouncedFetcher,
730
+ Ue as useDebouncedFetcherQuery,
727
731
  ke as useDebouncedQuery,
728
- Ue as useEventSubscription,
732
+ Ke as useEventSubscription,
729
733
  q as useExecutePromise,
730
- j as useFetcher,
731
- Ie as useFetcherCountQuery,
734
+ W as useFetcher,
735
+ Oe as useFetcherCountQuery,
732
736
  $e as useFetcherListQuery,
733
- Oe as useFetcherListStreamQuery,
734
- Pe as useFetcherPagedQuery,
737
+ Pe as useFetcherListStreamQuery,
738
+ pe as useFetcherPagedQuery,
735
739
  A as useFetcherQuery,
736
- pe as useFetcherSingleQuery,
737
- _e as useForceUpdate,
738
- we as useImmerKeyStorage,
739
- J as useKeyStorage,
740
+ Ae as useFetcherSingleQuery,
741
+ we as useForceUpdate,
742
+ Fe as useImmerKeyStorage,
743
+ G as useKeyStorage,
740
744
  P as useLatest,
741
- Ae as useListQuery,
742
- De as useListStreamQuery,
743
- G as useMounted,
745
+ De as useListQuery,
746
+ Me as useListStreamQuery,
747
+ z as useMounted,
744
748
  Te as usePagedQuery,
745
749
  le as usePromiseState,
746
750
  p as useQuery,
747
- N as useQueryState,
748
- Qe as useRefs,
751
+ j as useQueryState,
752
+ Se as useRefs,
749
753
  ie as useRequestId,
750
- fe as useSecurity,
751
- Re as useSecurityContext,
752
- Me as useSingleQuery
754
+ de as useSecurity,
755
+ Ce as useSecurityContext,
756
+ qe as useSingleQuery
753
757
  };
754
758
  //# sourceMappingURL=index.es.js.map