forked from HodofHod/SE-Modifications
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSidebarScrollbar.user.js
30 lines (27 loc) · 1.03 KB
/
SidebarScrollbar.user.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// ==UserScript==
// @name Sidebar Scrollbar
// @description Makes the lower starred messages in SE chat rooms accessible.
// @include http://chat.meta.stackoverflow.com/rooms/*
// @include http://chat.stackexchange.com/rooms/*
// @include http://chat.stackoverflow.com/rooms/*
// @include http://chat.askubuntu.com/rooms/*
// @match http://chat.meta.stackoverflow.com/rooms/*
// @match http://chat.stackexchange.com/rooms/*
// @match http://chat.stackoverflow.com/rooms/*
// @match http://chat.askubuntu.com/rooms/*
// @author @HodofHod
// @namespace HodofHod
// ==/UserScript==
function inject(f) {
var script = document.createElement('script');
script.type = 'text/javascript';
script.textContent = '(' + f.toString() + ')()';
document.body.appendChild(script);
}
function addScroll() {
var sidebar = document.querySelector('#sidebar');
sidebar.style.height = "auto";
sidebar.style.bottom = "88px";
sidebar.style.overflowY = "auto";
}
inject(addScroll);