Ionaru / easy-markdown-editor

EasyMDE: A simple, beautiful, and embeddable JavaScript Markdown editor. Delightful editing for beginners and experts alike. Features built-in autosaving and spell checking.
https://stackblitz.com/edit/easymde
MIT License
2.38k stars 314 forks source link

Add ARIA role=application #464

Closed vanillajonathan closed 2 years ago

vanillajonathan commented 2 years ago

Improves accessibility.

Ionaru commented 2 years ago

The application role indicates to assistive technologies that an element and all of its children should be treated similar to a desktop application, and no traditional HTML interpretation techniques should be used. This role should only be used to define very dynamic and desktop-like web applications. Most mobile and desktop web apps are not considered applications for this purpose.

https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/application_role

Doesn't this defeat the purpose of all the other attributes used in the editor? The editor is definitely not a "desktop-like web application."

vanillajonathan commented 2 years ago

I think that means that an entire application shouldn't be have this role, like for example on the html or the body attribute, but since EasyMDE is a component within an web page it is it's own component.

I am not an expert on WCAG though.

The popular TinyMCE editor has the role attribute set to application on it's container element.