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

Feature/image editor a11y #11496

Merged
merged 104 commits into from Jul 25, 2022
Merged

Feature/image editor a11y #11496

merged 104 commits into from Jul 25, 2022

Conversation

gcamacho079
Copy link
Contributor

@gcamacho079 gcamacho079 commented Jun 23, 2022

Description

  • Implement keyboard handlers and ARIA roles for Image Editor tabs (Resolves DEV-499)
  • Make image constraint options keyboard accessible by using a radio field group (Resolves DEV-505)
  • Give custom constraint inputs accessible labels (Resolves DEV-510)
  • Use fieldsets for orientation and constraint options (Resolves DEV-508)
  • Make slide rule for image rotation keyboard accessible (Resolves DEV-500)
  • Refocus Edit button on Image Editor close (Resolves DEV-495, DEV-451, DEV-450)
  • Keep image rotation graduations from being clipped on text zoom (Resolves DEV-503)
  • Move orientation fieldset before constraints to maintain meaningful focus order (Resolves DEV-507)
  • Prevent constraint options from causing horizontal scrolling at 320px (Resolves DEV-512)

Related issues

…e; update radio inputs for minimum touch target size
@linear
Copy link

linear bot commented Jun 23, 2022

DEV-499 When editing image assets, Rotate and crop options are not keyboard accessible

Rotate and Crop "buttons" are not keyboard accessible, so users can't switch between Image Editor panels

The Rotate and Crop buttons should be built using the Tabs with Manual Activation authoring guidelines, and vertical (up and down arrow) keyboard handlers should be included along with the ones outlined in the document

Resolves CMS-015

DEV-505 Image crop constraints are not keyboard accessible

Image crop constraints are built using clickable divs, which are not accessible to keyboard users

Crop constraints should be built using a set of radio buttons

Resolves CMS-152

Screen Shot 2022-04-18 at 9.51.54 AM.png

DEV-510 Custom constraint text inputs do not have programmatically determined labels

There is no programmatic label for the constraint width/height inputs for the custom option

The fields should be given at least visually-hidden labels to solve this issue

Resolves CMS-157

Screen Shot 2022-04-18 at 11.18.12 AM.png

DEV-500 Slider for image rotation is not keyboard accessible

The image rotation slider is not accessible to keyboard or screen reader users, as it requires clicking and dragging the .slide-rule div

Recommendation is to use an accessible component like the Horizontal Slider to build the rotation component

Screen Shot 2022-04-18 at 6.28.48 AM.png

Resolves CMS-017

DEV-495 When closing the Image Editor modal, focus is not returned to the element that triggered it

Location: Asset (Single)

When closing the image editor with the keyboard using the ESC key, focus is not returned to the button that triggered it

Return focus to the "Edit" button when the modal is closed

Resolves CMS-144

DEV-503 Doubling size of text content causes loss of rotation angle information

When a user with low vision doubles the size of text content, the text bar below the rotation control becomes clipped so that a user can no longer see the angle of rotation.

Element heights and positioning should be adjusted so that they are not clipped when the content is zoomed.

Resolves CMS-150

Screen Shot 2022-04-18 at 9.18.37 AM.png

DEV-507 Constraints should come after portrait/landscape option, instead of after

When a user selects a new orientation, the constraint options are updated. A screen reader user would not know that the content has updated, and a keyboard user would have to tab backwards to take advantage of the new options.

The orientation selector should be moved ahead of the constraints in the DOM order to maintain a meaningful focus order.

Resolves CMS-153

Screen Shot 2022-04-18 at 10.35.15 AM.png

gcamacho079 and others added 2 commits June 23, 2022 10:02
# Conflicts:
#	src/web/assets/cp/dist/cp.js
#	src/web/assets/cp/dist/cp.js.map
#	src/web/assets/garnish/dist/garnish.js
#	src/web/assets/garnish/dist/garnish.js.map
shinybrad and others added 28 commits July 25, 2022 13:31
Avoids JS errors that could occur via a race condition, by switching modes too quickly with the keyboard
@brandonkelly brandonkelly merged commit dcd3351 into 4.2 Jul 25, 2022
@brandonkelly brandonkelly deleted the feature/image-editor-a11y branch July 25, 2022 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accessibility 👤 features related to accessibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants