Do not put empty row in edit layout if not necessary

This commit is contained in:
Alexandre Bodin 2019-08-13 15:25:19 +02:00
parent 6e48232c85
commit c54efe7bbb

View File

@ -154,6 +154,7 @@ function syncLayouts(configuration, schema) {
}
const appendToEditLayout = (layout = [], keysToAppend, schema) => {
if (keysToAppend.length === 0) return layout;
let currentRowIndex = Math.max(layout.length - 1, 0);
// init currentRow if necessary