Fix dashboard drag error (#16731)

Fixes https://github.com/twentyhq/twenty/issues/16730
This commit is contained in:
Brian Pursley
2025-12-24 05:16:47 -05:00
committed by GitHub
parent 1cd413834d
commit 766822d04b
2 changed files with 2 additions and 1 deletions
@@ -52,6 +52,7 @@ describe('usePageLayoutHandleLayoutChange', () => {
});
expect(result.current.layouts['tab-1']).toEqual(newLayouts);
expect(result.current.layouts['tab-1']).not.toBe(newLayouts); // Ensure a clone was set, not the same reference
expect(result.current.layouts['tab-2']).toBeUndefined();
});
@@ -48,7 +48,7 @@ export const usePageLayoutHandleLayoutChange = (
set(pageLayoutCurrentLayoutsState, {
...currentTabLayouts,
[activeTabId]: allLayouts,
[activeTabId]: structuredClone(allLayouts),
});
const pageLayoutDraft = snapshot