Skip to content

Commit

Permalink
fix onclose
Browse files Browse the repository at this point in the history
Signed-off-by: Teo Koon Peng <[email protected]>
  • Loading branch information
koonpeng committed Aug 23, 2024
1 parent 2421e0b commit e432b93
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/dashboard/src/components/workspace.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,8 @@ export const Workspace = React.memo(
<microApp.Component
key={l.i}
onClose={() => {
const newLayout = layout.filter((l2) => l2.i !== l2.i);
const newLayout = layout.filter((l2) => l2.i !== l.i);
console.log(layout, newLayout);
onLayoutChange &&
onLayoutChange(
newLayout.map((l) => ({ layout: l, microApp: windowApps.current[l.i] })),
Expand Down

0 comments on commit e432b93

Please sign in to comment.