From d11e4c9544f544b3a024c7ac705a674b4096cf50 Mon Sep 17 00:00:00 2001 From: grm Date: Sun, 13 Sep 2026 00:38:24 +0300 Subject: Add the Layout tab: five areas with modules, columns and a menu editor A blog page is now header, left column, main content, right column and footer, each holding an ordered list of modules (blog title, logo, menu, archive by year/month, recent posts, custom HTML, footer text, RSS link, site map). Side columns have percentage widths, can be hidden, and can keep their space when empty; on phones they stack under the posts. The menu becomes its own ordered list mixing pages and outside links. Announcements are placed per column at its top or bottom. Modules and menu items get tables; the migration derives them from each blog's old theme (nav position, footer text, show-in-nav pages) so existing blogs look the same. Custom HTML is deliberately stored and served as-is (owner's decision; see AGENTS.md for why the blast radius is the blogger's own origin). Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01Sd8UPWrvyYCLj97JexNw3A --- internal/web/templates/dashboard/design.html | 54 ++++------ internal/web/templates/dashboard/layout.html | 113 +++++++++++++++++++++ internal/web/templates/dashboard/module_form.html | 34 +++++++ internal/web/templates/dashboard/overview.html | 2 +- internal/web/templates/dashboard/pages.html | 6 +- internal/web/templates/dashboard/section_form.html | 14 ++- internal/web/templates/dashboard/sections.html | 2 +- 7 files changed, 183 insertions(+), 42 deletions(-) create mode 100644 internal/web/templates/dashboard/layout.html create mode 100644 internal/web/templates/dashboard/module_form.html (limited to 'internal/web/templates/dashboard') diff --git a/internal/web/templates/dashboard/design.html b/internal/web/templates/dashboard/design.html index af482fe..342cabe 100644 --- a/internal/web/templates/dashboard/design.html +++ b/internal/web/templates/dashboard/design.html @@ -5,7 +5,8 @@

Design

Changes are live as soon as you save; refresh your blog ↗ to see them.

-

SchemesBackgroundTextHeaderMenuPostsFooterIcon

+

SchemesBackgroundTextHeaderMenuPostsFooterLogo & icon

+

What appears where — header, columns, footer and their modules — is arranged on the Layout tab.

Colour schemes

@@ -81,12 +82,13 @@ -
+

Width only applies while there are no side columns; with a left or right column the blog uses the whole page.

- +

The title, logo and menu are header modules — add, remove and order them on the Layout tab. The banner below is shown across the top of the header whenever one is chosen.

{{template "imagepick" (dict "name" "header_image" "current" $t.HeaderImage "images" .Data.images "label" "Header image (banner)")}}