aboutsummaryrefslogtreecommitdiffstats
path: root/Nettavisen noblink
diff options
context:
space:
mode:
Diffstat (limited to 'Nettavisen noblink')
-rw-r--r--Nettavisen noblink/Nettavisen noblink.user.js25
1 files changed, 25 insertions, 0 deletions
diff --git a/Nettavisen noblink/Nettavisen noblink.user.js b/Nettavisen noblink/Nettavisen noblink.user.js
new file mode 100644
index 0000000..080d2bc
--- /dev/null
+++ b/Nettavisen noblink/Nettavisen noblink.user.js
@@ -0,0 +1,25 @@
+// ==UserScript==
+// @name Nettavisen noblink
+// @namespace snake66
+// @description Remove annoying blinking backgrounds and animated marquees at nettavisen.no.
+// @include https://*.nettavisen.no/*
+// @version 1
+// @grant none
+// ==/UserScript==
+
+let nettavisen_blink_classes = [
+ 'optimus-element-sonar',
+]
+
+function nettavisen_noblink()
+{
+ for (let cls of nettavisen_blink_classes) {
+ for (let blinker of document.getElementsByClassName(cls)) {
+ console.log("Trying to remove blinker: " + blinker.toString())
+ blinker.remove()
+ }
+ }
+}
+
+let nettavisen_obsrvr = new MutationObserver(nettavisen_noblink)
+nettavisen_obsrvr.observe(document, { attributes: true, childList: true, subtree: true })