-
Notifications
You must be signed in to change notification settings - Fork 46
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
expanded: true opens all groups #15
Comments
Do it this way instead: var baseLayers = [
This makes the Basemaps layer group expanded by default. Species Distribution overlay group is collapsed by default, and Points of Interest overlay group is expanded by default. Check out my example: |
I'm not sure how this solves my problem. Maybe I wasn't precise enough, but this happens when I'm dynamically adding groups and layers, not when I initialize the control. When I dynamically add a new group with |
@neothemachine I understand the problem. Really I did not write the ability to expand a group dynamically. I am currently struggling to find time to update the plugin, but if you are willing to look at the code and create a pull request ... |
@stretchkerr I enjoyed its application in https://dl.dropboxusercontent.com/u/7075784/Leaflet/Leaflet2.html Taking advantage of you is already with that application in a production environment? If so, you could share the link? Thank you. |
When I add a layer to a group (or implicitly create a new group), I want that group to be expanded, but not the other groups. When I set
expanded: true
in the options foraddOverlay
it opens all groups which I think is a bug.The text was updated successfully, but these errors were encountered: