Home > Software engineering >  Prevent jaws from reading "password" twice in password-type input fields
Prevent jaws from reading "password" twice in password-type input fields

Time:04-12

I have a password field that is reading out "password : password" by JAWS screen reader. I want to change that so it only reads out "password" once. I tried various things such as using an aria-hidden tag or aria-label=" " but I still get the same results. There was an identical question asked 5 years ago, however there was never a perfect answer given as the one marked still had its issues. Link to that here.

Code example:

<label for='password' id='login-password-label'>Password:</label>

<input type="password" name="password" required="required" tabindex="2" id="password" maxlength="20" />

What else can I try to prevent JAWS from reading out password twice in the password field? I'm using Chrome browser.

CodePudding user response:

The speech output I get from JAWS 2022 in Chrome 95 is: "Password: password edit Required invalid entry".

The reason you're getting a second "password" there is not because JAWS is repeating the field label but because JAWS is announcing the <input> field type, which in this case is a password field.

Screen readers treat password fields differently from regular text fields because passwords contain sensitive information which is not read out in the same was as regular text fields. So the screen reader has to announce to the user that the edit field is a password field, hence the second "password" announcement in your example.

Back to your question, it's not advisable for you to circumvent JAWS announcing the field type (the second "password" bit in your announcement) because it's standard screen reader behaviour and would violate accessibility guidelines. In any case, many JAWS users would be familiar with this type of speech pattern when they encounter a standard password edit field on a web page.

  • Related