Skip to content
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

fix: role for th element in context #33

Merged
merged 1 commit into from
Jan 27, 2025

Conversation

jlp-craigmorten
Copy link
Contributor

Changes

Relates to #25

Updates the role returned for a th element to be either:

  1. columnheader when the scope is col or colgroup;
  2. rowheader when the scope is row or rowgroup;
  3. gridcell when the element is nested within a table element with role grid or treegrid;
  4. cell when the element is nested within a table element otherwise;
  5. columnheader otherwise per the existing precedent to return a sensible defaults unless empty ancestors are explicitly provided.

This detail is currently missing from the HTML-ARIA spec, but is describe in the sibling HTML-AAM spec:

How to Review

Nothing of note.

Checklist

  • Unit tests updated

Copy link

changeset-bot bot commented Jan 25, 2025

🦋 Changeset detected

Latest commit: 5c450df

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
html-aria Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@jlp-craigmorten jlp-craigmorten marked this pull request as ready for review January 25, 2025 15:27
@drwpow drwpow merged commit c257353 into drwpow:main Jan 27, 2025
6 checks passed
@github-actions github-actions bot mentioned this pull request Jan 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants