22 lines
515 B
JavaScript
22 lines
515 B
JavaScript
{aed622b12488239f70ff3ec1e6e919291c4d6342 true 515 app.js 0xc001b28b60}
// Toggle Menu
|
|
function menuToggle(){
|
|
|
|
const menuToggle = document.getElementById("menuToggle");
|
|
const navigation = document.getElementById("navigation");
|
|
|
|
menuToggle.classList.toggle("active");
|
|
navigation.classList.toggle("active");
|
|
}
|
|
|
|
// Dark Mode
|
|
let body = document.querySelector('body');
|
|
let dark = document.querySelector('#dark');
|
|
|
|
dark.onclick = function (){
|
|
|
|
if(dark.checked == true){
|
|
body.classList.add('darkMode');
|
|
} else {
|
|
body.classList.remove('darkMode');
|
|
}
|
|
} |