Greasy Fork

Greasy Fork is available in English.

洛谷学术神器

隐藏:犇犇、讨论、私信、通知等,专心刷题!

当前为 2020-06-22 提交的版本,查看 最新版本

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         洛谷学术神器
// @namespace    http://tampermonkey.net/
// @version      0.14
// @description  隐藏:犇犇、讨论、私信、通知等,专心刷题!
// @author      TNT°
// @match        *://*.luogu.com.cn/*
// @match        *://*.luogu.org/*
// @grant        none
// ==/UserScript==
(function() {
    'use strict'
    var benben_01 = 0, discuss_01 = 0, chat_01 = 0, notification_01 = 0;
    $sidebar = $('#app-old .lg-index-content .lg-right.am-u-lg-3');
    $firstele = $($sidebar.children()[0]);
   $finder = $(`
<div class="lg-article" id="console-form">
<script>
function save_benben_01(){
    var benben_txt;
    benben_txt = $('[name=inbenben]')[0].value;
    localStorage.benben_storage = benben_txt;
    return benben_txt;
}
function save_benben_01(){
    var benben_txt;
    benben_txt = $('[name=inbenben]')[0].value;
    localStorage.benben_storage = benben_txt;
    return benben_txt;
}
</script>
<h3 align="center">学术控制台</h3>
<small>(0:关闭;1:打开)</small>
<form id="console">
  是否打开犇犇: <input type="text" class="am-form-field"  name="inbenben" placeholder="是否打开犇犇" autocomplete="off" />
<button id="benben-button" onclick="save_benben_01()">确定</button><br>
  是否打开讨论: <input type="text" class="am-form-field"  name="indiscuss" placeholder="是否打开讨论" autocomplete="off" />
<button id="discuss-button" onclick="save_discuss_01()">确定</button><br>
是否打开私信: <input type="text" class="am-form-field"  name="inchat" placeholder="是否打开私信" autocomplete="off" />
<button id="chat-button" onclick="save_chat_01()">确定</button><br>
是否打开通知: <input type="text" class="am-form-field"  name="innotification" placeholder="是否打开通知" autocomplete="off" />
  <button id="notification-button" onclick="save_notification_01()">确定</button><br>
</form>
<div align="center"><small>这里是学术控制台,泥可以在这里控制泥想打开的学术模式哦qwq</small></div>
</div>
`);
$finder.insertAfter($firstele);
})();