diff options
| author | Eltrac <hi@guhub.cn> | 2025-04-25 22:36:33 +0800 |
|---|---|---|
| committer | Eltrac <hi@guhub.cn> | 2025-04-25 22:36:33 +0800 |
| commit | 33198f399b7f85f235a4e1235af46cbced33a1a9 (patch) | |
| tree | b14949c3e1b6428d1d6b584d7fe48d3b1aab8fdc /layouts/_default/term.html | |
| parent | f16f881bcea1ceed37a95a87b9b8bd1caaaaab9c (diff) | |
feat: separate cards and other pages in term page
Diffstat (limited to 'layouts/_default/term.html')
| -rw-r--r-- | layouts/_default/term.html | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/layouts/_default/term.html b/layouts/_default/term.html index 43e86953..7cab2827 100644 --- a/layouts/_default/term.html +++ b/layouts/_default/term.html @@ -11,8 +11,8 @@ {{ end }} <div class="term-list"> - <ul> - {{ range .Pages }} + <ul class="term-list-posts"> + {{ range where .Pages "Section" "ne" "cards" }} <li> <a href="{{ .RelPermalink }}" data-umami-event="Click Post Link from Category Page"> {{ .Title }}{{ with .Params.subtitle }}:<span class="posts-subtitle">{{. }}</span> @@ -22,8 +22,21 @@ {{ .Date.Format "2006-1-2" }} </time> </li> - {{ end }} + {{ end }} </ul> + <div class="term-list-cards"> + {{ range where .Pages "Section" "eq" "cards" }} + <div class="card"> + <h3> + <a href="{{ .RelPermalink }}" data-umami-event="Click Card Link from Category Page"> + {{ .Title }} + </a> + </h3> + <p>{{ .Summary }}</p> + </div> + {{ end }} + </div> </div> </article> + {{ partial "footer.html" . }} {{ end }} |
