Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e975d4a commit 27fad39Copy full SHA for 27fad39
1 file changed
internal/ui/ai/ai.go
@@ -924,9 +924,8 @@ func (m *Model) handleOverlayKey(msg tea.KeyMsg) tea.Cmd {
924
case "enter":
925
if m.overlayCursor >= 0 && m.overlayCursor < len(m.overlayFiltered) {
926
item := m.overlayFiltered[m.overlayCursor]
927
- val := m.textarea.Value()
928
- m.textarea.SetValue(val + string(m.overlayType) + item + " ")
929
- m.textarea.SetCursor(len(m.textarea.Value()))
+ // Insert at the textarea cursor (where @ / # was pressed), not at EOF.
+ m.textarea.InsertString(string(m.overlayType) + item + " ")
930
}
931
m.showOverlay = false
932
case "backspace":
0 commit comments