---
interface Props {
  text: string;
  class?: string;
}

const { text, class: className = '' } = Astro.props;
---

<button
  class:list={['copy-btn text-noir-600 hover:text-noir-100 transition-colors cursor-pointer', className]}
  data-copy={text}
  aria-label="Copy to clipboard"
>
  <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
    <rect x="9" y="9" width="13" height="13" rx="2" />
    <path d="M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1" />
  </svg>
</button>
