From e210701bcfc083fecea2a9fef6458afb6f81d0d8 Mon Sep 17 00:00:00 2001 From: Stefan Malzner Date: Thu, 5 Sep 2019 13:20:42 +0200 Subject: [PATCH] fix(Windows): Fix app size in fullscreen --- src/stores/AppStore.js | 11 +++++++++++ src/styles/layout.scss | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js index 6054e6721..315235ba4 100644 --- a/src/stores/AppStore.js +++ b/src/stores/AppStore.js @@ -94,6 +94,7 @@ export default class AppStore extends Store { this._offlineCheck.bind(this), this._setLocale.bind(this), this._muteAppHandler.bind(this), + this._handleFullScreen.bind(this), ]); } @@ -379,6 +380,16 @@ export default class AppStore extends Store { } } + _handleFullScreen() { + const body = document.querySelector('body'); + + if (this.isFullScreen) { + body.classList.add('isFullScreen'); + } else { + body.classList.remove('isFullScreen'); + } + } + // Helpers _appStartsCounter() { this.actions.settings.update({ diff --git a/src/styles/layout.scss b/src/styles/layout.scss index 58e9e3000..b18bd6dcf 100644 --- a/src/styles/layout.scss +++ b/src/styles/layout.scss @@ -32,7 +32,7 @@ html { overflow: hidden; } .app-loader .app-loader__title { color: $dark-theme-gray-lightest; } } -body.win32 .app .app__content { +body.win32:not(.isFullScreen) .app .app__content { height: calc(100% - 28px); }