Invite link
- Add the registry
- Add copy-field
Usage
Long values scroll sideways. The button confirms the copy, including to screen readers.
Examples
Without a label
Leave out label when the context makes it clear.
Copying on click
copyOnClick copies when anywhere in the row is clicked, as long as no text in it is selected. The
button still copies from the keyboard.
Confirming a copy
onCopy runs after the value is copied, such as to show a toast.
Install
Copy button
To copy a value shown some other way, use Copy Button on its own.
Props
CopyField takes the props of a <div>.