mirror of
https://github.com/XIU2/UserScript.git
synced 2026-09-07 11:27:41 +00:00
修复 知乎公式图片没有反色的问题(仅限反色的暗黑模式)
This commit is contained in:
+4
-4
@@ -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) {
|
||||
|
||||
@@ -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();}
|
||||
|
||||
Reference in New Issue
Block a user