Closed rklerck closed 6 years ago
Actually the provided sample dataset and style should render labels. Doesn't it work for you?
It doesn't.. Tried it again by cloning the rep but it doesn't work. Only real difference now is that I use "https://github.com/an-rahulpandey/cordova-plugin-dbcopy" and the base64js. But everything else is working, so I don't think that's a problem.
Could be an IOS problem, but not sure what it can be! This sucks.
ANDROID TEST I tested it on a Android device but I don't see any labels there! I have the exact same source code, but changed the fonts url to "http://fonts.openmaptiles.org/{fontstack}/{range}.pbf".
Because of that I changed the style to:
"layout": {
"text-field": "{housenumber}",
"text-size": 10,
"text-font": [
"Open Sans Regular"
]
},
When i check network traffic, the font pbf's are loaded correctly. But nothing is visible...
Great that your trying to fix this issue! I tested the new version on both Android and IOS, but labels don't work. Do I have to do something extra for it to work?
I changed the mapbox-gl-js dependency version. So make sure you do "npm install" and "npm run build" again.
BTW, mapbox-gl cannot handle multiple glyph sources, so the glyph URL actually used is the one from the first style loaded (the one you pass to the map constructor - empty.json in the example).
Please tell me if it worked. Thanks.
Working perfect on both Android and IOS, awesome job!
Sorry to keep firing questions, but this one is kinda essential. Did your labels show on the map? I have label layers in my style and glyphs configured correctly, but they are never shown... It looks like the layers aren't loaded from the tile.
It appears to go wrong because the layer isn't inside the bucket, so this won't return a layer for the symbol:
This is the data (without raw data) returned from the database: