From a9d47d3594ca654ef132542d8d5b4dc61705bc60 Mon Sep 17 00:00:00 2001 From: tangly1024 Date: Thu, 27 Jan 2022 10:03:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/Fukasawa/index.js | 2 ++ themes/Hexo/LayoutSlug.js | 5 +++-- themes/Hexo/components/SideRight.js | 2 +- themes/NEXT/index.js | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/themes/Fukasawa/index.js b/themes/Fukasawa/index.js index aabed077..e9e4db72 100644 --- a/themes/Fukasawa/index.js +++ b/themes/Fukasawa/index.js @@ -1,3 +1,5 @@ +import CONFIG_FUKA from './config_fuka' +export { CONFIG_FUKA as THEME_CONFIG } export { LayoutIndex } from './LayoutIndex' export { LayoutSearch } from './LayoutSearch' export { LayoutArchive } from './LayoutArchive' diff --git a/themes/Hexo/LayoutSlug.js b/themes/Hexo/LayoutSlug.js index 5800b844..b03095b9 100644 --- a/themes/Hexo/LayoutSlug.js +++ b/themes/Hexo/LayoutSlug.js @@ -39,12 +39,13 @@ export const LayoutSlug = props => { post.toc = getPageTableOfContents(post, post.blockMap) } + const headerImage = post?.page_cover ? `url("${post.page_cover}")` : `url("/${CONFIG_NEXT.HOME_BANNER_IMAGE}")` const headerSlot = (
-
+
{/* 文章Title */}
diff --git a/themes/Hexo/components/SideRight.js b/themes/Hexo/components/SideRight.js index 167d4ba4..f76ca950 100644 --- a/themes/Hexo/components/SideRight.js +++ b/themes/Hexo/components/SideRight.js @@ -25,7 +25,7 @@ export default function SideRight (props) { showTag } = props return ( -
+