mapbox / geojson.io

A quick, simple tool for creating, viewing, and sharing spatial data
http://geojson.io/
ISC License
1.91k stars 567 forks source link

Cannot edit with custom Raster tile layer #891

Open Kris-B opened 5 months ago

Kris-B commented 5 months ago

When using a custom raster tile layer, it's possible to draw polygons, but it's not possible to edit points of the created polygon

mnalis commented 1 week ago

I can confirm that. Edit geometries button works fine on all built-in layers (Standard, Satellite streets, OSM etc). But when I click on custom layer (added via Meta / Add raster tile layer) it fails, and console logs:

instrument.js:108 Error: The layer 'gl-draw-symbol.cold' does not exist in the map's style and cannot be queried for features.
    at Ia.queryRenderedFeatures (mapbox-gl.js:37:565310)
    at Map.queryRenderedFeatures (mapbox-gl.js:37:665946)
    at M (mapbox-gl-draw.js:1:6331)
    at Object.touch (mapbox-gl-draw.js:1:6141)
    at i.touchstart (mapbox-gl-draw.js:1:24067)
    at Map.fire (mapbox-gl.js:31:88170)
    at i.fire (mapbox-gl-draw.js:1:23024)
    at ja._firePreventable (mapbox-gl.js:37:586084)
    at ja.touchstart (mapbox-gl.js:37:585834)
    at Sn.handleEvent (mapbox-gl.js:37:611214)
(anonymous) @ instrument.js:108
fire @ mapbox-gl.js:31
queryRenderedFeatures @ mapbox-gl.js:37
queryRenderedFeatures @ mapbox-gl.js:37
M @ mapbox-gl-draw.js:1
touch @ mapbox-gl-draw.js:1
i.touchstart @ mapbox-gl-draw.js:1
fire @ mapbox-gl.js:31
i.fire @ mapbox-gl-draw.js:1
_firePreventable @ mapbox-gl.js:37
touchstart @ mapbox-gl.js:37
handleEvent @ mapbox-gl.js:37

If I click back on any of the standard layers, it works again and I can click on the points to move/edit geometry