Skip to main content

CoordinateDisplay

Controls & Overlays
View Docs

Show cursor coordinates and zoom level on the map

coordinatespositionzoomdebugging

Demo

Coordinate Display Demo. Interactive map centered at 37.77 degrees N, 122.42 degrees W at zoom level 12. Use keyboard to navigate.

Coordinate Format

Display Options

Current Map State

Center: -122.41940, 37.77490
Zoom: 12.00
Bearing: 0.0°
Pitch: 0.0°

Map Controls

Route Waypoints

1 Golden Gate Bridge
-122.47830, 37.81990
2 Marina District
-122.44690, 37.80450
3 Union Square
-122.41940, 37.77490
4 AT&T Park
-122.38940, 37.76490

Coordinate Format Examples

Decimal Degrees (DD)

Most common format for digital mapping:

37.77490, -122.41940

Degrees Minutes Seconds (DMS)

Traditional geographic notation:

37°46'29.6"N, 122°25'09.8"W

CoordinateDisplay Features:

  • Real-time cursor position tracking
  • Decimal degrees or DMS format
  • Configurable decimal precision (1-8)
  • Optional zoom level display
  • Optional bearing (rotation) display
  • Flexible positioning in all four corners
  • Dark mode support

Usage

import { CoordinateDisplay } from '@classic-homes/maps-svelte';
// or for React:
import { CoordinateDisplay } from '@classic-homes/maps-react';

Related Components