interface Options { debug?: boolean; message?: string; format?: string; /** * Intercept and optionally replace the clipboard item before writing. * * - On the async path (`navigator.clipboard`): receives a `ClipboardItem` and * may return a new `ClipboardItem` to replace it. * - On the execCommand fallback path: receives the `DataTransfer` object from * the copy event. Return value is ignored; use `clipboardData.setData()` to * override content (requires `options.format` to be set so `preventDefault` * is called). */ onCopy?: (clipboardData: ClipboardItem | DataTransfer) => ClipboardItem | void; /** * Enable the `window.prompt()` fallback when both `navigator.clipboard` and * `execCommand` fail. Off by default in v4. */ fallbackToPrompt?: boolean; } declare function copy(text: string, options?: Options): Promise; export { type Options, copy as default };