去你妈的秒懂

去除百度系网站的秒懂百科/视频,目前支持百度百科、百度知道

目前為 2023-03-14 提交的版本,檢視 最新版本

// ==UserScript==
// @name         去你妈的秒懂
// @namespace    http://tampermonkey.net/
// @version      0.1.3
// @license      unlicense
// @description  去除百度系网站的秒懂百科/视频,目前支持百度百科、百度知道
// @author       PRO
// @match        https://*.baidu.com/*
// @icon         https://www.baidu.com/favicon.ico
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    var domain = document.domain;
    var names = [];
    switch(domain){ // 添加域名-class的映射来适配更多网站
        case 'baike.baidu.com':
            names = ['second-wrapper'];
            break;
        case 'jingyan.baidu.com':
            names = ['feeds-video-box', 'feeds-video-one-view', 'video-wrapper'];
            break;
    };
    if (names) {
        var index;
        var flag = false;
        for (name of names){
            // [debug] console.log(names[index]);
            var sb = document.getElementsByClassName(name)[0];
            if (sb){
                sb.remove();
                flag = true;
            };
            if (flag){
                console.log(`[去你妈的秒懂] ${name} 元素移除成功!`);
            }
            else {
                console.log(`[去你妈的秒懂] 未发现 ${name} 元素!`);
            };
        };
    }
    else {
        console.log('[去你妈的秒懂] 暂不支持此站点,请提交适配反馈!');
    };
})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址