-
- Downloads
[FIX] web_editor: fix replacing media leaving unexpected elements
Previously, changing a media from a video/icon/document to a different type would leave empty elements in the DOM, this is because summernote's range API `range.insertNode` function deletes the content but not the structure (HTML elements). This commit fixes that by using jQuery's replaceWith method instead of summernote's insertNode when a media was found, and only using summernote in case no media was found (eg. a text range). Part of https://github.com/odoo/odoo/pull/64234 X-original-commit: 63f80995
Loading
Please register or sign in to comment