input#inputFen(type="text" v-model="newchallenge.fen")
button(@click="newChallenge") {{ st.tr["Send challenge"] }}
.row
input#inputFen(type="text" v-model="newchallenge.fen")
button(@click="newChallenge") {{ st.tr["Send challenge"] }}
.row
input#gameSection(type="radio" aria-hidden="true" name="accordion")
label(for="gameSection" aria-hidden="true") Games
div
input#gameSection(type="radio" aria-hidden="true" name="accordion")
label(for="gameSection" aria-hidden="true") Games
div
import { ArrayFun } from "@/utils/array";
import { ajax } from "@/utils/ajax";
import { getRandString, shuffle } from "@/utils/alea";
import { ArrayFun } from "@/utils/array";
import { ajax } from "@/utils/ajax";
import { getRandString, shuffle } from "@/utils/alea";
import GameList from "@/components/GameList.vue";
import ChallengeList from "@/components/ChallengeList.vue";
import { GameStorage } from "@/utils/gameStorage";
export default {
name: "my-hall",
components: {
import GameList from "@/components/GameList.vue";
import ChallengeList from "@/components/ChallengeList.vue";
import { GameStorage } from "@/utils/gameStorage";
export default {
name: "my-hall",
components: {
computed: {
uniquePlayers: function() {
// Show e.g. "@nonymous (5)", and do nothing on click on anonymous
computed: {
uniquePlayers: function() {
// Show e.g. "@nonymous (5)", and do nothing on click on anonymous
- {
- const remotes = g.players.filter(p => this.people.some(pl => pl.sid == p.sid));
- const rIdx = (remotes.length == 1 ? 0 : Math.floor(Math.random()*2));
- url += "?rid=" + remotes[rIdx].sid;
- }
+ url += "?rid=" + g.rid;
// Ask identity, challenges and game(s)
this.st.conn.send(JSON.stringify({code:"askidentity", target:sid}));
this.st.conn.send(JSON.stringify({code:"askchallenge", target:sid}));
// Ask identity, challenges and game(s)
this.st.conn.send(JSON.stringify({code:"askidentity", target:sid}));
this.st.conn.send(JSON.stringify({code:"askchallenge", target:sid}));