summaryrefslogtreecommitdiffstats
path: root/wp-includes/js/admin-bar.js
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--wp-includes/js/admin-bar.js36
1 files changed, 1 insertions, 35 deletions
diff --git a/wp-includes/js/admin-bar.js b/wp-includes/js/admin-bar.js
index 01b175d..eb18c61 100644
--- a/wp-includes/js/admin-bar.js
+++ b/wp-includes/js/admin-bar.js
@@ -95,11 +95,6 @@
} );
}
- if ( skipLink ) {
- // Focus the target of skip link after pressing Enter.
- skipLink.addEventListener( 'keydown', focusTargetAfterEnter );
- }
-
if ( shortlink ) {
shortlink.addEventListener( 'click', clickShortlink );
}
@@ -174,36 +169,7 @@
}
/**
- * Focus the target of skip link after pressing Enter.
- *
- * @since 5.3.1
- *
- * @param {Event} event The keydown event.
- */
- function focusTargetAfterEnter( event ) {
- var id, userAgent;
-
- if ( event.which !== 13 ) {
- return;
- }
-
- id = event.target.getAttribute( 'href' );
- userAgent = navigator.userAgent.toLowerCase();
-
- if ( userAgent.indexOf( 'applewebkit' ) > -1 && id && id.charAt( 0 ) === '#' ) {
- setTimeout( function() {
- var target = document.getElementById( id.replace( '#', '' ) );
-
- if ( target ) {
- target.setAttribute( 'tabIndex', '0' );
- target.focus();
- }
- }, 100 );
- }
- }
-
- /**
- * Toogle hover class for mobile devices.
+ * Toggle hover class for mobile devices.
*
* @since 5.3.1
*