From 7778ed2e08fdd7c0129496359bb9f15db6296e06 Mon Sep 17 00:00:00 2001 From: MrOtherGuy Date: Tue, 29 Oct 2019 19:34:50 +0200 Subject: [PATCH] Collapse the toolbar instead of negative margins --- chrome/autohide_tabstoolbar.css | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/chrome/autohide_tabstoolbar.css b/chrome/autohide_tabstoolbar.css index cddb042..d23ab74 100644 --- a/chrome/autohide_tabstoolbar.css +++ b/chrome/autohide_tabstoolbar.css @@ -1,10 +1,14 @@ /* Hide tabs unless cursor is on top of toolbar */ -/* This does not support multi-row tabs */ -:root:not([customizing]) #titlebar{ - margin-bottom: calc(0px - var(--tab-min-height)); - transition: margin-bottom 48ms ease-out; +@keyframes slidein{ + from{ margin-top: calc(0px - var(--tab-min-height)) } + to{ margin-top: 0 } } -#TabsToolbar:not([customizing]){ visibility: hidden; } -#navigator-toolbox:hover > #titlebar{ margin-bottom: 0; } -#navigator-toolbox:hover > #titlebar > #TabsToolbar{ visibility: visible; } +@keyframes slideout{ + from{ margin-top: var(--tab-min-height) } + to{ margin-top: 0 } +} +#navigator-toolbox:not(:hover) > #titlebar{ -moz-appearance: none !important } +#navigator-toolbox:not(:hover) #TabsToolbar:not([customizing]) { visibility: collapse } +#navigator-toolbox:hover > #nav-bar:not([customizing]){ animation: slidein ease-out 48ms 1 } +#navigator-toolbox:not(:hover) > #nav-bar:not([customizing]){ animation: slideout ease-out 48ms 1 } \ No newline at end of file