From 4a068483ed9b1334780402cbe64dfa3f4a0e8a3a Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Tue, 5 Apr 2022 18:38:05 +0300 Subject: wide mode initial implementation + cleanup --- src/boot/after_store.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/boot/after_store.js') diff --git a/src/boot/after_store.js b/src/boot/after_store.js index 76832708..ce96141d 100644 --- a/src/boot/after_store.js +++ b/src/boot/after_store.js @@ -332,8 +332,11 @@ const checkOAuthToken = async ({ store }) => { } const afterStoreSetup = async ({ store, i18n }) => { - const width = windowWidth() - store.dispatch('setMobileLayout', width <= 800) + // TODO cleanup copypasta + const mobileLayout = windowWidth() <= 800 + const wideLayout = windowWidth() >= 1300 + const layoutType = wideLayout ? 'wide' : (mobileLayout ? 'mobile' : 'normal') + store.dispatch('setLayoutType', layoutType) FaviconService.initFaviconService() -- cgit v1.2.3-70-g09d2