fix: #3618888 Free the Tab key and give the editors an accessible name

Fixes #3618888.

Three accessibility fixes for the two editable integrations (text editor and field widget); the read-only formatter and filter are unaffected:

  • Enable Ace's keyboard-accessibility mode, so Tab moves focus out of the editor and Esc leaves it (WCAG 2.1.2 No Keyboard Trap). Guarded for older Ace builds.
  • Carry the field's label to the editor as its accessible name (textInputAriaLabel), so assistive technology names the replacement the same as the field.
  • Mark the editor required when the original textarea was.

Verification

On Drupal 11.4.5: the editor reports keyboard accessibility on, and the field label "Body" is carried as the accessible name. eslint PASS.

Checkpoints:

  • File an issue
  • Addition/Change/Update/Fix
  • Testing to ensure no regression
  • Automated unit testing coverage
  • Automated functional testing coverage
  • UX/UI designer responsibilities
  • Readability
  • Accessibility
  • Performance
  • Security
  • Developer Documentation
  • User Guide Documentation
  • Reviewed by human
  • Code review by maintainers
  • Full testing and approval
  • Credit contributors
  • Review with the product owner
  • Release notes snippet
  • Release

AI-Generated: Yes

Edited by Rajab Natshah

Merge request reports

Loading
Loading