Skip to content

Commit

Permalink
yipee
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyler-Lentz committed Jun 19, 2024
1 parent cfdedc5 commit 031ff3d
Show file tree
Hide file tree
Showing 22 changed files with 81 additions and 0 deletions.
Binary file added images/yipee/yipee-0.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-1.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-10.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-11.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-12.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-13.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-14.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-15.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-16.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-17.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-18.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-19.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-2.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-3.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-4.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-5.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-6.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-7.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-8.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yipee-9.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/yipee/yippee.mp3
Binary file not shown.
81 changes: 81 additions & 0 deletions yipee.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Yipee!</title>
<link rel="stylesheet" href="css/global.css">
<style>
.yipee {
position: absolute;
top: 20vh;
animation-name: move;
animation-duration: 2.2s;
animation-timing-function: ease-in-out;
animation-iteration-count: 1;
}

@keyframes move {
from {
left: 0vw;
}
to {
left: 60vw;
}
}

@media (max-width: 1250px) {
@keyframes move {
from {
left: 0vw;
}
to {
left: 0vw;
}
}
}

#btn-container {
display: flex;
height: 100vh;
flex-direction: column;
justify-content: flex-end;
align-items: center;
}

#btn {
width: fit-content;
margin-bottom: 10rem;
font-size: 2rem;
}

</style>
<script>
var counter = 0;
document.addEventListener("DOMContentLoaded", () => {
let btn = document.getElementById('btn');
btn.addEventListener("click", () => {
btn.insertAdjacentHTML("afterend", `
<img class="yipee" style="left: 0vw" id="yippee-${counter}"src="./images/yipee/yipee-${counter % 20}.gif"></img>
`);
setTimeout(() => {
let sound = new Audio('./images/yipee/yippee.mp3');
sound.play();
}, 300);
const curr_val = counter;
setTimeout(() => {
document.getElementById(`yippee-${curr_val}`).remove();
}, 2200);
counter++;
});
});
</script>

<body>
<div id="btn-container">
<button id="btn">Click me</button>
</div>
</body>

</html>

0 comments on commit 031ff3d

Please sign in to comment.