mirror of https://github.com/gorhill/uBlock.git
Restore ability to set popup panel font size in advanced settings
Related issue: - https://github.com/uBlockOrigin/uBlock-issues/issues/397 Issue above will require non-trivial changes, so for now users who prefer smaller/larger popup panel can fall back on advanced setting `popupFontSize`: https://github.com/gorhill/uBlock/wiki/Advanced-settings#popupfontsize
This commit is contained in:
parent
565680e4e5
commit
8859d4352f
|
@ -511,7 +511,7 @@ body:not([data-more~="e"]) [data-more="e"] {
|
||||||
}
|
}
|
||||||
:root.desktop #main {
|
:root.desktop #main {
|
||||||
max-width: 340px;
|
max-width: 340px;
|
||||||
min-width: 290px;
|
width: 22em;
|
||||||
}
|
}
|
||||||
:root:not(.mobile) #switch:hover {
|
:root:not(.mobile) #switch:hover {
|
||||||
background-color: var(--default-surface-hover);
|
background-color: var(--default-surface-hover);
|
||||||
|
|
|
@ -30,14 +30,13 @@
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
||||||
/*
|
|
||||||
let popupFontSize;
|
let popupFontSize = 'unset';
|
||||||
vAPI.localStorage.getItemAsync('popupFontSize').then(value => {
|
vAPI.localStorage.getItemAsync('popupFontSize').then(value => {
|
||||||
if ( typeof value !== 'string' || value === 'unset' ) { return; }
|
if ( typeof value !== 'string' || value === 'unset' ) { return; }
|
||||||
document.body.style.setProperty('font-size', value);
|
document.body.style.setProperty('font-size', value);
|
||||||
popupFontSize = value;
|
popupFontSize = value;
|
||||||
});
|
});
|
||||||
*/
|
|
||||||
|
|
||||||
// https://github.com/chrisaljoudi/uBlock/issues/996
|
// https://github.com/chrisaljoudi/uBlock/issues/996
|
||||||
// Experimental: mitigate glitchy popup UI: immediately set the firewall
|
// Experimental: mitigate glitchy popup UI: immediately set the firewall
|
||||||
|
@ -581,7 +580,6 @@ let renderOnce = function() {
|
||||||
|
|
||||||
const body = document.body;
|
const body = document.body;
|
||||||
|
|
||||||
/*
|
|
||||||
if ( popupData.fontSize !== popupFontSize ) {
|
if ( popupData.fontSize !== popupFontSize ) {
|
||||||
popupFontSize = popupData.fontSize;
|
popupFontSize = popupData.fontSize;
|
||||||
if ( popupFontSize !== 'unset' ) {
|
if ( popupFontSize !== 'unset' ) {
|
||||||
|
@ -592,7 +590,6 @@ let renderOnce = function() {
|
||||||
vAPI.localStorage.removeItem('popupFontSize');
|
vAPI.localStorage.removeItem('popupFontSize');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
|
|
||||||
uDom.nodeFromId('version').textContent = popupData.appVersion;
|
uDom.nodeFromId('version').textContent = popupData.appVersion;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue