From 03e2c7eec60df3d03b0ba340263bb9ec6c94309d Mon Sep 17 00:00:00 2001 From: MeiMei <30769358+mei23@users.noreply.github.com> Date: Sun, 17 Feb 2019 23:40:00 +0900 Subject: [PATCH] Fix #4300 (#4304) * Fix #4300 * sidebar --- src/client/app/desktop/script.ts | 3 ++- src/client/app/desktop/views/components/ui.header.account.vue | 2 +- src/client/app/desktop/views/components/ui.sidebar.vue | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/client/app/desktop/script.ts b/src/client/app/desktop/script.ts index 6957f34d7..c66171e3a 100644 --- a/src/client/app/desktop/script.ts +++ b/src/client/app/desktop/script.ts @@ -126,7 +126,8 @@ init(async (launch, os) => { os.store.commit('device/set', { key: 'inDeckMode', - value: os.store.getters.isSignedIn && os.store.state.device.deckMode && document.location.pathname === '/' + value: os.store.getters.isSignedIn && os.store.state.device.deckMode + && (document.location.pathname === '/' || window.performance.navigation.type === 1) }); // Init router diff --git a/src/client/app/desktop/views/components/ui.header.account.vue b/src/client/app/desktop/views/components/ui.header.account.vue index 37983285c..132605504 100644 --- a/src/client/app/desktop/views/components/ui.header.account.vue +++ b/src/client/app/desktop/views/components/ui.header.account.vue @@ -166,7 +166,7 @@ export default Vue.extend({ }, toggleDeckMode() { this.$store.commit('device/set', { key: 'deckMode', value: !this.$store.state.device.inDeckMode }); - location.reload(); + location.replace('/'); }, } }); diff --git a/src/client/app/desktop/views/components/ui.sidebar.vue b/src/client/app/desktop/views/components/ui.sidebar.vue index c404d03a1..a0fca8102 100644 --- a/src/client/app/desktop/views/components/ui.sidebar.vue +++ b/src/client/app/desktop/views/components/ui.sidebar.vue @@ -122,7 +122,7 @@ export default Vue.extend({ methods: { toggleDeckMode(deck) { this.$store.commit('device/set', { key: 'deckMode', value: deck }); - location.reload(); + location.replace('/'); }, onReversiInvited() {