Skip to content

Commit

Permalink
1.6.11 release
Browse files Browse the repository at this point in the history
  • Loading branch information
ThomazPom committed Dec 15, 2024
1 parent 05bda63 commit 211a1d4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion background.js
Original file line number Diff line number Diff line change
Expand Up @@ -1239,7 +1239,7 @@ class uDarkC extends uDarkExtended {
if (!possiblecolor || possiblecolor === "none") { // none is not a color, and it not usefull to create a style element for it
return false
}
if (uDark.website_context && possiblecolor.includes("var(")) {
if (!uDark.is_background && possiblecolor.includes("var(")) {
return uDark.is_color_var(possiblecolor, as_float, fill, cssRule, spanp)
}

Expand Down
2 changes: 1 addition & 1 deletion backgroundClass.js
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ class uDarkExtended extends uDarkExtendedContentScript {
}),
}
regiteredCS = []
is_background = true
is_background = true // Tell ultimadark that we are in the background script and is_color_var is not available for instance
loggingWorkersActiveLogging = false // Conider moving this to imageWorker to avoid messages passing for nothing
LoggingWorker = class LoggingWorker extends Worker {
constructor(...args) {
Expand Down
4 changes: 2 additions & 2 deletions contentScriptClass.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class uDarkExtendedContentScript {

is_content_script = true
website_context = true
website_context = true // Tell ultimadark we are in a website context and is_color_var is available
install() {
uDark.exportFunction = globalThis.exportFunction; // Don't override the exportFunction function, but make it available to ultimadark
console.info("UltimaDark", "Content script install", window);
Expand Down Expand Up @@ -83,7 +83,7 @@ class uDarkExtendedContentScript {
let start = performance.now();

uDark.info( "Content script override website", window);
uDark.website_context = true;
uDark.website_context = true; // Tell ultimadark we are in a website context and is_color_var is available
window.userSettingsReadyAction = function() {
uDark.success("User settings ready", window.userSettings);
if (!uDark.userSettings.keep_service_workers && window.navigator.serviceWorker) {
Expand Down

0 comments on commit 211a1d4

Please sign in to comment.