Saving current state
[vchess.git] / client / src / components / ChallengeList.vue
... / ...
CommitLineData
1<template lang="pug">
2table
3 tr
4 th Variant
5 th From
6 th To
7 th Cadence
8 tr(v-for="c in challenges" @click="$emit('click-challenge',c)")
9 td {{ c.vname }}
10 td {{ c.from.name }}
11 td(v-if="c.to[0].id > 0")
12 span(v-for="p in c.to") {{ p.name }}
13 td(v-else) {{ c.nbPlayers - 1 }} player{{ c.nbPlayers >= 3 ? 's' : '' }}
14 td {{ c.timeControl }}
15</template>
16
17<script>
18export default {
19 name: "my-challenge-list",
20 props: ["challenges"],
21};
22</script>
23
24<style lang="sass">
25// TODO: affichage bizarre sur petits écrans <=767px
26</style>