55 lines
1.5 KiB
OCaml
55 lines
1.5 KiB
OCaml
open Drame
|
|
open Tyxml.Html
|
|
open Lang
|
|
|
|
let get request =
|
|
let txt_choice = txt_choice request in
|
|
let class' =
|
|
a_class [ "about-subgrid"; "left"; "no-indent"; "inline-padded" ]
|
|
in
|
|
let bio =
|
|
let photo =
|
|
let alt = { fr = "Une photo de moi."; en = "Picture of myself." } in
|
|
img request ~a:[] ~src:Sitemap.me ~alt
|
|
in
|
|
|
|
let p_l = List.map (fun o -> p [ txt_choice o ]) About_data.bio_p_l in
|
|
let bio_txt =
|
|
div (h3 [ txt_choice { fr = "Bonjour,"; en = "Hello," } ] :: p_l)
|
|
in
|
|
div ~a:[ class' ] [ photo; bio_txt ]
|
|
in
|
|
let approach =
|
|
let title =
|
|
h2
|
|
[ txt_choice
|
|
{ fr = "MA PRATIQUE ET VISION DE L'ARCHITECTURE"
|
|
; en = "MY APPROACH AND VISION OF ARCHITECTURE"
|
|
}
|
|
]
|
|
in
|
|
let p_l = List.map (fun o -> p [ txt_choice o ]) About_data.approach_p_l in
|
|
let approach_txt = div p_l in
|
|
div ~a:[ class' ] [ title; approach_txt ]
|
|
in
|
|
let desk =
|
|
let img =
|
|
img request ~a:[]
|
|
~src:(Sitemap.img Contact.contact_img.name)
|
|
~alt:Contact.contact_img.alt
|
|
in
|
|
let button_like_link_to_contact =
|
|
a
|
|
~a:[ a_href Sitemap.contact ]
|
|
[ txt_choice { fr = "Une question ?"; en = "A question?" } ]
|
|
in
|
|
div ~a:[ a_class [ "about-contact" ] ] [ img; button_like_link_to_contact ]
|
|
in
|
|
|
|
let content = div ~a:[ a_class [ "about-grid" ] ] [ bio; approach; desk ] in
|
|
|
|
let h1 = { en = "About"; fr = "À propos" } in
|
|
|
|
let doc = Template.render request ~h1 content in
|
|
Ok (Content.Html doc)
|