File tree 2 files changed +7
-2
lines changed
Standards/WCAG2AAA/Sniffs/Principle4/Guideline4_1
2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -136,11 +136,13 @@ _global.HTMLCS_WCAG2AAA_Sniffs_Principle4_Guideline4_1_4_1_2 = {
136
136
} //end if
137
137
} else {
138
138
if ( nameFound === false ) {
139
- // Href provided, but no content or title .
139
+ // Href provided, but no content, title or valid aria label .
140
140
// We only fire this message when there are no images in the content.
141
141
// A link around an image with no alt text is already covered in SC
142
142
// 1.1.1 (test H30).
143
- if ( element . querySelectorAll ( 'img' ) . length === 0 ) {
143
+ if ( element . querySelectorAll ( 'img' ) . length === 0
144
+ && HTMLCS . util . hasValidAriaLabel ( element ) === false
145
+ ) {
144
146
errors . noContent . push ( element ) ;
145
147
}
146
148
} //end if
Original file line number Diff line number Diff line change 12
12
Assert: Error *.H53.ARIA6 on #objectNoLabel
13
13
Assert: No Error *.H53.ARIA6 on #objectLabelledBy
14
14
Assert: No Error *.H53.ARIA6 on #objectLabel
15
+ Assert: No Error *.H91.A.NoContent on #hyperlinkLabel
15
16
-->
16
17
</ head >
17
18
< body >
42
43
43
44
< object id ="objectLabel " data ="x.jpg " aria-label ="monkey "> </ object >
44
45
46
+ < a id ="hyperlinkLabel " href ="http://www.squiz.net " aria-label ="Label as valid content "> </ a >
47
+
45
48
</ form >
46
49
</ body >
47
50
</ html >
You can’t perform that action at this time.
0 commit comments