georgesboris/elm-widgets-alpha/4.4.0

NOTE: the latest version is 4.18.3

W.Modal

List Attribute
-> { isOpen : Bool
, onClose : Maybe msg
, content : List (Html msg)
}
-> Html msg
type alias Attribute =
Attr Attributes

Togglable

If you don't want to manage your modal open state at all, use the togglable version.

W.Modal.viewTogglable []
    { id = "togglable-modal"
    , content = [ text "Hello!" ]
    }


W.Modal.viewToggle "togglable-modal"
    [ W.Button.viewDummy []
        [ text "Click here to toggle modal" ]
    ]
viewToggle : String -> List (Html msg) -> Html msg
List Attribute
-> { id : String
, content : List (Html msg)
}
-> Html msg

Styles

maxWidth : Int -> Attribute
zIndex : Int -> Attribute
background : String -> Attribute
backgroundOpacity : Float -> Attribute
noBlur : Attribute
absolute : Attribute