diff --git a/package.json b/package.json
index e7b1d90c..c6eb0d28 100644
--- a/package.json
+++ b/package.json
@@ -25,6 +25,7 @@
"@popperjs/core": "^2.9.3",
"animate.css": "^4.1.1",
"animejs": "^3.2.1",
+ "aos": "^3.0.0-beta.6",
"axios": ">=0.21.1",
"copy-to-clipboard": "^3.3.1",
"eslint-plugin-react-hooks": "^4.6.0",
diff --git a/themes/matery/LayoutBase.js b/themes/matery/LayoutBase.js
index d226497e..14352875 100644
--- a/themes/matery/LayoutBase.js
+++ b/themes/matery/LayoutBase.js
@@ -9,6 +9,8 @@ import Live2D from '@/components/Live2D'
import LoadingCover from './components/LoadingCover'
import { useGlobal } from '@/lib/global'
import BLOG from '@/blog.config'
+import AOS from 'aos'
+import 'aos/dist/aos.css' // You can also use for styles
/**
* 基础布局 采用左右两侧布局,移动端使用顶部导航栏
@@ -41,6 +43,8 @@ const LayoutBase = props => {
return () => document.removeEventListener('scroll', scrollListener)
}, [show])
+ AOS.init()
+
return (
diff --git a/themes/matery/components/BlogPostCard.js b/themes/matery/components/BlogPostCard.js
index afc84fb4..14e7ccbd 100644
--- a/themes/matery/components/BlogPostCard.js
+++ b/themes/matery/components/BlogPostCard.js
@@ -3,87 +3,85 @@ import Link from 'next/link'
import React from 'react'
import TagItemMini from './TagItemMini'
import CONFIG_MATERY from '../config_matery'
-import NotionPage from '@/components/NotionPage'
const BlogPostCard = ({ post, showSummary }) => {
const showPreview = CONFIG_MATERY.POST_LIST_PREVIEW && post.blockMap
return (
-
-
+
+ {/* 固定高度72 ,没有描述用图片填充 */}
+
+
+ {/* 头部图片 填充卡片 */}
{CONFIG_MATERY.POST_LIST_COVER && !showPreview && post?.page_cover && !post.results && (
-
+
{/* eslint-disable-next-line @next/next/no-img-element */}
{post.title}
)}
- {/* 描述 */}
-
+
+ {/* 描述 */}
+
- {(!showPreview || showSummary) && !post.results && post.summary && (
-
- {post.summary}
-
- )}
+ {(!showPreview || showSummary) && !post.results && post.summary && (
+
+ {post.summary}
+
+ )}
- {/* 搜索结果 */}
- {post.results && (
-
- {post.results.map(r => (
- {r}
- ))}
-
- )}
-
- {showPreview && (
-
- {post?.tagItems && post?.tagItems.length > 0 && (<>
-
-
-
-
- {' '}
- {post.tagItems.map(tag => (
-
- ))}
+ {post?.tagItems && post?.tagItems.length > 0 && (<>
+
+
+
+
+ {' '}
+ {post.tagItems.map(tag => (
+
+ ))}
+
-
- >)}
-
+ >)}
+
+
)
}
diff --git a/themes/matery/components/BlogPostListPage.js b/themes/matery/components/BlogPostListPage.js
index 64b77f96..74ea9903 100644
--- a/themes/matery/components/BlogPostListPage.js
+++ b/themes/matery/components/BlogPostListPage.js
@@ -21,7 +21,7 @@ const BlogPostListPage = ({ page = 1, posts = [], postCount }) => {
{/* 文章列表 */}
-
+
{posts.map(post => (
))}
diff --git a/themes/matery/components/SideBar.js b/themes/matery/components/SideBar.js
index 1b4f106b..41bd4eb5 100644
--- a/themes/matery/components/SideBar.js
+++ b/themes/matery/components/SideBar.js
@@ -31,8 +31,8 @@ const SideBar = (props) => {
{/* eslint-disable-next-line @next/next/no-img-element */}

-
{siteInfo.title}
-
{siteInfo.description}
+
{siteInfo?.title}
+
{siteInfo?.description}