Skip to content

TUI - each notification in a stack should use its own space - #4995

Open
krissetto wants to merge 1 commit into
docker:mainfrom
krissetto:notification-stack-bounds
Open

krissetto wants to merge 1 commit into
docker:mainfrom
krissetto:notification-stack-bounds

Conversation

@krissetto

Copy link
Copy Markdown
Contributor

Stacks of notifications were occupying the width of the widest message in the stack, and the height of the stack itself.

This means that if a short notification had a long one under it, the space between the long one and the short one was occupied by empty space that would cover anything underneath it (e.g. chat output)

This PR makes each notification use only the space it needs, regardless of the composition of the stack

Signed-off-by: Christopher Petito <chrisjpetito@gmail.com>
Copilot AI balanced review requested due to automatic review settings November 21, 2026 23:19

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

There are no active review issues blocking approval of the notification-layering change.

No open issues 🎉

What changed in this PR

This PR renders each TUI notification as a separate layer so shorter messages no longer obscure content beside them.

Changes:

  • Give each notification its own clipped rendering and hit-test bounds.
  • Prevent clicks from reaching controls covered by visible notifications, while preserving interaction through gaps.
  • Add regression coverage for transcript visibility, resize controls, image clipping, and lean mode.
File Description
pkg/​tui/​tui.go Compose individual notification layers and guard notification click handling.
pkg/​tui/​sidebar_resize_test.go Verify resize guides remain visible through notification gaps.
pkg/​tui/​notification_avoidance_test.go Test gap visibility and interaction, lean mode, and Kitty image clipping.
pkg/​tui/​components/​notification/​notification.go Render separate notification layers and share clipped geometry with hit testing.
pkg/​tui/​components/​notification/​notification_test.go Update layer assertions and test terminal-edge clipping.

Review effort: Balanced

@aheritier aheritier added area/tui For features/issues/fixes related to the TUI kind/feat PR adds a new feature (maps to feat:). Use on PRs only. labels Nov 21, 2026
@krissetto
krissetto marked this pull request as ready for review November 21, 2026 23:31
@krissetto
krissetto requested a review from a team as a code owner November 21, 2026 23:31
@krissetto
krissetto enabled auto-merge November 21, 2026 23:33

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/tui For features/issues/fixes related to the TUI kind/feat PR adds a new feature (maps to feat:). Use on PRs only.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants