HTML - Accessibility Part 1
Instructors: Jess, Carmen, and Eda
Accessibility
Before this session, please:
- Read Importance of Accessibility and Good HTML Structure: What Is Accessibility? and take notes
- Read Importance of Accessibility and Good HTML Structure: What Are Screen Readers, and Who Uses Them? and take notes
- Read Importance of Accessibility and Good HTML Structure: What Are Large Text or Braille Keyboards, and Who Uses Them? and take notes
- Read Importance of Accessibility and Good HTML Structure: What Are Alternative Pointing Devices Such as Trackballs, Joysticks, and Touchpads Used For? and take notes
- Read Importance of Accessibility and Good HTML Structure: What Are Screen Magnifiers Used For? and take notes
- Read Importance of Accessibility and Good HTML Structure: What Is Voice Recognition Software Used For? and take notes
- Read Importance of Accessibility and Good HTML Structure: What Are Some Common Accessibility Auditing Tools to Use? and take notes
- Read Importance of Accessibility and Good HTML Structure: How Does Proper Heading Level Structure Affect Accessibility? and take notes
- Try to complete all the steps in Debug a Coding Journey Blog Page
During this session, we’ll:
- Review notes
- Review notes
- Review notes
- Review notes
- Review notes
- Review notes
- Review notes
- Review notes
- We’ll look at key steps from Debug a Coding Journey Blog Page to explore accessibilty together
After this session, please:
- Read Working with Accessible Tables and Forms: What Are Best Practices for Tables and Accessibility? and take notes
- Read Working with Accessible Tables and Forms: Why Is It Important for Inputs to Have an Associated Label? and take notes
- Complete all the steps from Build a Tech Conference Schedule Table, recording your questions and new topics introduced
- Finish Debug a Donation Form solo over the next few days
Instructor notes
Importance of Accessibility and Good HTML Structure: What Is Accessibility?
Accessibility is the practice of making our websites in a way that everyone can use them, no matter what their ability or circumstance is. It’s about giving everyone equal opportunity.
Some of the disabilities can include:
- Visual impairments including blindness, low vision, color blindness
- Hearing impairments including deafness and hearing loss
- Mobility impairments that might cause difficulty using keyboards, mice, or touchscreens
- Cognitive impairments which is a broader range of disabilities that includes attention disorders, memory issues, language impairments, sensitivity to flashing light, etc.
There are standards that are known as the “Web Content Accessibility Guidelines” (WCAG) that are developed by the World Wide Web Consortium (W3C) that offer guidance to make our websites more accessible.
These guidelines are organized under four core principles, which are easy to remember with the POUR acronym:
- Perceivable: users must be able to perceive the information being presented. For example, we can provide alt text for images so that people with screen readers can understand them.
- Operable: users must be able to operate the interface. For example: we can make the functionality of our website accessible through keyboard as well (such as navigating with the Tab key) so that people who don’t or are not able to use a mouse can interact with our website.
- Understandable: users must be able to understand the information. For example, not using overly complex language.
- Robust: users must be able to access the content as technologies advance. For example, using semantic HTML so that our websites can remain compatible with different browsers and they continue to be accessible as technologies evolve.
You can use the WCAG Quick Reference to check if you’re following the guidelines correctly.
Importance of Accessibility and Good HTML Structure: What Are Screen Readers, and Who Uses Them?
Screen readers are assistive technologies that not only help visually impaired people access computers, but also help people with cognitive disabilities and allow them to have equal opportunity in accessing education, work and other prospects.
A screen reader is not a text-to-speech device; text-to-speech is only one of its features (there are other features like braille displays, navigation aids, and web browsing assistance).
Major operating systems have screen readers built-in:
- macOS and iOS: VoiceOver. Press
CMD + F5on macOS (or, through Settings on iOS) to activate it. - Windows: Narrator. Press
WIN + CTRL + ENTERto activate it. There is also NonVisual Desktop Access (NVDA), which is open source, and Job Access With Speech (JAWS), which is paid. - Linux: Orca for desktop and Speakup for the Linux terminal.
Android phones have TalkBack. Go to “Settings > Special Function > Accessibility > Talkback” to activate it. Some Android devices also have Ella and Select to Speak.
Importance of Accessibility and Good HTML Structure: What Are Large Text or Braille Keyboards, and Who Uses Them?
There are large text keyboards and Braille keyboards for people with visual disabilities.
Large text keyboards have the letters, numbers, symbols larger than other keyboards, and some of them have more contrast and brightness. For example, yellow keys with big, black, bold letters/numbers/symbols. They can be backlit so the users can adjust the brightness.
Braille is a tactile reading/writing system where raised dots in specific patterns represent letters, numbers, symbols. Braille keyboards have these raised dots to help users find the keys.
Some keyboards combine both large text and Braille patterns in the keys.
Importance of Accessibility and Good HTML Structure: What Are Alternative Pointing Devices Such as Trackballs, Joysticks, and Touchpads Used For?
There are pointing devices such as trackballs, joysticks, and touchpads that are alternatives to the traditional mouse. These are helpful for people with mobility impairments.
A trackball has a large movable ball within a socket. It also has buttons for other functionality. It is stationary, so only moving the ball is enough to control the cursor. A traditional mouse can have a trackball on the side or on top as well.
A joystick is a pointing device designed for games or machinery control. It has a lever that pivots up, down, left, and right. It also may have additional buttons for other functionality. They can be helpful especially for people with tremors and issues like arthritis and carpal tunnel syndrome.
A touchpad is a touch-sensitive, flat device. It allows people to control the cursor by sliding their fingers across the surface. It also has right and left click buttons. Laptops and some keyboards have built-in touchpad devices. They can be helpful as they support multi-touch gestures such as pinch-to-zoom, tap-to-click, etc. They are also helpful for people with low arm or hand movement as well as with issues such as arthritis, because the forelimb can stay stationary while using them.
Importance of Accessibility and Good HTML Structure: What Are Screen Magnifiers Used For?
Screen magnifiers enlarge texts and other elements on a screen. They are helpful for people with low vision and visual impairments.
Most magnifiers have features like customizable zoom, and many of them can allow users to enlarge the display more than 200%. They can help people read texts with smaller fonts, fill out forms more easily where the input is difficult to interact with, etc.
While making our websites, we need to consider:
- Using scalable fonts so that the layout stays consistent if a user resizes the page
- Different screen sizes through responsive design
- Using high-contrast and customizable colors
- Implementing a non-sticky navigation bar so users can still see content
- Using HTML text elements instead of using non-textual elements like images of text
- Providing feedback directly next to the element that triggers it
Major operating systems have at least one screen magnifier built-in:
- macOS and iOS: Zoom (through “Settings > Accessibility > Zoom”)
- Android devices: Magnification (It may vary from device to device, so you can search “Magnification” in the Settings)
- Windows: Magnifier (“Settings > Ease of Access > Magnifier”)
- Linux: Zoom or Magnifier
There are other third-party tools:
- Windows: ZoomText, ClaroView, iZoom, LunarPluse
- macOS: ClaroView, Zoomify - Screen Magnifier, Loupe
Importance of Accessibility and Good HTML Structure: What Is Voice Recognition Software Used For?
Voice recognition tools help people use their voice to perform tasks, instead of using devices like a mouse and keyboard. They can be helpful for people with visual, cognitive and mobility impairments. They are helpful not just for people with disabilities, but for people who might find it easier to perform tasks with voice commands as well.
Some examples include:
- macOS and iOS: Voice Control
- Android: Voice Access
- Windows: Windows Speech Recognition (or, Voice Access). A third-party tool is Dragon Speech Recognition by Nuance.
Importance of Accessibility and Good HTML Structure: What Are Some Common Accessibility Auditing Tools to Use?
We should make sure that our websites and digital content meet accessibility standards.
An accessibility auditing tool can help us with it by reporting accessibility issues. However, we should not rely on them entirely because they usually find only a third of all possible accessibility issues. That’s why we should also do manual testing, especially by people with disabilities to ensure the accessibility of our websites.
Some accessibility auditing tools are:
- Google Lighthouse: it can be used directly in Chrome DevTools or online. It has metrics that include accessibility, SEO, best practices, and performance. To use it, go to “DevTools > Lighthouse > Analyze page load”. The online version is at https://pagespeed.web.dev/.
- WAVE (https://wave.webaim.org/). It’s online and also has browser extensions. The report includes accessibility features implemented, ARIA, and contrasts.
- The IBM Equal Accessibility Checker which also has browser extensions (https://www.ibm.com/able/toolkit/tools/#develop).
Importance of Accessibility and Good HTML Structure: How Does Proper Heading Level Structure Affect Accessibility?
When we use logical heading hierarchy, like this basic example:
1<h1> Music Store Page</h1>
2
3<h2>Featured Albums</h2>
4<p>Check out our featured albums below:</p>It’s not only good for visual help such as proper use of font sizes, but it also helps with accessibility. It provides navigation in a way that people can jump to different sections on the page (if we add associated links, for example). It’s helpful for finding information easily because it reduces the cognitive load. Using well-formed headings also improves the SEO of our sites.
We should consider:
- Making page titles
h1, major section titlesh2, subsectionsh3and so on untilh6. - Not skipping the heading hierarchy, like jumping from
h2toh4. - Using clear and descriptive text for headings.
- Make sure that proper content follows the headings.
- Using proper HTML tags instead of formatting text to make it look like headings.
- Adding an
h1to each page for the main topic/title.
Debug a Coding Journey Blog Page
We’re going to find and work on some accessibility issues on this exercise together!