react-state-custom 1.0.6 → 1.0.8

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.es.js CHANGED
@@ -1,16 +1,16 @@
1
1
  var Ne = Object.defineProperty;
2
2
  var Ae = (e, t, r) => t in e ? Ne(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
3
3
  var Q = (e, t, r) => Ae(e, typeof t != "symbol" ? t + "" : t, r);
4
- import ke, { useMemo as z, useEffect as L, useState as U, useCallback as Me, Fragment as Ie } from "react";
5
- function $e(e) {
4
+ import ke, { useMemo as z, useEffect as L, useState as U, useCallback as Me, Fragment as $e } from "react";
5
+ function Ie(e) {
6
6
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
7
7
  }
8
8
  var Z = { exports: {} }, be;
9
9
  function xe() {
10
10
  if (be) return Z.exports;
11
11
  be = 1;
12
- var e = typeof Reflect == "object" ? Reflect : null, t = e && typeof e.apply == "function" ? e.apply : function(a, o, l) {
13
- return Function.prototype.apply.call(a, o, l);
12
+ var e = typeof Reflect == "object" ? Reflect : null, t = e && typeof e.apply == "function" ? e.apply : function(a, o, f) {
13
+ return Function.prototype.apply.call(a, o, f);
14
14
  }, r;
15
15
  e && typeof e.ownKeys == "function" ? r = e.ownKeys : Object.getOwnPropertySymbols ? r = function(a) {
16
16
  return Object.getOwnPropertyNames(a).concat(Object.getOwnPropertySymbols(a));
@@ -20,14 +20,14 @@ function xe() {
20
20
  function u(s) {
21
21
  console && console.warn && console.warn(s);
22
22
  }
23
- var c = Number.isNaN || function(a) {
23
+ var l = Number.isNaN || function(a) {
24
24
  return a !== a;
25
25
  };
26
26
  function n() {
27
27
  n.init.call(this);
28
28
  }
29
29
  Z.exports = n, Z.exports.once = N, n.EventEmitter = n, n.prototype._events = void 0, n.prototype._eventsCount = 0, n.prototype._maxListeners = void 0;
30
- var f = 10;
30
+ var c = 10;
31
31
  function h(s) {
32
32
  if (typeof s != "function")
33
33
  throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof s);
@@ -35,17 +35,17 @@ function xe() {
35
35
  Object.defineProperty(n, "defaultMaxListeners", {
36
36
  enumerable: !0,
37
37
  get: function() {
38
- return f;
38
+ return c;
39
39
  },
40
40
  set: function(s) {
41
- if (typeof s != "number" || s < 0 || c(s))
41
+ if (typeof s != "number" || s < 0 || l(s))
42
42
  throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + s + ".");
43
- f = s;
43
+ c = s;
44
44
  }
45
45
  }), n.init = function() {
46
46
  (this._events === void 0 || this._events === Object.getPrototypeOf(this)._events) && (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0;
47
47
  }, n.prototype.setMaxListeners = function(a) {
48
- if (typeof a != "number" || a < 0 || c(a))
48
+ if (typeof a != "number" || a < 0 || l(a))
49
49
  throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + a + ".");
50
50
  return this._maxListeners = a, this;
51
51
  };
@@ -55,7 +55,7 @@ function xe() {
55
55
  n.prototype.getMaxListeners = function() {
56
56
  return p(this);
57
57
  }, n.prototype.emit = function(a) {
58
- for (var o = [], l = 1; l < arguments.length; l++) o.push(arguments[l]);
58
+ for (var o = [], f = 1; f < arguments.length; f++) o.push(arguments[f]);
59
59
  var d = a === "error", _ = this._events;
60
60
  if (_ !== void 0)
61
61
  d = d && _.error === void 0;
@@ -74,11 +74,11 @@ function xe() {
74
74
  if (typeof A == "function")
75
75
  t(A, this, o);
76
76
  else
77
- for (var B = A.length, H = M(A, B), l = 0; l < B; ++l)
78
- t(H[l], this, o);
77
+ for (var B = A.length, H = M(A, B), f = 0; f < B; ++f)
78
+ t(H[f], this, o);
79
79
  return !0;
80
80
  };
81
- function m(s, a, o, l) {
81
+ function v(s, a, o, f) {
82
82
  var d, _, b;
83
83
  if (h(o), _ = s._events, _ === void 0 ? (_ = s._events = /* @__PURE__ */ Object.create(null), s._eventsCount = 0) : (_.newListener !== void 0 && (s.emit(
84
84
  "newListener",
@@ -86,7 +86,7 @@ function xe() {
86
86
  o.listener ? o.listener : o
87
87
  ), _ = s._events), b = _[a]), b === void 0)
88
88
  b = _[a] = o, ++s._eventsCount;
89
- else if (typeof b == "function" ? b = _[a] = l ? [o, b] : [b, o] : l ? b.unshift(o) : b.push(o), d = p(s), d > 0 && b.length > d && !b.warned) {
89
+ else if (typeof b == "function" ? b = _[a] = f ? [o, b] : [b, o] : f ? b.unshift(o) : b.push(o), d = p(s), d > 0 && b.length > d && !b.warned) {
90
90
  b.warned = !0;
91
91
  var j = new Error("Possible EventEmitter memory leak detected. " + b.length + " " + String(a) + " listeners added. Use emitter.setMaxListeners() to increase limit");
92
92
  j.name = "MaxListenersExceededWarning", j.emitter = s, j.type = a, j.count = b.length, u(j);
@@ -94,54 +94,54 @@ function xe() {
94
94
  return s;
95
95
  }
96
96
  n.prototype.addListener = function(a, o) {
97
- return m(this, a, o, !1);
97
+ return v(this, a, o, !1);
98
98
  }, n.prototype.on = n.prototype.addListener, n.prototype.prependListener = function(a, o) {
99
- return m(this, a, o, !0);
99
+ return v(this, a, o, !0);
100
100
  };
101
101
  function g() {
102
102
  if (!this.fired)
103
103
  return this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length === 0 ? this.listener.call(this.target) : this.listener.apply(this.target, arguments);
104
104
  }
105
- function y(s, a, o) {
106
- var l = { fired: !1, wrapFn: void 0, target: s, type: a, listener: o }, d = g.bind(l);
107
- return d.listener = o, l.wrapFn = d, d;
105
+ function E(s, a, o) {
106
+ var f = { fired: !1, wrapFn: void 0, target: s, type: a, listener: o }, d = g.bind(f);
107
+ return d.listener = o, f.wrapFn = d, d;
108
108
  }
109
109
  n.prototype.once = function(a, o) {
110
- return h(o), this.on(a, y(this, a, o)), this;
110
+ return h(o), this.on(a, E(this, a, o)), this;
111
111
  }, n.prototype.prependOnceListener = function(a, o) {
112
- return h(o), this.prependListener(a, y(this, a, o)), this;
112
+ return h(o), this.prependListener(a, E(this, a, o)), this;
113
113
  }, n.prototype.removeListener = function(a, o) {
114
- var l, d, _, b, j;
114
+ var f, d, _, b, j;
115
115
  if (h(o), d = this._events, d === void 0)
116
116
  return this;
117
- if (l = d[a], l === void 0)
117
+ if (f = d[a], f === void 0)
118
118
  return this;
119
- if (l === o || l.listener === o)
120
- --this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete d[a], d.removeListener && this.emit("removeListener", a, l.listener || o));
121
- else if (typeof l != "function") {
122
- for (_ = -1, b = l.length - 1; b >= 0; b--)
123
- if (l[b] === o || l[b].listener === o) {
124
- j = l[b].listener, _ = b;
119
+ if (f === o || f.listener === o)
120
+ --this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete d[a], d.removeListener && this.emit("removeListener", a, f.listener || o));
121
+ else if (typeof f != "function") {
122
+ for (_ = -1, b = f.length - 1; b >= 0; b--)
123
+ if (f[b] === o || f[b].listener === o) {
124
+ j = f[b].listener, _ = b;
125
125
  break;
126
126
  }
127
127
  if (_ < 0)
128
128
  return this;
129
- _ === 0 ? l.shift() : E(l, _), l.length === 1 && (d[a] = l[0]), d.removeListener !== void 0 && this.emit("removeListener", a, j || o);
129
+ _ === 0 ? f.shift() : y(f, _), f.length === 1 && (d[a] = f[0]), d.removeListener !== void 0 && this.emit("removeListener", a, j || o);
130
130
  }
131
131
  return this;
132
132
  }, n.prototype.off = n.prototype.removeListener, n.prototype.removeAllListeners = function(a) {
133
- var o, l, d;
134
- if (l = this._events, l === void 0)
133
+ var o, f, d;
134
+ if (f = this._events, f === void 0)
135
135
  return this;
136
- if (l.removeListener === void 0)
137
- return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : l[a] !== void 0 && (--this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete l[a]), this;
136
+ if (f.removeListener === void 0)
137
+ return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : f[a] !== void 0 && (--this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete f[a]), this;
138
138
  if (arguments.length === 0) {
139
- var _ = Object.keys(l), b;
139
+ var _ = Object.keys(f), b;
140
140
  for (d = 0; d < _.length; ++d)
141
141
  b = _[d], b !== "removeListener" && this.removeAllListeners(b);
142
142
  return this.removeAllListeners("removeListener"), this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0, this;
143
143
  }
144
- if (o = l[a], typeof o == "function")
144
+ if (o = f[a], typeof o == "function")
145
145
  this.removeListener(a, o);
146
146
  else if (o !== void 0)
147
147
  for (d = o.length - 1; d >= 0; d--)
@@ -149,10 +149,10 @@ function xe() {
149
149
  return this;
150
150
  };
151
151
  function T(s, a, o) {
152
- var l = s._events;
153
- if (l === void 0)
152
+ var f = s._events;
153
+ if (f === void 0)
154
154
  return [];
155
- var d = l[a];
155
+ var d = f[a];
156
156
  return d === void 0 ? [] : typeof d == "function" ? o ? [d.listener || d] : [d] : o ? O(d) : M(d, d.length);
157
157
  }
158
158
  n.prototype.listeners = function(a) {
@@ -177,11 +177,11 @@ function xe() {
177
177
  return this._eventsCount > 0 ? r(this._events) : [];
178
178
  };
179
179
  function M(s, a) {
180
- for (var o = new Array(a), l = 0; l < a; ++l)
181
- o[l] = s[l];
180
+ for (var o = new Array(a), f = 0; f < a; ++f)
181
+ o[f] = s[f];
182
182
  return o;
183
183
  }
184
- function E(s, a) {
184
+ function y(s, a) {
185
185
  for (; a + 1 < s.length; a++)
186
186
  s[a] = s[a + 1];
187
187
  s.pop();
@@ -192,33 +192,33 @@ function xe() {
192
192
  return a;
193
193
  }
194
194
  function N(s, a) {
195
- return new Promise(function(o, l) {
195
+ return new Promise(function(o, f) {
196
196
  function d(b) {
197
- s.removeListener(a, _), l(b);
197
+ s.removeListener(a, _), f(b);
198
198
  }
199
199
  function _() {
200
200
  typeof s.removeListener == "function" && s.removeListener("error", d), o([].slice.call(arguments));
201
201
  }
202
- F(s, a, _, { once: !0 }), a !== "error" && x(s, d, { once: !0 });
202
+ D(s, a, _, { once: !0 }), a !== "error" && x(s, d, { once: !0 });
203
203
  });
204
204
  }
205
205
  function x(s, a, o) {
206
- typeof s.on == "function" && F(s, "error", a, o);
206
+ typeof s.on == "function" && D(s, "error", a, o);
207
207
  }
208
- function F(s, a, o, l) {
208
+ function D(s, a, o, f) {
209
209
  if (typeof s.on == "function")
210
- l.once ? s.once(a, o) : s.on(a, o);
210
+ f.once ? s.once(a, o) : s.on(a, o);
211
211
  else if (typeof s.addEventListener == "function")
212
212
  s.addEventListener(a, function d(_) {
213
- l.once && s.removeEventListener(a, d), o(_);
213
+ f.once && s.removeEventListener(a, d), o(_);
214
214
  });
215
215
  else
216
216
  throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof s);
217
217
  }
218
218
  return Z.exports;
219
219
  }
220
- var Fe = xe();
221
- const De = /* @__PURE__ */ $e(Fe);
220
+ var De = xe();
221
+ const Fe = /* @__PURE__ */ Ie(De);
222
222
  var We = typeof global == "object" && global && global.Object === Object && global, ze = typeof self == "object" && self && self.Object === Object && self, re = We || ze || Function("return this")(), te = re.Symbol, Re = Object.prototype, Ye = Re.hasOwnProperty, Ge = Re.toString, q = te ? te.toStringTag : void 0;
223
223
  function Ue(e) {
224
224
  var t = Ye.call(e, q), r = e[q];
@@ -227,8 +227,8 @@ function Ue(e) {
227
227
  var u = !0;
228
228
  } catch {
229
229
  }
230
- var c = Ge.call(e);
231
- return u && (t ? e[q] = r : delete e[q]), c;
230
+ var l = Ge.call(e);
231
+ return u && (t ? e[q] = r : delete e[q]), l;
232
232
  }
233
233
  var Ve = Object.prototype, He = Ve.toString;
234
234
  function qe(e) {
@@ -260,7 +260,7 @@ function G(e) {
260
260
  return e != null && (t == "object" || t == "function");
261
261
  }
262
262
  var _e = NaN, nt = /^[-+]0x[0-9a-f]+$/i, ot = /^0b[01]+$/i, at = /^0o[0-7]+$/i, it = parseInt;
263
- function Ee(e) {
263
+ function ye(e) {
264
264
  if (typeof e == "number")
265
265
  return e;
266
266
  if (Qe(e))
@@ -275,19 +275,19 @@ function Ee(e) {
275
275
  var r = ot.test(e);
276
276
  return r || at.test(e) ? it(e.slice(2), r ? 2 : 8) : nt.test(e) ? _e : +e;
277
277
  }
278
- var st = "[object AsyncFunction]", ut = "[object Function]", ct = "[object GeneratorFunction]", lt = "[object Proxy]";
279
- function ft(e) {
278
+ var st = "[object AsyncFunction]", ut = "[object Function]", ct = "[object GeneratorFunction]", ft = "[object Proxy]";
279
+ function lt(e) {
280
280
  if (!G(e))
281
281
  return !1;
282
282
  var t = Se(e);
283
- return t == ut || t == ct || t == st || t == lt;
283
+ return t == ut || t == ct || t == st || t == ft;
284
284
  }
285
- var ce = re["__core-js_shared__"], ye = function() {
285
+ var ce = re["__core-js_shared__"], Ee = function() {
286
286
  var e = /[^.]+$/.exec(ce && ce.keys && ce.keys.IE_PROTO || "");
287
287
  return e ? "Symbol(src)_1." + e : "";
288
288
  }();
289
289
  function dt(e) {
290
- return !!ye && ye in e;
290
+ return !!Ee && Ee in e;
291
291
  }
292
292
  var ht = Function.prototype, pt = ht.toString;
293
293
  function vt(e) {
@@ -303,13 +303,13 @@ function vt(e) {
303
303
  }
304
304
  return "";
305
305
  }
306
- var mt = /[\\^$.*+?()[\]{}|]/g, bt = /^\[object .+?Constructor\]$/, gt = Function.prototype, _t = Object.prototype, Et = gt.toString, yt = _t.hasOwnProperty, wt = RegExp(
307
- "^" + Et.call(yt).replace(mt, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
306
+ var mt = /[\\^$.*+?()[\]{}|]/g, bt = /^\[object .+?Constructor\]$/, gt = Function.prototype, _t = Object.prototype, yt = gt.toString, Et = _t.hasOwnProperty, wt = RegExp(
307
+ "^" + yt.call(Et).replace(mt, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
308
308
  );
309
309
  function Tt(e) {
310
310
  if (!G(e) || dt(e))
311
311
  return !1;
312
- var t = ft(e) ? wt : bt;
312
+ var t = lt(e) ? wt : bt;
313
313
  return t.test(vt(e));
314
314
  }
315
315
  function Ot(e, t) {
@@ -344,23 +344,23 @@ function Mt(e) {
344
344
  var t = this.__data__;
345
345
  return K ? t[e] !== void 0 : kt.call(t, e);
346
346
  }
347
- var It = "__lodash_hash_undefined__";
348
- function $t(e, t) {
347
+ var $t = "__lodash_hash_undefined__";
348
+ function It(e, t) {
349
349
  var r = this.__data__;
350
- return this.size += this.has(e) ? 0 : 1, r[e] = K && t === void 0 ? It : t, this;
350
+ return this.size += this.has(e) ? 0 : 1, r[e] = K && t === void 0 ? $t : t, this;
351
351
  }
352
- function I(e) {
352
+ function $(e) {
353
353
  var t = -1, r = e == null ? 0 : e.length;
354
354
  for (this.clear(); ++t < r; ) {
355
355
  var u = e[t];
356
356
  this.set(u[0], u[1]);
357
357
  }
358
358
  }
359
- I.prototype.clear = St;
360
- I.prototype.delete = jt;
361
- I.prototype.get = Nt;
362
- I.prototype.has = Mt;
363
- I.prototype.set = $t;
359
+ $.prototype.clear = St;
360
+ $.prototype.delete = jt;
361
+ $.prototype.get = Nt;
362
+ $.prototype.has = Mt;
363
+ $.prototype.set = It;
364
364
  function xt() {
365
365
  this.__data__ = [], this.size = 0;
366
366
  }
@@ -370,13 +370,13 @@ function ne(e, t) {
370
370
  return r;
371
371
  return -1;
372
372
  }
373
- var Ft = Array.prototype, Dt = Ft.splice;
373
+ var Dt = Array.prototype, Ft = Dt.splice;
374
374
  function Wt(e) {
375
375
  var t = this.__data__, r = ne(t, e);
376
376
  if (r < 0)
377
377
  return !1;
378
378
  var u = t.length - 1;
379
- return r == u ? t.pop() : Dt.call(t, r, 1), --this.size, !0;
379
+ return r == u ? t.pop() : Ft.call(t, r, 1), --this.size, !0;
380
380
  }
381
381
  function zt(e) {
382
382
  var t = this.__data__, r = ne(t, e);
@@ -404,9 +404,9 @@ V.prototype.set = Gt;
404
404
  var Ut = je(re, "Map");
405
405
  function Vt() {
406
406
  this.size = 0, this.__data__ = {
407
- hash: new I(),
407
+ hash: new $(),
408
408
  map: new (Ut || V)(),
409
- string: new I()
409
+ string: new $()
410
410
  };
411
411
  }
412
412
  function Ht(e) {
@@ -431,91 +431,91 @@ function Kt(e, t) {
431
431
  var r = oe(this, e), u = r.size;
432
432
  return r.set(e, t), this.size += r.size == u ? 0 : 1, this;
433
433
  }
434
- function $(e) {
434
+ function I(e) {
435
435
  var t = -1, r = e == null ? 0 : e.length;
436
436
  for (this.clear(); ++t < r; ) {
437
437
  var u = e[t];
438
438
  this.set(u[0], u[1]);
439
439
  }
440
440
  }
441
- $.prototype.clear = Vt;
442
- $.prototype.delete = qt;
443
- $.prototype.get = Jt;
444
- $.prototype.has = Xt;
445
- $.prototype.set = Kt;
441
+ I.prototype.clear = Vt;
442
+ I.prototype.delete = qt;
443
+ I.prototype.get = Jt;
444
+ I.prototype.has = Xt;
445
+ I.prototype.set = Kt;
446
446
  var Bt = "Expected a function";
447
- function fe(e, t) {
447
+ function le(e, t) {
448
448
  if (typeof e != "function" || t != null && typeof t != "function")
449
449
  throw new TypeError(Bt);
450
450
  var r = function() {
451
- var u = arguments, c = t ? t.apply(this, u) : u[0], n = r.cache;
452
- if (n.has(c))
453
- return n.get(c);
454
- var f = e.apply(this, u);
455
- return r.cache = n.set(c, f) || n, f;
451
+ var u = arguments, l = t ? t.apply(this, u) : u[0], n = r.cache;
452
+ if (n.has(l))
453
+ return n.get(l);
454
+ var c = e.apply(this, u);
455
+ return r.cache = n.set(l, c) || n, c;
456
456
  };
457
- return r.cache = new (fe.Cache || $)(), r;
457
+ return r.cache = new (le.Cache || I)(), r;
458
458
  }
459
- fe.Cache = $;
460
- var le = function() {
459
+ le.Cache = I;
460
+ var fe = function() {
461
461
  return re.Date.now();
462
462
  }, Qt = "Expected a function", Zt = Math.max, er = Math.min;
463
463
  function ae(e, t, r) {
464
- var u, c, n, f, h, p, m = 0, g = !1, y = !1, T = !0;
464
+ var u, l, n, c, h, p, v = 0, g = !1, E = !1, T = !0;
465
465
  if (typeof e != "function")
466
466
  throw new TypeError(Qt);
467
- t = Ee(t) || 0, G(r) && (g = !!r.leading, y = "maxWait" in r, n = y ? Zt(Ee(r.maxWait) || 0, t) : n, T = "trailing" in r ? !!r.trailing : T);
467
+ t = ye(t) || 0, G(r) && (g = !!r.leading, E = "maxWait" in r, n = E ? Zt(ye(r.maxWait) || 0, t) : n, T = "trailing" in r ? !!r.trailing : T);
468
468
  function C(o) {
469
- var l = u, d = c;
470
- return u = c = void 0, m = o, f = e.apply(d, l), f;
469
+ var f = u, d = l;
470
+ return u = l = void 0, v = o, c = e.apply(d, f), c;
471
471
  }
472
472
  function M(o) {
473
- return m = o, h = setTimeout(N, t), g ? C(o) : f;
473
+ return v = o, h = setTimeout(N, t), g ? C(o) : c;
474
474
  }
475
- function E(o) {
476
- var l = o - p, d = o - m, _ = t - l;
477
- return y ? er(_, n - d) : _;
475
+ function y(o) {
476
+ var f = o - p, d = o - v, _ = t - f;
477
+ return E ? er(_, n - d) : _;
478
478
  }
479
479
  function O(o) {
480
- var l = o - p, d = o - m;
481
- return p === void 0 || l >= t || l < 0 || y && d >= n;
480
+ var f = o - p, d = o - v;
481
+ return p === void 0 || f >= t || f < 0 || E && d >= n;
482
482
  }
483
483
  function N() {
484
- var o = le();
484
+ var o = fe();
485
485
  if (O(o))
486
486
  return x(o);
487
- h = setTimeout(N, E(o));
487
+ h = setTimeout(N, y(o));
488
488
  }
489
489
  function x(o) {
490
- return h = void 0, T && u ? C(o) : (u = c = void 0, f);
490
+ return h = void 0, T && u ? C(o) : (u = l = void 0, c);
491
491
  }
492
- function F() {
493
- h !== void 0 && clearTimeout(h), m = 0, u = p = c = h = void 0;
492
+ function D() {
493
+ h !== void 0 && clearTimeout(h), v = 0, u = p = l = h = void 0;
494
494
  }
495
495
  function s() {
496
- return h === void 0 ? f : x(le());
496
+ return h === void 0 ? c : x(fe());
497
497
  }
498
498
  function a() {
499
- var o = le(), l = O(o);
500
- if (u = arguments, c = this, p = o, l) {
499
+ var o = fe(), f = O(o);
500
+ if (u = arguments, l = this, p = o, f) {
501
501
  if (h === void 0)
502
502
  return M(p);
503
- if (y)
503
+ if (E)
504
504
  return clearTimeout(h), h = setTimeout(N, t), C(p);
505
505
  }
506
- return h === void 0 && (h = setTimeout(N, t)), f;
506
+ return h === void 0 && (h = setTimeout(N, t)), c;
507
507
  }
508
- return a.cancel = F, a.flush = s, a;
508
+ return a.cancel = D, a.flush = s, a;
509
509
  }
510
510
  var tr = "Expected a function";
511
511
  function rr(e, t, r) {
512
- var u = !0, c = !0;
512
+ var u = !0, l = !0;
513
513
  if (typeof e != "function")
514
514
  throw new TypeError(tr);
515
- return G(r) && (u = "leading" in r ? !!r.leading : u, c = "trailing" in r ? !!r.trailing : c), ae(e, t, {
515
+ return G(r) && (u = "leading" in r ? !!r.leading : u, l = "trailing" in r ? !!r.trailing : l), ae(e, t, {
516
516
  leading: u,
517
517
  maxWait: t,
518
- trailing: c
518
+ trailing: l
519
519
  });
520
520
  }
521
521
  class nr {
@@ -524,7 +524,7 @@ class nr {
524
524
  * @param name - The name of the context (for debugging).
525
525
  */
526
526
  constructor(t) {
527
- Q(this, "event", new De.EventEmitter());
527
+ Q(this, "event", new Fe.EventEmitter());
528
528
  /**
529
529
  * The current data held by the context.
530
530
  */
@@ -550,13 +550,13 @@ class nr {
550
550
  * @returns Unsubscribe function.
551
551
  */
552
552
  subscribe(t, r) {
553
- const u = ({ value: c }) => {
554
- r(c);
553
+ const u = ({ value: l }) => {
554
+ r(l);
555
555
  };
556
- return this.event.addListener(String(t), u), console.log("listenerCount:", String(t), this.event.listenerCount(String(t))), t in this.data && r(this.data[t]), () => (this.event.removeListener(String(t), u), void 0);
556
+ return this.event.addListener(String(t), u), t in this.data && r(this.data[t]), () => (this.event.removeListener(String(t), u), void 0);
557
557
  }
558
558
  }
559
- const or = fe((e) => new nr(e)), Y = (e = "noname") => z(() => or(e), [e]), Ce = (e, ...t) => {
559
+ const or = le((e) => new nr(e)), Y = (e = "noname") => z(() => or(e), [e]), Ce = (e, ...t) => {
560
560
  const r = new Error("[ctx] useRegistryChecker failed " + JSON.stringify({ names: t, ctx: (e == null ? void 0 : e.name) ?? "undefined" }));
561
561
  L(
562
562
  () => {
@@ -572,32 +572,32 @@ const or = fe((e) => new nr(e)), Y = (e = "noname") => z(() => or(e), [e]), Ce =
572
572
  e && e.data[t] != r && e.publish(t, r);
573
573
  }, [t, r, e]), Ce(e, t);
574
574
  }, ar = (e, t, r = 0) => {
575
- const [{ value: u }, c] = U(() => {
575
+ const [{ value: u }, l] = U(() => {
576
576
  var n;
577
577
  return { value: (n = e == null ? void 0 : e.data) == null ? void 0 : n[t] };
578
578
  });
579
579
  return L(() => {
580
580
  if (e) {
581
- let n = r == 0 ? (h) => c({ value: h }) : ae((h) => c({ value: h }), r), f = e.subscribe(t, n);
582
- return u != e.data[t] && c({ value: e.data[t] }), () => {
583
- f();
581
+ let n = r == 0 ? (h) => l({ value: h }) : ae((h) => l({ value: h }), r), c = e.subscribe(t, n);
582
+ return u != e.data[t] && l({ value: e.data[t] }), () => {
583
+ c();
584
584
  };
585
585
  }
586
586
  }, [t, e]), e == null ? void 0 : e.data[t];
587
587
  }, pr = (e, t, r) => {
588
- const [, u] = U(0), c = z(
588
+ const [, u] = U(0), l = z(
589
589
  () => r(e == null ? void 0 : e.data[t]),
590
590
  [r, e == null ? void 0 : e.data[t]]
591
591
  );
592
592
  return L(() => {
593
593
  if (e) {
594
- let n = c, f = () => {
594
+ let n = l, c = () => {
595
595
  let p = r(e.data[t]);
596
- p != n && (n = p, u((m) => m + 1));
597
- }, h = e.subscribe(t, f);
598
- return f(), () => h();
596
+ p != n && (n = p, u((v) => v + 1));
597
+ }, h = e.subscribe(t, c);
598
+ return c(), () => h();
599
599
  }
600
- }, [t, e]), c;
600
+ }, [t, e]), l;
601
601
  }, Le = (e, ...t) => {
602
602
  L(() => {
603
603
  if (e)
@@ -605,47 +605,47 @@ const or = fe((e) => new nr(e)), Y = (e = "noname") => z(() => or(e), [e]), Ce =
605
605
  e.data[r] != u && e.publish(r, u);
606
606
  }, [e, ...t.flat()]), Ce(e, ...t.map((r) => r[0]));
607
607
  }, vr = (e, ...t) => {
608
- const [, r] = U(0), u = t.map((c) => {
608
+ const [, r] = U(0), u = t.map((l) => {
609
609
  var n;
610
- return (n = e == null ? void 0 : e.data) == null ? void 0 : n[c];
610
+ return (n = e == null ? void 0 : e.data) == null ? void 0 : n[l];
611
611
  });
612
612
  return L(() => {
613
613
  if (e) {
614
- let c = u;
614
+ let l = u;
615
615
  const n = ae(() => {
616
- let p = t.map((m) => {
616
+ let p = t.map((v) => {
617
617
  var g;
618
- return (g = e == null ? void 0 : e.data) == null ? void 0 : g[m];
618
+ return (g = e == null ? void 0 : e.data) == null ? void 0 : g[v];
619
619
  });
620
- t.some((m, g) => c[g] != p[g]) && (c = p, r((m) => m + 1));
620
+ t.some((v, g) => l[g] != p[g]) && (l = p, r((v) => v + 1));
621
621
  }, 1);
622
- let f = t.map((p) => e.subscribe(p, n)), h = setTimeout(n, 1);
622
+ let c = t.map((p) => e.subscribe(p, n)), h = setTimeout(n, 1);
623
623
  return () => {
624
- clearTimeout(h), n.cancel(), f.forEach((p) => p());
624
+ clearTimeout(h), n.cancel(), c.forEach((p) => p());
625
625
  };
626
626
  }
627
- }, [e, ...t]), Object.fromEntries(t.map((c, n) => [c, u[n]]));
627
+ }, [e, ...t]), Object.fromEntries(t.map((l, n) => [l, u[n]]));
628
628
  }, mr = (e, t = 100, ...r) => {
629
- const [, u] = U(0), c = r.map((n) => {
630
- var f;
631
- return (f = e == null ? void 0 : e.data) == null ? void 0 : f[n];
629
+ const [, u] = U(0), l = r.map((n) => {
630
+ var c;
631
+ return (c = e == null ? void 0 : e.data) == null ? void 0 : c[n];
632
632
  });
633
633
  return L(() => {
634
634
  if (e) {
635
- let n = c;
636
- const f = rr(() => {
637
- let m = r.map((g) => {
638
- var y;
639
- return (y = e == null ? void 0 : e.data) == null ? void 0 : y[g];
635
+ let n = l;
636
+ const c = rr(() => {
637
+ let v = r.map((g) => {
638
+ var E;
639
+ return (E = e == null ? void 0 : e.data) == null ? void 0 : E[g];
640
640
  });
641
- r.some((g, y) => n[y] != m[y]) && (n = m, u((g) => g + 1));
641
+ r.some((g, E) => n[E] != v[E]) && (n = v, u((g) => g + 1));
642
642
  }, t);
643
- let h = r.map((m) => e.subscribe(m, f)), p = setTimeout(f, 1);
643
+ let h = r.map((v) => e.subscribe(v, c)), p = setTimeout(c, 1);
644
644
  return () => {
645
- clearTimeout(p), f.cancel(), h.forEach((m) => m());
645
+ clearTimeout(p), c.cancel(), h.forEach((v) => v());
646
646
  };
647
647
  }
648
- }, [e, ...r]), c;
648
+ }, [e, ...r]), l;
649
649
  };
650
650
  var ee = { exports: {} }, J = {};
651
651
  /**
@@ -662,18 +662,18 @@ function ir() {
662
662
  if (we) return J;
663
663
  we = 1;
664
664
  var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
665
- function r(u, c, n) {
666
- var f = null;
667
- if (n !== void 0 && (f = "" + n), c.key !== void 0 && (f = "" + c.key), "key" in c) {
665
+ function r(u, l, n) {
666
+ var c = null;
667
+ if (n !== void 0 && (c = "" + n), l.key !== void 0 && (c = "" + l.key), "key" in l) {
668
668
  n = {};
669
- for (var h in c)
670
- h !== "key" && (n[h] = c[h]);
671
- } else n = c;
672
- return c = n.ref, {
669
+ for (var h in l)
670
+ h !== "key" && (n[h] = l[h]);
671
+ } else n = l;
672
+ return l = n.ref, {
673
673
  $$typeof: e,
674
674
  type: u,
675
- key: f,
676
- ref: c !== void 0 ? c : null,
675
+ key: c,
676
+ ref: l !== void 0 ? l : null,
677
677
  props: n
678
678
  };
679
679
  }
@@ -698,7 +698,7 @@ function sr() {
698
698
  return i.$$typeof === b ? null : i.displayName || i.name || null;
699
699
  if (typeof i == "string") return i;
700
700
  switch (i) {
701
- case E:
701
+ case y:
702
702
  return "Fragment";
703
703
  case N:
704
704
  return "Profiler";
@@ -717,19 +717,19 @@ function sr() {
717
717
  ), i.$$typeof) {
718
718
  case M:
719
719
  return "Portal";
720
- case F:
720
+ case D:
721
721
  return (i.displayName || "Context") + ".Provider";
722
722
  case x:
723
723
  return (i._context.displayName || "Context") + ".Consumer";
724
724
  case s:
725
- var v = i.render;
726
- return i = i.displayName, i || (i = v.displayName || v.name || "", i = i !== "" ? "ForwardRef(" + i + ")" : "ForwardRef"), i;
727
- case l:
728
- return v = i.displayName || null, v !== null ? v : e(i.type) || "Memo";
725
+ var m = i.render;
726
+ return i = i.displayName, i || (i = m.displayName || m.name || "", i = i !== "" ? "ForwardRef(" + i + ")" : "ForwardRef"), i;
727
+ case f:
728
+ return m = i.displayName || null, m !== null ? m : e(i.type) || "Memo";
729
729
  case d:
730
- v = i._payload, i = i._init;
730
+ m = i._payload, i = i._init;
731
731
  try {
732
- return e(i(v));
732
+ return e(i(m));
733
733
  } catch {
734
734
  }
735
735
  }
@@ -741,50 +741,50 @@ function sr() {
741
741
  function r(i) {
742
742
  try {
743
743
  t(i);
744
- var v = !1;
744
+ var m = !1;
745
745
  } catch {
746
- v = !0;
746
+ m = !0;
747
747
  }
748
- if (v) {
749
- v = console;
750
- var w = v.error, R = typeof Symbol == "function" && Symbol.toStringTag && i[Symbol.toStringTag] || i.constructor.name || "Object";
748
+ if (m) {
749
+ m = console;
750
+ var w = m.error, R = typeof Symbol == "function" && Symbol.toStringTag && i[Symbol.toStringTag] || i.constructor.name || "Object";
751
751
  return w.call(
752
- v,
752
+ m,
753
753
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
754
754
  R
755
755
  ), t(i);
756
756
  }
757
757
  }
758
758
  function u(i) {
759
- if (i === E) return "<>";
759
+ if (i === y) return "<>";
760
760
  if (typeof i == "object" && i !== null && i.$$typeof === d)
761
761
  return "<...>";
762
762
  try {
763
- var v = e(i);
764
- return v ? "<" + v + ">" : "<...>";
763
+ var m = e(i);
764
+ return m ? "<" + m + ">" : "<...>";
765
765
  } catch {
766
766
  return "<...>";
767
767
  }
768
768
  }
769
- function c() {
769
+ function l() {
770
770
  var i = j.A;
771
771
  return i === null ? null : i.getOwner();
772
772
  }
773
773
  function n() {
774
774
  return Error("react-stack-top-frame");
775
775
  }
776
- function f(i) {
776
+ function c(i) {
777
777
  if (A.call(i, "key")) {
778
- var v = Object.getOwnPropertyDescriptor(i, "key").get;
779
- if (v && v.isReactWarning) return !1;
778
+ var m = Object.getOwnPropertyDescriptor(i, "key").get;
779
+ if (m && m.isReactWarning) return !1;
780
780
  }
781
781
  return i.key !== void 0;
782
782
  }
783
- function h(i, v) {
783
+ function h(i, m) {
784
784
  function w() {
785
785
  de || (de = !0, console.error(
786
786
  "%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://react.dev/link/special-props)",
787
- v
787
+ m
788
788
  ));
789
789
  }
790
790
  w.isReactWarning = !0, Object.defineProperty(i, "key", {
@@ -798,11 +798,11 @@ function sr() {
798
798
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
799
799
  )), i = this.props.ref, i !== void 0 ? i : null;
800
800
  }
801
- function m(i, v, w, R, k, P, ie, se) {
801
+ function v(i, m, w, R, k, P, ie, se) {
802
802
  return w = P.ref, i = {
803
803
  $$typeof: C,
804
804
  type: i,
805
- key: v,
805
+ key: m,
806
806
  props: P,
807
807
  _owner: k
808
808
  }, (w !== void 0 ? w : null) !== null ? Object.defineProperty(i, "ref", {
@@ -830,25 +830,25 @@ function sr() {
830
830
  value: se
831
831
  }), Object.freeze && (Object.freeze(i.props), Object.freeze(i)), i;
832
832
  }
833
- function g(i, v, w, R, k, P, ie, se) {
834
- var S = v.children;
833
+ function g(i, m, w, R, k, P, ie, se) {
834
+ var S = m.children;
835
835
  if (S !== void 0)
836
836
  if (R)
837
837
  if (B(S)) {
838
838
  for (R = 0; R < S.length; R++)
839
- y(S[R]);
839
+ E(S[R]);
840
840
  Object.freeze && Object.freeze(S);
841
841
  } else
842
842
  console.error(
843
843
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
844
844
  );
845
- else y(S);
846
- if (A.call(v, "key")) {
845
+ else E(S);
846
+ if (A.call(m, "key")) {
847
847
  S = e(i);
848
- var D = Object.keys(v).filter(function(Pe) {
848
+ var F = Object.keys(m).filter(function(Pe) {
849
849
  return Pe !== "key";
850
850
  });
851
- R = 0 < D.length ? "{key: someKey, " + D.join(": ..., ") + ": ...}" : "{key: someKey}", me[S + R] || (D = 0 < D.length ? "{" + D.join(": ..., ") + ": ...}" : "{}", console.error(
851
+ R = 0 < F.length ? "{key: someKey, " + F.join(": ..., ") + ": ...}" : "{key: someKey}", me[S + R] || (F = 0 < F.length ? "{" + F.join(": ..., ") + ": ...}" : "{}", console.error(
852
852
  `A props object containing a "key" prop is being spread into JSX:
853
853
  let props = %s;
854
854
  <%s {...props} />
@@ -857,33 +857,33 @@ React keys must be passed directly to JSX without using spread:
857
857
  <%s key={someKey} {...props} />`,
858
858
  R,
859
859
  S,
860
- D,
860
+ F,
861
861
  S
862
862
  ), me[S + R] = !0);
863
863
  }
864
- if (S = null, w !== void 0 && (r(w), S = "" + w), f(v) && (r(v.key), S = "" + v.key), "key" in v) {
864
+ if (S = null, w !== void 0 && (r(w), S = "" + w), c(m) && (r(m.key), S = "" + m.key), "key" in m) {
865
865
  w = {};
866
- for (var ue in v)
867
- ue !== "key" && (w[ue] = v[ue]);
868
- } else w = v;
866
+ for (var ue in m)
867
+ ue !== "key" && (w[ue] = m[ue]);
868
+ } else w = m;
869
869
  return S && h(
870
870
  w,
871
871
  typeof i == "function" ? i.displayName || i.name || "Unknown" : i
872
- ), m(
872
+ ), v(
873
873
  i,
874
874
  S,
875
875
  P,
876
876
  k,
877
- c(),
877
+ l(),
878
878
  w,
879
879
  ie,
880
880
  se
881
881
  );
882
882
  }
883
- function y(i) {
883
+ function E(i) {
884
884
  typeof i == "object" && i !== null && i.$$typeof === C && i._store && (i._store.validated = 1);
885
885
  }
886
- var T = ke, C = Symbol.for("react.transitional.element"), M = Symbol.for("react.portal"), E = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), N = Symbol.for("react.profiler"), x = Symbol.for("react.consumer"), F = Symbol.for("react.context"), s = Symbol.for("react.forward_ref"), a = Symbol.for("react.suspense"), o = Symbol.for("react.suspense_list"), l = Symbol.for("react.memo"), d = Symbol.for("react.lazy"), _ = Symbol.for("react.activity"), b = Symbol.for("react.client.reference"), j = T.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, A = Object.prototype.hasOwnProperty, B = Array.isArray, H = console.createTask ? console.createTask : function() {
886
+ var T = ke, C = Symbol.for("react.transitional.element"), M = Symbol.for("react.portal"), y = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), N = Symbol.for("react.profiler"), x = Symbol.for("react.consumer"), D = Symbol.for("react.context"), s = Symbol.for("react.forward_ref"), a = Symbol.for("react.suspense"), o = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), d = Symbol.for("react.lazy"), _ = Symbol.for("react.activity"), b = Symbol.for("react.client.reference"), j = T.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, A = Object.prototype.hasOwnProperty, B = Array.isArray, H = console.createTask ? console.createTask : function() {
887
887
  return null;
888
888
  };
889
889
  T = {
@@ -895,11 +895,11 @@ React keys must be passed directly to JSX without using spread:
895
895
  T,
896
896
  n
897
897
  )(), ve = H(u(n)), me = {};
898
- X.Fragment = E, X.jsx = function(i, v, w, R, k) {
898
+ X.Fragment = y, X.jsx = function(i, m, w, R, k) {
899
899
  var P = 1e4 > j.recentlyCreatedOwnerStacks++;
900
900
  return g(
901
901
  i,
902
- v,
902
+ m,
903
903
  w,
904
904
  !1,
905
905
  R,
@@ -907,11 +907,11 @@ React keys must be passed directly to JSX without using spread:
907
907
  P ? Error("react-stack-top-frame") : pe,
908
908
  P ? H(u(i)) : ve
909
909
  );
910
- }, X.jsxs = function(i, v, w, R, k) {
910
+ }, X.jsxs = function(i, m, w, R, k) {
911
911
  var P = 1e4 > j.recentlyCreatedOwnerStacks++;
912
912
  return g(
913
913
  i,
914
- v,
914
+ m,
915
915
  w,
916
916
  !0,
917
917
  R,
@@ -928,47 +928,48 @@ function ur() {
928
928
  }
929
929
  var W = ur();
930
930
  const br = (e, t) => {
931
- const r = (c) => [
931
+ const r = (n) => [
932
932
  e,
933
- ...Object.entries(c ?? {}).sort((n, f) => n[0].localeCompare(f[0])).flat()
933
+ ...Object.entries(n ?? {}).sort((c, h) => c[0].localeCompare(h[0])).flat()
934
934
  ].join("-");
935
935
  let u = /* @__PURE__ */ new Set();
936
- return {
936
+ const l = (n) => {
937
+ const c = r(n), h = Y(c), p = t(n), v = z(() => new Error().stack, []);
938
+ return Le(
939
+ h,
940
+ ...Object.entries(p)
941
+ ), L(() => {
942
+ if (u.has(c)) {
943
+ const g = new Error("RootContext " + c + " are mounted more than once");
944
+ throw g.stack = v, g;
945
+ }
946
+ return u.add(c), () => {
947
+ u.delete(c);
948
+ };
949
+ }), /* @__PURE__ */ W.jsx(W.Fragment, {});
950
+ };
951
+ return l.displayName = `State[${(t == null ? void 0 : t.name) ?? "??"}]`, {
937
952
  resolveCtxName: r,
938
- Root: (c) => {
939
- const n = r(c), f = Y(n), h = t(c), p = z(() => new Error().stack, []);
940
- return Le(
941
- f,
942
- ...Object.entries(h)
943
- ), L(() => {
944
- if (u.has(n)) {
945
- const m = new Error("RootContext " + n + " are mounted more than once");
946
- throw m.stack = p, m;
947
- }
948
- return u.add(n), () => {
949
- u.delete(n);
950
- };
951
- }), /* @__PURE__ */ W.jsx(W.Fragment, {});
952
- },
953
- useCtxStateStrict: (c) => {
954
- const n = r(c), f = z(() => new Error().stack, []);
953
+ Root: l,
954
+ useCtxStateStrict: (n) => {
955
+ const c = r(n), h = z(() => new Error().stack, []);
955
956
  return L(() => {
956
- if (!u.has(n)) {
957
- const h = new Error("RootContext [" + n + "] is not mounted");
958
- throw h.stack = f, h;
957
+ if (!u.has(c)) {
958
+ const p = new Error("RootContext [" + c + "] is not mounted");
959
+ throw p.stack = h, p;
959
960
  }
960
- }, [n]), Y(n);
961
+ }, [c]), Y(c);
961
962
  },
962
- useCtxState: (c) => {
963
- const n = r(c), f = z(() => new Error().stack, []);
963
+ useCtxState: (n) => {
964
+ const c = r(n), h = z(() => new Error().stack, []);
964
965
  return L(() => {
965
- if (!u.has(n)) {
966
- const h = new Error("RootContext [" + n + "] is not mounted");
967
- h.stack = f;
968
- let p = setTimeout(() => console.error(h), 1e3);
969
- return () => clearTimeout(p);
966
+ if (!u.has(c)) {
967
+ const p = new Error("RootContext [" + c + "] is not mounted");
968
+ p.stack = h;
969
+ let v = setTimeout(() => console.error(p), 1e3);
970
+ return () => clearTimeout(v);
970
971
  }
971
- }, [u.has(n)]), Y(n);
972
+ }, [u.has(c)]), Y(c);
972
973
  }
973
974
  };
974
975
  }, cr = /* @__PURE__ */ function() {
@@ -977,27 +978,27 @@ const br = (e, t) => {
977
978
  let r = e.get(t);
978
979
  return r || e.set(t, r = ((t == null ? void 0 : t.name) ?? "") + Math.random().toString()), r;
979
980
  };
980
- }(), lr = (e) => [
981
+ }(), fr = (e) => [
981
982
  ...Object.entries(e ?? {}).sort((t, r) => t[0].localeCompare(r[0])).flat()
982
- ].join("-"), gr = ({ Wrapper: e = Ie }) => {
983
- const t = Y("auto-ctx"), [r, u] = U({}), c = Me(
984
- (n, f) => {
985
- const h = cr(n), p = lr(f);
983
+ ].join("-"), gr = ({ Wrapper: e = $e }) => {
984
+ const t = Y("auto-ctx"), [r, u] = U({}), l = Me(
985
+ (n, c) => {
986
+ const h = cr(n), p = fr(c);
986
987
  return u(({
987
988
  [h]: {
988
- Component: m = n,
989
+ Component: v = n,
989
990
  subState: {
990
- [p]: g = { params: f, counter: 0 },
991
- ...y
991
+ [p]: g = { params: c, counter: 0 },
992
+ ...E
992
993
  } = {}
993
994
  } = {},
994
995
  ...T
995
996
  }) => ({
996
997
  ...T,
997
998
  [h]: {
998
- Component: m,
999
+ Component: v,
999
1000
  subState: {
1000
- ...y,
1001
+ ...E,
1001
1002
  [p]: {
1002
1003
  ...g,
1003
1004
  counter: g.counter + 1
@@ -1006,19 +1007,19 @@ const br = (e, t) => {
1006
1007
  }
1007
1008
  })), () => u(({
1008
1009
  [h]: {
1009
- Component: m = n,
1010
+ Component: v = n,
1010
1011
  subState: {
1011
- [p]: g = { params: f, counter: 0 },
1012
- ...y
1012
+ [p]: g = { params: c, counter: 0 },
1013
+ ...E
1013
1014
  } = {}
1014
1015
  } = {},
1015
1016
  ...T
1016
1017
  }) => ({
1017
1018
  ...T,
1018
1019
  [h]: {
1019
- Component: m,
1020
+ Component: v,
1020
1021
  subState: {
1021
- ...y,
1022
+ ...E,
1022
1023
  ...g.counter > 1 ? {
1023
1024
  [p]: {
1024
1025
  ...g,
@@ -1033,51 +1034,51 @@ const br = (e, t) => {
1033
1034
  );
1034
1035
  return Le(
1035
1036
  t,
1036
- ["subscribe", c],
1037
+ ["subscribe", l],
1037
1038
  ["state", r]
1038
1039
  ), /* @__PURE__ */ W.jsx(W.Fragment, { children: Object.entries(r).flatMap(
1039
- ([n, { Component: f, subState: h }]) => Object.entries(h).map(([p, { counter: m, params: g }]) => ({ key: n + p, Component: f, params: g, counter: m })).filter((p) => p.counter > 0).map(({ key: p, params: m, Component: g }) => /* @__PURE__ */ W.jsx(e, { children: /* @__PURE__ */ W.jsx(g, { ...m }) }, p))
1040
+ ([n, { Component: c, subState: h }]) => Object.entries(h).map(([p, { counter: v, params: g }]) => ({ key: n + p, Component: c, params: g, counter: v })).filter((p) => p.counter > 0).map(({ key: p, params: v, Component: g }) => /* @__PURE__ */ W.jsx(e, { children: /* @__PURE__ */ W.jsx(g, { ...v }) }, p))
1040
1041
  ) });
1041
1042
  }, _r = ({ Root: e, useCtxState: t, useCtxStateStrict: r, resolveCtxName: u }) => ({
1042
- useCtxState: (c) => {
1043
- const n = u(c), f = ar(Y("auto-ctx"), "subscribe");
1044
- return L(() => f == null ? void 0 : f(e, c), [f, n]), Y(n);
1043
+ useCtxState: (l) => {
1044
+ const n = u(l), c = ar(Y("auto-ctx"), "subscribe");
1045
+ return L(() => c == null ? void 0 : c(e, l), [c, n]), Y(n);
1045
1046
  }
1046
- }), Er = (e) => {
1047
- const [, t] = U(0), { proxy: r, finalGetter: u, openGetter: c, clean: n } = z(
1047
+ }), yr = (e) => {
1048
+ const [, t] = U(0), { proxy: r, finalGetter: u, openGetter: l, clean: n } = z(
1048
1049
  () => {
1049
- const f = /* @__PURE__ */ new Set(), h = {}, p = /* @__PURE__ */ new Map(), m = new Proxy(
1050
+ const c = /* @__PURE__ */ new Set(), h = {}, p = /* @__PURE__ */ new Map(), v = new Proxy(
1050
1051
  e == null ? void 0 : e.data,
1051
1052
  {
1052
- get(E, O) {
1053
+ get(y, O) {
1053
1054
  if (g)
1054
- return f.add(O), h[O] = E[O];
1055
+ return c.add(O), h[O] = y[O];
1055
1056
  throw new Error("now allow here");
1056
1057
  }
1057
1058
  }
1058
1059
  );
1059
- let g = !0, y = ae(() => {
1060
- [...f.values()].some((E) => {
1060
+ let g = !0, E = ae(() => {
1061
+ [...c.values()].some((y) => {
1061
1062
  var O;
1062
- return h[E] != ((O = e == null ? void 0 : e.data) == null ? void 0 : O[E]);
1063
- }) && t((E) => E + 1);
1063
+ return h[y] != ((O = e == null ? void 0 : e.data) == null ? void 0 : O[y]);
1064
+ }) && t((y) => y + 1);
1064
1065
  }, 0), T = () => {
1065
- g = !0, f.clear();
1066
+ g = !0, c.clear();
1066
1067
  }, C = () => {
1067
- g = !1, [...f.values()].filter((E) => !p.has(E)).forEach((E) => {
1068
- p.set(E, e == null ? void 0 : e.subscribe(E, y));
1069
- }), [...p.keys()].filter((E) => !f.has(E)).forEach((E) => {
1070
- let O = p.get(E);
1071
- O == null || O(), p.delete(E);
1068
+ g = !1, [...c.values()].filter((y) => !p.has(y)).forEach((y) => {
1069
+ p.set(y, e == null ? void 0 : e.subscribe(y, E));
1070
+ }), [...p.keys()].filter((y) => !c.has(y)).forEach((y) => {
1071
+ let O = p.get(y);
1072
+ O == null || O(), p.delete(y);
1072
1073
  });
1073
1074
  };
1074
- return { proxy: m, finalGetter: C, openGetter: T, clean: () => {
1075
- T(), C(), t((E) => E + 1);
1075
+ return { proxy: v, finalGetter: C, openGetter: T, clean: () => {
1076
+ T(), C(), t((y) => y + 1);
1076
1077
  } };
1077
1078
  },
1078
1079
  [e]
1079
1080
  );
1080
- return c(), setTimeout(u, 0), L(
1081
+ return l(), setTimeout(u, 0), L(
1081
1082
  () => () => n(),
1082
1083
  [n]
1083
1084
  ), r;
@@ -1095,5 +1096,5 @@ export {
1095
1096
  vr as useDataSubscribeMultiple,
1096
1097
  mr as useDataSubscribeMultipleWithDebounce,
1097
1098
  pr as useDataSubscribeWithTransform,
1098
- Er as useQuickSubscribe
1099
+ yr as useQuickSubscribe
1099
1100
  };