cleanup and style

This commit is contained in:
Reppard 2022-02-08 13:27:43 -05:00
parent f218b4c27e
commit 72767c1ca5

View File

@ -212,7 +212,6 @@ export default {
this.pattern = []
this.check = []
this.score = 0
//this.generatePattern()
this.addToPattern()
this.playPattern()
},
@ -239,28 +238,6 @@ export default {
addToPattern() {
this.pattern.push(Math.floor(Math.random() * 4))
},
generatePattern() {
let pattern = []
for(let i = 0; i < this.count; i++ ) {
pattern[i] = Math.floor(Math.random() * 4)
setTimeout(()=> {
setTimeout(()=> {
this.blink = pattern[i]
}, 600)
setTimeout(()=> {
this.blink = null
}, 800)
}, 600 * (i+1))
}
this.pattern = pattern
return pattern
}
}
}
</script>
@ -397,10 +374,11 @@ html, body{
outline: none;
font-size: 24px;
font-weight: bold;
font-family: monospace;
height: 100%;
background: darkslategray;
text-shadow: 0px 0px 3px white;
color: black;
background: linear-gradient(45deg, black, transparent);
text-shadow: 0px 0px 12px black;
color: silver;
width: 100%;
}
@ -408,6 +386,10 @@ html, body{
border-radius: 100px 100px 0 0;
}
.start button:disabled {
color: black;
}
.reset button {
border-radius: 0 0 100px 100px;
}