mirror of https://github.com/bra1n/townsquare.git
menu stuff
This commit is contained in:
parent
e9745a6b51
commit
4a69cd50f9
10
src/App.vue
10
src/App.vue
|
@ -56,6 +56,12 @@ export default {
|
||||||
case "a":
|
case "a":
|
||||||
this.$refs.menu.addPlayer();
|
this.$refs.menu.addPlayer();
|
||||||
break;
|
break;
|
||||||
|
case "h":
|
||||||
|
this.$refs.menu.hostSession();
|
||||||
|
break;
|
||||||
|
case "j":
|
||||||
|
this.$refs.menu.joinSession();
|
||||||
|
break;
|
||||||
case "r":
|
case "r":
|
||||||
this.$store.commit("toggleModal", "reference");
|
this.$store.commit("toggleModal", "reference");
|
||||||
break;
|
break;
|
||||||
|
@ -67,8 +73,8 @@ export default {
|
||||||
if (this.session.isSpectator) return;
|
if (this.session.isSpectator) return;
|
||||||
this.$store.commit("toggleModal", "roles");
|
this.$store.commit("toggleModal", "roles");
|
||||||
break;
|
break;
|
||||||
case "Escape":
|
case "escape":
|
||||||
this.$store.commit("toggleMenu");
|
this.$store.commit("toggleModal");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,6 +70,7 @@
|
||||||
Zoom
|
Zoom
|
||||||
</li>
|
</li>
|
||||||
<li @click="setBackground">
|
<li @click="setBackground">
|
||||||
|
<em><font-awesome-icon icon="image"/></em>
|
||||||
Background image
|
Background image
|
||||||
</li>
|
</li>
|
||||||
</template>
|
</template>
|
||||||
|
@ -82,10 +83,10 @@
|
||||||
Live Session
|
Live Session
|
||||||
</li>
|
</li>
|
||||||
<li @click="hostSession" v-if="!session.sessionId">
|
<li @click="hostSession" v-if="!session.sessionId">
|
||||||
Host a session
|
<em>[H]</em> Host (Storyteller)
|
||||||
</li>
|
</li>
|
||||||
<li @click="joinSession" v-if="!session.sessionId">
|
<li @click="joinSession" v-if="!session.sessionId">
|
||||||
Join a session
|
<em>[J]</em> Join (Player)
|
||||||
</li>
|
</li>
|
||||||
<li v-if="session.sessionId" @click="copySessionUrl">
|
<li v-if="session.sessionId" @click="copySessionUrl">
|
||||||
<em><font-awesome-icon icon="copy"/></em>
|
<em><font-awesome-icon icon="copy"/></em>
|
||||||
|
@ -104,9 +105,11 @@
|
||||||
<em>[A]</em> Add
|
<em>[A]</em> Add
|
||||||
</li>
|
</li>
|
||||||
<li @click="randomizeSeatings" v-if="players.length > 2">
|
<li @click="randomizeSeatings" v-if="players.length > 2">
|
||||||
|
<em><font-awesome-icon icon="dice"/></em>
|
||||||
Randomize
|
Randomize
|
||||||
</li>
|
</li>
|
||||||
<li @click="clearPlayers" v-if="players.length">
|
<li @click="clearPlayers" v-if="players.length">
|
||||||
|
<em><font-awesome-icon icon="trash-alt"/></em>
|
||||||
Remove all
|
Remove all
|
||||||
</li>
|
</li>
|
||||||
</template>
|
</template>
|
||||||
|
@ -123,6 +126,7 @@
|
||||||
Choose & Assign
|
Choose & Assign
|
||||||
</li>
|
</li>
|
||||||
<li @click="clearRoles" v-if="players.length">
|
<li @click="clearRoles" v-if="players.length">
|
||||||
|
<em><font-awesome-icon icon="trash-alt"/></em>
|
||||||
Remove all
|
Remove all
|
||||||
</li>
|
</li>
|
||||||
</template>
|
</template>
|
||||||
|
@ -313,8 +317,8 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu {
|
.menu {
|
||||||
width: 210px;
|
width: 220px;
|
||||||
transform-origin: 190px 22px;
|
transform-origin: 200px 22px;
|
||||||
transition: transform 500ms cubic-bezier(0.68, -0.55, 0.27, 1.55);
|
transition: transform 500ms cubic-bezier(0.68, -0.55, 0.27, 1.55);
|
||||||
transform: rotate(-90deg);
|
transform: rotate(-90deg);
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
@ -357,7 +361,7 @@ export default {
|
||||||
border-radius: 10px 0 10px 10px;
|
border-radius: 10px 0 10px 10px;
|
||||||
|
|
||||||
li {
|
li {
|
||||||
padding: 2px 10px;
|
padding: 2px 5px;
|
||||||
color: white;
|
color: white;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
background: rgba(0, 0, 0, 0.7);
|
background: rgba(0, 0, 0, 0.7);
|
||||||
|
|
|
@ -13,10 +13,12 @@ const faIcons = [
|
||||||
"CheckSquare",
|
"CheckSquare",
|
||||||
"Cog",
|
"Cog",
|
||||||
"Copy",
|
"Copy",
|
||||||
|
"Dice",
|
||||||
"ExchangeAlt",
|
"ExchangeAlt",
|
||||||
"FileUpload",
|
"FileUpload",
|
||||||
"HandPointRight",
|
"HandPointRight",
|
||||||
"Heartbeat",
|
"Heartbeat",
|
||||||
|
"Image",
|
||||||
"Link",
|
"Link",
|
||||||
"PeopleArrows",
|
"PeopleArrows",
|
||||||
"Question",
|
"Question",
|
||||||
|
@ -27,6 +29,7 @@ const faIcons = [
|
||||||
"Square",
|
"Square",
|
||||||
"TheaterMasks",
|
"TheaterMasks",
|
||||||
"TimesCircle",
|
"TimesCircle",
|
||||||
|
"TrashAlt",
|
||||||
"Undo",
|
"Undo",
|
||||||
"User",
|
"User",
|
||||||
"UserEdit",
|
"UserEdit",
|
||||||
|
|
|
@ -95,12 +95,12 @@ export default new Vuex.Store({
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
toggleModal({ modals }, name) {
|
toggleModal({ modals }, name) {
|
||||||
modals[name] = !modals[name];
|
if (name) {
|
||||||
if (modals[name]) {
|
modals[name] = !modals[name];
|
||||||
for (let modal in modals) {
|
}
|
||||||
if (modal === name) continue;
|
for (let modal in modals) {
|
||||||
modals[modal] = false;
|
if (modal === name) continue;
|
||||||
}
|
modals[modal] = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
updateScreenshot({ grimoire }, status) {
|
updateScreenshot({ grimoire }, status) {
|
||||||
|
|
Loading…
Reference in New Issue