Componentform0.4 KB gzipZero dependencies

CopyChip

Small mono chip that copies to clipboard with check morph and 'COPIED' feedback

Preview

Live Preview
Open ↗

Installation

Tokens guide →

Add to your project via CLI (zero dependencies, code you own):

npx bigbullui add copy-chip

Or install the full npm package:

npm install bigbullui

Usage

tsx3 lines
import { CopyChip } from "@/components/ui/copy-chip" <CopyChip value="Hello Big Bull UI" label="Copy" />

Source code

copy-chip.tsx + 2 helpers

Zero third-party dependencies (3 local files shown in tabs below).

tsxcopy-chip.tsx40 lines
"use client";import { cn } from "./lib/utils";import { useCopy } from "./lib/hooks"; export type CopyChipProps = {  value: string;  label?: string;};  const CopyChip = ({ value, label = "COPY" }: CopyChipProps) => {  const { copied, copy } = useCopy();   return (    <div      className={cn(        "inline-flex items-center gap-2 rounded-md border border-border bg-background p-2",        "animate-[stampIn_0.2s_ease-out_both]",

Props

Interactive Prop Playground

Tweak parsed AST props below to generate ready-to-paste JSX.

tsx3 lines
import { CopyChip } from "@/components/ui/copy-chip"; <CopyChip />
PropTypeDescription
valuestringThe text value to copy to clipboard
labelstringLabel text for the copy button