diff --git a/make-pages/ImagePage.hs b/make-pages/ImagePage.hs index 2935734..d828e20 100644 --- a/make-pages/ImagePage.hs +++ b/make-pages/ImagePage.hs @@ -63,12 +63,13 @@ formatDate = fromString . formatTime defaultTimeLocale "%e %#B %Y" altButton :: Int -> Image -> Builder altButton i (Image {label, path, nsfw}) = - "
  • \n" <> + " nsfwClass <> ">\n" <> " checked <> "id=\"" <> idLabel <> "\" " <> "name=variant autocomplete=off\n" <> " value=\"" <> fromText path <> "\">\n" <> " \n" where + nsfwClass = if nsfw then " class=nsfw" else "" checked = if i == 0 then "checked " else "" idLabel = escId label