Content Editor

Press CTRL + SHIFT E to enable editing mode. this will allow you to edit any text of a website. Press CTRL + SHIFT + E again to turn it off.

当前为 2024-03-14 提交的版本,查看 最新版本

// ==UserScript==
// @name         Content Editor
// @namespace    http://tampermonkey.net/
// @version      6.0
// @description  Press CTRL + SHIFT E to enable editing mode. this will allow you to edit any text of a website. Press CTRL + SHIFT + E again to turn it off.
// @author       Aadoxide
// @match        *://*/*
// @icon         https://cdn.discordapp.com/attachments/983011546227703878/1217862855961870407/pencil-2307802775_1.png?ex=6605922b&is=65f31d2b&hm=9a13a84318a10d928be623bd157a4e124689d2814452e52dd309771fb9b2ef22&
// @license      WTFPL
// @grant        none
// ==/UserScript==

// i made this for my timepass just so you know.

(function() {
    'use strict';

    var notification = true; // optional
    let contentEditingEnabled = false;

    if (notification) {
        document.addEventListener('keydown', function(event) {
            if (event.ctrlKey && event.shiftKey && event.key === 'E') { // you can change the keybind if you want 👍
                contentEditingEnabled = !contentEditingEnabled;
                document.body.contentEditable = contentEditingEnabled;
                showNotification(`Editing Mode ${contentEditingEnabled ? 'Enabled' : 'Disabled'}`);
            }
        });
    }

    function showNotification(message) {
        const notificationElement = document.createElement('div');
        notificationElement.textContent = message;
        notificationElement.style.position = 'fixed';
        notificationElement.style.top = '10px';
        notificationElement.style.right = '10px';
        notificationElement.style.backgroundColor = 'rgba(0, 0, 0, 0.8)';
        notificationElement.style.color = 'white';
        notificationElement.style.padding = '10px';
        notificationElement.style.borderRadius = '5px';
        notificationElement.style.zIndex = '9999';

        document.body.appendChild(notificationElement);

        setTimeout(() => {
            document.body.removeChild(notificationElement);
        }, 2000); // duration of the notification (2 seconds)
    }
})();

QingJ © 2025

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