diff --git a/src/lib/components/lemmy/post/media/PostMediaCompact.svelte b/src/lib/components/lemmy/post/media/PostMediaCompact.svelte index 5a434990..349a790f 100644 --- a/src/lib/components/lemmy/post/media/PostMediaCompact.svelte +++ b/src/lib/components/lemmy/post/media/PostMediaCompact.svelte @@ -9,14 +9,14 @@ import { userSettings } from '$lib/settings.js' import { isImage } from '$lib/ui/image' import type { Post } from 'lemmy-js-client' - import { DocumentText, Icon, Link, VideoCamera } from 'svelte-hero-icons'; + import { DocumentText, Icon, Link, VideoCamera } from 'svelte-hero-icons' export let view: 'card' | 'cozy' | 'list' | 'compact' = 'cozy' export let post: Post export let type: MediaType = 'none' -{#if view == "compact" || (view == "list" && !post.embed_title && (post.thumbnail_url || isImage(post.url)))} +{#if view == 'compact' || (view == 'list' && (!post.embed_title || type == 'iframe') && type != 'none')}
{ - if (type == "image") { - showImage(bestImageURL(post, false, 2048)); + if (type == 'image') { + showImage(bestImageURL(post, false, 2048)) } }} role="button" @@ -46,7 +46,7 @@ class="relative w-7 h-7 bottom-8 left-1 rounded-lg text-slate-800 dark:text-zinc-200 backdrop-blur-sm bg-[#ffffff]/75 dark:bg-black/75 grid place-items-center" > - +
{/if} {:else} @@ -56,7 +56,15 @@ group-hover/media:dark:border-zinc-600 transition-colors text-slate-400 dark:text-zinc-600 grid place-items-center" > - + {/if}