Fix dashboard drag error (#16731)
Fixes https://github.com/twentyhq/twenty/issues/16730
This commit is contained in:
+1
@@ -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();
|
||||
});
|
||||
|
||||
|
||||
+1
-1
@@ -48,7 +48,7 @@ export const usePageLayoutHandleLayoutChange = (
|
||||
|
||||
set(pageLayoutCurrentLayoutsState, {
|
||||
...currentTabLayouts,
|
||||
[activeTabId]: allLayouts,
|
||||
[activeTabId]: structuredClone(allLayouts),
|
||||
});
|
||||
|
||||
const pageLayoutDraft = snapshot
|
||||
|
||||
Reference in New Issue
Block a user