import { InputHTMLAttributes } from 'react';
export type TagsInputValidationResult = {
    /** Normalized value to store. Falls back to the trimmed input if omitted. */
    normalizedValue?: string;
    /** Human-readable error message. Undefined means valid. */
    error?: string;
};
type ForwardedInputProps = Omit<InputHTMLAttributes<HTMLInputElement>, "className" | "defaultValue" | "disabled" | "onBlur" | "onChange" | "onKeyDown" | "onPaste" | "placeholder" | "type" | "value">;
export type TagsInputProps = {
    values: string[];
    onChange: (values: string[]) => void;
    placeholder?: string;
    /** Commit the pending input value when the field loses focus. Default: true. */
    addOnBlur?: boolean;
    /**
     * Validate (and optionally normalize) a trimmed input string before it is added.
     * Return `{ error }` to reject with a message, `{ normalizedValue }` to accept
     * with a transformed value, or `{}` to accept as-is.
     */
    validateValue?: (trimmed: string, currentValues: string[]) => TagsInputValidationResult;
    /**
     * Determine whether `incoming` is a duplicate of an existing `stored` value.
     * Return `true` to reject with the default "Already added" message, or a
     * non-empty string to reject with that string as the error. Defaults to
     * exact string equality with "Already added".
     */
    isDuplicate?: (incoming: string, stored: string) => boolean | string;
    /**
     * Render a custom chip for each committed value. Receives the value and a
     * `remove` callback. When omitted a plain Badge with an X button is rendered.
     * Keys are managed by TagsInput — do not add a `key` prop to the returned element.
     */
    renderValue?: (value: string, remove: () => void) => React.ReactNode;
    className?: string;
    disabled?: boolean;
} & ForwardedInputProps;
export type TagsInputValueProps = {
    value: string;
    onRemove: () => void;
};
export declare function TagsInputValue({ value, onRemove }: TagsInputValueProps): import("react/jsx-runtime").JSX.Element;
export declare function TagsInput({ values, onChange, placeholder, addOnBlur, validateValue, isDuplicate, renderValue, className, disabled, id, ...inputProps }: TagsInputProps): import("react/jsx-runtime").JSX.Element;
export {};
//# sourceMappingURL=tags-input.d.ts.map