You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
563 B
JavaScript

// Reveal text
Array.from(document.querySelectorAll(".reveal")).forEach(function(reveal) {
reveal.addEventListener("click", function (e) {
console.log("Surprise, there's text!");
reveal.classList.toggle("tada");
})
});
// Reveal visual
//Array.from(document.querySelectorAll(".reveal-visual")).forEach(function(revealVisual) {
// revealVisual.addEventListener("click", function (f) {
// console.log("Surprise, a visual!");
// revealVisual.classList.toggle("tada");
// var body = document.body;
// body.classList.toggle("switched");
// })
//});