Greasy Fork

cleanW3SchoolsAds

clean w3schools.com ads

目前为 2023-03-07 提交的版本。查看 最新版本

// ==UserScript==
// @name         cleanW3SchoolsAds
// @namespace    http://tampermonkey.net/
// @version      0.15
// @description  clean w3schools.com ads
// @author       [email protected]
// @match        https://*.w3schools.com/*
// @match        http://*.w3schools.com/*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=w3schools.com
// @grant        none
// @license      MIT
// @run-at       document.body
// ==/UserScript==

(function() {
    'use strict';
    let css=`
        [data-google-query-id],
        [class*="showcase"],.showcasebackend,.showcasebootcamp,.showcasesubs,
        #right,#internalCourses,#mainLeaderboard,#skyscraper,#tryitLeaderboard,#midcontentadcontainer
    {
        display:none!important;width:0!important;height:0!important;
        min-width:0!important;min-height:0!important;
        transform:scale(0.0001) translate3d(-99999px,-9999px,0px);
    }
    .w3-col.l10{width:98%!important}
    .trytopnav{top:0!important}
    #container{top:48px!important}
    `
    var style = document.createElement('style'); style.innerText = css;
    document.body.appendChild(style)
    // Your code here...
})();