ReviewOS

also looking at this

craft-native/craft

feat(maps): add key-free native Android maps and shared map controls

#363
Merged chris wants to merge codex/wildloop-native-map-providers into main
28 files +1857 -481
docs/guides/native-stx.mdmodified+15-6
Changes to docs/guides/native-stx.md
@@ -154,7 +154,7 @@ next route.
154154| `Image` | `UIImageView` | `ImageView` |
155155| `ImageBackground` | `CraftNativeImageBackgroundView` | `CraftNativeImageBackgroundView` |
156156| `Video` | `CraftNativeVideoView` (`AVPlayerViewController`) | `CraftNativeVideoView` (`VideoView`) |
157| `Map` | `CraftNativeMapView` (`MKMapView`) | `CraftNativeMapView` (`GoogleMap`) |
157| `Map` | `CraftNativeMapView` (`MKMapView`) | `CraftNativeMapView` (native MapLibre or Google Maps) |
158158| `MapPolyline`, `MapMarker` | overlays inside `CraftNativeMapView` | overlays inside `CraftNativeMapView` |
159159| `Svg` | `CraftNativeSvgView` | `CraftNativeSvgView` |
160160| `G`, `SvgText` | drawn inside `CraftNativeSvgView` | drawn inside `CraftNativeSvgView` |
@@ -228,12 +228,21 @@ or `fitToBounds`, which recenters only when its overlay geometry changes. Explic
228228authored camera bounds on both hosts; only `fitToBounds` adds framing padding. A marker's `onPress` or
229229`onMarkerPress` receives `nativeEvent.id`; a marker's own handler wins, and the map-level handler is
230230used as a fallback when the marker has no non-empty handler.
231It is backed by MapKit on iOS and the Google Maps SDK on
232Android; the Android template adds that dependency only for screens that opt
233into the native map host. The shared `mapType` values are `standard`,
231It is backed by MapKit on iOS and the configured native provider on Android.
232Set the Craft Android config's `mapProvider` to `maplibre` for a key-free native
233GL view; `google` preserves the existing Google Maps host. Only the selected
234provider's SDK is included in the generated Android project. These STX map
235components do not use the DOM-based `@craft-native/ts-maps` adapter.
236The shared `mapType` values are `standard`,
234237`satellite`, and `hybrid`; Android's terrain-only style is intentionally not
235part of the cross-platform contract. Tile styling, clustering, directions, and
236offline tiles remain outside this contract. Set `showsUserLocation` to opt into the
238part of the cross-platform contract. `tileOverlay` accepts an HTTPS raster URL
239template and its visible provider attribution. `edgePadding` reserves logical
240points around a fitted route for floating controls. `pitchEnabled` controls
241tilt gestures; `cameraPitch` and `cameraHeading` set the camera explicitly.
242Markers accept `pinColor` for trailheads and inspected profile positions, or
243`bearing` for a contrasting route-direction sign. Clustering, turn-by-turn
244directions, and offline tile downloads remain outside this view contract.
245Set `showsUserLocation` to opt into the
237246platform location dot; the host only enables it when the app's existing
238247location permission is already granted, and never prompts from a renderer
239248pass. Android also forwards `MapView` start/stop lifecycle callbacks as map