-
Notifications
You must be signed in to change notification settings - Fork 121
Don't make the header sticky by default #524
Comments
The above is even more important considering the inability to change the 'sticky' setting globally. When users want to change this setting, they have to do it manually for each template. I'd argue this is a very frustrating experience and I'm not sure it helps users in any way. Cc @carolinan |
I don't disagree with potentially changing the header to not be sticky, though this screenshot is far from the likely result. We should strive to resolve towards likely/expected results, rather than extreme. |
I wonder why it was decided to make the header sticky in the first place. I think the footnotes example is a much bigger issue than the massive menu one. As we should strive to make an accessible-ready theme, I'd be in favour of removing the stickiness from the header. |
+1000 |
I agree. The 'massive' menu example is obviously an edge case. I'd like to point out that also a smaller menu that goes in two or three rows on mobile would be problematic though. |
Skip to content links can have a similar problem too. The example of a giant menu, or multiple shorter rows on a smaller screen, illustrates that the header does not have a predictable height (or even an expected height range). I have used |
There is also a problem with the sticky menu and the lightbox focus outline. When the lightbox is "closed", the focus outline of the image is above the sticky header, but visually the image is below. I would like to look at this closer before I create a GitHub issue though. |
I'm also in favor of not having a sticky header. |
Just a note that a few days ago October 5) the Web Content Accessibility Guidelines 2.2 became the new official recommendation. The new recommendation introduces some new success criteria. One of them is relevant: Success Criterion 2.4.11 Focus Not Obscured (Minimum) When a user interface component receives keyboard focus, the component is not entirely hidden due to author-created content. In a few words, this new success criterium requires to ensure that, when an item gets keyboard focus, it is at least partially visible. That means that, from now on, for Core and bundled themes any fixed / sticky / absolutely positioned element and the like must not hide the currently focused element, for example when tabbing forwards and backwards. Any fixed / sticky header and the like are basically banned unless there is a mechanism in place to make sure the focused element is always (at least partially) visible. See a brief description on the 'What's new' post at: |
Thanks for sharing this detailed information @afercia! Since the sticky header got removed, we're good to go. :) |
Thanks @luminuu I know the default setting is not sticky now, thanks. My point is that all bundled theme and also Core should remove any such fixed sticky elements unless there is a mechanism to make the focused element always visible. This applies not only to Twenty Twenty-Four but also to all the previous and future bundled themes, if they sue such positioning:
I thought this was an important information for the Themes team. |
@afercia This is indeed important, but since we're only working on Twenty Twenty-Four here, I think it would be the best if you open an issue in Trac and label it with |
Description
it's a known fact that fixed / sticky headers or top bars may introduce usability and accessibility issues. While testing the footnotes block in the context of WordPress/gutenberg#54843 I noticed that the sticky header in the theme makes the user experience less than ideal.
Specifically, following a footnote link and clicking the 'jump back' link in the footnote does make the page scroll as expected but the page frgment that should scroll into view is always hidden behind the fixed header.
This is a very confusing experience for all users (it happens also when clicknw with mouse) and even more confusing for keyboard users.
Since the sticky header height can't be predicted, as it actually depends on the amount of links in the navigation, the only option I can think of is to change the default setting. The header should not be sticky by default. That would provide users with a default user experience that is less than ideal.
Step-by-step reproduction instructions
Expected behavior
Focused links and controls to be visible.
Screenshots
Animated GIF to illustrate the footnotes behavior:
Environment info
Additional context
The text was updated successfully, but these errors were encountered: