nitaliano / react-native-mapbox-gl

A Mapbox GL react native module for creating custom maps
Other
2.16k stars 697 forks source link

Base Outdoor Style Map Ghostly White #1507

Open systemlevel opened 5 years ago

systemlevel commented 5 years ago

In Mapbox studio I created a new map from the Outdoors base style. I did not modify anything. All I get when I load that style into the react-native-mapbox-gl is a white map that looks nothing like the base Outdoors style.

Why does it do this? How do you use any custom styles at all even ones that are not even modified?

screen shot 2019-02-12 at 2 17 11 pm

What's the difference between using "Mapbox.StyleURL.Outdoors" and using a style url which is based on the base Outdoors style? @nitaliano

nitaliano commented 5 years ago

it's probably using expressions, you need to make sure in Mapbox studio that you're not creating your map styles with them since they are not supported in the current native SDKs that are bundled with this library try this.

screen shot 2019-02-12 at 2 04 09 pm
systemlevel commented 5 years ago

@nitaliano thanks Nick. So how do I actually turn off expressions? I'm assuming you are suggesting changing the versions to reflect what you have in your screenshot. I have done that and hit "publish". However, here is what I'm getting when I use the mapbox style URL:

screen shot 2019-02-12 at 3 09 09 pm

Here's what the app is loading with the custom style URL:

screen shot 2019-02-12 at 3 11 34 pm

Still getting a blank white map. Again, I just created a new style using the Outdoors map as the base for the style. I did not make any edits or adjustments to that.

What's puzzling is if I use Mapbox.StyleURL.Outdoors it seems to load fine. Mapbox.StyleURL.Outdoors just uses "mapbox://styles/mapbox/outdoors-v10" which works but the moment I make a new map based on Outdoors everything goes white.

systemlevel commented 5 years ago

@nitaliano To clarify further. This is what I mean when I say I'm creating a new style based on the Outdoors basemap:

screen shot 2019-02-12 at 3 17 00 pm
systemlevel commented 5 years ago

@nitaliano Are my compatibility settings looking okay to you?

systemlevel commented 5 years ago

@zugaldia do you have any insights into this issue?

zugaldia commented 5 years ago

Hey @systemlevel - as @nitaliano pointed above this is probably something that will get fixed once https://github.com/mapbox/react-native-mapbox-gl/pull/1377 lands and update the React Native SDK to use more recent versions of the native libraries.

Meanwhile, you can verify if this is a native vs RN issue by using Studio Preview App (iOS, Android). This app only uses native code, so it you still see your style incorrectly rendered, then it's an issue with the native components. I hope it helps.

systemlevel commented 5 years ago

@zugaldia appreciate the reply and insights. I’ll give that a shot.