From 8fa12607ff9cb96ba8a4e4c4066be76c51b89cd1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E5=A4=B4?= Date: Sun, 6 Aug 2023 18:04:38 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=9C=AA=E5=90=AF=E7=94=A8?= =?UTF-8?q?=E5=8F=B3=E9=94=AE=E8=8F=9C=E5=8D=95=E6=97=B6=EF=BC=8C=E6=B5=AE?= =?UTF-8?q?=E7=AA=97=E6=97=A0=E6=B3=95=E5=88=87=E6=8D=A2=E6=B7=B1=E8=89=B2?= =?UTF-8?q?=E6=A8=A1=E5=BC=8F=E7=9A=84=E9=97=AE=E9=A2=98=20(#382)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修复未启用右键菜单时,浮窗无法切换深色模式的问题 --- templates/assets/zhheo/blogex.js | 5 +++++ templates/assets/zhheo/rightmenu.js | 6 ------ templates/modules/widgets/console.html | 2 +- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/templates/assets/zhheo/blogex.js b/templates/assets/zhheo/blogex.js index b747ff83..54f625ce 100644 --- a/templates/assets/zhheo/blogex.js +++ b/templates/assets/zhheo/blogex.js @@ -316,6 +316,11 @@ var navFn = { categoriesOptionNew.legend.textStyle.color = color categoriesChart.setOption(categoriesOptionNew) } + heo.darkModeStatus(); + //代码块 + if(GLOBAL_CONFIG.prism.enable){ + halo.dataCodeTheme(); + } } } diff --git a/templates/assets/zhheo/rightmenu.js b/templates/assets/zhheo/rightmenu.js index 614dc722..041f99e7 100644 --- a/templates/assets/zhheo/rightmenu.js +++ b/templates/assets/zhheo/rightmenu.js @@ -204,12 +204,6 @@ async function copyImage(imageURL) { rm.switchDarkMode = function () { navFn.switchDarkMode(); rm.hideRightMenu(); - heo.darkModeStatus(); - //代码块 - if(GLOBAL_CONFIG.prism.enable){ - halo.dataCodeTheme(); - } - //halo.darkComment(); } diff --git a/templates/modules/widgets/console.html b/templates/modules/widgets/console.html index 79204420..eecca085 100644 --- a/templates/modules/widgets/console.html +++ b/templates/modules/widgets/console.html @@ -86,7 +86,7 @@
-