diff --git a/js/main.js b/js/main.js index 6098a4b..8dad886 100644 --- a/js/main.js +++ b/js/main.js @@ -1,3 +1,11 @@ +// Toggle Menu +function menuToggle(){ + const menuToggle = document.getElementById('menuToggle'); + const navigation = document.getElementById('navigation'); + menuToggle.classList.toggle('active'); + navigation.classList.toggle('active'); +}; + // Countdown const body = document.body; @@ -20,15 +28,13 @@ function updateCountdown() { hoursEl.innerHTML = hours < 10 ? '0'+hours : hours; minutesEl.innerHTML = minutes < 10 ? '0'+minutes : minutes; secondsEl.innerHTML = seconds < 10 ? '0'+seconds : seconds; -} +}; - -// Time & Date +// Time & Date (Footer) setInterval(function(){ document.getElementById('date').innerHTML = Date(); },1000); - // scroll To Top let scrollTop = document.querySelector('.scrollTop');