summaryrefslogtreecommitdiff
path: root/addons/website/static/src
diff options
context:
space:
mode:
authorChristophe Matthieu <chm@odoo.com>2015-04-09 16:09:07 +0200
committerChristophe Matthieu <chm@odoo.com>2015-04-09 16:09:07 +0200
commit368ea9d614ce00bb5d3f6bb66e2f28448fcea0a5 (patch)
treeab0e8b9092bcec58684a47a3c9bffb1ce504f3d7 /addons/website/static/src
parentc35f8a7b483ab2e3deb44785c6864969ace51f1b (diff)
[FIX] website: summernote: don't need to add a white space when delete a selection if the string is not fully erase
Diffstat (limited to 'addons/website/static/src')
-rw-r--r--addons/website/static/src/js/summernote.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/website/static/src/js/summernote.js b/addons/website/static/src/js/summernote.js
index 955fe8843a4..282a06623aa 100644
--- a/addons/website/static/src/js/summernote.js
+++ b/addons/website/static/src/js/summernote.js
@@ -581,7 +581,7 @@ define(['summernote/editing/Editor', 'summernote/summernote'], function (Editor)
}
eo = so;
- if(!dom.isBR(sc) && !sc.textContent.match(/\S|\u00A0/)) {
+ if(!dom.isBR(sc) && !sc.textContent.match(/\S|\u00A0/) && !dom.isText(dom.hasContentBefore(sc)) && !dom.isText(dom.hasContentAfter(sc))) {
ancestor = dom.node(sc);
var text = document.createTextNode('\u00A0');
$(sc).before(text);