Meridian Atlas SDK

Turn-by-turn navigation for iOS, Android, React Native and Flutter: route guidance with lanes, signposted exits and "at the traffic lights" wording, rerouting, dead reckoning through tunnels, free drive (no destination), offline packages, multi-stop routes, route matrices, Places search and traffic, and CarPlay and Android Auto (car-screens.md).

PlatformPackageStart here
iOS (Swift)MeridianAtlas Swift packagequickstart-ios.md
Android (Kotlin)dev.meridianatlas:atlas-android (brings in dev.meridianatlas:atlas-core)quickstart-android.md
React Native@meridianatlas/react-nativequickstart-react-native.md
Fluttermeridian_atlasquickstart-flutter.md
Servers (TypeScript)@meridianatlas/apiits README

Status: engineering preview. The packages come as a release archive and are not yet published to a registry. Every code sample in the quickstarts is compiled and run by the SDK test suites, so the guides match the API (each guide's source names the test that runs it).

Configuration

Make one AtlasConfiguration and give it to every client, the navigation session and the map view. It holds the API key, the service's base URL, the map viewer's URL (for the map view), the deadline for each request and the app's identity:

Swift
let atlas = try AtlasConfiguration(apiKey: apiKey)                                                // Swift
let routes = AtlasRoutes(configuration: atlas)
let navigation = AtlasNavigation(configuration: atlas, onUpdate: { update in /* ... */ })
let map = try AtlasMapView(configuration: atlas)
Kotlin
val atlas = AtlasConfiguration(context, apiKey)                                                   // Kotlin
val routes = AtlasRoutes(atlas)
val navigation = AtlasNavigation(atlas, listener = listener)
val map = AtlasMapView(context, atlas)
TypeScript
import { NativeModules } from "react-native";                                                    // React Native
import { AtlasNavigation, AtlasRoutes, atlasAppIdentity, atlasConfiguration, atlasMapRoute } from "@meridianatlas/react-native";

const atlas = atlasConfiguration({ apiKey, appIdentity: atlasAppIdentity(NativeModules.MeridianAtlas) });
const routes = new AtlasRoutes(atlas);
const navigation = new AtlasNavigation(bridges.navigation, atlas);
const map = <AtlasMapView configuration={atlas} route={atlasMapRoute(route)} />;
Dart
final atlas = await AtlasConfiguration.forThisApp(apiKey: apiKey);                               // Flutter
final routes = AtlasRoutes.fromConfiguration(atlas);
final navigation = AtlasNavigation(MethodChannelAtlasNavigationBridge(), configuration: atlas);
final mapView = AtlasMapView(configuration: atlas, onCreated: (map) => map.showAtlasRoute(route));
  • A key is all a first route needs. The service defaults to https://api.meridianatlas.dev and the map viewer to https://maps.meridianatlas.dev/v1 (defaultBaseURL/defaultViewerURL in Swift, ATLAS_DEFAULT_BASE_URL/ATLAS_DEFAULT_VIEWER_URL in Kotlin, React Native and the TypeScript client, atlasDefaultBaseUrl/atlasDefaultViewerUrl in Flutter). That domain isn't live yet: until it is, beta partners pass the addresses Meridian gave them as baseURL/baseUrl and viewerURL/viewerUrl.
  • HTTPS only. Plain HTTP is accepted only in a debug build (iOS DEBUG, a debuggable Android app, React Native's __DEV__, Flutter's debug mode), and only to this device (localhost, 127.0.0.1, [::1]) or the Android emulator's host (10.0.2.2).
  • App keys work. An app key, made in Atlas Studio for named apps, only works from those apps, so every request names the app: Atlas-App is the iOS bundle ID or Android package name, and on Android Atlas-App-Cert is the SHA-256 of the app's signing certificate (64 lower-case hex digits). The configuration reads them once: from Bundle.main on iOS, from the Context's package manager on Android (the current certificate after key rotation; with several signers the one whose SHA-256 sorts first, so list every signer on the key), and from the native side in React Native (atlasAppIdentity, from the module's constants) and Flutter (AtlasConfiguration.forThisApp). A key used from an app it doesn't list fails with app_not_allowed. Server keys ignore the app.
  • The deadline for each request (timeout / timeoutMillis / timeoutMs) defaults to 30 seconds, at most 5 minutes.
  • The older initialisers (AtlasRoutes(baseURL:apiKey:) and the rest) still work. The Swift ones send the bundle ID too; the Android, React Native and Flutter ones send no app, so use them with server keys.
  • The server-side TypeScript client (@meridianatlas/api) takes the same baseUrl, apiKey and timeoutMs; it is for server keys and sends no app.

Features

Every feature has the same class on every platform. You turn features on for each API key when you set it up; a call for a feature the key doesn't have fails with capability_required, and capability names the feature.

FeatureKey featureiOSAndroidReact NativeFlutter
Routes with guidancecore_routingAtlasRoutesAtlasRoutesAtlasRoutesAtlasRoutes
Multi-stop routes (stops in the order given)core_routingAtlasMultiStopAtlasMultiStopAtlasMultiStopAtlasMultiStop
Route matrixroute_matrixAtlasRouteMatrixAtlasRouteMatrixAtlasRouteMatrixAtlasRouteMatrix
Places: autocomplete, search, details, photosplacesAtlasPlacesAtlasPlacesAtlasPlacesAtlasPlaces
Traffic on a routetrafficAtlasTrafficAtlasTrafficAtlasTrafficAtlasTraffic
Turn-by-turn navigation (on the device)navigationAtlasNavigationAtlasNavigationAtlasNavigationAtlasNavigation
Navigation legs: what guidance is charged bynavigationAtlasNavigationLegsAtlasNavigationLegsAtlasNavigationLegsAtlasNavigationLegs
Free drive: road names and speed limits (on the device)road_attributesAtlasFreeDriveAtlasFreeDriveAtlasFreeDriveAtlasFreeDrive
Roads near the car, for free driveroad_attributesAtlasRoadsAtlasRoadsAtlasRoadsAtlasRoads
Offline packagesofflineNot in the Swift package yetAtlasOfflineWorkManager, OfflinePackageInstaller (install from a folder on the phone)AtlasOfflineRoutes (route on an installed package)AtlasOfflineRoutes (route on an installed package)
The 3D mapmap_tilesAtlasMapViewAtlasMapViewATLAS_MAP_VIEW (native view)AtlasMapView

Each request is charged to the feature it uses: one route, one multi-stop leg, one resolved matrix cell (a pair with no route is free), one Places call, one traffic advisory, one nearby-roads lookup. Guidance itself runs on the device and is charged per navigation leg. A navigation session made with the configuration reroutes by itself (see Rerouting), registers its leg itself (POST /v1/navigation/legs) when guidance to a destination begins, puts its legId on every request_reroute (so its reroutes cost nothing more, up to 50 a leg), and ends it on arrival or when guidance stops; beginning again to the same destination (within 50 m) keeps the leg. A new destination is a new leg, and so is each stop of a multi-stop route: begun with AtlasMultiStopRoute.plan, the session arrives at each stop (stop_arrived), ends that leg, and registers the next when the car is more than 50 m from the stop or leaves the route (leg_started), so a run stopped at a stop is never charged the next leg. Its reroutes head for the next stop not yet reached (never back to one reached, and never straight to the end), and the snapshot says which leg is active (legIndex, legCount, nextStopId, legRemainingM). Registration never holds up guidance: a failure that may pass is tried again after 1, 2, 4, 8 and 16 seconds with the same Idempotency-Key (so the leg is charged once), and if the leg still can't be registered the session reports leg_registration_failed through its error channel and carries on, its reroutes then charged as routes. Without a configuration the session contacts no server, and AtlasNavigationLegs does the same by hand. Offline packages come after launch: no platform downloads them over the network yet.

The service clients share one error type (AtlasError on iOS and React Native, AtlasException on Android and Flutter, AtlasApiError / AtlasTransportError in the TypeScript server client) with the same code on every platform: missing_api_key, invalid_request, invalid_api_key, capability_required, app_not_allowed, billing_inactive, usage_policy_required, usage_allowance_exhausted, rate_limit, outside_coverage, route_unresolved, leg_invalid, leg_destination_mismatch, leg_not_found, wrong_service_address, request_timeout, network_error, invalid_response and service_error. Each message says what to fix and ends with a link to the code's entry in Errors; isRetryable (retryable in TypeScript) says whether trying again later can work. The navigation session reports leg_registration_failed (with the service's error as its cause, or its status and capability on iOS and Android) when it couldn't register its leg. Each request sends the key as X-Atlas-Key, the SDK as Atlas-Client (ios/, android/, react-native/, flutter/ or typescript/ and the version) and, from an app, Atlas-App (and Atlas-App-Cert on Android). Billed calls send an Idempotency-Key; asking again for the same request_reroute after a timeout or lost connection reuses its key, so a request that did reach the service counts once.

How it fits together

 location fixes ──▶ Atlas session ──updates (snapshot + effects)──▶ your app
                    ◀────── effects ask the app to act: load roads, pause, show the new route ─┘
  • Sessions are state machines. A route session (begin(route)) and a free-drive session (begin()) take location fixes and report a snapshot plus effects. The session core never makes network calls, asks for permissions, plays audio or draws: the app owns those, and Atlas tells it what to do. The one exception is the SDK class made with a configuration, which fetches its own reroutes and registers its navigation legs.

  • Who supplies the fixes. In React Native and Flutter the package runs GPS itself while a session is active (high accuracy; on Android a foreground service keeps it going with the screen off); the app only asks the user for location permission. With the native SDKs the app passes each fix in and calls tick about once a second:

    • iOS: AtlasNavigation.ingest(_:) and AtlasFreeDrive.ingest(_:) take a CLLocation; tick().
    • Android: the host, AtlasNavigation.ingest(AtlasPositionSample) and tick(nowMs) (ForegroundLocationSource can supply the samples, with the screen off too); the core sessions, AtlasNavigationSession.ingest and AtlasFreeDrive.ingest (an AtlasPositionFix) and tick(nowMs).
  • Effects are requests to the app.

    EffectSessionWhat the app does
    request_rerouterouteMade with a configuration, nothing: the session fetches the route itself (see Rerouting). Otherwise (or with manual rerouting), fetch a route from origin to destination, facing headingDegrees (the routes client's reroute(effect) does this, and sends the effect's legId), and answer with completeReroute(requestId, newRoute), or failReroute(requestId, error) if the fetch failed: Atlas keeps the old route and asks again. Unanswered after 20 seconds counts as failed. (The Android host takes your routing as a transport.)
    route_replacedrouteShow the new route (after automatic rerouting it carries it as route; Android: onRerouted) and guide by its steps.
    reroute_failed / reroute_cancelledrouteOptional: say "no new route yet" (the old one is kept; retryAtMs is the next try) or drop it (the car came back to the route).
    pause_guidance / resume_guidancebothGrey out the banner while GPS is lost or uncertain.
    arrivedrouteShow arrival; stop the session.
    roads_neededfree driveLoad roads within radiusM of centre (AtlasRoads.nearby(centre, radiusM) does this) and call setRoads.
    road_changed / speed_limit_changedfree driveUpdate the road name and limit sign.
  • Guidance text comes with the route. The route response carries a guidance list (contract: sdk/contracts/structured-guidance-v1.schema.json): each step has kind, atMetres, a ready-to-speak instruction ("At junction 18, take the exit towards M62, Bradford"), lanes, signposts and landmark. Show the next step whose atMetres is beyond the session's progressM.

  • Spoken announcements come with the updates. The route's plan carries its guidance, and the session decides what to say and when: each update's announcements ("In 300 yards, turn left onto the A five-eighty", then "Turn left now"), with an id, priority, plain text and ssml. Warning distances scale with speed. Nothing is said while guidance is paused or the phase isn't on_route, and nothing is repeated after a reroute. Every SDK announces the same things at the same points (conformance/voice-announcements-v1.json). Playing them is the app's: the opt-in AtlasVoice says them with the best installed British voice (or the app's own speech), never touches the audio session or audio focus, and tells the app before and after each one so it can duck its own audio (contract: sdk/contracts/voice-sdk-v1.schema.json).

  • Ordered updates. Each update has a sequence; the React Native and Flutter wrappers reject regressions, so a bridge that reorders events fails loudly.

Rerouting

A navigation session made with the configuration reroutes by itself, the same way on all four SDKs:

  • When. Off-route evidence builds up fix by fix (no match on the route, a course diverging from every route direction ahead, straight on where the route turns, a road alongside, a turn round); a fix back on the route clears it. A car under 4.5 m/s (a car park, a forecourt, a queue) gathers none unless it has turned round. The rules are measured on replayed drives with realistic GPS noise (conformance/reroute-scenarios-v1.json): a wrong motorway exit is caught in about 6 seconds, a missed city turn in about 3, and parking, waits at lights, lane changes, urban canyons and tunnels cause no reroutes.
  • What it asks for. From where the car is, facing the way it is going (its GPS course, or the way it has moved when the course isn't reliable), to the destination (on a multi-stop route, the next stop not yet reached), asked the way the route was (the plan's options: profile, traffic, approach, and a departure time moved on by the drive), inside the navigation leg (50 reroutes a leg; then without it, charged as a route, and leg_invalid is reported once). The route service starts the route on a road going within headingTolerance (60° by default) of that heading, so a reroute on a dual carriageway starts on the car's own side.
  • How. One fetch at a time, within 15 seconds; a fetch the session no longer needs (the car came back: reroute_cancelled) is dropped. The old route is kept until the new one arrives (route_replaced, with the new route). A failure is said (reroute_failed, with its reason and retryAtMs) and tried again after 3 seconds, then 6, 12 and so on, up to a minute; offline, reroutes wait (reroute_deferred).
  • Your own routing. Swift rerouting: .custom { ... } or .manual; Kotlin a transport; React Native { rerouting: handler | "manual" }; Flutter rerouting: AtlasRerouting.custom(...) or .manual. Manual answers are completeReroute(requestId, route) and failReroute(requestId, error).
  • Retry. retryReroute() asks for a new route at once after reroutes have failed (the driver's Retry), instead of at the session's next try.

What the driver is told: the guidance status

Every snapshot carries a status (AtlasGuidanceStatus): what to tell the driver about guidance itself, decided the same way by the Swift and Kotlin cores (conformance/guidance-status-v1.json). The map's own panels, CarPlay and Android Auto show it for you; read it if you draw your own.

stateWhenShown as
locatingGuidance has begun and the first usable fix hasn't come (for up to 10 s)"Locating…", calm, a small spinner
guidingNothing to say. A GPS gap of a few seconds, and dead reckoning through a tunnel, stay herethe guidance itself
no_gps, weak_gpsNo usable position: 10 s from the start, or mid-drive 3 s after the session's own 5 s without a fix"No GPS signal", "Guidance carries on when the signal is back"
finding_routeA reroute has taken more than a second (most take well under one)"Finding a new route…", a small spinner
no_routeTwo tries in a row failed (the first and its retry 3 s later)"Can't find a route", "Check your connection" (or "Head back to the route" when there is no route from there), with action retry
offlineOff the route with no connection (setConnectivity(false))"Offline", "New route when you're back online"
arrived, idlenothing

Why these numbers: a phone's first fixes are often Wi-Fi or cell estimates the session refuses (worse than 30 m), so "No GPS signal" at once (as before) was wrong almost every time guidance started; 10 s covers a warm phone's first good fix with room to spare without leaving a real problem (indoors, location off) unsaid for long. Mid-drive the session itself waits 5 s and dead reckons along the route meanwhile; 3 s more keeps bridges, underpasses and a few seconds of reflections between tall buildings off the screen. The status holds what it showed through those few seconds, so nothing flashes.

After a reroute, notice says "New route" for 6 seconds while guiding, with what it costs: "2 min longer", "1 min shorter" or "About the same time" (the new route's time against the old route's from where the car left it, to the next stop on a multi-stop trip; plans carry their durationSeconds for this). The voice says nothing extra: after a reroute it never repeats a prompt already said.

Retry: the map's panels and the car screens show a Retry button with no_route when the app takes it. Set onRetryReroute on AtlasMapView and AtlasCarPlay (Swift) or AtlasMapView and AtlasCar (Kotlin) to call your navigation's retryReroute(). The React Native and Flutter plugins do it themselves.

A faster simulated drive (AtlasRouteSimulator at 4×) sends fixes with four times the car's speed, as the session needs; the snapshots' measuredSpeedMps is the car's own speed, so the speed panel reads as a speedometer would.

Speed limits and speed cameras

The phone's speed panel, CarPlay's and Android Auto's speed sign and the camera alerts follow one set of rules, which every SDK and the map's panels are tested against (conformance/speed-alerts-v1.json):

  • The speed and the limit as shown: whole mph (km/h with metric units), halves up. In km/h a UK limit reads as what it is (30 mph is 48), not a round number it isn't; one set in km/h reads as its sign (50).
  • Over the limit: the shown speed above the shown limit (31 in a 30), plus a tolerance if your app sets one: speedTolerance, a whole number from 0 to 10, 0 by default (on the map presentation, and on AtlasCarPlay.Options, AtlasCar and AtlasCarScreen.configure, which take the presentation's). The legal limit is the shown limit, and the shown number is already rounded, so 0 is the honest default; drivers who want a margin, as Waze and TomTom let them choose, get one.
  • Steady, never flashing: over shows once it has held for a second, and goes once the speed has been within the limit for two seconds, or at once when the limit goes up past the speed. Hovering at 30 and 31 doesn't flicker, and one GPS spike never shows. Nothing pulses.
  • No sign without a limit: where the limit isn't known, there's no sign and no over.
  • A lower limit ahead (40 to 30 in 200 m) shows small beside the sign, from 12 seconds before it at the car's speed (150 m to 500 m), when the route's speed limits have it; a higher limit, a dip of under 50 m or a gap in the data shows nothing.
  • Speed cameras are warned of 22.4 seconds before at the camera's limit or the car's speed, whichever is more: 300 m on a 30 mph street, 500 m at 50, 700 m on a 70 mph road, never under 200 m or over 1 km. An average speed check (two or more average speed cameras in a row along the route) is warned of at its first camera, and the phone shows the average so far inside it. Red light cameras are named without a limit. Only where warning of cameras is lawful (the UK and Ireland).
  • Neutral words: "Speed camera", "Average speed check", "Red light camera", "Mobile camera site", and "Speed camera ahead, 30 limit" spoken.

How each surface shows it:

Phone (built-in panels)CarPlayAndroid Auto
The limita road sign beside the speeda road sign in the map's cornerthe same
Over the limitthe speed in Meridian's danger colour on a tinted panel; the sign stays a signthe speed beside the sign in Meridian's danger colourthe same
A lower limit aheada small sign and how far ("60 yd")the same, in a small navy pillthe same
A cameraa line under the banner: "Speed camera · 30 mph", how farCarPlay's navigation alert: "Speed camera ahead", "In 300 yd · 30 mph limit", until it is passedAndroid Auto's alert (a toast before car API 5)

Regulatory red is used only for the sign's ring.

What your app hears. AtlasSpeedAlert (Swift, Kotlin), the map view's onSpeedAlert (React Native) or speedAlerts (Flutter), and the car screen's onSpeedAlert (Swift AtlasCarPlay, Kotlin AtlasCar) or speed_alert event (React Native and Flutter's AtlasCarScreen):

  • speed_limit_exceeded, active true and then false: the speed and limit as shown, the unit, and chime when the optional chime should sound with it (as it begins, then not again until 30 seconds within the limit or a new limit).
  • camera_ahead, active true and then false once passed: the camera's id and kind, how far ahead, its limit, where an average speed check ends, and announcement: what to say, an announcement with the stage camera.

Each surface reports what it shows; with the phone's map and the car screen both up, listen to one.

The voice. An AtlasVoice attached to the map view (map.voice; React Native's deviceVoice) or the car screen (AtlasCarPlay.voice, AtlasCar.voice) says each camera once, whichever surface warns of it, and plays the over-limit chime if you turn it on: speaksCameraAlerts (on by default) and chimesOverLimit (off by default); React Native and Flutter setCameraAlerts and setOverLimitChime, and handleSpeedAlert(alert) for an alert you pass on yourself. The chime is two short soft tones, played on your app's own audio session (iOS) or as navigation guidance (Android). Like the speech, it never sets the audio session or takes audio focus: ducking or pausing your own audio stays yours (onWillSpeak). With a voice of your own, say the camera's announcement and play your own sound for chime.

Contracts

ContractFile
Route navigation wiresdk/contracts/navigation-sdk-v1.schema.json
Free drive wiresdk/contracts/free-drive-sdk-v1.schema.json
Guidance stepssdk/contracts/structured-guidance-v1.schema.json
Map presentationsdk/contracts/map-presentation-v1.schema.json

Behaviour is pinned by shared traces run against every core: conformance/navigation-session-v1.json, conformance/free-drive-v1.json, conformance/structured-guidance-v1.json, and the rerouting scenarios conformance/reroute-scenarios-v1.json (replayed by the TypeScript reference, the Swift core and the Kotlin core alike).

Roads for free drive

Free drive needs the roads near the car. Answer each roads_needed effect with AtlasRoads (the key needs the road_attributes feature; each answer is one unit) and pass what it returns straight to setRoads:

Swift
let nearby = try await roads.nearby(centre: effect.centre!, radiusM: effect.radiusM!)   // Swift
try freeDrive.setRoads(centre: nearby.centre, radiusM: nearby.radiusM, roads: nearby.roads)

Each AtlasRoad has id, coordinates, name, ref (A56), highway, maxspeed ("30 mph"; null when unknown, never a guess), maxspeedForward / maxspeedBackward and oneway, as OpenStreetMap tags them. radiusM is 50 to 2000 metres (free drive asks for 1000); at most 20,000 roads come back. An offline package can supply the same fields.

API reference

Shell
npm run docs:sdk

Builds reference from source into dist/docs: swift/ (DocC, open index.html through a local web server), flutter/ (dartdoc) and react-native/index.md (the package's type declarations) and kotlin/ (Dokka: the Android SDK and the core it re-exports, such as AtlasNavigationSession and AtlasFreeDrive).

The map

Give the map view the configuration and it loads the viewer from its viewerURL (by default https://maps.meridianatlas.dev/v1, whose page is /v1/3d; a viewerBaseURL given to the map view wins) and hands the viewer the key, which the viewer keeps in memory and sends as X-Atlas-Key on its scenery requests to its own host. The key reaches the viewer in the page's bootstrap (window.meridianAtlasHost), never in its URL; the viewer says it can take one with the keyedScenery capability in ready. A map view made with only the viewer's URL (viewerBaseURL) sends no key, as before.

Show the map a route from AtlasRoutes or AtlasMultiStop, not only its plan, and it gets the route's guidance (the route line moves into the lane each junction needs) and its speed limits. navigationUI on the map presentation (all four SDKs; off by default) shows the built-in Meridian guidance panels:

  • the manoeuvre, lanes, camera alerts, and the speed with the limit;
  • trip progress (the arrival time, and the time and distance left; the next stop and the destination on a multi-stop trip);
  • recentre, after the driver pans or pinches the map, or in the overview;
  • the overview button, in Recentre's place while the camera follows the car on a route;
  • the voice's mute button, which mutes and unmutes an attached AtlasVoice by itself (map.voice = voice; React Native's deviceVoice prop);
  • the arrival card (Next stop, End), with each place's name and address when your app gives them.

Each panel can be turned off (navigationPanels). The quickstarts show the calls.

The whole route. The overview (the button, or showOverview(): React Native's overviewKey) shows the rest of the trip: from the car to the destination through every stop left, with the stops numbered and the destination flagged. It is flat and north-up, as Google Maps', Apple Maps' and Waze's are: a glance at the whole route reads best on a map that doesn't turn with the car and isn't tilted away. It frames the route in the largest part of the map nothing covers (the panels, the system's bars and cutouts, and your views given to setInsets), so no part of it is under a panel. Guidance carries on in it: the banner, the trip panel and the voice. The driver can pan and pinch it; Recentre (or recentre()) brings the camera back to the car at its own distance, tilt and heading, as it does after a pan or a pinch. isOverview and the overview event (onOverviewChanged, Flutter overviewChanges) say when it starts and ends, whoever did it. The overview draws the route over the map's own scenery near the car; further off, the route crosses plain ground, as the map has no low-detail map of a whole region yet.

Auto-recentre is off by default. autoRecentreAfter on the map presentation (Swift seconds; Kotlin autoRecentreAfterSeconds; React Native autoRecentreAfterSeconds; Flutter a Duration), 2 to 600 seconds, brings the camera back to the car that long after the map was last moved: the driver's pan or pinch (from when the finger lifts), the overview, or a car screen's map buttons. It waits while a finger is on the map, and while no updates are arriving (a parked car).

What covers the map. The panels keep clear of the status bar, the Dynamic Island, a notch or a camera cut-out, and the home indicator or navigation bar, held upright and on its side: each map view tells the viewer what the system covers (iOS safeAreaInsets; Android's WindowInsets for the bars and the cut-out, which an edge-to-edge app, every app on Android 15 and later, draws under). Lay the map out edge to edge. If your own views cover part of it (a toolbar, a bottom sheet, buttons over the map), say how many points they cover at each edge, measured from the map's edges: setInsets (Swift map.setInsets(UIEdgeInsets), Android map.setInsets(top, left, bottom, right) in dp, React Native's insets prop, Flutter controller.setInsets(EdgeInsets)). The panels keep clear of those too, and the camera keeps the car in the part of the map left clear. At each edge the larger of the two counts, so a toolbar under the status bar is the status bar's height plus the toolbar's.

Day and night. The panels switch with the map: see Day and night.

Large text. The panels' text follows Dynamic Type and Android's font size, up to 1.5 times its default size (the WebView's own text zoom is kept at 100%, so it isn't scaled twice). Where the panels would overlap, leave the screen or leave too little map for the car (a small phone, a phone on its side, a lot of your own views), the text steps back down towards its default size, then the panels go compact: the instruction on one line, the trip panel without its stop names, Recentre as an icon. Long names end in an ellipsis.

Map styles

style on the map presentation (all four SDKs; default standard):

StyleDayNight
standardAtlas's own palette, captured building coloursRole-by-role night palette
neon-coastA game minimap by daylight: a light, minimal grey map, white roads, soft grey blocks, a pale periwinkle sea, a hot-pink routeA game pause map: near-black navy land, an indigo sea lighter than the land, lavender-grey roads, deep-teal parks, navy blocks with pale edges, the same hot-pink route
text
atlasMapPresentation({ style: "neon-coast" })            // React Native
AtlasMapPresentation(style: AtlasMapStyle.neonCoast)     // Flutter
try AtlasMapPresentation(style: .neonCoast)              // Swift
AtlasMapPresentation(style = AtlasMapStyle.NEON_COAST)   // Kotlin

Neon Coast is a flat map: 2D, or 3D with flat or hidden buildings. It defaults to flat buildings, and asking for extruded ones with it is an error on every platform (in the viewer, Full 3D is greyed out). Parks and woods are colour only, with no tree models.

The viewer parameters carry it to the renderer as ?style=neon-coast, on the 2D and the 3D map; day or night follows the map's appearance (Day and night). The palette is Atlas's own. Its colours are tested for legibility (tests/map-styles.test.ts): the route stands out from land and streets, streets from their edges, the sea and the blocks from land, by day and by night.

DayNight
2DNeon Coast 2D by dayNeon Coast 2D by night
Flat 3DNeon Coast flat 3D by dayNeon Coast flat 3D by night

Day and night

appearance on the map presentation (all four SDKs) says when the map is dark:

AppearanceNight
auto (the default)When the phone is in dark mode, and from civil dusk to civil dawn where the car is, whatever the phone is in
systemWhen the phone is in dark mode (iOS Dark Mode or your app's override of it; Android's dark theme or your app's night mode)
day, nightNever, always
text
try AtlasMapPresentation(appearance: .system)                   // Swift; map.appearance = .night while it shows
AtlasMapPresentation(appearance = AtlasMapAppearance.SYSTEM)    // Kotlin; map.appearance = AtlasMapAppearance.NIGHT
atlasMapPresentation({ appearance: "system" })                  // React Native: a new presentation's appearance applies at once
AtlasMapPresentation(appearance: AtlasMapAppearance.system)     // Flutter; controller.setAppearance(AtlasMapAppearance.night)
  • Why auto by default. A light map at night dazzles a driver, and most phones are in light mode: Apple Maps, Google Maps and Waze all go dark after dusk while navigating, and stay dark in dark mode. Use system to keep the map in step with your app's own light and dark screens, or day/night for a setting of your own.
  • The sun is worked out on the device, from the date and where the car is (no service, so it works offline): night from civil dusk (the sun 6° below the horizon, about 35 to 50 minutes after sunset in the UK) to civil dawn. It agrees with the US Naval Observatory's published times to within a minute across the UK (conformance/sun-times-v1.json), and is checked once a minute at the car's position, so a long drive crosses dusk when the car does.
  • Everything switches together, in place: the sky, the lighting, the roads, buildings, trees and road names, and the built-in panels, with no reload. The route, the session's progress and the camera stay as they were. Changing appearance while the map shows does the same (Swift and Kotlin map.appearance, a React Native presentation with a new appearance, Flutter setAppearance or a rebuilt AtlasMapView). On Android, an activity that handles uiMode configuration changes itself (as React Native's and Flutter's do) switches in place when the phone's theme changes; otherwise Android makes the activity, and the map, again.
  • No flash while the map loads. The map view shows Meridian's day ground (#ECEEE9) or night surface (#1A2535) until the map's first frame, in the appearance it will load in.
  • Car screens follow the car, whatever the phone's map does: CarPlay's and Android Auto's maps, and what's drawn round them, are dark when the car says (usually with its headlights). With CarPlay or Android Auto connected, the phone and the car may differ for a while at dusk: each is consistent in itself (CarPlay and Android Auto).

Accessibility

The map view's built-in panels (navigationUI) are built for VoiceOver and TalkBack, which read them inside the map view's web view, and for Dynamic Type, Reduce Motion and Increase Contrast. The car screens are the car's own templates, labelled for its screen reader and Siri or the Assistant.

What the panels do for you

  • Each panel reads as a sentence or two, in full words. The banner: "In 300 yards, bear left onto John Dalton Street, A34" (the road whole, even where the screen cuts it short, and "then turn right" when the next manoeuvre follows close behind). The lanes: "2 lanes: use the left lane, slight left", worded as the car screens word them. The trip panel: "Next stop, 1 of 2: Spinningfields loading bay", "4 minutes and 0.3 miles left, arriving at 14:32". The speed: "Speed 34 miles per hour. Speed limit 30, over the limit", with a lower limit ahead "Speed limit 30 in 100 yards". A camera: "Speed camera ahead, 30 miles per hour limit, in 300 yards"; in an average speed check, "Average speed check, 50 miles per hour limit. Your average 53 miles per hour, over the limit". The status: "Can't find a route. Check your connection". The figures, units, sign patches and pictures on screen are hidden from the screen reader, so it never reads "0.2 mi" or "dot".

  • The map is one element, "Map, following your position" (or "showing the whole route", or "moved away from your position"), not the road names drawn on it.

  • Reading order: the banner, its lanes, the status, a camera alert, the trip panel (or the arrival card), the speed, then the buttons. The look is unchanged: the buttons still sit above the trip panel.

  • Buttons: Recentre, Route overview, Mute voice guidance (a toggle, pressed while muted: its name stays the same), Retry finding a route, and the arrival card's Next stop and End, which name the stop. Each is at least 48 points square to the finger (Retry's touch area reaches past its drawn edge), and shows an accent ring with a navy halo when it has the focus of a keyboard, Switch Control or Full Keyboard Access.

  • What is announced unprompted (one polite live region): each new manoeuvre once, a change of guidance status ("No GPS signal", "Finding a new route", "New route. 2 minutes longer"), a speed camera when it is first warned of (an average speed check once, not its average), going over the speed limit ("Over the speed limit: 35 in a 30", once each time, after the same second's steadying as the red), and an arrival. Never a distance counting down or the speed changing. When an AtlasVoice is attached to the map (Swift and Kotlin map.voice = voice, React Native's deviceVoice prop, Flutter's map.voice) and not muted, the manoeuvres and cameras are left to it (it says each camera, "Speed camera ahead, 30 limit"), so the screen reader and the voice don't talk over each other. A voice with speaksCameraAlerts off still counts as speaking.

  • Large text: Dynamic Type and Android's font size, up to 1.5 times (The map).

  • Reduce Motion (iOS) and Remove animations (Android): the camera cuts to the overview, back to the car and to a new zoom instead of easing, and the panels don't slide, pop or pulse.

  • Increase Contrast (iOS) and high-contrast text or a raised contrast level (Android): the panels go opaque with a visible edge, and white text sits on Meridian's deeper blues.

  • Contrast, measured on the panels as drawn, the translucent ones over the brightest map there can be (WCAG 2.2 AA: 4.5:1 for text, 3:1 for large text and icons):

    DayNightIncrease Contrast
    Text on the panels (#F0F4FF)12.2:114.9:116.1:1
    Secondary text (#8FA3BF; #7D91AB at night; #A9B9CF)5.2:15.1:18.9:1
    Accent text and icons (#4F9CF9) on the panels4.75:15.8:16.3:1
    The banner's white text (the manoeuvre's verb is slightly translucent)2.5 to 2.8:1 on the accent6.3 to 7.6:1 on #2451A07.6:1 on #2451A0
    Retry, Next stop and End (white on the accent; accent-dark at night)2.8:14.0:1 (Retry 2.8:1)7.6:1
    The "Then" chip4.0:1 on #2D7DE811.3:1 on #1B3A6B11.3:1
    Over the limit: the speed (large) in the danger colour; its unit3.1:1; 11.0:13.8:1; 13.3:1white on #C42C42, 5.6:1
    An average speed check's average over the limitwhite on #C42C42, 5.6:1the samethe same

    By day the banner and the panels' main buttons are Meridian's accent blue, whose white text falls short of AA; Increase Contrast puts them on the deeper blue. The speed limit roundels are road signs, drawn as them (#111 on white, 18.9:1). Over the limit is shown by colour, a tinted panel and its border; the screen reader says it in words.

The viewer smoke test checks all of this in Chrome's accessibility tree, which Android's WebView shares (npm run test:viewer-smoke -- --cases accessibility).

What your app does

  • Leave the map view reachable. Don't make it, or a view that contains it, a single accessibility element (iOS isAccessibilityElement, Android importantForAccessibility="noHideDescendants" or a contentDescription on a container), and don't lay a transparent view over it: the panels' buttons are inside it.
  • Name your own controls over the map, and tell the map they cover it (setInsets), so the panels and the camera keep clear of them.
  • Attach the voice to the map if you speak guidance with AtlasVoice. With a voice of your own, the panels tell VoiceOver or TalkBack each manoeuvre as well.
  • Without navigationUI, your own panels' accessibility is yours: the map is one element, "Map".
  • Car screens: label the templates and buttons you add yourself. On CarPlay, give CPMapButtons and pictures an accessibilityLabel; on Android Auto an action's title is what is read, and the Car App Library gives the map's buttons no title or description, so Atlas's are icons (zoom in, zoom out, Route overview, Recentre) beside Android Auto's own Pan.
  • Test with the screen reader on, in a car or on the iOS Simulator's CarPlay window and the Desktop Head Unit for the car screens. The Accessibility Inspector's audit (Xcode) and Android's Accessibility Scanner check your own screens.
Proposal · draft