您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Remove o limite de 2000 caracteres do Discord no navegador
当前为
// ==UserScript== // @name Discord Character Limit Remover // @namespace Discord Character Limit Remover // @version 1.2 // @description Remove o limite de 2000 caracteres do Discord no navegador // @author EmersonxD // @match https://discord.com/* // @grant none // @run-at document-start // @license MIT // ==/UserScript== (function() { 'use strict'; const overrideLimit = () => { // Remove a validação de comprimento máximo const originalQuery = window.NativeTextInput.prototype._getMaxLength; window.NativeTextInput.prototype._getMaxLength = function() { return null; }; // Remove a validação do evento de input const originalInput = window.NativeTextInput.prototype._onInput; window.NativeTextInput.prototype._onInput = function(e) { e.target.value = e.target.value; this.emit('change', e.target.value); }; // Remove a validação no envio const originalSend = window.DiscordNative?.window?.sendMessage; if (originalSend) { window.DiscordNative.window.sendMessage = (message) => { return originalSend(message); }; } }; // Observa mudanças no DOM para aplicar em novos elementos const observer = new MutationObserver(() => { if (document.querySelector('[data-slate-editor="true"]')) { overrideLimit(); } }); observer.observe(document.body, { childList: true, subtree: true }); // Aplica imediatamente se o editor já estiver carregado if (document.querySelector('[data-slate-editor="true"]')) { overrideLimit(); } })();