screenreader-speech-capture 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/dist/cli.mjs +31 -3
  2. package/dist/ui/adapter-node.js +1 -1
  3. package/dist/ui/client/ui/_app/immutable/assets/{0.CeDGT9MW.css → 0.B2ZWH0rX.css} +1 -1
  4. package/dist/ui/client/ui/_app/immutable/assets/0.B2ZWH0rX.css.br +0 -0
  5. package/dist/ui/client/ui/_app/immutable/assets/0.B2ZWH0rX.css.gz +0 -0
  6. package/dist/ui/client/ui/_app/immutable/assets/2.CtITS5jU.css +1 -0
  7. package/dist/ui/client/ui/_app/immutable/assets/2.CtITS5jU.css.br +0 -0
  8. package/dist/ui/client/ui/_app/immutable/assets/2.CtITS5jU.css.gz +0 -0
  9. package/dist/ui/client/ui/_app/immutable/chunks/w6UAqFO5.js +37 -0
  10. package/dist/ui/client/ui/_app/immutable/chunks/w6UAqFO5.js.br +0 -0
  11. package/dist/ui/client/ui/_app/immutable/chunks/w6UAqFO5.js.gz +0 -0
  12. package/dist/ui/client/ui/_app/immutable/entry/{app.2mjWY9ga.js → app.COo3YJBG.js} +2 -2
  13. package/dist/ui/client/ui/_app/immutable/entry/app.COo3YJBG.js.br +2 -0
  14. package/dist/ui/client/ui/_app/immutable/entry/app.COo3YJBG.js.gz +0 -0
  15. package/dist/ui/client/ui/_app/immutable/nodes/{0.CQ_XophD.js → 0.BKE0tKKK.js} +1 -1
  16. package/dist/ui/client/ui/_app/immutable/nodes/0.BKE0tKKK.js.br +0 -0
  17. package/dist/ui/client/ui/_app/immutable/nodes/0.BKE0tKKK.js.gz +0 -0
  18. package/dist/ui/client/ui/_app/immutable/nodes/2.BCy3UgNz.js +227 -0
  19. package/dist/ui/client/ui/_app/immutable/nodes/2.BCy3UgNz.js.br +0 -0
  20. package/dist/ui/client/ui/_app/immutable/nodes/2.BCy3UgNz.js.gz +0 -0
  21. package/dist/ui/client/ui/_app/version.json +1 -1
  22. package/dist/ui/client/ui/_app/version.json.br +0 -0
  23. package/dist/ui/client/ui/_app/version.json.gz +0 -0
  24. package/dist/ui/server/.vite/manifest.json +33 -2
  25. package/dist/ui/server/_app/immutable/assets/{_layout.CeDGT9MW.css → _layout.B2ZWH0rX.css} +1 -1
  26. package/dist/ui/server/_app/immutable/assets/_page.CtITS5jU.css +1 -0
  27. package/dist/ui/server/chunks/bridge-api.js +29 -1
  28. package/dist/ui/server/chunks/bridge-api.js.map +1 -1
  29. package/dist/ui/server/chunks/composition.js +2863 -2
  30. package/dist/ui/server/chunks/composition.js.map +1 -1
  31. package/dist/ui/server/chunks/instance.js +3 -3
  32. package/dist/ui/server/chunks/internal.js +1 -1
  33. package/dist/ui/server/chunks/src.js +29 -2
  34. package/dist/ui/server/chunks/src.js.map +1 -1
  35. package/dist/ui/server/entries/endpoints/api/markers/_server.ts.js +14 -0
  36. package/dist/ui/server/entries/endpoints/api/markers/_server.ts.js.map +1 -0
  37. package/dist/ui/server/entries/endpoints/api/sessions/_server.ts.js +1 -1
  38. package/dist/ui/server/entries/endpoints/api/speech/_server.ts.js +21 -0
  39. package/dist/ui/server/entries/endpoints/api/speech/_server.ts.js.map +1 -0
  40. package/dist/ui/server/entries/endpoints/api/speech/stream/_server.ts.js +19 -0
  41. package/dist/ui/server/entries/endpoints/api/speech/stream/_server.ts.js.map +1 -0
  42. package/dist/ui/server/entries/pages/_layout.svelte.js +1 -3
  43. package/dist/ui/server/entries/pages/_layout.svelte.js.map +1 -1
  44. package/dist/ui/server/entries/pages/_page.svelte.js +2659 -39
  45. package/dist/ui/server/entries/pages/_page.svelte.js.map +1 -1
  46. package/dist/ui/server/manifest-full.js +22 -1
  47. package/dist/ui/server/manifest.js +22 -1
  48. package/dist/ui/server/nodes/0.js +2 -2
  49. package/dist/ui/server/nodes/2.js +2 -2
  50. package/dist/ui/server/server.js +22 -1
  51. package/package.json +1 -1
  52. package/dist/ui/client/ui/_app/immutable/assets/0.CeDGT9MW.css.br +0 -0
  53. package/dist/ui/client/ui/_app/immutable/assets/0.CeDGT9MW.css.gz +0 -0
  54. package/dist/ui/client/ui/_app/immutable/assets/2.DJfIfRJB.css +0 -1
  55. package/dist/ui/client/ui/_app/immutable/assets/2.DJfIfRJB.css.br +0 -0
  56. package/dist/ui/client/ui/_app/immutable/assets/2.DJfIfRJB.css.gz +0 -0
  57. package/dist/ui/client/ui/_app/immutable/chunks/DSHrAZZ8.js +0 -37
  58. package/dist/ui/client/ui/_app/immutable/chunks/DSHrAZZ8.js.br +0 -0
  59. package/dist/ui/client/ui/_app/immutable/chunks/DSHrAZZ8.js.gz +0 -0
  60. package/dist/ui/client/ui/_app/immutable/entry/app.2mjWY9ga.js.br +0 -0
  61. package/dist/ui/client/ui/_app/immutable/entry/app.2mjWY9ga.js.gz +0 -0
  62. package/dist/ui/client/ui/_app/immutable/nodes/0.CQ_XophD.js.br +0 -0
  63. package/dist/ui/client/ui/_app/immutable/nodes/0.CQ_XophD.js.gz +0 -0
  64. package/dist/ui/client/ui/_app/immutable/nodes/2.BTJ1n3E7.js +0 -224
  65. package/dist/ui/client/ui/_app/immutable/nodes/2.BTJ1n3E7.js.br +0 -0
  66. package/dist/ui/client/ui/_app/immutable/nodes/2.BTJ1n3E7.js.gz +0 -0
  67. package/dist/ui/server/_app/immutable/assets/_page.DJfIfRJB.css +0 -1
@@ -2,28 +2,2589 @@ import { mt as resolve } from "../../chunks/internal.js";
2
2
  import { f as escape_html, i as ensure_array_like, l as attr, n as attr_style, r as derived, t as attr_class, u as clsx } from "../../chunks/server2.js";
3
3
  import { t as page } from "../../chunks/state.js";
4
4
  import { n as goto } from "../../chunks/navigation.js";
5
- import { t as sessionsStore } from "../../chunks/composition.js";
6
- import { c as API_LIMITS } from "../../chunks/src.js";
7
- import "@material/web/icon/icon.js";
8
- import "@material/web/iconbutton/icon-button.js";
9
- import "@material/web/button/text-button.js";
10
- import "@material/web/dialog/dialog.js";
11
- import "@material/web/ripple/ripple.js";
12
- import "@material/web/textfield/outlined-text-field.js";
13
- // src/lib/components/SessionsPane/EndSessionDialog.svelte
14
- function EndSessionDialog($$renderer, $$props) {
5
+ import { A as r$1, C as A, D as Z, E as T, M as i$3, N as t$1, O as e$2, P as __decorate, S as i$2, T as E, _ as EASING, b as i$4, c as logHeading, d as mixinFormAssociated, f as internals, g as u$1, h as i$5, j as n$2, k as e$1, l as mixinFormSubmitter, m as mixinDelegatesAria, n as sessionsStore, o as canAddMarker, p as mixinElementInternals, r as speechStore, s as formatReceivedTime, t as sessionsPaneStore, u as getFormValue, v as e$3, w as B, x as t$2, y as e$4 } from "../../chunks/composition.js";
6
+ import { d as API_LIMITS } from "../../chunks/src.js";
7
+ // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query-assigned-elements.js
8
+ /**
9
+ * @license
10
+ * Copyright 2021 Google LLC
11
+ * SPDX-License-Identifier: BSD-3-Clause
12
+ */ function o$1(o) {
13
+ return (e, n) => {
14
+ const { slot: r, selector: s } = o ?? {}, c = "slot" + (r ? `[name=${r}]` : ":not([name])");
15
+ return e$1(e, n, { get() {
16
+ const e = (this.renderRoot?.querySelector(c))?.assignedElements(o) ?? [];
17
+ return void 0 === s ? e : e.filter((t) => t.matches(s));
18
+ } });
19
+ };
20
+ }
21
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/elevation/internal/elevation.js
22
+ /**
23
+ * @license
24
+ * Copyright 2022 Google LLC
25
+ * SPDX-License-Identifier: Apache-2.0
26
+ */
27
+ /**
28
+ * A component for elevation.
29
+ */
30
+ var Elevation = class extends i$2 {
31
+ connectedCallback() {
32
+ super.connectedCallback();
33
+ this.setAttribute("aria-hidden", "true");
34
+ }
35
+ render() {
36
+ return T`<span class="shadow"></span>`;
37
+ }
38
+ };
39
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/elevation/internal/elevation-styles.cssresult.js
40
+ /**
41
+ * @license
42
+ * Copyright 2026 Google LLC
43
+ * SPDX-License-Identifier: Apache-2.0
44
+ */
45
+ var styles$10 = i$3`:host,.shadow,.shadow::before,.shadow::after{border-radius:inherit;inset:0;position:absolute;transition-duration:inherit;transition-property:inherit;transition-timing-function:inherit}:host{display:flex;pointer-events:none;transition-property:box-shadow,opacity}.shadow::before,.shadow::after{content:"";transition-property:box-shadow,opacity;--_level: var(--md-elevation-level, 0);--_shadow-color: var(--md-elevation-shadow-color, var(--md-sys-color-shadow, #000))}.shadow::before{box-shadow:0px calc(1px*(clamp(0,var(--_level),1) + clamp(0,var(--_level) - 3,1) + 2*clamp(0,var(--_level) - 4,1))) calc(1px*(2*clamp(0,var(--_level),1) + clamp(0,var(--_level) - 2,1) + clamp(0,var(--_level) - 4,1))) 0px var(--_shadow-color);opacity:.3}.shadow::after{box-shadow:0px calc(1px*(clamp(0,var(--_level),1) + clamp(0,var(--_level) - 1,1) + 2*clamp(0,var(--_level) - 2,3))) calc(1px*(3*clamp(0,var(--_level),2) + 2*clamp(0,var(--_level) - 2,3))) calc(1px*(clamp(0,var(--_level),4) + 2*clamp(0,var(--_level) - 4,1))) var(--_shadow-color);opacity:.15}
46
+ `;
47
+ styles$10.styleSheet;
48
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/elevation/elevation.js
49
+ /**
50
+ * @license
51
+ * Copyright 2022 Google LLC
52
+ * SPDX-License-Identifier: Apache-2.0
53
+ */
54
+ /**
55
+ * The `<md-elevation>` custom element with default styles.
56
+ *
57
+ * Elevation is the relative distance between two surfaces along the z-axis.
58
+ *
59
+ * @final
60
+ * @suppress {visibility}
61
+ */
62
+ var MdElevation = class MdElevation extends Elevation {};
63
+ MdElevation.styles = [styles$10];
64
+ MdElevation = __decorate([t$1("md-elevation")], MdElevation);
65
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/internal/events/form-label-activation.js
66
+ /**
67
+ * @license
68
+ * Copyright 2021 Google LLC
69
+ * SPDX-License-Identifier: Apache-2.0
70
+ */
71
+ /**
72
+ * Dispatches a click event to the given element that triggers a native action,
73
+ * but is not composed and therefore is not seen outside the element.
74
+ *
75
+ * This is useful for responding to an external click event on the host element
76
+ * that should trigger an internal action like a button click.
77
+ *
78
+ * Note, a helper is provided because setting this up correctly is a bit tricky.
79
+ * In particular, calling `click` on an element creates a composed event, which
80
+ * is not desirable, and a manually dispatched event must specifically be a
81
+ * `MouseEvent` to trigger a native action.
82
+ *
83
+ * @example
84
+ * hostClickListener = (event: MouseEvent) {
85
+ * if (isActivationClick(event)) {
86
+ * this.dispatchActivationClick(this.buttonElement);
87
+ * }
88
+ * }
89
+ *
90
+ */
91
+ function dispatchActivationClick(element) {
92
+ const event = new MouseEvent("click", { bubbles: true });
93
+ element.dispatchEvent(event);
94
+ return event;
95
+ }
96
+ /**
97
+ * Returns true if the click event should trigger an activation behavior. The
98
+ * behavior is defined by the element and is whatever it should do when
99
+ * clicked.
100
+ *
101
+ * Typically when an element needs to handle a click, the click is generated
102
+ * from within the element and an event listener within the element implements
103
+ * the needed behavior; however, it's possible to fire a click directly
104
+ * at the element that the element should handle. This method helps
105
+ * distinguish these "external" clicks.
106
+ *
107
+ * An "external" click can be triggered in a number of ways: via a click
108
+ * on an associated label for a form associated element, calling
109
+ * `element.click()`, or calling
110
+ * `element.dispatchEvent(new MouseEvent('click', ...))`.
111
+ *
112
+ * Also works around Firefox issue
113
+ * https://bugzilla.mozilla.org/show_bug.cgi?id=1804576 by squelching
114
+ * events for a microtask after called.
115
+ *
116
+ * @example
117
+ * hostClickListener = (event: MouseEvent) {
118
+ * if (isActivationClick(event)) {
119
+ * this.dispatchActivationClick(this.buttonElement);
120
+ * }
121
+ * }
122
+ *
123
+ */
124
+ function isActivationClick(event) {
125
+ if (event.currentTarget !== event.target) return false;
126
+ if (event.composedPath()[0] !== event.target) return false;
127
+ if (event.target.disabled) return false;
128
+ return !squelchEvent(event);
129
+ }
130
+ function squelchEvent(event) {
131
+ const squelched = isSquelchingEvents;
132
+ if (squelched) {
133
+ event.preventDefault();
134
+ event.stopImmediatePropagation();
135
+ }
136
+ squelchEventsForMicrotask();
137
+ return squelched;
138
+ }
139
+ var isSquelchingEvents = false;
140
+ async function squelchEventsForMicrotask() {
141
+ isSquelchingEvents = true;
142
+ await null;
143
+ isSquelchingEvents = false;
144
+ }
145
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/button.js
146
+ /**
147
+ * @license
148
+ * Copyright 2019 Google LLC
149
+ * SPDX-License-Identifier: Apache-2.0
150
+ */
151
+ var buttonBaseClass = mixinDelegatesAria(mixinFormSubmitter(mixinFormAssociated(mixinElementInternals(i$2))));
152
+ /**
153
+ * A button component.
154
+ */
155
+ var Button = class extends buttonBaseClass {
156
+ constructor() {
157
+ super();
158
+ /**
159
+ * Whether or not the button is "soft-disabled" (disabled but still
160
+ * focusable).
161
+ *
162
+ * Use this when a button needs increased visibility when disabled. See
163
+ * https://www.w3.org/WAI/ARIA/apg/practices/keyboard-interface/#kbd_disabled_controls
164
+ * for more guidance on when this is needed.
165
+ */
166
+ this.softDisabled = false;
167
+ /**
168
+ * The URL that the link button points to.
169
+ */
170
+ this.href = "";
171
+ /**
172
+ * The filename to use when downloading the linked resource.
173
+ * If not specified, the browser will determine a filename.
174
+ * This is only applicable when the button is used as a link (`href` is set).
175
+ */
176
+ this.download = "";
177
+ /**
178
+ * Where to display the linked `href` URL for a link button. Common options
179
+ * include `_blank` to open in a new tab.
180
+ */
181
+ this.target = "";
182
+ /**
183
+ * Whether to render the icon at the inline end of the label rather than the
184
+ * inline start.
185
+ *
186
+ * _Note:_ Link buttons cannot have trailing icons.
187
+ */
188
+ this.trailingIcon = false;
189
+ /**
190
+ * Whether to display the icon or not.
191
+ */
192
+ this.hasIcon = false;
193
+ }
194
+ focus() {
195
+ this.buttonElement?.focus();
196
+ }
197
+ blur() {
198
+ this.buttonElement?.blur();
199
+ }
200
+ render() {
201
+ const isRippleDisabled = this.disabled || this.softDisabled;
202
+ const buttonOrLink = this.href ? this.renderLink() : this.renderButton();
203
+ const buttonId = this.href ? "link" : "button";
204
+ return T`
205
+ ${this.renderElevationOrOutline?.()}
206
+ <div class="background"></div>
207
+ <md-focus-ring part="focus-ring" for=${buttonId}></md-focus-ring>
208
+ <md-ripple
209
+ part="ripple"
210
+ for=${buttonId}
211
+ ?disabled="${isRippleDisabled}"></md-ripple>
212
+ ${buttonOrLink}
213
+ `;
214
+ }
215
+ renderButton() {
216
+ const { ariaLabel, ariaHasPopup, ariaExpanded } = this;
217
+ return T`<button
218
+ id="button"
219
+ class="button"
220
+ ?disabled=${this.disabled}
221
+ aria-disabled=${this.softDisabled || A}
222
+ aria-label="${ariaLabel || A}"
223
+ aria-haspopup="${ariaHasPopup || A}"
224
+ aria-expanded="${ariaExpanded || A}">
225
+ ${this.renderContent()}
226
+ </button>`;
227
+ }
228
+ renderLink() {
229
+ const { ariaLabel, ariaHasPopup, ariaExpanded } = this;
230
+ return T`<a
231
+ id="link"
232
+ class="button"
233
+ aria-label="${ariaLabel || A}"
234
+ aria-haspopup="${ariaHasPopup || A}"
235
+ aria-expanded="${ariaExpanded || A}"
236
+ aria-disabled=${this.disabled || this.softDisabled || A}
237
+ tabindex="${this.disabled && !this.softDisabled ? -1 : A}"
238
+ href=${this.href}
239
+ download=${this.download || A}
240
+ target=${this.target || A}
241
+ >${this.renderContent()}
242
+ </a>`;
243
+ }
244
+ renderContent() {
245
+ const icon = T`<slot
246
+ name="icon"
247
+ @slotchange="${this.handleSlotChange}"></slot>`;
248
+ return T`
249
+ <span class="touch"></span>
250
+ ${this.trailingIcon ? A : icon}
251
+ <span class="label"><slot></slot></span>
252
+ ${this.trailingIcon ? icon : A}
253
+ `;
254
+ }
255
+ handleClick(event) {
256
+ if (this.softDisabled || this.disabled && this.href) {
257
+ event.stopImmediatePropagation();
258
+ event.preventDefault();
259
+ return;
260
+ }
261
+ if (!isActivationClick(event) || !this.buttonElement) return;
262
+ this.focus();
263
+ dispatchActivationClick(this.buttonElement);
264
+ }
265
+ handleSlotChange() {
266
+ this.hasIcon = this.assignedIcons.length > 0;
267
+ }
268
+ };
269
+ /** @nocollapse */
270
+ Button.shadowRootOptions = {
271
+ mode: "open",
272
+ delegatesFocus: true
273
+ };
274
+ __decorate([n$2({
275
+ type: Boolean,
276
+ attribute: "soft-disabled",
277
+ reflect: true
278
+ })], Button.prototype, "softDisabled", void 0);
279
+ __decorate([n$2()], Button.prototype, "href", void 0);
280
+ __decorate([n$2()], Button.prototype, "download", void 0);
281
+ __decorate([n$2()], Button.prototype, "target", void 0);
282
+ __decorate([n$2({
283
+ type: Boolean,
284
+ attribute: "trailing-icon",
285
+ reflect: true
286
+ })], Button.prototype, "trailingIcon", void 0);
287
+ __decorate([n$2({
288
+ type: Boolean,
289
+ attribute: "has-icon",
290
+ reflect: true
291
+ })], Button.prototype, "hasIcon", void 0);
292
+ __decorate([e$2(".button")], Button.prototype, "buttonElement", void 0);
293
+ __decorate([o$1({
294
+ slot: "icon",
295
+ flatten: true
296
+ })], Button.prototype, "assignedIcons", void 0);
297
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/filled-tonal-button.js
298
+ /**
299
+ * @license
300
+ * Copyright 2021 Google LLC
301
+ * SPDX-License-Identifier: Apache-2.0
302
+ */
303
+ /**
304
+ * A filled tonal button component.
305
+ */
306
+ var FilledTonalButton = class extends Button {
307
+ renderElevationOrOutline() {
308
+ return T`<md-elevation part="elevation"></md-elevation>`;
309
+ }
310
+ };
311
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/filled-tonal-styles.cssresult.js
312
+ /**
313
+ * @license
314
+ * Copyright 2026 Google LLC
315
+ * SPDX-License-Identifier: Apache-2.0
316
+ */
317
+ var styles$9 = i$3`:host{--_container-color: var(--md-filled-tonal-button-container-color, var(--md-sys-color-secondary-container, #e8def8));--_container-elevation: var(--md-filled-tonal-button-container-elevation, 0);--_container-height: var(--md-filled-tonal-button-container-height, 40px);--_container-shadow-color: var(--md-filled-tonal-button-container-shadow-color, var(--md-sys-color-shadow, #000));--_disabled-container-color: var(--md-filled-tonal-button-disabled-container-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-container-elevation: var(--md-filled-tonal-button-disabled-container-elevation, 0);--_disabled-container-opacity: var(--md-filled-tonal-button-disabled-container-opacity, 0.12);--_disabled-label-text-color: var(--md-filled-tonal-button-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity: var(--md-filled-tonal-button-disabled-label-text-opacity, 0.38);--_focus-container-elevation: var(--md-filled-tonal-button-focus-container-elevation, 0);--_focus-label-text-color: var(--md-filled-tonal-button-focus-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_hover-container-elevation: var(--md-filled-tonal-button-hover-container-elevation, 1);--_hover-label-text-color: var(--md-filled-tonal-button-hover-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_hover-state-layer-color: var(--md-filled-tonal-button-hover-state-layer-color, var(--md-sys-color-on-secondary-container, #1d192b));--_hover-state-layer-opacity: var(--md-filled-tonal-button-hover-state-layer-opacity, 0.08);--_label-text-color: var(--md-filled-tonal-button-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_label-text-font: var(--md-filled-tonal-button-label-text-font, var(--md-sys-typescale-label-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height: var(--md-filled-tonal-button-label-text-line-height, var(--md-sys-typescale-label-large-line-height, 1.25rem));--_label-text-size: var(--md-filled-tonal-button-label-text-size, var(--md-sys-typescale-label-large-size, 0.875rem));--_label-text-weight: var(--md-filled-tonal-button-label-text-weight, var(--md-sys-typescale-label-large-weight, var(--md-ref-typeface-weight-medium, 500)));--_pressed-container-elevation: var(--md-filled-tonal-button-pressed-container-elevation, 0);--_pressed-label-text-color: var(--md-filled-tonal-button-pressed-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_pressed-state-layer-color: var(--md-filled-tonal-button-pressed-state-layer-color, var(--md-sys-color-on-secondary-container, #1d192b));--_pressed-state-layer-opacity: var(--md-filled-tonal-button-pressed-state-layer-opacity, 0.12);--_disabled-icon-color: var(--md-filled-tonal-button-disabled-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-icon-opacity: var(--md-filled-tonal-button-disabled-icon-opacity, 0.38);--_focus-icon-color: var(--md-filled-tonal-button-focus-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_hover-icon-color: var(--md-filled-tonal-button-hover-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_icon-color: var(--md-filled-tonal-button-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_icon-size: var(--md-filled-tonal-button-icon-size, 18px);--_pressed-icon-color: var(--md-filled-tonal-button-pressed-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_container-shape-start-start: var(--md-filled-tonal-button-container-shape-start-start, var(--md-filled-tonal-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-start-end: var(--md-filled-tonal-button-container-shape-start-end, var(--md-filled-tonal-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-end-end: var(--md-filled-tonal-button-container-shape-end-end, var(--md-filled-tonal-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-end-start: var(--md-filled-tonal-button-container-shape-end-start, var(--md-filled-tonal-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_leading-space: var(--md-filled-tonal-button-leading-space, 24px);--_trailing-space: var(--md-filled-tonal-button-trailing-space, 24px);--_with-leading-icon-leading-space: var(--md-filled-tonal-button-with-leading-icon-leading-space, 16px);--_with-leading-icon-trailing-space: var(--md-filled-tonal-button-with-leading-icon-trailing-space, 24px);--_with-trailing-icon-leading-space: var(--md-filled-tonal-button-with-trailing-icon-leading-space, 24px);--_with-trailing-icon-trailing-space: var(--md-filled-tonal-button-with-trailing-icon-trailing-space, 16px)}
318
+ `;
319
+ styles$9.styleSheet;
320
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/shared-elevation-styles.cssresult.js
321
+ /**
322
+ * @license
323
+ * Copyright 2026 Google LLC
324
+ * SPDX-License-Identifier: Apache-2.0
325
+ */
326
+ var styles$8 = i$3`md-elevation{transition-duration:280ms}:host(:is([disabled],[soft-disabled])) md-elevation{transition:none}md-elevation{--md-elevation-level: var(--_container-elevation);--md-elevation-shadow-color: var(--_container-shadow-color)}:host(:focus-within) md-elevation{--md-elevation-level: var(--_focus-container-elevation)}:host(:hover) md-elevation{--md-elevation-level: var(--_hover-container-elevation)}:host(:active) md-elevation{--md-elevation-level: var(--_pressed-container-elevation)}:host(:is([disabled],[soft-disabled])) md-elevation{--md-elevation-level: var(--_disabled-container-elevation)}
327
+ `;
328
+ styles$8.styleSheet;
329
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/shared-styles.cssresult.js
330
+ /**
331
+ * @license
332
+ * Copyright 2026 Google LLC
333
+ * SPDX-License-Identifier: Apache-2.0
334
+ */
335
+ var styles$7 = i$3`:host{border-start-start-radius:var(--_container-shape-start-start);border-start-end-radius:var(--_container-shape-start-end);border-end-start-radius:var(--_container-shape-end-start);border-end-end-radius:var(--_container-shape-end-end);box-sizing:border-box;cursor:pointer;display:inline-flex;gap:8px;min-height:var(--_container-height);outline:none;padding-block:calc((var(--_container-height) - max(var(--_label-text-line-height),var(--_icon-size)))/2);padding-inline-start:var(--_leading-space);padding-inline-end:var(--_trailing-space);place-content:center;place-items:center;position:relative;font-family:var(--_label-text-font);font-size:var(--_label-text-size);line-height:var(--_label-text-line-height);font-weight:var(--_label-text-weight);text-overflow:ellipsis;text-wrap:nowrap;user-select:none;-webkit-tap-highlight-color:rgba(0,0,0,0);vertical-align:top;--md-ripple-hover-color: var(--_hover-state-layer-color);--md-ripple-pressed-color: var(--_pressed-state-layer-color);--md-ripple-hover-opacity: var(--_hover-state-layer-opacity);--md-ripple-pressed-opacity: var(--_pressed-state-layer-opacity)}md-focus-ring{--md-focus-ring-shape-start-start: var(--_container-shape-start-start);--md-focus-ring-shape-start-end: var(--_container-shape-start-end);--md-focus-ring-shape-end-end: var(--_container-shape-end-end);--md-focus-ring-shape-end-start: var(--_container-shape-end-start)}:host(:is([disabled],[soft-disabled])){cursor:default;pointer-events:none}.button{border-radius:inherit;cursor:inherit;display:inline-flex;align-items:center;justify-content:center;border:none;outline:none;-webkit-appearance:none;vertical-align:middle;background:rgba(0,0,0,0);text-decoration:none;min-width:calc(64px - var(--_leading-space) - var(--_trailing-space));width:100%;z-index:0;height:100%;font:inherit;color:var(--_label-text-color);padding:0;gap:inherit;text-transform:inherit}.button::-moz-focus-inner{padding:0;border:0}:host(:hover) .button{color:var(--_hover-label-text-color)}:host(:focus-within) .button{color:var(--_focus-label-text-color)}:host(:active) .button{color:var(--_pressed-label-text-color)}.background{background:var(--_container-color);border-radius:inherit;inset:0;position:absolute}.label{overflow:hidden}:is(.button,.label,.label slot),.label ::slotted(*){text-overflow:inherit}:host(:is([disabled],[soft-disabled])) .label{color:var(--_disabled-label-text-color);opacity:var(--_disabled-label-text-opacity)}:host(:is([disabled],[soft-disabled])) .background{background:var(--_disabled-container-color);opacity:var(--_disabled-container-opacity)}@media(forced-colors: active){.background{border:1px solid CanvasText}:host(:is([disabled],[soft-disabled])){--_disabled-icon-color: GrayText;--_disabled-icon-opacity: 1;--_disabled-container-opacity: 1;--_disabled-label-text-color: GrayText;--_disabled-label-text-opacity: 1}}:host([has-icon]:not([trailing-icon])){padding-inline-start:var(--_with-leading-icon-leading-space);padding-inline-end:var(--_with-leading-icon-trailing-space)}:host([has-icon][trailing-icon]){padding-inline-start:var(--_with-trailing-icon-leading-space);padding-inline-end:var(--_with-trailing-icon-trailing-space)}::slotted([slot=icon]){display:inline-flex;position:relative;writing-mode:horizontal-tb;fill:currentColor;flex-shrink:0;color:var(--_icon-color);font-size:var(--_icon-size);inline-size:var(--_icon-size);block-size:var(--_icon-size)}:host(:hover) ::slotted([slot=icon]){color:var(--_hover-icon-color)}:host(:focus-within) ::slotted([slot=icon]){color:var(--_focus-icon-color)}:host(:active) ::slotted([slot=icon]){color:var(--_pressed-icon-color)}:host(:is([disabled],[soft-disabled])) ::slotted([slot=icon]){color:var(--_disabled-icon-color);opacity:var(--_disabled-icon-opacity)}.touch{position:absolute;top:50%;height:max(48px,100%);left:0;right:0;transform:translateY(-50%)}:host([touch-target=wrapper]){margin:max(0px,(48px - var(--_container-height))/2) 0}:host([touch-target=none]) .touch{display:none}
336
+ `;
337
+ styles$7.styleSheet;
338
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/filled-tonal-button.js
339
+ /**
340
+ * @license
341
+ * Copyright 2021 Google LLC
342
+ * SPDX-License-Identifier: Apache-2.0
343
+ */
344
+ /**
345
+ * @summary Buttons help people take action, such as sending an email, sharing a
346
+ * document, or liking a comment.
347
+ *
348
+ * @description
349
+ * __Emphasis:__ Medium emphasis – For important actions that don’t distract
350
+ * from other onscreen elements.
351
+ *
352
+ * __Rationale:__ Filled tonal buttons have a lighter background color and
353
+ * darker label color, making them less visually prominent than a regular,
354
+ * filled button. They’re still used for final or unblocking actions in a flow,
355
+ * but do so with less emphasis.
356
+ *
357
+ * __Example usages:__
358
+ * - Save
359
+ * - Confirm
360
+ * - Done
361
+ *
362
+ * @final
363
+ * @suppress {visibility}
364
+ */
365
+ var MdFilledTonalButton = class MdFilledTonalButton extends FilledTonalButton {};
366
+ MdFilledTonalButton.styles = [
367
+ styles$7,
368
+ styles$8,
369
+ styles$9
370
+ ];
371
+ MdFilledTonalButton = __decorate([t$1("md-filled-tonal-button")], MdFilledTonalButton);
372
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/text-button.js
373
+ /**
374
+ * @license
375
+ * Copyright 2021 Google LLC
376
+ * SPDX-License-Identifier: Apache-2.0
377
+ */
378
+ /**
379
+ * A text button component.
380
+ */
381
+ var TextButton = class extends Button {};
382
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/text-styles.cssresult.js
383
+ /**
384
+ * @license
385
+ * Copyright 2026 Google LLC
386
+ * SPDX-License-Identifier: Apache-2.0
387
+ */
388
+ var styles$6 = i$3`:host{--_container-height: var(--md-text-button-container-height, 40px);--_disabled-label-text-color: var(--md-text-button-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity: var(--md-text-button-disabled-label-text-opacity, 0.38);--_focus-label-text-color: var(--md-text-button-focus-label-text-color, var(--md-sys-color-primary, #6750a4));--_hover-label-text-color: var(--md-text-button-hover-label-text-color, var(--md-sys-color-primary, #6750a4));--_hover-state-layer-color: var(--md-text-button-hover-state-layer-color, var(--md-sys-color-primary, #6750a4));--_hover-state-layer-opacity: var(--md-text-button-hover-state-layer-opacity, 0.08);--_label-text-color: var(--md-text-button-label-text-color, var(--md-sys-color-primary, #6750a4));--_label-text-font: var(--md-text-button-label-text-font, var(--md-sys-typescale-label-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height: var(--md-text-button-label-text-line-height, var(--md-sys-typescale-label-large-line-height, 1.25rem));--_label-text-size: var(--md-text-button-label-text-size, var(--md-sys-typescale-label-large-size, 0.875rem));--_label-text-weight: var(--md-text-button-label-text-weight, var(--md-sys-typescale-label-large-weight, var(--md-ref-typeface-weight-medium, 500)));--_pressed-label-text-color: var(--md-text-button-pressed-label-text-color, var(--md-sys-color-primary, #6750a4));--_pressed-state-layer-color: var(--md-text-button-pressed-state-layer-color, var(--md-sys-color-primary, #6750a4));--_pressed-state-layer-opacity: var(--md-text-button-pressed-state-layer-opacity, 0.12);--_disabled-icon-color: var(--md-text-button-disabled-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-icon-opacity: var(--md-text-button-disabled-icon-opacity, 0.38);--_focus-icon-color: var(--md-text-button-focus-icon-color, var(--md-sys-color-primary, #6750a4));--_hover-icon-color: var(--md-text-button-hover-icon-color, var(--md-sys-color-primary, #6750a4));--_icon-color: var(--md-text-button-icon-color, var(--md-sys-color-primary, #6750a4));--_icon-size: var(--md-text-button-icon-size, 18px);--_pressed-icon-color: var(--md-text-button-pressed-icon-color, var(--md-sys-color-primary, #6750a4));--_container-shape-start-start: var(--md-text-button-container-shape-start-start, var(--md-text-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-start-end: var(--md-text-button-container-shape-start-end, var(--md-text-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-end-end: var(--md-text-button-container-shape-end-end, var(--md-text-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-end-start: var(--md-text-button-container-shape-end-start, var(--md-text-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_leading-space: var(--md-text-button-leading-space, 12px);--_trailing-space: var(--md-text-button-trailing-space, 12px);--_with-leading-icon-leading-space: var(--md-text-button-with-leading-icon-leading-space, 12px);--_with-leading-icon-trailing-space: var(--md-text-button-with-leading-icon-trailing-space, 16px);--_with-trailing-icon-leading-space: var(--md-text-button-with-trailing-icon-leading-space, 16px);--_with-trailing-icon-trailing-space: var(--md-text-button-with-trailing-icon-trailing-space, 12px);--_container-color: none;--_disabled-container-color: none;--_disabled-container-opacity: 0}
389
+ `;
390
+ styles$6.styleSheet;
391
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/text-button.js
392
+ /**
393
+ * @license
394
+ * Copyright 2021 Google LLC
395
+ * SPDX-License-Identifier: Apache-2.0
396
+ */
397
+ /**
398
+ * @summary Buttons help people take action, such as sending an email, sharing a
399
+ * document, or liking a comment.
400
+ *
401
+ * @description
402
+ * __Emphasis:__ Low emphasis – For optional or supplementary actions with the
403
+ * least amount of prominence
404
+ *
405
+ * __Rationale:__ Text buttons have less visual prominence, so should be used
406
+ * for low emphasis actions, such as an alternative option.
407
+ *
408
+ * __Example usages:__
409
+ * - Learn more
410
+ * - View all
411
+ * - Change account
412
+ * - Turn on
413
+ *
414
+ * @final
415
+ * @suppress {visibility}
416
+ */
417
+ var MdTextButton = class MdTextButton extends TextButton {};
418
+ MdTextButton.styles = [styles$7, styles$6];
419
+ MdTextButton = __decorate([t$1("md-text-button")], MdTextButton);
420
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/divider/internal/divider.js
421
+ /**
422
+ * @license
423
+ * Copyright 2023 Google LLC
424
+ * SPDX-License-Identifier: Apache-2.0
425
+ */
426
+ /**
427
+ * A divider component.
428
+ */
429
+ var Divider = class extends i$2 {
430
+ constructor() {
431
+ super(...arguments);
432
+ /**
433
+ * Indents the divider with equal padding on both sides.
434
+ */
435
+ this.inset = false;
436
+ /**
437
+ * Indents the divider with padding on the leading side.
438
+ */
439
+ this.insetStart = false;
440
+ /**
441
+ * Indents the divider with padding on the trailing side.
442
+ */
443
+ this.insetEnd = false;
444
+ }
445
+ };
446
+ __decorate([n$2({
447
+ type: Boolean,
448
+ reflect: true
449
+ })], Divider.prototype, "inset", void 0);
450
+ __decorate([n$2({
451
+ type: Boolean,
452
+ reflect: true,
453
+ attribute: "inset-start"
454
+ })], Divider.prototype, "insetStart", void 0);
455
+ __decorate([n$2({
456
+ type: Boolean,
457
+ reflect: true,
458
+ attribute: "inset-end"
459
+ })], Divider.prototype, "insetEnd", void 0);
460
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/divider/internal/divider-styles.cssresult.js
461
+ /**
462
+ * @license
463
+ * Copyright 2026 Google LLC
464
+ * SPDX-License-Identifier: Apache-2.0
465
+ */
466
+ var styles$5 = i$3`:host{box-sizing:border-box;color:var(--md-divider-color, var(--md-sys-color-outline-variant, #cac4d0));display:flex;height:var(--md-divider-thickness, 1px);width:100%}:host([inset]),:host([inset-start]){padding-inline-start:16px}:host([inset]),:host([inset-end]){padding-inline-end:16px}:host::before{background:currentColor;content:"";height:100%;width:100%}@media(forced-colors: active){:host::before{background:CanvasText}}
467
+ `;
468
+ styles$5.styleSheet;
469
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/divider/divider.js
470
+ /**
471
+ * @license
472
+ * Copyright 2023 Google LLC
473
+ * SPDX-License-Identifier: Apache-2.0
474
+ */
475
+ /**
476
+ * @summary A divider is a thin line that groups content in lists and
477
+ * containers.
478
+ *
479
+ * @description Dividers can reinforce tapability, such as when used to separate
480
+ * list items or define tappable regions in an accordion.
481
+ *
482
+ * @final
483
+ * @suppress {visibility}
484
+ */
485
+ var MdDivider = class MdDivider extends Divider {};
486
+ MdDivider.styles = [styles$5];
487
+ MdDivider = __decorate([t$1("md-divider")], MdDivider);
488
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/internal/events/redispatch-event.js
489
+ /**
490
+ * @license
491
+ * Copyright 2021 Google LLC
492
+ * SPDX-License-Identifier: Apache-2.0
493
+ */
494
+ /**
495
+ * Re-dispatches an event from the provided element.
496
+ *
497
+ * This function is useful for forwarding non-composed events, such as `change`
498
+ * events.
499
+ *
500
+ * @example
501
+ * class MyInput extends LitElement {
502
+ * render() {
503
+ * return html`<input @change=${this.redispatchEvent}>`;
504
+ * }
505
+ *
506
+ * protected redispatchEvent(event: Event) {
507
+ * redispatchEvent(this, event);
508
+ * }
509
+ * }
510
+ *
511
+ * @param element The element to dispatch the event from.
512
+ * @param event The event to re-dispatch.
513
+ * @return Whether or not the event was dispatched (if cancelable).
514
+ */
515
+ function redispatchEvent(element, event) {
516
+ if (event.bubbles && (!element.shadowRoot || event.composed)) event.stopPropagation();
517
+ const copy = Reflect.construct(event.constructor, [event.type, event]);
518
+ const dispatched = element.dispatchEvent(copy);
519
+ if (!dispatched) event.preventDefault();
520
+ return dispatched;
521
+ }
522
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/dialog/internal/animations.js
523
+ /**
524
+ * @license
525
+ * Copyright 2023 Google LLC
526
+ * SPDX-License-Identifier: Apache-2.0
527
+ */
528
+ /**
529
+ * The default dialog open animation.
530
+ */
531
+ var DIALOG_DEFAULT_OPEN_ANIMATION = {
532
+ dialog: [[[{ "transform": "translateY(-50px)" }, { "transform": "translateY(0)" }], {
533
+ duration: 500,
534
+ easing: EASING.EMPHASIZED
535
+ }]],
536
+ scrim: [[[{ "opacity": 0 }, { "opacity": .32 }], {
537
+ duration: 500,
538
+ easing: "linear"
539
+ }]],
540
+ container: [[[{ "opacity": 0 }, { "opacity": 1 }], {
541
+ duration: 50,
542
+ easing: "linear",
543
+ pseudoElement: "::before"
544
+ }], [[{ "height": "35%" }, { "height": "100%" }], {
545
+ duration: 500,
546
+ easing: EASING.EMPHASIZED,
547
+ pseudoElement: "::before"
548
+ }]],
549
+ headline: [[[
550
+ { "opacity": 0 },
551
+ {
552
+ "opacity": 0,
553
+ offset: .2
554
+ },
555
+ { "opacity": 1 }
556
+ ], {
557
+ duration: 250,
558
+ easing: "linear",
559
+ fill: "forwards"
560
+ }]],
561
+ content: [[[
562
+ { "opacity": 0 },
563
+ {
564
+ "opacity": 0,
565
+ offset: .2
566
+ },
567
+ { "opacity": 1 }
568
+ ], {
569
+ duration: 250,
570
+ easing: "linear",
571
+ fill: "forwards"
572
+ }]],
573
+ actions: [[[
574
+ { "opacity": 0 },
575
+ {
576
+ "opacity": 0,
577
+ offset: .5
578
+ },
579
+ { "opacity": 1 }
580
+ ], {
581
+ duration: 300,
582
+ easing: "linear",
583
+ fill: "forwards"
584
+ }]]
585
+ };
586
+ /**
587
+ * The default dialog close animation.
588
+ */
589
+ var DIALOG_DEFAULT_CLOSE_ANIMATION = {
590
+ dialog: [[[{ "transform": "translateY(0)" }, { "transform": "translateY(-50px)" }], {
591
+ duration: 150,
592
+ easing: EASING.EMPHASIZED_ACCELERATE
593
+ }]],
594
+ scrim: [[[{ "opacity": .32 }, { "opacity": 0 }], {
595
+ duration: 150,
596
+ easing: "linear"
597
+ }]],
598
+ container: [[[{ "height": "100%" }, { "height": "35%" }], {
599
+ duration: 150,
600
+ easing: EASING.EMPHASIZED_ACCELERATE,
601
+ pseudoElement: "::before"
602
+ }], [[{ "opacity": "1" }, { "opacity": "0" }], {
603
+ delay: 100,
604
+ duration: 50,
605
+ easing: "linear",
606
+ pseudoElement: "::before"
607
+ }]],
608
+ headline: [[[{ "opacity": 1 }, { "opacity": 0 }], {
609
+ duration: 100,
610
+ easing: "linear",
611
+ fill: "forwards"
612
+ }]],
613
+ content: [[[{ "opacity": 1 }, { "opacity": 0 }], {
614
+ duration: 100,
615
+ easing: "linear",
616
+ fill: "forwards"
617
+ }]],
618
+ actions: [[[{ "opacity": 1 }, { "opacity": 0 }], {
619
+ duration: 100,
620
+ easing: "linear",
621
+ fill: "forwards"
622
+ }]]
623
+ };
624
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/dialog/internal/dialog.js
625
+ /**
626
+ * @license
627
+ * Copyright 2023 Google LLC
628
+ * SPDX-License-Identifier: Apache-2.0
629
+ */
630
+ var dialogBaseClass = mixinDelegatesAria(i$2);
631
+ /**
632
+ * A dialog component.
633
+ *
634
+ * @fires open {Event} Dispatched when the dialog is opening before any animations.
635
+ * @fires opened {Event} Dispatched when the dialog has opened after any animations.
636
+ * @fires close {Event} Dispatched when the dialog is closing before any animations.
637
+ * @fires closed {Event} Dispatched when the dialog has closed after any animations.
638
+ * @fires cancel {Event} Dispatched when the dialog has been canceled by clicking
639
+ * on the scrim or pressing Escape.
640
+ */
641
+ var Dialog = class extends dialogBaseClass {
642
+ /**
643
+ * Opens the dialog when set to `true` and closes it when set to `false`.
644
+ */
645
+ get open() {
646
+ return this.isOpen;
647
+ }
648
+ set open(open) {
649
+ if (open === this.isOpen) return;
650
+ this.isOpen = open;
651
+ if (open) {
652
+ this.setAttribute("open", "");
653
+ this.show();
654
+ } else {
655
+ this.removeAttribute("open");
656
+ this.close();
657
+ }
658
+ }
659
+ constructor() {
660
+ super();
661
+ /**
662
+ * Skips the opening and closing animations.
663
+ */
664
+ this.quick = false;
665
+ /**
666
+ * Gets or sets the dialog's return value, usually to indicate which button
667
+ * a user pressed to close it.
668
+ *
669
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLDialogElement/returnValue
670
+ */
671
+ this.returnValue = "";
672
+ /**
673
+ * Disables focus trapping, which by default keeps keyboard Tab navigation
674
+ * within the dialog.
675
+ *
676
+ * When disabled, after focusing the last element of a dialog, pressing Tab
677
+ * again will release focus from the window back to the browser (such as the
678
+ * URL bar).
679
+ *
680
+ * Focus trapping is recommended for accessibility, and should not typically
681
+ * be disabled. Only turn this off if the use case of a dialog is more
682
+ * accessible without focus trapping.
683
+ */
684
+ this.noFocusTrap = false;
685
+ /**
686
+ * Gets the opening animation for a dialog. Set to a new function to customize
687
+ * the animation.
688
+ */
689
+ this.getOpenAnimation = () => DIALOG_DEFAULT_OPEN_ANIMATION;
690
+ /**
691
+ * Gets the closing animation for a dialog. Set to a new function to customize
692
+ * the animation.
693
+ */
694
+ this.getCloseAnimation = () => DIALOG_DEFAULT_CLOSE_ANIMATION;
695
+ this.isOpen = false;
696
+ this.isOpening = false;
697
+ this.isConnectedPromise = this.getIsConnectedPromise();
698
+ this.isAtScrollTop = false;
699
+ this.isAtScrollBottom = false;
700
+ this.nextClickIsFromContent = false;
701
+ this.hasHeadline = false;
702
+ this.hasActions = false;
703
+ this.hasIcon = false;
704
+ this.escapePressedWithoutCancel = false;
705
+ this.treewalker = null;
706
+ }
707
+ /**
708
+ * Opens the dialog and fires a cancelable `open` event. After a dialog's
709
+ * animation, an `opened` event is fired.
710
+ *
711
+ * Add an `autofocus` attribute to a child of the dialog that should
712
+ * receive focus after opening.
713
+ *
714
+ * @return A Promise that resolves after the animation is finished and the
715
+ * `opened` event was fired.
716
+ */
717
+ async show() {
718
+ this.isOpening = true;
719
+ await this.isConnectedPromise;
720
+ await this.updateComplete;
721
+ const dialog = this.dialog;
722
+ if (dialog.open || !this.isOpening) {
723
+ this.isOpening = false;
724
+ return;
725
+ }
726
+ if (!this.dispatchEvent(new Event("open", { cancelable: true }))) {
727
+ this.open = false;
728
+ this.isOpening = false;
729
+ return;
730
+ }
731
+ dialog.showModal();
732
+ this.open = true;
733
+ if (this.scroller) this.scroller.scrollTop = 0;
734
+ this.querySelector("[autofocus]")?.focus();
735
+ await this.animateDialog(this.getOpenAnimation());
736
+ this.dispatchEvent(new Event("opened"));
737
+ this.isOpening = false;
738
+ }
739
+ /**
740
+ * Closes the dialog and fires a cancelable `close` event. After a dialog's
741
+ * animation, a `closed` event is fired.
742
+ *
743
+ * @param returnValue A return value usually indicating which button was used
744
+ * to close a dialog. If a dialog is canceled by clicking the scrim or
745
+ * pressing Escape, it will not change the return value after closing.
746
+ * @return A Promise that resolves after the animation is finished and the
747
+ * `closed` event was fired.
748
+ */
749
+ async close(returnValue = this.returnValue) {
750
+ this.isOpening = false;
751
+ if (!this.isConnected) {
752
+ this.open = false;
753
+ return;
754
+ }
755
+ await this.updateComplete;
756
+ const dialog = this.dialog;
757
+ if (!dialog.open || this.isOpening) {
758
+ this.open = false;
759
+ return;
760
+ }
761
+ const prevReturnValue = this.returnValue;
762
+ this.returnValue = returnValue;
763
+ if (!this.dispatchEvent(new Event("close", { cancelable: true }))) {
764
+ this.returnValue = prevReturnValue;
765
+ return;
766
+ }
767
+ await this.animateDialog(this.getCloseAnimation());
768
+ dialog.close(returnValue);
769
+ this.open = false;
770
+ this.dispatchEvent(new Event("closed"));
771
+ }
772
+ connectedCallback() {
773
+ super.connectedCallback();
774
+ this.isConnectedPromiseResolve();
775
+ }
776
+ disconnectedCallback() {
777
+ super.disconnectedCallback();
778
+ this.isConnectedPromise = this.getIsConnectedPromise();
779
+ }
780
+ render() {
781
+ const scrollable = this.open && !(this.isAtScrollTop && this.isAtScrollBottom);
782
+ const classes = {
783
+ "has-headline": this.hasHeadline,
784
+ "has-actions": this.hasActions,
785
+ "has-icon": this.hasIcon,
786
+ "scrollable": scrollable,
787
+ "show-top-divider": scrollable && !this.isAtScrollTop,
788
+ "show-bottom-divider": scrollable && !this.isAtScrollBottom
789
+ };
790
+ const showFocusTrap = this.open && !this.noFocusTrap;
791
+ const focusTrap = T`
792
+ <div
793
+ class="focus-trap"
794
+ tabindex="0"
795
+ aria-hidden="true"
796
+ @focus=${this.handleFocusTrapFocus}></div>
797
+ `;
798
+ const { ariaLabel } = this;
799
+ return T`
800
+ <div class="scrim"></div>
801
+ <dialog
802
+ class=${e$3(classes)}
803
+ aria-label=${ariaLabel || A}
804
+ aria-labelledby=${this.hasHeadline ? "headline" : A}
805
+ role=${this.type === "alert" ? "alertdialog" : A}
806
+ @cancel=${this.handleCancel}
807
+ @click=${this.handleDialogClick}
808
+ @close=${this.handleClose}
809
+ @keydown=${this.handleKeydown}
810
+ .returnValue=${this.returnValue || A}>
811
+ ${showFocusTrap ? focusTrap : A}
812
+ <div class="container" @click=${this.handleContentClick}>
813
+ <div class="headline">
814
+ <div class="icon" aria-hidden="true">
815
+ <slot name="icon" @slotchange=${this.handleIconChange}></slot>
816
+ </div>
817
+ <h2 id="headline" aria-hidden=${!this.hasHeadline || A}>
818
+ <slot
819
+ name="headline"
820
+ @slotchange=${this.handleHeadlineChange}></slot>
821
+ </h2>
822
+ <md-divider></md-divider>
823
+ </div>
824
+ <div class="scroller">
825
+ <div class="content">
826
+ <div class="top anchor"></div>
827
+ <slot name="content"></slot>
828
+ <div class="bottom anchor"></div>
829
+ </div>
830
+ </div>
831
+ <div class="actions">
832
+ <md-divider></md-divider>
833
+ <slot name="actions" @slotchange=${this.handleActionsChange}></slot>
834
+ </div>
835
+ </div>
836
+ ${showFocusTrap ? focusTrap : A}
837
+ </dialog>
838
+ `;
839
+ }
840
+ firstUpdated() {
841
+ this.intersectionObserver = new IntersectionObserver((entries) => {
842
+ for (const entry of entries) this.handleAnchorIntersection(entry);
843
+ }, { root: this.scroller });
844
+ this.intersectionObserver.observe(this.topAnchor);
845
+ this.intersectionObserver.observe(this.bottomAnchor);
846
+ }
847
+ handleDialogClick() {
848
+ if (this.nextClickIsFromContent) {
849
+ this.nextClickIsFromContent = false;
850
+ return;
851
+ }
852
+ if (!this.dispatchEvent(new Event("cancel", { cancelable: true }))) return;
853
+ this.close();
854
+ }
855
+ handleContentClick() {
856
+ this.nextClickIsFromContent = true;
857
+ }
858
+ handleSubmit(event) {
859
+ const form = event.target;
860
+ const { submitter } = event;
861
+ if (form.getAttribute("method") !== "dialog" || !submitter) return;
862
+ this.close(submitter.getAttribute("value") ?? this.returnValue);
863
+ }
864
+ handleCancel(event) {
865
+ if (event.target !== this.dialog) return;
866
+ this.escapePressedWithoutCancel = false;
867
+ const preventDefault = !redispatchEvent(this, event);
868
+ event.preventDefault();
869
+ if (preventDefault) return;
870
+ this.close();
871
+ }
872
+ handleClose() {
873
+ if (!this.escapePressedWithoutCancel) return;
874
+ this.escapePressedWithoutCancel = false;
875
+ this.dialog?.dispatchEvent(new Event("cancel", { cancelable: true }));
876
+ }
877
+ handleKeydown(event) {
878
+ if (event.key !== "Escape") return;
879
+ this.escapePressedWithoutCancel = true;
880
+ setTimeout(() => {
881
+ this.escapePressedWithoutCancel = false;
882
+ });
883
+ }
884
+ async animateDialog(animation) {
885
+ this.cancelAnimations?.abort();
886
+ this.cancelAnimations = new AbortController();
887
+ if (this.quick) return;
888
+ const { dialog, scrim, container, headline, content, actions } = this;
889
+ if (!dialog || !scrim || !container || !headline || !content || !actions) return;
890
+ const { container: containerAnimate, dialog: dialogAnimate, scrim: scrimAnimate, headline: headlineAnimate, content: contentAnimate, actions: actionsAnimate } = animation;
891
+ const elementAndAnimation = [
892
+ [dialog, dialogAnimate ?? []],
893
+ [scrim, scrimAnimate ?? []],
894
+ [container, containerAnimate ?? []],
895
+ [headline, headlineAnimate ?? []],
896
+ [content, contentAnimate ?? []],
897
+ [actions, actionsAnimate ?? []]
898
+ ];
899
+ const animations = [];
900
+ for (const [element, animation] of elementAndAnimation) for (const animateArgs of animation) {
901
+ const animation = element.animate(...animateArgs);
902
+ this.cancelAnimations.signal.addEventListener("abort", () => {
903
+ animation.cancel();
904
+ });
905
+ animations.push(animation);
906
+ }
907
+ await Promise.all(animations.map((animation) => animation.finished.catch(() => {})));
908
+ }
909
+ handleHeadlineChange(event) {
910
+ const slot = event.target;
911
+ this.hasHeadline = slot.assignedElements().length > 0;
912
+ }
913
+ handleActionsChange(event) {
914
+ const slot = event.target;
915
+ this.hasActions = slot.assignedElements().length > 0;
916
+ }
917
+ handleIconChange(event) {
918
+ const slot = event.target;
919
+ this.hasIcon = slot.assignedElements().length > 0;
920
+ }
921
+ handleAnchorIntersection(entry) {
922
+ const { target, isIntersecting } = entry;
923
+ if (target === this.topAnchor) this.isAtScrollTop = isIntersecting;
924
+ if (target === this.bottomAnchor) this.isAtScrollBottom = isIntersecting;
925
+ }
926
+ getIsConnectedPromise() {
927
+ return new Promise((resolve) => {
928
+ this.isConnectedPromiseResolve = resolve;
929
+ });
930
+ }
931
+ handleFocusTrapFocus(event) {
932
+ const [firstFocusableChild, lastFocusableChild] = this.getFirstAndLastFocusableChildren();
933
+ if (!firstFocusableChild || !lastFocusableChild) {
934
+ this.dialog?.focus();
935
+ return;
936
+ }
937
+ const isFirstFocusTrap = event.target === this.firstFocusTrap;
938
+ const isLastFocusTrap = !isFirstFocusTrap;
939
+ const focusCameFromFirstChild = event.relatedTarget === firstFocusableChild;
940
+ const focusCameFromLastChild = event.relatedTarget === lastFocusableChild;
941
+ const focusCameFromOutsideDialog = !focusCameFromFirstChild && !focusCameFromLastChild;
942
+ if (isLastFocusTrap && focusCameFromLastChild || isFirstFocusTrap && focusCameFromOutsideDialog) {
943
+ firstFocusableChild.focus();
944
+ return;
945
+ }
946
+ if (isFirstFocusTrap && focusCameFromFirstChild || isLastFocusTrap && focusCameFromOutsideDialog) {
947
+ lastFocusableChild.focus();
948
+ return;
949
+ }
950
+ }
951
+ getFirstAndLastFocusableChildren() {
952
+ if (!this.treewalker) return [null, null];
953
+ let firstFocusableChild = null;
954
+ let lastFocusableChild = null;
955
+ this.treewalker.currentNode = this.treewalker.root;
956
+ while (this.treewalker.nextNode()) {
957
+ const nextChild = this.treewalker.currentNode;
958
+ if (!isFocusable(nextChild)) continue;
959
+ if (!firstFocusableChild) firstFocusableChild = nextChild;
960
+ lastFocusableChild = nextChild;
961
+ }
962
+ return [firstFocusableChild, lastFocusableChild];
963
+ }
964
+ };
965
+ __decorate([n$2({ type: Boolean })], Dialog.prototype, "open", null);
966
+ __decorate([n$2({ type: Boolean })], Dialog.prototype, "quick", void 0);
967
+ __decorate([n$2({ attribute: false })], Dialog.prototype, "returnValue", void 0);
968
+ __decorate([n$2()], Dialog.prototype, "type", void 0);
969
+ __decorate([n$2({
970
+ type: Boolean,
971
+ attribute: "no-focus-trap"
972
+ })], Dialog.prototype, "noFocusTrap", void 0);
973
+ __decorate([e$2("dialog")], Dialog.prototype, "dialog", void 0);
974
+ __decorate([e$2(".scrim")], Dialog.prototype, "scrim", void 0);
975
+ __decorate([e$2(".container")], Dialog.prototype, "container", void 0);
976
+ __decorate([e$2(".headline")], Dialog.prototype, "headline", void 0);
977
+ __decorate([e$2(".content")], Dialog.prototype, "content", void 0);
978
+ __decorate([e$2(".actions")], Dialog.prototype, "actions", void 0);
979
+ __decorate([r$1()], Dialog.prototype, "isAtScrollTop", void 0);
980
+ __decorate([r$1()], Dialog.prototype, "isAtScrollBottom", void 0);
981
+ __decorate([e$2(".scroller")], Dialog.prototype, "scroller", void 0);
982
+ __decorate([e$2(".top.anchor")], Dialog.prototype, "topAnchor", void 0);
983
+ __decorate([e$2(".bottom.anchor")], Dialog.prototype, "bottomAnchor", void 0);
984
+ __decorate([e$2(".focus-trap")], Dialog.prototype, "firstFocusTrap", void 0);
985
+ __decorate([r$1()], Dialog.prototype, "hasHeadline", void 0);
986
+ __decorate([r$1()], Dialog.prototype, "hasActions", void 0);
987
+ __decorate([r$1()], Dialog.prototype, "hasIcon", void 0);
988
+ function isFocusable(element) {
989
+ const knownFocusableElements = ":is(button,input,select,textarea,object,:is(a,area)[href],[tabindex],[contenteditable=true])";
990
+ const notDisabled = ":not(:disabled,[disabled])";
991
+ if (element.matches(knownFocusableElements + notDisabled + ":not([tabindex^=\"-\"])")) return true;
992
+ if (!element.localName.includes("-")) return false;
993
+ if (!element.matches(notDisabled)) return false;
994
+ return element.shadowRoot?.delegatesFocus ?? false;
995
+ }
996
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/dialog/internal/dialog-styles.cssresult.js
997
+ /**
998
+ * @license
999
+ * Copyright 2026 Google LLC
1000
+ * SPDX-License-Identifier: Apache-2.0
1001
+ */
1002
+ var styles$4 = i$3`:host{border-start-start-radius:var(--md-dialog-container-shape-start-start, var(--md-dialog-container-shape, var(--md-sys-shape-corner-extra-large, 28px)));border-start-end-radius:var(--md-dialog-container-shape-start-end, var(--md-dialog-container-shape, var(--md-sys-shape-corner-extra-large, 28px)));border-end-end-radius:var(--md-dialog-container-shape-end-end, var(--md-dialog-container-shape, var(--md-sys-shape-corner-extra-large, 28px)));border-end-start-radius:var(--md-dialog-container-shape-end-start, var(--md-dialog-container-shape, var(--md-sys-shape-corner-extra-large, 28px)));display:contents;margin:auto;max-height:min(560px,100% - 48px);max-width:min(560px,100% - 48px);min-height:140px;min-width:280px;position:fixed;height:fit-content;width:fit-content}dialog{background:rgba(0,0,0,0);border:none;border-radius:inherit;flex-direction:column;height:inherit;margin:inherit;max-height:inherit;max-width:inherit;min-height:inherit;min-width:inherit;outline:none;overflow:visible;padding:0;width:inherit}dialog[open]{display:flex}::backdrop{background:none}.scrim{background:var(--md-sys-color-scrim, #000);display:none;inset:0;opacity:32%;pointer-events:none;position:fixed;z-index:1}:host([open]) .scrim{display:flex}h2{all:unset;align-self:stretch}.headline{align-items:center;color:var(--md-dialog-headline-color, var(--md-sys-color-on-surface, #1d1b20));display:flex;flex-direction:column;font-family:var(--md-dialog-headline-font, var(--md-sys-typescale-headline-small-font, var(--md-ref-typeface-brand, Roboto)));font-size:var(--md-dialog-headline-size, var(--md-sys-typescale-headline-small-size, 1.5rem));line-height:var(--md-dialog-headline-line-height, var(--md-sys-typescale-headline-small-line-height, 2rem));font-weight:var(--md-dialog-headline-weight, var(--md-sys-typescale-headline-small-weight, var(--md-ref-typeface-weight-regular, 400)));position:relative}slot[name=headline]::slotted(*){align-items:center;align-self:stretch;box-sizing:border-box;display:flex;gap:8px;padding:24px 24px 0}.icon{display:flex}slot[name=icon]::slotted(*){color:var(--md-dialog-icon-color, var(--md-sys-color-secondary, #625b71));fill:currentColor;font-size:var(--md-dialog-icon-size, 24px);margin-top:24px;height:var(--md-dialog-icon-size, 24px);width:var(--md-dialog-icon-size, 24px)}.has-icon slot[name=headline]::slotted(*){justify-content:center;padding-top:16px}.scrollable slot[name=headline]::slotted(*){padding-bottom:16px}.scrollable.has-headline slot[name=content]::slotted(*){padding-top:8px}.container{border-radius:inherit;display:flex;flex-direction:column;flex-grow:1;overflow:hidden;position:relative;transform-origin:top}.container::before{background:var(--md-dialog-container-color, var(--md-sys-color-surface-container-high, #ece6f0));border-radius:inherit;content:"";inset:0;position:absolute}.scroller{display:flex;flex:1;flex-direction:column;overflow:hidden;z-index:1}.scrollable .scroller{overflow-y:scroll}.content{color:var(--md-dialog-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));font-family:var(--md-dialog-supporting-text-font, var(--md-sys-typescale-body-medium-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-dialog-supporting-text-size, var(--md-sys-typescale-body-medium-size, 0.875rem));line-height:var(--md-dialog-supporting-text-line-height, var(--md-sys-typescale-body-medium-line-height, 1.25rem));flex:1;font-weight:var(--md-dialog-supporting-text-weight, var(--md-sys-typescale-body-medium-weight, var(--md-ref-typeface-weight-regular, 400)));height:min-content;position:relative}slot[name=content]::slotted(*){box-sizing:border-box;padding:24px}.anchor{position:absolute}.top.anchor{top:0}.bottom.anchor{bottom:0}.actions{position:relative}slot[name=actions]::slotted(*){box-sizing:border-box;display:flex;gap:8px;justify-content:flex-end;padding:16px 24px 24px}.has-actions slot[name=content]::slotted(*){padding-bottom:8px}md-divider{display:none;position:absolute}.has-headline.show-top-divider .headline md-divider,.has-actions.show-bottom-divider .actions md-divider{display:flex}.headline md-divider{bottom:0}.actions md-divider{top:0}@media(forced-colors: active){dialog{outline:2px solid WindowText}}
1003
+ `;
1004
+ styles$4.styleSheet;
1005
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/dialog/dialog.js
1006
+ /**
1007
+ * @license
1008
+ * Copyright 2023 Google LLC
1009
+ * SPDX-License-Identifier: Apache-2.0
1010
+ */
1011
+ /**
1012
+ * @summary Dialogs can require an action, communicate information, or help
1013
+ * users accomplish a task. There are two types of dialogs: basic and
1014
+ * full-screen.
1015
+ *
1016
+ * @description
1017
+ * A dialog is a modal window that appears in front of app content to provide
1018
+ * critical information or ask for a decision. Dialogs disable all app
1019
+ * functionality when they appear, and remain on screen until confirmed,
1020
+ * dismissed, or a required action has been taken.
1021
+ *
1022
+ * Dialogs are purposefully interruptive, so they should be used sparingly.
1023
+ * A less disruptive alternative is to use a menu, which provides options
1024
+ * without interrupting a user’s experience.
1025
+ *
1026
+ * On mobile devices only, complex dialogs should be displayed fullscreen.
1027
+ *
1028
+ * __Example usages:__
1029
+ * - Common use cases for basic dialogs include alerts, quick selection, and
1030
+ * confirmation.
1031
+ * - More complex dialogs may contain actions that require a series of tasks
1032
+ * to complete. One example is creating a calendar entry with the event title,
1033
+ * date, location, and time.
1034
+ *
1035
+ * @final
1036
+ * @suppress {visibility}
1037
+ */
1038
+ var MdDialog = class MdDialog extends Dialog {};
1039
+ MdDialog.styles = [styles$4];
1040
+ MdDialog = __decorate([t$1("md-dialog")], MdDialog);
1041
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/field/internal/field.js
1042
+ /**
1043
+ * @license
1044
+ * Copyright 2021 Google LLC
1045
+ * SPDX-License-Identifier: Apache-2.0
1046
+ */
1047
+ /**
1048
+ * A field component.
1049
+ */
1050
+ var Field = class extends i$2 {
1051
+ constructor() {
1052
+ super(...arguments);
1053
+ this.disabled = false;
1054
+ this.error = false;
1055
+ this.focused = false;
1056
+ this.label = "";
1057
+ this.noAsterisk = false;
1058
+ this.populated = false;
1059
+ this.required = false;
1060
+ this.resizable = false;
1061
+ this.supportingText = "";
1062
+ this.errorText = "";
1063
+ this.count = -1;
1064
+ this.max = -1;
1065
+ /**
1066
+ * Whether or not the field has leading content.
1067
+ */
1068
+ this.hasStart = false;
1069
+ /**
1070
+ * Whether or not the field has trailing content.
1071
+ */
1072
+ this.hasEnd = false;
1073
+ this.isAnimating = false;
1074
+ /**
1075
+ * When set to true, the error text's `role="alert"` will be removed, then
1076
+ * re-added after an animation frame. This will re-announce an error message
1077
+ * to screen readers.
1078
+ */
1079
+ this.refreshErrorAlert = false;
1080
+ this.disableTransitions = false;
1081
+ }
1082
+ get counterText() {
1083
+ const countAsNumber = this.count ?? -1;
1084
+ const maxAsNumber = this.max ?? -1;
1085
+ if (countAsNumber < 0 || maxAsNumber <= 0) return "";
1086
+ return `${countAsNumber} / ${maxAsNumber}`;
1087
+ }
1088
+ get supportingOrErrorText() {
1089
+ return this.error && this.errorText ? this.errorText : this.supportingText;
1090
+ }
1091
+ /**
1092
+ * Re-announces the field's error supporting text to screen readers.
1093
+ *
1094
+ * Error text announces to screen readers anytime it is visible and changes.
1095
+ * Use the method to re-announce the message when the text has not changed,
1096
+ * but announcement is still needed (such as for `reportValidity()`).
1097
+ */
1098
+ reannounceError() {
1099
+ this.refreshErrorAlert = true;
1100
+ }
1101
+ update(props) {
1102
+ if (props.has("disabled") && props.get("disabled") !== void 0) this.disableTransitions = true;
1103
+ if (this.disabled && this.focused) {
1104
+ props.set("focused", true);
1105
+ this.focused = false;
1106
+ }
1107
+ this.animateLabelIfNeeded({
1108
+ wasFocused: props.get("focused"),
1109
+ wasPopulated: props.get("populated")
1110
+ });
1111
+ super.update(props);
1112
+ }
1113
+ render() {
1114
+ const floatingLabel = this.renderLabel(true);
1115
+ const restingLabel = this.renderLabel(false);
1116
+ const outline = this.renderOutline?.(floatingLabel);
1117
+ const classes = {
1118
+ "disabled": this.disabled,
1119
+ "disable-transitions": this.disableTransitions,
1120
+ "error": this.error && !this.disabled,
1121
+ "focused": this.focused,
1122
+ "with-start": this.hasStart,
1123
+ "with-end": this.hasEnd,
1124
+ "populated": this.populated,
1125
+ "resizable": this.resizable,
1126
+ "required": this.required,
1127
+ "no-label": !this.label
1128
+ };
1129
+ return T`
1130
+ <div class="field ${e$3(classes)}">
1131
+ <div class="container-overflow">
1132
+ ${this.renderBackground?.()}
1133
+ <slot name="container"></slot>
1134
+ ${this.renderStateLayer?.()} ${this.renderIndicator?.()} ${outline}
1135
+ <div class="container">
1136
+ <div class="start">
1137
+ <slot name="start"></slot>
1138
+ </div>
1139
+ <div class="middle">
1140
+ <div class="label-wrapper">
1141
+ ${restingLabel} ${outline ? A : floatingLabel}
1142
+ </div>
1143
+ <div class="content">
1144
+ <slot></slot>
1145
+ </div>
1146
+ </div>
1147
+ <div class="end">
1148
+ <slot name="end"></slot>
1149
+ </div>
1150
+ </div>
1151
+ </div>
1152
+ ${this.renderSupportingText()}
1153
+ </div>
1154
+ `;
1155
+ }
1156
+ updated(changed) {
1157
+ if (changed.has("supportingText") || changed.has("errorText") || changed.has("count") || changed.has("max")) this.updateSlottedAriaDescribedBy();
1158
+ if (this.refreshErrorAlert) requestAnimationFrame(() => {
1159
+ this.refreshErrorAlert = false;
1160
+ });
1161
+ if (this.disableTransitions) requestAnimationFrame(() => {
1162
+ this.disableTransitions = false;
1163
+ });
1164
+ }
1165
+ renderSupportingText() {
1166
+ const { supportingOrErrorText, counterText } = this;
1167
+ if (!supportingOrErrorText && !counterText) return A;
1168
+ const start = T`<span>${supportingOrErrorText}</span>`;
1169
+ const end = counterText ? T`<span class="counter">${counterText}</span>` : A;
1170
+ const role = this.error && this.errorText && !this.refreshErrorAlert ? "alert" : A;
1171
+ return T`
1172
+ <div class="supporting-text" role=${role}>${start}${end}</div>
1173
+ <slot
1174
+ name="aria-describedby"
1175
+ @slotchange=${this.updateSlottedAriaDescribedBy}></slot>
1176
+ `;
1177
+ }
1178
+ updateSlottedAriaDescribedBy() {
1179
+ for (const element of this.slottedAriaDescribedBy) {
1180
+ B(T`${this.supportingOrErrorText} ${this.counterText}`, element);
1181
+ element.setAttribute("hidden", "");
1182
+ }
1183
+ }
1184
+ renderLabel(isFloating) {
1185
+ if (!this.label) return A;
1186
+ let visible;
1187
+ if (isFloating) visible = this.focused || this.populated || this.isAnimating;
1188
+ else visible = !this.focused && !this.populated && !this.isAnimating;
1189
+ const classes = {
1190
+ "hidden": !visible,
1191
+ "floating": isFloating,
1192
+ "resting": !isFloating
1193
+ };
1194
+ const labelText = `${this.label}${this.required && !this.noAsterisk ? "*" : ""}`;
1195
+ return T`
1196
+ <span class="label ${e$3(classes)}" aria-hidden=${!visible}
1197
+ >${labelText}</span
1198
+ >
1199
+ `;
1200
+ }
1201
+ animateLabelIfNeeded({ wasFocused, wasPopulated }) {
1202
+ if (!this.label) return;
1203
+ wasFocused ??= this.focused;
1204
+ wasPopulated ??= this.populated;
1205
+ if ((wasFocused || wasPopulated) === (this.focused || this.populated)) return;
1206
+ const keyframes = this.getLabelKeyframes();
1207
+ if (!keyframes.length) return;
1208
+ this.isAnimating = true;
1209
+ this.labelAnimation?.cancel();
1210
+ this.labelAnimation = this.floatingLabelEl?.animate(keyframes, {
1211
+ duration: 150,
1212
+ easing: EASING.STANDARD
1213
+ });
1214
+ this.labelAnimation?.addEventListener("finish", () => {
1215
+ this.isAnimating = false;
1216
+ });
1217
+ }
1218
+ getLabelKeyframes() {
1219
+ const { floatingLabelEl, restingLabelEl } = this;
1220
+ if (!floatingLabelEl || !restingLabelEl) return [];
1221
+ const { x: floatingX, y: floatingY, height: floatingHeight } = floatingLabelEl.getBoundingClientRect();
1222
+ const { x: restingX, y: restingY, height: restingHeight } = restingLabelEl.getBoundingClientRect();
1223
+ const floatingScrollWidth = floatingLabelEl.scrollWidth;
1224
+ const restingScrollWidth = restingLabelEl.scrollWidth;
1225
+ if (floatingScrollWidth === 0 || restingScrollWidth === 0) return [];
1226
+ const scale = restingScrollWidth / floatingScrollWidth;
1227
+ const restTransform = `translateX(${restingX - floatingX}px) translateY(${restingY - floatingY + Math.round((restingHeight - floatingHeight * scale) / 2)}px) scale(${scale})`;
1228
+ const floatTransform = `translateX(0) translateY(0) scale(1)`;
1229
+ const restingClientWidth = restingLabelEl.clientWidth;
1230
+ const width = restingScrollWidth > restingClientWidth ? `${restingClientWidth / scale}px` : "";
1231
+ if (this.focused || this.populated) return [{
1232
+ transform: restTransform,
1233
+ width
1234
+ }, {
1235
+ transform: floatTransform,
1236
+ width
1237
+ }];
1238
+ return [{
1239
+ transform: floatTransform,
1240
+ width
1241
+ }, {
1242
+ transform: restTransform,
1243
+ width
1244
+ }];
1245
+ }
1246
+ getSurfacePositionClientRect() {
1247
+ return this.containerEl.getBoundingClientRect();
1248
+ }
1249
+ };
1250
+ __decorate([n$2({ type: Boolean })], Field.prototype, "disabled", void 0);
1251
+ __decorate([n$2({ type: Boolean })], Field.prototype, "error", void 0);
1252
+ __decorate([n$2({ type: Boolean })], Field.prototype, "focused", void 0);
1253
+ __decorate([n$2()], Field.prototype, "label", void 0);
1254
+ __decorate([n$2({
1255
+ type: Boolean,
1256
+ attribute: "no-asterisk"
1257
+ })], Field.prototype, "noAsterisk", void 0);
1258
+ __decorate([n$2({ type: Boolean })], Field.prototype, "populated", void 0);
1259
+ __decorate([n$2({ type: Boolean })], Field.prototype, "required", void 0);
1260
+ __decorate([n$2({ type: Boolean })], Field.prototype, "resizable", void 0);
1261
+ __decorate([n$2({ attribute: "supporting-text" })], Field.prototype, "supportingText", void 0);
1262
+ __decorate([n$2({ attribute: "error-text" })], Field.prototype, "errorText", void 0);
1263
+ __decorate([n$2({ type: Number })], Field.prototype, "count", void 0);
1264
+ __decorate([n$2({ type: Number })], Field.prototype, "max", void 0);
1265
+ __decorate([n$2({
1266
+ type: Boolean,
1267
+ attribute: "has-start"
1268
+ })], Field.prototype, "hasStart", void 0);
1269
+ __decorate([n$2({
1270
+ type: Boolean,
1271
+ attribute: "has-end"
1272
+ })], Field.prototype, "hasEnd", void 0);
1273
+ __decorate([o$1({ slot: "aria-describedby" })], Field.prototype, "slottedAriaDescribedBy", void 0);
1274
+ __decorate([r$1()], Field.prototype, "isAnimating", void 0);
1275
+ __decorate([r$1()], Field.prototype, "refreshErrorAlert", void 0);
1276
+ __decorate([r$1()], Field.prototype, "disableTransitions", void 0);
1277
+ __decorate([e$2(".label.floating")], Field.prototype, "floatingLabelEl", void 0);
1278
+ __decorate([e$2(".label.resting")], Field.prototype, "restingLabelEl", void 0);
1279
+ __decorate([e$2(".container")], Field.prototype, "containerEl", void 0);
1280
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/field/internal/outlined-field.js
1281
+ /**
1282
+ * @license
1283
+ * Copyright 2021 Google LLC
1284
+ * SPDX-License-Identifier: Apache-2.0
1285
+ */
1286
+ /**
1287
+ * An outlined field component.
1288
+ */
1289
+ var OutlinedField = class extends Field {
1290
+ renderOutline(floatingLabel) {
1291
+ return T`
1292
+ <div class="outline">
1293
+ <div class="outline-start"></div>
1294
+ <div class="outline-notch">
1295
+ <div class="outline-panel-inactive"></div>
1296
+ <div class="outline-panel-active"></div>
1297
+ <div class="outline-label">${floatingLabel}</div>
1298
+ </div>
1299
+ <div class="outline-end"></div>
1300
+ </div>
1301
+ `;
1302
+ }
1303
+ };
1304
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/field/internal/outlined-styles.cssresult.js
1305
+ /**
1306
+ * @license
1307
+ * Copyright 2026 Google LLC
1308
+ * SPDX-License-Identifier: Apache-2.0
1309
+ */
1310
+ var styles$3 = i$3`@layer styles{:host{--_bottom-space: var(--md-outlined-field-bottom-space, 16px);--_content-color: var(--md-outlined-field-content-color, var(--md-sys-color-on-surface, #1d1b20));--_content-font: var(--md-outlined-field-content-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));--_content-line-height: var(--md-outlined-field-content-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));--_content-size: var(--md-outlined-field-content-size, var(--md-sys-typescale-body-large-size, 1rem));--_content-space: var(--md-outlined-field-content-space, 16px);--_content-weight: var(--md-outlined-field-content-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));--_disabled-content-color: var(--md-outlined-field-disabled-content-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-content-opacity: var(--md-outlined-field-disabled-content-opacity, 0.38);--_disabled-label-text-color: var(--md-outlined-field-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity: var(--md-outlined-field-disabled-label-text-opacity, 0.38);--_disabled-leading-content-color: var(--md-outlined-field-disabled-leading-content-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-leading-content-opacity: var(--md-outlined-field-disabled-leading-content-opacity, 0.38);--_disabled-outline-color: var(--md-outlined-field-disabled-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-outline-opacity: var(--md-outlined-field-disabled-outline-opacity, 0.12);--_disabled-outline-width: var(--md-outlined-field-disabled-outline-width, 1px);--_disabled-supporting-text-color: var(--md-outlined-field-disabled-supporting-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-supporting-text-opacity: var(--md-outlined-field-disabled-supporting-text-opacity, 0.38);--_disabled-trailing-content-color: var(--md-outlined-field-disabled-trailing-content-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-trailing-content-opacity: var(--md-outlined-field-disabled-trailing-content-opacity, 0.38);--_error-content-color: var(--md-outlined-field-error-content-color, var(--md-sys-color-on-surface, #1d1b20));--_error-focus-content-color: var(--md-outlined-field-error-focus-content-color, var(--md-sys-color-on-surface, #1d1b20));--_error-focus-label-text-color: var(--md-outlined-field-error-focus-label-text-color, var(--md-sys-color-error, #b3261e));--_error-focus-leading-content-color: var(--md-outlined-field-error-focus-leading-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_error-focus-outline-color: var(--md-outlined-field-error-focus-outline-color, var(--md-sys-color-error, #b3261e));--_error-focus-supporting-text-color: var(--md-outlined-field-error-focus-supporting-text-color, var(--md-sys-color-error, #b3261e));--_error-focus-trailing-content-color: var(--md-outlined-field-error-focus-trailing-content-color, var(--md-sys-color-error, #b3261e));--_error-hover-content-color: var(--md-outlined-field-error-hover-content-color, var(--md-sys-color-on-surface, #1d1b20));--_error-hover-label-text-color: var(--md-outlined-field-error-hover-label-text-color, var(--md-sys-color-on-error-container, #410e0b));--_error-hover-leading-content-color: var(--md-outlined-field-error-hover-leading-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_error-hover-outline-color: var(--md-outlined-field-error-hover-outline-color, var(--md-sys-color-on-error-container, #410e0b));--_error-hover-supporting-text-color: var(--md-outlined-field-error-hover-supporting-text-color, var(--md-sys-color-error, #b3261e));--_error-hover-trailing-content-color: var(--md-outlined-field-error-hover-trailing-content-color, var(--md-sys-color-on-error-container, #410e0b));--_error-label-text-color: var(--md-outlined-field-error-label-text-color, var(--md-sys-color-error, #b3261e));--_error-leading-content-color: var(--md-outlined-field-error-leading-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_error-outline-color: var(--md-outlined-field-error-outline-color, var(--md-sys-color-error, #b3261e));--_error-supporting-text-color: var(--md-outlined-field-error-supporting-text-color, var(--md-sys-color-error, #b3261e));--_error-trailing-content-color: var(--md-outlined-field-error-trailing-content-color, var(--md-sys-color-error, #b3261e));--_focus-content-color: var(--md-outlined-field-focus-content-color, var(--md-sys-color-on-surface, #1d1b20));--_focus-label-text-color: var(--md-outlined-field-focus-label-text-color, var(--md-sys-color-primary, #6750a4));--_focus-leading-content-color: var(--md-outlined-field-focus-leading-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_focus-outline-color: var(--md-outlined-field-focus-outline-color, var(--md-sys-color-primary, #6750a4));--_focus-outline-width: var(--md-outlined-field-focus-outline-width, 3px);--_focus-supporting-text-color: var(--md-outlined-field-focus-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_focus-trailing-content-color: var(--md-outlined-field-focus-trailing-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-content-color: var(--md-outlined-field-hover-content-color, var(--md-sys-color-on-surface, #1d1b20));--_hover-label-text-color: var(--md-outlined-field-hover-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_hover-leading-content-color: var(--md-outlined-field-hover-leading-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-outline-color: var(--md-outlined-field-hover-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_hover-outline-width: var(--md-outlined-field-hover-outline-width, 1px);--_hover-supporting-text-color: var(--md-outlined-field-hover-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-trailing-content-color: var(--md-outlined-field-hover-trailing-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_label-text-color: var(--md-outlined-field-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_label-text-font: var(--md-outlined-field-label-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height: var(--md-outlined-field-label-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));--_label-text-padding-bottom: var(--md-outlined-field-label-text-padding-bottom, 8px);--_label-text-populated-line-height: var(--md-outlined-field-label-text-populated-line-height, var(--md-sys-typescale-body-small-line-height, 1rem));--_label-text-populated-size: var(--md-outlined-field-label-text-populated-size, var(--md-sys-typescale-body-small-size, 0.75rem));--_label-text-size: var(--md-outlined-field-label-text-size, var(--md-sys-typescale-body-large-size, 1rem));--_label-text-weight: var(--md-outlined-field-label-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));--_leading-content-color: var(--md-outlined-field-leading-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_leading-space: var(--md-outlined-field-leading-space, 16px);--_outline-color: var(--md-outlined-field-outline-color, var(--md-sys-color-outline, #79747e));--_outline-label-padding: var(--md-outlined-field-outline-label-padding, 4px);--_outline-width: var(--md-outlined-field-outline-width, 1px);--_supporting-text-color: var(--md-outlined-field-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_supporting-text-font: var(--md-outlined-field-supporting-text-font, var(--md-sys-typescale-body-small-font, var(--md-ref-typeface-plain, Roboto)));--_supporting-text-leading-space: var(--md-outlined-field-supporting-text-leading-space, 16px);--_supporting-text-line-height: var(--md-outlined-field-supporting-text-line-height, var(--md-sys-typescale-body-small-line-height, 1rem));--_supporting-text-size: var(--md-outlined-field-supporting-text-size, var(--md-sys-typescale-body-small-size, 0.75rem));--_supporting-text-top-space: var(--md-outlined-field-supporting-text-top-space, 4px);--_supporting-text-trailing-space: var(--md-outlined-field-supporting-text-trailing-space, 16px);--_supporting-text-weight: var(--md-outlined-field-supporting-text-weight, var(--md-sys-typescale-body-small-weight, var(--md-ref-typeface-weight-regular, 400)));--_top-space: var(--md-outlined-field-top-space, 16px);--_trailing-content-color: var(--md-outlined-field-trailing-content-color, var(--md-sys-color-on-surface-variant, #49454f));--_trailing-space: var(--md-outlined-field-trailing-space, 16px);--_with-leading-content-leading-space: var(--md-outlined-field-with-leading-content-leading-space, 12px);--_with-trailing-content-trailing-space: var(--md-outlined-field-with-trailing-content-trailing-space, 12px);--_container-shape-start-start: var(--md-outlined-field-container-shape-start-start, var(--md-outlined-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_container-shape-start-end: var(--md-outlined-field-container-shape-start-end, var(--md-outlined-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_container-shape-end-end: var(--md-outlined-field-container-shape-end-end, var(--md-outlined-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_container-shape-end-start: var(--md-outlined-field-container-shape-end-start, var(--md-outlined-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)))}.outline{border-color:var(--_outline-color);border-radius:inherit;display:flex;pointer-events:none;height:100%;position:absolute;width:100%;z-index:1}.outline-start::before,.outline-start::after,.outline-panel-inactive::before,.outline-panel-inactive::after,.outline-panel-active::before,.outline-panel-active::after,.outline-end::before,.outline-end::after{border:inherit;content:"";inset:0;position:absolute}.outline-start,.outline-end{border:inherit;border-radius:inherit;box-sizing:border-box;position:relative}.outline-start::before,.outline-start::after,.outline-end::before,.outline-end::after{border-bottom-style:solid;border-top-style:solid}.outline-start::after,.outline-end::after{opacity:0;transition:opacity 150ms cubic-bezier(0.2, 0, 0, 1)}.focused .outline-start::after,.focused .outline-end::after{opacity:1}.outline-start::before,.outline-start::after{border-inline-start-style:solid;border-inline-end-style:none;border-start-start-radius:inherit;border-start-end-radius:0;border-end-start-radius:inherit;border-end-end-radius:0;margin-inline-end:var(--_outline-label-padding)}.outline-end{flex-grow:1;margin-inline-start:calc(-1*var(--_outline-label-padding))}.outline-end::before,.outline-end::after{border-inline-start-style:none;border-inline-end-style:solid;border-start-start-radius:0;border-start-end-radius:inherit;border-end-start-radius:0;border-end-end-radius:inherit}.outline-notch{align-items:flex-start;border:inherit;display:flex;margin-inline-start:calc(-1*var(--_outline-label-padding));margin-inline-end:var(--_outline-label-padding);max-width:calc(100% - var(--_leading-space) - var(--_trailing-space));padding:0 var(--_outline-label-padding);position:relative}.no-label .outline-notch{display:none}.outline-panel-inactive,.outline-panel-active{border:inherit;border-bottom-style:solid;inset:0;position:absolute}.outline-panel-inactive::before,.outline-panel-inactive::after,.outline-panel-active::before,.outline-panel-active::after{border-top-style:solid;border-bottom:none;bottom:auto;transform:scaleX(1);transition:transform 150ms cubic-bezier(0.2, 0, 0, 1)}.outline-panel-inactive::before,.outline-panel-active::before{right:50%;transform-origin:top left}.outline-panel-inactive::after,.outline-panel-active::after{left:50%;transform-origin:top right}.populated .outline-panel-inactive::before,.populated .outline-panel-inactive::after,.populated .outline-panel-active::before,.populated .outline-panel-active::after,.focused .outline-panel-inactive::before,.focused .outline-panel-inactive::after,.focused .outline-panel-active::before,.focused .outline-panel-active::after{transform:scaleX(0)}.outline-panel-active{opacity:0;transition:opacity 150ms cubic-bezier(0.2, 0, 0, 1)}.focused .outline-panel-active{opacity:1}.outline-label{display:flex;max-width:100%;transform:translateY(calc(-100% + var(--_label-text-padding-bottom)))}.outline-start,.field:not(.with-start) .content ::slotted(*){padding-inline-start:max(var(--_leading-space),max(var(--_container-shape-start-start),var(--_container-shape-end-start)) + var(--_outline-label-padding))}.field:not(.with-start) .label-wrapper{margin-inline-start:max(var(--_leading-space),max(var(--_container-shape-start-start),var(--_container-shape-end-start)) + var(--_outline-label-padding))}.field:not(.with-end) .content ::slotted(*){padding-inline-end:max(var(--_trailing-space),max(var(--_container-shape-start-end),var(--_container-shape-end-end)))}.field:not(.with-end) .label-wrapper{margin-inline-end:max(var(--_trailing-space),max(var(--_container-shape-start-end),var(--_container-shape-end-end)))}.outline-start::before,.outline-end::before,.outline-panel-inactive,.outline-panel-inactive::before,.outline-panel-inactive::after{border-width:var(--_outline-width)}:hover .outline{border-color:var(--_hover-outline-color);color:var(--_hover-outline-color)}:hover .outline-start::before,:hover .outline-end::before,:hover .outline-panel-inactive,:hover .outline-panel-inactive::before,:hover .outline-panel-inactive::after{border-width:var(--_hover-outline-width)}.focused .outline{border-color:var(--_focus-outline-color);color:var(--_focus-outline-color)}.outline-start::after,.outline-end::after,.outline-panel-active,.outline-panel-active::before,.outline-panel-active::after{border-width:var(--_focus-outline-width)}.disabled .outline{border-color:var(--_disabled-outline-color);color:var(--_disabled-outline-color)}.disabled .outline-start,.disabled .outline-end,.disabled .outline-panel-inactive{opacity:var(--_disabled-outline-opacity)}.disabled .outline-start::before,.disabled .outline-end::before,.disabled .outline-panel-inactive,.disabled .outline-panel-inactive::before,.disabled .outline-panel-inactive::after{border-width:var(--_disabled-outline-width)}.error .outline{border-color:var(--_error-outline-color);color:var(--_error-outline-color)}.error:hover .outline{border-color:var(--_error-hover-outline-color);color:var(--_error-hover-outline-color)}.error.focused .outline{border-color:var(--_error-focus-outline-color);color:var(--_error-focus-outline-color)}.resizable .container{bottom:var(--_focus-outline-width);inset-inline-end:var(--_focus-outline-width);clip-path:inset(var(--_focus-outline-width) 0 0 var(--_focus-outline-width))}.resizable .container>*{top:var(--_focus-outline-width);inset-inline-start:var(--_focus-outline-width)}.resizable .container:dir(rtl){clip-path:inset(var(--_focus-outline-width) var(--_focus-outline-width) 0 0)}}@layer hcm{@media(forced-colors: active){.disabled .outline{border-color:GrayText;color:GrayText}.disabled :is(.outline-start,.outline-end,.outline-panel-inactive){opacity:1}}}
1311
+ `;
1312
+ styles$3.styleSheet;
1313
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/field/internal/shared-styles.cssresult.js
1314
+ /**
1315
+ * @license
1316
+ * Copyright 2026 Google LLC
1317
+ * SPDX-License-Identifier: Apache-2.0
1318
+ */
1319
+ var styles$2 = i$3`:host{display:inline-flex;resize:both}.field{display:flex;flex:1;flex-direction:column;writing-mode:horizontal-tb;max-width:100%}.container-overflow{border-start-start-radius:var(--_container-shape-start-start);border-start-end-radius:var(--_container-shape-start-end);border-end-end-radius:var(--_container-shape-end-end);border-end-start-radius:var(--_container-shape-end-start);display:flex;height:100%;position:relative}.container{align-items:center;border-radius:inherit;display:flex;flex:1;max-height:100%;min-height:100%;min-width:min-content;position:relative}.field,.container-overflow{resize:inherit}.resizable:not(.disabled) .container{resize:inherit;overflow:hidden}.disabled{pointer-events:none}slot[name=container]{border-radius:inherit}slot[name=container]::slotted(*){border-radius:inherit;inset:0;pointer-events:none;position:absolute}@layer styles{.start,.middle,.end{display:flex;box-sizing:border-box;height:100%;position:relative}.start{color:var(--_leading-content-color)}.end{color:var(--_trailing-content-color)}.start,.end{align-items:center;justify-content:center}.with-start .start{margin-inline:var(--_with-leading-content-leading-space) var(--_content-space)}.with-end .end{margin-inline:var(--_content-space) var(--_with-trailing-content-trailing-space)}.middle{align-items:stretch;align-self:baseline;flex:1}.content{color:var(--_content-color);display:flex;flex:1;opacity:0;transition:opacity 83ms cubic-bezier(0.2, 0, 0, 1)}.no-label .content,.focused .content,.populated .content{opacity:1;transition-delay:67ms}:is(.disabled,.disable-transitions) .content{transition:none}.content ::slotted(*){all:unset;color:currentColor;font-family:var(--_content-font);font-size:var(--_content-size);line-height:var(--_content-line-height);font-weight:var(--_content-weight);width:100%;overflow-wrap:revert;white-space:revert}.content ::slotted(:not(textarea)){padding-top:var(--_top-space);padding-bottom:var(--_bottom-space)}.content ::slotted(textarea){margin-top:var(--_top-space);margin-bottom:var(--_bottom-space)}:hover .content{color:var(--_hover-content-color)}:hover .start{color:var(--_hover-leading-content-color)}:hover .end{color:var(--_hover-trailing-content-color)}.focused .content{color:var(--_focus-content-color)}.focused .start{color:var(--_focus-leading-content-color)}.focused .end{color:var(--_focus-trailing-content-color)}.disabled .content{color:var(--_disabled-content-color)}.disabled.no-label .content,.disabled.focused .content,.disabled.populated .content{opacity:var(--_disabled-content-opacity)}.disabled .start{color:var(--_disabled-leading-content-color);opacity:var(--_disabled-leading-content-opacity)}.disabled .end{color:var(--_disabled-trailing-content-color);opacity:var(--_disabled-trailing-content-opacity)}.error .content{color:var(--_error-content-color)}.error .start{color:var(--_error-leading-content-color)}.error .end{color:var(--_error-trailing-content-color)}.error:hover .content{color:var(--_error-hover-content-color)}.error:hover .start{color:var(--_error-hover-leading-content-color)}.error:hover .end{color:var(--_error-hover-trailing-content-color)}.error.focused .content{color:var(--_error-focus-content-color)}.error.focused .start{color:var(--_error-focus-leading-content-color)}.error.focused .end{color:var(--_error-focus-trailing-content-color)}}@layer hcm{@media(forced-colors: active){.disabled :is(.start,.content,.end){color:GrayText;opacity:1}}}@layer styles{.label{box-sizing:border-box;color:var(--_label-text-color);overflow:hidden;max-width:100%;text-overflow:ellipsis;white-space:nowrap;z-index:1;font-family:var(--_label-text-font);font-size:var(--_label-text-size);line-height:var(--_label-text-line-height);font-weight:var(--_label-text-weight);width:min-content}.label-wrapper{inset:0;pointer-events:none;position:absolute}.label.resting{position:absolute;top:var(--_top-space)}.label.floating{font-size:var(--_label-text-populated-size);line-height:var(--_label-text-populated-line-height);transform-origin:top left}.label.hidden{opacity:0}.no-label .label{display:none}.label-wrapper{inset:0;position:absolute;text-align:initial}:hover .label{color:var(--_hover-label-text-color)}.focused .label{color:var(--_focus-label-text-color)}.disabled .label{color:var(--_disabled-label-text-color)}.disabled .label:not(.hidden){opacity:var(--_disabled-label-text-opacity)}.error .label{color:var(--_error-label-text-color)}.error:hover .label{color:var(--_error-hover-label-text-color)}.error.focused .label{color:var(--_error-focus-label-text-color)}}@layer hcm{@media(forced-colors: active){.disabled .label:not(.hidden){color:GrayText;opacity:1}}}@layer styles{.supporting-text{color:var(--_supporting-text-color);display:flex;font-family:var(--_supporting-text-font);font-size:var(--_supporting-text-size);line-height:var(--_supporting-text-line-height);font-weight:var(--_supporting-text-weight);gap:16px;justify-content:space-between;padding-inline-start:var(--_supporting-text-leading-space);padding-inline-end:var(--_supporting-text-trailing-space);padding-top:var(--_supporting-text-top-space)}.supporting-text :nth-child(2){flex-shrink:0}:hover .supporting-text{color:var(--_hover-supporting-text-color)}.focus .supporting-text{color:var(--_focus-supporting-text-color)}.disabled .supporting-text{color:var(--_disabled-supporting-text-color);opacity:var(--_disabled-supporting-text-opacity)}.error .supporting-text{color:var(--_error-supporting-text-color)}.error:hover .supporting-text{color:var(--_error-hover-supporting-text-color)}.error.focus .supporting-text{color:var(--_error-focus-supporting-text-color)}}@layer hcm{@media(forced-colors: active){.disabled .supporting-text{color:GrayText;opacity:1}}}
1320
+ `;
1321
+ styles$2.styleSheet;
1322
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/field/outlined-field.js
1323
+ /**
1324
+ * @license
1325
+ * Copyright 2021 Google LLC
1326
+ * SPDX-License-Identifier: Apache-2.0
1327
+ */
1328
+ /**
1329
+ * TODO(b/228525797): add docs
1330
+ * @final
1331
+ * @suppress {visibility}
1332
+ */
1333
+ var MdOutlinedField = class MdOutlinedField extends OutlinedField {};
1334
+ MdOutlinedField.styles = [styles$2, styles$3];
1335
+ MdOutlinedField = __decorate([t$1("md-outlined-field")], MdOutlinedField);
1336
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/textfield/internal/outlined-styles.cssresult.js
1337
+ /**
1338
+ * @license
1339
+ * Copyright 2026 Google LLC
1340
+ * SPDX-License-Identifier: Apache-2.0
1341
+ */
1342
+ var styles$1 = i$3`:host{--_caret-color: var(--md-outlined-text-field-caret-color, var(--md-sys-color-primary, #6750a4));--_disabled-input-text-color: var(--md-outlined-text-field-disabled-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-input-text-opacity: var(--md-outlined-text-field-disabled-input-text-opacity, 0.38);--_disabled-label-text-color: var(--md-outlined-text-field-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity: var(--md-outlined-text-field-disabled-label-text-opacity, 0.38);--_disabled-leading-icon-color: var(--md-outlined-text-field-disabled-leading-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-leading-icon-opacity: var(--md-outlined-text-field-disabled-leading-icon-opacity, 0.38);--_disabled-outline-color: var(--md-outlined-text-field-disabled-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-outline-opacity: var(--md-outlined-text-field-disabled-outline-opacity, 0.12);--_disabled-outline-width: var(--md-outlined-text-field-disabled-outline-width, 1px);--_disabled-supporting-text-color: var(--md-outlined-text-field-disabled-supporting-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-supporting-text-opacity: var(--md-outlined-text-field-disabled-supporting-text-opacity, 0.38);--_disabled-trailing-icon-color: var(--md-outlined-text-field-disabled-trailing-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-trailing-icon-opacity: var(--md-outlined-text-field-disabled-trailing-icon-opacity, 0.38);--_error-focus-caret-color: var(--md-outlined-text-field-error-focus-caret-color, var(--md-sys-color-error, #b3261e));--_error-focus-input-text-color: var(--md-outlined-text-field-error-focus-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_error-focus-label-text-color: var(--md-outlined-text-field-error-focus-label-text-color, var(--md-sys-color-error, #b3261e));--_error-focus-leading-icon-color: var(--md-outlined-text-field-error-focus-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_error-focus-outline-color: var(--md-outlined-text-field-error-focus-outline-color, var(--md-sys-color-error, #b3261e));--_error-focus-supporting-text-color: var(--md-outlined-text-field-error-focus-supporting-text-color, var(--md-sys-color-error, #b3261e));--_error-focus-trailing-icon-color: var(--md-outlined-text-field-error-focus-trailing-icon-color, var(--md-sys-color-error, #b3261e));--_error-hover-input-text-color: var(--md-outlined-text-field-error-hover-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_error-hover-label-text-color: var(--md-outlined-text-field-error-hover-label-text-color, var(--md-sys-color-on-error-container, #410e0b));--_error-hover-leading-icon-color: var(--md-outlined-text-field-error-hover-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_error-hover-outline-color: var(--md-outlined-text-field-error-hover-outline-color, var(--md-sys-color-on-error-container, #410e0b));--_error-hover-supporting-text-color: var(--md-outlined-text-field-error-hover-supporting-text-color, var(--md-sys-color-error, #b3261e));--_error-hover-trailing-icon-color: var(--md-outlined-text-field-error-hover-trailing-icon-color, var(--md-sys-color-on-error-container, #410e0b));--_error-input-text-color: var(--md-outlined-text-field-error-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_error-label-text-color: var(--md-outlined-text-field-error-label-text-color, var(--md-sys-color-error, #b3261e));--_error-leading-icon-color: var(--md-outlined-text-field-error-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_error-outline-color: var(--md-outlined-text-field-error-outline-color, var(--md-sys-color-error, #b3261e));--_error-supporting-text-color: var(--md-outlined-text-field-error-supporting-text-color, var(--md-sys-color-error, #b3261e));--_error-trailing-icon-color: var(--md-outlined-text-field-error-trailing-icon-color, var(--md-sys-color-error, #b3261e));--_focus-input-text-color: var(--md-outlined-text-field-focus-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_focus-label-text-color: var(--md-outlined-text-field-focus-label-text-color, var(--md-sys-color-primary, #6750a4));--_focus-leading-icon-color: var(--md-outlined-text-field-focus-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_focus-outline-color: var(--md-outlined-text-field-focus-outline-color, var(--md-sys-color-primary, #6750a4));--_focus-outline-width: var(--md-outlined-text-field-focus-outline-width, 3px);--_focus-supporting-text-color: var(--md-outlined-text-field-focus-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_focus-trailing-icon-color: var(--md-outlined-text-field-focus-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-input-text-color: var(--md-outlined-text-field-hover-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_hover-label-text-color: var(--md-outlined-text-field-hover-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_hover-leading-icon-color: var(--md-outlined-text-field-hover-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-outline-color: var(--md-outlined-text-field-hover-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_hover-outline-width: var(--md-outlined-text-field-hover-outline-width, 1px);--_hover-supporting-text-color: var(--md-outlined-text-field-hover-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-trailing-icon-color: var(--md-outlined-text-field-hover-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_input-text-color: var(--md-outlined-text-field-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_input-text-font: var(--md-outlined-text-field-input-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));--_input-text-line-height: var(--md-outlined-text-field-input-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));--_input-text-placeholder-color: var(--md-outlined-text-field-input-text-placeholder-color, var(--md-sys-color-on-surface-variant, #49454f));--_input-text-prefix-color: var(--md-outlined-text-field-input-text-prefix-color, var(--md-sys-color-on-surface-variant, #49454f));--_input-text-size: var(--md-outlined-text-field-input-text-size, var(--md-sys-typescale-body-large-size, 1rem));--_input-text-suffix-color: var(--md-outlined-text-field-input-text-suffix-color, var(--md-sys-color-on-surface-variant, #49454f));--_input-text-weight: var(--md-outlined-text-field-input-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));--_label-text-color: var(--md-outlined-text-field-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_label-text-font: var(--md-outlined-text-field-label-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height: var(--md-outlined-text-field-label-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));--_label-text-populated-line-height: var(--md-outlined-text-field-label-text-populated-line-height, var(--md-sys-typescale-body-small-line-height, 1rem));--_label-text-populated-size: var(--md-outlined-text-field-label-text-populated-size, var(--md-sys-typescale-body-small-size, 0.75rem));--_label-text-size: var(--md-outlined-text-field-label-text-size, var(--md-sys-typescale-body-large-size, 1rem));--_label-text-weight: var(--md-outlined-text-field-label-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));--_leading-icon-color: var(--md-outlined-text-field-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_leading-icon-size: var(--md-outlined-text-field-leading-icon-size, 24px);--_outline-color: var(--md-outlined-text-field-outline-color, var(--md-sys-color-outline, #79747e));--_outline-width: var(--md-outlined-text-field-outline-width, 1px);--_supporting-text-color: var(--md-outlined-text-field-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_supporting-text-font: var(--md-outlined-text-field-supporting-text-font, var(--md-sys-typescale-body-small-font, var(--md-ref-typeface-plain, Roboto)));--_supporting-text-line-height: var(--md-outlined-text-field-supporting-text-line-height, var(--md-sys-typescale-body-small-line-height, 1rem));--_supporting-text-size: var(--md-outlined-text-field-supporting-text-size, var(--md-sys-typescale-body-small-size, 0.75rem));--_supporting-text-weight: var(--md-outlined-text-field-supporting-text-weight, var(--md-sys-typescale-body-small-weight, var(--md-ref-typeface-weight-regular, 400)));--_trailing-icon-color: var(--md-outlined-text-field-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_trailing-icon-size: var(--md-outlined-text-field-trailing-icon-size, 24px);--_container-shape-start-start: var(--md-outlined-text-field-container-shape-start-start, var(--md-outlined-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_container-shape-start-end: var(--md-outlined-text-field-container-shape-start-end, var(--md-outlined-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_container-shape-end-end: var(--md-outlined-text-field-container-shape-end-end, var(--md-outlined-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_container-shape-end-start: var(--md-outlined-text-field-container-shape-end-start, var(--md-outlined-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_icon-input-space: var(--md-outlined-text-field-icon-input-space, 16px);--_leading-space: var(--md-outlined-text-field-leading-space, 16px);--_trailing-space: var(--md-outlined-text-field-trailing-space, 16px);--_top-space: var(--md-outlined-text-field-top-space, 16px);--_bottom-space: var(--md-outlined-text-field-bottom-space, 16px);--_input-text-prefix-trailing-space: var(--md-outlined-text-field-input-text-prefix-trailing-space, 2px);--_input-text-suffix-leading-space: var(--md-outlined-text-field-input-text-suffix-leading-space, 2px);--_focus-caret-color: var(--md-outlined-text-field-focus-caret-color, var(--md-sys-color-primary, #6750a4));--_with-leading-icon-leading-space: var(--md-outlined-text-field-with-leading-icon-leading-space, 12px);--_with-trailing-icon-trailing-space: var(--md-outlined-text-field-with-trailing-icon-trailing-space, 12px);--md-outlined-field-bottom-space: var(--_bottom-space);--md-outlined-field-container-shape-end-end: var(--_container-shape-end-end);--md-outlined-field-container-shape-end-start: var(--_container-shape-end-start);--md-outlined-field-container-shape-start-end: var(--_container-shape-start-end);--md-outlined-field-container-shape-start-start: var(--_container-shape-start-start);--md-outlined-field-content-color: var(--_input-text-color);--md-outlined-field-content-font: var(--_input-text-font);--md-outlined-field-content-line-height: var(--_input-text-line-height);--md-outlined-field-content-size: var(--_input-text-size);--md-outlined-field-content-space: var(--_icon-input-space);--md-outlined-field-content-weight: var(--_input-text-weight);--md-outlined-field-disabled-content-color: var(--_disabled-input-text-color);--md-outlined-field-disabled-content-opacity: var(--_disabled-input-text-opacity);--md-outlined-field-disabled-label-text-color: var(--_disabled-label-text-color);--md-outlined-field-disabled-label-text-opacity: var(--_disabled-label-text-opacity);--md-outlined-field-disabled-leading-content-color: var(--_disabled-leading-icon-color);--md-outlined-field-disabled-leading-content-opacity: var(--_disabled-leading-icon-opacity);--md-outlined-field-disabled-outline-color: var(--_disabled-outline-color);--md-outlined-field-disabled-outline-opacity: var(--_disabled-outline-opacity);--md-outlined-field-disabled-outline-width: var(--_disabled-outline-width);--md-outlined-field-disabled-supporting-text-color: var(--_disabled-supporting-text-color);--md-outlined-field-disabled-supporting-text-opacity: var(--_disabled-supporting-text-opacity);--md-outlined-field-disabled-trailing-content-color: var(--_disabled-trailing-icon-color);--md-outlined-field-disabled-trailing-content-opacity: var(--_disabled-trailing-icon-opacity);--md-outlined-field-error-content-color: var(--_error-input-text-color);--md-outlined-field-error-focus-content-color: var(--_error-focus-input-text-color);--md-outlined-field-error-focus-label-text-color: var(--_error-focus-label-text-color);--md-outlined-field-error-focus-leading-content-color: var(--_error-focus-leading-icon-color);--md-outlined-field-error-focus-outline-color: var(--_error-focus-outline-color);--md-outlined-field-error-focus-supporting-text-color: var(--_error-focus-supporting-text-color);--md-outlined-field-error-focus-trailing-content-color: var(--_error-focus-trailing-icon-color);--md-outlined-field-error-hover-content-color: var(--_error-hover-input-text-color);--md-outlined-field-error-hover-label-text-color: var(--_error-hover-label-text-color);--md-outlined-field-error-hover-leading-content-color: var(--_error-hover-leading-icon-color);--md-outlined-field-error-hover-outline-color: var(--_error-hover-outline-color);--md-outlined-field-error-hover-supporting-text-color: var(--_error-hover-supporting-text-color);--md-outlined-field-error-hover-trailing-content-color: var(--_error-hover-trailing-icon-color);--md-outlined-field-error-label-text-color: var(--_error-label-text-color);--md-outlined-field-error-leading-content-color: var(--_error-leading-icon-color);--md-outlined-field-error-outline-color: var(--_error-outline-color);--md-outlined-field-error-supporting-text-color: var(--_error-supporting-text-color);--md-outlined-field-error-trailing-content-color: var(--_error-trailing-icon-color);--md-outlined-field-focus-content-color: var(--_focus-input-text-color);--md-outlined-field-focus-label-text-color: var(--_focus-label-text-color);--md-outlined-field-focus-leading-content-color: var(--_focus-leading-icon-color);--md-outlined-field-focus-outline-color: var(--_focus-outline-color);--md-outlined-field-focus-outline-width: var(--_focus-outline-width);--md-outlined-field-focus-supporting-text-color: var(--_focus-supporting-text-color);--md-outlined-field-focus-trailing-content-color: var(--_focus-trailing-icon-color);--md-outlined-field-hover-content-color: var(--_hover-input-text-color);--md-outlined-field-hover-label-text-color: var(--_hover-label-text-color);--md-outlined-field-hover-leading-content-color: var(--_hover-leading-icon-color);--md-outlined-field-hover-outline-color: var(--_hover-outline-color);--md-outlined-field-hover-outline-width: var(--_hover-outline-width);--md-outlined-field-hover-supporting-text-color: var(--_hover-supporting-text-color);--md-outlined-field-hover-trailing-content-color: var(--_hover-trailing-icon-color);--md-outlined-field-label-text-color: var(--_label-text-color);--md-outlined-field-label-text-font: var(--_label-text-font);--md-outlined-field-label-text-line-height: var(--_label-text-line-height);--md-outlined-field-label-text-populated-line-height: var(--_label-text-populated-line-height);--md-outlined-field-label-text-populated-size: var(--_label-text-populated-size);--md-outlined-field-label-text-size: var(--_label-text-size);--md-outlined-field-label-text-weight: var(--_label-text-weight);--md-outlined-field-leading-content-color: var(--_leading-icon-color);--md-outlined-field-leading-space: var(--_leading-space);--md-outlined-field-outline-color: var(--_outline-color);--md-outlined-field-outline-width: var(--_outline-width);--md-outlined-field-supporting-text-color: var(--_supporting-text-color);--md-outlined-field-supporting-text-font: var(--_supporting-text-font);--md-outlined-field-supporting-text-line-height: var(--_supporting-text-line-height);--md-outlined-field-supporting-text-size: var(--_supporting-text-size);--md-outlined-field-supporting-text-weight: var(--_supporting-text-weight);--md-outlined-field-top-space: var(--_top-space);--md-outlined-field-trailing-content-color: var(--_trailing-icon-color);--md-outlined-field-trailing-space: var(--_trailing-space);--md-outlined-field-with-leading-content-leading-space: var(--_with-leading-icon-leading-space);--md-outlined-field-with-trailing-content-trailing-space: var(--_with-trailing-icon-trailing-space)}
1343
+ `;
1344
+ styles$1.styleSheet;
1345
+ // ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/directive-helpers.js
1346
+ /**
1347
+ * @license
1348
+ * Copyright 2020 Google LLC
1349
+ * SPDX-License-Identifier: BSD-3-Clause
1350
+ */ var { I: t } = Z, r = (o) => void 0 === o.strings, m = {}, p = (o, t = m) => o._$AH = t;
1351
+ // ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/directives/live.js
1352
+ /**
1353
+ * @license
1354
+ * Copyright 2020 Google LLC
1355
+ * SPDX-License-Identifier: BSD-3-Clause
1356
+ */ var l = e$4(class extends i$4 {
1357
+ constructor(r$2) {
1358
+ if (super(r$2), r$2.type !== t$2.PROPERTY && r$2.type !== t$2.ATTRIBUTE && r$2.type !== t$2.BOOLEAN_ATTRIBUTE) throw Error("The `live` directive is not allowed on child or event bindings");
1359
+ if (!r(r$2)) throw Error("`live` bindings can only contain a single expression");
1360
+ }
1361
+ render(r) {
1362
+ return r;
1363
+ }
1364
+ update(i, [t]) {
1365
+ if (t === E || t === A) return t;
1366
+ const o = i.element, l = i.name;
1367
+ if (i.type === t$2.PROPERTY) {
1368
+ if (t === o[l]) return E;
1369
+ } else if (i.type === t$2.BOOLEAN_ATTRIBUTE) {
1370
+ if (!!t === o.hasAttribute(l)) return E;
1371
+ } else if (i.type === t$2.ATTRIBUTE && o.getAttribute(l) === t + "") return E;
1372
+ return p(i), t;
1373
+ }
1374
+ });
1375
+ // ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/directives/style-map.js
1376
+ /**
1377
+ * @license
1378
+ * Copyright 2018 Google LLC
1379
+ * SPDX-License-Identifier: BSD-3-Clause
1380
+ */ var n = "important";
1381
+ var i = " !" + n;
1382
+ var o = e$4(class extends i$4 {
1383
+ constructor(t) {
1384
+ if (super(t), t.type !== t$2.ATTRIBUTE || "style" !== t.name || t.strings?.length > 2) throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.");
1385
+ }
1386
+ render(t) {
1387
+ return Object.keys(t).reduce((e, r) => {
1388
+ const s = t[r];
1389
+ return null == s ? e : e + `${r = r.includes("-") ? r : r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g, "-$&").toLowerCase()}:${s};`;
1390
+ }, "");
1391
+ }
1392
+ update(e, [r]) {
1393
+ const { style: s } = e.element;
1394
+ if (void 0 === this.ft) return this.ft = new Set(Object.keys(r)), this.render(r);
1395
+ for (const t of this.ft) r[t] ?? (this.ft.delete(t), t.includes("-") ? s.removeProperty(t) : s[t] = null);
1396
+ for (const t in r) {
1397
+ const e = r[t];
1398
+ if (null != e) {
1399
+ this.ft.add(t);
1400
+ const r = "string" == typeof e && e.endsWith(i);
1401
+ t.includes("-") || r ? s.setProperty(t, r ? e.slice(0, -11) : e, r ? n : "") : s[t] = e;
1402
+ }
1403
+ }
1404
+ return E;
1405
+ }
1406
+ });
1407
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/internal/controller/string-converter.js
1408
+ /**
1409
+ * @license
1410
+ * Copyright 2022 Google LLC
1411
+ * SPDX-License-Identifier: Apache-2.0
1412
+ */
1413
+ var stringConverter = {
1414
+ fromAttribute(value) {
1415
+ return value ?? "";
1416
+ },
1417
+ toAttribute(value) {
1418
+ return value || null;
1419
+ }
1420
+ };
1421
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/behaviors/constraint-validation.js
1422
+ /**
1423
+ * @license
1424
+ * Copyright 2023 Google LLC
1425
+ * SPDX-License-Identifier: Apache-2.0
1426
+ */
1427
+ /**
1428
+ * A symbol property used to create a constraint validation `Validator`.
1429
+ * Required for all `mixinConstraintValidation()` elements.
1430
+ */
1431
+ var createValidator = Symbol("createValidator");
1432
+ /**
1433
+ * A symbol property used to return an anchor for constraint validation popups.
1434
+ * Required for all `mixinConstraintValidation()` elements.
1435
+ */
1436
+ var getValidityAnchor = Symbol("getValidityAnchor");
1437
+ var privateSyncValidity = Symbol("privateSyncValidity");
1438
+ var privateCustomValidationMessage = Symbol("privateCustomValidationMessage");
1439
+ /**
1440
+ * Mixes in constraint validation APIs for an element.
1441
+ *
1442
+ * See https://developer.mozilla.org/en-US/docs/Web/HTML/Constraint_validation
1443
+ * for more details.
1444
+ *
1445
+ * Implementations must provide a validator to cache and compute its validity,
1446
+ * along with a shadow root element to anchor validation popups to.
1447
+ *
1448
+ * @example
1449
+ * ```ts
1450
+ * const baseClass = mixinConstraintValidation(
1451
+ * mixinFormAssociated(mixinElementInternals(LitElement))
1452
+ * );
1453
+ *
1454
+ * class MyCheckbox extends baseClass {
1455
+ * \@property({type: Boolean}) checked = false;
1456
+ * \@property({type: Boolean}) required = false;
1457
+ *
1458
+ * [createValidator]() {
1459
+ * return new CheckboxValidator(() => this);
1460
+ * }
1461
+ *
1462
+ * [getValidityAnchor]() {
1463
+ * return this.renderRoot.querySelector('.root');
1464
+ * }
1465
+ * }
1466
+ * ```
1467
+ *
1468
+ * @param base The class to mix functionality into.
1469
+ * @return The provided class with `ConstraintValidation` mixed in.
1470
+ */
1471
+ function mixinConstraintValidation(base) {
1472
+ var _a;
1473
+ class ConstraintValidationElement extends base {
1474
+ constructor() {
1475
+ super(...arguments);
1476
+ /**
1477
+ * Needed for Safari, see https://bugs.webkit.org/show_bug.cgi?id=261432
1478
+ * Replace with this[internals].validity.customError when resolved.
1479
+ */
1480
+ this[_a] = "";
1481
+ }
1482
+ get validity() {
1483
+ this[privateSyncValidity]();
1484
+ return this[internals].validity;
1485
+ }
1486
+ get validationMessage() {
1487
+ this[privateSyncValidity]();
1488
+ return this[internals].validationMessage;
1489
+ }
1490
+ get willValidate() {
1491
+ this[privateSyncValidity]();
1492
+ return this[internals].willValidate;
1493
+ }
1494
+ checkValidity() {
1495
+ this[privateSyncValidity]();
1496
+ return this[internals].checkValidity();
1497
+ }
1498
+ reportValidity() {
1499
+ this[privateSyncValidity]();
1500
+ return this[internals].reportValidity();
1501
+ }
1502
+ setCustomValidity(error) {
1503
+ this[privateCustomValidationMessage] = error;
1504
+ this[privateSyncValidity]();
1505
+ }
1506
+ requestUpdate(name, oldValue, options) {
1507
+ super.requestUpdate(name, oldValue, options);
1508
+ this[privateSyncValidity]();
1509
+ }
1510
+ firstUpdated(changed) {
1511
+ super.firstUpdated(changed);
1512
+ this[privateSyncValidity]();
1513
+ }
1514
+ [(_a = privateCustomValidationMessage, privateSyncValidity)]() {}
1515
+ [createValidator]() {
1516
+ throw new Error("Implement [createValidator]");
1517
+ }
1518
+ [getValidityAnchor]() {
1519
+ throw new Error("Implement [getValidityAnchor]");
1520
+ }
1521
+ }
1522
+ return ConstraintValidationElement;
1523
+ }
1524
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/behaviors/on-report-validity.js
1525
+ /**
1526
+ * @license
1527
+ * Copyright 2023 Google LLC
1528
+ * SPDX-License-Identifier: Apache-2.0
1529
+ */
1530
+ /**
1531
+ * A symbol property used for a callback when validity has been reported.
1532
+ */
1533
+ var onReportValidity = Symbol("onReportValidity");
1534
+ var privateCleanupFormListeners = Symbol("privateCleanupFormListeners");
1535
+ var privateDoNotReportInvalid = Symbol("privateDoNotReportInvalid");
1536
+ var privateIsSelfReportingValidity = Symbol("privateIsSelfReportingValidity");
1537
+ var privateCallOnReportValidity = Symbol("privateCallOnReportValidity");
1538
+ /**
1539
+ * Mixes in a callback for constraint validation when validity should be
1540
+ * styled and reported to the user.
1541
+ *
1542
+ * This is commonly used in text-field-like controls that display error styles
1543
+ * and error messages.
1544
+ *
1545
+ * @example
1546
+ * ```ts
1547
+ * const baseClass = mixinOnReportValidity(
1548
+ * mixinConstraintValidation(
1549
+ * mixinFormAssociated(mixinElementInternals(LitElement)),
1550
+ * ),
1551
+ * );
1552
+ *
1553
+ * class MyField extends baseClass {
1554
+ * \@property({type: Boolean}) error = false;
1555
+ * \@property() errorMessage = '';
1556
+ *
1557
+ * [onReportValidity](invalidEvent: Event | null) {
1558
+ * this.error = !!invalidEvent;
1559
+ * this.errorMessage = this.validationMessage;
1560
+ *
1561
+ * // Optionally prevent platform popup from displaying
1562
+ * invalidEvent?.preventDefault();
1563
+ * }
1564
+ * }
1565
+ * ```
1566
+ *
1567
+ * @param base The class to mix functionality into.
1568
+ * @return The provided class with `OnReportValidity` mixed in.
1569
+ */
1570
+ function mixinOnReportValidity(base) {
1571
+ var _a, _b, _c;
1572
+ class OnReportValidityElement extends base {
1573
+ constructor(...args) {
1574
+ super(...args);
1575
+ /**
1576
+ * Used to clean up event listeners when a new form is associated.
1577
+ */
1578
+ this[_a] = new AbortController();
1579
+ /**
1580
+ * Used to determine if an invalid event should report validity. Invalid
1581
+ * events from `checkValidity()` do not trigger reporting.
1582
+ */
1583
+ this[_b] = false;
1584
+ /**
1585
+ * Used to determine if the control is reporting validity from itself, or
1586
+ * if a `<form>` is causing the validity report. Forms have different
1587
+ * control focusing behavior.
1588
+ */
1589
+ this[_c] = false;
1590
+ }
1591
+ checkValidity() {
1592
+ this[privateDoNotReportInvalid] = true;
1593
+ const valid = super.checkValidity();
1594
+ this[privateDoNotReportInvalid] = false;
1595
+ return valid;
1596
+ }
1597
+ reportValidity() {
1598
+ this[privateIsSelfReportingValidity] = true;
1599
+ const valid = super.reportValidity();
1600
+ if (valid) this[privateCallOnReportValidity](null);
1601
+ this[privateIsSelfReportingValidity] = false;
1602
+ return valid;
1603
+ }
1604
+ [(_a = privateCleanupFormListeners, _b = privateDoNotReportInvalid, _c = privateIsSelfReportingValidity, privateCallOnReportValidity)](invalidEvent) {
1605
+ const wasCanceled = invalidEvent?.defaultPrevented;
1606
+ if (wasCanceled) return;
1607
+ this[onReportValidity](invalidEvent);
1608
+ if (!(!wasCanceled && invalidEvent?.defaultPrevented)) return;
1609
+ if (this[privateIsSelfReportingValidity] || isFirstInvalidControlInForm(this[internals].form, this)) this.focus();
1610
+ }
1611
+ [onReportValidity](invalidEvent) {
1612
+ throw new Error("Implement [onReportValidity]");
1613
+ }
1614
+ formAssociatedCallback(form) {
1615
+ if (super.formAssociatedCallback) super.formAssociatedCallback(form);
1616
+ this[privateCleanupFormListeners].abort();
1617
+ if (!form) return;
1618
+ this[privateCleanupFormListeners] = new AbortController();
1619
+ addFormReportValidListener(this, form, () => {
1620
+ this[privateCallOnReportValidity](null);
1621
+ }, this[privateCleanupFormListeners].signal);
1622
+ }
1623
+ }
1624
+ return OnReportValidityElement;
1625
+ }
1626
+ /**
1627
+ * Add a listener that fires when a form runs constraint validation on a control
1628
+ * and it is valid. This is needed to clear previously invalid styles.
1629
+ *
1630
+ * @param control The control of the form to listen for valid events.
1631
+ * @param form The control's form that can run constraint validation.
1632
+ * @param onControlValid A listener that is called when the form runs constraint
1633
+ * validation and the control is valid.
1634
+ * @param cleanup A cleanup signal to remove the listener.
1635
+ */
1636
+ function addFormReportValidListener(control, form, onControlValid, cleanup) {
1637
+ const validateHooks = getFormValidateHooks(form);
1638
+ let controlFiredInvalid = false;
1639
+ let cleanupInvalidListener;
1640
+ let isNextSubmitFromHook = false;
1641
+ validateHooks.addEventListener("before", () => {
1642
+ isNextSubmitFromHook = true;
1643
+ cleanupInvalidListener = new AbortController();
1644
+ controlFiredInvalid = false;
1645
+ control.addEventListener("invalid", () => {
1646
+ controlFiredInvalid = true;
1647
+ }, { signal: cleanupInvalidListener.signal });
1648
+ }, { signal: cleanup });
1649
+ validateHooks.addEventListener("after", () => {
1650
+ isNextSubmitFromHook = false;
1651
+ cleanupInvalidListener?.abort();
1652
+ if (controlFiredInvalid) return;
1653
+ onControlValid();
1654
+ }, { signal: cleanup });
1655
+ form.addEventListener("submit", () => {
1656
+ if (isNextSubmitFromHook) return;
1657
+ onControlValid();
1658
+ }, { signal: cleanup });
1659
+ }
1660
+ var FORM_VALIDATE_HOOKS = /* @__PURE__ */ new WeakMap();
1661
+ /**
1662
+ * Get a hooks `EventTarget` that dispatches 'before' and 'after' events that
1663
+ * fire before a form runs constraint validation and immediately after it
1664
+ * finishes running constraint validation on its controls.
1665
+ *
1666
+ * This happens during `form.reportValidity()` and `form.requestSubmit()`.
1667
+ *
1668
+ * @param form The form to get or set up hooks for.
1669
+ * @return A hooks `EventTarget` to add listeners to.
1670
+ */
1671
+ function getFormValidateHooks(form) {
1672
+ if (!FORM_VALIDATE_HOOKS.has(form)) {
1673
+ const hooks = new EventTarget();
1674
+ FORM_VALIDATE_HOOKS.set(form, hooks);
1675
+ for (const methodName of ["reportValidity", "requestSubmit"]) {
1676
+ const superMethod = form[methodName];
1677
+ form[methodName] = function() {
1678
+ hooks.dispatchEvent(new Event("before"));
1679
+ const result = Reflect.apply(superMethod, this, arguments);
1680
+ hooks.dispatchEvent(new Event("after"));
1681
+ return result;
1682
+ };
1683
+ }
1684
+ }
1685
+ return FORM_VALIDATE_HOOKS.get(form);
1686
+ }
1687
+ /**
1688
+ * Checks if a control is the first invalid control in a form.
1689
+ *
1690
+ * @param form The control's form. When `null`, the control doesn't have a form
1691
+ * and the method returns true.
1692
+ * @param control The control to check.
1693
+ * @return True if there is no form or if the control is the form's first
1694
+ * invalid control.
1695
+ */
1696
+ function isFirstInvalidControlInForm(form, control) {
1697
+ if (!form) return true;
1698
+ let firstInvalidControl;
1699
+ for (const element of form.elements) if (element.matches(":invalid")) {
1700
+ firstInvalidControl = element;
1701
+ break;
1702
+ }
1703
+ return firstInvalidControl === control;
1704
+ }
1705
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/behaviors/validators/validator.js
1706
+ /**
1707
+ * @license
1708
+ * Copyright 2023 Google LLC
1709
+ * SPDX-License-Identifier: Apache-2.0
1710
+ */
1711
+ /**
1712
+ * A class that computes and caches `ValidityStateFlags` for a component with
1713
+ * a given `State` interface.
1714
+ *
1715
+ * Cached performance before computing validity is important since constraint
1716
+ * validation must be checked frequently and synchronously when properties
1717
+ * change.
1718
+ *
1719
+ * @template State The expected interface of properties relevant to constraint
1720
+ * validation.
1721
+ */
1722
+ var Validator = class {
1723
+ /**
1724
+ * Creates a new validator.
1725
+ *
1726
+ * @param getCurrentState A callback that returns the current state of
1727
+ * constraint validation-related properties.
1728
+ */
1729
+ constructor(getCurrentState) {
1730
+ this.getCurrentState = getCurrentState;
1731
+ /**
1732
+ * The current validity state and message. This is cached and returns if
1733
+ * constraint validation state does not change.
1734
+ */
1735
+ this.currentValidity = {
1736
+ validity: {},
1737
+ validationMessage: ""
1738
+ };
1739
+ }
1740
+ /**
1741
+ * Returns the current `ValidityStateFlags` and validation message for the
1742
+ * validator.
1743
+ *
1744
+ * If the constraint validation state has not changed, this will return a
1745
+ * cached result. This is important since `getValidity()` can be called
1746
+ * frequently in response to synchronous property changes.
1747
+ *
1748
+ * @return The current validity and validation message.
1749
+ */
1750
+ getValidity() {
1751
+ const state = this.getCurrentState();
1752
+ if (!(!this.prevState || !this.equals(this.prevState, state))) return this.currentValidity;
1753
+ const { validity, validationMessage } = this.computeValidity(state);
1754
+ this.prevState = this.copy(state);
1755
+ this.currentValidity = {
1756
+ validationMessage,
1757
+ validity: {
1758
+ badInput: validity.badInput,
1759
+ customError: validity.customError,
1760
+ patternMismatch: validity.patternMismatch,
1761
+ rangeOverflow: validity.rangeOverflow,
1762
+ rangeUnderflow: validity.rangeUnderflow,
1763
+ stepMismatch: validity.stepMismatch,
1764
+ tooLong: validity.tooLong,
1765
+ tooShort: validity.tooShort,
1766
+ typeMismatch: validity.typeMismatch,
1767
+ valueMissing: validity.valueMissing
1768
+ }
1769
+ };
1770
+ return this.currentValidity;
1771
+ }
1772
+ };
1773
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/behaviors/validators/text-field-validator.js
1774
+ /**
1775
+ * @license
1776
+ * Copyright 2023 Google LLC
1777
+ * SPDX-License-Identifier: Apache-2.0
1778
+ */
1779
+ /**
1780
+ * A validator that provides constraint validation that emulates `<input>` and
1781
+ * `<textarea>` validation.
1782
+ */
1783
+ var TextFieldValidator = class extends Validator {
1784
+ computeValidity({ state, renderedControl }) {
1785
+ let inputOrTextArea = renderedControl;
1786
+ if (isInputState(state) && !inputOrTextArea) {
1787
+ inputOrTextArea = this.inputControl || document.createElement("input");
1788
+ this.inputControl = inputOrTextArea;
1789
+ } else if (!inputOrTextArea) {
1790
+ inputOrTextArea = this.textAreaControl || document.createElement("textarea");
1791
+ this.textAreaControl = inputOrTextArea;
1792
+ }
1793
+ const input = isInputState(state) ? inputOrTextArea : null;
1794
+ if (input) input.type = state.type;
1795
+ if (inputOrTextArea.value !== state.value) inputOrTextArea.value = state.value;
1796
+ inputOrTextArea.required = state.required;
1797
+ if (input) {
1798
+ const inputState = state;
1799
+ if (inputState.pattern) input.pattern = inputState.pattern;
1800
+ else input.removeAttribute("pattern");
1801
+ if (inputState.min) input.min = inputState.min;
1802
+ else input.removeAttribute("min");
1803
+ if (inputState.max) input.max = inputState.max;
1804
+ else input.removeAttribute("max");
1805
+ if (inputState.step) input.step = inputState.step;
1806
+ else input.removeAttribute("step");
1807
+ }
1808
+ if ((state.minLength ?? -1) > -1) inputOrTextArea.setAttribute("minlength", String(state.minLength));
1809
+ else inputOrTextArea.removeAttribute("minlength");
1810
+ if ((state.maxLength ?? -1) > -1) inputOrTextArea.setAttribute("maxlength", String(state.maxLength));
1811
+ else inputOrTextArea.removeAttribute("maxlength");
1812
+ return {
1813
+ validity: inputOrTextArea.validity,
1814
+ validationMessage: inputOrTextArea.validationMessage
1815
+ };
1816
+ }
1817
+ equals({ state: prev }, { state: next }) {
1818
+ const inputOrTextAreaEqual = prev.type === next.type && prev.value === next.value && prev.required === next.required && prev.minLength === next.minLength && prev.maxLength === next.maxLength;
1819
+ if (!isInputState(prev) || !isInputState(next)) return inputOrTextAreaEqual;
1820
+ return inputOrTextAreaEqual && prev.pattern === next.pattern && prev.min === next.min && prev.max === next.max && prev.step === next.step;
1821
+ }
1822
+ copy({ state }) {
1823
+ return {
1824
+ state: isInputState(state) ? this.copyInput(state) : this.copyTextArea(state),
1825
+ renderedControl: null
1826
+ };
1827
+ }
1828
+ copyInput(state) {
1829
+ const { type, pattern, min, max, step } = state;
1830
+ return {
1831
+ ...this.copySharedState(state),
1832
+ type,
1833
+ pattern,
1834
+ min,
1835
+ max,
1836
+ step
1837
+ };
1838
+ }
1839
+ copyTextArea(state) {
1840
+ return {
1841
+ ...this.copySharedState(state),
1842
+ type: state.type
1843
+ };
1844
+ }
1845
+ copySharedState({ value, required, minLength, maxLength }) {
1846
+ return {
1847
+ value,
1848
+ required,
1849
+ minLength,
1850
+ maxLength
1851
+ };
1852
+ }
1853
+ };
1854
+ function isInputState(state) {
1855
+ return state.type !== "textarea";
1856
+ }
1857
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/textfield/internal/text-field.js
1858
+ /**
1859
+ * @license
1860
+ * Copyright 2021 Google LLC
1861
+ * SPDX-License-Identifier: Apache-2.0
1862
+ */
1863
+ var textFieldBaseClass = mixinDelegatesAria(mixinOnReportValidity(mixinConstraintValidation(mixinFormAssociated(mixinElementInternals(i$2)))));
1864
+ /**
1865
+ * A text field component.
1866
+ *
1867
+ * @fires select {Event} The native `select` event on
1868
+ * [`<input>`](https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/select_event)
1869
+ * --bubbles
1870
+ * @fires change {Event} The native `change` event on
1871
+ * [`<input>`](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/change_event)
1872
+ * --bubbles
1873
+ * @fires input {InputEvent} The native `input` event on
1874
+ * [`<input>`](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/input_event)
1875
+ * --bubbles --composed
1876
+ */
1877
+ var TextField = class extends textFieldBaseClass {
1878
+ constructor() {
1879
+ super(...arguments);
1880
+ /**
1881
+ * Gets or sets whether or not the text field is in a visually invalid state.
1882
+ *
1883
+ * This error state overrides the error state controlled by
1884
+ * `reportValidity()`.
1885
+ */
1886
+ this.error = false;
1887
+ /**
1888
+ * The error message that replaces supporting text when `error` is true. If
1889
+ * `errorText` is an empty string, then the supporting text will continue to
1890
+ * show.
1891
+ *
1892
+ * This error message overrides the error message displayed by
1893
+ * `reportValidity()`.
1894
+ */
1895
+ this.errorText = "";
1896
+ /**
1897
+ * The floating Material label of the textfield component. It informs the user
1898
+ * about what information is requested for a text field. It is aligned with
1899
+ * the input text, is always visible, and it floats when focused or when text
1900
+ * is entered into the textfield. This label also sets accessibilty labels,
1901
+ * but the accessible label is overriden by `aria-label`.
1902
+ *
1903
+ * Learn more about floating labels from the Material Design guidelines:
1904
+ * https://m3.material.io/components/text-fields/guidelines
1905
+ */
1906
+ this.label = "";
1907
+ /**
1908
+ * Disables the asterisk on the floating label, when the text field is
1909
+ * required.
1910
+ */
1911
+ this.noAsterisk = false;
1912
+ /**
1913
+ * Indicates that the user must specify a value for the input before the
1914
+ * owning form can be submitted and will render an error state when
1915
+ * `reportValidity()` is invoked when value is empty. Additionally the
1916
+ * floating label will render an asterisk `"*"` when true.
1917
+ *
1918
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/required
1919
+ */
1920
+ this.required = false;
1921
+ /**
1922
+ * The current value of the text field. It is always a string.
1923
+ */
1924
+ this.value = "";
1925
+ /**
1926
+ * An optional prefix to display before the input value.
1927
+ */
1928
+ this.prefixText = "";
1929
+ /**
1930
+ * An optional suffix to display after the input value.
1931
+ */
1932
+ this.suffixText = "";
1933
+ /**
1934
+ * Whether or not the text field has a leading icon. Used for SSR.
1935
+ */
1936
+ this.hasLeadingIcon = false;
1937
+ /**
1938
+ * Whether or not the text field has a trailing icon. Used for SSR.
1939
+ */
1940
+ this.hasTrailingIcon = false;
1941
+ /**
1942
+ * Conveys additional information below the text field, such as how it should
1943
+ * be used.
1944
+ */
1945
+ this.supportingText = "";
1946
+ /**
1947
+ * Override the input text CSS `direction`. Useful for RTL languages that use
1948
+ * LTR notation for fractions.
1949
+ */
1950
+ this.textDirection = "";
1951
+ /**
1952
+ * The number of rows to display for a `type="textarea"` text field.
1953
+ * Defaults to 2.
1954
+ */
1955
+ this.rows = 2;
1956
+ /**
1957
+ * The number of cols to display for a `type="textarea"` text field.
1958
+ * Defaults to 20.
1959
+ */
1960
+ this.cols = 20;
1961
+ this.inputMode = "";
1962
+ /**
1963
+ * Defines the greatest value in the range of permitted values.
1964
+ *
1965
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#max
1966
+ */
1967
+ this.max = "";
1968
+ /**
1969
+ * The maximum number of characters a user can enter into the text field. Set
1970
+ * to -1 for none.
1971
+ *
1972
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#maxlength
1973
+ */
1974
+ this.maxLength = -1;
1975
+ /**
1976
+ * Defines the most negative value in the range of permitted values.
1977
+ *
1978
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#min
1979
+ */
1980
+ this.min = "";
1981
+ /**
1982
+ * The minimum number of characters a user can enter into the text field. Set
1983
+ * to -1 for none.
1984
+ *
1985
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#minlength
1986
+ */
1987
+ this.minLength = -1;
1988
+ /**
1989
+ * When true, hide the spinner for `type="number"` text fields.
1990
+ */
1991
+ this.noSpinner = false;
1992
+ /**
1993
+ * A regular expression that the text field's value must match to pass
1994
+ * constraint validation.
1995
+ *
1996
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#pattern
1997
+ */
1998
+ this.pattern = "";
1999
+ /**
2000
+ * Defines the text displayed in the textfield when it has no value. Provides
2001
+ * a brief hint to the user as to the expected type of data that should be
2002
+ * entered into the control. Unlike `label`, the placeholder is not visible
2003
+ * and does not float when the textfield has a value.
2004
+ *
2005
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/placeholder
2006
+ */
2007
+ this.placeholder = "";
2008
+ /**
2009
+ * Indicates whether or not a user should be able to edit the text field's
2010
+ * value.
2011
+ *
2012
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#readonly
2013
+ */
2014
+ this.readOnly = false;
2015
+ /**
2016
+ * Indicates that input accepts multiple email addresses.
2017
+ *
2018
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/email#multiple
2019
+ */
2020
+ this.multiple = false;
2021
+ /**
2022
+ * Returns or sets the element's step attribute, which works with min and max
2023
+ * to limit the increments at which a numeric or date-time value can be set.
2024
+ *
2025
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#step
2026
+ */
2027
+ this.step = "";
2028
+ /**
2029
+ * The `<input>` type to use, defaults to "text". The type greatly changes how
2030
+ * the text field behaves.
2031
+ *
2032
+ * Text fields support a limited number of `<input>` types:
2033
+ *
2034
+ * - text
2035
+ * - textarea
2036
+ * - email
2037
+ * - number
2038
+ * - password
2039
+ * - search
2040
+ * - tel
2041
+ * - url
2042
+ *
2043
+ * See
2044
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#input_types
2045
+ * for more details on each input type.
2046
+ */
2047
+ this.type = "text";
2048
+ /**
2049
+ * Describes what, if any, type of autocomplete functionality the input
2050
+ * should provide.
2051
+ *
2052
+ * https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete
2053
+ */
2054
+ this.autocomplete = "";
2055
+ /**
2056
+ * Returns true when the text field has been interacted with. Native
2057
+ * validation errors only display in response to user interactions.
2058
+ */
2059
+ this.dirty = false;
2060
+ this.focused = false;
2061
+ /**
2062
+ * Whether or not a native error has been reported via `reportValidity()`.
2063
+ */
2064
+ this.nativeError = false;
2065
+ /**
2066
+ * The validation message displayed from a native error via
2067
+ * `reportValidity()`.
2068
+ */
2069
+ this.nativeErrorText = "";
2070
+ }
2071
+ /**
2072
+ * Gets or sets the direction in which selection occurred.
2073
+ */
2074
+ get selectionDirection() {
2075
+ return this.getInputOrTextarea().selectionDirection;
2076
+ }
2077
+ set selectionDirection(value) {
2078
+ this.getInputOrTextarea().selectionDirection = value;
2079
+ }
2080
+ /**
2081
+ * Gets or sets the end position or offset of a text selection.
2082
+ */
2083
+ get selectionEnd() {
2084
+ return this.getInputOrTextarea().selectionEnd;
2085
+ }
2086
+ set selectionEnd(value) {
2087
+ this.getInputOrTextarea().selectionEnd = value;
2088
+ }
2089
+ /**
2090
+ * Gets or sets the starting position or offset of a text selection.
2091
+ */
2092
+ get selectionStart() {
2093
+ return this.getInputOrTextarea().selectionStart;
2094
+ }
2095
+ set selectionStart(value) {
2096
+ this.getInputOrTextarea().selectionStart = value;
2097
+ }
2098
+ /**
2099
+ * The text field's value as a number.
2100
+ */
2101
+ get valueAsNumber() {
2102
+ const input = this.getInput();
2103
+ if (!input) return NaN;
2104
+ return input.valueAsNumber;
2105
+ }
2106
+ set valueAsNumber(value) {
2107
+ const input = this.getInput();
2108
+ if (!input) return;
2109
+ input.valueAsNumber = value;
2110
+ this.value = input.value;
2111
+ }
2112
+ /**
2113
+ * The text field's value as a Date.
2114
+ */
2115
+ get valueAsDate() {
2116
+ const input = this.getInput();
2117
+ if (!input) return null;
2118
+ return input.valueAsDate;
2119
+ }
2120
+ set valueAsDate(value) {
2121
+ const input = this.getInput();
2122
+ if (!input) return;
2123
+ input.valueAsDate = value;
2124
+ this.value = input.value;
2125
+ }
2126
+ get hasError() {
2127
+ return this.error || this.nativeError;
2128
+ }
2129
+ /**
2130
+ * Selects all the text in the text field.
2131
+ *
2132
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/select
2133
+ */
2134
+ select() {
2135
+ this.getInputOrTextarea().select();
2136
+ }
2137
+ setRangeText(...args) {
2138
+ this.getInputOrTextarea().setRangeText(...args);
2139
+ this.value = this.getInputOrTextarea().value;
2140
+ }
2141
+ /**
2142
+ * Sets the start and end positions of a selection in the text field.
2143
+ *
2144
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/setSelectionRange
2145
+ *
2146
+ * @param start The offset into the text field for the start of the selection.
2147
+ * @param end The offset into the text field for the end of the selection.
2148
+ * @param direction The direction in which the selection is performed.
2149
+ */
2150
+ setSelectionRange(start, end, direction) {
2151
+ this.getInputOrTextarea().setSelectionRange(start, end, direction);
2152
+ }
2153
+ /**
2154
+ * Shows the browser picker for an input element of type "date", "time", etc.
2155
+ *
2156
+ * For a full list of supported types, see:
2157
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/showPicker#browser_compatibility
2158
+ *
2159
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/showPicker
2160
+ */
2161
+ showPicker() {
2162
+ const input = this.getInput();
2163
+ if (!input) return;
2164
+ input.showPicker();
2165
+ }
2166
+ /**
2167
+ * Decrements the value of a numeric type text field by `step` or `n` `step`
2168
+ * number of times.
2169
+ *
2170
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/stepDown
2171
+ *
2172
+ * @param stepDecrement The number of steps to decrement, defaults to 1.
2173
+ */
2174
+ stepDown(stepDecrement) {
2175
+ const input = this.getInput();
2176
+ if (!input) return;
2177
+ input.stepDown(stepDecrement);
2178
+ this.value = input.value;
2179
+ }
2180
+ /**
2181
+ * Increments the value of a numeric type text field by `step` or `n` `step`
2182
+ * number of times.
2183
+ *
2184
+ * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/stepUp
2185
+ *
2186
+ * @param stepIncrement The number of steps to increment, defaults to 1.
2187
+ */
2188
+ stepUp(stepIncrement) {
2189
+ const input = this.getInput();
2190
+ if (!input) return;
2191
+ input.stepUp(stepIncrement);
2192
+ this.value = input.value;
2193
+ }
2194
+ /**
2195
+ * Reset the text field to its default value.
2196
+ */
2197
+ reset() {
2198
+ this.dirty = false;
2199
+ this.value = this.getAttribute("value") ?? "";
2200
+ this.nativeError = false;
2201
+ this.nativeErrorText = "";
2202
+ }
2203
+ attributeChangedCallback(attribute, newValue, oldValue) {
2204
+ if (attribute === "value" && this.dirty) return;
2205
+ super.attributeChangedCallback(attribute, newValue, oldValue);
2206
+ }
2207
+ render() {
2208
+ const classes = {
2209
+ "disabled": this.disabled,
2210
+ "error": !this.disabled && this.hasError,
2211
+ "textarea": this.type === "textarea",
2212
+ "no-spinner": this.noSpinner
2213
+ };
2214
+ return T`
2215
+ <span class="text-field ${e$3(classes)}">
2216
+ ${this.renderField()}
2217
+ </span>
2218
+ `;
2219
+ }
2220
+ updated(changedProperties) {
2221
+ const value = this.getInputOrTextarea().value;
2222
+ if (this.value !== value) this.value = value;
2223
+ }
2224
+ renderField() {
2225
+ return u$1`<${this.fieldTag}
2226
+ class="field"
2227
+ count=${this.value.length}
2228
+ ?disabled=${this.disabled}
2229
+ ?error=${this.hasError}
2230
+ error-text=${this.getErrorText()}
2231
+ ?focused=${this.focused}
2232
+ ?has-end=${this.hasTrailingIcon}
2233
+ ?has-start=${this.hasLeadingIcon}
2234
+ label=${this.label}
2235
+ ?no-asterisk=${this.noAsterisk}
2236
+ max=${this.maxLength}
2237
+ ?populated=${!!this.value}
2238
+ ?required=${this.required}
2239
+ ?resizable=${this.type === "textarea"}
2240
+ supporting-text=${this.supportingText}
2241
+ >
2242
+ ${this.renderLeadingIcon()}
2243
+ ${this.renderInputOrTextarea()}
2244
+ ${this.renderTrailingIcon()}
2245
+ <div id="description" slot="aria-describedby"></div>
2246
+ <slot name="container" slot="container"></slot>
2247
+ </${this.fieldTag}>`;
2248
+ }
2249
+ renderLeadingIcon() {
2250
+ return T`
2251
+ <span class="icon leading" slot="start">
2252
+ <slot name="leading-icon" @slotchange=${this.handleIconChange}></slot>
2253
+ </span>
2254
+ `;
2255
+ }
2256
+ renderTrailingIcon() {
2257
+ return T`
2258
+ <span class="icon trailing" slot="end">
2259
+ <slot name="trailing-icon" @slotchange=${this.handleIconChange}></slot>
2260
+ </span>
2261
+ `;
2262
+ }
2263
+ renderInputOrTextarea() {
2264
+ const style = { "direction": this.textDirection };
2265
+ const ariaLabel = this.ariaLabel || this.label || A;
2266
+ const autocomplete = this.autocomplete;
2267
+ const hasMaxLength = (this.maxLength ?? -1) > -1;
2268
+ const hasMinLength = (this.minLength ?? -1) > -1;
2269
+ if (this.type === "textarea") return T`
2270
+ <textarea
2271
+ class="input"
2272
+ style=${o(style)}
2273
+ aria-describedby="description"
2274
+ aria-invalid=${this.hasError}
2275
+ aria-label=${ariaLabel}
2276
+ autocomplete=${autocomplete || A}
2277
+ name=${this.name || A}
2278
+ ?disabled=${this.disabled}
2279
+ maxlength=${hasMaxLength ? this.maxLength : A}
2280
+ minlength=${hasMinLength ? this.minLength : A}
2281
+ placeholder=${this.placeholder || A}
2282
+ ?readonly=${this.readOnly}
2283
+ ?required=${this.required}
2284
+ rows=${this.rows}
2285
+ cols=${this.cols}
2286
+ .value=${l(this.value)}
2287
+ @change=${this.redispatchEvent}
2288
+ @focus=${this.handleFocusChange}
2289
+ @blur=${this.handleFocusChange}
2290
+ @input=${this.handleInput}
2291
+ @select=${this.redispatchEvent}></textarea>
2292
+ `;
2293
+ const prefix = this.renderPrefix();
2294
+ const suffix = this.renderSuffix();
2295
+ const inputMode = this.inputMode;
2296
+ return T`
2297
+ <div class="input-wrapper">
2298
+ ${prefix}
2299
+ <input
2300
+ class="input"
2301
+ style=${o(style)}
2302
+ aria-describedby="description"
2303
+ aria-invalid=${this.hasError}
2304
+ aria-label=${ariaLabel}
2305
+ autocomplete=${autocomplete || A}
2306
+ name=${this.name || A}
2307
+ ?disabled=${this.disabled}
2308
+ inputmode=${inputMode || A}
2309
+ max=${this.max || A}
2310
+ maxlength=${hasMaxLength ? this.maxLength : A}
2311
+ min=${this.min || A}
2312
+ minlength=${hasMinLength ? this.minLength : A}
2313
+ pattern=${this.pattern || A}
2314
+ placeholder=${this.placeholder || A}
2315
+ ?readonly=${this.readOnly}
2316
+ ?required=${this.required}
2317
+ ?multiple=${this.multiple}
2318
+ step=${this.step || A}
2319
+ type=${this.type}
2320
+ .value=${l(this.value)}
2321
+ @change=${this.redispatchEvent}
2322
+ @focus=${this.handleFocusChange}
2323
+ @blur=${this.handleFocusChange}
2324
+ @input=${this.handleInput}
2325
+ @select=${this.redispatchEvent} />
2326
+ ${suffix}
2327
+ </div>
2328
+ `;
2329
+ }
2330
+ renderPrefix() {
2331
+ return this.renderAffix(this.prefixText, false);
2332
+ }
2333
+ renderSuffix() {
2334
+ return this.renderAffix(this.suffixText, true);
2335
+ }
2336
+ renderAffix(text, isSuffix) {
2337
+ if (!text) return A;
2338
+ return T`<span class="${e$3({
2339
+ "suffix": isSuffix,
2340
+ "prefix": !isSuffix
2341
+ })}">${text}</span>`;
2342
+ }
2343
+ getErrorText() {
2344
+ return this.error ? this.errorText : this.nativeErrorText;
2345
+ }
2346
+ handleFocusChange() {
2347
+ this.focused = this.inputOrTextarea?.matches(":focus") ?? false;
2348
+ }
2349
+ handleInput(event) {
2350
+ this.dirty = true;
2351
+ this.value = event.target.value;
2352
+ }
2353
+ redispatchEvent(event) {
2354
+ redispatchEvent(this, event);
2355
+ }
2356
+ getInputOrTextarea() {
2357
+ if (!this.inputOrTextarea) {
2358
+ this.connectedCallback();
2359
+ this.scheduleUpdate();
2360
+ }
2361
+ if (this.isUpdatePending) this.scheduleUpdate();
2362
+ return this.inputOrTextarea;
2363
+ }
2364
+ getInput() {
2365
+ if (this.type === "textarea") return null;
2366
+ return this.getInputOrTextarea();
2367
+ }
2368
+ handleIconChange() {
2369
+ this.hasLeadingIcon = this.leadingIcons.length > 0;
2370
+ this.hasTrailingIcon = this.trailingIcons.length > 0;
2371
+ }
2372
+ [getFormValue]() {
2373
+ return this.value;
2374
+ }
2375
+ formResetCallback() {
2376
+ this.reset();
2377
+ }
2378
+ formStateRestoreCallback(state) {
2379
+ this.value = state;
2380
+ }
2381
+ focus() {
2382
+ this.getInputOrTextarea().focus();
2383
+ }
2384
+ [createValidator]() {
2385
+ return new TextFieldValidator(() => ({
2386
+ state: this,
2387
+ renderedControl: this.inputOrTextarea
2388
+ }));
2389
+ }
2390
+ [getValidityAnchor]() {
2391
+ return this.inputOrTextarea;
2392
+ }
2393
+ [onReportValidity](invalidEvent) {
2394
+ invalidEvent?.preventDefault();
2395
+ const prevMessage = this.getErrorText();
2396
+ this.nativeError = !!invalidEvent;
2397
+ this.nativeErrorText = this.validationMessage;
2398
+ if (prevMessage === this.getErrorText()) this.field?.reannounceError();
2399
+ }
2400
+ };
2401
+ /** @nocollapse */
2402
+ TextField.shadowRootOptions = {
2403
+ ...i$2.shadowRootOptions,
2404
+ delegatesFocus: true
2405
+ };
2406
+ __decorate([n$2({
2407
+ type: Boolean,
2408
+ reflect: true
2409
+ })], TextField.prototype, "error", void 0);
2410
+ __decorate([n$2({ attribute: "error-text" })], TextField.prototype, "errorText", void 0);
2411
+ __decorate([n$2()], TextField.prototype, "label", void 0);
2412
+ __decorate([n$2({
2413
+ type: Boolean,
2414
+ attribute: "no-asterisk"
2415
+ })], TextField.prototype, "noAsterisk", void 0);
2416
+ __decorate([n$2({
2417
+ type: Boolean,
2418
+ reflect: true
2419
+ })], TextField.prototype, "required", void 0);
2420
+ __decorate([n$2()], TextField.prototype, "value", void 0);
2421
+ __decorate([n$2({ attribute: "prefix-text" })], TextField.prototype, "prefixText", void 0);
2422
+ __decorate([n$2({ attribute: "suffix-text" })], TextField.prototype, "suffixText", void 0);
2423
+ __decorate([n$2({
2424
+ type: Boolean,
2425
+ attribute: "has-leading-icon"
2426
+ })], TextField.prototype, "hasLeadingIcon", void 0);
2427
+ __decorate([n$2({
2428
+ type: Boolean,
2429
+ attribute: "has-trailing-icon"
2430
+ })], TextField.prototype, "hasTrailingIcon", void 0);
2431
+ __decorate([n$2({ attribute: "supporting-text" })], TextField.prototype, "supportingText", void 0);
2432
+ __decorate([n$2({ attribute: "text-direction" })], TextField.prototype, "textDirection", void 0);
2433
+ __decorate([n$2({ type: Number })], TextField.prototype, "rows", void 0);
2434
+ __decorate([n$2({ type: Number })], TextField.prototype, "cols", void 0);
2435
+ __decorate([n$2({ reflect: true })], TextField.prototype, "inputMode", void 0);
2436
+ __decorate([n$2()], TextField.prototype, "max", void 0);
2437
+ __decorate([n$2({ type: Number })], TextField.prototype, "maxLength", void 0);
2438
+ __decorate([n$2()], TextField.prototype, "min", void 0);
2439
+ __decorate([n$2({ type: Number })], TextField.prototype, "minLength", void 0);
2440
+ __decorate([n$2({
2441
+ type: Boolean,
2442
+ attribute: "no-spinner"
2443
+ })], TextField.prototype, "noSpinner", void 0);
2444
+ __decorate([n$2()], TextField.prototype, "pattern", void 0);
2445
+ __decorate([n$2({
2446
+ reflect: true,
2447
+ converter: stringConverter
2448
+ })], TextField.prototype, "placeholder", void 0);
2449
+ __decorate([n$2({
2450
+ type: Boolean,
2451
+ reflect: true
2452
+ })], TextField.prototype, "readOnly", void 0);
2453
+ __decorate([n$2({
2454
+ type: Boolean,
2455
+ reflect: true
2456
+ })], TextField.prototype, "multiple", void 0);
2457
+ __decorate([n$2()], TextField.prototype, "step", void 0);
2458
+ __decorate([n$2({ reflect: true })], TextField.prototype, "type", void 0);
2459
+ __decorate([n$2({ reflect: true })], TextField.prototype, "autocomplete", void 0);
2460
+ __decorate([r$1()], TextField.prototype, "dirty", void 0);
2461
+ __decorate([r$1()], TextField.prototype, "focused", void 0);
2462
+ __decorate([r$1()], TextField.prototype, "nativeError", void 0);
2463
+ __decorate([r$1()], TextField.prototype, "nativeErrorText", void 0);
2464
+ __decorate([e$2(".input")], TextField.prototype, "inputOrTextarea", void 0);
2465
+ __decorate([e$2(".field")], TextField.prototype, "field", void 0);
2466
+ __decorate([o$1({ slot: "leading-icon" })], TextField.prototype, "leadingIcons", void 0);
2467
+ __decorate([o$1({ slot: "trailing-icon" })], TextField.prototype, "trailingIcons", void 0);
2468
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/textfield/internal/outlined-text-field.js
2469
+ /**
2470
+ * @license
2471
+ * Copyright 2021 Google LLC
2472
+ * SPDX-License-Identifier: Apache-2.0
2473
+ */
2474
+ /**
2475
+ * An outlined text field component
2476
+ */
2477
+ var OutlinedTextField = class extends TextField {
2478
+ constructor() {
2479
+ super(...arguments);
2480
+ this.fieldTag = i$5`md-outlined-field`;
2481
+ }
2482
+ };
2483
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/textfield/internal/shared-styles.cssresult.js
2484
+ /**
2485
+ * @license
2486
+ * Copyright 2026 Google LLC
2487
+ * SPDX-License-Identifier: Apache-2.0
2488
+ */
2489
+ var styles = i$3`:host{display:inline-flex;outline:none;resize:both;text-align:start;-webkit-tap-highlight-color:rgba(0,0,0,0)}.text-field,.field{width:100%}.text-field{display:inline-flex}.field{cursor:text}.disabled .field{cursor:default}.text-field,.textarea .field{resize:inherit}slot[name=container]{border-radius:inherit}.icon{color:currentColor;display:flex;align-items:center;justify-content:center;fill:currentColor;position:relative}.icon ::slotted(*){display:flex;position:absolute}[has-start] .icon.leading{font-size:var(--_leading-icon-size);height:var(--_leading-icon-size);width:var(--_leading-icon-size)}[has-end] .icon.trailing{font-size:var(--_trailing-icon-size);height:var(--_trailing-icon-size);width:var(--_trailing-icon-size)}.input-wrapper{display:flex}.input-wrapper>*{all:inherit;padding:0}.input{caret-color:var(--_caret-color);overflow-x:hidden;text-align:inherit}.input::placeholder{color:currentColor;opacity:1}.input::-webkit-calendar-picker-indicator{display:none}.input::-webkit-search-decoration,.input::-webkit-search-cancel-button{display:none}@media(forced-colors: active){.input{background:none}}.no-spinner .input::-webkit-inner-spin-button,.no-spinner .input::-webkit-outer-spin-button{display:none}.no-spinner .input[type=number]{-moz-appearance:textfield}:focus-within .input{caret-color:var(--_focus-caret-color)}.error:focus-within .input{caret-color:var(--_error-focus-caret-color)}.text-field:not(.disabled) .prefix{color:var(--_input-text-prefix-color)}.text-field:not(.disabled) .suffix{color:var(--_input-text-suffix-color)}.text-field:not(.disabled) .input::placeholder{color:var(--_input-text-placeholder-color)}.prefix,.suffix{text-wrap:nowrap;width:min-content}.prefix{padding-inline-end:var(--_input-text-prefix-trailing-space)}.suffix{padding-inline-start:var(--_input-text-suffix-leading-space)}
2490
+ `;
2491
+ styles.styleSheet;
2492
+ // ../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/textfield/outlined-text-field.js
2493
+ /**
2494
+ * @license
2495
+ * Copyright 2021 Google LLC
2496
+ * SPDX-License-Identifier: Apache-2.0
2497
+ */
2498
+ /**
2499
+ * TODO(b/228525797): Add docs
2500
+ * @final
2501
+ * @suppress {visibility}
2502
+ */
2503
+ var MdOutlinedTextField = class MdOutlinedTextField extends OutlinedTextField {
2504
+ constructor() {
2505
+ super(...arguments);
2506
+ this.fieldTag = i$5`md-outlined-field`;
2507
+ }
2508
+ };
2509
+ MdOutlinedTextField.styles = [styles, styles$1];
2510
+ MdOutlinedTextField = __decorate([t$1("md-outlined-text-field")], MdOutlinedTextField);
2511
+ // src/lib/components/SpeechLog/MarkerDialog.svelte
2512
+ function MarkerDialog($$renderer, $$props) {
15
2513
  $$renderer.component(($$renderer) => {
16
- /** The session's entry count; the bridge forgets a session that ends with none. */
17
- /** Rejects with a message to show; resolves when the session has ended. */
18
- let { open, sessionId, entries, onEnd, onClose } = $$props;
19
- const empty = derived(() => entries === 0);
2514
+ /** Rejects with a message to show; resolves when the marker is in. */
2515
+ let { open, onAdd, onClose } = $$props;
2516
+ let label = "";
2517
+ let labelError = "";
20
2518
  let busy = false;
21
- $$renderer.push(`<md-dialog${attr("open", open, true)} class="svelte-17z3k9b"><div slot="headline">${escape_html(empty() ? "Drop" : "End")} session ${escape_html(sessionId === null ? "" : `#${sessionId}`)}?</div> <div slot="content">`);
22
- if (empty()) $$renderer.push(`<!--[0--><p class="svelte-17z3k9b">This session has no entries, so ending it deletes it. Its number is not reused.</p>`);
23
- else $$renderer.push(`<!--[-1--><p class="svelte-17z3k9b">Speech captured after this belongs to no session.</p>`);
24
- $$renderer.push(`<!--]--> `);
2519
+ $$renderer.push(`<md-dialog${attr("open", open, true)} class="svelte-ttl1x5"><div slot="headline">Add a marker</div> <form slot="content" id="add-marker-form" novalidate="" class="svelte-ttl1x5"><md-outlined-text-field label="Label" required=""${attr("maxlength", API_LIMITS.markerLength)} supporting-text="Shows in the log as a row of its own, for example “step 3”."${attr("value", label)}${attr("error", false)}${attr("error-text", labelError)}></md-outlined-text-field> `);
25
2520
  $$renderer.push("<!--[-1-->");
26
- $$renderer.push(`<!--]--></div> <div slot="actions"><md-text-button type="button">Cancel</md-text-button> <md-text-button type="button"${attr("disabled", busy, true)}>End session</md-text-button></div></md-dialog>`);
2521
+ $$renderer.push(`<!--]--></form> <div slot="actions"><md-text-button type="button">Cancel</md-text-button> <md-text-button type="submit" form="add-marker-form"${attr("disabled", busy, true)}>Add</md-text-button></div></md-dialog>`);
2522
+ });
2523
+ }
2524
+ // src/lib/components/SpeechLog/SpeechTable.svelte
2525
+ function SpeechTable($$renderer, $$props) {
2526
+ $$renderer.component(($$renderer) => {
2527
+ /** Oldest first. */
2528
+ let { entries } = $$props;
2529
+ /** A row that arrived this recently gets the tint that fades out (see `--app-new-row-ms`). */
2530
+ const FRESH_MS = 2e3;
2531
+ const fresh = (entry) => Date.now() - Date.parse(entry.receivedAt) < FRESH_MS;
2532
+ $$renderer.push(`<table aria-label="Speech" class="svelte-5c13xh"><thead class="svelte-5c13xh"><tr><th scope="col" class="svelte-5c13xh">Received</th><th scope="col" class="svelte-5c13xh">Spoken text</th><th scope="col" class="seq svelte-5c13xh">Seq</th></tr></thead><tbody class="svelte-5c13xh"><!--[-->`);
2533
+ const each_array = ensure_array_like(entries);
2534
+ for (let $$index = 0, $$length = each_array.length; $$index < $$length; $$index++) {
2535
+ let entry = each_array[$$index];
2536
+ $$renderer.push(`<tr${attr_class("svelte-5c13xh", void 0, {
2537
+ "fresh": fresh(entry),
2538
+ "marker": entry.kind === "marker"
2539
+ })}><td class="time mono svelte-5c13xh">${escape_html(formatReceivedTime(entry.receivedAt))}</td><td class="text svelte-5c13xh">`);
2540
+ if (entry.kind === "marker") $$renderer.push(`<!--[0--><span class="pill svelte-5c13xh"${attr("title", entry.text)}><md-icon aria-hidden="true" class="svelte-5c13xh">bookmark</md-icon> <span class="visually-hidden svelte-5c13xh">Marker:</span> <span class="label mono svelte-5c13xh">${escape_html(entry.text)}</span></span>`);
2541
+ else $$renderer.push(`<!--[-1-->${escape_html(entry.text)}`);
2542
+ $$renderer.push(`<!--]--></td><td class="seq mono svelte-5c13xh">#${escape_html(entry.seq)}</td></tr>`);
2543
+ }
2544
+ $$renderer.push(`<!--]--></tbody></table>`);
2545
+ });
2546
+ }
2547
+ // src/lib/components/SpeechLog/SpeechLog.svelte
2548
+ function SpeechLog($$renderer, $$props) {
2549
+ $$renderer.component(($$renderer) => {
2550
+ /** `#3 Checkout flow`, or `Outside sessions`. */
2551
+ /** Oldest first. */
2552
+ /** Whether a marker added now shows up in this log (see `canAddMarker`). */
2553
+ /** Rejects with a message to show; resolves when the marker is in. */
2554
+ let { heading, entries, connection, canMark, onAddMarker } = $$props;
2555
+ let markerOpen = false;
2556
+ $$renderer.push(`<section class="log svelte-1jnrixz" aria-labelledby="log-heading"><header class="svelte-1jnrixz"><h1 id="log-heading" class="trunc svelte-1jnrixz">${escape_html(heading)}</h1> `);
2557
+ if (canMark) $$renderer.push(`<!--[0--><div role="toolbar" aria-label="Log actions"><md-icon-button title="Add marker" aria-label="Add marker"><md-icon aria-hidden="true">bookmark_add</md-icon></md-icon-button></div>`);
2558
+ else $$renderer.push("<!--[-1-->");
2559
+ $$renderer.push(`<!--]--></header> <div class="scroll svelte-1jnrixz" role="region" aria-label="Speech log" aria-live="off" tabindex="0">`);
2560
+ SpeechTable($$renderer, { entries });
2561
+ $$renderer.push(`<!----> `);
2562
+ if (entries.length === 0) {
2563
+ $$renderer.push(`<!--[0--><div class="empty svelte-1jnrixz"><md-icon aria-hidden="true" class="svelte-1jnrixz">mic</md-icon> `);
2564
+ if (connection === "ended") $$renderer.push(`<!--[0--><p class="title svelte-1jnrixz">No entries left</p> <p class="svelte-1jnrixz">This session's entries are no longer in the buffer.</p>`);
2565
+ else $$renderer.push(`<!--[-1--><p class="title svelte-1jnrixz">No speech yet</p> <p class="svelte-1jnrixz">Make the screen reader speak.</p>`);
2566
+ $$renderer.push(`<!--]--></div>`);
2567
+ } else $$renderer.push("<!--[-1-->");
2568
+ $$renderer.push(`<!--]--></div> `);
2569
+ if (connection === "reconnecting" || connection === "failed" || false) {
2570
+ $$renderer.push(`<!--[0--><footer class="svelte-1jnrixz">`);
2571
+ if (connection === "reconnecting") $$renderer.push(`<!--[0--><p role="status" class="mono svelte-1jnrixz">Connection lost, reconnecting…</p>`);
2572
+ else if (connection === "failed") $$renderer.push(`<!--[1--><p role="alert" class="mono failed svelte-1jnrixz">The speech could not be loaded.</p>`);
2573
+ else $$renderer.push(`<!--[-1--><span></span>`);
2574
+ $$renderer.push(`<!--]--> `);
2575
+ $$renderer.push("<!--[-1-->");
2576
+ $$renderer.push(`<!--]--></footer>`);
2577
+ } else $$renderer.push("<!--[-1-->");
2578
+ $$renderer.push(`<!--]--></section> `);
2579
+ if (canMark) {
2580
+ $$renderer.push("<!--[0-->");
2581
+ MarkerDialog($$renderer, {
2582
+ open: markerOpen,
2583
+ onAdd: onAddMarker,
2584
+ onClose: () => markerOpen = false
2585
+ });
2586
+ } else $$renderer.push("<!--[-1-->");
2587
+ $$renderer.push(`<!--]-->`);
27
2588
  });
28
2589
  }
29
2590
  // src/lib/components/ListItem/ListItem.svelte
@@ -89,14 +2650,33 @@ function describeSession(session, now) {
89
2650
  spoken: parts.filter((part) => part !== null).join(", ")
90
2651
  };
91
2652
  }
2653
+ /** The URL value that selects the speech outside any session (the bridge's `session=none`). */
2654
+ var OUTSIDE_SESSIONS = "none";
92
2655
  /**
93
- * The session a pane shows: the one named in the URL if it still exists, otherwise the current
94
- * one (following), otherwise none.
2656
+ * The scope a pane shows: `none` if the URL asks for it, the session named in the URL if it still
2657
+ * exists, otherwise the current one (following), otherwise the speech outside any session.
95
2658
  */
96
- function selectedSessionId(requested, sessions, currentId) {
2659
+ function selectedScope(requested, sessions, currentId) {
2660
+ if (requested === "none") return OUTSIDE_SESSIONS;
97
2661
  const id = requested === null || !/^\d+$/.test(requested) ? null : Number(requested);
98
2662
  if (id !== null && sessions.some((session) => session.id === id)) return id;
99
- return currentId;
2663
+ return currentId ?? "none";
2664
+ }
2665
+ // src/lib/components/SessionsPane/EndSessionDialog.svelte
2666
+ function EndSessionDialog($$renderer, $$props) {
2667
+ $$renderer.component(($$renderer) => {
2668
+ /** The session's entry count; the bridge forgets a session that ends with none. */
2669
+ /** Rejects with a message to show; resolves when the session has ended. */
2670
+ let { open, sessionId, entries, onEnd, onClose } = $$props;
2671
+ const empty = derived(() => entries === 0);
2672
+ let busy = false;
2673
+ $$renderer.push(`<md-dialog${attr("open", open, true)} class="svelte-17z3k9b"><div slot="headline">${escape_html(empty() ? "Drop" : "End")} session ${escape_html(sessionId === null ? "" : `#${sessionId}`)}?</div> <div slot="content">`);
2674
+ if (empty()) $$renderer.push(`<!--[0--><p class="svelte-17z3k9b">This session has no entries, so ending it deletes it. Its number is not reused.</p>`);
2675
+ else $$renderer.push(`<!--[-1--><p class="svelte-17z3k9b">Speech captured after this belongs to no session.</p>`);
2676
+ $$renderer.push(`<!--]--> `);
2677
+ $$renderer.push("<!--[-1-->");
2678
+ $$renderer.push(`<!--]--></div> <div slot="actions"><md-text-button type="button">Cancel</md-text-button> <md-text-button type="button"${attr("disabled", busy, true)}>End session</md-text-button></div></md-dialog>`);
2679
+ });
100
2680
  }
101
2681
  // src/lib/components/SessionsPane/SessionRow.svelte
102
2682
  function SessionRow($$renderer, $$props) {
@@ -141,13 +2721,25 @@ function StartSessionDialog($$renderer, $$props) {
141
2721
  function SessionsPane($$renderer, $$props) {
142
2722
  $$renderer.component(($$renderer) => {
143
2723
  /** Newest first. */
2724
+ /** Entries in the buffer recorded outside any session. */
2725
+ /** The session the log shows, or `'none'` for the speech outside any session. */
144
2726
  /** Epoch ms, for the duration of the live session. */
145
- let { sessions, currentId, selectedId, now, onSelect, onStart, onEnd } = $$props;
2727
+ /** Only the header buttons show; the list and the heading are hidden. */
2728
+ let { sessions, currentId, outsideEntries, selectedId, now, collapsed = false, onToggleCollapse, onSelect, onStart, onEnd } = $$props;
146
2729
  let startOpen = false;
147
2730
  let endOpen = false;
148
2731
  const toggleLabel = derived(() => currentId === null ? "Start a session" : `End session ${currentId}`);
149
- $$renderer.push(`<section aria-labelledby="sessions-heading" class="svelte-1fz71rn"><header class="svelte-1fz71rn"><h2 id="sessions-heading" class="svelte-1fz71rn">Sessions</h2> <md-icon-button${attr_class(clsx(currentId === null ? "start" : "stop"), "svelte-1fz71rn")}${attr("title", toggleLabel())}${attr("aria-label", toggleLabel())}><md-icon aria-hidden="true">${escape_html(currentId === null ? "play_arrow" : "stop")}</md-icon></md-icon-button></header> `);
150
- if (sessions.length === 0) $$renderer.push(`<!--[0--><p class="empty svelte-1fz71rn">No sessions in the buffer. Start one with the play button.</p>`);
2732
+ const collapseLabel = derived(() => collapsed ? "Expand sessions" : "Collapse sessions");
2733
+ const entries = derived(() => outsideEntries === 1 ? "1 entry" : `${outsideEntries} entries`);
2734
+ function subtitle($$renderer) {
2735
+ $$renderer.push(`<span>${escape_html(entries())}</span>`);
2736
+ }
2737
+ $$renderer.push(`<section aria-labelledby="sessions-heading"${attr_class("svelte-1fz71rn", void 0, { "collapsed": collapsed })}><header class="svelte-1fz71rn">`);
2738
+ if (onToggleCollapse) $$renderer.push(`<!--[0--><md-icon-button class="collapse"${attr("title", collapseLabel())}${attr("aria-label", collapseLabel())}${attr("aria-expanded", !collapsed)}><md-icon aria-hidden="true">${escape_html(collapsed ? "left_panel_open" : "left_panel_close")}</md-icon></md-icon-button>`);
2739
+ else $$renderer.push("<!--[-1-->");
2740
+ $$renderer.push(`<!--]--> <h2 id="sessions-heading"${attr_class("svelte-1fz71rn", void 0, { "visually-hidden": collapsed })}>Sessions</h2> <md-icon-button${attr_class(clsx(currentId === null ? "start" : "stop"), "svelte-1fz71rn")}${attr("title", toggleLabel())}${attr("aria-label", toggleLabel())}><md-icon aria-hidden="true">${escape_html(currentId === null ? "play_arrow" : "stop")}</md-icon></md-icon-button></header> `);
2741
+ if (collapsed) $$renderer.push("<!--[0-->");
2742
+ else if (sessions.length === 0) $$renderer.push(`<!--[1--><p class="empty svelte-1fz71rn">No sessions in the buffer. Start one with the play button.</p>`);
151
2743
  else {
152
2744
  $$renderer.push(`<!--[-1--><ul aria-labelledby="sessions-heading" class="svelte-1fz71rn"><!--[-->`);
153
2745
  const each_array = ensure_array_like(sessions);
@@ -163,6 +2755,19 @@ function SessionsPane($$renderer, $$props) {
163
2755
  }
164
2756
  $$renderer.push(`<!--]--></ul>`);
165
2757
  }
2758
+ $$renderer.push(`<!--]--> `);
2759
+ if (!collapsed) {
2760
+ $$renderer.push(`<!--[0--><ul class="outside svelte-1fz71rn" aria-label="Outside sessions">`);
2761
+ ListItem($$renderer, {
2762
+ title: "Outside sessions",
2763
+ shape: "var(--md-sys-shape-corner-extra-large, 28px)",
2764
+ subtitle,
2765
+ selected: selectedId === OUTSIDE_SESSIONS,
2766
+ description: `Speech captured while no session was running, ${entries()}`,
2767
+ onSelect: () => onSelect(OUTSIDE_SESSIONS)
2768
+ });
2769
+ $$renderer.push(`<!----></ul>`);
2770
+ } else $$renderer.push("<!--[-1-->");
166
2771
  $$renderer.push(`<!--]--></section> `);
167
2772
  StartSessionDialog($$renderer, {
168
2773
  open: startOpen,
@@ -186,35 +2791,50 @@ function _page($$renderer, $$props) {
186
2791
  let { data } = $$props;
187
2792
  const list = derived(() => sessionsStore.loaded ? {
188
2793
  sessions: sessionsStore.sessions,
189
- currentId: sessionsStore.currentId
2794
+ currentId: sessionsStore.currentId,
2795
+ outsideEntries: sessionsStore.outsideEntries
190
2796
  } : data.sessions ?? {
191
2797
  sessions: [],
192
- currentId: null
2798
+ currentId: null,
2799
+ outsideEntries: 0
193
2800
  });
194
2801
  const now = derived(() => sessionsStore.loaded ? sessionsStore.now : data.now);
195
- const selectedId = derived(() => selectedSessionId(page.url.searchParams.get("session"), list().sessions, list().currentId));
2802
+ const selectedId = derived(() => selectedScope(page.url.searchParams.get("session"), list().sessions, list().currentId));
2803
+ const heading = derived(() => logHeading(selectedId(), list().sessions));
2804
+ const canMark = derived(() => canAddMarker(selectedId(), list().currentId));
196
2805
  function select(id) {
197
- const live = id === null || id === list().currentId;
198
- return goto(live ? resolve("/") : `${resolve("/")}?session=${id}`, { reset: false });
2806
+ return goto(id === null ? resolve("/") : `${resolve("/")}?session=${id}`, { reset: false });
2807
+ }
2808
+ async function end() {
2809
+ const ended = list().currentId;
2810
+ await sessionsStore.end();
2811
+ if (ended !== null && !list().sessions.some((session) => session.id === ended)) await select(null);
199
2812
  }
200
2813
  async function start(name, run) {
201
- await sessionsStore.start(name, run);
202
- await select(null);
2814
+ await select((await sessionsStore.start(name, run)).id);
203
2815
  }
204
- $$renderer.push(`<div class="monitor svelte-1uha8ag"><aside class="svelte-1uha8ag">`);
2816
+ $$renderer.push(`<div class="monitor svelte-1uha8ag"><aside${attr_class("svelte-1uha8ag", void 0, { "collapsed": sessionsPaneStore.collapsed })}>`);
205
2817
  SessionsPane($$renderer, {
2818
+ collapsed: sessionsPaneStore.collapsed,
2819
+ onToggleCollapse: () => sessionsPaneStore.toggle(),
206
2820
  sessions: list().sessions,
207
2821
  currentId: list().currentId,
2822
+ outsideEntries: list().outsideEntries,
208
2823
  selectedId: selectedId(),
209
2824
  now: now(),
210
2825
  onSelect: (id) => void select(id),
211
2826
  onStart: start,
212
- onEnd: () => sessionsStore.end()
2827
+ onEnd: end
2828
+ });
2829
+ $$renderer.push(`<!----></aside> <div class="log svelte-1uha8ag">`);
2830
+ SpeechLog($$renderer, {
2831
+ heading: heading(),
2832
+ entries: speechStore.entries,
2833
+ connection: speechStore.connection,
2834
+ canMark: canMark(),
2835
+ onAddMarker: (label) => speechStore.addMarker(label)
213
2836
  });
214
- $$renderer.push(`<!----></aside> <div class="log svelte-1uha8ag"><h1>Monitor</h1> `);
215
- if (data.status) $$renderer.push(`<!--[0--><p>Bridge ${escape_html(data.status.bridge.version)} is ${escape_html(data.status.bridge.state)}.</p>`);
216
- else $$renderer.push(`<!--[-1--><p>The bridge is not reachable.</p>`);
217
- $$renderer.push(`<!--]--></div></div>`);
2837
+ $$renderer.push(`<!----></div></div>`);
218
2838
  });
219
2839
  }
220
2840
  export { _page as default };