Web Accessibility Lesson 2
Let’s get started!
It’s all about content
Reader 1
Reader 2
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hgroup
<hgroup>
<h1>Calculus I</h1>
<h2>Fundamentals</h2>
</hgroup>
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hgroup
<hgroup>
<h1>Calculus I</h1>
<h2>Fundamentals</h2>
</hgroup>
The <hgroup> element has been removed from the HTML5 (W3C) specification, but it still is in the WHATWG version of HTML. It is partially implemented in most browsers, though, so is unlikely to go away.
However, given that a key purpose of the <hgroup> element is to affect how headings are displayed by the outline algorithm defined in the HTML specification—but the HTML outline algorithm is not implemented in any browsers—then the <hgroup> semantics are in practice only theoretical.
So the HTML5 (W3C) specification provides advice on how to mark up Subheadings, subtitles, alternative titles and taglines without using <hgroup>.
Success Criterion 2.4.2 Page Titled (A)
Which version of HTML?
HTML5
<!doctype html>
<html lang=en>
<title>Saving money, saving bytes</title>
<!doctype html>
<html lang=en>
<meta charset=utf-8>
<title>Saving money, saving bytes</title>
<h1>A Demo</h1>
<p>More content goes here.</p>
<head>
</head>
<body>
</body>
</html>
</li>
</dt>
</dd>
</p>
</option>
</tr>
</td>
</th>
<!doctype html>
<html lang=en>
<title>A demo on tabular data</title>
<h1>A demo on tabular data</h1>
<table>
<caption>Some fake data to demonstrate tabular data</caption>
<thead>
<tr> <th>Date <th>Visitors <th>Customers
<tbody>
<tr> <td>2020-09-01 <td>23 <td>12
<tr> <td>2020-09-02 <td>34 <td>16
<tr> <td>2020-09-03 <td>56 <td>19
<tr> <td>2020-09-04 <td>14 <td>3
</table>
zh-Hant-HK
<!doctype html>
<html lang=en>
<title>A demo on html lang</title>
SC 2.4.4 Link purpose in context (A)
SC 2.4.9 Link purpose (link text only) (AAA)
The purpose of each link can be determined from the link text alone or from the link text together with its programmatically determined link context, except where the purpose of the link would be ambiguous to users in general.
A mechanism is available to allow the purpose of each link to be identified from link text alone, except where the purpose of the link would be ambiguous to users in general.
Link Purpose (Link Only)
Link Purpose (In Context)
2. To download the PDF, please click here.
3. You may download the annual report in PDF format.
1. Download
2. To download the PDF, please click here.
3. You may download the annual report in PDF format.
1. Download
Yes, it is about writing. Content is about writing and communication.
<div class="row">
<div class="small-6 columns">
<h2>About</h2>
</div>
<div class="small-6 columns">
<h2>Teams</h2>
</div>
<div class="small-6 columns">
This is the content for about section
</div>
<div class="small-6 columns">
This is the teams members.
</div>
</div>
Bad flow
<main class="row">
<section class="small-6 columns">
<h2>About</h2>
<p>This is the content for about section</p>
</section>
<section class="small-6 columns">
<h2>Teams</h2>
<p>This is the teams members.</p>
</section>
</main>
Good flow
Bad one: Layout > Content Priority
Good one: Using Flexbox order
(AAA)
<p>
You can use <abbr title="Cascading Style Sheets">CSS</abbr> to style your <abbr title="HyperText Markup Language">HTML</abbr>.
</p>
<p>JavaScript Object Notation (<abbr>JSON</abbr>) is a lightweight data-interchange format.</p>
It’s all about content and structure