openlayers / openlayers/openlayers
Modify Interaction - ModifyEnd event return only one feature when we create a point on two touching polygons
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 12.6k
- Forks
- 3.2k
- Avg merge
- 2d 17h
- Merged PRs (30d)
- 21
Description
Description
When we create a new point in a line touching two polygons and drag it, the modifyend event only returns one feature.
This seems wrong as the points effectively gets created in the two polygons, furthermore modifying that points a second time the modifyend event then return the two features.
To Reproduce
Steps to reproduce the behavior:
- Go to https://codesandbox.io/s/modify-features-forked-x1ivn?fontsize=14&hidenavigation=1&theme=dark
- Click on the line between two countries to modify the polygons by adding a point.
- See that their is only one feature in the logged array.
- Modify that same point, the two features are then correctly logged.
Expected behavior
When creating a point in a line touching two (or more?) polygons, the modifyend event should return all affected polygons.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Run the linked CodeSandbox and reproduce the case with two touching polygons. Trace the Modify interaction and its modifyend event handling from the reproduction, then verify that creating a shared point reports every affected polygon while repeated modification still behaves correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend, web-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100