summaryrefslogtreecommitdiff
path: root/addons/web_editor/static/src/js/widgets/widgets.js
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2018-06-15 13:27:17 +0200
committerChristophe Simonis <chs@odoo.com>2018-06-15 13:27:27 +0200
commit73652a0b196b51ec1f9a27880d0b398fb79bfca3 (patch)
tree04e741fefdbb859dffa66a4037da7777ea980476 /addons/web_editor/static/src/js/widgets/widgets.js
parent8a03563269c3dc55c9c7157494af51e2485f1a14 (diff)
parent50860317ccd2c1b44f873598858a3cff87fa7ea6 (diff)
[MERGE] forward port branch saas-11.3 up to 50860317ccd
Note: 1aacc962620982528a3dfc90d2c1dd0027359375 has been ignored and will be forward-ported later
Diffstat (limited to 'addons/web_editor/static/src/js/widgets/widgets.js')
-rw-r--r--addons/web_editor/static/src/js/widgets/widgets.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/addons/web_editor/static/src/js/widgets/widgets.js b/addons/web_editor/static/src/js/widgets/widgets.js
index ab8f166d221..d0df042fa82 100644
--- a/addons/web_editor/static/src/js/widgets/widgets.js
+++ b/addons/web_editor/static/src/js/widgets/widgets.js
@@ -1406,6 +1406,8 @@ var LinkDialog = Dialog.extend({
if (dom.ancestor(nodes[i], dom.isImg)) {
this.data.images.push(dom.ancestor(nodes[i], dom.isImg));
text += '[IMG]';
+ } else if (!is_link && nodes[i].nodeType === 1) {
+ // just use text nodes from listBetween
} else if (!is_link && i===0) {
text += nodes[i].textContent.slice(so, Infinity);
} else if (!is_link && i===nodes.length-1) {