From 880acd5c115ff663fba22a1f6f5ff980c1628dac Mon Sep 17 00:00:00 2001 From: PaperDragon <2678885646@qq.com> Date: Fri, 10 Nov 2023 00:20:51 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B1=8F=E8=94=BDF12=E6=8C=89=E9=94=AE?= =?UTF-8?q?=EF=BC=8C=E5=B9=B6=E6=B7=BB=E5=8A=A0=E8=B7=B3=E8=BD=AC=E6=9C=BA?= =?UTF-8?q?=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/.vuepress/config.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/.vuepress/config.ts b/src/.vuepress/config.ts index 589a2b27569..5d1083d47d9 100644 --- a/src/.vuepress/config.ts +++ b/src/.vuepress/config.ts @@ -20,9 +20,17 @@ export default defineUserConfig({ /*禁用F12*/ document.onkeydown = function(){ if(window.event.keyCode==123) { - alert('大佬,别扒了!不妨加个友链?\\n执意要做?再按下F12可调出控制台'); + var x; + var r=confirm('大佬,别扒了!不妨加个友链?\\n点击确认键跳转到友链!\\n\\n执意要做?亦或是再按下F12可调出控制台\\n'); + if (r==true){ + //x="你按下的是\\"确定\\"按钮。"; + window.location.replace("/友链/友链.html"); + } + else{ + x="你按下的是\\"取消\\"按钮。"; + } + // document.write(x) event.preventDefault(); // 阻止默认事件行为 - event.keyCode=0; event.returnValue=false; }