-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP]fix(styles): horizontal nav a11y #5087
Conversation
✅ Deploy Preview for fundamental-styles ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@@ -1,19 +1,18 @@ | |||
<div style="height: 500px"> | |||
<nav class="fd-navigation fd-navigation--horizontal" aria-label="Horizontal Navigation"> | |||
<div class="fd-navigation__container"> | |||
<ul class="fd-navigation__list" role="menubar" aria-label="Horizontal Navigation"> | |||
<ul class="fd-navigation__list" role="tablist" aria-orientation="horizontal" aria-label="Horizontal Navigation"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the default aria-orientation for role="tablist" is horizontal, you don't need to specify it (just FYI)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UI5 does
> | ||
<div | ||
class="fd-navigation__item" | ||
aria-current="page" | ||
aria-selected="false" | ||
aria-expanded="false" | ||
role="menuitem" | ||
role="tab" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Role tab
needs the following:
- aria-labelledby: this should be leading to the span that wraps the text
- aria-controls: referring to the tabpanel that the tab controls
- aria-posinset and aria-setsize
- aria-selected
- aria-expanded
- aria-haspopup: if the tab has a popup menu
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
> | ||
<div | ||
class="fd-navigation__item" | ||
aria-current="page" | ||
aria-selected="false" | ||
aria-expanded="false" | ||
role="menuitem" | ||
role="tab" | ||
> | ||
<a class="fd-navigation__link" role="link" href="#"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in this case, since we now have Tabs, I am not sure if we need the role link and the href
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, technically it's still a navigation, and link can be applied to it, no?
waiting for the signed off a11y design spec |
can be reopened once the a11y design spec is finalized |
Related Issue
Closes none
Description