add footer to index page
This commit is contained in:
parent
185f8d5ca4
commit
a29fff1094
3 changed files with 30 additions and 12 deletions
|
@ -6,11 +6,11 @@ import Data.Text.Lazy.Builder (Builder, toLazyText)
|
|||
import BuilderQQ
|
||||
import Info
|
||||
|
||||
make :: [GalleryInfo] -> Lazy.Text
|
||||
make ginfos = toLazyText $ make' ginfos
|
||||
make :: IndexInfo -> Lazy.Text
|
||||
make iinfo = toLazyText $ make' iinfo
|
||||
|
||||
make' :: [GalleryInfo] -> Builder
|
||||
make' ginfos = [b|@0
|
||||
make' :: IndexInfo -> Builder
|
||||
make' (IndexInfo {galleries, footer}) = [b|@0
|
||||
<!DOCTYPE html>
|
||||
<html lang=en>
|
||||
<meta charset=utf-8>
|
||||
|
@ -27,9 +27,13 @@ make' ginfos = [b|@0
|
|||
$4.items
|
||||
</ul>
|
||||
</main>
|
||||
|
||||
<footer>
|
||||
$4*footer
|
||||
</footer>
|
||||
|]
|
||||
where
|
||||
items = map makeItem ginfos
|
||||
items = map makeItem galleries
|
||||
|
||||
makeItem :: GalleryInfo -> Builder
|
||||
makeItem (GalleryInfo {title, prefix, filters}) = [b|@4
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue