feat(tui): W puts the pane layout back

Hiding panes with w and zooming with z had no way back short of
pressing each hidden pane's number and Esc. W shows every pane and
leaves zoom in one go, and the shortcut bar offers it only while there
is a layout to reset.
This commit is contained in:
Michel de Graaf
2026-09-08 11:24:31 +02:00
parent 995fe98c01
commit 1fcde0a78b
5 changed files with 42 additions and 11 deletions
+5 -1
View File
@@ -1,5 +1,5 @@
use super::MainTui;
use crate::models::{CommandBarMode, FocusedPane, LogView};
use crate::models::{CommandBarMode, FocusedPane, LogView, PaneLayout};
use crate::ui::page_of;
use crate::ui::panes::{
InfoSubject, name_end_offset, query_end_offset, selected_transfer,
@@ -100,6 +100,10 @@ impl MainTui {
self.state.hide_focused_pane();
return;
}
KeyCode::Char('W') => {
self.state.layout = PaneLayout::default();
return;
}
KeyCode::Esc if self.state.layout.zoomed => {
self.state.layout.zoomed = false;
return;