-
Notifications
You must be signed in to change notification settings - Fork 10
/
home.js
27 lines (26 loc) · 1.04 KB
/
home.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
document.addEventListener("click", (clickEvent) => {
if (clickEvent.target.id === "onboardingButtonZero") {
flipVisibility("onboardingContentZero");
} else if (clickEvent.target.id === "onboardingButtonOne") {
flipVisibility("onboardingContentOne");
} else if (clickEvent.target.id === "onboardingButtonTwo") {
flipVisibility("onboardingContentTwo");
} else if (clickEvent.target.id === "onboardingButtonThree") {
flipVisibility("onboardingContentThree");
} else if (clickEvent.target.id === "onboardingButtonFour") {
flipVisibility("onboardingContentFour");
} else if (clickEvent.target.id === "onboardingButtonFive") {
flipVisibility("onboardingContentFive");
} else if (clickEvent.target.id === "fliplinks") {
flipVisibility("info-content");
}
});
function flipVisibility(div) {
console.log("(home) seeking flippable", div);
let flippable = document.getElementById(div);
if (flippable.style.display !== "block") {
flippable.style.display = "block";
} else {
flippable.style.display = "none";
}
}