export interface ClipboardState { copied: boolean; error: Error | null; } export interface UseClipboardReturn extends ClipboardState { copy: (text: string) => Promise; reset: () => void; } /** * Reads and writes text to the user's clipboard, managing a temporary "copied" state. * Great for "Copy to Clipboard" buttons. Safely cleans up timers on unmount. * * @param timeout - The duration in milliseconds before the `copied` state resets to false (default: 2000). * @returns Object containing the copy function, reset function, current copied state, and any errors. * * @example * ```tsx * const { copy, copied } = useClipboard(2000); * return ; * ``` */ export declare const useClipboard: (timeout?: number) => UseClipboardReturn; export default useClipboard;