From c4efbdf4c7f10942a578b1b1387e625fe12e70c6 Mon Sep 17 00:00:00 2001 From: MeiMei <30769358+mei23@users.noreply.github.com> Date: Sun, 17 Feb 2019 21:28:20 +0900 Subject: [PATCH] Fix #4292 (#4294) * Fix #4292 * use commit --- src/client/app/desktop/script.ts | 7 ++++++- .../app/desktop/views/components/ui.header.account.vue | 4 ++-- src/client/app/desktop/views/components/ui.header.nav.vue | 2 +- src/client/app/desktop/views/components/ui.sidebar.vue | 4 ++-- 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/client/app/desktop/script.ts b/src/client/app/desktop/script.ts index 9fa4ec39f6..6957f34d75 100644 --- a/src/client/app/desktop/script.ts +++ b/src/client/app/desktop/script.ts @@ -124,11 +124,16 @@ init(async (launch, os) => { require('./views/components'); require('./views/widgets'); + os.store.commit('device/set', { + key: 'inDeckMode', + value: os.store.getters.isSignedIn && os.store.state.device.deckMode && document.location.pathname === '/' + }); + // Init router const router = new VueRouter({ mode: 'history', routes: [ - os.store.getters.isSignedIn && os.store.state.device.deckMode && document.location.pathname === '/' + os.store.state.device.inDeckMode ? { path: '/', name: 'index', component: MkDeck, children: [ { path: '/@:user', name: 'user', component: () => import('./views/deck/deck.user-column.vue').then(m => m.default), children: [ { path: '', name: 'user', component: () => import('./views/deck/deck.user-column.home.vue').then(m => m.default) }, 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 d94549c2aa..37983285c4 100644 --- a/src/client/app/desktop/views/components/ui.header.account.vue +++ b/src/client/app/desktop/views/components/ui.header.account.vue @@ -63,7 +63,7 @@
{{ $t('@.deck') }}
-