From e466fdbaf70cc3e7d03beafbe26377ca1dcfa39f Mon Sep 17 00:00:00 2001 From: Antoine Guenet Date: Fri, 12 Nov 2021 13:54:29 +0000 Subject: [PATCH] [FIX] web_editor: properly convert overflowing row closes odoo/odoo#80621 X-original-commit: 5a1d94d29004f0f0ddd81c25020a90083d6b8bea Signed-off-by: David Monjoie (dmo) --- addons/web_editor/static/src/js/backend/convert_inline.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 627c3a8e2af..0ff006e5025 100644 --- a/addons/web_editor/static/src/js/backend/convert_inline.js +++ b/addons/web_editor/static/src/js/backend/convert_inline.js @@ -478,13 +478,13 @@ function bootstrapToTable($editable) { if (gridIndex + columnSize < 12) { $currentCol = grid[gridIndex]; _applyColspanToGridElement($currentCol, columnSize); - gridIndex += columnSize; if (columnIndex === $bootstrapColumns.length - 1) { // We handled all the columns but there is still space // in the row. Insert the columns and fill the row. grid[gridIndex].attr('colspan', 12 - gridIndex); $currentRow.append(...grid.filter(td => td.attr('colspan'))); } + gridIndex += columnSize; } else if (gridIndex + columnSize === 12) { // Finish the row. $currentCol = grid[gridIndex];