Skip to content

Commit

Permalink
update version
Browse files Browse the repository at this point in the history
  • Loading branch information
yujinpan committed Apr 4, 2020
1 parent 584b3fe commit 2e09e88
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,3 +121,7 @@
- 兼容 img 的 `srcset` 属性
- 去掉重复的资源
- 修改按钮的动态透明度,不遮挡内容

## 黑白

黑白化网站。
19 changes: 19 additions & 0 deletions scripts/black-and-white.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// ==UserScript==
// @name 黑白
// @namespace https://github.com/yujinpan/tampermonkey-extension
// @version 1.0
// @license MIT
// @description 网站黑白化。
// @author yujinpan
// @include http*://**
// ==/UserScript==

(function () {
var html = document.querySelector('html');
var style = html.getAttribute('style') || '';
if (style && style.slice(-1) !== ';') style += ';';
html.setAttribute('style',
style +
'filter: progid:DXImageTransform.Microsoft.BasicImage(grayscale=1);' +
'filter: grayscale(100%);');
})();

0 comments on commit 2e09e88

Please sign in to comment.