SlideShare a Scribd company logo
1 of 52
Download to read offline
Hitting the high notes
with ARIA
Ted Drake, Intuit Accessibility
Silicon Valley Code Camp,
October 2013
Sunday, October 6, 13
This presentation on ARIA was created for the Silicon Valley Code Camp, 2013 by Ted Drake.
Goals
• Screen Reader Introduction
• Introduce ARIA
• Use it today
• Examples
Sunday, October 6, 13
The goal of this talk to to de-mystify ARIA and encourage engineers to make their sites more
accessible by using it correctly. This talk will be focused on new users, but should also
provide interesting content and examples for more advanced users.
Screen
Readers
Sunday, October 6, 13
Screen readers are used primarily by people with vision disabilities. However, they are also
used as a middle layer for automated testing and for people with cognitive and physical
disabilities.
Screen readers interpret the user’s interaction and the applications responses.
Sunday, October 6, 13
This short video shows how a screen reader announces the content and role of an element,
such as a link or form input.
Sunday, October 6, 13
This short video shows how a screen reader announces the content and role of an element,
such as a link or form input.
Sunday, October 6, 13
This short video shows how a screen reader user can navigate around a page by examining
the header tags. The user can also navigate via landmarks, form elements, links, images, and
other types of elements on the page.
Sunday, October 6, 13
This short video shows how a screen reader user can navigate around a page by examining
the header tags. The user can also navigate via landmarks, form elements, links, images, and
other types of elements on the page.
What is ARIA?
Sunday, October 6, 13
a·ri·a
ˈärēə/
noun Music
noun: aria; plural noun: arias
1.
a long, accompanied song for a solo voice,
typically one in an opera or oratorio.
Sunday, October 6, 13
An aria is the solo performance during an opera that brings people to their feet.
A·RI·A
ˈärēə/
nounTechnology
noun: aria; 
1.
WAI-ARIA (Web Accessibility Initiative -
Accessible Rich Internet Applications) is a draft
technical specification published by the World
Wide Web Consortium that specifies how to
increase the accessibility of dynamic content and
user interface components
Sunday, October 6, 13
WAI ARIA is a web standard established as a bridging technique to provide accessibility to
dynamic web sites.
Basics
• HTML attributes
• Good support
• Easy
• Bridge to HTML5
• No visual impact
Sunday, October 6, 13
ARIA is a set of HTML attributes that provide information to the user via the browser and
assistive technology.
ARIA has good support via browsers and screen readers, but not as good for other assistive
technology.
Don’t depend on ARIA if possible.
ARIA’s basic elements are easy to understand and code
ARIA is a bridge technology until HTML5 is completely supported. It’s ok to combine and
should be future proof.
ARIA Rules
1. Don’t use ARIA if
native tag is available.
2. See #1
Sunday, October 6, 13
The best user experience is created with the semantic HTML tags. ARIA is meant to fix areas that
cannot use existing native elements.
Use <button> instead of role=”button”, <table> instead of role=”grid”, and <img> instead of
role=”img”
too many people are using crap code because it is part of a platform, given in a demo, or think it’s
easier to style a blank element.
Don’t do this. Use the correct tag to give your site structure. If you are stuck using bad code, use ARIA
to make it work, but you are still stuck with a bad foundation.
http://www.w3.org/TR/aria-in-html/#first-rule-of-aria-use
ARIA > HTML
Sunday, October 6, 13
ARIA has more importance than HTML.
When you put ARIA on a tag, it will supercede the tag’s value.
This includes role, state, and properties.
I’m a link that points to
the same page and
says “Button”
Before ARIA
Sunday, October 6, 13
In this example, we have a link that has been styled to look like a button.
<a href=”#”>Button</a>
<a href=”#”>
! Button
</a>
Sunday, October 6, 13
This is the code for the link that looks like a button. It will be announced as an internal link,
as the href value is #.
I’m a button that says
“Button”
After ARIA
Sunday, October 6, 13
In this example, we have a link that has been styled to look like a button.
<a href=”#” role=”button”>Button</a>
<a href=”#” role=”button”>
! Button
</a>
Sunday, October 6, 13
In this example, we are using the ARIA role attribute to redefine a link as a button. This will
cause the screen reader to ignore the href.
Links should take the user to a new page or chunk of content.
Buttons should trigger an action.
Roles
• Widget: role=”alert”
• Composite: role=”grid”
• Document Structure: role=”img”
• Landmark: role=”search”
• w3.org/TR/wai-aria/roles
Sunday, October 6, 13
Alert is a widget role. Adding this role suggests an interface and may be standalone or part of
a group. Alert will prompt the browser to announce the content when this object changes,
such as when an alert appears on a page.
Grid is a composite role. There’s a complex arrangement of sub-roles. Grid allows a set of
divs to act like a table.
Img is a structure role. It describes the structural elements and are not interactive.
Landmarks are regions that can be used for navigation to key elements of an application.
http://www.w3.org/TR/wai-aria/roles
Landmarks
• Search Form: role=”search”
• Main: role=”main”
• Nav: role=”navigation”
• Header: role=”banner”
Sunday, October 6, 13
landmarks define content areas on a page. These match HTML5 tags and can be combined.
They provide alternate navigation opportunities for users.
Firefox is the only browser that currently surfaces the native HTML5 tag roles to assistive
technology.
So <nav role=”navigation”> is good.
Landmarks
<form role=”search”>
<label for=”q”>Search</label>
<input type=”search” id=”q” name=”q”>
<button>submit</button>
</form>
Sunday, October 6, 13
Adding role=”search” to the form tag allows a user to quickly move to the search form from
anywhere in the page. Note, this goes on the form, not the input.
States
• aria-disabled=”true | false”
• aria-expanded=”true | false | undefined”
• aria-hidden=”true | false”
• aria-invalid=”true | false | grammar | spelling”
• aria-selected=”true | false | undefined”
Sunday, October 6, 13
States represent the current state of an object and can change as the user interacts with the
application.
Many are tied to specific roles and cannot be used indiscriminately.
Many of these states are already commonly used in HTML elements
I’m a disabled button
that says “Disabled
Button”
After ARIA
Sunday, October 6, 13
In this example, we have a span that has been styled to look like a button.
<a href=”#” role=”button”>Button</a>
<a href=”#”
role=”button” aria-disabled=”true”>
! Disabled Button
</a>
Sunday, October 6, 13
In this example, we added aria-disabled=”true” to the link to let users know this isn’t just a
button, it’s a disabled button.
It would be easier to simply use <button disabled>Disabled Button</button>
<button disabled>
Disabled Button
</button>
Sunday, October 6, 13
This shows how it is much easier to use the native tags and avoid fixing stuff with ARIA
http://www.w3.org/TR/html401/interact/forms.html#h-17.12
Properties
• aria-live=”polite | assertive | off”
• aria-label=”string”
• aria-describedby=”string”
• aria-haspopup=”true | false”
Sunday, October 6, 13
Properties attributes don’t change frequently. They describe special features for an object
aria-live: describes how a browser/screen reader should announce content when it changes, ie polite waits for
the user to pause.
aria-label: provides a label when the standard text label is not available. It will also over-write any existing text
labels.
aria-describedby: is treated similar to the title attribute. It announces optional information that provides context.
aria-haspopup: clicking on this link or button will generate a new chunk of content, such as a dropdown menu or
dialog window.
Live Regions
• aria-live=”polite”: announced after user
stops interacting with page.
• aria-live=”assertive”: interrupts user
• aria-live=”off”: no announcement
• role=”alert”: inherits aria-live=”assertive”
Sunday, October 6, 13
Sunday, October 6, 13
This example from the University of Illinois Urbana-Champagne shows how aria-live
announced new content.
There is a message box that will interrupt the reading of the text box.
The message box is using aria-live=”assertive”
http://test.cita.illinois.edu/aria/live/
Sunday, October 6, 13
This example from the University of Illinois Urbana-Champagne shows how aria-live
announced new content.
There is a message box that will interrupt the reading of the text box.
The message box is using aria-live=”assertive”
http://test.cita.illinois.edu/aria/live/
Screen Reader Problems
Sunday, October 6, 13
Sunday, October 6, 13
This shows how pseudo buttons are not focusable via tab key and are announced as a text
string, not an interactive element
test page: http://fyvr.net/a11y/fake-real-buttons.html
Sunday, October 6, 13
This shows how pseudo buttons are not focusable via tab key and are announced as a text
string, not an interactive element
test page: http://fyvr.net/a11y/fake-real-buttons.html
Sunday, October 6, 13
This short video shows a common pattern where the search form has no label. Further, the
input is using the value attribute to contain a pseudo-placeholder. The value is cleared when
the user places focus into the input.
This fails because the input now has no label, no placeholder, and no value.
The placeholder attribute is not consistently supported and will not be announced if a user
moves back into the input after a value has been entered.
Sunday, October 6, 13
This short video shows a common pattern where the search form has no label. Further, the
input is using the value attribute to contain a pseudo-placeholder. The value is cleared when
the user places focus into the input.
This fails because the input now has no label, no placeholder, and no value.
The placeholder attribute is not consistently supported and will not be announced if a user
moves back into the input after a value has been entered.
Sunday, October 6, 13
This video is a bit more difficult to understand. It shows a data table that uses divs instead of
a standard table markup. the screen reader announces the content as a series of simple
strings. The selected icons are not announced, as they are empty spans with background
images.
Test page: http://fyvr.net/a11y/payroll-table.html
Sunday, October 6, 13
This video is a bit more difficult to understand. It shows a data table that uses divs instead of
a standard table markup. the screen reader announces the content as a series of simple
strings. The selected icons are not announced, as they are empty spans with background
images.
Test page: http://fyvr.net/a11y/payroll-table.html
ARIA to the
Rescue
Sunday, October 6, 13
Let’s go back to our earlier examples and show how ARIA can fix those common issues.
Sunday, October 6, 13
This video shows how role=”button” makes a link sound just like a real button.
<a href=”#” role=”button”>foo</a>
Sunday, October 6, 13
This video shows how role=”button” makes a link sound just like a real button.
<a href=”#” role=”button”>foo</a>
Sunday, October 6, 13
This form fixes the search form by adding role=”search” to the form tag. This sets it as a
landmark.
The input receives a label via aria-label=”search”
The placeholder attribute is not a substitute for a label.
Sunday, October 6, 13
This form fixes the search form by adding role=”search” to the form tag. This sets it as a
landmark.
The input receives a label via aria-label=”search”
The placeholder attribute is not a substitute for a label.
Sunday, October 6, 13
This example isn’t perfect. But it does show how these divs can be given the data table
semantics by using the role=”grid” and appropriate children roles. The blue dots are also
given text: supported and not supported.
This could have been built with a basic data table in the start.
Sunday, October 6, 13
This example isn’t perfect. But it does show how these divs can be given the data table
semantics by using the role=”grid” and appropriate children roles. The blue dots are also
given text: supported and not supported.
This could have been built with a basic data table in the start.
ARIA Form
• role=”alert”
• aria-describedby=”emailerror”
• aria-invalid=”true”
Sunday, October 6, 13
So far, this presentation has given examples of using ARIA to restore semantics and add
landmarks. Let’s see how a few small changes can make significant usability improvements
that were not possible with basic html.
This example will use role=”alert” on an input’s error message. The invalid form input will
also get aria-invalid=”true” and aria-describedby to point to the error message.
Sunday, October 6, 13
This form has an email input that is validated as the user leaves the input (onBlur). The video
shows how the screen reader will announce the alert as soon as it appears. When the user
goes back to the input, they are told the input is invalid and the error message is repeated.
Sunday, October 6, 13
This form has an email input that is validated as the user leaves the input (onBlur). The video
shows how the screen reader will announce the alert as soon as it appears. When the user
goes back to the input, they are told the input is invalid and the error message is repeated.
role=”alert”
<p role="alert" id="emailerror">
Please enter a valid email
address
</p>
Sunday, October 6, 13
Adding role=”alert” to an element will trigger the screen reader to announce the content
whenever it changes. In this page, the content is announced when the display status is
changed from display:none to display:block.
Also note, there is an id on this element. This will be used by aria-describedby attribute.
Original input
<input
type="email"
required
id="email"
name="email" >
Sunday, October 6, 13
Invalid input
<input
type="email"
required
id="email"
name="email"
aria-invalid=”true”
aria-describedby=”emailerror” >
Sunday, October 6, 13
After the input has been identified as invalid, we will need to add some attributes.
aria-invalid=”true” lets the user know when an input is invalid.
Add this attribute in your logic that uses a style or content to visually identify invalid inputs.
aria-describedby points to the id value of the error message. This will be announced as the
input has focus.
Sunday, October 6, 13
Repeat the video to show how this works.
Sunday, October 6, 13
Repeat the video to show how this works.
Key Takeaways
• ARIA is easy and safe to use.
• Use basic HTML before reaching into the
ARIA bag
• ARIA provides information on role, state,
and property
• Make your forms more accessible with
ARIA
• Stop the div-itis
Sunday, October 6, 13
T: @ted_drake
S: slideshare.net/7mary4
U: last-child.com
Y: youtube.com/7mary4responding
E: ted_drake@intuit.com
Thank You!
Sunday, October 6, 13

More Related Content

Similar to Hitting the accessibility high notes with ARIA

A deep dive into accessible names
A deep dive into accessible namesA deep dive into accessible names
A deep dive into accessible namesRuss Weakley
 
Create Accessible Infographics
Create Accessible Infographics Create Accessible Infographics
Create Accessible Infographics Ted Drake
 
Discover the Possibilities of the Jira Cloud Asset API
Discover the Possibilities of the Jira Cloud Asset APIDiscover the Possibilities of the Jira Cloud Asset API
Discover the Possibilities of the Jira Cloud Asset APIAtlassian
 
#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...
#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...
#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...Agile Testing Alliance
 
HTML5 and ARIA accessibility - Bangalore 2013
HTML5 and ARIA accessibility - Bangalore 2013HTML5 and ARIA accessibility - Bangalore 2013
HTML5 and ARIA accessibility - Bangalore 2013Ted Drake
 
Testing For Web Accessibility
Testing For Web AccessibilityTesting For Web Accessibility
Testing For Web AccessibilityHagai Asaban
 
jQuery: Accessibility, Mobile und Responsive
jQuery: Accessibility, Mobile und ResponsivejQuery: Accessibility, Mobile und Responsive
jQuery: Accessibility, Mobile und ResponsivePeter Rozek
 
YUI + Accessibility: Welcome the whole world
YUI + Accessibility: Welcome the whole worldYUI + Accessibility: Welcome the whole world
YUI + Accessibility: Welcome the whole worldTed Drake
 
Making JavaScript Accessible
Making JavaScript AccessibleMaking JavaScript Accessible
Making JavaScript AccessibleDennis Lembree
 
Best practices in museum search
 Best practices in museum search Best practices in museum search
Best practices in museum searchNate Solas
 
How Accessibility Made Me a Better Developer
How Accessibility Made Me a Better DeveloperHow Accessibility Made Me a Better Developer
How Accessibility Made Me a Better DeveloperBilly Gregory
 
ARIA_11_12_Practical_Perspective.pptx
ARIA_11_12_Practical_Perspective.pptxARIA_11_12_Practical_Perspective.pptx
ARIA_11_12_Practical_Perspective.pptxMarkSteadman7
 
HTML5 & WAI-ARIA - Happy Families
HTML5 & WAI-ARIA - Happy FamiliesHTML5 & WAI-ARIA - Happy Families
HTML5 & WAI-ARIA - Happy FamiliesSteven Faulkner
 

Similar to Hitting the accessibility high notes with ARIA (20)

A deep dive into accessible names
A deep dive into accessible namesA deep dive into accessible names
A deep dive into accessible names
 
Create Accessible Infographics
Create Accessible Infographics Create Accessible Infographics
Create Accessible Infographics
 
P.S. I love you
P.S. I love youP.S. I love you
P.S. I love you
 
Web Accessibility
Web AccessibilityWeb Accessibility
Web Accessibility
 
Discover the Possibilities of the Jira Cloud Asset API
Discover the Possibilities of the Jira Cloud Asset APIDiscover the Possibilities of the Jira Cloud Asset API
Discover the Possibilities of the Jira Cloud Asset API
 
#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...
#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...
#ATAGTR2018 Presentation "Manual and Automated Accessibility Testing Implemen...
 
HTML5 and ARIA accessibility - Bangalore 2013
HTML5 and ARIA accessibility - Bangalore 2013HTML5 and ARIA accessibility - Bangalore 2013
HTML5 and ARIA accessibility - Bangalore 2013
 
Web Accessbility
Web AccessbilityWeb Accessbility
Web Accessbility
 
Testing For Web Accessibility
Testing For Web AccessibilityTesting For Web Accessibility
Testing For Web Accessibility
 
jQuery: Accessibility, Mobile und Responsive
jQuery: Accessibility, Mobile und ResponsivejQuery: Accessibility, Mobile und Responsive
jQuery: Accessibility, Mobile und Responsive
 
EVOLVE'16 | Maximize | Libby Schaper & Gina Petrucceli | Web Accessibility & AEM
EVOLVE'16 | Maximize | Libby Schaper & Gina Petrucceli | Web Accessibility & AEMEVOLVE'16 | Maximize | Libby Schaper & Gina Petrucceli | Web Accessibility & AEM
EVOLVE'16 | Maximize | Libby Schaper & Gina Petrucceli | Web Accessibility & AEM
 
EVOLVE'16 | Maximize | Gina Petruccelli & Libby Schaper | Web Accessibility &...
EVOLVE'16 | Maximize | Gina Petruccelli & Libby Schaper | Web Accessibility &...EVOLVE'16 | Maximize | Gina Petruccelli & Libby Schaper | Web Accessibility &...
EVOLVE'16 | Maximize | Gina Petruccelli & Libby Schaper | Web Accessibility &...
 
YUI + Accessibility: Welcome the whole world
YUI + Accessibility: Welcome the whole worldYUI + Accessibility: Welcome the whole world
YUI + Accessibility: Welcome the whole world
 
Making JavaScript Accessible
Making JavaScript AccessibleMaking JavaScript Accessible
Making JavaScript Accessible
 
Best practices in museum search
 Best practices in museum search Best practices in museum search
Best practices in museum search
 
How Accessibility Made Me a Better Developer
How Accessibility Made Me a Better DeveloperHow Accessibility Made Me a Better Developer
How Accessibility Made Me a Better Developer
 
Empezando con Twig
Empezando con TwigEmpezando con Twig
Empezando con Twig
 
ARIA_11_12_Practical_Perspective.pptx
ARIA_11_12_Practical_Perspective.pptxARIA_11_12_Practical_Perspective.pptx
ARIA_11_12_Practical_Perspective.pptx
 
Building Web Hack Interfaces
Building Web Hack InterfacesBuilding Web Hack Interfaces
Building Web Hack Interfaces
 
HTML5 & WAI-ARIA - Happy Families
HTML5 & WAI-ARIA - Happy FamiliesHTML5 & WAI-ARIA - Happy Families
HTML5 & WAI-ARIA - Happy Families
 

More from Ted Drake

Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024
Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024
Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024Ted Drake
 
Transforming Accessibility one lunch at a tiime - CSUN 2023
Transforming Accessibility one lunch at a tiime - CSUN 2023Transforming Accessibility one lunch at a tiime - CSUN 2023
Transforming Accessibility one lunch at a tiime - CSUN 2023Ted Drake
 
Inclusive Design for cognitive disabilities, neurodiversity, and chronic illness
Inclusive Design for cognitive disabilities, neurodiversity, and chronic illnessInclusive Design for cognitive disabilities, neurodiversity, and chronic illness
Inclusive Design for cognitive disabilities, neurodiversity, and chronic illnessTed Drake
 
Inclusive design for Long Covid
 Inclusive design for Long Covid  Inclusive design for Long Covid
Inclusive design for Long Covid Ted Drake
 
Covid 19, brain fog, and inclusive design
Covid 19, brain fog, and inclusive designCovid 19, brain fog, and inclusive design
Covid 19, brain fog, and inclusive designTed Drake
 
Customer obsession and accessibility
Customer obsession and accessibilityCustomer obsession and accessibility
Customer obsession and accessibilityTed Drake
 
The Saga of Accessible Colors
The Saga of Accessible ColorsThe Saga of Accessible Colors
The Saga of Accessible ColorsTed Drake
 
Artificial Intelligence and Accessibility - GAAD 2020 - Hello A11y
Artificial Intelligence and Accessibility - GAAD 2020 - Hello A11yArtificial Intelligence and Accessibility - GAAD 2020 - Hello A11y
Artificial Intelligence and Accessibility - GAAD 2020 - Hello A11yTed Drake
 
Expand your outreach with an accessibility champions program
Expand your outreach with an accessibility champions program Expand your outreach with an accessibility champions program
Expand your outreach with an accessibility champions program Ted Drake
 
Intuit's Accessibility Champion Program - Coaching and Celebrating
Intuit's Accessibility Champion Program - Coaching and Celebrating Intuit's Accessibility Champion Program - Coaching and Celebrating
Intuit's Accessibility Champion Program - Coaching and Celebrating Ted Drake
 
Accessibility First Innovation
Accessibility First InnovationAccessibility First Innovation
Accessibility First InnovationTed Drake
 
Inclusive customer interviews make it your friday task
Inclusive customer interviews  make it your friday taskInclusive customer interviews  make it your friday task
Inclusive customer interviews make it your friday taskTed Drake
 
Coaching and Celebrating Accessibility Champions
Coaching and Celebrating Accessibility ChampionsCoaching and Celebrating Accessibility Champions
Coaching and Celebrating Accessibility ChampionsTed Drake
 
Accessibility statements and resource publishing best practices csun 2019
Accessibility statements and resource publishing best practices   csun 2019Accessibility statements and resource publishing best practices   csun 2019
Accessibility statements and resource publishing best practices csun 2019Ted Drake
 
Raising Accessibility Awareness at Intuit
Raising Accessibility Awareness at IntuitRaising Accessibility Awareness at Intuit
Raising Accessibility Awareness at IntuitTed Drake
 
Trickle Down Accessibility
Trickle Down AccessibilityTrickle Down Accessibility
Trickle Down AccessibilityTed Drake
 
Trickle-Down Accessibility - CSUN 2018
Trickle-Down Accessibility - CSUN 2018Trickle-Down Accessibility - CSUN 2018
Trickle-Down Accessibility - CSUN 2018Ted Drake
 
Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...
Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...
Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...Ted Drake
 
Mystery Meat 2.0 – Making hidden mobile interactions accessible
Mystery Meat 2.0 – Making hidden mobile interactions accessibleMystery Meat 2.0 – Making hidden mobile interactions accessible
Mystery Meat 2.0 – Making hidden mobile interactions accessibleTed Drake
 
React Native Accessibility - San Diego React and React Native Meetup
React Native Accessibility - San Diego React and React Native MeetupReact Native Accessibility - San Diego React and React Native Meetup
React Native Accessibility - San Diego React and React Native MeetupTed Drake
 

More from Ted Drake (20)

Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024
Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024
Introduce Trauma-Informed Design to Your Organization - CSUN ATC 2024
 
Transforming Accessibility one lunch at a tiime - CSUN 2023
Transforming Accessibility one lunch at a tiime - CSUN 2023Transforming Accessibility one lunch at a tiime - CSUN 2023
Transforming Accessibility one lunch at a tiime - CSUN 2023
 
Inclusive Design for cognitive disabilities, neurodiversity, and chronic illness
Inclusive Design for cognitive disabilities, neurodiversity, and chronic illnessInclusive Design for cognitive disabilities, neurodiversity, and chronic illness
Inclusive Design for cognitive disabilities, neurodiversity, and chronic illness
 
Inclusive design for Long Covid
 Inclusive design for Long Covid  Inclusive design for Long Covid
Inclusive design for Long Covid
 
Covid 19, brain fog, and inclusive design
Covid 19, brain fog, and inclusive designCovid 19, brain fog, and inclusive design
Covid 19, brain fog, and inclusive design
 
Customer obsession and accessibility
Customer obsession and accessibilityCustomer obsession and accessibility
Customer obsession and accessibility
 
The Saga of Accessible Colors
The Saga of Accessible ColorsThe Saga of Accessible Colors
The Saga of Accessible Colors
 
Artificial Intelligence and Accessibility - GAAD 2020 - Hello A11y
Artificial Intelligence and Accessibility - GAAD 2020 - Hello A11yArtificial Intelligence and Accessibility - GAAD 2020 - Hello A11y
Artificial Intelligence and Accessibility - GAAD 2020 - Hello A11y
 
Expand your outreach with an accessibility champions program
Expand your outreach with an accessibility champions program Expand your outreach with an accessibility champions program
Expand your outreach with an accessibility champions program
 
Intuit's Accessibility Champion Program - Coaching and Celebrating
Intuit's Accessibility Champion Program - Coaching and Celebrating Intuit's Accessibility Champion Program - Coaching and Celebrating
Intuit's Accessibility Champion Program - Coaching and Celebrating
 
Accessibility First Innovation
Accessibility First InnovationAccessibility First Innovation
Accessibility First Innovation
 
Inclusive customer interviews make it your friday task
Inclusive customer interviews  make it your friday taskInclusive customer interviews  make it your friday task
Inclusive customer interviews make it your friday task
 
Coaching and Celebrating Accessibility Champions
Coaching and Celebrating Accessibility ChampionsCoaching and Celebrating Accessibility Champions
Coaching and Celebrating Accessibility Champions
 
Accessibility statements and resource publishing best practices csun 2019
Accessibility statements and resource publishing best practices   csun 2019Accessibility statements and resource publishing best practices   csun 2019
Accessibility statements and resource publishing best practices csun 2019
 
Raising Accessibility Awareness at Intuit
Raising Accessibility Awareness at IntuitRaising Accessibility Awareness at Intuit
Raising Accessibility Awareness at Intuit
 
Trickle Down Accessibility
Trickle Down AccessibilityTrickle Down Accessibility
Trickle Down Accessibility
 
Trickle-Down Accessibility - CSUN 2018
Trickle-Down Accessibility - CSUN 2018Trickle-Down Accessibility - CSUN 2018
Trickle-Down Accessibility - CSUN 2018
 
Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...
Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...
Accessibility metrics Accessibility Data Metrics and Reporting – Industry Bes...
 
Mystery Meat 2.0 – Making hidden mobile interactions accessible
Mystery Meat 2.0 – Making hidden mobile interactions accessibleMystery Meat 2.0 – Making hidden mobile interactions accessible
Mystery Meat 2.0 – Making hidden mobile interactions accessible
 
React Native Accessibility - San Diego React and React Native Meetup
React Native Accessibility - San Diego React and React Native MeetupReact Native Accessibility - San Diego React and React Native Meetup
React Native Accessibility - San Diego React and React Native Meetup
 

Recently uploaded

Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetEnjoy Anytime
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 

Recently uploaded (20)

Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
The transition to renewables in India.pdf
The transition to renewables in India.pdfThe transition to renewables in India.pdf
The transition to renewables in India.pdf
 

Hitting the accessibility high notes with ARIA

  • 1. Hitting the high notes with ARIA Ted Drake, Intuit Accessibility Silicon Valley Code Camp, October 2013 Sunday, October 6, 13 This presentation on ARIA was created for the Silicon Valley Code Camp, 2013 by Ted Drake.
  • 2. Goals • Screen Reader Introduction • Introduce ARIA • Use it today • Examples Sunday, October 6, 13 The goal of this talk to to de-mystify ARIA and encourage engineers to make their sites more accessible by using it correctly. This talk will be focused on new users, but should also provide interesting content and examples for more advanced users.
  • 3. Screen Readers Sunday, October 6, 13 Screen readers are used primarily by people with vision disabilities. However, they are also used as a middle layer for automated testing and for people with cognitive and physical disabilities. Screen readers interpret the user’s interaction and the applications responses.
  • 4. Sunday, October 6, 13 This short video shows how a screen reader announces the content and role of an element, such as a link or form input.
  • 5. Sunday, October 6, 13 This short video shows how a screen reader announces the content and role of an element, such as a link or form input.
  • 6. Sunday, October 6, 13 This short video shows how a screen reader user can navigate around a page by examining the header tags. The user can also navigate via landmarks, form elements, links, images, and other types of elements on the page.
  • 7. Sunday, October 6, 13 This short video shows how a screen reader user can navigate around a page by examining the header tags. The user can also navigate via landmarks, form elements, links, images, and other types of elements on the page.
  • 8. What is ARIA? Sunday, October 6, 13
  • 9. a·ri·a ˈärēə/ noun Music noun: aria; plural noun: arias 1. a long, accompanied song for a solo voice, typically one in an opera or oratorio. Sunday, October 6, 13 An aria is the solo performance during an opera that brings people to their feet.
  • 10. A·RI·A ˈärēə/ nounTechnology noun: aria;  1. WAI-ARIA (Web Accessibility Initiative - Accessible Rich Internet Applications) is a draft technical specification published by the World Wide Web Consortium that specifies how to increase the accessibility of dynamic content and user interface components Sunday, October 6, 13 WAI ARIA is a web standard established as a bridging technique to provide accessibility to dynamic web sites.
  • 11. Basics • HTML attributes • Good support • Easy • Bridge to HTML5 • No visual impact Sunday, October 6, 13 ARIA is a set of HTML attributes that provide information to the user via the browser and assistive technology. ARIA has good support via browsers and screen readers, but not as good for other assistive technology. Don’t depend on ARIA if possible. ARIA’s basic elements are easy to understand and code ARIA is a bridge technology until HTML5 is completely supported. It’s ok to combine and should be future proof.
  • 12. ARIA Rules 1. Don’t use ARIA if native tag is available. 2. See #1 Sunday, October 6, 13 The best user experience is created with the semantic HTML tags. ARIA is meant to fix areas that cannot use existing native elements. Use <button> instead of role=”button”, <table> instead of role=”grid”, and <img> instead of role=”img” too many people are using crap code because it is part of a platform, given in a demo, or think it’s easier to style a blank element. Don’t do this. Use the correct tag to give your site structure. If you are stuck using bad code, use ARIA to make it work, but you are still stuck with a bad foundation. http://www.w3.org/TR/aria-in-html/#first-rule-of-aria-use
  • 13. ARIA > HTML Sunday, October 6, 13 ARIA has more importance than HTML. When you put ARIA on a tag, it will supercede the tag’s value. This includes role, state, and properties.
  • 14. I’m a link that points to the same page and says “Button” Before ARIA Sunday, October 6, 13 In this example, we have a link that has been styled to look like a button. <a href=”#”>Button</a>
  • 15. <a href=”#”> ! Button </a> Sunday, October 6, 13 This is the code for the link that looks like a button. It will be announced as an internal link, as the href value is #.
  • 16. I’m a button that says “Button” After ARIA Sunday, October 6, 13 In this example, we have a link that has been styled to look like a button. <a href=”#” role=”button”>Button</a>
  • 17. <a href=”#” role=”button”> ! Button </a> Sunday, October 6, 13 In this example, we are using the ARIA role attribute to redefine a link as a button. This will cause the screen reader to ignore the href. Links should take the user to a new page or chunk of content. Buttons should trigger an action.
  • 18. Roles • Widget: role=”alert” • Composite: role=”grid” • Document Structure: role=”img” • Landmark: role=”search” • w3.org/TR/wai-aria/roles Sunday, October 6, 13 Alert is a widget role. Adding this role suggests an interface and may be standalone or part of a group. Alert will prompt the browser to announce the content when this object changes, such as when an alert appears on a page. Grid is a composite role. There’s a complex arrangement of sub-roles. Grid allows a set of divs to act like a table. Img is a structure role. It describes the structural elements and are not interactive. Landmarks are regions that can be used for navigation to key elements of an application. http://www.w3.org/TR/wai-aria/roles
  • 19. Landmarks • Search Form: role=”search” • Main: role=”main” • Nav: role=”navigation” • Header: role=”banner” Sunday, October 6, 13 landmarks define content areas on a page. These match HTML5 tags and can be combined. They provide alternate navigation opportunities for users. Firefox is the only browser that currently surfaces the native HTML5 tag roles to assistive technology. So <nav role=”navigation”> is good.
  • 20. Landmarks <form role=”search”> <label for=”q”>Search</label> <input type=”search” id=”q” name=”q”> <button>submit</button> </form> Sunday, October 6, 13 Adding role=”search” to the form tag allows a user to quickly move to the search form from anywhere in the page. Note, this goes on the form, not the input.
  • 21. States • aria-disabled=”true | false” • aria-expanded=”true | false | undefined” • aria-hidden=”true | false” • aria-invalid=”true | false | grammar | spelling” • aria-selected=”true | false | undefined” Sunday, October 6, 13 States represent the current state of an object and can change as the user interacts with the application. Many are tied to specific roles and cannot be used indiscriminately. Many of these states are already commonly used in HTML elements
  • 22. I’m a disabled button that says “Disabled Button” After ARIA Sunday, October 6, 13 In this example, we have a span that has been styled to look like a button. <a href=”#” role=”button”>Button</a>
  • 23. <a href=”#” role=”button” aria-disabled=”true”> ! Disabled Button </a> Sunday, October 6, 13 In this example, we added aria-disabled=”true” to the link to let users know this isn’t just a button, it’s a disabled button. It would be easier to simply use <button disabled>Disabled Button</button>
  • 24. <button disabled> Disabled Button </button> Sunday, October 6, 13 This shows how it is much easier to use the native tags and avoid fixing stuff with ARIA http://www.w3.org/TR/html401/interact/forms.html#h-17.12
  • 25. Properties • aria-live=”polite | assertive | off” • aria-label=”string” • aria-describedby=”string” • aria-haspopup=”true | false” Sunday, October 6, 13 Properties attributes don’t change frequently. They describe special features for an object aria-live: describes how a browser/screen reader should announce content when it changes, ie polite waits for the user to pause. aria-label: provides a label when the standard text label is not available. It will also over-write any existing text labels. aria-describedby: is treated similar to the title attribute. It announces optional information that provides context. aria-haspopup: clicking on this link or button will generate a new chunk of content, such as a dropdown menu or dialog window.
  • 26. Live Regions • aria-live=”polite”: announced after user stops interacting with page. • aria-live=”assertive”: interrupts user • aria-live=”off”: no announcement • role=”alert”: inherits aria-live=”assertive” Sunday, October 6, 13
  • 27. Sunday, October 6, 13 This example from the University of Illinois Urbana-Champagne shows how aria-live announced new content. There is a message box that will interrupt the reading of the text box. The message box is using aria-live=”assertive” http://test.cita.illinois.edu/aria/live/
  • 28. Sunday, October 6, 13 This example from the University of Illinois Urbana-Champagne shows how aria-live announced new content. There is a message box that will interrupt the reading of the text box. The message box is using aria-live=”assertive” http://test.cita.illinois.edu/aria/live/
  • 30. Sunday, October 6, 13 This shows how pseudo buttons are not focusable via tab key and are announced as a text string, not an interactive element test page: http://fyvr.net/a11y/fake-real-buttons.html
  • 31. Sunday, October 6, 13 This shows how pseudo buttons are not focusable via tab key and are announced as a text string, not an interactive element test page: http://fyvr.net/a11y/fake-real-buttons.html
  • 32. Sunday, October 6, 13 This short video shows a common pattern where the search form has no label. Further, the input is using the value attribute to contain a pseudo-placeholder. The value is cleared when the user places focus into the input. This fails because the input now has no label, no placeholder, and no value. The placeholder attribute is not consistently supported and will not be announced if a user moves back into the input after a value has been entered.
  • 33. Sunday, October 6, 13 This short video shows a common pattern where the search form has no label. Further, the input is using the value attribute to contain a pseudo-placeholder. The value is cleared when the user places focus into the input. This fails because the input now has no label, no placeholder, and no value. The placeholder attribute is not consistently supported and will not be announced if a user moves back into the input after a value has been entered.
  • 34. Sunday, October 6, 13 This video is a bit more difficult to understand. It shows a data table that uses divs instead of a standard table markup. the screen reader announces the content as a series of simple strings. The selected icons are not announced, as they are empty spans with background images. Test page: http://fyvr.net/a11y/payroll-table.html
  • 35. Sunday, October 6, 13 This video is a bit more difficult to understand. It shows a data table that uses divs instead of a standard table markup. the screen reader announces the content as a series of simple strings. The selected icons are not announced, as they are empty spans with background images. Test page: http://fyvr.net/a11y/payroll-table.html
  • 36. ARIA to the Rescue Sunday, October 6, 13 Let’s go back to our earlier examples and show how ARIA can fix those common issues.
  • 37. Sunday, October 6, 13 This video shows how role=”button” makes a link sound just like a real button. <a href=”#” role=”button”>foo</a>
  • 38. Sunday, October 6, 13 This video shows how role=”button” makes a link sound just like a real button. <a href=”#” role=”button”>foo</a>
  • 39. Sunday, October 6, 13 This form fixes the search form by adding role=”search” to the form tag. This sets it as a landmark. The input receives a label via aria-label=”search” The placeholder attribute is not a substitute for a label.
  • 40. Sunday, October 6, 13 This form fixes the search form by adding role=”search” to the form tag. This sets it as a landmark. The input receives a label via aria-label=”search” The placeholder attribute is not a substitute for a label.
  • 41. Sunday, October 6, 13 This example isn’t perfect. But it does show how these divs can be given the data table semantics by using the role=”grid” and appropriate children roles. The blue dots are also given text: supported and not supported. This could have been built with a basic data table in the start.
  • 42. Sunday, October 6, 13 This example isn’t perfect. But it does show how these divs can be given the data table semantics by using the role=”grid” and appropriate children roles. The blue dots are also given text: supported and not supported. This could have been built with a basic data table in the start.
  • 43. ARIA Form • role=”alert” • aria-describedby=”emailerror” • aria-invalid=”true” Sunday, October 6, 13 So far, this presentation has given examples of using ARIA to restore semantics and add landmarks. Let’s see how a few small changes can make significant usability improvements that were not possible with basic html. This example will use role=”alert” on an input’s error message. The invalid form input will also get aria-invalid=”true” and aria-describedby to point to the error message.
  • 44. Sunday, October 6, 13 This form has an email input that is validated as the user leaves the input (onBlur). The video shows how the screen reader will announce the alert as soon as it appears. When the user goes back to the input, they are told the input is invalid and the error message is repeated.
  • 45. Sunday, October 6, 13 This form has an email input that is validated as the user leaves the input (onBlur). The video shows how the screen reader will announce the alert as soon as it appears. When the user goes back to the input, they are told the input is invalid and the error message is repeated.
  • 46. role=”alert” <p role="alert" id="emailerror"> Please enter a valid email address </p> Sunday, October 6, 13 Adding role=”alert” to an element will trigger the screen reader to announce the content whenever it changes. In this page, the content is announced when the display status is changed from display:none to display:block. Also note, there is an id on this element. This will be used by aria-describedby attribute.
  • 48. Invalid input <input type="email" required id="email" name="email" aria-invalid=”true” aria-describedby=”emailerror” > Sunday, October 6, 13 After the input has been identified as invalid, we will need to add some attributes. aria-invalid=”true” lets the user know when an input is invalid. Add this attribute in your logic that uses a style or content to visually identify invalid inputs. aria-describedby points to the id value of the error message. This will be announced as the input has focus.
  • 49. Sunday, October 6, 13 Repeat the video to show how this works.
  • 50. Sunday, October 6, 13 Repeat the video to show how this works.
  • 51. Key Takeaways • ARIA is easy and safe to use. • Use basic HTML before reaching into the ARIA bag • ARIA provides information on role, state, and property • Make your forms more accessible with ARIA • Stop the div-itis Sunday, October 6, 13
  • 52. T: @ted_drake S: slideshare.net/7mary4 U: last-child.com Y: youtube.com/7mary4responding E: ted_drake@intuit.com Thank You! Sunday, October 6, 13