Created
March 12, 2020 09:28
-
-
Save codepunkt/ce925dd3adb913b212182b0d9693a564 to your computer and use it in GitHub Desktop.
adblock banner delete - work in progress
This file contains 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 characters
document.querySelectorAll('*').forEach(el => { | |
const cs = getComputedStyle(el) | |
//const zIndex = +cs.zIndex | |
//const aboveThreshold = zIndex > 100000 | |
if (cs.position === 'fixed') { | |
console.log(el) | |
el.style.cssText += ';position:static !important;' | |
} | |
if (cs.overflow === 'hidden') { | |
el.style.cssText += ';overflow:auto !important;' | |
} | |
//if (aboveThreshold) { | |
// console.log(el) | |
// el.style.display = 'none'; | |
//} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment