implemented header and footer
This commit is contained in:
parent
7a4b7c9105
commit
7218db542b
@ -8,6 +8,13 @@ let html_of ymd =
|
||||
(title (Unsafe.data ymd_title))
|
||||
[link ~rel:[`Stylesheet] ~href:"style.css" ();]
|
||||
)
|
||||
(body [Unsafe.data ymd_body])
|
||||
(body [
|
||||
header [
|
||||
h1 [Unsafe.data ymd_title];
|
||||
details (summary [Unsafe.data ymd.Logarion.meta.abstract]) [];
|
||||
];
|
||||
Unsafe.data ymd_body;
|
||||
footer [p []];
|
||||
])
|
||||
in
|
||||
Format.asprintf "%a" (Tyxml.Html.pp ()) tyhtml
|
||||
|
@ -39,6 +39,7 @@ let log_meta yaml =
|
||||
abstract = "" } in
|
||||
let field_map meta (k,v) = match k with
|
||||
| "title" -> { meta with title = v }
|
||||
| "abstract" -> { meta with abstract = v }
|
||||
| _ -> meta
|
||||
in
|
||||
List.fold_left field_map m fields
|
||||
|
Loading…
x
Reference in New Issue
Block a user