Directions
A · {origin.label || `${origin.lat.toFixed(4)}, ${origin.lon.toFixed(4)}`}
{#if !hasGraph}
Road data layer needed for route computation

The {graphLabel} isn't loaded yet. Load it to enable routing.

{/if} {#if hasGraph} {#if destination}
B · {destination.label || `${destination.lat.toFixed(4)}, ${destination.lon.toFixed(4)}`}
{:else}
Click a point on the map, or search below.
{ showDestResults = true; void inputDestSearch(); }} onfocus={() => (showDestResults = true)} /> {#if showDestResults && (destSearchResults.length || destGeoResults.length || destSearching || savedMatches().length)}
    {#if savedMatches().length}
  • Saved points
  • {#each savedMatches() as p (p.id)}
  • {/each} {/if} {#if destSearchResults.length}
  • From your data
  • {#each destSearchResults as r (r.item.id)}
  • {/each} {/if} {#if destSearching}
  • Searching the web for locations…
  • {:else if destGeoResults.length}
  • Online
  • {#each destGeoResults as g, i (g.osmId + '-' + i)}
  • {/each} {/if}
{/if}
{#if savedPoints.length && !destQuery.trim()}
— or a saved point — {#each savedPoints as p (p.id)} {/each}
{/if}
{/if}
{#if optionsOpen}
Avoid {#each CATEGORIES as c (c.key)} {/each}
{/if}
{#if computing}
Computing route… {Math.round(progress * 100)}%
{/if} {#if status === 'error'}
No complete route. {errorMsg}
{:else if result}
Distance{formatDistance(result.distanceM)}
{formatAlt(result.distanceM)}
Est. time{formatTime(result.distanceM)}
{mode === 'drive' ? 'driving' : 'walking'} · {result.nodesVisited.toLocaleString()} nodes searched {#if result.reason}
{result.reason}
{/if}
{#if turns}
Turn-by-turn
    {#each turns.list as t, i (i + '-' + t.instruction)}
  1. {formatDistance(t.distanceM)}{t.instruction}
  2. {/each}
{turns.list.length} steps · {formatDistance(turns.total)} total
{/if} {/if} {/if}
Pick a destination (map click or search), then calculate the route.