meveo-org / mv-select

0 stars 1 forks source link

handle new data attribute "not-selectable" #13

Open sophieperrineau opened 1 year ago

sophieperrineau commented 1 year ago

Curently options has the following properties:

{
  label, // string or html template to render as the label
  value, // object value of the option
  childrens /childrens
}

After the changes, we'll have :

{
  label, // string or html template to render as the label
  value, // object value of the option
  childrens, /childrens
  not-selectable // is ti possible to select the option => default false
}

It won't be possible to select options having the attribute "not-selectable". If a not-selectble attribute has some childs, it is possible to click on it, in order to select / unselect all the childs