Fix sidebar not opening when lounge is open in a background tab
This commit is contained in:
parent
674d9cfbd8
commit
cf0a4999e9
@ -70,7 +70,7 @@ export default {
|
|||||||
return tommorow - today;
|
return tommorow - today;
|
||||||
},
|
},
|
||||||
prepareOpenStates() {
|
prepareOpenStates() {
|
||||||
const viewportWidth = window.outerWidth;
|
const viewportWidth = window.innerWidth;
|
||||||
let isUserlistOpen = storage.get("thelounge.state.userlist");
|
let isUserlistOpen = storage.get("thelounge.state.userlist");
|
||||||
|
|
||||||
if (viewportWidth > constants.mobileViewportPixels) {
|
if (viewportWidth > constants.mobileViewportPixels) {
|
||||||
|
@ -69,7 +69,7 @@ const vueApp = new Vue({
|
|||||||
store.watch(
|
store.watch(
|
||||||
(state) => state.sidebarOpen,
|
(state) => state.sidebarOpen,
|
||||||
(sidebarOpen) => {
|
(sidebarOpen) => {
|
||||||
if (window.outerWidth > constants.mobileViewportPixels) {
|
if (window.innerWidth > constants.mobileViewportPixels) {
|
||||||
storage.set("thelounge.state.sidebar", sidebarOpen);
|
storage.set("thelounge.state.sidebar", sidebarOpen);
|
||||||
vueApp.$emit("resize");
|
vueApp.$emit("resize");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user