X-Git-Url: https://git.auder.net/variants/Dynamo/complete_rules.html?a=blobdiff_plain;f=client%2Fsrc%2Fviews%2FGame.vue;h=6282680845cbea3d84e98d8a653e855ac797b4eb;hb=42a9284896b9cf9a579d32b7cf77dfc1f5786472;hp=009dbb4765f43826b16a215d811605a726bb6b78;hpb=abb5917eabac5f6da6841c35567c706066409e44;p=vchess.git diff --git a/client/src/views/Game.vue b/client/src/views/Game.vue index 009dbb47..62826808 100644 --- a/client/src/views/Game.vue +++ b/client/src/views/Game.vue @@ -89,7 +89,7 @@ main ) img(src="/images/icons/resign.svg") button.tooltip( - v-else-if="!!game.mycolor" + v-else @click="clickRematch()" :class="{['rematch-' + rematchOffer]: true}" :aria-label="st.tr['Rematch']" @@ -216,13 +216,14 @@ export default { }, mounted: function() { document.addEventListener('visibilitychange', this.visibilityChange); - document - .getElementById("chatWrap") - .addEventListener("click", processModalClick); + ["chatWrap", "infoDiv"].forEach(eltName => { + document.getElementById(eltName) + .addEventListener("click", processModalClick); + }); if ("ontouchstart" in window) { // Disable tooltips on smartphones: document.querySelectorAll("#aboveBoard .tooltip").forEach(elt => { - elt.classList.remove("tooltip") + elt.classList.remove("tooltip"); }); } }, @@ -757,7 +758,7 @@ export default { drawSent: this.drawOffer == "sent", rematchSent: this.rematchOffer == "sent", score: this.game.score, - score: this.game.scoreMsg, + scoreMsg: this.game.scoreMsg, movesCount: L, initime: this.game.initime[1 - myIdx] //relevant only if I played };