view lib/basis.lig @ 104:b1e5398a7f30

Initial HTML attributes support
author Adam Chlipala <adamc@hcoop.net>
date Thu, 10 Jul 2008 15:04:32 -0400
parents 94afff1ff7f6
children da760c34f5ed
line wrap: on
line source
type int
type float
type string


con tag :: {Type} -> {Unit} -> {Unit} -> Type


con xml :: {Unit} -> Type
val cdata : ctx ::: {Unit} -> string -> xml ctx
val tag : attrsGiven ::: {Type} -> attrsAbsent ::: {Type} -> attrsGiven ~ attrsAbsent
        -> outer ::: {Unit} -> inner ::: {Unit}
        -> $attrsGiven
        -> tag (attrsGiven ++ attrsAbsent) outer inner
        -> xml inner
        -> xml outer
val join : shared :: {Unit}
        -> ctx1 ::: {Unit} -> ctx1 ~ shared
        -> ctx2 ::: {Unit} -> ctx2 ~ shared
        -> xml (shared ++ ctx1) -> xml (shared ++ ctx2) -> xml shared


val head : tag [] [Html] [Head]
val title : tag [] [Head] []

val body : tag [] [Html] [Body]
val p : tag [] [Body] [Body]
val b : tag [] [Body] [Body]
val i : tag [] [Body] [Body]
val font : tag [Size = int, Face = string] [Body] [Body]