Last active
May 13, 2021 21:47
-
-
Save Odepax/d599626fac4941a85aebfa37b137a337 to your computer and use it in GitHub Desktop.
Revisions
-
Odepax revised this gist
May 13, 2021 . 1 changed file with 5 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,6 +1,6 @@ ((invertImages, invertCode, applyBlackBackground) => { document.body.style.filter = "invert()" document.body.style.background = applyBlackBackground ? "black" : "white" Array.from(document.querySelectorAll("pre")).map(pre => pre.style.filter = invertCode ? "invert()" : null) Array.from(document.querySelectorAll("img")).map(img => img.style.filter = invertImages ? "invert()" : null) })(/* Invert Image | Invert Code | Dark BG */ 1, 0, 1) -
Odepax created this gist
Mar 7, 2020 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,6 @@ ((invertImages, invertCode, applyBlackBackground) => { document.body.style.filter = "invert()" if (applyBlackBackground) document.body.style.background = "black" if (invertCode) Array.from(document.querySelectorAll("pre")).map(pre => pre.style.filter = "invert()") if (invertImages) Array.from(document.querySelectorAll("img")).map(img => img.style.filter = "invert()") })(/* Invert Image | Invert Code | Dark BG */ 1, 1, 1)