mirror of
https://github.com/Maks1mS/bubbles.git
synced 2024-12-25 23:14:41 +03:00
fix(textarea): ActionChange + e should also delete end of word
This commit is contained in:
parent
907f5e659d
commit
3e1a14200c
@ -437,7 +437,7 @@ func (m *Model) normalUpdate(msg tea.Msg) tea.Cmd {
|
|||||||
return executeCmd(*m.command)
|
return executeCmd(*m.command)
|
||||||
case "e", "E":
|
case "e", "E":
|
||||||
end := m.findWordEndRight(max(m.command.Count, 1), msg.String() == "E")
|
end := m.findWordEndRight(max(m.command.Count, 1), msg.String() == "E")
|
||||||
if m.command.Action == ActionDelete {
|
if m.command.Action == ActionDelete || m.command.Action == ActionChange {
|
||||||
end.Col = min(end.Col+1, len(m.value[end.Row]))
|
end.Col = min(end.Col+1, len(m.value[end.Row]))
|
||||||
}
|
}
|
||||||
m.command.Range = Range{
|
m.command.Range = Range{
|
||||||
|
Loading…
Reference in New Issue
Block a user