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

Avoid ValueError with ARIA rowindex/colindex/rowcount/colcount in Firefox #13405

Merged

Conversation

AAClause
Copy link
Contributor

@AAClause AAClause commented Mar 1, 2022

Link to issue number:

Fixes #13404

Summary of the issue:

A bad value for aria-colcount, aria-rowcount, aria-colindex and aria-rowindex attributes causes a bug.

Description of how this pull request fixes the issue:

Make sure the value is numeric before casting it to integer, otherwise exclude it.

Testing strategy:

Tested with the following HTML Code Snippets (which were previously problematic now work properly):

  • <div role="grid" aria-colcount>Empty value (colcount)</div>
  • <div role="grid" aria-rowcount>Empty value (rowcount)</div>
  • <div role="grid" aria-colcount="abc">Wrong value (colcount)</div>
  • <div role="grid" aria-rowcount="abc">Wrong value (rowcount)</div>
  • <div role="grid" aria-colcount="-1">The table size is not known (colcount)</div>
  • <div role="grid" aria-rowcount="-1">The table size is not known (rowcount)</div>

References:

Known issues with pull request:

None but I think we should improve the restitution when aria-colcount and/or aria-rowcount is set to -1.

Change log entries:

Bug fixes:
- In Firefox, NVDA no longer fails to report items in web pages when aria-rowindex, aria-colindex, aria-rowcount or aria-colcount attributes are invalid. (#13405)

Code Review Checklist:

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

@AAClause AAClause force-pushed the aria-table-presentational-fix branch 2 times, most recently from ae54d56 to b9ad3f3 Compare March 8, 2022 10:10
@AAClause AAClause marked this pull request as ready for review March 8, 2022 10:41
@AAClause AAClause requested a review from a team as a code owner March 8, 2022 10:41
@AAClause AAClause requested a review from michaelDCurran March 8, 2022 10:41
@AAClause AAClause force-pushed the aria-table-presentational-fix branch from b9ad3f3 to 91aa035 Compare March 8, 2022 10:44
@michaelDCurran michaelDCurran merged commit 12319e7 into nvaccess:master Mar 9, 2022
@nvaccessAuto nvaccessAuto added this to the 2022.1 milestone Mar 9, 2022
feerrenrut added a commit that referenced this pull request Mar 15, 2022
feerrenrut added a commit that referenced this pull request Mar 17, 2022
feerrenrut added a commit that referenced this pull request Mar 17, 2022
@feerrenrut feerrenrut modified the milestones: 2022.1, 2022.2 Mar 17, 2022
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.

ARIA rowindex, colindex, rowcount and colcount can cause bug in Firefox
4 participants