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

Report aria-label and aria-description even when parent has no visible children #16471

Merged
merged 8 commits into from May 8, 2024

Conversation

SaschaCowley
Copy link
Member

Link to issue number:

Fixes #14514

Summary of the issue:

HTML figure elements with no accessible children (EG, all children set to aria-hidden=true) but with an aria-label or aria-description are not reported by NVDA.

Description of user facing changes

Elements with no accessible children but which have a label or description are now reported in browse mode. Note this only applies to elements which are still rendered; if all children are set to display: none, for example, NVDA still does not report the parent element.

Description of development approach

Render a single space in elements with no content but a label or description set.

Testing strategy:

Manually tested in Firefox and Edge, using the example markup provided by the OP.

Known issues with pull request:

N/A

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

@seanbudd
Copy link
Member

seanbudd commented May 1, 2024

is this ready for review?

@SaschaCowley SaschaCowley marked this pull request as ready for review May 1, 2024 07:22
@SaschaCowley SaschaCowley requested a review from a team as a code owner May 1, 2024 07:22
@SaschaCowley SaschaCowley requested a review from seanbudd May 1, 2024 07:22
@seanbudd seanbudd added this to the 2024.3 milestone May 2, 2024
@seanbudd seanbudd added the conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review. label May 7, 2024
@seanbudd
Copy link
Member

seanbudd commented May 7, 2024

Could you move the changes to the new changes.md for this PR please?

@seanbudd seanbudd added the blocked/merge-conflicts Merge conflicts exist on this PR label May 7, 2024
@seanbudd seanbudd merged commit a1848dd into nvaccess:master May 8, 2024
1 check was pending
XLTechie pushed a commit to XLTechie/xlnvda that referenced this pull request May 10, 2024
…e children (nvaccess#16471)

Fixes nvaccess#14514

Summary of the issue:
HTML figure elements with no accessible children (EG, all children set to aria-hidden=true) but with an aria-label or aria-description are not reported by NVDA.

Description of user facing changes
Elements with no accessible children but which have a label or description are now reported in browse mode. Note this only applies to elements which are still rendered; if all children are set to display: none, for example, NVDA still does not report the parent element.

Description of development approach
Render a single space in elements with no content but a label or description se
@LeonarddeR
Copy link
Collaborator

I'm afraid this pr has unexpected side effects. Se #16554

@@ -1262,11 +1262,13 @@ VBufStorage_fieldNode_t* GeckoVBufBackend_t::fillVBuf(
parentNode->isBlock=false;
}

if ((isInteractive || role == ROLE_SYSTEM_SEPARATOR) && parentNode->getLength() == 0) {
if ((isInteractive || role == ROLE_SYSTEM_SEPARATOR || name || description.has_value()) && parentNode->getLength() == 0) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should name be changed to name.has_value() here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked/merge-conflicts Merge conflicts exist on this PR conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review. queued for merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

A <figure>'s aria-label and description is not spoken when it has a child element with aria-hidden="true"
3 participants