diff --git a/src/lib/components/lemmy/post/Post.svelte b/src/lib/components/lemmy/post/Post.svelte index e7d69796..bfb6aa3c 100644 --- a/src/lib/components/lemmy/post/Post.svelte +++ b/src/lib/components/lemmy/post/Post.svelte @@ -108,6 +108,7 @@ -{#if (view == 'list' || view == 'compact') && !post.embed_title && (post.thumbnail_url || isImage(post.url))} +{#if view == "compact" || (view == "list" && !post.embed_title && (post.thumbnail_url || isImage(post.url)))}
showImage(bestImageURL(post, false, 2048))} + on:click={() => { + if (type == "image") { + showImage(bestImageURL(post, false, 2048)); + } + }} role="button" tabindex="0" > - {post.name} + {#if post.thumbnail_url || isImage(post.url)} + {post.name} + {#if type != 'image'} +
+ +
+ {/if} + {:else} +
+ +
+ {/if}
{/if}