fix: TUI overflow, scrollable header, tool output, git branch
- Fixed: chat content no longer overflows past allocated height. Lines are measured for physical width and hard-truncated to exactly the chat area height. Input + status bar always visible. - Header scrolls with chat (not pinned), only input/status fixed - Git branch in status bar (green, via git rev-parse) - Alt screen mode — terminal scrollback disabled - Mouse wheel + PgUp/PgDown scroll within TUI - New EventToolResult: tool output as dimmed indented block - Separator lines above/below input, no status bar backgrounds
This commit is contained in:
@@ -16,6 +16,7 @@ const (
|
||||
EventToolCallStart
|
||||
EventToolCallDelta
|
||||
EventToolCallDone
|
||||
EventToolResult // tool execution output
|
||||
EventUsage
|
||||
EventError
|
||||
)
|
||||
@@ -32,6 +33,8 @@ func (et EventType) String() string {
|
||||
return "tool_call_delta"
|
||||
case EventToolCallDone:
|
||||
return "tool_call_done"
|
||||
case EventToolResult:
|
||||
return "tool_result"
|
||||
case EventUsage:
|
||||
return "usage"
|
||||
case EventError:
|
||||
@@ -56,6 +59,10 @@ type Event struct {
|
||||
ArgDelta string // partial JSON fragment
|
||||
Args json.RawMessage // complete arguments (on Done)
|
||||
|
||||
// ToolResult: tool name + output
|
||||
ToolName string
|
||||
ToolOutput string
|
||||
|
||||
// Usage
|
||||
Usage *message.Usage
|
||||
|
||||
|
||||
Reference in New Issue
Block a user