import { ClipboardEventHandler, FocusEventHandler, KeyboardEvent } from 'react'; export interface UseDateInputFormatterProps { /** * error messages for different validation scenarios * @default { enabled: true, invalidInput: 'Input value is not valid.', invalidPaste: 'Pasted content is not valid.' } */ errorMessages?: { enabled?: boolean; invalidInput?: string; invalidPaste?: string; }; /** * Format pattern (e.g., "YYYY-MM-DD", "HH:mm:ss") */ format: string; /** * Current value */ value?: string; /** * Change handler receiving formatted value and raw digits */ onChange?: (formattedValue: string, rawDigits: string) => void; /** * Input ref for controlling selection */ inputRef?: React.RefObject; /** * Focus event handler */ onFocus?: FocusEventHandler; /** * Blur event handler */ onBlur?: FocusEventHandler; /** * Custom validation function. Return true if valid, false to clear the value. * Called after format validation passes. */ validate?: (isoDate: string) => boolean; /** * Callback when a valid ISO date is pasted. * This allows parent components to handle cross-field updates * (e.g., updating time field when date+time is pasted into date field). */ onPasteIsoValue?: (isoValue: string) => void; } /** * Hook for formatting date/time input with mask format */ export declare function useDateInputFormatter(props: UseDateInputFormatterProps): { value: string; focused: boolean; isComplete: boolean; handleKeyDown: (e: KeyboardEvent) => void; handleFocus: FocusEventHandler; handleBlur: FocusEventHandler; handlePaste: ClipboardEventHandler; };