We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ae9c0a6 commit b8cfdfbCopy full SHA for b8cfdfb
src/editor.js
@@ -1325,7 +1325,10 @@ export class OdooEditor extends EventTarget {
1325
this._computeHistoryCursor();
1326
1327
const selection = this.document.defaultView.getSelection();
1328
- this._updateToolbar(!selection.isCollapsed);
+ const isSelectionInEditable = !selection.isCollapsed &&
1329
+ this.editable.contains(selection.anchorNode) &&
1330
+ this.editable.contains(selection.focusNode);
1331
+ this._updateToolbar(isSelectionInEditable);
1332
1333
if (this._currentMouseState === 'mouseup') {
1334
this._fixFontAwesomeSelection();
0 commit comments