livestream.com Widescreen tweak

Expand the video on livestream.com while keeping the chat visible

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name        livestream.com Widescreen tweak
// @description Expand the video on livestream.com while keeping the chat visible
// @icon        https://lh4.googleusercontent.com/-HR473IkG4L8/AAAAAAAAAAI/AAAAAAAAE2E/tgp7xxNk6dI/s46-c-k-no/photo.jpg
// @version     0.3.2
// @license     GNU General Public License v3
// @copyright   2014, Nickel
// @grant       GM_addStyle
// @include     *://www.livestream.com/*
// @namespace https://greasyfork.org/users/10797
// ==/UserScript==

(function(){

// don't run in frames
if (frameElement){ return; }

// fallback (Chrome lacks GM functions)
if( typeof GM_addStyle != 'function' ) {
	function GM_addStyle(css) {
		var head, style;
		head = document.getElementsByTagName('head')[0];
		if( !head ){ return; }
		style = document.createElement('style');
		style.type = 'text/css';
		style.innerHTML = css;
		head.appendChild(style);
	}
}

// expand
document.getElementById("content").classList.add("expanded");
document.getElementById("expand-channel-player").classList.add("expanded");

// fix widths
GM_addStyle("#main {width:1280px !important;}");

GM_addStyle("#main-top {width:1310px !important;}");
GM_addStyle("#top-header {width:1280px !important;}");

GM_addStyle("#main-bottom {width:1310px !important;}");
GM_addStyle("#top-bottom {width:1280px !important;}");
GM_addStyle("#footer-main-bottom {width:1280px !important;}");

GM_addStyle("#main .box-wrap:not(#channel-chat):not(#like):not(#adContainer):not(#related-channels) {width:912px !important;}");
GM_addStyle("#main #channel-about .content {width:720px !important;}");
GM_addStyle("#main .box .footer {width:910px !important;}");

})();