干净Bing

Bing搜索去除视频&相关信息板块、菜单栏不需要的选项、语音输入按钮

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         干净Bing
// @namespace    http://tampermonkey.net/
// @version      1.1
// @description  Bing搜索去除视频&相关信息板块、菜单栏不需要的选项、语音输入按钮
// @author       大触紫衣WisteriaZy
// @match        https://www.bing.com/search*
// @match        https://cn.bing.com/search*
// @grant        none
// @license      MIT
// ==/UserScript==

(function() {
    'use strict';

    // 视频
    const videoSection = document.querySelector('li.b_ans.b_mop.b_vidAns');
    if (videoSection) {
        videoSection.style.display = 'none';
    }

    // 新闻
    const newsSection = document.querySelector('li.b_ans.b_mop.b_nwsAns');
    if (newsSection) {
        newsSection.style.display = 'none';
    }

    // 趣味阅读
    const readSection = document.querySelector('li.b_ans.b_mop.b_mopb');
    if (readSection) {
        readSection.style.display = 'none';
    }

    // 语音输入
    const micSection = document.querySelector('#mic_cont_icon.mic_cont.icon.partner');
    if (micSection) {
        micSection.style.display = 'none';
    }

    // 隐藏导航栏中的不需要的项目
    function hideNavItemById(itemId) {
        const navItem = document.getElementById(itemId);
        if (navItem) {
            navItem.style.display = 'none';
        }
    }

    // Hide specific navigation items
    hideNavItemById('b-scopeListItem-video'); // 隐藏“视频”
    hideNavItemById('b-scopeListItem-dictionary'); // 隐藏“词典”
    hideNavItemById('b-scopeListItem-academic'); // 隐藏“学术”
    hideNavItemById('b-scopeListItem-menu');
    //hideNavItemById('b-scopeListItem-local'); // 隐藏“地图”(在“更多”里面)
    //hideNavItemById('b-scopeListItem-flights'); // 隐藏“航班”(在“更多”里面)

})();