https://www.mdsrbija.org/2016/wp-content/themes/activello/inc/js/skip-link-focus-fix.js?ver=20140222
1/** 2 * File skip-link-focus-fix.js. 3 * 4 * Helps with accessibility for keyboard only users. 5 * 6 * Learn more: https://git.io/vWdr2 7 */ 8( function() { 9 var isWebkit = navigator.userAgent.toLowerCase().indexOf( 'webkit' ) > -1, 10 isOpera = navigator.userAgent.toLowerCase().indexOf( 'opera' ) > -1, 11 isIe = navigator.userAgent.toLowerCase().indexOf( 'msie' ) > -1; 12 13 if ( ( isWebkit || isOpera || isIe ) && document.getElementById && window.addEventListener ) { 14 window.addEventListener( 'hashchange', function() { 15 var id = location.hash.substring( 1 ), 16 element; 17 18 if ( ! ( /^[A-z0-9_-]+$/.test( id ) ) ) { 19 return; 20 } 21 22 element = document.getElementById( id ); 23 24 if ( element ) { 25 if ( ! ( /^(?:a|select|input|button|textarea)$/i.test( element.tagName ) ) ) { 26 element.tabIndex = -1; 27 } 28 29 element.focus(); 30 } 31 }, false ); 32 } 33})();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.