1/** 2 * Mobil menunun acilip kapanmasi. 3 * 4 * @package Hero Concept 5 */ 6( function () { 7 var toggle = document.getElementById( 'toggle' ); 8 var popout = document.getElementById( 'popout' ); 9 10 if ( ! toggle || ! popout ) { 11 return; 12 } 13 14 function setExpanded( expanded ) { 15 popout.style.display = expanded ? 'block' : 'none'; 16 toggle.setAttribute( 'aria-expanded', expanded ? 'true' : 'false' ); 17 } 18 19 setExpanded( false ); 20 21 toggle.addEventListener( 'click', function () { 22 setExpanded( toggle.getAttribute( 'aria-expanded' ) !== 'true' ); 23 } ); 24 25 // Pencere masaustu genisligine cikinca menuyu kapat: dugme orada 26 // gizli oldugu icin acik kalirsa kullanici kapatamiyor. 27 var masaustu = window.matchMedia( '(min-width: 768px)' ); 28 function masaustuneGecince( olay ) { 29 if ( olay.matches ) { 30 setExpanded( false ); 31 } 32 } 33 if ( masaustu.addEventListener ) { 34 masaustu.addEventListener( 'change', masaustuneGecince ); 35 } else if ( masaustu.addListener ) { 36 masaustu.addListener( masaustuneGecince ); 37 } 38 39 document.addEventListener( 'keydown', function ( event ) { 40 if ( 'Escape' === event.key && 'true' === toggle.getAttribute( 'aria-expanded' ) ) { 41 setExpanded( false ); 42 toggle.focus(); 43 } 44 } ); 45} )();
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.