// ==UserScript== // @name spiegel.de: entferne störende Elemente // @description Entfernt ausgewählte Elemente von Spiegel Online // @namespace https://greasyfork.org/de/users/541444-critias // @match https://www.spiegel.de/ // @match https://www.spiegel.de/* // @version 1.1 // @grant none // @downloadURL none // ==/UserScript== var candidateSelectors = [ 'article.py-16', 'li.py-16', 'article.lg\\:py-24', 'div.pb-16', 'li > a.text-black', 'div.mb-16', 'div.z-10', 'main.z-20 > section.relative', ]; candidateSelectors = candidateSelectors.toString(); var links = document.querySelectorAll( 'a[href^=\'https://www.spiegel.de/thema/test_und_produkte\'], a[href^=\'https://www.spiegel.de/fotostrecke/bilder-des-tages\'], a[href^=\'https://www.bento.de\'], a[href^=\'https://www.manager-magazin.de\'], a[href^=\'https://www.spiegel.de/deinspiegel/\']'); for(var link of links) { var containerElement = link.closest(candidateSelectors); if(containerElement && containerElement.parentElement){ containerElement.parentElement.removeChild(containerElement); } } candidateSelectors = candidateSelectors.toString(); var links2 = document.querySelectorAll('[data-target-id="content-marketing"],[data-contains-flags="sponpaid"],[data-conditional-flag="sponpaid"],[data-contains-flags^="conditional"],[data-conditional-flag^="paid"],[data-contains-flags^="paid"], div [aria-label^=Anzeige], div [aria-label="Die Bilder des Tages"], div [data-target-id="digital-abo-ew"]'); for(var link2 of links2) { var containerElement2 = link2.closest(candidateSelectors); if(containerElement2 && containerElement2.parentElement){ containerElement2.parentElement.removeChild(containerElement2); } } (function() { 'use strict'; var badSpans = document.querySelectorAll('div [data-area^="block>podlove:acht_milliarden"], div [data-area^="block>podlove:spiegel_update"], div [data-area^="block>podlove:und_was_machst"], div [data-area^="block>podlove:smarter_leben"], div [data-area^="block>podlove:stimmenfang"], div [data-area*="_spiegel+"], section[data-area="block>highlight:bild_des_tages"], section[data-area*="Podcast von bento"], div [data-area^="block>podlove:spiegel_live"], div [data-area^="group:tests"], section[data-area^="block>podlove:und_was_machst"], section[data-area="block>DeinSPIEGEL"], section[data-area="latest-news"], section[data-area="block>sportdaten"],[data-area^="block>podcastslider"]') badSpans.forEach((s) => { if(s !== undefined) { s.remove() } }) })();