summaryrefslogtreecommitdiff
path: root/addons/web_editor/static/src/js/rte.summernote.js
diff options
context:
space:
mode:
authorOlivier Dony <odo@openerp.com>2017-06-01 00:15:27 +0200
committerOlivier Dony <odo@openerp.com>2017-06-01 00:15:27 +0200
commitb9e220726730e2e0c25dae9952fa90e783fadc16 (patch)
treec083daa90cfa91548a775b53a14c3ededdaa10a6 /addons/web_editor/static/src/js/rte.summernote.js
parentbb438a29354048be36fe973cd4eba11cee03ed26 (diff)
parent7e44444878760ca44cf1b22bf05d77e26c477cab (diff)
[MERGE] Forward-port 10.0 up to 7e44444878760ca44cf1b22bf05d77e26c477cab
Diffstat (limited to 'addons/web_editor/static/src/js/rte.summernote.js')
-rw-r--r--addons/web_editor/static/src/js/rte.summernote.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/addons/web_editor/static/src/js/rte.summernote.js b/addons/web_editor/static/src/js/rte.summernote.js
index 60c096603d8..4ab1e7bed06 100644
--- a/addons/web_editor/static/src/js/rte.summernote.js
+++ b/addons/web_editor/static/src/js/rte.summernote.js
@@ -511,7 +511,12 @@ function prettify_html(html) {
level--;
}
- result += token.trim().replace(/\s+/, ' ');
+ // don't trim inline content (which could change appearance)
+ if (!inline) {
+ token = token.trim();
+ }
+
+ result += token.replace(/\s+/, ' ');
if (inline_level > level) {
result += '\n';