You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-07 10:46:24 +03:00
handle Escape properly
close autocomplete, and also replace with plain text part. also remove leftover logging
This commit is contained in:
@@ -26,6 +26,11 @@ export default class AutocompleteWrapperModel {
|
||||
|
||||
onEscape(e) {
|
||||
this._getAutocompleterComponent().onEscape(e);
|
||||
this._updateCallback({
|
||||
replacePart: new PlainPart(this._queryPart.text),
|
||||
replaceCaret: this._queryOffset,
|
||||
close: true,
|
||||
});
|
||||
}
|
||||
|
||||
onEnter() {
|
||||
@@ -37,12 +42,10 @@ export default class AutocompleteWrapperModel {
|
||||
}
|
||||
|
||||
onUpArrow() {
|
||||
console.log("onUpArrow");
|
||||
this._getAutocompleterComponent().onUpArrow();
|
||||
}
|
||||
|
||||
onDownArrow() {
|
||||
console.log("onDownArrow");
|
||||
this._getAutocompleterComponent().onDownArrow();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user