feat: use share and link to original post, close #129

This commit is contained in:
Xyphyn committed 2023-08-27 12:10:26 -07:00
1 parent e73d74ff31
commit af8a963445
1 file changed
+6 -5
@@ -158,13 +158,14 @@
</MenuButton>
{/if}
<MenuButton
on:click={() =>
navigator.clipboard.writeText(
`https://${getInstance()}/post/${post.post.id}`
)}
on:click={() => {
navigator.share?.({
url: post.post.ap_id,
}) ?? navigator.clipboard.writeText(post.post.ap_id)
}}
>
<Icon src={Share} width={16} mini />
Copy Link
Share
</MenuButton>
{#if $profile?.jwt}
<MenuButton