From 33e54a4febca735e41eb9c09a34a73f12006cfbc Mon Sep 17 00:00:00 2001 From: Rodolpho Lima Date: Thu, 2 Mar 2023 11:25:08 +0000 Subject: [PATCH] [FIX] mass_mailing: deactivate snippet overlay on codeview Before this commit, when toggling the codeview in mass_mailing (debug=1), the overlay that highlights the selected snippet is not deactivated. This results on the blue rectangle being seen on the codeview when the mouse cursor is hovered over the corresponding position. This commit deactivates the current snippet overlay when the codeview is toggled. closes odoo/odoo#115299 X-original-commit: ec8070adb38d092d743679c2dd30872424d46e9d Signed-off-by: David Monjoie (dmo) --- addons/mass_mailing/static/src/js/mass_mailing_html_field.js | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/mass_mailing/static/src/js/mass_mailing_html_field.js b/addons/mass_mailing/static/src/js/mass_mailing_html_field.js index ec769a058b5..65a96dbb685 100644 --- a/addons/mass_mailing/static/src/js/mass_mailing_html_field.js +++ b/addons/mass_mailing/static/src/js/mass_mailing_html_field.js @@ -244,6 +244,7 @@ export class MassMailingHtmlField extends HtmlField { } else { $codeview.val(this.wysiwyg.getValue()); } + this.wysiwyg.snippetsMenu.activateSnippet(false); this.onIframeUpdated(); }); const $previewBtn = $snippetsSideBar.find('.o_mobile_preview_btn');