record wild cards are bad actually
This commit is contained in:
parent
ef7f2685c0
commit
3cd7bc98f6
2 changed files with 6 additions and 6 deletions
|
@ -16,7 +16,7 @@ make :: Info -> Lazy.Text
|
|||
make = toLazyText . make'
|
||||
|
||||
make' :: Info -> Builder
|
||||
make' (Info {..}) =
|
||||
make' (Info {date, title, tags, description, images, links}) =
|
||||
"<!DOCTYPE html>\n" <>
|
||||
"<html lang=en>\n" <>
|
||||
"<meta charset=utf-8>\n" <>
|
||||
|
@ -46,7 +46,7 @@ make' (Info {..}) =
|
|||
" <a href=../>back to gallery</a>\n" <>
|
||||
"</nav>\n"
|
||||
where
|
||||
path0 = let Image {..} = Vector.head images in fromText path
|
||||
path0 = let Image {path} = Vector.head images in fromText path
|
||||
|
||||
|
||||
esc :: Strict.Text -> Builder
|
||||
|
@ -62,7 +62,7 @@ formatDate :: Day -> Builder
|
|||
formatDate = fromString . formatTime defaultTimeLocale "%e %#B %Y"
|
||||
|
||||
altButton :: Int -> Image -> Builder
|
||||
altButton i (Image {..}) =
|
||||
altButton i (Image {label, path, nsfw}) =
|
||||
" <li>\n" <>
|
||||
" <input type=radio " <> checked <> "id=\"" <> idLabel <> "\" " <>
|
||||
"name=variant autocomplete=off\n" <>
|
||||
|
@ -88,7 +88,7 @@ indent n txt = spaces <> go (Strict.unpack txt) where
|
|||
spaces = fromString $ replicate n ' '
|
||||
|
||||
extLink :: Link -> Builder
|
||||
extLink (Link {..}) =
|
||||
extLink (Link {title, url}) =
|
||||
" <li>\n" <>
|
||||
" <a href=\"" <> fromText url <> "\">\n" <>
|
||||
" " <> fromText title <> "\n" <>
|
||||
|
|
|
@ -15,8 +15,8 @@ executable make-pages
|
|||
BlockArguments,
|
||||
DuplicateRecordFields,
|
||||
LambdaCase,
|
||||
OverloadedStrings,
|
||||
RecordWildCards
|
||||
NamedFieldPuns,
|
||||
OverloadedStrings
|
||||
build-depends:
|
||||
base ^>= 4.12.0.0,
|
||||
containers ^>= 0.6.0.1,
|
||||
|
|
Loading…
Reference in a new issue