Mercurial > urweb
comparison lib/basis.urs @ 361:260b680a6a04
lform -> form
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Tue, 14 Oct 2008 16:41:48 -0400 |
parents | 383c72d11db8 |
children | acaf9d19fbb7 |
comparison
equal
deleted
inserted
replaced
360:c1e96b387115 | 361:260b680a6a04 |
---|---|
281 | 281 |
282 con xhtml = xml [Html] | 282 con xhtml = xml [Html] |
283 con page = xhtml [] [] | 283 con page = xhtml [] [] |
284 con xbody = xml [Body] [] [] | 284 con xbody = xml [Body] [] [] |
285 con xtr = xml [Body, Tr] [] [] | 285 con xtr = xml [Body, Tr] [] [] |
286 con xform = xml [Body, LForm] [] [] | 286 con xform = xml [Body, Form] [] [] |
287 | 287 |
288 (*** HTML details *) | 288 (*** HTML details *) |
289 | 289 |
290 con html = [Html] | 290 con html = [Html] |
291 con head = [Head] | 291 con head = [Head] |
292 con body = [Body] | 292 con body = [Body] |
293 con form = [Body, LForm] | 293 con form = [Body, Form] |
294 con tabl = [Body, Table] | 294 con tabl = [Body, Table] |
295 con tr = [Body, Tr] | 295 con tr = [Body, Tr] |
296 | 296 |
297 val head : unit -> tag [] html head [] [] | 297 val head : unit -> tag [] html head [] [] |
298 val title : unit -> tag [] head [] [] [] | 298 val title : unit -> tag [] head [] [] [] |
317 val h1 : bodyTag [] | 317 val h1 : bodyTag [] |
318 val li : bodyTag [] | 318 val li : bodyTag [] |
319 | 319 |
320 val a : bodyTag [Link = transaction page] | 320 val a : bodyTag [Link = transaction page] |
321 | 321 |
322 val lform : ctx ::: {Unit} -> bind ::: {Type} | 322 val form : ctx ::: {Unit} -> bind ::: {Type} |
323 -> fn [[Body] ~ ctx] => | 323 -> fn [[Body] ~ ctx] => |
324 xml form [] bind | 324 xml form [] bind |
325 -> xml ([Body] ++ ctx) [] [] | 325 -> xml ([Body] ++ ctx) [] [] |
326 con lformTag = fn (ty :: Type) (inner :: {Unit}) (attrs :: {Type}) => | 326 con formTag = fn (ty :: Type) (inner :: {Unit}) (attrs :: {Type}) => |
327 ctx ::: {Unit} | 327 ctx ::: {Unit} |
328 -> fn [[LForm] ~ ctx] => | 328 -> fn [[Form] ~ ctx] => |
329 nm :: Name -> unit | 329 nm :: Name -> unit |
330 -> tag attrs ([LForm] ++ ctx) inner [] [nm = ty] | 330 -> tag attrs ([Form] ++ ctx) inner [] [nm = ty] |
331 val textbox : lformTag string [] [Value = string] | 331 val textbox : formTag string [] [Value = string] |
332 val password : lformTag string [] [] | 332 val password : formTag string [] [] |
333 val ltextarea : lformTag string [] [] | 333 val textarea : formTag string [] [] |
334 | 334 |
335 val checkbox : lformTag bool [] [Checked = bool] | 335 val checkbox : formTag bool [] [Checked = bool] |
336 | 336 |
337 con radio = [Body, Radio] | 337 con radio = [Body, Radio] |
338 val radio : lformTag string radio [] | 338 val radio : formTag string radio [] |
339 val radioOption : unit -> tag [Value = string] radio [] [] [] | 339 val radioOption : unit -> tag [Value = string] radio [] [] [] |
340 | 340 |
341 con select = [Select] | 341 con select = [Select] |
342 val lselect : lformTag string select [] | 342 val select : formTag string select [] |
343 val loption : unit -> tag [Value = string] select [] [] [] | 343 val option : unit -> tag [Value = string] select [] [] [] |
344 | 344 |
345 val submit : ctx ::: {Unit} -> use ::: {Type} | 345 val submit : ctx ::: {Unit} -> use ::: {Type} |
346 -> fn [[LForm] ~ ctx] => | 346 -> fn [[Form] ~ ctx] => |
347 unit | 347 unit |
348 -> tag [Action = $use -> transaction page] | 348 -> tag [Action = $use -> transaction page] |
349 ([LForm] ++ ctx) ([LForm] ++ ctx) use [] | 349 ([Form] ++ ctx) ([Form] ++ ctx) use [] |
350 | 350 |
351 (*** Tables *) | 351 (*** Tables *) |
352 | 352 |
353 val tabl : unit -> tag [Border = int] [Body] [Body, Table] [] [] | 353 val tabl : unit -> tag [Border = int] [Body] [Body, Table] [] [] |
354 val tr : unit -> tag [] [Body, Table] [Body, Tr] [] [] | 354 val tr : unit -> tag [] [Body, Table] [Body, Tr] [] [] |