"use client"
import{a as r}from"./chunk-EHYVEIOL.mjs";import{a as e}from"./chunk-BKZ6TNZC.mjs";import{j as o}from"./chunk-WCU5PG4B.mjs";import{cva as m}from"class-variance-authority";import{useState as f}from"react";import{toast as d}from"sonner";import{jsx as t,jsxs as v}from"react/jsx-runtime";var g=m("relative group rounded-full p-1.5 transition-all duration-75",{variants:{variant:{default:"bg-gray-100 hover:scale-105 hover:bg-blue-100 active:scale-95 text-gray-700 hover:text-blue-800",neutral:"bg-transparent hover:bg-gray-100 active:bg-gray-200"}},defaultVariants:{variant:"default"}});function w({variant:n="default",value:s,className:i,icon:c}){let[p,a]=f(!1),l=c||e;return v("button",{onClick:u=>{u.stopPropagation(),a(!0),navigator.clipboard.writeText(s).then(()=>{d.success("Copied to clipboard!")}),setTimeout(()=>a(!1),3e3)},className:o(g({variant:n}),i),type:"button",children:[t("span",{className:"sr-only",children:"Copy"}),p?t(r,{className:"h-3.5 w-3.5"}):t(l,{className:"h-3.5 w-3.5"})]})}export{w as a};
