-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcode.js
More file actions
53 lines (43 loc) · 1.26 KB
/
code.js
File metadata and controls
53 lines (43 loc) · 1.26 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
var keysPressed = 0
var fullFakeText = "Your gradnma! 😊😊😊"
document.addEventListener('keydown', function(event) {
keysPressed += 1
if(keysPressed > 12){
keysPressed += 1
}
console.log(keysPressed)
fakeTextBox = document.getElementById("fake-text")
fakeTextBox.style.opacity = 1.0
fakeTextBox.innerHTML = fullFakeText.slice(0, keysPressed)
event.preventDefault()
});
var shader1 = document.getElementById("shader1")
var shader2 = document.getElementById("shader2")
var scam1 = document.getElementById("scam1")
var scam2 = document.getElementById("scam2")
function buttonHover(button){
if (button.style.opacity < 1.0){
button.style.opacity = 0.8
}
}
function buttonUnhover(button){
if (button.style.opacity < 1.0){
button.style.opacity = 0.5
}
}
shader1.addEventListener("click", function() {
shader1.style.opacity = 1.0
shader2.style.opacity = 0.5
})
shader2.addEventListener("click", function() {
shader2.style.opacity = 1.0
shader1.style.opacity = 0.5
})
scam1.addEventListener("click", function() {
scam1.style.opacity = 1.0
scam2.style.opacity = 0.5
})
scam2.addEventListener("click", function() {
scam2.style.opacity = 1.0
scam1.style.opacity = 0.5
})