diff --git a/src/components/RecommendedCard.tsx b/src/components/RecommendedCard.tsx index 3557f4a..6f8c122 100644 --- a/src/components/RecommendedCard.tsx +++ b/src/components/RecommendedCard.tsx @@ -40,10 +40,9 @@ export function RecommendedCard({ visualIndex % officialRecommendationCoverFallbacks.length ]; const cover = useMemo(() => { - if (useFigmaDesign) return figmaCover; const original = r.coverImage || r.previewUrl; if (isPlaceholderAsset(original)) { - return figmaCover; + return useFigmaDesign ? "" : figmaCover; } return assetUrl(original); }, [figmaCover, r.coverImage, r.previewUrl, useFigmaDesign]); diff --git a/src/utils/postResourceAdapter.ts b/src/utils/postResourceAdapter.ts index 8417436..0a3086a 100644 --- a/src/utils/postResourceAdapter.ts +++ b/src/utils/postResourceAdapter.ts @@ -23,10 +23,10 @@ function inferType(post: Post, att: Attachment | undefined): string { function coverFor(att: Attachment | undefined) { if (!att) return ""; - if (att.kind === "image") return att.thumbnailUrl || att.url; - if (att.kind === "video") return att.posterUrl || att.thumbnailUrl || ""; - if (att.mime.startsWith("image/")) return att.thumbnailUrl || att.url; - return ""; + if (att.kind === "image" || att.mime.startsWith("image/")) { + return att.thumbnailUrl || att.url; + } + return att.posterUrl || att.thumbnailUrl || ""; } export function postToResource(