Merge pull request #3391 from matrix-org/bwindels/cider-format-history

New composer: ensure undo history is persisted before applying formatting
This commit is contained in:
Bruno Windels 2019-09-06 09:28:18 +00:00 committed by GitHub
commit 5014b606db
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 3 deletions

View file

@ -454,6 +454,7 @@ export default class BasicMessageEditor extends React.Component {
if (range.length === 0) {
return;
}
this.historyManager.ensureLastChangesPushed(this.props.model);
switch (action) {
case "bold":
formatInline(range, "**");