samedi 24 novembre 2018

Very very Simple AngularJS Dropdown displaying a list of values with multiselect checkboxes

Very very Simple AngularJS Dropdown displaying a list of values with multiselect checkboxes

I would like to make a dropdown with a list of values, where one can multiselect among these values with a checkbox on each value in the dropdown list. I want to be able to react to the event when one checks or unchecks the checkbox for one of the values I display in dropdown.

I would like the solution to be as simple as possible, so if it can be made without some custom directive, or third party library. I would prefer that.

So basically I just want to display a totally plain AngularJS drop down, with a check box for each value in the dropdown list. Something like just adding a checkbox to it and make it able to perform multiselect. The dropdown should also be scrollable. https://docs.angularjs.org/api/ng/directive/select

I have found some more complex solutions to give you an idea about what I want: enter code herehttps://codepen.io/elmahdim/pen/hlmri enter code herehttps://jsfiddle.net/michaeldeongreen/22et6sao/9/ But I find these solutions too complex and would like something really simple if possible.




Aucun commentaire:

Enregistrer un commentaire