[StyleReader] add support for field "tiles" in sources.
According to various map styles specification, the sources properties can ether hold a field url or a field tiles.
- https://docs.geotools.org/stable/userguide/extension/mbstyle/spec/sources.html
- https://developer.tomtom.com/map-display-api/documentation/mapstyles/map-style-specification#source-properties
- https://maplibre.org/maplibre-style-spec/sources/#sources
Currently tiles is not supported. The StyleReader. _readProviderByName makes the assomption that url is not null, but in the spec, url is not required.
Why do you need it? How would you use it?
I need it! This is the first part of the json file I need to use:
{ "version": 8, "name": "Xyz (local)", "metadata": { "mapbox:type": "template" }, "sources": { "openmaptiles": { "type": "vector", "attribution": "(c) xyz", "scheme": "xyz", "tiles": [ "https://services.xyz.nl/api/map/nl/{z}/{x}/{y}" ], "minzoom": 0, "maxzoom": 14 } }, "sprite": "https://services.xyz.nl/sprite", "glyphs": "https://services.xyz.nl/api/fonts/nl/{fontstack}/{range}", "layers": [ { "id": "basemap-background", "type": "background", "minzoom": 0, "paint": { "background-color": "rgba(245, 249, 236, 1)" } }, { "id": "basemap-park", "type": "fill",
This style file is according to the mapbox specs defined here: https://docs.mapbox.com/style-spec/reference/sources/
I've just merged a change that might do what you want: https://github.com/greensopinion/flutter-vector-map-tiles/blame/main/lib/src/style/style.dart#L108C7-L116
Feel free to provide feedback on this issue, and close it if it's working for you now.