feat: pan on solution when submitting
All checks were successful
deploy to cloudflare pages / deploy (push) Successful in 32s

This commit is contained in:
uku 2024-10-26 18:05:25 +02:00
parent bd229982f6
commit c06553fb74
Signed by: uku
SSH key fingerprint: SHA256:4P0aN6M8ajKukNi6aPOaX0LacanGYtlfjmN+m/sHY/o

View file

@ -69,7 +69,14 @@
if (response.ok && map) {
const res: CheckResponse = await response.json();
const line = L.polyline([checkData.latlng, res.solution], {
color: "black",
weight: 6,
}).addTo(map);
map.flyToBounds(line.getBounds());
L.marker(res.solution).bindPopup(data.gameData.stopName).addTo(map).openPopup();
results = res;
} else {
alert("you dirty little cheater");