-
Notifications
You must be signed in to change notification settings - Fork 0
/
improving-a11y.html
executable file
·381 lines (302 loc) · 12.4 KB
/
improving-a11y.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
<!doctype html>
<!-- Copyright (c) 2019 Environmental Systems Research Institute, Inc.
Apache-2.0 -->
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>Improving Accessibility with ArcGIS Online Web Apps</title>
<link rel="stylesheet" href="css/reveal.css">
<link rel="stylesheet" href="css/theme/dev-summit-2019.css">
<!-- Theme used for syntax highlighting of code -->
<link rel="stylesheet" href="lib/css/zenburn.css">
<!-- Printing and PDF exports -->
<script>
var link = document.createElement('link');
link.rel = 'stylesheet';
link.type = 'text/css';
link.href = window.location.search.match(/print-pdf/gi) ? 'css/print/pdf.css' : 'css/print/paper.css';
document.getElementsByTagName('head')[0].appendChild(link);
</script>
<style>
.reveal pre {
width: 50%;
}
.reveal p {
line-height: 1.5;
}
.reveal ul {
line-height: 1.5;
}
.reveal .twocol {
display: grid;
grid-template-columns: 1.5fr 1fr;
text-align: left;
}
.reveal p,
.reveal ul {
font-size: 50px;
}
.reveal p {
margin-top: 0;
}
.reveal section img {
border: none;
}
</style>
</head>
<body>
<div class="reveal">
<div class="slides">
<!-- Title slide -->
<section data-background="img/2019/devsummit/bg-1.png" data-background-size="cover" style="padding-left: 80px;">
<h1 style="text-align: left; font-size: 60px; margin-left: 65px; width: 15em; margin-top: 60px;">Improving
Accessibility with
ArcGIS Online Web Apps</h1>
<p style="text-align: left; font-size: 30px; margin-top: 2em; margin-left: 65px;">Kelly Hutchins</p>
<p style="text-align: left; font-size: 30px; line-height: 1; margin-left: 65px;">Tao Zhang</p>
<p style="text-align: left; font-size: 30px; margin-top: 2em; margin-left: 65px;">slides: <a href="https://arcg.is/08yqfD0"><code>https://arcg.is/08yqfD0</code></a></p>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-2.png">
<textarea data-template>
## What is accessibility?
Make content usable for everyone regardless of abilities.
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## Why is accessibility important?
- The ADA and Section 508
- People with different abilities should have equal access
- Good accessibility is good user experience
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## Accessibility presentations
|Title|Time|
|---|---|
|DIY Accessibility|Wed, March 6. 5:30pm - 6:30pm|
|Accessible Web Mapping Apps|Thu, March 7. 9am - 10am|
|Improving Accessibility with ArcGIS Online Web Apps|Thu, March 7. 2:30pm - 3:00pm|
</textarea>
</section>
<!-- Outline -->
<section data-markdown data-background="img/2019/devsummit/bg-4.png">
<textarea data-template>
## What we will cover today
- Test accessibility
- Fix accessibility issues
- Tools
- Best practices
</textarea>
</section>
<!-- Demo app link -->
<section data-markdown data-background="img/2019/devsummit/bg-6.png">
<textarea data-template>
## Demo app
Link: <a href="https://arcg.is/1O5u09"><code>https://arcg.is/1O5u09</code></a>
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-6.png">
<textarea data-template>
## aXe
Link: <a href="https://arcg.is/0Hv8Cn"><code>https://arcg.is/0Hv8Cn</code></a>
</textarea>
</section>
<!-- Color contrast -->
<section data-markdown data-background="img/2019/devsummit/bg-2.png">
<textarea data-template>
## Color contrast
- [WCAG 1.4.3](http:https://www.w3.org/TR/UNDERSTANDING-WCAG20/visual-audio-contrast-contrast.html): Text needs to have
contrast ratio of at least 4.5:1.
- [Contrast ratio](https://contrast-ratio.com/)
- Color picker in Chrome DevTools.
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-2.png">
<textarea data-template>
## Symbol colors
- [Color cube](https://oomphinc.github.io/colorcube/)
- [ColorBrewer 2.0](http:https://colorbrewer2.org)
- Blog article: [How to Make Smart Color Choices in Your Maps](https://www.esri.com/arcgis-blog/products/arcgis-enterprise/mapping/how-to-make-smart-color-choices-in-your-maps/)
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## White text on colored background
<p style="text-align:center;">
<img src="images/color-example-1.png" alt="Example of white text on light colored background">
</p>
<p style="text-align:center;">
<img class="fragment" src="images/color-example-2.png" alt="Example of white text on dark colored background">
</p>
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## Flipping the contrast
<p style="text-align:center;">
<img src="images/color-example-3.png" alt="Example of black text on light colored background">
</p>
</textarea>
</section>
<!-- Alternate text -->
<section data-markdown data-background="/img/2019/devsummit/bg-6.png">
<textarea data-template>
## Alternate text
- [WCAG 1.1.1](https://www.w3.org/TR/UNDERSTANDING-WCAG20/text-equiv-all.html): Non-text content has text alternative.
- If image is decorative, use `alt=""`.
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## Write effective alternate text
- Think about how users will be doing with the information
- Be accurate in presenting the content in images
- Be succinct
- No need to use the phrase "image of ..." to describe images
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## Alternate text demo
- [Empty alt](https://developers.arcgis.com/javascript/latest/sample-code/widgets-basemapgallery/live/index.html)
- [Descriptive alt](https://story.maps.arcgis.com/apps/MapJournal/index.html?appid=2b1c793f464b4cd2944a0b9700c0dc48)
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-3.png">
<textarea data-template>
## Landmark
Use both HTML 5 elements and ARIA landmarks.
| HTML | ARIA Role |
|----------|--------------------|
| `<header>` | `role="banner"` |
| `<nav>` | `role="navigation"` |
| `<main>` | `role="main"` |
| `<footer>` | `role="contentinfo"` |
<p style="margin-top: 1.5em; font-size: 0.8em;">Reference: <a href="https://www.scottohara.me/blog/2018/03/03/landmarks.html">Accessible Landmarks</a></p>
</textarea>
</section>
<section data-markdown data-background="img/2019/devsummit/bg-3.png">
<textarea data-template>
## Focus and tab order
<ul>
<li class="fragment">[WCAG 2.4.7](https://www.w3.org/TR/UNDERSTANDING-WCAG20/navigation-mechanisms-focus-visible.html): Interactive
elements should have clear focus.</li>
<li class="fragment">[WCAG 1.3.2](https://www.w3.org/TR/UNDERSTANDING-WCAG20/content-structure-separation-sequence.html): Navigation (tab)
order should be logical and intuitive.</li>
<li class="fragment">[WCAG 2.1.1](https://www.w3.org/TR/UNDERSTANDING-WCAG20/keyboard-operation-keyboard-operable.html): Keyboard users
should be able to use functionalities using keyboard only.</li>
<li class="fragment">[WCAG 2.1.2](http:https://www.w3.org/TR/UNDERSTANDING-WCAG20/keyboard-operation-trapping.html): Content does not "trap"
keyboard focus within subsections.</li>
</ul>
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-2.png">
<textarea data-template>
## Focus
Don't do this:
```css
*:focus {
outline: 0;
}
```
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-3.png">
<textarea data-template>
## Focus
Keep the browser's default focus styling.
Or implement custom focus style.
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-3.png">
<textarea data-template>
## Tab order
<p style="text-align: left; margin-left: 25px;">Tab order should match intended reading order.</p>
- `tabindex="0"`: let DOM structure determine focus order.
- `tabindex="-1"`: necessary for programmatically moving focus (e.g., error message, menus, radio buttons, etc.)
- `tabindex="3"`: anti-pattern.
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-3.png">
<textarea data-template>
## The `<button>` element
<p style="text-align: left;">When you use `<button>` element, you get a lot of functionality for free:</p>
- Buttons are automatically focusable.
- Screen readers will announce the button in focus and offer ways to click the button.
- Space and Enter keys are automatically supported when binding a click event listener to a button.
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-3.png">
<textarea data-template>
## Semantic HTML
- Choose the right HTML element to reflect content structure and meaning.
- `<div>` and `<span>` are semantically neutral.
- Significantly more work to polyfill the missing semantic information and expected behavior.
</textarea>
</section>
<section data-markdown data-background="/img/2019/devsummit/bg-3.png">
<textarea data-template>
## Dialog
- When a dialog opens, focus moves to an element inside the dialog.
- Focus should be "trapped" inside the dialog until the dialog is dismissed.
- Focus should return to the element that opens the dialog.
<p style="margin-top: 1.5em; font-size: 0.8em;">Reference: <a href="http:https://w3c.github.io/aria-practices/#dialog_modal">ARIA Best Practices - Dialog</a></p>
</textarea>
</section>
<!-- This is just the beginning -->
<section data-markdown data-background="/img/2019/devsummit/bg-2.png">
<textarea data-template>
## This is just the beginning
- [Lighthouse](https://github.com/GoogleChrome/lighthouse)
- Screen reader test
- [A11ycasts: VoiceOver](https://youtu.be/5R-6WvAihms)
- [A11ycasts: NVDA](https://youtu.be/Jao3s_CwdRU)
- Accessibility needs to be part of development process
</textarea>
</section>
<!-- ESRI LOGO SLIDE: -->
<section data-markdown data-background="img/2019/devsummit/bg-esri.png">
</section>
<!-- SURVEY SLIDE: -->
<section data-markdown data-background="img/2019/devsummit/bg-rating.png">
</section>
</div>
</div>
<script src="lib/js/head.min.js"></script>
<script src="js/reveal.js"></script>
<script>
// More info about config & dependencies:
// - https://github.com/hakimel/reveal.js#configuration
// - https://github.com/hakimel/reveal.js#dependencies
Reveal.initialize({
// This height and width are here for the left-aligned title slide.
// If you do not want that, you can remove these two settings and
// the presentation will be closer to OOTB-Reveal.js:
width: '100%',
height: '100%',
history: true,
dependencies: [{
src: 'plugin/markdown/marked.js'
},
{
src: 'plugin/markdown/markdown.js'
},
{
src: 'plugin/notes/notes.js',
async: true
},
{
src: 'plugin/highlight/highlight.js',
async: true,
callback: function () {
hljs.initHighlightingOnLoad();
}
}
]
});
</script>
</body>
</html>