Add service layer#12
Merged
Merged
Conversation
Adds RouteMapPoiLayer + RouteMapPoiCategory for clustered, optionally interactive point-of-interest overlays. Features: * Declarative API mirroring NoServiceAreaLayer — pass a list of POI layers to RouteMap and visibility can be toggled via the controller. * Categories render as pin-shaped markers matching the visual style of regular RouteMapIcons (same markerPath + RouteMapIconTheme). * Optional clustering with configurable circle + count-text appearance. * GeoJSON-expression labels with light/dark mode colors. * Per-feature tap events forwarded via onPoiTapped. Extracts the pin-marker rasterization logic from RouteMapIconManager into the reusable rasterizePinMarker helper so both regular icons and POI categories share the exact same rendering.
Make RouteMapIconTheme.foreground nullable. When null, rasterizePinMarker keeps the original fill/stroke attributes of the SVG instead of overriding them — useful for multi-color brand icons. Asserts that foreground is non-null whenever a RouteMapIcon renders text.
TarekTolba1
reviewed
Jun 29, 2026
TarekTolba1
approved these changes
Jun 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add clustered POI layer support
Adds first-class support for clustered point-of-interest overlays on top of RouteMap, mirroring the declarative style of NoServiceAreaLayer.
Motivation
Consumers (e.g. route-ticket-app) need to render service points and border crossings as clustered, interactive markers. Previously this had to be hand-rolled against the underlying MapLibreMapController. This PR ports that pattern into route_map as a reusable API.
What's new