{-# LANGUAGE OverloadedStrings #-} -- | This module exports HTML combinators used to create documents. -- module Text.Blaze.Html5 ( module Text.Blaze , html , docType , a , abbr , address , area , article , aside , audio , b , base , bdo , blockquote , body , br , button , canvas , caption , cite , code , col , colgroup , command , datalist , dd , del , details , dfn , div , dl , dt , em , embed , fieldset , figcaption , figure , footer , form , h1 , h2 , h3 , h4 , h5 , h6 , head , header , hgroup , hr , htmlNoDocType , i , iframe , img , input , ins , kbd , keygen , label , legend , li , link , map , mark , menu , meta , meter , nav , noscript , object , ol , optgroup , option , output , p , param , pre , progress , q , rp , rt , ruby , samp , script , section , select , small , source , span , strong , style , sub , summary , sup , table , tbody , td , textarea , tfoot , th , thead , time , title , tr , ul , var , video ) where import Prelude () import Data.Monoid (mappend) import Text.Blaze import Text.Blaze.Internal (parent, leaf, open) -- | Combinator for the @\@ element. This combinator will also -- insert the correct doctype. -- -- Example: -- -- > html $ span $ text "foo" -- -- Result: -- -- > -- > foo -- html :: Html a -- ^ Inner HTML. -> Html b -- ^ Resulting HTML. html inner = docType `mappend` htmlNoDocType inner {-# INLINE html #-} -- | Combinator for the document type. This should be placed at the top -- of every HTML page. -- -- Example: -- -- > docType -- -- Result: -- -- > -- docType :: Html a -- ^ The document type HTML. docType = preEscapedText "\n" {-# INLINE docType #-} -- | Combinator for the @\@ element. -- -- Example: -- -- > a $ span $ text "foo" -- -- Result: -- -- > foo -- a :: Html a -- ^ Inner HTML. -> Html b -- ^ Resulting HTML. a = parent "" {-# INLINE a #-} -- | Combinator for the @\@ element. -- -- Example: -- -- > abbr $ span $ text "foo" -- -- Result: -- -- > foo -- abbr :: Html a -- ^ Inner HTML. -> Html b -- ^ Resulting HTML. abbr = parent "" {-# INLINE abbr #-} -- | Combinator for the @\
@ element. -- -- Example: -- -- > address $ span $ text "foo" -- -- Result: -- -- >
foo
-- address :: Html a -- ^ Inner HTML. -> Html b -- ^ Resulting HTML. address = parent "" {-# INLINE address #-} -- | Combinator for the @\@ element. -- -- Example: -- -- > area -- -- Result: -- -- > -- area :: Html a -- ^ Resulting HTML. area = leaf "@ element. -- -- Example: -- -- > article $ span $ text "foo" -- -- Result: -- -- >
foo
-- article :: Html a -- ^ Inner HTML. -> Html b -- ^ Resulting HTML. article = parent "" {-# INLINE article #-} -- | Combinator for the @\