From e5db0334c0a4da4ea05116193b07ee10ec036820 Mon Sep 17 00:00:00 2001 From: Priec Date: Wed, 27 Aug 2025 01:34:56 +0200 Subject: [PATCH] fixed intro movement, select not working yet --- client/src/ui/handlers/ui.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/client/src/ui/handlers/ui.rs b/client/src/ui/handlers/ui.rs index 6d38a77..ad78403 100644 --- a/client/src/ui/handlers/ui.rs +++ b/client/src/ui/handlers/ui.rs @@ -342,7 +342,14 @@ pub async fn run_ui() -> Result<()> { if let Some(active_view) = buffer_state.get_active_view() { match active_view { - AppView::Intro => router.navigate(Page::Intro(intro_state.clone())), + AppView::Intro => { + // Keep external intro_state in sync with the live Router state + if let Page::Intro(current) = &router.current { + intro_state = current.clone(); + } + // Navigate with the up-to-date state + router.navigate(Page::Intro(intro_state.clone())); + } AppView::Login => router.navigate(Page::Login(login_state.clone())), AppView::Register => router.navigate(Page::Register(register_state.clone())), AppView::Admin => {