mirror of
https://github.com/manilarome/the-glorious-startpage.git
synced 2024-11-28 02:23:12 +01:00
25 lines
537 B
JavaScript
25 lines
537 B
JavaScript
var centeredBox = document.getElementById("centeredBox");
|
|
|
|
let centeredBoxVisibility = true;
|
|
|
|
const showCenteredBox = () => {
|
|
centeredBox.classList.remove('hiddenBox');
|
|
centeredBoxVisibility = !centeredBoxVisibility;
|
|
}
|
|
|
|
const hideCenteredBox = () => {
|
|
centeredBox.classList.add('hiddenBox');
|
|
centeredBoxVisibility = !centeredBoxVisibility;
|
|
}
|
|
|
|
const toggleCenteredBox = () => {
|
|
|
|
if (centeredBoxVisibility) {
|
|
// Hide web menu
|
|
hideCenteredBox();
|
|
|
|
} else {
|
|
// Show Web menu
|
|
showCenteredBox();
|
|
}
|
|
} |