From f8541ef965ca22e746b523eb418e47cb4f78f2d8 Mon Sep 17 00:00:00 2001 From: Arne Rief Date: Fri, 9 Jan 2026 12:24:05 +0100 Subject: Upgrade to new template system from Hugo v0.146.0 --- layouts/partials/list/pagination.html | 28 -------------- layouts/partials/list/post-card.html | 66 --------------------------------- layouts/partials/list/recent-posts.html | 45 ---------------------- 3 files changed, 139 deletions(-) delete mode 100644 layouts/partials/list/pagination.html delete mode 100644 layouts/partials/list/post-card.html delete mode 100644 layouts/partials/list/recent-posts.html (limited to 'layouts/partials/list') diff --git a/layouts/partials/list/pagination.html b/layouts/partials/list/pagination.html deleted file mode 100644 index dfe8178..0000000 --- a/layouts/partials/list/pagination.html +++ /dev/null @@ -1,28 +0,0 @@ -{{- $paginator := . }} -{{- if gt $paginator.TotalPages 1 }} - -{{- end }} diff --git a/layouts/partials/list/post-card.html b/layouts/partials/list/post-card.html deleted file mode 100644 index 6444701..0000000 --- a/layouts/partials/list/post-card.html +++ /dev/null @@ -1,66 +0,0 @@ -{{- /* -Card with a summary of and link to a post. Accepts a dict with the following parameters: - -@context {Page} post: The post to display. -@context {bool} show_section: Whether to display a badge with the name of the section the post was published under (default: false). - -@example: {{ partial "list/post-card.html" (dict "post" . "show_section" true) }} -*/ -}} - -{{- $post := .post -}} -{{- $showSection := .show_section | default false -}} -
-
-

- - {{ $post.Title }} - -

-
- - - {{- if $showSection }} - - {{ lang.Translate ($post.Section | singularize) | default ($post.Section | singularize | title) }} - - {{- end }} -
-
- - {{- with $post.Summary }} -
- {{ . }} -
- {{- end }} - - {{- with $post.Params.tags }} -
-
    - {{- range first 3 . }} -
  • - #{{ . }} -
  • - {{- end }} - {{- if gt (len .) 3 }} -
  • - - +{{ sub (len .) 3 }} {{ lang.Translate "more" | default "more" }} - -
  • - {{- end }} -
-
- {{- end }} -
diff --git a/layouts/partials/list/recent-posts.html b/layouts/partials/list/recent-posts.html deleted file mode 100644 index 464e9f7..0000000 --- a/layouts/partials/list/recent-posts.html +++ /dev/null @@ -1,45 +0,0 @@ -{{- /* -List of specified number of the most recent and published posts. Accepts a dict with the following optional parameters: - -@context {int} count: Number of posts to display (default: 10). -@context {string} title: Section title (default: "Recent Articles"). -@context {bool} show_view_all: Whether to show "View All Posts" link (default: true). - -@example: {{ partial "list/recent-posts.html" (dict "count" 20 "title" "Latest updates" "show_view_all" true) }} -*/ -}} - -{{- $count := .count | default 10 -}} -{{- $title := .title | default (lang.Translate "posts_recent" | default "Recent Articles") -}} -{{- $showViewAll := .show_view_all | default true -}} -
-
-

- {{ $title }} -

-
- - {{- $recentPosts := where site.RegularPages "Params.excludeFromLists" "!=" true | first $count }} - {{- if $recentPosts }} -
-
    - {{- range $recentPosts }} -
  • - {{- partial "list/post-card.html" (dict "post" . "show_section" true) }} -
  • - {{- end }} -
- - {{- if $showViewAll }} - {{- with site.GetPage "/all-posts"}} - - {{ lang.Translate "posts_all_view" | default "View all posts" }} » - - {{- end }} - {{- end }} -
- {{ else }} -

- {{ lang.Translate "list_empty" | default "No posts in this section." }} -

- {{- end }} -
-- cgit v1.2.3