Minor changes to the templates, added about and projects.

master
LijeroM 2018-05-05 18:07:53 -07:00
parent 67212ebd17
commit 97c6683981
6 changed files with 95 additions and 15 deletions

23
about/index.hs Normal file
View File

@ -0,0 +1,23 @@
module Page where
import HtmlGen
import Templates
lastModified :: String
lastModified = "2018-05-05"
sitemap :: Sitemap
sitemap = baseSitemap aboutUrl
`withLastMod` lastModified
`withPriority` "0.8"
`withChangeFreq` "weekly"
page :: Html
page = simplePage "About Lijero" "Lijero" lastModified $
article
%> (h1 %>> "About")
%> (p
%>> "I am a programmer, musician, and hiker. I seek beauty, elegance, and cleanliness in everything I do."
%>> "I write Agda, Haskell, and Java. I enjoy making programming languages and constructed human languages."
%>> "This page is, like the rest of the site, obviously incomplete."
)

View File

@ -2,15 +2,19 @@ module Page where
import Templates
import HtmlGen.Html
import HtmlGen.Tags
import HtmlGen.Sitemap
import HtmlGen
lastModified :: String
lastModified = "2018-05-05"
sitemap :: Sitemap
sitemap = baseSitemap "https://lijero.co/index.xhtml" `withLastMod` "2018-05-05"
sitemap = baseSitemap "https://lijero.co/index.xhtml"
`withLastMod` lastModified
`withPriority` "1.0"
`withChangeFreq` "weekly"
page :: Html
page = simplePage "Lijero" "Lijero" "2018-05-05" $
page = simplePage "Lijero" "Lijero" lastModified $
article
%> (h1 %>> "Home Page")
%> (p %>> "Sorry! This site is currently under construction.")

35
projects/index.hs Normal file
View File

@ -0,0 +1,35 @@
module Page where
import HtmlGen
import Templates
lastModified :: String
lastModified = "2018-05-05"
sitemap :: Sitemap
sitemap = baseSitemap projectsUrl
`withLastMod` lastModified
`withPriority` "0.8"
`withChangeFreq` "weekly"
page :: Html
page = simplePage "Lijero's Projects" "Lijero" lastModified $
article
%> (h1 %>> "Projects")
%> (h2 %>> "Programming")
%> (p
%>> "All of my active programming projects may be found on "
%> (href githubUserUrl $ text "my Github page")
%>> ". My most notable projects include my work-in-progress programming language "
%> (href (githubQiplProjectUrl "qipl-agda") $ text "Qipl")
%>> " and my contributions to "
%> (href (githubUrl ++ "HazenRobotics/ftc_app") $ text "Hazen Robotics")
%>> "."
)
%> (h2 %>> "Audiobooks")
%> (p
%>> "I am currently working on recording The Grapes of Wrath for my English teacher"
%>> "due to a lack of quality recordings of it. You may find that series in "
%> (href (baseUrl ++ "gow/") $ text "its YouTube playlist")
%>> "."
)

@ -1 +1 @@
Subproject commit aef2e729730166c2928307f65d4f5f80bf789b24
Subproject commit ee8ceaca33d16a07a8b1128398150daf11867c06

View File

@ -1,10 +1,13 @@
module Templates where
module Templates
( module Templates
, module Templates.Urls
, module Templates.Icons
) where
import Templates.Urls
import Templates.Icons
import HtmlGen.Html
import HtmlGen.Tags
import HtmlGen
basePage :: String -> String -> Html -> Html
basePage pageTitle authorName content =
@ -26,7 +29,7 @@ navSection =
%> (spanTag `withId` "navbrand" %>> "Lijero")
%> unorderedList
[ href baseUrl $ text "Home"
, href qiplUrl $ text "Qipl"
, href projectsUrl $ text "Projects"
, href aboutUrl $ text "About"
]
@ -36,11 +39,11 @@ footerSection authorName dateModified =
%> (divTag `withClass` "metadata"
%> (spanTag
%> authorIcon
%>> ' ' : authorName
%>> ' ' : authorName ++ " "
)
%> (spanTag
%> updatedIcon
%>> ' ' : dateModified
%>> ' ' : dateModified ++ " "
)
%> license
)

View File

@ -1,7 +1,7 @@
module Templates.Urls where
baseUrl :: String
baseUrl = "//lijero.co/"
baseUrl = "https://lijero.co/"
resUrl :: String
resUrl = baseUrl ++ "res/"
@ -15,8 +15,23 @@ ccbysaUrl = "http://creativecommons.org/licenses/by-sa/4.0/"
stylesheetCommonUrl :: String
stylesheetCommonUrl = resUrl ++ "common.css"
qiplUrl :: String
qiplUrl = baseUrl ++ "qipl/"
projectsUrl :: String
projectsUrl = baseUrl ++ "projects/"
aboutUrl :: String
aboutUrl = baseUrl ++ "about/"
githubUrl :: String
githubUrl = "https://github.com/"
githubUserUrl :: String
githubUserUrl = githubUrl ++ "LijeroM/"
githubProjectUrl :: String -> String
githubProjectUrl name = githubUserUrl ++ name ++ "/"
githubQiplUrl :: String
githubQiplUrl = githubUrl ++ "qipl/"
githubQiplProjectUrl :: String -> String
githubQiplProjectUrl name = githubQiplUrl ++ name ++ "/"