-
Notifications
You must be signed in to change notification settings - Fork 365
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add position to Maps add method #1156
Add position to Maps add method #1156
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a nice addition! Would you be able to add some ui-tests for this?
Also, I would rename position
into index
, what do you think?
ipyleaflet/leaflet.py
Outdated
@@ -2676,13 +2676,15 @@ def __isub__(self, item): | |||
def __add__(self, item): | |||
return self.add(item) | |||
|
|||
def add(self, item): | |||
def add(self, item, position=None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
def add(self, item, position=None): | |
def add(self, item, index=None): |
I added the UI tests, I also added the collapsed option to the LayerControl since that was easier then getting playwright to hover the mouse and take a screenshot |
You probably forgot to commit the files for that? Only |
lol woops |
update galata references |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Add
position
parameter to Mapsadd
method, allowing users to specify where in the layers stack they would add their new layer.