import { HTMLAttributes } from "react";
export interface TextProps extends HTMLAttributes<HTMLInputElement> {
    /** Type of the input. */
    type: "text";
    /** If true, mouse events are disabled and the input appears faded. */
    disabled?: boolean;
    /** The value of the input. */
    value: string;
    /** Text to display next to the input. */
    legend?: string;
    /** If true, text will be display to indicate that the field is required. */
    required?: boolean;
    /** Callback function that is triggered when the input loses focus. */
    onValidate?: (value: string) => boolean;
    /** Error message that is displayed when `onValidate` callback returns false; */
    validationError?: string;
}
export interface PasswordProps extends HTMLAttributes<HTMLInputElement> {
    type: "password";
    disabled?: boolean;
    value: string;
    legend?: string;
    required?: boolean;
}
export interface TextareaProps extends HTMLAttributes<HTMLTextAreaElement> {
    type: "textarea";
    disabled?: boolean;
    value: string;
    legend?: string;
    required?: boolean;
}
export interface TextHandle {
    clearError: () => void;
    showError: () => void;
}
declare const Text: import("react").ForwardRefExoticComponent<(TextProps | PasswordProps | TextareaProps) & import("react").RefAttributes<TextHandle>>;
export default Text;
