1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-07-31 13:44:28 +03:00

Fix autocomplete not resetting properly on message send (#10741)

This commit is contained in:
Michael Telatynski
2023-04-28 14:31:02 +01:00
committed by GitHub
parent 0d1020c66f
commit f819853cad
3 changed files with 49 additions and 13 deletions

View File

@ -21,7 +21,7 @@ import { Caret } from "../../src/editor/caret";
import { PillPart, Part, PartCreator } from "../../src/editor/parts";
import DocumentPosition from "../../src/editor/position";
class MockAutoComplete {
export class MockAutoComplete {
public _updateCallback;
public _partCreator;
public _completions;
@ -44,7 +44,7 @@ class MockAutoComplete {
});
if (matches.length === 1 && this._part && this._part.text.length > 1) {
const match = matches[0];
let pill;
let pill: PillPart;
if (match.resourceId[0] === "@") {
pill = this._partCreator.userPill(match.text, match.resourceId);
} else {