mirror of
https://github.com/vector-im/element-web.git
synced 2026-05-05 20:26:19 +02:00
Balance out the throttle
This commit is contained in:
parent
6c4c581f8f
commit
ae8b75214a
@ -83,7 +83,8 @@ export default class RoomSearch extends React.PureComponent<IProps, IState> {
|
||||
|
||||
// it wants this at the top of the file, but we know better
|
||||
// tslint:disable-next-line
|
||||
private onSearchUpdated = throttle(() => {
|
||||
private onSearchUpdated = throttle(
|
||||
() => {
|
||||
// We can't use the state variable because it can lag behind the input.
|
||||
// The lag is most obvious when deleting/clearing text with the keyboard.
|
||||
this.props.onQueryUpdate(this.inputRef.current.value);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user