@capillaryjs/capillary-ui 1.0.0-alpha.1 → 1.1.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 (59) hide show
  1. package/CHANGELOG.md +65 -0
  2. package/README.md +88 -18
  3. package/dist/Components/Placeholder.d.ts.map +1 -1
  4. package/dist/Components/component.d.ts +6 -0
  5. package/dist/Components/component.d.ts.map +1 -1
  6. package/dist/Components/data/listview/listview.d.ts +4 -3
  7. package/dist/Components/data/listview/listview.d.ts.map +1 -1
  8. package/dist/Components/data/selectionhandler.d.ts +1 -0
  9. package/dist/Components/data/selectionhandler.d.ts.map +1 -1
  10. package/dist/Components/data/table/DataTable.d.ts +1 -0
  11. package/dist/Components/data/table/DataTable.d.ts.map +1 -1
  12. package/dist/Components/data/table/TableHeader.d.ts.map +1 -1
  13. package/dist/Components/data/table/TableHeaderCell.d.ts.map +1 -1
  14. package/dist/Components/data/table/tableDataSource.d.ts +7 -1
  15. package/dist/Components/data/table/tableDataSource.d.ts.map +1 -1
  16. package/dist/Components/data/treeview/treeview.d.ts +3 -2
  17. package/dist/Components/data/treeview/treeview.d.ts.map +1 -1
  18. package/dist/Components/layout/groupBox.d.ts +4 -0
  19. package/dist/Components/layout/groupBox.d.ts.map +1 -1
  20. package/dist/Components/layout/header.d.ts.map +1 -1
  21. package/dist/Components/layout/panel.d.ts.map +1 -1
  22. package/dist/Components/layout/sidebar.d.ts +1 -1
  23. package/dist/Components/layout/sidebar.d.ts.map +1 -1
  24. package/dist/Components/lineinputs/LabeledInputControl.d.ts.map +1 -1
  25. package/dist/Components/lineinputs/SelectControl.d.ts.map +1 -1
  26. package/dist/Components/lineinputs/datetime/DatePicker.d.ts +19 -57
  27. package/dist/Components/lineinputs/datetime/DatePicker.d.ts.map +1 -1
  28. package/dist/Components/lineinputs/datetime/DateTimePicker.d.ts +20 -48
  29. package/dist/Components/lineinputs/datetime/DateTimePicker.d.ts.map +1 -1
  30. package/dist/Components/lineinputs/datetime/TemporalInput.d.ts +59 -0
  31. package/dist/Components/lineinputs/datetime/TemporalInput.d.ts.map +1 -0
  32. package/dist/Components/lineinputs/datetime/TimePicker.d.ts +18 -41
  33. package/dist/Components/lineinputs/datetime/TimePicker.d.ts.map +1 -1
  34. package/dist/Components/lineinputs/datetime/localDateTime.d.ts +49 -0
  35. package/dist/Components/lineinputs/datetime/localDateTime.d.ts.map +1 -0
  36. package/dist/Components/lineinputs/datetime/timeString.d.ts +5 -1
  37. package/dist/Components/lineinputs/datetime/timeString.d.ts.map +1 -1
  38. package/dist/Components/lineinputs/textbox.d.ts.map +1 -1
  39. package/dist/Components/lineinputs/toggle.d.ts.map +1 -1
  40. package/dist/Components/menu/button.d.ts.map +1 -1
  41. package/dist/index.d.ts +3 -1
  42. package/dist/index.d.ts.map +1 -1
  43. package/dist/index.js +2311 -2714
  44. package/dist/index.js.map +1 -1
  45. package/dist/{jsx-dev-runtime-BAF7C1E1.js → jsx-dev-runtime-D3UnwrKT.js} +141 -147
  46. package/dist/jsx-dev-runtime-D3UnwrKT.js.map +1 -0
  47. package/dist/jsx-dev-runtime.js +1 -1
  48. package/dist/jsx-runtime.js +1 -1
  49. package/dist/localization.d.ts +0 -8
  50. package/dist/localization.d.ts.map +1 -1
  51. package/docs/application-composition-guide.md +2 -1
  52. package/package.json +3 -3
  53. package/styles/structural.css +393 -356
  54. package/themes/base.css +5 -3
  55. package/themes/minimal/theme.css +3 -2
  56. package/themes/shiny/theme.css +14 -18
  57. package/dist/Components/lineinputs/datetime/Calendar.d.ts +0 -23
  58. package/dist/Components/lineinputs/datetime/Calendar.d.ts.map +0 -1
  59. package/dist/jsx-dev-runtime-BAF7C1E1.js.map +0 -1
@@ -1,10 +1,10 @@
1
1
  var ge = Object.defineProperty;
2
2
  var we = (e, t, n) => t in e ? ge(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var l = (e, t, n) => we(e, typeof t != "symbol" ? t + "" : t, n);
4
- const H = "data-cap-structural-styles";
5
- let ve = 1;
4
+ const D = "data-cap-structural-styles";
5
+ let Se = 1;
6
6
  class J {
7
- constructor(t = `runtime-${ve++}`) {
7
+ constructor(t = `runtime-${Se++}`) {
8
8
  l(this, "id");
9
9
  l(this, "cssFragments", /* @__PURE__ */ new Map());
10
10
  if (typeof t != "string") throw new TypeError("StyleRegistry id must be a string");
@@ -38,9 +38,9 @@ class J {
38
38
  injectAll(t = globalThis.document) {
39
39
  if ((t == null ? void 0 : t.head) == null)
40
40
  throw new TypeError("StyleRegistry.injectAll requires a document with a head");
41
- const n = `style[${H}="${Ee(this.id)}"]`;
41
+ const n = `style[${D}="${Ce(this.id)}"]`;
42
42
  let r = t.head.querySelector(n);
43
- r == null && (r = t.createElement("style"), r.setAttribute(H, this.id), t.head.prepend(r));
43
+ r == null && (r = t.createElement("style"), r.setAttribute(D, this.id), t.head.prepend(r));
44
44
  const i = this.generateCSS();
45
45
  return r.textContent !== i && (r.textContent = i), r;
46
46
  }
@@ -48,19 +48,19 @@ class J {
48
48
  this.cssFragments.clear();
49
49
  }
50
50
  }
51
- function Se() {
51
+ function ve() {
52
52
  return new J();
53
53
  }
54
- const Ce = new J("");
55
- function Ee(e) {
54
+ const Ee = new J("");
55
+ function Ce(e) {
56
56
  return e.replaceAll("\\", "\\\\").replaceAll('"', '\\"');
57
57
  }
58
58
  function Q(e, t) {
59
59
  let n = "", r = 0;
60
60
  for (; r < e.length; ) {
61
- const i = Oe(e, r);
61
+ const i = Le(e, r);
62
62
  if (i < 0) return n + e.slice(r);
63
- const s = Pe(e, i);
63
+ const s = Te(e, i);
64
64
  if (s < 0) return n + e.slice(r);
65
65
  const o = e.slice(r, i), a = e.slice(i + 1, s), c = o.trim();
66
66
  n += c.startsWith("@") ? `${o}{${Q(a, t)}}` : `${Re(o, t)}{${a}}`, r = s + 1;
@@ -71,11 +71,11 @@ function Re(e, t) {
71
71
  var o, a, c;
72
72
  if (t.length === 1 || !e.includes("&"))
73
73
  return t.length === 1 ? e.replaceAll("&", t[0]) : e;
74
- const n = ((o = e.match(/^\s*/)) == null ? void 0 : o[0]) ?? "", r = ((a = e.match(/\s*$/)) == null ? void 0 : a[0]) ?? "", i = Le(e.trim()), s = ((c = n.match(/(?:^|\n)([ \t]*)$/)) == null ? void 0 : c[1]) ?? "";
74
+ const n = ((o = e.match(/^\s*/)) == null ? void 0 : o[0]) ?? "", r = ((a = e.match(/\s*$/)) == null ? void 0 : a[0]) ?? "", i = Oe(e.trim()), s = ((c = n.match(/(?:^|\n)([ \t]*)$/)) == null ? void 0 : c[1]) ?? "";
75
75
  return n + i.flatMap((u) => u.includes("&") ? t.map((p) => u.replaceAll("&", p)) : [u]).join(`,
76
76
  ${s}`) + r;
77
77
  }
78
- function Le(e) {
78
+ function Oe(e) {
79
79
  const t = [];
80
80
  let n = 0, r = 0, i = 0, s = null;
81
81
  for (let o = 0; o < e.length; o += 1) {
@@ -88,7 +88,7 @@ function Le(e) {
88
88
  }
89
89
  return t.push(e.slice(n).trim()), t.filter(Boolean);
90
90
  }
91
- function Oe(e, t) {
91
+ function Le(e, t) {
92
92
  for (let n = t; n < e.length; n += 1) {
93
93
  const r = e[n];
94
94
  if (r === '"' || r === "'")
@@ -100,7 +100,7 @@ function Oe(e, t) {
100
100
  }
101
101
  return -1;
102
102
  }
103
- function Pe(e, t) {
103
+ function Te(e, t) {
104
104
  let n = 1;
105
105
  for (let r = t + 1; r < e.length; r += 1) {
106
106
  const i = e[r];
@@ -198,14 +198,14 @@ class re {
198
198
  if (this.disposed) throw new Error("ServiceScope has been disposed");
199
199
  }
200
200
  }
201
- function Te(e = []) {
201
+ function je(e = []) {
202
202
  return new re(e);
203
203
  }
204
- function je(e) {
204
+ function Pe(e) {
205
205
  return e != null && (typeof e == "object" || typeof e == "function") && te.has(e);
206
206
  }
207
207
  function I(e) {
208
- if (!je(e)) throw new TypeError("Expected a service key created by defineService()");
208
+ if (!Pe(e)) throw new TypeError("Expected a service key created by defineService()");
209
209
  }
210
210
  function Ae(e) {
211
211
  if (e == null || typeof e != "object" && typeof e != "function" || !ne.has(e))
@@ -216,11 +216,8 @@ function ze(e) {
216
216
  const t = Reflect.get(e, "dispose");
217
217
  return typeof t == "function" ? t : null;
218
218
  }
219
- const P = Object.freeze({
219
+ const T = Object.freeze({
220
220
  breadcrumbLabel: "Breadcrumb",
221
- calendarGridLabel: "Choose a date",
222
- calendarNextMonthLabel: "Next month",
223
- calendarPreviousMonthLabel: "Previous month",
224
221
  checkboxOptionLabel: "Option",
225
222
  checkboxStateLabel: (e, t) => `${e}: ${t}`,
226
223
  colorOptionGrayLabel: "Gray",
@@ -235,10 +232,6 @@ const P = Object.freeze({
235
232
  dataTableLoadError: "Unable to load rows",
236
233
  dataTableLoading: "Loading rows…",
237
234
  dataTableRetry: "Retry",
238
- datePickerDialogLabel: "Choose a date",
239
- datePickerOpenCalendarLabel: "Open calendar",
240
- dateTimePickerDateLabel: "Date",
241
- dateTimePickerTimeLabel: "Time",
242
235
  dialogCloseLabel: "Close",
243
236
  dropdownLoadError: "Unable to load options",
244
237
  dropdownPlaceholder: "Select…",
@@ -263,7 +256,6 @@ const P = Object.freeze({
263
256
  themeOptionJavaLabel: "Java",
264
257
  themeOptionMinimalLabel: "Minimal",
265
258
  themeOptionShinyLabel: "Shiny",
266
- timePickerPlaceholder: "Select time…",
267
259
  toolbarLabel: "Actions",
268
260
  treeViewEmpty: "No tree items",
269
261
  treeViewLoadError: "Unable to load tree items",
@@ -279,30 +271,30 @@ class ie {
279
271
  return this.messages[t];
280
272
  }
281
273
  }
282
- const ke = new ie(
274
+ const _e = new ie(
283
275
  void 0,
284
- P
276
+ T
285
277
  );
286
- function _e(e) {
287
- if (e == null) return ke;
278
+ function ke(e) {
279
+ if (e == null) return _e;
288
280
  if (typeof e != "object" || Array.isArray(e))
289
281
  throw new TypeError("Capillary UI localization must be an object");
290
- const t = Ne(e.locale), n = e.messages;
282
+ const t = $e(e.locale), n = e.messages;
291
283
  if (n != null && (typeof n != "object" || Array.isArray(n)))
292
284
  throw new TypeError("Capillary UI localization messages must be an object");
293
- const r = { ...P };
285
+ const r = { ...T };
294
286
  if (n != null)
295
- for (const i of Object.keys(P)) {
287
+ for (const i of Object.keys(T)) {
296
288
  const s = n[i];
297
289
  if (s === void 0) continue;
298
- const o = P[i];
290
+ const o = T[i];
299
291
  if (typeof s != typeof o)
300
292
  throw new TypeError(`Capillary UI localization message "${i}" has the wrong type`);
301
293
  Object.assign(r, { [i]: s });
302
294
  }
303
295
  return new ie(t, Object.freeze(r));
304
296
  }
305
- function Ne(e) {
297
+ function $e(e) {
306
298
  if (typeof e != "string" || e.trim() === "")
307
299
  throw new TypeError("Capillary UI localization locale must be a non-empty BCP 47 language tag");
308
300
  try {
@@ -311,7 +303,7 @@ function Ne(e) {
311
303
  throw new RangeError(`Invalid Capillary UI localization locale: ${e}`, { cause: t });
312
304
  }
313
305
  }
314
- const $e = /* @__PURE__ */ new Set([
306
+ const Ne = /* @__PURE__ */ new Set([
315
307
  "annotation-xml",
316
308
  "color-profile",
317
309
  "font-face",
@@ -321,8 +313,8 @@ const $e = /* @__PURE__ */ new Set([
321
313
  "font-face-name",
322
314
  "missing-glyph"
323
315
  ]);
324
- class U {
325
- constructor(t = {}, n = Se()) {
316
+ class M {
317
+ constructor(t = {}, n = ve()) {
326
318
  l(this, "styleRegistry");
327
319
  l(this, "services");
328
320
  l(this, "router");
@@ -332,7 +324,7 @@ class U {
332
324
  throw new TypeError("CapillaryUiRuntime options must be an object");
333
325
  if (Object.hasOwn(t, "elementNames"))
334
326
  throw new TypeError("CapillaryUiRuntime no longer supports configurable element names");
335
- if (this.styleRegistry = n, this.localization = _e(t.localization), this.services = t.services ?? Te(), !(this.services instanceof re))
327
+ if (this.styleRegistry = n, this.localization = ke(t.localization), this.services = t.services ?? je(), !(this.services instanceof re))
336
328
  throw new TypeError("Capillary UI services must be a ServiceScope");
337
329
  if (this.router = t.router ?? null, this.router != null && (typeof this.router != "object" || typeof this.router.openScope != "function" || typeof this.router.completeScope != "function"))
338
330
  throw new TypeError("Capillary UI router must be a BrowserRouter");
@@ -376,18 +368,18 @@ class U {
376
368
  }
377
369
  }
378
370
  function at(e = {}) {
379
- return new U(e);
371
+ return new M(e);
380
372
  }
381
- const K = new U({}, Ce);
373
+ const K = new M({}, Ee);
382
374
  function se(e, t) {
383
375
  if (typeof e != "string" || !/^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$/.test(e))
384
376
  throw new TypeError(`${t} must be a lowercase kebab-case name`);
385
377
  }
386
378
  function Ie(e) {
387
- if (se(e, "Capillary UI element name"), !e.includes("-") || $e.has(e))
379
+ if (se(e, "Capillary UI element name"), !e.includes("-") || Ne.has(e))
388
380
  throw new TypeError(`Capillary UI element name must be a non-reserved name containing a hyphen: ${e}`);
389
381
  }
390
- const j = Symbol.for("@capillaryjs/capillary-ui.Fragment"), oe = /* @__PURE__ */ new WeakSet(), xe = /* @__PURE__ */ new Set([
382
+ const P = Symbol.for("@capillaryjs/capillary-ui.Fragment"), oe = /* @__PURE__ */ new WeakSet(), Ue = /* @__PURE__ */ new Set([
391
383
  "allowFullScreen",
392
384
  "async",
393
385
  "autoFocus",
@@ -411,7 +403,7 @@ const j = Symbol.for("@capillaryjs/capillary-ui.Fragment"), oe = /* @__PURE__ */
411
403
  "required",
412
404
  "reversed",
413
405
  "selected"
414
- ]), Me = /* @__PURE__ */ new Set([
406
+ ]), xe = /* @__PURE__ */ new Set([
415
407
  "checked",
416
408
  "defaultChecked",
417
409
  "defaultValue",
@@ -427,7 +419,7 @@ const j = Symbol.for("@capillaryjs/capillary-ui.Fragment"), oe = /* @__PURE__ */
427
419
  "value"
428
420
  ]), W = "data-cap";
429
421
  function lt(e) {
430
- D(e, "live");
422
+ H(e, "live");
431
423
  const t = Object.freeze({ emitter: e });
432
424
  return oe.add(t), t;
433
425
  }
@@ -449,10 +441,10 @@ function A(e, t = null, ...n) {
449
441
  }
450
442
  };
451
443
  }
452
- function Ue(e, ...t) {
444
+ function Me(e, ...t) {
453
445
  return e.reduce((n, r, i) => n + r + String(t[i] ?? ""), "");
454
446
  }
455
- const m = class m {
447
+ const h = class h {
456
448
  constructor(t = {}) {
457
449
  l(this, "props");
458
450
  l(this, "dom", null);
@@ -486,7 +478,7 @@ const m = class m {
486
478
  }
487
479
  static new(...t) {
488
480
  const n = new this(...t);
489
- if (!(n instanceof m))
481
+ if (!(n instanceof h))
490
482
  throw new TypeError("Component.new() requires a Component constructor");
491
483
  return n.mount();
492
484
  }
@@ -512,7 +504,7 @@ const m = class m {
512
504
  }
513
505
  /** Render this component's configured custom host element. */
514
506
  host(t = null, ...n) {
515
- const i = this.constructor.hostName;
507
+ const r = this.constructor, i = r.hostName;
516
508
  if (i == null)
517
509
  throw new Error(`${this.constructor.name} does not declare a custom host name`);
518
510
  const {
@@ -523,13 +515,14 @@ const m = class m {
523
515
  return A(this._runtime.resolveElementName(i), {
524
516
  ...a,
525
517
  ...u == null ? {} : { className: u },
526
- "data-cap-component": i
518
+ "data-cap-component": i,
519
+ ...r.dataSurface == null ? {} : { "data-cap-surface": r.dataSurface }
527
520
  }, ...n);
528
521
  }
529
522
  /** @internal Assign an immutable application runtime before initialization or mounting. */
530
523
  _setRuntime(t) {
531
524
  var n;
532
- if (!(t instanceof U))
525
+ if (!(t instanceof M))
533
526
  throw new TypeError("Component runtime must be a CapillaryUiRuntime");
534
527
  if (t === this._runtime) return this;
535
528
  if (this.initialized || this.mounted || this._rendered != null)
@@ -660,7 +653,7 @@ const m = class m {
660
653
  return t.addEventListener(n, s, i), this.onCleanup(() => t.removeEventListener(n, s, i)), this;
661
654
  }
662
655
  registerChild(t) {
663
- if (!(t instanceof m))
656
+ if (!(t instanceof h))
664
657
  throw new TypeError("registerChild requires a Component");
665
658
  return this._childComponents.add(t), t;
666
659
  }
@@ -680,25 +673,25 @@ const m = class m {
680
673
  throw new Error(`${t.name} requires unregistered service "${n.name}"`);
681
674
  }
682
675
  validateIslandAncestry(t) {
683
- if (!$(t)) return;
676
+ if (!N(t)) return;
684
677
  if (this.hasIslandDescendant())
685
678
  throw new Error("An island component cannot contain another island");
686
679
  let n = this._parentComponent;
687
680
  for (; n != null; ) {
688
- if ($(n.props))
681
+ if (N(n.props))
689
682
  throw new Error("An island component cannot be nested inside another island");
690
683
  n = n._parentComponent;
691
684
  }
692
685
  }
693
686
  hasIslandDescendant() {
694
687
  for (const t of this._childComponents)
695
- if ($(t.props) || t.hasIslandDescendant()) return !0;
688
+ if (N(t.props) || t.hasIslandDescendant()) return !0;
696
689
  return !1;
697
690
  }
698
691
  onDestroy() {
699
692
  }
700
693
  trackRenderRead(t) {
701
- if (D(t, "Component.read"), this.collectingRenderReads == null)
694
+ if (H(t, "Component.read"), this.collectingRenderReads == null)
702
695
  throw new Error("Component.read() and snapshot() may only be called during render()");
703
696
  this.collectingRenderReads.add(t);
704
697
  }
@@ -714,8 +707,8 @@ const m = class m {
714
707
  }
715
708
  }
716
709
  };
717
- l(m, "dependencies", []), l(m, "requiredServices", []), /** Component `live()` bindings are opt-in; subclasses declare their allowlist. */
718
- l(m, "liveProps", []), l(m, "css", Ue`
710
+ l(h, "dependencies", []), l(h, "requiredServices", []), /** Component `live()` bindings are opt-in; subclasses declare their allowlist. */
711
+ l(h, "liveProps", []), l(h, "css", Me`
719
712
  .cap-fill-horizontal,
720
713
  .cap-fill-vertical {
721
714
  box-sizing: border-box;
@@ -815,10 +808,11 @@ l(m, "liveProps", []), l(m, "css", Ue`
815
808
  label[data-cap] {
816
809
  user-select: none;
817
810
  }
818
- `), l(m, "hostName", null);
819
- let h = m;
811
+ `), l(h, "hostName", null), /** Optional host-level data surface marker for parent composition. */
812
+ l(h, "dataSurface", null);
813
+ let m = h;
820
814
  function R(e) {
821
- return Array.isArray(e) ? A(j, null, e) : e == null || typeof e == "boolean" ? A(j) : e;
815
+ return Array.isArray(e) ? A(P, null, e) : e == null || typeof e == "boolean" ? A(P) : e;
822
816
  }
823
817
  function ae(e) {
824
818
  const t = [], n = (r) => {
@@ -828,7 +822,7 @@ function ae(e) {
828
822
  };
829
823
  return n(e), t;
830
824
  }
831
- function L(e, t) {
825
+ function O(e, t) {
832
826
  if (typeof e == "string" || typeof e == "number")
833
827
  return {
834
828
  kind: "text",
@@ -837,13 +831,13 @@ function L(e, t) {
837
831
  node: document.createTextNode(String(e)),
838
832
  owner: t
839
833
  };
840
- if (_(e)) {
834
+ if (k(e)) {
841
835
  const s = document.createComment("cap-emitter-start"), o = document.createComment("cap-emitter-end"), a = e.get();
842
836
  if (Object.is(a, e))
843
837
  throw new TypeError("A Capillary UI emitter child cannot render itself");
844
838
  const c = document.createDocumentFragment();
845
839
  c.append(s, o);
846
- const u = L(R(a), t);
840
+ const u = O(R(a), t);
847
841
  V(c, u, o);
848
842
  const p = {
849
843
  kind: "emitter",
@@ -862,7 +856,7 @@ function L(e, t) {
862
856
  p.child = F(p.child, R(b), t);
863
857
  }, { emitCurrent: !1 }), p;
864
858
  }
865
- if (e instanceof h)
859
+ if (e instanceof m)
866
860
  return e._setRuntime(t._runtime), e._setRouteContext(t._routeContextForChildren()), e._setParentComponent(t), e.mount(), t.registerChild(e), {
867
861
  kind: "component",
868
862
  key: de(e.props),
@@ -874,9 +868,9 @@ function L(e, t) {
874
868
  owner: t
875
869
  };
876
870
  if (!y(e))
877
- throw new TypeError(`Invalid Capillary UI child: ${Z(e)}`);
871
+ throw new TypeError(`Invalid Capillary UI child: ${G(e)}`);
878
872
  const { type: n, key: r = null, props: i } = e;
879
- if (n === j) {
873
+ if (n === P) {
880
874
  const s = document.createComment("cap-fragment-start"), o = document.createComment("cap-fragment-end"), a = {
881
875
  kind: "fragment",
882
876
  key: r,
@@ -914,7 +908,7 @@ function L(e, t) {
914
908
  if (me(n)) {
915
909
  const s = i;
916
910
  ue(n, s);
917
- const o = G(s), a = new n(o);
911
+ const o = Y(s), a = new n(o);
918
912
  a._setRuntime(t._runtime), a._setRouteContext(t._routeContextForChildren()), a._setParentComponent(t);
919
913
  const c = {
920
914
  kind: "component",
@@ -929,28 +923,28 @@ function L(e, t) {
929
923
  return ce(c, s), a.mount(), t.registerChild(a), c;
930
924
  }
931
925
  if (typeof n == "function") {
932
- const s = n, o = i, a = G(o), c = R(s(a)), u = {
926
+ const s = n, o = i, a = Y(o), c = R(s(a)), u = {
933
927
  kind: "function",
934
928
  key: r,
935
929
  type: s,
936
930
  props: a,
937
931
  sourceProps: o,
938
932
  liveProps: /* @__PURE__ */ new Map(),
939
- child: L(c, t),
933
+ child: O(c, t),
940
934
  owner: t
941
935
  };
942
936
  return qe(u), u;
943
937
  }
944
- throw new TypeError(`Unsupported vnode type: ${Z(n)}`);
938
+ throw new TypeError(`Unsupported vnode type: ${G(n)}`);
945
939
  }
946
940
  function F(e, t, n) {
947
- if (e == null) return L(t, n);
941
+ if (e == null) return O(t, n);
948
942
  if (he(e, t)) return le(e, t, n);
949
- const r = L(t, n), i = pe(e), s = (i == null ? void 0 : i.parentNode) ?? null;
943
+ const r = O(t, n), i = pe(e), s = (i == null ? void 0 : i.parentNode) ?? null;
950
944
  return s && V(s, r, i), g(e, !0), r;
951
945
  }
952
946
  function le(e, t, n) {
953
- 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" ? (!_(t) || e.source !== t, e) : e.kind === "component" ? (t instanceof h || y(t) && Fe(e, t.props), e) : y(t) ? e.kind === "function" ? (Be(e, t.props), e) : e.kind === "fragment" ? (e.children = z(
947
+ 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) && Fe(e, t.props), e) : y(t) ? e.kind === "function" ? (Be(e, t.props), e) : e.kind === "fragment" ? (e.children = z(
954
948
  e.start.parentNode,
955
949
  e.children,
956
950
  t.props.children,
@@ -964,10 +958,10 @@ function le(e, t, n) {
964
958
  n
965
959
  ), e) : e;
966
960
  }
967
- function G(e) {
961
+ function Y(e) {
968
962
  return Object.fromEntries(Object.entries(e).map(([t, n]) => [
969
963
  t,
970
- S(n) ? n.emitter.get() : n
964
+ v(n) ? n.emitter.get() : n
971
965
  ]));
972
966
  }
973
967
  function ce(e, t) {
@@ -985,32 +979,32 @@ function ue(e, t) {
985
979
  throw new TypeError(`${e.name || "Component"}.liveProps must be an array`);
986
980
  const r = new Set(n);
987
981
  for (const [i, s] of Object.entries(t))
988
- if (S(s) && !r.has(i))
982
+ if (v(s) && !r.has(i))
989
983
  throw new TypeError(
990
984
  `${e.name || "Component"} prop "${i}" does not support live()`
991
985
  );
992
986
  }
993
987
  function qe(e) {
994
988
  q(e.liveProps, e.sourceProps, (t, n) => {
995
- e.props = { ...e.props, [t]: n }, x(e);
989
+ e.props = { ...e.props, [t]: n }, U(e);
996
990
  }), e.props = B(e.liveProps, e.sourceProps);
997
991
  }
998
992
  function Be(e, t) {
999
993
  e.sourceProps = t, q(e.liveProps, t, (n, r) => {
1000
- e.props = { ...e.props, [n]: r }, x(e);
1001
- }), e.props = B(e.liveProps, t), x(e);
994
+ e.props = { ...e.props, [n]: r }, U(e);
995
+ }), e.props = B(e.liveProps, t), U(e);
1002
996
  }
1003
- function x(e) {
997
+ function U(e) {
1004
998
  const t = R(e.type(e.props));
1005
999
  e.child = F(e.child, t, e.owner);
1006
1000
  }
1007
1001
  function q(e, t, n) {
1008
1002
  for (const [r, i] of e) {
1009
1003
  const s = t[r];
1010
- S(s) && s.emitter === i.source || (i.unsubscribe(), e.delete(r));
1004
+ v(s) && s.emitter === i.source || (i.unsubscribe(), e.delete(r));
1011
1005
  }
1012
1006
  for (const [r, i] of Object.entries(t)) {
1013
- if (!S(i) || e.has(r)) continue;
1007
+ if (!v(i) || e.has(r)) continue;
1014
1008
  const s = {
1015
1009
  source: i.emitter,
1016
1010
  value: i.emitter.get(),
@@ -1027,7 +1021,7 @@ function B(e, t) {
1027
1021
  var i;
1028
1022
  return [
1029
1023
  n,
1030
- S(r) ? ((i = e.get(n)) == null ? void 0 : i.value) ?? r.emitter.get() : r
1024
+ v(r) ? ((i = e.get(n)) == null ? void 0 : i.value) ?? r.emitter.get() : r
1031
1025
  ];
1032
1026
  }));
1033
1027
  }
@@ -1039,25 +1033,25 @@ function z(e, t, n, r, i = null, s = null) {
1039
1033
  const u = /* @__PURE__ */ new Set(), p = /* @__PURE__ */ new Set(), b = [];
1040
1034
  let be = 0;
1041
1035
  for (const f of o) {
1042
- const d = E(f);
1036
+ const d = C(f);
1043
1037
  if (d != null) {
1044
1038
  if (u.has(d)) throw new Error(`Duplicate sibling key: ${String(d)}`);
1045
1039
  u.add(d);
1046
1040
  }
1047
- const O = d == null ? c[be++] : a.get(d);
1048
- O && he(O, f) ? (p.add(O), b.push(le(O, f, r))) : b.push(L(f, r));
1041
+ const L = d == null ? c[be++] : a.get(d);
1042
+ L && he(L, f) ? (p.add(L), b.push(le(L, f, r))) : b.push(O(f, r));
1049
1043
  }
1050
1044
  for (const f of t)
1051
1045
  p.has(f) || g(f, !0);
1052
- let C = s ? s.nextSibling : e.firstChild;
1046
+ let E = s ? s.nextSibling : e.firstChild;
1053
1047
  for (const f of b)
1054
1048
  for (const d of w(f))
1055
- d === C ? C = C.nextSibling : (e.insertBefore(d, C ?? i), C = d.nextSibling);
1049
+ d === E ? E = E.nextSibling : (e.insertBefore(d, E ?? i), E = d.nextSibling);
1056
1050
  return b;
1057
1051
  }
1058
1052
  function fe(e, t) {
1059
1053
  const n = Object.fromEntries(Object.entries(t).filter(
1060
- ([s]) => s !== "children" && T(s) !== W
1054
+ ([s]) => s !== "children" && j(s) !== W
1061
1055
  )), r = e.props, i = /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(n)]);
1062
1056
  for (const s of ["value", "checked"])
1063
1057
  if (Object.hasOwn(n, s) && Object.hasOwn(n, `bind:${s}`))
@@ -1065,18 +1059,18 @@ function fe(e, t) {
1065
1059
  for (const s of i) {
1066
1060
  const o = r[s], a = n[s];
1067
1061
  if (Je(s))
1068
- De(e, s, a);
1062
+ He(e, s, a);
1069
1063
  else if (s === "ref")
1070
1064
  o !== a && Ke(e, a);
1071
- else if (Ze(s))
1072
- He(e, s, a);
1073
- else if (S(a))
1065
+ else if (Ge(s))
1066
+ De(e, s, a);
1067
+ else if (v(a))
1074
1068
  Ve(e, s, a);
1075
1069
  else {
1076
1070
  const c = e.liveProps.get(s);
1077
1071
  c && (c.unsubscribe(), e.liveProps.delete(s));
1078
1072
  const u = (c == null ? void 0 : c.value) ?? o;
1079
- Object.is(u, a) || v(e.node, s, u, a);
1073
+ Object.is(u, a) || S(e.node, s, u, a);
1080
1074
  }
1081
1075
  }
1082
1076
  e.node.setAttribute(W, ""), e.props = { ...n };
@@ -1086,7 +1080,7 @@ function Ve(e, t, n) {
1086
1080
  if ((r == null ? void 0 : r.source) === n.emitter) return;
1087
1081
  r == null || r.unsubscribe();
1088
1082
  const i = n.emitter.get();
1089
- v(e.node, t, (r == null ? void 0 : r.value) ?? e.props[t], i);
1083
+ S(e.node, t, (r == null ? void 0 : r.value) ?? e.props[t], i);
1090
1084
  const s = {
1091
1085
  source: n.emitter,
1092
1086
  value: i,
@@ -1095,19 +1089,19 @@ function Ve(e, t, n) {
1095
1089
  };
1096
1090
  s.unsubscribe = n.emitter.subscribe(({ value: o }) => {
1097
1091
  const a = s.value;
1098
- s.value = o, Object.is(a, o) || v(e.node, t, a, o);
1092
+ s.value = o, Object.is(a, o) || S(e.node, t, a, o);
1099
1093
  }, { emitCurrent: !1 }), e.liveProps.set(t, s);
1100
1094
  }
1101
- function De(e, t, n) {
1095
+ function He(e, t, n) {
1102
1096
  const r = t.slice(5), i = e.nativeBindings.get(t);
1103
1097
  if (n == null) {
1104
- i && (i.unsubscribe(), e.node.removeEventListener(i.eventName, i.listener), e.nativeBindings.delete(t), v(e.node, r, i.value, void 0));
1098
+ i && (i.unsubscribe(), e.node.removeEventListener(i.eventName, i.listener), e.nativeBindings.delete(t), S(e.node, r, i.value, void 0));
1105
1099
  return;
1106
1100
  }
1107
1101
  if (Qe(n, t), (i == null ? void 0 : i.source) === n) return;
1108
1102
  i && (i.unsubscribe(), e.node.removeEventListener(i.eventName, i.listener)), Xe(e.node, r);
1109
1103
  const s = et(e.node, r), o = n.get();
1110
- v(e.node, r, i == null ? void 0 : i.value, o);
1104
+ S(e.node, r, i == null ? void 0 : i.value, o);
1111
1105
  const a = () => {
1112
1106
  n.set(Reflect.get(e.node, r), `${t} changed`);
1113
1107
  }, c = {
@@ -1120,10 +1114,10 @@ function De(e, t, n) {
1120
1114
  };
1121
1115
  c.unsubscribe = n.subscribe(({ value: u }) => {
1122
1116
  const p = c.value;
1123
- c.value = u, Object.is(p, u) || v(e.node, r, p, u);
1117
+ c.value = u, Object.is(p, u) || S(e.node, r, p, u);
1124
1118
  }, { emitCurrent: !1 }), e.node.addEventListener(s, a), e.nativeBindings.set(t, c);
1125
1119
  }
1126
- function He(e, t, n) {
1120
+ function De(e, t, n) {
1127
1121
  const r = t.slice(2).toLowerCase(), i = e.listeners.get(t);
1128
1122
  if (i && i !== n && (e.node.removeEventListener(r, i), e.listeners.delete(t)), n != null && typeof n != "function")
1129
1123
  throw new TypeError(`${t} must be a function or null`);
@@ -1133,17 +1127,17 @@ function He(e, t, n) {
1133
1127
  }
1134
1128
  }
1135
1129
  function Ke(e, t) {
1136
- if (M(e.ref, null), t != null && typeof t != "function" && typeof t != "object")
1130
+ if (x(e.ref, null), t != null && typeof t != "function" && typeof t != "object")
1137
1131
  throw new TypeError("ref must be a function, object, or null");
1138
- e.ref = t, M(e.ref, e.node);
1132
+ e.ref = t, x(e.ref, e.node);
1139
1133
  }
1140
- function v(e, t, n, r) {
1134
+ function S(e, t, n, r) {
1141
1135
  if (t === "class" || t === "className") {
1142
- N(e, "class", r);
1136
+ $(e, "class", r);
1143
1137
  return;
1144
1138
  }
1145
1139
  if (t === "for" || t === "htmlFor") {
1146
- N(e, "for", r);
1140
+ $(e, "for", r);
1147
1141
  return;
1148
1142
  }
1149
1143
  if (t === "dataset") {
@@ -1151,62 +1145,62 @@ function v(e, t, n, r) {
1151
1145
  return;
1152
1146
  }
1153
1147
  if (t === "style") {
1154
- Ge(e, n, r);
1148
+ Ye(e, n, r);
1155
1149
  return;
1156
1150
  }
1157
1151
  if (t === "dangerouslySetInnerHTML")
1158
1152
  throw new Error("dangerouslySetInnerHTML is not supported");
1159
- const i = Ye(t);
1160
- if (xe.has(i)) {
1153
+ const i = Ze(t);
1154
+ if (Ue.has(i)) {
1161
1155
  const s = !!r;
1162
- i in e && Reflect.set(e, i, s), e.toggleAttribute(T(t), s);
1156
+ i in e && Reflect.set(e, i, s), e.toggleAttribute(j(t), s);
1163
1157
  return;
1164
1158
  }
1165
- if (Me.has(i) && i in e) {
1159
+ if (xe.has(i) && i in e) {
1166
1160
  const s = r ?? (i === "value" ? "" : !1);
1167
- Object.is(Reflect.get(e, i), s) || Reflect.set(e, i, s), r == null && e.removeAttribute(T(t));
1161
+ Object.is(Reflect.get(e, i), s) || Reflect.set(e, i, s), r == null && e.removeAttribute(j(t));
1168
1162
  return;
1169
1163
  }
1170
- N(e, T(t), r);
1164
+ $(e, j(t), r);
1171
1165
  }
1172
1166
  function We(e, t, n) {
1173
- const r = k(t, "dataset"), i = k(n, "dataset");
1167
+ const r = _(t, "dataset"), i = _(n, "dataset");
1174
1168
  for (const s of /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(i)])) {
1175
1169
  const o = i[s];
1176
1170
  o == null ? delete e.dataset[s] : e.dataset[s] = String(o);
1177
1171
  }
1178
1172
  }
1179
- function Ge(e, t, n) {
1173
+ function Ye(e, t, n) {
1180
1174
  if (typeof n == "string") {
1181
1175
  e.style.cssText = n;
1182
1176
  return;
1183
1177
  }
1184
- const r = typeof t == "string" ? {} : k(t, "style"), i = k(n, "style");
1178
+ const r = typeof t == "string" ? {} : _(t, "style"), i = _(n, "style");
1185
1179
  typeof t == "string" && (e.style.cssText = "");
1186
1180
  for (const s of /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(i)])) {
1187
1181
  const o = i[s];
1188
1182
  s.startsWith("--") ? o == null ? e.style.removeProperty(s) : e.style.setProperty(s, String(o)) : Reflect.set(e.style, s, o == null ? "" : String(o));
1189
1183
  }
1190
1184
  }
1191
- function k(e, t) {
1185
+ function _(e, t) {
1192
1186
  if (e == null) return {};
1193
1187
  if (typeof e != "object" || Array.isArray(e))
1194
1188
  throw new TypeError(`${t} must be an object or null`);
1195
1189
  return e;
1196
1190
  }
1197
- function N(e, t, n) {
1191
+ function $(e, t, n) {
1198
1192
  n == null || n === !1 ? e.removeAttribute(t) : n === !0 ? e.setAttribute(t, "") : e.setAttribute(t, String(n));
1199
1193
  }
1200
- function Ye(e) {
1194
+ function Ze(e) {
1201
1195
  return e === "readonly" ? "readOnly" : e === "autofocus" ? "autoFocus" : e;
1202
1196
  }
1203
- function T(e) {
1204
- return e === "className" ? "class" : e === "htmlFor" ? "for" : e === "minLength" ? "minlength" : e === "maxLength" ? "maxlength" : e === "autoComplete" ? "autocomplete" : e === "inputMode" ? "inputmode" : /^aria[A-Z]/.test(e) || /^data[A-Z]/.test(e) ? Y(e) : e.replace(/[A-Z]/g, (t) => `-${t.toLowerCase()}`);
1197
+ function j(e) {
1198
+ return e === "className" ? "class" : e === "htmlFor" ? "for" : e === "minLength" ? "minlength" : e === "maxLength" ? "maxlength" : e === "autoComplete" ? "autocomplete" : e === "inputMode" ? "inputmode" : /^aria[A-Z]/.test(e) || /^data[A-Z]/.test(e) ? Z(e) : e.replace(/[A-Z]/g, (t) => `-${t.toLowerCase()}`);
1205
1199
  }
1206
- function Y(e) {
1200
+ function Z(e) {
1207
1201
  return e.replace(/[A-Z]/g, (t) => `-${t.toLowerCase()}`);
1208
1202
  }
1209
- function M(e, t) {
1203
+ function x(e, t) {
1210
1204
  e != null && (typeof e == "function" ? e(t) : e.current = t);
1211
1205
  }
1212
1206
  function g(e, t) {
@@ -1226,7 +1220,7 @@ function g(e, t) {
1226
1220
  return;
1227
1221
  }
1228
1222
  if (e.kind === "element") {
1229
- M(e.ref, null);
1223
+ x(e.ref, null);
1230
1224
  for (const [n, r] of e.listeners)
1231
1225
  e.node.removeEventListener(n.slice(2).toLowerCase(), r);
1232
1226
  e.listeners.clear();
@@ -1265,39 +1259,39 @@ function w(e) {
1265
1259
  function pe(e) {
1266
1260
  return w(e)[0] ?? null;
1267
1261
  }
1268
- function E(e) {
1269
- return e instanceof h ? de(e.props) : y(e) ? e.key : null;
1262
+ function C(e) {
1263
+ return e instanceof m ? de(e.props) : y(e) ? e.key : null;
1270
1264
  }
1271
1265
  function de(e) {
1272
1266
  const t = e.key;
1273
1267
  return typeof t == "string" || typeof t == "number" ? t : null;
1274
1268
  }
1275
1269
  function he(e, t) {
1276
- return e.kind === "text" ? typeof t == "string" || typeof t == "number" : e.kind === "emitter" ? _(t) && e.source === t : e.kind === "component" ? t instanceof h ? e.instance === t : y(t) && me(t.type) && e.type === t.type && e.key === E(t) : e.kind === "function" ? y(t) && e.type === t.type && e.key === E(t) : e.kind === "fragment" ? y(t) && t.type === j && e.key === E(t) : y(t) && typeof t.type == "string" && e.type === t.type && e.key === E(t);
1270
+ return e.kind === "text" ? typeof t == "string" || typeof t == "number" : e.kind === "emitter" ? k(t) && e.source === t : e.kind === "component" ? t instanceof m ? e.instance === t : y(t) && me(t.type) && e.type === t.type && e.key === C(t) : e.kind === "function" ? y(t) && e.type === t.type && e.key === C(t) : e.kind === "fragment" ? y(t) && t.type === P && e.key === C(t) : y(t) && typeof t.type == "string" && e.type === t.type && e.key === C(t);
1277
1271
  }
1278
1272
  function y(e) {
1279
1273
  return e != null && typeof e == "object" && Object.hasOwn(e, "type");
1280
1274
  }
1281
1275
  function me(e) {
1282
- return typeof e == "function" && (e === h || e.prototype instanceof h);
1276
+ return typeof e == "function" && (e === m || e.prototype instanceof m);
1283
1277
  }
1284
- function Ze(e) {
1278
+ function Ge(e) {
1285
1279
  return /^on[A-Z]/.test(e);
1286
1280
  }
1287
1281
  function Je(e) {
1288
1282
  return e === "bind:value" || e === "bind:checked";
1289
1283
  }
1290
- function S(e) {
1284
+ function v(e) {
1291
1285
  return e != null && typeof e == "object" && oe.has(e);
1292
1286
  }
1293
- function _(e) {
1287
+ function k(e) {
1294
1288
  return (typeof e != "object" || e == null) && typeof e != "function" ? !1 : typeof Reflect.get(e, "get") == "function" && typeof Reflect.get(e, "getFetchState") == "function" && typeof Reflect.get(e, "getError") == "function" && typeof Reflect.get(e, "subscribe") == "function";
1295
1289
  }
1296
- function D(e, t) {
1297
- if (!_(e)) throw new TypeError(`${t} requires a readable emitter`);
1290
+ function H(e, t) {
1291
+ if (!k(e)) throw new TypeError(`${t} requires a readable emitter`);
1298
1292
  }
1299
1293
  function Qe(e, t) {
1300
- if (D(e, t), typeof Reflect.get(e, "set") != "function")
1294
+ if (H(e, t), typeof Reflect.get(e, "set") != "function")
1301
1295
  throw new TypeError(`${t} requires a writable emitter`);
1302
1296
  }
1303
1297
  function Xe(e, t) {
@@ -1311,7 +1305,7 @@ function tt(e) {
1311
1305
  if (e == null || typeof e != "object" && typeof e != "function" || typeof Reflect.get(e, "insertBefore") != "function")
1312
1306
  throw new TypeError("Component parent must be a DOM ParentNode");
1313
1307
  }
1314
- function Z(e) {
1308
+ function G(e) {
1315
1309
  try {
1316
1310
  return String(e);
1317
1311
  } catch {
@@ -1321,14 +1315,14 @@ function Z(e) {
1321
1315
  function nt(e) {
1322
1316
  const t = [];
1323
1317
  let n = e;
1324
- for (; n != null && typeof n == "function" && (t.unshift(n), n !== h); )
1318
+ for (; n != null && typeof n == "function" && (t.unshift(n), n !== m); )
1325
1319
  n = Object.getPrototypeOf(n);
1326
1320
  return t;
1327
1321
  }
1328
1322
  function rt(...e) {
1329
1323
  return [...new Set(e.flatMap((t) => typeof t == "string" ? t.split(/\s+/) : []).filter(Boolean))].join(" ");
1330
1324
  }
1331
- function $(e) {
1325
+ function N(e) {
1332
1326
  if (e.island === !0) return !0;
1333
1327
  const t = e.className ?? e.class;
1334
1328
  return typeof t == "string" && t.split(/\s+/).includes("island");
@@ -1339,21 +1333,21 @@ function ye(e, t, n) {
1339
1333
  }
1340
1334
  const ct = ye, ut = ye;
1341
1335
  function ft(e) {
1342
- if (!(e instanceof h))
1336
+ if (!(e instanceof m))
1343
1337
  throw new TypeError("createPrebuiltElement requires a Component instance");
1344
1338
  return e;
1345
1339
  }
1346
1340
  export {
1347
- h as C,
1348
- j as F,
1341
+ m as C,
1342
+ P as F,
1349
1343
  re as S,
1350
1344
  ct as a,
1351
- U as b,
1352
- Ue as c,
1345
+ M as b,
1346
+ Me as c,
1353
1347
  J as d,
1354
1348
  at as e,
1355
- Te as f,
1356
- Se as g,
1349
+ je as f,
1350
+ ve as g,
1357
1351
  A as h,
1358
1352
  y as i,
1359
1353
  ye as j,
@@ -1363,6 +1357,6 @@ export {
1363
1357
  lt as n,
1364
1358
  ft as o,
1365
1359
  ot as p,
1366
- Ce as s
1360
+ Ee as s
1367
1361
  };
1368
- //# sourceMappingURL=jsx-dev-runtime-BAF7C1E1.js.map
1362
+ //# sourceMappingURL=jsx-dev-runtime-D3UnwrKT.js.map