您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Disable site restrictions which prevent users on performing clipboard operations, text selection, page printing (experimental), and opening the Right-Click context menu. To open the Right-Click context menu use SHIFT+RightClick (the default; configurable in the script code).
当前为
// ==UserScript== // @name Disable Site Restriction On Page Operations // @namespace https://gf.qytechs.cn/en/users/85671-jcunews // @version 1.0.1 // @license AGPLv3 // @author jcunews // @description Disable site restrictions which prevent users on performing clipboard operations, text selection, page printing (experimental), and opening the Right-Click context menu. To open the Right-Click context menu use SHIFT+RightClick (the default; configurable in the script code). // @match *://*/* // @grant none // @run-at document-start // ==/UserScript== (() => { //=== CONFIGURATION BEGIN === //Setting for Right-Click. At least either SHIFT or CTRL should be set to true. let useShift = true; let useCtrl = false; //=== CONFIGURATION END === let epd = Event.prototype.preventDefault; Event.prototype.preventDefault = function() { switch (this.type) { case "cut": case "copy": case "paste": case "selectstart": return; case "contextmenu": if ((this.shiftKey === useShift) && (this.ctrlKey === useCtrl)) return; } return epd.apply(this, arguments); }; addEventListener("load", () => { document.body.appendChild(document.createElement("STYLE")).innerHTML = ` @media print { html, body { opacity: 1 !important; visibility: visible !important } html { display: ${getComputedStyle(document.documentElement).display} !important } body { display: ${getComputedStyle(document.body).display} !important } } * { user-select: auto !important; -moz-user-select: auto !important; -webkit-user-select: auto !important; -ms-user-select: auto !important; } `; }); })();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址