Skip to content

Add additional accessibility-related authoring advice regarding <details> - #9989

Merged
domenic merged 2 commits into
whatwg:mainfrom
dbaron:accordion-grouping
Jan 9, 2024
Merged

domenic merged 2 commits into
whatwg:mainfrom
dbaron:accordion-grouping

Conversation

@dbaron

@dbaron dbaron commented Dec 12, 2023 •

Copy link
Copy Markdown
Member

This adds two pieces of advice discussed in
w3c/html-aam#509 and
#9899 .

  • At least two implementers are interested (and none opposed):
    • (I think this isn't relevant since this affects only document conformance and not implementation conformance)
  • MDN issue is filed: …
  • The top of this comment includes a clear commit message to use.

/interactive-elements.html ( diff )

Comment thread source Resolved
Comment thread source Resolved
Comment thread source Outdated
introduced with a heading, authors should put that heading in a <span
data-x="concept-heading">heading</span> element at the start of the containing element.</p>

<p class="note">Keeping related elements together can be important for accessibility.</p>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's improve this note while we're at it.

Suggested change
<p class="note">Keeping related elements together can be important for accessibility.</p>
<p class="note">Visually and programmatically grouping related elements together can be important for accessible user experiences. Doing so will help ensure users are more likely to understand the relationship between such elements. When related elements are not grouped, e.g., the associated elements are located in disparate sections of a web page, it can decrease the discoverability and/or the understandability of the elements' relationship to one another.</p>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Somehow github's "commit suggestion" UI wouldn't commit the suggestion... but I've incorporated it into the edit that I'll push shortly. I've edited the wording a bit but I don't think I've changed the substance.

One note is that I'm not a fan of "programatically" here (though I've left it for now) because that feels like it's referring to code in a programming language rather than tree structure of markup, but I'm not sure what alternative might be better. Maybe "structurally" or "logically"?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeh. the HTML spec is far too big for the comitting of suggestions.

you could use 'structurally' rather than 'programmatically' i suppose.

@domenic domenic left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice

@domenic
domenic merged commit 73902be into whatwg:main Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

3 participants