diff options
author | Yorhel <git@yorhel.nl> | 2019-09-30 18:05:28 +0200 |
---|---|---|
committer | Yorhel <git@yorhel.nl> | 2019-09-30 18:05:41 +0200 |
commit | 2d7e855cfb37f35cb2cd0f8f39754002c20c8a7c (patch) | |
tree | b1ff536adee289c3b6e1a56c1f1a71acd1da6c87 /elm/Lib/Html.elm | |
parent | 24e08e0f2caf8dede4a0c8a77b8ede1e13899785 (diff) |
v2rw: Convert login, logout & insecure-password-change forms
The insecure-password-change flow is now slightly more friendly. The
logout functionality has been hardened to use POST and require CSRF.
Diffstat (limited to 'elm/Lib/Html.elm')
-rw-r--r-- | elm/Lib/Html.elm | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/elm/Lib/Html.elm b/elm/Lib/Html.elm index bbd2e1fb..41f6e376 100644 --- a/elm/Lib/Html.elm +++ b/elm/Lib/Html.elm @@ -53,6 +53,19 @@ inputText nam val onch attrs = input ( ) [] +inputPassword : String -> String -> (String -> m) -> List (Attribute m) -> Html m +inputPassword nam val onch attrs = input ( + [ type_ "password" + , class "text" + , tabindex 10 + , value val + , onInput onch + ] + ++ attrs + ++ (if nam == "" then [] else [ id nam, name nam ]) + ) [] + + inputTextArea : String -> String -> (String -> m) -> List (Attribute m) -> Html m inputTextArea nam val onch attrs = textarea ( [ tabindex 10 |