mirror of
https://github.com/gorhill/uBlock.git
synced 2024-09-04 10:09:38 +02:00
Do not set color-scheme CSS style in epicker for Firefox 106+
Related issue: - https://github.com/uBlockOrigin/uBlock-issues/issues/2240
This commit is contained in:
parent
f806438de6
commit
707609dc86
@ -890,7 +890,12 @@ const onMessage = function(request, sender, callback) {
|
||||
mouse: µb.epickerArgs.mouse,
|
||||
zap: µb.epickerArgs.zap,
|
||||
eprom: µb.epickerArgs.eprom,
|
||||
pickerURL: vAPI.getURL(`/web_accessible_resources/epicker-ui.html?secret=${vAPI.warSecret()}`),
|
||||
pickerURL: vAPI.getURL(
|
||||
`/web_accessible_resources/epicker-ui.html?secret=${vAPI.warSecret()}`
|
||||
),
|
||||
needColorScheme:
|
||||
vAPI.webextFlavor.soup.has('firefox') === false ||
|
||||
vAPI.webextFlavor.major < 106,
|
||||
});
|
||||
µb.epickerArgs.target = '';
|
||||
});
|
||||
|
@ -1281,11 +1281,15 @@ const pickerCSSStyle = [
|
||||
'visibility: visible',
|
||||
'width: 100%',
|
||||
'z-index: 2147483647',
|
||||
// https://github.com/uBlockOrigin/uBlock-issues/issues/1408
|
||||
'color-scheme: light',
|
||||
''
|
||||
];
|
||||
|
||||
// https://github.com/uBlockOrigin/uBlock-issues/issues/1408
|
||||
// https://github.com/uBlockOrigin/uBlock-issues/issues/2240
|
||||
if ( pickerBootArgs.needColorScheme ) {
|
||||
pickerCSSStyle.push('color-scheme: light');
|
||||
}
|
||||
pickerCSSStyle.push(''); // Important
|
||||
|
||||
const pickerCSS = `
|
||||
:root > [${vAPI.sessionId}] {
|
||||
${pickerCSSStyle.join(' !important;')}
|
||||
|
Loading…
Reference in New Issue
Block a user