Skip to content

Commit

Permalink
🐛 Update the active dimension on close with last value in the state
Browse files Browse the repository at this point in the history
  • Loading branch information
dej611 committed Nov 10, 2020
1 parent bafe9df commit bf5ac0f
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -463,10 +463,12 @@ export function LayerPanel(
prevState: props.visualizationState,
})
);
setActiveDimension({
...activeDimension,
// Many setActiveDimension calls may happen at once
// so pick the last update value and update it
setActiveDimension((prevActiveDimension) => ({
...prevActiveDimension,
isNew: false,
});
}));
},
}}
/>
Expand Down

0 comments on commit bf5ac0f

Please sign in to comment.