You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Header Stick: Search bar is on top of the navigation overlay #99
When the Header Stick design is used, and the navigation overlay is opened, the search bar from the footer area is visible at the bottom of the navigation overlay. It can be clicked on with the mouse, but it cannot be reached with the keyboard, since the focus is contained within the overlay.
This does not occur with the other header designs, default and collapsed.
My expectation would be for the search bar to not show above the overlay.
Where does it happen?
On the site (front end)
Steps to reproduce
In the Site Editor, edit the header template part and select the design called Header Stick. Save.
View the site on the front. This needs to be tested on a view that has the search bar, so for example NOT the search result page or the 404, but the index works fine for testing.
Reduce the browser window width so that the main menu in the header shows as the menu button.
Activate that button to open the navigation overlay.
See that the search bar shows when the overlay is open.
Try to interact with the search bar using mouse and keyboard.
Screenshots or screen recording
The opened overlay:
WordPress version
7.2
PHP version
8.2
Ipsum version
trunk
Gutenberg plugin version
No response
Browser and device
Chrome
Before you submit
I searched the existing issues and this bug hasn't been reported yet.
The navigation overlay has z-index: 100000. With the default and collapsed headers, the <header> isn't positioned, so that z-index competes at the page level and the overlay covers the pinned Search Bar.
With Header Stick, the header wrapper is position: sticky; z-index: 10, which creates a stacking context. The overlay's z-index: 100000 then only applies inside the header; at the page level, the whole header, overlay included, sits at 10. The Search Bar (.sticky-bottom) is also z-index: 10 and comes later in the DOM, so it paints on top of the open overlay.
The fix is to rank the sticky header one layer above the pinned bar, so the header and everything in it (overlay, submenus) always sits above it. This matches how the other header designs behave:
Activity
prasadkarmalkar commentedon Sep 24, 2026
I looked into this and found the cause.
The navigation overlay has
z-index: 100000. With the default and collapsed headers, the<header>isn't positioned, so that z-index competes at the page level and the overlay covers the pinned Search Bar.With Header Stick, the header wrapper is
position: sticky; z-index: 10, which creates a stacking context. The overlay'sz-index: 100000then only applies inside the header; at the page level, the whole header, overlay included, sits at10. The Search Bar (.sticky-bottom) is alsoz-index: 10and comes later in the DOM, so it paints on top of the open overlay.The fix is to rank the sticky header one layer above the pinned bar, so the header and everything in it (overlay, submenus) always sits above it. This matches how the other header designs behave:
header.wp-block-template-part:has(> .is-position-sticky) { position: sticky; inset-block-start: 0; - z-index: 10; + z-index: 11; }This keeps the change to a single value and doesn't rely on core's overlay class names or z-index values.
Let me know if this approach looks good. Happy to open a PR.
Header Sticky: Keep the open navigation overlay above the admin bar a…