mirror of
				https://github.com/Maks1mS/bubbles.git
				synced 2025-11-04 07:31:23 +03:00 
			
		
		
		
	Fix backspace keybinding
This commit is contained in:
		@@ -36,6 +36,8 @@ func Update(msg tea.Msg, m Model) (Model, tea.Cmd) {
 | 
			
		||||
	case tea.KeyMsg:
 | 
			
		||||
		switch msg.Type {
 | 
			
		||||
		case tea.KeyBackspace:
 | 
			
		||||
			fallthrough
 | 
			
		||||
		case tea.KeyDelete:
 | 
			
		||||
			if len(m.Value) > 0 {
 | 
			
		||||
				m.Value = m.Value[:m.pos-1] + m.Value[m.pos:]
 | 
			
		||||
				m.pos--
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user