Fix visual of DOM inspector layer in dark theme mode

Related discussion:
- https://github.com/uBlockOrigin/uBlock-issues/discussions/2359
This commit is contained in:
Raymond Hill 2022-11-17 09:25:20 -05:00
parent d9744d012a
commit 105c7f5446
No known key found for this signature in database
GPG key ID: 25E1490B761470C2
2 changed files with 8 additions and 1 deletions

View file

@ -784,6 +784,12 @@ const bootstrap = function(ev) {
}
const pickerDoc = ev.target.contentDocument;
pickerDoc.documentElement.style.setProperty(
'color-scheme',
'dark light',
'important'
);
const style = pickerDoc.createElement('style');
style.textContent = [
'body {',
@ -855,6 +861,7 @@ pickerRoot.style.cssText = [
'border: 0',
'border-radius: 0',
'box-shadow: none',
'color-scheme: light dark',
'display: block',
'height: 100%',
'left: 0',

View file

@ -1272,6 +1272,7 @@ const pickerCSSStyle = [
'border: 0',
'border-radius: 0',
'box-shadow: none',
'color-scheme: light dark',
'display: block',
'filter: none',
'height: 100vh',
@ -1291,7 +1292,6 @@ const pickerCSSStyle = [
'visibility: hidden',
'width: 100%',
'z-index: 2147483647',
'color-scheme: light dark',
''
];