Merge branch 'develop' into travis/ft-sep1620/04-jitsi-hangup

This commit is contained in:
Travis Ralston 2020-09-29 10:20:02 -06:00
commit a5569303d1
9 changed files with 52 additions and 12 deletions

View file

@ -619,13 +619,14 @@ export default class BasicMessageEditor extends React.Component<IProps, IState>
}
private onFormatAction = (action: Formatting) => {
const range = getRangeForSelection(
this.editorRef.current,
this.props.model,
document.getSelection());
const range = getRangeForSelection(this.editorRef.current, this.props.model, document.getSelection());
// trim the range as we want it to exclude leading/trailing spaces
range.trim();
if (range.length === 0) {
return;
}
this.historyManager.ensureLastChangesPushed(this.props.model);
this.modifiedFlag = true;
switch (action) {