Skip to content

Commit

Permalink
fix: add stop by dragging route (#442)
Browse files Browse the repository at this point in the history
fixes #439
  • Loading branch information
TheGreatRefrigerator authored Jul 12, 2024
2 parents e32a692 + 62cfc73 commit 5821cc4
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,10 @@ export default {
* @param {*} data {latLng: ..., place:...}
*/
addRouteStop (data) {
// leaflet native drag event exposes under .latlng
if (data.latLng === undefined) {
data.latLng = data.latlng
}
// Only one place input, so the selected point will be the 'from'
if (this.places.length === 1) {
this.directionsFromPoint(data)
Expand Down

0 comments on commit 5821cc4

Please sign in to comment.