MultiSelect
<select> element with multiple selection.
This will properly give you the selected values for onChange event since the core onChange on select doesn't.
Options
Options for the dropdown.
* items is content of the dropdown.
* onChange is the message for when the selected value in the multi-select is changed.
Default Options, will give you empty multi-select with no empty item
Html element.
Put this in your view's Html content. Example:
type Msg = MultiSelectChanged (List String)
Html.div []
[ multiSelect
(defaultOptions MultiSelectChanged)
[ class "my-multiSelect" ]
model.selectedValues
]
Item is the individual content of the dropdown.
*
valueis the item value orid*textis the display text of the multi-select item. *enabledis a flag to indicate whether the item is enabled or disabled.