diff options
Diffstat (limited to 'global/.local/share/qutebrowser/greasemonkey/youtube.css.js')
| -rw-r--r-- | global/.local/share/qutebrowser/greasemonkey/youtube.css.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/global/.local/share/qutebrowser/greasemonkey/youtube.css.js b/global/.local/share/qutebrowser/greasemonkey/youtube.css.js new file mode 100644 index 0000000..e86edf9 --- /dev/null +++ b/global/.local/share/qutebrowser/greasemonkey/youtube.css.js @@ -0,0 +1,18 @@ +// ==UserScript== +// @name YouTube +// @include *://*.youtube.com/* +// ==/UserScript== + +/* ~/.config/qutebrowser/greasemonkey/youtube.css.js :: */ + +document.addEventListener('load', () => { + try { document.querySelector('.ad-showing video').currentTime = 99999 } catch {} + try { document.querySelector('.ytp-ad-skip-button').click() } catch {} +}, true); + +GM_addStyle(` + ytd-compact-promoted-video-renderer, .ytd-action-companion-ad-renderer, + .ytd-ad-slot-renderer, .ytd-promoted-sparkles-web-renderer { + display: none !important; + } +`); |
