-
Notifications
You must be signed in to change notification settings - Fork 3.1k
[#70166] Fix accessibility errors found by ERB Lint #21503
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
base: dev
Are you sure you want to change the base?
Conversation
f41d46d to
986b27b
Compare
- Replaces `title` attribute with `aria-label` for interactive elements. - Removes `title` from non-interactive elements. - Converts `<a>` tags without proper `href` to `<button>` elements, using Primer `Button`/`IconButton` where possible.
Removes all positive `tabindex` values.
986b27b to
f3d723b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This pull request addresses accessibility issues detected by ERB Lint with GitHub's A11y Linters, focusing on improving the accessibility of UI elements throughout the application.
Changes:
- Replaced redundant
titleattributes with appropriatearia-labelattributes on interactive elements - Converted icon-only buttons to use Primer Design System components with proper ARIA labels
- Updated test selectors to use accessible names for better test reliability
- Removed positive
tabindexvalues to improve keyboard navigation - Added security improvements (
rel="noopener") and form autocomplete attributes
Reviewed changes
Copilot reviewed 21 out of 21 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| spec/features/admin/custom_fields/work_packages/list_spec.rb | Updated test to use accessible_name selector for "Move to bottom" button |
| spec/features/admin/custom_fields/shared_custom_field_expectations.rb | Updated test to use accessible_name selector for "Move to top" button |
| modules/webhooks/spec/features/manage_webhooks_spec.rb | Simplified test selectors for webhook response modal triggers |
| modules/webhooks/app/views/webhooks/outgoing/admin/_form.html.erb | Removed redundant title attributes from legend elements |
| modules/webhooks/app/components/webhooks/outgoing/deliveries/response_component.rb | Renamed method from title to response_body_title for clarity |
| modules/webhooks/app/components/webhooks/outgoing/deliveries/response_component.html.erb | Converted link to Primer Button with proper ARIA labels and updated modal trigger selector |
| modules/two_factor_authentication/app/views/two_factor_authentication/two_factor_devices/totp/_form.html.erb | Removed redundant title attribute from legend |
| modules/two_factor_authentication/app/views/two_factor_authentication/two_factor_devices/sms/_form.html.erb | Removed redundant title attributes from legends |
| modules/two_factor_authentication/app/views/two_factor_authentication/two_factor_devices/confirm.html.erb | Removed positive tabindex values from form elements |
| modules/two_factor_authentication/app/views/two_factor_authentication/settings.html.erb | Added rel="noopener" to external link for security |
| modules/two_factor_authentication/app/views/two_factor_authentication/authentication/request_otp.html.erb | Removed positive tabindex values from form elements |
| modules/avatars/app/views/settings/_openproject_avatars.html.erb | Removed redundant title attributes from legends |
| modules/avatars/app/views/avatars/users/_local_avatars.html.erb | Removed redundant title attribute from legend |
| modules/avatars/app/views/avatars/users/_gravatars.html.erb | Removed redundant title attribute from legend |
| app/views/repositories/revision.html.erb | Changed title attributes to aria-label on list items |
| app/views/onboarding/_configuration_modal.html.erb | Removed redundant title attribute from button |
| app/views/members/_member_form.html.erb | Converted anchor tag to button element for close action with proper aria-label |
| app/views/ldap_auth_sources/_form.html.erb | Replaced custom toast with Primer Banner component and updated copyright format |
| app/views/custom_fields/_custom_options.html.erb | Replaced custom reorder links with Primer ButtonGroup component and updated copyright format |
| app/views/custom_actions/_form.html.erb | Changed title attribute to aria-label on close button |
| app/components/individual_principal_base_filter_component.html.erb | Added autocomplete="off" to name filter input |
| icon: :"arrow-up", | ||
| "aria-label": t(:label_sort_higher), | ||
| data: { action: "admin--custom-fields#moveRowUp" } | ||
| ) | ||
| component.with_button( | ||
| icon: :"arrow-down", |
Copilot
AI
Jan 16, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The icon names used here are inconsistent with the rest of the codebase. Other similar components use "chevron-up" and "chevron-down" for the up/down movement icons (see app/components/admin/custom_fields/hierarchy/item/actions_component.rb, app/components/admin/enumerations/item_component.rb, etc.), but this change uses :"arrow-up" and :"arrow-down". These should be changed to match the established pattern: use :"chevron-up" instead of :"arrow-up" and :"chevron-down" instead of :"arrow-down".
| icon: :"arrow-up", | |
| "aria-label": t(:label_sort_higher), | |
| data: { action: "admin--custom-fields#moveRowUp" } | |
| ) | |
| component.with_button( | |
| icon: :"arrow-down", | |
| icon: :"chevron-up", | |
| "aria-label": t(:label_sort_higher), | |
| data: { action: "admin--custom-fields#moveRowUp" } | |
| ) | |
| component.with_button( | |
| icon: :"chevron-down", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
Ticket
https://community.openproject.org/wp/70166
What are you trying to accomplish?
This PR fixes a number of Accessibility issues detected by ERB Lint + GitHub's A11y Linters.
See #13704
Screenshots
What approach did you choose and why?
This is not an exhaustive fix, but rather an incremental pass!!
Merge checklist