debug panel now optional
This commit is contained in:
parent
b24f222533
commit
748d6991a4
@ -15,7 +15,7 @@
|
||||
<Final v-if="gameState === 'final'" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="page-play__container-debug">
|
||||
<div v-if="showDebugPanel" class="page-play__container-debug">
|
||||
<EngineDebug />
|
||||
</div>
|
||||
</div>
|
||||
@ -31,6 +31,13 @@ export default {
|
||||
await this.$engine.stop()
|
||||
},
|
||||
computed: {
|
||||
showDebugPanel() {
|
||||
const user = this.$store.state.engine.user
|
||||
if (this.$route.query && this.$route.query.debug) {
|
||||
return true
|
||||
}
|
||||
return user && ['gamemaster', 'admin'].indexOf(user.role) != -1
|
||||
},
|
||||
gameState() {
|
||||
return this.$store.state.game.state
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user