UNPKG

claritykit-svelte

Version:

A comprehensive Svelte component library focused on accessibility, ADHD-optimized design, developer experience, and full SSR compatibility

41 lines 1.34 kB
import { FieldValidator, type ValidationRule, type ValidationContext } from '../../utils/validation.js'; interface Props { id?: string; name: string; value?: string; type?: 'text' | 'email' | 'password' | 'tel' | 'url' | 'search' | 'number'; label?: string; description?: string; placeholder?: string; required?: boolean; disabled?: boolean; readonly?: boolean; hint?: string; size?: 'sm' | 'md' | 'lg'; inline?: boolean; hideLabel?: boolean; debounceMs?: number; validateOnBlur?: boolean; validateOnInput?: boolean; validator?: FieldValidator<string>; validationRules?: ValidationRule<string>[]; formContext?: ValidationContext; autocomplete?: string; maxlength?: number; minlength?: number; pattern?: string; step?: string | number; min?: string | number; max?: string | number; } declare const ValidatedInput: import("svelte").Component<Props, { focus: () => void; blur: () => void; validate: () => Promise<boolean>; clearError: () => void; reset: (newValue?: string) => Promise<void>; getValidator: () => FieldValidator<string> | undefined; }, "value" | "validator">; type ValidatedInput = ReturnType<typeof ValidatedInput>; export default ValidatedInput; //# sourceMappingURL=ValidatedInput.svelte.d.ts.map