From c8902ae6cda4be6be35c1a34bb83b61be165d470 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Thu, 14 Jul 2016 19:57:26 +0200 Subject: [PATCH] Fixed search input with fixed header --- .../files/style/layout/pageHeaderSticky.scss | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/wcfsetup/install/files/style/layout/pageHeaderSticky.scss b/wcfsetup/install/files/style/layout/pageHeaderSticky.scss index 4dd8994015..c3a103b351 100644 --- a/wcfsetup/install/files/style/layout/pageHeaderSticky.scss +++ b/wcfsetup/install/files/style/layout/pageHeaderSticky.scss @@ -117,9 +117,21 @@ } } - .pageHeaderSearchInputContainer { + &:not(.searchBarOpen) .pageHeaderSearchInputContainer { display: none; } + + &.searchBarOpen .pageHeaderSearchInputContainer { + position: absolute; + + // Regular top calculation does not work because one of the parents + // is set to `position: fixed`, screwing up the entire calculation. + // We can work around this by using a relative top value of 100% + // which equals the total height of the parent container. + top: 100% !important; + } + + } } -- 2.20.1