/******* Do not edit this file ******* Woody Code Snippets CSS and JS Saved: Jul 10 2024 | 08:16:45 */ const items = document.querySelectorAll('.menu__item'); const backgrounds = document.querySelectorAll('.menu__background'); items.forEach(el => el.addEventListener('mouseover', (e) => { let index = Array.from(items).indexOf(e.currentTarget); backgrounds.forEach(bg => bg.classList.remove('menu__background--active')); backgrounds[index].classList.add('menu__background--active'); }));