From 999977e32f01ff3aef75c4ae5ee2e36064fe9444 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Sat, 4 Jan 2025 12:18:23 +0200 Subject: [PATCH] fix(mobile): toggling sidebar sometimes doesn't work --- src/public/app/widgets/mobile_widgets/sidebar_container.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/public/app/widgets/mobile_widgets/sidebar_container.js b/src/public/app/widgets/mobile_widgets/sidebar_container.js index 59786321a..e401ef9f2 100644 --- a/src/public/app/widgets/mobile_widgets/sidebar_container.js +++ b/src/public/app/widgets/mobile_widgets/sidebar_container.js @@ -86,7 +86,8 @@ export default class SidebarContainer extends FlexContainer { // If the sidebar is closed, snap the sidebar open only if the user swiped over a threshold. // When the sidebar is open, always close for a smooth experience. const isOpen = (this.currentTranslate === -100 && this.translatePercentage > -(100 - DRAG_THRESHOLD)); - this.#setSidebarOpen(isOpen); + const screen = (isOpen ? "tree" : "detail"); + this.triggerCommand("setActiveScreen", { screen }); } #setInitialState() {