您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
tuifei breaker
// ==UserScript== // @name 4245 - 洛谷强力学术 // @namespace http://tampermonkey.net/ // @version 1.0 // @author Yt_4245 // @icon https://cdn.luogu.com.cn/upload/usericon/1334245.png // @description tuifei breaker // @match *://*/* // @grant none // @license MIT // @run-at document-start // ==/UserScript== (function() { 'use strict'; const ALLOW_RULES = [ /^https:\/\/(www\.)?luogu\.com\.cn\/?$/i, /^https:\/\/(www\.)?luogu\.com\.cn\/problem(\/list)?/i, /^https?:\/\/.*\.?deepseek\.com\/.*/i, /^https?:\/\/.*\.?doubao\.com\/.*/i, /^https:\/\/fanyi\.baidu\.com\/.*/i, /^https:\/\/www\.baidu\.com\/s\?.*wd=.*/i, /^https:\/\/(ai|chat|knowledge)\.baidu\.com\/.*/i ]; function shouldAllow() { const currentURL = window.location.href.toLowerCase(); return ALLOW_RULES.some(regex => regex.test(currentURL)); } if (!shouldAllow()) { console.warn('[学术模式] 拦截非学习网站:', window.location.href); window.location.replace('https://www.luogu.com.cn/problem/list'); } })();