Copyable Input
Reusable React component that renders an input field with a copy button to copy the input value to the clipboard.
Copy
Input
Installation
Run the following command:
npx gopx-webui add copyable-input
Props
Prop | Type | Required | Description |
---|---|---|---|
value | string | Yes | The value of the input field. This is a required prop. |
onChange | (value: string) => void | No | An optional callback function that is called when the input value changes. |
className | string | No | An optional additional CSS class to apply to the container div for custom styling. |
editable | boolean | No | Determines if the input field is editable. If false , the input will be read-only. |
spellcheck | boolean | No | Specifies whether the input should have spell checking enabled. Default is false . |