felipemenezes098

One Clipboard

Buttons 65

About

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds One Clipboard to your project and fits it to your theme.

Code

How One Clipboard is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

'use client'

import { useState } from 'react'
import { CheckIcon, CopyIcon } from 'lucide-react'

import { Button } from '@/components/ui/button'

export function Button13() {
  const [copied, setCopied] = useState(false)

  function handleCopy() {
    navigator.clipboard.writeText('npm install shadcn')
    setCopied(true)
    setTimeout(() => setCopied(false), 1500)
  }

  return (
    <Button variant="outline" onClick={handleCopy}>
      {copied ? (
        <CheckIcon size={16} strokeWidth={2} data-icon="inline-start" className="text-emerald-500" />
      ) : (
        <CopyIcon size={16} strokeWidth={2} data-icon="inline-start" />
      )}
      <span className="ml-1">{copied ? 'Copied' : 'Copy'}</span>
    </Button>
  )
}

export default Button13

Dependencies

More by felipemenezes098

View all
  • Centered Hero with Image Fan

    Centered Hero with Image Fan

    932
  • Editorial Collage Hero

    Editorial Collage Hero

    431
  • Split Hero With Image Cards

    Split Hero With Image Cards

    402
  • Editorial Image Hero

    Editorial Image Hero

    388
  • Scroll 01

    Scroll 01

    341
  • Real Estate Search Hero

    Real Estate Search Hero

    190
  • Editorial Hero

    Editorial Hero

    173
  • Hero with Dashboard Mockup

    Hero with Dashboard Mockup

    123

More in Buttons

View all
  • Button Save

    Button Save

    46
  • Button

    Button

    20
  • Eclipse Button

    Eclipse Button

    5
  • Button

    Button

    6
  • Button

    Button

    14
  • Button Group

    Button Group

    37
  • Button

    Button

    32
  • Split Button

    Split Button

    32