mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-06-05 23:16:52 +00:00
预览文章溢出
This commit is contained in:
@@ -43,27 +43,28 @@ const BlogPostCard = ({ post, showSummary }) => {
|
|||||||
{post.summary}
|
{post.summary}
|
||||||
</p>}
|
</p>}
|
||||||
|
|
||||||
{showPreview && post?.blockMap && <div className='max-h-screen overflow-hidden truncate max-w-full'>
|
{showPreview && post?.blockMap && <div className='max-h-screen overflow-ellipsis truncate max-w-full'>
|
||||||
<NotionRenderer
|
<NotionRenderer
|
||||||
recordMap={post.blockMap}
|
bodyClassName='max-h-full'
|
||||||
mapPageUrl={mapPageUrl}
|
recordMap={post.blockMap}
|
||||||
components={{
|
mapPageUrl={mapPageUrl}
|
||||||
equation: Equation,
|
components={{
|
||||||
code: Code,
|
equation: Equation,
|
||||||
collectionRow: CollectionRow,
|
code: Code,
|
||||||
collection: Collection
|
collectionRow: CollectionRow,
|
||||||
}}
|
collection: Collection
|
||||||
/>
|
}}
|
||||||
|
/>
|
||||||
</div> }
|
</div> }
|
||||||
|
|
||||||
<div className='border-b-2 w-full border-dashed py-2'></div>
|
<div className='border-b-2 w-full border-dashed py-2'></div>
|
||||||
|
|
||||||
<Link href={`${BLOG.path}/article/${post.slug}`} passHref>
|
<div className='flex items-center pt-6 justify-end leading-tight'>
|
||||||
<div className='flex items-center cursor-pointer pt-6 justify-end leading-tight'>
|
<Link href={`${BLOG.path}/article/${post.slug}`} passHref>
|
||||||
<a className='bg-black p-2 text-white'>{locale.COMMON.ARTICLE_DETAIL}
|
<a className='bg-black p-2 text-white cursor-pointer'>{locale.COMMON.ARTICLE_DETAIL}
|
||||||
<FontAwesomeIcon icon={faAngleDoubleRight} /></a>
|
<FontAwesomeIcon icon={faAngleDoubleRight} /></a>
|
||||||
</div>
|
</Link>
|
||||||
</Link>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{BLOG.home?.showPostCover && post?.page_cover && (
|
{BLOG.home?.showPostCover && post?.page_cover && (
|
||||||
|
|||||||
@@ -33,7 +33,6 @@ export async function getStaticProps () {
|
|||||||
post.blockMap = blockMap
|
post.blockMap = blockMap
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
console.log('加载文章预览完成')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -59,7 +59,6 @@ export async function getStaticProps ({ params: { page } }) {
|
|||||||
post.blockMap = blockMap
|
post.blockMap = blockMap
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
console.log('加载文章预览完成')
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
props: {
|
props: {
|
||||||
|
|||||||
Reference in New Issue
Block a user