From f626325cae7db1b6015fae7ec58cdc13e2e88061 Mon Sep 17 00:00:00 2001 From: srgooglo Date: Tue, 11 Oct 2022 13:26:30 +0200 Subject: [PATCH] improve `session.created` transitions --- packages/app/src/App.jsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/app/src/App.jsx b/packages/app/src/App.jsx index 7025bfac..84cb6bfd 100644 --- a/packages/app/src/App.jsx +++ b/packages/app/src/App.jsx @@ -148,6 +148,9 @@ class App extends React.Component { await this.sessionController.logout() }, "session.created": async () => { + app.eventBus.emit("layout.animations.fadeOut") + app.eventBus.emit("layout.render.lock") + await this.flushState() await this.initialization() @@ -155,6 +158,9 @@ class App extends React.Component { if (window.location.pathname === "/login") { app.setLocation("/") } + + app.eventBus.emit("layout.render.unlock") + app.eventBus.emit("layout.animations.fadeIn") }, "session.destroyed": async () => { await this.flushState()