Skip to content

Instantly share code, notes, and snippets.

@rishubil
Last active October 5, 2019 04:54
Show Gist options
  • Save rishubil/6759277b9905ce4b159b7aaf57e92a2b to your computer and use it in GitHub Desktop.
Save rishubil/6759277b9905ce4b159b7aaf57e92a2b to your computer and use it in GitHub Desktop.
fixed-youtube-player.user.js
// ==UserScript==
// @name Fixed Youtube Player
// @namespace fixed-youtube-player
// @author Nesswit
// @version 0.1
// @description Youtube player has fixed position with theater mode
// @downloadURL https://gist.github.com/rishubil/6759277b9905ce4b159b7aaf57e92a2b/raw/fixed-youtube-player.user.js
// @updateURL https://gist.github.com/rishubil/6759277b9905ce4b159b7aaf57e92a2b/raw/fixed-youtube-player.user.js
// @include https://www.youtube.com/watch?v=*
// @match about:blank
// @grant GM_addStyle
// @run-at document-start
// ==/UserScript==
GM_addStyle(`
#ytd-player {
position: fixed;
z-index: 1000000;
width: 100%;
height: calc((9 / 16) * 100vw);
}
`);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment