From 5672ee664abece41adeb59a8b2863d58d1b9b380 Mon Sep 17 00:00:00 2001 From: Zero~Informatique Date: Fri, 28 Feb 2020 04:05:02 +0100 Subject: viewer: show/hide the left panel depending on the viewport's width at init GitHub: Resolves #103 --- viewer/.env | 1 + viewer/src/store/uiStore.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'viewer') diff --git a/viewer/.env b/viewer/.env index 0914292..4721300 100644 --- a/viewer/.env +++ b/viewer/.env @@ -3,3 +3,4 @@ VUE_APP_I18N_LOCALE=en VUE_APP_I18N_FALLBACK_LOCALE=en VUE_APP_DATA_URL=./ +VUE_APP_FULLWIDTH_LIMIT=1500 diff --git a/viewer/src/store/uiStore.ts b/viewer/src/store/uiStore.ts index 1e63b3e..1d0d62f 100644 --- a/viewer/src/store/uiStore.ts +++ b/viewer/src/store/uiStore.ts @@ -27,7 +27,7 @@ const VuexModule = createModule({ export default class UIStore extends VuexModule { fullscreen: boolean = false; - fullWidth: boolean = true; + fullWidth: boolean = window.innerWidth < Number(process.env.VUE_APP_FULLWIDTH_LIMIT); searchMode: boolean = false; // --- -- cgit v1.2.3 From df98cc52700f77b06ce986ccb2137ec055a0e66c Mon Sep 17 00:00:00 2001 From: OzoneGrif Date: Fri, 28 Feb 2020 12:05:18 +0100 Subject: viewer: fullwidth limit consistent with Bulma's limit Co-Authored-By: Notkea --- viewer/.env | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'viewer') diff --git a/viewer/.env b/viewer/.env index 4721300..99efa3d 100644 --- a/viewer/.env +++ b/viewer/.env @@ -3,4 +3,4 @@ VUE_APP_I18N_LOCALE=en VUE_APP_I18N_FALLBACK_LOCALE=en VUE_APP_DATA_URL=./ -VUE_APP_FULLWIDTH_LIMIT=1500 +VUE_APP_FULLWIDTH_LIMIT=1216 -- cgit v1.2.3