Skip to main content

CopyBox

CopyBox displays a value alongside a copy button. Clicking it copies the value to the clipboard — handy for IDs, links, keys, and connection strings the user needs to grab quickly.

When to use

  • Surface a value the user will copy: a record ID, share URL, API key, correlation ID.

Import

import { CopyBox } from '@spartanfx/react';

Basic usage

The only required prop is value.

<CopyBox value="https://contoso.sharepoint.com/sites/projects/alpha" />

Key props

PropTypeNotes
value (required)stringThe string copied when the button is clicked.

See the full generated reference: CopyBox API ↗.

See also