您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
11/27/2023, 6:47:56 AM
// ==UserScript== // @name Accented letters workaround for WhatsApp on Firefox Linux // @namespace Violentmonkey Scripts // @match https://web.whatsapp.com/ // @grant none // @version 1.0 // @author André Kugland // @license MIT // @description 11/27/2023, 6:47:56 AM // ==/UserScript== // https://forum.manjaro.org/t/whatsapp-web-deleting-letter-that-starts-with-accent/119772 // This script was created through trial and error. I don’t know why it works, but it does // work, at least for me in my particular configuration. (() => { const eatevent = (e) => { e.preventDefault(); e.stopPropagation(); return false; }; for (const evtype of ["compositionstart", "compositionend"]) { document.addEventListener(evtype, (e) => { eatevent(e); if (evtype == "compositionstart") { document.addEventListener("input", eatevent, true); } if (evtype == "compositionend") { document.removeEventListener("input", eatevent, true); } }, true); } })();