From 4cc4f908d83251fedfe0814aedd61694289e13bd Mon Sep 17 00:00:00 2001 From: nicfreeman1209 Date: Tue, 11 May 2021 17:58:41 +0100 Subject: [PATCH] add dismiss button --- src/components/TownSquare.vue | 15 +++++++--- src/store/index.js | 54 +++++++++++++++++------------------ 2 files changed, 38 insertions(+), 31 deletions(-) diff --git a/src/components/TownSquare.vue b/src/components/TownSquare.vue index efedfd3..4166f0d 100644 --- a/src/components/TownSquare.vue +++ b/src/components/TownSquare.vue @@ -23,9 +23,12 @@ > -
-
- Reveal storyteller grimoire? +
+
+ Reveal grimoire +
+
+ Dismiss
state.fabled.get(f.id) || f) + if (isLightweight) return; + // townsquare + this.commit("toggleNight", !!isNight); + this.commit("session/setVoteHistoryAllowed", isVoteHistoryAllowed); + if (nomination !== -1) { + this.commit("session/nomination", { + nomination, + votes, + votingSpeed, + lockedVote, + isVoteInProgress }); - // bluffs - if (bluffs !== -1) { - bluffs.forEach((bluff, i) => { - const role = - this.state.roles.get(bluff.roleId) || - this.getters.rolesJSONbyId.get(bluff.roleId) || - {}; - this.commit("players/setBluff", { - index: i, - role - }); + } + this.commit("session/setMarkedPlayer", markedPlayer); + this.commit("players/setFabled", { + fabled: fabled.map(f => state.fabled.get(f.id) || f) + }); + // bluffs + if (bluffs !== -1) { + bluffs.forEach((bluff, i) => { + const role = + this.state.roles.get(bluff.roleId) || + this.getters.rolesJSONbyId.get(bluff.roleId) || + {}; + this.commit("players/setBluff", { + index: i, + role }); - } + }); } if (isRevealedGrimoire) { this.commit("session/setRevealedGrimoire", null);