mapbox / mapbox/mapbox-gl-draw

Delete vertex deletes whole polygon

Open
#953 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

bug ui
Dominant language
JavaScript
Stars
1.1k
Forks
612
Avg merge
8d 9h
Merged PRs (30d)
5

Description

mapbox-gl-js version: newest
mapbox-gl-draw version: newest

Steps to Trigger Behavior

It's randomly happening:

  1. Select a polygon
  2. Select a vertex (point), -> the yellow point goes bigger
  3. Delete the vertex

https://gifyu.com/image/mQuD

Expected Behavior

When I select a vertex and delete it (Del button or Trash icon) the selected vertex should be deleted.

Actual Behavior

Sometimes the whole polygon disappears sometimes only the selected vertex. I've tried many many times.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the behavior described in the issue: select a polygon, select a vertex, and delete it with the Delete key or Trash icon using the reported mapbox-gl-js and mapbox-gl-draw versions. Compare cases where only the vertex disappears with cases where the whole polygon disappears; done means deleting a vertex consistently preserves the polygon.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.