-
Notifications
You must be signed in to change notification settings - Fork 6
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
♿ [#2435] Add aria-expanded to mobile anchors navigation #1273
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #1273 +/- ##
========================================
Coverage 95.18% 95.18%
========================================
Files 980 980
Lines 35687 35687
========================================
Hits 33969 33969
Misses 1718 1718 ☔ View full report in Codecov by Sentry. |
ca054a5
to
0c3cd06
Compare
012381f
to
b9fc781
Compare
{% button href="#" icon="expand_more" icon_position="after" extra_classes="anchor-menu--mobile__title anchor-menu__toggle" bordered=False text=_("Op deze pagina") %} | ||
<ul class="anchor-menu__list"> | ||
{% button icon="expand_more" icon_position="after" extra_classes="anchor-menu--mobile__title anchor-menu__toggle" bordered=False text=_("Op deze pagina") ariaExpanded="false" ariaControls="anchor-menu-list-mobile" %} | ||
<ul class="anchor-menu__list" id="anchor-menu-list-mobile"> |
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.
I don't see where the id
is used. Is this necessary?
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.
Yes. That ID is needed for the WAI_ARIA attribute "aria-controls".
Read more here: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-controls
issue https://taiga.maykinmedia.nl/project/open-inwoner/task/2435
note:
aria-expanded
only works for the elements that indicate if a control is expanded or collapsed.aria-controls
is not a hard requirement, but 'recommended'