mapbox-maps-ios
mapbox-maps-ios copied to clipboard
Add Cluster Support for Point Annotation Managers
Fixes: #1475
This PR enables clustering on point annotation managers, achieving parity with the Android implementation. Developers using this feature will pass a set of ClusterOptions when creating a pointAnnotationManager. This will configure cluster options on the GeoJSON Source, create a series of circle layers for each level of clustering, and add a text layer to display the cluster count.
In addition, this PR creates a new example to demo this functionality and new unit tests.
https://user-images.githubusercontent.com/7976026/196284010-54c9890e-5c04-4a86-9216-c84a37a0e8f9.mp4
Pull request checklist:
- [X] Describe the changes in this PR, especially public API changes.
- [X] Include before/after visuals or gifs if this PR includes visual changes.
- [X] Write tests for all new functionality. If tests were not written, please explain why.
- [X] Add documentation comments for any added or updated public APIs.
- [ ] Add any new public, top-level symbols to the Jazzy config's
custom_categories
(scripts/doc-generation/.jazzy.yaml) - [ ] Add a changelog entry to to bottom of the relevant section (typically the
## main
heading near the top). - [ ] Update the guides (internal access only), README.md, and DEVELOPING.md if their contents are impacted by these changes.
- [ ] If this PR is a
v10.[version]
release branch fix / enhancement, merge it tomain
first and then port tov10.[version]
release branch.
PRs must be submitted under the terms of our Contributor License Agreement CLA.