From ce13806c97c9fe46417e769a4c06f6a7e76c098e Mon Sep 17 00:00:00 2001 From: Rhiannon Morris Date: Thu, 17 Sep 2020 19:12:48 +0200 Subject: [PATCH] (re-)add tag counts to filter list --- make-pages/GalleryPage.hs | 4 ++-- style/shiny/gallery.css | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/make-pages/GalleryPage.hs b/make-pages/GalleryPage.hs index 6d2a6ba..d6b1e0f 100644 --- a/make-pages/GalleryPage.hs +++ b/make-pages/GalleryPage.hs @@ -107,10 +107,10 @@ make' root (GalleryInfo {title, desc, prefix, filters, hidden}) infos = [b|@0 | otherwise = "/style/card.png" makeFilter :: Text -> HashSet Text -> Text -> Int -> Builder -makeFilter prefix initial tag _count = [b|@8 +makeFilter prefix initial tag count = [b|@8
  • - + |] where id' = [b|$prefix$&_$tag'|] diff --git a/style/shiny/gallery.css b/style/shiny/gallery.css index 6cbedf3..78707c0 100644 --- a/style/shiny/gallery.css +++ b/style/shiny/gallery.css @@ -80,6 +80,11 @@ body { border: none; box-shadow: none; } +#filters label[data-count]::after { + content: '(' attr(data-count) ')'; + font-size: 80%; + padding-left: 0.25em; +} .grid { padding: 0;