Testing accessibility using Mac VoiceOver for web pages - html

I am working on developing/testing accessibility of a web page using VoiceOver [Mac Tool].
Typical workflow I am using is trial and error,
Do changes to HTML
Open page in browser
Turn on VoiceOver and test and again #1
What I understand is VoiceOver convert/see HTML/Webpage in text form and starts reading it. I hope how it does it would make it easy for me to understand how to make process easy.
So I want to know if there is any tool or utility or guidelines which could assist me to see HTML/Webpage the way VoiceOver does. I mean tool which take html as input and then output text file like VoiceOver (JUST to understand what changes affects VoiceOver in what way quickly).
Any inputs will be really helpful.

WebAIM has a great article titled Using VoiceOver to Evaluate Web Accessibility
It helps by telling you how to get set up, what keys are used, how users navigate, how to test images, tables, and other elements.
Testing with any screen reader is about more than tabbing through the page as you watch. Ideally you want to get to the point where you can turn off your screen and test. You must also recognize that most VO users do not tab through a page, but instead tend to jump around by landmarks, headings, links, lists, and so on.
I am not pasting the entire article, but here is the outline:
Introduction
Getting Started
Reading
Navigation
Other useful shortcut keys
Images
Data Tables
Forms
Practice
VoiceOver on the iPhone, iPod Touch, and iPad

Chrome Dev tools has an Accessibility Properties panel, which will show you the accessible name of an item the way it is exposed to the VoiceOver API. It would be quicker to keep that panel open and only test in VoiceOver when you are happy with what you're seeing in the panel.

To answer your question, it sounds like you're looking for the Accessibility inspector tool, which exposes the accessibility API (OSX Safari uses NSAccessibility and iOS Safari uses UIAccessibility for iOS) bits (which VoiceOver consumes). This is part of Xcode, so you'll need Xcode on your Mac to get to it

Related

How to test your Aria tags on your website?

I been doing some research but I having issues finding a good way to test my Aria-labels, and other Aria tags I used. What is the best practice for testing this. Currently doing this for Angular using Material UI which already has some good ARIA support.
I tried using the trial version of JAWS 9 but sometimes I can't tell if it's my code is bad or the screenreader isn't as good as I hope.
Thanks for reading and hope someone could point me in the right direction.
JAWS has been around for a long time so if things are not working like you'd expect, sorry to say, it's probably a problem with your code. However, JAWS isn't great for testing because the intent of JAWS is to allow visually impaired users to get stuff done on their computer. JAWS uses some heuristics when it's reading a website and if you have bad html, JAWS will try to figure out what you meant so that the end user can finish their task.
NVDA is a great a screen reader for testing. It will not try to guess what your code is doing and if you have poorly written html, it'll be read poorly. And it's free (although donations appreciated).
Both JAWS and NVDA are for the PC.
On a Mac, you can use the built in VoiceOver screen reader. Nothing to install. Just hit Cmd+F5.
Turn the screen reader on and navigate through your site using tab and listen for how interactive elements are announced. You can turn on NVDA's speech viewer tool (ins+n > tools > speech viewer) and you can see what is being spoken. VoiceOver has a "closed captions" type viewer so you can see what's being announced. Your aria-labels will be read by the screen reader.
You can also use the shortcut keys when NVDA is running to see if other elements are defined properly.
H - navigate to the next heading
B - navigate to the next button
T - navigate to the next table
L - navigate to the next list
See https://www.nvaccess.org/files/nvda/documentation/userGuide.html#SingleLetterNavigation
Chrome devtools has build in accessibility check:
Press F12 (or just open your Chrome devtools)
Choose the tab "Elements"
Click on the tag you want to inspect
there has a part underneath where you can see all the styles for your tags, classes,...and it is calles "Styles"
here you can also choose between tabs, so choose then for "accessibility"
Now you are able to see which aria attributes are set for your tag.
(In this image you can see that I put an aria-hidden attribute on my font-awesome so screenreaders don't try to read the icon)
Chromevox is a good plugin for simulating screen reader if that's what you are looking for. If you're interested in learning how good your website is conforming to accessibility guidelines, you can go to the audits in chrome dev tools & run a report. (Ctrl+ Shift + I -->Audits --> Select only accessibility & hit Run audits)

Screen reader capability for checkboxes in different browsers

I'm working on a website that has to be accessible for almost anyone.
Currently, I'm trying to figure out a way to make checkboxes accessible by different types of screen readers, using the keyboard to navigate through the content. At the moment i'm using both the standard Windows Screenreader and NVDA (see https://www.nvaccess.org/). I've tried different solutions I found on the web, but i'm still stuck and I would love some tips and trix on how to implement these sorts of features. One thing to note is that it has to work for different types of browsers (ideal would be Microsoft Edge, Google Chrome and Internet Explorer).
The ideal scenario would be something like this:
1: Navigate to the checkbox (or list off checkboxes) using the tab key.
2: The screen reader informs me that it's a checkbox, it's current state (checked, not checked), and its label.
3: Space key will uncheck and check my checkbox, informing me of my actions.
Here's two different code snippets that I've tried, but they only work on Microsoft Edge and Internet Explorer:
<fieldset id="accept">
<legend> My legend </legend>
<input type ="checkbox" id ="chbox" name ="check_1">
<label for "chbox">This is my checkbox></label>
</fieldset>
And this is when i'm using the Struts checkbox tag.
<span class="">
<s:checkbox
label="someLabel"
name="someName" id="accept" />
</span>
These work as expected in Microsoft Edge and Internet Explorer, but whenever I'm using Google Chrome, the screen readers are having trouble figuring out my content. The scenario I'm having:
1: I'm tabbing to my Checkbox, the screen readers say "Tab".
2: I'm using the space key to uncheck my checkbox, the screen readers
say "Space". (It still unchecks my checkbox though)
Apart from this, I've tried to surround my code in different divs, assigning roles and web-aria, but nothing seems to work. As I'm totally new to this, I would love some 'best-practice' ideas and tips.
Any help is appreciated,
Thanks in advance.
First, I could suggest you not to use Struts checkbox as most of them are design for legacy browser. And it may not always best for modern screen reader.
Regarding the checkbox, the recent recommendations from ARIA reference is to use DOM structure <label><input>Text</label> over <label for>.
Or use aria-label on the checkbox. But the second way is less recommend due to different support from browser/screen reader. In some bad case, they could ignore or read duplicate by different way to read the line.
Well, it's kind of a Chrome Issue.
Check this as you're not the only one.
I don't know any solution for this, I've bumped into this a few years back, luckly I just had to make it at A/AA.
It's worth mentioning that Narrator does not support third party (non-Microsoft) browsers.

iOS safari reader view not showing site correctly

iOS safari reader view looks weird. It shows headline and underline of a video and a lot of white space. Also the title is double. It also shows the word advertisement when there is an ad in the original page.
Does anybody now wich keywords triggers the reader view in iOS and how to customize it?
I found absolutely nothing to this topic at all...
tanks :)
It seems that there's no official way to customize the viewer. It's technically implemented as Safari Extension and simply injects JavaScript in your page to do its magic. For more information, see the extracted source at https://github.com/amumu/safari-reader-js
Official Apple documentation does mention class SafariReader but as far as I know, there's no way to access that from the content (server emitted HTML or JavaScript). If you could access SafariReader it would provide required methods to better control it. Another interesting class would be SafariContentViewer. If you could somehow access SafariReader, you could then follow the documentation: Working with Safari Reader.

Howto make HTML-Elements visually invisible but present in Voice Over

I have some information in HTML run in a WebView on an iPhone which should not be visible to regular Users, but should be read out by accesibility features such as IOs's VoiceOver.
just putting all the information inside an aria-label="lorem ipsum dolor" attribute did not work. Voice Over stil reads out the plain content of the tag. So i tried adding an "invisible" Element holding this information. However it seem to me that VoiceOver magically ignores elements which are not visibleto the user. I tried the varios techniques described by the Yahoo Accesibility Lab: http://www.cssmojo.com/hide-content-from-sighted-users/ but none of them are working for me.
Here is the Code:
<div tabindex="2">
<h2 class="visually-hidden">Ausgewählter Ton:</h2>
<div class="jingle" ng-if="ctrl.getAlarmJingle()">{{ctrl.getAlarmJingle()}}</div>
</div>
I want VoiceOver to read out "Ausgewählter Ton:" plus the value of `{{ctrl.getAlarmJingle()}}. best case would be that all of this appears to be one element in VoiceOver the Accessibility-Tree. What is the best practice of doing this? Has anybody good resources on how VoiceOver really works?
The Project is a hybrid app using angular 1 and Ionic. We are using wkwebview as WebView, but i don't think thats relevant for VoiceOver problems.
Sorry the problem was, that my scss wasn't compiled hance the css never updated. Now that it does everythings works as expected.

How do you test if your HTML page or application is accessible?

After adding accessibility to my HTML page, how would one test if it is working correctly? I would like to hear how it sounds and navigates for someone who is using a screen reader.
Let me put it another way, when you build a web page you preview it in a browser(s) to see if it looks and behaves correctly. When you add accessible to that same web page how to do you know it's working correctly?
If you are looking for a quick spot check, you can use WebAIM's WAVE, which tells you the big errors. If you wish to dig deeper, you both need an understanding of WCAG 2.0, and assistive technology. WebAIM has a checklist for WCAG 2.0, which would be the next step, along-side using assistive technology. People tend to only think assistive technology = screen readers, but this is incorrect. There are many different types of assistive technology. I recommend reading through the note at the top of the checklist.
NVDA is a free screen reader
Looks like you might be SOL:
Site accessibility: what screen readers, etc to test against, and how?
Screen Readers For Testing Website Accessibility
If you're really looking for a semi-automated solution, you might be able to stitch together Selenium (or similar) and a screen reader emulator (as described in the second linked post) to pull down an audio file of the screen reader, then submit the text to Mechanical Turk for transcription, then diff your site text against the transcript you get to see how confused the writer was. It would cost a few bucks, but potentially save you more-expensive programmer hours.