From ae5793d52c8b186184c074869aab9386f79acadc Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Fri, 9 Feb 2024 14:23:34 +0100 Subject: Add headings to tag pages --- src/templates.ts | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src') diff --git a/src/templates.ts b/src/templates.ts index b8139f6..ac58a2c 100644 --- a/src/templates.ts +++ b/src/templates.ts @@ -118,6 +118,11 @@ async function renderListPage(tag: string, posts: Post[]) { const $feed = $(".h-feed"); const $tpl = $(".h-entry").remove(); $(".title").addClass("p-author h-card").attr("rel", "author"); + if (tag === "") { + $(".filter").remove(); + } else { + $(".filter").find("h3").text(`#${tag}`); + } for (const post of posts) { const $post = $tpl.clone(); -- cgit 1.4.1