1(function () { 2 function init() { 3 var mobileNavBlock = document.querySelector('.mobile-nav-block'); 4 var hamburger = document.querySelector('.hamburger'); 5 var closeBtn = document.querySelector('.clos-mobile-menu'); 6 7 function openMenu() { if (mobileNavBlock) mobileNavBlock.style.display = 'flex'; } 8 function closeMenu() { if (mobileNavBlock) mobileNavBlock.style.display = 'none'; } 9 10 if (hamburger) { 11 hamburger.addEventListener('click', function (e) { 12 e.preventDefault(); 13 e.stopImmediatePropagation(); 14 mobileNavBlock && mobileNavBlock.style.display === 'flex' ? closeMenu() : openMenu(); 15 }); 16 } 17 18 if (mobileNavBlock) { 19 mobileNavBlock.addEventListener('click', function (e) { 20 if (e.target === mobileNavBlock) closeMenu(); 21 }); 22 } 23 24 if (closeBtn) { 25 closeBtn.addEventListener('click', function (e) { 26 e.preventDefault(); 27 closeMenu(); 28 }); 29 } 30 31 document.querySelectorAll('.mobile-nav-menu-block .nav-link, .mobile-nav-menu-block .nav-cta-1, .mobile-nav-menu-block .nav-cta-2').forEach(function (el) { 32 el.addEventListener('click', closeMenu); 33 }); 34 35 window.addEventListener('resize', function () { 36 if (window.innerWidth >= 1051) closeMenu(); 37 }); 38 } 39 40 if (document.readyState === 'loading') { 41 document.addEventListener('DOMContentLoaded', init); 42 } else { 43 init(); 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.