export type { PropsDef } from '@vielzeug/ore'; /** Form validity methods exposed on form-associated custom elements. */ export type FormValidityMethods = { checkValidity(): boolean; reportValidity(): boolean; setCustomValidity(message: string): void; }; /** Component size variants */ export type ComponentSize = 'sm' | 'md' | 'lg'; /** Semantic theme colors */ export type ThemeColor = 'primary' | 'secondary' | 'info' | 'success' | 'warning' | 'error'; /** Visual variant styles */ export type VisualVariant = 'solid' | 'flat' | 'bordered' | 'outline' | 'ghost' | 'text' | 'frost'; /** Visual variant styles for surface/container components that also support the glass effect */ export type SurfaceVariant = VisualVariant | 'glass'; /** Border radius variants */ export type RoundedSize = 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl' | 'full'; /** Elevation/shadow depth levels */ export type ElevationLevel = 0 | 1 | 2 | 3 | 4 | 5; /** Internal spacing variants */ export type PaddingSize = 'none' | 'sm' | 'md' | 'lg' | 'xl'; /** Button form-submission types */ export type ButtonType = 'button' | 'submit' | 'reset'; /** Anchor browsing-context values */ export type LinkTarget = '_blank' | '_self' | '_parent' | '_top'; /** Allowed HTML5 input type values for `` */ export type InputType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url' | 'search' | 'date' | 'time' | 'datetime-local' | 'month' | 'week'; /** Props for form-associated elements */ export type FormElementProps = { name?: string; value?: string; }; /** Props for checkable form-associated elements (checkbox, radio) */ export type CheckableProps = FormElementProps & { checked?: boolean; }; /** * Adds type-safe `addEventListener` / `removeEventListener` overloads to a custom element type. * * ```ts * export interface OreInputEvents { * change: { value: string; originalEvent: Event }; * } * type OreInputElement = HTMLElement & OreInputProps & AddEventListeners; * ``` */ export type AddEventListeners = { addEventListener(type: K, listener: (this: HTMLElement, ev: CustomEvent) => void, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: HTMLElement, ev: CustomEvent) => void, options?: boolean | EventListenerOptions): void; }; export type BaseFormProps = { color?: ThemeColor; disabled?: boolean; error?: string; fullwidth?: boolean; helper?: string; label?: string; 'label-placement'?: 'inset' | 'outside'; name?: string; size?: ComponentSize; /** * Shows an inline green check icon inside the field to confirm the value has passed * validation. Ignored while `error` is set — an error always wins. */ success?: boolean; }; type FieldVisualProps = { rounded?: RoundedSize | ''; variant?: TVariant; }; export type TextFieldProps = BaseFormProps & FieldVisualProps & { placeholder?: string; readonly?: boolean; required?: boolean; value?: string; }; export type SelectableFieldProps = BaseFormProps & FieldVisualProps & { placeholder?: string; value?: string; }; //# sourceMappingURL=types.d.ts.map