From b4e4ad384577ba4219e7bf2f27d67d43e28cbce8 Mon Sep 17 00:00:00 2001 From: tangly1024 Date: Tue, 15 Mar 2022 13:32:39 +0800 Subject: [PATCH 01/10] =?UTF-8?q?=E5=88=87=E6=8D=A2=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E8=AF=B4=E6=98=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/themes/index.js b/themes/index.js index d47d2a42..286446ca 100644 --- a/themes/index.js +++ b/themes/index.js @@ -1,7 +1,6 @@ /** - * 修改 from 后面的路径,实现主题切换 + * 切换主题请修改 blog.config.js 中的 THEME 字段 */ - import * as next from './next' import * as fukasawa from './fukasawa' import * as hexo from './hexo' From e5c696b3790bb153c30472e0027af8e8e9f83e35 Mon Sep 17 00:00:00 2001 From: tangly1024 Date: Tue, 15 Mar 2022 13:32:58 +0800 Subject: [PATCH 02/10] =?UTF-8?q?Medium=E4=B8=BB=E9=A2=98=E9=A1=B6?= =?UTF-8?q?=E9=83=A8=E5=AF=BC=E8=88=AA=E6=A0=8F=E5=BE=AE=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/Medium/components/TopNavBar.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/themes/Medium/components/TopNavBar.js b/themes/Medium/components/TopNavBar.js index 78daa747..7b1ffa21 100644 --- a/themes/Medium/components/TopNavBar.js +++ b/themes/Medium/components/TopNavBar.js @@ -21,11 +21,11 @@ export default function TopNavBar (props) { if (link.show) { const selected = (router.pathname === link.to) || (router.asPath === link.to) return -
-
{link.name}
+
{link.name}
{link.slot}
From 3ecc3679957bf705fa5303d1f4781e937dd70d90 Mon Sep 17 00:00:00 2001 From: tangly1024 Date: Tue, 15 Mar 2022 13:35:34 +0800 Subject: [PATCH 03/10] =?UTF-8?q?Medium=E4=B8=BB=E9=A2=98=E9=A1=B6?= =?UTF-8?q?=E9=83=A8=E5=AF=BC=E8=88=AA=E6=A0=8F=E5=BE=AE=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/Medium/components/LogoBar.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/themes/Medium/components/LogoBar.js b/themes/Medium/components/LogoBar.js index ed622890..9bb3aa30 100644 --- a/themes/Medium/components/LogoBar.js +++ b/themes/Medium/components/LogoBar.js @@ -2,11 +2,9 @@ import BLOG from '@/blog.config' import Link from 'next/link' export default function LogoBar () { - return
-
+ return
} From a15fc196b27db98e4b72bc786fee890b59b04e5a Mon Sep 17 00:00:00 2001 From: tangly1024 Date: Tue, 15 Mar 2022 15:40:29 +0800 Subject: [PATCH 04/10] =?UTF-8?q?hexo=E4=B8=BB=E9=A2=98=E8=8F=9C=E5=8D=95?= =?UTF-8?q?=E6=A0=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/Hexo/components/Header.js | 5 +++-- themes/Hexo/components/MenuButtonGroupTop.js | 2 +- themes/Hexo/components/TopNav.js | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/themes/Hexo/components/Header.js b/themes/Hexo/components/Header.js index 25c06f1c..5a335ddb 100644 --- a/themes/Hexo/components/Header.js +++ b/themes/Hexo/components/Header.js @@ -51,7 +51,7 @@ export default function Header () { const scrollS = window.scrollY const nav = document.querySelector('#sticky-nav') - if (scrollS < 300) { + if (scrollS < 500) { nav && nav.classList.replace('bg-white', 'bg-none') nav && nav.classList.replace('text-black', 'text-white') } else { @@ -59,6 +59,7 @@ export default function Header () { nav && nav.classList.replace('text-white', 'text-black') } + // 自动滚动 if ((scrollS > windowTop) & (scrollS < window.innerHeight) && !autoScroll ) { autoScroll = true @@ -98,7 +99,7 @@ export default function Header () { return (