[fix] 文章不存在封面的时候,不使用默认站点封面,导致不显示封面的问题

This commit is contained in:
expoli
2023-10-29 19:43:56 +08:00
parent 61f014e60f
commit 49038d6133

View File

@@ -9,7 +9,7 @@ import LazyImage from '@/components/LazyImage'
const BlogPostCard = ({ index, post, showSummary, siteInfo }) => {
const showPreview = CONFIG.POST_LIST_PREVIEW && post.blockMap
if (post && !post.pageCoverThumbnail && CONFIG.POST_LIST_COVER_DEFAULT) {
post.pageCover = siteInfo?.pageCoverThumbnail
post.pageCoverThumbnail = siteInfo?.pageCover
}
const showPageCover = CONFIG.POST_LIST_COVER && post?.pageCoverThumbnail && !showPreview
// const delay = (index % 2) * 200