1
0
Fork 0
mirror of https://github.com/kkapsner/CanvasBlocker synced 2025-07-04 20:46:39 +02:00

Theme in options page

This commit is contained in:
kkapsner 2019-04-30 23:29:38 +02:00
parent 31bc324019
commit 650f325702
8 changed files with 222 additions and 3 deletions

View file

@ -428,6 +428,16 @@
document.body.appendChild(version);
settings.onloaded(function(){
// load theme
var themeLink = document.createElement("link");
themeLink.href = `options-${settings.theme}.css`;
themeLink.rel = "stylesheet";
themeLink.type = "text/css";
document.head.appendChild(themeLink);
settings.on("theme", function(){
themeLink.href = `options-${settings.theme}.css`;
});
const reCaptchaEntry = "^https://www\\.google\\.com/recaptcha/api2/(?:b?frame|anchor).*$";
const {url: urlContainer} = settings.getContainers();
settings.on("protectWindow", function({newValue}){