diff options
Diffstat (limited to 'addons/web_editor/static/src/js/editor')
| -rw-r--r-- | addons/web_editor/static/src/js/editor/summernote.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/web_editor/static/src/js/editor/summernote.js b/addons/web_editor/static/src/js/editor/summernote.js index f1145c8d8c1..290918a9563 100644 --- a/addons/web_editor/static/src/js/editor/summernote.js +++ b/addons/web_editor/static/src/js/editor/summernote.js @@ -2077,8 +2077,9 @@ eventHandler.modules.editor.currentStyle = function (target) { if (!styleInfo.image || !dom.isEditable(styleInfo.image)) { styleInfo.image = undefined; var r = range.create(); - if (r) + if (r && r.isOnEditable()) { styleInfo.image = r.isOnImg(); + } } // Fix when the target is a link: the text-align buttons state should // indicate the alignment of the link in the parent, not the text inside |
