您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
prevent user post a replying toot without click *reply* button of the origin toot.
// ==UserScript== // @name mastodon-confirm-no-replying // @namespace http://gholk.github.io // @version 1 // @grant none // @license GPLv3 // @description prevent user post a replying toot without click *reply* button of the origin toot. // @include https://g0v.social/* // @exclude https://g0v.social/settings/* // ==/UserScript== window.addEventListener('keydown', e=>{ const t = e.target; if (!(e.key == 'Enter' && e.ctrlKey)) return true if (t.nodeName == 'TEXTAREA' && t.matches('.autosuggest-textarea__textarea')) { const f = t.form; confirmNotReply(f, e) } }, { capture: true, passive: false }) window.addEventListener('click', e=>{ const b = e.target; if (b.matches('.compose-form__publish-button-wrapper *')) { const f = b.closest('form'); confirmNotReply(f, e) } }, { capture: true, passive: false }) function confirmNotReply(form, event) { const f = form const e = event if (f.querySelector('.reply-indicator')) return; if (confirm('not replying, toot this?')) return; e.preventDefault(); e.stopImmediatePropagation() }
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址