From 371b9a8098f43b0cad614cec9c8026defd207b27 Mon Sep 17 00:00:00 2001 From: Tissevert Date: Wed, 30 Sep 2020 11:44:19 +0200 Subject: [PATCH] Fix missing '
  • ' around pages by factorizing the 'li_' into navigationSection --- src/DOM.hs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/DOM.hs b/src/DOM.hs index aff7749..ef2fb31 100644 --- a/src/DOM.hs +++ b/src/DOM.hs @@ -72,9 +72,8 @@ mDLink raw (Markdown {Markdown.path, title}) = url = absoluteLink $ path <.> (if raw then "md" else "html") tag :: String -> HtmlGenerator () -tag name = li_ ( - a_ [href_ . pack $ absoluteLink name ++ "/", class_ "tag"] $ toHtml name - ) +tag name = + a_ [href_ . pack $ absoluteLink name ++ "/", class_ "tag"] $ toHtml name defaultBanner :: HtmlGenerator () defaultBanner = @@ -99,7 +98,7 @@ navigationSection sectionId templateKey generator collection | otherwise = div_ [id_ sectionId, class_ "navigator"] (do h2_ . toHtml =<< template templateKey [] - ul_ . mapM_ generator $ Map.toList collection + ul_ . mapM_ (li_ . generator) $ Map.toList collection ) htmlDocument :: HasContent a => a -> HtmlGenerator ()