module Drasil.Website.Documentation where
import Language.Drasil
docsSec :: FilePath -> Section
docsSec :: FilePath -> Section
docsSec FilePath
path =
Sentence -> [Contents] -> [Section] -> Reference -> Section
section Sentence
haddockDocsTitle
[Sentence -> Contents
mkParagraph forall a b. (a -> b) -> a -> b
$ FilePath -> Sentence
haddockDocsDesc FilePath
path]
[] forall a b. (a -> b) -> a -> b
$ FilePath -> Sentence -> Reference
makeSecRef FilePath
"Documentation" forall a b. (a -> b) -> a -> b
$ FilePath -> Sentence
S FilePath
"Documentation"
haddockDocsTitle :: Sentence
haddockDocsTitle :: Sentence
haddockDocsTitle = FilePath -> Sentence
S FilePath
"Haddock Documentation"
haddockDocsDesc :: FilePath -> Sentence
haddockDocsDesc :: FilePath -> Sentence
haddockDocsDesc FilePath
path = FilePath -> Sentence
S FilePath
"Drasil's framework is primariliy written in Haskell, \
\so we use Haddock to document our code. The following link will take you \
\to the current" Sentence -> Sentence -> Sentence
+:+ forall r.
(HasUID r, HasRefAddress r, HasShortName r) =>
r -> Sentence -> Sentence
namedRef (FilePath -> Reference
docsRef FilePath
path) (FilePath -> Sentence
S FilePath
"Haddock documentation")
Sentence -> Sentence -> Sentence
+:+ FilePath -> Sentence
S FilePath
"for the Drasil framework. A variant with"
Sentence -> Sentence -> Sentence
+:+ forall r.
(HasUID r, HasRefAddress r, HasShortName r) =>
r -> Sentence -> Sentence
namedRef (FilePath -> Reference
fullDocsRef FilePath
path) (FilePath -> Sentence
S FilePath
"fully exposed modules") Sentence -> Sentence -> Sentence
+:+ FilePath -> Sentence
S FilePath
"is also available."
docsRef, fullDocsRef :: FilePath -> Reference
docsRef :: FilePath -> Reference
docsRef FilePath
path = FilePath -> FilePath -> ShortName -> Reference
makeURI FilePath
"haddockDocs" (FilePath
path forall a. [a] -> [a] -> [a]
++ FilePath
"index.html") forall a b. (a -> b) -> a -> b
$ Sentence -> ShortName
shortname' forall a b. (a -> b) -> a -> b
$ FilePath -> Sentence
S FilePath
"HaddockDocs"
fullDocsRef :: FilePath -> Reference
fullDocsRef FilePath
path = FilePath -> FilePath -> ShortName -> Reference
makeURI FilePath
"fullHaddockDocs" (FilePath
path forall a. [a] -> [a] -> [a]
++ FilePath
"full/index.html") forall a b. (a -> b) -> a -> b
$ Sentence -> ShortName
shortname' forall a b. (a -> b) -> a -> b
$ FilePath -> Sentence
S FilePath
"fullHaddockDocs"
docRefs :: FilePath -> [Reference]
docRefs :: FilePath -> [Reference]
docRefs FilePath
path = [FilePath -> Reference
docsRef FilePath
path, FilePath -> Reference
fullDocsRef FilePath
path]