Skip to content

Commit

Permalink
Merge pull request #990 from frett/patch-1
Browse files Browse the repository at this point in the history
Update GeoURI to drop a pin when opened with Google Maps
  • Loading branch information
TurtIeSocks authored Mar 25, 2024
2 parents 7b74ebb + 3e002fa commit 4b4e99d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions server/src/configs/default.json
Original file line number Diff line number Diff line change
Expand Up @@ -907,7 +907,7 @@
},
{
"name": "GeoURI",
"url": "geo:{x},{y}"
"url": "geo:{x},{y}?q={x},{y}"
}
],
"icons": {
Expand Down Expand Up @@ -1022,4 +1022,4 @@
"tracesSampleRate": 0.1
}
}
}
}
4 changes: 3 additions & 1 deletion src/components/popups/Navigation.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ export function Navigation({ lat, lon, size = 'large' }) {
const url = useMemory((s) => s.settings.navigation[nav]?.url)
return (
<IconButton
href={url.replace('{x}', lat.toString()).replace('{y}', lon.toString())}
href={url
.replaceAll('{x}', lat.toString())
.replaceAll('{y}', lon.toString())}
target="_blank"
rel="noreferrer"
size={size}
Expand Down

0 comments on commit 4b4e99d

Please sign in to comment.