mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-01-31 19:02:59 +01:00
Accessibility fix for JAWS screen readers
ace.js: removed the role 'application' from innerDocument.body. JAWS do not read any text from the edit lines if this role is set. domline.createDomLine: to give JAWS the ability to read the lines correctly, it is required to set the attribute 'aria-live' to 'assertive'.
This commit is contained in:
parent
15995acc2a
commit
84d6d277d7
2 changed files with 2 additions and 1 deletions
|
@ -284,7 +284,6 @@ const Ace2Editor = function () {
|
|||
// <body> tag
|
||||
innerDocument.body.id = 'innerdocbody';
|
||||
innerDocument.body.classList.add('innerdocbody');
|
||||
innerDocument.body.setAttribute('role', 'application');
|
||||
innerDocument.body.setAttribute('spellcheck', 'false');
|
||||
innerDocument.body.appendChild(innerDocument.createTextNode('\u00A0')); //
|
||||
|
||||
|
|
|
@ -61,6 +61,8 @@ domline.createDomLine = (nonEmpty, doesWrap, optBrowser, optDocument) => {
|
|||
|
||||
if (document) {
|
||||
result.node = document.createElement('div');
|
||||
// JAWS and NVDA screen reader compatibility. Only needed if in a real browser.
|
||||
result.node.setAttribute('aria-live', 'assertive');
|
||||
} else {
|
||||
result.node = {
|
||||
innerHTML: '',
|
||||
|
|
Loading…
Reference in a new issue