Skip to content

Add select function to button#103

Open
scaddenp wants to merge 2 commits intoCliffCloud:masterfrom
scaddenp:master
Open

Add select function to button#103
scaddenp wants to merge 2 commits intoCliffCloud:masterfrom
scaddenp:master

Conversation

@scaddenp
Copy link

This simple addition added select and unselect method to buttons which add or remove a '.selected' class to the button. This is useful when controls activate a new mode (eg drawing) which captures mouse actions until deselected. A user can add a style like:
.leaflet-bar button.selected{
background-color: #666666 !important;
}

to style the button. I considered putting a default into the easybutton.css but though better of it.

@scaddenp scaddenp closed this Sep 22, 2021
@scaddenp scaddenp reopened this Sep 22, 2021
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.

1 participant