import { ChangeEvent, ComponentType, FocusEventHandler, InputHTMLAttributes, KeyboardEventHandler, MutableRefObject, ReactNode, RefCallback } from 'react'; export type TextInputProps = { label?: ReactNode; value?: string | number; onChange?: (value: string, event: ChangeEvent) => void; disabled?: boolean; /** * Controls component's visual style. * ⚠️ ⚠️ ⚠️ Use `inputType` prop for underlying `input`'s element `type` attribute. Old values added for backwards compatibility and will be removed in the future */ type?: 'default' | 'search' | 'text' | 'email' | 'password' | 'number' | 'phone' | 'url'; /** * Underlying `input`'s element `type` attribute */ inputType?: 'text' | 'email' | 'password' | 'number' | 'phone' | 'url' | 'search'; status?: 'error' | 'loading'; spacing?: 'normal' | 'dense'; message?: ReactNode; onFocus?: FocusEventHandler; onBlur?: FocusEventHandler; onKeyDown?: KeyboardEventHandler; onKeyUp?: KeyboardEventHandler; /** * If present - will render a "clear" button */ onClear?: () => void; /** * Controls if the field should keep/gain focus after "Clear" button is clicked */ focusOnClear?: boolean; placeholder?: string; prefix?: ReactNode; suffix?: ReactNode; inputRef?: RefCallback | MutableRefObject; readOnly?: boolean; autoFocus?: boolean; forceLabelShrink?: boolean; /** * Escape hatch for when you need to override/add attributes to the `` tag */ htmlAttributes?: Omit>, 'type' | 'onFocus' | 'onBlur' | 'onKeyDown' | 'onKeyUp' | 'placeholder' | 'readOnly' | 'disabled' | 'value' | 'onChange'>; className?: string; testId?: string; }; declare const TextInputBase: import("react").ForwardRefExoticComponent>; type TextInputType = typeof TextInputBase & { Affix: ComponentType<{ children?: ReactNode; className?: string; }>; }; /** * @deprecated use `TextInputNext` */ export declare const TextInput: TextInputType; export {}; //# sourceMappingURL=TextInput.d.ts.map