@lofid/web 0.0.0-stage → 1.0.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 (55) hide show
  1. package/README.md +85 -2
  2. package/custom-elements.json +11166 -0
  3. package/dist/index.d.ts +2784 -0
  4. package/dist/index.js +18710 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/styles/ag-grid.css +145 -0
  7. package/dist/styles/motion.css +32 -0
  8. package/dist/styles/motion.tokens.json +38 -0
  9. package/dist/styles/vars.css +870 -0
  10. package/package.json +44 -4
  11. package/readmes/lof-accordion/README.md +140 -0
  12. package/readmes/lof-alert/README.md +142 -0
  13. package/readmes/lof-autocomplete/README.md +209 -0
  14. package/readmes/lof-avatar/README.md +228 -0
  15. package/readmes/lof-badge/README.md +102 -0
  16. package/readmes/lof-breadcrumb/README.md +97 -0
  17. package/readmes/lof-button/README.md +190 -0
  18. package/readmes/lof-calendar/README.md +111 -0
  19. package/readmes/lof-card/README.md +75 -0
  20. package/readmes/lof-cardmedia/README.md +100 -0
  21. package/readmes/lof-carousel/README.md +187 -0
  22. package/readmes/lof-checkbox/README.md +159 -0
  23. package/readmes/lof-chip/README.md +141 -0
  24. package/readmes/lof-container/README.md +107 -0
  25. package/readmes/lof-date-picker/README.md +221 -0
  26. package/readmes/lof-divider/README.md +88 -0
  27. package/readmes/lof-drawer/README.md +188 -0
  28. package/readmes/lof-kbd/README.md +188 -0
  29. package/readmes/lof-layout/README.md +122 -0
  30. package/readmes/lof-menu/README.md +187 -0
  31. package/readmes/lof-menubar/README.md +218 -0
  32. package/readmes/lof-otp/README.md +167 -0
  33. package/readmes/lof-pagination/README.md +141 -0
  34. package/readmes/lof-popover/README.md +220 -0
  35. package/readmes/lof-progress/README.md +88 -0
  36. package/readmes/lof-radio/README.md +142 -0
  37. package/readmes/lof-range-picker/README.md +194 -0
  38. package/readmes/lof-resizable/README.md +220 -0
  39. package/readmes/lof-segmented-button/README.md +158 -0
  40. package/readmes/lof-select/README.md +193 -0
  41. package/readmes/lof-sheet/README.md +170 -0
  42. package/readmes/lof-signature-pad/README.md +161 -0
  43. package/readmes/lof-skeleton/README.md +104 -0
  44. package/readmes/lof-slider/README.md +140 -0
  45. package/readmes/lof-snackbar/README.md +170 -0
  46. package/readmes/lof-split-button/README.md +129 -0
  47. package/readmes/lof-stepper/README.md +171 -0
  48. package/readmes/lof-switch/README.md +122 -0
  49. package/readmes/lof-tab/README.md +184 -0
  50. package/readmes/lof-textfield/README.md +206 -0
  51. package/readmes/lof-time-picker/README.md +188 -0
  52. package/readmes/lof-toast/README.md +174 -0
  53. package/readmes/lof-tooltip/README.md +120 -0
  54. package/readmes/lof-tree/README.md +157 -0
  55. package/readmes/lof-upload/README.md +223 -0
@@ -0,0 +1,2784 @@
1
+ import * as lit_html from 'lit-html';
2
+ import * as lit from 'lit';
3
+ import { LitElement, PropertyDeclaration, PropertyValues, TemplateResult } from 'lit';
4
+
5
+ /**
6
+ * Extra options `@property()` accepts on a LofElement (Lit passes unknown keys through
7
+ * to `createProperty`):
8
+ *
9
+ * - `legacy`: an older attribute spelling (e.g. "totalpages" for `attribute: "total-pages"`).
10
+ * It keeps working and logs one deprecation notice per (component, attribute).
11
+ * - `kebab`: the canonical kebab spelling of a reflected prop whose declared `attribute`
12
+ * is still the old one (e.g. `attribute: "fullwidth", kebab: "full-width"`). Reflection
13
+ * keeps writing the old name in 1.x so `[fullwidth]` selectors match; the kebab name is
14
+ * accepted silently and the old name logs the notice when the page writes it.
15
+ */
16
+ interface LofPropertyOptions {
17
+ legacy?: string;
18
+ kebab?: string;
19
+ }
20
+ declare module "@lit/reactive-element" {
21
+ interface PropertyDeclaration<Type = unknown, TypeHint = unknown> extends LofPropertyOptions {
22
+ }
23
+ }
24
+ /**
25
+ * Base class of every Lofid element (1.5.0).
26
+ *
27
+ * - `="false"` turns a Boolean attribute off; presence and `""` stay true.
28
+ * - A string assigned to an Array / Object / Number / Boolean property is converted
29
+ * the way the attribute would be (React 19 sets custom-element props as properties).
30
+ * Unparseable JSON warns once and falls back to `[]` / `{}`.
31
+ * - Old attribute spellings (`legacy` / `kebab` options above) keep working with a
32
+ * one-time notice.
33
+ */
34
+ declare class LofElement extends LitElement {
35
+ private static __lofAliasesFor;
36
+ static createProperty(name: PropertyKey, options?: PropertyDeclaration): void;
37
+ protected static getPropertyDescriptor(name: PropertyKey, key: string | symbol, options: PropertyDeclaration): PropertyDescriptor | undefined;
38
+ static get observedAttributes(): string[];
39
+ /** The kebab aliases this class observes: `{ from, to, deprecated }`. */
40
+ static kebabAliasList(): {
41
+ from: string;
42
+ to: string;
43
+ prop: string;
44
+ deprecated: boolean;
45
+ }[];
46
+ private __lofReflecting;
47
+ protected update(changed: Map<PropertyKey, unknown>): void;
48
+ attributeChangedCallback(name: string, old: string | null, value: string | null): void;
49
+ private __lofDeprecated;
50
+ }
51
+
52
+ type AccordionSize = "md" | "sm" | "large" | "medium" | "small";
53
+ type AccordionType = "default" | "action";
54
+ type AccordionContentType = "text" | "custom";
55
+ type AccordionAppearance = "shadow" | "plain";
56
+ /**
57
+ * One collapsible section: a header (title + chevron) that expands or
58
+ * collapses the slotted body. Independent of its siblings.
59
+ */
60
+ declare class LofAccordion extends LofElement {
61
+ static styles: lit.CSSResult[];
62
+ /** Header text. Also the native tooltip attribute. */
63
+ title: string;
64
+ open: boolean;
65
+ /** large (56px) | medium (48px) | small (44px); legacy md = large, sm = medium. */
66
+ size: AccordionSize;
67
+ type: AccordionType;
68
+ appearance: AccordionAppearance;
69
+ disabled: boolean;
70
+ /** Body treatment (Figma Content Type): text (default) styles it as copy; custom leaves it to you. */
71
+ contentType: AccordionContentType;
72
+ protected willUpdate(changed: Map<string, unknown>): void;
73
+ private readonly ids;
74
+ private toggle;
75
+ private onKeydown;
76
+ render(): lit_html.TemplateResult<1>;
77
+ }
78
+ declare global {
79
+ interface HTMLElementTagNameMap {
80
+ "lof-accordion": LofAccordion;
81
+ }
82
+ }
83
+
84
+ type AlertTone = "neutral" | "info" | "success" | "warning" | "destructive";
85
+ type AlertToneInput = AlertTone | "error" | "danger" | "critical";
86
+ type AlertType = "info" | "success" | "warning" | "error";
87
+ type AlertAppearance = "subtle" | "solid" | "outline" | "filled";
88
+ /**
89
+ * Inline status banner: tone-coloured box with a status icon, a title
90
+ * (message1), optional supporting text (message2), an optional inline link
91
+ * and an optional dismiss button.
92
+ */
93
+ declare class LofAlert extends LofElement {
94
+ static styles: lit.CSSResult[];
95
+ /** Tone: neutral | info | success | warning | destructive. */
96
+ tone?: AlertToneInput;
97
+ /** Deprecated alias of `tone` (tone wins when both are set). */
98
+ type?: AlertType;
99
+ /** subtle (default) | solid | outline. `filled` is a silent alias of solid. */
100
+ appearance: AlertAppearance;
101
+ message1: string;
102
+ message2: string;
103
+ urlText: string;
104
+ urlHref: string;
105
+ /** Shows the dismiss button. Defaults to true — clear it from script. */
106
+ dismissible: boolean;
107
+ /** Set when dismissed; hides the host. Set back to false to show it again. */
108
+ dismissed: boolean;
109
+ /** The tone actually rendered after alias resolution. */
110
+ get resolvedTone(): AlertTone;
111
+ protected willUpdate(changed: Map<string, unknown>): void;
112
+ private onDismiss;
113
+ render(): lit_html.TemplateResult<1>;
114
+ }
115
+ declare global {
116
+ interface HTMLElementTagNameMap {
117
+ "lof-alert": LofAlert;
118
+ }
119
+ }
120
+
121
+ type TextFieldState = "default" | "error" | "disabled";
122
+ type TextFieldSize = "small" | "medium" | "large";
123
+ type TextFieldLabelStyle = "default" | "floating" | "none";
124
+ type TextFieldVariant = "default" | "underline" | "legend";
125
+ type TextFieldPrefixStyle = "clear" | "divider" | "fill";
126
+ /**
127
+ * Single- and multi-line text input with three chromes (outlined, underline,
128
+ * notched legend), three heights, prefix/suffix blocks and helper/error text.
129
+ */
130
+ declare class LofTextfield extends LofElement {
131
+ static styles: lit.CSSResult[];
132
+ label?: string;
133
+ placeholder: string;
134
+ type: string;
135
+ value: string;
136
+ /** Legacy leading icon name; prefixIcon wins. */
137
+ leftIcon?: string;
138
+ rightIcon?: string;
139
+ clickableRightIcon: boolean;
140
+ rightIconAriaLabel?: string;
141
+ prefixText?: string;
142
+ prefixStyle: TextFieldPrefixStyle;
143
+ suffixText?: string;
144
+ suffixDivider: boolean;
145
+ /** Legacy helper line; helperText wins. */
146
+ supportingText?: string;
147
+ /** Legacy visual state; the error/disabled booleans win. */
148
+ state: TextFieldState;
149
+ size: TextFieldSize;
150
+ labelStyle?: TextFieldLabelStyle;
151
+ /** Deprecated alias of labelStyle="floating". */
152
+ floatingLabel: boolean;
153
+ fieldAriaLabel?: string;
154
+ fieldAriaLabelledby?: string;
155
+ variant: TextFieldVariant;
156
+ disabled: boolean;
157
+ required: boolean;
158
+ multiline: boolean;
159
+ rows: number;
160
+ prefixIcon?: string;
161
+ prefixIconAriaLabel?: string;
162
+ error: boolean;
163
+ errorMessage?: string;
164
+ helperText?: string;
165
+ helperIcon?: string;
166
+ readonly: boolean;
167
+ maxLength?: number;
168
+ name?: string;
169
+ fullWidth: boolean;
170
+ private focused;
171
+ private field;
172
+ private fid;
173
+ connectedCallback(): void;
174
+ /** Focuses the inner input / textarea. */
175
+ focus(options?: FocusOptions): void;
176
+ private get effLabelStyle();
177
+ private get isError();
178
+ private get isDisabled();
179
+ protected willUpdate(changed: Map<string, unknown>): void;
180
+ private onInput;
181
+ private onControlMouseDown;
182
+ /** The icon's own click stays inside the field; only lof-right-icon-click leaves it. */
183
+ private onRightIcon;
184
+ private onRightIconKey;
185
+ private slotHas;
186
+ render(): lit_html.TemplateResult<1>;
187
+ }
188
+ declare global {
189
+ interface HTMLElementTagNameMap {
190
+ "lof-textfield": LofTextfield;
191
+ }
192
+ }
193
+
194
+ type CheckboxState = "default" | "error" | "disabled";
195
+ type CheckboxStatus = "unchecked" | "checked" | "indeterminate";
196
+ type CheckboxSize = "small" | "medium" | "large" | "extra-large";
197
+ type CheckboxDensity = "compact" | "comfortable";
198
+ type CheckboxAlignment = "leading" | "trailing";
199
+ /**
200
+ * Tri-state checkbox: a hidden native <input type="checkbox"> behind a custom
201
+ * box, with a label, an optional label-prefix icon and optional supporting text.
202
+ */
203
+ declare class LofCheckbox extends LofElement {
204
+ static styles: lit.CSSResult[];
205
+ label: string;
206
+ /** lof-icon name shown between the box and the label. */
207
+ icon: string;
208
+ /** Supporting text; the attribute is `supporting-text` (the run-together spelling is deprecated). */
209
+ supportingtext: string;
210
+ /** default | error | disabled */
211
+ state: CheckboxState;
212
+ /** unchecked | checked | indeterminate (indeterminate is programmatic only). */
213
+ status: CheckboxStatus;
214
+ /** Reported in the lof-change detail; not submitted with a form. */
215
+ value: string;
216
+ size: CheckboxSize;
217
+ density: CheckboxDensity;
218
+ alignment: CheckboxAlignment;
219
+ /** Disables the checkbox as `state="disabled"` does; either one (or a disabled fieldset) disables it. */
220
+ disabled: boolean;
221
+ /** Overrides the accessible name from the visible label. */
222
+ fieldAriaLabel?: string;
223
+ private input;
224
+ static formAssociated: boolean;
225
+ private form;
226
+ formDisabledCallback(disabled: boolean): void;
227
+ /** camelCase alias of `supportingtext`, matching lof-textfield and lof-select. */
228
+ get supportingText(): string;
229
+ set supportingText(v: string);
230
+ /** Boolean view of `status`. */
231
+ get checked(): boolean;
232
+ set checked(v: boolean);
233
+ protected willUpdate(changed: Map<string, unknown>): void;
234
+ protected updated(): void;
235
+ /** Runs during the input's click (checked is already toggled), so lof-change
236
+ * fires before the native input/change events — the 1.4.9 order. */
237
+ private onInputClick;
238
+ /** An outer label or `el.click()`: toggle as the native input would. */
239
+ private toggle;
240
+ render(): lit_html.TemplateResult<1>;
241
+ }
242
+ declare global {
243
+ interface HTMLElementTagNameMap {
244
+ "lof-checkbox": LofCheckbox;
245
+ }
246
+ }
247
+
248
+ type ChipTone = "neutral" | "info" | "warning" | "destructive" | "success" | "danger";
249
+ type ChipVariant = "fill" | "subtle";
250
+ type ChipSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
251
+ type ChipBorder = "default" | "rounded";
252
+ /**
253
+ * Compact chip: a short label with tone × variant colouring, optional leading
254
+ * icon or initials avatar, trailing icon, remove control and drag-and-drop.
255
+ */
256
+ declare class LofChip extends LofElement {
257
+ static shadowRootOptions: {
258
+ delegatesFocus: boolean;
259
+ clonable?: boolean;
260
+ customElementRegistry?: CustomElementRegistry;
261
+ mode: ShadowRootMode;
262
+ serializable?: boolean;
263
+ slotAssignment?: SlotAssignmentMode;
264
+ };
265
+ static styles: lit.CSSResult[];
266
+ label: string;
267
+ tone: ChipTone;
268
+ variant: ChipVariant;
269
+ size: ChipSize;
270
+ border: ChipBorder;
271
+ /** Icon name for a leading lof-icon. Ignored when `avatar` is set. */
272
+ leadingIcon: string;
273
+ trailingIcon: string;
274
+ /** Initials for a leading text avatar; wins over leading-icon. */
275
+ avatar: string;
276
+ removable: boolean;
277
+ /** Set when the chip has been removed; hides the host. */
278
+ removed: boolean;
279
+ /** Native drag-and-drop plus Left/Right arrow reordering. */
280
+ draggableChip: boolean;
281
+ /** Accessible name for an icon-only or unlabelled chip; overrides `label` for the chip and its remove button. */
282
+ fieldAriaLabel?: string;
283
+ /** Plain-text body: no button role, Tab stop or key handling. The remove button stays a button. */
284
+ presentational: boolean;
285
+ constructor();
286
+ protected willUpdate(changed: Map<string, unknown>): void;
287
+ private remove_;
288
+ private onKey;
289
+ private onRemoveClick;
290
+ render(): lit_html.TemplateResult<1>;
291
+ }
292
+ declare global {
293
+ interface HTMLElementTagNameMap {
294
+ "lof-chip": LofChip;
295
+ }
296
+ }
297
+
298
+ type AutocompleteItem = string | Record<string, unknown>;
299
+ type AutocompleteFilter = "contains" | "starts-with" | "none";
300
+ type AutocompleteSize = "small" | "medium" | "large";
301
+ type AutocompleteVariant = "default" | "underline" | "legend";
302
+ type AutocompleteLabelStyle = "default" | "floating" | "none";
303
+ /**
304
+ * `<lof-autocomplete>` — a type-ahead field: `lof-textfield` plus a suggestion
305
+ * listbox fed by local `items` or an async `searchFn`.
306
+ */
307
+ declare class LofAutocomplete extends LofElement {
308
+ static styles: lit.CSSResult[];
309
+ items: AutocompleteItem[];
310
+ value: string;
311
+ displayField: string;
312
+ valueField: string;
313
+ supportingField: string;
314
+ filter: AutocompleteFilter;
315
+ searchFn?: (query: string) => Promise<AutocompleteItem[]>;
316
+ debounceMs: number;
317
+ minSearchLength: number;
318
+ maxSuggestions: number;
319
+ multiple: boolean;
320
+ selectedValues: string[];
321
+ selectAllLabel: string;
322
+ clearable: boolean;
323
+ loading: boolean;
324
+ noResultsText: string;
325
+ loadingText: string;
326
+ label?: string;
327
+ placeholder: string;
328
+ size: AutocompleteSize;
329
+ variant: AutocompleteVariant;
330
+ labelStyle?: AutocompleteLabelStyle;
331
+ /** @deprecated use `labelStyle="floating"` (kept as a permanent alias). */
332
+ floatingLabel: boolean;
333
+ fieldAriaLabel?: string;
334
+ fieldAriaLabelledby?: string;
335
+ prefixIcon?: string;
336
+ disabled: boolean;
337
+ readonly: boolean;
338
+ required: boolean;
339
+ error: boolean;
340
+ errorMessage?: string;
341
+ helperText?: string;
342
+ name?: string;
343
+ fullWidth: boolean;
344
+ private text;
345
+ private open;
346
+ private hl;
347
+ private busy;
348
+ private remote;
349
+ private field;
350
+ private panel;
351
+ private readonly aid;
352
+ private debounceTimer?;
353
+ private searchToken;
354
+ private syncingValue;
355
+ private lastCount;
356
+ private toRow;
357
+ private get allRows();
358
+ /** Rows the panel shows for the current text. */
359
+ private get rows();
360
+ /** The search text; in multiple mode the field is always a pure search box. */
361
+ private get query();
362
+ private get inactive();
363
+ private get effLabelStyle();
364
+ private optionId;
365
+ private labelForValue;
366
+ protected willUpdate(changed: PropertyValues): void;
367
+ protected updated(changed: PropertyValues): void;
368
+ disconnectedCallback(): void;
369
+ private detachDoc;
370
+ focus(options?: FocusOptions): void;
371
+ private position;
372
+ private onDocPointer;
373
+ /** An outside scroll moves the panel with its field; it closes once the field is hidden. */
374
+ private onDocScroll;
375
+ private openPanel;
376
+ private close;
377
+ private canOpenFor;
378
+ private announceResults;
379
+ private pick;
380
+ private toggleValue;
381
+ private toggleAll;
382
+ private removeChip;
383
+ /** Enter / Tab / blur with no highlight: an exact label or value match becomes the value. */
384
+ private commitExact;
385
+ private clear;
386
+ private onInput;
387
+ private runSearch;
388
+ private onFocusIn;
389
+ private onFocusOut;
390
+ private move;
391
+ private onKeyDown;
392
+ private renderRow;
393
+ private renderSelectAll;
394
+ private renderChips;
395
+ render(): TemplateResult<1>;
396
+ }
397
+ declare global {
398
+ interface HTMLElementTagNameMap {
399
+ "lof-autocomplete": LofAutocomplete;
400
+ }
401
+ }
402
+
403
+ type AvatarSize = "large" | "medium" | "small" | "extra-small" | "lg" | "md" | "sm" | "xs";
404
+ type AvatarType = "image" | "text" | "icon";
405
+ type AvatarVariant = "fill" | "subtle" | "outline";
406
+ type AvatarBadge = "" | "dot" | "icon";
407
+ /**
408
+ * Circular identity mark: a photo, uppercase initials or a slotted icon in a
409
+ * 20–40px disc. Presentational only — no focus, no events.
410
+ */
411
+ declare class LofAvatar extends LofElement {
412
+ static styles: lit.CSSResult;
413
+ size: AvatarSize;
414
+ type: AvatarType;
415
+ variant: AvatarVariant;
416
+ src: string;
417
+ text: string;
418
+ alt: string;
419
+ /** Inline background colour; wins over the variant and the hooks. */
420
+ bg: string;
421
+ /** Inline text / icon colour; wins over the variant and the hooks. */
422
+ color: string;
423
+ /** lof-icon name for `type="icon"`; replaces the slot when set. */
424
+ icon: string;
425
+ /** A 2px page-colour ring just outside the circle (separates overlapping avatars). */
426
+ ring: boolean;
427
+ /** Status badge on the bottom-right edge: dot (green) or icon (neutral disc with `badge-icon`). */
428
+ badge: AvatarBadge;
429
+ /** lof-icon name inside a `badge="icon"` badge. */
430
+ badgeIcon: string;
431
+ /** What the badge means, for screen readers ("Online"). Without it the badge is decorative. */
432
+ badgeLabel: string;
433
+ protected willUpdate(changed: Map<string, unknown>): void;
434
+ private renderInner;
435
+ private renderBadge;
436
+ render(): lit_html.TemplateResult<1>;
437
+ }
438
+ declare global {
439
+ interface HTMLElementTagNameMap {
440
+ "lof-avatar": LofAvatar;
441
+ }
442
+ }
443
+
444
+ /**
445
+ * `<lof-avatar-group>` (new in 1.5.0, Figma "Avatar Group"): slotted `lof-avatar`s in a
446
+ * row, each overlapping the previous one by a quarter of the diameter (10 / 8 / 6 / 4px),
447
+ * later ones on top. The group gives every avatar its `size` and a `ring`; avatars
448
+ * beyond `max` are hidden and counted, with anyone beyond the slotted ones when `total`
449
+ * is larger, in a "+N" circle.
450
+ */
451
+ declare class LofAvatarGroup extends LofElement {
452
+ static styles: lit.CSSResult;
453
+ /** Diameter step for every avatar and the "+N" circle (40 / 32 / 24 / 20px). */
454
+ size: AvatarSize;
455
+ /** Most avatars to show; 0 shows them all. */
456
+ max: number;
457
+ /** Everyone, when only some avatars are slotted; 0 counts the slotted ones. */
458
+ total: number;
459
+ /** Accessible name of the group. */
460
+ label: string;
461
+ /** Accessible name of the "+N" circle; {n} is the count. */
462
+ overflowLabel: string;
463
+ private slottedCount;
464
+ /** People counted in the "+N" circle. */
465
+ get overflowCount(): number;
466
+ private get avatars();
467
+ protected willUpdate(changed: Map<string, unknown>): void;
468
+ protected updated(): void;
469
+ private onSlotChange;
470
+ private applyToAvatars;
471
+ private renderOverflow;
472
+ render(): lit_html.TemplateResult<1>;
473
+ }
474
+ declare global {
475
+ interface HTMLElementTagNameMap {
476
+ "lof-avatar-group": LofAvatarGroup;
477
+ }
478
+ }
479
+
480
+ type BadgeSize = "small" | "medium" | "large" | "extra-large";
481
+ type BadgeSizeInput = BadgeSize | "sm" | "md" | "lg" | "xl";
482
+ type BadgeVariant = "dot" | "number";
483
+ /**
484
+ * Count indicator: a number pill ("5", "99+") or an unlabeled dot.
485
+ * Position it over the element it decorates yourself.
486
+ */
487
+ declare class LofBadge extends LofElement {
488
+ static styles: lit.CSSResult[];
489
+ /** Count text for the number variant ("5", "99+"). Also feeds the accessible name. */
490
+ number: string;
491
+ /** Explicit accessible name. Attribute is `arialabel` (no hyphen). */
492
+ ariaLabel: string;
493
+ /** Noun used in the generated accessible name: "3 notifications". */
494
+ suffix: string;
495
+ size: BadgeSizeInput;
496
+ variant: BadgeVariant;
497
+ /** Any CSS colour for the background; writes --lof-badge-bg on the host. */
498
+ color: string;
499
+ /** Any CSS colour for the text; writes --lof-badge-color on the host. */
500
+ textColor: string;
501
+ /** Announce count changes: the pill becomes a polite live region (role="status").
502
+ * Badges are quiet by default (role="img"). */
503
+ live: boolean;
504
+ protected willUpdate(changed: Map<string, unknown>): void;
505
+ private get label();
506
+ render(): lit_html.TemplateResult<1>;
507
+ }
508
+ declare global {
509
+ interface HTMLElementTagNameMap {
510
+ "lof-badge": LofBadge;
511
+ }
512
+ }
513
+
514
+ interface BreadcrumbItem {
515
+ label: string;
516
+ url?: string;
517
+ }
518
+ /**
519
+ * Breadcrumb trail: a named navigation landmark holding an ordered list. Every
520
+ * item with a url is a link except the last, which is always the current page.
521
+ */
522
+ declare class LofBreadcrumbs extends LofElement {
523
+ static styles: lit.CSSResult[];
524
+ /** Root first: `{ label, url? }[]`. Set as a property. */
525
+ items: BreadcrumbItem[];
526
+ /** Name of the navigation landmark. */
527
+ ariaLabel: string;
528
+ render(): lit_html.TemplateResult<1>;
529
+ }
530
+ declare global {
531
+ interface HTMLElementTagNameMap {
532
+ "lof-breadcrumbs": LofBreadcrumbs;
533
+ }
534
+ }
535
+
536
+ type ButtonVariant = "default" | "primary" | "secondary" | "ghost" | "link" | "static" | "text" | "outline" | "icon";
537
+ type ButtonTone = "default" | "neutral" | "primary" | "brand" | "destructive" | "critical" | "danger" | "success" | "secondary";
538
+ type ButtonSize = "small" | "medium" | "large";
539
+ type ButtonBorder = "corner-radius" | "small-corner-radius" | "no-corner-radius";
540
+ type Tone = "neutral" | "brand" | "destructive" | "success" | "secondary";
541
+ /**
542
+ * Action button: a native <button> with Style (variant), Tone and Size axes,
543
+ * an icon-only mode, a loading state and an optional corner badge.
544
+ */
545
+ declare class LofButton extends LofElement {
546
+ static styles: lit.CSSResult[];
547
+ /** Style axis. Canonical: default | primary | secondary | ghost | link | static. */
548
+ variant: ButtonVariant;
549
+ /** Tone axis. Canonical: neutral | brand | destructive. */
550
+ tone?: ButtonTone;
551
+ iconOnly: boolean;
552
+ loading: boolean;
553
+ size: ButtonSize;
554
+ border: ButtonBorder;
555
+ disabled: boolean;
556
+ /** Accessible name forwarded to the inner <button>. Required for icon-only. */
557
+ ariaLabel: string | null;
558
+ /** Text for a corner lof-badge ("3", "999+"). */
559
+ badge: string;
560
+ /** Corner dot badge; wins over `badge`. */
561
+ badgeDot: boolean;
562
+ constructor();
563
+ /** The tone actually rendered (unset tone on variant="primary" still means brand for this release). */
564
+ get effectiveTone(): Tone;
565
+ private get styleKey();
566
+ protected willUpdate(changed: Map<string, unknown>): void;
567
+ private pressed;
568
+ private onKeyDown;
569
+ render(): lit_html.TemplateResult<1>;
570
+ }
571
+ declare global {
572
+ interface HTMLElementTagNameMap {
573
+ "lof-button": LofButton;
574
+ }
575
+ }
576
+
577
+ type CalendarWeekStart = "sun" | "mon";
578
+ /**
579
+ * The day a grid key moves to: arrows by date, Home / End to the week's ends
580
+ * (honouring week-start), PageUp / PageDown by a month (Shift: a year), clamped to
581
+ * the target month's end. Null for other keys.
582
+ */
583
+ declare function dayKeyTarget(e: KeyboardEvent, from: Date, ws: 0 | 1): Date | null;
584
+ /**
585
+ * Day-cell look shared by the calendar and the pickers: a 36px halo (hover,
586
+ * focus ring, selected backing) around a 28px disc (today ring, selected fill).
587
+ */
588
+ declare const dayCellStyles: lit.CSSResult;
589
+ /** `<lof-calendar>` — an inline month grid with single-date selection. */
590
+ declare class LofCalendar extends LofElement {
591
+ static styles: lit.CSSResult[];
592
+ value: string | null;
593
+ min: string | null;
594
+ max: string | null;
595
+ disabled: boolean;
596
+ weekStart: CalendarWeekStart;
597
+ locale: string;
598
+ /** Extra per-day unavailability on top of min / max (property only). */
599
+ isDateDisabled?: (date: Date) => boolean;
600
+ /** First day of the month in view. */
601
+ private view;
602
+ /** Last cell reached with the keyboard (the preferred Tab stop). */
603
+ private focusDate;
604
+ protected willUpdate(changed: PropertyValues): void;
605
+ private get ws();
606
+ /** min / max / isDateDisabled: the day is focusable but inert (aria-disabled). */
607
+ private isUnavailable;
608
+ private inView;
609
+ /** The one cell in the Tab order: last arrowed → selected → today → first enabled day of the month. */
610
+ private tabStop;
611
+ private setView;
612
+ private select;
613
+ private dateOf;
614
+ /** Focus the cell for `d`, switching the month first when it is not in view. */
615
+ private focusCell;
616
+ private onGridKey;
617
+ render(): lit_html.TemplateResult<1>;
618
+ }
619
+ declare global {
620
+ interface HTMLElementTagNameMap {
621
+ "lof-calendar": LofCalendar;
622
+ }
623
+ }
624
+
625
+ type CardType = "custom" | "media";
626
+ /**
627
+ * Elevated, padded surface that groups related content. `type="media"` adds a
628
+ * flush media region (for <lof-card-media>) above the padded body.
629
+ */
630
+ declare class LofCard extends LofElement {
631
+ static styles: lit.CSSResult[];
632
+ /** custom (default): padded body. media: flush media slot above the body. */
633
+ type: CardType;
634
+ render(): lit_html.TemplateResult<1>;
635
+ }
636
+ declare global {
637
+ interface HTMLElementTagNameMap {
638
+ "lof-card": LofCard;
639
+ }
640
+ }
641
+
642
+ /**
643
+ * Media card: a bordered surface with an optional full-width image, then a
644
+ * title, a subtitle and slotted body content in a padded area.
645
+ */
646
+ declare class LofCardMedia extends LofElement {
647
+ static styles: lit.CSSResult[];
648
+ imageSrc: string;
649
+ imageAlt: string;
650
+ /** Rendered as an <h3>. Also the native `title` attribute, so it shows as a tooltip. */
651
+ title: string;
652
+ subtitle: string;
653
+ render(): lit_html.TemplateResult<1>;
654
+ }
655
+ declare global {
656
+ interface HTMLElementTagNameMap {
657
+ "lof-card-media": LofCardMedia;
658
+ }
659
+ }
660
+
661
+ type CarouselType = "default" | "only-indicators" | "side-arrows" | "bottom-arrows";
662
+ type CarouselOrientation = "horizontal" | "vertical";
663
+ /**
664
+ * `<lof-carousel>` — slotted slides in a clipped viewport, moved with arrows,
665
+ * dots, drag, the keyboard or autoplay.
666
+ */
667
+ declare class LofCarousel extends LofElement {
668
+ static styles: lit.CSSResult[];
669
+ value: number;
670
+ loop: boolean;
671
+ autoplay: boolean;
672
+ interval: number;
673
+ pauseOnHover: boolean;
674
+ showButtons: boolean;
675
+ showDots?: boolean;
676
+ type?: CarouselType;
677
+ orientation: CarouselOrientation;
678
+ label: string;
679
+ gap: number;
680
+ panels: number;
681
+ disabled: boolean;
682
+ private slides;
683
+ /** Track position in slide steps, counting the leading clones when looping. */
684
+ private pos;
685
+ private animating;
686
+ private panelSize;
687
+ private viewport;
688
+ private track;
689
+ private ro?;
690
+ private timer?;
691
+ private hovering;
692
+ private focusWithin;
693
+ private drag;
694
+ private get vertical();
695
+ private get panelCount();
696
+ private get wraps();
697
+ private get cloneCount();
698
+ private get maxIndex();
699
+ private get gapPx();
700
+ private get arrows();
701
+ private get dots();
702
+ connectedCallback(): void;
703
+ disconnectedCallback(): void;
704
+ protected willUpdate(changed: PropertyValues): void;
705
+ protected updated(changed: PropertyValues): void;
706
+ /** Position for the current `value`; out-of-range values leave the track at the start (as 1.4.9 does). */
707
+ private syncPos;
708
+ private onSlot;
709
+ private renderClones;
710
+ private measure;
711
+ /** A loop wrap in flight: the track is on a clone and settles on `real` when the transition ends. */
712
+ private pendingWrap;
713
+ private goTo;
714
+ private settleWrap;
715
+ private onTransitionEnd;
716
+ private prev;
717
+ private next;
718
+ private onKey;
719
+ private onPointerDown;
720
+ private onPointerMove;
721
+ private onPointerUp;
722
+ private onEnter;
723
+ private onLeave;
724
+ private onFocusIn;
725
+ private onFocusOut;
726
+ private stopAutoplay;
727
+ private restartAutoplay;
728
+ private renderArrow;
729
+ private renderDots;
730
+ render(): lit_html.TemplateResult<1>;
731
+ }
732
+ declare global {
733
+ interface HTMLElementTagNameMap {
734
+ "lof-carousel": LofCarousel;
735
+ }
736
+ }
737
+
738
+ type ContainerPadding = "small" | "medium" | "large" | "extra-large" | "sm" | "md" | "lg" | "xl";
739
+ type ContainerSurface = "default" | "elevated" | "transparent";
740
+ type ContainerBackground = "light" | "white" | "none";
741
+ /** A full-width rounded surface block that groups a section of a page. */
742
+ declare class LofContainer extends LofElement {
743
+ static styles: lit.CSSResult;
744
+ padding: ContainerPadding;
745
+ shadow: boolean;
746
+ surface?: ContainerSurface;
747
+ /** @deprecated since 1.4.7 — use `surface` (white→default, light→elevated, none→transparent). */
748
+ background?: ContainerBackground;
749
+ /** Explicit `surface` wins, else the mapped `background`, else "default". */
750
+ get resolvedSurface(): ContainerSurface;
751
+ protected willUpdate(changed: Map<string, unknown>): void;
752
+ render(): lit_html.TemplateResult<1>;
753
+ }
754
+ declare global {
755
+ interface HTMLElementTagNameMap {
756
+ "lof-container": LofContainer;
757
+ }
758
+ }
759
+
760
+ type DatePickerSize = "small" | "medium" | "large";
761
+ /** Field chrome shared by the date and range pickers. */
762
+ declare const pickerFieldStyles: lit.CSSResult;
763
+ /** Popover surface and the month / year grids shared by the date and range pickers. */
764
+ declare const pickerPanelStyles: lit.CSSResult;
765
+ /**
766
+ * `<lof-date-picker>` — a typeable date field with a calendar popover
767
+ * (month / year drill-down and Today / Tomorrow / Yesterday shortcuts).
768
+ */
769
+ declare class LofDatePicker extends LofElement {
770
+ static styles: lit.CSSResult[];
771
+ value: string | null;
772
+ placeholder: string;
773
+ label: string | null;
774
+ disabled: boolean;
775
+ required: boolean;
776
+ readonly: boolean;
777
+ minDate: string | null;
778
+ maxDate: string | null;
779
+ /** @deprecated use `minDate`. */
780
+ min: string | null;
781
+ /** @deprecated use `maxDate`. */
782
+ max: string | null;
783
+ weekStart: "sun" | "mon";
784
+ locale: string;
785
+ displayFormat: string | null;
786
+ formatDate?: (date: Date) => string;
787
+ open: boolean;
788
+ closeOnSelect: boolean;
789
+ clearable: boolean;
790
+ showShortcuts: boolean;
791
+ error: boolean;
792
+ errorMessage?: string;
793
+ helperText?: string;
794
+ name?: string;
795
+ size: DatePickerSize;
796
+ variant: "outlined";
797
+ fullWidth: boolean;
798
+ /** Extra per-day disabling on top of min / max. Property only. */
799
+ isDateDisabled?: (date: Date) => boolean;
800
+ private text;
801
+ private typedError;
802
+ private view;
803
+ private panelView;
804
+ private focusDate;
805
+ private periodFocus;
806
+ private input;
807
+ private panel;
808
+ private focusTimer?;
809
+ private moveFocusOnOpen;
810
+ /** Set while setOpen() drives `open`, so a plain property write can be told apart. */
811
+ private openedByUser;
812
+ private get ws();
813
+ private get sizeClass();
814
+ private available;
815
+ private minBound;
816
+ private maxBound;
817
+ private display;
818
+ protected willUpdate(changed: PropertyValues): void;
819
+ protected updated(changed: PropertyValues): void;
820
+ disconnectedCallback(): void;
821
+ private detach;
822
+ private position;
823
+ private setOpen;
824
+ private onDocPointer;
825
+ /** An outside scroll moves the panel with its field; it closes once the field is hidden. */
826
+ private onDocScroll;
827
+ /** Escape closes from anywhere in the document while open. */
828
+ private onDocKey;
829
+ private focusGrid;
830
+ private commitDate;
831
+ private pick;
832
+ private commitTyped;
833
+ private revert;
834
+ private clear;
835
+ private onFieldClick;
836
+ private onInputKey;
837
+ private onInput;
838
+ private onInputBlur;
839
+ private onFocusOut;
840
+ private onPanelKey;
841
+ private dateOf;
842
+ private onDayKey;
843
+ private focusDay;
844
+ private inView;
845
+ private setView;
846
+ private shiftView;
847
+ private onPrev;
848
+ private onNext;
849
+ private yearPageStart;
850
+ private pageYears;
851
+ private togglePanelView;
852
+ private monthAvailable;
853
+ private yearAvailable;
854
+ private chooseMonth;
855
+ private chooseYear;
856
+ private onPeriodKey;
857
+ private renderDays;
858
+ private renderMonths;
859
+ private renderYears;
860
+ private renderShortcuts;
861
+ render(): lit_html.TemplateResult<1>;
862
+ }
863
+ declare global {
864
+ interface HTMLElementTagNameMap {
865
+ "lof-date-picker": LofDatePicker;
866
+ }
867
+ }
868
+
869
+ type DividerOrientation = "horizontal" | "vertical";
870
+ /**
871
+ * Thin separator rule, horizontal or vertical. The host carries
872
+ * role="separator" and aria-orientation; the visible line is the `base` part.
873
+ */
874
+ declare class LofDivider extends LofElement {
875
+ static styles: lit.CSSResult;
876
+ orientation: DividerOrientation;
877
+ connectedCallback(): void;
878
+ protected updated(): void;
879
+ render(): lit_html.TemplateResult<1>;
880
+ }
881
+ declare global {
882
+ interface HTMLElementTagNameMap {
883
+ "lof-divider": LofDivider;
884
+ }
885
+ }
886
+
887
+ type DrawerSide = "bottom" | "left" | "right";
888
+ /** Right-aligned actions row; the drawer uses it for its footer slot. */
889
+ declare class LofDrawerFooter extends LofElement {
890
+ static styles: lit.CSSResult;
891
+ render(): lit_html.TemplateResult<1>;
892
+ }
893
+ /**
894
+ * Edge-anchored panel that slides in from the bottom, left or right over a
895
+ * scrim, with an optional drag-to-close handle on bottom drawers.
896
+ */
897
+ declare class LofDrawer extends LofElement {
898
+ static styles: lit.CSSResult;
899
+ open: boolean;
900
+ side: DrawerSide;
901
+ /** False hides the close button and ignores backdrop / Escape (drag still closes). */
902
+ dismissible: boolean;
903
+ modal: boolean;
904
+ closeOnBackdrop: boolean;
905
+ closeOnEscape: boolean;
906
+ showHandle: boolean;
907
+ draggable: boolean;
908
+ /** Fraction of the panel height a drag must pass before release closes. */
909
+ snapThreshold: number;
910
+ /** Written to the panel as --drawer-max-height; no rule reads it (as in 1.4.9). */
911
+ maxHeight: string;
912
+ /** Explicit panel width; wins over a host --lof-drawer-width. */
913
+ width: string;
914
+ title: string;
915
+ description: string;
916
+ private settled;
917
+ private drag;
918
+ private dragging;
919
+ private panel;
920
+ private contentEl;
921
+ private watch;
922
+ private locked;
923
+ private opener;
924
+ private settleTimer?;
925
+ private dragStart;
926
+ connectedCallback(): void;
927
+ disconnectedCallback(): void;
928
+ protected firstUpdated(): void;
929
+ private onFooterSlotChange;
930
+ protected willUpdate(changed: Map<string, unknown>): void;
931
+ protected updated(changed: Map<string, unknown>): void;
932
+ private setLocked;
933
+ private focusOnOpen;
934
+ private returnFocus;
935
+ private onDocKeydown;
936
+ private trapTab;
937
+ private onOverlayClick;
938
+ private onHandleDown;
939
+ private onHandleMove;
940
+ private onHandleUp;
941
+ render(): lit_html.TemplateResult<1>;
942
+ }
943
+ declare global {
944
+ interface HTMLElementTagNameMap {
945
+ "lof-drawer": LofDrawer;
946
+ "lof-drawer-footer": LofDrawerFooter;
947
+ }
948
+ }
949
+
950
+ /** Keyboard convention for named keys. */
951
+ type KbdPlatform = "auto" | "mac" | "other";
952
+ /** How a named key is drawn and read. */
953
+ interface ResolvedKbdKey {
954
+ /** What the cap shows. */
955
+ label: string;
956
+ /** What assistive technology reads; equals `label` when the cap needs no translation. */
957
+ spoken: string;
958
+ /** True when `label` is not the key's full name (a symbol or an abbreviation). */
959
+ translated: boolean;
960
+ }
961
+ /** "mac" on Mac / iPhone / iPad, otherwise "other" (also without a navigator, as in SSR). */
962
+ declare function detectKbdPlatform(): "mac" | "other";
963
+ /** Resolves a named key (any case) in a platform's convention; other text is returned as typed. */
964
+ declare function resolveKbdKey(name: string, platform?: KbdPlatform | string): ResolvedKbdKey;
965
+
966
+ type KbdSize = "sm" | "md" | "lg" | "small" | "medium" | "large";
967
+ type KbdVariant = "default" | "muted";
968
+ /**
969
+ * A single key cap for showing keyboard shortcuts inline with text.
970
+ * Display-only: no role, no focus, no events.
971
+ */
972
+ declare class LofKbd extends LofElement {
973
+ static styles: lit.CSSResult[];
974
+ size: KbdSize;
975
+ variant: KbdVariant;
976
+ /** @deprecated The Kbd spec has one 4px radius at every size. */
977
+ pill: boolean;
978
+ /** Pressed look. */
979
+ inset: boolean;
980
+ /** A named key (mod, shift, enter, esc, arrows…) drawn in the platform's convention; replaces the slotted text. */
981
+ keyName?: string;
982
+ /** Convention for `key-name`: auto (detect), mac or other. */
983
+ platform: KbdPlatform;
984
+ private internals_?;
985
+ private slotted;
986
+ constructor();
987
+ private setSymbol;
988
+ private onSlotChange;
989
+ protected willUpdate(changed: Map<string, unknown>): void;
990
+ render(): lit_html.TemplateResult<1>;
991
+ }
992
+ /** A multi-key shortcut: one <lof-kbd> per item, joined by "+" separators. */
993
+ declare class LofKbdGroup extends LofElement {
994
+ static styles: lit.CSSResult[];
995
+ /** Keys, one <lof-kbd key-name> each; property or JSON array attribute. */
996
+ items: string[];
997
+ size: KbdSize;
998
+ variant: KbdVariant;
999
+ /** Convention passed to every generated <lof-kbd>. */
1000
+ platform: KbdPlatform;
1001
+ render(): lit_html.TemplateResult<1>;
1002
+ }
1003
+ declare global {
1004
+ interface HTMLElementTagNameMap {
1005
+ "lof-kbd": LofKbd;
1006
+ "lof-kbd-group": LofKbdGroup;
1007
+ }
1008
+ }
1009
+
1010
+ /**
1011
+ * `<lof-layout>` — the host itself is a CSS grid of `columns` equal tracks
1012
+ * separated by `gap`; with `responsive` on it drops to 3 / 2 / 1 columns at
1013
+ * the 1024 / 768 / 480px viewport breakpoints.
1014
+ */
1015
+ declare class LofLayout extends LofElement {
1016
+ static styles: lit.CSSResult;
1017
+ /** Any CSS length; written to the host as the grid gap. */
1018
+ gap: string;
1019
+ columns: number;
1020
+ responsive: boolean;
1021
+ protected willUpdate(changed: PropertyValues): void;
1022
+ private setVar;
1023
+ render(): lit_html.TemplateResult<1>;
1024
+ }
1025
+ declare global {
1026
+ interface HTMLElementTagNameMap {
1027
+ "lof-layout": LofLayout;
1028
+ }
1029
+ }
1030
+
1031
+ interface RadioOption {
1032
+ value: string;
1033
+ label: string;
1034
+ supportingText?: string;
1035
+ disabled?: boolean;
1036
+ icon?: string;
1037
+ avatar?: string;
1038
+ }
1039
+ type RadioOrientation = "horizontal" | "vertical";
1040
+ type RadioSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
1041
+ type RadioDensity = "compact" | "comfortable";
1042
+ type RadioAlignment = "leading" | "trailing";
1043
+ /**
1044
+ * Single-select radio group: one element renders a native radio input for
1045
+ * every entry in `options`.
1046
+ */
1047
+ declare class LofRadio extends LofElement {
1048
+ static styles: lit.CSSResult[];
1049
+ /** The options, in order. Property or JSON attribute. */
1050
+ options: RadioOption[];
1051
+ /** Shared by every native input in the group; give each group its own. */
1052
+ name: string;
1053
+ orientation: RadioOrientation;
1054
+ size: RadioSize;
1055
+ density: RadioDensity;
1056
+ alignment: RadioAlignment;
1057
+ /** Value of the selected option, or null. Updated on every user selection. */
1058
+ selectedValue: string | null;
1059
+ disabled: boolean;
1060
+ error: boolean;
1061
+ errorMessage: string;
1062
+ /** Accessible name for the radiogroup (it has no visible legend). */
1063
+ fieldAriaLabel?: string;
1064
+ /** Value reported to the Angular forms bridge; not used for rendering. */
1065
+ value: string;
1066
+ /** Set by the Angular forms bridge; not used for rendering. */
1067
+ checked: boolean;
1068
+ static formAssociated: boolean;
1069
+ private form;
1070
+ formDisabledCallback(disabled: boolean): void;
1071
+ protected willUpdate(changed: Map<string, unknown>): void;
1072
+ private onChange;
1073
+ render(): lit_html.TemplateResult<1>;
1074
+ }
1075
+ declare global {
1076
+ interface HTMLElementTagNameMap {
1077
+ "lof-radio": LofRadio;
1078
+ }
1079
+ }
1080
+
1081
+ interface MenuItem {
1082
+ label: string;
1083
+ active?: boolean;
1084
+ checked?: boolean;
1085
+ disabled?: boolean;
1086
+ submenu?: MenuItem[];
1087
+ open?: boolean;
1088
+ /** lof-icon name drawn before the label on list and arrow rows (decorative). */
1089
+ icon?: string;
1090
+ }
1091
+ type MenuType = "list" | "checkbox" | "select-option" | "arrow" | "default" | "fixed" | "fit";
1092
+ type MenuWidth = "fixed" | "fit";
1093
+ type MenuSize = "large" | "medium" | "small";
1094
+ /** Declarative placeholder for menu rows. It renders nothing and the menu does not read it. */
1095
+ declare class LofMenuItem extends LofElement {
1096
+ label: string;
1097
+ value: string;
1098
+ disabled: boolean;
1099
+ icon: string;
1100
+ protected createRenderRoot(): this;
1101
+ render(): symbol;
1102
+ }
1103
+ /**
1104
+ * `<lof-menu>` — a vertical action menu built from `items`. DOM focus stays on
1105
+ * the list; the highlighted row is tracked separately (aria-activedescendant).
1106
+ */
1107
+ declare class LofMenu extends LofElement {
1108
+ type: MenuType;
1109
+ width?: MenuWidth;
1110
+ size: MenuSize;
1111
+ items: MenuItem[];
1112
+ /** Working copy; interaction replaces entries, never the caller's objects. */
1113
+ _items: MenuItem[];
1114
+ /** Highlighted row, and the highlighted entry of its submenu (-1 = none). */
1115
+ private row;
1116
+ private sub;
1117
+ /** Row whose submenu was opened by a click or the keyboard (hover can't close it). */
1118
+ private locked;
1119
+ /** True after keyboard use; the row ring shows only then. */
1120
+ private kbd;
1121
+ private readonly baseId;
1122
+ protected createRenderRoot(): this;
1123
+ connectedCallback(): void;
1124
+ disconnectedCallback(): void;
1125
+ /**
1126
+ * Moves the highlight (aria-activedescendant) to row `index`, clamped; a negative
1127
+ * index counts from the end (-1 = last row). For menu buttons that open on the last row.
1128
+ */
1129
+ focusItem(index: number): void;
1130
+ /** Places open flyouts beside their row, flipping at the viewport edge; closes them when the row scrolls away. */
1131
+ private placeFlyouts;
1132
+ private get shape();
1133
+ private get widthMode();
1134
+ private rowId;
1135
+ private hasSub;
1136
+ private get inSub();
1137
+ private setOpen;
1138
+ private closeAll;
1139
+ private activate;
1140
+ /** Submenu entries are always selectable: 1.4.9 does not check their `disabled` flag. */
1141
+ private activateSub;
1142
+ private onRowClick;
1143
+ private onSubClick;
1144
+ private onRowEnter;
1145
+ private onRowLeave;
1146
+ private onDocClick;
1147
+ private onKeyDown;
1148
+ protected willUpdate(changed: PropertyValues): void;
1149
+ protected updated(): void;
1150
+ private renderBody;
1151
+ private renderRow;
1152
+ render(): lit_html.TemplateResult<1>;
1153
+ }
1154
+ declare global {
1155
+ interface HTMLElementTagNameMap {
1156
+ "lof-menu": LofMenu;
1157
+ "lof-menu-item": LofMenuItem;
1158
+ }
1159
+ }
1160
+
1161
+ type MenubarType = "fit" | "fixed";
1162
+ interface MenubarSelectDetail {
1163
+ label: string;
1164
+ value?: string;
1165
+ shortcut?: string;
1166
+ }
1167
+ type MenubarChangeDetail = {
1168
+ type: "checkbox";
1169
+ label: string;
1170
+ name: string;
1171
+ checked: boolean;
1172
+ } | {
1173
+ type: "radio";
1174
+ label: string;
1175
+ name: string;
1176
+ value: string;
1177
+ };
1178
+ /** A data holder for one menu of the bar. It renders nothing; the bar reads its children. */
1179
+ declare class LofMenubarMenu extends LofElement {
1180
+ label: string;
1181
+ disabled: boolean;
1182
+ protected createRenderRoot(): this;
1183
+ render(): symbol;
1184
+ }
1185
+ /**
1186
+ * `<lof-menubar>` — a horizontal File / Edit / View strip. Each child
1187
+ * `<lof-menubar-menu>` becomes a trigger; its marked-up children are copied
1188
+ * into a fixed-position dropdown.
1189
+ */
1190
+ declare class LofMenubar extends LofElement {
1191
+ bindShortcuts: boolean;
1192
+ type: MenubarType;
1193
+ private menus;
1194
+ /** Open menu (-1 = none), the highlighted entry in it, and the open submenu. */
1195
+ private openIndex;
1196
+ private focusIndex;
1197
+ private subOpen;
1198
+ private subFocus;
1199
+ private readonly baseId;
1200
+ protected createRenderRoot(): this;
1201
+ connectedCallback(): void;
1202
+ disconnectedCallback(): void;
1203
+ private entries;
1204
+ private subItems;
1205
+ private checkboxLabel;
1206
+ private trigger;
1207
+ private panel;
1208
+ private openMenu;
1209
+ private closeAll;
1210
+ private position;
1211
+ private openSub;
1212
+ private onScroll;
1213
+ private onDocClick;
1214
+ private select;
1215
+ private toggleCheckbox;
1216
+ private pickRadio;
1217
+ private activate;
1218
+ private onTriggerClick;
1219
+ private onTriggerEnter;
1220
+ private onTriggerKey;
1221
+ private onPanelKey;
1222
+ private onDocKey;
1223
+ private shortcutMatches;
1224
+ private renderEntries;
1225
+ private closeSubFromHover;
1226
+ private activeDescendant;
1227
+ render(): TemplateResult<1>;
1228
+ }
1229
+ declare global {
1230
+ interface HTMLElementTagNameMap {
1231
+ "lof-menubar": LofMenubar;
1232
+ "lof-menubar-menu": LofMenubarMenu;
1233
+ }
1234
+ }
1235
+
1236
+ type OtpMode = "numeric" | "alphanumeric";
1237
+ type OtpSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
1238
+ /**
1239
+ * `<lof-otp>` — one single-character input per code position, with
1240
+ * auto-advance, smart backspace, paste distribution and group separators.
1241
+ */
1242
+ declare class LofOtp extends LofElement {
1243
+ static styles: lit.CSSResult[];
1244
+ value: string;
1245
+ length: number;
1246
+ groupSize: number;
1247
+ placeholder: string;
1248
+ inputMode: OtpMode | "";
1249
+ /** @deprecated use `input-mode`. */
1250
+ type: OtpMode;
1251
+ mask: boolean;
1252
+ disabled: boolean;
1253
+ readonly: boolean;
1254
+ required: boolean;
1255
+ name: string | null;
1256
+ autocomplete: string;
1257
+ inputmode: "numeric" | "text" | null;
1258
+ pattern: string | null;
1259
+ ariaLabel: string | null;
1260
+ invalid: boolean;
1261
+ showSeparator: boolean;
1262
+ size: OtpSize;
1263
+ private cells;
1264
+ private chars;
1265
+ /** Set while the component writes `value` itself, so the cells keep their positions. */
1266
+ private selfSet;
1267
+ private get count();
1268
+ private get mode();
1269
+ private valid;
1270
+ private get complete();
1271
+ protected willUpdate(changed: PropertyValues): void;
1272
+ connectedCallback(): void;
1273
+ private commit;
1274
+ private focusCell;
1275
+ /** Spread valid characters from `start` onward; overflow is dropped. */
1276
+ private distribute;
1277
+ private onInput;
1278
+ private onKeyDown;
1279
+ private onPaste;
1280
+ private onPointerDown;
1281
+ private renderCell;
1282
+ render(): lit_html.TemplateResult<1>;
1283
+ }
1284
+ declare global {
1285
+ interface HTMLElementTagNameMap {
1286
+ "lof-otp": LofOtp;
1287
+ }
1288
+ }
1289
+
1290
+ interface SelectOptionObject {
1291
+ value: string;
1292
+ label?: string;
1293
+ supportingText?: string;
1294
+ icon?: string;
1295
+ }
1296
+ type SelectOption = string | SelectOptionObject;
1297
+ type SelectState = "default" | "error" | "disabled";
1298
+ type SelectSize = "small" | "medium" | "large";
1299
+ type SelectBorder = "rounded" | "sharp";
1300
+ type SelectLabelStyle = "default" | "floating" | "none";
1301
+ /**
1302
+ * Combobox-style dropdown: a text-field-styled trigger that opens a custom
1303
+ * listbox (top layer), with optional search, multi-select chips and Select-all.
1304
+ */
1305
+ declare class LofSelect extends LofElement {
1306
+ static styles: lit.CSSResult[];
1307
+ label: string;
1308
+ labelStyle: SelectLabelStyle;
1309
+ fieldAriaLabel?: string;
1310
+ fieldAriaLabelledby?: string;
1311
+ options: SelectOption[];
1312
+ multiple: boolean;
1313
+ /** Selected value in single-select mode. */
1314
+ selected: string;
1315
+ /** Selected values in multi-select mode. */
1316
+ selectedValues: string[];
1317
+ state: SelectState;
1318
+ supportingText: string;
1319
+ supportingIcon: string;
1320
+ size: SelectSize;
1321
+ border: SelectBorder;
1322
+ leftIcon: string;
1323
+ rightIcon: string;
1324
+ placeholder: string;
1325
+ searchPlaceholder: string;
1326
+ selectAllLabel: string;
1327
+ /** Hard cap on visible chips; by default the count adapts to the trigger width. */
1328
+ maxVisibleChips: number;
1329
+ noSearch: boolean;
1330
+ private open;
1331
+ private query;
1332
+ /** Highlighted row: -1 none; in multi mode 0 is the Select-all row. */
1333
+ private hl;
1334
+ private fit;
1335
+ private trigger;
1336
+ private panel;
1337
+ private searchInput?;
1338
+ private measure?;
1339
+ private valueEl?;
1340
+ private sid;
1341
+ private ro?;
1342
+ private typeBuf;
1343
+ private typeTimer?;
1344
+ private get opts();
1345
+ private get filtered();
1346
+ private labelOf;
1347
+ private get values();
1348
+ private get hasValue();
1349
+ private get isDisabled();
1350
+ private get name();
1351
+ private get triggerName();
1352
+ /** 1.4.9 fires `changed` and then `lof-change` with the same detail (the README
1353
+ * documents only `changed`); both are kept so either listener works. */
1354
+ private commit;
1355
+ private pick;
1356
+ private toggleAll;
1357
+ private removeChip;
1358
+ private removeLast;
1359
+ private openPanel;
1360
+ private close;
1361
+ /**
1362
+ * Opens on the side with more room when the list fits neither, shortened to fit,
1363
+ * but never shorter than three rows plus the pinned header.
1364
+ */
1365
+ private position;
1366
+ private onDocPointer;
1367
+ /** An outside scroll moves the panel with its field; it closes once the field is hidden. */
1368
+ private onDocScroll;
1369
+ protected updated(changed: PropertyValues): void;
1370
+ private detachDoc;
1371
+ connectedCallback(): void;
1372
+ disconnectedCallback(): void;
1373
+ private measureChips;
1374
+ private get rowCount();
1375
+ private activate;
1376
+ private move;
1377
+ private onTriggerKey;
1378
+ private onListKey;
1379
+ private typeAhead;
1380
+ private onSearchInput;
1381
+ protected willUpdate(changed: PropertyValues): void;
1382
+ private renderChips;
1383
+ /** After a keyboard removal, focus the next remove button (or the trigger). */
1384
+ private focusRemoveAt;
1385
+ private renderRows;
1386
+ render(): lit_html.TemplateResult<1>;
1387
+ }
1388
+ declare global {
1389
+ interface HTMLElementTagNameMap {
1390
+ "lof-select": LofSelect;
1391
+ }
1392
+ }
1393
+
1394
+ type PaginationType = "extended" | "compact" | "count-text" | "page-select";
1395
+ type Slot = {
1396
+ kind: "page";
1397
+ n: number;
1398
+ } | {
1399
+ kind: "gap";
1400
+ };
1401
+ /** Pages shown in the extended layout: all up to 7, else a window with gaps. */
1402
+ declare function pageWindow(total: number, current: number): Slot[];
1403
+ /**
1404
+ * The 480–768px window: first, last and current ±1, with a gap wherever that hides
1405
+ * two or more pages (a single hidden page is shown instead).
1406
+ */
1407
+ declare function midWindow(total: number, current: number): Slot[];
1408
+ /**
1409
+ * Page navigation in three layouts: extended (numbered chips), compact
1410
+ * ("Page X of Y") and count-text ("1–10 of 50"). Never loads data itself:
1411
+ * listen for lof-change.
1412
+ */
1413
+ declare class LofPagination extends LofElement {
1414
+ static styles: lit.CSSResult[];
1415
+ type: PaginationType;
1416
+ /** Controlled current page (1-based). Leave unset for uncontrolled use. */
1417
+ page?: number;
1418
+ defaultPage: number;
1419
+ totalPages: number;
1420
+ totalItems: number;
1421
+ perPage: number;
1422
+ showLabel: boolean;
1423
+ disabled: boolean;
1424
+ /** Reserved for link mode; accepted but not rendered. */
1425
+ hrefTemplate: string;
1426
+ /** Name of the navigation landmark. */
1427
+ ariaLabel: string;
1428
+ /** Adds a rows-per-page selector after the navigation (any type). */
1429
+ showRowsPerPage: boolean;
1430
+ /** Values the rows-per-page selector offers; the current per-page is added when missing. */
1431
+ rowsPerPageOptions: number[];
1432
+ /** Text before the rows-per-page selector; also its accessible name. */
1433
+ rowsPerPageLabel: string;
1434
+ private internal?;
1435
+ private get pageCount();
1436
+ private get current();
1437
+ private go;
1438
+ /** A nav button that becomes disabled under focus hands focus to its sibling. */
1439
+ private keepFocus;
1440
+ private nav;
1441
+ private compactStack;
1442
+ private renderNumbers;
1443
+ private renderExtended;
1444
+ private renderCount;
1445
+ /** The inner dropdowns' own events stop here: listeners on the pagination only see { page }. */
1446
+ private swallow;
1447
+ private renderPageSelect;
1448
+ private get perPageChoices();
1449
+ private pickPerPage;
1450
+ private renderRowsPerPage;
1451
+ private renderNav;
1452
+ render(): lit_html.TemplateResult<1>;
1453
+ }
1454
+ declare global {
1455
+ interface HTMLElementTagNameMap {
1456
+ "lof-pagination": LofPagination;
1457
+ }
1458
+ }
1459
+
1460
+ type PopoverSide = "top" | "right" | "bottom" | "left";
1461
+ type PopoverAlign = "start" | "center" | "end";
1462
+ type PopoverHasPopup = "dialog" | "menu" | "listbox" | "tree" | "grid" | "true";
1463
+ type PopoverContentSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
1464
+ /**
1465
+ * Click-to-open floating panel. The first element in the default slot is the
1466
+ * trigger; whatever is in the `content` slot is shown in a top-layer wrapper
1467
+ * positioned next to it.
1468
+ */
1469
+ declare class LofPopover extends LofElement {
1470
+ static styles: lit.CSSResult;
1471
+ /** Controlled open state; once set (true or false) the element only requests changes. */
1472
+ open?: boolean;
1473
+ defaultOpen: boolean;
1474
+ disabled: boolean;
1475
+ side: PopoverSide;
1476
+ align: PopoverAlign;
1477
+ sideOffset: number;
1478
+ alignOffset: number;
1479
+ /** Tab / Shift+Tab wrap inside the panel while it is open. */
1480
+ trapFocus: boolean;
1481
+ closeOnEscape: boolean;
1482
+ closeOnOutsideClick: boolean;
1483
+ arrow: boolean;
1484
+ /** Written to the trigger's aria-haspopup: dialog (default), or menu for a lof-menu panel. */
1485
+ hasPopup: PopoverHasPopup;
1486
+ private internalOpen;
1487
+ private arrowStyle;
1488
+ private wrapper;
1489
+ private readonly panelId;
1490
+ private trigger;
1491
+ private wasOpen;
1492
+ /** How the last open / close was asked for: a pointer shows no focus ring. */
1493
+ private via;
1494
+ /** closeOnOutsideClick as it was when the panel opened (1.4.9 reads it once). */
1495
+ private outsideCloses;
1496
+ private initialised;
1497
+ /** The state actually shown. */
1498
+ get isOpen(): boolean;
1499
+ connectedCallback(): void;
1500
+ disconnectedCallback(): void;
1501
+ protected willUpdate(changed: Map<string, unknown>): void;
1502
+ /** Ask for a new state: always emits; applies it only in uncontrolled mode. */
1503
+ private request;
1504
+ /** Close from outside (another popover opening). */
1505
+ dismiss(): void;
1506
+ private onDefaultSlot;
1507
+ private detachTrigger;
1508
+ private onTriggerPointerDown;
1509
+ private onTriggerKeydown;
1510
+ private onDocPointerDown;
1511
+ private onDocKeydown;
1512
+ /** Whether focus is on the popover, its trigger or anything in its panel (composed tree). */
1513
+ private holdsFocus;
1514
+ private panelTabbables;
1515
+ private focusOpts;
1516
+ /** On open: the first focusable in the panel, else the panel itself (so it is announced). */
1517
+ private focusPanel;
1518
+ /** The trigger's own control: a lof-button's inner <button>, or the trigger itself. */
1519
+ private triggerControl;
1520
+ protected willUpdateHasPopup(): void;
1521
+ protected updated(changed: Map<string, unknown>): void;
1522
+ /** Place the panel on `side`, aligned per `align`, clamped inside the viewport. */
1523
+ private reposition;
1524
+ render(): lit_html.TemplateResult<1>;
1525
+ }
1526
+ /** Optional styled surface for a popover's `content` slot. */
1527
+ declare class LofPopoverContent extends LofElement {
1528
+ static styles: lit.CSSResult[];
1529
+ ariaLabel: string;
1530
+ size: PopoverContentSize;
1531
+ protected willUpdate(changed: Map<string, unknown>): void;
1532
+ /** Focuses the role="dialog" box (the host itself is not focusable). */
1533
+ focus(options?: FocusOptions): void;
1534
+ render(): lit_html.TemplateResult<1>;
1535
+ }
1536
+ declare global {
1537
+ interface HTMLElementTagNameMap {
1538
+ "lof-popover": LofPopover;
1539
+ "lof-popover-content": LofPopoverContent;
1540
+ }
1541
+ }
1542
+
1543
+ type ProgressMode = "linear-determinate" | "linear-indeterminate" | "circular-determinate" | "circular-indeterminate";
1544
+ /**
1545
+ * Progress indicator: a 2px linear bar or a 36px ring, determinate (fills to
1546
+ * `value`, 0–100) or indeterminate (loops while you wait).
1547
+ */
1548
+ declare class LofProgress extends LofElement {
1549
+ static styles: lit.CSSResult;
1550
+ mode: ProgressMode;
1551
+ /** 0–100; clamped. Ignored by the indeterminate modes. */
1552
+ value: number;
1553
+ /** Accessible name; defaults to "Progress" (determinate) or "Loading" (indeterminate). */
1554
+ label: string;
1555
+ private get clamped();
1556
+ render(): lit_html.TemplateResult<1>;
1557
+ }
1558
+ declare global {
1559
+ interface HTMLElementTagNameMap {
1560
+ "lof-progress": LofProgress;
1561
+ }
1562
+ }
1563
+
1564
+ type RangePickerMode = "popover" | "popup";
1565
+ type RangePickerTrigger = "default" | "icon";
1566
+ type RangePickerSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
1567
+ /**
1568
+ * `<lof-range-picker>` — a typeable from → to field with a preset column, a
1569
+ * range grid and Reset / Cancel / Apply. Grid and presets edit a draft that
1570
+ * only Apply commits.
1571
+ */
1572
+ declare class LofRangePicker extends LofElement {
1573
+ static styles: lit.CSSResult[];
1574
+ from: string;
1575
+ to: string;
1576
+ locale: string;
1577
+ weekStart: "mon" | "sun";
1578
+ minDate: string;
1579
+ maxDate: string;
1580
+ disabled: boolean;
1581
+ open: boolean;
1582
+ mode: RangePickerMode;
1583
+ width: string;
1584
+ minWidth: string;
1585
+ maxWidth: string;
1586
+ height: string;
1587
+ minHeight: string;
1588
+ maxHeight: string;
1589
+ placeholder: string;
1590
+ triggerVariant: RangePickerTrigger;
1591
+ clearable: boolean;
1592
+ fullWidth: boolean;
1593
+ size: RangePickerSize;
1594
+ private draftStart;
1595
+ private draftEnd;
1596
+ private hover;
1597
+ private view;
1598
+ private panelView;
1599
+ private focusDate;
1600
+ private text;
1601
+ private typedError;
1602
+ private yearPageStart;
1603
+ /** Typed text and inline errors of the panel's From / To boxes. */
1604
+ private boxText;
1605
+ private boxError;
1606
+ /** After a pointer pick of the start day the To box is marked as the next field. */
1607
+ private nextTo;
1608
+ private input?;
1609
+ private panel;
1610
+ private overlay?;
1611
+ /** Formatted committed range: "MM/DD/YYYY → MM/DD/YYYY", one date, or "". */
1612
+ get displayLabel(): string;
1613
+ private get sizeClass();
1614
+ private get ws();
1615
+ private available;
1616
+ private inView;
1617
+ protected willUpdate(changed: PropertyValues): void;
1618
+ protected updated(changed: PropertyValues): void;
1619
+ disconnectedCallback(): void;
1620
+ private show;
1621
+ private hide;
1622
+ private detach;
1623
+ private position;
1624
+ private openPanel;
1625
+ /** Closing without Apply throws the draft away (Apply clears nothing: it has just committed it). */
1626
+ private closePanel;
1627
+ private onDocClick;
1628
+ /** An outside scroll moves the panel with its field; it closes once the field is hidden. */
1629
+ private onDocScroll;
1630
+ private onDocKey;
1631
+ private applyPreset;
1632
+ /** Commits a typed From / To box into the draft (Apply still commits the range). */
1633
+ private commitBox;
1634
+ private presetActive;
1635
+ private pickDay;
1636
+ private reset;
1637
+ private apply;
1638
+ private cancel;
1639
+ private commitTyped;
1640
+ private clearRange;
1641
+ private onInputKey;
1642
+ private onFocusOut;
1643
+ private setView;
1644
+ private onGridKey;
1645
+ private onPrev;
1646
+ private onNext;
1647
+ private focusLater;
1648
+ private togglePanelView;
1649
+ private renderTrigger;
1650
+ private rangeOf;
1651
+ private renderDays;
1652
+ private renderMonths;
1653
+ private renderYears;
1654
+ private renderBox;
1655
+ render(): lit_html.TemplateResult<1>;
1656
+ }
1657
+ declare global {
1658
+ interface HTMLElementTagNameMap {
1659
+ "lof-range-picker": LofRangePicker;
1660
+ }
1661
+ }
1662
+
1663
+ type ResizableOrientation = "horizontal" | "vertical";
1664
+ /**
1665
+ * `<lof-resizable-handle>` — the focusable splitter bar between two panels.
1666
+ * It only renders and announces; the parent group does the resizing.
1667
+ */
1668
+ declare class LofResizableHandle extends LofElement {
1669
+ static styles: lit.CSSResult;
1670
+ orientation: ResizableOrientation;
1671
+ private split;
1672
+ /** The leading panel's share of the pair it separates, 0–100; maintained by the group. */
1673
+ get splitValue(): number;
1674
+ /** @internal */
1675
+ applySplit(pct: number): void;
1676
+ connectedCallback(): void;
1677
+ protected updated(changed: PropertyValues): void;
1678
+ render(): lit_html.TemplateResult<1>;
1679
+ }
1680
+ declare global {
1681
+ interface HTMLElementTagNameMap {
1682
+ "lof-resizable-handle": LofResizableHandle;
1683
+ }
1684
+ }
1685
+
1686
+ type ResizableDirection = ResizableOrientation;
1687
+ /**
1688
+ * `<lof-resizable-group>` — a flex row (or column) of panels separated by
1689
+ * handles; dragging or arrow-keying a handle trades percentage size between
1690
+ * the two panels next to it.
1691
+ */
1692
+ declare class LofResizableGroup extends LofElement {
1693
+ static styles: lit.CSSResult;
1694
+ direction: ResizableDirection;
1695
+ private panels;
1696
+ private pairs;
1697
+ private sizes;
1698
+ private drag;
1699
+ constructor();
1700
+ protected firstUpdated(_changed: PropertyValues): void;
1701
+ /** Given sizes first; the rest share what is left; then everything is scaled to total 100. */
1702
+ private initialSizes;
1703
+ private apply;
1704
+ private detail;
1705
+ /**
1706
+ * Move `delta` percent from the trailing panel to the leading one: each side
1707
+ * is clamped to its own bounds, then the pair is rescaled to its old total.
1708
+ * A handle without two panels changes nothing.
1709
+ */
1710
+ private resize;
1711
+ private pairFor;
1712
+ private onPointerDown;
1713
+ private onPointerMove;
1714
+ private onPointerEnd;
1715
+ private onKeyDown;
1716
+ render(): lit_html.TemplateResult<1>;
1717
+ }
1718
+ declare global {
1719
+ interface HTMLElementTagNameMap {
1720
+ "lof-resizable-group": LofResizableGroup;
1721
+ }
1722
+ }
1723
+
1724
+ /**
1725
+ * `<lof-resizable-panel>` — one pane of a `<lof-resizable-group>`. Its size is
1726
+ * a percentage of the group, set by the group as the host's `flex-basis`.
1727
+ */
1728
+ declare class LofResizablePanel extends LofElement {
1729
+ static styles: lit.CSSResult;
1730
+ /** Starting share of the group, in percent (attribute `defaultsize`). */
1731
+ defaultSize?: number;
1732
+ /** Smallest share the panel can be dragged to, in percent (attribute `minsize`). */
1733
+ minSize: number;
1734
+ /** Largest share the panel can be dragged to, in percent (attribute `maxsize`). */
1735
+ maxSize: number;
1736
+ /** Accessible name while the content overflows (default "Panel N", by position). */
1737
+ panelLabel?: string;
1738
+ private size;
1739
+ private scrollable_;
1740
+ private owned;
1741
+ private resizeObs?;
1742
+ private mutationObs?;
1743
+ /** True while the content overflows the panel in either axis (read-only). */
1744
+ get scrollable(): boolean;
1745
+ connectedCallback(): void;
1746
+ disconnectedCallback(): void;
1747
+ protected updated(changed: Map<string, unknown>): void;
1748
+ private onFocusOut;
1749
+ private measure;
1750
+ private defaultLabel;
1751
+ private applyRegion;
1752
+ /** Current share of the group in percent; maintained by the group. */
1753
+ get currentSize(): number;
1754
+ /** @internal */
1755
+ applySize(pct: number): void;
1756
+ render(): lit_html.TemplateResult<1>;
1757
+ }
1758
+ declare global {
1759
+ interface HTMLElementTagNameMap {
1760
+ "lof-resizable-panel": LofResizablePanel;
1761
+ }
1762
+ }
1763
+
1764
+ interface SegmentOption {
1765
+ label: string;
1766
+ value: string;
1767
+ disabled?: boolean;
1768
+ icon?: string;
1769
+ badge?: number | string | boolean;
1770
+ }
1771
+ type SegmentSize = "small" | "medium" | "large";
1772
+ type SegmentAlign = "left" | "middle" | "right";
1773
+ /**
1774
+ * Single-select segmented control: native buttons with role="radio" inside a
1775
+ * radiogroup, one Tab stop, arrow keys move the selection.
1776
+ */
1777
+ declare class LofSegmentedButton extends LofElement {
1778
+ static styles: lit.CSSResult[];
1779
+ /** The segments in order. Property or JSON array attribute. */
1780
+ options: SegmentOption[];
1781
+ /** `value` of the selected segment. */
1782
+ active: string;
1783
+ size: SegmentSize;
1784
+ align: SegmentAlign;
1785
+ /** Accessible name of the radiogroup. */
1786
+ fieldAriaLabel?: string;
1787
+ /** Disables the whole group: click, keyboard and the Tab stop. Per-option `disabled` still works. */
1788
+ disabled: boolean;
1789
+ private get opts();
1790
+ private choose;
1791
+ private nextEnabled;
1792
+ private onKeydown;
1793
+ private renderBadge;
1794
+ render(): lit_html.TemplateResult<1>;
1795
+ }
1796
+ declare global {
1797
+ interface HTMLElementTagNameMap {
1798
+ "lof-segmented-button": LofSegmentedButton;
1799
+ }
1800
+ }
1801
+
1802
+ type ModalSide = "top" | "bottom" | "center";
1803
+ type ModalSize = "small" | "medium" | "large" | "extra-large" | "fullscreen" | "sm" | "md" | "lg" | "xl";
1804
+ type ModalVariant = "default" | "text";
1805
+ type ModalBreakpoint = "responsive" | "web";
1806
+ /**
1807
+ * Modal dialog / sheet: a panel anchored to the bottom, top or centre of the
1808
+ * viewport over a scrim, with a title/description header, a scrollable body,
1809
+ * an optional footer and a loading state.
1810
+ */
1811
+ declare class LofModal extends LofElement {
1812
+ static styles: lit.CSSResult;
1813
+ /** Whether the modal is shown. Every change fires `lof-open-change`. */
1814
+ open: boolean;
1815
+ side: ModalSide;
1816
+ /** Heading text. The host's `title` attribute is removed once read, so no tooltip appears. */
1817
+ title: string;
1818
+ description: string;
1819
+ /** Alias for `description`; shown only when `description` is empty. */
1820
+ subtitle: string;
1821
+ /** Coarse switch: when false there is no close button and backdrop / Escape are ignored. */
1822
+ dismissible: boolean;
1823
+ /** Scrim, dialog role, focus trap and initial focus. Off: a plain region. */
1824
+ modal: boolean;
1825
+ size: ModalSize;
1826
+ variant: ModalVariant;
1827
+ closeOnBackdropClick: boolean;
1828
+ closeOnEscape: boolean;
1829
+ showCloseButton: boolean;
1830
+ autoFocus: boolean;
1831
+ restoreFocus: boolean;
1832
+ scrollable: boolean;
1833
+ loading: boolean;
1834
+ disabled: boolean;
1835
+ zIndex: number;
1836
+ breakpoint: ModalBreakpoint;
1837
+ private panel;
1838
+ private contentEl;
1839
+ private locked;
1840
+ private opener;
1841
+ private stripping;
1842
+ private watch;
1843
+ private bodyOverflows;
1844
+ connectedCallback(): void;
1845
+ disconnectedCallback(): void;
1846
+ attributeChangedCallback(name: string, old: string | null, value: string | null): void;
1847
+ protected willUpdate(changed: Map<string, unknown>): void;
1848
+ protected firstUpdated(): void;
1849
+ protected updated(changed: Map<string, unknown>): void;
1850
+ private setLocked;
1851
+ private onBodyOverflow;
1852
+ private syncBodyScrolls;
1853
+ private tabbables;
1854
+ /** As in 1.4.9, the first focusable is picked without regard to `inert`: when
1855
+ * it sits in an inert region (loading, or a disabled footer) the focus call
1856
+ * is a no-op and focus stays where it was. */
1857
+ private focusOnOpen;
1858
+ private returnFocus;
1859
+ private requestClose;
1860
+ private onDocKeydown;
1861
+ private trapTab;
1862
+ private onOverlayClick;
1863
+ private onCloseClick;
1864
+ private onFooterSlotChange;
1865
+ render(): lit_html.TemplateResult<1>;
1866
+ }
1867
+ declare global {
1868
+ interface HTMLElementTagNameMap {
1869
+ "lof-modal": LofModal;
1870
+ }
1871
+ }
1872
+
1873
+ type SignaturePadMode = "draw" | "type";
1874
+ /** One stroke: points are `[x, y, t, pressure]` in CSS pixels of the pad; `t` is epoch ms. */
1875
+ interface SignatureStroke {
1876
+ points: [number, number, number, number][];
1877
+ pointerType?: string;
1878
+ }
1879
+ interface SignaturePadChangeDetail {
1880
+ value: string;
1881
+ strokes: SignatureStroke[];
1882
+ signedAt: string;
1883
+ mode: SignaturePadMode;
1884
+ }
1885
+ /**
1886
+ * `<lof-signature-pad>` (new in 1.5.0): a signature field. Sign with a mouse, pen or
1887
+ * finger, or type a name (the keyboard alternative). `value` is a trimmed PNG data URL
1888
+ * (2×, black ink) and the form value; `strokes` and `toSVG()` give the vectors.
1889
+ */
1890
+ declare class LofSignaturePad extends LofElement {
1891
+ static formAssociated: boolean;
1892
+ static styles: lit.CSSResult[];
1893
+ label?: string;
1894
+ required: boolean;
1895
+ helperText?: string;
1896
+ disabledText?: string;
1897
+ error: boolean;
1898
+ errorMessage?: string;
1899
+ disabled: boolean;
1900
+ readonly: boolean;
1901
+ placeholder: string;
1902
+ name?: string;
1903
+ fieldAriaLabel?: string;
1904
+ /** draw (default) or type. */
1905
+ mode: SignaturePadMode;
1906
+ /** The name typed in type mode. */
1907
+ typedName: string;
1908
+ private strokes_;
1909
+ /** A stored signature image (from `value`) in draw mode. */
1910
+ private stored;
1911
+ private signedAtDraw;
1912
+ private typedAt;
1913
+ private drawing;
1914
+ private formDisabled;
1915
+ private undoStack;
1916
+ private value_;
1917
+ private canvas?;
1918
+ private pad?;
1919
+ private typedInput?;
1920
+ private internals?;
1921
+ private baseWidth;
1922
+ private current;
1923
+ private storedImg?;
1924
+ private ro?;
1925
+ private silent;
1926
+ constructor();
1927
+ /** `value` is also read from the attribute, for static markup. */
1928
+ static get observedAttributes(): string[];
1929
+ attributeChangedCallback(name: string, old: string | null, value: string | null): void;
1930
+ /** The signature as a PNG data URL, trimmed to the ink at 2× with black ink; "" when empty. */
1931
+ get value(): string;
1932
+ set value(v: string);
1933
+ /** The vector record of the signature. Setting it redraws and starts a new Undo history. */
1934
+ get strokes(): SignatureStroke[];
1935
+ set strokes(v: SignatureStroke[]);
1936
+ /** When the signature was started (ISO 8601); "" while empty. */
1937
+ get signedAt(): string;
1938
+ isEmpty(): boolean;
1939
+ /** Removes the last stroke, or restores what Clear removed. No lof-change. */
1940
+ undo(): void;
1941
+ /** Removes the whole signature of the active mode; Undo brings it back. No lof-change. */
1942
+ clear(): void;
1943
+ /** The signature as a data URL: image/png (default), image/jpeg (white background) or image/svg+xml. */
1944
+ toDataURL(type?: string): string;
1945
+ /** The signature as an SVG document string, black and trimmed; "" when empty. */
1946
+ toSVG(): string;
1947
+ formDisabledCallback(disabled: boolean): void;
1948
+ formResetCallback(): void;
1949
+ formStateRestoreCallback(state: string | File | FormData | null): void;
1950
+ private get isDisabled();
1951
+ private syncForm;
1952
+ private refreshValue;
1953
+ private loadStored;
1954
+ /** Where a stored image sits in the pad's coordinate space (its 2× pixels at 1×). */
1955
+ private storedRect;
1956
+ private inkBounds;
1957
+ private typeBox;
1958
+ private renderExport;
1959
+ private draw;
1960
+ private point;
1961
+ private onDown;
1962
+ private onMove;
1963
+ private onUp;
1964
+ /** lof-change: user actions only. */
1965
+ private changed;
1966
+ private userUndo;
1967
+ private userClear;
1968
+ /** When Undo or Clear disables itself, focus moves to the pad. */
1969
+ private keepFocus;
1970
+ private onKeydown;
1971
+ private switchMode;
1972
+ private onTypedInput;
1973
+ connectedCallback(): void;
1974
+ disconnectedCallback(): void;
1975
+ protected updated(changed: PropertyValues): void;
1976
+ private signedText;
1977
+ render(): lit_html.TemplateResult<1>;
1978
+ }
1979
+ declare global {
1980
+ interface HTMLElementTagNameMap {
1981
+ "lof-signature-pad": LofSignaturePad;
1982
+ }
1983
+ }
1984
+
1985
+ type SkeletonShape = "line" | "circle" | "block";
1986
+ type SkeletonAnimation = "pulse" | "shimmer" | "none";
1987
+ /**
1988
+ * Loading placeholder that keeps the space of content still being fetched.
1989
+ * Hides itself once `loaded` is set.
1990
+ */
1991
+ declare class LofSkeleton extends LofElement {
1992
+ static styles: lit.CSSResult;
1993
+ shape: SkeletonShape;
1994
+ /** Bars drawn when shape="line" (minimum 1). */
1995
+ lines: number;
1996
+ /** Any CSS width, written to the host's inline style. */
1997
+ width: string;
1998
+ /** Any CSS height, written to the host's inline style. */
1999
+ height: string;
2000
+ animation: SkeletonAnimation;
2001
+ /** Hides the placeholder and drops its loading semantics. */
2002
+ loaded: boolean;
2003
+ protected updated(changed: Map<string, unknown>): void;
2004
+ render(): lit_html.TemplateResult<1>;
2005
+ }
2006
+ declare global {
2007
+ interface HTMLElementTagNameMap {
2008
+ "lof-skeleton": LofSkeleton;
2009
+ }
2010
+ }
2011
+
2012
+ type SliderType = "continuous" | "discrete" | "default" | "range";
2013
+ type SliderSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
2014
+ type SliderTrack = "solid" | "dotted";
2015
+ /**
2016
+ * Slider on native range inputs: a pill track, a stroked round thumb, an
2017
+ * optional value bubble, tick marks and a dual-thumb range mode.
2018
+ */
2019
+ declare class LofSlider extends LofElement {
2020
+ static styles: lit.CSSResult[];
2021
+ type: SliderType;
2022
+ /** Tick marks on any type; unset follows type="discrete". */
2023
+ showTicks?: boolean;
2024
+ size: SliderSize;
2025
+ min: number;
2026
+ max: number;
2027
+ step: number;
2028
+ disabled: boolean;
2029
+ track: SliderTrack;
2030
+ showTickLabels: boolean;
2031
+ showBubble: boolean;
2032
+ value: number;
2033
+ valueEnd: number;
2034
+ fieldAriaLabel?: string;
2035
+ private hoverThumb;
2036
+ private activeThumb;
2037
+ private focusThumb;
2038
+ private dragging;
2039
+ protected willUpdate(changed: Map<string, unknown>): void;
2040
+ private get isRange();
2041
+ private get isDiscrete();
2042
+ private pct;
2043
+ private ticks;
2044
+ private onInput;
2045
+ private fire;
2046
+ private valueAt;
2047
+ private onPointerDown;
2048
+ private onPointerMove;
2049
+ private onPointerUp;
2050
+ private moveTo;
2051
+ private setState;
2052
+ private input;
2053
+ private thumb;
2054
+ render(): lit_html.TemplateResult<1>;
2055
+ }
2056
+ declare global {
2057
+ interface HTMLElementTagNameMap {
2058
+ "lof-slider": LofSlider;
2059
+ }
2060
+ }
2061
+
2062
+ type SnackbarTone = "neutral" | "success" | "warning" | "destructive";
2063
+ type SnackbarToneInput = SnackbarTone | "default" | "error" | "danger" | "critical";
2064
+ type SnackbarVariant = "default" | "longer-action";
2065
+ /**
2066
+ * `<lof-snackbar>` — an in-flow dark message bar shown by setting `show`;
2067
+ * it hides itself after `duration` ms.
2068
+ */
2069
+ declare class LofSnackbar extends LofElement {
2070
+ static styles: lit.CSSResult[];
2071
+ message: string;
2072
+ action?: string;
2073
+ variant?: SnackbarVariant;
2074
+ /** @deprecated use `variant="longer-action"`. */
2075
+ longerAction: boolean;
2076
+ iconClose: boolean;
2077
+ /** @deprecated use `variant`. */
2078
+ lines?: "single" | "double";
2079
+ duration: number;
2080
+ tone?: SnackbarToneInput;
2081
+ /** @deprecated use `tone`. */
2082
+ type?: SnackbarToneInput;
2083
+ show: boolean;
2084
+ private timer?;
2085
+ /** Canonical layout actually rendered. */
2086
+ get resolvedVariant(): SnackbarVariant;
2087
+ /** Canonical tone actually rendered after alias resolution. */
2088
+ get resolvedTone(): SnackbarTone;
2089
+ private get stacked();
2090
+ private get delay();
2091
+ protected willUpdate(changed: PropertyValues): void;
2092
+ protected updated(changed: PropertyValues): void;
2093
+ disconnectedCallback(): void;
2094
+ private arm;
2095
+ private dismiss;
2096
+ private onAction;
2097
+ render(): lit_html.TemplateResult<1>;
2098
+ }
2099
+ declare global {
2100
+ interface HTMLElementTagNameMap {
2101
+ "lof-snackbar": LofSnackbar;
2102
+ }
2103
+ }
2104
+
2105
+ interface SplitButtonItem {
2106
+ value: string;
2107
+ label: string;
2108
+ icon?: string;
2109
+ disabled?: boolean;
2110
+ }
2111
+ type SplitButtonVariant = "primary" | "secondary" | "ghost" | "static";
2112
+ type SplitButtonTone = "neutral" | "brand" | "destructive";
2113
+ type SplitButtonSize = "small" | "medium" | "large";
2114
+ interface SplitButtonSelectDetail {
2115
+ value: string;
2116
+ item: SplitButtonItem;
2117
+ }
2118
+ /**
2119
+ * `<lof-split-button>` (new in 1.5.0, the Combo Button): a main action and a chevron
2120
+ * that opens a `lof-menu` of related actions, in one pill. Both segments are
2121
+ * `lof-button`s, so variant, tone, size, hover, pressed, focus and disabled match
2122
+ * lof-button exactly; the outer corners keep the pill radius and the seam is square.
2123
+ * The host's `click` is the main action.
2124
+ */
2125
+ declare class LofSplitButton extends LofElement {
2126
+ static styles: lit.CSSResult[];
2127
+ /** Text of the main action; slotted content replaces it. */
2128
+ label: string;
2129
+ /** primary | secondary (default) | ghost | static, as lof-button. */
2130
+ variant: SplitButtonVariant;
2131
+ /** neutral (default) | brand | destructive, as lof-button. */
2132
+ tone: SplitButtonTone;
2133
+ /** small (32px) | medium (40px) | large (48px). */
2134
+ size: SplitButtonSize;
2135
+ disabled: boolean;
2136
+ /** Spinner only on the main action (its text stays its name); the chevron is disabled. */
2137
+ loading: boolean;
2138
+ /** The main action is a square; set aria-label. */
2139
+ iconOnly: boolean;
2140
+ /** Accessible name of the main action. */
2141
+ ariaLabel: string | null;
2142
+ /** Accessible name of the chevron. */
2143
+ menuLabel: string;
2144
+ /** lof-icon name drawn before the main action's text. */
2145
+ icon: string;
2146
+ /** Menu entries: { value, label, icon?, disabled? }. */
2147
+ items: SplitButtonItem[];
2148
+ /** Whether the menu is open. */
2149
+ open: boolean;
2150
+ private pop;
2151
+ private menu;
2152
+ private toggleEl;
2153
+ /** How the menu was opened: a pointer shows no rings. */
2154
+ private via;
2155
+ private startAt;
2156
+ private hovered;
2157
+ private pressedMain;
2158
+ private get list();
2159
+ private get canOpen();
2160
+ protected willUpdate(changed: PropertyValues): void;
2161
+ connectedCallback(): void;
2162
+ disconnectedCallback(): void;
2163
+ private onDocPointer;
2164
+ private setOpen;
2165
+ /** The menu sits below the pill, end-aligned and at least as wide. */
2166
+ private place;
2167
+ protected updated(changed: PropertyValues): void;
2168
+ private onToggleClick;
2169
+ private onTogglePointer;
2170
+ private onToggleKey;
2171
+ private onMenuKey;
2172
+ private onMenuSelect;
2173
+ private get menuItems();
2174
+ private setActive;
2175
+ render(): lit_html.TemplateResult<1>;
2176
+ }
2177
+ declare global {
2178
+ interface HTMLElementTagNameMap {
2179
+ "lof-split-button": LofSplitButton;
2180
+ }
2181
+ }
2182
+
2183
+ type StepStatus = "done" | "progress" | "disabled";
2184
+ interface Step {
2185
+ title: string;
2186
+ subtitle?: string;
2187
+ status: StepStatus;
2188
+ }
2189
+ type StepperType = "default" | "dot" | "number" | "icon";
2190
+ type StepperConnector = "solid" | "dot";
2191
+ type LabelPlacement = "top" | "centered" | "inverted";
2192
+ type StepperOrientation = "horizontal" | "vertical";
2193
+ /**
2194
+ * Multi-step progress indicator. Presentation only: activating a step emits
2195
+ * lof-step-change and the host app updates `steps`.
2196
+ */
2197
+ declare class LofStepper extends LofElement {
2198
+ static styles: lit.CSSResult[];
2199
+ /** `{ title, subtitle?, status }[]`. Property or JSON array attribute. */
2200
+ steps: Step[];
2201
+ /** @deprecated use label-placement (right → centered, below → inverted). */
2202
+ textAlign?: "right" | "below";
2203
+ orientation: StepperOrientation;
2204
+ /** @deprecated Figma has no Size axis on the Stepper. */
2205
+ size?: "small" | "large";
2206
+ type: StepperType;
2207
+ connector: StepperConnector;
2208
+ labelPlacement?: LabelPlacement;
2209
+ protected willUpdate(changed: Map<string, unknown>): void;
2210
+ private get layout();
2211
+ private get list();
2212
+ private activate;
2213
+ private onKeydown;
2214
+ private indicatorContent;
2215
+ render(): lit_html.TemplateResult<1>;
2216
+ }
2217
+ declare global {
2218
+ interface HTMLElementTagNameMap {
2219
+ "lof-stepper": LofStepper;
2220
+ }
2221
+ }
2222
+
2223
+ type SwitchType = "line" | "pill";
2224
+ type SwitchLabelPlacement = "end" | "start";
2225
+ type SwitchSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
2226
+ /**
2227
+ * Toggle switch wrapping a native checkbox with role="switch".
2228
+ * Geometry per size: handle = control height (line), width = 2 × height + 4,
2229
+ * rail = height / 2, travel = width − 4 − handle. Pill is 4px taller.
2230
+ */
2231
+ declare class LofSwitch extends LofElement {
2232
+ static styles: lit.CSSResult[];
2233
+ checked: boolean;
2234
+ /** line (default): thin rail with the handle riding on it. pill: filled track. */
2235
+ type: SwitchType;
2236
+ disabled: boolean;
2237
+ /** Echoed in the lof-change detail. */
2238
+ value: string;
2239
+ /** Accessible name when there is no visible label. */
2240
+ fieldAriaLabel?: string;
2241
+ /** Visible text beside the control; also becomes the accessible name. */
2242
+ label?: string;
2243
+ labelPlacement: SwitchLabelPlacement;
2244
+ size: SwitchSize;
2245
+ private hasSlotted;
2246
+ private pressed;
2247
+ static formAssociated: boolean;
2248
+ private form;
2249
+ formDisabledCallback(disabled: boolean): void;
2250
+ private onDown;
2251
+ protected willUpdate(changed: Map<string, unknown>): void;
2252
+ /** Unlike lof-checkbox, 1.4.9's switch reports on the native change event,
2253
+ * so lof-change follows click and input. */
2254
+ private onInputChange;
2255
+ private onSlotChange;
2256
+ render(): lit_html.TemplateResult<1>;
2257
+ }
2258
+ declare global {
2259
+ interface HTMLElementTagNameMap {
2260
+ "lof-switch": LofSwitch;
2261
+ }
2262
+ }
2263
+
2264
+ interface TabItem {
2265
+ label: string;
2266
+ icon?: string;
2267
+ value?: string;
2268
+ badge?: number;
2269
+ badgeDot?: boolean;
2270
+ disabled?: boolean;
2271
+ }
2272
+ type TabSize = "sm" | "md" | "lg" | "small" | "medium" | "large";
2273
+ type TabOrientation = "horizontal" | "vertical";
2274
+ type TabIconPlacement = "start" | "top";
2275
+ /**
2276
+ * Declares one tab for a parent <lof-tab>. Renders nothing itself; the parent
2277
+ * reads its properties when the `items` slot changes.
2278
+ */
2279
+ declare class LofTabItem extends LofElement {
2280
+ label: string;
2281
+ /** lof-icon name drawn before the label. */
2282
+ icon: string;
2283
+ /** Not read by <lof-tab>; look it up from the item at event.detail. */
2284
+ value: string;
2285
+ /** Count badge; 0 hides it. */
2286
+ badge: number;
2287
+ /** Dot badge; wins over `badge`. */
2288
+ badgeDot: boolean;
2289
+ disabled: boolean;
2290
+ /** Tells the parent <lof-tab> to re-read the items (a live badge, a tab enabled later). */
2291
+ protected updated(changed: Map<string, unknown>): void;
2292
+ render(): symbol;
2293
+ }
2294
+ /**
2295
+ * Underline tab strip with roving tabindex and a single shared tabpanel
2296
+ * (the default slot) under it.
2297
+ */
2298
+ declare class LofTab extends LofElement {
2299
+ static styles: lit.CSSResult[];
2300
+ /** Tab definitions; ignored when <lof-tab-item> children fill the `items` slot. */
2301
+ tabs: TabItem[];
2302
+ activeIndex: number;
2303
+ size: TabSize;
2304
+ /** horizontal (a row above the panel) or vertical (a column beside it; Up / Down move). */
2305
+ orientation: TabOrientation;
2306
+ /** start (icon before the label) or top (stacked above it). */
2307
+ iconPlacement: TabIconPlacement;
2308
+ connectedCallback(): void;
2309
+ disconnectedCallback(): void;
2310
+ private slotted;
2311
+ private readonly ids;
2312
+ private get items();
2313
+ private readItems;
2314
+ private onItemsSlot;
2315
+ private select;
2316
+ private tabEl;
2317
+ private step;
2318
+ private onKeydown;
2319
+ private renderBadge;
2320
+ render(): lit_html.TemplateResult<1>;
2321
+ }
2322
+ declare global {
2323
+ interface HTMLElementTagNameMap {
2324
+ "lof-tab": LofTab;
2325
+ "lof-tab-item": LofTabItem;
2326
+ }
2327
+ }
2328
+
2329
+ type TimePickerSize = "small" | "medium" | "large";
2330
+ type TimeFormat = "12h" | "24h";
2331
+ /**
2332
+ * `<lof-time-picker>` — a typeable time field with Hour / Minute (/ Second /
2333
+ * AM-PM) columns. Column picks are a draft until OK.
2334
+ */
2335
+ declare class LofTimePicker extends LofElement {
2336
+ static styles: lit.CSSResult[];
2337
+ value: string | null;
2338
+ placeholder: string;
2339
+ label: string | null;
2340
+ disabled: boolean;
2341
+ required: boolean;
2342
+ readonly: boolean;
2343
+ format: TimeFormat;
2344
+ seconds: boolean;
2345
+ minuteStep: number;
2346
+ minTime: string | null;
2347
+ maxTime: string | null;
2348
+ open: boolean;
2349
+ clearable: boolean;
2350
+ error: boolean;
2351
+ invalid: boolean;
2352
+ errorMessage?: string;
2353
+ helperText?: string;
2354
+ name?: string;
2355
+ size: TimePickerSize;
2356
+ variant: "outlined";
2357
+ fullWidth: boolean;
2358
+ private draft;
2359
+ private text;
2360
+ private typedError;
2361
+ private input;
2362
+ private panel;
2363
+ private openedByUser;
2364
+ private focusOnOpen;
2365
+ private get step();
2366
+ private get is12();
2367
+ private get sizeClass();
2368
+ private get minM();
2369
+ private get maxM();
2370
+ private inRange;
2371
+ private minutesFor;
2372
+ private hourEnabled;
2373
+ private display;
2374
+ private toValue;
2375
+ protected willUpdate(changed: PropertyValues): void;
2376
+ protected updated(changed: PropertyValues): void;
2377
+ disconnectedCallback(): void;
2378
+ private detach;
2379
+ private resetDraft;
2380
+ private position;
2381
+ /** Scroll each column so its selected entry sits in the middle. */
2382
+ private centerSelected;
2383
+ private focusHour;
2384
+ private setOpen;
2385
+ private onDocClick;
2386
+ /** An outside scroll moves the panel with its field; it closes once the field is hidden. */
2387
+ private onDocScroll;
2388
+ private onDocKey;
2389
+ private commit;
2390
+ private now;
2391
+ /** The current time clamped into min / max (the N shortcut and typed "n"). */
2392
+ private clampedNow;
2393
+ private commitNow;
2394
+ private applyDraft;
2395
+ private draftNow;
2396
+ private snapMinute;
2397
+ private commitTyped;
2398
+ private clear;
2399
+ private pickHour;
2400
+ private pickMinute;
2401
+ private pickSecond;
2402
+ private pickPeriod;
2403
+ private firstEnabledHour;
2404
+ private onFieldClick;
2405
+ private onInputKey;
2406
+ private onFocusOut;
2407
+ private onPanelKey;
2408
+ private onColumnKey;
2409
+ private column;
2410
+ private renderColumns;
2411
+ render(): lit_html.TemplateResult<1>;
2412
+ }
2413
+ declare global {
2414
+ interface HTMLElementTagNameMap {
2415
+ "lof-time-picker": LofTimePicker;
2416
+ }
2417
+ }
2418
+
2419
+ type ToastTone = "neutral" | "destructive" | "success" | "info";
2420
+ type ToastToneInput = ToastTone | "default" | "error" | "danger" | "critical";
2421
+ type ToastPosition = "top-left" | "top-center" | "top-right" | "bottom-left" | "bottom-center" | "bottom-right";
2422
+ type ToastSize = "small" | "medium" | "large" | "sm" | "md" | "lg";
2423
+ /**
2424
+ * `<lof-toast>` — a transient card pinned to a viewport edge, shown with
2425
+ * `show` / `open()` and hidden after `duration` ms.
2426
+ */
2427
+ declare class LofToast extends LofElement {
2428
+ static styles: lit.CSSResult[];
2429
+ message: string;
2430
+ tone?: ToastToneInput;
2431
+ /** @deprecated use `tone`. */
2432
+ type?: ToastToneInput;
2433
+ actionLabel?: string;
2434
+ duration: number;
2435
+ show: boolean;
2436
+ dismissible: boolean;
2437
+ position: ToastPosition;
2438
+ size: ToastSize;
2439
+ maxVisible: number;
2440
+ /** Whether this toast currently has a slot in its stack (queued toasts wait). */
2441
+ private onScreen;
2442
+ private timer?;
2443
+ private joined;
2444
+ /** Canonical tone actually rendered after alias resolution. */
2445
+ get resolvedTone(): ToastTone;
2446
+ open(): void;
2447
+ close(): void;
2448
+ /** @internal */
2449
+ setOnScreen(on: boolean): void;
2450
+ /** @internal */
2451
+ setStackOffset(px: number | null): void;
2452
+ /** @internal */
2453
+ cardHeight(): number;
2454
+ private join;
2455
+ private leave;
2456
+ private startTimer;
2457
+ protected willUpdate(changed: PropertyValues): void;
2458
+ protected updated(changed: PropertyValues): void;
2459
+ connectedCallback(): void;
2460
+ disconnectedCallback(): void;
2461
+ private onAction;
2462
+ render(): lit_html.TemplateResult<1>;
2463
+ }
2464
+ declare global {
2465
+ interface HTMLElementTagNameMap {
2466
+ "lof-toast": LofToast;
2467
+ }
2468
+ }
2469
+
2470
+ type TooltipPosition = "above" | "below" | "left" | "right";
2471
+ type TooltipType = "single-line" | "multi-line";
2472
+ type TooltipTone = "inverse" | "neutral";
2473
+ /**
2474
+ * Hover / focus hint: wraps one trigger and fades in a short text bubble on
2475
+ * one side of it. No collision detection; the bubble never takes focus.
2476
+ */
2477
+ declare class LofTooltip extends LofElement {
2478
+ static styles: lit.CSSResult;
2479
+ /** Plain-text content of the bubble. */
2480
+ text: string;
2481
+ position: TooltipPosition;
2482
+ showTail: boolean;
2483
+ type: TooltipType;
2484
+ tone: TooltipTone;
2485
+ private dismissed;
2486
+ private readonly bubbleId;
2487
+ private hovered;
2488
+ /** Elements given our text as aria-description (the trigger and its focused control). */
2489
+ private described;
2490
+ connectedCallback(): void;
2491
+ disconnectedCallback(): void;
2492
+ /**
2493
+ * Escape hides the bubble (WCAG 1.4.13) while it is shown by hover or focus, wherever
2494
+ * focus is; it is not swallowed, so an enclosing dialog also receives it.
2495
+ */
2496
+ private onDocKeydown;
2497
+ private onEnter;
2498
+ private onLeave;
2499
+ private reset;
2500
+ /** The text reaches screen readers as the focused control's description. */
2501
+ private onFocusIn;
2502
+ private describe;
2503
+ protected updated(changed: Map<string, unknown>): void;
2504
+ private onSlotChange;
2505
+ render(): lit_html.TemplateResult<1>;
2506
+ }
2507
+ declare global {
2508
+ interface HTMLElementTagNameMap {
2509
+ "lof-tooltip": LofTooltip;
2510
+ }
2511
+ }
2512
+
2513
+ interface TreeItem {
2514
+ value: string;
2515
+ label: string;
2516
+ icon?: string;
2517
+ children?: TreeItem[];
2518
+ expanded?: boolean;
2519
+ disabled?: boolean;
2520
+ /** Has children that load on first expand (`lof-load-children`). */
2521
+ lazy?: boolean;
2522
+ }
2523
+ type TreeSelection = "single" | "multiple" | "none";
2524
+ /**
2525
+ * `<lof-tree>` (new in 1.5.0, Figma "Nested Tree"): a hierarchical list whose parents
2526
+ * expand and collapse, with hierarchy guides, single / multiple (cascading
2527
+ * checkboxes) / no selection, lazy children and the WAI-ARIA tree keyboard.
2528
+ */
2529
+ declare class LofTree extends LofElement {
2530
+ static styles: lit.CSSResult[];
2531
+ /** The items: `{ value, label, icon?, children?, expanded?, disabled?, lazy? }`. */
2532
+ items: TreeItem[];
2533
+ /** single (default) | multiple (cascading checkboxes) | none (navigation only). */
2534
+ selection: TreeSelection;
2535
+ /** Selected value in single mode. */
2536
+ selected: string;
2537
+ /** Checked values in multiple mode, parents included (normalised on set). */
2538
+ selectedValues: string[];
2539
+ /** Values of the expanded parents. */
2540
+ expandedValues: string[];
2541
+ /** Draws the hierarchy guides; `show-guides="false"` keeps only the indentation. */
2542
+ showGuides: boolean;
2543
+ /** Accessible name of the tree. */
2544
+ fieldAriaLabel?: string;
2545
+ /** The row holding the roving Tab stop. */
2546
+ private focusValue;
2547
+ private seenExpanded;
2548
+ private loading;
2549
+ private typeBuf;
2550
+ private typeTimer?;
2551
+ private get list();
2552
+ private walk;
2553
+ private find;
2554
+ private descendants;
2555
+ /** Visible rows, in order. */
2556
+ private rows;
2557
+ /** Cascades a set of checked values: parents check their subtree; parents follow their children. */
2558
+ private normalise;
2559
+ private checkState;
2560
+ protected willUpdate(changed: PropertyValues): void;
2561
+ private requestChildren;
2562
+ /** Expands every parent with children (unloaded lazy items stay closed). */
2563
+ expandAll(): void;
2564
+ /** Collapses every parent. */
2565
+ collapseAll(): void;
2566
+ private setExpanded;
2567
+ private activate;
2568
+ private focusRow;
2569
+ private onClick;
2570
+ private onKeydown;
2571
+ private renderCheck;
2572
+ private renderItem;
2573
+ render(): TemplateResult<1>;
2574
+ }
2575
+ declare global {
2576
+ interface HTMLElementTagNameMap {
2577
+ "lof-tree": LofTree;
2578
+ }
2579
+ }
2580
+
2581
+ type UploadStatus = "ready" | "uploading" | "success" | "error";
2582
+ type UploadPhase = "empty" | "selected" | "uploading" | "delayed" | "failed";
2583
+ interface UploadFile {
2584
+ id: string;
2585
+ name: string;
2586
+ size: number;
2587
+ status: UploadStatus;
2588
+ file?: File;
2589
+ progress?: number;
2590
+ loaded?: number;
2591
+ error?: string;
2592
+ }
2593
+ interface UploadRejection {
2594
+ name: string;
2595
+ reason: "format" | "size" | "count";
2596
+ message: string;
2597
+ }
2598
+ /** `lof-upload-complete` detail: this batch's rows. */
2599
+ interface UploadCompleteDetail {
2600
+ succeeded: UploadFile[];
2601
+ failed: UploadFile[];
2602
+ }
2603
+ /** `lof-file-replaced` detail. */
2604
+ interface FileReplacedDetail {
2605
+ name: string;
2606
+ previous: UploadFile;
2607
+ next: UploadFile;
2608
+ }
2609
+ interface UploaderContext {
2610
+ file: File;
2611
+ signal: AbortSignal;
2612
+ onProgress: (loaded: number, total?: number) => void;
2613
+ }
2614
+ type Uploader = (file: File, ctx: UploaderContext) => Promise<void>;
2615
+ interface UploadState {
2616
+ phase: UploadPhase;
2617
+ total: number;
2618
+ failed: number;
2619
+ canUpload: boolean;
2620
+ primaryLabel: string;
2621
+ }
2622
+ /**
2623
+ * `<lof-upload>` — dropzone, hint, status alert and per-file rows. Without an
2624
+ * `uploader` it only emits intents; with one it runs the batch itself.
2625
+ */
2626
+ declare class LofUpload extends LofElement {
2627
+ static styles: lit.CSSResult[];
2628
+ accept: string;
2629
+ maxSize: string;
2630
+ multiple: boolean;
2631
+ disabled: boolean;
2632
+ hint: string;
2633
+ dropzoneTitle: string;
2634
+ browseLabel: string;
2635
+ files: UploadFile[];
2636
+ uploader?: Uploader;
2637
+ concurrency: number;
2638
+ delayThreshold: number;
2639
+ /** With `multiple`, the most files the list may hold; 0 = no limit. */
2640
+ maxFiles: number;
2641
+ private dragging;
2642
+ private delayed;
2643
+ /** The last settled batch, for the success alert. */
2644
+ private settled;
2645
+ /** Names replaced by the last pick, for the info notice. */
2646
+ private replacedNames;
2647
+ /** Rows rejected by accept / max-size / max-files: they hold no place in the limit. */
2648
+ private rejectedIds;
2649
+ /** Rows of the batch in flight (both modes). */
2650
+ private batch;
2651
+ private previews;
2652
+ private brokenPreviews;
2653
+ private input;
2654
+ private controllers;
2655
+ private cancelled;
2656
+ private delayTimer?;
2657
+ private lastState;
2658
+ private lastHeading;
2659
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject | null, options?: boolean | AddEventListenerOptions): void;
2660
+ private get list();
2661
+ private get failedFiles();
2662
+ private get inFlight();
2663
+ /** Aggregate state, matching the Figma modal variants. */
2664
+ get phase(): UploadPhase;
2665
+ private retryable;
2666
+ get canUpload(): boolean;
2667
+ get primaryLabel(): string;
2668
+ get state(): UploadState;
2669
+ private get hintText();
2670
+ /** Returns a rejection reason, or null when the file passes accept / max-size. */
2671
+ private validate;
2672
+ private get limit();
2673
+ private countRejection;
2674
+ private addFiles;
2675
+ private patch;
2676
+ /** Emit `lof-state` right away when the derived snapshot changed (de-duplicated). */
2677
+ private syncState;
2678
+ /** Start (or resume) the batch: emits `lof-upload`, and runs it when `uploader` is set. */
2679
+ upload(): void;
2680
+ /** Re-queue every retryable failed row and send again. */
2681
+ retry(): void;
2682
+ /** Abort anything in flight and emit `lof-cancel`; the list is kept. */
2683
+ cancel(): void;
2684
+ /** Remove one row by id. */
2685
+ removeFile(id: string): void;
2686
+ /** Clear everything and abort in-flight transfers. */
2687
+ reset(): void;
2688
+ private run;
2689
+ /** Fires lof-upload-complete for the rows of the batch that just settled. */
2690
+ private finishBatch;
2691
+ private sendOne;
2692
+ private startDelay;
2693
+ private stopDelay;
2694
+ connectedCallback(): void;
2695
+ disconnectedCallback(): void;
2696
+ protected willUpdate(changed: PropertyValues): void;
2697
+ private previewOf;
2698
+ protected updated(_changed: PropertyValues): void;
2699
+ private openPicker;
2700
+ private onPicked;
2701
+ private onDragOver;
2702
+ private onDrop;
2703
+ private heading;
2704
+ private meta;
2705
+ private renderAlert;
2706
+ render(): lit_html.TemplateResult<1>;
2707
+ }
2708
+ /**
2709
+ * `<lof-upload-actions>` — the Cancel / Upload (or Retry) footer for a
2710
+ * `<lof-upload>`, kept separate so it can sit in a modal footer.
2711
+ */
2712
+ declare class LofUploadActions extends LofElement {
2713
+ static styles: lit.CSSResult[];
2714
+ for: string;
2715
+ cancelLabel: string;
2716
+ noCancel: boolean;
2717
+ private snapshot;
2718
+ private root;
2719
+ private get target();
2720
+ private onState;
2721
+ connectedCallback(): void;
2722
+ disconnectedCallback(): void;
2723
+ private onCancel;
2724
+ private onPrimary;
2725
+ render(): lit_html.TemplateResult<1>;
2726
+ }
2727
+ declare global {
2728
+ interface HTMLElementTagNameMap {
2729
+ "lof-upload": LofUpload;
2730
+ "lof-upload-actions": LofUploadActions;
2731
+ }
2732
+ }
2733
+
2734
+ /** A cell's place in the grid: zero-based row and column. */
2735
+ interface GridPosition {
2736
+ row: number;
2737
+ col: number;
2738
+ }
2739
+ interface GridNavigationOptions {
2740
+ /** Selector for the rows inside the grid. Default `'[role="row"]'`. */
2741
+ rowSelector?: string;
2742
+ /** Selector for the cells inside a row, in DOM order. Default `'[role="gridcell"]'`. Rows without cells are not part of the grid. */
2743
+ cellSelector?: string;
2744
+ /** A disabled cell (`aria-disabled="true"`): "focus" (default) stays reachable but does not activate; "skip" jumps over it. */
2745
+ disabledCells?: "focus" | "skip";
2746
+ /** Arrows past an edge continue at the opposite edge of the same row or column. Default false. */
2747
+ wrap?: boolean;
2748
+ /** PageUp / PageDown move this many rows (clamped). Unset: Page keys are not handled. */
2749
+ pageSize?: number;
2750
+ /** "auto" (default) reads the grid's direction on every key, so Left / Right follow right-to-left. */
2751
+ direction?: "auto" | "ltr" | "rtl";
2752
+ /** Enter, Space or a click on a cell that is not disabled. */
2753
+ onActivate?(cell: HTMLElement, pos: GridPosition, event: KeyboardEvent | MouseEvent): void;
2754
+ /** After a key moved the focus to `cell`. */
2755
+ onMove?(cell: HTMLElement, pos: GridPosition, event: KeyboardEvent): void;
2756
+ /** A custom key map, consulted first: a target, `null` (leave the key alone) or `undefined` (default map). */
2757
+ resolve?(key: string, pos: GridPosition, event: KeyboardEvent): GridPosition | null | undefined;
2758
+ }
2759
+ interface GridNavigation {
2760
+ /** The cell that holds the Tab stop, or null while the grid has no cells. */
2761
+ readonly active: GridPosition | null;
2762
+ /** Moves the Tab stop to `pos` (clamped) and focuses it, unless `focus: false`. */
2763
+ focusCell(pos: GridPosition, opts?: {
2764
+ focus?: boolean;
2765
+ }): void;
2766
+ /** Re-reads rows and cells after a re-render; the Tab stop keeps its position, clamped. */
2767
+ refresh(): void;
2768
+ /** Removes the listeners. The cells keep their tabindex. */
2769
+ destroy(): void;
2770
+ }
2771
+ /**
2772
+ * The WAI-ARIA grid keyboard for plain markup (`[role="row"] > [role="gridcell"]`):
2773
+ * one roving Tab stop, arrows, Home / End (Ctrl: grid corners), PageUp / PageDown,
2774
+ * right-to-left, disabled cells, wrapping and activation. Framework-free.
2775
+ */
2776
+ declare function createGridNavigation(grid: HTMLElement, options?: GridNavigationOptions): GridNavigation;
2777
+
2778
+ /**
2779
+ * Speak a short message through a shared, visually hidden polite live region —
2780
+ * used when an element disappears (e.g. a removed chip) and can't announce itself.
2781
+ */
2782
+ declare function announce(message: string): void;
2783
+
2784
+ export { type AccordionAppearance, type AccordionContentType, type AccordionSize, type AccordionType, type AlertAppearance, type AlertTone, type AlertToneInput, type AlertType, type AutocompleteFilter, type AutocompleteItem, type AutocompleteLabelStyle, type AutocompleteSize, type AutocompleteVariant, type AvatarBadge, type AvatarSize, type AvatarType, type AvatarVariant, type BadgeSize, type BadgeSizeInput, type BadgeVariant, type BreadcrumbItem, type ButtonBorder, type ButtonSize, type ButtonTone, type ButtonVariant, type CalendarWeekStart, type CardType, type CarouselOrientation, type CarouselType, type CheckboxAlignment, type CheckboxDensity, type CheckboxSize, type CheckboxState, type CheckboxStatus, type ChipBorder, type ChipSize, type ChipTone, type ChipVariant, type ContainerBackground, type ContainerPadding, type ContainerSurface, type DatePickerSize, type DividerOrientation, type DrawerSide, type FileReplacedDetail, type GridNavigation, type GridNavigationOptions, type GridPosition, type KbdPlatform, type KbdSize, type KbdVariant, type LabelPlacement, LofAccordion, LofAlert, LofAutocomplete, LofAvatar, LofAvatarGroup, LofBadge, LofBreadcrumbs, LofButton, LofCalendar, LofCard, LofCardMedia, LofCarousel, LofCheckbox, LofChip, LofContainer, LofDatePicker, LofDivider, LofDrawer, LofDrawerFooter, LofKbd, LofKbdGroup, LofLayout, LofMenu, LofMenuItem, LofMenubar, LofMenubarMenu, LofModal, LofOtp, LofPagination, LofPopover, LofPopoverContent, LofProgress, LofRadio, LofRangePicker, LofResizableGroup, LofResizableHandle, LofResizablePanel, LofSegmentedButton, LofSelect, LofSignaturePad, LofSkeleton, LofSlider, LofSnackbar, LofSplitButton, LofStepper, LofSwitch, LofTab, LofTabItem, LofTextfield, LofTimePicker, LofToast, LofTooltip, LofTree, LofUpload, LofUploadActions, type MenuItem, type MenuSize, type MenuType, type MenuWidth, type MenubarChangeDetail, type MenubarSelectDetail, type MenubarType, type ModalBreakpoint, type ModalSide, type ModalSize, type ModalVariant, type OtpMode, type OtpSize, type PaginationType, type PopoverAlign, type PopoverContentSize, type PopoverHasPopup, type PopoverSide, type ProgressMode, type RadioAlignment, type RadioDensity, type RadioOption, type RadioOrientation, type RadioSize, type RangePickerMode, type RangePickerSize, type RangePickerTrigger, type ResizableDirection, type ResizableOrientation, type ResolvedKbdKey, type SegmentAlign, type SegmentOption, type SegmentSize, type SelectBorder, type SelectLabelStyle, type SelectOption, type SelectOptionObject, type SelectSize, type SelectState, type SignaturePadChangeDetail, type SignaturePadMode, type SignatureStroke, type SkeletonAnimation, type SkeletonShape, type SliderSize, type SliderTrack, type SliderType, type SnackbarTone, type SnackbarToneInput, type SnackbarVariant, type SplitButtonItem, type SplitButtonSelectDetail, type SplitButtonSize, type SplitButtonTone, type SplitButtonVariant, type Step, type StepStatus, type StepperConnector, type StepperOrientation, type StepperType, type SwitchLabelPlacement, type SwitchSize, type SwitchType, type TabIconPlacement, type TabItem, type TabOrientation, type TabSize, type TextFieldLabelStyle, type TextFieldPrefixStyle, type TextFieldSize, type TextFieldState, type TextFieldVariant, type TimeFormat, type TimePickerSize, type ToastPosition, type ToastSize, type ToastTone, type ToastToneInput, type TooltipPosition, type TooltipTone, type TooltipType, type TreeItem, type TreeSelection, type UploadCompleteDetail, type UploadFile, type UploadPhase, type UploadRejection, type UploadState, type UploadStatus, type Uploader, type UploaderContext, announce, createGridNavigation, dayCellStyles, dayKeyTarget, detectKbdPlatform, midWindow, pageWindow, pickerFieldStyles, pickerPanelStyles, resolveKbdKey };