diff --git a/addons/web_editor/static/src/js/backend/convert_inline.js b/addons/web_editor/static/src/js/backend/convert_inline.js index 98ca47c9d36..6753fae8ff3 100644 --- a/addons/web_editor/static/src/js/backend/convert_inline.js +++ b/addons/web_editor/static/src/js/backend/convert_inline.js @@ -495,7 +495,9 @@ function formatTables($editable) { } // Ensure a tbody in every table and cancel its default style. for (const table of $editable.find('table:not(:has(tbody))')) { - $(table).contents().wrap('
'); + const $contents = $(table).contents(); + $(table).prepend(''); + $(table.firstChild).append($contents); } // Children will only take 100% height if the parent has a height property. for (const node of $editable.find('*').filter((i, n) => (