-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
62 lines (57 loc) · 2.03 KB
/
Copy pathindex.html
File metadata and controls
62 lines (57 loc) · 2.03 KB
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Bad Apple</title>
<link rel="icon" href="favicon.ico" type="image/x-icon">
<style>
body {
background-color: black;
color: white;
font-family: monospace;
white-space: pre;
margin: 0;
padding: 0;
overflow: hidden;
display: flex;
justify-content: center;
align-items: center;
height: 100vh; /* Ensures the content takes up the full height of the viewport */
flex-direction: column; /* Stack the button and ASCII display vertically */
}
#ascii-display {
font-size: 20px; /* Initial value, will be updated dynamically */
line-height: 1.1;
text-align: center; /* Ensures the ASCII art is centered */
display: flex;
justify-content: center;
align-items: center;
}
#play-button {
font-size: 24px;
padding: 10px 20px;
cursor: pointer;
background-color: white;
color: black;
border: none;
border-radius: 5px;
margin-top: 20px;
position: absolute; /* Make the button float above other content */
top: 50%; /* Position it vertically in the center */
left: 50%; /* Position it horizontally in the center */
transform: translate(-50%, -50%); /* Correct for the button's own size */
}
</style>
</head>
<body>
<div id="ascii-display"></div>
<button id="play-button">Play</button>
<audio id="audio-player">
<source src="bad_apple.mp3" type="audio/mp3">
Your browser does not support the audio element.
</audio>
<script src="https://cdnjs.cloudflare.com/ajax/libs/lz-string/1.4.4/lz-string.min.js"></script>
<script src="script.js"></script>
</body>
</html>