@sylwellsoftware/fray 0.3.0 → 0.5.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.
package/dist/index.js CHANGED
@@ -1,15 +1,15 @@
1
1
  var Ye = Object.defineProperty;
2
2
  var _e = (t, r, e) => r in t ? Ye(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
3
3
  var s = (t, r, e) => _e(t, typeof r != "symbol" ? r + "" : r, e);
4
- import { C as g, j as u, c as v, a as w, i as ie } from "./jsx-dev-runtime-DukiDpV9.js";
5
- import { F as pr, b as mr, S as br, d as yr, e as gr, f as wr, h as Er, g as vr, l as Sr, s as kr } from "./jsx-dev-runtime-DukiDpV9.js";
4
+ import { C as g, j as u, c as v, a as w, i as ie } from "./jsx-dev-runtime-pzseD2Sz.js";
5
+ import { F as pr, b as mr, S as br, d as yr, e as gr, f as wr, g as Er, h as vr, k as Sr, l as kr, m as Ir, n as xr, p as Tr, s as Rr } from "./jsx-dev-runtime-pzseD2Sz.js";
6
6
  import { Emitter as I, DerivedEmitter as le, FetchState as k, QueryArg as ke, LiveQuery as Xe, RestQueryHandler as Ze } from "@sylwellsoftware/glue";
7
7
  class ze extends g {
8
8
  render() {
9
9
  return this.props.children ?? [];
10
10
  }
11
11
  }
12
- const y = {
12
+ const b = {
13
13
  /** Deny mode: Excludes items that match the filter. */
14
14
  Deny: "deny",
15
15
  /** Require mode: Includes only items that match the filter. */
@@ -20,7 +20,7 @@ const y = {
20
20
  Neutral: "neutral"
21
21
  };
22
22
  function de(t) {
23
- return Object.values(y).some((r) => r === t);
23
+ return Object.values(b).some((r) => r === t);
24
24
  }
25
25
  let et = 1;
26
26
  function j(t, r) {
@@ -593,11 +593,11 @@ function Pe(t, r, e) {
593
593
  if (i == null) continue;
594
594
  const n = a.options.flatMap((d) => {
595
595
  const h = i[d.key];
596
- return h == null || h === y.Neutral ? [] : [{ option: d, mode: h }];
596
+ return h == null || h === b.Neutral ? [] : [{ option: d, mode: h }];
597
597
  });
598
- if (n.some(({ option: d, mode: h }) => h === y.Deny && d.matches(t)) || n.filter(({ mode: d }) => d === y.Require).some(({ option: d }) => !d.matches(t)))
598
+ if (n.some(({ option: d, mode: h }) => h === b.Deny && d.matches(t)) || n.filter(({ mode: d }) => d === b.Require).some(({ option: d }) => !d.matches(t)))
599
599
  return !1;
600
- const l = n.filter(({ mode: d }) => d === y.Prefer);
600
+ const l = n.filter(({ mode: d }) => d === b.Prefer);
601
601
  if (l.length > 0 && !l.some(({ option: d }) => d.matches(t)))
602
602
  return !1;
603
603
  }
@@ -969,7 +969,7 @@ class G extends g {
969
969
  "aria-busy": n ? "true" : null,
970
970
  "aria-multiselectable": this.props.multiSelect ? "true" : null,
971
971
  children: e.map((d, h) => {
972
- const f = this.getItemKey(d, h), p = o.has(f), m = this.props.renderItem ? this.props.renderItem(d, h) : ut(d);
972
+ const f = this.getItemKey(d, h), m = o.has(f), y = this.props.renderItem ? this.props.renderItem(d, h) : ut(d);
973
973
  return /* @__PURE__ */ u(
974
974
  "div",
975
975
  {
@@ -977,9 +977,9 @@ class G extends g {
977
977
  "data-part": "row",
978
978
  "data-fray-selectable-row": "",
979
979
  "data-index": h,
980
- "aria-selected": String(p),
980
+ "aria-selected": String(m),
981
981
  tabIndex: h === 0 ? 0 : -1,
982
- children: m
982
+ children: y
983
983
  },
984
984
  String(f)
985
985
  );
@@ -1117,14 +1117,14 @@ class D extends g {
1117
1117
  required: i = !1,
1118
1118
  name: n,
1119
1119
  value: o
1120
- } = this.props, l = this.valueEmitter.get(), [d] = this.symbols.find(([, m]) => Object.is(m, l)) ?? ["?", l], h = rt(l), f = l === y.Prefer || l === y.Require, p = this.Host;
1120
+ } = this.props, l = this.valueEmitter.get(), d = this.symbols.findIndex(([, p]) => Object.is(p, l)), [h] = this.symbols[d] ?? ["?", l], f = rt(l), m = l === b.Prefer || l === b.Require || this.symbols.length === 2 && d === 1, y = this.Host;
1121
1121
  return /* @__PURE__ */ u(
1122
- p,
1122
+ y,
1123
1123
  {
1124
1124
  className: E(this.props) || null,
1125
1125
  "data-disabled": a ? "" : null,
1126
1126
  "data-required": i ? "" : null,
1127
- "data-state": h,
1127
+ "data-state": f,
1128
1128
  children: /* @__PURE__ */ w(
1129
1129
  "button",
1130
1130
  {
@@ -1134,15 +1134,15 @@ class D extends g {
1134
1134
  name: n,
1135
1135
  value: o == null ? void 0 : String(o),
1136
1136
  "data-part": "control",
1137
- "aria-checked": f ? "true" : "false",
1137
+ "aria-checked": m ? "true" : "false",
1138
1138
  "aria-required": i ? "true" : null,
1139
- "aria-label": `${e}: ${h}`,
1140
- onClick: (m) => this.cycleState(1, m),
1141
- onKeyDown: (m) => {
1142
- m.key === "ArrowRight" || m.key === "ArrowDown" ? (m.preventDefault(), this.cycleState(1, m)) : (m.key === "ArrowLeft" || m.key === "ArrowUp") && (m.preventDefault(), this.cycleState(-1, m));
1139
+ "aria-label": `${e}: ${f}`,
1140
+ onClick: (p) => this.cycleState(1, p),
1141
+ onKeyDown: (p) => {
1142
+ p.key === "ArrowRight" || p.key === "ArrowDown" ? (p.preventDefault(), this.cycleState(1, p)) : (p.key === "ArrowLeft" || p.key === "ArrowUp") && (p.preventDefault(), this.cycleState(-1, p));
1143
1143
  },
1144
1144
  children: [
1145
- /* @__PURE__ */ u("span", { "data-part": "symbol", "aria-hidden": "true", children: d }),
1145
+ /* @__PURE__ */ u("span", { "data-part": "symbol", "aria-hidden": "true", children: h }),
1146
1146
  /* @__PURE__ */ u("span", { "data-part": "label", children: e })
1147
1147
  ]
1148
1148
  }
@@ -1152,9 +1152,9 @@ class D extends g {
1152
1152
  }
1153
1153
  }
1154
1154
  s(D, "symbols", [
1155
- ["☐", y.Neutral],
1156
- ["✓", y.Prefer]
1157
- ]), s(D, "defaultSemanticState", y.Neutral), s(D, "hostName", "checkbox"), s(D, "standaloneHostName", "check-box"), s(D, "baseStyles", [
1155
+ ["☐", b.Neutral],
1156
+ ["✓", b.Prefer]
1157
+ ]), s(D, "defaultSemanticState", b.Neutral), s(D, "hostName", "checkbox"), s(D, "standaloneHostName", "check-box"), s(D, "baseStyles", [
1158
1158
  ["&", ["inputline"]],
1159
1159
  ['& > [data-part="control"]', ["input", "inputline"]],
1160
1160
  ["&[data-disabled]", ["disabled"]]
@@ -1206,13 +1206,13 @@ class V extends g {
1206
1206
  this.optionsEmitter && this.watch(this.optionsEmitter);
1207
1207
  }
1208
1208
  render() {
1209
- var f, p, m;
1209
+ var f, m, y;
1210
1210
  const e = ((f = this.optionsEmitter) == null ? void 0 : f.get()) ?? (Array.isArray(this.props.options) ? this.props.options : []);
1211
1211
  if (!Array.isArray(e))
1212
1212
  throw new TypeError("FilterPanel options must be an array or emitter of arrays");
1213
- const a = ((p = this.optionsEmitter) == null ? void 0 : p.getFetchState()) ?? k.Ready, i = (m = this.optionsEmitter) == null ? void 0 : m.getError(), n = Ne(this.props.filters), o = this.props.filterModes ?? D.symbols, l = this.props.defaultSemanticState ?? y.Neutral, d = new Set(e.map(pe));
1213
+ const a = ((m = this.optionsEmitter) == null ? void 0 : m.getFetchState()) ?? k.Ready, i = (y = this.optionsEmitter) == null ? void 0 : y.getError(), n = Ne(this.props.filters), o = this.props.filterModes ?? D.symbols, l = this.props.defaultSemanticState ?? b.Neutral, d = new Set(e.map(pe));
1214
1214
  this.staleOptionValues = new Set(
1215
- [...this.optionStateEmitters.keys()].filter((b) => !d.has(b))
1215
+ [...this.optionStateEmitters.keys()].filter((p) => !d.has(p))
1216
1216
  );
1217
1217
  const h = this.Host;
1218
1218
  return a === k.Error ? /* @__PURE__ */ u(
@@ -1237,8 +1237,8 @@ class V extends g {
1237
1237
  className: E(this.props) || null,
1238
1238
  role: "group",
1239
1239
  "aria-label": this.props.label ?? "Filter options",
1240
- children: e.length === 0 ? /* @__PURE__ */ u("span", { children: "No filter options" }) : e.map((b) => {
1241
- const S = pe(b), x = bt(b), O = n.get(S) ?? l, $ = this.optionEmitter(S, O);
1240
+ children: e.length === 0 ? /* @__PURE__ */ u("span", { children: "No filter options" }) : e.map((p) => {
1241
+ const S = pe(p), x = bt(p), O = n.get(S) ?? l, $ = this.optionEmitter(S, O);
1242
1242
  return /* @__PURE__ */ u(
1243
1243
  mt,
1244
1244
  {
@@ -1249,7 +1249,7 @@ class V extends g {
1249
1249
  var T, B;
1250
1250
  A == null || A.stopPropagation();
1251
1251
  const F = Ne(this.props.filters);
1252
- K === y.Neutral ? F.delete(S) : F.set(S, K), (B = (T = this.props).onChange) == null || B.call(T, F, A);
1252
+ K === b.Neutral ? F.delete(S) : F.set(S, K), (B = (T = this.props).onChange) == null || B.call(T, F, A);
1253
1253
  }
1254
1254
  },
1255
1255
  yt(S)
@@ -1482,10 +1482,10 @@ class me extends g {
1482
1482
  }
1483
1483
  s(me, "dependencies", [W]);
1484
1484
  const St = {
1485
- [y.Neutral]: "☐",
1486
- [y.Prefer]: "",
1487
- [y.Require]: "_",
1488
- [y.Deny]: "!"
1485
+ [b.Neutral]: "☐",
1486
+ [b.Prefer]: "",
1487
+ [b.Require]: "_",
1488
+ [b.Deny]: "!"
1489
1489
  };
1490
1490
  function kt(t, { sort: r = null, filters: e = {} } = {}) {
1491
1491
  Nt(t), r != null && (Ge(r), t.searchParams.set("sort", `${r.field}:${r.direction}`));
@@ -1511,10 +1511,10 @@ function It(t, r, e) {
1511
1511
  function xt(t, r) {
1512
1512
  for (const [e, a] of Object.entries(r)) {
1513
1513
  const i = be(t, e);
1514
- if (a.filter(([, d]) => d === y.Deny).some(([d]) => Object.is(d, i))) return !1;
1515
- const o = a.filter(([, d]) => d === y.Require);
1514
+ if (a.filter(([, d]) => d === b.Deny).some(([d]) => Object.is(d, i))) return !1;
1515
+ const o = a.filter(([, d]) => d === b.Require);
1516
1516
  if (o.length > 0 && !o.some(([d]) => Object.is(d, i))) return !1;
1517
- const l = a.filter(([, d]) => d === y.Prefer);
1517
+ const l = a.filter(([, d]) => d === b.Prefer);
1518
1518
  if (l.length > 0 && !l.some(([d]) => Object.is(d, i))) return !1;
1519
1519
  }
1520
1520
  return !0;
@@ -1680,11 +1680,11 @@ class X extends g {
1680
1680
  }), this.dataSource = this.ownedDataSource), this.query = this.dataSource.query, this.watch(this.query, this.selectedItemsEmitter);
1681
1681
  }
1682
1682
  render() {
1683
- var d, h, f, p;
1683
+ var d, h, f, m;
1684
1684
  const e = ((d = this.query) == null ? void 0 : d.get()) ?? [];
1685
1685
  if (!Array.isArray(e)) throw new TypeError("DataTable query value must be an array");
1686
1686
  const a = ((h = this.query) == null ? void 0 : h.getFetchState()) ?? k.Initial, i = (f = this.query) == null ? void 0 : f.getError(), n = a === k.Initial || a === k.Loading, o = new Set(
1687
- this.selectedItemsEmitter.get().map((m, b) => this.rowKey(m, b))
1687
+ this.selectedItemsEmitter.get().map((y, p) => this.rowKey(y, p))
1688
1688
  ), l = this.Host;
1689
1689
  return /* @__PURE__ */ w(
1690
1690
  l,
@@ -1696,13 +1696,13 @@ class X extends g {
1696
1696
  n ? /* @__PURE__ */ u("p", { role: "status", "data-part": "status", children: "Loading rows…" }) : null,
1697
1697
  a === k.Error ? /* @__PURE__ */ w("div", { "data-part": "error", role: "alert", children: [
1698
1698
  /* @__PURE__ */ u("span", { children: Ht(i, "Unable to load rows") }),
1699
- typeof ((p = this.dataSource) == null ? void 0 : p.retry) == "function" ? /* @__PURE__ */ u(
1699
+ typeof ((m = this.dataSource) == null ? void 0 : m.retry) == "function" ? /* @__PURE__ */ u(
1700
1700
  "button",
1701
1701
  {
1702
1702
  type: "button",
1703
1703
  onClick: () => {
1704
- var m, b;
1705
- return (b = (m = this.dataSource) == null ? void 0 : m.retry) == null ? void 0 : b.call(m, "table retry");
1704
+ var y, p;
1705
+ return (p = (y = this.dataSource) == null ? void 0 : y.retry) == null ? void 0 : p.call(y, "table retry");
1706
1706
  },
1707
1707
  children: "Retry"
1708
1708
  }
@@ -1722,7 +1722,7 @@ class X extends g {
1722
1722
  },
1723
1723
  "header"
1724
1724
  ),
1725
- /* @__PURE__ */ u("tbody", { children: e.length > 0 ? e.map((m, b) => this.renderRow(m, b, o)) : n ? this.renderPlaceholders() : a === k.Error ? null : /* @__PURE__ */ u("tr", { children: /* @__PURE__ */ u("td", { colSpan: this.columns.length, children: this.props.emptyMessage ?? "No rows" }) }, "empty") })
1725
+ /* @__PURE__ */ u("tbody", { children: e.length > 0 ? e.map((y, p) => this.renderRow(y, p, o)) : n ? this.renderPlaceholders() : a === k.Error ? null : /* @__PURE__ */ u("tr", { children: /* @__PURE__ */ u("td", { colSpan: this.columns.length, children: this.props.emptyMessage ?? "No rows" }) }, "empty") })
1726
1726
  ] })
1727
1727
  ]
1728
1728
  }
@@ -1927,8 +1927,8 @@ function Mt(t, r, e) {
1927
1927
  if (!Object.is(f.id, l.id))
1928
1928
  throw new Error("Tree node update cannot change the stable id");
1929
1929
  if (Object.is(f, l)) return n;
1930
- const p = [...n];
1931
- return p[o] = f, p;
1930
+ const m = [...n];
1931
+ return m[o] = f, m;
1932
1932
  }
1933
1933
  const d = l.children ?? [], h = a(d);
1934
1934
  if (!Object.is(h, d)) {
@@ -1988,21 +1988,21 @@ class Z extends g {
1988
1988
  const l = this.Host;
1989
1989
  return /* @__PURE__ */ u(l, { className: E(this.props) || null, children: i.length === 0 ? /* @__PURE__ */ u("p", { role: "status", "data-part": "empty", children: "No tree items" }) : /* @__PURE__ */ u("div", { role: "tree", "aria-label": this.props.label, "data-part": "tree", children: i.map((d, h) => {
1990
1990
  var K, A, F;
1991
- const { node: f, depth: p, position: m, setSize: b } = d, S = (((K = f.children) == null ? void 0 : K.length) ?? 0) > 0, x = S && a.has(f.id), O = Object.is(f.id, n), $ = ((F = (A = this.props).renderItem) == null ? void 0 : F.call(A, f, p)) ?? f.label;
1991
+ const { node: f, depth: m, position: y, setSize: p } = d, S = (((K = f.children) == null ? void 0 : K.length) ?? 0) > 0, x = S && a.has(f.id), O = Object.is(f.id, n), $ = ((F = (A = this.props).renderItem) == null ? void 0 : F.call(A, f, m)) ?? f.label;
1992
1992
  return /* @__PURE__ */ w(
1993
1993
  "div",
1994
1994
  {
1995
1995
  role: "treeitem",
1996
1996
  "data-part": "item",
1997
1997
  "data-index": h,
1998
- "data-depth": p,
1999
- "aria-level": p + 1,
2000
- "aria-posinset": m,
2001
- "aria-setsize": b,
1998
+ "data-depth": m,
1999
+ "aria-level": m + 1,
2000
+ "aria-posinset": y,
2001
+ "aria-setsize": p,
2002
2002
  "aria-expanded": S ? String(x) : null,
2003
2003
  "aria-selected": String(O),
2004
2004
  tabIndex: Object.is(f.id, o == null ? void 0 : o.node.id) ? 0 : -1,
2005
- style: { "--tree-depth": p },
2005
+ style: { "--tree-depth": m },
2006
2006
  onClick: (T) => {
2007
2007
  if (this.focusedKey = f.id, Ut(T.target) && S) {
2008
2008
  this.toggleExpanded(f.id), this.focusRow(f.id);
@@ -2062,11 +2062,11 @@ class Z extends g {
2062
2062
  e.preventDefault();
2063
2063
  const f = n.node.children ?? [];
2064
2064
  if (f.length === 0) return;
2065
- this.expandedKeysEmitter.get().some((m) => Object.is(m, n.node.id)) ? this.focusRow(f[0].id) : this.toggleExpanded(n.node.id);
2065
+ this.expandedKeysEmitter.get().some((y) => Object.is(y, n.node.id)) ? this.focusRow(f[0].id) : this.toggleExpanded(n.node.id);
2066
2066
  return;
2067
2067
  }
2068
2068
  if (e.key === "ArrowLeft") {
2069
- e.preventDefault(), this.expandedKeysEmitter.get().some((p) => Object.is(p, n.node.id)) ? this.toggleExpanded(n.node.id) : n.parentId != null && this.focusRow(n.parentId);
2069
+ e.preventDefault(), this.expandedKeysEmitter.get().some((m) => Object.is(m, n.node.id)) ? this.toggleExpanded(n.node.id) : n.parentId != null && this.focusRow(n.parentId);
2070
2070
  return;
2071
2071
  }
2072
2072
  if (e.key === "Enter" || e.key === " ") {
@@ -2224,9 +2224,9 @@ class se extends g {
2224
2224
  id: d,
2225
2225
  name: h,
2226
2226
  value: f,
2227
- title: p,
2228
- ariaLabel: m,
2229
- onClick: b
2227
+ title: m,
2228
+ ariaLabel: y,
2229
+ onClick: p
2230
2230
  } = this.props, x = (Array.isArray(r) ? r.length > 0 : r != null && typeof r != "boolean") ? r : e ?? "", O = o ? l ?? x : x, $ = i || o;
2231
2231
  return /* @__PURE__ */ u(
2232
2232
  "button",
@@ -2234,16 +2234,16 @@ class se extends g {
2234
2234
  id: d,
2235
2235
  name: h,
2236
2236
  value: f == null ? void 0 : String(f),
2237
- title: p,
2237
+ title: m,
2238
2238
  type: a,
2239
2239
  disabled: $,
2240
2240
  className: E(this.props) || void 0,
2241
2241
  "data-fray-component": "button",
2242
- "aria-label": m,
2242
+ "aria-label": y,
2243
2243
  "aria-pressed": n == null ? null : String(!!n),
2244
2244
  "aria-busy": o ? "true" : null,
2245
2245
  onClick: (K) => {
2246
- $ || C(b, K);
2246
+ $ || C(p, K);
2247
2247
  },
2248
2248
  children: O
2249
2249
  }
@@ -2438,11 +2438,11 @@ const z = class z extends D {
2438
2438
  }
2439
2439
  };
2440
2440
  s(z, "hostName", "quad-checkbox"), s(z, "standaloneHostName", "quad-checkbox"), s(z, "symbols", [
2441
- ["✖", y.Deny],
2442
- ["☐", y.Neutral],
2443
- ["✓", y.Prefer],
2444
- ["+", y.Require]
2445
- ]), s(z, "defaultSemanticState", y.Neutral);
2441
+ ["✖", b.Deny],
2442
+ ["☐", b.Neutral],
2443
+ ["✓", b.Prefer],
2444
+ ["+", b.Require]
2445
+ ]), s(z, "defaultSemanticState", b.Neutral);
2446
2446
  let $e = z;
2447
2447
  const q = class q extends D {
2448
2448
  constructor(r = {}) {
@@ -2450,10 +2450,10 @@ const q = class q extends D {
2450
2450
  }
2451
2451
  };
2452
2452
  s(q, "hostName", "tri-checkbox"), s(q, "standaloneHostName", "tri-checkbox"), s(q, "symbols", [
2453
- ["✖", y.Deny],
2454
- ["☐", y.Neutral],
2455
- ["✓", y.Prefer]
2456
- ]), s(q, "defaultSemanticState", y.Neutral);
2453
+ ["✖", b.Deny],
2454
+ ["☐", b.Neutral],
2455
+ ["✓", b.Prefer]
2456
+ ]), s(q, "defaultSemanticState", b.Neutral);
2457
2457
  let Ce = q;
2458
2458
  class ee extends g {
2459
2459
  constructor(e = {}) {
@@ -2488,9 +2488,9 @@ class ee extends g {
2488
2488
  onChange: h
2489
2489
  } = this.props, f = this.optionsEmitter.get() ?? [];
2490
2490
  fe(f);
2491
- const p = this.valueEmitter.get(), m = this.Host;
2491
+ const m = this.valueEmitter.get(), y = this.Host;
2492
2492
  return /* @__PURE__ */ w(
2493
- m,
2493
+ y,
2494
2494
  {
2495
2495
  className: E(this.props) || null,
2496
2496
  "data-disabled": i ? "" : null,
@@ -2503,30 +2503,30 @@ class ee extends g {
2503
2503
  {
2504
2504
  id: this.inputId,
2505
2505
  name: a,
2506
- value: p == null ? "" : String(p),
2506
+ value: m == null ? "" : String(m),
2507
2507
  disabled: i,
2508
2508
  required: n,
2509
2509
  "aria-label": e == null ? d : null,
2510
2510
  "aria-invalid": o == null ? null : "true",
2511
2511
  "aria-describedby": o == null ? null : this.errorId,
2512
- onChange: (b) => {
2513
- const S = Qt(b, "dropdown change"), x = f.find(({ value: $ }) => String($) === S), O = (x == null ? void 0 : x.value) ?? S;
2514
- this.valueEmitter.set(O, "dropdown selection"), C(h, O, b);
2512
+ onChange: (p) => {
2513
+ const S = Qt(p, "dropdown change"), x = f.find(({ value: $ }) => String($) === S), O = (x == null ? void 0 : x.value) ?? S;
2514
+ this.valueEmitter.set(O, "dropdown selection"), C(h, O, p);
2515
2515
  },
2516
2516
  children: [
2517
- p == null || p === "" ? /* @__PURE__ */ u("option", { value: "", disabled: n, selected: !0, children: l }) : null,
2518
- f.map((b) => {
2519
- if (b == null || !Object.hasOwn(b, "value"))
2517
+ m == null || m === "" ? /* @__PURE__ */ u("option", { value: "", disabled: n, selected: !0, children: l }) : null,
2518
+ f.map((p) => {
2519
+ if (p == null || !Object.hasOwn(p, "value"))
2520
2520
  throw new TypeError("Dropdown options require value and label fields");
2521
2521
  return /* @__PURE__ */ u(
2522
2522
  "option",
2523
2523
  {
2524
- value: String(b.value),
2525
- disabled: !!b.disabled,
2526
- selected: Object.is(p, b.value),
2527
- children: b.label ?? String(b.value)
2524
+ value: String(p.value),
2525
+ disabled: !!p.disabled,
2526
+ selected: Object.is(m, p.value),
2527
+ children: p.label ?? String(p.value)
2528
2528
  },
2529
- String(b.value)
2529
+ String(p.value)
2530
2530
  );
2531
2531
  })
2532
2532
  ]
@@ -2588,9 +2588,9 @@ class te extends g {
2588
2588
  readOnly: d = !1,
2589
2589
  error: h = null,
2590
2590
  autoComplete: f,
2591
- inputMode: p,
2592
- minLength: m,
2593
- maxLength: b,
2591
+ inputMode: m,
2592
+ minLength: y,
2593
+ maxLength: p,
2594
2594
  pattern: S,
2595
2595
  ariaLabel: x,
2596
2596
  inputRef: O,
@@ -2618,9 +2618,9 @@ class te extends g {
2618
2618
  required: l,
2619
2619
  readOnly: d,
2620
2620
  autoComplete: f,
2621
- inputMode: p,
2622
- minLength: m,
2623
- maxLength: b,
2621
+ inputMode: m,
2622
+ minLength: y,
2623
+ maxLength: p,
2624
2624
  pattern: S,
2625
2625
  ref: O,
2626
2626
  "aria-label": e == null ? x : null,
@@ -2736,8 +2736,8 @@ class Ae extends g {
2736
2736
  "aria-checked": Object.is(o, d) ? "true" : "false",
2737
2737
  "data-value": String(d),
2738
2738
  tabIndex: f === l ? 0 : -1,
2739
- onClick: (p) => this.selectOption(d, p),
2740
- onKeyDown: (p) => this.handleKeyDown(p, f, e),
2739
+ onClick: (m) => this.selectOption(d, m),
2740
+ onKeyDown: (m) => this.handleKeyDown(m, f, e),
2741
2741
  children: h
2742
2742
  },
2743
2743
  String(d)
@@ -3098,8 +3098,8 @@ class oe extends g {
3098
3098
  disabled: o,
3099
3099
  "aria-label": i == null ? n : null,
3100
3100
  onChange: (h) => {
3101
- const f = Zt(h), p = ae(e, f);
3102
- this.valueEmitter.set(f, `${this.kind} selected`), C(l, f, p, h);
3101
+ const f = Zt(h), m = ae(e, f);
3102
+ this.valueEmitter.set(f, `${this.kind} selected`), C(l, f, m, h);
3103
3103
  },
3104
3104
  children: e.map((h) => /* @__PURE__ */ u(
3105
3105
  "option",
@@ -3194,7 +3194,7 @@ export {
3194
3194
  Te as DescriptionList,
3195
3195
  Oe as Dialog,
3196
3196
  ee as Dropdown,
3197
- y as FilterMode,
3197
+ b as FilterMode,
3198
3198
  V as FilterPanel,
3199
3199
  pr as Fragment,
3200
3200
  mr as FrayRuntime,
@@ -3204,10 +3204,11 @@ export {
3204
3204
  H as Placeholder,
3205
3205
  he as ProgressBar,
3206
3206
  $e as QuadCheckbox,
3207
+ br as ServiceScope,
3207
3208
  xe as Sidebar,
3208
3209
  ge as SingleSelectionHandler,
3209
3210
  ce as SplitView,
3210
- br as StyleRegistry,
3211
+ yr as StyleRegistry,
3211
3212
  ze as Tab,
3212
3213
  L as TabLine,
3213
3214
  J as TabPanel,
@@ -3223,16 +3224,18 @@ export {
3223
3224
  It as applyLocalTableState,
3224
3225
  Ge as assertSort,
3225
3226
  P as assertTreeNodes,
3226
- yr as createFrayRuntime,
3227
+ gr as createFrayRuntime,
3227
3228
  Ot as createHandlerTableDataSource,
3228
3229
  Dt as createLocalTableDataSource,
3229
3230
  or as createQueryTableDataSource,
3230
3231
  $t as createRestTableDataSource,
3231
3232
  ne as createSelectionHandler,
3232
- gr as createStyleRegistry,
3233
+ wr as createServiceScope,
3234
+ Er as createStyleRegistry,
3233
3235
  v as css,
3234
- wr as defaultFrayRuntime,
3236
+ vr as defaultFrayRuntime,
3235
3237
  we as defaultItemKey,
3238
+ Sr as defineService,
3236
3239
  ar as deriveFilterPredicate,
3237
3240
  ir as deriveFilteredItems,
3238
3241
  dr as deriveTreeNode,
@@ -3242,18 +3245,19 @@ export {
3242
3245
  Yt as frayColorOptions,
3243
3246
  Jt as frayThemeOptions,
3244
3247
  ur as frayThemeVariableCatalog,
3245
- Er as h,
3248
+ kr as h,
3246
3249
  de as isFilterMode,
3247
3250
  u as jsx,
3248
- vr as jsxDEV,
3251
+ Ir as jsxDEV,
3249
3252
  w as jsxs,
3250
- Sr as live,
3253
+ xr as live,
3251
3254
  Pe as matchesFilterState,
3252
3255
  sr as parseFilterState,
3256
+ Tr as provideService,
3253
3257
  _t as replaceFrayStylesheet,
3254
3258
  nr as serializeFilterState,
3255
3259
  kt as serializeTableQuery,
3256
- kr as styleRegistry,
3260
+ Rr as styleRegistry,
3257
3261
  qe as tabButtonId,
3258
3262
  Le as tabPanelId,
3259
3263
  Mt as updateTreeNode,