Top Banner
Accessibility & Web Technologies HTML5 Toronto Web Developers Meetup @georgezamfir [email protected] #a11y = accessibility
54

Accessibility & Web Technologies

Jan 14, 2016

Download

Documents

Caine

HTML5 Toronto Web Developers Meetup. Accessibility & Web Technologies. @ georgezamfir [email protected] #a11y = accessibility. HTML5 Toronto Web Developers Meetup. The power of the Web is in its universality Access by everyone regardless of disability is an essential aspect - PowerPoint PPT Presentation
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Accessibility & Web Technologies

Accessibility & Web Technologies

HTML5 Toronto Web Developers Meetup

@[email protected]

#a11y = accessibility

Page 2: Accessibility & Web Technologies

@[email protected]

#a11y = accessibility

HTML5 Toronto Web Developers Meetup

The power of the Web is in its The power of the Web is in its universalityuniversality

Access by everyone regardless of disability is an essential Access by everyone regardless of disability is an essential aspectaspect

- Tim Berners-Lee - Tim Berners-Lee W3C DirectorW3C Director

Inventor of the World Wide WebInventor of the World Wide Web

Page 3: Accessibility & Web Technologies

What is #a11y ?

Page 4: Accessibility & Web Technologies

What is accessibility ?

Page 5: Accessibility & Web Technologies

Accessibility is about disabilities…

What is accessibility ?

It’s making things accessible for people with disabilities, riiiiight?

Page 6: Accessibility & Web Technologies

"We are only as (dis)abled as the environment around us!"

What is accessibility ?

Page 7: Accessibility & Web Technologies

"We are only as (dis)abled as the environment around us!"

What is accessibility ?

- Oscar Pistorius

Page 8: Accessibility & Web Technologies

"We are only as (dis)abled as the environment around us!"

What is accessibility ?

Gillian Lynne – “She’s not sick, she’s a dancer!”

Page 9: Accessibility & Web Technologies

4 Basic Types of Needs

What is accessibility ?

Visual low vision, colorblindness, blindnessScreen magnifiers, text-to-speech, refreshable braille, good mark-up

Auditory hearing loss, deafnessCaptions & transcripts, haptic feedback, good mark-up

Mobility dexterity, strength, loss of limbSpeech-to-text, alternative input hardware, good mark-up

Cognitive & Speech dyslexia, ADD, lack of skillsWord prediction, augmentative devices (hear & see), good mark-up

Page 10: Accessibility & Web Technologies

Accessibility is not just about disabilities!

What is accessibility ?

DID YOU KNOW? 4.4 million Canadians reported having a disability (14.3% )

> 1 billion people worldwide (15% )

Disabilities

Aging population

Non-native language

speakers

Low (computer?) literacy

Page 11: Accessibility & Web Technologies

It’s not about them, it’s about all of us!

What is accessibility ?

Page 12: Accessibility & Web Technologies

Need for web accessibility is ever greater!

Page 13: Accessibility & Web Technologies

Mobile Web Great promoter for accessibility

What is accessibility ?

Page 14: Accessibility & Web Technologies

Need for web accessibility is ever greater!

But what do we do?

What is accessibility ?

Page 15: Accessibility & Web Technologies

What is accessibility ?

Allowing people of all abilities & disabilities to have equal access to

information & functionality

Page 16: Accessibility & Web Technologies

Why care about accessibility ?

It’s the right thing to do

Regulations say you must (AODA)

Leaving out some of the audience is bad business.

Page 17: Accessibility & Web Technologies

Assistive Technologies (AT)

Page 18: Accessibility & Web Technologies

Assistive Technologies Demo

Screen Magnifiers: ZoomText, iOS native

Screen Readers: NVDA, Jaws, VoiceOver

Voice Recognition: Dragon Naturally Speaking, Siri

iPhone / iPad: youtube.com/watch?v=t60voPIY5xY

Assistive Technologies (AT)

Page 19: Accessibility & Web Technologies

ATs, How Do They Work ?

Assistive Technologies (AT)

Page 20: Accessibility & Web Technologies

ATs – Accessibility APIs – Code(Accessibility Stack)(Accessibility Stack)

Assistive Technologies (AT)

FRONT-END CODEFRONT-END CODEFRONT-END CODEFRONT-END CODE

Accessibility APIsAccessibility APIsAccessibility APIsAccessibility APIs

Assistive Technologies (ATs)Assistive Technologies (ATs)Assistive Technologies (ATs)Assistive Technologies (ATs)

Page 21: Accessibility & Web Technologies

Accessibility Stack AT - Accessibility APIs – FRONT-END CODE

WCAG 2Web Content Accessibility Guidelines 2

AODAAccessibility for Ontarians with Disabilities Act

Page 22: Accessibility & Web Technologies

Accessibility Stack

Accessibility Stack: ATs – Accessibility APIs - CODE

FRONT-END CODEFRONT-END CODEHTML, CSS, JavaScriptHTML, CSS, JavaScript

FRONT-END CODEFRONT-END CODEHTML, CSS, JavaScriptHTML, CSS, JavaScript

Accessibility APIsAccessibility APIsMSAA, UIA, IA2, AX/uiA, AT-SPI, UAAG, ARIAMSAA, UIA, IA2, AX/uiA, AT-SPI, UAAG, ARIA

Accessibility APIsAccessibility APIsMSAA, UIA, IA2, AX/uiA, AT-SPI, UAAG, ARIAMSAA, UIA, IA2, AX/uiA, AT-SPI, UAAG, ARIA

Assistive Technologies (ATs)Assistive Technologies (ATs)

JAWS, NVDA, Dragon, ZoomText, VoiceOver, etc.JAWS, NVDA, Dragon, ZoomText, VoiceOver, etc.

Assistive Technologies (ATs)Assistive Technologies (ATs)

JAWS, NVDA, Dragon, ZoomText, VoiceOver, etc.JAWS, NVDA, Dragon, ZoomText, VoiceOver, etc.

Page 23: Accessibility & Web Technologies

Accessibility Stack – Text-to-Speech Example

Accessibility Stack: ATs – Accessibility APIs - CODE

<a href=“http://google.com”>search engine</a><a href=“http://google.com”>search engine</a>

HTML CODEHTML CODE

<a href=“http://google.com”>search engine</a><a href=“http://google.com”>search engine</a>

HTML CODEHTML CODE

AXTextLink AXURL=“http://google.com” AXTitle=“search engine” AXTextLink AXURL=“http://google.com” AXTitle=“search engine”

Mac OSx / iOS Accessibility ProtocolsMac OSx / iOS Accessibility Protocols

AXTextLink AXURL=“http://google.com” AXTitle=“search engine” AXTextLink AXURL=“http://google.com” AXTitle=“search engine”

Mac OSx / iOS Accessibility ProtocolsMac OSx / iOS Accessibility Protocols

text-to-speech: “search engine link”text-to-speech: “search engine link”

iPhone / iPad VoiceOveriPhone / iPad VoiceOver

text-to-speech: “search engine link”text-to-speech: “search engine link”

iPhone / iPad VoiceOveriPhone / iPad VoiceOver

Page 24: Accessibility & Web Technologies

WCAG 2

Web Content Accessibility Guidelines (WCAG 2) - w3.org/TR/WCAG

So, how in the world do I know how to build for all these types of needs?

It would be nice to have one standard that addresses all needs / disabilities / ATs, right?

Page 25: Accessibility & Web Technologies

WCAG 2

Web Content Accessibility Guidelines (WCAG 2) - w3.org/TR/WCAG

W3C set of 12 guidelines

Technology agnostic – not just for HTML

Covers a wide range of needs / disabilities

Developed by W3C & numerous experts

Widely adopted as THE standard for

compliance

3 levels of compliance: A, AA, AAA

Page 26: Accessibility & Web Technologies

How to Use WCAG 2 ?

Web Content Accessibility Guidelines (WCAG 2) - w3.org/TR/WCAG

Set of 12 Guidelines divided into 4

Principles

Perceivable Information and UI can’t be invisible to all

senses

Operable Users must be able to operate UI & navigation

Understandable Info & operation of UI must be understandable

Robust Content must be interpreted reliably by all user

agents

Page 27: Accessibility & Web Technologies

Web Standards & WCAG 2

Web Content Accessibility Guidelines (WCAG 2) - w3.org/TR/WCAG

Use web standards for greater interoperability

& functionality to people using AT, alternative

browsers, mobile devices

Doesn’t necessarily provide an engaging UX

but using standards at least people can have

an experience in the first place.

Page 28: Accessibility & Web Technologies

Accessibility for Ontarians with Disabilities Act (AODA)

Accessibility for Ontarians with Disabilities Act – AODA 2005

•ON legislation for accessible products & services

•Information & Communication standard (IC) – 1/5

•IC standard – requirement to conform with WCAG

2

•For businesses in both the private & public

sectors

Page 29: Accessibility & Web Technologies

Information & Communication StandardTimelines

Information & Communication (IC) Standard – AODA

ON Government

All public & private > 50

Level AA - 2012

Level A – 2014, AA – 2021

It’s your responsibility

to deliver accessible products & services to your clients

who may not necessarily be the users.

Page 30: Accessibility & Web Technologies

It’s Your

Responsibility

!

Page 31: Accessibility & Web Technologies

Practical Accessibility

1. Semantic Content

2. Keyboard Access

3. Forms Fields & More

4. UI Visual Design & Code Order

5. Progressive Enhancement & ARIA

Practical #A11Y

Page 32: Accessibility & Web Technologies

Yo dawg, I heard you like

<div>so I put a <div> in your <div>’s <div>

Practical #A11Y – Semantic Content

Page 33: Accessibility & Web Technologies

Practical #A11Y – Semantic Content

<div class="T-I J-J5-Ji T-I-KE L3" role="button" tabindex="0" style="-webkit-user-select: none; " gsdh="cm">COMPOSE</div>

Gmail

<div id=":rj" class="T-I J-J5-Ji T-I-atl L3" role="button" tabindex="0" style="-webkit-user-select: none; "><span class="w-nIgmKf T-I-J3 J-J5-Ji"></span></div>

Page 34: Accessibility & Web Technologies

Semantic Content

Practical #A11Y – Semantic Content

Page 35: Accessibility & Web Technologies

Keyboard Access

Page 36: Accessibility & Web Technologies

This website is best viewed at 1024x768 and only works with a mouse

Practical #A11Y – Keyboard Access

Page 37: Accessibility & Web Technologies

2 BIG concepts:

Everything is functional by keyboard(including highly interactive UI elements)

Visual focus indicator(be the :focus to my :hover)

Practical #A11Y – Keyboard Access

Page 38: Accessibility & Web Technologies

Forms Fields & More

Page 39: Accessibility & Web Technologies

Forms Fields & More

Practical #A11Y – Forms Fields & More

Associate <label> with form <input> using for / id

Use <fieldset> & <legend> for logical groups of fields(then hide off-screen what you don’t / can’t style appropriately)

Deal with input errors & error messages (beware of browsers’ support for required=)

How to do accessible tooltips / hover effects

Page 40: Accessibility & Web Technologies

Associate <label> with form <input> using for / id

Practical #A11Y – Forms Fields & More

<label for="COAPP“>Yes, I am applying with a co-applicant

</label><input id="COAPP" type="radio" value="Yes“ title="Yes, I am applying with a co-applicant" required="required“>

<fieldset> <legend>Are you applying with a co-applicant?</legend>

<label for="COAPPNO“ >No, I am not applying with a co-applicant

</label> <input id="COAPPNO" type="radio" value="No“ title="No, I am not applying with a co-applicant" required="required"></fieldset>

Use <fieldset> & <legend> for logical groups of fields(then hide off-screen what you don’t / can’t style appropriately)

<h3 class="section">Are you applying with a co-applicant?</h3>

Page 41: Accessibility & Web Technologies

Deal with input errors & error messages (be aware of browsers’ support for required=)

Practical #A11Y – Forms Fields & More

•Visual & non-visual indicator that there’s an error on the

field

•Keyboard / visual focus moves to errors area

•A way to move back from the error to the field

Page 42: Accessibility & Web Technologies

How to do accessible tooltips / hover effects

Practical #A11Y – Forms Fields & More

•Not just :hover anymore (look at mobile)

•Open / close by keyboard

•Manage focus

•Enhance with ARIA

Page 43: Accessibility & Web Technologies

UI Visual Design & Code Order

Page 44: Accessibility & Web Technologies

UI Visual Design & Code Order

Page 45: Accessibility & Web Technologies

UI Visual Design & Code Order

Page 46: Accessibility & Web Technologies
Page 47: Accessibility & Web Technologies

UI Visual Design & Code Order

Most often the design flow should match the source code order

Markup content in the order it should be read NOT in the order it should be displayed

It makes it much worse for AT users (try tabbing through every amazon.com page just to get to your product specs)

Practical #A11Y – UI Visual Design & Code Order

Page 48: Accessibility & Web Technologies

Progressive Enhancement & ARIA

Text Content & prose

HTML Semantic & some

behaviour

CSS Presentation

JavaScript Advanced behaviourARIA Extend semantics

(insight into roles &

states)

Practical #A11Y – Progressive Enhancement & ARIA

Page 49: Accessibility & Web Technologies

ARIA integrated into HTML5 but predates it

Set of attributes that specify meaning - role, properties,

state

Really good for widgets that we don’t have in HTML /

HTML5

ARIA-specific mark-up doesn’t affect functionality

Doesn’t mean we can get away with <div> <div> <div> <div> <div>

Practical #A11Y – ARIA - dev.w3.org/html5/markup/aria/Overview.html

Page 50: Accessibility & Web Technologies

It’s a plane… It’s a bird… It’s a……slider? Wait a minute, there’s no such thing in HTML!

<a href="#" aria-valuemin="0" aria-valuemax="10" role="slider" aria-labelledby="question-transactions" title="Transactions per week?" aria-valuenow="5" aria-valuetext="5 transactions">5</a>

Practical #A11Y – ARIA - dev.w3.org/html5/markup/aria/Overview.html

Page 51: Accessibility & Web Technologies

Practical Accessibility TestingDesign stage: Colour contrast & general

layout

Prototype stage: Keyboard & automated testing

Semantic content

Some AT testing

Development stage: Functional & AT testing

Usability testing with real

peoplePractical #A11Y Testing

Page 52: Accessibility & Web Technologies

Testing Techniques & Tools

Keyboard: Test for keyboard functionality & visual focus

Automated Testing: Deque FireEyes

Webaim Wave

Tools & Plugins: Firebug, Web Developer, Color Checker (FF)

AIS Web Toolbar (IE)

Practical #A11Y Testing

Your Brain: No tools can replace it!

Page 53: Accessibility & Web Technologies

A Few Thing to Remember

Write semantic content & markup, presentation matters not

Accessibility is not a feature, it’s a subset of usability

Remember: not everyone is using a mouse

Start small, do 1 thing but do it well

ASK FOR HELP!

Practical #A11Y Testing

Page 54: Accessibility & Web Technologies

?