UseClipboardProps
@firecms/core / UseClipboardProps
Interface: UseClipboardProps
Section titled “Interface: UseClipboardProps”Defined in: hooks/useClipboard.tsx:5
Properties
Section titled “Properties”copiedDuration?
Section titled “copiedDuration?”
optionalcopiedDuration:number
Defined in: hooks/useClipboard.tsx:31
revert back the isCopied flag to false again if a value is set.
disableClipboardAPI?
Section titled “disableClipboardAPI?”
optionaldisableClipboardAPI:boolean
Defined in: hooks/useClipboard.tsx:26
Disables the new clipboard API navigator.clipboard even if
it is supported.
onError()?
Section titled “onError()?”
optionalonError: (error) =>void
Defined in: hooks/useClipboard.tsx:20
Triggers when the hook encounters an error. If passed hook won’t throw an error.
Parameters
Section titled “Parameters”string
Returns
Section titled “Returns”void
onSuccess()?
Section titled “onSuccess()?”
optionalonSuccess: (text) =>void
Defined in: hooks/useClipboard.tsx:12
It’s callback function that is called after the copy command
is executed.
Parameters
Section titled “Parameters”string
Returns
Section titled “Returns”void