From f53e0da42d9395292333e4fa5bc4d66dc1cea3aa Mon Sep 17 00:00:00 2001 From: Antoine Guenet Date: Mon, 8 Aug 2022 15:32:18 +0000 Subject: [PATCH] [FIX] web_editor: properly convert heights of masonry cells Masonry's top inner container needs to have a 100% height to properly size its contents. task-2925779 X-original-commit: 717672d56958915084d98d69246c9e7e986fabab Part-of: odoo/odoo#97962 --- addons/web_editor/static/src/js/backend/convert_inline.js | 3 +++ 1 file changed, 3 insertions(+) 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 982b34ff410..15526aa214c 100644 --- a/addons/web_editor/static/src/js/backend/convert_inline.js +++ b/addons/web_editor/static/src/js/backend/convert_inline.js @@ -122,6 +122,9 @@ function bootstrapToTable($editable) { // These containers from the mass mailing masonry snippet require full // height contents, which is only possible if the table itself has a set // height. We also need to restyle it because of the change in structure. + for(const masonryTopInnerContainer of editable.querySelectorAll('.s_masonry_block > .container')) { + masonryTopInnerContainer.style.setProperty('height', '100%'); + } for (const masonryGrid of editable.querySelectorAll('.o_masonry_grid_container')) { masonryGrid.style.setProperty('padding', 0); for (const fakeTable of [...masonryGrid.children].filter(c => c.classList.contains('o_fake_table'))) {