Difference between revisions of "Accessible name calc"
(→Input type button) |
(→Applet Element) |
||
(5 intermediate revisions by the same user not shown) | |||
Line 235: | Line 235: | ||
<html> | <html> | ||
<body> | <body> | ||
+ | <p>none</p> | ||
+ | <applet code="Acc.class" width="350" height="350"> | ||
+ | |||
<p>Inner text</p> | <p>Inner text</p> | ||
<div> | <div> | ||
Line 342: | Line 345: | ||
</body> | </body> | ||
+ | </html> | ||
+ | |||
+ | =Area Element= | ||
+ | <html> | ||
+ | <body> | ||
+ | <h2>Alt attribute</h2> | ||
+ | <p>Acc name for area elements "NOVA", "Central", "Tidewater"</p> | ||
+ | <img src="virginia.gif" width="140" height="125" alt="Virginia" | ||
+ | usemap="#virginamap"> | ||
+ | |||
+ | <map name="virginiamap"> | ||
+ | <area shape="rect" coords="0,0,82,126" href="nova.htm" alt="NOVA"> | ||
+ | <area shape="circle" coords="90,58,3" href="central.htm" alt="central"> | ||
+ | <area shape="circle" coords="124,58,8" href="tidewater.htm" alt="Tidewater"> | ||
+ | </map> | ||
+ | |||
+ | <h2>Title attribute</h2> | ||
+ | <p>Acc name for area elements "NOVA", "Central", "Tidewater"</p> | ||
+ | <img src="virginia.gif" width="140" height="125" title="Virginia" | ||
+ | usemap="#virginamap"> | ||
+ | <map name="virginiamap"> | ||
+ | <area shape="rect" coords="0,0,82,126" href="nova.htm" title="NOVA"> | ||
+ | <area shape="circle" coords="90,58,3" href="central.htm" title="central"> | ||
+ | <area shape="circle" coords="124,58,8" href="tidewater.htm" title="Tidewater"> | ||
+ | </map> | ||
+ | |||
+ | <h2>aria-label attribute</h2> | ||
+ | <p>Acc name for area elements "NOVA", "Central", "Tidewater"</p> | ||
+ | <img src="virginia.gif" width="140" height="125" aria-label="Virginia" | ||
+ | usemap="#virginamap"> | ||
+ | |||
+ | <map name="virginiamap"> | ||
+ | <area shape="rect" coords="0,0,82,126" href="nova.htm" aria-label="NOVA"> | ||
+ | <area shape="circle" coords="90,58,3" href="central.htm" aria-label="central"> | ||
+ | <area shape="circle" coords="124,58,8" href="tidewater.htm" aria-label="Tidewater"> | ||
+ | </map> | ||
+ | |||
+ | <h2>aria-labelledby attribute</h2> | ||
+ | <p>Acc name for image "virginia"</p> | ||
+ | <div id="virginia1">Virginia</div> | ||
+ | <p>Acc name for area elements "NOVA", "Central", "Tidewater"</p> | ||
+ | <img src="virginia.gif" width="140" height="125" aria-labelledby="Virginia1" | ||
+ | usemap="#virginamap"> | ||
+ | |||
+ | <div id="va1">NOVA</div> | ||
+ | <div id="va2">Central</div> | ||
+ | <div id="va3">Tidewater</div> | ||
+ | |||
+ | <map name="virginiamap"> | ||
+ | <area shape="rect" coords="0,0,82,126" href="nova.htm" aria-labelledby="va1"> | ||
+ | <area shape="circle" coords="90,58,3" href="central.htm" aria-labelledby="va2"> | ||
+ | <area shape="circle" coords="124,58,8" href="tidewater.htm" aria-labelledby="va3"> | ||
+ | </map> | ||
+ | |||
+ | </body> | ||
+ | </html> | ||
+ | |||
+ | =Meter Element= | ||
+ | <html> | ||
+ | <body> | ||
+ | <h2>Inner text</h2> | ||
+ | <p>Acc name = "3 out of 10</p> | ||
+ | <meter value="3" min="0" max="10">3 out of 10</meter> | ||
+ | |||
+ | <h2>Title</h2> | ||
+ | <p>Acc name = "3 out of 10</p> | ||
+ | <meter value="3" min="0" max="10" title="3 out of 10"></meter> | ||
+ | |||
+ | <h2>aria-label</h2> | ||
+ | <p>Acc name = "3 out of 10</p> | ||
+ | <meter value="3" min="0" max="10" aria-label="3 out of 10"></meter> | ||
+ | |||
+ | <h2>aria-labelledby</h2> | ||
+ | <p>Acc name = "3 out of 10</p> | ||
+ | <meter value="3" min="0" max="10" aria-labelledby="meter1"></meter> | ||
+ | <div id="meter1">3 out of 10</div> | ||
+ | |||
+ | </body> | ||
+ | </html> | ||
+ | |||
+ | =Progress Element= | ||
+ | <html> | ||
+ | <body> | ||
+ | <h2>Inner text</h2> | ||
+ | <p>Acc name= "23 out of 100"</p> | ||
+ | <progress value="23" max="100">23 out of 100</progress> | ||
+ | |||
+ | <h2>title</h2> | ||
+ | <p>Acc name= "23 out of 100"</p> | ||
+ | <progress value="23" max="100" title="23 out of 100"></progress> | ||
+ | |||
+ | <h2>aria-label</h2> | ||
+ | <p>Acc name= "23 out of 100"</p> | ||
+ | <progress value="23" max="100" aria-label="23 out of 100"></progress> | ||
+ | |||
+ | <h2>aria-labelledby</h2> | ||
+ | <p>Acc name= "23 out of 100"</p> | ||
+ | <progress value="23" max="100" aria-labelledby="progress1"></progress> | ||
+ | <div id="progress1">23 out of 100</div> | ||
+ | </body> | ||
</html> | </html> | ||
[[Category:ARIA]] | [[Category:ARIA]] |
Latest revision as of 17:42, 7 September 2017
Image
Image with aria-label and alt
having an accessible name of “here”.
Image with space for aria-label and alt
having an accessible name of “ ”.
Image with null for aria-label and alt
having an accessible name of “hello”.
Image with aria-labelledby with multiple id refs/h2>
Hello
Here

Link
Link with pseudo content
has an accessible name of "click here".
Link with only pseudo content
Link referencing aria-labelledby with pseudo content
Link referencing aria-labelledby with display none including children
has an accessible name of "pool location"
Link referencing aria-labelledby with visibility hidden including children
has an accessible name of "pool"
Link referencing parent with aria-labelledby
Massive storm sweeps across nation click here
has an accessible name of "Massive storms sweeps across nation click here"
Link with aria-labelledby that contains some content with aria-hidden
Link with aria-labelledby that contains all content with aria-hidden
Link with text and span with aria-label and span with aria-labelledby
Avila D
Has an accessible name of "Jon not".
Reference to aria-labelledby element which has aria-label
Avila
Has an accessible name of "David".
Switch
Name as text content "running?"
Name as aria-labelledby "Is your refrigerator running?"
Name as aria-label "Fridge is running?"
Name as title attribute with text content "Running?"
Name as title attribute with no text content "Fridge is running?"
iframe
title "SSB's homepage"
aria-label "my label"
aria-labelledby "SSB's homepage"
Input no type
Explicit label
acc name is "first name:"
Implicit label
acc name is "first name:"
title attribute
acc name is "last name:"
aria-label attribute
acc name is "Middle name:"
aria-labelledby
acc name is "SSN:"
SSN:Input type text
Explicit Label
acc name is "first name:"
Implicit label
acc name is "first name:"
title attribute
acc name is "last name:"
aria-label attribute
acc name is "Middle name:"
aria-labelledby
acc name is "SSN:"
SSN:Contents
Object element
Inner text
acc name is "This is an object"
title attribute
Acc name = "This is an object"
aria-label attribute
acc name is "This is an object"
aria-labelledby attribute
acc name is "This is Flash"
Applet Element
none