Skip to content

Commit 71a1c06

Browse files
committed
Refactor handleCopy function in Profile component to remove alert after copying URL
1 parent 1052984 commit 71a1c06

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/components/Profile/Profile.jsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,8 @@ function Card({ data }) {
104104
setShowTooltip(false);
105105
};
106106
const handleCopy = () => {
107-
navigator.clipboard.writeText(shareUrl);
108-
setShowTooltip(false);
109-
alert(`URL copied to clipboard: ${shareUrl}`);
107+
navigator.clipboard.writeText(shareUrl);
108+
setShowTooltip(false);
110109
};
111110
return (
112111
<div className="mb-6 h-auto rounded-lg bg-white p-4 shadow dark:bg-textPrimary">

0 commit comments

Comments
 (0)