Skip to content

Conversation

@ak8abhinay
Copy link

I noticed that the current "Extract" operation can be a bit destructive. When you extract a named feature (like pool) from an area, it often wipes the original area clean, leading to "Area has no descriptive tags" validation errors.

This PR updates the tool about what it moves and what it keeps. It also ensures the tool doesn't appear for standalone objects where extraction wouldn't make sense.

Changes
actions/extract.js file : I added a list of identityKeys (like amenity, leisure, shop, etc.) that stay on the original area after extraction. This prevents the area from becoming "naked" and keeps it valid on the map.

Protecting the level tag and it is now kept on the original geometry rather than being moved to the point.

operations/extract.js file : Modified the tool's availability so it hides itself if an object has no parent ways or no other tags. This prevents users from accidentally turning a standalone building into a single point.

The new extracted node now receives a copy of the identity tags, ensuring it has the correct icon and remains searchable in the editor.

I tested everything locally and above mentioned solutions are working perfectly in the editor.

Fixes #11830

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bad extract of a swimming pool

1 participant