Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Good intentions gone bad
Search
Eva Ferreira
May 23, 2024
Programming
0
170
Good intentions gone bad
JSHeroes 2024
Eva Ferreira
May 23, 2024
Tweet
Share
More Decks by Eva Ferreira
See All by Eva Ferreira
Bulletproof your Design System
evaferreira
0
98
Tales of Accessibility Failures
evaferreira
0
34
Tales of Accessibility Failures
evaferreira
0
180
La accesibilidad de todos los días - HackAcademy
evaferreira
0
110
Rescue the Dead Horse
evaferreira
0
130
De 45 a 85
evaferreira
0
90
Oda a la década++
evaferreira
1
110
Take on me
evaferreira
3
540
Video edition with CSS & JavaScript
evaferreira
1
270
Other Decks in Programming
See All in Programming
Compose 1.7のTextFieldはPOBox Plusで日本語変換できない
tomoya0x00
0
190
Better Code Design in PHP
afilina
PRO
0
120
『ドメイン駆動設計をはじめよう』のモデリングアプローチ
masuda220
PRO
8
540
ローコードSaaSのUXを向上させるためのTypeScript
taro28
1
610
距離関数を極める! / SESSIONS 2024
gam0022
0
280
WebフロントエンドにおけるGraphQL(あるいはバックエンドのAPI)との向き合い方 / #241106_plk_frontend
izumin5210
4
1.4k
Kaigi on Rails 2024 〜運営の裏側〜
krpk1900
1
210
シェーダーで魅せるMapLibreの動的ラスタータイル
satoshi7190
1
480
Jakarta EE meets AI
ivargrimstad
0
540
どうして僕の作ったクラスが手続き型と言われなきゃいけないんですか
akikogoto
1
120
リアーキテクチャxDDD 1年間の取り組みと進化
hsawaji
1
220
as(型アサーション)を書く前にできること
marokanatani
10
2.6k
Featured
See All Featured
Producing Creativity
orderedlist
PRO
341
39k
The Art of Programming - Codeland 2020
erikaheidi
52
13k
Intergalactic Javascript Robots from Outer Space
tanoku
269
27k
Automating Front-end Workflow
addyosmani
1366
200k
Build The Right Thing And Hit Your Dates
maggiecrowley
33
2.4k
Designing on Purpose - Digital PM Summit 2013
jponch
115
7k
The Cult of Friendly URLs
andyhume
78
6k
Git: the NoSQL Database
bkeepers
PRO
427
64k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
Building Flexible Design Systems
yeseniaperezcruz
327
38k
Teambox: Starting and Learning
jrom
133
8.8k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5k
Transcript
Good Intentions, Gone Bad Eva Ferreira – JS Heroes, 2024
Not another “This is how you do a11y” talk Good
intentions gone bad. @evaferreira92
@evaferreira92 YOU DON’T HAVE TO LEARN FROM YOUR MISTAKES IF
YOU CAN LEARN FROM MINE
WARNING This is a work in progress. I will, most
definitely, keep on messing up. @evaferreira92
5 lessons 1. Accessibility personas 2. Simplest things first 3.
People mean well 4. Test, test, test! 5. Accessibility ownership
Lesson 1
A11y personas Understanding disabilities and assistive technologies
What is a disability? “Accessibility is for blind people”
Disability: A failed interaction between the environment and a person
with a medical condition.
Diverse group of people, a wide range of needs. @evaferreira92
16% of world’s population. has a permanent disability.
None
None
Assistive Technologies * Also known as AT
The most common assistive technology is…
Keyboard Visual and motor impairments
Lesson 2
Simplest things tend to have the biggest impact. I went
ALL IN into aria and screen readers
I wrongly prioritized screen readers over keyboard navigation Begin your
a11y journey with simple and impactful changes. @evaferreira92
Simple, impactful • Color contrast • Semantics • Keyboard navigation
Outlines Skip navigation links @evaferreira92
Outlines
None
@evaferreira92
But they are ugly! Yes, they are!
https://www.sarasoueidan.com Use outlines on your focusable elements
https://mabl.com
Skip navigation links
https://www.sarasoueidan.com
Skip navigation links
None
Lots impact, Low code.
Sometimes simple is not that simple “Code debt just called;
it wants your happiness back.” @evaferreira92
Prioritize Impact and easy to solve @evaferreira92
Prioritize 1. Big impact, easy to solve 2. Mix with
small impact, easy to solve Ideal for Fridays 3. Big impact, hard to solve 4. Small impact, hard to solve @evaferreira92
Lesson 3
People mean well … Most of the time.
Story time! Story Number 1
Aria-label all the things! The Infobae & the React Testing
Library stories @evaferreira92
@evaferreira92
Code
Non Screen Reader users
Screen Reader users
aria-label overrides values
Screen Reader users
Why?
@evaferreira92 https://webaim.org/blog/aria-cause-solution https://webaim.org/blog/aria-cause-solution
Story time! Story Number 2
“Every image should have an alt text!” @evaferreira92
Rules for alternative texts • The alt attribute is compulsory
• It can be empty if the image is decorative (alt=“”) • Do not be redundant • If it has an action, describe the action, not the image @evaferreira92
https://www.w3.org/WAI/tutorials/images/decision-tree
The SEO in the room And the story of how
every image had the same alt text. @evaferreira92
Lesson 4
Testing correctly Having 98/100 on Lighthouse won’t save you.
None
None
Manual tests @evaferreira92
Manual tests • Keyboard navigation • Screen readers @evaferreira92
What do we test? We test users’ stories. @evaferreira92
Can a user with [assistive technology] do [action]? @evaferreira92
Test users’ stories • Can a user with keyboard navigation
- create an account? • Can a user with a screen reader - add a product to the cart? • Can a user watch this video - using captions? @evaferreira92
Test for people. @evaferreira92
Automated tests WCAG
None
WCAG • Set of rules created by W3C a long
time ago. • Standard in the industry • What gives the foundation for a11y laws all around the globe • Different success criteria depending on target audience, target country, type of company, etc. @evaferreira92
Of course, always aim for no errors. @evaferreira92
Automated tools • Axe-core by Deque • Lighthouse • Mabl
• Storybook add-on @evaferreira92
Automated tools • Add these to your pipelines • CI/CD
should fail when requirements are not met. @evaferreira92
How many websites do you think pass with no errors?
5%? 20%? 40%?
4.1% WebAIM Million, 2024 https://webaim.org/projects/million
None
@evaferreira92
“It’s just too hard.” @evaferreira92
@evaferreira92
Lesson 5
A11y ownership Team effort
None
None
You cannot out-code bad design. Accessibility is a team effort.
So, You made a mistake. What happens when you mess
up.
You try again! * Easier said than done @evaferreira92
None
Mistakes are: • Temporal • Localized • Changeable
You don’t need to be always right. Aim for making
new mistakes instead of repeating old ones. @evaferreira92
You need to try, you need to care. @evaferreira92
Thanks! @evaferreira92