NOTICE: By continued use of this site you understand and agree to the binding Terms of Service and Privacy Policy.
// ==UserScript== // @name Bigger TogetherTube // @namespace https://openuserjs.org/scripts/captzulu/Bigger_TogetherTube // @version 0.1 // @description use all the screen for a bigger video // @author Captzulu // @match https://togethertube.com/rooms/* // @grant none // ==/UserScript== var container=$('#player').parents("div.container-non-responsive"); var ButtonAdded; (function() { ButtonAdded = $('<button id="ButtonBigger" type="button" class="btn btn-default navbar-btn">' + '</button>'); if(checkIfBigger()){ ButtonAdded.text("Smaller Player"); }else{ ButtonAdded.text("Bigger Player"); } $("#bs-example-navbar-collapse-1").append(ButtonAdded); //--- Activate the newly added button. ButtonAdded.click(ButtonClickAction); })(); function ButtonClickAction () { console.log("test"); if(!checkIfBigger()){ container.removeClass("container-non-responsive").css("padding","20px"); $("div.panel-body.chatlog").css("height","700px").parents(); ButtonAdded.text("Smaller Player"); }else{ container.addClass("container-non-responsive").css("padding","0px"); $("div.panel-body.chatlog").css("height","447px"); ButtonAdded.text("Bigger Player"); } } function checkIfBigger () { if($(container).filter(".container-non-responsive").length===0){ return true; }else{ return false; } }