一个折中可变亮的方法:将下列代码贴到油猴脚本保存,刷新界面即可。不过能力有限,一些控件没能改变颜色,且和其他恢复彩色的脚本冲突,可选择将其关闭再用。
- // ==UserScript==
- // @name 暗黑模式转明亮
- // @namespace http://tampermonkey.net/
- // @version 0.1
- // @description for waxianzhi.com
- // @author Lingmi
- // @match *://*.waxianzhi.com/*
- // @icon https://www.google.com/s2/favicons?sz=64&domain=waxianzhi.com
- // @grant none
- // ==/UserScript==
- (function() {
- 'use strict';
- javascript:(function(){var nightmode=function(w){(function(d){var css='html,img,video{filter:invert(1) hue-rotate(180deg);}body{background:#000;}';var s=d.getElementsByTagName('style');for(var i=0,si;si=s[i];i++){if(si.innerHTML==css){si.parentNode.removeChild(si);return}};var heads=d.getElementsByTagName('head');if(heads.length){var node=d.createElement('style');node.type='text/css';node.appendChild(d.createTextNode(css));heads[0].appendChild(node)}})(w.document);for(var i=0,f;f=w.frames[i];i++){try{arguments.callee(f)}catch(e){}}};nightmode(window)})();
- // Your code here...
- })();
复制代码 |