/
EducationSection.hs
83 lines (77 loc) · 2.51 KB
/
EducationSection.hs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
module EducationSection (educationSection) where
import Text.XML.HXT.Core (XmlTree, ArrowXml, sattr, txt, mkelem)
import Common (h2, h3, ul, strong, link, cls, section, attrVal, mk, trs, q)
import Links (mkLink, Link(LinkCRGS, LinkGreyFriars))
educationSection :: (ArrowXml a) => a n XmlTree
educationSection = section [cls "educationSection"]
[ h2 "Education"
, mkelem "table" [cls "firstColFixedWidth"]
[ mk "tbody" $ trs [ msc, ba, aLevels, gcses ] ]
, h3 "Other courses"
, mkelem "table" [cls "firstColFixedWidth"]
[ mk "tbody" $ trs
[ attrVal [txt "Sep.–Nov. 2012"] []
[ q "Functional Programming Principles in Scala"
, txt " at Coursera. In progress."
]
, attrVal [txt "Nov.–Dec. 2012"] []
[ q "Cryptography"
, txt " at Coursera. In progress."
]
]
]
]
msc, ba, aLevels, gcses :: (ArrowXml a) => [a n XmlTree]
msc =
attrVal [txt "2010–12"] []
[ txt "M.Sc. with "
, strong "distinction"
, txt " in "
, link "http://www3.imperial.ac.uk/pgprospectus/facultiesanddepartments/computing/postgraduatecourses/computingscience" "Computing Science"
, txt " at "
, mkelem "strong" [] [link "http://www3.imperial.ac.uk/" "Imperial College London"]
, txt ". "
, txt "Individual project covered "
, q "verifying a balanced-tree index implementation in VeriFast" -- TODO: link
, txt "."
]
ba =
attrVal [txt "2006–9"] []
[ txt "B.A. with "
, strong "first-class"
, txt " honors in "
, link "http://www.york.ac.uk/history/undergraduate/" "History"
, txt " at the "
, mkelem "strong" [] [link "http://www.york.ac.uk/" "University of York"]
, txt "."
]
aLevels =
attrVal [txt "2004–6"] []
[ txt "Achieved the following ", strong "six A-levels", txt ":"
, mkelem "table" [cls "aLevelTable"]
[ mk "tbody" $
[ mk "tr" $ map (\s -> mk "th" [ txt s]) ["Grade", "Subject", "Institution"]
] ++ (map toRow subjects)
]
]
where
toRow (grade, subject, institution) =
mk "tr"
[ mk "td" [txt grade]
, mk "td" [txt subject]
, mk "td" [mkLink institution]
]
subjects =
[ ("A", "History" , LinkCRGS )
, ("A", "Computing" , LinkCRGS )
, ("A", "General Studies", LinkCRGS )
, ("B", "Physics" , LinkCRGS )
, ("B", "Mathematics" , LinkCRGS )
, ("B", "Art and Design" , LinkGreyFriars)
]
gcses =
attrVal [txt "2002–4"] []
[ txt "Eleven GCSEs at "
, mk "strong" [ mkLink LinkCRGS ]
, txt "."
]