fixed intro movement, select not working yet

This commit is contained in:
Priec
2025-08-27 01:34:56 +02:00
parent d641ad1bbb
commit e5db0334c0

View File

@@ -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 => {