import { ChangeEvent, ChangeEventHandler, FocusEventHandler, forwardRef, KeyboardEventHandler, MutableRefObject, ReactNode, Ref, RefCallback } from 'react'; type ComponentProvidedProps = Partial<{ className: string; 'data-testid': string; placeholder: string; value: string; readOnly: boolean; onChange: ChangeEventHandler; disabled: boolean; autoFocus: boolean; onFocus: FocusEventHandler; onBlur: FocusEventHandler; onKeyUp: KeyboardEventHandler; onKeyDown: KeyboardEventHandler; }>; export type ComponentProvidedPropNames = keyof ComponentProvidedProps; type EmptyObject = Record; export type TextInputBaseComponentProps = ComponentProvidedProps & ComponentProps; export type TextInputBaseProps = { label?: ReactNode; value?: string | number; size?: 'small' | 'medium' | 'large'; labelPlacement?: 'top' | 'start' | 'end'; /** * HTML tag of the root element. Use `div` when `prefix`/`suffix` contain interactive * controls — nested interactive elements inside a `label` are invalid for assistive tech */ rootTagName?: 'label' | 'div'; disabled?: boolean; status?: 'error' | 'loading'; message?: ReactNode; onFocus?: FocusEventHandler; onBlur?: FocusEventHandler; onKeyDown?: KeyboardEventHandler; onKeyUp?: KeyboardEventHandler; placeholder?: string; prefix?: ReactNode; suffix?: ReactNode; /** * Ref to an underlying input element */ inputRef?: RefCallback | MutableRefObject | null; /** * Ref to a container that contains input and its affixes * Useful for positioning of popovers */ inputContainerRef?: RefCallback | MutableRefObject | null; readOnly?: boolean; /** * If `true` will focus on the field on render. Useful for modals, but may be detrimental to a11y */ autoFocus?: boolean; elementsClassNames?: Partial<{ label: string; input: string; inputContainer: string; prefix: string; suffix: string; message: string; }>; onChange?: (value: string, changeReason: 'change' | 'clear', event?: ChangeEvent) => void; clearable?: boolean; /** * Controls if the field should keep/gain focus after "Clear" button is clicked */ focusOnClear?: boolean; className?: string; testId?: string; /** * ⚠️⚠️⚠️ PRIVATE API. If you see it in docs you're doing something wrong */ component: ReturnType>>; /** * ⚠️⚠️⚠️ PRIVATE API. If you see it in docs you're doing something wrong */ componentProps?: ComponentProps; /** * ⚠️⚠️⚠️ PRIVATE API. If you see it in docs you're doing something wrong */ testIds?: Partial<{ input: string; label: string; prefix: string; suffix: string; clearButton: string; message: string; }>; }; export declare const SizeToClassMap: Record>['size'], string>; export declare const TextInputBase: ({ testId, className, label, rootTagName, clearable, focusOnClear, prefix, suffix, placeholder, size, value, readOnly, labelPlacement, inputRef, disabled, autoFocus, message, onFocus, onBlur, onKeyUp, onKeyDown, status, onChange, elementsClassNames, inputContainerRef, component: Component, componentProps, rootRef, testIds, }: TextInputBaseProps & { rootRef: Ref; }) => import("react/jsx-runtime").JSX.Element; export {}; //# sourceMappingURL=TextInputBase.d.ts.map