[BUG] Input box overflows past the bottom of the screen instead of scrolling when the todo/task widget is visible — typed text and cursor become invisible
What's Wrong?
When the todo/task widget is visible (any tasks in the task list), typing a long
message makes the input box grow past the bottom edge of the terminal instead
of capping its height and scrolling. The rendered box keeps showing the head of
the message; the tail — and the cursor — are pushed below the last terminal row,
so you keep typing without being able to see what you're typing. The terminal
cursor parks on the last row, moving over earlier text that never updates.
With no tasks in the task list, the same input caps at a few rows and correctly
scrolls to follow the cursor. Toggling the widget off and on (Ctrl+T) flips the
bug off and on deterministically with the same input content:
- widget off → box re-lays out, tail + cursor visible, scrolls correctly
- widget on → tail invisible again, cursor below the bottom row
Looks like the input box's max-height budget doesn't subtract the widget's rows
(and possibly other footer chrome — statusline, background-agent roster), so the
box + cursor overflow the screen once the input exceeds the remaining space.
What Should Happen?
The input box should cap its visible height to the space actually remaining and
scroll its viewport so the cursor line is always visible — same behavior as when
no task widget is shown.
Steps to Reproduce
Deterministic, reproduced in a clean tmux pane (tmux -f /dev/null, 89x45,
macOS, v2.1.222):
claude "Create 6 tasks in the task list titled Task A through Task F"— so
the todo widget renders above the input box.
- Type continuously (real typing, not paste — e.g. ~250 five-char words).
- Once the input exceeds the rows left under the widget, the bottom border and
statusline disappear off-screen and newly typed text is no longer visible.
tmux capture-pane shows the last row holding mid-message text while the
cursor sits at the bottom row of the pane; a marker string typed at the end
(TAIL-MARKER-1) appears nowhere on screen.
- Press Ctrl+T (hide todo widget) → full re-layout, tail + marker visible,
further typing scrolls correctly. Ctrl+T again (show widget) → immediately
broken again.
Capture excerpt at step 3 (pane is 89x45; these are the last visible rows —
input continues to v250 + marker below the screen edge):
❯ v001 v002 v003 v004 v005 v006 v007 v008 v009 v010 v011 v012 v013 v014 v015 v016 v017
...
v188 v189 v190 v191 v192 v193 v194 v195 v196 v197 v198 v199 v200 v201 v202 v203 v204
(cursor reported at pane row 44 — the v188…v204 row — while actual input end is
v250 TAIL-MARKER-1)
First hit in a real session: long /morning output, 8-row task widget, custom
multi-row statusline, and a background-agent roster below the input — i.e. lots
of footer chrome, which makes the overflow trigger after fewer typed rows.
Environment
- Platform: darwin (macOS 25.5.0)
- Terminal: iTerm2 + tmux (reproduced with a config-free tmux server; not yet
tested outside tmux)
- Version: 2.1.222 (also observed on a session launched the same day)
Workaround
Ctrl+T twice (hide + reshow the todo widget) re-lays-out and restores cursor
visibility; composing long messages with the widget hidden avoids it entirely.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗