@nonoun/native-ui 0.2.9 → 0.2.10

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 (57) hide show
  1. package/dist/{ui-layout-inspector-element.js → components.js} +2279 -386
  2. package/dist/{register-all2.js → core.js} +78 -35
  3. package/dist/custom-elements.json +2502 -2502
  4. package/dist/inspector/build-inspector.d.ts +4 -4
  5. package/dist/inspector/build-inspector.d.ts.map +1 -1
  6. package/dist/inspector/index.d.ts +8 -8
  7. package/dist/inspector/index.d.ts.map +1 -1
  8. package/dist/inspector/{ds-color-swatch-element.d.ts → native-tokens-color-swatch-element.d.ts} +2 -2
  9. package/dist/inspector/native-tokens-color-swatch-element.d.ts.map +1 -0
  10. package/dist/inspector/native-tokens-color-swatch.d.ts +3 -0
  11. package/dist/inspector/native-tokens-color-swatch.d.ts.map +1 -0
  12. package/dist/inspector/{ds-colors-element.d.ts → native-tokens-colors-element.d.ts} +3 -3
  13. package/dist/inspector/native-tokens-colors-element.d.ts.map +1 -0
  14. package/dist/inspector/native-tokens-colors.d.ts +4 -0
  15. package/dist/inspector/native-tokens-colors.d.ts.map +1 -0
  16. package/dist/inspector/native-tokens-inspector-element.d.ts +15 -0
  17. package/dist/inspector/native-tokens-inspector-element.d.ts.map +1 -0
  18. package/dist/inspector/native-tokens-inspector.d.ts +3 -0
  19. package/dist/inspector/native-tokens-inspector.d.ts.map +1 -0
  20. package/dist/inspector/{ds-themes-element.d.ts → native-tokens-themes-element.d.ts} +3 -3
  21. package/dist/inspector/native-tokens-themes-element.d.ts.map +1 -0
  22. package/dist/inspector/native-tokens-themes.d.ts +4 -0
  23. package/dist/inspector/native-tokens-themes.d.ts.map +1 -0
  24. package/dist/inspector/{ds-variable-element.d.ts → native-tokens-variable-element.d.ts} +3 -3
  25. package/dist/inspector/native-tokens-variable-element.d.ts.map +1 -0
  26. package/dist/inspector/native-tokens-variable.d.ts +4 -0
  27. package/dist/inspector/native-tokens-variable.d.ts.map +1 -0
  28. package/dist/inspector.css +30 -30
  29. package/dist/inspector.d.ts +10 -9
  30. package/dist/inspector.d.ts.map +1 -1
  31. package/dist/inspector.js +102 -103
  32. package/dist/kernel.js +175 -174
  33. package/dist/native-ui.js +4 -49
  34. package/dist/register-all.js +4 -4
  35. package/dist/traits.js +3 -5
  36. package/dist/ui-icon.js +56 -0
  37. package/package.json +1 -1
  38. package/dist/dialog-controller.js +0 -391
  39. package/dist/inspector/ds-color-swatch-element.d.ts.map +0 -1
  40. package/dist/inspector/ds-color-swatch.d.ts +0 -3
  41. package/dist/inspector/ds-color-swatch.d.ts.map +0 -1
  42. package/dist/inspector/ds-colors-element.d.ts.map +0 -1
  43. package/dist/inspector/ds-colors.d.ts +0 -4
  44. package/dist/inspector/ds-colors.d.ts.map +0 -1
  45. package/dist/inspector/ds-inspector-element.d.ts +0 -15
  46. package/dist/inspector/ds-inspector-element.d.ts.map +0 -1
  47. package/dist/inspector/ds-inspector.d.ts +0 -3
  48. package/dist/inspector/ds-inspector.d.ts.map +0 -1
  49. package/dist/inspector/ds-themes-element.d.ts.map +0 -1
  50. package/dist/inspector/ds-themes.d.ts +0 -4
  51. package/dist/inspector/ds-themes.d.ts.map +0 -1
  52. package/dist/inspector/ds-variable-element.d.ts.map +0 -1
  53. package/dist/inspector/ds-variable.d.ts +0 -4
  54. package/dist/inspector/ds-variable.d.ts.map +0 -1
  55. package/dist/list-navigate-controller.js +0 -457
  56. package/dist/ui-icon-element.js +0 -986
  57. package/dist/uid.js +0 -147
@@ -1,19 +1,1295 @@
1
- import { a as e, o as t, r as n, t as r } from "./uid.js";
2
- import { i, n as a, r as o, t as s } from "./dialog-controller.js";
3
- import { a as c, d as l, f as u, h as d, i as f, m as p, n as m, p as h, t as g, u as _ } from "./list-navigate-controller.js";
4
- import { _ as v, d as y, f as b, g as x, h as S, p as C, v as w } from "./ui-icon-element.js";
1
+ var e = null, t = 0, n = /* @__PURE__ */ new Set();
2
+ const r = /* @__PURE__ */ new WeakMap(), i = /* @__PURE__ */ new Set();
3
+ function a() {
4
+ return e;
5
+ }
6
+ function o(t) {
7
+ e = t;
8
+ }
9
+ function s() {
10
+ return t;
11
+ }
12
+ function c() {
13
+ t++;
14
+ }
15
+ function l() {
16
+ t--;
17
+ }
18
+ var u = class {
19
+ _value;
20
+ _subs = /* @__PURE__ */ new Set();
21
+ constructor(e) {
22
+ this._value = e;
23
+ }
24
+ }, d = class e {
25
+ _subs = /* @__PURE__ */ new Set();
26
+ _deps = /* @__PURE__ */ new Set();
27
+ _fn;
28
+ _value = void 0;
29
+ _dirty = !0;
30
+ constructor(e) {
31
+ this._fn = e;
32
+ }
33
+ _notify() {
34
+ if (!this._dirty) {
35
+ this._dirty = !0;
36
+ for (let r of [...this._subs]) r instanceof e ? r._notify() : t > 0 ? n.add(r) : g(r);
37
+ }
38
+ }
39
+ }, f = class {
40
+ _deps = /* @__PURE__ */ new Set();
41
+ _fn;
42
+ _disposed = !1;
43
+ _running = !1;
44
+ constructor(e) {
45
+ this._fn = e;
46
+ }
47
+ };
48
+ function p(t) {
49
+ e !== null && (t._subs.add(e), e._deps.add(t));
50
+ }
51
+ function m(e) {
52
+ for (let t of e._deps) t._subs.delete(e);
53
+ e._deps.clear();
54
+ }
55
+ function h(e) {
56
+ for (let r of [...e._subs]) r instanceof d ? r._notify() : t > 0 ? n.add(r) : g(r);
57
+ }
58
+ function g(t) {
59
+ if (t._disposed || t._running) return;
60
+ m(t);
61
+ let n = e;
62
+ e = t, t._running = !0;
63
+ try {
64
+ t._fn();
65
+ } finally {
66
+ e = n, t._running = !1;
67
+ }
68
+ }
69
+ function ee() {
70
+ let e = 0;
71
+ for (; n.size > 0;) {
72
+ if (++e > 100) throw Error("Reactive flush limit exceeded (100 iterations). Possible infinite loop.");
73
+ let t = [...n];
74
+ n.clear();
75
+ for (let e of t) g(e);
76
+ }
77
+ }
78
+ var te = class {
79
+ [Symbol.toStringTag] = "Signal";
80
+ #e;
81
+ constructor(e) {
82
+ this.#e = e;
83
+ }
84
+ get value() {
85
+ return p(this.#e), this.#e._value;
86
+ }
87
+ set value(e) {
88
+ Object.is(this.#e._value, e) || (this.#e._value = e, h(this.#e));
89
+ }
90
+ peek() {
91
+ return this.#e._value;
92
+ }
93
+ };
94
+ function _(e) {
95
+ let t = new u(e), n = new te(t);
96
+ return r.set(n, t), n;
97
+ }
98
+ var ne = class {
99
+ [Symbol.toStringTag] = "Computed";
100
+ #e;
101
+ constructor(e) {
102
+ this.#e = e;
103
+ }
104
+ get value() {
105
+ return p(this.#e), this.#e._dirty && this.#t(), this.#e._value;
106
+ }
107
+ peek() {
108
+ return this.#e._dirty && this.#t(), this.#e._value;
109
+ }
110
+ #t() {
111
+ let e = this.#e;
112
+ if (i.has(e)) throw Error("Circular computed dependency detected.");
113
+ m(e), i.add(e);
114
+ let t = a();
115
+ o(e);
116
+ try {
117
+ e._value = e._fn();
118
+ } finally {
119
+ o(t), i.delete(e), e._dirty = !1;
120
+ }
121
+ }
122
+ };
123
+ function v(e) {
124
+ let t = new d(e), n = new ne(t);
125
+ return r.set(n, t), n;
126
+ }
127
+ function y(e) {
128
+ let t = new f(e);
129
+ return g(t), () => {
130
+ t._disposed || (t._disposed = !0, m(t));
131
+ };
132
+ }
133
+ function b(e) {
134
+ c();
135
+ try {
136
+ e();
137
+ } finally {
138
+ l(), s() === 0 && ee();
139
+ }
140
+ }
141
+ function x(e) {
142
+ let t = a();
143
+ o(null);
144
+ try {
145
+ return e();
146
+ } finally {
147
+ o(t);
148
+ }
149
+ }
150
+ var S = /* @__PURE__ */ new Map(), C = /* @__PURE__ */ new Set();
151
+ function re(e) {
152
+ if (S.has(e.name)) {
153
+ console.warn(`[native-ui] Trait "${e.name}" is already registered.`);
154
+ return;
155
+ }
156
+ S.set(e.name, e);
157
+ for (let t of C) t(e.name);
158
+ }
159
+ /** Subscribe to trait registration events. Returns unsubscribe function. */
160
+ function w(e) {
161
+ return C.add(e), () => C.delete(e);
162
+ }
163
+ function T(e) {
164
+ return S.get(e);
165
+ }
166
+ function E() {
167
+ return new Set(S.keys());
168
+ }
5
169
  /**
6
- * Single-line text input using contenteditable with form association.
7
- * @attr {string} value - Current text value
8
- * @attr {string} placeholder - Placeholder text shown when empty
9
- * @attr {boolean} disabled - Disables interaction
10
- * @attr {boolean} readonly - Prevents editing while remaining focusable
11
- * @attr {boolean} required - Marks as required for form validation
12
- * @attr {string} name - Form field name
13
- * @fires ui-input - Fired on each keystroke with `{ value }` detail
14
- * @fires ui-change - Fired on blur with `{ value }` detail
170
+ * Parse a namespaced trait attribute like "draggable-axis" into
171
+ * { trait: "draggable", key: "axis" }. Returns null if the attribute
172
+ * doesn't match any registered trait name prefix.
173
+ */
174
+ function D(e) {
175
+ let t = E();
176
+ for (let n of t) if (e.startsWith(n + "-")) return {
177
+ trait: n,
178
+ key: e.slice(n.length + 1)
179
+ };
180
+ return null;
181
+ }
182
+ /**
183
+ * Collect all `{traitName}-*` attributes from an element for a given trait.
184
+ * Returns a plain object mapping option keys to string values.
185
+ *
186
+ * Example: element has `draggable-axis="x"` and `draggable-mode="slot"`
187
+ * → collectTraitOptions(el, 'draggable') returns { axis: 'x', mode: 'slot' }
188
+ */
189
+ function O(e, t) {
190
+ let n = t + "-", r = {};
191
+ for (let t of e.attributes) t.name.startsWith(n) && (r[t.name.slice(n.length)] = t.value);
192
+ return r;
193
+ }
194
+ /** Base custom element class with reactive effect lifecycle, child deferral, and trait protocol. */
195
+ var k = class extends HTMLElement {
196
+ #e = [];
197
+ #t = /* @__PURE__ */ new Map();
198
+ #n = null;
199
+ #r = /* @__PURE__ */ new Set();
200
+ #i = null;
201
+ #a = !1;
202
+ #o = null;
203
+ /** Resolves after setup() and any deferChildren microtask have completed. */
204
+ ready = new Promise((e) => {
205
+ this.#o = e;
206
+ });
207
+ addEffect(e) {
208
+ this.#e.push(y(e));
209
+ }
210
+ connectedCallback() {
211
+ if (this.#a) return;
212
+ this.#a = !0, this.setup();
213
+ let e = this.getAttribute("traits");
214
+ e !== null && this.#s(e), queueMicrotask(() => this.#o?.());
215
+ }
216
+ disconnectedCallback() {
217
+ this.#a = !1, this.#l(), this.#n?.disconnect(), this.#n = null, this.#i?.(), this.#i = null, this.#r.clear(), this.teardown();
218
+ for (let e of this.#e) e();
219
+ this.#e = [];
220
+ }
221
+ setup() {}
222
+ teardown() {}
223
+ deferChildren(e) {
224
+ this.firstChild ? e() : queueMicrotask(() => {
225
+ this.isConnected && e();
226
+ });
227
+ }
228
+ attributeChangedCallback(e, t, n) {}
229
+ /**
230
+ * Get a trait controller instance by name.
231
+ * Returns null if no controller with that name is active.
232
+ */
233
+ getTraitController(e) {
234
+ return this.#t.get(e) ?? null;
235
+ }
236
+ #s(e) {
237
+ this.#c(e), this.#n = new MutationObserver((e) => {
238
+ for (let t of e) if (t.attributeName === "traits") this.#c(this.getAttribute("traits") ?? "");
239
+ else if (t.attributeName) {
240
+ let e = D(t.attributeName);
241
+ if (e) {
242
+ let t = T(e.trait), n = this.#t.get(e.trait);
243
+ t && n && t.update && t.update(n, O(this, e.trait));
244
+ }
245
+ }
246
+ }), this.#n.observe(this, { attributes: !0 });
247
+ }
248
+ #c(e) {
249
+ let t = new Set(e.split(/\s+/).filter(Boolean));
250
+ for (let [e, n] of this.#t) if (!t.has(e)) {
251
+ let t = T(e);
252
+ t && t.destroy(n), this.#t.delete(e);
253
+ }
254
+ this.#r.clear();
255
+ for (let e of t) {
256
+ if (this.#t.has(e)) continue;
257
+ let t = T(e);
258
+ if (!t) {
259
+ this.#r.add(e);
260
+ continue;
261
+ }
262
+ for (let [n] of this.#t) if (T(n)?.conflicts?.includes(e) || t.conflicts?.includes(n)) {
263
+ let t = `[native-ui] Trait conflict: "${e}" and "${n}" are incompatible.`;
264
+ console.warn(t);
265
+ }
266
+ let n = O(this, e), r = t.create(this, n);
267
+ this.#t.set(e, r);
268
+ }
269
+ this.#r.size > 0 && !this.#i ? this.#i = w((e) => {
270
+ this.#r.has(e) && (this.#r.delete(e), this.#c(this.getAttribute("traits") ?? ""), this.#r.size === 0 && (this.#i?.(), this.#i = null));
271
+ }) : this.#r.size === 0 && this.#i && (this.#i(), this.#i = null);
272
+ }
273
+ #l() {
274
+ for (let [e, t] of this.#t) {
275
+ let n = T(e);
276
+ n && n.destroy(t);
277
+ }
278
+ this.#t.clear();
279
+ }
280
+ };
281
+ function A(e = "ui") {
282
+ return `${e}-${crypto.randomUUID().slice(0, 8)}`;
283
+ }
284
+ function j(e, t, n, r) {
285
+ let i;
286
+ return () => {
287
+ let n = t.value;
288
+ e.toggleAttribute("disabled", n), n ? e.setAttribute("aria-disabled", "true") : e.removeAttribute("aria-disabled"), r?.manageTabindex && e.setAttribute("tabindex", n ? "-1" : "0"), i !== void 0 && i !== n && e.dispatchEvent(new CustomEvent("ui-disabled", {
289
+ bubbles: !0,
290
+ composed: !0,
291
+ detail: { disabled: n }
292
+ })), i = n;
293
+ };
294
+ }
295
+ function M(e, t, n) {
296
+ let r = n.attribute ?? t;
297
+ if (n.type === "boolean") {
298
+ let t = _(!1);
299
+ return {
300
+ get signal() {
301
+ return t;
302
+ },
303
+ get value() {
304
+ return t.value;
305
+ },
306
+ set(n) {
307
+ t.value = n, e.toggleAttribute(r, n);
308
+ },
309
+ fromAttribute(e) {
310
+ t.value = e !== null;
311
+ }
312
+ };
313
+ }
314
+ if (n.type === "number") {
315
+ let t = n.initial ?? 0, i = _(t);
316
+ return {
317
+ get signal() {
318
+ return i;
319
+ },
320
+ get value() {
321
+ return i.value;
322
+ },
323
+ set(t) {
324
+ i.value = t, e.setAttribute(r, String(t));
325
+ },
326
+ fromAttribute(e) {
327
+ i.value = parseFloat(e ?? String(t)) || t;
328
+ }
329
+ };
330
+ }
331
+ let i = n.initial ?? "", a = _(i);
332
+ return {
333
+ get signal() {
334
+ return a;
335
+ },
336
+ get value() {
337
+ return a.value;
338
+ },
339
+ set(t) {
340
+ a.value = t, t ? e.getAttribute(r) !== t && e.setAttribute(r, t) : e.removeAttribute(r);
341
+ },
342
+ fromAttribute(e) {
343
+ a.value = e ?? i;
344
+ }
345
+ };
346
+ }
347
+ /**
348
+ * Dispatches an attribute change to the matching reactive prop.
349
+ * Returns true if handled, false if no matching prop was found.
350
+ *
351
+ * ```ts
352
+ * attributeChangedCallback(name, old, val) {
353
+ * if (old === val) return;
354
+ * if (syncProp(this.#props, name, val)) return;
355
+ * // handle non-prop attributes...
356
+ * super.attributeChangedCallback?.(name, old, val);
357
+ * }
358
+ * ```
359
+ */
360
+ function N(e, t, n) {
361
+ let r = e[t];
362
+ return r ? (r.fromAttribute(n), !0) : !1;
363
+ }
364
+ /**
365
+ * Mixin that provides the common form-association boilerplate:
366
+ *
367
+ * - `static formAssociated = true`
368
+ * - `formDisabledCallback` → calls `onFormDisabled(disabled)`
369
+ * - `formResetCallback` → calls `onFormReset()`
370
+ * - `formStateRestoreCallback` → calls `onFormStateRestore(state)`
371
+ *
372
+ * Must remain a mixin (not a controller) because the Web Components spec
373
+ * requires `static formAssociated = true` on the class constructor.
374
+ *
375
+ * ```ts
376
+ * class UIInput extends FormAssociable(UIElement) {
377
+ * #internals = this.attachInternals();
378
+ * onFormDisabled(disabled: boolean) { this.#disabled.value = disabled; }
379
+ * onFormReset() { this.textContent = ''; }
380
+ * }
381
+ * ```
382
+ */
383
+ function P(e) {
384
+ return class extends e {
385
+ static formAssociated = !0;
386
+ /** Override to handle form-initiated disabled state changes. */
387
+ onFormDisabled(e) {}
388
+ /** Override to handle form reset. */
389
+ onFormReset() {}
390
+ /** Override to handle form state restore (e.g. back/forward navigation). */
391
+ onFormStateRestore(e) {}
392
+ formDisabledCallback(e) {
393
+ this.onFormDisabled(e);
394
+ }
395
+ formResetCallback() {
396
+ this.onFormReset();
397
+ }
398
+ formStateRestoreCallback(e, t) {
399
+ this.onFormStateRestore(e);
400
+ }
401
+ formAssociatedCallback(e) {}
402
+ };
403
+ }
404
+ var F = class {
405
+ #e = /* @__PURE__ */ new Set();
406
+ #t = null;
407
+ #n = !1;
408
+ register(e) {
409
+ this.#e.add(e), this.#a();
410
+ }
411
+ unregister(e) {
412
+ this.#e.delete(e), this.#t === e && (this.#t = null), this.#e.size === 0 && this.#o();
413
+ }
414
+ /** Release the current claim (e.g. on pointerup). */
415
+ release() {
416
+ this.#t = null;
417
+ }
418
+ /** Get the currently active (claiming) participant, if any. */
419
+ get activeParticipant() {
420
+ return this.#t;
421
+ }
422
+ #r = (e) => {
423
+ if (this.#t) return;
424
+ let t = e.target, n = [];
425
+ for (let e of this.#e) e.host.contains(t) && n.push(e);
426
+ if (n.length !== 0) {
427
+ n.sort((e, t) => e.priority - t.priority);
428
+ for (let t of n) if (t.onGestureStart(e) === "claim") {
429
+ this.#t = t;
430
+ for (let e of n) e !== t && e.onGestureCancel?.();
431
+ return;
432
+ }
433
+ }
434
+ };
435
+ #i = () => {
436
+ this.release();
437
+ };
438
+ #a() {
439
+ this.#n ||= (document.addEventListener("pointerdown", this.#r, !0), document.addEventListener("pointerup", this.#i, !0), document.addEventListener("pointercancel", this.#i, !0), !0);
440
+ }
441
+ #o() {
442
+ this.#n &&= (document.removeEventListener("pointerdown", this.#r, !0), document.removeEventListener("pointerup", this.#i, !0), document.removeEventListener("pointercancel", this.#i, !0), !1);
443
+ }
444
+ }, I = class {
445
+ #e = [];
446
+ #t = !1;
447
+ #n = (e) => {
448
+ let t = this.#e[this.#e.length - 1];
449
+ t && (e.composedPath().includes(t) || t.dispatchEvent(new CustomEvent("ui-dismiss", {
450
+ bubbles: !0,
451
+ composed: !0
452
+ })));
453
+ };
454
+ #r = (e) => {
455
+ if (e.key !== "Escape") return;
456
+ let t = this.#e[this.#e.length - 1];
457
+ t && (e.preventDefault(), t.dispatchEvent(new CustomEvent("ui-dismiss", {
458
+ bubbles: !0,
459
+ composed: !0
460
+ })));
461
+ };
462
+ push(e) {
463
+ let t = this.#e.indexOf(e);
464
+ t !== -1 && this.#e.splice(t, 1), this.#e.push(e), this.#i();
465
+ }
466
+ remove(e) {
467
+ let t = this.#e.indexOf(e);
468
+ t !== -1 && this.#e.splice(t, 1), this.#a();
469
+ }
470
+ #i() {
471
+ this.#t ||= (document.addEventListener("pointerdown", this.#n, !0), document.addEventListener("keydown", this.#r), !0);
472
+ }
473
+ #a() {
474
+ this.#e.length > 0 || (document.removeEventListener("pointerdown", this.#n, !0), document.removeEventListener("keydown", this.#r), this.#t = !1);
475
+ }
476
+ }, L = class {
477
+ #e = null;
478
+ #t = 0;
479
+ #n = [];
480
+ #r() {
481
+ return this.#e && this.#e.isConnected ? this.#e : (this.#e = document.createElement("div"), this.#e.className = "ui-toast-container", this.#e.setAttribute("role", "status"), this.#e.setAttribute("aria-live", "polite"), this.#e.setAttribute("aria-atomic", "false"), this.#e.style.cssText = "\n position: fixed;\n top: 1rem;\n right: 1rem;\n display: flex;\n flex-direction: column;\n gap: 0.5rem;\n z-index: 10000;\n pointer-events: none;\n ", document.body.appendChild(this.#e), this.#e);
482
+ }
483
+ toast(e, t) {
484
+ let { message: n, intent: r = "info", duration: i = 4e3, dismissible: a = !0 } = t, o = this.#t++, s = this.#r(), c = document.createElement("div");
485
+ c.className = "ui-toast", c.setAttribute("intent", r), c.setAttribute("role", "alert"), c.style.cssText = "pointer-events: auto;";
486
+ let l = document.createElement("span");
487
+ if (l.className = "ui-toast-message", l.textContent = n, c.appendChild(l), a) {
488
+ let e = document.createElement("button");
489
+ e.className = "ui-toast-close", e.setAttribute("aria-label", "Dismiss"), e.textContent = "×", e.addEventListener("click", () => this.dismiss(o)), c.appendChild(e);
490
+ }
491
+ s.appendChild(c);
492
+ let u = i > 0 ? setTimeout(() => this.dismiss(o), i) : null;
493
+ return this.#n.push({
494
+ id: o,
495
+ el: c,
496
+ timer: u
497
+ }), e.dispatchEvent(new CustomEvent("ui-toast", {
498
+ bubbles: !0,
499
+ composed: !0,
500
+ detail: {
501
+ id: o,
502
+ message: n,
503
+ intent: r
504
+ }
505
+ })), o;
506
+ }
507
+ dismiss(e) {
508
+ let t = this.#n.findIndex((t) => t.id === e);
509
+ if (t === -1) return;
510
+ let n = this.#n[t];
511
+ n.timer && clearTimeout(n.timer), n.el.remove(), this.#n.splice(t, 1), this.#n.length === 0 && this.#e && (this.#e.remove(), this.#e = null);
512
+ }
513
+ dismissAll() {
514
+ for (let e of [...this.#n]) this.dismiss(e.id);
515
+ }
516
+ }, ie = null;
517
+ function R() {
518
+ return ie ||= {
519
+ dismissStack: new I(),
520
+ toastManager: new L(),
521
+ gestureRouter: new F()
522
+ }, ie;
523
+ }
524
+ function ae(e, t) {
525
+ return e.label.toLowerCase().includes(t.toLowerCase());
526
+ }
527
+ var z = class {
528
+ data;
529
+ query;
530
+ #e;
531
+ #t;
532
+ filtered;
533
+ sorted;
534
+ activeIndex;
535
+ activeItem;
536
+ value;
537
+ selected;
538
+ #n;
539
+ selectedItem;
540
+ empty;
541
+ constructor(e = {}) {
542
+ this.data = _([]), this.query = _(""), this.#e = _(e.filterFn ?? ae), this.#t = _(e.sortFn ?? null), this.#n = _(e.multiple ?? !1), this.activeIndex = _(e.initialActiveIndex ?? -1), this.value = _(null), this.selected = _(/* @__PURE__ */ new Set()), this.filtered = v(() => {
543
+ let e = this.data.value, t = this.query.value, n = this.#e.value;
544
+ return t ? e.filter((e) => n(e, t)) : e;
545
+ }), this.sorted = v(() => {
546
+ let e = this.filtered.value, t = this.#t.value;
547
+ return t ? [...e].sort(t) : e;
548
+ }), this.activeItem = v(() => {
549
+ let e = this.view.value, t = this.activeIndex.value;
550
+ return t >= 0 && t < e.length ? e[t] : null;
551
+ }), this.selectedItem = v(() => {
552
+ let e = this.value.value;
553
+ return e === null ? null : this.data.value.find((t) => t.value === e) ?? null;
554
+ }), this.empty = v(() => this.view.value.length === 0);
555
+ }
556
+ get view() {
557
+ return this.sorted;
558
+ }
559
+ get multiple() {
560
+ return this.#n.value;
561
+ }
562
+ set multiple(e) {
563
+ this.#n.value = e;
564
+ }
565
+ setQuery(e, t) {
566
+ b(() => {
567
+ this.query.value = e, this.activeIndex.value = t ?? -1;
568
+ });
569
+ }
570
+ moveActive(e, t) {
571
+ let n = t ?? this.view.value.length;
572
+ if (n === 0) return;
573
+ let r = this.activeIndex.value;
574
+ if (t == null) {
575
+ let t = this.view.value, i = (r + e + n) % n, a = 0;
576
+ for (; t[i]?.disabled && a < n;) i = (i + e + n) % n, a++;
577
+ this.activeIndex.value = i;
578
+ return;
579
+ }
580
+ this.activeIndex.value = (r + e + n) % n;
581
+ }
582
+ selectActive() {
583
+ let e = this.activeItem.value;
584
+ e && this.select(e.value);
585
+ }
586
+ select(e) {
587
+ if (this.#n.value) {
588
+ let t = new Set(this.selected.value);
589
+ t.add(e), b(() => {
590
+ this.selected.value = t, this.value.value = e;
591
+ });
592
+ } else this.value.value = e;
593
+ }
594
+ deselect(e) {
595
+ if (!this.#n.value) return;
596
+ let t = new Set(this.selected.value);
597
+ t.delete(e), b(() => {
598
+ this.selected.value = t, this.value.value === e && (this.value.value = null);
599
+ });
600
+ }
601
+ toggle(e) {
602
+ this.#n.value && this.selected.value.has(e) ? this.deselect(e) : this.select(e);
603
+ }
604
+ selectAll() {
605
+ if (!this.#n.value) return;
606
+ let e = this.view.value;
607
+ this.selected.value = new Set(e.map((e) => e.value));
608
+ }
609
+ clearSelection() {
610
+ b(() => {
611
+ this.value.value = null, this.selected.value = /* @__PURE__ */ new Set();
612
+ });
613
+ }
614
+ reset() {
615
+ b(() => {
616
+ this.data.value = [], this.query.value = "", this.activeIndex.value = -1, this.value.value = null, this.selected.value = /* @__PURE__ */ new Set();
617
+ });
618
+ }
619
+ setFilter(e) {
620
+ this.#e.value = e;
621
+ }
622
+ setSort(e) {
623
+ this.#t.value = e;
624
+ }
625
+ };
626
+ function oe(e) {
627
+ return new z(e);
628
+ }
629
+ /**
630
+ * Validates a JSON string → typed option array.
631
+ * Filters out entries missing `value` or `label` strings.
15
632
  */
16
- var ee = class extends S(_) {
633
+ function B(e, t) {
634
+ try {
635
+ let t = JSON.parse(e);
636
+ return Array.isArray(t) ? t.filter((e) => typeof e == "object" && !!e && typeof e.value == "string" && typeof e.label == "string") : [];
637
+ } catch {
638
+ return console.warn(`<${t}>: invalid options JSON`, e), [];
639
+ }
640
+ }
641
+ /**
642
+ * Fetches remote options with abort-guard and stale-response protection.
643
+ * Aborts any in-flight request before starting a new one.
644
+ * Returns the new AbortController for the caller to store.
645
+ */
646
+ async function V(e, t, n, r) {
647
+ t?.abort();
648
+ let i = new AbortController();
649
+ try {
650
+ let t = await fetch(e, { signal: i.signal });
651
+ if (!t.ok) return console.warn(`<${r}>: fetch failed (${t.status}) for ${e}`), i;
652
+ let a = await t.json();
653
+ if (i.signal.aborted) return i;
654
+ n.value = (Array.isArray(a) ? a : []).filter((e) => typeof e == "object" && !!e && typeof e.value == "string" && typeof e.label == "string");
655
+ } catch (e) {
656
+ if (e instanceof DOMException && e.name === "AbortError") return i;
657
+ console.warn(`<${r}>: fetch error`, e);
658
+ }
659
+ return i;
660
+ }
661
+ /** Enables pointer-driven drag-and-drop with drop, slot, or preview reordering. */
662
+ var H = class {
663
+ host;
664
+ selector;
665
+ dropZoneSelector;
666
+ axis;
667
+ mode;
668
+ disabled;
669
+ animate;
670
+ #e = null;
671
+ #t = null;
672
+ #n = null;
673
+ #r = 0;
674
+ #i = 0;
675
+ #a = 0;
676
+ #o = 0;
677
+ #s = -1;
678
+ #c = -1;
679
+ #l = !1;
680
+ #u = null;
681
+ #d = null;
682
+ #f = -1;
683
+ constructor(e, t) {
684
+ this.host = e, this.selector = t.selector, this.dropZoneSelector = t.dropZoneSelector ?? "", this.axis = t.axis ?? "both", this.mode = t.mode ?? "drop", this.disabled = t.disabled ?? !1, this.animate = t.animate ?? !0, this.attach();
685
+ }
686
+ attach() {
687
+ this.#l || (this.#l = !0, this.host.addEventListener("pointerdown", this.#_), this.host.addEventListener("pointerenter", this.#h, !0), this.host.addEventListener("pointerleave", this.#g, !0));
688
+ }
689
+ detach() {
690
+ this.#l && (this.#l = !1, this.host.removeEventListener("pointerdown", this.#_), this.host.removeEventListener("pointerenter", this.#h, !0), this.host.removeEventListener("pointerleave", this.#g, !0), this.#A());
691
+ }
692
+ destroy() {
693
+ this.detach();
694
+ }
695
+ #p() {
696
+ return this.selector ? [...this.host.querySelectorAll(this.selector)] : [];
697
+ }
698
+ #m() {
699
+ return this.dropZoneSelector ? [...this.host.querySelectorAll(this.dropZoneSelector)] : this.#p();
700
+ }
701
+ #h = (e) => {
702
+ if (this.disabled || !this.selector || this.#t) return;
703
+ let t = e.target.closest?.(this.selector);
704
+ !t || !this.host.contains(t) || (t.style.outline = "2px solid var(--ui-focus-ring, highlight)", t.style.outlineOffset = "2px");
705
+ };
706
+ #g = (e) => {
707
+ if (!this.selector) return;
708
+ let t = e.target.closest?.(this.selector);
709
+ !t || !this.host.contains(t) || (t.style.removeProperty("outline"), t.style.removeProperty("outline-offset"));
710
+ };
711
+ #_ = (e) => {
712
+ if (e.button !== 0 || this.disabled || !this.selector) return;
713
+ let t = e.target.closest?.(this.selector);
714
+ if (!t || !this.host.contains(t)) return;
715
+ let n = this.#p().indexOf(t);
716
+ if (n === -1) return;
717
+ e.preventDefault(), this.#e = t, this.#s = n, this.#r = e.clientX, this.#i = e.clientY;
718
+ let r = t.getBoundingClientRect();
719
+ this.#a = r.left + r.width / 2 - e.clientX, this.#o = r.top + r.height / 2 - e.clientY, document.addEventListener("pointermove", this.#v), document.addEventListener("pointerup", this.#E), document.addEventListener("pointercancel", this.#D), document.addEventListener("keydown", this.#O);
720
+ };
721
+ #v = (e) => {
722
+ if (!this.#e) return;
723
+ if (!this.#t) {
724
+ this.#e.style.removeProperty("outline"), this.#e.style.removeProperty("outline-offset");
725
+ try {
726
+ this.#k(e);
727
+ } catch {
728
+ this.#A();
729
+ return;
730
+ }
731
+ this.#e.setAttribute("dragging", ""), this.mode === "preview" && (this.#u = this.#e.parentElement, this.#d = this.#e.nextElementSibling, this.#f = -1, this.animate && this.#C()), this.host.dispatchEvent(new CustomEvent("ui-drag-start", {
732
+ bubbles: !0,
733
+ composed: !0,
734
+ detail: {
735
+ item: this.#e,
736
+ index: this.#s
737
+ }
738
+ }));
739
+ }
740
+ let t = e.clientX - this.#r, n = e.clientY - this.#i;
741
+ this.#t.style.transform = `translate(${t}px, ${n}px) scale(0.9)`, this.host.dispatchEvent(new CustomEvent("ui-drag-move", {
742
+ bubbles: !0,
743
+ composed: !0,
744
+ detail: {
745
+ item: this.#e,
746
+ x: e.clientX,
747
+ y: e.clientY
748
+ }
749
+ }));
750
+ let r = this.#m().filter((e) => e !== this.#t);
751
+ if (this.mode === "slot") {
752
+ let t = e.clientX + this.#a, n = e.clientY + this.#o, i = r.filter((e) => e !== this.#e), a = 0;
753
+ for (let e = 0; e < i.length; e++) {
754
+ let r = i[e].getBoundingClientRect(), o = r.left + r.width / 2, s = r.top + r.height / 2;
755
+ if (this.axis === "horizontal" ? t > o : (this.axis === "vertical" || t > o) && n > s) a = e + 1;
756
+ else break;
757
+ }
758
+ this.#b(r, a);
759
+ } else if (this.mode === "preview") {
760
+ let t = e.clientX + this.#a, n = e.clientY + this.#o;
761
+ this.#S(r, t, n);
762
+ } else {
763
+ let t = null, n = -1;
764
+ for (let i = 0; i < r.length; i++) {
765
+ let a = r[i].getBoundingClientRect(), o = a.left + a.width / 2, s = a.top + a.height / 2;
766
+ if (this.axis === "vertical" ? e.clientY >= a.top && e.clientY <= a.bottom : this.axis === "horizontal" ? e.clientX >= a.left && e.clientX <= a.right : e.clientX >= a.left && e.clientX <= a.right && e.clientY >= a.top && e.clientY <= a.bottom) {
767
+ n = (this.axis === "horizontal" ? e.clientX < o : e.clientY < s) ? i : i + 1, t = r[i];
768
+ break;
769
+ }
770
+ }
771
+ this.#y(r, t, n);
772
+ }
773
+ };
774
+ #y(e, t, n) {
775
+ for (let n of e) n !== t && (n.removeAttribute("drag-over"), n.style.removeProperty("outline"), n.style.removeProperty("outline-offset"));
776
+ t && (t.setAttribute("drag-over", ""), t.style.outline = "2px solid var(--ui-focus-ring, highlight)", t.style.outlineOffset = "2px", this.host.dispatchEvent(new CustomEvent("ui-drag-over", {
777
+ bubbles: !0,
778
+ composed: !0,
779
+ detail: {
780
+ item: this.#e,
781
+ target: t,
782
+ index: n
783
+ }
784
+ })));
785
+ }
786
+ #b(e, t) {
787
+ if (t === -1 || t === this.#c) return;
788
+ this.#c = t, this.#x(e), this.#n || (this.#n = document.createElement("div"), this.#n.className = "drag-placeholder", this.#n.setAttribute("aria-hidden", "true"));
789
+ let n = e.filter((e) => e !== this.#e), r = Math.min(t, n.length);
790
+ r < n.length ? n[r].before(this.#n) : n.length > 0 ? n[n.length - 1].after(this.#n) : this.host.appendChild(this.#n), r < n.length && n[r].setAttribute("drag-slot-before", ""), r > 0 && r - 1 < n.length && n[r - 1].setAttribute("drag-slot-after", "");
791
+ let i = r < n.length ? n[r] : null;
792
+ this.host.dispatchEvent(new CustomEvent("ui-drag-over", {
793
+ bubbles: !0,
794
+ composed: !0,
795
+ detail: {
796
+ item: this.#e,
797
+ index: t,
798
+ insertBefore: i
799
+ }
800
+ }));
801
+ }
802
+ #x(e) {
803
+ for (let t of e) t.removeAttribute("drag-slot-before"), t.removeAttribute("drag-slot-after");
804
+ }
805
+ #S(e, t, n) {
806
+ let r = e.filter((e) => e !== this.#e);
807
+ if (r.length === 0) return;
808
+ let i = e[0].getBoundingClientRect(), a = 1;
809
+ for (let t = 1; t < e.length && Math.abs(e[t].getBoundingClientRect().top - i.top) < i.height * .5; t++) a = t + 1;
810
+ let o = a > 1 ? e[1].getBoundingClientRect().left - i.left : i.width, s = a < e.length ? e[a].getBoundingClientRect().top - i.top : i.height, c = Math.round((t - (i.left + i.width / 2)) / o), l = Math.round((n - (i.top + i.height / 2)) / s), u = Math.ceil(r.length / a) - 1, d = Math.max(0, Math.min(c, a - 1)), f = Math.max(0, Math.min(l, u)) * a + d;
811
+ if (f = Math.max(0, Math.min(f, r.length)), f === this.#f) return;
812
+ this.#f = f;
813
+ let p = f < r.length ? r[f] : null, m = () => {
814
+ p ? p.before(this.#e) : r[r.length - 1].after(this.#e);
815
+ };
816
+ this.animate && typeof document.startViewTransition == "function" ? document.startViewTransition(() => {
817
+ m(), this.#C();
818
+ }) : m(), this.host.dispatchEvent(new CustomEvent("ui-drag-over", {
819
+ bubbles: !0,
820
+ composed: !0,
821
+ detail: {
822
+ item: this.#e,
823
+ index: f,
824
+ insertBefore: p
825
+ }
826
+ }));
827
+ }
828
+ #C() {
829
+ let e = this.#p();
830
+ for (let t = 0; t < e.length; t++) e[t].style.viewTransitionName = e[t] === this.#e ? "none" : `drag-item-${t}`;
831
+ }
832
+ #w() {
833
+ for (let e of this.#p()) e.style.removeProperty("view-transition-name");
834
+ }
835
+ #T() {
836
+ if (this.mode !== "preview" || !this.#e || !this.#u) return;
837
+ let e = this.#e, t = this.#d, n = this.#u, r = () => {
838
+ t && t.isConnected ? t.before(e) : n.appendChild(e);
839
+ };
840
+ this.animate && typeof document.startViewTransition == "function" ? document.startViewTransition(() => {
841
+ r(), this.#C();
842
+ }) : r();
843
+ }
844
+ #E = (e) => {
845
+ if (this.#e) {
846
+ if (this.#t) if (this.mode === "slot") {
847
+ let e = this.#p().filter((e) => e !== this.#e), t = this.#c >= 0 && this.#c < e.length ? e[this.#c] : null;
848
+ this.host.dispatchEvent(new CustomEvent("ui-drop", {
849
+ bubbles: !0,
850
+ composed: !0,
851
+ detail: {
852
+ item: this.#e,
853
+ fromIndex: this.#s,
854
+ toIndex: this.#c,
855
+ insertBefore: t
856
+ }
857
+ }));
858
+ } else if (this.mode === "preview") {
859
+ let e = this.#p(), t = this.#e ? e.indexOf(this.#e) : -1;
860
+ this.#u = null, this.#d = null, this.host.dispatchEvent(new CustomEvent("ui-drop", {
861
+ bubbles: !0,
862
+ composed: !0,
863
+ detail: {
864
+ item: this.#e,
865
+ fromIndex: this.#s,
866
+ toIndex: t
867
+ }
868
+ }));
869
+ } else {
870
+ let e = this.#m(), t = e.find((e) => e.hasAttribute("drag-over")) ?? null, n = t ? e.indexOf(t) : -1;
871
+ this.host.dispatchEvent(new CustomEvent("ui-drop", {
872
+ bubbles: !0,
873
+ composed: !0,
874
+ detail: {
875
+ item: this.#e,
876
+ target: t,
877
+ fromIndex: this.#s,
878
+ toIndex: n
879
+ }
880
+ }));
881
+ }
882
+ this.#A();
883
+ }
884
+ };
885
+ #D = () => {
886
+ this.#e && (this.#T(), this.#t && this.host.dispatchEvent(new CustomEvent("ui-drag-cancel", {
887
+ bubbles: !0,
888
+ composed: !0,
889
+ detail: { item: this.#e }
890
+ })), this.#A());
891
+ };
892
+ #O = (e) => {
893
+ e.key === "Escape" && this.#e && (e.preventDefault(), this.#T(), this.#t && this.host.dispatchEvent(new CustomEvent("ui-drag-cancel", {
894
+ bubbles: !0,
895
+ composed: !0,
896
+ detail: { item: this.#e }
897
+ })), this.#A());
898
+ };
899
+ #k(e) {
900
+ if (!this.#e) return;
901
+ let t = this.#e.getBoundingClientRect(), n = this.#e.cloneNode(!0);
902
+ n.setAttribute("popover", "manual"), n.setAttribute("aria-hidden", "true"), document.body.appendChild(n), n.showPopover(), n.style.position = "fixed", n.style.inset = "unset", n.style.left = `${t.left}px`, n.style.top = `${t.top}px`, n.style.width = `${t.width}px`, n.style.height = `${t.height}px`, n.style.margin = "0", n.style.pointerEvents = "none", n.style.opacity = "0.8", n.style.transformOrigin = "center center", n.style.border = "none", n.style.outline = "none", this.#t = n, this.#r = e.clientX, this.#i = e.clientY;
903
+ }
904
+ #A() {
905
+ if (this.#t) {
906
+ if (this.#t.isConnected) try {
907
+ this.#t.hidePopover();
908
+ } catch {}
909
+ this.#t.remove(), this.#t = null;
910
+ }
911
+ this.#e && this.#e.removeAttribute("dragging"), this.mode === "preview" && this.animate && this.#w();
912
+ let e = this.#m();
913
+ if (this.mode === "slot") this.#x(e);
914
+ else for (let t of e) t.removeAttribute("drag-over"), t.style.removeProperty("outline"), t.style.removeProperty("outline-offset");
915
+ this.#n &&= (this.#n.remove(), null), this.#e = null, this.#s = -1, this.#c = -1, this.#u = null, this.#d = null, this.#f = -1, document.removeEventListener("pointermove", this.#v), document.removeEventListener("pointerup", this.#E), document.removeEventListener("pointercancel", this.#D), document.removeEventListener("keydown", this.#O);
916
+ }
917
+ }, U = class {
918
+ host;
919
+ handleSelector;
920
+ axis;
921
+ min;
922
+ max;
923
+ disabled;
924
+ reverse;
925
+ #e = 0;
926
+ #t = 0;
927
+ #n = 0;
928
+ #r = 0;
929
+ #i = !1;
930
+ #a = !1;
931
+ constructor(e, t) {
932
+ this.host = e, this.handleSelector = t.handleSelector, this.axis = t.axis ?? "horizontal", this.min = t.min ?? 0, this.max = t.max ?? Infinity, this.disabled = t.disabled ?? !1, this.reverse = t.reverse ?? !1, this.attach();
933
+ }
934
+ attach() {
935
+ this.#a || (this.#a = !0, this.host.addEventListener("pointerdown", this.#o));
936
+ }
937
+ detach() {
938
+ this.#a && (this.#a = !1, this.host.removeEventListener("pointerdown", this.#o), this.#d());
939
+ }
940
+ destroy() {
941
+ this.detach();
942
+ }
943
+ #o = (e) => {
944
+ if (e.button !== 0 || this.disabled || !this.handleSelector) return;
945
+ let t = e.target.closest?.(this.handleSelector);
946
+ if (!t || !this.host.contains(t)) return;
947
+ e.preventDefault(), this.#i = !0, this.#e = e.clientX, this.#t = e.clientY;
948
+ let n = this.host.getBoundingClientRect();
949
+ this.#n = n.width, this.#r = n.height, this.host.setAttribute("resizing", ""), this.host.setPointerCapture(e.pointerId), document.addEventListener("pointermove", this.#s), document.addEventListener("pointerup", this.#c), document.addEventListener("pointercancel", this.#l), document.addEventListener("keydown", this.#u), this.host.dispatchEvent(new CustomEvent("ui-resize-start", {
950
+ bubbles: !0,
951
+ composed: !0,
952
+ detail: {
953
+ width: this.#n,
954
+ height: this.#r
955
+ }
956
+ }));
957
+ };
958
+ #s = (e) => {
959
+ if (!this.#i) return;
960
+ let t = this.reverse ? -1 : 1, n = (e.clientX - this.#e) * t, r = (e.clientY - this.#t) * t;
961
+ if (this.axis === "horizontal" || this.axis === "both") {
962
+ let e = Math.min(this.max, Math.max(this.min, this.#n + n));
963
+ this.host.style.width = `${e}px`;
964
+ }
965
+ if (this.axis === "vertical" || this.axis === "both") {
966
+ let e = Math.min(this.max, Math.max(this.min, this.#r + r));
967
+ this.host.style.height = `${e}px`;
968
+ }
969
+ let i = this.host.getBoundingClientRect();
970
+ this.host.dispatchEvent(new CustomEvent("ui-resize-move", {
971
+ bubbles: !0,
972
+ composed: !0,
973
+ detail: {
974
+ width: i.width,
975
+ height: i.height
976
+ }
977
+ }));
978
+ };
979
+ #c = (e) => {
980
+ if (!this.#i) return;
981
+ let t = this.host.getBoundingClientRect();
982
+ this.host.dispatchEvent(new CustomEvent("ui-resize-end", {
983
+ bubbles: !0,
984
+ composed: !0,
985
+ detail: {
986
+ width: t.width,
987
+ height: t.height
988
+ }
989
+ })), this.#d();
990
+ };
991
+ #l = () => {
992
+ this.#i && ((this.axis === "horizontal" || this.axis === "both") && (this.host.style.width = `${this.#n}px`), (this.axis === "vertical" || this.axis === "both") && (this.host.style.height = `${this.#r}px`), this.#d());
993
+ };
994
+ #u = (e) => {
995
+ e.key === "Escape" && this.#i && (e.preventDefault(), (this.axis === "horizontal" || this.axis === "both") && (this.host.style.width = `${this.#n}px`), (this.axis === "vertical" || this.axis === "both") && (this.host.style.height = `${this.#r}px`), this.#d());
996
+ };
997
+ #d() {
998
+ this.#i = !1, this.host.removeAttribute("resizing"), document.removeEventListener("pointermove", this.#s), document.removeEventListener("pointerup", this.#c), document.removeEventListener("pointercancel", this.#l), document.removeEventListener("keydown", this.#u);
999
+ }
1000
+ }, W = class {
1001
+ host;
1002
+ disabled;
1003
+ #e = !1;
1004
+ #t = "mouse";
1005
+ #n = !1;
1006
+ constructor(e, t = {}) {
1007
+ this.host = e, this.disabled = t.disabled ?? !1, this.attach();
1008
+ }
1009
+ #r() {
1010
+ return typeof this.disabled == "function" ? this.disabled() : this.disabled ? !0 : this.host.disabled === !0;
1011
+ }
1012
+ attach() {
1013
+ this.#n || (this.#n = !0, this.host.addEventListener("pointerdown", this.#i), this.host.addEventListener("pointerup", this.#a), this.host.addEventListener("pointercancel", this.#o), this.host.addEventListener("lostpointercapture", this.#s), this.host.addEventListener("keydown", this.#c), this.host.addEventListener("keyup", this.#l));
1014
+ }
1015
+ detach() {
1016
+ this.#n && (this.#n = !1, this.host.removeEventListener("pointerdown", this.#i), this.host.removeEventListener("pointerup", this.#a), this.host.removeEventListener("pointercancel", this.#o), this.host.removeEventListener("lostpointercapture", this.#s), this.host.removeEventListener("keydown", this.#c), this.host.removeEventListener("keyup", this.#l), this.host.removeAttribute("pressed"));
1017
+ }
1018
+ destroy() {
1019
+ this.detach();
1020
+ }
1021
+ #i = (e) => {
1022
+ e.button === 0 && (this.#r() || (this.#t = e.pointerType, this.host.setPointerCapture(e.pointerId), this.#e = !0, this.host.toggleAttribute("pressed", !0)));
1023
+ };
1024
+ #a = (e) => {
1025
+ this.#e && (this.#e = !1, this.host.removeAttribute("pressed"), this.host.dispatchEvent(new CustomEvent("ui-press", {
1026
+ bubbles: !0,
1027
+ composed: !0,
1028
+ detail: { pointerType: this.#t }
1029
+ })));
1030
+ };
1031
+ #o = () => {
1032
+ this.#e = !1, this.host.removeAttribute("pressed");
1033
+ };
1034
+ #s = () => {
1035
+ this.#e = !1, this.host.removeAttribute("pressed");
1036
+ };
1037
+ #c = (e) => {
1038
+ e.repeat || this.#r() || e.key !== "Enter" && e.key !== " " || (e.key === " " && e.preventDefault(), this.host.toggleAttribute("pressed", !0));
1039
+ };
1040
+ #l = (e) => {
1041
+ e.key !== "Enter" && e.key !== " " || (this.host.removeAttribute("pressed"), !this.#r() && this.host.dispatchEvent(new CustomEvent("ui-press", {
1042
+ bubbles: !0,
1043
+ composed: !0,
1044
+ detail: { pointerType: "keyboard" }
1045
+ })));
1046
+ };
1047
+ }, G = class {
1048
+ host;
1049
+ selector;
1050
+ orientation;
1051
+ wrap;
1052
+ disabled;
1053
+ #e = 0;
1054
+ #t = !1;
1055
+ constructor(e, t = {}) {
1056
+ this.host = e, this.selector = t.selector ?? ":scope > [role]", this.orientation = t.orientation ?? "vertical", this.wrap = t.wrap ?? !0, this.disabled = t.disabled ?? !1, this.attach();
1057
+ }
1058
+ attach() {
1059
+ if (this.#t || this.disabled) return;
1060
+ this.#t = !0, this.host.addEventListener("keydown", this.#r), this.host.addEventListener("focusin", this.#i);
1061
+ let e = this.#n();
1062
+ for (let t = 0; t < e.length; t++) e[t].setAttribute("tabindex", t === 0 ? "0" : "-1");
1063
+ }
1064
+ detach() {
1065
+ this.#t && (this.#t = !1, this.host.removeEventListener("keydown", this.#r), this.host.removeEventListener("focusin", this.#i));
1066
+ }
1067
+ destroy() {
1068
+ this.detach();
1069
+ }
1070
+ #n() {
1071
+ return [...this.host.querySelectorAll(this.selector)].filter((e) => !e.hasAttribute("disabled") && e.getAttribute("aria-disabled") !== "true");
1072
+ }
1073
+ #r = (e) => {
1074
+ let t = this.#n();
1075
+ if (t.length === 0) return;
1076
+ let n = 0, r = this.orientation === "vertical" || this.orientation === "both", i = this.orientation === "horizontal" || this.orientation === "both";
1077
+ if (e.key === "ArrowDown" && r) n = 1;
1078
+ else if (e.key === "ArrowUp" && r) n = -1;
1079
+ else if (e.key === "ArrowRight" && i) n = 1;
1080
+ else if (e.key === "ArrowLeft" && i) n = -1;
1081
+ else if (e.key === "Home") {
1082
+ this.#a(t, 0), e.preventDefault();
1083
+ return;
1084
+ } else if (e.key === "End") {
1085
+ this.#a(t, t.length - 1), e.preventDefault();
1086
+ return;
1087
+ } else return;
1088
+ e.preventDefault();
1089
+ let a = this.#e + n;
1090
+ a = this.wrap ? (a + t.length) % t.length : Math.max(0, Math.min(t.length - 1, a)), this.#a(t, a);
1091
+ };
1092
+ #i = (e) => {
1093
+ e.target === this.host && this.#n()[this.#e]?.focus();
1094
+ };
1095
+ #a(e, t) {
1096
+ let n = e[this.#e];
1097
+ n && n.setAttribute("tabindex", "-1"), this.#e = t;
1098
+ let r = e[t];
1099
+ r && (r.setAttribute("tabindex", "0"), r.focus());
1100
+ }
1101
+ }, K = class {
1102
+ host;
1103
+ #e = 0;
1104
+ constructor(e) {
1105
+ this.host = e;
1106
+ }
1107
+ enable() {
1108
+ this.#e = requestAnimationFrame(() => {
1109
+ this.#e = 0, R().dismissStack.push(this.host);
1110
+ });
1111
+ }
1112
+ disable() {
1113
+ this.#e &&= (cancelAnimationFrame(this.#e), 0), R().dismissStack.remove(this.host);
1114
+ }
1115
+ destroy() {
1116
+ this.#e &&= (cancelAnimationFrame(this.#e), 0), R().dismissStack.remove(this.host);
1117
+ }
1118
+ }, q = class {
1119
+ host;
1120
+ #e;
1121
+ #t = null;
1122
+ #n = null;
1123
+ constructor(e) {
1124
+ this.host = e, this.#e = new K(e);
1125
+ }
1126
+ wirePopover(e, t) {
1127
+ this.#t = e, this.#n = t;
1128
+ let n = A("anchor");
1129
+ e.style.setProperty("anchor-name", `--${n}`), t.style.setProperty("position-anchor", `--${n}`);
1130
+ }
1131
+ syncPopover(e) {
1132
+ if (e) {
1133
+ try {
1134
+ this.#n?.showPopover();
1135
+ } catch {}
1136
+ this.#e.enable();
1137
+ } else {
1138
+ try {
1139
+ this.#n?.hidePopover();
1140
+ } catch {}
1141
+ this.#e.disable();
1142
+ }
1143
+ }
1144
+ destroy() {
1145
+ this.#e.destroy(), this.#t?.style.removeProperty("anchor-name"), this.#t = null, this.#n?.style.removeProperty("position-anchor"), this.#n = null;
1146
+ }
1147
+ }, J = class {
1148
+ host;
1149
+ listValue = _(null);
1150
+ itemSelector;
1151
+ ariaAttr;
1152
+ autoSync;
1153
+ onChildSelect;
1154
+ #e;
1155
+ #t = !1;
1156
+ constructor(e, t = {}) {
1157
+ if (this.host = e, this.itemSelector = t.itemSelector ?? ":scope > [role]", this.ariaAttr = t.ariaAttr ?? "aria-selected", this.autoSync = t.autoSync ?? !0, this.onChildSelect = t.onChildSelect ?? ((t) => {
1158
+ this.listValue.value = t.value, e.dispatchEvent(new CustomEvent("ui-change", {
1159
+ bubbles: !0,
1160
+ composed: !0,
1161
+ cancelable: !0,
1162
+ detail: t
1163
+ }));
1164
+ }), this.#e = new G(e, {
1165
+ selector: this.itemSelector,
1166
+ orientation: t.orientation ?? "vertical",
1167
+ wrap: t.wrap ?? !0,
1168
+ disabled: t.disabled ?? !1
1169
+ }), this.attach(), this.autoSync && t.addEffect && t.deferChildren) {
1170
+ let n = t.addEffect;
1171
+ t.deferChildren(() => {
1172
+ n(() => {
1173
+ let t = this.listValue.value, n = e.querySelectorAll(this.itemSelector), r = this.ariaAttr === "aria-current";
1174
+ for (let e of n) {
1175
+ let n = e.getAttribute("value") ?? e.value;
1176
+ if (n !== void 0) {
1177
+ let i = n === t;
1178
+ r ? i ? e.setAttribute("aria-current", "page") : e.removeAttribute("aria-current") : e.setAttribute(this.ariaAttr, i ? "true" : "false");
1179
+ }
1180
+ }
1181
+ });
1182
+ });
1183
+ }
1184
+ }
1185
+ attach() {
1186
+ this.#t || (this.#t = !0, this.host.addEventListener("ui-select", this.#n));
1187
+ }
1188
+ detach() {
1189
+ this.#t && (this.#t = !1, this.host.removeEventListener("ui-select", this.#n));
1190
+ }
1191
+ destroy() {
1192
+ this.detach(), this.#e.destroy();
1193
+ }
1194
+ /** Access the underlying roving focus controller for direct configuration. */
1195
+ get rovingFocus() {
1196
+ return this.#e;
1197
+ }
1198
+ #n = (e) => {
1199
+ if (this.host.disabled === !0) return;
1200
+ let t = e.detail;
1201
+ this.onChildSelect(t);
1202
+ };
1203
+ }, Y = class {
1204
+ host;
1205
+ #e = null;
1206
+ #t;
1207
+ constructor(e, t = {}) {
1208
+ this.host = e, this.#t = t.contentTarget, this.#a();
1209
+ }
1210
+ get open() {
1211
+ return this.#e?.open ?? !1;
1212
+ }
1213
+ showModal() {
1214
+ !this.#e || this.open || (this.#e.showModal(), this.host.toggleAttribute("open", !0), queueMicrotask(() => {
1215
+ let e = this.#e?.querySelector("[autofocus]");
1216
+ if (e) {
1217
+ e.focus();
1218
+ return;
1219
+ }
1220
+ (this.#e?.querySelector("ui-input, ui-textarea, ui-button, ui-select, ui-listbox, input, textarea, select, button, [tabindex]:not([tabindex=\"-1\"])"))?.focus();
1221
+ }));
1222
+ }
1223
+ close() {
1224
+ !this.#e || !this.open || (this.#e.close(), this.host.toggleAttribute("open", !1), this.host.dispatchEvent(new Event("close")));
1225
+ }
1226
+ destroy() {
1227
+ this.#e && (this.#e.removeEventListener("cancel", this.#n), this.#e.removeEventListener("click", this.#r)), this.host.removeEventListener("ui-dismiss", this.#i), this.#e = null;
1228
+ }
1229
+ #n = (e) => {
1230
+ e.preventDefault(), this.host.hasAttribute("no-close-on-escape") || this.close();
1231
+ };
1232
+ #r = (e) => {
1233
+ e.target === this.#e && !this.host.hasAttribute("no-close-on-backdrop") && this.close();
1234
+ };
1235
+ #i = () => {
1236
+ this.host.hasAttribute("no-close-on-escape") || this.close();
1237
+ };
1238
+ #a() {
1239
+ let e = document.createElement("dialog"), t = this.#t ? this.#t(e) : e;
1240
+ for (; this.host.firstChild;) t.appendChild(this.host.firstChild);
1241
+ t !== e && e.appendChild(t), this.host.appendChild(e), this.#e = e, e.addEventListener("cancel", this.#n), e.addEventListener("click", this.#r), this.host.addEventListener("ui-dismiss", this.#i);
1242
+ }
1243
+ }, se = class extends P(k) {
1244
+ static observedAttributes = ["disabled", "type"];
1245
+ #e;
1246
+ #t;
1247
+ #n;
1248
+ #r;
1249
+ constructor() {
1250
+ super(), this.#e = this.attachInternals(), this.#e.role = "button", this.#t = M(this, "disabled", { type: "boolean" }), this.#n = M(this, "type", {
1251
+ type: "string",
1252
+ initial: "button"
1253
+ });
1254
+ }
1255
+ get disabled() {
1256
+ return this.#t.value;
1257
+ }
1258
+ set disabled(e) {
1259
+ this.#t.set(e);
1260
+ }
1261
+ get type() {
1262
+ return this.#n.value;
1263
+ }
1264
+ set type(e) {
1265
+ this.#n.set(e);
1266
+ }
1267
+ attributeChangedCallback(e, t, n) {
1268
+ t !== n && (N({
1269
+ disabled: this.#t,
1270
+ type: this.#n
1271
+ }, e, n), super.attributeChangedCallback?.(e, t, n));
1272
+ }
1273
+ setup() {
1274
+ super.setup(), this.#r = new W(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEffect(j(this, this.#t.signal, this.#e, { manageTabindex: !0 })), this.addEventListener("ui-press", this.#i);
1275
+ }
1276
+ teardown() {
1277
+ this.removeEventListener("ui-press", this.#i), this.#r.destroy(), super.teardown();
1278
+ }
1279
+ #i = () => {
1280
+ if (this.#t.value) return;
1281
+ let e = this.#e.form;
1282
+ if (!e) return;
1283
+ let t = this.#n.value;
1284
+ t === "submit" ? e.requestSubmit() : t === "reset" && e.reset();
1285
+ };
1286
+ onFormDisabled(e) {
1287
+ this.#t.signal.value = e;
1288
+ }
1289
+ onFormReset() {
1290
+ this.#t.signal.value = this.hasAttribute("disabled");
1291
+ }
1292
+ }, ce = class extends P(k) {
17
1293
  static observedAttributes = [
18
1294
  "value",
19
1295
  "placeholder",
@@ -23,9 +1299,9 @@ var ee = class extends S(_) {
23
1299
  "pattern"
24
1300
  ];
25
1301
  #e;
26
- #t = t(!1);
27
- #n = t(!1);
28
- #r = t("");
1302
+ #t = _(!1);
1303
+ #n = _(!1);
1304
+ #r = _("");
29
1305
  #i = "";
30
1306
  #a = null;
31
1307
  #o = [];
@@ -53,119 +1329,281 @@ var ee = class extends S(_) {
53
1329
  set placeholder(e) {
54
1330
  this.setAttribute("placeholder", e);
55
1331
  }
56
- get name() {
57
- return this.getAttribute("name") ?? "";
1332
+ get name() {
1333
+ return this.getAttribute("name") ?? "";
1334
+ }
1335
+ set name(e) {
1336
+ this.setAttribute("name", e);
1337
+ }
1338
+ get disabled() {
1339
+ return this.#t.value;
1340
+ }
1341
+ set disabled(e) {
1342
+ this.#t.value = e, this.toggleAttribute("disabled", e);
1343
+ }
1344
+ get readOnly() {
1345
+ return this.hasAttribute("readonly");
1346
+ }
1347
+ set readOnly(e) {
1348
+ this.toggleAttribute("readonly", e), this.setAttribute("contenteditable", e ? "false" : "plaintext-only");
1349
+ }
1350
+ get required() {
1351
+ return this.#n.value;
1352
+ }
1353
+ set required(e) {
1354
+ this.#n.value = e, this.toggleAttribute("required", e);
1355
+ }
1356
+ attributeChangedCallback(e, t, n) {
1357
+ if (t !== n) {
1358
+ switch (e) {
1359
+ case "value":
1360
+ this.#c(n ?? ""), this.#r.value = n ?? "", this.#e.setFormValue(n ?? ""), this.#l();
1361
+ break;
1362
+ case "disabled":
1363
+ this.#t.value = n !== null, this.setAttribute("contenteditable", n !== null || this.hasAttribute("readonly") ? "false" : "plaintext-only");
1364
+ break;
1365
+ case "readonly":
1366
+ this.setAttribute("contenteditable", n !== null || this.#t.value ? "false" : "plaintext-only");
1367
+ break;
1368
+ case "required":
1369
+ this.#n.value = n !== null;
1370
+ break;
1371
+ case "pattern":
1372
+ this.#a = n;
1373
+ break;
1374
+ }
1375
+ super.attributeChangedCallback?.(e, t, n);
1376
+ }
1377
+ }
1378
+ setup() {
1379
+ super.setup(), this.hasAttribute("contenteditable") || this.setAttribute("contenteditable", "plaintext-only"), this.#o = [...this.querySelectorAll(":scope > [slot]")];
1380
+ for (let e of this.#o) e.setAttribute("contenteditable", "false");
1381
+ this.#n.value = this.hasAttribute("required"), this.#a = this.getAttribute("pattern"), this.#i = this.getAttribute("value") ?? this.#s(), this.#r.value = this.#s(), this.#l(), this.addEffect(j(this, this.#t, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
1382
+ let e = this.#r.value;
1383
+ this.#n.value && e === "" ? this.#e.setValidity({ valueMissing: !0 }, "Please fill out this field.", this) : this.#a !== null && e !== "" && !RegExp(`^(?:${this.#a})$`).test(e) ? this.#e.setValidity({ patternMismatch: !0 }, "Please match the requested format.", this) : this.#e.setValidity({});
1384
+ }), this.addEventListener("input", this.#u), this.addEventListener("blur", this.#d);
1385
+ }
1386
+ teardown() {
1387
+ this.removeEventListener("input", this.#u), this.removeEventListener("blur", this.#d), super.teardown();
1388
+ }
1389
+ select() {
1390
+ let e = document.createRange();
1391
+ e.selectNodeContents(this);
1392
+ let t = window.getSelection();
1393
+ t?.removeAllRanges(), t?.addRange(e);
1394
+ }
1395
+ onFormDisabled(e) {
1396
+ this.#t.value = e, this.setAttribute("contenteditable", e || this.hasAttribute("readonly") ? "false" : "plaintext-only");
1397
+ }
1398
+ onFormReset() {
1399
+ this.#c(this.#i), this.#r.value = this.#i, this.#e.setFormValue(this.#i), this.#l(), this.#t.value = this.hasAttribute("disabled"), this.setAttribute("contenteditable", this.#t.value || this.hasAttribute("readonly") ? "false" : "plaintext-only");
1400
+ }
1401
+ onFormStateRestore(e) {
1402
+ this.value = typeof e == "string" ? e : "";
1403
+ }
1404
+ #l() {
1405
+ this.#s().trim() === "" ? this.#e.states.add("empty") : this.#e.states.delete("empty");
1406
+ }
1407
+ #u = () => {
1408
+ for (let e of this.#o) e.parentNode || this.appendChild(e);
1409
+ let e = this.#s();
1410
+ this.#r.value = e, this.#e.setFormValue(e), this.#l(), this.dispatchEvent(new CustomEvent("ui-input", {
1411
+ bubbles: !0,
1412
+ composed: !0,
1413
+ detail: { value: e }
1414
+ }));
1415
+ };
1416
+ #d = () => {
1417
+ this.dispatchEvent(new CustomEvent("ui-change", {
1418
+ bubbles: !0,
1419
+ composed: !0,
1420
+ detail: { value: this.#s() }
1421
+ }));
1422
+ };
1423
+ }, le = class extends k {
1424
+ static observedAttributes = [
1425
+ "disabled",
1426
+ "multiple",
1427
+ "virtual-focus"
1428
+ ];
1429
+ #e;
1430
+ #t;
1431
+ #n = _(!1);
1432
+ #r = new z();
1433
+ #i;
1434
+ constructor() {
1435
+ super(), this.#e = this.attachInternals(), this.#e.role = "listbox", this.#t = M(this, "disabled", { type: "boolean" });
1436
+ }
1437
+ get virtualFocus() {
1438
+ return this.hasAttribute("virtual-focus");
1439
+ }
1440
+ set virtualFocus(e) {
1441
+ this.toggleAttribute("virtual-focus", e);
1442
+ }
1443
+ get disabled() {
1444
+ return this.#t.value;
1445
+ }
1446
+ set disabled(e) {
1447
+ this.#t.set(e);
1448
+ }
1449
+ get multiple() {
1450
+ return this.#n.value;
1451
+ }
1452
+ set multiple(e) {
1453
+ this.#n.value = e, this.#r.multiple = e, this.toggleAttribute("multiple", e);
1454
+ }
1455
+ get value() {
1456
+ return this.#r.value.value;
1457
+ }
1458
+ get controller() {
1459
+ return this.#r;
1460
+ }
1461
+ get listValue() {
1462
+ return this.#i.listValue;
1463
+ }
1464
+ attributeChangedCallback(e, t, n) {
1465
+ if (t !== n) {
1466
+ if (N({ disabled: this.#t }, e, n)) {
1467
+ super.attributeChangedCallback?.(e, t, n);
1468
+ return;
1469
+ }
1470
+ switch (e) {
1471
+ case "multiple":
1472
+ this.#n.value = n !== null, this.#r.multiple = n !== null;
1473
+ break;
1474
+ case "virtual-focus":
1475
+ this.#i && (this.#i.rovingFocus.disabled = n !== null);
1476
+ break;
1477
+ }
1478
+ super.attributeChangedCallback?.(e, t, n);
1479
+ }
1480
+ }
1481
+ setup() {
1482
+ super.setup(), this.#i = new J(this, {
1483
+ itemSelector: ":scope ui-option:not([disabled])",
1484
+ autoSync: !1,
1485
+ orientation: "vertical",
1486
+ disabled: this.virtualFocus,
1487
+ onChildSelect: (e) => {
1488
+ this.#n.value ? this.#r.toggle(e.value) : this.#r.select(e.value), this.dispatchEvent(new CustomEvent("ui-change", {
1489
+ bubbles: !0,
1490
+ composed: !0,
1491
+ cancelable: !0,
1492
+ detail: e
1493
+ }));
1494
+ },
1495
+ addEffect: (e) => this.addEffect(e),
1496
+ deferChildren: (e) => this.deferChildren(e)
1497
+ }), this.addEffect(j(this, this.#t.signal, this.#e)), this.deferChildren(() => {
1498
+ this.addEffect(() => {
1499
+ let e = this.#r.value.value, t = this.#r.selected.value, n = this.#n.value, r = this.querySelectorAll(":scope ui-option");
1500
+ for (let i of r) {
1501
+ let r = i.getAttribute("value") ?? "", a = n ? t.has(r) : r === e;
1502
+ i.setAttribute("aria-selected", a ? "true" : "false");
1503
+ }
1504
+ }), this.addEffect(() => {
1505
+ let e = this.#r.activeIndex.value, t = this.querySelectorAll(":scope ui-option:not([disabled])");
1506
+ for (let n = 0; n < t.length; n++) {
1507
+ let r = t[n], i = n === e;
1508
+ r.toggleAttribute("active", i), i && (r.id ||= A("opt"), this.setAttribute("aria-activedescendant", r.id));
1509
+ }
1510
+ (e < 0 || e >= t.length) && this.removeAttribute("aria-activedescendant");
1511
+ });
1512
+ });
1513
+ }
1514
+ teardown() {
1515
+ this.#i.destroy(), super.teardown();
58
1516
  }
59
- set name(e) {
60
- this.setAttribute("name", e);
1517
+ getActiveOption() {
1518
+ let e = this.#r.activeIndex.value;
1519
+ return this.querySelectorAll(":scope ui-option:not([disabled])")[e] ?? null;
61
1520
  }
62
- get disabled() {
1521
+ }, ue = class extends k {
1522
+ static observedAttributes = [
1523
+ "value",
1524
+ "disabled",
1525
+ "label"
1526
+ ];
1527
+ #e;
1528
+ #t = _("");
1529
+ #n;
1530
+ #r = _("");
1531
+ constructor() {
1532
+ super(), this.#e = this.attachInternals(), this.#e.role = "option", this.#n = M(this, "disabled", { type: "boolean" });
1533
+ }
1534
+ get value() {
63
1535
  return this.#t.value;
64
1536
  }
65
- set disabled(e) {
66
- this.#t.value = e, this.toggleAttribute("disabled", e);
1537
+ set value(e) {
1538
+ this.#t.value = e, this.getAttribute("value") !== e && this.setAttribute("value", e);
67
1539
  }
68
- get readOnly() {
69
- return this.hasAttribute("readonly");
1540
+ get disabled() {
1541
+ return this.#n.value;
70
1542
  }
71
- set readOnly(e) {
72
- this.toggleAttribute("readonly", e), this.setAttribute("contenteditable", e ? "false" : "plaintext-only");
1543
+ set disabled(e) {
1544
+ this.#n.set(e);
73
1545
  }
74
- get required() {
75
- return this.#n.value;
1546
+ get label() {
1547
+ return this.#r.value || this.textContent?.trim() || "";
76
1548
  }
77
- set required(e) {
78
- this.#n.value = e, this.toggleAttribute("required", e);
1549
+ set label(e) {
1550
+ this.#r.value = e, e ? this.getAttribute("label") !== e && this.setAttribute("label", e) : this.removeAttribute("label");
79
1551
  }
80
1552
  attributeChangedCallback(e, t, n) {
81
1553
  if (t !== n) {
1554
+ if (N({ disabled: this.#n }, e, n)) {
1555
+ super.attributeChangedCallback?.(e, t, n);
1556
+ return;
1557
+ }
82
1558
  switch (e) {
83
1559
  case "value":
84
- this.#c(n ?? ""), this.#r.value = n ?? "", this.#e.setFormValue(n ?? ""), this.#l();
85
- break;
86
- case "disabled":
87
- this.#t.value = n !== null, this.setAttribute("contenteditable", n !== null || this.hasAttribute("readonly") ? "false" : "plaintext-only");
88
- break;
89
- case "readonly":
90
- this.setAttribute("contenteditable", n !== null || this.#t.value ? "false" : "plaintext-only");
91
- break;
92
- case "required":
93
- this.#n.value = n !== null;
1560
+ this.#t.value = n ?? "";
94
1561
  break;
95
- case "pattern":
96
- this.#a = n;
1562
+ case "label":
1563
+ this.#r.value = n ?? "";
97
1564
  break;
98
1565
  }
99
1566
  super.attributeChangedCallback?.(e, t, n);
100
1567
  }
101
1568
  }
102
1569
  setup() {
103
- super.setup(), this.hasAttribute("contenteditable") || this.setAttribute("contenteditable", "plaintext-only"), this.#o = [...this.querySelectorAll(":scope > [slot]")];
104
- for (let e of this.#o) e.setAttribute("contenteditable", "false");
105
- this.#n.value = this.hasAttribute("required"), this.#a = this.getAttribute("pattern"), this.#i = this.getAttribute("value") ?? this.#s(), this.#r.value = this.#s(), this.#l(), this.addEffect(w(this, this.#t, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
106
- let e = this.#r.value;
107
- this.#n.value && e === "" ? this.#e.setValidity({ valueMissing: !0 }, "Please fill out this field.", this) : this.#a !== null && e !== "" && !RegExp(`^(?:${this.#a})$`).test(e) ? this.#e.setValidity({ patternMismatch: !0 }, "Please match the requested format.", this) : this.#e.setValidity({});
108
- }), this.addEventListener("input", this.#u), this.addEventListener("blur", this.#d);
1570
+ super.setup(), this.addEffect(j(this, this.#n.signal, this.#e)), this.addEventListener("click", this.#i);
109
1571
  }
110
1572
  teardown() {
111
- this.removeEventListener("input", this.#u), this.removeEventListener("blur", this.#d), super.teardown();
112
- }
113
- select() {
114
- let e = document.createRange();
115
- e.selectNodeContents(this);
116
- let t = window.getSelection();
117
- t?.removeAllRanges(), t?.addRange(e);
118
- }
119
- onFormDisabled(e) {
120
- this.#t.value = e, this.setAttribute("contenteditable", e || this.hasAttribute("readonly") ? "false" : "plaintext-only");
121
- }
122
- onFormReset() {
123
- this.#c(this.#i), this.#r.value = this.#i, this.#e.setFormValue(this.#i), this.#l(), this.#t.value = this.hasAttribute("disabled"), this.setAttribute("contenteditable", this.#t.value || this.hasAttribute("readonly") ? "false" : "plaintext-only");
124
- }
125
- onFormStateRestore(e) {
126
- this.value = typeof e == "string" ? e : "";
127
- }
128
- #l() {
129
- this.#s().trim() === "" ? this.#e.states.add("empty") : this.#e.states.delete("empty");
1573
+ this.removeEventListener("click", this.#i), super.teardown();
130
1574
  }
131
- #u = () => {
132
- for (let e of this.#o) e.parentNode || this.appendChild(e);
133
- let e = this.#s();
134
- this.#r.value = e, this.#e.setFormValue(e), this.#l(), this.dispatchEvent(new CustomEvent("ui-input", {
135
- bubbles: !0,
136
- composed: !0,
137
- detail: { value: e }
138
- }));
139
- };
140
- #d = () => {
141
- this.dispatchEvent(new CustomEvent("ui-change", {
1575
+ #i = () => {
1576
+ this.disabled || this.dispatchEvent(new CustomEvent("ui-select", {
142
1577
  bubbles: !0,
143
1578
  composed: !0,
144
- detail: { value: this.#s() }
1579
+ detail: {
1580
+ value: this.#t.value,
1581
+ label: this.label
1582
+ }
145
1583
  }));
146
1584
  };
147
- }, te = class extends _ {
1585
+ }, de = class extends k {
148
1586
  constructor() {
149
1587
  super();
150
1588
  let e = this.attachInternals();
151
1589
  e.role = "presentation";
152
1590
  }
153
1591
  setup() {
154
- super.setup(), this.id ||= r("ogh");
1592
+ super.setup(), this.id ||= A("ogh");
155
1593
  let e = this.closest("ui-option-group");
156
1594
  e && e.setAttribute("aria-labelledby", this.id);
157
1595
  }
158
- }, ne = class extends _ {
1596
+ }, fe = class extends k {
159
1597
  constructor() {
160
1598
  super();
161
1599
  let e = this.attachInternals();
162
1600
  e.role = "group";
163
1601
  }
164
- }, re = class extends _ {
1602
+ }, pe = class extends k {
165
1603
  static observedAttributes = ["disabled"];
166
1604
  #e;
167
- #t = new C({ initialActiveIndex: 0 });
168
- #n = t(!1);
1605
+ #t = new z({ initialActiveIndex: 0 });
1606
+ #n = _(!1);
169
1607
  constructor() {
170
1608
  super(), this.#e = this.attachInternals(), this.#e.role = "search";
171
1609
  }
@@ -182,7 +1620,7 @@ var ee = class extends S(_) {
182
1620
  t !== n && (e === "disabled" && (this.#n.value = n !== null), super.attributeChangedCallback?.(e, t, n));
183
1621
  }
184
1622
  setup() {
185
- super.setup(), this.addEffect(w(this, this.#n, this.#e)), this.addEventListener("ui-input", this.#i), this.addEventListener("ui-select", this.#a), this.addEventListener("keydown", this.#o), this.deferChildren(() => {
1623
+ super.setup(), this.addEffect(j(this, this.#n, this.#e)), this.addEventListener("ui-input", this.#i), this.addEventListener("ui-select", this.#a), this.addEventListener("keydown", this.#o), this.deferChildren(() => {
186
1624
  this.addEffect(() => {
187
1625
  let e = this.#t.query.value.toLowerCase().trim(), t = this.querySelectorAll("ui-command-item");
188
1626
  for (let n of t) {
@@ -193,8 +1631,8 @@ var ee = class extends S(_) {
193
1631
  this.#t.query.value;
194
1632
  let e = this.#t.activeIndex.value, t = this.#r(), n = this.querySelector("ui-command-list");
195
1633
  for (let n = 0; n < t.length; n++) t[n].toggleAttribute("active", n === e);
196
- let i = t[e];
197
- i && n ? (i.id ||= r("cmd"), n.setAttribute("aria-activedescendant", i.id), i.scrollIntoView({ block: "nearest" })) : n?.removeAttribute("aria-activedescendant");
1634
+ let r = t[e];
1635
+ r && n ? (r.id ||= A("cmd"), n.setAttribute("aria-activedescendant", r.id), r.scrollIntoView({ block: "nearest" })) : n?.removeAttribute("aria-activedescendant");
198
1636
  }), this.addEffect(() => {
199
1637
  this.#t.query.value;
200
1638
  let e = this.#r(), t = this.querySelector("ui-command-empty");
@@ -252,7 +1690,7 @@ var ee = class extends S(_) {
252
1690
  break;
253
1691
  }
254
1692
  };
255
- }, ie = class extends _ {
1693
+ }, me = class extends k {
256
1694
  #e = null;
257
1695
  setup() {
258
1696
  super.setup(), this.deferChildren(() => {
@@ -279,22 +1717,22 @@ var ee = class extends S(_) {
279
1717
  detail: { value: e }
280
1718
  }));
281
1719
  };
282
- }, T = class extends _ {
1720
+ }, he = class extends k {
283
1721
  constructor() {
284
1722
  super();
285
1723
  let e = this.attachInternals();
286
1724
  e.role = "listbox";
287
1725
  }
288
- }, E = class extends _ {
1726
+ }, ge = class extends k {
289
1727
  static observedAttributes = [
290
1728
  "value",
291
1729
  "disabled",
292
1730
  "keywords"
293
1731
  ];
294
1732
  #e;
295
- #t = t("");
296
- #n = t(!1);
297
- #r = t("");
1733
+ #t = _("");
1734
+ #n = _(!1);
1735
+ #r = _("");
298
1736
  constructor() {
299
1737
  super(), this.#e = this.attachInternals(), this.#e.role = "option";
300
1738
  }
@@ -339,7 +1777,7 @@ var ee = class extends S(_) {
339
1777
  }
340
1778
  }
341
1779
  setup() {
342
- super.setup(), this.addEffect(w(this, this.#n, this.#e)), this.addEventListener("click", this.#i);
1780
+ super.setup(), this.addEffect(j(this, this.#n, this.#e)), this.addEventListener("click", this.#i);
343
1781
  }
344
1782
  teardown() {
345
1783
  this.removeEventListener("click", this.#i), super.teardown();
@@ -354,7 +1792,7 @@ var ee = class extends S(_) {
354
1792
  }
355
1793
  }));
356
1794
  };
357
- }, D = class extends _ {
1795
+ }, _e = class extends k {
358
1796
  constructor() {
359
1797
  super();
360
1798
  let e = this.attachInternals();
@@ -363,9 +1801,9 @@ var ee = class extends S(_) {
363
1801
  setup() {
364
1802
  super.setup();
365
1803
  let e = this.querySelector("[slot=\"heading\"]");
366
- e && (e.id ||= r("cg"), this.setAttribute("aria-labelledby", e.id));
1804
+ e && (e.id ||= A("cg"), this.setAttribute("aria-labelledby", e.id));
367
1805
  }
368
- }, O = class extends _ {}, k = class extends S(_) {
1806
+ }, ve = class extends k {}, ye = class extends P(k) {
369
1807
  static observedAttributes = [
370
1808
  "checked",
371
1809
  "indeterminate",
@@ -378,11 +1816,11 @@ var ee = class extends S(_) {
378
1816
  #t;
379
1817
  #n;
380
1818
  #r;
381
- #i = t(!1);
1819
+ #i = _(!1);
382
1820
  #a = !1;
383
1821
  #o;
384
1822
  constructor() {
385
- super(), this.#e = this.attachInternals(), this.#e.role = "checkbox", this.#t = x(this, "checked", { type: "boolean" }), this.#n = x(this, "indeterminate", { type: "boolean" }), this.#r = x(this, "disabled", { type: "boolean" });
1823
+ super(), this.#e = this.attachInternals(), this.#e.role = "checkbox", this.#t = M(this, "checked", { type: "boolean" }), this.#n = M(this, "indeterminate", { type: "boolean" }), this.#r = M(this, "disabled", { type: "boolean" });
386
1824
  }
387
1825
  get checked() {
388
1826
  return this.#t.value;
@@ -422,7 +1860,7 @@ var ee = class extends S(_) {
422
1860
  }
423
1861
  attributeChangedCallback(e, t, n) {
424
1862
  if (t !== n) {
425
- if (v({
1863
+ if (N({
426
1864
  checked: this.#t,
427
1865
  indeterminate: this.#n,
428
1866
  disabled: this.#r
@@ -434,7 +1872,7 @@ var ee = class extends S(_) {
434
1872
  }
435
1873
  }
436
1874
  setup() {
437
- super.setup(), this.#o = new c(this, { disabled: () => this.disabled }), this.#a = this.hasAttribute("checked"), this.#i.value = this.hasAttribute("required"), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEffect(w(this, this.#r.signal, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
1875
+ super.setup(), this.#o = new W(this, { disabled: () => this.disabled }), this.#a = this.hasAttribute("checked"), this.#i.value = this.hasAttribute("required"), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEffect(j(this, this.#r.signal, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
438
1876
  let e = this.#t.value, t = this.#n.value ? "mixed" : e ? "true" : "false";
439
1877
  this.setAttribute("aria-checked", t), this.#e.setFormValue(e ? this.value : null);
440
1878
  }), this.addEffect(() => {
@@ -465,7 +1903,7 @@ var ee = class extends S(_) {
465
1903
  }
466
1904
  })));
467
1905
  };
468
- }, A = class extends S(_) {
1906
+ }, be = class extends P(k) {
469
1907
  static observedAttributes = [
470
1908
  "checked",
471
1909
  "disabled",
@@ -480,7 +1918,7 @@ var ee = class extends S(_) {
480
1918
  #i = !1;
481
1919
  #a;
482
1920
  constructor() {
483
- super(), this.#e = this.attachInternals(), this.#e.role = "switch", this.#t = x(this, "checked", { type: "boolean" }), this.#n = x(this, "disabled", { type: "boolean" }), this.#r = x(this, "required", { type: "boolean" });
1921
+ super(), this.#e = this.attachInternals(), this.#e.role = "switch", this.#t = M(this, "checked", { type: "boolean" }), this.#n = M(this, "disabled", { type: "boolean" }), this.#r = M(this, "required", { type: "boolean" });
484
1922
  }
485
1923
  get checked() {
486
1924
  return this.#t.value;
@@ -513,14 +1951,14 @@ var ee = class extends S(_) {
513
1951
  this.#r.set(e);
514
1952
  }
515
1953
  attributeChangedCallback(e, t, n) {
516
- t !== n && (v({
1954
+ t !== n && (N({
517
1955
  checked: this.#t,
518
1956
  disabled: this.#n,
519
1957
  required: this.#r
520
1958
  }, e, n), super.attributeChangedCallback?.(e, t, n));
521
1959
  }
522
1960
  setup() {
523
- super.setup(), this.#a = new c(this, { disabled: () => this.disabled }), this.#i = this.hasAttribute("checked"), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEffect(w(this, this.#n.signal, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
1961
+ super.setup(), this.#a = new W(this, { disabled: () => this.disabled }), this.#i = this.hasAttribute("checked"), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEffect(j(this, this.#n.signal, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
524
1962
  let e = this.#t.value;
525
1963
  this.setAttribute("aria-checked", e ? "true" : "false"), this.#e.setFormValue(e ? this.value : null);
526
1964
  }), this.addEffect(() => {
@@ -549,13 +1987,13 @@ var ee = class extends S(_) {
549
1987
  }
550
1988
  })));
551
1989
  };
552
- }, j = class extends _ {
1990
+ }, xe = class extends k {
553
1991
  static observedAttributes = ["disabled"];
554
1992
  #e;
555
1993
  #t;
556
1994
  #n;
557
1995
  constructor() {
558
- super(), this.#e = this.attachInternals(), this.#e.role = "radio", this.#t = x(this, "disabled", { type: "boolean" });
1996
+ super(), this.#e = this.attachInternals(), this.#e.role = "radio", this.#t = M(this, "disabled", { type: "boolean" });
559
1997
  }
560
1998
  get value() {
561
1999
  return this.getAttribute("value") ?? "";
@@ -573,10 +2011,10 @@ var ee = class extends S(_) {
573
2011
  return this.getAttribute("label") ?? this.textContent?.trim() ?? "";
574
2012
  }
575
2013
  attributeChangedCallback(e, t, n) {
576
- t !== n && (v({ disabled: this.#t }, e, n), super.attributeChangedCallback?.(e, t, n));
2014
+ t !== n && (N({ disabled: this.#t }, e, n), super.attributeChangedCallback?.(e, t, n));
577
2015
  }
578
2016
  setup() {
579
- super.setup(), this.setAttribute("aria-checked", "false"), this.#n = new c(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1"), this.addEffect(w(this, this.#t.signal, this.#e)), this.addEventListener("click", this.#r), this.addEventListener("keydown", this.#i);
2017
+ super.setup(), this.setAttribute("aria-checked", "false"), this.#n = new W(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1"), this.addEffect(j(this, this.#t.signal, this.#e)), this.addEventListener("click", this.#r), this.addEventListener("keydown", this.#i);
580
2018
  }
581
2019
  teardown() {
582
2020
  this.removeEventListener("click", this.#r), this.removeEventListener("keydown", this.#i), this.#n.destroy(), super.teardown();
@@ -601,7 +2039,7 @@ var ee = class extends S(_) {
601
2039
  }
602
2040
  })));
603
2041
  };
604
- }, M = class extends S(_) {
2042
+ }, Se = class extends P(k) {
605
2043
  static observedAttributes = [
606
2044
  "value",
607
2045
  "disabled",
@@ -610,8 +2048,8 @@ var ee = class extends S(_) {
610
2048
  "orientation"
611
2049
  ];
612
2050
  #e;
613
- #t = t(!1);
614
- #n = t(!1);
2051
+ #t = _(!1);
2052
+ #n = _(!1);
615
2053
  #r = null;
616
2054
  #i;
617
2055
  constructor() {
@@ -661,7 +2099,7 @@ var ee = class extends S(_) {
661
2099
  }
662
2100
  }
663
2101
  setup() {
664
- super.setup(), this.#r = this.getAttribute("value"), this.#n.value = this.hasAttribute("required"), this.#i = new g(this, {
2102
+ super.setup(), this.#r = this.getAttribute("value"), this.#n.value = this.hasAttribute("required"), this.#i = new J(this, {
665
2103
  itemSelector: ":scope ui-radio:not([disabled])",
666
2104
  ariaAttr: "aria-checked",
667
2105
  orientation: "vertical",
@@ -676,7 +2114,7 @@ var ee = class extends S(_) {
676
2114
  deferChildren: (e) => this.deferChildren(e)
677
2115
  });
678
2116
  let e = this.getAttribute("value");
679
- e !== null && (this.#i.listValue.value = e), this.addEffect(w(this, this.#t, this.#e)), this.addEffect(() => {
2117
+ e !== null && (this.#i.listValue.value = e), this.addEffect(j(this, this.#t, this.#e)), this.addEffect(() => {
680
2118
  let e = this.#t.value, t = this.querySelectorAll("ui-radio");
681
2119
  for (let n of t) n.toggleAttribute("disabled", e);
682
2120
  }), this.addEffect(() => {
@@ -701,7 +2139,7 @@ var ee = class extends S(_) {
701
2139
  onFormStateRestore(e) {
702
2140
  typeof e == "string" && e && (this.value = e);
703
2141
  }
704
- }, N = class extends S(_) {
2142
+ }, Ce = class extends P(k) {
705
2143
  static observedAttributes = [
706
2144
  "value",
707
2145
  "disabled",
@@ -709,8 +2147,8 @@ var ee = class extends S(_) {
709
2147
  "required"
710
2148
  ];
711
2149
  #e;
712
- #t = t(!1);
713
- #n = t(!1);
2150
+ #t = _(!1);
2151
+ #n = _(!1);
714
2152
  #r = null;
715
2153
  #i;
716
2154
  constructor() {
@@ -757,7 +2195,7 @@ var ee = class extends S(_) {
757
2195
  }
758
2196
  }
759
2197
  setup() {
760
- super.setup(), this.#r = this.getAttribute("value"), this.#i = new g(this, {
2198
+ super.setup(), this.#r = this.getAttribute("value"), this.#i = new J(this, {
761
2199
  itemSelector: ":scope > ui-segment:not([disabled])",
762
2200
  ariaAttr: "aria-checked",
763
2201
  orientation: "horizontal",
@@ -772,7 +2210,7 @@ var ee = class extends S(_) {
772
2210
  deferChildren: (e) => this.deferChildren(e)
773
2211
  });
774
2212
  let e = this.getAttribute("value");
775
- e !== null && (this.#i.listValue.value = e), this.addEffect(w(this, this.#t, this.#e)), this.#n.value = this.hasAttribute("required"), this.addEffect(() => {
2213
+ e !== null && (this.#i.listValue.value = e), this.addEffect(j(this, this.#t, this.#e)), this.#n.value = this.hasAttribute("required"), this.addEffect(() => {
776
2214
  let e = this.#i.listValue.value;
777
2215
  this.#n.value && (e === null || e === "") ? this.#e.setValidity({ valueMissing: !0 }, "Please select one of these options.", this) : this.#e.setValidity({});
778
2216
  }), this.addEffect(() => {
@@ -805,13 +2243,13 @@ var ee = class extends S(_) {
805
2243
  }
806
2244
  this.style.setProperty("--_indicator-index", `${e}`), this.style.setProperty("--_segment-count", `${t}`), this.#e.states.add("ready");
807
2245
  }
808
- }, P = class extends _ {
2246
+ }, we = class extends k {
809
2247
  static observedAttributes = ["disabled"];
810
2248
  #e;
811
2249
  #t;
812
2250
  #n;
813
2251
  constructor() {
814
- super(), this.#e = this.attachInternals(), this.#e.role = "radio", this.#t = x(this, "disabled", { type: "boolean" }), this.setAttribute("aria-checked", "false");
2252
+ super(), this.#e = this.attachInternals(), this.#e.role = "radio", this.#t = M(this, "disabled", { type: "boolean" }), this.setAttribute("aria-checked", "false");
815
2253
  }
816
2254
  get value() {
817
2255
  return this.getAttribute("value") ?? "";
@@ -829,10 +2267,10 @@ var ee = class extends S(_) {
829
2267
  return this.getAttribute("label") ?? this.textContent?.trim() ?? "";
830
2268
  }
831
2269
  attributeChangedCallback(e, t, n) {
832
- t !== n && (v({ disabled: this.#t }, e, n), super.attributeChangedCallback?.(e, t, n));
2270
+ t !== n && (N({ disabled: this.#t }, e, n), super.attributeChangedCallback?.(e, t, n));
833
2271
  }
834
2272
  setup() {
835
- super.setup(), this.#n = new c(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1"), this.addEffect(w(this, this.#t.signal, this.#e)), this.addEventListener("ui-press", this.#r);
2273
+ super.setup(), this.#n = new W(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1"), this.addEffect(j(this, this.#t.signal, this.#e)), this.addEventListener("ui-press", this.#r);
836
2274
  }
837
2275
  teardown() {
838
2276
  this.removeEventListener("ui-press", this.#r), this.#n.destroy(), super.teardown();
@@ -847,15 +2285,15 @@ var ee = class extends S(_) {
847
2285
  }
848
2286
  }));
849
2287
  };
850
- }, F = class extends _ {
2288
+ }, Te = class extends k {
851
2289
  static observedAttributes = [
852
2290
  "placement",
853
2291
  "delay",
854
2292
  "disabled"
855
2293
  ];
856
2294
  #e;
857
- #t = t(!1);
858
- #n = t(!1);
2295
+ #t = _(!1);
2296
+ #n = _(!1);
859
2297
  #r = null;
860
2298
  #i = null;
861
2299
  #a = "";
@@ -884,7 +2322,7 @@ var ee = class extends S(_) {
884
2322
  t !== n && (e === "disabled" && (this.#n.value = n !== null), super.attributeChangedCallback?.(e, t, n));
885
2323
  }
886
2324
  setup() {
887
- super.setup(), this.addEffect(w(this, this.#n, this.#e)), this.#i = this.parentElement, this.#i && (this.#a = r("tip"), this.#i.style.setProperty("anchor-name", `--${this.#a}`), this.style.setProperty("position-anchor", `--${this.#a}`), this.hasAttribute("popover") || this.setAttribute("popover", "manual"), this.id ||= r("tooltip"), this.#i.setAttribute("aria-describedby", this.id), this.#i.addEventListener("mouseenter", this.#o), this.#i.addEventListener("mouseleave", this.#s), this.#i.addEventListener("focusin", this.#o), this.#i.addEventListener("focusout", this.#s), this.#i.addEventListener("keydown", this.#c), this.addEffect(() => {
2325
+ super.setup(), this.addEffect(j(this, this.#n, this.#e)), this.#i = this.parentElement, this.#i && (this.#a = A("tip"), this.#i.style.setProperty("anchor-name", `--${this.#a}`), this.style.setProperty("position-anchor", `--${this.#a}`), this.hasAttribute("popover") || this.setAttribute("popover", "manual"), this.id ||= A("tooltip"), this.#i.setAttribute("aria-describedby", this.id), this.#i.addEventListener("mouseenter", this.#o), this.#i.addEventListener("mouseleave", this.#s), this.#i.addEventListener("focusin", this.#o), this.#i.addEventListener("focusout", this.#s), this.#i.addEventListener("keydown", this.#c), this.addEffect(() => {
888
2326
  this.#n.value && this.#t.value && (this.#l(), this.#t.value = !1);
889
2327
  }), this.addEffect(() => {
890
2328
  if (this.#t.value) try {
@@ -912,9 +2350,9 @@ var ee = class extends S(_) {
912
2350
  #l() {
913
2351
  this.#r !== null && (clearTimeout(this.#r), this.#r = null);
914
2352
  }
915
- }, I = class extends _ {
2353
+ }, Ee = class extends k {
916
2354
  static observedAttributes = ["multiple", "disabled"];
917
- #e = t(!1);
2355
+ #e = _(!1);
918
2356
  get multiple() {
919
2357
  return this.hasAttribute("multiple");
920
2358
  }
@@ -944,7 +2382,7 @@ var ee = class extends S(_) {
944
2382
  }
945
2383
  }
946
2384
  setup() {
947
- super.setup(), this.addEffect(w(this, this.#e)), this.addEventListener("toggle", this.#t, !0);
2385
+ super.setup(), this.addEffect(j(this, this.#e)), this.addEventListener("toggle", this.#t, !0);
948
2386
  }
949
2387
  teardown() {
950
2388
  this.removeEventListener("toggle", this.#t, !0), super.teardown();
@@ -958,10 +2396,10 @@ var ee = class extends S(_) {
958
2396
  let r = this.querySelectorAll(":scope > ui-accordion-item[open]");
959
2397
  for (let e of r) e !== n && (e.open = !1);
960
2398
  };
961
- }, L = class extends _ {
2399
+ }, De = class extends k {
962
2400
  static observedAttributes = ["open", "disabled"];
963
- #e = t(!1);
964
- #t = t(!1);
2401
+ #e = _(!1);
2402
+ #t = _(!1);
965
2403
  #n = null;
966
2404
  get open() {
967
2405
  return this.#e.value;
@@ -997,7 +2435,7 @@ var ee = class extends S(_) {
997
2435
  e.appendChild(t), e.appendChild(r), this.appendChild(e), this.#n = e, this.addEffect(() => {
998
2436
  let e = this.#e.value;
999
2437
  this.#n && (this.#n.open = e);
1000
- }), this.addEffect(w(this, this.#t)), e.addEventListener("toggle", this.#r);
2438
+ }), this.addEffect(j(this, this.#t)), e.addEventListener("toggle", this.#r);
1001
2439
  }
1002
2440
  teardown() {
1003
2441
  this.#n?.removeEventListener("toggle", this.#r), this.#n = null, super.teardown();
@@ -1007,7 +2445,7 @@ var ee = class extends S(_) {
1007
2445
  let e = this.#n.open;
1008
2446
  this.#e.value = e, this.toggleAttribute("open", e);
1009
2447
  };
1010
- }, R = class extends _ {
2448
+ }, Oe = class extends k {
1011
2449
  #e;
1012
2450
  get open() {
1013
2451
  return this.#e.open;
@@ -1019,19 +2457,19 @@ var ee = class extends S(_) {
1019
2457
  this.#e.close();
1020
2458
  }
1021
2459
  setup() {
1022
- super.setup(), this.#e = new s(this);
2460
+ super.setup(), this.#e = new Y(this);
1023
2461
  }
1024
2462
  teardown() {
1025
2463
  this.#e.destroy(), super.teardown();
1026
2464
  }
1027
- }, z = class extends _ {
2465
+ }, ke = class extends k {
1028
2466
  static observedAttributes = [
1029
2467
  "value",
1030
2468
  "disabled",
1031
2469
  "orientation"
1032
2470
  ];
1033
2471
  #e;
1034
- #t = t(!1);
2472
+ #t = _(!1);
1035
2473
  #n;
1036
2474
  constructor() {
1037
2475
  super(), this.#e = this.attachInternals(), this.#e.role = "tablist";
@@ -1065,7 +2503,7 @@ var ee = class extends S(_) {
1065
2503
  }
1066
2504
  }
1067
2505
  setup() {
1068
- super.setup(), this.#n = new g(this, {
2506
+ super.setup(), this.#n = new J(this, {
1069
2507
  itemSelector: ":scope > ui-tab:not([disabled])",
1070
2508
  orientation: "horizontal",
1071
2509
  autoSync: !0,
@@ -1080,7 +2518,7 @@ var ee = class extends S(_) {
1080
2518
  deferChildren: (e) => this.deferChildren(e)
1081
2519
  });
1082
2520
  let e = this.getAttribute("value");
1083
- e !== null && (this.#n.listValue.value = e), this.hasAttribute("aria-label") || this.setAttribute("aria-label", "Tabs"), this.addEffect(w(this, this.#t, this.#e)), this.addEffect(() => {
2521
+ e !== null && (this.#n.listValue.value = e), this.hasAttribute("aria-label") || this.setAttribute("aria-label", "Tabs"), this.addEffect(j(this, this.#t, this.#e)), this.addEffect(() => {
1084
2522
  let e = this.#t.value, t = this.querySelectorAll(":scope > ui-tab");
1085
2523
  for (let n of t) n.toggleAttribute("disabled", e);
1086
2524
  }), this.deferChildren(() => {
@@ -1100,9 +2538,9 @@ var ee = class extends S(_) {
1100
2538
  }
1101
2539
  #r() {
1102
2540
  let e = this.querySelectorAll(":scope > ui-tab"), t = this.querySelectorAll(":scope > ui-tab-panels > ui-tab-panel"), n = /* @__PURE__ */ new Map();
1103
- for (let e of t) e.id ||= r("tp"), n.set(e.getAttribute("value") ?? "", e);
2541
+ for (let e of t) e.id ||= A("tp"), n.set(e.getAttribute("value") ?? "", e);
1104
2542
  for (let t of e) {
1105
- t.id ||= r("tab");
2543
+ t.id ||= A("tab");
1106
2544
  let e = n.get(t.getAttribute("value") ?? "");
1107
2545
  e && (t.setAttribute("aria-controls", e.id), e.setAttribute("aria-labelledby", t.id));
1108
2546
  }
@@ -1114,13 +2552,13 @@ var ee = class extends S(_) {
1114
2552
  }
1115
2553
  this.style.setProperty("--_indicator-index", `${e}`), this.style.setProperty("--_tab-count", `${t}`), this.#e.states.add("ready");
1116
2554
  }
1117
- }, B = class extends _ {
2555
+ }, Ae = class extends k {
1118
2556
  static observedAttributes = ["disabled"];
1119
2557
  #e;
1120
2558
  #t;
1121
2559
  #n;
1122
2560
  constructor() {
1123
- super(), this.#e = this.attachInternals(), this.#e.role = "tab", this.#t = x(this, "disabled", { type: "boolean" });
2561
+ super(), this.#e = this.attachInternals(), this.#e.role = "tab", this.#t = M(this, "disabled", { type: "boolean" });
1124
2562
  }
1125
2563
  get value() {
1126
2564
  return this.getAttribute("value") ?? "";
@@ -1138,10 +2576,10 @@ var ee = class extends S(_) {
1138
2576
  return this.getAttribute("label") ?? this.textContent?.trim() ?? "";
1139
2577
  }
1140
2578
  attributeChangedCallback(e, t, n) {
1141
- t !== n && (v({ disabled: this.#t }, e, n), super.attributeChangedCallback?.(e, t, n));
2579
+ t !== n && (N({ disabled: this.#t }, e, n), super.attributeChangedCallback?.(e, t, n));
1142
2580
  }
1143
2581
  setup() {
1144
- super.setup(), this.#n = new c(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1"), this.addEffect(w(this, this.#t.signal, this.#e)), this.addEventListener("ui-press", this.#r);
2582
+ super.setup(), this.#n = new W(this, { disabled: () => this.disabled }), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1"), this.addEffect(j(this, this.#t.signal, this.#e)), this.addEventListener("ui-press", this.#r);
1145
2583
  }
1146
2584
  teardown() {
1147
2585
  this.removeEventListener("ui-press", this.#r), this.#n.destroy(), super.teardown();
@@ -1156,7 +2594,7 @@ var ee = class extends S(_) {
1156
2594
  }
1157
2595
  }));
1158
2596
  };
1159
- }, V = class extends _ {
2597
+ }, je = class extends k {
1160
2598
  static observedAttributes = ["value"];
1161
2599
  #e;
1162
2600
  constructor() {
@@ -1171,21 +2609,21 @@ var ee = class extends S(_) {
1171
2609
  attributeChangedCallback(e, t, n) {
1172
2610
  t !== n && super.attributeChangedCallback?.(e, t, n);
1173
2611
  }
1174
- }, H = class extends _ {
2612
+ }, Me = class extends k {
1175
2613
  #e;
1176
2614
  constructor() {
1177
2615
  super(), this.#e = this.attachInternals(), this.#e.role = "presentation";
1178
2616
  }
1179
- }, U = class {
2617
+ }, X = class {
1180
2618
  sortColumn;
1181
2619
  sortDirection;
1182
2620
  selected;
1183
2621
  columnWidths;
1184
2622
  constructor(e = {}) {
1185
- this.sortColumn = t(e.sortColumn ?? null), this.sortDirection = t(e.sortDirection ?? "none"), this.selected = t(/* @__PURE__ */ new Set()), this.columnWidths = t([]);
2623
+ this.sortColumn = _(e.sortColumn ?? null), this.sortDirection = _(e.sortDirection ?? "none"), this.selected = _(/* @__PURE__ */ new Set()), this.columnWidths = _([]);
1186
2624
  }
1187
2625
  toggleSort(e) {
1188
- n(() => {
2626
+ b(() => {
1189
2627
  if (this.sortColumn.value === e) {
1190
2628
  let e = this.sortDirection.value;
1191
2629
  this.sortDirection.value = e === "asc" ? "desc" : e === "desc" ? "none" : "asc", this.sortDirection.value === "none" && (this.sortColumn.value = null);
@@ -1213,10 +2651,10 @@ var ee = class extends S(_) {
1213
2651
  return this.selected.value.has(e);
1214
2652
  }
1215
2653
  };
1216
- function W(e = {}) {
1217
- return new U(e);
2654
+ function Ne(e = {}) {
2655
+ return new X(e);
1218
2656
  }
1219
- var G = class {
2657
+ var Pe = class {
1220
2658
  table;
1221
2659
  #e = [];
1222
2660
  #t = -1;
@@ -1293,13 +2731,13 @@ var G = class {
1293
2731
  #m() {
1294
2732
  this.#i = !1, this.#t = -1, this.table.removeAttribute("resizing"), document.removeEventListener("pointermove", this.#u), document.removeEventListener("pointerup", this.#d), document.removeEventListener("pointercancel", this.#f), document.removeEventListener("keydown", this.#p);
1295
2733
  }
1296
- }, K = class {
2734
+ }, Fe = class {
1297
2735
  #e;
1298
2736
  #t;
1299
2737
  #n;
1300
2738
  #r = !1;
1301
2739
  constructor(e, t) {
1302
- this.#t = t, this.#n = e, this.#e = new o(e, {
2740
+ this.#t = t, this.#n = e, this.#e = new H(e, {
1303
2741
  selector: "ui-table-row:not([colspan])",
1304
2742
  axis: "vertical",
1305
2743
  mode: "slot"
@@ -1329,14 +2767,14 @@ var G = class {
1329
2767
  destroy() {
1330
2768
  this.#n.removeEventListener("ui-drag-start", this.#i), this.#n.removeEventListener("ui-drop", this.#a), this.#n.removeEventListener("click", this.#o, { capture: !0 }), this.#e.destroy();
1331
2769
  }
1332
- }, q = class extends _ {
2770
+ }, Ie = class extends k {
1333
2771
  static observedAttributes = [
1334
2772
  "selectable",
1335
2773
  "resizable",
1336
2774
  "reorderable"
1337
2775
  ];
1338
2776
  #e;
1339
- #t = new U();
2777
+ #t = new X();
1340
2778
  #n = null;
1341
2779
  #r = null;
1342
2780
  #i = null;
@@ -1394,7 +2832,7 @@ var G = class {
1394
2832
  let e = document.createElement("div");
1395
2833
  e.className = "table-resize-handle", e.setAttribute("aria-hidden", "true"), e.addEventListener("click", (e) => e.stopPropagation()), t.appendChild(e);
1396
2834
  }
1397
- this.#n = new G(this), this.#n.init();
2835
+ this.#n = new Pe(this), this.#n.init();
1398
2836
  }
1399
2837
  #o() {
1400
2838
  let e = this.querySelector(":scope > ui-table-head > ui-table-row");
@@ -1407,7 +2845,7 @@ var G = class {
1407
2845
  }
1408
2846
  #s() {
1409
2847
  let e = this.querySelector(":scope > ui-table-body");
1410
- e && (this.#i = new K(e, this));
2848
+ e && (this.#i = new Fe(e, this));
1411
2849
  }
1412
2850
  #c = (e) => {
1413
2851
  let t = e.detail;
@@ -1433,17 +2871,17 @@ var G = class {
1433
2871
  }
1434
2872
  }));
1435
2873
  };
1436
- }, J = class extends _ {
2874
+ }, Le = class extends k {
1437
2875
  #e;
1438
2876
  constructor() {
1439
2877
  super(), this.#e = this.attachInternals(), this.#e.role = "rowgroup";
1440
2878
  }
1441
- }, Y = class extends _ {
2879
+ }, Re = class extends k {
1442
2880
  #e;
1443
2881
  constructor() {
1444
2882
  super(), this.#e = this.attachInternals(), this.#e.role = "rowgroup";
1445
2883
  }
1446
- }, ae = class extends _ {
2884
+ }, ze = class extends k {
1447
2885
  static observedAttributes = ["value", "selected"];
1448
2886
  #e;
1449
2887
  constructor() {
@@ -1474,12 +2912,12 @@ var G = class {
1474
2912
  detail: { value: this.value }
1475
2913
  }));
1476
2914
  };
1477
- }, oe = class extends _ {
2915
+ }, Be = class extends k {
1478
2916
  #e;
1479
2917
  constructor() {
1480
2918
  super(), this.#e = this.attachInternals(), this.#e.role = "cell";
1481
2919
  }
1482
- }, se = class extends _ {
2920
+ }, Ve = class extends k {
1483
2921
  static observedAttributes = ["sort", "sortable"];
1484
2922
  #e;
1485
2923
  constructor() {
@@ -1524,18 +2962,18 @@ var G = class {
1524
2962
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), this.#t());
1525
2963
  };
1526
2964
  };
1527
- function X(e) {
2965
+ function Z(e) {
1528
2966
  if (!e) return null;
1529
2967
  let t = /* @__PURE__ */ new Date(e + "T00:00:00");
1530
2968
  return isNaN(t.getTime()) ? null : t;
1531
2969
  }
1532
- function ce(e) {
2970
+ function He(e) {
1533
2971
  return `${e.getFullYear()}-${String(e.getMonth() + 1).padStart(2, "0")}-${String(e.getDate()).padStart(2, "0")}`;
1534
2972
  }
1535
- function Z(e, t) {
2973
+ function Q(e, t) {
1536
2974
  return e.getFullYear() === t.getFullYear() && e.getMonth() === t.getMonth() && e.getDate() === t.getDate();
1537
2975
  }
1538
- var Q = class {
2976
+ var $ = class {
1539
2977
  view;
1540
2978
  focusedYear;
1541
2979
  focusedMonth;
@@ -1548,17 +2986,17 @@ var Q = class {
1548
2986
  months;
1549
2987
  years;
1550
2988
  title;
1551
- constructor(n = {}) {
1552
- let r = /* @__PURE__ */ new Date(), i = X(n.value ?? null) ?? r;
1553
- this.view = t("day"), this.focusedYear = t(i.getFullYear()), this.focusedMonth = t(i.getMonth()), this.value = t(n.value ?? null), this.rangeStart = t(n.rangeStart ?? null), this.rangeEnd = t(n.rangeEnd ?? null), this.min = t(n.min ?? null), this.max = t(n.max ?? null), this.days = e(() => this.#e()), this.months = e(() => this.#t()), this.years = e(() => this.#n()), this.title = e(() => this.#r());
2989
+ constructor(e = {}) {
2990
+ let t = /* @__PURE__ */ new Date(), n = Z(e.value ?? null) ?? t;
2991
+ this.view = _("day"), this.focusedYear = _(n.getFullYear()), this.focusedMonth = _(n.getMonth()), this.value = _(e.value ?? null), this.rangeStart = _(e.rangeStart ?? null), this.rangeEnd = _(e.rangeEnd ?? null), this.min = _(e.min ?? null), this.max = _(e.max ?? null), this.days = v(() => this.#e()), this.months = v(() => this.#t()), this.years = v(() => this.#n()), this.title = v(() => this.#r());
1554
2992
  }
1555
2993
  prevMonth() {
1556
- n(() => {
2994
+ b(() => {
1557
2995
  this.focusedMonth.value === 0 ? (this.focusedMonth.value = 11, this.focusedYear.value--) : this.focusedMonth.value--;
1558
2996
  });
1559
2997
  }
1560
2998
  nextMonth() {
1561
- n(() => {
2999
+ b(() => {
1562
3000
  this.focusedMonth.value === 11 ? (this.focusedMonth.value = 0, this.focusedYear.value++) : this.focusedMonth.value++;
1563
3001
  });
1564
3002
  }
@@ -1578,31 +3016,31 @@ var Q = class {
1578
3016
  this.value.value = e;
1579
3017
  }
1580
3018
  selectMonth(e) {
1581
- n(() => {
3019
+ b(() => {
1582
3020
  this.focusedMonth.value = e, this.view.value = "day";
1583
3021
  });
1584
3022
  }
1585
3023
  selectYear(e) {
1586
- n(() => {
3024
+ b(() => {
1587
3025
  this.focusedYear.value = e, this.view.value = "month";
1588
3026
  });
1589
3027
  }
1590
3028
  setRange(e, t) {
1591
- n(() => {
3029
+ b(() => {
1592
3030
  this.rangeStart.value = e, this.rangeEnd.value = t;
1593
3031
  });
1594
3032
  }
1595
3033
  isDateDisabled(e) {
1596
- let t = X(this.min.value), n = X(this.max.value), r = X(e);
3034
+ let t = Z(this.min.value), n = Z(this.max.value), r = Z(e);
1597
3035
  return !!(!r || t && r < t || n && r > n);
1598
3036
  }
1599
3037
  #e() {
1600
- let e = this.focusedYear.value, t = this.focusedMonth.value, n = X(this.value.value), r = /* @__PURE__ */ new Date(), i = X(this.rangeStart.value), a = X(this.rangeEnd.value), o = new Date(e, t, 1).getDay(), s = new Date(e, t, 1 - o), c = [];
3038
+ let e = this.focusedYear.value, t = this.focusedMonth.value, n = Z(this.value.value), r = /* @__PURE__ */ new Date(), i = Z(this.rangeStart.value), a = Z(this.rangeEnd.value), o = new Date(e, t, 1).getDay(), s = new Date(e, t, 1 - o), c = [];
1601
3039
  for (let e = 0; e < 42; e++) {
1602
- let o = new Date(s.getFullYear(), s.getMonth(), s.getDate() + e), l = ce(o), u = o.getMonth() === t, d = Z(o, r), f = n ? Z(o, n) : !1, p = this.isDateDisabled(l), m = !1, h = !1, g = !1;
3040
+ let o = new Date(s.getFullYear(), s.getMonth(), s.getDate() + e), l = He(o), u = o.getMonth() === t, d = Q(o, r), f = n ? Q(o, n) : !1, p = this.isDateDisabled(l), m = !1, h = !1, g = !1;
1603
3041
  if (i && a) {
1604
3042
  let e = i <= a ? i : a, t = i <= a ? a : i;
1605
- m = o >= e && o <= t, h = Z(o, e), g = Z(o, t);
3043
+ m = o >= e && o <= t, h = Q(o, e), g = Q(o, t);
1606
3044
  }
1607
3045
  c.push({
1608
3046
  date: l,
@@ -1675,8 +3113,8 @@ var Q = class {
1675
3113
  }
1676
3114
  }
1677
3115
  };
1678
- function le(e = {}) {
1679
- return new Q(e);
3116
+ function Ue(e = {}) {
3117
+ return new $(e);
1680
3118
  }
1681
3119
  /**
1682
3120
  * Calendar date picker with day/month/year views and optional range selection.
@@ -1689,7 +3127,7 @@ function le(e = {}) {
1689
3127
  * @fires ui-change - Fired on single date selection with `{ value }` detail
1690
3128
  * @fires ui-range-select - Fired on range commit with `{ start, end }` detail
1691
3129
  */
1692
- var ue = class extends S(_) {
3130
+ var We = class extends P(k) {
1693
3131
  static observedAttributes = [
1694
3132
  "value",
1695
3133
  "min",
@@ -1700,11 +3138,11 @@ var ue = class extends S(_) {
1700
3138
  "required"
1701
3139
  ];
1702
3140
  #e;
1703
- #t = new Q();
1704
- #n = t(!1);
1705
- #r = t(!1);
3141
+ #t = new $();
3142
+ #n = _(!1);
3143
+ #r = _(!1);
1706
3144
  #i = null;
1707
- #a = t(0);
3145
+ #a = _(0);
1708
3146
  #o = "idle";
1709
3147
  constructor() {
1710
3148
  super(), this.#e = this.attachInternals(), this.#e.role = "group";
@@ -1761,14 +3199,14 @@ var ue = class extends S(_) {
1761
3199
  }
1762
3200
  setup() {
1763
3201
  super.setup(), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.#i = this.getAttribute("value");
1764
- let e = this.getAttribute("value"), t = this.getAttribute("min"), r = this.getAttribute("max");
1765
- n(() => {
1766
- e && (this.#t.value.value = e), t && (this.#t.min.value = t), r && (this.#t.max.value = r);
3202
+ let e = this.getAttribute("value"), t = this.getAttribute("min"), n = this.getAttribute("max");
3203
+ b(() => {
3204
+ e && (this.#t.value.value = e), t && (this.#t.min.value = t), n && (this.#t.max.value = n);
1767
3205
  }), this.#s(), this.addEventListener("keydown", this.#b), this.addEffect(() => this.#c()), this.addEffect(() => {
1768
3206
  this.#e.setFormValue(this.#t.value.value);
1769
3207
  }), this.addEffect(() => {
1770
3208
  this.setAttribute("aria-label", this.#t.title.value);
1771
- }), this.addEffect(w(this, this.#n, this.#e, { manageTabindex: !0 })), this.#r.value = this.hasAttribute("required"), this.addEffect(() => {
3209
+ }), this.addEffect(j(this, this.#n, this.#e, { manageTabindex: !0 })), this.#r.value = this.hasAttribute("required"), this.addEffect(() => {
1772
3210
  let e = this.#t.value.value;
1773
3211
  this.#r.value && (e === null || e === "") ? this.#e.setValidity({ valueMissing: !0 }, "Please select a date.", this) : this.#e.setValidity({});
1774
3212
  });
@@ -1842,85 +3280,356 @@ var ue = class extends S(_) {
1842
3280
  let e = this.#t.view.value;
1843
3281
  e === "day" ? this.#t.view.value = "month" : e === "month" && (this.#t.view.value = "year");
1844
3282
  }
1845
- #_(e) {
1846
- if (this.#n.value) return;
1847
- let t = e.target.closest(".cal-cell");
1848
- if (!t || t.hasAttribute("disabled")) return;
1849
- let n = t.dataset.date, r = t.dataset.month, i = t.dataset.year;
1850
- n ? this.#v(n) : r === void 0 ? i !== void 0 && this.#t.selectYear(Number(i)) : this.#t.selectMonth(Number(r));
3283
+ #_(e) {
3284
+ if (this.#n.value) return;
3285
+ let t = e.target.closest(".cal-cell");
3286
+ if (!t || t.hasAttribute("disabled")) return;
3287
+ let n = t.dataset.date, r = t.dataset.month, i = t.dataset.year;
3288
+ n ? this.#v(n) : r === void 0 ? i !== void 0 && this.#t.selectYear(Number(i)) : this.#t.selectMonth(Number(r));
3289
+ }
3290
+ #v(e) {
3291
+ if (this.range) if (this.#o === "idle") b(() => {
3292
+ this.#t.selectDate(e), this.#t.setRange(e, null);
3293
+ }), this.setAttribute("value", e), this.#o = "selecting";
3294
+ else if (this.#o === "selecting") {
3295
+ let t = this.#t.rangeStart.value;
3296
+ if (!t) return;
3297
+ this.#t.setRange(t, e), this.#o = "committed", this.dispatchEvent(new CustomEvent("ui-range-select", {
3298
+ bubbles: !0,
3299
+ composed: !0,
3300
+ detail: {
3301
+ start: this.#t.rangeStart.value,
3302
+ end: this.#t.rangeEnd.value
3303
+ }
3304
+ }));
3305
+ } else b(() => {
3306
+ this.#t.value.value = null, this.#t.setRange(null, null);
3307
+ }), this.removeAttribute("value"), this.#o = "idle";
3308
+ else this.#t.selectDate(e), this.setAttribute("value", e), this.dispatchEvent(new CustomEvent("ui-change", {
3309
+ bubbles: !0,
3310
+ composed: !0,
3311
+ detail: { value: e }
3312
+ }));
3313
+ }
3314
+ #y(e) {
3315
+ if (this.#n.value || !this.range || this.#o !== "selecting") return;
3316
+ let t = e.target.closest(".cal-cell");
3317
+ if (!t || t.hasAttribute("disabled")) return;
3318
+ let n = t.dataset.date;
3319
+ if (!n) return;
3320
+ let r = this.#t.rangeStart.value;
3321
+ r && this.#t.setRange(r, n);
3322
+ }
3323
+ #b = (e) => {
3324
+ if (this.#n.value || this.#t.view.value !== "day") return;
3325
+ let t = this.#t.days.value, n = this.#a.value, r = !0;
3326
+ switch (e.key) {
3327
+ case "ArrowRight":
3328
+ n += 1;
3329
+ break;
3330
+ case "ArrowLeft":
3331
+ --n;
3332
+ break;
3333
+ case "ArrowDown":
3334
+ n += 7;
3335
+ break;
3336
+ case "ArrowUp":
3337
+ n -= 7;
3338
+ break;
3339
+ case "Home":
3340
+ n -= n % 7;
3341
+ break;
3342
+ case "End":
3343
+ n = n - n % 7 + 6;
3344
+ break;
3345
+ case "PageDown":
3346
+ e.shiftKey ? this.#t.nextYear() : this.#t.nextMonth();
3347
+ break;
3348
+ case "PageUp":
3349
+ e.shiftKey ? this.#t.prevYear() : this.#t.prevMonth();
3350
+ break;
3351
+ case "Enter":
3352
+ case " ": {
3353
+ let e = t[n];
3354
+ e && !e.isDisabled && this.#v(e.date);
3355
+ break;
3356
+ }
3357
+ default: r = !1;
3358
+ }
3359
+ r && (e.preventDefault(), n = Math.max(0, Math.min(41, n)), this.#a.value = n, n < 0 && this.#t.prevMonth(), n > 41 && this.#t.nextMonth());
3360
+ };
3361
+ }, Ge = class {
3362
+ open = _(!1);
3363
+ value = _(null);
3364
+ label = _("");
3365
+ toggle() {
3366
+ this.open.value = !this.open.value;
3367
+ }
3368
+ show() {
3369
+ this.open.value = !0;
3370
+ }
3371
+ hide() {
3372
+ this.open.value = !1;
3373
+ }
3374
+ select(e, t) {
3375
+ b(() => {
3376
+ this.value.value = e, this.label.value = t, this.open.value = !1;
3377
+ });
3378
+ }
3379
+ reset() {
3380
+ b(() => {
3381
+ this.open.value = !1, this.value.value = null, this.label.value = "";
3382
+ });
3383
+ }
3384
+ }, Ke = class extends P(k) {
3385
+ static observedAttributes = [
3386
+ "value",
3387
+ "disabled",
3388
+ "name",
3389
+ "options",
3390
+ "src",
3391
+ "placeholder",
3392
+ "required"
3393
+ ];
3394
+ #e;
3395
+ #t = new Ge();
3396
+ #n = _(!1);
3397
+ #r = _(!1);
3398
+ #i;
3399
+ #a = _([]);
3400
+ #o = _(null);
3401
+ #s = _("");
3402
+ #c = !1;
3403
+ #l = null;
3404
+ #u = null;
3405
+ #d = null;
3406
+ #f = null;
3407
+ #p = "";
3408
+ constructor() {
3409
+ super(), this.#e = this.attachInternals();
3410
+ }
3411
+ get controller() {
3412
+ return this.#t;
3413
+ }
3414
+ get value() {
3415
+ return this.#t.value.value;
3416
+ }
3417
+ set value(e) {
3418
+ if (e === null) {
3419
+ this.#t.reset();
3420
+ return;
3421
+ }
3422
+ let t = this.querySelector(`ui-option[value="${CSS.escape(e)}"]`), n = t?.getAttribute("label") ?? t?.textContent?.trim() ?? e;
3423
+ this.#t.select(e, n);
3424
+ }
3425
+ get name() {
3426
+ return this.getAttribute("name") ?? "";
3427
+ }
3428
+ set name(e) {
3429
+ this.setAttribute("name", e);
3430
+ }
3431
+ get disabled() {
3432
+ return this.#n.value;
3433
+ }
3434
+ set disabled(e) {
3435
+ this.#n.value = e, this.toggleAttribute("disabled", e);
3436
+ }
3437
+ get required() {
3438
+ return this.#r.value;
3439
+ }
3440
+ set required(e) {
3441
+ this.#r.value = e, this.toggleAttribute("required", e);
3442
+ }
3443
+ get options() {
3444
+ return this.#a.value;
3445
+ }
3446
+ set options(e) {
3447
+ this.#a.value = e, this.setAttribute("options", JSON.stringify(e));
3448
+ }
3449
+ get src() {
3450
+ return this.#o.value;
3451
+ }
3452
+ set src(e) {
3453
+ this.#o.value = e, e == null ? this.removeAttribute("src") : this.setAttribute("src", e);
3454
+ }
3455
+ get placeholder() {
3456
+ return this.#s.value;
3457
+ }
3458
+ set placeholder(e) {
3459
+ this.#s.value = e, e ? this.setAttribute("placeholder", e) : this.removeAttribute("placeholder");
3460
+ }
3461
+ #m(e) {
3462
+ return B(e, "ui-select");
3463
+ }
3464
+ async #h(e) {
3465
+ this.#l = await V(e, this.#l, this.#a, "ui-select");
3466
+ }
3467
+ #g() {
3468
+ let e = document.createElement("ui-button");
3469
+ e.setAttribute("justify", "spread");
3470
+ let t = document.createElement("span");
3471
+ t.setAttribute("slot", "label"), t.textContent = this.#s.value || "\xA0", e.appendChild(t);
3472
+ let n = document.createElement("ui-icon");
3473
+ n.setAttribute("name", "caret-up-down"), n.setAttribute("slot", "trailing"), e.appendChild(n);
3474
+ let r = document.createElement("ui-listbox");
3475
+ r.setAttribute("popover", "manual"), this.appendChild(e), this.appendChild(r);
3476
+ }
3477
+ #_(e) {
3478
+ let t = this.#u;
3479
+ if (t) {
3480
+ for (; t.firstChild;) t.removeChild(t.firstChild);
3481
+ for (let n of e) {
3482
+ let e = document.createElement("ui-option");
3483
+ e.setAttribute("value", n.value), e.setAttribute("label", n.label), e.textContent = n.label, n.disabled && e.setAttribute("disabled", ""), t.appendChild(e);
3484
+ }
3485
+ }
3486
+ }
3487
+ attributeChangedCallback(e, t, n) {
3488
+ if (t !== n) {
3489
+ switch (e) {
3490
+ case "value":
3491
+ if (n !== null) {
3492
+ let e = this.querySelector(`ui-option[value="${CSS.escape(n)}"]`), t = e?.getAttribute("label") ?? e?.textContent?.trim() ?? n;
3493
+ this.#t.select(n, t);
3494
+ } else this.#t.reset();
3495
+ break;
3496
+ case "disabled":
3497
+ this.#n.value = n !== null;
3498
+ break;
3499
+ case "required":
3500
+ this.#r.value = n !== null;
3501
+ break;
3502
+ case "options":
3503
+ n ? this.#a.value = this.#m(n) : this.#a.value = [];
3504
+ break;
3505
+ case "src":
3506
+ this.#o.value = n;
3507
+ break;
3508
+ case "placeholder":
3509
+ this.#s.value = n ?? "";
3510
+ break;
3511
+ }
3512
+ super.attributeChangedCallback?.(e, t, n);
3513
+ }
1851
3514
  }
1852
- #v(e) {
1853
- if (this.range) if (this.#o === "idle") n(() => {
1854
- this.#t.selectDate(e), this.#t.setRange(e, null);
1855
- }), this.setAttribute("value", e), this.#o = "selecting";
1856
- else if (this.#o === "selecting") {
1857
- let t = this.#t.rangeStart.value;
1858
- if (!t) return;
1859
- this.#t.setRange(t, e), this.#o = "committed", this.dispatchEvent(new CustomEvent("ui-range-select", {
1860
- bubbles: !0,
1861
- composed: !0,
1862
- detail: {
1863
- start: this.#t.rangeStart.value,
1864
- end: this.#t.rangeEnd.value
3515
+ setup() {
3516
+ if (super.setup(), this.#i = new q(this), this.#c = this.hasAttribute("options") || this.hasAttribute("src"), this.#c) {
3517
+ let e = this.getAttribute("options");
3518
+ e && (this.#a.value = this.#m(e)), this.#o.value = this.getAttribute("src"), this.#s.value = this.getAttribute("placeholder") ?? "", this.#g();
3519
+ }
3520
+ let e = this.querySelector(":scope > ui-button");
3521
+ this.#d = e;
3522
+ let t = this.querySelector(":scope > ui-listbox[popover]");
3523
+ this.#u = t, t?.setAttribute("popover", "manual"), e && t && this.#i.wirePopover(e, t), e?.setAttribute("aria-haspopup", "listbox"), e && t && (t.id ||= A("lb"), e.setAttribute("aria-controls", t.id)), this.#c && (this.addEffect(() => {
3524
+ let e = this.#a.value;
3525
+ this.#_(e);
3526
+ }), this.addEffect(() => {
3527
+ let e = this.#o.value;
3528
+ e && this.#h(e);
3529
+ }), this.addEffect(() => {
3530
+ let t = this.#s.value, n = this.#t.label.value, r = e?.querySelector("[slot=\"label\"]");
3531
+ r && !n && (r.textContent = t || "\xA0");
3532
+ })), this.deferChildren(() => {
3533
+ let n = this.getAttribute("value");
3534
+ if (n) {
3535
+ let e = this.querySelector(`ui-option[value="${CSS.escape(n)}"]`), t = e?.getAttribute("label") ?? e?.textContent?.trim() ?? n;
3536
+ this.#t.value.value = n, this.#t.label.value = t, this.#f = n, this.#p = t;
3537
+ }
3538
+ this.addEffect(() => {
3539
+ let t = this.#t.label.value, n = e?.querySelector("[slot=\"label\"]");
3540
+ n && (n.textContent = t || (this.#c ? this.#s.value || "\xA0" : n.textContent ?? ""));
3541
+ }), this.addEffect(() => {
3542
+ let e = this.#t.value.value, n = t?.querySelectorAll("ui-option") ?? [];
3543
+ for (let t of n) {
3544
+ let n = t.getAttribute("value") === e;
3545
+ t.setAttribute("aria-selected", String(n));
1865
3546
  }
1866
- }));
1867
- } else n(() => {
1868
- this.#t.value.value = null, this.#t.setRange(null, null);
1869
- }), this.removeAttribute("value"), this.#o = "idle";
1870
- else this.#t.selectDate(e), this.setAttribute("value", e), this.dispatchEvent(new CustomEvent("ui-change", {
3547
+ });
3548
+ }), this.addEffect(j(this, this.#n, this.#e)), this.addEffect(() => {
3549
+ let t = this.#n.value;
3550
+ e && e.toggleAttribute("disabled", t), t && this.#t.open.peek() && this.#t.hide();
3551
+ }), this.#r.value = this.hasAttribute("required"), this.addEffect(() => {
3552
+ let e = this.#t.value.value;
3553
+ this.#r.value && (e === null || e === "") ? this.#e.setValidity({ valueMissing: !0 }, "Please select an option.", this) : this.#e.setValidity({});
3554
+ }), this.addEffect(() => {
3555
+ let t = this.#t.open.value;
3556
+ this.#i.syncPopover(t), e?.setAttribute("aria-expanded", String(t));
3557
+ }), this.addEffect(() => {
3558
+ let e = this.#t.value.value;
3559
+ this.#e.setFormValue(e ?? ""), e == null ? this.removeAttribute("value") : this.setAttribute("value", e);
3560
+ }), e?.addEventListener("ui-press", this.#v), this.addEventListener("ui-change", this.#y), this.addEventListener("ui-select", this.#b), this.addEventListener("ui-dismiss", this.#x), e?.addEventListener("keydown", this.#S);
3561
+ }
3562
+ #v = () => {
3563
+ this.#n.value || this.#t.toggle();
3564
+ };
3565
+ #y = (e) => {
3566
+ e.target !== this && e.stopImmediatePropagation();
3567
+ };
3568
+ #b = (e) => {
3569
+ let t = e.detail;
3570
+ this.#t.select(t.value, t.label), this.dispatchEvent(new CustomEvent("ui-change", {
1871
3571
  bubbles: !0,
1872
3572
  composed: !0,
1873
- detail: { value: e }
3573
+ detail: t
1874
3574
  }));
1875
- }
1876
- #y(e) {
1877
- if (this.#n.value || !this.range || this.#o !== "selecting") return;
1878
- let t = e.target.closest(".cal-cell");
1879
- if (!t || t.hasAttribute("disabled")) return;
1880
- let n = t.dataset.date;
1881
- if (!n) return;
1882
- let r = this.#t.rangeStart.value;
1883
- r && this.#t.setRange(r, n);
1884
- }
1885
- #b = (e) => {
1886
- if (this.#n.value || this.#t.view.value !== "day") return;
1887
- let t = this.#t.days.value, n = this.#a.value, r = !0;
3575
+ };
3576
+ #x = () => {
3577
+ this.#t.hide();
3578
+ };
3579
+ #S = (e) => {
3580
+ if (this.#n.value) return;
3581
+ let t = this.#u;
1888
3582
  switch (e.key) {
1889
- case "ArrowRight":
1890
- n += 1;
1891
- break;
1892
- case "ArrowLeft":
1893
- --n;
1894
- break;
1895
3583
  case "ArrowDown":
1896
- n += 7;
1897
- break;
1898
- case "ArrowUp":
1899
- n -= 7;
1900
- break;
1901
- case "Home":
1902
- n -= n % 7;
3584
+ case "ArrowUp": {
3585
+ e.preventDefault();
3586
+ let n = t?.controller;
3587
+ if (this.#t.open.value || this.#t.show(), n) {
3588
+ let r = t?.querySelectorAll(":scope ui-option:not([disabled])")?.length ?? 0;
3589
+ n.moveActive(e.key === "ArrowDown" ? 1 : -1, r);
3590
+ }
1903
3591
  break;
1904
- case "End":
1905
- n = n - n % 7 + 6;
3592
+ }
3593
+ case "Enter":
3594
+ case " ":
3595
+ if (e.preventDefault(), this.#t.open.value) {
3596
+ let e = t?.getActiveOption();
3597
+ e && e.click();
3598
+ } else this.#t.toggle();
1906
3599
  break;
1907
- case "PageDown":
1908
- e.shiftKey ? this.#t.nextYear() : this.#t.nextMonth();
3600
+ case "Escape":
3601
+ this.#t.open.value && (e.preventDefault(), this.#t.hide());
1909
3602
  break;
1910
- case "PageUp":
1911
- e.shiftKey ? this.#t.prevYear() : this.#t.prevMonth();
3603
+ case "Home": {
3604
+ e.preventDefault();
3605
+ let n = t?.controller;
3606
+ n && (n.activeIndex.value = 0);
1912
3607
  break;
1913
- case "Enter":
1914
- case " ": {
1915
- let e = t[n];
1916
- e && !e.isDisabled && this.#v(e.date);
3608
+ }
3609
+ case "End": {
3610
+ e.preventDefault();
3611
+ let n = t?.controller;
3612
+ if (n) {
3613
+ let e = t?.querySelectorAll(":scope ui-option:not([disabled])");
3614
+ n.activeIndex.value = Math.max(0, (e?.length ?? 1) - 1);
3615
+ }
1917
3616
  break;
1918
3617
  }
1919
- default: r = !1;
1920
3618
  }
1921
- r && (e.preventDefault(), n = Math.max(0, Math.min(41, n)), this.#a.value = n, n < 0 && this.#t.prevMonth(), n > 41 && this.#t.nextMonth());
1922
3619
  };
1923
- }, de = class extends S(_) {
3620
+ teardown() {
3621
+ this.#d?.removeEventListener("ui-press", this.#v), this.#d?.removeEventListener("keydown", this.#S), this.removeEventListener("ui-change", this.#y), this.removeEventListener("ui-select", this.#b), this.removeEventListener("ui-dismiss", this.#x), this.#d = null, this.#l?.abort(), this.#l = null, this.#u = null, this.#i.destroy(), super.teardown();
3622
+ }
3623
+ onFormReset() {
3624
+ this.#f === null ? this.#t.reset() : this.#t.select(this.#f, this.#p);
3625
+ }
3626
+ onFormStateRestore(e) {
3627
+ typeof e == "string" && e && (this.value = e);
3628
+ }
3629
+ onFormDisabled(e) {
3630
+ this.#n.value = e;
3631
+ }
3632
+ }, qe = class extends P(k) {
1924
3633
  static observedAttributes = [
1925
3634
  "value",
1926
3635
  "disabled",
@@ -1931,16 +3640,16 @@ var ue = class extends S(_) {
1931
3640
  "required"
1932
3641
  ];
1933
3642
  #e;
1934
- #t = new C();
1935
- #n = t(!1);
1936
- #r = t(!1);
1937
- #i = t(!1);
3643
+ #t = new z();
3644
+ #n = _(!1);
3645
+ #r = _(!1);
3646
+ #i = _(!1);
1938
3647
  #a;
1939
- #o = r("listbox");
3648
+ #o = A("listbox");
1940
3649
  #s = null;
1941
- #c = t([]);
1942
- #l = t(null);
1943
- #u = t("");
3650
+ #c = _([]);
3651
+ #l = _(null);
3652
+ #u = _("");
1944
3653
  #d = !1;
1945
3654
  #f = null;
1946
3655
  #p = null;
@@ -1957,7 +3666,7 @@ var ue = class extends S(_) {
1957
3666
  }
1958
3667
  set value(e) {
1959
3668
  if (e === null) {
1960
- n(() => {
3669
+ b(() => {
1961
3670
  this.#t.clearSelection(), this.#t.query.value = "", this.#t.activeIndex.value = -1, this.#n.value = !1;
1962
3671
  });
1963
3672
  return;
@@ -2001,10 +3710,10 @@ var ue = class extends S(_) {
2001
3710
  this.#u.value = e, e ? this.setAttribute("placeholder", e) : this.removeAttribute("placeholder");
2002
3711
  }
2003
3712
  #g(e) {
2004
- return b(e, "ui-combobox");
3713
+ return B(e, "ui-combobox");
2005
3714
  }
2006
3715
  async #_(e) {
2007
- this.#f = await y(e, this.#f, this.#c, "ui-combobox");
3716
+ this.#f = await V(e, this.#f, this.#c, "ui-combobox");
2008
3717
  }
2009
3718
  #v() {
2010
3719
  let e = document.createElement("ui-input"), t = this.#u.value;
@@ -2025,38 +3734,38 @@ var ue = class extends S(_) {
2025
3734
  this.#t.data.value = e;
2026
3735
  }
2027
3736
  }
2028
- attributeChangedCallback(e, t, r) {
2029
- if (t !== r) {
3737
+ attributeChangedCallback(e, t, n) {
3738
+ if (t !== n) {
2030
3739
  switch (e) {
2031
3740
  case "value":
2032
- if (r !== null) {
2033
- let e = this.querySelector(`ui-option[value="${CSS.escape(r)}"]`), t = e?.getAttribute("label") ?? e?.textContent?.trim() ?? r;
2034
- this.#t.select(r), this.#t.query.value = t, this.#s && "value" in this.#s && (this.#s.value = t);
2035
- } else n(() => {
3741
+ if (n !== null) {
3742
+ let e = this.querySelector(`ui-option[value="${CSS.escape(n)}"]`), t = e?.getAttribute("label") ?? e?.textContent?.trim() ?? n;
3743
+ this.#t.select(n), this.#t.query.value = t, this.#s && "value" in this.#s && (this.#s.value = t);
3744
+ } else b(() => {
2036
3745
  this.#t.clearSelection(), this.#t.query.value = "";
2037
3746
  }), this.#s && "value" in this.#s && (this.#s.value = "");
2038
3747
  break;
2039
3748
  case "disabled":
2040
- this.#r.value = r !== null;
3749
+ this.#r.value = n !== null;
2041
3750
  break;
2042
3751
  case "required":
2043
- this.#i.value = r !== null;
3752
+ this.#i.value = n !== null;
2044
3753
  break;
2045
3754
  case "options":
2046
- r ? this.#c.value = this.#g(r) : this.#c.value = [];
3755
+ n ? this.#c.value = this.#g(n) : this.#c.value = [];
2047
3756
  break;
2048
3757
  case "src":
2049
- this.#l.value = r;
3758
+ this.#l.value = n;
2050
3759
  break;
2051
3760
  case "placeholder":
2052
- this.#u.value = r ?? "";
3761
+ this.#u.value = n ?? "";
2053
3762
  break;
2054
3763
  }
2055
- super.attributeChangedCallback?.(e, t, r);
3764
+ super.attributeChangedCallback?.(e, t, n);
2056
3765
  }
2057
3766
  }
2058
3767
  setup() {
2059
- if (super.setup(), this.#a = new m(this), this.#d = this.hasAttribute("options") || this.hasAttribute("src"), this.#d) {
3768
+ if (super.setup(), this.#a = new q(this), this.#d = this.hasAttribute("options") || this.hasAttribute("src"), this.#d) {
2060
3769
  let e = this.getAttribute("options");
2061
3770
  e && (this.#c.value = this.#g(e)), this.#l.value = this.getAttribute("src"), this.#u.value = this.getAttribute("placeholder") ?? "", this.#v();
2062
3771
  }
@@ -2090,10 +3799,10 @@ var ue = class extends S(_) {
2090
3799
  for (let e of r) e.toggleAttribute("hidden", !n.has(e.getAttribute("value") ?? ""));
2091
3800
  }), this.addEffect(() => {
2092
3801
  this.#t.view.value;
2093
- let n = this.#t.activeIndex.value, i = [...t?.querySelectorAll("ui-option:not([hidden]):not([disabled])") ?? []];
2094
- for (let e = 0; e < i.length; e++) i[e].toggleAttribute("active", e === n);
2095
- let a = i[n];
2096
- a ? (a.scrollIntoView({ block: "nearest" }), a.id ||= r("opt"), e?.setAttribute("aria-activedescendant", a.id)) : e?.removeAttribute("aria-activedescendant");
3802
+ let n = this.#t.activeIndex.value, r = [...t?.querySelectorAll("ui-option:not([hidden]):not([disabled])") ?? []];
3803
+ for (let e = 0; e < r.length; e++) r[e].toggleAttribute("active", e === n);
3804
+ let i = r[n];
3805
+ i ? (i.scrollIntoView({ block: "nearest" }), i.id ||= A("opt"), e?.setAttribute("aria-activedescendant", i.id)) : e?.removeAttribute("aria-activedescendant");
2097
3806
  }), this.addEffect(() => {
2098
3807
  let e = this.#t.value.value, n = t?.querySelectorAll("ui-option") ?? [];
2099
3808
  for (let t of n) {
@@ -2101,7 +3810,7 @@ var ue = class extends S(_) {
2101
3810
  t.setAttribute("aria-selected", String(n));
2102
3811
  }
2103
3812
  });
2104
- }), this.addEffect(w(this, this.#r, this.#e)), this.addEffect(() => {
3813
+ }), this.addEffect(j(this, this.#r, this.#e)), this.addEffect(() => {
2105
3814
  let t = this.#r.value;
2106
3815
  e && e.toggleAttribute("disabled", t), t && this.#n.peek() && (this.#n.value = !1);
2107
3816
  }), this.#i.value = this.hasAttribute("required"), this.addEffect(() => {
@@ -2126,11 +3835,11 @@ var ue = class extends S(_) {
2126
3835
  };
2127
3836
  #C = (e) => {
2128
3837
  let t = e.detail;
2129
- n(() => {
3838
+ b(() => {
2130
3839
  this.#t.select(t.value), this.#t.query.value = t.label, this.#t.activeIndex.value = -1, this.#n.value = !1;
2131
3840
  });
2132
- let r = this.#s;
2133
- r && "value" in r && (r.value = t.label), this.dispatchEvent(new CustomEvent("ui-change", {
3841
+ let n = this.#s;
3842
+ n && "value" in n && (n.value = t.label), this.dispatchEvent(new CustomEvent("ui-change", {
2134
3843
  bubbles: !0,
2135
3844
  composed: !0,
2136
3845
  detail: t
@@ -2175,7 +3884,7 @@ var ue = class extends S(_) {
2175
3884
  this.#s?.removeEventListener("focus", this.#b), this.#s?.removeEventListener("keydown", this.#T), this.removeEventListener("ui-input", this.#x), this.removeEventListener("ui-change", this.#S), this.removeEventListener("ui-select", this.#C), this.removeEventListener("ui-dismiss", this.#w), this.#s = null, this.#p = null, this.#f?.abort(), this.#f = null, this.#a.destroy(), super.teardown();
2176
3885
  }
2177
3886
  onFormReset() {
2178
- n(() => {
3887
+ b(() => {
2179
3888
  this.#m === null ? (this.#t.clearSelection(), this.#t.query.value = "") : (this.#t.select(this.#m), this.#t.query.value = this.#h), this.#t.activeIndex.value = -1, this.#n.value = !1;
2180
3889
  });
2181
3890
  let e = this.querySelector(":scope > ui-input");
@@ -2187,11 +3896,11 @@ var ue = class extends S(_) {
2187
3896
  onFormDisabled(e) {
2188
3897
  this.#r.value = e;
2189
3898
  }
2190
- }, fe = class extends _ {
3899
+ }, Je = class extends k {
2191
3900
  static observedAttributes = ["disabled", "required"];
2192
- #e = r("field-label");
2193
- #t = r("field-desc");
2194
- #n = r("field-err");
3901
+ #e = A("field-label");
3902
+ #t = A("field-desc");
3903
+ #n = A("field-err");
2195
3904
  #r = null;
2196
3905
  setup() {
2197
3906
  super.setup(), this.deferChildren(() => {
@@ -2251,7 +3960,7 @@ var ue = class extends S(_) {
2251
3960
  let t = this.querySelector("[slot=\"description\"]"), n = this.querySelector("[slot=\"error\"]"), r = [];
2252
3961
  t && r.push(t.id), e && n && r.push(n.id), r.length ? this.#r.setAttribute("aria-describedby", r.join(" ")) : this.#r.removeAttribute("aria-describedby");
2253
3962
  }
2254
- }, pe = class extends S(_) {
3963
+ }, Ye = class extends P(k) {
2255
3964
  static observedAttributes = [
2256
3965
  "value",
2257
3966
  "placeholder",
@@ -2264,10 +3973,10 @@ var ue = class extends S(_) {
2264
3973
  "pattern"
2265
3974
  ];
2266
3975
  #e;
2267
- #t = t(!1);
2268
- #n = t(!1);
2269
- #r = t(NaN);
2270
- #i = t("");
3976
+ #t = _(!1);
3977
+ #n = _(!1);
3978
+ #r = _(NaN);
3979
+ #i = _("");
2271
3980
  #a = "";
2272
3981
  #o = 0;
2273
3982
  #s = null;
@@ -2341,7 +4050,7 @@ var ue = class extends S(_) {
2341
4050
  setup() {
2342
4051
  super.setup(), this.setAttribute("aria-multiline", "true"), this.hasAttribute("contenteditable") || this.setAttribute("contenteditable", "plaintext-only"), this.#n.value = this.hasAttribute("required");
2343
4052
  let e = this.getAttribute("maxlength");
2344
- this.#r.value = e === null ? NaN : parseInt(e, 10), this.#s = this.getAttribute("pattern"), this.#a = this.getAttribute("value") ?? this.textContent ?? "", this.#i.value = this.textContent ?? "", this.#c(), this.#l(), this.addEffect(w(this, this.#t, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
4053
+ this.#r.value = e === null ? NaN : parseInt(e, 10), this.#s = this.getAttribute("pattern"), this.#a = this.getAttribute("value") ?? this.textContent ?? "", this.#i.value = this.textContent ?? "", this.#c(), this.#l(), this.addEffect(j(this, this.#t, this.#e, { manageTabindex: !0 })), this.addEffect(() => {
2345
4054
  let e = this.#i.value, t = this.#r.value;
2346
4055
  this.#n.value && e === "" ? this.#e.setValidity({ valueMissing: !0 }, "Please fill out this field.", this) : !isNaN(t) && e.length > t ? this.#e.setValidity({ tooLong: !0 }, `Please shorten this text to ${t} characters or less.`, this) : this.#s !== null && e !== "" && !RegExp(`^(?:${this.#s})$`).test(e) ? this.#e.setValidity({ patternMismatch: !0 }, "Please match the requested format.", this) : this.#e.setValidity({});
2347
4056
  }), this.addEventListener("input", this.#u), this.addEventListener("blur", this.#d);
@@ -2381,7 +4090,191 @@ var ue = class extends S(_) {
2381
4090
  detail: { value: this.textContent ?? "" }
2382
4091
  }));
2383
4092
  };
2384
- }, me = class extends S(_) {
4093
+ }, Xe = class extends P(k) {
4094
+ static observedAttributes = [
4095
+ "value",
4096
+ "min",
4097
+ "max",
4098
+ "step",
4099
+ "disabled",
4100
+ "name",
4101
+ "required"
4102
+ ];
4103
+ #e;
4104
+ #t = _(!1);
4105
+ #n = _(!1);
4106
+ #r = _(50);
4107
+ #i = 50;
4108
+ #a = _(0);
4109
+ #o = _(100);
4110
+ #s = _(1);
4111
+ #c = null;
4112
+ #l = !1;
4113
+ constructor() {
4114
+ super(), this.#e = this.attachInternals(), this.#e.role = "slider";
4115
+ }
4116
+ get value() {
4117
+ return this.#r.value;
4118
+ }
4119
+ set value(e) {
4120
+ this.#r.value = this.#u(e);
4121
+ }
4122
+ get min() {
4123
+ return this.#a.value;
4124
+ }
4125
+ set min(e) {
4126
+ this.#a.value = e, this.setAttribute("min", String(e));
4127
+ }
4128
+ get max() {
4129
+ return this.#o.value;
4130
+ }
4131
+ set max(e) {
4132
+ this.#o.value = e, this.setAttribute("max", String(e));
4133
+ }
4134
+ get step() {
4135
+ return this.#s.value;
4136
+ }
4137
+ set step(e) {
4138
+ this.#s.value = e, this.setAttribute("step", String(e));
4139
+ }
4140
+ get disabled() {
4141
+ return this.#t.value;
4142
+ }
4143
+ set disabled(e) {
4144
+ this.#t.value = e, this.toggleAttribute("disabled", e);
4145
+ }
4146
+ get required() {
4147
+ return this.#n.value;
4148
+ }
4149
+ set required(e) {
4150
+ this.#n.value = e, this.toggleAttribute("required", e);
4151
+ }
4152
+ get name() {
4153
+ return this.getAttribute("name") ?? "";
4154
+ }
4155
+ set name(e) {
4156
+ this.setAttribute("name", e);
4157
+ }
4158
+ attributeChangedCallback(e, t, n) {
4159
+ if (t !== n) {
4160
+ switch (e) {
4161
+ case "value":
4162
+ this.#r.value = this.#u(parseFloat(n ?? "50") || 50);
4163
+ break;
4164
+ case "min":
4165
+ this.#a.value = parseFloat(n ?? "0") || 0;
4166
+ break;
4167
+ case "max":
4168
+ this.#o.value = parseFloat(n ?? "100") || 100;
4169
+ break;
4170
+ case "step":
4171
+ this.#s.value = parseFloat(n ?? "1") || 1;
4172
+ break;
4173
+ case "disabled":
4174
+ this.#t.value = n !== null;
4175
+ break;
4176
+ case "required":
4177
+ this.#n.value = n !== null;
4178
+ break;
4179
+ }
4180
+ super.attributeChangedCallback(e, t, n);
4181
+ }
4182
+ }
4183
+ setup() {
4184
+ super.setup(), this.#i = this.#r.value, this.#c = document.createElement("div"), this.#c.classList.add("ui-range-thumb"), this.appendChild(this.#c), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEffect(j(this, this.#t, this.#e, { manageTabindex: !0 })), this.#n.value = this.hasAttribute("required"), this.addEffect(() => {
4185
+ let e = this.#r.value, t = this.#d();
4186
+ this.style.setProperty("--_progress", String(t)), this.setAttribute("aria-valuenow", String(e)), this.setAttribute("aria-valuemin", String(this.#a.value)), this.setAttribute("aria-valuemax", String(this.#o.value)), this.#e.setFormValue(String(e));
4187
+ }), this.addEventListener("pointerdown", this.#p), this.addEventListener("keydown", this.#_);
4188
+ }
4189
+ teardown() {
4190
+ this.removeEventListener("pointerdown", this.#p), this.removeEventListener("keydown", this.#_), this.#c &&= (this.#c.remove(), null), super.teardown();
4191
+ }
4192
+ onFormDisabled(e) {
4193
+ this.#t.value = e;
4194
+ }
4195
+ onFormReset() {
4196
+ this.#r.value = this.#i;
4197
+ }
4198
+ onFormStateRestore(e) {
4199
+ if (typeof e == "string") {
4200
+ let t = parseFloat(e);
4201
+ isNaN(t) || (this.value = t);
4202
+ }
4203
+ }
4204
+ #u(e) {
4205
+ let t = this.#a.value, n = this.#o.value, r = this.#s.value, i = Math.round((e - t) / r) * r + t;
4206
+ return Math.min(n, Math.max(t, i));
4207
+ }
4208
+ #d() {
4209
+ let e = this.#o.value - this.#a.value;
4210
+ return e === 0 ? 0 : (this.#r.value - this.#a.value) / e;
4211
+ }
4212
+ #f(e) {
4213
+ let t = this.getBoundingClientRect(), n = this.#c?.offsetWidth ?? 0, r = n / 2, i = t.width - n;
4214
+ if (i <= 0) return this.#a.value;
4215
+ let a = e.clientX - t.left - r, o = Math.min(1, Math.max(0, a / i));
4216
+ return this.#a.value + o * (this.#o.value - this.#a.value);
4217
+ }
4218
+ #p = (e) => {
4219
+ if (e.button !== 0 || this.#t.value) return;
4220
+ this.setPointerCapture(e.pointerId), this.#l = !0, this.toggleAttribute("pressed", !0);
4221
+ let t = this.#u(this.#f(e));
4222
+ this.#r.value = t, this.#v(), this.addEventListener("pointermove", this.#m), this.addEventListener("pointerup", this.#h), this.addEventListener("pointercancel", this.#g);
4223
+ };
4224
+ #m = (e) => {
4225
+ if (!this.#l || this.#t.value) return;
4226
+ let t = this.#u(this.#f(e));
4227
+ t !== this.#r.value && (this.#r.value = t, this.#v());
4228
+ };
4229
+ #h = () => {
4230
+ this.#l = !1, this.removeAttribute("pressed"), this.removeEventListener("pointermove", this.#m), this.removeEventListener("pointerup", this.#h), this.removeEventListener("pointercancel", this.#g), this.#y();
4231
+ };
4232
+ #g = () => {
4233
+ this.#l = !1, this.removeAttribute("pressed"), this.removeEventListener("pointermove", this.#m), this.removeEventListener("pointerup", this.#h), this.removeEventListener("pointercancel", this.#g);
4234
+ };
4235
+ #_ = (e) => {
4236
+ if (this.#t.value) return;
4237
+ let t = this.#s.value, n = t * 10, r = this.#r.value;
4238
+ switch (e.key) {
4239
+ case "ArrowRight":
4240
+ case "ArrowUp":
4241
+ r += t;
4242
+ break;
4243
+ case "ArrowLeft":
4244
+ case "ArrowDown":
4245
+ r -= t;
4246
+ break;
4247
+ case "PageUp":
4248
+ r += n;
4249
+ break;
4250
+ case "PageDown":
4251
+ r -= n;
4252
+ break;
4253
+ case "Home":
4254
+ r = this.#a.value;
4255
+ break;
4256
+ case "End":
4257
+ r = this.#o.value;
4258
+ break;
4259
+ default: return;
4260
+ }
4261
+ e.preventDefault(), r = this.#u(r), r !== this.#r.value && (this.#r.value = r, this.#v(), this.#y());
4262
+ };
4263
+ #v() {
4264
+ this.dispatchEvent(new CustomEvent("ui-input", {
4265
+ bubbles: !0,
4266
+ composed: !0,
4267
+ detail: { value: this.#r.value }
4268
+ }));
4269
+ }
4270
+ #y() {
4271
+ this.dispatchEvent(new CustomEvent("ui-change", {
4272
+ bubbles: !0,
4273
+ composed: !0,
4274
+ detail: { value: this.#r.value }
4275
+ }));
4276
+ }
4277
+ }, Ze = class extends P(k) {
2385
4278
  static observedAttributes = [
2386
4279
  "value",
2387
4280
  "length",
@@ -2392,7 +4285,7 @@ var ue = class extends S(_) {
2392
4285
  "required"
2393
4286
  ];
2394
4287
  #e;
2395
- #t = t(!1);
4288
+ #t = _(!1);
2396
4289
  #n;
2397
4290
  #r = [];
2398
4291
  #i = [];
@@ -2401,7 +4294,7 @@ var ue = class extends S(_) {
2401
4294
  #s = null;
2402
4295
  #c = "";
2403
4296
  constructor() {
2404
- super(), this.#e = this.attachInternals(), this.#e.role = "group", this.#n = x(this, "disabled", { type: "boolean" });
4297
+ super(), this.#e = this.attachInternals(), this.#e.role = "group", this.#n = M(this, "disabled", { type: "boolean" });
2405
4298
  }
2406
4299
  get value() {
2407
4300
  return this.#i.join("");
@@ -2429,7 +4322,7 @@ var ue = class extends S(_) {
2429
4322
  }
2430
4323
  attributeChangedCallback(e, t, n) {
2431
4324
  if (t !== n) {
2432
- if (v({ disabled: this.#n }, e, n)) {
4325
+ if (N({ disabled: this.#n }, e, n)) {
2433
4326
  super.attributeChangedCallback(e, t, n);
2434
4327
  return;
2435
4328
  }
@@ -2468,7 +4361,7 @@ var ue = class extends S(_) {
2468
4361
  if (t) try {
2469
4362
  this.#o = new RegExp(t);
2470
4363
  } catch {}
2471
- this.#s = this.getAttribute("mask"), this.#l(), this.addEffect(w(this, this.#n.signal, this.#e, { manageTabindex: !1 })), this.addEffect(() => {
4364
+ this.#s = this.getAttribute("mask"), this.#l(), this.addEffect(j(this, this.#n.signal, this.#e, { manageTabindex: !1 })), this.addEffect(() => {
2472
4365
  let e = this.#n.value;
2473
4366
  for (let t of this.#r) t.setAttribute("contenteditable", e ? "false" : "plaintext-only");
2474
4367
  }), this.#t.value = this.hasAttribute("required");
@@ -2566,7 +4459,7 @@ var ue = class extends S(_) {
2566
4459
  detail: { value: this.value }
2567
4460
  }));
2568
4461
  }
2569
- }, he = class extends _ {
4462
+ }, Qe = class extends k {
2570
4463
  static observedAttributes = [
2571
4464
  "src",
2572
4465
  "name",
@@ -2618,7 +4511,7 @@ var ue = class extends S(_) {
2618
4511
  let e = this.getAttribute("name");
2619
4512
  e ? this.textContent = this.#r(e) : this.textContent = "?";
2620
4513
  };
2621
- }, ge = class extends _ {
4514
+ }, $e = class extends k {
2622
4515
  static observedAttributes = ["max"];
2623
4516
  #e;
2624
4517
  #t = "";
@@ -2639,7 +4532,7 @@ var ue = class extends S(_) {
2639
4532
  let n = parseInt(this.#t, 10);
2640
4533
  isNaN(n) || (n > t ? this.textContent = `${t}+` : this.textContent = this.#t);
2641
4534
  }
2642
- }, _e = class extends _ {}, ve = class extends _ {
4535
+ }, et = class extends k {}, tt = class extends k {
2643
4536
  #e;
2644
4537
  constructor() {
2645
4538
  super(), this.#e = this.attachInternals(), this.#e.role = "navigation";
@@ -2649,7 +4542,7 @@ var ue = class extends S(_) {
2649
4542
  let e = this.getAttribute("aria-label") ?? "Breadcrumb";
2650
4543
  this.#e.ariaLabel = e, this.hasAttribute("aria-label") || this.setAttribute("aria-label", e);
2651
4544
  }
2652
- }, ye = class extends _ {
4545
+ }, nt = class extends k {
2653
4546
  static observedAttributes = ["href", "current"];
2654
4547
  #e;
2655
4548
  constructor() {
@@ -2675,7 +4568,7 @@ var ue = class extends S(_) {
2675
4568
  #r = (e) => {
2676
4569
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), this.#n());
2677
4570
  };
2678
- }, be = class extends _ {
4571
+ }, rt = class extends k {
2679
4572
  static observedAttributes = [
2680
4573
  "total",
2681
4574
  "value",
@@ -2684,11 +4577,11 @@ var ue = class extends S(_) {
2684
4577
  "disabled"
2685
4578
  ];
2686
4579
  #e;
2687
- #t = t(1);
2688
- #n = t(1);
2689
- #r = t(1);
2690
- #i = t(1);
2691
- #a = t(!1);
4580
+ #t = _(1);
4581
+ #n = _(1);
4582
+ #r = _(1);
4583
+ #i = _(1);
4584
+ #a = _(!1);
2692
4585
  constructor() {
2693
4586
  super(), this.#e = this.attachInternals(), this.#e.role = "navigation";
2694
4587
  }
@@ -2747,10 +4640,10 @@ var ue = class extends S(_) {
2747
4640
  setup() {
2748
4641
  super.setup();
2749
4642
  let e = this.getAttribute("aria-label") ?? "Pagination";
2750
- this.#e.ariaLabel = e, this.hasAttribute("aria-label") || this.setAttribute("aria-label", e), this.addEffect(w(this, this.#a, this.#e)), this.addEffect(() => {
4643
+ this.#e.ariaLabel = e, this.hasAttribute("aria-label") || this.setAttribute("aria-label", e), this.addEffect(j(this, this.#a, this.#e)), this.addEffect(() => {
2751
4644
  this.#l();
2752
4645
  }), this.addEffect(() => {
2753
- let e = this.#a.value, t = i(() => this.#n.value), n = i(() => this.#t.value);
4646
+ let e = this.#a.value, t = x(() => this.#n.value), n = x(() => this.#t.value);
2754
4647
  for (let r of this.querySelectorAll("ui-button")) {
2755
4648
  let i = r.getAttribute("aria-label") ?? "";
2756
4649
  i === "Previous page" ? r.toggleAttribute("disabled", e || t <= 1) : i === "Next page" ? r.toggleAttribute("disabled", e || t >= n) : r.toggleAttribute("disabled", e);
@@ -2784,7 +4677,7 @@ var ue = class extends S(_) {
2784
4677
  return a.setAttribute("name", e), i.appendChild(a), i.addEventListener("ui-press", r), i;
2785
4678
  }
2786
4679
  #l() {
2787
- let e = this.#t.value, t = this.#n.value, n = i(() => this.#a.value), r = this.#o();
4680
+ let e = this.#t.value, t = this.#n.value, n = x(() => this.#a.value), r = this.#o();
2788
4681
  this.textContent = "", this.appendChild(this.#c("caret-left", "Previous page", n || t <= 1, () => this.#u(t - 1)));
2789
4682
  for (let e of r) if (e === "ellipsis") {
2790
4683
  let e = document.createElement("span");
@@ -2804,7 +4697,7 @@ var ue = class extends S(_) {
2804
4697
  detail: { value: t }
2805
4698
  })));
2806
4699
  }
2807
- }, xe = class extends _ {
4700
+ }, it = class extends k {
2808
4701
  #e;
2809
4702
  get open() {
2810
4703
  return this.#e.open;
@@ -2816,15 +4709,15 @@ var ue = class extends S(_) {
2816
4709
  this.#e.close();
2817
4710
  }
2818
4711
  setup() {
2819
- super.setup(), this.#e = new s(this, { contentTarget: () => document.createElement("ui-drawer-panel") });
4712
+ super.setup(), this.#e = new Y(this, { contentTarget: () => document.createElement("ui-drawer-panel") });
2820
4713
  }
2821
4714
  teardown() {
2822
4715
  this.#e.destroy(), super.teardown();
2823
4716
  }
2824
- }, Se = class extends _ {
4717
+ }, at = class extends k {
2825
4718
  static observedAttributes = ["disabled"];
2826
4719
  #e;
2827
- #t = t(!1);
4720
+ #t = _(!1);
2828
4721
  #n;
2829
4722
  constructor() {
2830
4723
  super(), this.#e = this.attachInternals(), this.#e.role = "tree";
@@ -2839,17 +4732,17 @@ var ue = class extends S(_) {
2839
4732
  t !== n && (e === "disabled" && (this.#t.value = n !== null), super.attributeChangedCallback?.(e, t, n));
2840
4733
  }
2841
4734
  setup() {
2842
- super.setup(), this.#n = new f(this, {
4735
+ super.setup(), this.#n = new G(this, {
2843
4736
  selector: ":scope ui-tree-item > [slot=\"label\"]",
2844
4737
  orientation: "vertical"
2845
4738
  });
2846
4739
  let e = this.getAttribute("aria-label") ?? "Tree";
2847
- this.#e.ariaLabel = e, this.hasAttribute("aria-label") || this.setAttribute("aria-label", e), this.addEffect(w(this, this.#t, this.#e));
4740
+ this.#e.ariaLabel = e, this.hasAttribute("aria-label") || this.setAttribute("aria-label", e), this.addEffect(j(this, this.#t, this.#e));
2848
4741
  }
2849
4742
  teardown() {
2850
4743
  this.#n.destroy(), super.teardown();
2851
4744
  }
2852
- }, Ce = class extends _ {
4745
+ }, ot = class extends k {
2853
4746
  static observedAttributes = [
2854
4747
  "expanded",
2855
4748
  "selected",
@@ -2858,7 +4751,7 @@ var ue = class extends S(_) {
2858
4751
  #e;
2859
4752
  #t = null;
2860
4753
  #n = null;
2861
- #r = t(!1);
4754
+ #r = _(!1);
2862
4755
  constructor() {
2863
4756
  super(), this.#e = this.attachInternals(), this.#e.role = "treeitem";
2864
4757
  }
@@ -2881,7 +4774,7 @@ var ue = class extends S(_) {
2881
4774
  this.#r.value = e, this.toggleAttribute("disabled", e);
2882
4775
  }
2883
4776
  setup() {
2884
- super.setup(), this.addEffect(w(this, this.#r, this.#e)), this.deferChildren(() => {
4777
+ super.setup(), this.addEffect(j(this, this.#r, this.#e)), this.deferChildren(() => {
2885
4778
  this.#i(), this.#a();
2886
4779
  }), this.addEventListener("click", this.#o), this.addEventListener("keydown", this.#s);
2887
4780
  }
@@ -2943,7 +4836,7 @@ var ue = class extends S(_) {
2943
4836
  break;
2944
4837
  }
2945
4838
  };
2946
- }, we = class extends _ {
4839
+ }, st = class extends k {
2947
4840
  static observedAttributes = [
2948
4841
  "direction",
2949
4842
  "controls",
@@ -2961,9 +4854,9 @@ var ue = class extends S(_) {
2961
4854
  #n = null;
2962
4855
  #r = null;
2963
4856
  #i = null;
2964
- #a = t(0);
2965
- #o = t(0);
2966
- #s = t(!1);
4857
+ #a = _(0);
4858
+ #o = _(0);
4859
+ #s = _(!1);
2967
4860
  #c = null;
2968
4861
  #l = null;
2969
4862
  #u = null;
@@ -3024,7 +4917,7 @@ var ue = class extends S(_) {
3024
4917
  setup() {
3025
4918
  super.setup(), this.#l = window.matchMedia("(prefers-reduced-motion: reduce)");
3026
4919
  let e = document.createElement("div");
3027
- e.setAttribute("part", "track"), e.id = r("ss-track"), e.setAttribute("tabindex", "0");
4920
+ e.setAttribute("part", "track"), e.id = A("ss-track"), e.setAttribute("tabindex", "0");
3028
4921
  let t = [];
3029
4922
  for (; this.firstChild;) {
3030
4923
  let n = this.firstChild;
@@ -3033,17 +4926,17 @@ var ue = class extends S(_) {
3033
4926
  this.appendChild(e), this.#e = e, this.#d = t;
3034
4927
  let n = document.createElement("div");
3035
4928
  n.setAttribute("part", "controls");
4929
+ let r = document.createElement("button");
4930
+ r.setAttribute("part", "prev"), r.setAttribute("aria-label", "Previous slide"), r.setAttribute("type", "button"), r.innerHTML = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 256 256\" aria-hidden=\"true\" focusable=\"false\"><path d=\"M165.66,202.34a8,8,0,0,1-11.32,11.32l-80-80a8,8,0,0,1,0-11.32l80-80a8,8,0,0,1,11.32,11.32L91.31,128Z\" fill=\"currentColor\"/></svg>";
3036
4931
  let i = document.createElement("button");
3037
- i.setAttribute("part", "prev"), i.setAttribute("aria-label", "Previous slide"), i.setAttribute("type", "button"), i.innerHTML = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 256 256\" aria-hidden=\"true\" focusable=\"false\"><path d=\"M165.66,202.34a8,8,0,0,1-11.32,11.32l-80-80a8,8,0,0,1,0-11.32l80-80a8,8,0,0,1,11.32,11.32L91.31,128Z\" fill=\"currentColor\"/></svg>";
3038
- let a = document.createElement("button");
3039
- a.setAttribute("part", "next"), a.setAttribute("aria-label", "Next slide"), a.setAttribute("type", "button"), a.innerHTML = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 256 256\" aria-hidden=\"true\" focusable=\"false\"><path d=\"M181.66,133.66l-80,80a8,8,0,0,1-11.32-11.32L164.69,128,90.34,53.66a8,8,0,0,1,11.32-11.32l80,80A8,8,0,0,1,181.66,133.66Z\" fill=\"currentColor\"/></svg>", n.appendChild(i), n.appendChild(a), this.appendChild(n), this.#n = i, this.#r = a;
4932
+ i.setAttribute("part", "next"), i.setAttribute("aria-label", "Next slide"), i.setAttribute("type", "button"), i.innerHTML = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 256 256\" aria-hidden=\"true\" focusable=\"false\"><path d=\"M181.66,133.66l-80,80a8,8,0,0,1-11.32-11.32L164.69,128,90.34,53.66a8,8,0,0,1,11.32-11.32l80,80A8,8,0,0,1,181.66,133.66Z\" fill=\"currentColor\"/></svg>", n.appendChild(r), n.appendChild(i), this.appendChild(n), this.#n = r, this.#r = i;
4933
+ let a = document.createElement("div");
4934
+ a.setAttribute("part", "indicators"), a.setAttribute("aria-hidden", "true"), this.appendChild(a), this.#t = a;
3040
4935
  let o = document.createElement("div");
3041
- o.setAttribute("part", "indicators"), o.setAttribute("aria-hidden", "true"), this.appendChild(o), this.#t = o;
3042
- let s = document.createElement("div");
3043
- s.id = r("ss-live"), s.setAttribute("aria-live", "polite"), s.setAttribute("aria-atomic", "true"), s.setAttribute("data-visually-hidden", ""), this.appendChild(s), this.#i = s, this.setAttribute("aria-roledescription", "carousel"), this.hasAttribute("aria-label") || this.setAttribute("aria-label", "Slideshow"), this.#v(this.getAttribute("per-view")), this.#o.value = t.length, this.#y(t), this.#b(t.length), this.#S(t), t.length > 0 && t[0].toggleAttribute("active", !0), this.addEffect(() => {
4936
+ o.id = A("ss-live"), o.setAttribute("aria-live", "polite"), o.setAttribute("aria-atomic", "true"), o.setAttribute("data-visually-hidden", ""), this.appendChild(o), this.#i = o, this.setAttribute("aria-roledescription", "carousel"), this.hasAttribute("aria-label") || this.setAttribute("aria-label", "Slideshow"), this.#v(this.getAttribute("per-view")), this.#o.value = t.length, this.#y(t), this.#b(t.length), this.#S(t), t.length > 0 && t[0].toggleAttribute("active", !0), this.addEffect(() => {
3044
4937
  let e = this.#a.value, t = this.#o.value;
3045
4938
  this.#C(e), this.#w(e, t), this.#i && (this.#i.textContent = `Slide ${e + 1} of ${t}`);
3046
- }), this.addEffect(w(this, this.#s, this.#_)), i.addEventListener("click", this.#D), a.addEventListener("click", this.#O), e.addEventListener("keydown", this.#P), e.addEventListener("pointerdown", this.#j), this.addEventListener("mouseenter", this.#k), this.addEventListener("mouseleave", this.#A), this.addEventListener("focusin", this.#k), this.addEventListener("focusout", this.#A), this.hasAttribute("autoplay") && this.#T();
4939
+ }), this.addEffect(j(this, this.#s, this.#_)), r.addEventListener("click", this.#D), i.addEventListener("click", this.#O), e.addEventListener("keydown", this.#P), e.addEventListener("pointerdown", this.#j), this.addEventListener("mouseenter", this.#k), this.addEventListener("mouseleave", this.#A), this.addEventListener("focusin", this.#k), this.addEventListener("focusout", this.#A), this.hasAttribute("autoplay") && this.#T();
3047
4940
  }
3048
4941
  teardown() {
3049
4942
  this.#E(), this.#u?.disconnect(), this.#u = null, this.#n?.removeEventListener("click", this.#D), this.#r?.removeEventListener("click", this.#O), this.#e?.removeEventListener("keydown", this.#P), this.#e?.removeEventListener("pointerdown", this.#j), this.removeEventListener("mouseenter", this.#k), this.removeEventListener("mouseleave", this.#A), this.removeEventListener("focusin", this.#k), this.removeEventListener("focusout", this.#A), this.#e = null, this.#t?.removeEventListener("click", this.#x), this.#t && (this.#t.innerHTML = ""), this.#t = null, this.#n = null, this.#r = null, this.#i = null, this.#d = [], super.teardown();
@@ -3055,8 +4948,8 @@ var ue = class extends S(_) {
3055
4948
  #y(e) {
3056
4949
  let t = e.length;
3057
4950
  for (let n = 0; n < t; n++) {
3058
- let i = e[n];
3059
- i.setAttribute("role", "group"), i.setAttribute("aria-roledescription", "slide"), i.setAttribute("aria-label", `${n + 1} of ${t}`), i.id ||= r("slide");
4951
+ let r = e[n];
4952
+ r.setAttribute("role", "group"), r.setAttribute("aria-roledescription", "slide"), r.setAttribute("aria-label", `${n + 1} of ${t}`), r.id ||= A("slide");
3060
4953
  }
3061
4954
  }
3062
4955
  #b(e) {
@@ -3162,17 +5055,17 @@ var ue = class extends S(_) {
3162
5055
  break;
3163
5056
  }
3164
5057
  };
3165
- }, Te = class extends _ {
5058
+ }, ct = class extends k {
3166
5059
  setup() {
3167
5060
  super.setup(), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "-1");
3168
5061
  }
3169
- }, Ee = class extends _ {
5062
+ }, lt = class extends k {
3170
5063
  static observedAttributes = ["value", "disabled"];
3171
5064
  #e;
3172
5065
  #t;
3173
5066
  #n;
3174
5067
  constructor() {
3175
- super(), this.#e = this.attachInternals(), this.#e.role = "navigation", this.#t = x(this, "disabled", { type: "boolean" });
5068
+ super(), this.#e = this.attachInternals(), this.#e.role = "navigation", this.#t = M(this, "disabled", { type: "boolean" });
3176
5069
  }
3177
5070
  get value() {
3178
5071
  return this.#n?.listValue.value ?? null;
@@ -3188,7 +5081,7 @@ var ue = class extends S(_) {
3188
5081
  }
3189
5082
  attributeChangedCallback(e, t, n) {
3190
5083
  if (t !== n) {
3191
- if (v({ disabled: this.#t }, e, n)) {
5084
+ if (N({ disabled: this.#t }, e, n)) {
3192
5085
  super.attributeChangedCallback?.(e, t, n);
3193
5086
  return;
3194
5087
  }
@@ -3196,7 +5089,7 @@ var ue = class extends S(_) {
3196
5089
  }
3197
5090
  }
3198
5091
  setup() {
3199
- super.setup(), this.#n = new g(this, {
5092
+ super.setup(), this.#n = new J(this, {
3200
5093
  itemSelector: ":scope ui-nav-item:not([disabled])",
3201
5094
  orientation: "vertical",
3202
5095
  ariaAttr: "aria-current",
@@ -3212,23 +5105,23 @@ var ue = class extends S(_) {
3212
5105
  deferChildren: (e) => this.deferChildren(e)
3213
5106
  });
3214
5107
  let e = this.getAttribute("value");
3215
- e !== null && (this.#n.listValue.value = e), this.addEffect(w(this, this.#t.signal, this.#e));
5108
+ e !== null && (this.#n.listValue.value = e), this.addEffect(j(this, this.#t.signal, this.#e));
3216
5109
  }
3217
5110
  teardown() {
3218
5111
  this.#n.destroy(), super.teardown();
3219
5112
  }
3220
- }, De = class extends _ {
5113
+ }, ut = class extends k {
3221
5114
  static observedAttributes = [
3222
5115
  "value",
3223
5116
  "disabled",
3224
5117
  "label"
3225
5118
  ];
3226
5119
  #e;
3227
- #t = t("");
5120
+ #t = _("");
3228
5121
  #n;
3229
- #r = t("");
5122
+ #r = _("");
3230
5123
  constructor() {
3231
- super(), this.#e = this.attachInternals(), this.#e.role = "link", this.#n = x(this, "disabled", { type: "boolean" });
5124
+ super(), this.#e = this.attachInternals(), this.#e.role = "link", this.#n = M(this, "disabled", { type: "boolean" });
3232
5125
  }
3233
5126
  get value() {
3234
5127
  return this.#t.value;
@@ -3250,7 +5143,7 @@ var ue = class extends S(_) {
3250
5143
  }
3251
5144
  attributeChangedCallback(e, t, n) {
3252
5145
  if (t !== n) {
3253
- if (v({ disabled: this.#n }, e, n)) {
5146
+ if (N({ disabled: this.#n }, e, n)) {
3254
5147
  super.attributeChangedCallback?.(e, t, n);
3255
5148
  return;
3256
5149
  }
@@ -3266,7 +5159,7 @@ var ue = class extends S(_) {
3266
5159
  }
3267
5160
  }
3268
5161
  setup() {
3269
- super.setup(), this.addEffect(w(this, this.#n.signal, this.#e)), this.addEventListener("click", this.#i);
5162
+ super.setup(), this.addEffect(j(this, this.#n.signal, this.#e)), this.addEventListener("click", this.#i);
3270
5163
  }
3271
5164
  teardown() {
3272
5165
  this.removeEventListener("click", this.#i), super.teardown();
@@ -3281,9 +5174,9 @@ var ue = class extends S(_) {
3281
5174
  }
3282
5175
  }));
3283
5176
  };
3284
- }, $ = class extends _ {
5177
+ }, dt = class extends k {
3285
5178
  static observedAttributes = ["open"];
3286
- #e = t(!1);
5179
+ #e = _(!1);
3287
5180
  #t = null;
3288
5181
  #n;
3289
5182
  #r = null;
@@ -3319,7 +5212,7 @@ var ue = class extends S(_) {
3319
5212
  attributeFilter: ["aria-current"]
3320
5213
  }), this.#s();
3321
5214
  let r = document.createElement("ui-listbox");
3322
- r.setAttribute("popover", "manual"), r.className = "nav-group-flyout", this.appendChild(r), this.#i = r, this.#a = new m(this), this.#a.wirePopover(this, r), r.addEventListener("ui-select", this.#u), r.addEventListener("ui-change", this.#d), this.addEventListener("ui-dismiss", this.#l);
5215
+ r.setAttribute("popover", "manual"), r.className = "nav-group-flyout", this.appendChild(r), this.#i = r, this.#a = new q(this), this.#a.wirePopover(this, r), r.addEventListener("ui-select", this.#u), r.addEventListener("ui-change", this.#d), this.addEventListener("ui-dismiss", this.#l);
3323
5216
  }
3324
5217
  teardown() {
3325
5218
  this.closeFlyout(), this.#a?.destroy(), this.#a = null, this.#i?.remove(), this.#i = null, this.#r?.disconnect(), this.#r = null, this.#t?.removeEventListener("toggle", this.#c), this.#t = null, super.teardown();
@@ -3368,14 +5261,14 @@ var ue = class extends S(_) {
3368
5261
  #d = (e) => {
3369
5262
  e.stopPropagation();
3370
5263
  };
3371
- }, Oe = class extends _ {
5264
+ }, ft = class extends k {
3372
5265
  constructor() {
3373
5266
  super();
3374
5267
  let e = this.attachInternals();
3375
5268
  e.role = "presentation";
3376
5269
  }
3377
5270
  setup() {
3378
- super.setup(), this.id ||= r("ngh");
5271
+ super.setup(), this.id ||= A("ngh");
3379
5272
  let e = this.closest("ui-nav-group");
3380
5273
  e && e.setAttribute("aria-labelledby", this.id);
3381
5274
  let t = this.querySelector(":scope > ui-icon");
@@ -3384,7 +5277,7 @@ var ue = class extends S(_) {
3384
5277
  e.className = "icon-well", this.insertBefore(e, t), e.appendChild(t);
3385
5278
  }
3386
5279
  }
3387
- }, ke = class extends _ {
5280
+ }, pt = class extends k {
3388
5281
  static observedAttributes = [
3389
5282
  "traits",
3390
5283
  "for",
@@ -3420,7 +5313,7 @@ var ue = class extends S(_) {
3420
5313
  let e = this.getAttribute("traits");
3421
5314
  if (!e) return;
3422
5315
  let t = this.getAttribute("for");
3423
- t === null ? this.#s(e) : this.#c(e, t), this.#r.size > 0 && !this.#i && (this.#i = d((e) => {
5316
+ t === null ? this.#s(e) : this.#c(e, t), this.#r.size > 0 && !this.#i && (this.#i = w((e) => {
3424
5317
  this.#r.has(e) && (this.#r.delete(e), this.#o(), this.#r.size === 0 && (this.#i?.(), this.#i = null));
3425
5318
  }));
3426
5319
  }
@@ -3457,16 +5350,16 @@ var ue = class extends S(_) {
3457
5350
  let n = t.split(/\s+/).filter(Boolean), r = this.#e.get(e) ?? /* @__PURE__ */ new Map();
3458
5351
  for (let t of n) {
3459
5352
  if (r.has(t)) continue;
3460
- let n = p(t);
5353
+ let n = T(t);
3461
5354
  if (!n) {
3462
5355
  this.#r.add(t);
3463
5356
  continue;
3464
5357
  }
3465
- for (let [e] of r) if (p(e)?.conflicts?.includes(t) || n.conflicts?.includes(e)) {
5358
+ for (let [e] of r) if (T(e)?.conflicts?.includes(t) || n.conflicts?.includes(e)) {
3466
5359
  let n = `[native-ui] Trait conflict: "${t}" and "${e}" are incompatible.`;
3467
5360
  console.warn(n);
3468
5361
  }
3469
- let i = l(this, t), a = n.create(e, i);
5362
+ let i = O(this, t), a = n.create(e, i);
3470
5363
  r.set(t, a);
3471
5364
  }
3472
5365
  this.#e.set(e, r);
@@ -3477,7 +5370,7 @@ var ue = class extends S(_) {
3477
5370
  }
3478
5371
  #f(e, t) {
3479
5372
  for (let [e, n] of t) {
3480
- let t = p(e);
5373
+ let t = T(e);
3481
5374
  t && t.destroy(n);
3482
5375
  }
3483
5376
  t.clear();
@@ -3491,11 +5384,11 @@ var ue = class extends S(_) {
3491
5384
  this.#n = new MutationObserver((e) => {
3492
5385
  for (let t of e) {
3493
5386
  if (!t.attributeName) continue;
3494
- let e = u(t.attributeName);
5387
+ let e = D(t.attributeName);
3495
5388
  if (!e) continue;
3496
- let n = p(e.trait);
5389
+ let n = T(e.trait);
3497
5390
  if (!n?.update) continue;
3498
- let r = l(this, e.trait);
5391
+ let r = O(this, e.trait);
3499
5392
  for (let [, t] of this.#e) {
3500
5393
  let i = t.get(e.trait);
3501
5394
  i && n.update(i, r);
@@ -3510,17 +5403,17 @@ var ue = class extends S(_) {
3510
5403
  }
3511
5404
  /** Collect all attributes on this element that match any registered trait prefix. */
3512
5405
  #h() {
3513
- let e = h(), t = [];
5406
+ let e = E(), t = [];
3514
5407
  for (let n of this.attributes) for (let r of e) if (n.name.startsWith(r + "-")) {
3515
5408
  t.push(n.name);
3516
5409
  break;
3517
5410
  }
3518
5411
  return t;
3519
5412
  }
3520
- }, Ae = class extends _ {
5413
+ }, mt = class extends k {
3521
5414
  static observedAttributes = ["disabled"];
3522
5415
  #e;
3523
- #t = t(!1);
5416
+ #t = _(!1);
3524
5417
  #n = null;
3525
5418
  #r = null;
3526
5419
  constructor() {
@@ -3549,7 +5442,7 @@ var ue = class extends S(_) {
3549
5442
  }
3550
5443
  }
3551
5444
  setup() {
3552
- super.setup(), this.addEffect(w(this, this.#t, this.#e)), this.deferChildren(() => {
5445
+ super.setup(), this.addEffect(j(this, this.#t, this.#e)), this.deferChildren(() => {
3553
5446
  this.#i(), this.addEffect(() => {
3554
5447
  let e = this.#t.value;
3555
5448
  this.#n && this.#n.toggleAttribute("disabled", e), this.#r && (e ? this.#r.setAttribute("disabled", "") : this.#o());
@@ -3593,7 +5486,7 @@ var ue = class extends S(_) {
3593
5486
  detail: { value: e }
3594
5487
  })) && !this.hasAttribute("no-auto-clear") && (this.value = "", this.#r?.setAttribute("disabled", ""));
3595
5488
  }
3596
- }, je = class extends _ {
5489
+ }, ht = class extends k {
3597
5490
  static observedAttributes = ["interactive", "href"];
3598
5491
  setup() {
3599
5492
  super.setup(), this.hasAttribute("interactive") && (this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.addEventListener("click", this.#e), this.addEventListener("keydown", this.#t));
@@ -3608,7 +5501,7 @@ var ue = class extends S(_) {
3608
5501
  #t = (e) => {
3609
5502
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), this.#e());
3610
5503
  };
3611
- }, Me = class extends _ {
5504
+ }, gt = class extends k {
3612
5505
  static observedAttributes = [
3613
5506
  "collapsible",
3614
5507
  "collapsed",
@@ -3627,14 +5520,14 @@ var ue = class extends S(_) {
3627
5520
  #e = () => {
3628
5521
  this.hasAttribute("collapsible") && this.toggleAttribute("collapsed");
3629
5522
  };
3630
- }, Ne = class extends _ {
5523
+ }, _t = class extends k {
3631
5524
  #e;
3632
5525
  #t;
3633
5526
  constructor() {
3634
5527
  super(), this.#e = this.attachInternals(), this.#e.role = "toolbar";
3635
5528
  }
3636
5529
  setup() {
3637
- super.setup(), this.#t = new f(this, {
5530
+ super.setup(), this.#t = new G(this, {
3638
5531
  selector: ":scope > ui-button:not([disabled]), :scope > button:not([disabled])",
3639
5532
  orientation: "horizontal"
3640
5533
  }), this.hasAttribute("aria-label") || this.setAttribute("aria-label", "Toolbar");
@@ -3642,7 +5535,7 @@ var ue = class extends S(_) {
3642
5535
  teardown() {
3643
5536
  this.#t.destroy(), super.teardown();
3644
5537
  }
3645
- }, Pe = class extends _ {
5538
+ }, vt = class extends k {
3646
5539
  static observedAttributes = ["collapsed"];
3647
5540
  #e = null;
3648
5541
  #t = null;
@@ -3654,7 +5547,7 @@ var ue = class extends S(_) {
3654
5547
  setup() {
3655
5548
  super.setup();
3656
5549
  let e = this.querySelector(":scope > [slot=\"sidebar\"]");
3657
- e?.querySelector(".layout-resize-handle") && (this.#e = new a(e, {
5550
+ e?.querySelector(".layout-resize-handle") && (this.#e = new U(e, {
3658
5551
  handleSelector: ".layout-resize-handle",
3659
5552
  axis: "horizontal",
3660
5553
  min: 160,
@@ -3710,13 +5603,13 @@ var ue = class extends S(_) {
3710
5603
  for (let e of a) this.#t.observe(e);
3711
5604
  }
3712
5605
  }
3713
- }, Fe = class extends _ {
5606
+ }, yt = class extends k {
3714
5607
  #e = null;
3715
5608
  #t = !1;
3716
5609
  setup() {
3717
5610
  super.setup();
3718
5611
  let e = this.querySelector(":scope > ui-listbox[popover]");
3719
- e && (this.#e = new m(this), this.#e.wirePopover(this, e), this.addEventListener("click", this.#n), this.addEventListener("ui-dismiss", this.#r));
5612
+ e && (this.#e = new q(this), this.#e.wirePopover(this, e), this.addEventListener("click", this.#n), this.addEventListener("ui-dismiss", this.#r));
3720
5613
  }
3721
5614
  teardown() {
3722
5615
  this.removeEventListener("click", this.#n), this.removeEventListener("ui-dismiss", this.#r), this.#e?.destroy(), this.#e = null, this.#t = !1, super.teardown();
@@ -3727,7 +5620,7 @@ var ue = class extends S(_) {
3727
5620
  #r = () => {
3728
5621
  this.#t = !1, this.#e?.syncPopover(!1);
3729
5622
  };
3730
- }, Ie = class extends _ {
5623
+ }, bt = class extends k {
3731
5624
  #e = null;
3732
5625
  get open() {
3733
5626
  return this.hasAttribute("open");
@@ -3739,7 +5632,7 @@ var ue = class extends S(_) {
3739
5632
  this.open = !this.open;
3740
5633
  }
3741
5634
  setup() {
3742
- super.setup(), this.querySelector(".layout-resize-handle") && (this.#e = new a(this, {
5635
+ super.setup(), this.querySelector(".layout-resize-handle") && (this.#e = new U(this, {
3743
5636
  handleSelector: ".layout-resize-handle",
3744
5637
  axis: "horizontal",
3745
5638
  min: 280,
@@ -3750,7 +5643,7 @@ var ue = class extends S(_) {
3750
5643
  teardown() {
3751
5644
  this.#e?.destroy(), this.#e = null, super.teardown();
3752
5645
  }
3753
- }, Le = class extends _ {
5646
+ }, xt = class extends k {
3754
5647
  #e = null;
3755
5648
  get open() {
3756
5649
  return this.hasAttribute("open");
@@ -3762,7 +5655,7 @@ var ue = class extends S(_) {
3762
5655
  this.open = !this.open;
3763
5656
  }
3764
5657
  setup() {
3765
- super.setup(), this.querySelector(".layout-resize-handle") && (this.#e = new a(this, {
5658
+ super.setup(), this.querySelector(".layout-resize-handle") && (this.#e = new U(this, {
3766
5659
  handleSelector: ".layout-resize-handle",
3767
5660
  axis: "horizontal",
3768
5661
  min: 280,
@@ -3774,4 +5667,4 @@ var ue = class extends S(_) {
3774
5667
  this.#e?.destroy(), this.#e = null, super.teardown();
3775
5668
  }
3776
5669
  };
3777
- export { A as $, Q as A, W as B, ge as C, fe as D, pe as E, Y as F, R as G, V as H, J as I, F as J, L as K, q as L, se as M, oe as N, de as O, ae as P, j as Q, G as R, _e as S, me as T, B as U, H as V, z as W, N as X, P as Y, M as Z, Se as _, Ne as a, ie as at, ye as b, Ae as c, te as ct, $ as d, k as et, De as f, Ce as g, we as h, Pe as i, T as it, le as j, ue as k, ke as l, ee as lt, Te as m, Ie as n, D as nt, Me as o, re as ot, Ee as p, I as q, Fe as r, E as rt, je as s, ne as st, Le as t, O as tt, Oe as u, xe as v, he as w, ve as x, be as y, U as z };
5670
+ export { Ce as $, Ke as A, R as At, Ie as B, E as Bt, $e as C, H as Ct, Ye as D, oe as Dt, Xe as E, z as Et, Ve as F, j as Ft, je as G, y as Gt, X as H, re as Ht, Be as I, A as It, Oe as J, u as Jt, Ae as K, v as Kt, ze as L, k as Lt, We as M, P as Mt, $ as N, M as Nt, Je as O, I as Ot, Ue as P, N as Pt, we as Q, Re as R, O as Rt, et as S, U as St, Ze as T, B as Tt, Ne as U, x as Ut, Pe as V, T as Vt, Me as W, b as Wt, Ee as X, De as Y, r as Yt, Te as Z, at as _, J as _t, _t as a, _e as at, nt as b, G as bt, mt as c, me as ct, dt as d, de as dt, Se as et, ut as f, ue as ft, ot as g, Y as gt, st as h, se as ht, vt as i, ve as it, Ge as j, F as jt, qe as k, L as kt, pt as l, pe as lt, ct as m, ce as mt, bt as n, be as nt, gt as o, ge as ot, lt as p, le as pt, ke as q, _ as qt, yt as r, ye as rt, ht as s, he as st, xt as t, xe as tt, ft as u, fe as ut, it as v, q as vt, Qe as w, V as wt, tt as x, W as xt, rt as y, K as yt, Le as z, D as zt };