Description
Removing SplitMapControl
doesn't update the map layers, if I remove this control, I would expect to leave the map as it was before of adding it? this, however doesn't happen in the MapView
who triggered the event, but if I create a new view, it removes successfully the added layres.
To recreate
Screencast.from.04-10-2024.11.28.59.webm
from ipyleaflet import Map, TileLayer, SplitMapControl
center = [34.6252978589571, -77.34580993652344]
zoom = 10
m = Map(center=center, zoom=zoom)
left = TileLayer(
url="https://cartodb-basemaps-{s}.global.ssl.fastly.net/light_all/{z}/{x}/{y}.png"
)
right = TileLayer(
url="https://cartodb-basemaps-{s}.global.ssl.fastly.net/dark_all/{z}/{x}/{y}.png"
)
control = SplitMapControl(left_layer=left, right_layer=right)
m.add(control)
And, then....
m.remove(control)
Metadata
Metadata
Assignees
Labels
No labels