From c65dfe897493bf4561d8bba9daa15915082e4540 Mon Sep 17 00:00:00 2001 From: xiu2 <54703944+XIU2@users.noreply.github.com> Date: Sat, 31 Jul 2021 16:40:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20=E7=9F=A5=E4=B9=8E?= =?UTF-8?q?=E5=85=AC=E5=BC=8F=E5=9B=BE=E7=89=87=E6=B2=A1=E6=9C=89=E5=8F=8D?= =?UTF-8?q?=E8=89=B2=E7=9A=84=E9=97=AE=E9=A2=98=EF=BC=88=E4=BB=85=E9=99=90?= =?UTF-8?q?=E5=8F=8D=E8=89=B2=E7=9A=84=E6=9A=97=E9=BB=91=E6=A8=A1=E5=BC=8F?= =?UTF-8?q?=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DarkMode.user.js | 8 ++++---- Zhihu-Beautification.user.js | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/DarkMode.user.js b/DarkMode.user.js index 4506049..5cb30f1 100644 --- a/DarkMode.user.js +++ b/DarkMode.user.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 护眼模式 -// @version 1.2.3 +// @version 1.2.4 // @author X.I.U // @description 简单有效的全网通用护眼模式、夜间模式、暗黑模式 // @match *://*/* @@ -24,8 +24,8 @@ // @homepageURL https://github.com/XIU2/UserScript // ==/UserScript== -'use strict'; (function() { + 'use strict'; var menu_ALL = [ ['menu_disable', '✅ 已启用 (点击对当前网站禁用)', '❎ 已禁用 (点击对当前网站启用)', []], ['menu_runDuringTheDay', '白天保持开启 (比晚上亮一点点)', '白天保持开启', true], @@ -272,8 +272,8 @@ style_21_firefox = `html {filter: brightness(${style_20[0]}%) sepia(${style_20[1]}%) !important; background-image: url();}`, style_22 = `html {filter: brightness(${style_20[2]}%) sepia(${style_20[3]}%) !important;}`, style_22_firefox = `html {filter: brightness(${style_20[2]}%) sepia(${style_20[3]}%) !important; background-image: url();}`, - style_31 = `html {filter: invert(${style_30[0]}%) !important;} img, video {filter: invert(1) !important;} .mode-fullscreen video {filter: none !important;}`, - style_31_firefox = `html {filter: invert(${style_30[0]}%) !important; background-image: url();} img, video {filter: invert(1) !important;}`; + style_31 = `html {filter: invert(${style_30[0]}%) !important;} img, video {filter: invert(1) !important;}.mode-fullscreen video, img[alt="[公式]"] {filter: none !important;}`, + style_31_firefox = `html {filter: invert(${style_30[0]}%) !important; background-image: url();} img, video {filter: invert(1) !important;} .mode-fullscreen video, img[alt="[公式]"] {filter: none !important;}`; // Firefox 浏览器需要特殊对待 if (navigator.userAgent.toLowerCase().indexOf('firefox') > -1) { diff --git a/Zhihu-Beautification.user.js b/Zhihu-Beautification.user.js index 5c75b5d..93cc26b 100644 --- a/Zhihu-Beautification.user.js +++ b/Zhihu-Beautification.user.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 知乎美化 -// @version 1.2.7 +// @version 1.2.8 // @author X.I.U // @description 宽屏显示、暗黑模式(4种)、隐藏文章开头大图、调整图片最大高度、向下翻时自动隐藏顶栏、文章编辑页面与实际文章宽度一致、屏蔽登录提示 // @match *://www.zhihu.com/* @@ -19,8 +19,8 @@ // @homepageURL https://github.com/XIU2/UserScript // ==/UserScript== -'use strict'; (function() { + 'use strict'; var menu_ALL = [ ['menu_widescreenDisplay', '宽屏显示', '宽屏显示', true], ['menu_darkMode', '暗黑模式', '暗黑模式', true], @@ -278,7 +278,7 @@ html[data-theme=dark] div#zh-hovercard a {color: #353535 !important;} html {filter: invert(80%) !important;} img, .ZVideoItem-video, .ZVideo-video {filter: invert(1) !important;} .GifPlayer img, .GifPlayer.isPlaying video {filter: invert(1) !important;} -.GifPlayer.isPlaying img.ztext-gif.GifPlayer-gif2mp4Image {filter: none !important;} +.GifPlayer.isPlaying img.ztext-gif.GifPlayer-gif2mp4Image, img[alt="[公式]"] {filter: none !important;} `, style_darkMode_2_firefox = `/* 暗黑模式(方案 2) */ html {filter: invert(80%) !important; background-image: url();}