File tree Expand file tree Collapse file tree 2 files changed +26
-1
lines changed
Standards/WCAG2AAA/Sniffs/Principle2/Guideline2_4 Expand file tree Collapse file tree 2 files changed +26
-1
lines changed Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ _global.HTMLCS_WCAG2AAA_Sniffs_Principle2_Guideline2_4_2_4_1 = {
110110 */
111111 testSameDocFragmentLinks : function ( element , top )
112112 {
113- if ( element . hasAttribute ( 'href' ) === true ) {
113+ if ( element . hasAttribute ( 'href' ) === true && HTMLCS . util . isFocusable ( element ) === true ) {
114114 var href = element . getAttribute ( 'href' ) ;
115115 href = HTMLCS . util . trim ( href ) ;
116116 if ( ( href . length > 1 ) && ( href . charAt ( 0 ) === '#' ) ) {
Original file line number Diff line number Diff line change 1+ <!DOCTYPE html>
2+ < html >
3+ < head >
4+ < title > 2.4.1 Bypass</ title >
5+ <!-- @HTMLCS_Test@
6+ Name: SC 2.4.1 Bypass
7+ Standard: WCAG2AA
8+ Assert: No Error *.G1,G123,G124.NoSuchID on #hidden-anchor
9+ -->
10+ < style type ="text/css ">
11+ .d-none {
12+ display : none;
13+ }
14+ </ style >
15+ </ head >
16+ < body >
17+
18+ < a href ="#main-content " id ="hidden-anchor " class ="d-none ">
19+ Skip to main content
20+ </ a >
21+
22+ </ body >
23+ </ html >
24+
25+
You can’t perform that action at this time.
0 commit comments