Lichess Compact Lobby

Display enterable tournaments and simuls within seek box. Hide leaderboards.

当前为 2015-10-22 提交的版本,查看 最新版本

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

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

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

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

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

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

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

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

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

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

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

// ==UserScript==
// @id          Lichess_Compact_Lobby@https://github.com/ddugovic/UserScripts
// @name        Lichess Compact Lobby
// @namespace   https://github.com/ddugovic/UserScripts
// @description Display enterable tournaments and simuls within seek box. Hide leaderboards.
// @author      ddugovic
// @copyright   2015+, ddugovic
// @license     CC0 1.0 Universal
// @supportURL  https://github.com/ddugovic/UserScripts/issues
// @version     0.1
// @match       http://*.lichess.org/
// @grant       none
// @icon        https://raw.githubusercontent.com/ornicar/lila/master/public/images/favicon-32-white.png
// ==/UserScript==

var container = document.getElementById('hooks_wrap');
var theOriginal = document.getElementById('enterable_tournaments').parentNode;
var theClone = theOriginal.cloneNode(true);
container.insertBefore(theClone, container.lastChild);
theClone.style.marginTop = '0px';
theClone.style.marginBottom = '15px';
theOriginal.parentNode.removeChild(theOriginal);

theOriginal = document.getElementById('enterable_simuls').parentNode;
theClone = theOriginal.cloneNode(true);
container.insertBefore(theClone, container.lastChild);
theClone.style.marginTop = '0px';
theClone.style.marginBottom = '15px';
theOriginal.parentNode.removeChild(theOriginal);

leaderboards = document.getElementsByClassName('leaderboard');
var i;
for (i = leaderboards.length-1; i >= 0; i--) {
    leaderboards[i].parentNode.removeChild(leaderboards[i]);
}