Skip to content

Commit

Permalink
Unselect deployment when clicking in selected one
Browse files Browse the repository at this point in the history
  • Loading branch information
willemarcel committed Dec 12, 2023
1 parent 4e8af45 commit b709501
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions src/components/timeline/deployment.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,19 +97,21 @@ export const Deployment = ({
}
transition="all 2s"
onClick={() => {
setSelectedDeployment({
...{
start,
end,
events,
iops,
id,
longname,
shortname,
aliases,
regions,
},
})
selectedDeployment?.id === id
? setSelectedDeployment(null)
: setSelectedDeployment({
...{
start,
end,
events,
iops,
id,
longname,
shortname,
aliases,
regions,
},
})
setSelectedEvent({ content: null, type: "deployment" })
}}
/>
Expand Down

0 comments on commit b709501

Please sign in to comment.