Update search when Backspace is received
This commit is contained in:
@@ -94,7 +94,11 @@ fn handle_message(state: State, control: Control) -> actor.Next(State, Control)
|
||||
|
||||
let content = case state.mode {
|
||||
Idle -> state.input.content
|
||||
Searching -> string.drop_end(state.input.content, 1)
|
||||
Searching -> {
|
||||
let updated = string.drop_end(state.input.content, 1)
|
||||
update_search(state.ui, "searching: " <> updated)
|
||||
updated
|
||||
}
|
||||
}
|
||||
actor.continue(State(..state, input: Input(..state.input, content:)))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user