mirror of
https://github.com/bra1n/townsquare.git
synced 2025-04-04 22:24:36 +00:00
commit
6c050aae66
5 changed files with 13 additions and 10 deletions
BIN
public/countdown.mp3
Normal file
BIN
public/countdown.mp3
Normal file
Binary file not shown.
|
@ -51,7 +51,7 @@
|
||||||
<font-awesome-icon icon="hand-paper" class="vote" title="Hand UP" />
|
<font-awesome-icon icon="hand-paper" class="vote" title="Hand UP" />
|
||||||
</div>
|
</div>
|
||||||
<div class="overlay" @click="vote()">
|
<div class="overlay" @click="vote()">
|
||||||
<font-awesome-icon icon="times" class="vote" title="Hand DOWN" />
|
<font-awesome-icon icon="xmark" class="vote" title="Hand DOWN" />
|
||||||
</div>
|
</div>
|
||||||
<div class="overlay" @click="cancel()">
|
<div class="overlay" @click="cancel()">
|
||||||
<font-awesome-icon icon="times-circle" class="cancel" title="Cancel" />
|
<font-awesome-icon icon="times-circle" class="cancel" title="Cancel" />
|
||||||
|
@ -548,7 +548,7 @@ export default {
|
||||||
&.fa-hand * {
|
&.fa-hand * {
|
||||||
fill: url(#demon);
|
fill: url(#demon);
|
||||||
}
|
}
|
||||||
&.fa-times * {
|
&.fa-xmark * {
|
||||||
fill: url(#townsfolk);
|
fill: url(#townsfolk);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -563,7 +563,7 @@ export default {
|
||||||
// you voted yes | a locked vote yes | a locked vote no
|
// you voted yes | a locked vote yes | a locked vote no
|
||||||
#townsquare.vote .player.you.vote-yes .overlay svg.vote.fa-hand,
|
#townsquare.vote .player.you.vote-yes .overlay svg.vote.fa-hand,
|
||||||
#townsquare.vote .player.vote-lock.vote-yes .overlay svg.vote.fa-hand,
|
#townsquare.vote .player.vote-lock.vote-yes .overlay svg.vote.fa-hand,
|
||||||
#townsquare.vote .player.vote-lock:not(.vote-yes) .overlay svg.vote.fa-times {
|
#townsquare.vote .player.vote-lock:not(.vote-yes) .overlay svg.vote.fa-xmark {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
transform: scale(1);
|
transform: scale(1);
|
||||||
}
|
}
|
||||||
|
|
|
@ -75,7 +75,9 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
nameToFontSize(name) {
|
nameToFontSize(name) {
|
||||||
return name && name.length > 10 ? "90%" : "110%";
|
if (name && name.length > 14) return "80%";
|
||||||
|
if (name && name.length > 10) return "90%";
|
||||||
|
return "110%";
|
||||||
},
|
},
|
||||||
setRole() {
|
setRole() {
|
||||||
this.$emit("set-role");
|
this.$emit("set-role");
|
||||||
|
|
|
@ -104,6 +104,11 @@
|
||||||
<span>2</span>
|
<span>2</span>
|
||||||
<span>1</span>
|
<span>1</span>
|
||||||
<span>GO</span>
|
<span>GO</span>
|
||||||
|
<audio
|
||||||
|
:autoplay="!grimoire.isMuted"
|
||||||
|
src="/countdown.mp3"
|
||||||
|
:muted="grimoire.isMuted"
|
||||||
|
></audio>
|
||||||
</div>
|
</div>
|
||||||
</transition>
|
</transition>
|
||||||
</div>
|
</div>
|
||||||
|
@ -111,7 +116,6 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters, mapState } from "vuex";
|
import { mapGetters, mapState } from "vuex";
|
||||||
import bongs from "../assets/sounds/countdown.mp3";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
computed: {
|
computed: {
|
||||||
|
@ -189,10 +193,6 @@ export default {
|
||||||
countdown() {
|
countdown() {
|
||||||
this.$store.commit("session/lockVote", 0);
|
this.$store.commit("session/lockVote", 0);
|
||||||
this.$store.commit("session/setVoteInProgress", true);
|
this.$store.commit("session/setVoteInProgress", true);
|
||||||
if (!this.grimoire.isMuted) {
|
|
||||||
var sound = new Audio(bongs);
|
|
||||||
sound.play();
|
|
||||||
}
|
|
||||||
this.voteTimer = setInterval(() => {
|
this.voteTimer = setInterval(() => {
|
||||||
this.start();
|
this.start();
|
||||||
}, 4000);
|
}, 4000);
|
||||||
|
|
|
@ -39,7 +39,6 @@ const faIcons = [
|
||||||
"Skull",
|
"Skull",
|
||||||
"Square",
|
"Square",
|
||||||
"TheaterMasks",
|
"TheaterMasks",
|
||||||
"Times",
|
|
||||||
"TimesCircle",
|
"TimesCircle",
|
||||||
"TrashAlt",
|
"TrashAlt",
|
||||||
"Undo",
|
"Undo",
|
||||||
|
@ -53,6 +52,8 @@ const faIcons = [
|
||||||
"VoteYea",
|
"VoteYea",
|
||||||
"WindowMaximize",
|
"WindowMaximize",
|
||||||
"WindowMinimize",
|
"WindowMinimize",
|
||||||
|
"Times",
|
||||||
|
"Xmark",
|
||||||
];
|
];
|
||||||
const fabIcons = ["Github", "Discord"];
|
const fabIcons = ["Github", "Discord"];
|
||||||
library.add(
|
library.add(
|
||||||
|
|
Loading…
Add table
Reference in a new issue