1const menu = document.querySelector('.menu'), 2 menuBtn = document.querySelector('.menu-btn'), 3 menuLists = document.querySelectorAll('.menu-nav p'), 4 shop_btn = document.querySelector('.shop-btn .btn'), 5 body = document.querySelector('body'); 6 7 8menuBtn.addEventListener('click', () => { 9 menu.classList.toggle('d-none'); 10 body.classList.toggle('bodyStopScroll'); 11}); 12 13 14window.addEventListener('click', (e) => { 15 if(e.target == menu) { 16 menu.classList.add('d-none'); 17 body.classList.remove('bodyStopScroll'); 18 } 19}); 20 21menuLists.forEach(list => { 22 list.addEventListener('click', () => { 23 list.nextElementSibling.classList.toggle('d-none') 24 list.children[0].classList.toggle('rotate') 25 }) 26}); 27 28 29shop_btn.addEventListener('click', () => { 30 shop_btn.parentElement.classList.toggle('showNav') 31}); 32 33document.addEventListener('click', (e)=> { 34 shop_btn.parentElement.contains(e.target) || shop_btn.parentElement.classList.remove('showNav') 35});
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.