From 66543c0b3449b5dfc48c3b6a62b0387788b69d3f Mon Sep 17 00:00:00 2001 From: yingyu5658 Date: Sun, 21 Dec 2025 15:36:23 +0800 Subject: chore: set up weekly archetype and refine homepage layout * Remove the banner in index.md * Add default cover and ending template to weekly.md archetype * Remove the banner from homepage * Refactor recent-posts.md * tweak related CSS styles --- layouts/partials/style.html | 4 ++-- layouts/shortcodes/recent-posts.html | 37 +++++++++++++++++++++--------------- 2 files changed, 24 insertions(+), 17 deletions(-) (limited to 'layouts') diff --git a/layouts/partials/style.html b/layouts/partials/style.html index e922440..14b2eea 100644 --- a/layouts/partials/style.html +++ b/layouts/partials/style.html @@ -31,7 +31,7 @@ } img.missing { - display: none; + display: none; } nav a, @@ -79,7 +79,7 @@ } h1.post-title { - margin-top: 5vh; + margin-top: 2vh; margin-bottom: 10px; text-align: center; } diff --git a/layouts/shortcodes/recent-posts.html b/layouts/shortcodes/recent-posts.html index c6c1a3e..0d1d955 100644 --- a/layouts/shortcodes/recent-posts.html +++ b/layouts/shortcodes/recent-posts.html @@ -1,5 +1,5 @@ {{ $pages := where site.RegularPages "Type" "in" site.Params.mainSections }} {{ -$recent := first 5 $pages.ByDate.Reverse }} +$recent := first 8 $pages.ByDate.Reverse }}
- {{ if $recent }} - - {{ else }} + +
+ {{ end }} {{ else }}

暂无文章

{{ end }} -- cgit v1.2.3