From 0bda80c57d95c748fba11146bb69c9a12a49bec7 Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Wed, 19 Aug 2020 10:32:24 +0100 Subject: [PATCH] Consider tab completions as modifications for editing purposes to unlock sending --- src/components/views/rooms/BasicMessageComposer.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/views/rooms/BasicMessageComposer.tsx b/src/components/views/rooms/BasicMessageComposer.tsx index 58dd82341e..6024f272ec 100644 --- a/src/components/views/rooms/BasicMessageComposer.tsx +++ b/src/components/views/rooms/BasicMessageComposer.tsx @@ -93,7 +93,7 @@ interface IProps { initialCaret?: DocumentOffset; onChange(); - onPaste(event: ClipboardEvent, model: EditorModel): boolean; + onPaste?(event: ClipboardEvent, model: EditorModel): boolean; } interface IState { @@ -554,10 +554,12 @@ export default class BasicMessageEditor extends React.Component } private onAutoCompleteConfirm = (completion: ICompletion) => { + this.modifiedFlag = true; this.props.model.autoComplete.onComponentConfirm(completion); }; private onAutoCompleteSelectionChange = (completion: ICompletion, completionIndex: number) => { + this.modifiedFlag = true; this.props.model.autoComplete.onComponentSelectionChange(completion); this.setState({completionIndex}); };