@pie-element/venn-classification 0.1.1-next.4 → 0.1.1-next.6

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,16 +1,16 @@
1
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/disclose-version.js
1
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/disclose-version.js
2
2
  if (typeof window !== "undefined") {
3
3
  var _window$__svelte, _window;
4
4
  ((_window$__svelte = (_window = window).__svelte ?? (_window.__svelte = {})).v ?? (_window$__svelte.v = /* @__PURE__ */ new Set())).add("5");
5
5
  }
6
6
  //#endregion
7
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/constants.js
7
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/constants.js
8
8
  var HYDRATION_ERROR = {};
9
9
  var UNINITIALIZED = Symbol("uninitialized");
10
10
  var NAMESPACE_SVG = "http://www.w3.org/2000/svg";
11
11
  var NAMESPACE_MATHML = "http://www.w3.org/1998/Math/MathML";
12
12
  //#endregion
13
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/shared/utils.js
13
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/shared/utils.js
14
14
  var is_array = Array.isArray;
15
15
  var index_of = Array.prototype.indexOf;
16
16
  var includes = Array.prototype.includes;
@@ -132,6 +132,8 @@ var REACTION_IS_UPDATING = 1 << 21;
132
132
  var ASYNC = 1 << 22;
133
133
  var ERROR_VALUE = 1 << 23;
134
134
  var STATE_SYMBOL = Symbol("$state");
135
+ /** Marks component export objects, so that `proxy(...)` leaves them untouched */
136
+ var COMPONENT_SYMBOL = Symbol("component");
135
137
  var LEGACY_PROPS = Symbol("legacy props");
136
138
  var LOADING_ATTR_SYMBOL = Symbol("");
137
139
  var ATTRIBUTES_CACHE = Symbol("attributes");
@@ -148,106 +150,6 @@ var STALE_REACTION = new class StaleReactionError extends Error {
148
150
  }();
149
151
  var IS_XHTML = !!globalThis.document?.contentType && /* @__PURE__ */ globalThis.document.contentType.includes("xml");
150
152
  /**
151
- * `%name%(...)` can only be used during component initialisation
152
- * @param {string} name
153
- * @returns {never}
154
- */
155
- function lifecycle_outside_component(name) {
156
- throw new Error(`https://svelte.dev/e/lifecycle_outside_component`);
157
- }
158
- //#endregion
159
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/errors.js
160
- /**
161
- * Cannot create a `$derived(...)` with an `await` expression outside of an effect tree
162
- * @returns {never}
163
- */
164
- function async_derived_orphan() {
165
- throw new Error(`https://svelte.dev/e/async_derived_orphan`);
166
- }
167
- /**
168
- * Keyed each block has duplicate key `%value%` at indexes %a% and %b%
169
- * @param {string} a
170
- * @param {string} b
171
- * @param {string | undefined | null} [value]
172
- * @returns {never}
173
- */
174
- function each_key_duplicate(a, b, value) {
175
- throw new Error(`https://svelte.dev/e/each_key_duplicate`);
176
- }
177
- /**
178
- * `%rune%` cannot be used inside an effect cleanup function
179
- * @param {string} rune
180
- * @returns {never}
181
- */
182
- function effect_in_teardown(rune) {
183
- throw new Error(`https://svelte.dev/e/effect_in_teardown`);
184
- }
185
- /**
186
- * Effect cannot be created inside a `$derived` value that was not itself created inside an effect
187
- * @returns {never}
188
- */
189
- function effect_in_unowned_derived() {
190
- throw new Error(`https://svelte.dev/e/effect_in_unowned_derived`);
191
- }
192
- /**
193
- * `%rune%` can only be used inside an effect (e.g. during component initialisation)
194
- * @param {string} rune
195
- * @returns {never}
196
- */
197
- function effect_orphan(rune) {
198
- throw new Error(`https://svelte.dev/e/effect_orphan`);
199
- }
200
- /**
201
- * Maximum update depth exceeded. This typically indicates that an effect reads and writes the same piece of state
202
- * @returns {never}
203
- */
204
- function effect_update_depth_exceeded() {
205
- throw new Error(`https://svelte.dev/e/effect_update_depth_exceeded`);
206
- }
207
- /**
208
- * Failed to hydrate the application
209
- * @returns {never}
210
- */
211
- function hydration_failed() {
212
- throw new Error(`https://svelte.dev/e/hydration_failed`);
213
- }
214
- /**
215
- * Cannot do `bind:%key%={undefined}` when `%key%` has a fallback value
216
- * @param {string} key
217
- * @returns {never}
218
- */
219
- function props_invalid_value(key) {
220
- throw new Error(`https://svelte.dev/e/props_invalid_value`);
221
- }
222
- /**
223
- * Property descriptors defined on `$state` objects must contain `value` and always be `enumerable`, `configurable` and `writable`.
224
- * @returns {never}
225
- */
226
- function state_descriptors_fixed() {
227
- throw new Error(`https://svelte.dev/e/state_descriptors_fixed`);
228
- }
229
- /**
230
- * Cannot set prototype of `$state` object
231
- * @returns {never}
232
- */
233
- function state_prototype_fixed() {
234
- throw new Error(`https://svelte.dev/e/state_prototype_fixed`);
235
- }
236
- /**
237
- * Updating state inside `$derived(...)`, `$inspect(...)` or a template expression is forbidden. If the value should not be reactive, declare it without `$state`
238
- * @returns {never}
239
- */
240
- function state_unsafe_mutation() {
241
- throw new Error(`https://svelte.dev/e/state_unsafe_mutation`);
242
- }
243
- /**
244
- * A `<svelte:boundary>` `reset` function cannot be called while an error is still being handled
245
- * @returns {never}
246
- */
247
- function svelte_boundary_reset_onerror() {
248
- throw new Error(`https://svelte.dev/e/svelte_boundary_reset_onerror`);
249
- }
250
- /**
251
153
  * Reading a derived belonging to a now-destroyed effect may result in stale values
252
154
  */
253
155
  function derived_inert() {
@@ -267,7 +169,7 @@ function svelte_boundary_reset_noop() {
267
169
  console.warn(`https://svelte.dev/e/svelte_boundary_reset_noop`);
268
170
  }
269
171
  //#endregion
270
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/hydration.js
172
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/hydration.js
271
173
  /** @import { TemplateNode } from '#client' */
272
174
  /**
273
175
  * Use this variable to guard everything related to hydration code so it can be treeshaken out
@@ -346,7 +248,7 @@ function read_hydration_instruction(node) {
346
248
  return node.data;
347
249
  }
348
250
  //#endregion
349
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/equality.js
251
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/equality.js
350
252
  /** @import { Equals } from '#client' */
351
253
  /** @type {Equals} */
352
254
  function equals(value) {
@@ -364,14 +266,114 @@ function safe_not_equal(a, b) {
364
266
  function safe_equals(value) {
365
267
  return !safe_not_equal(value, this.v);
366
268
  }
269
+ /**
270
+ * `%name%(...)` can only be used during component initialisation
271
+ * @param {string} name
272
+ * @returns {never}
273
+ */
274
+ function lifecycle_outside_component(name) {
275
+ throw new Error(`https://svelte.dev/e/lifecycle_outside_component`);
276
+ }
277
+ //#endregion
278
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/errors.js
279
+ /**
280
+ * Cannot create a `$derived(...)` with an `await` expression outside of an effect tree
281
+ * @returns {never}
282
+ */
283
+ function async_derived_orphan() {
284
+ throw new Error(`https://svelte.dev/e/async_derived_orphan`);
285
+ }
286
+ /**
287
+ * Keyed each block has duplicate key `%value%` at indexes %a% and %b%
288
+ * @param {string} a
289
+ * @param {string} b
290
+ * @param {string | undefined | null} [value]
291
+ * @returns {never}
292
+ */
293
+ function each_key_duplicate(a, b, value) {
294
+ throw new Error(`https://svelte.dev/e/each_key_duplicate`);
295
+ }
296
+ /**
297
+ * `%rune%` cannot be used inside an effect cleanup function
298
+ * @param {string} rune
299
+ * @returns {never}
300
+ */
301
+ function effect_in_teardown(rune) {
302
+ throw new Error(`https://svelte.dev/e/effect_in_teardown`);
303
+ }
304
+ /**
305
+ * Effect cannot be created inside a `$derived` value that was not itself created inside an effect
306
+ * @returns {never}
307
+ */
308
+ function effect_in_unowned_derived() {
309
+ throw new Error(`https://svelte.dev/e/effect_in_unowned_derived`);
310
+ }
311
+ /**
312
+ * `%rune%` can only be used inside an effect (e.g. during component initialisation)
313
+ * @param {string} rune
314
+ * @returns {never}
315
+ */
316
+ function effect_orphan(rune) {
317
+ throw new Error(`https://svelte.dev/e/effect_orphan`);
318
+ }
319
+ /**
320
+ * Maximum update depth exceeded. This typically indicates that an effect reads and writes the same piece of state
321
+ * @returns {never}
322
+ */
323
+ function effect_update_depth_exceeded() {
324
+ throw new Error(`https://svelte.dev/e/effect_update_depth_exceeded`);
325
+ }
326
+ /**
327
+ * Failed to hydrate the application
328
+ * @returns {never}
329
+ */
330
+ function hydration_failed() {
331
+ throw new Error(`https://svelte.dev/e/hydration_failed`);
332
+ }
333
+ /**
334
+ * Cannot do `bind:%key%={undefined}` when `%key%` has a fallback value
335
+ * @param {string} key
336
+ * @returns {never}
337
+ */
338
+ function props_invalid_value(key) {
339
+ throw new Error(`https://svelte.dev/e/props_invalid_value`);
340
+ }
341
+ /**
342
+ * Property descriptors defined on `$state` objects must contain `value` and always be `enumerable`, `configurable` and `writable`.
343
+ * @returns {never}
344
+ */
345
+ function state_descriptors_fixed() {
346
+ throw new Error(`https://svelte.dev/e/state_descriptors_fixed`);
347
+ }
348
+ /**
349
+ * Cannot set prototype of `$state` object
350
+ * @returns {never}
351
+ */
352
+ function state_prototype_fixed() {
353
+ throw new Error(`https://svelte.dev/e/state_prototype_fixed`);
354
+ }
355
+ /**
356
+ * Updating state inside `$derived(...)`, `$inspect(...)` or a template expression is forbidden. If the value should not be reactive, declare it without `$state`
357
+ * @returns {never}
358
+ */
359
+ function state_unsafe_mutation() {
360
+ throw new Error(`https://svelte.dev/e/state_unsafe_mutation`);
361
+ }
362
+ /**
363
+ * A `<svelte:boundary>` `reset` function cannot be called while an error is still being handled
364
+ * @returns {never}
365
+ */
366
+ function svelte_boundary_reset_onerror() {
367
+ throw new Error(`https://svelte.dev/e/svelte_boundary_reset_onerror`);
368
+ }
367
369
  //#endregion
368
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/flags/index.js
370
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/flags/index.js
369
371
  /** True if experimental.async=true */
370
372
  var async_mode_flag = false;
371
373
  /** True if we're not certain that we only have Svelte 5 code in the compilation */
372
374
  var legacy_mode_flag = false;
373
375
  //#endregion
374
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/context.js
376
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/context.js
375
377
  /** @import { ComponentContext, DevStackEntry, Effect } from '#client' */
376
378
  /** @type {ComponentContext | null} */
377
379
  var component_context = null;
@@ -416,14 +418,22 @@ function pop(component) {
416
418
  if (component !== void 0) context.x = component;
417
419
  context.i = true;
418
420
  component_context = context.p;
419
- return component ?? {};
421
+ return mark_as_component(component);
422
+ }
423
+ /**
424
+ * Add a symbol to the object (or create one if undefined) to mark it as a component so it isn't proxified.
425
+ * @param {any} component
426
+ */
427
+ function mark_as_component(component = {}) {
428
+ define_property(component, COMPONENT_SYMBOL, { value: true });
429
+ return component;
420
430
  }
421
431
  /** @returns {boolean} */
422
432
  function is_runes() {
423
433
  return !legacy_mode_flag || component_context !== null && component_context.l === null;
424
434
  }
425
435
  //#endregion
426
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/task.js
436
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/task.js
427
437
  /** @type {Array<() => void>} */
428
438
  var micro_tasks = [];
429
439
  function run_micro_tasks() {
@@ -449,40 +459,8 @@ function queue_micro_task(fn) {
449
459
  function flush_tasks() {
450
460
  while (micro_tasks.length > 0) run_micro_tasks();
451
461
  }
452
- /**
453
- * @param {unknown} error
454
- */
455
- function handle_error(error) {
456
- var effect = active_effect;
457
- if (effect === null) {
458
- /** @type {Derived} */ active_reaction.f |= ERROR_VALUE;
459
- return error;
460
- }
461
- if ((effect.f & 32768) === 0 && (effect.f & 4) === 0) throw error;
462
- invoke_error_boundary(error, effect);
463
- }
464
- /**
465
- * @param {unknown} error
466
- * @param {Effect | null} effect
467
- */
468
- function invoke_error_boundary(error, effect) {
469
- if (effect !== null && (effect.f & 16384) !== 0) return;
470
- while (effect !== null) {
471
- if ((effect.f & 128) !== 0) {
472
- if ((effect.f & 32768) === 0) throw error;
473
- try {
474
- /** @type {Boundary} */ effect.b.error(error);
475
- return;
476
- } catch (e) {
477
- error = e;
478
- }
479
- }
480
- effect = effect.parent;
481
- }
482
- throw error;
483
- }
484
462
  //#endregion
485
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/status.js
463
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/status.js
486
464
  /** @import { Derived, Signal } from '#client' */
487
465
  var STATUS_MASK = ~(DIRTY | MAYBE_DIRTY | CLEAN);
488
466
  /**
@@ -501,7 +479,7 @@ function update_derived_status(derived) {
501
479
  else set_signal_status(derived, MAYBE_DIRTY);
502
480
  }
503
481
  //#endregion
504
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/utils.js
482
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/utils.js
505
483
  /** @import { Derived, Effect, Value } from '#client' */
506
484
  /**
507
485
  * @param {Value[] | null} deps
@@ -529,7 +507,7 @@ function defer_effect(effect, dirty_effects, maybe_dirty_effects) {
529
507
  set_signal_status(effect, CLEAN);
530
508
  }
531
509
  //#endregion
532
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/store.js
510
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/store.js
533
511
  /**
534
512
  * We set this to `true` when updating a store so that we correctly
535
513
  * schedule effects if the update takes place inside a `$:` effect
@@ -559,7 +537,7 @@ function capture_store_binding(fn) {
559
537
  }
560
538
  }
561
539
  //#endregion
562
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/bindings/shared.js
540
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/bindings/shared.js
563
541
  /**
564
542
  * @template T
565
543
  * @param {() => T} fn
@@ -577,482 +555,8 @@ function without_reactive_context(fn) {
577
555
  }
578
556
  }
579
557
  //#endregion
580
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/reactivity/create-subscriber.js
581
- /**
582
- * Returns a `subscribe` function that integrates external event-based systems with Svelte's reactivity.
583
- * It's particularly useful for integrating with web APIs like `MediaQuery`, `IntersectionObserver`, or `WebSocket`.
584
- *
585
- * If `subscribe` is called inside an effect (including indirectly, for example inside a getter),
586
- * the `start` callback will be called with an `update` function. Whenever `update` is called, the effect re-runs.
587
- *
588
- * If `start` returns a cleanup function, it will be called when the effect is destroyed.
589
- *
590
- * If `subscribe` is called in multiple effects, `start` will only be called once as long as the effects
591
- * are active, and the returned teardown function will only be called when all effects are destroyed.
592
- *
593
- * It's best understood with an example. Here's an implementation of [`MediaQuery`](https://svelte.dev/docs/svelte/svelte-reactivity#MediaQuery):
594
- *
595
- * ```js
596
- * import { createSubscriber } from 'svelte/reactivity';
597
- * import { on } from 'svelte/events';
598
- *
599
- * export class MediaQuery {
600
- * #query;
601
- * #subscribe;
602
- *
603
- * constructor(query) {
604
- * this.#query = window.matchMedia(`(${query})`);
605
- *
606
- * this.#subscribe = createSubscriber((update) => {
607
- * // when the `change` event occurs, re-run any effects that read `this.current`
608
- * const off = on(this.#query, 'change', update);
609
- *
610
- * // stop listening when all the effects are destroyed
611
- * return () => off();
612
- * });
613
- * }
614
- *
615
- * get current() {
616
- * // This makes the getter reactive, if read in an effect
617
- * this.#subscribe();
618
- *
619
- * // Return the current state of the query, whether or not we're in an effect
620
- * return this.#query.matches;
621
- * }
622
- * }
623
- * ```
624
- * @param {(update: () => void) => (() => void) | void} start
625
- * @since 5.7.0
626
- */
627
- function createSubscriber(start) {
628
- let subscribers = 0;
629
- let version = source(0);
630
- /** @type {(() => void) | void} */
631
- let stop;
632
- return () => {
633
- if (effect_tracking()) {
634
- get(version);
635
- render_effect(() => {
636
- if (subscribers === 0) stop = untrack(() => start(() => increment(version)));
637
- subscribers += 1;
638
- return () => {
639
- queue_micro_task(() => {
640
- subscribers -= 1;
641
- if (subscribers === 0) {
642
- stop?.();
643
- stop = void 0;
644
- increment(version);
645
- }
646
- });
647
- };
648
- });
649
- }
650
- };
651
- }
652
- //#endregion
653
- //#region \0@oxc-project+runtime@0.139.0/helpers/esm/checkPrivateRedeclaration.js
654
- function _checkPrivateRedeclaration(e, t) {
655
- if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object");
656
- }
657
- //#endregion
658
- //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateMethodInitSpec.js
659
- function _classPrivateMethodInitSpec(e, a) {
660
- _checkPrivateRedeclaration(e, a), a.add(e);
661
- }
662
- //#endregion
663
- //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateFieldInitSpec.js
664
- function _classPrivateFieldInitSpec(e, t, a) {
665
- _checkPrivateRedeclaration(e, t), t.set(e, a);
666
- }
667
- //#endregion
668
- //#region \0@oxc-project+runtime@0.139.0/helpers/esm/assertClassBrand.js
669
- function _assertClassBrand(e, t, n) {
670
- if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
671
- throw new TypeError("Private element is not present on this object");
672
- }
673
- //#endregion
674
- //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateFieldSet2.js
675
- function _classPrivateFieldSet2(s, a, r) {
676
- return s.set(_assertClassBrand(s, a), r), r;
677
- }
678
- //#endregion
679
- //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateFieldGet2.js
680
- function _classPrivateFieldGet2(s, a) {
681
- return s.get(_assertClassBrand(s, a));
682
- }
683
- //#endregion
684
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/blocks/boundary.js
685
- /** @import { Effect, Source, TemplateNode, } from '#client' */
686
- /**
687
- * @typedef {{
688
- * onerror?: ((error: unknown, reset: () => void) => void) | null;
689
- * failed?: ((anchor: Node, error: () => unknown, reset: () => () => void) => void) | null;
690
- * pending?: ((anchor: Node) => void) | null;
691
- * }} BoundaryProps
692
- */
693
- var flags = EFFECT_TRANSPARENT | EFFECT_PRESERVED;
694
- /**
695
- * @param {TemplateNode} node
696
- * @param {BoundaryProps} props
697
- * @param {((anchor: Node) => void)} children
698
- * @param {((error: unknown) => unknown) | undefined} [transform_error]
699
- * @returns {void}
700
- */
701
- function boundary(node, props, children, transform_error) {
702
- new Boundary(node, props, children, transform_error);
703
- }
704
- var _anchor = /* @__PURE__ */ new WeakMap();
705
- var _hydrate_open = /* @__PURE__ */ new WeakMap();
706
- var _props = /* @__PURE__ */ new WeakMap();
707
- var _children = /* @__PURE__ */ new WeakMap();
708
- var _effect = /* @__PURE__ */ new WeakMap();
709
- var _main_effect = /* @__PURE__ */ new WeakMap();
710
- var _pending_effect = /* @__PURE__ */ new WeakMap();
711
- var _failed_effect = /* @__PURE__ */ new WeakMap();
712
- var _offscreen_fragment = /* @__PURE__ */ new WeakMap();
713
- var _local_pending_count = /* @__PURE__ */ new WeakMap();
714
- var _pending_count = /* @__PURE__ */ new WeakMap();
715
- var _pending_count_update_queued = /* @__PURE__ */ new WeakMap();
716
- var _dirty_effects$1 = /* @__PURE__ */ new WeakMap();
717
- var _maybe_dirty_effects$1 = /* @__PURE__ */ new WeakMap();
718
- var _effect_pending = /* @__PURE__ */ new WeakMap();
719
- var _effect_pending_subscriber = /* @__PURE__ */ new WeakMap();
720
- var _Boundary_brand = /* @__PURE__ */ new WeakSet();
721
- var Boundary = class {
722
- /**
723
- * @param {TemplateNode} node
724
- * @param {BoundaryProps} props
725
- * @param {((anchor: Node) => void)} children
726
- * @param {((error: unknown) => unknown) | undefined} [transform_error]
727
- */
728
- constructor(node, props, children, transform_error) {
729
- _classPrivateMethodInitSpec(this, _Boundary_brand);
730
- _defineProperty(
731
- this,
732
- /** @type {Boundary | null} */
733
- "parent",
734
- void 0
735
- );
736
- _defineProperty(this, "is_pending", false);
737
- _defineProperty(
738
- this,
739
- /**
740
- * API-level transformError transform function. Transforms errors before they reach the `failed` snippet.
741
- * Inherited from parent boundary, or defaults to identity.
742
- * @type {(error: unknown) => unknown}
743
- */
744
- "transform_error",
745
- void 0
746
- );
747
- _classPrivateFieldInitSpec(this, _anchor, void 0);
748
- _classPrivateFieldInitSpec(this, _hydrate_open, hydrating ? hydrate_node : null);
749
- _classPrivateFieldInitSpec(this, _props, void 0);
750
- _classPrivateFieldInitSpec(this, _children, void 0);
751
- _classPrivateFieldInitSpec(this, _effect, void 0);
752
- _classPrivateFieldInitSpec(this, _main_effect, null);
753
- _classPrivateFieldInitSpec(this, _pending_effect, null);
754
- _classPrivateFieldInitSpec(this, _failed_effect, null);
755
- _classPrivateFieldInitSpec(this, _offscreen_fragment, null);
756
- _classPrivateFieldInitSpec(this, _local_pending_count, 0);
757
- _classPrivateFieldInitSpec(this, _pending_count, 0);
758
- _classPrivateFieldInitSpec(this, _pending_count_update_queued, false);
759
- _classPrivateFieldInitSpec(this, _dirty_effects$1, /* @__PURE__ */ new Set());
760
- _classPrivateFieldInitSpec(this, _maybe_dirty_effects$1, /* @__PURE__ */ new Set());
761
- _classPrivateFieldInitSpec(this, _effect_pending, null);
762
- _classPrivateFieldInitSpec(this, _effect_pending_subscriber, createSubscriber(() => {
763
- _classPrivateFieldSet2(_effect_pending, this, source(_classPrivateFieldGet2(_local_pending_count, this)));
764
- return () => {
765
- _classPrivateFieldSet2(_effect_pending, this, null);
766
- };
767
- }));
768
- _classPrivateFieldSet2(_anchor, this, node);
769
- _classPrivateFieldSet2(_props, this, props);
770
- _classPrivateFieldSet2(_children, this, (anchor) => {
771
- var effect = active_effect;
772
- effect.b = this;
773
- effect.f |= 128;
774
- children(anchor);
775
- });
776
- this.parent = active_effect.b;
777
- this.transform_error = transform_error ?? this.parent?.transform_error ?? ((e) => e);
778
- _classPrivateFieldSet2(_effect, this, block(() => {
779
- if (hydrating) {
780
- const comment = _classPrivateFieldGet2(_hydrate_open, this);
781
- hydrate_next();
782
- const server_rendered_pending = comment.data === "[!";
783
- if (comment.data.startsWith("[?")) {
784
- const serialized_error = JSON.parse(comment.data.slice(2));
785
- _assertClassBrand(_Boundary_brand, this, _hydrate_failed_content).call(this, serialized_error);
786
- } else if (server_rendered_pending) _assertClassBrand(_Boundary_brand, this, _hydrate_pending_content).call(this);
787
- else _assertClassBrand(_Boundary_brand, this, _hydrate_resolved_content).call(this);
788
- } else _assertClassBrand(_Boundary_brand, this, _render).call(this);
789
- }, flags));
790
- if (hydrating) _classPrivateFieldSet2(_anchor, this, hydrate_node);
791
- }
792
- /**
793
- * Defer an effect inside a pending boundary until the boundary resolves
794
- * @param {Effect} effect
795
- */
796
- defer_effect(effect) {
797
- defer_effect(effect, _classPrivateFieldGet2(_dirty_effects$1, this), _classPrivateFieldGet2(_maybe_dirty_effects$1, this));
798
- }
799
- /**
800
- * Returns `false` if the effect exists inside a boundary whose pending snippet is shown
801
- * @returns {boolean}
802
- */
803
- is_rendered() {
804
- return !this.is_pending && (!this.parent || this.parent.is_rendered());
805
- }
806
- has_pending_snippet() {
807
- return !!_classPrivateFieldGet2(_props, this).pending;
808
- }
809
- /**
810
- * Update the source that powers `$effect.pending()` inside this boundary,
811
- * and controls when the current `pending` snippet (if any) is removed.
812
- * Do not call from inside the class
813
- * @param {1 | -1} d
814
- * @param {Batch} batch
815
- */
816
- update_pending_count(d, batch) {
817
- _assertClassBrand(_Boundary_brand, this, _update_pending_count).call(this, d, batch);
818
- _classPrivateFieldSet2(_local_pending_count, this, _classPrivateFieldGet2(_local_pending_count, this) + d);
819
- if (!_classPrivateFieldGet2(_effect_pending, this) || _classPrivateFieldGet2(_pending_count_update_queued, this)) return;
820
- _classPrivateFieldSet2(_pending_count_update_queued, this, true);
821
- queue_micro_task(() => {
822
- _classPrivateFieldSet2(_pending_count_update_queued, this, false);
823
- if (_classPrivateFieldGet2(_effect_pending, this)) internal_set(_classPrivateFieldGet2(_effect_pending, this), _classPrivateFieldGet2(_local_pending_count, this));
824
- });
825
- }
826
- get_effect_pending() {
827
- _classPrivateFieldGet2(_effect_pending_subscriber, this).call(this);
828
- return get(_classPrivateFieldGet2(_effect_pending, this));
829
- }
830
- /** @param {unknown} error */
831
- error(error) {
832
- if (!_classPrivateFieldGet2(_props, this).onerror && !_classPrivateFieldGet2(_props, this).failed) throw error;
833
- if (current_batch?.is_fork) {
834
- if (_classPrivateFieldGet2(_main_effect, this)) current_batch.skip_effect(_classPrivateFieldGet2(_main_effect, this));
835
- if (_classPrivateFieldGet2(_pending_effect, this)) current_batch.skip_effect(_classPrivateFieldGet2(_pending_effect, this));
836
- if (_classPrivateFieldGet2(_failed_effect, this)) current_batch.skip_effect(_classPrivateFieldGet2(_failed_effect, this));
837
- current_batch.oncommit(() => {
838
- _assertClassBrand(_Boundary_brand, this, _handle_error).call(this, error);
839
- });
840
- } else _assertClassBrand(_Boundary_brand, this, _handle_error).call(this, error);
841
- }
842
- };
843
- function _hydrate_resolved_content() {
844
- try {
845
- _classPrivateFieldSet2(_main_effect, this, branch(() => _classPrivateFieldGet2(_children, this).call(this, _classPrivateFieldGet2(_anchor, this))));
846
- } catch (error) {
847
- this.error(error);
848
- }
849
- }
850
- /**
851
- * @param {unknown} error The deserialized error from the server's hydration comment
852
- */
853
- function _hydrate_failed_content(error) {
854
- const failed = _classPrivateFieldGet2(_props, this).failed;
855
- const { reset, invoke_onerror } = _assertClassBrand(_Boundary_brand, this, _create_reset).call(this, error);
856
- queue_micro_task(invoke_onerror);
857
- if (!failed) return;
858
- _classPrivateFieldSet2(_failed_effect, this, branch(() => {
859
- failed(_classPrivateFieldGet2(_anchor, this), () => error, () => reset);
860
- }));
861
- }
862
- /**
863
- * Creates the `reset` function for a failed boundary, along with a function
864
- * that invokes `onerror` with it (if provided)
865
- * @param {unknown} error
866
- * @returns {{ reset: () => void, invoke_onerror: () => void }}
867
- */
868
- function _create_reset(error) {
869
- var did_reset = false;
870
- var calling_on_error = false;
871
- const reset = () => {
872
- if (did_reset) {
873
- svelte_boundary_reset_noop();
874
- return;
875
- }
876
- did_reset = true;
877
- if (calling_on_error) svelte_boundary_reset_onerror();
878
- if (_classPrivateFieldGet2(_failed_effect, this) !== null) pause_effect(_classPrivateFieldGet2(_failed_effect, this), () => {
879
- _classPrivateFieldSet2(_failed_effect, this, null);
880
- });
881
- _assertClassBrand(_Boundary_brand, this, _run).call(this, () => {
882
- _assertClassBrand(_Boundary_brand, this, _render).call(this);
883
- });
884
- };
885
- const invoke_onerror = () => {
886
- try {
887
- calling_on_error = true;
888
- _classPrivateFieldGet2(_props, this).onerror?.(error, reset);
889
- calling_on_error = false;
890
- } catch (err) {
891
- invoke_error_boundary(err, _classPrivateFieldGet2(_effect, this) && _classPrivateFieldGet2(_effect, this).parent);
892
- }
893
- };
894
- return {
895
- reset,
896
- invoke_onerror
897
- };
898
- }
899
- function _hydrate_pending_content() {
900
- const pending = _classPrivateFieldGet2(_props, this).pending;
901
- if (!pending) return;
902
- this.is_pending = true;
903
- _classPrivateFieldSet2(_pending_effect, this, branch(() => pending(_classPrivateFieldGet2(_anchor, this))));
904
- queue_micro_task(() => {
905
- var fragment = _classPrivateFieldSet2(_offscreen_fragment, this, document.createDocumentFragment());
906
- var anchor = create_text();
907
- fragment.append(anchor);
908
- _classPrivateFieldSet2(_main_effect, this, _assertClassBrand(_Boundary_brand, this, _run).call(this, () => {
909
- return branch(() => _classPrivateFieldGet2(_children, this).call(this, anchor));
910
- }));
911
- if (_classPrivateFieldGet2(_pending_count, this) === 0) {
912
- _classPrivateFieldGet2(_anchor, this).before(fragment);
913
- _classPrivateFieldSet2(_offscreen_fragment, this, null);
914
- pause_effect(_classPrivateFieldGet2(_pending_effect, this), () => {
915
- _classPrivateFieldSet2(_pending_effect, this, null);
916
- });
917
- _assertClassBrand(_Boundary_brand, this, _resolve).call(this, current_batch);
918
- }
919
- });
920
- }
921
- function _render() {
922
- try {
923
- this.is_pending = this.has_pending_snippet();
924
- _classPrivateFieldSet2(_pending_count, this, 0);
925
- _classPrivateFieldSet2(_local_pending_count, this, 0);
926
- _classPrivateFieldSet2(_main_effect, this, branch(() => {
927
- _classPrivateFieldGet2(_children, this).call(this, _classPrivateFieldGet2(_anchor, this));
928
- }));
929
- if (_classPrivateFieldGet2(_pending_count, this) > 0) {
930
- var fragment = _classPrivateFieldSet2(_offscreen_fragment, this, document.createDocumentFragment());
931
- move_effect(_classPrivateFieldGet2(_main_effect, this), fragment);
932
- const pending = _classPrivateFieldGet2(_props, this).pending;
933
- _classPrivateFieldSet2(_pending_effect, this, branch(() => pending(_classPrivateFieldGet2(_anchor, this))));
934
- } else _assertClassBrand(_Boundary_brand, this, _resolve).call(this, current_batch);
935
- } catch (error) {
936
- this.error(error);
937
- }
938
- }
939
- /**
940
- * @param {Batch} batch
941
- */
942
- function _resolve(batch) {
943
- this.is_pending = false;
944
- batch.transfer_effects(_classPrivateFieldGet2(_dirty_effects$1, this), _classPrivateFieldGet2(_maybe_dirty_effects$1, this));
945
- }
946
- /**
947
- * @template T
948
- * @param {() => T} fn
949
- */
950
- function _run(fn) {
951
- var previous_effect = active_effect;
952
- var previous_reaction = active_reaction;
953
- var previous_ctx = component_context;
954
- set_active_effect(_classPrivateFieldGet2(_effect, this));
955
- set_active_reaction(_classPrivateFieldGet2(_effect, this));
956
- set_component_context(_classPrivateFieldGet2(_effect, this).ctx);
957
- try {
958
- Batch.ensure();
959
- return fn();
960
- } catch (e) {
961
- handle_error(e);
962
- return null;
963
- } finally {
964
- set_active_effect(previous_effect);
965
- set_active_reaction(previous_reaction);
966
- set_component_context(previous_ctx);
967
- }
968
- }
969
- /**
970
- * Updates the pending count associated with the currently visible pending snippet,
971
- * if any, such that we can replace the snippet with content once work is done
972
- * @param {1 | -1} d
973
- * @param {Batch} batch
974
- */
975
- function _update_pending_count(d, batch) {
976
- if (!this.has_pending_snippet()) {
977
- if (this.parent) {
978
- var _this$parent;
979
- _assertClassBrand(_Boundary_brand, _this$parent = this.parent, _update_pending_count).call(_this$parent, d, batch);
980
- }
981
- return;
982
- }
983
- _classPrivateFieldSet2(_pending_count, this, _classPrivateFieldGet2(_pending_count, this) + d);
984
- if (_classPrivateFieldGet2(_pending_count, this) === 0) {
985
- _assertClassBrand(_Boundary_brand, this, _resolve).call(this, batch);
986
- if (_classPrivateFieldGet2(_pending_effect, this)) pause_effect(_classPrivateFieldGet2(_pending_effect, this), () => {
987
- _classPrivateFieldSet2(_pending_effect, this, null);
988
- });
989
- if (_classPrivateFieldGet2(_offscreen_fragment, this)) {
990
- _classPrivateFieldGet2(_anchor, this).before(_classPrivateFieldGet2(_offscreen_fragment, this));
991
- _classPrivateFieldSet2(_offscreen_fragment, this, null);
992
- }
993
- }
994
- }
995
- /**
996
- * @param {unknown} error
997
- */
998
- function _handle_error(error) {
999
- if (_classPrivateFieldGet2(_main_effect, this)) {
1000
- destroy_effect(_classPrivateFieldGet2(_main_effect, this));
1001
- _classPrivateFieldSet2(_main_effect, this, null);
1002
- }
1003
- if (_classPrivateFieldGet2(_pending_effect, this)) {
1004
- destroy_effect(_classPrivateFieldGet2(_pending_effect, this));
1005
- _classPrivateFieldSet2(_pending_effect, this, null);
1006
- }
1007
- if (_classPrivateFieldGet2(_failed_effect, this)) {
1008
- destroy_effect(_classPrivateFieldGet2(_failed_effect, this));
1009
- _classPrivateFieldSet2(_failed_effect, this, null);
1010
- }
1011
- if (hydrating) {
1012
- set_hydrate_node(_classPrivateFieldGet2(_hydrate_open, this));
1013
- next();
1014
- set_hydrate_node(skip_nodes());
1015
- }
1016
- let failed = _classPrivateFieldGet2(_props, this).failed;
1017
- /** @param {unknown} transformed_error */
1018
- const handle_error_result = (transformed_error) => {
1019
- const { reset, invoke_onerror } = _assertClassBrand(_Boundary_brand, this, _create_reset).call(this, transformed_error);
1020
- invoke_onerror();
1021
- if (failed) _classPrivateFieldSet2(_failed_effect, this, _assertClassBrand(_Boundary_brand, this, _run).call(this, () => {
1022
- try {
1023
- return branch(() => {
1024
- var effect = active_effect;
1025
- effect.b = this;
1026
- effect.f |= 128;
1027
- failed(_classPrivateFieldGet2(_anchor, this), () => transformed_error, () => reset);
1028
- });
1029
- } catch (error) {
1030
- invoke_error_boundary(error, _classPrivateFieldGet2(_effect, this).parent);
1031
- return null;
1032
- }
1033
- }));
1034
- };
1035
- queue_micro_task(() => {
1036
- /** @type {unknown} */
1037
- var result;
1038
- try {
1039
- result = this.transform_error(error);
1040
- } catch (e) {
1041
- invoke_error_boundary(e, _classPrivateFieldGet2(_effect, this) && _classPrivateFieldGet2(_effect, this).parent);
1042
- return;
1043
- }
1044
- if (result !== null && typeof result === "object" && typeof result.then === "function")
1045
- /** @type {any} */ result.then(
1046
- handle_error_result,
1047
- /** @param {unknown} e */
1048
- (e) => invoke_error_boundary(e, _classPrivateFieldGet2(_effect, this) && _classPrivateFieldGet2(_effect, this).parent)
1049
- );
1050
- else handle_error_result(result);
1051
- });
1052
- }
1053
- //#endregion
1054
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/async.js
1055
- /** @import { Blocker, Effect, Source, Value } from '#client' */
558
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/async.js
559
+ /** @import { Blocker, Effect, Source, Value } from '#client' */
1056
560
  /**
1057
561
  * @param {Blocker[]} blockers
1058
562
  * @param {Array<() => any>} sync
@@ -1340,7 +844,38 @@ function unfreeze_derived_effects(derived) {
1340
844
  for (const e of derived.effects) if (e.teardown && e.fn !== null) update_effect(e);
1341
845
  }
1342
846
  //#endregion
1343
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/batch.js
847
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/checkPrivateRedeclaration.js
848
+ function _checkPrivateRedeclaration(e, t) {
849
+ if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object");
850
+ }
851
+ //#endregion
852
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateMethodInitSpec.js
853
+ function _classPrivateMethodInitSpec(e, a) {
854
+ _checkPrivateRedeclaration(e, a), a.add(e);
855
+ }
856
+ //#endregion
857
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateFieldInitSpec.js
858
+ function _classPrivateFieldInitSpec(e, t, a) {
859
+ _checkPrivateRedeclaration(e, t), t.set(e, a);
860
+ }
861
+ //#endregion
862
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/assertClassBrand.js
863
+ function _assertClassBrand(e, t, n) {
864
+ if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
865
+ throw new TypeError("Private element is not present on this object");
866
+ }
867
+ //#endregion
868
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateFieldSet2.js
869
+ function _classPrivateFieldSet2(s, a, r) {
870
+ return s.set(_assertClassBrand(s, a), r), r;
871
+ }
872
+ //#endregion
873
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/classPrivateFieldGet2.js
874
+ function _classPrivateFieldGet2(s, a) {
875
+ return s.get(_assertClassBrand(s, a));
876
+ }
877
+ //#endregion
878
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/batch.js
1344
879
  /** @import { Fork } from 'svelte' */
1345
880
  /** @import { Derived, Effect, Reaction, Source, Value } from '#client' */
1346
881
  var _Batch;
@@ -1393,8 +928,8 @@ var _blocking_pending = /* @__PURE__ */ new WeakMap();
1393
928
  var _deferred = /* @__PURE__ */ new WeakMap();
1394
929
  var _roots = /* @__PURE__ */ new WeakMap();
1395
930
  var _new_effects = /* @__PURE__ */ new WeakMap();
1396
- var _dirty_effects = /* @__PURE__ */ new WeakMap();
1397
- var _maybe_dirty_effects = /* @__PURE__ */ new WeakMap();
931
+ var _dirty_effects$1 = /* @__PURE__ */ new WeakMap();
932
+ var _maybe_dirty_effects$1 = /* @__PURE__ */ new WeakMap();
1398
933
  var _skipped_branches = /* @__PURE__ */ new WeakMap();
1399
934
  var _unskipped_branches = /* @__PURE__ */ new WeakMap();
1400
935
  var _decrement_queued = /* @__PURE__ */ new WeakMap();
@@ -1441,8 +976,8 @@ var Batch = class Batch {
1441
976
  _classPrivateFieldInitSpec(this, _deferred, null);
1442
977
  _classPrivateFieldInitSpec(this, _roots, []);
1443
978
  _classPrivateFieldInitSpec(this, _new_effects, []);
1444
- _classPrivateFieldInitSpec(this, _dirty_effects, /* @__PURE__ */ new Set());
1445
- _classPrivateFieldInitSpec(this, _maybe_dirty_effects, /* @__PURE__ */ new Set());
979
+ _classPrivateFieldInitSpec(this, _dirty_effects$1, /* @__PURE__ */ new Set());
980
+ _classPrivateFieldInitSpec(this, _maybe_dirty_effects$1, /* @__PURE__ */ new Set());
1446
981
  _classPrivateFieldInitSpec(this, _skipped_branches, /* @__PURE__ */ new Map());
1447
982
  _classPrivateFieldInitSpec(this, _unskipped_branches, /* @__PURE__ */ new Set());
1448
983
  _defineProperty(this, "is_fork", false);
@@ -1571,8 +1106,8 @@ var Batch = class Batch {
1571
1106
  * @param {Set<Effect>} maybe_dirty_effects
1572
1107
  */
1573
1108
  transfer_effects(dirty_effects, maybe_dirty_effects) {
1574
- for (const e of dirty_effects) _classPrivateFieldGet2(_dirty_effects, this).add(e);
1575
- for (const e of maybe_dirty_effects) _classPrivateFieldGet2(_maybe_dirty_effects, this).add(e);
1109
+ for (const e of dirty_effects) _classPrivateFieldGet2(_dirty_effects$1, this).add(e);
1110
+ for (const e of maybe_dirty_effects) _classPrivateFieldGet2(_maybe_dirty_effects$1, this).add(e);
1576
1111
  dirty_effects.clear();
1577
1112
  maybe_dirty_effects.clear();
1578
1113
  }
@@ -1667,12 +1202,12 @@ function _process() {
1667
1202
  _assertClassBrand(_Batch_brand, this, _unlink).call(this);
1668
1203
  infinite_loop_guard();
1669
1204
  }
1670
- for (const e of _classPrivateFieldGet2(_dirty_effects, this)) {
1671
- _classPrivateFieldGet2(_maybe_dirty_effects, this).delete(e);
1205
+ for (const e of _classPrivateFieldGet2(_dirty_effects$1, this)) {
1206
+ _classPrivateFieldGet2(_maybe_dirty_effects$1, this).delete(e);
1672
1207
  set_signal_status(e, DIRTY);
1673
1208
  this.schedule(e);
1674
1209
  }
1675
- for (const e of _classPrivateFieldGet2(_maybe_dirty_effects, this)) {
1210
+ for (const e of _classPrivateFieldGet2(_maybe_dirty_effects$1, this)) {
1676
1211
  set_signal_status(e, MAYBE_DIRTY);
1677
1212
  this.schedule(e);
1678
1213
  }
@@ -1717,8 +1252,8 @@ function _process() {
1717
1252
  _assertClassBrand(_Batch_brand, earlier_batch, _merge).call(earlier_batch, this);
1718
1253
  return;
1719
1254
  }
1720
- _classPrivateFieldGet2(_dirty_effects, this).clear();
1721
- _classPrivateFieldGet2(_maybe_dirty_effects, this).clear();
1255
+ _classPrivateFieldGet2(_dirty_effects$1, this).clear();
1256
+ _classPrivateFieldGet2(_maybe_dirty_effects$1, this).clear();
1722
1257
  for (const fn of _classPrivateFieldGet2(_commit_callbacks, this)) fn(this);
1723
1258
  _classPrivateFieldGet2(_commit_callbacks, this).clear();
1724
1259
  previous_batch = this;
@@ -1738,7 +1273,10 @@ function _process() {
1738
1273
  const batch = next_batch;
1739
1274
  _classPrivateFieldGet2(_roots, batch).push(..._classPrivateFieldGet2(_roots, this).filter((r) => !_classPrivateFieldGet2(_roots, batch).includes(r)));
1740
1275
  } else next_batch = this;
1741
- if (next_batch !== null) _assertClassBrand(_Batch_brand, next_batch, _process).call(next_batch);
1276
+ if (next_batch !== null) {
1277
+ old_values.clear();
1278
+ _assertClassBrand(_Batch_brand, next_batch, _process).call(next_batch);
1279
+ }
1742
1280
  }
1743
1281
  /**
1744
1282
  * Traverse the effect tree, executing effects or stashing
@@ -1758,7 +1296,7 @@ function _traverse(root, effects, render_effects) {
1758
1296
  else if ((flags & 4) !== 0) effects.push(effect);
1759
1297
  else if (async_mode_flag && (flags & 16777224) !== 0) render_effects.push(effect);
1760
1298
  else if (is_dirty(effect)) {
1761
- if ((flags & 16) !== 0) _classPrivateFieldGet2(_maybe_dirty_effects, this).add(effect);
1299
+ if ((flags & 16) !== 0) _classPrivateFieldGet2(_maybe_dirty_effects$1, this).add(effect);
1762
1300
  update_effect(effect);
1763
1301
  }
1764
1302
  var child = effect.first;
@@ -1800,7 +1338,7 @@ function _merge(batch) {
1800
1338
  if (d) deferred.promise.then(d.resolve).catch(d.reject);
1801
1339
  }
1802
1340
  batch.async_deriveds.clear();
1803
- this.transfer_effects(_classPrivateFieldGet2(_dirty_effects, batch), _classPrivateFieldGet2(_maybe_dirty_effects, batch));
1341
+ this.transfer_effects(_classPrivateFieldGet2(_dirty_effects$1, batch), _classPrivateFieldGet2(_maybe_dirty_effects$1, batch));
1804
1342
  /**
1805
1343
  * mark all effects that depend on `batch.current`, except the
1806
1344
  * async effects that we just resolved (TODO unless they depend
@@ -1819,7 +1357,7 @@ function _merge(batch) {
1819
1357
  else {
1820
1358
  var effect = reaction;
1821
1359
  if (flags & 4194320 && !this.async_deriveds.has(effect)) {
1822
- _classPrivateFieldGet2(_maybe_dirty_effects, this).delete(effect);
1360
+ _classPrivateFieldGet2(_maybe_dirty_effects$1, this).delete(effect);
1823
1361
  set_signal_status(effect, DIRTY);
1824
1362
  this.schedule(effect);
1825
1363
  }
@@ -1836,7 +1374,7 @@ function _merge(batch) {
1836
1374
  * @param {Effect[]} effects
1837
1375
  */
1838
1376
  function _defer_effects(effects) {
1839
- for (var i = 0; i < effects.length; i += 1) defer_effect(effects[i], _classPrivateFieldGet2(_dirty_effects, this), _classPrivateFieldGet2(_maybe_dirty_effects, this));
1377
+ for (var i = 0; i < effects.length; i += 1) defer_effect(effects[i], _classPrivateFieldGet2(_dirty_effects$1, this), _classPrivateFieldGet2(_maybe_dirty_effects$1, this));
1840
1378
  }
1841
1379
  function _commit$1() {
1842
1380
  for (let batch = first_batch; batch !== null; batch = _classPrivateFieldGet2(_next, batch)) {
@@ -1881,7 +1419,7 @@ function _commit$1() {
1881
1419
  for (const effect of _classPrivateFieldGet2(_new_effects, this)) if ((effect.f & 155648) === 0 && depends_on(effect, current_unequal, checked)) if ((effect.f & 4194320) !== 0) {
1882
1420
  set_signal_status(effect, DIRTY);
1883
1421
  batch.schedule(effect);
1884
- } else _classPrivateFieldGet2(_dirty_effects, batch).add(effect);
1422
+ } else _classPrivateFieldGet2(_dirty_effects$1, batch).add(effect);
1885
1423
  }
1886
1424
  if (_classPrivateFieldGet2(_roots, batch).length > 0 && !_classPrivateFieldGet2(_decrement_queued, batch)) {
1887
1425
  batch.apply();
@@ -2053,7 +1591,7 @@ function reset_all(effect) {
2053
1591
  }
2054
1592
  }
2055
1593
  //#endregion
2056
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/sources.js
1594
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/sources.js
2057
1595
  /** @import { Derived, Effect, Source, Value } from '#client' */
2058
1596
  /** @type {Set<Effect>} */
2059
1597
  var eager_effects = /* @__PURE__ */ new Set();
@@ -2123,7 +1661,8 @@ function set(source, value, should_proxy = false) {
2123
1661
  */
2124
1662
  function internal_set(source, value, updated_during_traversal = null) {
2125
1663
  if (!source.equals(value)) {
2126
- old_values.set(source, is_destroying_effect ? value : source.v);
1664
+ if (is_destroying_effect) old_values.set(source, value);
1665
+ else if (!old_values.has(source)) old_values.set(source, source.v);
2127
1666
  var batch = Batch.ensure();
2128
1667
  batch.capture(source, value);
2129
1668
  if ((source.f & 2) !== 0) {
@@ -2199,7 +1738,7 @@ function mark_reactions(signal, status, updated_during_traversal) {
2199
1738
  * @returns {T}
2200
1739
  */
2201
1740
  function proxy(value) {
2202
- if (typeof value !== "object" || value === null || STATE_SYMBOL in value) return value;
1741
+ if (typeof value !== "object" || value === null || STATE_SYMBOL in value || COMPONENT_SYMBOL in value) return value;
2203
1742
  const prototype = get_prototype_of(value);
2204
1743
  if (prototype !== object_prototype && prototype !== array_prototype) return value;
2205
1744
  /** @type {Map<any, Source<any>>} */
@@ -2352,7 +1891,7 @@ function proxy(value) {
2352
1891
  });
2353
1892
  }
2354
1893
  //#endregion
2355
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/operations.js
1894
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/operations.js
2356
1895
  /** @import { Effect, TemplateNode } from '#client' */
2357
1896
  /** @type {Window} */
2358
1897
  var $window;
@@ -2452,6 +1991,21 @@ function first_child(node, is_text = false) {
2452
1991
  return hydrate_node;
2453
1992
  }
2454
1993
  /**
1994
+ * `child`, for the very common case of an element with exactly one child. Resetting the
1995
+ * hydration cursor is part of the same step, so the compiler doesn't have to emit a
1996
+ * separate `reset` call for every `<p>{text}</p>` in an app.
1997
+ * Don't mark this as side-effect-free, hydration needs to walk all nodes
1998
+ * @param {TemplateNode} node
1999
+ * @param {boolean} [is_text]
2000
+ * @returns {TemplateNode | null}
2001
+ */
2002
+ function only_child(node, is_text = false) {
2003
+ if (!hydrating) return /* @__PURE__ */ get_first_child(node);
2004
+ var first = child(node, is_text);
2005
+ reset(node);
2006
+ return first;
2007
+ }
2008
+ /**
2455
2009
  * Don't mark this as side-effect-free, hydration needs to walk all nodes
2456
2010
  * @param {TemplateNode} node
2457
2011
  * @param {number} count
@@ -2516,21 +2070,53 @@ function create_element(tag, namespace, is) {
2516
2070
  return is ? document.createElementNS(namespace, tag, { is }) : document.createElementNS(namespace, tag);
2517
2071
  }
2518
2072
  /**
2519
- * Browsers split text nodes larger than 65536 bytes when parsing.
2520
- * For hydration to succeed, we need to stitch them back together
2521
- * @param {Text} text
2073
+ * Browsers split text nodes larger than 65536 bytes when parsing.
2074
+ * For hydration to succeed, we need to stitch them back together
2075
+ * @param {Text} text
2076
+ */
2077
+ function merge_text_nodes(text) {
2078
+ if (text.nodeValue.length < 65536) return;
2079
+ let next = text.nextSibling;
2080
+ while (next !== null && next.nodeType === 3) {
2081
+ next.remove();
2082
+ /** @type {string} */ text.nodeValue += next.nodeValue;
2083
+ next = text.nextSibling;
2084
+ }
2085
+ }
2086
+ /**
2087
+ * @param {unknown} error
2088
+ */
2089
+ function handle_error(error) {
2090
+ var effect = active_effect;
2091
+ if (effect === null) {
2092
+ /** @type {Derived} */ active_reaction.f |= ERROR_VALUE;
2093
+ return error;
2094
+ }
2095
+ if ((effect.f & 32768) === 0 && (effect.f & 4) === 0) throw error;
2096
+ invoke_error_boundary(error, effect);
2097
+ }
2098
+ /**
2099
+ * @param {unknown} error
2100
+ * @param {Effect | null} effect
2522
2101
  */
2523
- function merge_text_nodes(text) {
2524
- if (text.nodeValue.length < 65536) return;
2525
- let next = text.nextSibling;
2526
- while (next !== null && next.nodeType === 3) {
2527
- next.remove();
2528
- /** @type {string} */ text.nodeValue += next.nodeValue;
2529
- next = text.nextSibling;
2102
+ function invoke_error_boundary(error, effect) {
2103
+ if (effect !== null && (effect.f & 16384) !== 0) return;
2104
+ while (effect !== null) {
2105
+ if ((effect.f & 128) !== 0 && (effect.f & 33570816) === 0) {
2106
+ if ((effect.f & 32768) === 0) throw error;
2107
+ try {
2108
+ /** @type {Boundary} */ effect.b.error(error);
2109
+ return;
2110
+ } catch (e) {
2111
+ error = e;
2112
+ }
2113
+ }
2114
+ effect = effect.parent;
2530
2115
  }
2116
+ throw error;
2531
2117
  }
2532
2118
  //#endregion
2533
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/reactivity/effects.js
2119
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/effects.js
2534
2120
  /** @import { Blocker, ComponentContext, ComponentContextLegacy, Derived, Effect, TemplateNode, TransitionManager } from '#client' */
2535
2121
  /**
2536
2122
  * @param {'$effect' | '$effect.pre' | '$inspect'} rune
@@ -2733,6 +2319,8 @@ function execute_effect_teardown(effect) {
2733
2319
  set_active_reaction(null);
2734
2320
  try {
2735
2321
  teardown.call(null);
2322
+ } catch (error) {
2323
+ invoke_error_boundary(error, effect.parent);
2736
2324
  } finally {
2737
2325
  set_is_destroying_effect(previously_destroying_effect);
2738
2326
  set_active_reaction(previous_reaction);
@@ -2835,6 +2423,7 @@ function unlink_effect(effect) {
2835
2423
  function pause_effect(effect, callback, destroy = true) {
2836
2424
  /** @type {TransitionManager[]} */
2837
2425
  var transitions = [];
2426
+ effect.f |= 256;
2838
2427
  pause_children(effect, transitions, true);
2839
2428
  var fn = () => {
2840
2429
  if (destroy) destroy_effect(effect);
@@ -2874,6 +2463,7 @@ function pause_children(effect, transitions, local) {
2874
2463
  * @param {Effect} effect
2875
2464
  */
2876
2465
  function resume_effect(effect) {
2466
+ effect.f &= -257;
2877
2467
  resume_children(effect, true);
2878
2468
  }
2879
2469
  /**
@@ -2881,6 +2471,7 @@ function resume_effect(effect) {
2881
2471
  * @param {boolean} local
2882
2472
  */
2883
2473
  function resume_children(effect, local) {
2474
+ if ((effect.f & 256) !== 0) return;
2884
2475
  if ((effect.f & 8192) === 0) return;
2885
2476
  effect.f ^= INERT;
2886
2477
  if ((effect.f & 1024) === 0) {
@@ -2916,14 +2507,14 @@ function move_effect(effect, fragment) {
2916
2507
  }
2917
2508
  }
2918
2509
  //#endregion
2919
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/legacy.js
2510
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/legacy.js
2920
2511
  /**
2921
2512
  * @type {Set<Value> | null}
2922
2513
  * @deprecated
2923
2514
  */
2924
2515
  var captured_signals = null;
2925
2516
  //#endregion
2926
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/runtime.js
2517
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/runtime.js
2927
2518
  /** @import { Derived, Effect, Reaction, Source, Value } from '#client' */
2928
2519
  /**
2929
2520
  * True if updating in an effect context that is reactive (i.e. not branch/root effects)
@@ -2980,7 +2571,7 @@ function set_untracked_writes(value) {
2980
2571
  * Version starts from 1 so that unowned deriveds differentiate between a created effect and a run one for tracing
2981
2572
  **/
2982
2573
  var write_version = 1;
2983
- /** @type {number} Used to version each read of a source of derived to avoid duplicating depedencies inside a reaction */
2574
+ /** @type {number} Used to version each read of a source of derived to avoid duplicating dependencies inside a reaction */
2984
2575
  var read_version = 0;
2985
2576
  var update_version = read_version;
2986
2577
  /** @param {number} value */
@@ -3061,24 +2652,8 @@ function update_reaction(reaction) {
3061
2652
  var fn = reaction.fn;
3062
2653
  var result = fn();
3063
2654
  reaction.f |= REACTION_RAN;
3064
- var deps = reaction.deps;
3065
- var is_fork = current_batch?.is_fork;
3066
- if (new_deps !== null) {
3067
- var i;
3068
- if (!is_fork) remove_reactions(reaction, skipped_deps);
3069
- if (deps !== null && skipped_deps > 0) {
3070
- deps.length = skipped_deps + new_deps.length;
3071
- for (i = 0; i < new_deps.length; i++) deps[skipped_deps + i] = new_deps[i];
3072
- } else reaction.deps = deps = new_deps;
3073
- if (effect_tracking() && (reaction.f & 512) !== 0) for (i = skipped_deps; i < deps.length; i++) {
3074
- var _deps$i;
3075
- ((_deps$i = deps[i]).reactions ?? (_deps$i.reactions = [])).push(reaction);
3076
- }
3077
- } else if (!is_fork && deps !== null && skipped_deps < deps.length) {
3078
- remove_reactions(reaction, skipped_deps);
3079
- deps.length = skipped_deps;
3080
- }
3081
- if (is_runes() && untracked_writes !== null && !untracking && deps !== null && (reaction.f & 6146) === 0) for (i = 0; i < untracked_writes.length; i++) schedule_possible_effect_self_invalidation(untracked_writes[i], reaction);
2655
+ var deps = update_dependencies(reaction);
2656
+ if (is_runes() && untracked_writes !== null && !untracking && deps !== null && (reaction.f & 6146) === 0) for (var i = 0; i < untracked_writes.length; i++) schedule_possible_effect_self_invalidation(untracked_writes[i], reaction);
3082
2657
  if (previous_reaction !== null && previous_reaction !== reaction) {
3083
2658
  read_version++;
3084
2659
  if (previous_reaction.deps !== null) for (let i = 0; i < previous_skipped_deps; i += 1) previous_reaction.deps[i].rv = read_version;
@@ -3089,6 +2664,7 @@ function update_reaction(reaction) {
3089
2664
  if ((reaction.f & 8388608) !== 0) reaction.f ^= ERROR_VALUE;
3090
2665
  return result;
3091
2666
  } catch (error) {
2667
+ update_dependencies(reaction);
3092
2668
  return handle_error(error);
3093
2669
  } finally {
3094
2670
  reaction.f ^= REACTION_IS_UPDATING;
@@ -3103,6 +2679,29 @@ function update_reaction(reaction) {
3103
2679
  }
3104
2680
  }
3105
2681
  /**
2682
+ * @param {Reaction} reaction
2683
+ */
2684
+ function update_dependencies(reaction) {
2685
+ var deps = reaction.deps;
2686
+ var is_fork = current_batch?.is_fork;
2687
+ if (new_deps !== null) {
2688
+ var i;
2689
+ if (!is_fork) remove_reactions(reaction, skipped_deps);
2690
+ if (deps !== null && skipped_deps > 0) {
2691
+ deps.length = skipped_deps + new_deps.length;
2692
+ for (i = 0; i < new_deps.length; i++) deps[skipped_deps + i] = new_deps[i];
2693
+ } else reaction.deps = deps = new_deps;
2694
+ if (effect_tracking() && (reaction.f & 512) !== 0) for (i = skipped_deps; i < deps.length; i++) {
2695
+ var _deps$i;
2696
+ ((_deps$i = deps[i]).reactions ?? (_deps$i.reactions = [])).push(reaction);
2697
+ }
2698
+ } else if (!is_fork && deps !== null && skipped_deps < deps.length) {
2699
+ remove_reactions(reaction, skipped_deps);
2700
+ deps.length = skipped_deps;
2701
+ }
2702
+ return deps;
2703
+ }
2704
+ /**
3106
2705
  * @template V
3107
2706
  * @param {Reaction} signal
3108
2707
  * @param {Value<V>} dependency
@@ -3287,7 +2886,7 @@ function untrack(fn) {
3287
2886
  }
3288
2887
  }
3289
2888
  //#endregion
3290
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/events.js
2889
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/events.js
3291
2890
  /**
3292
2891
  * Used on elements, as a map of event type -> event handler,
3293
2892
  * and on events themselves to track which element handled an event
@@ -3355,6 +2954,7 @@ function delegate(events) {
3355
2954
  for (var fn of root_event_handles) fn(events);
3356
2955
  }
3357
2956
  var last_propagated_event = null;
2957
+ var last_propagated_event_clear_scheduled = false;
3358
2958
  /**
3359
2959
  * @this {EventTarget}
3360
2960
  * @param {Event} event
@@ -3367,6 +2967,13 @@ function handle_event_propagation(event) {
3367
2967
  var path = event.composedPath?.() || [];
3368
2968
  var current_target = path[0] || event.target;
3369
2969
  last_propagated_event = event;
2970
+ if (!last_propagated_event_clear_scheduled) {
2971
+ last_propagated_event_clear_scheduled = true;
2972
+ setTimeout(() => {
2973
+ last_propagated_event_clear_scheduled = false;
2974
+ last_propagated_event = null;
2975
+ });
2976
+ }
3370
2977
  var path_idx = 0;
3371
2978
  var handled_at = last_propagated_event === event && event[event_symbol];
3372
2979
  if (handled_at) {
@@ -3417,178 +3024,634 @@ function handle_event_propagation(event) {
3417
3024
  for (let error of other_errors) queueMicrotask(() => {
3418
3025
  throw error;
3419
3026
  });
3420
- throw throw_error;
3027
+ throw throw_error;
3028
+ }
3029
+ } finally {
3030
+ event[event_symbol] = handler_element;
3031
+ delete event.currentTarget;
3032
+ set_active_reaction(previous_reaction);
3033
+ set_active_effect(previous_effect);
3034
+ }
3035
+ }
3036
+ //#endregion
3037
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/reconciler.js
3038
+ var policy = globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", {
3039
+ /** @param {string} html */
3040
+ createHTML: (html) => {
3041
+ return html;
3042
+ } });
3043
+ /** @param {string} html */
3044
+ function create_trusted_html(html) {
3045
+ return policy?.createHTML(html) ?? html;
3046
+ }
3047
+ /**
3048
+ * @param {string} html
3049
+ */
3050
+ function create_fragment_from_html(html) {
3051
+ var elem = create_element("template");
3052
+ elem.innerHTML = create_trusted_html(html.replaceAll("<!>", "<!---->"));
3053
+ return elem.content;
3054
+ }
3055
+ //#endregion
3056
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/template.js
3057
+ /** @import { Effect, EffectNodes, TemplateNode } from '#client' */
3058
+ /** @import { TemplateStructure } from './types' */
3059
+ /**
3060
+ * @param {TemplateNode} start
3061
+ * @param {TemplateNode | null} end
3062
+ */
3063
+ function assign_nodes(start, end) {
3064
+ var effect = active_effect;
3065
+ if (effect.nodes === null) effect.nodes = {
3066
+ start,
3067
+ end,
3068
+ a: null,
3069
+ t: null
3070
+ };
3071
+ }
3072
+ /**
3073
+ * @param {string} content
3074
+ * @param {number} flags
3075
+ * @returns {() => Node | Node[]}
3076
+ */
3077
+ /*#__NO_SIDE_EFFECTS__*/
3078
+ function from_html(content, flags) {
3079
+ var is_fragment = (flags & 1) !== 0;
3080
+ var use_import_node = (flags & 2) !== 0;
3081
+ /** @type {Node} */
3082
+ var node;
3083
+ /**
3084
+ * Whether or not the first item is a text/element node. If not, we need to
3085
+ * create an additional comment node to act as `effect.nodes.start`
3086
+ */
3087
+ var has_start = !content.startsWith("<!>");
3088
+ return () => {
3089
+ if (hydrating) {
3090
+ assign_nodes(hydrate_node, null);
3091
+ return hydrate_node;
3092
+ }
3093
+ if (node === void 0) {
3094
+ node = create_fragment_from_html(has_start ? content : "<!>" + content);
3095
+ if (!is_fragment) node = /* @__PURE__ */ get_first_child(node);
3096
+ }
3097
+ var clone = use_import_node || is_firefox ? document.importNode(node, true) : node.cloneNode(true);
3098
+ if (is_fragment) {
3099
+ var start = /* @__PURE__ */ get_first_child(clone);
3100
+ var end = clone.lastChild;
3101
+ assign_nodes(start, end);
3102
+ } else assign_nodes(clone, clone);
3103
+ return clone;
3104
+ };
3105
+ }
3106
+ /**
3107
+ * @param {string} content
3108
+ * @param {number} flags
3109
+ * @param {'svg' | 'math'} ns
3110
+ * @returns {() => Node | Node[]}
3111
+ */
3112
+ /*#__NO_SIDE_EFFECTS__*/
3113
+ function from_namespace(content, flags, ns = "svg") {
3114
+ /**
3115
+ * Whether or not the first item is a text/element node. If not, we need to
3116
+ * create an additional comment node to act as `effect.nodes.start`
3117
+ */
3118
+ var has_start = !content.startsWith("<!>");
3119
+ var is_fragment = (flags & 1) !== 0;
3120
+ var wrapped = `<${ns}>${has_start ? content : "<!>" + content}</${ns}>`;
3121
+ /** @type {Element | DocumentFragment} */
3122
+ var node;
3123
+ return () => {
3124
+ if (hydrating) {
3125
+ assign_nodes(hydrate_node, null);
3126
+ return hydrate_node;
3127
+ }
3128
+ if (!node) {
3129
+ var root = /* @__PURE__ */ get_first_child(create_fragment_from_html(wrapped));
3130
+ if (is_fragment) {
3131
+ node = document.createDocumentFragment();
3132
+ while (/* @__PURE__ */ get_first_child(root)) node.appendChild(/* @__PURE__ */ get_first_child(root));
3133
+ } else node = /* @__PURE__ */ get_first_child(root);
3134
+ }
3135
+ var clone = node.cloneNode(true);
3136
+ if (is_fragment) {
3137
+ var start = /* @__PURE__ */ get_first_child(clone);
3138
+ var end = clone.lastChild;
3139
+ assign_nodes(start, end);
3140
+ } else assign_nodes(clone, clone);
3141
+ return clone;
3142
+ };
3143
+ }
3144
+ /**
3145
+ * @param {string} content
3146
+ * @param {number} flags
3147
+ */
3148
+ /*#__NO_SIDE_EFFECTS__*/
3149
+ function from_svg(content, flags) {
3150
+ return /* @__PURE__ */ from_namespace(content, flags, "svg");
3151
+ }
3152
+ /**
3153
+ * @returns {TemplateNode | DocumentFragment}
3154
+ */
3155
+ function comment() {
3156
+ if (hydrating) {
3157
+ assign_nodes(hydrate_node, null);
3158
+ return hydrate_node;
3159
+ }
3160
+ var frag = document.createDocumentFragment();
3161
+ var start = document.createComment("");
3162
+ var anchor = create_text();
3163
+ frag.append(start, anchor);
3164
+ assign_nodes(start, anchor);
3165
+ return frag;
3166
+ }
3167
+ /**
3168
+ * Assign the created (or in hydration mode, traversed) dom elements to the current block
3169
+ * and insert the elements into the dom (in client mode).
3170
+ * @param {Text | Comment | Element} anchor
3171
+ * @param {DocumentFragment | Element} dom
3172
+ */
3173
+ function append(anchor, dom) {
3174
+ if (hydrating) {
3175
+ var effect = active_effect;
3176
+ if ((effect.f & 32768) === 0 || effect.nodes.end === null) effect.nodes.end = hydrate_node;
3177
+ hydrate_next();
3178
+ return;
3179
+ }
3180
+ if (anchor === null) return;
3181
+ anchor.before(dom);
3182
+ }
3183
+ /**
3184
+ * Subset of delegated events which should be passive by default.
3185
+ * These two are already passive via browser defaults on window, document and body.
3186
+ * But since
3187
+ * - we're delegating them
3188
+ * - they happen often
3189
+ * - they apply to mobile which is generally less performant
3190
+ * we're marking them as passive by default for other elements, too.
3191
+ */
3192
+ var PASSIVE_EVENTS = ["touchstart", "touchmove"];
3193
+ /**
3194
+ * Returns `true` if `name` is a passive event
3195
+ * @param {string} name
3196
+ */
3197
+ function is_passive_event(name) {
3198
+ return PASSIVE_EVENTS.includes(name);
3199
+ }
3200
+ //#endregion
3201
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/reactivity/create-subscriber.js
3202
+ /**
3203
+ * Returns a `subscribe` function that integrates external event-based systems with Svelte's reactivity.
3204
+ * It's particularly useful for integrating with web APIs like `MediaQuery`, `IntersectionObserver`, or `WebSocket`.
3205
+ *
3206
+ * If `subscribe` is called inside an effect (including indirectly, for example inside a getter),
3207
+ * the `start` callback will be called with an `update` function. Whenever `update` is called, the effect re-runs.
3208
+ *
3209
+ * If `start` returns a cleanup function, it will be called when the effect is destroyed.
3210
+ *
3211
+ * If `subscribe` is called in multiple effects, `start` will only be called once as long as the effects
3212
+ * are active, and the returned teardown function will only be called when all effects are destroyed.
3213
+ *
3214
+ * It's best understood with an example. Here's an implementation of [`MediaQuery`](https://svelte.dev/docs/svelte/svelte-reactivity#MediaQuery):
3215
+ *
3216
+ * ```js
3217
+ * import { createSubscriber } from 'svelte/reactivity';
3218
+ * import { on } from 'svelte/events';
3219
+ *
3220
+ * export class MediaQuery {
3221
+ * #query;
3222
+ * #subscribe;
3223
+ *
3224
+ * constructor(query) {
3225
+ * this.#query = window.matchMedia(`(${query})`);
3226
+ *
3227
+ * this.#subscribe = createSubscriber((update) => {
3228
+ * // when the `change` event occurs, re-run any effects that read `this.current`
3229
+ * const off = on(this.#query, 'change', update);
3230
+ *
3231
+ * // stop listening when all the effects are destroyed
3232
+ * return () => off();
3233
+ * });
3234
+ * }
3235
+ *
3236
+ * get current() {
3237
+ * // This makes the getter reactive, if read in an effect
3238
+ * this.#subscribe();
3239
+ *
3240
+ * // Return the current state of the query, whether or not we're in an effect
3241
+ * return this.#query.matches;
3242
+ * }
3243
+ * }
3244
+ * ```
3245
+ * @param {(update: () => void) => (() => void) | void} start
3246
+ * @since 5.7.0
3247
+ */
3248
+ function createSubscriber(start) {
3249
+ let subscribers = 0;
3250
+ let version = source(0);
3251
+ /** @type {(() => void) | void} */
3252
+ let stop;
3253
+ return () => {
3254
+ if (effect_tracking()) {
3255
+ get(version);
3256
+ render_effect(() => {
3257
+ if (subscribers === 0) stop = untrack(() => start(() => increment(version)));
3258
+ subscribers += 1;
3259
+ return () => {
3260
+ queue_micro_task(() => {
3261
+ subscribers -= 1;
3262
+ if (subscribers === 0) {
3263
+ stop?.();
3264
+ stop = void 0;
3265
+ increment(version);
3266
+ }
3267
+ });
3268
+ };
3269
+ });
3421
3270
  }
3422
- } finally {
3423
- event[event_symbol] = handler_element;
3424
- delete event.currentTarget;
3425
- set_active_reaction(previous_reaction);
3426
- set_active_effect(previous_effect);
3427
- }
3271
+ };
3428
3272
  }
3429
3273
  //#endregion
3430
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/reconciler.js
3431
- var policy = globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", {
3432
- /** @param {string} html */
3433
- createHTML: (html) => {
3434
- return html;
3435
- } });
3436
- /** @param {string} html */
3437
- function create_trusted_html(html) {
3438
- return policy?.createHTML(html) ?? html;
3439
- }
3274
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/boundary.js
3275
+ /** @import { Effect, Source, TemplateNode, } from '#client' */
3440
3276
  /**
3441
- * @param {string} html
3277
+ * @typedef {{
3278
+ * onerror?: ((error: unknown, reset: () => void) => void) | null;
3279
+ * failed?: ((anchor: Node, error: () => unknown, reset: () => () => void) => void) | null;
3280
+ * pending?: ((anchor: Node) => void) | null;
3281
+ * }} BoundaryProps
3442
3282
  */
3443
- function create_fragment_from_html(html) {
3444
- var elem = create_element("template");
3445
- elem.innerHTML = create_trusted_html(html.replaceAll("<!>", "<!---->"));
3446
- return elem.content;
3447
- }
3448
- //#endregion
3449
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/template.js
3450
- /** @import { Effect, EffectNodes, TemplateNode } from '#client' */
3451
- /** @import { TemplateStructure } from './types' */
3283
+ var flags = EFFECT_TRANSPARENT | EFFECT_PRESERVED;
3452
3284
  /**
3453
- * @param {TemplateNode} start
3454
- * @param {TemplateNode | null} end
3285
+ * @param {TemplateNode} node
3286
+ * @param {BoundaryProps} props
3287
+ * @param {((anchor: Node) => void)} children
3288
+ * @param {((error: unknown) => unknown) | undefined} [transform_error]
3289
+ * @returns {void}
3455
3290
  */
3456
- function assign_nodes(start, end) {
3457
- var effect = active_effect;
3458
- if (effect.nodes === null) effect.nodes = {
3459
- start,
3460
- end,
3461
- a: null,
3462
- t: null
3463
- };
3291
+ function boundary(node, props, children, transform_error) {
3292
+ new Boundary(node, props, children, transform_error);
3464
3293
  }
3465
- /**
3466
- * @param {string} content
3467
- * @param {number} flags
3468
- * @returns {() => Node | Node[]}
3469
- */
3470
- /*#__NO_SIDE_EFFECTS__*/
3471
- function from_html(content, flags) {
3472
- var is_fragment = (flags & 1) !== 0;
3473
- var use_import_node = (flags & 2) !== 0;
3474
- /** @type {Node} */
3475
- var node;
3294
+ var _anchor = /* @__PURE__ */ new WeakMap();
3295
+ var _hydrate_open = /* @__PURE__ */ new WeakMap();
3296
+ var _props = /* @__PURE__ */ new WeakMap();
3297
+ var _children = /* @__PURE__ */ new WeakMap();
3298
+ var _effect = /* @__PURE__ */ new WeakMap();
3299
+ var _main_effect = /* @__PURE__ */ new WeakMap();
3300
+ var _pending_effect = /* @__PURE__ */ new WeakMap();
3301
+ var _failed_effect = /* @__PURE__ */ new WeakMap();
3302
+ var _offscreen_fragment = /* @__PURE__ */ new WeakMap();
3303
+ var _local_pending_count = /* @__PURE__ */ new WeakMap();
3304
+ var _pending_count = /* @__PURE__ */ new WeakMap();
3305
+ var _pending_count_update_queued = /* @__PURE__ */ new WeakMap();
3306
+ var _dirty_effects = /* @__PURE__ */ new WeakMap();
3307
+ var _maybe_dirty_effects = /* @__PURE__ */ new WeakMap();
3308
+ var _effect_pending = /* @__PURE__ */ new WeakMap();
3309
+ var _effect_pending_subscriber = /* @__PURE__ */ new WeakMap();
3310
+ var _Boundary_brand = /* @__PURE__ */ new WeakSet();
3311
+ var Boundary = class {
3476
3312
  /**
3477
- * Whether or not the first item is a text/element node. If not, we need to
3478
- * create an additional comment node to act as `effect.nodes.start`
3313
+ * @param {TemplateNode} node
3314
+ * @param {BoundaryProps} props
3315
+ * @param {((anchor: Node) => void)} children
3316
+ * @param {((error: unknown) => unknown) | undefined} [transform_error]
3479
3317
  */
3480
- var has_start = !content.startsWith("<!>");
3481
- return () => {
3482
- if (hydrating) {
3483
- assign_nodes(hydrate_node, null);
3484
- return hydrate_node;
3485
- }
3486
- if (node === void 0) {
3487
- node = create_fragment_from_html(has_start ? content : "<!>" + content);
3488
- if (!is_fragment) node = /* @__PURE__ */ get_first_child(node);
3489
- }
3490
- var clone = use_import_node || is_firefox ? document.importNode(node, true) : node.cloneNode(true);
3491
- if (is_fragment) {
3492
- var start = /* @__PURE__ */ get_first_child(clone);
3493
- var end = clone.lastChild;
3494
- assign_nodes(start, end);
3495
- } else assign_nodes(clone, clone);
3496
- return clone;
3497
- };
3318
+ constructor(node, props, children, transform_error) {
3319
+ _classPrivateMethodInitSpec(this, _Boundary_brand);
3320
+ _defineProperty(
3321
+ this,
3322
+ /** @type {Boundary | null} */
3323
+ "parent",
3324
+ void 0
3325
+ );
3326
+ _defineProperty(this, "is_pending", false);
3327
+ _defineProperty(
3328
+ this,
3329
+ /**
3330
+ * API-level transformError transform function. Transforms errors before they reach the `failed` snippet.
3331
+ * Inherited from parent boundary, or defaults to identity.
3332
+ * @type {(error: unknown) => unknown}
3333
+ */
3334
+ "transform_error",
3335
+ void 0
3336
+ );
3337
+ _classPrivateFieldInitSpec(this, _anchor, void 0);
3338
+ _classPrivateFieldInitSpec(this, _hydrate_open, hydrating ? hydrate_node : null);
3339
+ _classPrivateFieldInitSpec(this, _props, void 0);
3340
+ _classPrivateFieldInitSpec(this, _children, void 0);
3341
+ _classPrivateFieldInitSpec(this, _effect, void 0);
3342
+ _classPrivateFieldInitSpec(this, _main_effect, null);
3343
+ _classPrivateFieldInitSpec(this, _pending_effect, null);
3344
+ _classPrivateFieldInitSpec(this, _failed_effect, null);
3345
+ _classPrivateFieldInitSpec(this, _offscreen_fragment, null);
3346
+ _classPrivateFieldInitSpec(this, _local_pending_count, 0);
3347
+ _classPrivateFieldInitSpec(this, _pending_count, 0);
3348
+ _classPrivateFieldInitSpec(this, _pending_count_update_queued, false);
3349
+ _classPrivateFieldInitSpec(this, _dirty_effects, /* @__PURE__ */ new Set());
3350
+ _classPrivateFieldInitSpec(this, _maybe_dirty_effects, /* @__PURE__ */ new Set());
3351
+ _classPrivateFieldInitSpec(this, _effect_pending, null);
3352
+ _classPrivateFieldInitSpec(this, _effect_pending_subscriber, createSubscriber(() => {
3353
+ _classPrivateFieldSet2(_effect_pending, this, source(_classPrivateFieldGet2(_local_pending_count, this)));
3354
+ return () => {
3355
+ _classPrivateFieldSet2(_effect_pending, this, null);
3356
+ };
3357
+ }));
3358
+ _classPrivateFieldSet2(_anchor, this, node);
3359
+ _classPrivateFieldSet2(_props, this, props);
3360
+ _classPrivateFieldSet2(_children, this, (anchor) => {
3361
+ var effect = active_effect;
3362
+ effect.b = this;
3363
+ effect.f |= 128;
3364
+ children(anchor);
3365
+ });
3366
+ this.parent = active_effect.b;
3367
+ this.transform_error = transform_error ?? this.parent?.transform_error ?? ((e) => e);
3368
+ _classPrivateFieldSet2(_effect, this, block(() => {
3369
+ if (hydrating) {
3370
+ const comment = _classPrivateFieldGet2(_hydrate_open, this);
3371
+ hydrate_next();
3372
+ const server_rendered_pending = comment.data === "[!";
3373
+ if (comment.data.startsWith("[?")) {
3374
+ const serialized_error = JSON.parse(comment.data.slice(2));
3375
+ _assertClassBrand(_Boundary_brand, this, _hydrate_failed_content).call(this, serialized_error);
3376
+ } else if (server_rendered_pending) _assertClassBrand(_Boundary_brand, this, _hydrate_pending_content).call(this);
3377
+ else _assertClassBrand(_Boundary_brand, this, _hydrate_resolved_content).call(this);
3378
+ } else _assertClassBrand(_Boundary_brand, this, _render).call(this);
3379
+ }, flags));
3380
+ if (hydrating) _classPrivateFieldSet2(_anchor, this, hydrate_node);
3381
+ }
3382
+ /**
3383
+ * Defer an effect inside a pending boundary until the boundary resolves
3384
+ * @param {Effect} effect
3385
+ */
3386
+ defer_effect(effect) {
3387
+ defer_effect(effect, _classPrivateFieldGet2(_dirty_effects, this), _classPrivateFieldGet2(_maybe_dirty_effects, this));
3388
+ }
3389
+ /**
3390
+ * Returns `false` if the effect exists inside a boundary whose pending snippet is shown
3391
+ * @returns {boolean}
3392
+ */
3393
+ is_rendered() {
3394
+ return !this.is_pending && (!this.parent || this.parent.is_rendered());
3395
+ }
3396
+ has_pending_snippet() {
3397
+ return !!_classPrivateFieldGet2(_props, this).pending;
3398
+ }
3399
+ /**
3400
+ * Update the source that powers `$effect.pending()` inside this boundary,
3401
+ * and controls when the current `pending` snippet (if any) is removed.
3402
+ * Do not call from inside the class
3403
+ * @param {1 | -1} d
3404
+ * @param {Batch} batch
3405
+ */
3406
+ update_pending_count(d, batch) {
3407
+ _assertClassBrand(_Boundary_brand, this, _update_pending_count).call(this, d, batch);
3408
+ _classPrivateFieldSet2(_local_pending_count, this, _classPrivateFieldGet2(_local_pending_count, this) + d);
3409
+ if (!_classPrivateFieldGet2(_effect_pending, this) || _classPrivateFieldGet2(_pending_count_update_queued, this)) return;
3410
+ _classPrivateFieldSet2(_pending_count_update_queued, this, true);
3411
+ queue_micro_task(() => {
3412
+ _classPrivateFieldSet2(_pending_count_update_queued, this, false);
3413
+ if (_classPrivateFieldGet2(_effect_pending, this)) internal_set(_classPrivateFieldGet2(_effect_pending, this), _classPrivateFieldGet2(_local_pending_count, this));
3414
+ });
3415
+ }
3416
+ get_effect_pending() {
3417
+ _classPrivateFieldGet2(_effect_pending_subscriber, this).call(this);
3418
+ return get(_classPrivateFieldGet2(_effect_pending, this));
3419
+ }
3420
+ /** @param {unknown} error */
3421
+ error(error) {
3422
+ if (!_classPrivateFieldGet2(_props, this).onerror && !_classPrivateFieldGet2(_props, this).failed) throw error;
3423
+ if (current_batch?.is_fork) {
3424
+ if (_classPrivateFieldGet2(_main_effect, this)) current_batch.skip_effect(_classPrivateFieldGet2(_main_effect, this));
3425
+ if (_classPrivateFieldGet2(_pending_effect, this)) current_batch.skip_effect(_classPrivateFieldGet2(_pending_effect, this));
3426
+ if (_classPrivateFieldGet2(_failed_effect, this)) current_batch.skip_effect(_classPrivateFieldGet2(_failed_effect, this));
3427
+ current_batch.oncommit(() => {
3428
+ _assertClassBrand(_Boundary_brand, this, _handle_error).call(this, error);
3429
+ });
3430
+ } else _assertClassBrand(_Boundary_brand, this, _handle_error).call(this, error);
3431
+ }
3432
+ };
3433
+ function _hydrate_resolved_content() {
3434
+ try {
3435
+ _classPrivateFieldSet2(_main_effect, this, branch(() => _classPrivateFieldGet2(_children, this).call(this, _classPrivateFieldGet2(_anchor, this))));
3436
+ } catch (error) {
3437
+ this.error(error);
3438
+ }
3439
+ }
3440
+ /**
3441
+ * @param {unknown} error The deserialized error from the server's hydration comment
3442
+ */
3443
+ function _hydrate_failed_content(error) {
3444
+ const failed = _classPrivateFieldGet2(_props, this).failed;
3445
+ const { reset, invoke_onerror } = _assertClassBrand(_Boundary_brand, this, _create_reset).call(this, error);
3446
+ queue_micro_task(invoke_onerror);
3447
+ if (!failed) return;
3448
+ _classPrivateFieldSet2(_failed_effect, this, branch(() => {
3449
+ failed(_classPrivateFieldGet2(_anchor, this), () => error, () => reset);
3450
+ }));
3498
3451
  }
3499
3452
  /**
3500
- * @param {string} content
3501
- * @param {number} flags
3502
- * @param {'svg' | 'math'} ns
3503
- * @returns {() => Node | Node[]}
3453
+ * Creates the `reset` function for a failed boundary, along with a function
3454
+ * that invokes `onerror` with it (if provided)
3455
+ * @param {unknown} error
3456
+ * @returns {{ reset: () => void, invoke_onerror: () => void }}
3504
3457
  */
3505
- /*#__NO_SIDE_EFFECTS__*/
3506
- function from_namespace(content, flags, ns = "svg") {
3507
- /**
3508
- * Whether or not the first item is a text/element node. If not, we need to
3509
- * create an additional comment node to act as `effect.nodes.start`
3510
- */
3511
- var has_start = !content.startsWith("<!>");
3512
- var is_fragment = (flags & 1) !== 0;
3513
- var wrapped = `<${ns}>${has_start ? content : "<!>" + content}</${ns}>`;
3514
- /** @type {Element | DocumentFragment} */
3515
- var node;
3516
- return () => {
3517
- if (hydrating) {
3518
- assign_nodes(hydrate_node, null);
3519
- return hydrate_node;
3458
+ function _create_reset(error) {
3459
+ var did_reset = false;
3460
+ var calling_on_error = false;
3461
+ const reset = () => {
3462
+ if (did_reset) {
3463
+ svelte_boundary_reset_noop();
3464
+ return;
3520
3465
  }
3521
- if (!node) {
3522
- var root = /* @__PURE__ */ get_first_child(create_fragment_from_html(wrapped));
3523
- if (is_fragment) {
3524
- node = document.createDocumentFragment();
3525
- while (/* @__PURE__ */ get_first_child(root)) node.appendChild(/* @__PURE__ */ get_first_child(root));
3526
- } else node = /* @__PURE__ */ get_first_child(root);
3466
+ did_reset = true;
3467
+ if (calling_on_error) svelte_boundary_reset_onerror();
3468
+ if (_classPrivateFieldGet2(_failed_effect, this) !== null) pause_effect(_classPrivateFieldGet2(_failed_effect, this), () => {
3469
+ _classPrivateFieldSet2(_failed_effect, this, null);
3470
+ });
3471
+ _assertClassBrand(_Boundary_brand, this, _run).call(this, () => {
3472
+ _assertClassBrand(_Boundary_brand, this, _render).call(this);
3473
+ });
3474
+ };
3475
+ const invoke_onerror = () => {
3476
+ try {
3477
+ calling_on_error = true;
3478
+ _classPrivateFieldGet2(_props, this).onerror?.(error, reset);
3479
+ calling_on_error = false;
3480
+ } catch (err) {
3481
+ invoke_error_boundary(err, _classPrivateFieldGet2(_effect, this) && _classPrivateFieldGet2(_effect, this).parent);
3527
3482
  }
3528
- var clone = node.cloneNode(true);
3529
- if (is_fragment) {
3530
- var start = /* @__PURE__ */ get_first_child(clone);
3531
- var end = clone.lastChild;
3532
- assign_nodes(start, end);
3533
- } else assign_nodes(clone, clone);
3534
- return clone;
3535
3483
  };
3484
+ return {
3485
+ reset,
3486
+ invoke_onerror
3487
+ };
3488
+ }
3489
+ function _hydrate_pending_content() {
3490
+ const pending = _classPrivateFieldGet2(_props, this).pending;
3491
+ if (!pending) return;
3492
+ this.is_pending = true;
3493
+ _classPrivateFieldSet2(_pending_effect, this, branch(() => pending(_classPrivateFieldGet2(_anchor, this))));
3494
+ queue_micro_task(() => {
3495
+ var fragment = _classPrivateFieldSet2(_offscreen_fragment, this, document.createDocumentFragment());
3496
+ var anchor = create_text();
3497
+ var handled = false;
3498
+ fragment.append(anchor);
3499
+ _classPrivateFieldSet2(_main_effect, this, _assertClassBrand(_Boundary_brand, this, _run).call(this, () => {
3500
+ try {
3501
+ return branch(() => _classPrivateFieldGet2(_children, this).call(this, anchor));
3502
+ } catch (error) {
3503
+ try {
3504
+ this.error(error);
3505
+ handled = true;
3506
+ } catch (error) {
3507
+ invoke_error_boundary(error, _classPrivateFieldGet2(_effect, this).parent);
3508
+ }
3509
+ return null;
3510
+ }
3511
+ }));
3512
+ if (_classPrivateFieldGet2(_main_effect, this) === null) {
3513
+ _classPrivateFieldSet2(_offscreen_fragment, this, null);
3514
+ if (handled) _assertClassBrand(_Boundary_brand, this, _resolve).call(this, current_batch);
3515
+ return;
3516
+ }
3517
+ if (_classPrivateFieldGet2(_pending_count, this) === 0) {
3518
+ _classPrivateFieldGet2(_anchor, this).before(fragment);
3519
+ _classPrivateFieldSet2(_offscreen_fragment, this, null);
3520
+ pause_effect(_classPrivateFieldGet2(_pending_effect, this), () => {
3521
+ _classPrivateFieldSet2(_pending_effect, this, null);
3522
+ });
3523
+ _assertClassBrand(_Boundary_brand, this, _resolve).call(this, current_batch);
3524
+ }
3525
+ });
3526
+ }
3527
+ function _render() {
3528
+ try {
3529
+ this.is_pending = this.has_pending_snippet();
3530
+ _classPrivateFieldSet2(_pending_count, this, 0);
3531
+ _classPrivateFieldSet2(_local_pending_count, this, 0);
3532
+ _classPrivateFieldSet2(_main_effect, this, branch(() => {
3533
+ _classPrivateFieldGet2(_children, this).call(this, _classPrivateFieldGet2(_anchor, this));
3534
+ }));
3535
+ if (_classPrivateFieldGet2(_pending_count, this) > 0) {
3536
+ var fragment = _classPrivateFieldSet2(_offscreen_fragment, this, document.createDocumentFragment());
3537
+ move_effect(_classPrivateFieldGet2(_main_effect, this), fragment);
3538
+ const pending = _classPrivateFieldGet2(_props, this).pending;
3539
+ _classPrivateFieldSet2(_pending_effect, this, branch(() => pending(_classPrivateFieldGet2(_anchor, this))));
3540
+ } else _assertClassBrand(_Boundary_brand, this, _resolve).call(this, current_batch);
3541
+ } catch (error) {
3542
+ this.error(error);
3543
+ }
3536
3544
  }
3537
3545
  /**
3538
- * @param {string} content
3539
- * @param {number} flags
3546
+ * @param {Batch} batch
3540
3547
  */
3541
- /*#__NO_SIDE_EFFECTS__*/
3542
- function from_svg(content, flags) {
3543
- return /* @__PURE__ */ from_namespace(content, flags, "svg");
3548
+ function _resolve(batch) {
3549
+ this.is_pending = false;
3550
+ batch.transfer_effects(_classPrivateFieldGet2(_dirty_effects, this), _classPrivateFieldGet2(_maybe_dirty_effects, this));
3544
3551
  }
3545
3552
  /**
3546
- * @returns {TemplateNode | DocumentFragment}
3553
+ * @template T
3554
+ * @param {() => T} fn
3547
3555
  */
3548
- function comment() {
3549
- if (hydrating) {
3550
- assign_nodes(hydrate_node, null);
3551
- return hydrate_node;
3556
+ function _run(fn) {
3557
+ var previous_effect = active_effect;
3558
+ var previous_reaction = active_reaction;
3559
+ var previous_ctx = component_context;
3560
+ set_active_effect(_classPrivateFieldGet2(_effect, this));
3561
+ set_active_reaction(_classPrivateFieldGet2(_effect, this));
3562
+ set_component_context(_classPrivateFieldGet2(_effect, this).ctx);
3563
+ try {
3564
+ Batch.ensure();
3565
+ return fn();
3566
+ } finally {
3567
+ set_active_effect(previous_effect);
3568
+ set_active_reaction(previous_reaction);
3569
+ set_component_context(previous_ctx);
3552
3570
  }
3553
- var frag = document.createDocumentFragment();
3554
- var start = document.createComment("");
3555
- var anchor = create_text();
3556
- frag.append(start, anchor);
3557
- assign_nodes(start, anchor);
3558
- return frag;
3559
3571
  }
3560
3572
  /**
3561
- * Assign the created (or in hydration mode, traversed) dom elements to the current block
3562
- * and insert the elements into the dom (in client mode).
3563
- * @param {Text | Comment | Element} anchor
3564
- * @param {DocumentFragment | Element} dom
3573
+ * Updates the pending count associated with the currently visible pending snippet,
3574
+ * if any, such that we can replace the snippet with content once work is done
3575
+ * @param {1 | -1} d
3576
+ * @param {Batch} batch
3565
3577
  */
3566
- function append(anchor, dom) {
3567
- if (hydrating) {
3568
- var effect = active_effect;
3569
- if ((effect.f & 32768) === 0 || effect.nodes.end === null) effect.nodes.end = hydrate_node;
3570
- hydrate_next();
3578
+ function _update_pending_count(d, batch) {
3579
+ if (!this.has_pending_snippet()) {
3580
+ if (this.parent) {
3581
+ var _this$parent;
3582
+ _assertClassBrand(_Boundary_brand, _this$parent = this.parent, _update_pending_count).call(_this$parent, d, batch);
3583
+ }
3571
3584
  return;
3572
3585
  }
3573
- if (anchor === null) return;
3574
- anchor.before(dom);
3586
+ _classPrivateFieldSet2(_pending_count, this, _classPrivateFieldGet2(_pending_count, this) + d);
3587
+ if (_classPrivateFieldGet2(_pending_count, this) === 0) {
3588
+ _assertClassBrand(_Boundary_brand, this, _resolve).call(this, batch);
3589
+ if (_classPrivateFieldGet2(_pending_effect, this)) pause_effect(_classPrivateFieldGet2(_pending_effect, this), () => {
3590
+ _classPrivateFieldSet2(_pending_effect, this, null);
3591
+ });
3592
+ if (_classPrivateFieldGet2(_offscreen_fragment, this)) {
3593
+ _classPrivateFieldGet2(_anchor, this).before(_classPrivateFieldGet2(_offscreen_fragment, this));
3594
+ _classPrivateFieldSet2(_offscreen_fragment, this, null);
3595
+ }
3596
+ }
3575
3597
  }
3576
3598
  /**
3577
- * Subset of delegated events which should be passive by default.
3578
- * These two are already passive via browser defaults on window, document and body.
3579
- * But since
3580
- * - we're delegating them
3581
- * - they happen often
3582
- * - they apply to mobile which is generally less performant
3583
- * we're marking them as passive by default for other elements, too.
3584
- */
3585
- var PASSIVE_EVENTS = ["touchstart", "touchmove"];
3586
- /**
3587
- * Returns `true` if `name` is a passive event
3588
- * @param {string} name
3599
+ * @param {unknown} error
3589
3600
  */
3590
- function is_passive_event(name) {
3591
- return PASSIVE_EVENTS.includes(name);
3601
+ function _handle_error(error) {
3602
+ if (_classPrivateFieldGet2(_main_effect, this)) {
3603
+ destroy_effect(_classPrivateFieldGet2(_main_effect, this));
3604
+ _classPrivateFieldSet2(_main_effect, this, null);
3605
+ }
3606
+ if (_classPrivateFieldGet2(_pending_effect, this)) {
3607
+ destroy_effect(_classPrivateFieldGet2(_pending_effect, this));
3608
+ _classPrivateFieldSet2(_pending_effect, this, null);
3609
+ }
3610
+ if (_classPrivateFieldGet2(_failed_effect, this)) {
3611
+ destroy_effect(_classPrivateFieldGet2(_failed_effect, this));
3612
+ _classPrivateFieldSet2(_failed_effect, this, null);
3613
+ }
3614
+ if (hydrating) {
3615
+ set_hydrate_node(_classPrivateFieldGet2(_hydrate_open, this));
3616
+ next();
3617
+ set_hydrate_node(skip_nodes());
3618
+ }
3619
+ let failed = _classPrivateFieldGet2(_props, this).failed;
3620
+ /** @param {unknown} transformed_error */
3621
+ const handle_error_result = (transformed_error) => {
3622
+ const { reset, invoke_onerror } = _assertClassBrand(_Boundary_brand, this, _create_reset).call(this, transformed_error);
3623
+ invoke_onerror();
3624
+ if (failed) _classPrivateFieldSet2(_failed_effect, this, _assertClassBrand(_Boundary_brand, this, _run).call(this, () => {
3625
+ try {
3626
+ return branch(() => {
3627
+ var effect = active_effect;
3628
+ effect.b = this;
3629
+ effect.f |= 128;
3630
+ failed(_classPrivateFieldGet2(_anchor, this), () => transformed_error, () => reset);
3631
+ });
3632
+ } catch (error) {
3633
+ invoke_error_boundary(error, _classPrivateFieldGet2(_effect, this).parent);
3634
+ return null;
3635
+ }
3636
+ }));
3637
+ };
3638
+ queue_micro_task(() => {
3639
+ /** @type {unknown} */
3640
+ var result;
3641
+ try {
3642
+ result = this.transform_error(error);
3643
+ } catch (e) {
3644
+ invoke_error_boundary(e, _classPrivateFieldGet2(_effect, this) && _classPrivateFieldGet2(_effect, this).parent);
3645
+ return;
3646
+ }
3647
+ if (result !== null && typeof result === "object" && typeof result.then === "function")
3648
+ /** @type {any} */ result.then(
3649
+ handle_error_result,
3650
+ /** @param {unknown} e */
3651
+ (e) => invoke_error_boundary(e, _classPrivateFieldGet2(_effect, this) && _classPrivateFieldGet2(_effect, this).parent)
3652
+ );
3653
+ else handle_error_result(result);
3654
+ });
3592
3655
  }
3593
3656
  /**
3594
3657
  * @param {Element} text
@@ -3692,7 +3755,7 @@ function _mount(Component, { target, anchor, props = {}, events, context, intro
3692
3755
  if (events)
3693
3756
  /** @type {any} */ props.$$events = events;
3694
3757
  if (hydrating) assign_nodes(anchor_node, null);
3695
- component = Component(anchor_node, props) || {};
3758
+ component = Component(anchor_node, props) || mark_as_component();
3696
3759
  if (hydrating) {
3697
3760
  /** @type {Effect & { nodes: EffectNodes }} */ active_effect.nodes.end = hydrate_node;
3698
3761
  if (hydrate_node === null || hydrate_node.nodeType !== 8 || hydrate_node.data !== "]") {
@@ -3778,7 +3841,7 @@ function unmount(component, options) {
3778
3841
  return Promise.resolve();
3779
3842
  }
3780
3843
  //#endregion
3781
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/blocks/branches.js
3844
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/branches.js
3782
3845
  /** @import { Effect, TemplateNode } from '#client' */
3783
3846
  var _batches = /* @__PURE__ */ new WeakMap();
3784
3847
  var _onscreen = /* @__PURE__ */ new WeakMap();
@@ -3901,7 +3964,7 @@ var BranchManager = class {
3901
3964
  }
3902
3965
  };
3903
3966
  //#endregion
3904
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/blocks/snippet.js
3967
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/snippet.js
3905
3968
  /** @import { Snippet } from 'svelte' */
3906
3969
  /** @import { TemplateNode } from '#client' */
3907
3970
  /** @import { Getters } from '#shared' */
@@ -3954,7 +4017,7 @@ function init_update_callbacks(context) {
3954
4017
  });
3955
4018
  }
3956
4019
  //#endregion
3957
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/blocks/if.js
4020
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/if.js
3958
4021
  /** @import { TemplateNode } from '#client' */
3959
4022
  /**
3960
4023
  * @param {TemplateNode} node
@@ -4000,7 +4063,7 @@ function if_block(node, fn, elseif = false) {
4000
4063
  }, flags);
4001
4064
  }
4002
4065
  //#endregion
4003
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/blocks/each.js
4066
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/each.js
4004
4067
  /** @import { EachItem, EachOutroGroup, EachState, Effect, EffectNodes, MaybeSource, Source, TemplateNode, TransitionManager, Value } from '#client' */
4005
4068
  /** @import { Batch } from '../../reactivity/batch.js'; */
4006
4069
  /**
@@ -4040,7 +4103,7 @@ function pause_effects(state, to_destroy, controlled_anchor) {
4040
4103
  }, false);
4041
4104
  }
4042
4105
  if (remaining === 0) {
4043
- var fast_path = transitions.length === 0 && controlled_anchor !== null;
4106
+ var fast_path = transitions.length === 0 && controlled_anchor !== null && state.pending.size === 0;
4044
4107
  if (fast_path) {
4045
4108
  var anchor = controlled_anchor;
4046
4109
  var parent_node = anchor.parentNode;
@@ -4472,13 +4535,14 @@ function html(node, get_value, is_controlled = false, svg = false, mathml = fals
4472
4535
  });
4473
4536
  }
4474
4537
  //#endregion
4475
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/css.js
4538
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/css.js
4476
4539
  /**
4477
4540
  * @param {Node} anchor
4478
4541
  * @param {{ hash: string, code: string }} css
4479
4542
  */
4480
4543
  function append_styles$1(anchor, css) {
4481
4544
  effect(() => {
4545
+ anchor = active_effect?.parent?.nodes?.start ?? anchor;
4482
4546
  var root = anchor.getRootNode();
4483
4547
  var target = root.host ? root : /** @type {Document} */ root.head ?? root.ownerDocument.head;
4484
4548
  if (!target.querySelector("#" + css.hash)) {
@@ -4490,7 +4554,7 @@ function append_styles$1(anchor, css) {
4490
4554
  });
4491
4555
  }
4492
4556
  //#endregion
4493
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/shared/attributes.js
4557
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/shared/attributes.js
4494
4558
  var whitespace = [..." \n\r\f\xA0\v"];
4495
4559
  /**
4496
4560
  * @param {any} value
@@ -4554,7 +4618,7 @@ function to_style(value, styles) {
4554
4618
  important_styles = styles[1];
4555
4619
  } else normal_styles = styles;
4556
4620
  if (value) {
4557
- value = String(value).replaceAll(/\s*\/\*.*?\*\/\s*/g, "").trim();
4621
+ value = String(value).replaceAll(/\/\*.*?\*\//g, "").trim();
4558
4622
  /** @type {boolean | '"' | "'"} */
4559
4623
  var in_str = false;
4560
4624
  var in_apo = 0;
@@ -4600,7 +4664,7 @@ function to_style(value, styles) {
4600
4664
  return value == null ? null : String(value);
4601
4665
  }
4602
4666
  //#endregion
4603
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/class.js
4667
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/class.js
4604
4668
  /**
4605
4669
  * @param {Element} dom
4606
4670
  * @param {boolean | number} is_html
@@ -4625,7 +4689,7 @@ function set_class(dom, is_html, value, hash, prev_classes, next_classes) {
4625
4689
  return next_classes;
4626
4690
  }
4627
4691
  //#endregion
4628
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/style.js
4692
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/style.js
4629
4693
  /**
4630
4694
  * @param {Element & ElementCSSInlineStyle} dom
4631
4695
  * @param {Record<string, any>} prev
@@ -4659,7 +4723,7 @@ function set_style(dom, value, prev_styles, next_styles) {
4659
4723
  return next_styles;
4660
4724
  }
4661
4725
  //#endregion
4662
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/attributes.js
4726
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/attributes.js
4663
4727
  /** @import { Blocker, Effect } from '#client' */
4664
4728
  var IS_CUSTOM_ELEMENT = Symbol("is custom element");
4665
4729
  var IS_HTML = Symbol("is html");
@@ -4682,7 +4746,7 @@ function set_attribute(element, attribute, value, skip_warning) {
4682
4746
  if (attributes[attribute] === (attributes[attribute] = value)) return;
4683
4747
  if (attribute === "loading") element[LOADING_ATTR_SYMBOL] = value;
4684
4748
  if (value == null) element.removeAttribute(attribute);
4685
- else if (typeof value !== "string" && get_setters(element).includes(attribute)) element[attribute] = value;
4749
+ else if (typeof value !== "string" && get_setters(element).has(attribute)) element[attribute] = value;
4686
4750
  else element.setAttribute(attribute, value);
4687
4751
  }
4688
4752
  /**
@@ -4695,26 +4759,26 @@ function get_attributes(element) {
4695
4759
  [IS_HTML]: element.namespaceURI === "http://www.w3.org/1999/xhtml"
4696
4760
  });
4697
4761
  }
4698
- /** @type {Map<string, string[]>} */
4762
+ /** @type {Map<string, Set<string>>} */
4699
4763
  var setters_cache = /* @__PURE__ */ new Map();
4700
4764
  /** @param {Element} element */
4701
4765
  function get_setters(element) {
4702
4766
  var cache_key = element.getAttribute("is") || element.nodeName;
4703
4767
  var setters = setters_cache.get(cache_key);
4704
4768
  if (setters) return setters;
4705
- setters_cache.set(cache_key, setters = []);
4769
+ setters_cache.set(cache_key, setters = /* @__PURE__ */ new Set());
4706
4770
  var descriptors;
4707
4771
  var proto = element;
4708
4772
  var element_proto = Element.prototype;
4709
4773
  while (element_proto !== proto) {
4710
4774
  descriptors = get_descriptors(proto);
4711
- for (var key in descriptors) if (descriptors[key].set && key !== "innerHTML" && key !== "textContent" && key !== "innerText") setters.push(key);
4775
+ for (var key in descriptors) if (descriptors[key].set && key !== "innerHTML" && key !== "textContent" && key !== "innerText") setters.add(key);
4712
4776
  proto = get_prototype_of(proto);
4713
4777
  }
4714
4778
  return setters;
4715
4779
  }
4716
4780
  //#endregion
4717
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/bindings/size.js
4781
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/bindings/size.js
4718
4782
  var _ResizeObserverSingleton;
4719
4783
  var _listeners = /* @__PURE__ */ new WeakMap();
4720
4784
  var _observer = /* @__PURE__ */ new WeakMap();
@@ -4766,7 +4830,7 @@ function _getObserver() {
4766
4830
  }
4767
4831
  _defineProperty(ResizeObserverSingleton, "entries", /* @__PURE__ */ new WeakMap());
4768
4832
  //#endregion
4769
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/bindings/this.js
4833
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/bindings/this.js
4770
4834
  /** @import { ComponentContext, Effect } from '#client' */
4771
4835
  /**
4772
4836
  * @param {any} bound_value
@@ -4784,7 +4848,7 @@ function is_bound_this(bound_value, element_or_component) {
4784
4848
  * returns all the parts of the each block context that are used in the expression
4785
4849
  * @returns {void}
4786
4850
  */
4787
- function bind_this(element_or_component = {}, update, get_value, get_parts) {
4851
+ function bind_this(element_or_component = mark_as_component(), update, get_value, get_parts) {
4788
4852
  var component_effect = component_context.r;
4789
4853
  var parent = active_effect;
4790
4854
  effect(() => {
@@ -4908,7 +4972,7 @@ function prop(props, key, flags, fallback) {
4908
4972
  });
4909
4973
  }
4910
4974
  //#endregion
4911
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/legacy/legacy-client.js
4975
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/legacy/legacy-client.js
4912
4976
  /** @import { ComponentConstructorOptions, ComponentType, SvelteComponent, Component } from 'svelte' */
4913
4977
  /**
4914
4978
  * Takes the same options as a Svelte 4 component and the component function and returns a Svelte 4 compatible component.
@@ -5027,7 +5091,7 @@ var Svelte4Component = class {
5027
5091
  }
5028
5092
  };
5029
5093
  //#endregion
5030
- //#region ../../../node_modules/.bun/svelte@5.56.8/node_modules/svelte/src/internal/client/dom/elements/custom-element.js
5094
+ //#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/custom-element.js
5031
5095
  /**
5032
5096
  * @typedef {Object} CustomElementPropDefinition
5033
5097
  * @property {string} [attribute]
@@ -5358,7 +5422,21 @@ function n$1(e, n = {}) {
5358
5422
  }
5359
5423
  return null;
5360
5424
  }
5361
- function r$1({ sourceEl: t, fallbackSelector: r, component: i, complete: a, session: o }) {
5425
+ function r$1(e) {
5426
+ return !!e && typeof e == "object" && !Array.isArray(e);
5427
+ }
5428
+ function i(e, t) {
5429
+ if (e === t) return e;
5430
+ if (!r$1(e) || !r$1(t) || Object.isFrozen(e) || !Object.isExtensible(e)) return t;
5431
+ try {
5432
+ for (let n of Object.keys(e)) n in t || delete e[n];
5433
+ Object.assign(e, t);
5434
+ } catch {
5435
+ return t;
5436
+ }
5437
+ return e;
5438
+ }
5439
+ function a$1({ sourceEl: t, fallbackSelector: r, component: i, complete: a, session: o }) {
5362
5440
  let s = n$1(t, { fallbackSelector: r });
5363
5441
  return s ? typeof s.onSessionChange == "function" ? (s.onSessionChange(o), s) : (s.dispatchEvent(new t$2(i, a)), s) : null;
5364
5442
  }
@@ -5723,8 +5801,7 @@ function Tray($$anchor, $$props) {
5723
5801
  var div = root$1();
5724
5802
  let classes;
5725
5803
  var div_1 = child(div);
5726
- var text = child(div_1, true);
5727
- reset(div_1);
5804
+ var text = only_child(div_1, true);
5728
5805
  var div_2 = sibling(div_1, 2);
5729
5806
  var node = child(div_2);
5730
5807
  var consequent = ($$anchor) => {
@@ -6166,7 +6243,7 @@ function VennClassification($$anchor, $$props) {
6166
6243
  tileId,
6167
6244
  placement
6168
6245
  });
6169
- r$1({
6246
+ a$1({
6170
6247
  sourceEl: containerEl,
6171
6248
  fallbackSelector: "venn-classification",
6172
6249
  component: "venn-classification",
@@ -6343,9 +6420,7 @@ function VennClassification($$anchor, $$props) {
6343
6420
  if (get(showCorrect)) $$render(consequent_1);
6344
6421
  else $$render(alternate, -1);
6345
6422
  });
6346
- var span = sibling(node_2, 2);
6347
- var text = child(span);
6348
- reset(span);
6423
+ var text = only_child(sibling(node_2, 2));
6349
6424
  reset(button);
6350
6425
  template_effect(() => {
6351
6426
  set_attribute(button, "aria-pressed", get(showCorrect));
@@ -6371,8 +6446,7 @@ function VennClassification($$anchor, $$props) {
6371
6446
  var circle_3 = sibling(circle_2);
6372
6447
  reset(mask_1);
6373
6448
  var clipPath = sibling(mask_1);
6374
- var circle_4 = child(clipPath);
6375
- reset(clipPath);
6449
+ var circle_4 = only_child(clipPath);
6376
6450
  var mask_2 = sibling(clipPath);
6377
6451
  var rect_3 = child(mask_2);
6378
6452
  var circle_5 = sibling(rect_3);
@@ -6457,8 +6531,7 @@ function VennClassification($$anchor, $$props) {
6457
6531
  each(node_9, 17, () => geometry.circles, index, ($$anchor, c, idx) => {
6458
6532
  var text_1 = root_10();
6459
6533
  set_attribute(text_1, "text-anchor", idx === 0 ? "start" : "end");
6460
- var text_2 = child(text_1, true);
6461
- reset(text_1);
6534
+ var text_2 = only_child(text_1, true);
6462
6535
  template_effect(($0, $1) => {
6463
6536
  set_attribute(text_1, "x", $0);
6464
6537
  set_attribute(text_1, "y", $1);
@@ -6675,6 +6748,16 @@ var VennClassificationElement = class extends SvelteElementClass {
6675
6748
  constructor(..._args) {
6676
6749
  super(..._args);
6677
6750
  _defineProperty(this, "_internalSession", null);
6751
+ _defineProperty(
6752
+ this,
6753
+ /**
6754
+ * The session object the player handed us. A player reads the learner's
6755
+ * response back off this object, so every update is written into it as well
6756
+ * as into the copy the component renders from.
6757
+ */
6758
+ "_playerSession",
6759
+ null
6760
+ );
6678
6761
  _defineProperty(this, "_model", null);
6679
6762
  _defineProperty(this, "_isComplete", () => {
6680
6763
  return isComplete(this._model, this._internalSession);
@@ -6686,6 +6769,7 @@ var VennClassificationElement = class extends SvelteElementClass {
6686
6769
  this.dispatchEvent(new t$2(this.tagName.toLowerCase(), this._isComplete()));
6687
6770
  });
6688
6771
  _defineProperty(this, "onSessionChange", (updatedSession) => {
6772
+ i(this._playerSession, updatedSession);
6689
6773
  this._internalSession = updatedSession;
6690
6774
  super.session = updatedSession;
6691
6775
  this._dispatchSessionChanged();
@@ -6701,6 +6785,7 @@ var VennClassificationElement = class extends SvelteElementClass {
6701
6785
  }
6702
6786
  set session(s) {
6703
6787
  if (s === this._internalSession) return;
6788
+ this._playerSession = s;
6704
6789
  this._internalSession = s;
6705
6790
  super.session = s;
6706
6791
  this._dispatchSessionChanged();