diff --git a/src/lib/components/lemmy/post/Post.svelte b/src/lib/components/lemmy/post/Post.svelte index d6facefa..f7761a15 100644 --- a/src/lib/components/lemmy/post/Post.svelte +++ b/src/lib/components/lemmy/post/Post.svelte @@ -21,10 +21,13 @@ let loaded = false // hack because you cant use typescript types in svelte markup - const onclick = (e: any) => { - if (e.target?.id == post.post.id) { - goto(postLink(post.post)) + const onclick = ( + e: MouseEvent & { + currentTarget: EventTarget & HTMLDivElement + target: any } + ) => { + if (e.target.id == post.post.id) goto(postLink(post.post)) } @@ -45,36 +48,34 @@ > {#if view == 'list' || view == 'compact'}
{/if}