How can I preview PDFs with Google Chrome in dark mode / reverse color?
how to invert the color of pdf in chrome browser?
Reverse white and black colors in a PDF?
PDF viewer that can invert all colors
If you have question like this, then I can assure you that you will get your answer in this article.
This will be the ultimate solution for you.
Let's begin
STEP 1: Copy this JavaScript code :
_______________________________________
|
var cover = document.createElement("div");
let css = `
position: fixed;
pointer-events: none;
top: 0;
left: 0;
width: 100vw;
height: 100vh;
background-color: white;
mix-blend-mode: difference;
z-index: 1;`
cover.setAttribute("style", css);
document.body.appendChild(cover);
_______________________________________|
STEP 2: Right click on pdf and click on "Inspect Ctrl+Shift+I"
STEP 3: Click on "Console"
STEP 4: Paste the copied code and press Enter.
Congratulation!!
Before
 |
| Light mode pdf |
After
 |
| Dark mode pdf |
If you want to switch back to light mode , you can
simply refresh the page.
Hope it helped you :)
Post a Comment