diff --git a/src/js/footer/070-tabs.js b/src/js/footer/070-tabs.js index 46938c448..d68d6648b 100644 --- a/src/js/footer/070-tabs.js +++ b/src/js/footer/070-tabs.js @@ -10,7 +10,7 @@ AddEvent( tabItems, 'click', function( event, $this ) { for( var i = 0; i < currentTabItems.length; i++ ) { RemoveClass( currentTabItems[ i ], 'tab-item--active' ); - currentTabItems[ i ].removeAttribute( 'aria-selected' ); + currentTabItems[ i ].setAttribute( 'aria-selected', 'false' ); currentTabItems[ i ].setAttribute( 'tabindex', '1' ); } @@ -40,6 +40,9 @@ var InitialiseTabs = function( tabs ) { if( HasClass( tabs[ i ], 'tab-item--active' ) ){ tabs[ i ].setAttribute( 'aria-selected', 'true' ); } + else { + tabs[ i ].setAttribute( 'aria-selected', 'false' ); + } } };