@lofid/react 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.
- package/README.md +89 -2
- package/dist/index.d.ts +421 -0
- package/dist/index.js +503 -0
- package/dist/index.js.map +1 -0
- package/package.json +39 -4
package/README.md
CHANGED
|
@@ -1,3 +1,90 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @lofid/react
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
React wrappers for every element in `@lofid/web`: all 51 `lof-*` custom elements,
|
|
4
|
+
companions included (`LofTabItem`, `LofMenuItem`, `LofResizablePanel`, …). They work with React 18
|
|
5
|
+
and 19, and they server-render.
|
|
6
|
+
|
|
7
|
+
The wrappers are **generated from the web package's source** (`scripts/generate.mjs`), so their
|
|
8
|
+
props, event handlers and event detail types can't drift from the components. `npm run build` fails
|
|
9
|
+
if `src/generated.ts` is stale.
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npm install @lofid/react @lofid/web
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Setup
|
|
16
|
+
|
|
17
|
+
Load the tokens once, then register the elements on the client.
|
|
18
|
+
|
|
19
|
+
```tsx
|
|
20
|
+
// Vite / CRA entry
|
|
21
|
+
import "@lofid/web/vars.css";
|
|
22
|
+
import "@lofid/web"; // defines lof-* and lof-icon
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
In Next.js (or any SSR setup), register the elements after hydration. The wrappers never import the
|
|
26
|
+
web package themselves, so they're safe in server-rendered trees:
|
|
27
|
+
|
|
28
|
+
```tsx
|
|
29
|
+
"use client";
|
|
30
|
+
import { useEffect } from "react";
|
|
31
|
+
import { defineElements } from "@lofid/react";
|
|
32
|
+
|
|
33
|
+
export function LdsElements() {
|
|
34
|
+
useEffect(() => void defineElements(), []);
|
|
35
|
+
return null;
|
|
36
|
+
}
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## Usage
|
|
40
|
+
|
|
41
|
+
```tsx
|
|
42
|
+
import { useState } from "react";
|
|
43
|
+
import { LofButton, LofSelect, LofTextfield, type LofSelectElement } from "@lofid/react";
|
|
44
|
+
|
|
45
|
+
export function Profile() {
|
|
46
|
+
const [name, setName] = useState("");
|
|
47
|
+
const [countries, setCountries] = useState<string[]>([]);
|
|
48
|
+
|
|
49
|
+
return (
|
|
50
|
+
<form>
|
|
51
|
+
<LofTextfield label="Name" size="small" value={name} onLofChange={(e) => setName(e.detail)} />
|
|
52
|
+
<LofSelect
|
|
53
|
+
label="Countries"
|
|
54
|
+
multiple
|
|
55
|
+
options={[{ label: "India", value: "in" }, { label: "Nepal", value: "np" }]}
|
|
56
|
+
selectedValues={countries}
|
|
57
|
+
onLofChange={(e) => setCountries(e.detail.value as string[])}
|
|
58
|
+
/>
|
|
59
|
+
<LofButton variant="primary">Save</LofButton>
|
|
60
|
+
</form>
|
|
61
|
+
);
|
|
62
|
+
}
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
- **Props** are the element's own properties, typed from its class: `variant`, `options`,
|
|
66
|
+
`selectedValues` and so on. Arrays, objects and functions are assigned as properties. Strings,
|
|
67
|
+
numbers and `true` booleans are also rendered as attributes, so server-rendered HTML carries them.
|
|
68
|
+
`false` works too, including for props that default to `true` (`fullWidth={false}`).
|
|
69
|
+
- **Events** are `on` + the event name in PascalCase: `lof-change` → `onLofChange`, `open-change` →
|
|
70
|
+
`onOpenChange`, `changed` → `onChanged`, `actionClick` → `onActionClick`. A handler only fires for
|
|
71
|
+
events its own element dispatches, never for one bubbling up from a nested `lof-*` element.
|
|
72
|
+
- **HTML attributes** (`className`, `style`, `id`, `slot`, `aria-*`, `data-*`, `onClick`, …) pass
|
|
73
|
+
through unchanged. `className` becomes `class` on React 18 as well.
|
|
74
|
+
- **Refs** point at the element. Each element type is exported as `<Name>Element`
|
|
75
|
+
(`LofSelectElement`, `LofModalElement`, …) for `useRef`.
|
|
76
|
+
- **Children** are slotted content, exactly as in HTML: `<LofButton>Save</LofButton>`.
|
|
77
|
+
|
|
78
|
+
Dropping a prop returns the element to its default. Controlled values (`value`, `checked`,
|
|
79
|
+
`selectedValues`, …) are re-applied on every render, so resetting state resets the element.
|
|
80
|
+
|
|
81
|
+
## Development
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
npm run generate -w @lofid/react # rewrite src/generated.ts from packages/web/src
|
|
85
|
+
npm run build -w @lofid/react # check generated.ts is current, then bundle
|
|
86
|
+
npm test -w @lofid/react # SSR tests + real-browser tests (Chrome or Edge)
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
The browser tests use `playwright-core` with an installed Chrome or Edge; set `BROWSER_PATH` to use
|
|
90
|
+
another Chromium.
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,421 @@
|
|
|
1
|
+
import { ForwardRefExoticComponent, HTMLAttributes, ReactNode, RefAttributes } from 'react';
|
|
2
|
+
import * as W from '@lofid/web';
|
|
3
|
+
export { LofAccordion as LofAccordionElement, LofAlert as LofAlertElement, LofAutocomplete as LofAutocompleteElement, LofAvatar as LofAvatarElement, LofAvatarGroup as LofAvatarGroupElement, LofBadge as LofBadgeElement, LofBreadcrumbs as LofBreadcrumbsElement, LofButton as LofButtonElement, LofCalendar as LofCalendarElement, LofCard as LofCardElement, LofCardMedia as LofCardMediaElement, LofCarousel as LofCarouselElement, LofCheckbox as LofCheckboxElement, LofChip as LofChipElement, LofContainer as LofContainerElement, LofDatePicker as LofDatePickerElement, LofDivider as LofDividerElement, LofDrawer as LofDrawerElement, LofDrawerFooter as LofDrawerFooterElement, LofKbd as LofKbdElement, LofKbdGroup as LofKbdGroupElement, LofLayout as LofLayoutElement, LofMenu as LofMenuElement, LofMenuItem as LofMenuItemElement, LofMenubar as LofMenubarElement, LofMenubarMenu as LofMenubarMenuElement, LofModal as LofModalElement, LofOtp as LofOtpElement, LofPagination as LofPaginationElement, LofPopoverContent as LofPopoverContentElement, LofPopover as LofPopoverElement, LofProgress as LofProgressElement, LofRadio as LofRadioElement, LofRangePicker as LofRangePickerElement, LofResizableGroup as LofResizableGroupElement, LofResizableHandle as LofResizableHandleElement, LofResizablePanel as LofResizablePanelElement, LofSegmentedButton as LofSegmentedButtonElement, LofSelect as LofSelectElement, LofSignaturePad as LofSignaturePadElement, LofSkeleton as LofSkeletonElement, LofSlider as LofSliderElement, LofSnackbar as LofSnackbarElement, LofSplitButton as LofSplitButtonElement, LofStepper as LofStepperElement, LofSwitch as LofSwitchElement, LofTab as LofTabElement, LofTabItem as LofTabItemElement, LofTextfield as LofTextfieldElement, LofTimePicker as LofTimePickerElement, LofToast as LofToastElement, LofTooltip as LofTooltipElement, LofTree as LofTreeElement, LofUploadActions as LofUploadActionsElement, LofUpload as LofUploadElement } from '@lofid/web';
|
|
4
|
+
|
|
5
|
+
/** Event handler props, e.g. `{ onLofChange: (e: CustomEvent<{ value: string }>) => void }`. */
|
|
6
|
+
type EventHandlers<Events> = {
|
|
7
|
+
[K in keyof Events]?: (event: Events[K]) => void;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* Props of a wrapper: the element's public properties (typed from the element class),
|
|
11
|
+
* its event handlers, and ordinary HTML attributes (className, style, id, slot, aria-*, data-*).
|
|
12
|
+
*/
|
|
13
|
+
type LofProps<E extends HTMLElement, P extends keyof E, Events> = {
|
|
14
|
+
[K in P]?: E[K];
|
|
15
|
+
} & EventHandlers<Events> & Omit<HTMLAttributes<E>, P | keyof Events> & {
|
|
16
|
+
children?: ReactNode;
|
|
17
|
+
};
|
|
18
|
+
type LofComponent<E extends HTMLElement, P extends keyof E, Events> = ForwardRefExoticComponent<LofProps<E, P, Events> & RefAttributes<E>>;
|
|
19
|
+
/**
|
|
20
|
+
* How a property also renders as an attribute: `"attr"` for strings and numbers,
|
|
21
|
+
* `"?attr"` for booleans (present only when `true`), `null` for property-only
|
|
22
|
+
* values such as arrays, objects and functions.
|
|
23
|
+
*/
|
|
24
|
+
type AttributeSpec = string | null;
|
|
25
|
+
/**
|
|
26
|
+
* Builds a React component that renders `tag` and bridges what React 18 cannot:
|
|
27
|
+
*
|
|
28
|
+
* - **Properties.** Every key of `props` is assigned to the element as a JS
|
|
29
|
+
* property after each render, before paint. React 18 alone would set a string
|
|
30
|
+
* attribute, which breaks arrays, objects, `false` booleans and camelCase names
|
|
31
|
+
* whose attribute differs (`selectedValues` is `selected-values`). A property
|
|
32
|
+
* dropped from the props goes back to the element's default.
|
|
33
|
+
* - **Attributes.** Strings, numbers and `true` booleans are also rendered under
|
|
34
|
+
* their attribute name, so server-rendered HTML carries them and the element
|
|
35
|
+
* looks right the moment it is defined, before React hydrates.
|
|
36
|
+
* - **Events.** Each `onX` key of `events` listens for the custom event it names.
|
|
37
|
+
* Only events the element itself dispatches reach the handler: the events bubble,
|
|
38
|
+
* so a `<LofSelect>` inside a `<LofTab>` would otherwise call the tab's
|
|
39
|
+
* `onLofChange` with the select's detail.
|
|
40
|
+
*
|
|
41
|
+
* Nothing here imports the web package, so wrappers render on the server as plain
|
|
42
|
+
* tags. Register the elements once on the client (see `defineElements`).
|
|
43
|
+
*/
|
|
44
|
+
declare function createComponent<E extends HTMLElement, P extends keyof E & string, Events extends Record<string, Event>>(tag: string, props: {
|
|
45
|
+
readonly [K in P]: AttributeSpec;
|
|
46
|
+
}, events: {
|
|
47
|
+
readonly [K in keyof Events]: string;
|
|
48
|
+
}): LofComponent<E, P, Events>;
|
|
49
|
+
|
|
50
|
+
/** React wrapper for `<lof-accordion>`. */
|
|
51
|
+
declare const LofAccordion: LofComponent<W.LofAccordion, "title" | "type" | "appearance" | "contentType" | "disabled" | "open" | "size", {
|
|
52
|
+
onOpenChange: CustomEvent<boolean>;
|
|
53
|
+
}>;
|
|
54
|
+
/** React wrapper for `<lof-alert>`. */
|
|
55
|
+
declare const LofAlert: LofComponent<W.LofAlert, "type" | "appearance" | "dismissed" | "dismissible" | "message1" | "message2" | "tone" | "urlHref" | "urlText", {
|
|
56
|
+
onDismiss: CustomEvent<undefined>;
|
|
57
|
+
}>;
|
|
58
|
+
/** React wrapper for `<lof-autocomplete>`. */
|
|
59
|
+
declare const LofAutocomplete: LofComponent<W.LofAutocomplete, "label" | "filter" | "error" | "disabled" | "size" | "clearable" | "debounceMs" | "displayField" | "errorMessage" | "fieldAriaLabel" | "fieldAriaLabelledby" | "floatingLabel" | "fullWidth" | "helperText" | "items" | "labelStyle" | "loading" | "loadingText" | "maxSuggestions" | "minSearchLength" | "multiple" | "name" | "noResultsText" | "placeholder" | "prefixIcon" | "readonly" | "required" | "searchFn" | "selectAllLabel" | "selectedValues" | "supportingField" | "value" | "valueField" | "variant", {
|
|
60
|
+
onChanged: CustomEvent<{
|
|
61
|
+
value: string;
|
|
62
|
+
item: W.AutocompleteItem;
|
|
63
|
+
} | {
|
|
64
|
+
value: string[];
|
|
65
|
+
item: null;
|
|
66
|
+
} | {
|
|
67
|
+
value: string;
|
|
68
|
+
item: null;
|
|
69
|
+
}>;
|
|
70
|
+
onLofChange: CustomEvent<string>;
|
|
71
|
+
onLofClear: CustomEvent<undefined>;
|
|
72
|
+
onLofSearchError: CustomEvent<{
|
|
73
|
+
query: string;
|
|
74
|
+
error: unknown;
|
|
75
|
+
}>;
|
|
76
|
+
}>;
|
|
77
|
+
/** React wrapper for `<lof-avatar>`. */
|
|
78
|
+
declare const LofAvatar: LofComponent<W.LofAvatar, "color" | "text" | "type" | "size" | "variant" | "alt" | "badge" | "badgeIcon" | "badgeLabel" | "bg" | "icon" | "ring" | "src", {}>;
|
|
79
|
+
/** React wrapper for `<lof-avatar-group>`. */
|
|
80
|
+
declare const LofAvatarGroup: LofComponent<W.LofAvatarGroup, "label" | "size" | "max" | "overflowLabel" | "total", {}>;
|
|
81
|
+
/** React wrapper for `<lof-badge>`. */
|
|
82
|
+
declare const LofBadge: LofComponent<W.LofBadge, "number" | "ariaLabel" | "color" | "size" | "variant" | "live" | "suffix" | "textColor", {}>;
|
|
83
|
+
/** React wrapper for `<lof-breadcrumbs>`. */
|
|
84
|
+
declare const LofBreadcrumbs: LofComponent<W.LofBreadcrumbs, "ariaLabel" | "items", {}>;
|
|
85
|
+
/** React wrapper for `<lof-button>`. */
|
|
86
|
+
declare const LofButton: LofComponent<W.LofButton, "ariaLabel" | "disabled" | "size" | "tone" | "loading" | "variant" | "badge" | "badgeDot" | "border" | "iconOnly", {}>;
|
|
87
|
+
/** React wrapper for `<lof-calendar>`. */
|
|
88
|
+
declare const LofCalendar: LofComponent<W.LofCalendar, "disabled" | "value" | "max" | "isDateDisabled" | "locale" | "min" | "weekStart", {
|
|
89
|
+
onLofChange: CustomEvent<{
|
|
90
|
+
value: string;
|
|
91
|
+
date: Date;
|
|
92
|
+
}>;
|
|
93
|
+
}>;
|
|
94
|
+
/** React wrapper for `<lof-card>`. */
|
|
95
|
+
declare const LofCard: LofComponent<W.LofCard, "type", {}>;
|
|
96
|
+
/** React wrapper for `<lof-card-media>`. */
|
|
97
|
+
declare const LofCardMedia: LofComponent<W.LofCardMedia, "title" | "imageAlt" | "imageSrc" | "subtitle", {}>;
|
|
98
|
+
/** React wrapper for `<lof-carousel>`. */
|
|
99
|
+
declare const LofCarousel: LofComponent<W.LofCarousel, "label" | "type" | "disabled" | "value" | "autoplay" | "gap" | "interval" | "loop" | "orientation" | "panels" | "pauseOnHover" | "showButtons" | "showDots", {
|
|
100
|
+
onLofChange: CustomEvent<{
|
|
101
|
+
value: number;
|
|
102
|
+
}>;
|
|
103
|
+
}>;
|
|
104
|
+
/** React wrapper for `<lof-checkbox>`. */
|
|
105
|
+
declare const LofCheckbox: LofComponent<W.LofCheckbox, "label" | "disabled" | "size" | "fieldAriaLabel" | "value" | "icon" | "alignment" | "checked" | "density" | "state" | "status" | "supportingtext" | "supportingText", {
|
|
106
|
+
onLofChange: CustomEvent<{
|
|
107
|
+
checked: boolean;
|
|
108
|
+
value: string;
|
|
109
|
+
}>;
|
|
110
|
+
}>;
|
|
111
|
+
/** React wrapper for `<lof-chip>`. */
|
|
112
|
+
declare const LofChip: LofComponent<W.LofChip, "label" | "size" | "tone" | "fieldAriaLabel" | "variant" | "border" | "avatar" | "draggableChip" | "leadingIcon" | "presentational" | "removable" | "removed" | "trailingIcon", {
|
|
113
|
+
onChipMove: CustomEvent<{
|
|
114
|
+
direction: number;
|
|
115
|
+
}>;
|
|
116
|
+
onRemoved: CustomEvent<undefined>;
|
|
117
|
+
}>;
|
|
118
|
+
/** React wrapper for `<lof-container>`. */
|
|
119
|
+
declare const LofContainer: LofComponent<W.LofContainer, "background" | "padding" | "shadow" | "surface", {}>;
|
|
120
|
+
/** React wrapper for `<lof-date-picker>`. */
|
|
121
|
+
declare const LofDatePicker: LofComponent<W.LofDatePicker, "label" | "error" | "disabled" | "open" | "size" | "clearable" | "errorMessage" | "fullWidth" | "helperText" | "name" | "placeholder" | "readonly" | "required" | "value" | "variant" | "max" | "isDateDisabled" | "locale" | "min" | "weekStart" | "closeOnSelect" | "displayFormat" | "formatDate" | "maxDate" | "minDate" | "showShortcuts", {
|
|
122
|
+
onLofBlur: CustomEvent<undefined>;
|
|
123
|
+
onLofChange: CustomEvent<{
|
|
124
|
+
value: string | null;
|
|
125
|
+
date: Date;
|
|
126
|
+
} | {
|
|
127
|
+
value: null;
|
|
128
|
+
date: null;
|
|
129
|
+
}>;
|
|
130
|
+
onLofOpenChange: CustomEvent<{
|
|
131
|
+
open: boolean;
|
|
132
|
+
}>;
|
|
133
|
+
}>;
|
|
134
|
+
/** React wrapper for `<lof-divider>`. */
|
|
135
|
+
declare const LofDivider: LofComponent<W.LofDivider, "orientation", {}>;
|
|
136
|
+
/** React wrapper for `<lof-drawer>`. */
|
|
137
|
+
declare const LofDrawer: LofComponent<W.LofDrawer, "draggable" | "title" | "description" | "open" | "dismissible" | "closeOnBackdrop" | "closeOnEscape" | "maxHeight" | "modal" | "showHandle" | "side" | "snapThreshold" | "width", {
|
|
138
|
+
onLofOpenChange: CustomEvent<{
|
|
139
|
+
open: boolean;
|
|
140
|
+
}>;
|
|
141
|
+
}>;
|
|
142
|
+
/** React wrapper for `<lof-drawer-footer>`. */
|
|
143
|
+
declare const LofDrawerFooter: LofComponent<W.LofDrawerFooter, never, {}>;
|
|
144
|
+
/** React wrapper for `<lof-kbd>`. */
|
|
145
|
+
declare const LofKbd: LofComponent<W.LofKbd, "size" | "variant" | "inset" | "keyName" | "pill" | "platform", {}>;
|
|
146
|
+
/** React wrapper for `<lof-kbd-group>`. */
|
|
147
|
+
declare const LofKbdGroup: LofComponent<W.LofKbdGroup, "size" | "items" | "variant" | "platform", {}>;
|
|
148
|
+
/** React wrapper for `<lof-layout>`. */
|
|
149
|
+
declare const LofLayout: LofComponent<W.LofLayout, "gap" | "columns" | "responsive", {}>;
|
|
150
|
+
/** React wrapper for `<lof-menu>`. */
|
|
151
|
+
declare const LofMenu: LofComponent<W.LofMenu, "type" | "size" | "items" | "width", {
|
|
152
|
+
onLofCheck: CustomEvent<{
|
|
153
|
+
item: {
|
|
154
|
+
checked: boolean;
|
|
155
|
+
label: string;
|
|
156
|
+
active?: boolean;
|
|
157
|
+
disabled?: boolean;
|
|
158
|
+
submenu?: W.MenuItem[];
|
|
159
|
+
open?: boolean;
|
|
160
|
+
icon?: string;
|
|
161
|
+
};
|
|
162
|
+
checked: boolean;
|
|
163
|
+
}>;
|
|
164
|
+
onLofSelect: CustomEvent<{
|
|
165
|
+
item: W.MenuItem;
|
|
166
|
+
}>;
|
|
167
|
+
onLofSubmenuSelect: CustomEvent<{
|
|
168
|
+
parent: W.MenuItem;
|
|
169
|
+
sub: W.MenuItem | undefined;
|
|
170
|
+
}>;
|
|
171
|
+
}>;
|
|
172
|
+
/** React wrapper for `<lof-menu-item>`. */
|
|
173
|
+
declare const LofMenuItem: LofComponent<W.LofMenuItem, "label" | "disabled" | "value" | "icon", {}>;
|
|
174
|
+
/** React wrapper for `<lof-menubar>`. */
|
|
175
|
+
declare const LofMenubar: LofComponent<W.LofMenubar, "type" | "bindShortcuts", {
|
|
176
|
+
onLofMenubarChange: CustomEvent<W.MenubarChangeDetail>;
|
|
177
|
+
onLofMenubarSelect: CustomEvent<W.MenubarSelectDetail | {
|
|
178
|
+
label: string;
|
|
179
|
+
value: string | undefined;
|
|
180
|
+
shortcut: string | undefined;
|
|
181
|
+
}>;
|
|
182
|
+
}>;
|
|
183
|
+
/** React wrapper for `<lof-menubar-menu>`. */
|
|
184
|
+
declare const LofMenubarMenu: LofComponent<W.LofMenubarMenu, "label" | "disabled", {}>;
|
|
185
|
+
/** React wrapper for `<lof-modal>`. */
|
|
186
|
+
declare const LofModal: LofComponent<W.LofModal, "title" | "description" | "autoFocus" | "disabled" | "open" | "size" | "dismissible" | "loading" | "variant" | "subtitle" | "closeOnEscape" | "modal" | "side" | "breakpoint" | "closeOnBackdropClick" | "restoreFocus" | "scrollable" | "showCloseButton" | "zIndex", {
|
|
187
|
+
onLofOpenChange: CustomEvent<boolean>;
|
|
188
|
+
}>;
|
|
189
|
+
/** React wrapper for `<lof-otp>`. */
|
|
190
|
+
declare const LofOtp: LofComponent<W.LofOtp, "ariaLabel" | "inputMode" | "length" | "mask" | "pattern" | "type" | "invalid" | "disabled" | "size" | "name" | "placeholder" | "readonly" | "required" | "value" | "autocomplete" | "groupSize" | "inputmode" | "showSeparator", {
|
|
191
|
+
onLofChange: CustomEvent<{
|
|
192
|
+
value: string;
|
|
193
|
+
complete: boolean;
|
|
194
|
+
}>;
|
|
195
|
+
onLofComplete: CustomEvent<{
|
|
196
|
+
value: string;
|
|
197
|
+
}>;
|
|
198
|
+
}>;
|
|
199
|
+
/** React wrapper for `<lof-pagination>`. */
|
|
200
|
+
declare const LofPagination: LofComponent<W.LofPagination, "ariaLabel" | "type" | "disabled" | "defaultPage" | "hrefTemplate" | "page" | "perPage" | "rowsPerPageLabel" | "rowsPerPageOptions" | "showLabel" | "showRowsPerPage" | "totalItems" | "totalPages", {
|
|
201
|
+
onLofChange: CustomEvent<{
|
|
202
|
+
page: number;
|
|
203
|
+
}>;
|
|
204
|
+
onLofPerPageChange: CustomEvent<{
|
|
205
|
+
perPage: number;
|
|
206
|
+
}>;
|
|
207
|
+
}>;
|
|
208
|
+
/** React wrapper for `<lof-popover>`. */
|
|
209
|
+
declare const LofPopover: LofComponent<W.LofPopover, "disabled" | "open" | "closeOnEscape" | "side" | "align" | "alignOffset" | "arrow" | "closeOnOutsideClick" | "defaultOpen" | "hasPopup" | "sideOffset" | "trapFocus", {
|
|
210
|
+
onLofOpenChange: CustomEvent<{
|
|
211
|
+
open: boolean;
|
|
212
|
+
}>;
|
|
213
|
+
}>;
|
|
214
|
+
/** React wrapper for `<lof-popover-content>`. */
|
|
215
|
+
declare const LofPopoverContent: LofComponent<W.LofPopoverContent, "ariaLabel" | "size", {}>;
|
|
216
|
+
/** React wrapper for `<lof-progress>`. */
|
|
217
|
+
declare const LofProgress: LofComponent<W.LofProgress, "label" | "value" | "mode", {}>;
|
|
218
|
+
/** React wrapper for `<lof-radio>`. */
|
|
219
|
+
declare const LofRadio: LofComponent<W.LofRadio, "error" | "disabled" | "size" | "errorMessage" | "fieldAriaLabel" | "name" | "value" | "orientation" | "alignment" | "density" | "options" | "selectedValue", {
|
|
220
|
+
onLofChange: CustomEvent<{
|
|
221
|
+
value: string;
|
|
222
|
+
checked: true;
|
|
223
|
+
}>;
|
|
224
|
+
}>;
|
|
225
|
+
/** React wrapper for `<lof-range-picker>`. */
|
|
226
|
+
declare const LofRangePicker: LofComponent<W.LofRangePicker, "disabled" | "open" | "size" | "clearable" | "fullWidth" | "placeholder" | "locale" | "weekStart" | "maxDate" | "minDate" | "maxHeight" | "width" | "mode" | "from" | "height" | "maxWidth" | "minHeight" | "minWidth" | "to" | "triggerVariant", {
|
|
227
|
+
onLofBlur: CustomEvent<undefined>;
|
|
228
|
+
onLofChange: CustomEvent<{
|
|
229
|
+
from: string;
|
|
230
|
+
to: string;
|
|
231
|
+
label: string;
|
|
232
|
+
}>;
|
|
233
|
+
onLofOpenChange: CustomEvent<{
|
|
234
|
+
open: true;
|
|
235
|
+
} | {
|
|
236
|
+
open: false;
|
|
237
|
+
}>;
|
|
238
|
+
}>;
|
|
239
|
+
/** React wrapper for `<lof-resizable-group>`. */
|
|
240
|
+
declare const LofResizableGroup: LofComponent<W.LofResizableGroup, "direction", {
|
|
241
|
+
onLofResize: CustomEvent<{
|
|
242
|
+
direction: W.ResizableOrientation;
|
|
243
|
+
sizes: number[];
|
|
244
|
+
}>;
|
|
245
|
+
onLofResizeEnd: CustomEvent<{
|
|
246
|
+
direction: W.ResizableOrientation;
|
|
247
|
+
sizes: number[];
|
|
248
|
+
}>;
|
|
249
|
+
}>;
|
|
250
|
+
/** React wrapper for `<lof-resizable-handle>`. */
|
|
251
|
+
declare const LofResizableHandle: LofComponent<W.LofResizableHandle, "orientation", {}>;
|
|
252
|
+
/** React wrapper for `<lof-resizable-panel>`. */
|
|
253
|
+
declare const LofResizablePanel: LofComponent<W.LofResizablePanel, "defaultSize" | "maxSize" | "minSize" | "panelLabel", {}>;
|
|
254
|
+
/** React wrapper for `<lof-segmented-button>`. */
|
|
255
|
+
declare const LofSegmentedButton: LofComponent<W.LofSegmentedButton, "disabled" | "size" | "fieldAriaLabel" | "align" | "options" | "active", {
|
|
256
|
+
onChanged: CustomEvent<{
|
|
257
|
+
value: string;
|
|
258
|
+
}>;
|
|
259
|
+
onLofChange: CustomEvent<{
|
|
260
|
+
value: string;
|
|
261
|
+
}>;
|
|
262
|
+
}>;
|
|
263
|
+
/** React wrapper for `<lof-select>`. */
|
|
264
|
+
declare const LofSelect: LofComponent<W.LofSelect, "label" | "size" | "fieldAriaLabel" | "fieldAriaLabelledby" | "labelStyle" | "multiple" | "placeholder" | "selectAllLabel" | "selectedValues" | "border" | "state" | "supportingText" | "options" | "leftIcon" | "maxVisibleChips" | "noSearch" | "rightIcon" | "searchPlaceholder" | "selected" | "supportingIcon", {
|
|
265
|
+
onChanged: CustomEvent<{
|
|
266
|
+
value: string | string[];
|
|
267
|
+
}>;
|
|
268
|
+
onLofChange: CustomEvent<{
|
|
269
|
+
value: string | string[];
|
|
270
|
+
}>;
|
|
271
|
+
}>;
|
|
272
|
+
/** React wrapper for `<lof-signature-pad>`. */
|
|
273
|
+
declare const LofSignaturePad: LofComponent<W.LofSignaturePad, "label" | "error" | "disabled" | "errorMessage" | "fieldAriaLabel" | "helperText" | "name" | "placeholder" | "readonly" | "required" | "value" | "mode" | "disabledText" | "strokes" | "typedName", {
|
|
274
|
+
onLofBegin: CustomEvent<{}>;
|
|
275
|
+
onLofChange: CustomEvent<W.SignaturePadChangeDetail>;
|
|
276
|
+
onLofEnd: CustomEvent<{}>;
|
|
277
|
+
}>;
|
|
278
|
+
/** React wrapper for `<lof-skeleton>`. */
|
|
279
|
+
declare const LofSkeleton: LofComponent<W.LofSkeleton, "width" | "height" | "animation" | "lines" | "loaded" | "shape", {}>;
|
|
280
|
+
/** React wrapper for `<lof-slider>`. */
|
|
281
|
+
declare const LofSlider: LofComponent<W.LofSlider, "track" | "type" | "disabled" | "size" | "fieldAriaLabel" | "value" | "max" | "min" | "showBubble" | "showTickLabels" | "showTicks" | "step" | "valueEnd", {
|
|
282
|
+
onLofChange: CustomEvent<{
|
|
283
|
+
value: number;
|
|
284
|
+
valueEnd: number;
|
|
285
|
+
} | {
|
|
286
|
+
value: number;
|
|
287
|
+
}>;
|
|
288
|
+
}>;
|
|
289
|
+
/** React wrapper for `<lof-snackbar>`. */
|
|
290
|
+
declare const LofSnackbar: LofComponent<W.LofSnackbar, "type" | "tone" | "variant" | "lines" | "action" | "duration" | "iconClose" | "longerAction" | "message" | "show", {
|
|
291
|
+
onActionClick: CustomEvent<undefined>;
|
|
292
|
+
onClose: CustomEvent<undefined>;
|
|
293
|
+
}>;
|
|
294
|
+
/** React wrapper for `<lof-split-button>`. */
|
|
295
|
+
declare const LofSplitButton: LofComponent<W.LofSplitButton, "ariaLabel" | "label" | "disabled" | "open" | "size" | "tone" | "items" | "loading" | "variant" | "icon" | "iconOnly" | "menuLabel", {
|
|
296
|
+
onLofOpenChange: CustomEvent<{
|
|
297
|
+
open: boolean;
|
|
298
|
+
}>;
|
|
299
|
+
onLofSelect: CustomEvent<W.SplitButtonSelectDetail>;
|
|
300
|
+
}>;
|
|
301
|
+
/** React wrapper for `<lof-stepper>`. */
|
|
302
|
+
declare const LofStepper: LofComponent<W.LofStepper, "type" | "size" | "orientation" | "connector" | "labelPlacement" | "steps" | "textAlign", {
|
|
303
|
+
onLofStepChange: CustomEvent<{
|
|
304
|
+
index: number;
|
|
305
|
+
step: W.Step;
|
|
306
|
+
}>;
|
|
307
|
+
}>;
|
|
308
|
+
/** React wrapper for `<lof-switch>`. */
|
|
309
|
+
declare const LofSwitch: LofComponent<W.LofSwitch, "label" | "type" | "disabled" | "size" | "fieldAriaLabel" | "value" | "checked" | "labelPlacement", {
|
|
310
|
+
onLofChange: CustomEvent<{
|
|
311
|
+
checked: boolean;
|
|
312
|
+
value: string;
|
|
313
|
+
}>;
|
|
314
|
+
}>;
|
|
315
|
+
/** React wrapper for `<lof-tab>`. */
|
|
316
|
+
declare const LofTab: LofComponent<W.LofTab, "size" | "orientation" | "activeIndex" | "iconPlacement" | "tabs", {
|
|
317
|
+
onLofChange: CustomEvent<number>;
|
|
318
|
+
onLofTabChange: CustomEvent<number>;
|
|
319
|
+
}>;
|
|
320
|
+
/** React wrapper for `<lof-tab-item>`. */
|
|
321
|
+
declare const LofTabItem: LofComponent<W.LofTabItem, "label" | "disabled" | "value" | "badge" | "icon" | "badgeDot", {}>;
|
|
322
|
+
/** React wrapper for `<lof-textfield>`. */
|
|
323
|
+
declare const LofTextfield: LofComponent<W.LofTextfield, "label" | "type" | "error" | "disabled" | "size" | "errorMessage" | "fieldAriaLabel" | "fieldAriaLabelledby" | "floatingLabel" | "fullWidth" | "helperText" | "labelStyle" | "name" | "placeholder" | "prefixIcon" | "readonly" | "required" | "value" | "variant" | "state" | "supportingText" | "leftIcon" | "rightIcon" | "clickableRightIcon" | "helperIcon" | "maxLength" | "multiline" | "prefixIconAriaLabel" | "prefixStyle" | "prefixText" | "rightIconAriaLabel" | "rows" | "suffixDivider" | "suffixText", {
|
|
324
|
+
onLofChange: CustomEvent<string>;
|
|
325
|
+
onLofRightIconClick: CustomEvent<undefined>;
|
|
326
|
+
}>;
|
|
327
|
+
/** React wrapper for `<lof-time-picker>`. */
|
|
328
|
+
declare const LofTimePicker: LofComponent<W.LofTimePicker, "label" | "error" | "invalid" | "disabled" | "open" | "size" | "clearable" | "errorMessage" | "fullWidth" | "helperText" | "name" | "placeholder" | "readonly" | "required" | "value" | "variant" | "format" | "maxTime" | "minTime" | "minuteStep" | "seconds", {
|
|
329
|
+
onLofBlur: CustomEvent<undefined>;
|
|
330
|
+
onLofChange: CustomEvent<{
|
|
331
|
+
value: string | null;
|
|
332
|
+
}>;
|
|
333
|
+
onLofFocus: CustomEvent<undefined>;
|
|
334
|
+
onLofOpenChange: CustomEvent<{
|
|
335
|
+
open: boolean;
|
|
336
|
+
}>;
|
|
337
|
+
}>;
|
|
338
|
+
/** React wrapper for `<lof-toast>`. */
|
|
339
|
+
declare const LofToast: LofComponent<W.LofToast, "type" | "size" | "dismissible" | "tone" | "duration" | "message" | "show" | "actionLabel" | "maxVisible" | "position", {
|
|
340
|
+
onAction: CustomEvent<undefined>;
|
|
341
|
+
onDismissed: CustomEvent<undefined>;
|
|
342
|
+
}>;
|
|
343
|
+
/** React wrapper for `<lof-tooltip>`. */
|
|
344
|
+
declare const LofTooltip: LofComponent<W.LofTooltip, "text" | "type" | "tone" | "position" | "showTail", {}>;
|
|
345
|
+
/** React wrapper for `<lof-tree>`. */
|
|
346
|
+
declare const LofTree: LofComponent<W.LofTree, "fieldAriaLabel" | "items" | "selectedValues" | "selected" | "expandedValues" | "selection" | "showGuides", {
|
|
347
|
+
onLofChange: CustomEvent<{
|
|
348
|
+
value: string[];
|
|
349
|
+
} | {
|
|
350
|
+
value: string;
|
|
351
|
+
}>;
|
|
352
|
+
onLofExpandedChange: CustomEvent<{
|
|
353
|
+
value: string;
|
|
354
|
+
expanded: boolean;
|
|
355
|
+
}>;
|
|
356
|
+
onLofLoadChildren: CustomEvent<{
|
|
357
|
+
value: string;
|
|
358
|
+
}>;
|
|
359
|
+
}>;
|
|
360
|
+
/** React wrapper for `<lof-upload>`. */
|
|
361
|
+
declare const LofUpload: LofComponent<W.LofUpload, "disabled" | "multiple" | "maxSize" | "accept" | "browseLabel" | "concurrency" | "delayThreshold" | "dropzoneTitle" | "files" | "hint" | "maxFiles" | "uploader", {
|
|
362
|
+
onLofCancel: CustomEvent<undefined>;
|
|
363
|
+
onLofChange: CustomEvent<{
|
|
364
|
+
files: W.UploadFile[];
|
|
365
|
+
}>;
|
|
366
|
+
onLofComplete: CustomEvent<{
|
|
367
|
+
succeeded: W.UploadFile[];
|
|
368
|
+
failed: W.UploadFile[];
|
|
369
|
+
}>;
|
|
370
|
+
onLofFileComplete: CustomEvent<{
|
|
371
|
+
id: string;
|
|
372
|
+
file: File;
|
|
373
|
+
}>;
|
|
374
|
+
onLofFileError: CustomEvent<{
|
|
375
|
+
id: string;
|
|
376
|
+
file: File;
|
|
377
|
+
error: string;
|
|
378
|
+
}>;
|
|
379
|
+
onLofFileReplaced: CustomEvent<W.FileReplacedDetail>;
|
|
380
|
+
onLofFilesAdded: CustomEvent<{
|
|
381
|
+
added: W.UploadFile[];
|
|
382
|
+
rejected: W.UploadRejection[];
|
|
383
|
+
}>;
|
|
384
|
+
onLofInvalid: CustomEvent<{
|
|
385
|
+
rejected: W.UploadRejection[];
|
|
386
|
+
}>;
|
|
387
|
+
onLofProgress: CustomEvent<{
|
|
388
|
+
id: string;
|
|
389
|
+
progress: number;
|
|
390
|
+
loaded: number;
|
|
391
|
+
total: number;
|
|
392
|
+
}>;
|
|
393
|
+
onLofRemove: CustomEvent<{
|
|
394
|
+
id: string;
|
|
395
|
+
file: File | undefined;
|
|
396
|
+
}>;
|
|
397
|
+
onLofRetry: CustomEvent<{
|
|
398
|
+
files: W.UploadFile[];
|
|
399
|
+
}>;
|
|
400
|
+
onLofState: CustomEvent<W.UploadState>;
|
|
401
|
+
onLofUpload: CustomEvent<{
|
|
402
|
+
files: W.UploadFile[];
|
|
403
|
+
}>;
|
|
404
|
+
onLofUploadComplete: CustomEvent<W.UploadCompleteDetail>;
|
|
405
|
+
}>;
|
|
406
|
+
/** React wrapper for `<lof-upload-actions>`. */
|
|
407
|
+
declare const LofUploadActions: LofComponent<W.LofUploadActions, "cancelLabel" | "for" | "noCancel", {
|
|
408
|
+
onLofCancel: CustomEvent<undefined>;
|
|
409
|
+
}>;
|
|
410
|
+
|
|
411
|
+
/** Every tag these wrappers render. */
|
|
412
|
+
declare const WRAPPED_TAGS: readonly ["lof-accordion", "lof-alert", "lof-autocomplete", "lof-avatar", "lof-avatar-group", "lof-badge", "lof-breadcrumbs", "lof-button", "lof-calendar", "lof-card", "lof-card-media", "lof-carousel", "lof-checkbox", "lof-chip", "lof-container", "lof-date-picker", "lof-divider", "lof-drawer", "lof-drawer-footer", "lof-kbd", "lof-kbd-group", "lof-layout", "lof-menu", "lof-menu-item", "lof-menubar", "lof-menubar-menu", "lof-modal", "lof-otp", "lof-pagination", "lof-popover", "lof-popover-content", "lof-progress", "lof-radio", "lof-range-picker", "lof-resizable-group", "lof-resizable-handle", "lof-resizable-panel", "lof-segmented-button", "lof-select", "lof-signature-pad", "lof-skeleton", "lof-slider", "lof-snackbar", "lof-split-button", "lof-stepper", "lof-switch", "lof-tab", "lof-tab-item", "lof-textfield", "lof-time-picker", "lof-toast", "lof-tooltip", "lof-tree", "lof-upload", "lof-upload-actions"];
|
|
413
|
+
|
|
414
|
+
/**
|
|
415
|
+
* Registers every lof-* element (and lof-icon) by loading @lofid/web.
|
|
416
|
+
* Safe to call from anywhere and any number of times; it does nothing on the
|
|
417
|
+
* server. Bundled SPAs can import "@lofid/web" at their entry instead.
|
|
418
|
+
*/
|
|
419
|
+
declare function defineElements(): Promise<void>;
|
|
420
|
+
|
|
421
|
+
export { type AttributeSpec, type EventHandlers, LofAccordion, LofAlert, LofAutocomplete, LofAvatar, LofAvatarGroup, LofBadge, LofBreadcrumbs, LofButton, LofCalendar, LofCard, LofCardMedia, LofCarousel, LofCheckbox, LofChip, type LofComponent, LofContainer, LofDatePicker, LofDivider, LofDrawer, LofDrawerFooter, LofKbd, LofKbdGroup, LofLayout, LofMenu, LofMenuItem, LofMenubar, LofMenubarMenu, LofModal, LofOtp, LofPagination, LofPopover, LofPopoverContent, LofProgress, type LofProps, LofRadio, LofRangePicker, LofResizableGroup, LofResizableHandle, LofResizablePanel, LofSegmentedButton, LofSelect, LofSignaturePad, LofSkeleton, LofSlider, LofSnackbar, LofSplitButton, LofStepper, LofSwitch, LofTab, LofTabItem, LofTextfield, LofTimePicker, LofToast, LofTooltip, LofTree, LofUpload, LofUploadActions, WRAPPED_TAGS, createComponent, defineElements };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,503 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// src/create-component.ts
|
|
4
|
+
import {
|
|
5
|
+
createElement,
|
|
6
|
+
forwardRef,
|
|
7
|
+
useCallback,
|
|
8
|
+
useEffect,
|
|
9
|
+
useLayoutEffect,
|
|
10
|
+
useRef,
|
|
11
|
+
version
|
|
12
|
+
} from "react";
|
|
13
|
+
var useClientLayoutEffect = typeof window === "undefined" ? useEffect : useLayoutEffect;
|
|
14
|
+
var NO_DEFAULT = /* @__PURE__ */ Symbol("no-default");
|
|
15
|
+
var CLASS_PROP = Number.parseInt(version, 10) >= 19 ? "className" : "class";
|
|
16
|
+
function createComponent(tag, props, events) {
|
|
17
|
+
const specs = props;
|
|
18
|
+
const eventEntries = Object.entries(events);
|
|
19
|
+
const Component = forwardRef((props2, forwardedRef) => {
|
|
20
|
+
const node = useRef(null);
|
|
21
|
+
const handlers = useRef({});
|
|
22
|
+
const defaults = useRef(/* @__PURE__ */ new Map());
|
|
23
|
+
const applied = useRef(/* @__PURE__ */ new Set());
|
|
24
|
+
const domProps = {};
|
|
25
|
+
const attributes = {};
|
|
26
|
+
const elementProps = {};
|
|
27
|
+
const handlerProps = {};
|
|
28
|
+
for (const key in props2) {
|
|
29
|
+
const value = props2[key];
|
|
30
|
+
if (key in events) handlerProps[key] = value;
|
|
31
|
+
else if (key in specs) {
|
|
32
|
+
elementProps[key] = value;
|
|
33
|
+
const spec = specs[key];
|
|
34
|
+
if (spec === null || value == null) continue;
|
|
35
|
+
if (spec[0] === "?") {
|
|
36
|
+
if (value === true) attributes[spec.slice(1)] = true;
|
|
37
|
+
} else if (typeof value === "string" || typeof value === "number") attributes[spec] = value;
|
|
38
|
+
} else domProps[key === "className" ? CLASS_PROP : key] = value;
|
|
39
|
+
}
|
|
40
|
+
handlers.current = handlerProps;
|
|
41
|
+
useClientLayoutEffect(() => {
|
|
42
|
+
const el = node.current;
|
|
43
|
+
if (!el) return;
|
|
44
|
+
const upgraded = customElements.get(tag) !== void 0;
|
|
45
|
+
for (const key in elementProps) {
|
|
46
|
+
if (!defaults.current.has(key)) defaults.current.set(key, upgraded ? el[key] : NO_DEFAULT);
|
|
47
|
+
const value = elementProps[key];
|
|
48
|
+
if (el[key] !== value) el[key] = value;
|
|
49
|
+
applied.current.add(key);
|
|
50
|
+
}
|
|
51
|
+
for (const key of applied.current) {
|
|
52
|
+
if (key in elementProps) continue;
|
|
53
|
+
const fallback = defaults.current.get(key);
|
|
54
|
+
el[key] = fallback === NO_DEFAULT ? void 0 : fallback;
|
|
55
|
+
applied.current.delete(key);
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
useClientLayoutEffect(() => {
|
|
59
|
+
if (customElements.get(tag)) return;
|
|
60
|
+
let live = true;
|
|
61
|
+
customElements.whenDefined(tag).then(() => {
|
|
62
|
+
const el = node.current;
|
|
63
|
+
if (!live || !el) return;
|
|
64
|
+
for (const key of applied.current) {
|
|
65
|
+
if (!Object.prototype.hasOwnProperty.call(el, key)) continue;
|
|
66
|
+
const value = el[key];
|
|
67
|
+
delete el[key];
|
|
68
|
+
el[key] = value;
|
|
69
|
+
}
|
|
70
|
+
});
|
|
71
|
+
return () => {
|
|
72
|
+
live = false;
|
|
73
|
+
};
|
|
74
|
+
}, []);
|
|
75
|
+
useClientLayoutEffect(() => {
|
|
76
|
+
const el = node.current;
|
|
77
|
+
if (!el || eventEntries.length === 0) return;
|
|
78
|
+
const off = eventEntries.map(([prop, type]) => {
|
|
79
|
+
const listener = (event) => {
|
|
80
|
+
if (event.target !== el) return;
|
|
81
|
+
handlers.current[prop]?.(event);
|
|
82
|
+
};
|
|
83
|
+
el.addEventListener(type, listener);
|
|
84
|
+
return () => el.removeEventListener(type, listener);
|
|
85
|
+
});
|
|
86
|
+
return () => off.forEach((fn) => fn());
|
|
87
|
+
}, []);
|
|
88
|
+
const ref = useCallback(
|
|
89
|
+
(el) => {
|
|
90
|
+
node.current = el;
|
|
91
|
+
if (typeof forwardedRef === "function") forwardedRef(el);
|
|
92
|
+
else if (forwardedRef) forwardedRef.current = el;
|
|
93
|
+
},
|
|
94
|
+
[forwardedRef]
|
|
95
|
+
);
|
|
96
|
+
return createElement(tag, { ...domProps, ...attributes, ref });
|
|
97
|
+
});
|
|
98
|
+
Component.displayName = tag.split("-").map((p) => p[0].toUpperCase() + p.slice(1)).join("");
|
|
99
|
+
return Component;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
// src/generated.ts
|
|
103
|
+
var LofAccordion = /* @__PURE__ */ createComponent(
|
|
104
|
+
"lof-accordion",
|
|
105
|
+
{ appearance: "appearance", contentType: "content-type", disabled: "?disabled", open: "?open", size: "size", title: "title", type: "type" },
|
|
106
|
+
{ onOpenChange: "open-change" }
|
|
107
|
+
);
|
|
108
|
+
var LofAlert = /* @__PURE__ */ createComponent(
|
|
109
|
+
"lof-alert",
|
|
110
|
+
{ appearance: "appearance", dismissed: "?dismissed", dismissible: "?dismissible", message1: "message1", message2: "message2", tone: "tone", type: "type", urlHref: "url-href", urlText: "url-text" },
|
|
111
|
+
{ onDismiss: "dismiss" }
|
|
112
|
+
);
|
|
113
|
+
var LofAutocomplete = /* @__PURE__ */ createComponent(
|
|
114
|
+
"lof-autocomplete",
|
|
115
|
+
{ clearable: "?clearable", debounceMs: "debounce-ms", disabled: "?disabled", displayField: "display-field", error: "?error", errorMessage: "error-message", fieldAriaLabel: "field-aria-label", fieldAriaLabelledby: "field-aria-labelledby", filter: "filter", floatingLabel: "?floating-label", fullWidth: "?full-width", helperText: "helper-text", items: null, label: "label", labelStyle: "label-style", loading: "?loading", loadingText: "loading-text", maxSuggestions: "max-suggestions", minSearchLength: "min-search-length", multiple: "?multiple", name: "name", noResultsText: "no-results-text", placeholder: "placeholder", prefixIcon: "prefix-icon", readonly: "?readonly", required: "?required", searchFn: null, selectAllLabel: "select-all-label", selectedValues: null, size: "size", supportingField: "supporting-field", value: "value", valueField: "value-field", variant: "variant" },
|
|
116
|
+
{ onChanged: "changed", onLofChange: "lof-change", onLofClear: "lof-clear", onLofSearchError: "lof-search-error" }
|
|
117
|
+
);
|
|
118
|
+
var LofAvatar = /* @__PURE__ */ createComponent(
|
|
119
|
+
"lof-avatar",
|
|
120
|
+
{ alt: "alt", badge: "badge", badgeIcon: "badge-icon", badgeLabel: "badge-label", bg: "bg", color: "color", icon: "icon", ring: "?ring", size: "size", src: "src", text: "text", type: "type", variant: "variant" },
|
|
121
|
+
{}
|
|
122
|
+
);
|
|
123
|
+
var LofAvatarGroup = /* @__PURE__ */ createComponent(
|
|
124
|
+
"lof-avatar-group",
|
|
125
|
+
{ label: "label", max: "max", overflowLabel: "overflow-label", size: "size", total: "total" },
|
|
126
|
+
{}
|
|
127
|
+
);
|
|
128
|
+
var LofBadge = /* @__PURE__ */ createComponent(
|
|
129
|
+
"lof-badge",
|
|
130
|
+
{ ariaLabel: "arialabel", color: "color", live: "?live", number: "number", size: "size", suffix: "suffix", textColor: "text-color", variant: "variant" },
|
|
131
|
+
{}
|
|
132
|
+
);
|
|
133
|
+
var LofBreadcrumbs = /* @__PURE__ */ createComponent(
|
|
134
|
+
"lof-breadcrumbs",
|
|
135
|
+
{ ariaLabel: "aria-label", items: null },
|
|
136
|
+
{}
|
|
137
|
+
);
|
|
138
|
+
var LofButton = /* @__PURE__ */ createComponent(
|
|
139
|
+
"lof-button",
|
|
140
|
+
{ ariaLabel: "aria-label", badge: "badge", badgeDot: "?badge-dot", border: "border", disabled: "?disabled", iconOnly: "?icon-only", loading: "?loading", size: "size", tone: "tone", variant: "variant" },
|
|
141
|
+
{}
|
|
142
|
+
);
|
|
143
|
+
var LofCalendar = /* @__PURE__ */ createComponent(
|
|
144
|
+
"lof-calendar",
|
|
145
|
+
{ disabled: "?disabled", isDateDisabled: null, locale: "locale", max: "max", min: "min", value: "value", weekStart: "week-start" },
|
|
146
|
+
{ onLofChange: "lof-change" }
|
|
147
|
+
);
|
|
148
|
+
var LofCard = /* @__PURE__ */ createComponent(
|
|
149
|
+
"lof-card",
|
|
150
|
+
{ type: "type" },
|
|
151
|
+
{}
|
|
152
|
+
);
|
|
153
|
+
var LofCardMedia = /* @__PURE__ */ createComponent(
|
|
154
|
+
"lof-card-media",
|
|
155
|
+
{ imageAlt: "image-alt", imageSrc: "image-src", subtitle: "subtitle", title: "title" },
|
|
156
|
+
{}
|
|
157
|
+
);
|
|
158
|
+
var LofCarousel = /* @__PURE__ */ createComponent(
|
|
159
|
+
"lof-carousel",
|
|
160
|
+
{ autoplay: "?autoplay", disabled: "?disabled", gap: "gap", interval: "interval", label: "label", loop: "?loop", orientation: "orientation", panels: "panels", pauseOnHover: "?pause-on-hover", showButtons: "?show-buttons", showDots: null, type: "type", value: "value" },
|
|
161
|
+
{ onLofChange: "lof-change" }
|
|
162
|
+
);
|
|
163
|
+
var LofCheckbox = /* @__PURE__ */ createComponent(
|
|
164
|
+
"lof-checkbox",
|
|
165
|
+
{ alignment: "alignment", checked: null, density: "density", disabled: "?disabled", fieldAriaLabel: "field-aria-label", icon: "icon", label: "label", size: "size", state: "state", status: "status", supportingtext: "supporting-text", supportingText: null, value: "value" },
|
|
166
|
+
{ onLofChange: "lof-change" }
|
|
167
|
+
);
|
|
168
|
+
var LofChip = /* @__PURE__ */ createComponent(
|
|
169
|
+
"lof-chip",
|
|
170
|
+
{ avatar: "avatar", border: "border", draggableChip: "?draggable-chip", fieldAriaLabel: "field-aria-label", label: "label", leadingIcon: "leading-icon", presentational: "?presentational", removable: "?removable", removed: "?removed", size: "size", tone: "tone", trailingIcon: "trailing-icon", variant: "variant" },
|
|
171
|
+
{ onChipMove: "chip-move", onRemoved: "removed" }
|
|
172
|
+
);
|
|
173
|
+
var LofContainer = /* @__PURE__ */ createComponent(
|
|
174
|
+
"lof-container",
|
|
175
|
+
{ background: "background", padding: "padding", shadow: "?shadow", surface: "surface" },
|
|
176
|
+
{}
|
|
177
|
+
);
|
|
178
|
+
var LofDatePicker = /* @__PURE__ */ createComponent(
|
|
179
|
+
"lof-date-picker",
|
|
180
|
+
{ clearable: "?clearable", closeOnSelect: "?close-on-select", disabled: "?disabled", displayFormat: "display-format", error: "?error", errorMessage: "error-message", formatDate: null, fullWidth: "?full-width", helperText: "helper-text", isDateDisabled: null, label: "label", locale: "locale", max: "max", maxDate: "max-date", min: "min", minDate: "min-date", name: "name", open: "?open", placeholder: "placeholder", readonly: "?readonly", required: "?required", showShortcuts: null, size: "size", value: "value", variant: "variant", weekStart: "week-start" },
|
|
181
|
+
{ onLofBlur: "lof-blur", onLofChange: "lof-change", onLofOpenChange: "lof-open-change" }
|
|
182
|
+
);
|
|
183
|
+
var LofDivider = /* @__PURE__ */ createComponent(
|
|
184
|
+
"lof-divider",
|
|
185
|
+
{ orientation: "orientation" },
|
|
186
|
+
{}
|
|
187
|
+
);
|
|
188
|
+
var LofDrawer = /* @__PURE__ */ createComponent(
|
|
189
|
+
"lof-drawer",
|
|
190
|
+
{ closeOnBackdrop: "?close-on-backdrop", closeOnEscape: "?close-on-escape", description: "description", dismissible: "?dismissible", draggable: "?draggable", maxHeight: "max-height", modal: "?modal", open: "?open", showHandle: "?show-handle", side: "side", snapThreshold: "snap-threshold", title: "title", width: "width" },
|
|
191
|
+
{ onLofOpenChange: "lof-open-change" }
|
|
192
|
+
);
|
|
193
|
+
var LofDrawerFooter = /* @__PURE__ */ createComponent(
|
|
194
|
+
"lof-drawer-footer",
|
|
195
|
+
{},
|
|
196
|
+
{}
|
|
197
|
+
);
|
|
198
|
+
var LofKbd = /* @__PURE__ */ createComponent(
|
|
199
|
+
"lof-kbd",
|
|
200
|
+
{ inset: "?inset", keyName: "key-name", pill: "?pill", platform: "platform", size: "size", variant: "variant" },
|
|
201
|
+
{}
|
|
202
|
+
);
|
|
203
|
+
var LofKbdGroup = /* @__PURE__ */ createComponent(
|
|
204
|
+
"lof-kbd-group",
|
|
205
|
+
{ items: null, platform: "platform", size: "size", variant: "variant" },
|
|
206
|
+
{}
|
|
207
|
+
);
|
|
208
|
+
var LofLayout = /* @__PURE__ */ createComponent(
|
|
209
|
+
"lof-layout",
|
|
210
|
+
{ columns: "columns", gap: "gap", responsive: "?responsive" },
|
|
211
|
+
{}
|
|
212
|
+
);
|
|
213
|
+
var LofMenu = /* @__PURE__ */ createComponent(
|
|
214
|
+
"lof-menu",
|
|
215
|
+
{ items: null, size: "size", type: "type", width: "width" },
|
|
216
|
+
{ onLofCheck: "lof-check", onLofSelect: "lof-select", onLofSubmenuSelect: "lof-submenu-select" }
|
|
217
|
+
);
|
|
218
|
+
var LofMenuItem = /* @__PURE__ */ createComponent(
|
|
219
|
+
"lof-menu-item",
|
|
220
|
+
{ disabled: "?disabled", icon: "icon", label: "label", value: "value" },
|
|
221
|
+
{}
|
|
222
|
+
);
|
|
223
|
+
var LofMenubar = /* @__PURE__ */ createComponent(
|
|
224
|
+
"lof-menubar",
|
|
225
|
+
{ bindShortcuts: "?bind-shortcuts", type: "type" },
|
|
226
|
+
{ onLofMenubarChange: "lof-menubar-change", onLofMenubarSelect: "lof-menubar-select" }
|
|
227
|
+
);
|
|
228
|
+
var LofMenubarMenu = /* @__PURE__ */ createComponent(
|
|
229
|
+
"lof-menubar-menu",
|
|
230
|
+
{ disabled: "?disabled", label: "label" },
|
|
231
|
+
{}
|
|
232
|
+
);
|
|
233
|
+
var LofModal = /* @__PURE__ */ createComponent(
|
|
234
|
+
"lof-modal",
|
|
235
|
+
{ autoFocus: "?auto-focus", breakpoint: "breakpoint", closeOnBackdropClick: "?close-on-backdrop-click", closeOnEscape: "?close-on-escape", description: "description", disabled: "?disabled", dismissible: "?dismissible", loading: "?loading", modal: "?modal", open: "?open", restoreFocus: "?restore-focus", scrollable: "?scrollable", showCloseButton: "?show-close-button", side: "side", size: "size", subtitle: "subtitle", title: "title", variant: "variant", zIndex: "z-index" },
|
|
236
|
+
{ onLofOpenChange: "lof-open-change" }
|
|
237
|
+
);
|
|
238
|
+
var LofOtp = /* @__PURE__ */ createComponent(
|
|
239
|
+
"lof-otp",
|
|
240
|
+
{ ariaLabel: "aria-label", autocomplete: "autocomplete", disabled: "?disabled", groupSize: "group-size", inputmode: "inputmode", inputMode: "input-mode", invalid: "?invalid", length: "length", mask: "?mask", name: "name", pattern: "pattern", placeholder: "placeholder", readonly: "?readonly", required: "?required", showSeparator: "?show-separator", size: "size", type: "type", value: "value" },
|
|
241
|
+
{ onLofChange: "lof-change", onLofComplete: "lof-complete" }
|
|
242
|
+
);
|
|
243
|
+
var LofPagination = /* @__PURE__ */ createComponent(
|
|
244
|
+
"lof-pagination",
|
|
245
|
+
{ ariaLabel: "arialabel", defaultPage: "default-page", disabled: "?disabled", hrefTemplate: "href-template", page: "page", perPage: "per-page", rowsPerPageLabel: "rows-per-page-label", rowsPerPageOptions: null, showLabel: "?show-label", showRowsPerPage: "?show-rows-per-page", totalItems: "total-items", totalPages: "total-pages", type: "type" },
|
|
246
|
+
{ onLofChange: "lof-change", onLofPerPageChange: "lof-per-page-change" }
|
|
247
|
+
);
|
|
248
|
+
var LofPopover = /* @__PURE__ */ createComponent(
|
|
249
|
+
"lof-popover",
|
|
250
|
+
{ align: "align", alignOffset: "align-offset", arrow: "?arrow", closeOnEscape: "?close-on-escape", closeOnOutsideClick: "?close-on-outside-click", defaultOpen: "?default-open", disabled: "?disabled", hasPopup: "has-popup", open: "?open", side: "side", sideOffset: "side-offset", trapFocus: "?trap-focus" },
|
|
251
|
+
{ onLofOpenChange: "lof-open-change" }
|
|
252
|
+
);
|
|
253
|
+
var LofPopoverContent = /* @__PURE__ */ createComponent(
|
|
254
|
+
"lof-popover-content",
|
|
255
|
+
{ ariaLabel: "aria-label", size: "size" },
|
|
256
|
+
{}
|
|
257
|
+
);
|
|
258
|
+
var LofProgress = /* @__PURE__ */ createComponent(
|
|
259
|
+
"lof-progress",
|
|
260
|
+
{ label: "label", mode: "mode", value: "value" },
|
|
261
|
+
{}
|
|
262
|
+
);
|
|
263
|
+
var LofRadio = /* @__PURE__ */ createComponent(
|
|
264
|
+
"lof-radio",
|
|
265
|
+
{ alignment: "alignment", density: "density", disabled: "?disabled", error: "?error", errorMessage: "error-message", fieldAriaLabel: "field-aria-label", name: "name", options: null, orientation: "orientation", selectedValue: "selected-value", size: "size", value: "value" },
|
|
266
|
+
{ onLofChange: "lof-change" }
|
|
267
|
+
);
|
|
268
|
+
var LofRangePicker = /* @__PURE__ */ createComponent(
|
|
269
|
+
"lof-range-picker",
|
|
270
|
+
{ clearable: "?clearable", disabled: "?disabled", from: "from", fullWidth: "?full-width", height: "height", locale: "locale", maxDate: "max-date", maxHeight: "max-height", maxWidth: "max-width", minDate: "min-date", minHeight: "min-height", minWidth: "min-width", mode: "mode", open: "?open", placeholder: "placeholder", size: "size", to: "to", triggerVariant: "trigger-variant", weekStart: "week-start", width: "width" },
|
|
271
|
+
{ onLofBlur: "lof-blur", onLofChange: "lof-change", onLofOpenChange: "lof-open-change" }
|
|
272
|
+
);
|
|
273
|
+
var LofResizableGroup = /* @__PURE__ */ createComponent(
|
|
274
|
+
"lof-resizable-group",
|
|
275
|
+
{ direction: "direction" },
|
|
276
|
+
{ onLofResize: "lof-resize", onLofResizeEnd: "lof-resize-end" }
|
|
277
|
+
);
|
|
278
|
+
var LofResizableHandle = /* @__PURE__ */ createComponent(
|
|
279
|
+
"lof-resizable-handle",
|
|
280
|
+
{ orientation: "orientation" },
|
|
281
|
+
{}
|
|
282
|
+
);
|
|
283
|
+
var LofResizablePanel = /* @__PURE__ */ createComponent(
|
|
284
|
+
"lof-resizable-panel",
|
|
285
|
+
{ defaultSize: "default-size", maxSize: "max-size", minSize: "min-size", panelLabel: "panel-label" },
|
|
286
|
+
{}
|
|
287
|
+
);
|
|
288
|
+
var LofSegmentedButton = /* @__PURE__ */ createComponent(
|
|
289
|
+
"lof-segmented-button",
|
|
290
|
+
{ active: "active", align: "align", disabled: "?disabled", fieldAriaLabel: "field-aria-label", options: null, size: "size" },
|
|
291
|
+
{ onChanged: "changed", onLofChange: "lof-change" }
|
|
292
|
+
);
|
|
293
|
+
var LofSelect = /* @__PURE__ */ createComponent(
|
|
294
|
+
"lof-select",
|
|
295
|
+
{ border: "border", fieldAriaLabel: "field-aria-label", fieldAriaLabelledby: "field-aria-labelledby", label: "label", labelStyle: "label-style", leftIcon: "left-icon", maxVisibleChips: "max-visible-chips", multiple: "?multiple", noSearch: "?no-search", options: null, placeholder: "placeholder", rightIcon: "right-icon", searchPlaceholder: "search-placeholder", selectAllLabel: "select-all-label", selected: "selected", selectedValues: null, size: "size", state: "state", supportingIcon: "supporting-icon", supportingText: "supporting-text" },
|
|
296
|
+
{ onChanged: "changed", onLofChange: "lof-change" }
|
|
297
|
+
);
|
|
298
|
+
var LofSignaturePad = /* @__PURE__ */ createComponent(
|
|
299
|
+
"lof-signature-pad",
|
|
300
|
+
{ disabled: "?disabled", disabledText: "disabled-text", error: "?error", errorMessage: "error-message", fieldAriaLabel: "field-aria-label", helperText: "helper-text", label: "label", mode: "mode", name: "name", placeholder: "placeholder", readonly: "?readonly", required: "?required", strokes: null, typedName: "typed-name", value: null },
|
|
301
|
+
{ onLofBegin: "lof-begin", onLofChange: "lof-change", onLofEnd: "lof-end" }
|
|
302
|
+
);
|
|
303
|
+
var LofSkeleton = /* @__PURE__ */ createComponent(
|
|
304
|
+
"lof-skeleton",
|
|
305
|
+
{ animation: "animation", height: "height", lines: "lines", loaded: "?loaded", shape: "shape", width: "width" },
|
|
306
|
+
{}
|
|
307
|
+
);
|
|
308
|
+
var LofSlider = /* @__PURE__ */ createComponent(
|
|
309
|
+
"lof-slider",
|
|
310
|
+
{ disabled: "?disabled", fieldAriaLabel: "field-aria-label", max: "max", min: "min", showBubble: "?show-bubble", showTickLabels: "?show-tick-labels", showTicks: "?show-ticks", size: "size", step: "step", track: "track", type: "type", value: "value", valueEnd: "value-end" },
|
|
311
|
+
{ onLofChange: "lof-change" }
|
|
312
|
+
);
|
|
313
|
+
var LofSnackbar = /* @__PURE__ */ createComponent(
|
|
314
|
+
"lof-snackbar",
|
|
315
|
+
{ action: "action", duration: "duration", iconClose: "?icon-close", lines: "lines", longerAction: "?longeraction", message: "message", show: "?show", tone: "tone", type: "type", variant: "variant" },
|
|
316
|
+
{ onActionClick: "actionClick", onClose: "close" }
|
|
317
|
+
);
|
|
318
|
+
var LofSplitButton = /* @__PURE__ */ createComponent(
|
|
319
|
+
"lof-split-button",
|
|
320
|
+
{ ariaLabel: "aria-label", disabled: "?disabled", icon: "icon", iconOnly: "?icon-only", items: null, label: "label", loading: "?loading", menuLabel: "menu-label", open: "?open", size: "size", tone: "tone", variant: "variant" },
|
|
321
|
+
{ onLofOpenChange: "lof-open-change", onLofSelect: "lof-select" }
|
|
322
|
+
);
|
|
323
|
+
var LofStepper = /* @__PURE__ */ createComponent(
|
|
324
|
+
"lof-stepper",
|
|
325
|
+
{ connector: "connector", labelPlacement: "label-placement", orientation: "orientation", size: "size", steps: null, textAlign: "textalign", type: "type" },
|
|
326
|
+
{ onLofStepChange: "lof-step-change" }
|
|
327
|
+
);
|
|
328
|
+
var LofSwitch = /* @__PURE__ */ createComponent(
|
|
329
|
+
"lof-switch",
|
|
330
|
+
{ checked: "?checked", disabled: "?disabled", fieldAriaLabel: "field-aria-label", label: "label", labelPlacement: "label-placement", size: "size", type: "type", value: "value" },
|
|
331
|
+
{ onLofChange: "lof-change" }
|
|
332
|
+
);
|
|
333
|
+
var LofTab = /* @__PURE__ */ createComponent(
|
|
334
|
+
"lof-tab",
|
|
335
|
+
{ activeIndex: "active-index", iconPlacement: "icon-placement", orientation: "orientation", size: "size", tabs: null },
|
|
336
|
+
{ onLofChange: "lof-change", onLofTabChange: "lof-tab-change" }
|
|
337
|
+
);
|
|
338
|
+
var LofTabItem = /* @__PURE__ */ createComponent(
|
|
339
|
+
"lof-tab-item",
|
|
340
|
+
{ badge: "badge", badgeDot: "?badge-dot", disabled: "?disabled", icon: "icon", label: "label", value: "value" },
|
|
341
|
+
{}
|
|
342
|
+
);
|
|
343
|
+
var LofTextfield = /* @__PURE__ */ createComponent(
|
|
344
|
+
"lof-textfield",
|
|
345
|
+
{ clickableRightIcon: "?clickable-right-icon", disabled: "?disabled", error: "?error", errorMessage: "error-message", fieldAriaLabel: "field-aria-label", fieldAriaLabelledby: "field-aria-labelledby", floatingLabel: "?floatinglabel", fullWidth: "?full-width", helperIcon: "helper-icon", helperText: "helper-text", label: "label", labelStyle: "label-style", leftIcon: "left-icon", maxLength: "maxlength", multiline: "?multiline", name: "name", placeholder: "placeholder", prefixIcon: "prefix-icon", prefixIconAriaLabel: "prefix-icon-aria-label", prefixStyle: "prefix-style", prefixText: "prefix-text", readonly: "?readonly", required: "?required", rightIcon: "right-icon", rightIconAriaLabel: "right-icon-aria-label", rows: "rows", size: "size", state: "state", suffixDivider: "?suffix-divider", suffixText: "suffix-text", supportingText: "supportingtext", type: "type", value: "value", variant: "variant" },
|
|
346
|
+
{ onLofChange: "lof-change", onLofRightIconClick: "lof-right-icon-click" }
|
|
347
|
+
);
|
|
348
|
+
var LofTimePicker = /* @__PURE__ */ createComponent(
|
|
349
|
+
"lof-time-picker",
|
|
350
|
+
{ clearable: "?clearable", disabled: "?disabled", error: "?error", errorMessage: "error-message", format: "format", fullWidth: "?full-width", helperText: "helper-text", invalid: "?invalid", label: "label", maxTime: "max-time", minTime: "min-time", minuteStep: "minute-step", name: "name", open: "?open", placeholder: "placeholder", readonly: "?readonly", required: "?required", seconds: "?seconds", size: "size", value: "value", variant: "variant" },
|
|
351
|
+
{ onLofBlur: "lof-blur", onLofChange: "lof-change", onLofFocus: "lof-focus", onLofOpenChange: "lof-open-change" }
|
|
352
|
+
);
|
|
353
|
+
var LofToast = /* @__PURE__ */ createComponent(
|
|
354
|
+
"lof-toast",
|
|
355
|
+
{ actionLabel: "action-label", dismissible: "?dismissible", duration: "duration", maxVisible: "max-visible", message: "message", position: "position", show: "?show", size: "size", tone: "tone", type: "type" },
|
|
356
|
+
{ onAction: "action", onDismissed: "dismissed" }
|
|
357
|
+
);
|
|
358
|
+
var LofTooltip = /* @__PURE__ */ createComponent(
|
|
359
|
+
"lof-tooltip",
|
|
360
|
+
{ position: "position", showTail: "?show-tail", text: "text", tone: "tone", type: "type" },
|
|
361
|
+
{}
|
|
362
|
+
);
|
|
363
|
+
var LofTree = /* @__PURE__ */ createComponent(
|
|
364
|
+
"lof-tree",
|
|
365
|
+
{ expandedValues: null, fieldAriaLabel: "field-aria-label", items: null, selected: "selected", selectedValues: null, selection: "selection", showGuides: "?show-guides" },
|
|
366
|
+
{ onLofChange: "lof-change", onLofExpandedChange: "lof-expanded-change", onLofLoadChildren: "lof-load-children" }
|
|
367
|
+
);
|
|
368
|
+
var LofUpload = /* @__PURE__ */ createComponent(
|
|
369
|
+
"lof-upload",
|
|
370
|
+
{ accept: "accept", browseLabel: "browse-label", concurrency: "concurrency", delayThreshold: "delay-threshold", disabled: "?disabled", dropzoneTitle: "dropzone-title", files: null, hint: "hint", maxFiles: "max-files", maxSize: "max-size", multiple: "?multiple", uploader: null },
|
|
371
|
+
{ onLofCancel: "lof-cancel", onLofChange: "lof-change", onLofComplete: "lof-complete", onLofFileComplete: "lof-file-complete", onLofFileError: "lof-file-error", onLofFileReplaced: "lof-file-replaced", onLofFilesAdded: "lof-files-added", onLofInvalid: "lof-invalid", onLofProgress: "lof-progress", onLofRemove: "lof-remove", onLofRetry: "lof-retry", onLofState: "lof-state", onLofUpload: "lof-upload", onLofUploadComplete: "lof-upload-complete" }
|
|
372
|
+
);
|
|
373
|
+
var LofUploadActions = /* @__PURE__ */ createComponent(
|
|
374
|
+
"lof-upload-actions",
|
|
375
|
+
{ cancelLabel: "cancel-label", for: "for", noCancel: "?no-cancel" },
|
|
376
|
+
{ onLofCancel: "lof-cancel" }
|
|
377
|
+
);
|
|
378
|
+
var WRAPPED_TAGS = [
|
|
379
|
+
"lof-accordion",
|
|
380
|
+
"lof-alert",
|
|
381
|
+
"lof-autocomplete",
|
|
382
|
+
"lof-avatar",
|
|
383
|
+
"lof-avatar-group",
|
|
384
|
+
"lof-badge",
|
|
385
|
+
"lof-breadcrumbs",
|
|
386
|
+
"lof-button",
|
|
387
|
+
"lof-calendar",
|
|
388
|
+
"lof-card",
|
|
389
|
+
"lof-card-media",
|
|
390
|
+
"lof-carousel",
|
|
391
|
+
"lof-checkbox",
|
|
392
|
+
"lof-chip",
|
|
393
|
+
"lof-container",
|
|
394
|
+
"lof-date-picker",
|
|
395
|
+
"lof-divider",
|
|
396
|
+
"lof-drawer",
|
|
397
|
+
"lof-drawer-footer",
|
|
398
|
+
"lof-kbd",
|
|
399
|
+
"lof-kbd-group",
|
|
400
|
+
"lof-layout",
|
|
401
|
+
"lof-menu",
|
|
402
|
+
"lof-menu-item",
|
|
403
|
+
"lof-menubar",
|
|
404
|
+
"lof-menubar-menu",
|
|
405
|
+
"lof-modal",
|
|
406
|
+
"lof-otp",
|
|
407
|
+
"lof-pagination",
|
|
408
|
+
"lof-popover",
|
|
409
|
+
"lof-popover-content",
|
|
410
|
+
"lof-progress",
|
|
411
|
+
"lof-radio",
|
|
412
|
+
"lof-range-picker",
|
|
413
|
+
"lof-resizable-group",
|
|
414
|
+
"lof-resizable-handle",
|
|
415
|
+
"lof-resizable-panel",
|
|
416
|
+
"lof-segmented-button",
|
|
417
|
+
"lof-select",
|
|
418
|
+
"lof-signature-pad",
|
|
419
|
+
"lof-skeleton",
|
|
420
|
+
"lof-slider",
|
|
421
|
+
"lof-snackbar",
|
|
422
|
+
"lof-split-button",
|
|
423
|
+
"lof-stepper",
|
|
424
|
+
"lof-switch",
|
|
425
|
+
"lof-tab",
|
|
426
|
+
"lof-tab-item",
|
|
427
|
+
"lof-textfield",
|
|
428
|
+
"lof-time-picker",
|
|
429
|
+
"lof-toast",
|
|
430
|
+
"lof-tooltip",
|
|
431
|
+
"lof-tree",
|
|
432
|
+
"lof-upload",
|
|
433
|
+
"lof-upload-actions"
|
|
434
|
+
];
|
|
435
|
+
|
|
436
|
+
// src/index.ts
|
|
437
|
+
var defined;
|
|
438
|
+
function defineElements() {
|
|
439
|
+
if (typeof window === "undefined") return Promise.resolve();
|
|
440
|
+
defined ??= import("@lofid/web").then(() => void 0);
|
|
441
|
+
return defined;
|
|
442
|
+
}
|
|
443
|
+
export {
|
|
444
|
+
LofAccordion,
|
|
445
|
+
LofAlert,
|
|
446
|
+
LofAutocomplete,
|
|
447
|
+
LofAvatar,
|
|
448
|
+
LofAvatarGroup,
|
|
449
|
+
LofBadge,
|
|
450
|
+
LofBreadcrumbs,
|
|
451
|
+
LofButton,
|
|
452
|
+
LofCalendar,
|
|
453
|
+
LofCard,
|
|
454
|
+
LofCardMedia,
|
|
455
|
+
LofCarousel,
|
|
456
|
+
LofCheckbox,
|
|
457
|
+
LofChip,
|
|
458
|
+
LofContainer,
|
|
459
|
+
LofDatePicker,
|
|
460
|
+
LofDivider,
|
|
461
|
+
LofDrawer,
|
|
462
|
+
LofDrawerFooter,
|
|
463
|
+
LofKbd,
|
|
464
|
+
LofKbdGroup,
|
|
465
|
+
LofLayout,
|
|
466
|
+
LofMenu,
|
|
467
|
+
LofMenuItem,
|
|
468
|
+
LofMenubar,
|
|
469
|
+
LofMenubarMenu,
|
|
470
|
+
LofModal,
|
|
471
|
+
LofOtp,
|
|
472
|
+
LofPagination,
|
|
473
|
+
LofPopover,
|
|
474
|
+
LofPopoverContent,
|
|
475
|
+
LofProgress,
|
|
476
|
+
LofRadio,
|
|
477
|
+
LofRangePicker,
|
|
478
|
+
LofResizableGroup,
|
|
479
|
+
LofResizableHandle,
|
|
480
|
+
LofResizablePanel,
|
|
481
|
+
LofSegmentedButton,
|
|
482
|
+
LofSelect,
|
|
483
|
+
LofSignaturePad,
|
|
484
|
+
LofSkeleton,
|
|
485
|
+
LofSlider,
|
|
486
|
+
LofSnackbar,
|
|
487
|
+
LofSplitButton,
|
|
488
|
+
LofStepper,
|
|
489
|
+
LofSwitch,
|
|
490
|
+
LofTab,
|
|
491
|
+
LofTabItem,
|
|
492
|
+
LofTextfield,
|
|
493
|
+
LofTimePicker,
|
|
494
|
+
LofToast,
|
|
495
|
+
LofTooltip,
|
|
496
|
+
LofTree,
|
|
497
|
+
LofUpload,
|
|
498
|
+
LofUploadActions,
|
|
499
|
+
WRAPPED_TAGS,
|
|
500
|
+
createComponent,
|
|
501
|
+
defineElements
|
|
502
|
+
};
|
|
503
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/create-component.ts","../src/generated.ts","../src/index.ts"],"sourcesContent":["import {\n createElement,\n forwardRef,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n version,\n type ForwardRefExoticComponent,\n type HTMLAttributes,\n type ReactNode,\n type RefAttributes,\n} from \"react\";\n\n/** Event handler props, e.g. `{ onLofChange: (e: CustomEvent<{ value: string }>) => void }`. */\nexport type EventHandlers<Events> = { [K in keyof Events]?: (event: Events[K]) => void };\n\n/**\n * Props of a wrapper: the element's public properties (typed from the element class),\n * its event handlers, and ordinary HTML attributes (className, style, id, slot, aria-*, data-*).\n */\nexport type LofProps<E extends HTMLElement, P extends keyof E, Events> = { [K in P]?: E[K] } & EventHandlers<Events> &\n Omit<HTMLAttributes<E>, P | keyof Events> & { children?: ReactNode };\n\nexport type LofComponent<E extends HTMLElement, P extends keyof E, Events> = ForwardRefExoticComponent<\n LofProps<E, P, Events> & RefAttributes<E>\n>;\n\n// useLayoutEffect warns during server rendering; neither effect runs there anyway.\nconst useClientLayoutEffect = typeof window === \"undefined\" ? useEffect : useLayoutEffect;\n\nconst NO_DEFAULT = Symbol(\"no-default\");\n\n// React 18 writes `className` on a custom element as a literal \"classname\"\n// attribute; React 19 maps it to `class` itself.\nconst CLASS_PROP = Number.parseInt(version, 10) >= 19 ? \"className\" : \"class\";\n\n/**\n * How a property also renders as an attribute: `\"attr\"` for strings and numbers,\n * `\"?attr\"` for booleans (present only when `true`), `null` for property-only\n * values such as arrays, objects and functions.\n */\nexport type AttributeSpec = string | null;\n\n/**\n * Builds a React component that renders `tag` and bridges what React 18 cannot:\n *\n * - **Properties.** Every key of `props` is assigned to the element as a JS\n * property after each render, before paint. React 18 alone would set a string\n * attribute, which breaks arrays, objects, `false` booleans and camelCase names\n * whose attribute differs (`selectedValues` is `selected-values`). A property\n * dropped from the props goes back to the element's default.\n * - **Attributes.** Strings, numbers and `true` booleans are also rendered under\n * their attribute name, so server-rendered HTML carries them and the element\n * looks right the moment it is defined, before React hydrates.\n * - **Events.** Each `onX` key of `events` listens for the custom event it names.\n * Only events the element itself dispatches reach the handler: the events bubble,\n * so a `<LofSelect>` inside a `<LofTab>` would otherwise call the tab's\n * `onLofChange` with the select's detail.\n *\n * Nothing here imports the web package, so wrappers render on the server as plain\n * tags. Register the elements once on the client (see `defineElements`).\n */\nexport function createComponent<E extends HTMLElement, P extends keyof E & string, Events extends Record<string, Event>>(\n tag: string,\n props: { readonly [K in P]: AttributeSpec },\n events: { readonly [K in keyof Events]: string }\n): LofComponent<E, P, Events> {\n const specs = props as Record<string, AttributeSpec>;\n const eventEntries = Object.entries(events) as [keyof Events & string, string][];\n\n const Component = forwardRef<E, LofProps<E, P, Events>>((props, forwardedRef) => {\n const node = useRef<E | null>(null);\n const handlers = useRef<Record<string, unknown>>({});\n const defaults = useRef(new Map<string, unknown>());\n const applied = useRef(new Set<string>());\n\n const domProps: Record<string, unknown> = {};\n const attributes: Record<string, unknown> = {};\n const elementProps: Record<string, unknown> = {};\n const handlerProps: Record<string, unknown> = {};\n for (const key in props) {\n const value = (props as Record<string, unknown>)[key];\n if (key in events) handlerProps[key] = value;\n else if (key in specs) {\n elementProps[key] = value;\n const spec = specs[key];\n if (spec === null || value == null) continue;\n if (spec[0] === \"?\") {\n if (value === true) attributes[spec.slice(1)] = true;\n } else if (typeof value === \"string\" || typeof value === \"number\") attributes[spec] = value;\n } else domProps[key === \"className\" ? CLASS_PROP : key] = value;\n }\n handlers.current = handlerProps;\n\n useClientLayoutEffect(() => {\n const el = node.current as unknown as Record<string, unknown> | null;\n if (!el) return;\n const upgraded = customElements.get(tag) !== undefined;\n for (const key in elementProps) {\n if (!defaults.current.has(key)) defaults.current.set(key, upgraded ? el[key] : NO_DEFAULT);\n const value = elementProps[key];\n if (el[key] !== value) el[key] = value;\n applied.current.add(key);\n }\n for (const key of applied.current) {\n if (key in elementProps) continue;\n const fallback = defaults.current.get(key);\n el[key] = fallback === NO_DEFAULT ? undefined : fallback;\n applied.current.delete(key);\n }\n });\n\n // Lit keeps properties set before the element upgrades, but only its reactive\n // ones. Any other accessor (lof-checkbox `checked`) would stay shadowed by the\n // own property, so re-assign those once the class is defined.\n useClientLayoutEffect(() => {\n if (customElements.get(tag)) return;\n let live = true;\n customElements.whenDefined(tag).then(() => {\n const el = node.current as unknown as Record<string, unknown> | null;\n if (!live || !el) return;\n for (const key of applied.current) {\n if (!Object.prototype.hasOwnProperty.call(el, key)) continue;\n const value = el[key];\n delete el[key];\n el[key] = value;\n }\n });\n return () => {\n live = false;\n };\n }, []);\n\n useClientLayoutEffect(() => {\n const el = node.current;\n if (!el || eventEntries.length === 0) return;\n const off = eventEntries.map(([prop, type]) => {\n const listener = (event: Event) => {\n if (event.target !== el) return;\n (handlers.current[prop] as ((e: Event) => void) | undefined)?.(event);\n };\n el.addEventListener(type, listener);\n return () => el.removeEventListener(type, listener);\n });\n return () => off.forEach((fn) => fn());\n }, []);\n\n const ref = useCallback(\n (el: E | null) => {\n node.current = el;\n if (typeof forwardedRef === \"function\") forwardedRef(el);\n else if (forwardedRef) forwardedRef.current = el;\n },\n [forwardedRef]\n );\n\n return createElement(tag, { ...domProps, ...attributes, ref });\n });\n Component.displayName = tag\n .split(\"-\")\n .map((p) => p[0].toUpperCase() + p.slice(1))\n .join(\"\");\n return Component as LofComponent<E, P, Events>;\n}\n","// Generated by scripts/generate.mjs from packages/web/src. Do not edit by hand:\n// change the web component, then run `npm run generate -w @lofid/react`.\n\nimport type * as W from \"@lofid/web\";\nimport { createComponent } from \"./create-component\";\n\n/** React wrapper for `<lof-accordion>`. */\nexport const LofAccordion = /* @__PURE__ */ createComponent<W.LofAccordion, \"appearance\" | \"contentType\" | \"disabled\" | \"open\" | \"size\" | \"title\" | \"type\", { onOpenChange: CustomEvent<boolean> }>(\n \"lof-accordion\",\n { appearance: \"appearance\", contentType: \"content-type\", disabled: \"?disabled\", open: \"?open\", size: \"size\", title: \"title\", type: \"type\" },\n { onOpenChange: \"open-change\" },\n);\n\n/** React wrapper for `<lof-alert>`. */\nexport const LofAlert = /* @__PURE__ */ createComponent<W.LofAlert, \"appearance\" | \"dismissed\" | \"dismissible\" | \"message1\" | \"message2\" | \"tone\" | \"type\" | \"urlHref\" | \"urlText\", { onDismiss: CustomEvent<undefined> }>(\n \"lof-alert\",\n { appearance: \"appearance\", dismissed: \"?dismissed\", dismissible: \"?dismissible\", message1: \"message1\", message2: \"message2\", tone: \"tone\", type: \"type\", urlHref: \"url-href\", urlText: \"url-text\" },\n { onDismiss: \"dismiss\" },\n);\n\n/** React wrapper for `<lof-autocomplete>`. */\nexport const LofAutocomplete = /* @__PURE__ */ createComponent<W.LofAutocomplete, \"clearable\" | \"debounceMs\" | \"disabled\" | \"displayField\" | \"error\" | \"errorMessage\" | \"fieldAriaLabel\" | \"fieldAriaLabelledby\" | \"filter\" | \"floatingLabel\" | \"fullWidth\" | \"helperText\" | \"items\" | \"label\" | \"labelStyle\" | \"loading\" | \"loadingText\" | \"maxSuggestions\" | \"minSearchLength\" | \"multiple\" | \"name\" | \"noResultsText\" | \"placeholder\" | \"prefixIcon\" | \"readonly\" | \"required\" | \"searchFn\" | \"selectAllLabel\" | \"selectedValues\" | \"size\" | \"supportingField\" | \"value\" | \"valueField\" | \"variant\", { onChanged: CustomEvent<{ value: string; item: W.AutocompleteItem; } | { value: string[]; item: null; } | { value: string; item: null; }>; onLofChange: CustomEvent<string>; onLofClear: CustomEvent<undefined>; onLofSearchError: CustomEvent<{ query: string; error: unknown; }> }>(\n \"lof-autocomplete\",\n { clearable: \"?clearable\", debounceMs: \"debounce-ms\", disabled: \"?disabled\", displayField: \"display-field\", error: \"?error\", errorMessage: \"error-message\", fieldAriaLabel: \"field-aria-label\", fieldAriaLabelledby: \"field-aria-labelledby\", filter: \"filter\", floatingLabel: \"?floating-label\", fullWidth: \"?full-width\", helperText: \"helper-text\", items: null, label: \"label\", labelStyle: \"label-style\", loading: \"?loading\", loadingText: \"loading-text\", maxSuggestions: \"max-suggestions\", minSearchLength: \"min-search-length\", multiple: \"?multiple\", name: \"name\", noResultsText: \"no-results-text\", placeholder: \"placeholder\", prefixIcon: \"prefix-icon\", readonly: \"?readonly\", required: \"?required\", searchFn: null, selectAllLabel: \"select-all-label\", selectedValues: null, size: \"size\", supportingField: \"supporting-field\", value: \"value\", valueField: \"value-field\", variant: \"variant\" },\n { onChanged: \"changed\", onLofChange: \"lof-change\", onLofClear: \"lof-clear\", onLofSearchError: \"lof-search-error\" },\n);\n\n/** React wrapper for `<lof-avatar>`. */\nexport const LofAvatar = /* @__PURE__ */ createComponent<W.LofAvatar, \"alt\" | \"badge\" | \"badgeIcon\" | \"badgeLabel\" | \"bg\" | \"color\" | \"icon\" | \"ring\" | \"size\" | \"src\" | \"text\" | \"type\" | \"variant\", {}>(\n \"lof-avatar\",\n { alt: \"alt\", badge: \"badge\", badgeIcon: \"badge-icon\", badgeLabel: \"badge-label\", bg: \"bg\", color: \"color\", icon: \"icon\", ring: \"?ring\", size: \"size\", src: \"src\", text: \"text\", type: \"type\", variant: \"variant\" },\n {},\n);\n\n/** React wrapper for `<lof-avatar-group>`. */\nexport const LofAvatarGroup = /* @__PURE__ */ createComponent<W.LofAvatarGroup, \"label\" | \"max\" | \"overflowLabel\" | \"size\" | \"total\", {}>(\n \"lof-avatar-group\",\n { label: \"label\", max: \"max\", overflowLabel: \"overflow-label\", size: \"size\", total: \"total\" },\n {},\n);\n\n/** React wrapper for `<lof-badge>`. */\nexport const LofBadge = /* @__PURE__ */ createComponent<W.LofBadge, \"ariaLabel\" | \"color\" | \"live\" | \"number\" | \"size\" | \"suffix\" | \"textColor\" | \"variant\", {}>(\n \"lof-badge\",\n { ariaLabel: \"arialabel\", color: \"color\", live: \"?live\", number: \"number\", size: \"size\", suffix: \"suffix\", textColor: \"text-color\", variant: \"variant\" },\n {},\n);\n\n/** React wrapper for `<lof-breadcrumbs>`. */\nexport const LofBreadcrumbs = /* @__PURE__ */ createComponent<W.LofBreadcrumbs, \"ariaLabel\" | \"items\", {}>(\n \"lof-breadcrumbs\",\n { ariaLabel: \"aria-label\", items: null },\n {},\n);\n\n/** React wrapper for `<lof-button>`. */\nexport const LofButton = /* @__PURE__ */ createComponent<W.LofButton, \"ariaLabel\" | \"badge\" | \"badgeDot\" | \"border\" | \"disabled\" | \"iconOnly\" | \"loading\" | \"size\" | \"tone\" | \"variant\", {}>(\n \"lof-button\",\n { ariaLabel: \"aria-label\", badge: \"badge\", badgeDot: \"?badge-dot\", border: \"border\", disabled: \"?disabled\", iconOnly: \"?icon-only\", loading: \"?loading\", size: \"size\", tone: \"tone\", variant: \"variant\" },\n {},\n);\n\n/** React wrapper for `<lof-calendar>`. */\nexport const LofCalendar = /* @__PURE__ */ createComponent<W.LofCalendar, \"disabled\" | \"isDateDisabled\" | \"locale\" | \"max\" | \"min\" | \"value\" | \"weekStart\", { onLofChange: CustomEvent<{ value: string; date: Date; }> }>(\n \"lof-calendar\",\n { disabled: \"?disabled\", isDateDisabled: null, locale: \"locale\", max: \"max\", min: \"min\", value: \"value\", weekStart: \"week-start\" },\n { onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-card>`. */\nexport const LofCard = /* @__PURE__ */ createComponent<W.LofCard, \"type\", {}>(\n \"lof-card\",\n { type: \"type\" },\n {},\n);\n\n/** React wrapper for `<lof-card-media>`. */\nexport const LofCardMedia = /* @__PURE__ */ createComponent<W.LofCardMedia, \"imageAlt\" | \"imageSrc\" | \"subtitle\" | \"title\", {}>(\n \"lof-card-media\",\n { imageAlt: \"image-alt\", imageSrc: \"image-src\", subtitle: \"subtitle\", title: \"title\" },\n {},\n);\n\n/** React wrapper for `<lof-carousel>`. */\nexport const LofCarousel = /* @__PURE__ */ createComponent<W.LofCarousel, \"autoplay\" | \"disabled\" | \"gap\" | \"interval\" | \"label\" | \"loop\" | \"orientation\" | \"panels\" | \"pauseOnHover\" | \"showButtons\" | \"showDots\" | \"type\" | \"value\", { onLofChange: CustomEvent<{ value: number; }> }>(\n \"lof-carousel\",\n { autoplay: \"?autoplay\", disabled: \"?disabled\", gap: \"gap\", interval: \"interval\", label: \"label\", loop: \"?loop\", orientation: \"orientation\", panels: \"panels\", pauseOnHover: \"?pause-on-hover\", showButtons: \"?show-buttons\", showDots: null, type: \"type\", value: \"value\" },\n { onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-checkbox>`. */\nexport const LofCheckbox = /* @__PURE__ */ createComponent<W.LofCheckbox, \"alignment\" | \"checked\" | \"density\" | \"disabled\" | \"fieldAriaLabel\" | \"icon\" | \"label\" | \"size\" | \"state\" | \"status\" | \"supportingtext\" | \"supportingText\" | \"value\", { onLofChange: CustomEvent<{ checked: boolean; value: string; }> }>(\n \"lof-checkbox\",\n { alignment: \"alignment\", checked: null, density: \"density\", disabled: \"?disabled\", fieldAriaLabel: \"field-aria-label\", icon: \"icon\", label: \"label\", size: \"size\", state: \"state\", status: \"status\", supportingtext: \"supporting-text\", supportingText: null, value: \"value\" },\n { onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-chip>`. */\nexport const LofChip = /* @__PURE__ */ createComponent<W.LofChip, \"avatar\" | \"border\" | \"draggableChip\" | \"fieldAriaLabel\" | \"label\" | \"leadingIcon\" | \"presentational\" | \"removable\" | \"removed\" | \"size\" | \"tone\" | \"trailingIcon\" | \"variant\", { onChipMove: CustomEvent<{ direction: number; }>; onRemoved: CustomEvent<undefined> }>(\n \"lof-chip\",\n { avatar: \"avatar\", border: \"border\", draggableChip: \"?draggable-chip\", fieldAriaLabel: \"field-aria-label\", label: \"label\", leadingIcon: \"leading-icon\", presentational: \"?presentational\", removable: \"?removable\", removed: \"?removed\", size: \"size\", tone: \"tone\", trailingIcon: \"trailing-icon\", variant: \"variant\" },\n { onChipMove: \"chip-move\", onRemoved: \"removed\" },\n);\n\n/** React wrapper for `<lof-container>`. */\nexport const LofContainer = /* @__PURE__ */ createComponent<W.LofContainer, \"background\" | \"padding\" | \"shadow\" | \"surface\", {}>(\n \"lof-container\",\n { background: \"background\", padding: \"padding\", shadow: \"?shadow\", surface: \"surface\" },\n {},\n);\n\n/** React wrapper for `<lof-date-picker>`. */\nexport const LofDatePicker = /* @__PURE__ */ createComponent<W.LofDatePicker, \"clearable\" | \"closeOnSelect\" | \"disabled\" | \"displayFormat\" | \"error\" | \"errorMessage\" | \"formatDate\" | \"fullWidth\" | \"helperText\" | \"isDateDisabled\" | \"label\" | \"locale\" | \"max\" | \"maxDate\" | \"min\" | \"minDate\" | \"name\" | \"open\" | \"placeholder\" | \"readonly\" | \"required\" | \"showShortcuts\" | \"size\" | \"value\" | \"variant\" | \"weekStart\", { onLofBlur: CustomEvent<undefined>; onLofChange: CustomEvent<{ value: string | null; date: Date; } | { value: null; date: null; }>; onLofOpenChange: CustomEvent<{ open: boolean; }> }>(\n \"lof-date-picker\",\n { clearable: \"?clearable\", closeOnSelect: \"?close-on-select\", disabled: \"?disabled\", displayFormat: \"display-format\", error: \"?error\", errorMessage: \"error-message\", formatDate: null, fullWidth: \"?full-width\", helperText: \"helper-text\", isDateDisabled: null, label: \"label\", locale: \"locale\", max: \"max\", maxDate: \"max-date\", min: \"min\", minDate: \"min-date\", name: \"name\", open: \"?open\", placeholder: \"placeholder\", readonly: \"?readonly\", required: \"?required\", showShortcuts: null, size: \"size\", value: \"value\", variant: \"variant\", weekStart: \"week-start\" },\n { onLofBlur: \"lof-blur\", onLofChange: \"lof-change\", onLofOpenChange: \"lof-open-change\" },\n);\n\n/** React wrapper for `<lof-divider>`. */\nexport const LofDivider = /* @__PURE__ */ createComponent<W.LofDivider, \"orientation\", {}>(\n \"lof-divider\",\n { orientation: \"orientation\" },\n {},\n);\n\n/** React wrapper for `<lof-drawer>`. */\nexport const LofDrawer = /* @__PURE__ */ createComponent<W.LofDrawer, \"closeOnBackdrop\" | \"closeOnEscape\" | \"description\" | \"dismissible\" | \"draggable\" | \"maxHeight\" | \"modal\" | \"open\" | \"showHandle\" | \"side\" | \"snapThreshold\" | \"title\" | \"width\", { onLofOpenChange: CustomEvent<{ open: boolean; }> }>(\n \"lof-drawer\",\n { closeOnBackdrop: \"?close-on-backdrop\", closeOnEscape: \"?close-on-escape\", description: \"description\", dismissible: \"?dismissible\", draggable: \"?draggable\", maxHeight: \"max-height\", modal: \"?modal\", open: \"?open\", showHandle: \"?show-handle\", side: \"side\", snapThreshold: \"snap-threshold\", title: \"title\", width: \"width\" },\n { onLofOpenChange: \"lof-open-change\" },\n);\n\n/** React wrapper for `<lof-drawer-footer>`. */\nexport const LofDrawerFooter = /* @__PURE__ */ createComponent<W.LofDrawerFooter, never, {}>(\n \"lof-drawer-footer\",\n {},\n {},\n);\n\n/** React wrapper for `<lof-kbd>`. */\nexport const LofKbd = /* @__PURE__ */ createComponent<W.LofKbd, \"inset\" | \"keyName\" | \"pill\" | \"platform\" | \"size\" | \"variant\", {}>(\n \"lof-kbd\",\n { inset: \"?inset\", keyName: \"key-name\", pill: \"?pill\", platform: \"platform\", size: \"size\", variant: \"variant\" },\n {},\n);\n\n/** React wrapper for `<lof-kbd-group>`. */\nexport const LofKbdGroup = /* @__PURE__ */ createComponent<W.LofKbdGroup, \"items\" | \"platform\" | \"size\" | \"variant\", {}>(\n \"lof-kbd-group\",\n { items: null, platform: \"platform\", size: \"size\", variant: \"variant\" },\n {},\n);\n\n/** React wrapper for `<lof-layout>`. */\nexport const LofLayout = /* @__PURE__ */ createComponent<W.LofLayout, \"columns\" | \"gap\" | \"responsive\", {}>(\n \"lof-layout\",\n { columns: \"columns\", gap: \"gap\", responsive: \"?responsive\" },\n {},\n);\n\n/** React wrapper for `<lof-menu>`. */\nexport const LofMenu = /* @__PURE__ */ createComponent<W.LofMenu, \"items\" | \"size\" | \"type\" | \"width\", { onLofCheck: CustomEvent<{ item: { checked: boolean; label: string; active?: boolean; disabled?: boolean; submenu?: W.MenuItem[]; open?: boolean; icon?: string; }; checked: boolean; }>; onLofSelect: CustomEvent<{ item: W.MenuItem; }>; onLofSubmenuSelect: CustomEvent<{ parent: W.MenuItem; sub: W.MenuItem | undefined; }> }>(\n \"lof-menu\",\n { items: null, size: \"size\", type: \"type\", width: \"width\" },\n { onLofCheck: \"lof-check\", onLofSelect: \"lof-select\", onLofSubmenuSelect: \"lof-submenu-select\" },\n);\n\n/** React wrapper for `<lof-menu-item>`. */\nexport const LofMenuItem = /* @__PURE__ */ createComponent<W.LofMenuItem, \"disabled\" | \"icon\" | \"label\" | \"value\", {}>(\n \"lof-menu-item\",\n { disabled: \"?disabled\", icon: \"icon\", label: \"label\", value: \"value\" },\n {},\n);\n\n/** React wrapper for `<lof-menubar>`. */\nexport const LofMenubar = /* @__PURE__ */ createComponent<W.LofMenubar, \"bindShortcuts\" | \"type\", { onLofMenubarChange: CustomEvent<W.MenubarChangeDetail>; onLofMenubarSelect: CustomEvent<W.MenubarSelectDetail | { label: string; value: string | undefined; shortcut: string | undefined; }> }>(\n \"lof-menubar\",\n { bindShortcuts: \"?bind-shortcuts\", type: \"type\" },\n { onLofMenubarChange: \"lof-menubar-change\", onLofMenubarSelect: \"lof-menubar-select\" },\n);\n\n/** React wrapper for `<lof-menubar-menu>`. */\nexport const LofMenubarMenu = /* @__PURE__ */ createComponent<W.LofMenubarMenu, \"disabled\" | \"label\", {}>(\n \"lof-menubar-menu\",\n { disabled: \"?disabled\", label: \"label\" },\n {},\n);\n\n/** React wrapper for `<lof-modal>`. */\nexport const LofModal = /* @__PURE__ */ createComponent<W.LofModal, \"autoFocus\" | \"breakpoint\" | \"closeOnBackdropClick\" | \"closeOnEscape\" | \"description\" | \"disabled\" | \"dismissible\" | \"loading\" | \"modal\" | \"open\" | \"restoreFocus\" | \"scrollable\" | \"showCloseButton\" | \"side\" | \"size\" | \"subtitle\" | \"title\" | \"variant\" | \"zIndex\", { onLofOpenChange: CustomEvent<boolean> }>(\n \"lof-modal\",\n { autoFocus: \"?auto-focus\", breakpoint: \"breakpoint\", closeOnBackdropClick: \"?close-on-backdrop-click\", closeOnEscape: \"?close-on-escape\", description: \"description\", disabled: \"?disabled\", dismissible: \"?dismissible\", loading: \"?loading\", modal: \"?modal\", open: \"?open\", restoreFocus: \"?restore-focus\", scrollable: \"?scrollable\", showCloseButton: \"?show-close-button\", side: \"side\", size: \"size\", subtitle: \"subtitle\", title: \"title\", variant: \"variant\", zIndex: \"z-index\" },\n { onLofOpenChange: \"lof-open-change\" },\n);\n\n/** React wrapper for `<lof-otp>`. */\nexport const LofOtp = /* @__PURE__ */ createComponent<W.LofOtp, \"ariaLabel\" | \"autocomplete\" | \"disabled\" | \"groupSize\" | \"inputmode\" | \"inputMode\" | \"invalid\" | \"length\" | \"mask\" | \"name\" | \"pattern\" | \"placeholder\" | \"readonly\" | \"required\" | \"showSeparator\" | \"size\" | \"type\" | \"value\", { onLofChange: CustomEvent<{ value: string; complete: boolean; }>; onLofComplete: CustomEvent<{ value: string; }> }>(\n \"lof-otp\",\n { ariaLabel: \"aria-label\", autocomplete: \"autocomplete\", disabled: \"?disabled\", groupSize: \"group-size\", inputmode: \"inputmode\", inputMode: \"input-mode\", invalid: \"?invalid\", length: \"length\", mask: \"?mask\", name: \"name\", pattern: \"pattern\", placeholder: \"placeholder\", readonly: \"?readonly\", required: \"?required\", showSeparator: \"?show-separator\", size: \"size\", type: \"type\", value: \"value\" },\n { onLofChange: \"lof-change\", onLofComplete: \"lof-complete\" },\n);\n\n/** React wrapper for `<lof-pagination>`. */\nexport const LofPagination = /* @__PURE__ */ createComponent<W.LofPagination, \"ariaLabel\" | \"defaultPage\" | \"disabled\" | \"hrefTemplate\" | \"page\" | \"perPage\" | \"rowsPerPageLabel\" | \"rowsPerPageOptions\" | \"showLabel\" | \"showRowsPerPage\" | \"totalItems\" | \"totalPages\" | \"type\", { onLofChange: CustomEvent<{ page: number; }>; onLofPerPageChange: CustomEvent<{ perPage: number; }> }>(\n \"lof-pagination\",\n { ariaLabel: \"arialabel\", defaultPage: \"default-page\", disabled: \"?disabled\", hrefTemplate: \"href-template\", page: \"page\", perPage: \"per-page\", rowsPerPageLabel: \"rows-per-page-label\", rowsPerPageOptions: null, showLabel: \"?show-label\", showRowsPerPage: \"?show-rows-per-page\", totalItems: \"total-items\", totalPages: \"total-pages\", type: \"type\" },\n { onLofChange: \"lof-change\", onLofPerPageChange: \"lof-per-page-change\" },\n);\n\n/** React wrapper for `<lof-popover>`. */\nexport const LofPopover = /* @__PURE__ */ createComponent<W.LofPopover, \"align\" | \"alignOffset\" | \"arrow\" | \"closeOnEscape\" | \"closeOnOutsideClick\" | \"defaultOpen\" | \"disabled\" | \"hasPopup\" | \"open\" | \"side\" | \"sideOffset\" | \"trapFocus\", { onLofOpenChange: CustomEvent<{ open: boolean; }> }>(\n \"lof-popover\",\n { align: \"align\", alignOffset: \"align-offset\", arrow: \"?arrow\", closeOnEscape: \"?close-on-escape\", closeOnOutsideClick: \"?close-on-outside-click\", defaultOpen: \"?default-open\", disabled: \"?disabled\", hasPopup: \"has-popup\", open: \"?open\", side: \"side\", sideOffset: \"side-offset\", trapFocus: \"?trap-focus\" },\n { onLofOpenChange: \"lof-open-change\" },\n);\n\n/** React wrapper for `<lof-popover-content>`. */\nexport const LofPopoverContent = /* @__PURE__ */ createComponent<W.LofPopoverContent, \"ariaLabel\" | \"size\", {}>(\n \"lof-popover-content\",\n { ariaLabel: \"aria-label\", size: \"size\" },\n {},\n);\n\n/** React wrapper for `<lof-progress>`. */\nexport const LofProgress = /* @__PURE__ */ createComponent<W.LofProgress, \"label\" | \"mode\" | \"value\", {}>(\n \"lof-progress\",\n { label: \"label\", mode: \"mode\", value: \"value\" },\n {},\n);\n\n/** React wrapper for `<lof-radio>`. */\nexport const LofRadio = /* @__PURE__ */ createComponent<W.LofRadio, \"alignment\" | \"density\" | \"disabled\" | \"error\" | \"errorMessage\" | \"fieldAriaLabel\" | \"name\" | \"options\" | \"orientation\" | \"selectedValue\" | \"size\" | \"value\", { onLofChange: CustomEvent<{ value: string; checked: true; }> }>(\n \"lof-radio\",\n { alignment: \"alignment\", density: \"density\", disabled: \"?disabled\", error: \"?error\", errorMessage: \"error-message\", fieldAriaLabel: \"field-aria-label\", name: \"name\", options: null, orientation: \"orientation\", selectedValue: \"selected-value\", size: \"size\", value: \"value\" },\n { onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-range-picker>`. */\nexport const LofRangePicker = /* @__PURE__ */ createComponent<W.LofRangePicker, \"clearable\" | \"disabled\" | \"from\" | \"fullWidth\" | \"height\" | \"locale\" | \"maxDate\" | \"maxHeight\" | \"maxWidth\" | \"minDate\" | \"minHeight\" | \"minWidth\" | \"mode\" | \"open\" | \"placeholder\" | \"size\" | \"to\" | \"triggerVariant\" | \"weekStart\" | \"width\", { onLofBlur: CustomEvent<undefined>; onLofChange: CustomEvent<{ from: string; to: string; label: string; }>; onLofOpenChange: CustomEvent<{ open: true; } | { open: false; }> }>(\n \"lof-range-picker\",\n { clearable: \"?clearable\", disabled: \"?disabled\", from: \"from\", fullWidth: \"?full-width\", height: \"height\", locale: \"locale\", maxDate: \"max-date\", maxHeight: \"max-height\", maxWidth: \"max-width\", minDate: \"min-date\", minHeight: \"min-height\", minWidth: \"min-width\", mode: \"mode\", open: \"?open\", placeholder: \"placeholder\", size: \"size\", to: \"to\", triggerVariant: \"trigger-variant\", weekStart: \"week-start\", width: \"width\" },\n { onLofBlur: \"lof-blur\", onLofChange: \"lof-change\", onLofOpenChange: \"lof-open-change\" },\n);\n\n/** React wrapper for `<lof-resizable-group>`. */\nexport const LofResizableGroup = /* @__PURE__ */ createComponent<W.LofResizableGroup, \"direction\", { onLofResize: CustomEvent<{ direction: W.ResizableOrientation; sizes: number[]; }>; onLofResizeEnd: CustomEvent<{ direction: W.ResizableOrientation; sizes: number[]; }> }>(\n \"lof-resizable-group\",\n { direction: \"direction\" },\n { onLofResize: \"lof-resize\", onLofResizeEnd: \"lof-resize-end\" },\n);\n\n/** React wrapper for `<lof-resizable-handle>`. */\nexport const LofResizableHandle = /* @__PURE__ */ createComponent<W.LofResizableHandle, \"orientation\", {}>(\n \"lof-resizable-handle\",\n { orientation: \"orientation\" },\n {},\n);\n\n/** React wrapper for `<lof-resizable-panel>`. */\nexport const LofResizablePanel = /* @__PURE__ */ createComponent<W.LofResizablePanel, \"defaultSize\" | \"maxSize\" | \"minSize\" | \"panelLabel\", {}>(\n \"lof-resizable-panel\",\n { defaultSize: \"default-size\", maxSize: \"max-size\", minSize: \"min-size\", panelLabel: \"panel-label\" },\n {},\n);\n\n/** React wrapper for `<lof-segmented-button>`. */\nexport const LofSegmentedButton = /* @__PURE__ */ createComponent<W.LofSegmentedButton, \"active\" | \"align\" | \"disabled\" | \"fieldAriaLabel\" | \"options\" | \"size\", { onChanged: CustomEvent<{ value: string; }>; onLofChange: CustomEvent<{ value: string; }> }>(\n \"lof-segmented-button\",\n { active: \"active\", align: \"align\", disabled: \"?disabled\", fieldAriaLabel: \"field-aria-label\", options: null, size: \"size\" },\n { onChanged: \"changed\", onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-select>`. */\nexport const LofSelect = /* @__PURE__ */ createComponent<W.LofSelect, \"border\" | \"fieldAriaLabel\" | \"fieldAriaLabelledby\" | \"label\" | \"labelStyle\" | \"leftIcon\" | \"maxVisibleChips\" | \"multiple\" | \"noSearch\" | \"options\" | \"placeholder\" | \"rightIcon\" | \"searchPlaceholder\" | \"selectAllLabel\" | \"selected\" | \"selectedValues\" | \"size\" | \"state\" | \"supportingIcon\" | \"supportingText\", { onChanged: CustomEvent<{ value: string | string[]; }>; onLofChange: CustomEvent<{ value: string | string[]; }> }>(\n \"lof-select\",\n { border: \"border\", fieldAriaLabel: \"field-aria-label\", fieldAriaLabelledby: \"field-aria-labelledby\", label: \"label\", labelStyle: \"label-style\", leftIcon: \"left-icon\", maxVisibleChips: \"max-visible-chips\", multiple: \"?multiple\", noSearch: \"?no-search\", options: null, placeholder: \"placeholder\", rightIcon: \"right-icon\", searchPlaceholder: \"search-placeholder\", selectAllLabel: \"select-all-label\", selected: \"selected\", selectedValues: null, size: \"size\", state: \"state\", supportingIcon: \"supporting-icon\", supportingText: \"supporting-text\" },\n { onChanged: \"changed\", onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-signature-pad>`. */\nexport const LofSignaturePad = /* @__PURE__ */ createComponent<W.LofSignaturePad, \"disabled\" | \"disabledText\" | \"error\" | \"errorMessage\" | \"fieldAriaLabel\" | \"helperText\" | \"label\" | \"mode\" | \"name\" | \"placeholder\" | \"readonly\" | \"required\" | \"strokes\" | \"typedName\" | \"value\", { onLofBegin: CustomEvent<{}>; onLofChange: CustomEvent<W.SignaturePadChangeDetail>; onLofEnd: CustomEvent<{}> }>(\n \"lof-signature-pad\",\n { disabled: \"?disabled\", disabledText: \"disabled-text\", error: \"?error\", errorMessage: \"error-message\", fieldAriaLabel: \"field-aria-label\", helperText: \"helper-text\", label: \"label\", mode: \"mode\", name: \"name\", placeholder: \"placeholder\", readonly: \"?readonly\", required: \"?required\", strokes: null, typedName: \"typed-name\", value: null },\n { onLofBegin: \"lof-begin\", onLofChange: \"lof-change\", onLofEnd: \"lof-end\" },\n);\n\n/** React wrapper for `<lof-skeleton>`. */\nexport const LofSkeleton = /* @__PURE__ */ createComponent<W.LofSkeleton, \"animation\" | \"height\" | \"lines\" | \"loaded\" | \"shape\" | \"width\", {}>(\n \"lof-skeleton\",\n { animation: \"animation\", height: \"height\", lines: \"lines\", loaded: \"?loaded\", shape: \"shape\", width: \"width\" },\n {},\n);\n\n/** React wrapper for `<lof-slider>`. */\nexport const LofSlider = /* @__PURE__ */ createComponent<W.LofSlider, \"disabled\" | \"fieldAriaLabel\" | \"max\" | \"min\" | \"showBubble\" | \"showTickLabels\" | \"showTicks\" | \"size\" | \"step\" | \"track\" | \"type\" | \"value\" | \"valueEnd\", { onLofChange: CustomEvent<{ value: number; valueEnd: number; } | { value: number; }> }>(\n \"lof-slider\",\n { disabled: \"?disabled\", fieldAriaLabel: \"field-aria-label\", max: \"max\", min: \"min\", showBubble: \"?show-bubble\", showTickLabels: \"?show-tick-labels\", showTicks: \"?show-ticks\", size: \"size\", step: \"step\", track: \"track\", type: \"type\", value: \"value\", valueEnd: \"value-end\" },\n { onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-snackbar>`. */\nexport const LofSnackbar = /* @__PURE__ */ createComponent<W.LofSnackbar, \"action\" | \"duration\" | \"iconClose\" | \"lines\" | \"longerAction\" | \"message\" | \"show\" | \"tone\" | \"type\" | \"variant\", { onActionClick: CustomEvent<undefined>; onClose: CustomEvent<undefined> }>(\n \"lof-snackbar\",\n { action: \"action\", duration: \"duration\", iconClose: \"?icon-close\", lines: \"lines\", longerAction: \"?longeraction\", message: \"message\", show: \"?show\", tone: \"tone\", type: \"type\", variant: \"variant\" },\n { onActionClick: \"actionClick\", onClose: \"close\" },\n);\n\n/** React wrapper for `<lof-split-button>`. */\nexport const LofSplitButton = /* @__PURE__ */ createComponent<W.LofSplitButton, \"ariaLabel\" | \"disabled\" | \"icon\" | \"iconOnly\" | \"items\" | \"label\" | \"loading\" | \"menuLabel\" | \"open\" | \"size\" | \"tone\" | \"variant\", { onLofOpenChange: CustomEvent<{ open: boolean; }>; onLofSelect: CustomEvent<W.SplitButtonSelectDetail> }>(\n \"lof-split-button\",\n { ariaLabel: \"aria-label\", disabled: \"?disabled\", icon: \"icon\", iconOnly: \"?icon-only\", items: null, label: \"label\", loading: \"?loading\", menuLabel: \"menu-label\", open: \"?open\", size: \"size\", tone: \"tone\", variant: \"variant\" },\n { onLofOpenChange: \"lof-open-change\", onLofSelect: \"lof-select\" },\n);\n\n/** React wrapper for `<lof-stepper>`. */\nexport const LofStepper = /* @__PURE__ */ createComponent<W.LofStepper, \"connector\" | \"labelPlacement\" | \"orientation\" | \"size\" | \"steps\" | \"textAlign\" | \"type\", { onLofStepChange: CustomEvent<{ index: number; step: W.Step; }> }>(\n \"lof-stepper\",\n { connector: \"connector\", labelPlacement: \"label-placement\", orientation: \"orientation\", size: \"size\", steps: null, textAlign: \"textalign\", type: \"type\" },\n { onLofStepChange: \"lof-step-change\" },\n);\n\n/** React wrapper for `<lof-switch>`. */\nexport const LofSwitch = /* @__PURE__ */ createComponent<W.LofSwitch, \"checked\" | \"disabled\" | \"fieldAriaLabel\" | \"label\" | \"labelPlacement\" | \"size\" | \"type\" | \"value\", { onLofChange: CustomEvent<{ checked: boolean; value: string; }> }>(\n \"lof-switch\",\n { checked: \"?checked\", disabled: \"?disabled\", fieldAriaLabel: \"field-aria-label\", label: \"label\", labelPlacement: \"label-placement\", size: \"size\", type: \"type\", value: \"value\" },\n { onLofChange: \"lof-change\" },\n);\n\n/** React wrapper for `<lof-tab>`. */\nexport const LofTab = /* @__PURE__ */ createComponent<W.LofTab, \"activeIndex\" | \"iconPlacement\" | \"orientation\" | \"size\" | \"tabs\", { onLofChange: CustomEvent<number>; onLofTabChange: CustomEvent<number> }>(\n \"lof-tab\",\n { activeIndex: \"active-index\", iconPlacement: \"icon-placement\", orientation: \"orientation\", size: \"size\", tabs: null },\n { onLofChange: \"lof-change\", onLofTabChange: \"lof-tab-change\" },\n);\n\n/** React wrapper for `<lof-tab-item>`. */\nexport const LofTabItem = /* @__PURE__ */ createComponent<W.LofTabItem, \"badge\" | \"badgeDot\" | \"disabled\" | \"icon\" | \"label\" | \"value\", {}>(\n \"lof-tab-item\",\n { badge: \"badge\", badgeDot: \"?badge-dot\", disabled: \"?disabled\", icon: \"icon\", label: \"label\", value: \"value\" },\n {},\n);\n\n/** React wrapper for `<lof-textfield>`. */\nexport const LofTextfield = /* @__PURE__ */ createComponent<W.LofTextfield, \"clickableRightIcon\" | \"disabled\" | \"error\" | \"errorMessage\" | \"fieldAriaLabel\" | \"fieldAriaLabelledby\" | \"floatingLabel\" | \"fullWidth\" | \"helperIcon\" | \"helperText\" | \"label\" | \"labelStyle\" | \"leftIcon\" | \"maxLength\" | \"multiline\" | \"name\" | \"placeholder\" | \"prefixIcon\" | \"prefixIconAriaLabel\" | \"prefixStyle\" | \"prefixText\" | \"readonly\" | \"required\" | \"rightIcon\" | \"rightIconAriaLabel\" | \"rows\" | \"size\" | \"state\" | \"suffixDivider\" | \"suffixText\" | \"supportingText\" | \"type\" | \"value\" | \"variant\", { onLofChange: CustomEvent<string>; onLofRightIconClick: CustomEvent<undefined> }>(\n \"lof-textfield\",\n { clickableRightIcon: \"?clickable-right-icon\", disabled: \"?disabled\", error: \"?error\", errorMessage: \"error-message\", fieldAriaLabel: \"field-aria-label\", fieldAriaLabelledby: \"field-aria-labelledby\", floatingLabel: \"?floatinglabel\", fullWidth: \"?full-width\", helperIcon: \"helper-icon\", helperText: \"helper-text\", label: \"label\", labelStyle: \"label-style\", leftIcon: \"left-icon\", maxLength: \"maxlength\", multiline: \"?multiline\", name: \"name\", placeholder: \"placeholder\", prefixIcon: \"prefix-icon\", prefixIconAriaLabel: \"prefix-icon-aria-label\", prefixStyle: \"prefix-style\", prefixText: \"prefix-text\", readonly: \"?readonly\", required: \"?required\", rightIcon: \"right-icon\", rightIconAriaLabel: \"right-icon-aria-label\", rows: \"rows\", size: \"size\", state: \"state\", suffixDivider: \"?suffix-divider\", suffixText: \"suffix-text\", supportingText: \"supportingtext\", type: \"type\", value: \"value\", variant: \"variant\" },\n { onLofChange: \"lof-change\", onLofRightIconClick: \"lof-right-icon-click\" },\n);\n\n/** React wrapper for `<lof-time-picker>`. */\nexport const LofTimePicker = /* @__PURE__ */ createComponent<W.LofTimePicker, \"clearable\" | \"disabled\" | \"error\" | \"errorMessage\" | \"format\" | \"fullWidth\" | \"helperText\" | \"invalid\" | \"label\" | \"maxTime\" | \"minTime\" | \"minuteStep\" | \"name\" | \"open\" | \"placeholder\" | \"readonly\" | \"required\" | \"seconds\" | \"size\" | \"value\" | \"variant\", { onLofBlur: CustomEvent<undefined>; onLofChange: CustomEvent<{ value: string | null; }>; onLofFocus: CustomEvent<undefined>; onLofOpenChange: CustomEvent<{ open: boolean; }> }>(\n \"lof-time-picker\",\n { clearable: \"?clearable\", disabled: \"?disabled\", error: \"?error\", errorMessage: \"error-message\", format: \"format\", fullWidth: \"?full-width\", helperText: \"helper-text\", invalid: \"?invalid\", label: \"label\", maxTime: \"max-time\", minTime: \"min-time\", minuteStep: \"minute-step\", name: \"name\", open: \"?open\", placeholder: \"placeholder\", readonly: \"?readonly\", required: \"?required\", seconds: \"?seconds\", size: \"size\", value: \"value\", variant: \"variant\" },\n { onLofBlur: \"lof-blur\", onLofChange: \"lof-change\", onLofFocus: \"lof-focus\", onLofOpenChange: \"lof-open-change\" },\n);\n\n/** React wrapper for `<lof-toast>`. */\nexport const LofToast = /* @__PURE__ */ createComponent<W.LofToast, \"actionLabel\" | \"dismissible\" | \"duration\" | \"maxVisible\" | \"message\" | \"position\" | \"show\" | \"size\" | \"tone\" | \"type\", { onAction: CustomEvent<undefined>; onDismissed: CustomEvent<undefined> }>(\n \"lof-toast\",\n { actionLabel: \"action-label\", dismissible: \"?dismissible\", duration: \"duration\", maxVisible: \"max-visible\", message: \"message\", position: \"position\", show: \"?show\", size: \"size\", tone: \"tone\", type: \"type\" },\n { onAction: \"action\", onDismissed: \"dismissed\" },\n);\n\n/** React wrapper for `<lof-tooltip>`. */\nexport const LofTooltip = /* @__PURE__ */ createComponent<W.LofTooltip, \"position\" | \"showTail\" | \"text\" | \"tone\" | \"type\", {}>(\n \"lof-tooltip\",\n { position: \"position\", showTail: \"?show-tail\", text: \"text\", tone: \"tone\", type: \"type\" },\n {},\n);\n\n/** React wrapper for `<lof-tree>`. */\nexport const LofTree = /* @__PURE__ */ createComponent<W.LofTree, \"expandedValues\" | \"fieldAriaLabel\" | \"items\" | \"selected\" | \"selectedValues\" | \"selection\" | \"showGuides\", { onLofChange: CustomEvent<{ value: string[]; } | { value: string; }>; onLofExpandedChange: CustomEvent<{ value: string; expanded: boolean; }>; onLofLoadChildren: CustomEvent<{ value: string; }> }>(\n \"lof-tree\",\n { expandedValues: null, fieldAriaLabel: \"field-aria-label\", items: null, selected: \"selected\", selectedValues: null, selection: \"selection\", showGuides: \"?show-guides\" },\n { onLofChange: \"lof-change\", onLofExpandedChange: \"lof-expanded-change\", onLofLoadChildren: \"lof-load-children\" },\n);\n\n/** React wrapper for `<lof-upload>`. */\nexport const LofUpload = /* @__PURE__ */ createComponent<W.LofUpload, \"accept\" | \"browseLabel\" | \"concurrency\" | \"delayThreshold\" | \"disabled\" | \"dropzoneTitle\" | \"files\" | \"hint\" | \"maxFiles\" | \"maxSize\" | \"multiple\" | \"uploader\", { onLofCancel: CustomEvent<undefined>; onLofChange: CustomEvent<{ files: W.UploadFile[]; }>; onLofComplete: CustomEvent<{ succeeded: W.UploadFile[]; failed: W.UploadFile[]; }>; onLofFileComplete: CustomEvent<{ id: string; file: File; }>; onLofFileError: CustomEvent<{ id: string; file: File; error: string; }>; onLofFileReplaced: CustomEvent<W.FileReplacedDetail>; onLofFilesAdded: CustomEvent<{ added: W.UploadFile[]; rejected: W.UploadRejection[]; }>; onLofInvalid: CustomEvent<{ rejected: W.UploadRejection[]; }>; onLofProgress: CustomEvent<{ id: string; progress: number; loaded: number; total: number; }>; onLofRemove: CustomEvent<{ id: string; file: File | undefined; }>; onLofRetry: CustomEvent<{ files: W.UploadFile[]; }>; onLofState: CustomEvent<W.UploadState>; onLofUpload: CustomEvent<{ files: W.UploadFile[]; }>; onLofUploadComplete: CustomEvent<W.UploadCompleteDetail> }>(\n \"lof-upload\",\n { accept: \"accept\", browseLabel: \"browse-label\", concurrency: \"concurrency\", delayThreshold: \"delay-threshold\", disabled: \"?disabled\", dropzoneTitle: \"dropzone-title\", files: null, hint: \"hint\", maxFiles: \"max-files\", maxSize: \"max-size\", multiple: \"?multiple\", uploader: null },\n { onLofCancel: \"lof-cancel\", onLofChange: \"lof-change\", onLofComplete: \"lof-complete\", onLofFileComplete: \"lof-file-complete\", onLofFileError: \"lof-file-error\", onLofFileReplaced: \"lof-file-replaced\", onLofFilesAdded: \"lof-files-added\", onLofInvalid: \"lof-invalid\", onLofProgress: \"lof-progress\", onLofRemove: \"lof-remove\", onLofRetry: \"lof-retry\", onLofState: \"lof-state\", onLofUpload: \"lof-upload\", onLofUploadComplete: \"lof-upload-complete\" },\n);\n\n/** React wrapper for `<lof-upload-actions>`. */\nexport const LofUploadActions = /* @__PURE__ */ createComponent<W.LofUploadActions, \"cancelLabel\" | \"for\" | \"noCancel\", { onLofCancel: CustomEvent<undefined> }>(\n \"lof-upload-actions\",\n { cancelLabel: \"cancel-label\", for: \"for\", noCancel: \"?no-cancel\" },\n { onLofCancel: \"lof-cancel\" },\n);\n\n/** The element instance behind each wrapper, for typing refs: `useRef<LofSelectElement>(null)`. */\nexport type {\n LofAccordion as LofAccordionElement,\n LofAlert as LofAlertElement,\n LofAutocomplete as LofAutocompleteElement,\n LofAvatar as LofAvatarElement,\n LofAvatarGroup as LofAvatarGroupElement,\n LofBadge as LofBadgeElement,\n LofBreadcrumbs as LofBreadcrumbsElement,\n LofButton as LofButtonElement,\n LofCalendar as LofCalendarElement,\n LofCard as LofCardElement,\n LofCardMedia as LofCardMediaElement,\n LofCarousel as LofCarouselElement,\n LofCheckbox as LofCheckboxElement,\n LofChip as LofChipElement,\n LofContainer as LofContainerElement,\n LofDatePicker as LofDatePickerElement,\n LofDivider as LofDividerElement,\n LofDrawer as LofDrawerElement,\n LofDrawerFooter as LofDrawerFooterElement,\n LofKbd as LofKbdElement,\n LofKbdGroup as LofKbdGroupElement,\n LofLayout as LofLayoutElement,\n LofMenu as LofMenuElement,\n LofMenuItem as LofMenuItemElement,\n LofMenubar as LofMenubarElement,\n LofMenubarMenu as LofMenubarMenuElement,\n LofModal as LofModalElement,\n LofOtp as LofOtpElement,\n LofPagination as LofPaginationElement,\n LofPopover as LofPopoverElement,\n LofPopoverContent as LofPopoverContentElement,\n LofProgress as LofProgressElement,\n LofRadio as LofRadioElement,\n LofRangePicker as LofRangePickerElement,\n LofResizableGroup as LofResizableGroupElement,\n LofResizableHandle as LofResizableHandleElement,\n LofResizablePanel as LofResizablePanelElement,\n LofSegmentedButton as LofSegmentedButtonElement,\n LofSelect as LofSelectElement,\n LofSignaturePad as LofSignaturePadElement,\n LofSkeleton as LofSkeletonElement,\n LofSlider as LofSliderElement,\n LofSnackbar as LofSnackbarElement,\n LofSplitButton as LofSplitButtonElement,\n LofStepper as LofStepperElement,\n LofSwitch as LofSwitchElement,\n LofTab as LofTabElement,\n LofTabItem as LofTabItemElement,\n LofTextfield as LofTextfieldElement,\n LofTimePicker as LofTimePickerElement,\n LofToast as LofToastElement,\n LofTooltip as LofTooltipElement,\n LofTree as LofTreeElement,\n LofUpload as LofUploadElement,\n LofUploadActions as LofUploadActionsElement,\n} from \"@lofid/web\";\n\n/** Every tag these wrappers render. */\nexport const WRAPPED_TAGS = [\n \"lof-accordion\",\n \"lof-alert\",\n \"lof-autocomplete\",\n \"lof-avatar\",\n \"lof-avatar-group\",\n \"lof-badge\",\n \"lof-breadcrumbs\",\n \"lof-button\",\n \"lof-calendar\",\n \"lof-card\",\n \"lof-card-media\",\n \"lof-carousel\",\n \"lof-checkbox\",\n \"lof-chip\",\n \"lof-container\",\n \"lof-date-picker\",\n \"lof-divider\",\n \"lof-drawer\",\n \"lof-drawer-footer\",\n \"lof-kbd\",\n \"lof-kbd-group\",\n \"lof-layout\",\n \"lof-menu\",\n \"lof-menu-item\",\n \"lof-menubar\",\n \"lof-menubar-menu\",\n \"lof-modal\",\n \"lof-otp\",\n \"lof-pagination\",\n \"lof-popover\",\n \"lof-popover-content\",\n \"lof-progress\",\n \"lof-radio\",\n \"lof-range-picker\",\n \"lof-resizable-group\",\n \"lof-resizable-handle\",\n \"lof-resizable-panel\",\n \"lof-segmented-button\",\n \"lof-select\",\n \"lof-signature-pad\",\n \"lof-skeleton\",\n \"lof-slider\",\n \"lof-snackbar\",\n \"lof-split-button\",\n \"lof-stepper\",\n \"lof-switch\",\n \"lof-tab\",\n \"lof-tab-item\",\n \"lof-textfield\",\n \"lof-time-picker\",\n \"lof-toast\",\n \"lof-tooltip\",\n \"lof-tree\",\n \"lof-upload\",\n \"lof-upload-actions\"\n] as const;\n","// @lofid/react: React wrappers for every @lofid/web element.\nexport * from \"./generated\";\nexport { createComponent } from \"./create-component\";\nexport type { AttributeSpec, EventHandlers, LofComponent, LofProps } from \"./create-component\";\n\nlet defined: Promise<void> | undefined;\n\n/**\n * Registers every lof-* element (and lof-icon) by loading @lofid/web.\n * Safe to call from anywhere and any number of times; it does nothing on the\n * server. Bundled SPAs can import \"@lofid/web\" at their entry instead.\n */\nexport function defineElements(): Promise<void> {\n if (typeof window === \"undefined\") return Promise.resolve();\n defined ??= import(\"@lofid/web\").then(() => undefined);\n return defined;\n}\n"],"mappings":";;;AAAA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAKK;AAiBP,IAAM,wBAAwB,OAAO,WAAW,cAAc,YAAY;AAE1E,IAAM,aAAa,uBAAO,YAAY;AAItC,IAAM,aAAa,OAAO,SAAS,SAAS,EAAE,KAAK,KAA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,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;;;ACtfA,IAAI;AAOG,SAAS,iBAAgC;AAC9C,MAAI,OAAO,WAAW,YAAa,QAAO,QAAQ,QAAQ;AAC1D,cAAY,OAAO,YAAY,EAAE,KAAK,MAAM,MAAS;AACrD,SAAO;AACT;","names":["props"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,41 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lofid/react",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "React wrappers for the Lofid Design System web components, generated from @lofid/web",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "dist/index.js",
|
|
7
|
+
"module": "dist/index.js",
|
|
8
|
+
"types": "dist/index.d.ts",
|
|
9
|
+
"sideEffects": false,
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"types": "./dist/index.d.ts",
|
|
13
|
+
"import": "./dist/index.js"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"files": [
|
|
17
|
+
"dist",
|
|
18
|
+
"README.md"
|
|
19
|
+
],
|
|
20
|
+
"scripts": {
|
|
21
|
+
"generate": "node scripts/generate.mjs",
|
|
22
|
+
"check": "node scripts/generate.mjs --check && tsc --noEmit",
|
|
23
|
+
"build": "node scripts/generate.mjs --check && tsup",
|
|
24
|
+
"dev": "tsup --watch",
|
|
25
|
+
"test": "node --test test/ssr.test.mjs && node test/browser.mjs"
|
|
26
|
+
},
|
|
27
|
+
"peerDependencies": {
|
|
28
|
+
"@lofid/web": "^1.0.0",
|
|
29
|
+
"react": "^18.0.0 || ^19.0.0"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"@types/react": "^18.3.11",
|
|
33
|
+
"playwright-core": "1.55.0",
|
|
34
|
+
"react-dom": "18.3.1",
|
|
35
|
+
"tsup": "^8.3.0",
|
|
36
|
+
"typescript": "^5.6.0"
|
|
37
|
+
},
|
|
38
|
+
"publishConfig": {
|
|
39
|
+
"access": "public"
|
|
40
|
+
}
|
|
41
|
+
}
|