mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 02:11:05 +00:00
20 lines
453 B
Svelte
20 lines
453 B
Svelte
<script>
|
|
/** @extends {"../Copy/Copy"} CopyProps */
|
|
|
|
/** Set the title and ARIA label for the copy button */
|
|
export let iconDescription = "Copy to clipboard";
|
|
|
|
import { Copy } from "../Copy";
|
|
import Copy16 from "carbon-icons-svelte/lib/Copy16";
|
|
</script>
|
|
|
|
<Copy
|
|
class="bx--copy-btn"
|
|
aria-label="{iconDescription}"
|
|
title="{iconDescription}"
|
|
{...$$restProps}
|
|
on:click
|
|
on:animationend
|
|
>
|
|
<Copy16 class="bx--snippet__icon" />
|
|
</Copy>
|