From f16bd0f79c624665580615321b5d13b4be27cdad Mon Sep 17 00:00:00 2001 From: grm Date: Thu, 17 Sep 2026 17:09:01 +0300 Subject: Add the Gizmo look for announcements: framed boxes that share a row gizmolab's "next event" and "next assembly" boxes were hand-written HTML in the home page's intro; they are announcements by nature, so now they can be: a fourth style, a box framed in the theme's link colour with an italic heading. Headed Gizmo boxes in the same spot share a row on wide screens (the notices wrapper is a flex row, stacking on old browsers like .cols); one without a heading takes the whole row, which is how a banner line goes above a pair of boxes. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01Sd8UPWrvyYCLj97JexNw3A --- internal/web/templates/dashboard/section_form.html | 2 ++ internal/web/templates/dashboard/sections.html | 2 +- internal/web/templates/layouts/blog.html | 4 +++- 3 files changed, 6 insertions(+), 2 deletions(-) (limited to 'internal/web/templates') diff --git a/internal/web/templates/dashboard/section_form.html b/internal/web/templates/dashboard/section_form.html index 0171aaa..0a0e4ea 100644 --- a/internal/web/templates/dashboard/section_form.html +++ b/internal/web/templates/dashboard/section_form.html @@ -20,8 +20,10 @@ + +

{{t "Gizmo is a box framed in your link colour. Gizmo boxes with a heading share a row on wide screens (up to three); one without a heading takes the whole row."}}

{{t "“Top” of a side column means above its modules, “bottom” below them. If that column is not shown on your blog (see"}} {{t "Design"}}) {{t "the announcement moves to the main content instead."}}

{{template "editor" (dict "name" "body" "value" $s.BodyMD "format" $s.Format "rows" 10 "tall" false "upload" (print "/b/" .Blog.Subdomain "/files/upload") "preview" (print "/b/" .Blog.Subdomain "/preview") "csrf" .CSRF)}} diff --git a/internal/web/templates/dashboard/sections.html b/internal/web/templates/dashboard/sections.html index 4d62f29..9f0e314 100644 --- a/internal/web/templates/dashboard/sections.html +++ b/internal/web/templates/dashboard/sections.html @@ -17,7 +17,7 @@ {{if .Title}}{{.Title}}{{else}}({{t "untitled"}}){{end}}{{if not .Enabled}}{{t "hidden"}}{{end}} {{if eq .Column "main"}}{{t "Main content"}}{{else if eq .Column "left"}}{{t "Left column"}}{{else}}{{t "Right column"}}{{end}}, {{t .Position}} - {{if eq .Style "note"}}{{t "Highlighted"}}{{else if eq .Style "warning"}}{{t "Warning"}}{{else}}{{t "Plain"}}{{end}} + {{if eq .Style "note"}}{{t "Highlighted"}}{{else if eq .Style "warning"}}{{t "Warning"}}{{else if eq .Style "gizmo"}}{{t "Gizmo"}}{{else}}{{t "Plain"}}{{end}}
{{t "delete"}} diff --git a/internal/web/templates/layouts/blog.html b/internal/web/templates/layouts/blog.html index 6e8b819..76475b9 100644 --- a/internal/web/templates/layouts/blog.html +++ b/internal/web/templates/layouts/blog.html @@ -43,10 +43,12 @@ {{end}} -{{define "notices"}}{{range .}}