diff --git a/addons/web_editor/static/src/js/editor/odoo-editor/src/OdooEditor.js b/addons/web_editor/static/src/js/editor/odoo-editor/src/OdooEditor.js index c94e7c6592e..76e5666e961 100644 --- a/addons/web_editor/static/src/js/editor/odoo-editor/src/OdooEditor.js +++ b/addons/web_editor/static/src/js/editor/odoo-editor/src/OdooEditor.js @@ -1238,8 +1238,10 @@ export class OdooEditor extends EventTarget { focusNode, computedSelection.focusOffset, ); + return true; } } + return false; } historySetSelection(step) { this.deselectTable(); @@ -2400,7 +2402,7 @@ export class OdooEditor extends EventTarget { focusNode: sel.focusNode, focusOffset: sel.focusOffset, }; - if (!sel.isCollapsed && this.isSelectionInEditable(sel)) { + if (this.isSelectionInEditable(sel)) { this._latestComputedSelectionInEditable = this._latestComputedSelection; } return this._latestComputedSelection;