EngageSoftware / elm-engage-common / Engage.UI.Dropdown

UI.Dropdown


type alias Item =
{ value : String
, text : String
, enabled : Basics.Bool 
}

The Item type


type State

The State type

dropdown : { id : String, labelText : String, requiredText : Maybe String, items : List Item, onChange : { onlyStateChange : Basics.Bool } -> State -> Maybe String -> msg, status : Engage.UI.Error.Status, namespace : Engage.Namespace.Namespace, withEmptyItem : Basics.Bool } -> State -> Maybe String -> Html msg

Get the dropdown view

dropdownWithAttributes : { id : String, labelText : String, requiredText : Maybe String, items : List Item, onChange : { onlyStateChange : Basics.Bool } -> State -> Maybe String -> msg, status : Engage.UI.Error.Status, namespace : Engage.Namespace.Namespace, withEmptyItem : Basics.Bool } -> List (Html.Attribute msg) -> State -> Maybe String -> Html msg

Get the dropdown with attributes view

initialState : State

Get the initial State

reset : State -> State

Reset the State