Don't allow the server error to appear before initial connection
This commit is contained in:
parent
9f6766bd78
commit
c1339dc673
1 changed files with 7 additions and 1 deletions
|
|
@ -3,7 +3,7 @@
|
||||||
<transition name="top-slide">
|
<transition name="top-slide">
|
||||||
<div
|
<div
|
||||||
id="disconnect-error"
|
id="disconnect-error"
|
||||||
v-if="$socket.disconnected"
|
v-if="$socket.disconnected && ready"
|
||||||
>
|
>
|
||||||
No connection to the game server.
|
No connection to the game server.
|
||||||
<br>
|
<br>
|
||||||
|
|
@ -70,6 +70,7 @@ export default {
|
||||||
message: null,
|
message: null,
|
||||||
type: null,
|
type: null,
|
||||||
},
|
},
|
||||||
|
ready: false,
|
||||||
}},
|
}},
|
||||||
computed: {
|
computed: {
|
||||||
gameState() {
|
gameState() {
|
||||||
|
|
@ -119,6 +120,11 @@ export default {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.ready = true;
|
||||||
|
}, 1000);
|
||||||
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue