import BLOG from '@/blog.config' import Link from 'next/link' import React from 'react' import TagItemMini from './TagItemMini' import CONFIG_MATERY from '../config_matery' // import Image from 'next/image' const BlogPostCard = ({ index, post, showSummary, siteInfo }) => { const showPreview = CONFIG_MATERY.POST_LIST_PREVIEW && post.blockMap // matery 主题默认强制显示图片 if (post && !post.page_cover) { post.page_cover = siteInfo?.pageCover } const showPageCover = CONFIG_MATERY.POST_LIST_COVER && !showPreview && post?.page_cover const delay = (index % 3) * 300 return (
{/* 固定高度 ,空白用图片拉升填充 */}
{/* 头部图片 填充卡片 */} {showPageCover && (
{/* eslint-disable-next-line @next/next/no-img-element */} {post.title} {post.title}
)} {/* 文字描述 */}
{/* 描述 */}
{(!showPreview || showSummary) && post.summary && (

{post.summary}

)}
{post.date?.start_date || post.lastEditedTime} {post.category}
{post?.tagItems && post?.tagItems.length > 0 && (<>
{' '} {post.tagItems.map(tag => ( ))}
)}
) } export default BlogPostCard