diff --git a/src/css/popup-fenix.css b/src/css/popup-fenix.css index 20627607a..71a2af874 100644 --- a/src/css/popup-fenix.css +++ b/src/css/popup-fenix.css @@ -36,9 +36,13 @@ a { position: relative; } #main { + align-self: flex-start; max-width: 340px; min-width: 18em; } +:root.portrait #main { + align-self: inherit; + } hr { border: 0; border-top: 1px solid #e3e2e3; @@ -260,6 +264,9 @@ body[data-more=""] #lessButton { text-align: right; --rule-cell-width: 5em; } +:root.desktop body.vMin #firewall { + max-height: 100vh; + } #firewall > div { border: 0; direction: ltr; diff --git a/src/js/background.js b/src/js/background.js index 7ed4db62d..8a357c97e 100644 --- a/src/js/background.js +++ b/src/js/background.js @@ -68,6 +68,7 @@ const µBlock = (( ) => { // jshint ignore:line popupFontSize: 'unset', popupPanelDisabledSections: 0, popupPanelLockedSections: 0, + popupPanelHeightMode: 0, requestJournalProcessPeriod: 1000, selfieAfter: 3, strictBlockingBypassDuration: 120, diff --git a/src/js/messaging.js b/src/js/messaging.js index 7a67a7423..85baa9190 100644 --- a/src/js/messaging.js +++ b/src/js/messaging.js @@ -290,6 +290,7 @@ const popupDataFromTabId = function(tabId, tabTitle) { popupPanelSections: µbus.popupPanelSections, popupPanelDisabledSections: µb.hiddenSettings.popupPanelDisabledSections, popupPanelLockedSections: µb.hiddenSettings.popupPanelLockedSections, + popupPanelHeightMode: µb.hiddenSettings.popupPanelHeightMode, tabId: tabId, tabTitle: tabTitle, tooltipsDisabled: µbus.tooltipsDisabled diff --git a/src/js/popup-fenix.js b/src/js/popup-fenix.js index 579c46b9e..89c77301b 100644 --- a/src/js/popup-fenix.js +++ b/src/js/popup-fenix.js @@ -639,6 +639,11 @@ let renderOnce = function() { if ( popupData.advancedUserEnabled !== true ) { uDom('#firewall [title][data-src]').removeAttr('title'); } + + // This must be done the firewall is populated + if ( popupData.popupPanelHeightMode === 1 ) { + body.classList.add('vMin'); + } }; /******************************************************************************/