diff --git a/codex-rs/tui/src/bottom_pane/mod.rs b/codex-rs/tui/src/bottom_pane/mod.rs index b9b05d55..384d8bf4 100644 --- a/codex-rs/tui/src/bottom_pane/mod.rs +++ b/codex-rs/tui/src/bottom_pane/mod.rs @@ -72,7 +72,7 @@ pub(crate) struct BottomPaneParams { } impl BottomPane { - const BOTTOM_PAD_LINES: u16 = 2; + const BOTTOM_PAD_LINES: u16 = 1; pub fn new(params: BottomPaneParams) -> Self { let enhanced_keys_supported = params.enhanced_keys_supported; Self { @@ -648,28 +648,15 @@ mod tests { "expected Working header on top row: {top:?}" ); - // Next row (spacer) is blank, and bottom two rows are blank padding - let mut spacer = String::new(); + // Last row should be blank padding; the row above should generally contain composer content. let mut r_last = String::new(); - let mut r_last2 = String::new(); for x in 0..area.width { - // Spacer row immediately below the status header lives at y=2. - spacer.push(buf[(x, 2)].symbol().chars().next().unwrap_or(' ')); r_last.push(buf[(x, height - 1)].symbol().chars().next().unwrap_or(' ')); - r_last2.push(buf[(x, height - 2)].symbol().chars().next().unwrap_or(' ')); } - assert!( - spacer.trim().is_empty(), - "expected spacer line blank: {spacer:?}" - ); assert!( r_last.trim().is_empty(), "expected last row blank: {r_last:?}" ); - assert!( - r_last2.trim().is_empty(), - "expected second-to-last row blank: {r_last2:?}" - ); } #[test] diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_exec.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_exec.snap index 9a205be1..9173b726 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_exec.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_exec.snap @@ -1,5 +1,6 @@ --- source: tui/src/chatwidget/tests.rs +assertion_line: 728 expression: terminal.backend() --- "? Codex wants to run echo hello world " @@ -10,4 +11,3 @@ expression: terminal.backend() "▌ Yes Always No No, provide feedback " "▌ Approve and run the command " " " -" " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_patch.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_patch.snap index 2e79127f..e449f0c5 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_patch.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__approval_modal_patch.snap @@ -1,6 +1,6 @@ --- source: tui/src/chatwidget/tests.rs -assertion_line: 690 +assertion_line: 763 expression: terminal.backend() --- "The model wants to apply changes " @@ -11,4 +11,3 @@ expression: terminal.backend() "▌ Yes No No, provide feedback " "▌ Approve and apply the changes " " " -" " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h2.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h2.snap index 48e6154e..bf8bd08b 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h2.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h2.snap @@ -1,5 +1,6 @@ --- source: tui/src/chatwidget/tests.rs +assertion_line: 779 expression: terminal.backend() --- "▌ Ask Codex to do anything " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h3.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h3.snap index 7ab4159a..11047736 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h3.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_idle_h3.snap @@ -1,7 +1,8 @@ --- source: tui/src/chatwidget/tests.rs +assertion_line: 779 expression: terminal.backend() --- +" " "▌ Ask Codex to do anything " " " -" " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h2.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h2.snap index 48e6154e..7f84982a 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h2.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h2.snap @@ -1,5 +1,6 @@ --- source: tui/src/chatwidget/tests.rs +assertion_line: 807 expression: terminal.backend() --- "▌ Ask Codex to do anything " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h3.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h3.snap index c77477a0..dbe9cbed 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h3.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__chat_small_running_h3.snap @@ -1,5 +1,6 @@ --- source: tui/src/chatwidget/tests.rs +assertion_line: 807 expression: terminal.backend() --- " " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_active.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_active.snap index 79b55e26..c598dbe1 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_active.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_active.snap @@ -1,6 +1,6 @@ --- source: tui/src/chatwidget/tests.rs -assertion_line: 806 +assertion_line: 878 expression: terminal.backend() --- " " @@ -9,4 +9,3 @@ expression: terminal.backend() "▌ Ask Codex to do anything " " ⏎ send Ctrl+J newline Ctrl+T transcript Ctrl+C quit " " " -" " diff --git a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_and_approval_modal.snap b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_and_approval_modal.snap index 5cd47524..3abc8c7b 100644 --- a/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_and_approval_modal.snap +++ b/codex-rs/tui/src/chatwidget/snapshots/codex_tui__chatwidget__tests__status_widget_and_approval_modal.snap @@ -1,5 +1,6 @@ --- source: tui/src/chatwidget/tests.rs +assertion_line: 851 expression: terminal.backend() --- "? Codex wants to run echo 'hello world' " @@ -10,4 +11,3 @@ expression: terminal.backend() "▌ Yes Always No No, provide feedback " "▌ Approve and run the command " " " -" "