p5.js-web-editor/developer_docs/accessibility.md
Cassie Tarakajian 8495a59e36
Development documentation (#705)
* delete unused files, move webpack configs to their own directory

* start of improved developer documentation, moving everything to developer_docs/ directory

* documentation updates
2018-09-26 16:14:06 -04:00

2.4 KiB

Accessibility Guidelines

Here is guide on how to use the accessible editor and here is an overview of the p5-accessibility.js library that makes p5.js sketches accessible to screen readers.

The code for the p5.js web editor adheres to web accessibility standards. The following guidelines will help to ensure that accessibility continues to be a priority as development continues.

Code Structure

  • Screen Readers are an assistive technology for vision loss which helps users to navigate a web page. They are able to prioritize content based on the semantic meaning of HTML tags. Therefore, it is important to use specific tags, such as nav, ul, li, section, and so on. div is the least screen reader friendly tag. For example, here is the semantic meaning of the body tag
  • All buttons/links/windows need to be accessible by the keyboard ( By tabbing, pressing space etc.)
  • In cases where tags are not screen reader friendly, we can take advantage of tabIndex. Using tabIndex ensures that all elements are accessible via keyboard. code example
  • When opening a new window or pop up window, ensure the keyboard focus also moves to the new window. code example

Labeling

  • When creating button icons, images, or something without text (this does not include an HTML5 <button>), use aria-labels. code example
  • All <table>s need to have a summary attribute. This will ensure user is given context to what the table is. code example
  • uls and navs menus need to include a title. code example

For more information on accessibility see the teach access tutorial