🐛 Fix Change Position not working with gridstack
This commit is contained in:
@@ -22,13 +22,17 @@ export const ChangeAppPositionModal = ({
|
||||
return;
|
||||
}
|
||||
|
||||
updateConfig(configName, (previousConfig) => ({
|
||||
...previousConfig,
|
||||
apps: [
|
||||
...previousConfig.apps.filter((x) => x.id !== innerProps.app.id),
|
||||
{ ...innerProps.app, shape: { location: { x, y }, size: { width, height } } },
|
||||
],
|
||||
}));
|
||||
updateConfig(
|
||||
configName,
|
||||
(previousConfig) => ({
|
||||
...previousConfig,
|
||||
apps: [
|
||||
...previousConfig.apps.filter((x) => x.id !== innerProps.app.id),
|
||||
{ ...innerProps.app, shape: { location: { x, y }, size: { width, height } } },
|
||||
],
|
||||
}),
|
||||
true
|
||||
);
|
||||
context.closeModal(id);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user