From f973f447a1ed3b528e44a496a7a0926fab0fbd28 Mon Sep 17 00:00:00 2001 From: MrOtherGuy Date: Sat, 16 Oct 2021 08:47:27 +0300 Subject: [PATCH] use absolute positioning for window controls in fullscreen --- chrome/window_control_placeholder_support.css | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/chrome/window_control_placeholder_support.css b/chrome/window_control_placeholder_support.css index ff0ea7a..9c81c35 100644 --- a/chrome/window_control_placeholder_support.css +++ b/chrome/window_control_placeholder_support.css @@ -35,8 +35,10 @@ See the above repository for updates as well as full license text. */ /* macOS settings are further below */ .titlebar-buttonbox, #window-controls{ color: var(--toolbar-color) } -:root[sizemode="fullscreen"] .titlebar-buttonbox-container:not(:last-child){ display: none !important } +:root[sizemode="fullscreen"] .titlebar-buttonbox-container{ display: none } :root[sizemode="fullscreen"] #navigator-toolbox { position: relative; } + +:root[sizemode="fullscreen"] #TabsToolbar > .titlebar-buttonbox-container:last-child, :root[sizemode="fullscreen"] #window-controls{ position: absolute; display: flex; @@ -44,7 +46,10 @@ See the above repository for updates as well as full license text. */ right:0; height: 40px; } + +:root[sizemode="fullscreen"] #TabsToolbar > .titlebar-buttonbox-container:last-child, :root[uidensity="compact"][sizemode="fullscreen"] #window-controls{ height: 32px } + #nav-bar{ border-inline: var(--uc-window-drag-space-pre,0px) solid var(--toolbar-bgcolor); border-inline-style: solid !important; @@ -58,4 +63,6 @@ See the above repository for updates as well as full license text. */ :root[tabsintitlebar="true"]:not([inFullscreen]) #nav-bar{ border-inline-width: calc(var(--uc-window-control-width,0px) + var(--uc-window-drag-space-post,0px)) var(--uc-window-drag-space-pre,0px) } + :root[sizemode="fullscreen"] #TabsToolbar > .titlebar-buttonbox-container:last-child, + :root[sizemode="fullscreen"] #window-controls{ right: unset } }