4chan Board List Toggle

Add a button to toggle the board list

K instalaci tototo skriptu si budete muset nainstalovat rozšíření jako Tampermonkey, Greasemonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

K instalaci tohoto skriptu si budete muset nainstalovat manažer uživatelských skriptů.

(Už mám manažer uživatelských skriptů, nechte mě ho nainstalovat!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Už mám manažer uživatelských stylů, nechte mě ho nainstalovat!)

// ==UserScript==
// @name            4chan Board List Toggle
// @namespace       4chan
// @version         1.0.5
// @description     Add a button to toggle the board list
// @icon            data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAMAAABg3Am1AAAACVBMVEUAAGcAAABmzDNZt9VtAAAAAXRSTlMAQObYZgAAAF5JREFUeNrtkTESABAQxPD/R6tsE2dUGYUtFJvLDKf93KevHJAjpBorAQWSBIKqFASC4G0pCAkm4GfaEvgYXl0T6HBaE97f0vmnfYHbZOMLZCx9ISdKWwjOWZSC8GYm4SUGwfYgqI4AAAAASUVORK5CYII=
// @include         https://boards.4chan.org/*
// @include         https://boards.4channel.org/*
// @include         http://boards.4channel.org/*
// @grant           none
// @license         MIT
// ==/UserScript==

var trigger = document.createElement('button');
trigger.id = 'trigger-btn';
var text_trigger = document.createTextNode('board');
trigger.appendChild(text_trigger);
document.body.appendChild(trigger);
var board = document.getElementById('board-list');
trigger.onclick = function() {
    board.style.bottom = '0px';
};
var close = document.createElement('button');
close.id = 'close-btn';
var text_close = document.createTextNode('close');
close.appendChild(text_close);
board.appendChild(close);
close.onclick = function() {
    board.style.bottom = '-250px';
};