Skip to content

Map with coordinate regions and markers - #35

Merged
colemancda merged 5 commits into
masterfrom
feature/map
Jul 23, 2026
Merged

Map with coordinate regions and markers#35
colemancda merged 5 commits into
masterfrom
feature/map

Conversation

@colemancda

Copy link
Copy Markdown
Member

MapKit-style maps.

What's new

  • TypesCLLocationCoordinate2D, MKCoordinateSpan, MKCoordinateRegion, MapMarker (title, coordinate, optional tint)
  • Map(coordinateRegion:markers:) — emits a Map node carrying the region, with MapMarker children
  • Interpreter renders a schematic map: the visible region maps linearly onto the box, markers sit at their proportional position (north at the top) with pin + label, and the center coordinate is captioned. Default fill-width × 220dp; .frame/.cornerRadius compose normally.

Real tile rendering is deliberately left to the composable registry — maps SDKs on Android require an API key, so the host app can register a tile-backed Map composable when it has one; the schematic keeps the core dependency-free.

Verification

  • swift test — region + marker emission test, 57 passing
  • Emulator (new Map screen): a Lima region with three tinted markers whose relative placement matches real geography (Plaza Mayor east of center, Miraflores south, Callao west), and a framed Cupertino region with its caption

Deferred

Region-change gestures (pan/zoom writing back to the binding); Marker-in-MapContentBuilder API form; tile providers.

@colemancda colemancda mentioned this pull request Jul 23, 2026
@colemancda
colemancda merged commit 5e0f0c2 into master Jul 23, 2026
6 checks passed
@colemancda
colemancda deleted the feature/map branch July 23, 2026 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant