mirror of
https://github.com/sst/opencode.git
synced 2025-08-04 13:30:52 +00:00
fix(tui): input feels laggy
This commit is contained in:
parent
a300bfaccb
commit
261e76e0a3
2 changed files with 35 additions and 37 deletions
|
@ -1161,8 +1161,6 @@ func (m Model) Update(msg tea.Msg) (Model, tea.Cmd) {
|
|||
}
|
||||
|
||||
var cmd tea.Cmd
|
||||
cmds = append(cmds, cmd)
|
||||
|
||||
newRow, newCol := m.cursorLineNumber(), m.col
|
||||
m.virtualCursor, cmd = m.virtualCursor.Update(msg)
|
||||
if (newRow != oldRow || newCol != oldCol) && m.virtualCursor.Mode() == cursor.CursorBlink {
|
||||
|
@ -1171,7 +1169,6 @@ func (m Model) Update(msg tea.Msg) (Model, tea.Cmd) {
|
|||
}
|
||||
cmds = append(cmds, cmd)
|
||||
|
||||
m.SetHeight(m.ContentHeight())
|
||||
return m, tea.Batch(cmds...)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue