diff options
| author | Nicolas Lempereur <nle@odoo.com> | 2017-05-22 10:04:19 +0200 |
|---|---|---|
| committer | qsm-odoo <qsm@odoo.com> | 2018-05-11 11:06:05 +0200 |
| commit | 1dae7ea1d660dca32e7261c5c0ed710e5541c641 (patch) | |
| tree | 240f391b50e7044e44b854c455afc054f3557776 | |
| parent | 4431c8c843f28f9229a5cacb8b786b2b8303fd6b (diff) | |
[FIX] web_editor: inline space in source code
Backport of 57f7c681062f07002312e91d79d02b2b1b59d9fe
| -rw-r--r-- | addons/web_editor/static/src/js/rte.summernote.js | 7 |
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 25d966b354d..123b5560424 100644 --- a/addons/web_editor/static/src/js/rte.summernote.js +++ b/addons/web_editor/static/src/js/rte.summernote.js @@ -485,7 +485,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'; |
