sibujs 4.14.0 → 4.15.0

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.
Files changed (93) hide show
  1. package/dist/browser.cjs +297 -45
  2. package/dist/browser.js +6 -7
  3. package/dist/build.cjs +2189 -573
  4. package/dist/build.js +16 -15
  5. package/dist/cdn.dev.global.js +13 -12
  6. package/dist/cdn.full.dev.global.js +14 -13
  7. package/dist/cdn.full.global.js +12 -12
  8. package/dist/cdn.global.js +12 -12
  9. package/dist/{chunk-RVR5NPFL.js → chunk-2VKTFA7C.js} +1 -1
  10. package/dist/{chunk-7ILEHTVX.js → chunk-4AEFGRYW.js} +1 -1
  11. package/dist/{chunk-4TQDTWWN.js → chunk-6IV5ZRG6.js} +5 -7
  12. package/dist/{chunk-GVAMIU6K.js → chunk-75EAQH3U.js} +2 -2
  13. package/dist/{chunk-TLS4NVIB.js → chunk-7JO7DPSS.js} +4 -4
  14. package/dist/{chunk-SVULV7O4.js → chunk-AQH7WDSE.js} +6 -8
  15. package/dist/{chunk-S37PZD6I.js → chunk-BF3WBJJQ.js} +60 -10
  16. package/dist/{chunk-LJMX4SQ7.js → chunk-BG4BP44S.js} +3 -3
  17. package/dist/{chunk-N7A6FKWW.js → chunk-D44TAGCT.js} +2 -2
  18. package/dist/{chunk-CCKUNHVU.js → chunk-DAEXQJQA.js} +1 -1
  19. package/dist/chunk-DNCQDFJJ.js +22 -0
  20. package/dist/{chunk-BKZ5N6NK.js → chunk-DNCT2UXB.js} +4 -4
  21. package/dist/{chunk-BOYKGGVD.js → chunk-DRWOD7RZ.js} +4 -4
  22. package/dist/chunk-DS5V2PRE.js +64 -0
  23. package/dist/{chunk-VM2U5LEL.js → chunk-EHSJESRN.js} +595 -123
  24. package/dist/{chunk-MIRKTVH4.js → chunk-GFM5WWPU.js} +252 -5
  25. package/dist/{chunk-52XFPGSN.js → chunk-HTPOIAAL.js} +1 -1
  26. package/dist/{chunk-3HEX6QJQ.js → chunk-I2R5QALY.js} +2 -4
  27. package/dist/{chunk-4FJSAUKB.js → chunk-IUBV5WO5.js} +1 -1
  28. package/dist/{chunk-A454RAEK.js → chunk-KIDETDMU.js} +5 -7
  29. package/dist/{chunk-JTFQ7IL4.js → chunk-KPAXG5IR.js} +7 -9
  30. package/dist/{chunk-AE32RGWX.js → chunk-LGUXYHTZ.js} +3 -3
  31. package/dist/{chunk-Y4LUM2XS.js → chunk-LQWLPQOK.js} +6 -8
  32. package/dist/{chunk-CNPT6NKV.js → chunk-MINLMJUY.js} +48 -9
  33. package/dist/{chunk-BNXRWZZV.js → chunk-OURTGOJT.js} +8 -10
  34. package/dist/{chunk-F67F77IA.js → chunk-TQ24Y3IV.js} +2 -2
  35. package/dist/{chunk-2TTRW2TE.js → chunk-UM3M5PXS.js} +8 -8
  36. package/dist/{chunk-CJ7KS3DF.js → chunk-VSTX3XSX.js} +205 -15
  37. package/dist/{chunk-HQIAL7F2.js → chunk-XPDZ2LDR.js} +2 -2
  38. package/dist/{chunk-UUIKJJIK.js → chunk-Y7JM7GY2.js} +5 -7
  39. package/dist/{chunk-QS6GMWDD.js → chunk-YAFITBOK.js} +1269 -162
  40. package/dist/data.cjs +285 -33
  41. package/dist/data.js +6 -7
  42. package/dist/devtools.cjs +289 -39
  43. package/dist/devtools.js +5 -6
  44. package/dist/{dispose-EIHHHDC7.js → dispose-3WDBYJMH.js} +3 -1
  45. package/dist/ecosystem.cjs +345 -61
  46. package/dist/ecosystem.d.cts +1 -1
  47. package/dist/ecosystem.d.ts +1 -1
  48. package/dist/ecosystem.js +10 -10
  49. package/dist/extras.cjs +568 -248
  50. package/dist/extras.d.cts +1 -1
  51. package/dist/extras.d.ts +1 -1
  52. package/dist/extras.js +27 -27
  53. package/dist/index.cjs +2134 -515
  54. package/dist/index.d.cts +628 -211
  55. package/dist/index.d.ts +628 -211
  56. package/dist/index.js +22 -15
  57. package/dist/motion.cjs +286 -30
  58. package/dist/motion.js +4 -4
  59. package/dist/patterns.cjs +301 -43
  60. package/dist/patterns.js +6 -6
  61. package/dist/performance.cjs +286 -36
  62. package/dist/performance.js +9 -9
  63. package/dist/plugins.cjs +1237 -291
  64. package/dist/plugins.d.cts +3 -1
  65. package/dist/plugins.d.ts +3 -1
  66. package/dist/plugins.js +20 -19
  67. package/dist/{renderRoute-fxgsm2Ir.d.ts → renderRoute-B84MONaO.d.cts} +2 -2
  68. package/dist/{renderRoute-DP20XwMS.d.cts → renderRoute-_yxPuEQY.d.ts} +2 -2
  69. package/dist/{routeHead-CE9SV-cH.d.cts → routeHead-DLxlq15W.d.cts} +94 -0
  70. package/dist/{routeHead-DzVxPviY.d.ts → routeHead-w8nANZ3M.d.ts} +94 -0
  71. package/dist/{ssr-NECEU4X4.js → ssr-EF3IUHTE.js} +6 -6
  72. package/dist/ssr-dom.cjs +64 -9
  73. package/dist/ssr-dom.d.cts +2 -0
  74. package/dist/ssr-dom.d.ts +2 -0
  75. package/dist/ssr-dom.js +2 -1
  76. package/dist/ssr.cjs +850 -170
  77. package/dist/ssr.d.cts +5 -3
  78. package/dist/ssr.d.ts +5 -3
  79. package/dist/ssr.js +16 -15
  80. package/dist/{tagFactory-DkytnJws.d.cts → tagFactory-BfEh69VF.d.cts} +7 -0
  81. package/dist/{tagFactory-Bnd_Nph9.d.ts → tagFactory-pSYiLYyh.d.ts} +7 -0
  82. package/dist/testing.cjs +817 -132
  83. package/dist/testing.d.cts +4 -2
  84. package/dist/testing.d.ts +4 -2
  85. package/dist/testing.js +18 -17
  86. package/dist/track-core-0edROAF5.d.ts +187 -0
  87. package/dist/track-core-DN5fYLWi.d.cts +187 -0
  88. package/dist/ui.cjs +293 -43
  89. package/dist/ui.js +10 -12
  90. package/dist/widgets.cjs +285 -27
  91. package/dist/widgets.js +7 -7
  92. package/package.json +1 -1
  93. package/dist/chunk-7ZHH77QA.js +0 -9
package/dist/data.cjs CHANGED
@@ -162,6 +162,12 @@ function reportError(error, context) {
162
162
  });
163
163
  }
164
164
 
165
+ // src/utils/globalSingleton.ts
166
+ function globalSingleton(key, create) {
167
+ const g = globalThis;
168
+ return g[key] ?? (g[key] = create());
169
+ }
170
+
165
171
  // src/core/rendering/adoptScope.ts
166
172
  var current = null;
167
173
  function currentSink() {
@@ -189,12 +195,19 @@ function holdHydration(sessions, entry) {
189
195
  }
190
196
 
191
197
  // src/core/rendering/dispose.ts
198
+ var state2 = globalSingleton(/* @__PURE__ */ Symbol.for("sibujs.disposers.v1"), () => ({
199
+ disposers: /* @__PURE__ */ new WeakMap(),
200
+ captures: [],
201
+ bindings: { count: 0 }
202
+ }));
203
+ var elementDisposers = state2.disposers;
204
+ var bindings = state2.bindings;
192
205
  function resolveCapture(capture) {
193
206
  let frame = capture;
194
207
  while (frame?.closed) frame = frame.forwardTo;
195
208
  return frame ?? null;
196
209
  }
197
- var registrationCaptures = [];
210
+ var registrationCaptures = state2.captures;
198
211
  function currentDisposerCapture() {
199
212
  return resolveCapture(registrationCaptures[registrationCaptures.length - 1]);
200
213
  }
@@ -370,6 +383,201 @@ function bindOwnerScope(fn) {
370
383
  return (...args) => runWithOwnerScope(scope, () => fn(...args));
371
384
  }
372
385
  var currentStructOwner = null;
386
+ var frozenOwners = 0;
387
+ var ACTIVE = 0;
388
+ var PAUSED = 1;
389
+ var ENDED = 2;
390
+ var NOOP = () => {
391
+ };
392
+ var skippedWhileHeld = /* @__PURE__ */ new Set();
393
+ var waiters = /* @__PURE__ */ new Set();
394
+ var heldRoots = /* @__PURE__ */ new Set();
395
+ function ownerState(tok) {
396
+ let state3 = ACTIVE;
397
+ for (let t = tok; t !== null; ) {
398
+ const o = t.sub;
399
+ if (o === null) return ENDED;
400
+ if (o._frozen === true) state3 = PAUSED;
401
+ t = o._owner ?? null;
402
+ }
403
+ return state3;
404
+ }
405
+ var endWatchers = /* @__PURE__ */ new Set();
406
+ var stateWatchers = /* @__PURE__ */ new Set();
407
+ var stateCheckQueued = false;
408
+ function queueStateCheck() {
409
+ if (stateCheckQueued || stateWatchers.size === 0) return;
410
+ stateCheckQueued = true;
411
+ queueMicrotask(() => {
412
+ stateCheckQueued = false;
413
+ for (const watcher of [...stateWatchers]) {
414
+ if (!stateWatchers.has(watcher)) continue;
415
+ const state3 = watcher.check.state();
416
+ if (state3 === ENDED) stateWatchers.delete(watcher);
417
+ if (state3 === ENDED || state3 === watcher.last) continue;
418
+ watcher.last = state3;
419
+ try {
420
+ watcher.listener(state3);
421
+ } catch (err) {
422
+ reportError(err, { phase: "effect" });
423
+ }
424
+ }
425
+ });
426
+ }
427
+ var ALWAYS_ACTIVE = Object.assign(() => false, {
428
+ state: () => ACTIVE,
429
+ wait: (onActive) => {
430
+ onActive();
431
+ return NOOP;
432
+ },
433
+ onEnd: () => NOOP,
434
+ run: (fn) => fn(),
435
+ onChange: () => NOOP,
436
+ within: () => false
437
+ });
438
+ function captureFrozen() {
439
+ const tok = currentStructOwner;
440
+ if (tok === null) return ALWAYS_ACTIVE;
441
+ const state3 = () => ownerState(tok);
442
+ const check = Object.assign(() => state3() !== ACTIVE, {
443
+ state: state3,
444
+ wait: (onActive, onEnd) => {
445
+ const now = state3();
446
+ if (now !== PAUSED) {
447
+ (now === ACTIVE ? onActive : onEnd)();
448
+ return NOOP;
449
+ }
450
+ const waiter = { check, onActive, onEnd };
451
+ waiters.add(waiter);
452
+ return () => {
453
+ waiters.delete(waiter);
454
+ };
455
+ },
456
+ onEnd: (onEnd) => {
457
+ if (state3() === ENDED) {
458
+ onEnd();
459
+ return NOOP;
460
+ }
461
+ const watcher = { check, onActive: NOOP, onEnd };
462
+ endWatchers.add(watcher);
463
+ return () => {
464
+ endWatchers.delete(watcher);
465
+ };
466
+ },
467
+ run: (fn) => {
468
+ const prev = currentStructOwner;
469
+ currentStructOwner = tok.sub === null ? null : tok;
470
+ try {
471
+ return fn();
472
+ } finally {
473
+ currentStructOwner = prev;
474
+ }
475
+ },
476
+ onChange: (listener) => {
477
+ const last = state3();
478
+ if (last === ENDED) return NOOP;
479
+ const watcher = { check, last, listener };
480
+ stateWatchers.add(watcher);
481
+ return () => {
482
+ stateWatchers.delete(watcher);
483
+ };
484
+ },
485
+ within: (owner) => {
486
+ const target = owner.run(() => currentStructOwner);
487
+ if (target === null) return false;
488
+ for (let t = tok; t !== null; ) {
489
+ if (t === target) return true;
490
+ const o = t.sub;
491
+ if (o === null) return false;
492
+ t = o._owner ?? null;
493
+ }
494
+ return false;
495
+ }
496
+ });
497
+ return check;
498
+ }
499
+ function holdSubtree(root) {
500
+ heldRoots.add(root);
501
+ return () => {
502
+ if (heldRoots.delete(root)) settleHeld();
503
+ };
504
+ }
505
+ function isHeld(sub) {
506
+ if (frozenOwners !== 0 && hasFrozenOwner(sub)) return true;
507
+ if (heldRoots.size !== 0) {
508
+ const node = sub._errorNode;
509
+ if (node != null) {
510
+ for (const root of heldRoots) if (root.contains(node)) return true;
511
+ }
512
+ }
513
+ return false;
514
+ }
515
+ function notifyEnded() {
516
+ for (const watcher of stateWatchers) if (watcher.check.state() === ENDED) stateWatchers.delete(watcher);
517
+ let ended = null;
518
+ for (const watcher of endWatchers) {
519
+ if (watcher.check.state() !== ENDED) continue;
520
+ endWatchers.delete(watcher);
521
+ (ended ?? (ended = [])).push(watcher);
522
+ }
523
+ if (ended === null) return;
524
+ for (const watcher of ended) {
525
+ try {
526
+ watcher.onEnd();
527
+ } catch (err) {
528
+ reportError(err, { phase: "cleanup" });
529
+ }
530
+ }
531
+ }
532
+ function dropReleasedSkipped() {
533
+ for (const sub of skippedWhileHeld) {
534
+ if (sub._disposed === true || sub.depsHead == null) skippedWhileHeld.delete(sub);
535
+ }
536
+ }
537
+ function settleHeld() {
538
+ for (const sub of skippedWhileHeld) {
539
+ if (sub._disposed === true) skippedWhileHeld.delete(sub);
540
+ else if (!isHeld(sub)) {
541
+ skippedWhileHeld.delete(sub);
542
+ if (!pendingSet.has(sub)) {
543
+ pendingSet.add(sub);
544
+ pendingQueue.push(sub);
545
+ }
546
+ }
547
+ }
548
+ if (frozenOwners === 0 && heldRoots.size === 0) skippedWhileHeld.clear();
549
+ let ready = null;
550
+ for (const waiter of waiters) {
551
+ if (waiter.check.state() === PAUSED) continue;
552
+ waiters.delete(waiter);
553
+ (ready ?? (ready = [])).push(waiter);
554
+ }
555
+ if (ready !== null) {
556
+ const settle = ready;
557
+ queueMicrotask(() => {
558
+ for (const waiter of settle) {
559
+ const state3 = waiter.check.state();
560
+ if (state3 === PAUSED) waiters.add(waiter);
561
+ else
562
+ try {
563
+ (state3 === ACTIVE ? waiter.onActive : waiter.onEnd)();
564
+ } catch (err) {
565
+ reportError(err, { phase: "effect" });
566
+ }
567
+ }
568
+ });
569
+ }
570
+ if (pendingQueue.length > 0) drainNotificationQueue();
571
+ }
572
+ function hasFrozenOwner(sub) {
573
+ for (let t = sub._owner ?? null; t !== null; ) {
574
+ const o = t.sub;
575
+ if (o === null) return false;
576
+ if (o._frozen === true) return true;
577
+ t = o._owner ?? null;
578
+ }
579
+ return false;
580
+ }
373
581
  var subscriberEpochCounter = 0;
374
582
  function retrack(effectFn, subscriber) {
375
583
  const prev = currentSubscriber;
@@ -477,6 +685,20 @@ function structuralBinding(commit, ownerNode) {
477
685
  } finally {
478
686
  currentStructOwner = prev;
479
687
  }
688
+ },
689
+ freeze: () => {
690
+ const s = sub;
691
+ if (s._disposed || s._frozen) return;
692
+ s._frozen = true;
693
+ frozenOwners++;
694
+ queueStateCheck();
695
+ },
696
+ thaw: () => {
697
+ if (!sub._frozen) return;
698
+ sub._frozen = false;
699
+ frozenOwners--;
700
+ queueStateCheck();
701
+ settleHeld();
480
702
  }
481
703
  };
482
704
  }
@@ -505,20 +727,34 @@ function createBinding(commit, ownerNode, structural) {
505
727
  subscriber._errorNode = ownerNode;
506
728
  subscriber._tok = null;
507
729
  subscriber._owner = null;
730
+ subscriber._frozen = false;
508
731
  if (structural) subscriber._tok = { sub: subscriber };
509
732
  try {
510
733
  run();
511
734
  } catch (err) {
512
735
  subscriber._disposed = true;
513
736
  subscriber._errorNode = void 0;
514
- if (subscriber._tok != null) subscriber._tok.sub = null;
737
+ if (subscriber._tok != null) {
738
+ subscriber._tok.sub = null;
739
+ if (endWatchers.size !== 0 || stateWatchers.size !== 0) notifyEnded();
740
+ }
515
741
  cleanup(subscriber);
516
742
  throw err;
517
743
  }
518
744
  subscriber._dispose = () => {
519
745
  subscriber._disposed = true;
746
+ const wasFrozen = subscriber._frozen === true;
747
+ if (wasFrozen) {
748
+ subscriber._frozen = false;
749
+ frozenOwners--;
750
+ }
520
751
  subscriber._errorNode = void 0;
521
- if (subscriber._tok != null) subscriber._tok.sub = null;
752
+ if (subscriber._tok != null) {
753
+ subscriber._tok.sub = null;
754
+ if (endWatchers.size !== 0 || stateWatchers.size !== 0) notifyEnded();
755
+ if (skippedWhileHeld.size !== 0) dropReleasedSkipped();
756
+ if (wasFrozen || waiters.size !== 0) settleHeld();
757
+ }
522
758
  cleanup(subscriber);
523
759
  };
524
760
  return subscriber;
@@ -628,6 +864,10 @@ function runPendingOwners(sub) {
628
864
  }
629
865
  }
630
866
  function runQueued(sub) {
867
+ if ((frozenOwners !== 0 || heldRoots.size !== 0) && isHeld(sub)) {
868
+ skippedWhileHeld.add(sub);
869
+ return;
870
+ }
631
871
  if (quarantined.size > 0 && quarantined.has(sub)) return;
632
872
  if (sub._hasComputedDep === true && !depsChanged(sub)) return;
633
873
  if (tickRepeat(sub)) {
@@ -775,7 +1015,7 @@ function forEachSubscriber(signal2, visit) {
775
1015
  }
776
1016
 
777
1017
  // src/reactivity/track.ts
778
- var _runtimeVersion = true ? "4.14.0" : "dev";
1018
+ var _runtimeVersion = true ? "4.15.0" : "dev";
779
1019
  var REGISTRY_KEY = /* @__PURE__ */ Symbol.for("sibujs.reactive.v1");
780
1020
  function resolveReactiveApi() {
781
1021
  const g = globalThis;
@@ -811,6 +1051,8 @@ function resolveReactiveApi() {
811
1051
  runWithOwnerScope,
812
1052
  bindOwnerScope,
813
1053
  structuralBinding,
1054
+ captureFrozen,
1055
+ holdSubtree,
814
1056
  version: _runtimeVersion
815
1057
  };
816
1058
  g[REGISTRY_KEY] = local;
@@ -838,6 +1080,22 @@ var getOwnerScope2 = API.getOwnerScope ?? getOwnerScope;
838
1080
  var runWithOwnerScope2 = API.runWithOwnerScope ?? runWithOwnerScope;
839
1081
  var bindOwnerScope2 = API.bindOwnerScope ?? bindOwnerScope;
840
1082
  var structuralBinding2 = API.structuralBinding ?? ((commit, ownerNode) => ({ stop: API.reactiveBinding(commit, ownerNode), run: (fn) => fn() }));
1083
+ var captureFrozen2 = API.captureFrozen ?? (() => Object.assign(() => false, {
1084
+ state: () => 0,
1085
+ wait: (onActive) => {
1086
+ onActive();
1087
+ return () => {
1088
+ };
1089
+ },
1090
+ onEnd: () => () => {
1091
+ },
1092
+ run: (fn) => fn(),
1093
+ onChange: () => () => {
1094
+ },
1095
+ within: () => false
1096
+ }));
1097
+ var holdSubtree2 = API.holdSubtree ?? (() => () => {
1098
+ });
841
1099
 
842
1100
  // src/core/devtoolsHook.ts
843
1101
  function emitDevtools(hook, event, payload) {
@@ -1234,7 +1492,7 @@ var isBatching = API2.isBatching;
1234
1492
  // src/core/signals/signal.ts
1235
1493
  var _g2 = globalThis;
1236
1494
  function signal(initial, options) {
1237
- const state2 = {
1495
+ const state3 = {
1238
1496
  value: initial,
1239
1497
  __v: 0,
1240
1498
  __sc: 0,
@@ -1247,67 +1505,61 @@ function signal(initial, options) {
1247
1505
  };
1248
1506
  const debugName = DEV ? options?.name : void 0;
1249
1507
  const equalsFn = options?.equals;
1250
- if (debugName) state2.__name = debugName;
1508
+ if (debugName) state3.__name = debugName;
1251
1509
  function get() {
1252
- recordDependency2(state2);
1253
- return state2.value;
1510
+ recordDependency2(state3);
1511
+ return state3.value;
1254
1512
  }
1255
- get.__signal = state2;
1513
+ get.__signal = state3;
1256
1514
  if (debugName) get.__name = debugName;
1257
1515
  let set;
1258
1516
  if (equalsFn) {
1259
1517
  set = (next) => {
1260
- const prev = state2.value;
1518
+ const prev = state3.value;
1261
1519
  const newValue = typeof next === "function" ? next(prev) : next;
1262
1520
  if (equalsFn(prev, newValue)) return;
1263
- state2.value = newValue;
1264
- state2.__v++;
1521
+ state3.value = newValue;
1522
+ state3.__v++;
1265
1523
  if (DEV) {
1266
1524
  const hook = _g2.__SIBU_DEVTOOLS_GLOBAL_HOOK__;
1267
- if (hook) emitDevtools(hook, "signal:update", { signal: state2, name: debugName, oldValue: prev, newValue });
1525
+ if (hook) emitDevtools(hook, "signal:update", { signal: state3, name: debugName, oldValue: prev, newValue });
1268
1526
  }
1269
- if (!enqueueBatchedSignal(state2)) {
1270
- notifySubscribers2(state2);
1527
+ if (!enqueueBatchedSignal(state3)) {
1528
+ notifySubscribers2(state3);
1271
1529
  }
1272
1530
  };
1273
1531
  } else if (DEV) {
1274
1532
  set = (next) => {
1275
- const prev = state2.value;
1533
+ const prev = state3.value;
1276
1534
  const newValue = typeof next === "function" ? next(prev) : next;
1277
1535
  if (Object.is(newValue, prev)) return;
1278
- state2.value = newValue;
1279
- state2.__v++;
1536
+ state3.value = newValue;
1537
+ state3.__v++;
1280
1538
  const hook = _g2.__SIBU_DEVTOOLS_GLOBAL_HOOK__;
1281
- if (hook) emitDevtools(hook, "signal:update", { signal: state2, name: debugName, oldValue: prev, newValue });
1282
- if (!enqueueBatchedSignal(state2)) {
1283
- notifySubscribers2(state2);
1539
+ if (hook) emitDevtools(hook, "signal:update", { signal: state3, name: debugName, oldValue: prev, newValue });
1540
+ if (!enqueueBatchedSignal(state3)) {
1541
+ notifySubscribers2(state3);
1284
1542
  }
1285
1543
  };
1286
1544
  } else {
1287
1545
  set = (next) => {
1288
- const prev = state2.value;
1546
+ const prev = state3.value;
1289
1547
  const newValue = typeof next === "function" ? next(prev) : next;
1290
1548
  if (Object.is(newValue, prev)) return;
1291
- state2.value = newValue;
1292
- state2.__v++;
1293
- if (!enqueueBatchedSignal(state2)) {
1294
- notifySubscribers2(state2);
1549
+ state3.value = newValue;
1550
+ state3.__v++;
1551
+ if (!enqueueBatchedSignal(state3)) {
1552
+ notifySubscribers2(state3);
1295
1553
  }
1296
1554
  };
1297
1555
  }
1298
1556
  if (DEV) {
1299
1557
  const hook = _g2.__SIBU_DEVTOOLS_GLOBAL_HOOK__;
1300
- if (hook) emitDevtools(hook, "signal:create", { signal: state2, name: debugName, getter: get, initial });
1558
+ if (hook) emitDevtools(hook, "signal:create", { signal: state3, name: debugName, getter: get, initial });
1301
1559
  }
1302
1560
  return [get, set];
1303
1561
  }
1304
1562
 
1305
- // src/utils/globalSingleton.ts
1306
- function globalSingleton(key, create) {
1307
- const g = globalThis;
1308
- return g[key] ?? (g[key] = create());
1309
- }
1310
-
1311
1563
  // src/utils/guards.ts
1312
1564
  var UNSAFE_KEYS = /* @__PURE__ */ new Set(["__proto__", "constructor", "prototype"]);
1313
1565
  function isUnsafeKey(key) {
package/dist/data.js CHANGED
@@ -23,17 +23,16 @@ import {
23
23
  withLoader,
24
24
  withRetry,
25
25
  withholdTransfer
26
- } from "./chunk-SVULV7O4.js";
26
+ } from "./chunk-AQH7WDSE.js";
27
27
  import "./chunk-3HZOSMPX.js";
28
28
  import "./chunk-62BDYGAG.js";
29
- import "./chunk-N7A6FKWW.js";
30
- import "./chunk-7ZHH77QA.js";
31
- import "./chunk-AE32RGWX.js";
29
+ import "./chunk-D44TAGCT.js";
30
+ import "./chunk-LGUXYHTZ.js";
32
31
  import "./chunk-B3HOT4TK.js";
33
32
  import "./chunk-UYTYNCMZ.js";
34
- import "./chunk-4FJSAUKB.js";
35
- import "./chunk-MIRKTVH4.js";
36
- import "./chunk-S37PZD6I.js";
33
+ import "./chunk-IUBV5WO5.js";
34
+ import "./chunk-GFM5WWPU.js";
35
+ import "./chunk-BF3WBJJQ.js";
37
36
  import "./chunk-NT3ZYB5S.js";
38
37
  import "./chunk-R5U7XKVJ.js";
39
38
  export {