mirror of
https://github.com/FoggedLens/iD.git
synced 2026-03-31 09:19:25 +02:00
prevent pasting when map features are hidden (#10000)
This commit is contained in:
@@ -11,6 +11,10 @@ export function behaviorPaste(context) {
|
||||
// prevent paste during low zoom selection
|
||||
if (!context.map().withinEditableZoom()) return;
|
||||
|
||||
// prevent paste if the pasted object would be invisible (see #10000)
|
||||
const isOsmLayerEnabled = context.layers().layer('osm').enabled();
|
||||
if (!isOsmLayerEnabled) return;
|
||||
|
||||
d3_event.preventDefault();
|
||||
|
||||
var baseGraph = context.graph();
|
||||
|
||||
Reference in New Issue
Block a user