Youtube in Black, not the ugly gray (dark mode must be active on youtube in order for it to work)
当前为
// ==UserScript==
// @name Youtube Black Mode
// @version 1
// @date 2020-05-22
// @author Paul Reiner
// @description Youtube in Black, not the ugly gray (dark mode must be active on youtube in order for it to work)
// @include http://*
// @include https://*
// @run-at document-end
// @namespace https://greasyfork.org/users/570213
// ==/UserScript==
(function(){
"use strict";
var x=window.location.toString().split("/")[2].split(".");
var y=x[x.length-2];
if (y == "youtube") {
document.getElementsByTagName("head")[0].innerHTML+='<style>html:not(.style-scope)[dark],:not(.style-scope)[dark]{--yt-spec-brand-background-solid:black;--yt-spec-brand-background-primary:#000000;--yt-spec-brand-background-secondary:#000000;--yt-spec-general-background-a: #000000;}ytd-browse[background-color-update][page-subtype="channels"]{background: #000000;}</style>';
}
})();