Skip to content

Commit

Permalink
Added the function that selects the bounding box of the selected plac…
Browse files Browse the repository at this point in the history
…e from the options
  • Loading branch information
berkaydoner committed Dec 11, 2021
1 parent 7c3f3d6 commit 457f2ce
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,11 @@ export default function MapWithRectangle(props) {
setOptionsOpen(true)
}
const selectLocation = (input) => {

setOptionsOpen(false)
let bottomLeft = {lat:input.bottomLeft.lat, lng:input.bottomLeft.lng}
let topRight = {lat:input.topRight.lat, lng:input.topRight.lng}
props.setBottomLeft(bottomLeft)
props.setTopRight(topRight)
}
return (
<div>
Expand Down

0 comments on commit 457f2ce

Please sign in to comment.