From 8405e88cc5f652b37693c2e0223166144a8797ee Mon Sep 17 00:00:00 2001 From: Rusty Pickle Date: Thu, 1 Oct 2026 20:15:23 +0600 Subject: [PATCH 1/2] Fix table lerp reset on right key press --- tui/src/key_checker/key_handler.rs | 35 ++++++++++++++---------------- 1 file changed, 16 insertions(+), 19 deletions(-) diff --git a/tui/src/key_checker/key_handler.rs b/tui/src/key_checker/key_handler.rs index 604b0519..71f126d9 100644 --- a/tui/src/key_checker/key_handler.rs +++ b/tui/src/key_checker/key_handler.rs @@ -613,11 +613,9 @@ impl<'a> InputKeyHandler<'a> { CurrentUi::AddTx => self.add_tx_data.move_index_right(self.add_tx_tab), CurrentUi::Search => { self.search_data.move_index_right(self.search_tab); - self.lerp_state.clear_lerp(SEARCH_TABLE_ID); } CurrentUi::Recurring => { self.recurring_data.move_index_right(self.recurring_tab); - self.lerp_state.clear_lerp(RECURRING_TABLE_ID); } CurrentUi::Chart => { if !*self.chart_hidden_mode { @@ -662,26 +660,20 @@ impl<'a> InputKeyHandler<'a> { } SummaryTab::Table => {} } - - self.lerp_state.clear_lerp(SUMMARY_TABLE_ID); } } - CurrentUi::Activity => { - match self.activity_tab { - ActivityTab::Years => { - self.activity_months.set_index_zero(); - self.activity_years.next_yearly(); - self.reload_activity_table()?; - } - ActivityTab::Months => { - self.activity_months.next(); - self.reload_activity_table()?; - } - ActivityTab::List => {} + CurrentUi::Activity => match self.activity_tab { + ActivityTab::Years => { + self.activity_months.set_index_zero(); + self.activity_years.next_yearly(); + self.reload_activity_table()?; } - - self.lerp_state.clear_lerp(ACTIVITY_TABLE_ID); - } + ActivityTab::Months => { + self.activity_months.next(); + self.reload_activity_table()?; + } + ActivityTab::List => {} + }, CurrentUi::Initial => {} } @@ -2597,6 +2589,8 @@ impl InputKeyHandler<'_> { *self.summary_view = summary_view; } + self.lerp_state.clear_lerp(SUMMARY_TABLE_ID); + Ok(()) } @@ -2644,6 +2638,8 @@ impl InputKeyHandler<'_> { *self.activity_table = TableData::new(self.activity_view.get_activity_table()); self.activity_table.state = old_table_position; + self.lerp_state.clear_lerp(ACTIVITY_TABLE_ID); + Ok(()) } @@ -2660,6 +2656,7 @@ impl InputKeyHandler<'_> { .collect(); *self.recurring_table = TableData::new(items); self.recurring_table.state = old_table_position; + self.lerp_state.clear_lerp(RECURRING_TABLE_ID); Ok(()) } From 57572b2fbb6f175b2e51c6375b5d8a1a56d52207 Mon Sep 17 00:00:00 2001 From: Rusty Pickle Date: Fri, 2 Oct 2026 18:19:01 +0600 Subject: [PATCH 2/2] Bump version --- Cargo.lock | 8 ++++---- app/Cargo.toml | 2 +- db/Cargo.toml | 2 +- shared/Cargo.toml | 2 +- tui/Cargo.toml | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 27ddeb98..a3197e6f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2172,7 +2172,7 @@ dependencies = [ [[package]] name = "rex-app" -version = "0.3.0" +version = "0.3.1" dependencies = [ "anyhow", "chrono", @@ -2187,7 +2187,7 @@ dependencies = [ [[package]] name = "rex-db" -version = "0.3.0" +version = "0.3.1" dependencies = [ "anyhow", "chrono", @@ -2201,14 +2201,14 @@ dependencies = [ [[package]] name = "rex-shared" -version = "0.3.0" +version = "0.3.1" dependencies = [ "chrono", ] [[package]] name = "rex-tui" -version = "0.3.0" +version = "0.3.1" dependencies = [ "anyhow", "atty", diff --git a/app/Cargo.toml b/app/Cargo.toml index 04a77a1f..bac3c68e 100644 --- a/app/Cargo.toml +++ b/app/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rex-app" -version = "0.3.0" +version = "0.3.1" edition = "2024" description = "Core functionality for Rex" homepage = "https://github.com/TheRustyPickle/Rex" diff --git a/db/Cargo.toml b/db/Cargo.toml index ca281834..7ab2c92c 100644 --- a/db/Cargo.toml +++ b/db/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rex-db" -version = "0.3.0" +version = "0.3.1" edition = "2024" description = "Rex database models using diesel" homepage = "https://github.com/TheRustyPickle/Rex" diff --git a/shared/Cargo.toml b/shared/Cargo.toml index 9d15b52d..1655d3af 100644 --- a/shared/Cargo.toml +++ b/shared/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rex-shared" -version = "0.3.0" +version = "0.3.1" edition = "2024" description = "Shared code for Rex" homepage = "https://github.com/TheRustyPickle/Rex" diff --git a/tui/Cargo.toml b/tui/Cargo.toml index 986eb785..957acec2 100644 --- a/tui/Cargo.toml +++ b/tui/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rex-tui" -version = "0.3.0" +version = "0.3.1" edition = "2024" description = "A TUI app for managing Incomes and Expenses." readme = "../README.md"