X-Git-Url: https://git.auder.net/doc/current/git-logo.png?a=blobdiff_plain;f=client%2Fsrc%2Fviews%2FGame.vue;h=a0e264ed9e8b25d3011db34db6d2eaa57efd89a5;hb=6808d7a16ec1e761c6a2dffec2281c96953e4d89;hp=7b14055f969f595bbb217fb7f7f9d14e82bec646;hpb=63ca2b89cfe577efd168c6b2e26750cb01b66d64;p=vchess.git
diff --git a/client/src/views/Game.vue b/client/src/views/Game.vue
index 7b14055f..a0e264ed 100644
--- a/client/src/views/Game.vue
+++ b/client/src/views/Game.vue
@@ -1,18 +1,37 @@
main
+ input#modalChat.modal(type="checkbox" @click="resetChatColor()")
+ div#chatWrap(role="dialog" data-checkbox="modalChat")
+ #chat.card
+ label.modal-close(for="modalChat")
+ #participants
+ span {{ Object.keys(people).length + " " + st.tr["participant(s):"] }}
+ span(v-for="p in Object.values(people)" v-if="!!p.name")
+ | {{ p.name }}
+ span.anonymous(v-if="Object.values(people).some(p => !p.name)")
+ | + @nonymous
+ Chat(:players="game.players" :pastChats="game.chats"
+ :newChat="newChat" @mychat="processChat")
.row
- #chat.col-sm-12.col-md-4.col-md-offset-4
- Chat(:players="game.players" @newchat="processChat")
- .row
- .col-sm-12
- #actions(v-if="game.mode!='analyze' && game.score=='*'")
- button(@click="offerDraw") Draw
- button(@click="abortGame") Abort
- button(@click="resign") Resign
- div Names: {{ game.players[0].name }} - {{ game.players[1].name }}
- div(v-if="game.score=='*'") Time: {{ virtualClocks[0] }} - {{ virtualClocks[1] }}
- BaseGame(:game="game" :vr="vr" ref="basegame"
- @newmove="processMove" @gameover="gameOver")
+ #aboveBoard.col-sm-12.col-md-9.col-md-offset-3.col-lg-10.col-lg-offset-2
+ span.variant-cadence {{ game.cadence }}
+ span.variant-name {{ game.vname }}
+ button#chatBtn(onClick="doClick('modalChat')") Chat
+ #actions(v-if="game.score=='*'")
+ button(@click="clickDraw()" :class="{['draw-' + drawOffer]: true}")
+ | {{ st.tr["Draw"] }}
+ button(v-if="!!game.mycolor" @click="abortGame()") {{ st.tr["Abort"] }}
+ button(v-if="!!game.mycolor" @click="resign()") {{ st.tr["Resign"] }}
+ #playersInfo
+ p
+ span.name(:class="{connected: isConnected(0)}")
+ | {{ game.players[0].name || "@nonymous" }}
+ span.time(v-if="game.score=='*'") {{ virtualClocks[0] }}
+ span.split-names -
+ span.name(:class="{connected: isConnected(1)}")
+ | {{ game.players[1].name || "@nonymous" }}
+ span.time(v-if="game.score=='*'") {{ virtualClocks[1] }}
+ BaseGame(:game="game" :vr="vr" @newmove="processMove" @gameover="gameOver")
-