/** * Handles toggling the navigation menu for small screens and * accessibility for submenu items. */ ( function() { var nav = document.getElementById( 'site-navigation' ), button, menu; if ( ! nav ) { return; } button = nav.getElementsByTagName( 'button' )[0]; menu = nav.getElementsByTagName( 'ul' )[0]; if ( ! button ) { return; } // Hide button if menu is missing or empty. if ( ! menu || ! menu.childNodes.length ) { button.style.display = 'none'; return; } button.onclick = function() { if ( -1 === menu.className.indexOf( 'nav-menu' ) ) { menu.className = 'nav-menu'; } if ( -1 !== button.className.indexOf( 'toggled-on' ) ) { button.className = button.className.replace( ' toggled-on', '' ); menu.className = menu.className.replace( ' toggled-on', '' ); } else { button.className += ' toggled-on'; menu.className += ' toggled-on'; } }; } )(); // Better focus for hidden submenu items for accessibility. ( function( $ ) { $( '.main-navigation' ).find( 'a' ).on( 'focus.twentytwelve blur.twentytwelve', function() { $( this ).parents( '.menu-item, .page_item' ).toggleClass( 'focus' ); } ); if ( 'ontouchstart' in window ) { $('body').on( 'touchstart.twentytwelve', '.menu-item-has-children > a, .page_item_has_children > a', function( e ) { var el = $( this ).parent( 'li' ); if ( ! el.hasClass( 'focus' ) ) { e.preventDefault(); el.toggleClass( 'focus' ); el.siblings( '.focus').removeClass( 'focus' ); } } ); } } )( jQuery ); /* FILE ARCHIVED ON 11:48:35 May 10, 2019 AND RETRIEVED FROM THE INTERNET ARCHIVE ON 11:41:49 Mar 25, 2020. JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE. ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C. SECTION 108(a)(3)). */ /* playback timings (ms): exclusion.robots.policy: 0.235 captures_list: 173.533 PetaboxLoader3.resolve: 1288.994 (2) RedisCDXSource: 1.92 esindex: 0.007 load_resource: 1398.609 exclusion.robots: 0.247 PetaboxLoader3.datanode: 240.517 (5) LoadShardBlock: 155.759 (3) CDXLines.iter: 13.237 (3) * menu for small screens and * accessibility for submenu items. */ ( function() { var nav = document.getElementById( 'site-navigation' ), button, menu; if ( ! nav ) { return; } button = nav.getElementsByTagName( 'button' )[0]; menu = nav.getElementsByTagName( 'ul' )[0]; if ( ! button ) { return; } // Hide button if menu is missing or empty. if ( ! menu || ! menu.childNodes.length ) { button.style.display = 'none'; return; } button.onclick = function() { if ( -1 === menu.className.indexOf( 'nav-menu' ) ) { menu.className = 'nav-menu'; } if ( -1 !== button.className.indexOf( 'toggled-on' ) ) { button.className = button.className.replace( ' toggled-on', '' ); menu.className = menu.className.replace( ' toggled-on', '' ); } else { button.className += ' toggled-on'; menu.className += ' toggled-on'; } }; } )(); // Better focus for hidden submenu items for accessibility. ( function( $ ) { $( '.main-navigation' ).find( 'a' ).on( 'focus.twentytwelve blur.twentytwelve', function() { $( this ).parents( '.menu-item, .page_item' ).toggleClass( 'focus' ); } ); if ( 'ontouchstart' in window ) { $('body').on( 'touchstart.twentytwelve', '.menu-item-has-children > a, .page_item_has_children > a', function( e ) { var el = $( this ).parent( 'li' ); if ( ! el.hasClass( 'focus' ) ) { e.preventDefault(); el.toggleClass( 'focus' ); el.siblings( '.focus').removeClass( 'focus' ); } } ); } } )( jQuery ); /* FILE ARCHIVED ON 11:48:35 May 10, 2019 AND RETRIEVED FROM THE INTERNET ARCHIVE ON 11:41:49 Mar 25, 2020. JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE. ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C. SECTION 108(a)(3)). */ /* playback timings (ms): exclusion.robots.policy: 0.235 captures_list: 173.533 PetaboxLoader3.resolve: 1288.994 (2) RedisCDXSource: 1.92 esindex: 0.007 load_resource: 1398.609 exclusion.robots: 0.247 PetaboxLoader3.datanode: 240.517 (5) LoadShardBlock: 155.759 (3) CDXLines.iter: 13.237 (3) */