a11y: Headings inconsistent & out of semantic order on results page
Closed this issue · 0 comments
iamjolly commented
Description:
Headings on the page are not nested consistently to provide a semantic match with the page's information structure conveyed visually.
- The first heading level 2 on the page should be the search input's
label
instead of anh2
element. - The
h3
for "Refine your search" hash2
elements for "Sections" and "Agencies" which are subordinate to theh3
, so they should beh4
or not headings at all (see video below about how screen readers encounter those). - The results cards in the
main
content on the page has anh2
for the result title (good), but then skipsh3
and usesh4
for the "FOUND IN" content header. That should be anh3
to reduce potential confusion for some users.
Screenshots:
Screencast/video:
sorns-refine-and-results-headings.mp4
WCAG SC
Success Criterion 1.3.1 Info and Relationships (Level A): Information, structure, and relationships conveyed through presentation can be programmatically determined or are available in text.
Recommended fix(es):
- Removing the
h2
and usinglabel
for the search input field per #129 will resolve the firsth2
issue. - Change the
h3
for Refine your search to anh2
- Replace the
h2
withdiv
elements for Sections and Agencies