您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Greasy Fork is available in English.
Remove footer from DeepL website
当前为
// ==UserScript== // @name DeepL Footer remover // @namespace http://tampermonkey.net/ // @version 0.1 // @description Remove footer from DeepL website // @match https://www.deepl.com/* // @license Unlicense // @grant none // ==/UserScript== (function() { 'use strict'; // Configuration object for target elements const TARGETS = { footer: 'footer', header: '.relative.bg-neutral-next-50 > .mobile\\:hidden' }; /** * Removes specified elements from the page */ function removeElements() { Object.entries(TARGETS).forEach(([key, selector]) => { const element = document.querySelector(selector); if (element) { element.remove(); console.log(`${key} removed`); } }); } /** * Initializes the script */ function init() { // Remove elements on initial page load removeElements(); // Set up MutationObserver to handle dynamic content const observerConfig = { childList: true, subtree: true }; const observer = new MutationObserver(removeElements); observer.observe(document.body, observerConfig); console.log('DeepL Footer Remover initialized'); } // Run the initialization function when the script loads init(); })();