From dd13e4b73a105ee416b6cfd8eb19b217622c0031 Mon Sep 17 00:00:00 2001 From: grm Date: Sat, 12 Sep 2026 12:33:57 +0300 Subject: Add announcements: blog-wide notices on every page and post A blog can have any number of announcements ("sections" in the schema): a book club's next meeting, this month's pick, a holiday closure. Each has a placement (above or below the posts, or under the menu when the menu is a left sidebar), a look (highlighted, warning, plain), an order, and an on/off switch so recurring notices can be kept around while hidden. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01Sd8UPWrvyYCLj97JexNw3A --- internal/web/templates/layouts/blog.html | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'internal/web/templates/layouts') diff --git a/internal/web/templates/layouts/blog.html b/internal/web/templates/layouts/blog.html index 7e3128e..ac6595b 100644 --- a/internal/web/templates/layouts/blog.html +++ b/internal/web/templates/layouts/blog.html @@ -19,9 +19,11 @@ {{if eq .Data.theme.NavPosition "below-header"}}{{template "blognav" .}}{{end}}
- {{if eq .Data.theme.NavPosition "left-sidebar"}}{{template "blognav" .}}{{end}} + {{if eq .Data.theme.NavPosition "left-sidebar"}}{{template "blognav" .}}{{if .Data.sidebar}}{{end}}{{end}}
+ {{template "notices" .Data.above}} {{template "content" .}} + {{template "notices" .Data.below}}