Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [mapbox-gl]

A client-side framework for rendering web maps with implementations on native platforms utilizing OpenGL.

0
votes
1answer
13 views

Mapbox gl expression to get match in text field

I am trying to set one of the values from feature properties to text-field depending on a property "text-field": [ "match", ["get","label"], "L1","{...
0
votes
1answer
14 views

Change dynamically created layer's minZoom after render

I want to change the minzoom of dynamically created layer after the rendering. I tried couple of things: map.getLayer('my_custom_layer'); // this gets the layer map.getLayer('my_custom_layer')....
1
vote
1answer
45 views

Mapbox GL JS/Android: Draw User's 3D Vector Layer of Buildings

Here: https://docs.mapbox.com/mapbox-gl-js/example/3d-buildings/ It's possible to draw 3D buildings by taking advantage of extrusions, however the 3D vector layer source is the Mapbox's underlying ...
0
votes
0answers
14 views

Putting inset map Popup in front using Mapbox GL?

I have maps of Hawaii and Alaska inset on a map of the continental US. All maps have markers and popups when you click the markers. How do I position the AK and HI popups so they are fully visible?
0
votes
0answers
105 views

How to add GeoServer WMS layer to Mapbox GL API?

I have been using GeoServer WMS layers with OpenLayers 3 and it is working well. Below is the code how I have used to add my GeoServer WMS layer to the Mapbox GL API: var mapOptions: MapboxOptions ...
0
votes
0answers
34 views

Categorical circle colour on mapbox gl js

Adapting the documented example here To produce the code below I get the following error. Error: "layers.circles-heat.paint.circle-color.stops[9][1]: color expected, "#5675d2" found" map....
0
votes
0answers
13 views

Filtering Custom Mapbox style implemented in Android

I created Custom Mapbox styles by importing Tilesets containing custom point locations in it.I implemented the same style in my android app.I can access the data inside each points by using ...
0
votes
1answer
37 views

Location is not accurate when replicating an existing feature and zooming in

I am trying to resolve an issue with the accuracy of a selected point using queryRenderedFeatures. The accuracy is fine when zoomed out, but when zooming in it appears off. I am using the ...
0
votes
0answers
33 views

Mapbox GL - change all marker symbols based on zoom

I am adding markers from a GeoJSON one by one. myGeoJSON.features.forEach(function(marker) { var elem = document.createElement('div'); var text = var text = document.createTextNode(marker....
0
votes
0answers
19 views

Using Mapbox, I have a filter input. As i type I would like the points to filter by words in the input

Below I have a code that basically filters as I move along the view which is good. However I would like to also include a portion within here that would make points disappear as I type in my search ...
0
votes
0answers
206 views

Adding select option menu to Mapbox map and filtering data source?

I'm attempting to add a drop down select menu for # of bedrooms to a mapbox map. The data source that I'm attempting to filter on is a geojson data file. I setup window onchange event listener ...
0
votes
1answer
123 views

How to post marker to Mapbox GL map

I'm following this tutorial about Mapbox GL and flask which has been going great until the step to add markers to the map. I've tried to distill it to make it as simple as possible but it's still not ...
0
votes
0answers
29 views

Display a popup with the information arranged in tabs using Mapbox GL JS

I'm creating a map in the Mapbox and I need When you click a point on the map the information is displayed in a popup. So far I can already do following this tutorial: https://www.mapbox.com/help/...
4
votes
0answers
77 views

Fixing buildings that do not appear in 3D using Mapbox gl js?

I'm trying to adopt this Display buildings in 3D example, but I found out that in my city (Minsk, Belarus) some buildings look flat like this: The coordinates of this particular building are 27....
0
votes
1answer
86 views

How to get GeoJOSN Features using Mapbox?

I'm using Mapbox to create webmapping, I want to get GeoJSON Features. I tried map.queryRenderedFeatures but it returns array empty. there are my code: map.on('load', function(e) { map.addSource("...
1
vote
0answers
84 views

WMTS with Mapbox WebGL

I need to add a WMTS to a mapping application that uses mapbox-webgl (this is a React App using react-map-gl). There is no support for WMTS in mapbox-webgl but it seems like I should be able to do ...
1
vote
0answers
121 views

How to update circle-color or marker symbol on update of a source property in Mapbox GL?

I am trying to get Mapbox GL work in my React code as below: I have a property called strength in each of my features in a FeatureCollection of a mapbox-gl map. I want to display a circle (ideally a ...
1
vote
0answers
144 views

Mapbox multiple filters to layers

I'm new to Mapbox GL and want to understand how i would go about the following; I have 5 principle layers (from the same source, all vector tiles from Geoserver) which will only be drawn in ...
0
votes
1answer
516 views

Set border width and color in Mapbox GL

I'm working on an application based on Mapbox GL, I need to give to the user the opportunity to set the width and the color of the borders of polygons but I can't find the right GeoJSON proprieties to ...
2
votes
1answer
233 views

Can I use a browser's developer tools to see the zoom level of current map in browser?

What I'm looking for Where a map is being served by Mapbox in my browser is there anywhere within the Chrome/Firefox Developer Tools where it shows the current zoom level as displayed on screen? ...
0
votes
1answer
162 views

Mapbox GL JS Toggle Layers default to “off”

Using Mapbox's 'Toggle Layer' example, how would I load the map with the "contours" and "museums" layers turned off? I want the layers to be turned "off" by default and have the user turn "on" the ...
0
votes
1answer
197 views

Mapbox GL JS - toggling 2 layers

I'm using Mapbox's Show and Hide Layer example where the user can toggle on/off layers, but seem to be running into an issue I can't pinpoint. What I did In Mapbox's example, I replace the first ...
0
votes
0answers
129 views

Mix raster and vector tiles with tileserver-gl

I am quite new to vector tiles. Up until now my app only used our own self made raster tiles. Now we'd like to have vector tiles as well, but still keep our high quality hill shading as vector. We'd ...
2
votes
3answers
2k views

React Native - react-native-mapbox-gl vs react-native-maps

I have to develop apps with React Native for mobile that concern with mapping and found out there are two libraries for Native on this - react-native-mapbox-gl and react-native-maps. From github pages ...
1
vote
1answer
112 views

Combining popup info from overlapping polygons in Mapbox Studio?

I'm trying to display popup information from overlapping polygons similar to this question, but instead of a click, I'm using the mouse over to identify my popup. In areas that have overlapping ...
0
votes
0answers
99 views

Mapbox minimum zoom extent

I uploaded a custom shapefile (converted to geoJSON) using the mapbox python SDK and visualize it in a Jupyter Notebook using the MapboxGL python module. After I successfully upload the GeoJSON file ...
0
votes
0answers
170 views

Consume ArcGIS REST API in MapBox's React Native Library

I’m currently working on a weather app built in React Native. In the process, I’ve come to learn a lot about mapping technologies and GIS in general. My immediate goal is to display radar imagery in ...
1
vote
1answer
150 views

Mapbox Vector Tiles dropping features across tile boundaries

I'm currently working on a project that involves the creation of vector tiles from geojson files. These vector tiles are then displayed using Mapbox GL JS. Recently, we've ran into an issue where ...
0
votes
1answer
64 views

Workflow to create global mapbox tileset

I am in process of creating a hiking map rendered from OSM data using Mapbox. It works quite fine already, however some data are missing in the Mapbox Streets V7 datasets, namely: bus stops power ...
0
votes
0answers
197 views

Vector Tiles: Considering a rule, change each building color of Buildings layer

I'm consuming a Mapbox hosted map with Mapbox GL (but if needed, I can use leaflet or whatever) that has the standard Mapbox street layers including OSM Buildings layer plus a custom layer uploaded by ...
0
votes
0answers
316 views

Popups offset from points Mapbox GL JS

I've been playing a lot with mapbox for mapping some data of mine. I have created a map that is heavily borrowed from the original mapbox sweetgreen tutorial here. However, now that I am almost ...
2
votes
1answer
4k views

How to add CSS styling in Mapbox GL Popup?

I am aware this is similar to many other questions, but I have been unable to determine how to add the correct code to style my popups in mapbox-gl. I'm very new to CSS, Mapbox-gl, and coding in ...
1
vote
2answers
86 views

Symbolizing field with many values in Mapbox Studio?

I am using Mapbox Studio and trying to symbolize my Tileset which has about 200 unique values. I am able to create individual 'stops' and manually assign a unique color, but looking for a more ...
2
votes
1answer
1k views

Making legends for each layers and switching between them using Mapbox GL JS?

I created a map using Mapbox GL JS with several layers using this example At the same time I don't have any spatial knowledge in Javascript. It's restrict me to create legends for each layers. The ...
0
votes
1answer
117 views

Geocoding to only reference Tileset using Mapbox GL JS?

I'm using Mapbox's Geocoding (search box) and was wondering if there's a way that it would only reference my Tileset data rather than the generic global address search? Looks like Mapbox has a "...
0
votes
1answer
392 views

How to return count of popups opened up by clicking on a mapbox gl map feature?

I’ve a point dataset with overlapping points. For each feature a popup is created automatically. When I click on a point with other overlapping point on it all popups are opened up and it’s messed up. ...
2
votes
1answer
1k views

Leaflet MapBox Issue of poly line which crosses the International dateline

I am using mapbox leaflet js in my application "https://api.mapbox.com/mapbox.js/v3.0.1/mapbox.js". Previously i was using google map, I am facing an issue when i draw a polyline in map which crosses ...
1
vote
1answer
3k views

Custom icon for clusters in Mapbox GL Js

Is it possible to use a custom icon instead of a circle and a symbol (with the cluster_count string) for Mapbox GL Js' "Superclusters?" My goal here is to approximate something like Pie Clusters or ...
1
vote
1answer
397 views

Filter geojson file to Get last 24 Hours Data [closed]

i am using mapbox platform to showing the map in my site. geojson is having time attribute Ex: "time":1510301955145 I want to show the map of last 24 hours.
0
votes
1answer
337 views

How can I use icons on a my own maptiles klokantech docker container?

If I take this example: https://www.mapbox.com/mapbox-gl-js/example/geojson-markers/ an change the mapsource from: style: 'mapbox://styles/mapbox/light-v9' to my own docker container: var map = ...
1
vote
1answer
115 views

tippocanoe feature filter not working

I use tippocanoe to build Mapbox Vector Tiles from GEOJSON features but can't get the filter to work. I use a geojson file which contains millions of features and want to filter them for different ...
0
votes
1answer
341 views

Mapbox GL control visibility on multiple labels using zoom attribute

I have a point dataset that is intended only as labels. Each label has a pre-calculated minZoom attribute to one decimal place, e.g. 6.1. While there are labels that share the same value, they vary ...
2
votes
1answer
1k views

Building an interactive web map that displays table data in a static portion of the page separate from the map?

I am trying to build an interactive web map to display the results of my master's thesis. Basically, it is a shapefile of line segments that have each been assigned to 1 out of 8 categories. The ...
2
votes
0answers
211 views

CartoCSS to MapboxGL

I have some old styles in CartoCSS and some I have found online. However obviously with the update of mapbox studio it uses Mapbox GL styling and the two are different. I can't see a way of ...
1
vote
0answers
348 views

Mapbox gl : How to perform a filter in a polygon?

I want to make a filter on the geometry of my layer source vector. var polygone = ..... var filter = polygone.reduce(function (memo, coord) { memo.push(coord); return memo; }, ['in', '$...
1
vote
0answers
163 views

Mapbox GL JS and GeoJson Files [closed]

Currently, I am creating GeoJson files using QGIS and render them in Mapbox GL JS. I create 10 GeoJson files for each map. I am wondering what is the best practice to render the files in Mapbox GL JS. ...
2
votes
1answer
963 views

Render raster tiles from a Mapbox GL style

I'm struggling to put together the appropriate stack for rendering raster tiles (for display of slippy maps) from a given Mapbox GL style. Style specifications: First there were the Mapnik XML ...
3
votes
1answer
4k views

Removing events map.on(“click”…) from mapbox gl?

I am removed the layers with map.removeLayer("clusters"); but got this error evented.js:111 The layer 'clusters' does not exist in the map's style and cannot be queried for features. as I have ...
1
vote
1answer
626 views

Difference of Mapzen Vector Tiles (mvt) to pbf extracted from .mbtiles

I was wondering what is the difference between a mvt tile and a pbf extracted from a .mbtiles container using mbutil? Mvt is in pbf as well. The pbf is supposed to be a vector tile as well. They are ...
3
votes
0answers
108 views

Appropriate GeoJSON type for grouping many anonymous objects

I'm writing a converter that produces GeoJSON. My source data has multiple layers of discrete objects over a few square miles. For example: Shuttle Stops: ~25 polygons Shuttle Routes: ~10 line ...