From 0aa8c49b99d31ee5936fcfd14a9a561231c3b745 Mon Sep 17 00:00:00 2001 From: MrOtherGuy Date: Fri, 24 Mar 2023 10:44:05 +0200 Subject: [PATCH] selected_tab_as_urlbar: Add mechanism to show back and forward buttons --- chrome/selected_tab_as_urlbar.css | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/chrome/selected_tab_as_urlbar.css b/chrome/selected_tab_as_urlbar.css index 1328919..216cd98 100644 --- a/chrome/selected_tab_as_urlbar.css +++ b/chrome/selected_tab_as_urlbar.css @@ -10,6 +10,7 @@ See the above repository for updates as well as full license text. */ .urlbar-input-box{ z-index: -1 !important; } #urlbar{ z-index: auto !important; } #alltabs-button, +#unified-extensions-button, #PanelUI-button, #nav-bar-overflow-button{ z-index: 2; position: relative } @@ -46,14 +47,27 @@ See the above repository for updates as well as full license text. */ background-size: auto !important; } -:root:not([customizing]) #titlebar{ margin-bottom: -40px } +:root:not([customizing]) #titlebar{ margin-bottom: calc(0px - var(--tab-min-height) - 2*var(--tab-block-margin)); } /* Oh and! also hide other buttons from the nav-bar because why not */ :root:not([customizing]) #nav-bar-customization-target > :not(#urlbar-container){ visibility: collapse } -#TabsToolbar > .toolbar-items{ margin-right: 40px !important; } +#TabsToolbar > .toolbar-items{ margin-right: 80px !important; } +/* By default this style moves your back and forward buttons to the left edge of the navbar and adds a placeholder space for them. + Set the following pref to false to disable that behavior */ +@supports not -moz-bool-pref("userchrome.selected-tab-as-urlbar.nav-buttons-space.disabled"){ + #TabsToolbar > .toolbar-items{ margin-left: 80px } + :root[sizemode="normal"] #nav-bar-customization-target{ margin-left: 40px } + #back-button, #forward-button{ + -moz-box-ordinal-group: 0; + order: -1; + visibility: visible !important; + z-index: 2; + } +} #nav-bar{ + height: calc(var(--tab-min-height) + 2*var(--tab-block-margin)); padding-right: 138px; box-shadow: none !important; background-color: transparent !important; -} +} \ No newline at end of file