去除百度建议

去除百度拉的屎

// ==UserScript==
// @name         Remove Baidu Suggestion
// @name:zh-CN   去除百度建议
// @author       Zero
// @match        *://www.baidu.com/*
// @grant        none
// @run-at       document-start
// @description  Remove Baidu's shit
// @description:zh-CN 去除百度拉的屎
// @version      0.0.1
// @license      GNU GPLv3
// @namespace    rbs
// ==/UserScript==

(function() {
    const observer = new MutationObserver(() => {
        document.querySelectorAll('.bdsug-ai-guide').forEach(el => {
            el.closest('li')?.remove();
        });
    });
    observer.observe(document.body, { childList: true, subtree: true });

    const searchbar = document.getElementsByClassName('s_ipt');
    for(var a = 0; a < searchbar.length; a++){
        searchbar[a].setAttribute('placeholder', '');
    }
})();