Skip to main content
  1. Docs
  2. Components
  3. Actions

Copy button

Copies a value. The icon turns to a check, "Copied" is announced, and focus stays.

Import
@qeetrix/react/experimental
Status
ExperimentalSince 0.0.4
Renders
<button>Server-rendered
Tested
WCAG 2.2 AAaxe on every pull request

01

Playground

Every prop, live, and the code it takes.

Variant
Tone
Size
client-id.tsx
import { CopyButton } from "@qeetrix/react/experimental";

<CopyButton value="qid_app_01J9ZK4T7B2R" label="Copy client ID" />

02

Icon or label

An icon alone, named by label; or a label, which makes it a Button. Ghost and neutral by default.

03

Beside its value

Each value with its own button, named for it.

Client IDqid_app_01J9ZK4T7B2R
Redirect URIhttps://console.acme.in/auth/callback
Tenanttnt_acme_01HZX3

04

Made when it's copied

value can be a function, even an async one: a fresh link on every copy.

05

Sizes

Square, at a control's height; with a label, a Button's.

06

In Hindi

Its words come from QeetrixProvider: "कॉपी करें", then "कॉपी हो गया".

Next — Copy buttonUsage