diff --git a/themes/fukasawa/components/ArticleDetail.js b/themes/fukasawa/components/ArticleDetail.js index 961e3e40..65af8400 100644 --- a/themes/fukasawa/components/ArticleDetail.js +++ b/themes/fukasawa/components/ArticleDetail.js @@ -12,10 +12,11 @@ import ArticleAround from './ArticleAround' */ export default function ArticleDetail(props) { const { post, prev, next } = props + const { locale } = useGlobal() + if (!post) { return <> } - const { locale } = useGlobal() const date = formatDate(post?.date?.start_date || post?.createdTime, locale.LOCALE) return (
@@ -26,7 +27,7 @@ export default function ArticleDetail(props) {
)}
diff --git a/themes/hexo/LayoutSlug.js b/themes/hexo/LayoutSlug.js index 9e1d8aa4..12799877 100644 --- a/themes/hexo/LayoutSlug.js +++ b/themes/hexo/LayoutSlug.js @@ -51,7 +51,7 @@ export const LayoutSlug = props => { {!lock &&
-
+
{/* Notion文章主体 */}
{post && } diff --git a/themes/matery/LayoutSlug.js b/themes/matery/LayoutSlug.js index 1d3a7e48..02fc3060 100644 --- a/themes/matery/LayoutSlug.js +++ b/themes/matery/LayoutSlug.js @@ -64,7 +64,7 @@ export const LayoutSlug = props => { }
-
+
{/* Notion文章主体 */}
{showArticleInfo &&