diff lib/ur/basis.urs @ 2077:3cd2bd4b1de0

More simple textual HTML5 input types
author Adam Chlipala <adam@chlipala.net>
date Sun, 16 Nov 2014 14:16:11 -0500
parents 855d7746a084
children 6d126af2e1cb
line wrap: on
line diff
--- a/lib/ur/basis.urs	Sun Nov 16 14:06:24 2014 -0500
+++ b/lib/ur/basis.urs	Sun Nov 16 14:16:11 2014 -0500
@@ -956,12 +956,21 @@
 val textbox : formTag string [] ([Value = string, Size = int, Placeholder = string, Source = source string, Onchange = transaction unit,
                                   Ontext = transaction unit] ++ boxAttrs ++ inputAttrs)
 val password : formTag string [] ([Value = string, Size = int, Placeholder = string, Onchange = transaction unit] ++ boxAttrs ++ inputAttrs)
-val email : formTag string [] ([Value = string, Size = int, Placeholder = string, Onchange = transaction unit] ++ boxAttrs ++ inputAttrs)
 val textarea : formTag string [] ([Rows = int, Cols = int, Onchange = transaction unit,
                                    Ontext = transaction unit] ++ boxAttrs ++ inputAttrs)
 
 val checkbox : formTag bool [] ([Checked = bool, Onchange = transaction unit] ++ boxAttrs)
 
+(* HTML5 widgets galore! *)
+
+type textWidget = formTag string [] ([Value = string, Size = int, Placeholder = string, Onchange = transaction unit] ++ boxAttrs ++ inputAttrs)
+
+val email : textWidget
+val search : textWidget
+val url_ : textWidget
+val tel : textWidget
+
+
 type file
 val fileName : file -> option string
 val fileMimeType : file -> string