We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5aafab1 commit 500cea5Copy full SHA for 500cea5
packages/tui/internal/tui/tui.go
@@ -515,7 +515,12 @@ func (a Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
515
Parts []opencode.Part `json:"parts"`
516
}
517
json.Unmarshal((msg.Body), &body)
518
- a.editor.SetValueWithAttachments(strings.TrimRight(a.editor.Value(), " ") + " " + body.Text + " ")
+ existing := a.editor.Value()
519
+ text := body.Text
520
+ if existing != "" && !strings.HasSuffix(existing, " ") {
521
+ text = " " + text
522
+ }
523
+ a.editor.SetValueWithAttachments(existing + text + " ")
524
default:
525
break
526
0 commit comments