diff --git a/src/utils/CopyToClipboardBtn/index.stories.tsx b/src/utils/CopyToClipboardBtn/index.stories.tsx index 1a717f54..0de3dca8 100644 --- a/src/utils/CopyToClipboardBtn/index.stories.tsx +++ b/src/utils/CopyToClipboardBtn/index.stories.tsx @@ -13,3 +13,7 @@ export default { export const Copy = (): React.ReactElement => ( ); + +export const CopyWithDifferentLogo = (): React.ReactElement => ( + +); diff --git a/src/utils/CopyToClipboardBtn/index.tsx b/src/utils/CopyToClipboardBtn/index.tsx index fa59df80..311abf2d 100644 --- a/src/utils/CopyToClipboardBtn/index.tsx +++ b/src/utils/CopyToClipboardBtn/index.tsx @@ -27,11 +27,16 @@ const StyledButton = styled.button` type Props = { textToCopy: string; className?: string; + iconType?: Parameters[0]['type']; + tooltip?: string; + tooltipAfterCopy?: string; }; const CopyToClipboardBtn = ({ className, textToCopy, + iconType = 'copy', + tooltip = 'Copy to clipboard', }: Props): React.ReactElement => { const [clicked, setClicked] = useState(false); @@ -67,8 +72,8 @@ const CopyToClipboardBtn = ({ ); diff --git a/tests/utils/CopyToClipboardBtn/__snapshots__/index.stories.storyshot b/tests/utils/CopyToClipboardBtn/__snapshots__/index.stories.storyshot index 0a107b71..14660416 100644 --- a/tests/utils/CopyToClipboardBtn/__snapshots__/index.stories.storyshot +++ b/tests/utils/CopyToClipboardBtn/__snapshots__/index.stories.storyshot @@ -43,3 +43,46 @@ exports[`Storyshots Utils/CopyToClipboardBtn Copy 1`] = ` `; + +exports[`Storyshots Utils/CopyToClipboardBtn Copy With Different Logo 1`] = ` + +`;