fix(import): autofix missing sizes of items with grid-algorithm (#2522)

This commit is contained in:
Meier Lukas
2025-03-07 21:27:29 +01:00
committed by GitHub
parent 65f00f19de
commit d410af3402
6 changed files with 115 additions and 14 deletions

View File

@@ -135,7 +135,7 @@ const moveWidgetsAndAppsInLeftSidebar = (
offset: number,
screenSize: BoardSize,
) => {
const columnCount = mapColumnCount(old, screenSize);
const columnCount = mapColumnCount(old.settings.customization.gridstack, screenSize);
let requiredHeight = updateItems({
// This should work as the reference of the items did not change, only the array reference did
items: [...old.widgets, ...old.apps],
@@ -211,7 +211,7 @@ const moveWidgetsAndAppsInRightSidebar = (
offset: number,
screenSize: BoardSize,
) => {
const columnCount = mapColumnCount(old, screenSize);
const columnCount = mapColumnCount(old.settings.customization.gridstack, screenSize);
const xOffsetDelta = Math.max(columnCount - 2, 0);
const requiredHeight = updateItems({
// This should work as the reference of the items did not change, only the array reference did