hangman fix typing letters
This commit is contained in:
@@ -38,10 +38,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="game-input">
|
|
||||||
<label for="saisie" class="pb-1">Saisir vos lettres ici</label>
|
|
||||||
<input v-model="letterBox" id="saisie" type="text" @keyup="keyMessage">
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -69,6 +65,7 @@
|
|||||||
this.selectedWord = this.words[Math.floor(Math.random() * this.words.length)].toLowerCase()
|
this.selectedWord = this.words[Math.floor(Math.random() * this.words.length)].toLowerCase()
|
||||||
this.figureParts = this.$el.querySelectorAll('.figure-part')
|
this.figureParts = this.$el.querySelectorAll('.figure-part')
|
||||||
this.displayWord()
|
this.displayWord()
|
||||||
|
window.addEventListener('keyup', this.keyMessage)
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
keyMessage(e) {
|
keyMessage(e) {
|
||||||
|
|||||||
6
resources/sass/pages/games/hangman.scss
vendored
6
resources/sass/pages/games/hangman.scss
vendored
@@ -60,12 +60,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.game-input {
|
|
||||||
max-width: 30rem;
|
|
||||||
margin: 0 auto;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.popup-container {
|
.popup-container {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: calc(100% - 6rem);
|
width: calc(100% - 6rem);
|
||||||
|
|||||||
Reference in New Issue
Block a user