@sylwellsoftware/fray 0.6.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/README.md +164 -3
  2. package/dist/Components/component.d.ts.map +1 -1
  3. package/dist/Components/layout/tabpanel/tab.d.ts +2 -0
  4. package/dist/Components/layout/tabpanel/tab.d.ts.map +1 -1
  5. package/dist/Components/layout/tabpanel/tabline.d.ts.map +1 -1
  6. package/dist/Components/layout/tabpanel/tabpanel.d.ts +9 -1
  7. package/dist/Components/layout/tabpanel/tabpanel.d.ts.map +1 -1
  8. package/dist/Components/lineinputs/checkbox/Checkbox.d.ts +0 -1
  9. package/dist/Components/lineinputs/checkbox/Checkbox.d.ts.map +1 -1
  10. package/dist/Components/lineinputs/radio.d.ts +51 -0
  11. package/dist/Components/lineinputs/radio.d.ts.map +1 -0
  12. package/dist/index.d.ts +8 -0
  13. package/dist/index.d.ts.map +1 -1
  14. package/dist/index.js +2065 -841
  15. package/dist/index.js.map +1 -1
  16. package/dist/{jsx-dev-runtime-CqunwZ8j.js → jsx-dev-runtime-Kf1Dhu-y.js} +277 -252
  17. package/dist/jsx-dev-runtime-Kf1Dhu-y.js.map +1 -0
  18. package/dist/jsx-dev-runtime.js +1 -1
  19. package/dist/jsx-runtime.js +1 -1
  20. package/dist/routing/RouteLink.d.ts +17 -0
  21. package/dist/routing/RouteLink.d.ts.map +1 -0
  22. package/dist/routing/RouteQuery.d.ts +18 -0
  23. package/dist/routing/RouteQuery.d.ts.map +1 -0
  24. package/dist/routing/RouteScope.d.ts +17 -0
  25. package/dist/routing/RouteScope.d.ts.map +1 -0
  26. package/dist/routing/RouteValue.d.ts +18 -0
  27. package/dist/routing/RouteValue.d.ts.map +1 -0
  28. package/dist/routing/navigationAdapter.d.ts +33 -0
  29. package/dist/routing/navigationAdapter.d.ts.map +1 -0
  30. package/dist/routing/route.d.ts +64 -0
  31. package/dist/routing/route.d.ts.map +1 -0
  32. package/dist/routing/router.d.ts +109 -0
  33. package/dist/routing/router.d.ts.map +1 -0
  34. package/dist/runtime.d.ts +5 -0
  35. package/dist/runtime.d.ts.map +1 -1
  36. package/package.json +3 -3
  37. package/styles/structural.css +166 -34
  38. package/themes/dark.css +13 -1
  39. package/themes/java/theme.css +14 -2
  40. package/themes/light.css +13 -1
  41. package/themes/minimal/theme.css +14 -2
  42. package/themes/shiny/theme.css +95 -87
  43. package/dist/jsx-dev-runtime-CqunwZ8j.js.map +0 -1
@@ -1,6 +1,6 @@
1
- var de = Object.defineProperty;
2
- var he = (e, t, n) => t in e ? de(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
- var c = (e, t, n) => he(e, typeof t != "symbol" ? t + "" : t, n);
1
+ var he = Object.defineProperty;
2
+ var de = (e, t, n) => t in e ? he(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var a = (e, t, n) => de(e, typeof t != "symbol" ? t + "" : t, n);
4
4
  const D = {
5
5
  after: {
6
6
  content: '""',
@@ -74,9 +74,9 @@ const D = {
74
74
  let me = 1;
75
75
  class Q {
76
76
  constructor(t = `runtime-${me++}`) {
77
- c(this, "id");
78
- c(this, "cssFragments", /* @__PURE__ */ new Set());
79
- c(this, "baseStyleMap", /* @__PURE__ */ new Map());
77
+ a(this, "id");
78
+ a(this, "cssFragments", /* @__PURE__ */ new Set());
79
+ a(this, "baseStyleMap", /* @__PURE__ */ new Map());
80
80
  if (typeof t != "string") throw new TypeError("StyleRegistry id must be a string");
81
81
  this.id = t;
82
82
  }
@@ -90,11 +90,11 @@ class Q {
90
90
  const r = typeof n == "string" ? [n] : n;
91
91
  if (!Array.isArray(r))
92
92
  throw new TypeError("Base style names must be a string or array");
93
- for (const s of r) {
94
- if (!Object.hasOwn(D, s))
95
- throw new Error(`Unknown Fray base style: ${String(s)}`);
96
- const i = s, o = this.baseStyleMap.get(i) ?? /* @__PURE__ */ new Set();
97
- o.add(t.trim()), this.baseStyleMap.set(i, o);
93
+ for (const i of r) {
94
+ if (!Object.hasOwn(D, i))
95
+ throw new Error(`Unknown Fray base style: ${String(i)}`);
96
+ const s = i, o = this.baseStyleMap.get(s) ?? /* @__PURE__ */ new Set();
97
+ o.add(t.trim()), this.baseStyleMap.set(s, o);
98
98
  }
99
99
  return this;
100
100
  }
@@ -122,12 +122,12 @@ class Q {
122
122
  generateBaseStyleCSS() {
123
123
  let t = "";
124
124
  for (const [n, r] of this.baseStyleMap) {
125
- const { properties: s, variants: i } = ge(D[n]), o = [...r];
126
- t += U(n, o, s);
127
- for (const [a, l] of Object.entries(i))
125
+ const { properties: i, variants: s } = ge(D[n]), o = [...r];
126
+ t += U(n, o, i);
127
+ for (const [c, l] of Object.entries(s))
128
128
  t += U(
129
- `${n}${a}`,
130
- o.map((u) => we(u, a)),
129
+ `${n}${c}`,
130
+ o.map((u) => we(u, c)),
131
131
  l
132
132
  );
133
133
  }
@@ -150,8 +150,8 @@ class Q {
150
150
  const n = `style[${K}="${Se(this.id)}"]`;
151
151
  let r = t.head.querySelector(n);
152
152
  r == null && (r = t.createElement("style"), r.setAttribute(K, this.id), t.head.prepend(r));
153
- const s = this.generateCSS();
154
- return r.textContent !== s && (r.textContent = s), r;
153
+ const i = this.generateCSS();
154
+ return r.textContent !== i && (r.textContent = i), r;
155
155
  }
156
156
  reset() {
157
157
  this.cssFragments.clear(), this.baseStyleMap.clear();
@@ -164,20 +164,20 @@ const be = new Q("");
164
164
  function ge(e) {
165
165
  const t = {};
166
166
  let n = {};
167
- for (const [r, s] of Object.entries(e))
167
+ for (const [r, i] of Object.entries(e))
168
168
  if (r === "variants") {
169
- if (typeof s != "object")
169
+ if (typeof i != "object")
170
170
  throw new TypeError("Base style variants must be declaration maps");
171
- n = s;
172
- } else if (typeof s == "string")
173
- t[r] = s;
171
+ n = i;
172
+ } else if (typeof i == "string")
173
+ t[r] = i;
174
174
  else
175
175
  throw new TypeError(`Base style property ${r} must be a string`);
176
176
  return { properties: t, variants: n };
177
177
  }
178
178
  function U(e, t, n) {
179
179
  if (t.length === 0 || Object.keys(n).length === 0) return "";
180
- const r = Object.entries(n).map(([s, i]) => ` ${s}: ${i};`).join(`
180
+ const r = Object.entries(n).map(([i, s]) => ` ${i}: ${s};`).join(`
181
181
  `);
182
182
  return `/* ${e} */
183
183
  ${t.join(`,
@@ -202,18 +202,18 @@ function Ue(e) {
202
202
  return X.add(t), t;
203
203
  }
204
204
  function We(e, t) {
205
- if (_(e), typeof t != "function")
205
+ if (x(e), typeof t != "function")
206
206
  throw new TypeError(`Service provider "${e.name}" requires a factory function`);
207
207
  const n = Object.freeze({ key: e, create: t });
208
208
  return ee.add(n), n;
209
209
  }
210
210
  class te {
211
211
  constructor(t = []) {
212
- c(this, "providers", /* @__PURE__ */ new Map());
213
- c(this, "instances", /* @__PURE__ */ new Map());
214
- c(this, "creationOrder", []);
215
- c(this, "resolving", []);
216
- c(this, "disposed", !1);
212
+ a(this, "providers", /* @__PURE__ */ new Map());
213
+ a(this, "instances", /* @__PURE__ */ new Map());
214
+ a(this, "creationOrder", []);
215
+ a(this, "resolving", []);
216
+ a(this, "disposed", !1);
217
217
  if (!Array.isArray(t))
218
218
  throw new TypeError("ServiceScope providers must be an array");
219
219
  for (const n of t) {
@@ -226,21 +226,21 @@ class te {
226
226
  return this.disposed;
227
227
  }
228
228
  has(t) {
229
- return this.assertActive(), _(t), this.providers.has(t);
229
+ return this.assertActive(), x(t), this.providers.has(t);
230
230
  }
231
231
  require(t) {
232
- if (this.assertActive(), _(t), this.instances.has(t)) return this.instances.get(t);
232
+ if (this.assertActive(), x(t), this.instances.has(t)) return this.instances.get(t);
233
233
  const n = this.providers.get(t);
234
234
  if (n == null) throw new Error(`Service "${t.name}" is not registered`);
235
235
  const r = this.resolving.indexOf(t);
236
236
  if (r >= 0) {
237
- const s = [...this.resolving.slice(r), t].map((i) => i.name).join(" -> ");
238
- throw new Error(`Circular service dependency: ${s}`);
237
+ const i = [...this.resolving.slice(r), t].map((s) => s.name).join(" -> ");
238
+ throw new Error(`Circular service dependency: ${i}`);
239
239
  }
240
240
  this.resolving.push(t);
241
241
  try {
242
- const s = n.create(this);
243
- return this.instances.set(t, s), this.creationOrder.push(t), s;
242
+ const i = n.create(this);
243
+ return this.instances.set(t, i), this.creationOrder.push(t), i;
244
244
  } finally {
245
245
  this.resolving.pop();
246
246
  }
@@ -252,10 +252,10 @@ class te {
252
252
  for (const n of [...this.creationOrder].reverse()) {
253
253
  const r = this.instances.get(n);
254
254
  try {
255
- const s = je(r);
256
- s != null && s.call(r);
257
- } catch (s) {
258
- t.push(s);
255
+ const i = Ce(r);
256
+ i != null && i.call(r);
257
+ } catch (i) {
258
+ t.push(i);
259
259
  }
260
260
  }
261
261
  if (this.instances.clear(), this.creationOrder.length = 0, this.resolving.length = 0, t.length === 1) throw t[0];
@@ -272,19 +272,19 @@ function ve(e = []) {
272
272
  function Ee(e) {
273
273
  return e != null && (typeof e == "object" || typeof e == "function") && X.has(e);
274
274
  }
275
- function _(e) {
275
+ function x(e) {
276
276
  if (!Ee(e)) throw new TypeError("Expected a service key created by defineService()");
277
277
  }
278
278
  function Re(e) {
279
279
  if (e == null || typeof e != "object" && typeof e != "function" || !ee.has(e))
280
280
  throw new TypeError("Expected a service provider created by provideService()");
281
281
  }
282
- function je(e) {
282
+ function Ce(e) {
283
283
  if (e == null || typeof e != "object" && typeof e != "function") return null;
284
284
  const t = Reflect.get(e, "dispose");
285
285
  return typeof t == "function" ? t : null;
286
286
  }
287
- const Te = /* @__PURE__ */ new Set([
287
+ const je = /* @__PURE__ */ new Set([
288
288
  "annotation-xml",
289
289
  "color-profile",
290
290
  "font-face",
@@ -294,31 +294,35 @@ const Te = /* @__PURE__ */ new Set([
294
294
  "font-face-name",
295
295
  "missing-glyph"
296
296
  ]);
297
- class M {
297
+ class L {
298
298
  constructor(t = {}, n = ye()) {
299
- c(this, "elementPrefix");
300
- c(this, "elementNameOverrides");
301
- c(this, "styleRegistry");
302
- c(this, "services");
299
+ a(this, "elementPrefix");
300
+ a(this, "elementNameOverrides");
301
+ a(this, "styleRegistry");
302
+ a(this, "services");
303
+ a(this, "router");
304
+ a(this, "routedRoots", /* @__PURE__ */ new WeakSet());
303
305
  if (t == null || typeof t != "object" || Array.isArray(t))
304
306
  throw new TypeError("FrayRuntime options must be an object");
305
307
  const r = t.elementNames ?? {};
306
308
  if (r == null || typeof r != "object" || Array.isArray(r))
307
309
  throw new TypeError("Fray elementNames must be an object");
308
- const s = r.prefix === void 0 ? "fray" : r.prefix;
309
- s !== null && P(s, "Fray element prefix");
310
- const i = r.overrides ?? {};
311
- if (i == null || typeof i != "object" || Array.isArray(i))
310
+ const i = r.prefix === void 0 ? "fray" : r.prefix;
311
+ i !== null && P(i, "Fray element prefix");
312
+ const s = r.overrides ?? {};
313
+ if (s == null || typeof s != "object" || Array.isArray(s))
312
314
  throw new TypeError("Fray element-name overrides must be an object");
313
- for (const [o, a] of Object.entries(i))
314
- P(o, "Fray component host name"), Z(a);
315
- if (this.elementPrefix = s, this.elementNameOverrides = Object.freeze({ ...i }), this.styleRegistry = n, this.services = t.services ?? ve(), !(this.services instanceof te))
315
+ for (const [o, c] of Object.entries(s))
316
+ P(o, "Fray component host name"), Z(c);
317
+ if (this.elementPrefix = i, this.elementNameOverrides = Object.freeze({ ...s }), this.styleRegistry = n, this.services = t.services ?? ve(), !(this.services instanceof te))
316
318
  throw new TypeError("Fray services must be a ServiceScope");
319
+ if (this.router = t.router ?? null, this.router != null && (typeof this.router != "object" || typeof this.router.openScope != "function" || typeof this.router.completeScope != "function"))
320
+ throw new TypeError("Fray router must be a BrowserRouter");
317
321
  }
318
322
  resolveElementName(t, n = null) {
319
323
  P(t, "Fray component host name");
320
- const s = this.elementNameOverrides[t] ?? (this.elementPrefix == null ? n ?? t : `${this.elementPrefix}-${t}`);
321
- return Z(s), s;
324
+ const i = this.elementNameOverrides[t] ?? (this.elementPrefix == null ? n ?? t : `${this.elementPrefix}-${t}`);
325
+ return Z(i), i;
322
326
  }
323
327
  resolveHostSelector(t, n, r = null) {
324
328
  if (typeof t != "string") throw new TypeError("Host selector must be a string");
@@ -333,7 +337,15 @@ class M {
333
337
  return r._setRuntime(this), r;
334
338
  }
335
339
  mount(t, n, r = null) {
336
- return t._setRuntime(this), t.mount(n, r), t;
340
+ t._setRuntime(this);
341
+ let i = null;
342
+ this.router != null && !this.routedRoots.has(t) && (this.routedRoots.add(t), i = this.router.openScope(this.router.root, t), t.onCleanup(i));
343
+ try {
344
+ t.mount(n, r), this.router != null && i != null && this.router.completeScope(this.router.root, t);
345
+ } catch (s) {
346
+ throw i == null || i(), s;
347
+ }
348
+ return t;
337
349
  }
338
350
  registerStyles(t) {
339
351
  if (t == null || typeof t.registerStyles != "function")
@@ -345,18 +357,18 @@ class M {
345
357
  }
346
358
  }
347
359
  function Ze(e = {}) {
348
- return new M(e);
360
+ return new L(e);
349
361
  }
350
- const W = new M({}, be);
362
+ const W = new L({}, be);
351
363
  function P(e, t) {
352
364
  if (typeof e != "string" || !/^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$/.test(e))
353
365
  throw new TypeError(`${t} must be a lowercase kebab-case name`);
354
366
  }
355
367
  function Z(e) {
356
- if (P(e, "Fray element name"), !e.includes("-") || Te.has(e))
368
+ if (P(e, "Fray element name"), !e.includes("-") || je.has(e))
357
369
  throw new TypeError(`Fray element name must be a non-reserved name containing a hyphen: ${e}`);
358
370
  }
359
- const A = Symbol.for("@sylwellsoftware/fray.Fragment"), ne = /* @__PURE__ */ new WeakSet(), Ce = /* @__PURE__ */ new Set([
371
+ const A = Symbol.for("@sylwellsoftware/fray.Fragment"), ne = /* @__PURE__ */ new WeakSet(), Te = /* @__PURE__ */ new Set([
360
372
  "allowFullScreen",
361
373
  "async",
362
374
  "autoFocus",
@@ -405,43 +417,45 @@ function O(e, t = null, ...n) {
405
417
  if (typeof r != "object" || Array.isArray(r))
406
418
  throw new TypeError("VNode props must be an object or null");
407
419
  const {
408
- children: s,
409
- key: i = null,
420
+ children: i,
421
+ key: s = null,
410
422
  ...o
411
423
  } = r;
412
424
  return {
413
425
  type: e,
414
- key: i,
426
+ key: s,
415
427
  props: {
416
428
  ...o,
417
- children: re([s, n])
429
+ children: re([i, n])
418
430
  }
419
431
  };
420
432
  }
421
433
  function Ge(e, ...t) {
422
- return e.reduce((n, r, s) => n + r + String(t[s] ?? ""), "");
434
+ return e.reduce((n, r, i) => n + r + String(t[i] ?? ""), "");
423
435
  }
424
- const h = class h {
436
+ const d = class d {
425
437
  constructor(t = {}) {
426
- c(this, "props");
427
- c(this, "dom", null);
438
+ a(this, "props");
439
+ a(this, "dom", null);
428
440
  /** @internal */
429
- c(this, "_rendered", null);
441
+ a(this, "_rendered", null);
430
442
  /** @internal */
431
- c(this, "_childComponents", /* @__PURE__ */ new Set());
432
- c(this, "initialized", !1);
433
- c(this, "mounted", !1);
434
- c(this, "destroyed", !1);
435
- c(this, "updating", !1);
436
- c(this, "updateRequested", !1);
437
- c(this, "cleanupFunctions", /* @__PURE__ */ new Set());
438
- c(this, "watched", /* @__PURE__ */ new Map());
439
- c(this, "renderReadSubscriptions", /* @__PURE__ */ new Map());
440
- c(this, "collectingRenderReads", null);
443
+ a(this, "_childComponents", /* @__PURE__ */ new Set());
444
+ a(this, "initialized", !1);
445
+ a(this, "mounted", !1);
446
+ a(this, "destroyed", !1);
447
+ a(this, "updating", !1);
448
+ a(this, "updateRequested", !1);
449
+ a(this, "cleanupFunctions", /* @__PURE__ */ new Set());
450
+ a(this, "watched", /* @__PURE__ */ new Map());
451
+ a(this, "renderReadSubscriptions", /* @__PURE__ */ new Map());
452
+ a(this, "collectingRenderReads", null);
441
453
  /** @internal */
442
- c(this, "_runtime", W);
454
+ a(this, "_runtime", W);
455
+ /** @internal Route lineage inherited by nested routed components. */
456
+ a(this, "_routeContext", null);
443
457
  /** JSX component for this instance's runtime-configured custom host. */
444
- c(this, "Host", ({
458
+ a(this, "Host", ({
445
459
  children: t = [],
446
460
  ...n
447
461
  }) => this.host(n, t));
@@ -451,7 +465,7 @@ const h = class h {
451
465
  }
452
466
  static new(...t) {
453
467
  const n = new this(...t);
454
- if (!(n instanceof h))
468
+ if (!(n instanceof d))
455
469
  throw new TypeError("Component.new() requires a Component constructor");
456
470
  return n.mount();
457
471
  }
@@ -461,11 +475,11 @@ const h = class h {
461
475
  static registerStyles(t = W, n = /* @__PURE__ */ new Set()) {
462
476
  if (n.has(this)) return;
463
477
  n.add(this);
464
- const r = this.hostName ?? null, s = this.standaloneHostName ?? null;
465
- this.css && t.styleRegistry.registerCSS(r == null ? this.css : t.resolveHostCSS(this.css, r, s));
466
- const i = De(this.baseStyles);
467
- for (const [o, a] of i)
468
- t.styleRegistry.registerBaseStyle(r == null ? o : t.resolveHostSelector(o, r, s), a);
478
+ const r = this.hostName ?? null, i = this.standaloneHostName ?? null;
479
+ this.css && t.styleRegistry.registerCSS(r == null ? this.css : t.resolveHostCSS(this.css, r, i));
480
+ const s = De(this.baseStyles);
481
+ for (const [o, c] of s)
482
+ t.styleRegistry.registerBaseStyle(r == null ? o : t.resolveHostSelector(o, r, i), c);
469
483
  for (const o of this.dependencies ?? [])
470
484
  o.registerStyles(t, n);
471
485
  }
@@ -477,25 +491,36 @@ const h = class h {
477
491
  }
478
492
  /** Render this component's configured custom host element. */
479
493
  host(t = null, ...n) {
480
- const r = this.constructor, s = r.hostName;
481
- if (s == null)
494
+ const r = this.constructor, i = r.hostName;
495
+ if (i == null)
482
496
  throw new Error(`${this.constructor.name} does not declare a custom host name`);
483
497
  return O(this._runtime.resolveElementName(
484
- s,
498
+ i,
485
499
  r.standaloneHostName
486
500
  ), {
487
501
  ...t,
488
- "data-fray-component": s
502
+ "data-fray-component": i
489
503
  }, ...n);
490
504
  }
491
505
  /** @internal Assign an immutable application runtime before initialization or mounting. */
492
506
  _setRuntime(t) {
493
- if (!(t instanceof M))
507
+ var n;
508
+ if (!(t instanceof L))
494
509
  throw new TypeError("Component runtime must be a FrayRuntime");
495
510
  if (t === this._runtime) return this;
496
511
  if (this.initialized || this.mounted || this._rendered != null)
497
512
  throw new Error("Cannot change a component runtime after initialization");
498
- return this._runtime = t, this;
513
+ return this._runtime = t, this._routeContext == null && (this._routeContext = ((n = t.router) == null ? void 0 : n.root) ?? null), this;
514
+ }
515
+ /** @internal Assign contextual route lineage before initialization. */
516
+ _setRouteContext(t) {
517
+ if (this.initialized || this.mounted || this._rendered != null)
518
+ throw new Error("Cannot change a component route context after initialization");
519
+ return this._routeContext = t, this;
520
+ }
521
+ /** @internal Route lineage inherited by component children. */
522
+ _routeContextForChildren() {
523
+ return this._routeContext;
499
524
  }
500
525
  mount(t = null, n = null) {
501
526
  if (this.destroyed) throw new Error("Cannot mount a destroyed component");
@@ -522,7 +547,7 @@ const h = class h {
522
547
  } finally {
523
548
  this.collectingRenderReads = null;
524
549
  }
525
- this._rendered = q(this._rendered, r, this), this.dom = ae(this._rendered), this.reconcileRenderReads(n), this.afterUpdate(this.dom);
550
+ this._rendered = M(this._rendered, r, this), this.dom = ae(this._rendered), this.reconcileRenderReads(n), this.afterUpdate(this.dom);
526
551
  } while (this.updateRequested && !this.destroyed);
527
552
  } finally {
528
553
  this.updating = !1;
@@ -543,8 +568,8 @@ const h = class h {
543
568
  if (n == null || typeof n.subscribe != "function")
544
569
  throw new TypeError("watch requires emitter-like values");
545
570
  if (this.watched.has(n)) continue;
546
- const r = n.subscribe(({ event: s }) => {
547
- this.mounted && !this.destroyed && this.update(s);
571
+ const r = n.subscribe(({ event: i }) => {
572
+ this.mounted && !this.destroyed && this.update(i);
548
573
  }, { emitCurrent: !1 });
549
574
  this.watched.set(n, r), this.onCleanup(() => {
550
575
  r(), this.watched.delete(n);
@@ -589,14 +614,14 @@ const h = class h {
589
614
  );
590
615
  return this._runtime.services.require(t);
591
616
  }
592
- listen(t, n, r, s) {
617
+ listen(t, n, r, i) {
593
618
  if (t == null || typeof t.addEventListener != "function")
594
619
  throw new TypeError("listen target must be an EventTarget");
595
- const i = r;
596
- return t.addEventListener(n, i, s), this.onCleanup(() => t.removeEventListener(n, i, s)), this;
620
+ const s = r;
621
+ return t.addEventListener(n, s, i), this.onCleanup(() => t.removeEventListener(n, s, i)), this;
597
622
  }
598
623
  registerChild(t) {
599
- if (!(t instanceof h))
624
+ if (!(t instanceof d))
600
625
  throw new TypeError("registerChild requires a Component");
601
626
  return this._childComponents.add(t), t;
602
627
  }
@@ -627,27 +652,27 @@ const h = class h {
627
652
  t.has(n) || (r(), this.renderReadSubscriptions.delete(n));
628
653
  for (const n of t) {
629
654
  if (this.watched.has(n) || this.renderReadSubscriptions.has(n)) continue;
630
- const r = n.subscribe(({ event: s }) => {
631
- this.mounted && !this.destroyed && this.update(s);
655
+ const r = n.subscribe(({ event: i }) => {
656
+ this.mounted && !this.destroyed && this.update(i);
632
657
  }, { emitCurrent: !1 });
633
658
  this.renderReadSubscriptions.set(n, r);
634
659
  }
635
660
  }
636
661
  };
637
- c(h, "dependencies", []), c(h, "requiredServices", []), c(h, "css", ""), c(h, "hostName", null), c(h, "standaloneHostName", null);
638
- let m = h;
662
+ a(d, "dependencies", []), a(d, "requiredServices", []), a(d, "css", ""), a(d, "hostName", null), a(d, "standaloneHostName", null);
663
+ let m = d;
639
664
  function R(e) {
640
665
  return Array.isArray(e) ? O(A, null, e) : e == null || typeof e == "boolean" ? O(A) : e;
641
666
  }
642
667
  function re(e) {
643
668
  const t = [], n = (r) => {
644
669
  if (Array.isArray(r))
645
- for (const s of r) n(s);
670
+ for (const i of r) n(i);
646
671
  else r != null && typeof r != "boolean" && t.push(r);
647
672
  };
648
673
  return n(e), t;
649
674
  }
650
- function j(e, t) {
675
+ function C(e, t) {
651
676
  if (typeof e == "string" || typeof e == "number")
652
677
  return {
653
678
  kind: "text",
@@ -657,18 +682,18 @@ function j(e, t) {
657
682
  owner: t
658
683
  };
659
684
  if (k(e)) {
660
- const i = document.createComment("fray-emitter-start"), o = document.createComment("fray-emitter-end"), a = e.get();
661
- if (Object.is(a, e))
685
+ const s = document.createComment("fray-emitter-start"), o = document.createComment("fray-emitter-end"), c = e.get();
686
+ if (Object.is(c, e))
662
687
  throw new TypeError("A Fray emitter child cannot render itself");
663
688
  const l = document.createDocumentFragment();
664
- l.append(i, o);
665
- const u = j(R(a), t);
689
+ l.append(s, o);
690
+ const u = C(R(c), t);
666
691
  H(l, u, o);
667
692
  const p = {
668
693
  kind: "emitter",
669
694
  key: null,
670
695
  source: e,
671
- start: i,
696
+ start: s,
672
697
  end: o,
673
698
  child: u,
674
699
  unsubscribe: () => {
@@ -678,11 +703,11 @@ function j(e, t) {
678
703
  return p.unsubscribe = e.subscribe(({ value: b }) => {
679
704
  if (Object.is(b, e))
680
705
  throw new TypeError("A Fray emitter child cannot render itself");
681
- p.child = q(p.child, R(b), t);
706
+ p.child = M(p.child, R(b), t);
682
707
  }, { emitCurrent: !1 }), p;
683
708
  }
684
709
  if (e instanceof m)
685
- return e._setRuntime(t._runtime), e.mount(), t.registerChild(e), {
710
+ return e._setRuntime(t._runtime), e._setRouteContext(t._routeContextForChildren()), e.mount(), t.registerChild(e), {
686
711
  kind: "component",
687
712
  key: ce(e.props),
688
713
  type: e.constructor,
@@ -694,32 +719,32 @@ function j(e, t) {
694
719
  };
695
720
  if (!y(e))
696
721
  throw new TypeError(`Invalid Fray child: ${J(e)}`);
697
- const { type: n, key: r = null, props: s } = e;
722
+ const { type: n, key: r = null, props: i } = e;
698
723
  if (n === A) {
699
- const i = document.createComment("fray-fragment-start"), o = document.createComment("fray-fragment-end"), a = {
724
+ const s = document.createComment("fray-fragment-start"), o = document.createComment("fray-fragment-end"), c = {
700
725
  kind: "fragment",
701
726
  key: r,
702
727
  type: n,
703
- start: i,
728
+ start: s,
704
729
  end: o,
705
730
  children: [],
706
731
  owner: t
707
732
  }, l = document.createDocumentFragment();
708
- return l.append(i, o), a.children = $(
733
+ return l.append(s, o), c.children = $(
709
734
  l,
710
735
  [],
711
- s.children,
736
+ i.children,
712
737
  t,
713
738
  o,
714
- i
715
- ), a;
739
+ s
740
+ ), c;
716
741
  }
717
742
  if (typeof n == "string") {
718
- const i = document.createElement(n), o = {
743
+ const s = document.createElement(n), o = {
719
744
  kind: "element",
720
745
  key: r,
721
746
  type: n,
722
- node: i,
747
+ node: s,
723
748
  props: {},
724
749
  listeners: /* @__PURE__ */ new Map(),
725
750
  liveProps: /* @__PURE__ */ new Map(),
@@ -728,45 +753,45 @@ function j(e, t) {
728
753
  children: [],
729
754
  owner: t
730
755
  };
731
- return oe(o, s), o.children = $(i, [], s.children, t), o;
756
+ return oe(o, i), o.children = $(s, [], i.children, t), o;
732
757
  }
733
758
  if (ue(n)) {
734
- const i = s, o = Y(i), a = new n(o);
735
- a._setRuntime(t._runtime);
759
+ const s = i, o = Y(s), c = new n(o);
760
+ c._setRuntime(t._runtime), c._setRouteContext(t._routeContextForChildren());
736
761
  const l = {
737
762
  kind: "component",
738
763
  key: r,
739
764
  type: n,
740
- instance: a,
765
+ instance: c,
741
766
  prebuilt: !1,
742
767
  props: o,
743
768
  liveProps: /* @__PURE__ */ new Map(),
744
769
  owner: t
745
770
  };
746
- return ie(l, i), a.mount(), t.registerChild(a), l;
771
+ return se(l, s), c.mount(), t.registerChild(c), l;
747
772
  }
748
773
  if (typeof n == "function") {
749
- const i = n, o = s, a = Y(o), l = R(i(a)), u = {
774
+ const s = n, o = i, c = Y(o), l = R(s(c)), u = {
750
775
  kind: "function",
751
776
  key: r,
752
- type: i,
753
- props: a,
777
+ type: s,
778
+ props: c,
754
779
  sourceProps: o,
755
780
  liveProps: /* @__PURE__ */ new Map(),
756
- child: j(l, t),
781
+ child: C(l, t),
757
782
  owner: t
758
783
  };
759
784
  return Oe(u), u;
760
785
  }
761
786
  throw new TypeError(`Unsupported vnode type: ${J(n)}`);
762
787
  }
763
- function q(e, t, n) {
764
- if (e == null) return j(t, n);
765
- if (le(e, t)) return se(e, t, n);
766
- const r = j(t, n), s = ae(e), i = (s == null ? void 0 : s.parentNode) ?? null;
767
- return i && H(i, r, s), g(e, !0), r;
788
+ function M(e, t, n) {
789
+ if (e == null) return C(t, n);
790
+ if (le(e, t)) return ie(e, t, n);
791
+ const r = C(t, n), i = ae(e), s = (i == null ? void 0 : i.parentNode) ?? null;
792
+ return s && H(s, r, i), g(e, !0), r;
768
793
  }
769
- function se(e, t, n) {
794
+ function ie(e, t, n) {
770
795
  return e.kind === "text" ? (typeof t != "string" && typeof t != "number" || Object.is(e.value, t) || (e.value = t, e.node.data = String(t)), e) : e.kind === "emitter" ? (!k(t) || e.source !== t, e) : e.kind === "component" ? (t instanceof m || y(t) && Ae(e, t.props), e) : y(t) ? e.kind === "function" ? ($e(e, t.props), e) : e.kind === "fragment" ? (e.children = $(
771
796
  e.start.parentNode,
772
797
  e.children,
@@ -784,232 +809,232 @@ function se(e, t, n) {
784
809
  function Y(e) {
785
810
  return Object.fromEntries(Object.entries(e).map(([t, n]) => [
786
811
  t,
787
- T(n) ? n.emitter.get() : n
812
+ j(n) ? n.emitter.get() : n
788
813
  ]));
789
814
  }
790
- function ie(e, t) {
791
- x(e.liveProps, t, (n, r) => {
815
+ function se(e, t) {
816
+ q(e.liveProps, t, (n, r) => {
792
817
  e.props = { ...e.props, [n]: r }, e.instance.setProps(e.props);
793
818
  }), e.props = V(e.liveProps, t), e.instance.setProps(e.props);
794
819
  }
795
820
  function Ae(e, t) {
796
- ie(e, t);
821
+ se(e, t);
797
822
  }
798
823
  function Oe(e) {
799
- x(e.liveProps, e.sourceProps, (t, n) => {
800
- e.props = { ...e.props, [t]: n }, B(e);
824
+ q(e.liveProps, e.sourceProps, (t, n) => {
825
+ e.props = { ...e.props, [t]: n }, z(e);
801
826
  }), e.props = V(e.liveProps, e.sourceProps);
802
827
  }
803
828
  function $e(e, t) {
804
- e.sourceProps = t, x(e.liveProps, t, (n, r) => {
805
- e.props = { ...e.props, [n]: r }, B(e);
806
- }), e.props = V(e.liveProps, t), B(e);
829
+ e.sourceProps = t, q(e.liveProps, t, (n, r) => {
830
+ e.props = { ...e.props, [n]: r }, z(e);
831
+ }), e.props = V(e.liveProps, t), z(e);
807
832
  }
808
- function B(e) {
833
+ function z(e) {
809
834
  const t = R(e.type(e.props));
810
- e.child = q(e.child, t, e.owner);
811
- }
812
- function x(e, t, n) {
813
- for (const [r, s] of e) {
814
- const i = t[r];
815
- T(i) && i.emitter === s.source || (s.unsubscribe(), e.delete(r));
816
- }
817
- for (const [r, s] of Object.entries(t)) {
818
- if (!T(s) || e.has(r)) continue;
819
- const i = {
820
- source: s.emitter,
821
- value: s.emitter.get(),
835
+ e.child = M(e.child, t, e.owner);
836
+ }
837
+ function q(e, t, n) {
838
+ for (const [r, i] of e) {
839
+ const s = t[r];
840
+ j(s) && s.emitter === i.source || (i.unsubscribe(), e.delete(r));
841
+ }
842
+ for (const [r, i] of Object.entries(t)) {
843
+ if (!j(i) || e.has(r)) continue;
844
+ const s = {
845
+ source: i.emitter,
846
+ value: i.emitter.get(),
822
847
  unsubscribe: () => {
823
848
  }
824
849
  };
825
- i.unsubscribe = s.emitter.subscribe(({ value: o }) => {
826
- e.get(r) === i && (i.value = o, n(r, o));
827
- }, { emitCurrent: !1 }), e.set(r, i);
850
+ s.unsubscribe = i.emitter.subscribe(({ value: o }) => {
851
+ e.get(r) === s && (s.value = o, n(r, o));
852
+ }, { emitCurrent: !1 }), e.set(r, s);
828
853
  }
829
854
  }
830
855
  function V(e, t) {
831
856
  return Object.fromEntries(Object.entries(t).map(([n, r]) => {
832
- var s;
857
+ var i;
833
858
  return [
834
859
  n,
835
- T(r) ? ((s = e.get(n)) == null ? void 0 : s.value) ?? r.emitter.get() : r
860
+ j(r) ? ((i = e.get(n)) == null ? void 0 : i.value) ?? r.emitter.get() : r
836
861
  ];
837
862
  }));
838
863
  }
839
- function $(e, t, n, r, s = null, i = null) {
864
+ function $(e, t, n, r, i = null, s = null) {
840
865
  if (e == null) throw new Error("Cannot patch a detached fragment range");
841
- const o = re(n), a = /* @__PURE__ */ new Map(), l = [];
866
+ const o = re(n), c = /* @__PURE__ */ new Map(), l = [];
842
867
  for (const f of t)
843
- f.key == null ? l.push(f) : a.has(f.key) || a.set(f.key, f);
868
+ f.key == null ? l.push(f) : c.has(f.key) || c.set(f.key, f);
844
869
  const u = /* @__PURE__ */ new Set(), p = /* @__PURE__ */ new Set(), b = [];
845
870
  let pe = 0;
846
871
  for (const f of o) {
847
- const d = E(f);
848
- if (d != null) {
849
- if (u.has(d)) throw new Error(`Duplicate sibling key: ${String(d)}`);
850
- u.add(d);
872
+ const h = E(f);
873
+ if (h != null) {
874
+ if (u.has(h)) throw new Error(`Duplicate sibling key: ${String(h)}`);
875
+ u.add(h);
851
876
  }
852
- const C = d == null ? l[pe++] : a.get(d);
853
- C && le(C, f) ? (p.add(C), b.push(se(C, f, r))) : b.push(j(f, r));
877
+ const T = h == null ? l[pe++] : c.get(h);
878
+ T && le(T, f) ? (p.add(T), b.push(ie(T, f, r))) : b.push(C(f, r));
854
879
  }
855
880
  for (const f of t)
856
881
  p.has(f) || g(f, !0);
857
- let v = i ? i.nextSibling : e.firstChild;
882
+ let v = s ? s.nextSibling : e.firstChild;
858
883
  for (const f of b)
859
- for (const d of w(f))
860
- d === v ? v = v.nextSibling : (e.insertBefore(d, v ?? s), v = d.nextSibling);
884
+ for (const h of w(f))
885
+ h === v ? v = v.nextSibling : (e.insertBefore(h, v ?? i), v = h.nextSibling);
861
886
  return b;
862
887
  }
863
888
  function oe(e, t) {
864
- const { children: n, ...r } = t, s = e.props, i = /* @__PURE__ */ new Set([...Object.keys(s), ...Object.keys(r)]);
889
+ const { children: n, ...r } = t, i = e.props, s = /* @__PURE__ */ new Set([...Object.keys(i), ...Object.keys(r)]);
865
890
  for (const o of ["value", "checked"])
866
891
  if (Object.hasOwn(r, o) && Object.hasOwn(r, `bind:${o}`))
867
892
  throw new Error(`${o} and bind:${o} cannot be used together`);
868
- for (const o of i) {
869
- const a = s[o], l = r[o];
870
- if (qe(o))
893
+ for (const o of s) {
894
+ const c = i[o], l = r[o];
895
+ if (Me(o))
871
896
  ke(e, o, l);
872
897
  else if (o === "ref")
873
- a !== l && ze(e, l);
874
- else if (Me(o))
875
- Fe(e, o, l);
876
- else if (T(l))
898
+ c !== l && _e(e, l);
899
+ else if (Le(o))
877
900
  Ne(e, o, l);
901
+ else if (j(l))
902
+ Fe(e, o, l);
878
903
  else {
879
904
  const u = e.liveProps.get(o);
880
905
  u && (u.unsubscribe(), e.liveProps.delete(o));
881
- const p = (u == null ? void 0 : u.value) ?? a;
906
+ const p = (u == null ? void 0 : u.value) ?? c;
882
907
  Object.is(p, l) || S(e.node, o, p, l);
883
908
  }
884
909
  }
885
910
  e.props = { ...r };
886
911
  }
887
- function Ne(e, t, n) {
912
+ function Fe(e, t, n) {
888
913
  const r = e.liveProps.get(t);
889
914
  if ((r == null ? void 0 : r.source) === n.emitter) return;
890
915
  r == null || r.unsubscribe();
891
- const s = n.emitter.get();
892
- S(e.node, t, (r == null ? void 0 : r.value) ?? e.props[t], s);
893
- const i = {
916
+ const i = n.emitter.get();
917
+ S(e.node, t, (r == null ? void 0 : r.value) ?? e.props[t], i);
918
+ const s = {
894
919
  source: n.emitter,
895
- value: s,
920
+ value: i,
896
921
  unsubscribe: () => {
897
922
  }
898
923
  };
899
- i.unsubscribe = n.emitter.subscribe(({ value: o }) => {
900
- const a = i.value;
901
- i.value = o, Object.is(a, o) || S(e.node, t, a, o);
902
- }, { emitCurrent: !1 }), e.liveProps.set(t, i);
924
+ s.unsubscribe = n.emitter.subscribe(({ value: o }) => {
925
+ const c = s.value;
926
+ s.value = o, Object.is(c, o) || S(e.node, t, c, o);
927
+ }, { emitCurrent: !1 }), e.liveProps.set(t, s);
903
928
  }
904
929
  function ke(e, t, n) {
905
- const r = t.slice(5), s = e.nativeBindings.get(t);
930
+ const r = t.slice(5), i = e.nativeBindings.get(t);
906
931
  if (n == null) {
907
- s && (s.unsubscribe(), e.node.removeEventListener(s.eventName, s.listener), e.nativeBindings.delete(t), S(e.node, r, s.value, void 0));
932
+ i && (i.unsubscribe(), e.node.removeEventListener(i.eventName, i.listener), e.nativeBindings.delete(t), S(e.node, r, i.value, void 0));
908
933
  return;
909
934
  }
910
- if (xe(n, t), (s == null ? void 0 : s.source) === n) return;
911
- s && (s.unsubscribe(), e.node.removeEventListener(s.eventName, s.listener)), Ve(e.node, r);
912
- const i = He(e.node, r), o = n.get();
913
- S(e.node, r, s == null ? void 0 : s.value, o);
914
- const a = () => {
935
+ if (qe(n, t), (i == null ? void 0 : i.source) === n) return;
936
+ i && (i.unsubscribe(), e.node.removeEventListener(i.eventName, i.listener)), Ve(e.node, r);
937
+ const s = He(e.node, r), o = n.get();
938
+ S(e.node, r, i == null ? void 0 : i.value, o);
939
+ const c = () => {
915
940
  n.set(Reflect.get(e.node, r), `${t} changed`);
916
941
  }, l = {
917
942
  source: n,
918
943
  value: o,
919
- eventName: i,
920
- listener: a,
944
+ eventName: s,
945
+ listener: c,
921
946
  unsubscribe: () => {
922
947
  }
923
948
  };
924
949
  l.unsubscribe = n.subscribe(({ value: u }) => {
925
950
  const p = l.value;
926
951
  l.value = u, Object.is(p, u) || S(e.node, r, p, u);
927
- }, { emitCurrent: !1 }), e.node.addEventListener(i, a), e.nativeBindings.set(t, l);
952
+ }, { emitCurrent: !1 }), e.node.addEventListener(s, c), e.nativeBindings.set(t, l);
928
953
  }
929
- function Fe(e, t, n) {
930
- const r = t.slice(2).toLowerCase(), s = e.listeners.get(t);
931
- if (s && s !== n && (e.node.removeEventListener(r, s), e.listeners.delete(t)), n != null && typeof n != "function")
954
+ function Ne(e, t, n) {
955
+ const r = t.slice(2).toLowerCase(), i = e.listeners.get(t);
956
+ if (i && i !== n && (e.node.removeEventListener(r, i), e.listeners.delete(t)), n != null && typeof n != "function")
932
957
  throw new TypeError(`${t} must be a function or null`);
933
- if (typeof n == "function" && s !== n) {
934
- const i = n;
935
- e.node.addEventListener(r, i), e.listeners.set(t, i);
958
+ if (typeof n == "function" && i !== n) {
959
+ const s = n;
960
+ e.node.addEventListener(r, s), e.listeners.set(t, s);
936
961
  }
937
962
  }
938
- function ze(e, t) {
939
- if (L(e.ref, null), t != null && typeof t != "function" && typeof t != "object")
963
+ function _e(e, t) {
964
+ if (B(e.ref, null), t != null && typeof t != "function" && typeof t != "object")
940
965
  throw new TypeError("ref must be a function, object, or null");
941
- e.ref = t, L(e.ref, e.node);
966
+ e.ref = t, B(e.ref, e.node);
942
967
  }
943
968
  function S(e, t, n, r) {
944
969
  if (t === "class" || t === "className") {
945
- F(e, "class", r);
970
+ N(e, "class", r);
946
971
  return;
947
972
  }
948
973
  if (t === "for" || t === "htmlFor") {
949
- F(e, "for", r);
974
+ N(e, "for", r);
950
975
  return;
951
976
  }
952
977
  if (t === "dataset") {
953
- _e(e, n, r);
978
+ xe(e, n, r);
954
979
  return;
955
980
  }
956
981
  if (t === "style") {
957
- Be(e, n, r);
982
+ ze(e, n, r);
958
983
  return;
959
984
  }
960
985
  if (t === "dangerouslySetInnerHTML")
961
986
  throw new Error("dangerouslySetInnerHTML is not supported");
962
- const s = Le(t);
963
- if (Ce.has(s)) {
964
- const i = !!r;
965
- s in e && Reflect.set(e, s, i), e.toggleAttribute(z(t), i);
987
+ const i = Be(t);
988
+ if (Te.has(i)) {
989
+ const s = !!r;
990
+ i in e && Reflect.set(e, i, s), e.toggleAttribute(_(t), s);
966
991
  return;
967
992
  }
968
- if (Pe.has(s) && s in e) {
969
- const i = r ?? (s === "value" ? "" : !1);
970
- Object.is(Reflect.get(e, s), i) || Reflect.set(e, s, i), r == null && e.removeAttribute(z(t));
993
+ if (Pe.has(i) && i in e) {
994
+ const s = r ?? (i === "value" ? "" : !1);
995
+ Object.is(Reflect.get(e, i), s) || Reflect.set(e, i, s), r == null && e.removeAttribute(_(t));
971
996
  return;
972
997
  }
973
- F(e, z(t), r);
998
+ N(e, _(t), r);
974
999
  }
975
- function _e(e, t, n) {
976
- const r = N(t, "dataset"), s = N(n, "dataset");
977
- for (const i of /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(s)])) {
978
- const o = s[i];
979
- o == null ? delete e.dataset[i] : e.dataset[i] = String(o);
1000
+ function xe(e, t, n) {
1001
+ const r = F(t, "dataset"), i = F(n, "dataset");
1002
+ for (const s of /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(i)])) {
1003
+ const o = i[s];
1004
+ o == null ? delete e.dataset[s] : e.dataset[s] = String(o);
980
1005
  }
981
1006
  }
982
- function Be(e, t, n) {
1007
+ function ze(e, t, n) {
983
1008
  if (typeof n == "string") {
984
1009
  e.style.cssText = n;
985
1010
  return;
986
1011
  }
987
- const r = typeof t == "string" ? {} : N(t, "style"), s = N(n, "style");
1012
+ const r = typeof t == "string" ? {} : F(t, "style"), i = F(n, "style");
988
1013
  typeof t == "string" && (e.style.cssText = "");
989
- for (const i of /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(s)])) {
990
- const o = s[i];
991
- i.startsWith("--") ? o == null ? e.style.removeProperty(i) : e.style.setProperty(i, String(o)) : Reflect.set(e.style, i, o == null ? "" : String(o));
1014
+ for (const s of /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(i)])) {
1015
+ const o = i[s];
1016
+ s.startsWith("--") ? o == null ? e.style.removeProperty(s) : e.style.setProperty(s, String(o)) : Reflect.set(e.style, s, o == null ? "" : String(o));
992
1017
  }
993
1018
  }
994
- function N(e, t) {
1019
+ function F(e, t) {
995
1020
  if (e == null) return {};
996
1021
  if (typeof e != "object" || Array.isArray(e))
997
1022
  throw new TypeError(`${t} must be an object or null`);
998
1023
  return e;
999
1024
  }
1000
- function F(e, t, n) {
1025
+ function N(e, t, n) {
1001
1026
  n == null || n === !1 ? e.removeAttribute(t) : n === !0 ? e.setAttribute(t, "") : e.setAttribute(t, String(n));
1002
1027
  }
1003
- function Le(e) {
1028
+ function Be(e) {
1004
1029
  return e === "readonly" ? "readOnly" : e === "autofocus" ? "autoFocus" : e;
1005
1030
  }
1006
- function z(e) {
1031
+ function _(e) {
1007
1032
  return e === "className" ? "class" : e === "htmlFor" ? "for" : /^aria[A-Z]/.test(e) || /^data[A-Z]/.test(e) ? G(e) : e.replace(/[A-Z]/g, (t) => `-${t.toLowerCase()}`);
1008
1033
  }
1009
1034
  function G(e) {
1010
1035
  return e.replace(/[A-Z]/g, (t) => `-${t.toLowerCase()}`);
1011
1036
  }
1012
- function L(e, t) {
1037
+ function B(e, t) {
1013
1038
  e != null && (typeof e == "function" ? e(t) : e.current = t);
1014
1039
  }
1015
1040
  function g(e, t) {
@@ -1029,7 +1054,7 @@ function g(e, t) {
1029
1054
  return;
1030
1055
  }
1031
1056
  if (e.kind === "element") {
1032
- L(e.ref, null);
1057
+ B(e.ref, null);
1033
1058
  for (const [n, r] of e.listeners)
1034
1059
  e.node.removeEventListener(n.slice(2).toLowerCase(), r);
1035
1060
  e.listeners.clear();
@@ -1084,13 +1109,13 @@ function y(e) {
1084
1109
  function ue(e) {
1085
1110
  return typeof e == "function" && (e === m || e.prototype instanceof m);
1086
1111
  }
1087
- function Me(e) {
1112
+ function Le(e) {
1088
1113
  return /^on[A-Z]/.test(e);
1089
1114
  }
1090
- function qe(e) {
1115
+ function Me(e) {
1091
1116
  return e === "bind:value" || e === "bind:checked";
1092
1117
  }
1093
- function T(e) {
1118
+ function j(e) {
1094
1119
  return e != null && typeof e == "object" && ne.has(e);
1095
1120
  }
1096
1121
  function k(e) {
@@ -1099,7 +1124,7 @@ function k(e) {
1099
1124
  function I(e, t) {
1100
1125
  if (!k(e)) throw new TypeError(`${t} requires a readable emitter`);
1101
1126
  }
1102
- function xe(e, t) {
1127
+ function qe(e, t) {
1103
1128
  if (I(e, t), typeof Reflect.get(e, "set") != "function")
1104
1129
  throw new TypeError(`${t} requires a writable emitter`);
1105
1130
  }
@@ -1154,21 +1179,21 @@ export {
1154
1179
  A as F,
1155
1180
  te as S,
1156
1181
  Je as a,
1157
- M as b,
1182
+ L as b,
1158
1183
  Ge as c,
1159
1184
  Q as d,
1160
1185
  Ze as e,
1161
1186
  ve as f,
1162
1187
  ye as g,
1163
- W as h,
1188
+ O as h,
1164
1189
  y as i,
1165
1190
  fe as j,
1166
- Ue as k,
1167
- O as l,
1191
+ W as k,
1192
+ Ue as l,
1168
1193
  Qe as m,
1169
1194
  Ye as n,
1170
1195
  Xe as o,
1171
1196
  We as p,
1172
1197
  be as s
1173
1198
  };
1174
- //# sourceMappingURL=jsx-dev-runtime-CqunwZ8j.js.map
1199
+ //# sourceMappingURL=jsx-dev-runtime-Kf1Dhu-y.js.map