mirror of
https://github.com/zvx-echo6/navi.git
synced 2026-08-26 17:31:37 +00:00
fix(navi): Auto-mode usability — boundary chips for non-Drive + 50m snap threshold
(1) DirectionsPanel: show boundary-mode chips for all modes except Drive (vehicle). Drive is pure Valhalla road routing so boundary mode is irrelevant; Auto/Foot/MTB/ATV may traverse wilderness and need the chips. (2) router.py: raise OFF_NETWORK_THRESHOLD_M 10 -> 50. Geocoded street addresses commonly snap 20-50m from the road centerline; 10m forced normal road routes into wilderness pathfinding. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
777a311c2c
commit
a1e891ba70
2 changed files with 7 additions and 4 deletions
|
|
@ -56,8 +56,10 @@ EXPANDED_SEARCH_RADIUS_KM = 100
|
||||||
# Memory limit
|
# Memory limit
|
||||||
MEMORY_LIMIT_GB = 12
|
MEMORY_LIMIT_GB = 12
|
||||||
|
|
||||||
# Off-network detection threshold (meters)
|
# Off-network detection threshold (meters). Geocoded street addresses commonly
|
||||||
OFF_NETWORK_THRESHOLD_M = 10
|
# snap 20-50m from the road centerline, so a tight value forces normal road routes
|
||||||
|
# into wilderness pathfinding; 50m keeps on-road endpoints on-network.
|
||||||
|
OFF_NETWORK_THRESHOLD_M = 50
|
||||||
|
|
||||||
# Mode to Valhalla costing mapping
|
# Mode to Valhalla costing mapping
|
||||||
MODE_TO_COSTING = {
|
MODE_TO_COSTING = {
|
||||||
|
|
|
||||||
|
|
@ -325,8 +325,9 @@ export default function DirectionsPanel({ onClose }) {
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* Boundary mode selector (only for non-auto modes) */}
|
{/* Boundary mode selector — hidden only for Drive (vehicle), which is pure
|
||||||
{routeMode !== "auto" && (
|
Valhalla road routing; Auto/Foot/MTB/ATV may traverse wilderness. */}
|
||||||
|
{routeMode !== "vehicle" && (
|
||||||
<div className="flex gap-1">
|
<div className="flex gap-1">
|
||||||
{BOUNDARY_MODES.map((m) => {
|
{BOUNDARY_MODES.map((m) => {
|
||||||
const active = boundaryMode === m.id
|
const active = boundaryMode === m.id
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue