Skip to content

Commit

Permalink
Don’t send update events when there are no steps involved
Browse files Browse the repository at this point in the history
  • Loading branch information
bastianallgeier committed Feb 13, 2025
1 parent 4525823 commit ef02976
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions panel/src/components/Forms/Input/WriterInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,12 @@ export default {
return;
}
// if no steps are recorded, this is a selection change
// and we don't need to update the content
if (payload.transaction.steps.length === 0) {
return;
}
// compare documents to avoid minor HTML differences
// to cause unwanted updates
const jsonNew = JSON.stringify(this.editor.getJSON());
Expand Down

0 comments on commit ef02976

Please sign in to comment.