Only encode path of url

This commit is contained in:
Regalijan 2024-11-02 01:01:52 -04:00
parent 60eb7bca64
commit 941808a67a
Signed by: regalijan
GPG Key ID: 5D4196DA269EF520

View File

@ -103,17 +103,17 @@ export default function () {
return (
<Tr>
<Td>{entry.destination}</Td>
<Td
onClick={() => {
navigator.clipboard.writeText(
encodeURIComponent(
`https://carcrushe.rs/${entry.path}`,
),
<Td>
<Link
onClick={async () => {
await navigator.clipboard.writeText(
`https://carcrushe.rs/${encodeURIComponent(entry.path)}`,
);
alert("Link copied");
}}
>
https://carcrushe.rs/{entry.path}
</Link>
</Td>
<Td>
<IconButton