From f4f00c2d8a1db81bb45e076106624a17f42e8f96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B5=AA=E5=AD=90?= Date: Mon, 20 May 2024 19:32:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=AF=B4=E8=AF=B4=E5=8E=BB?= =?UTF-8?q?=E9=99=A4=E5=88=86=E7=B1=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hugo.toml | 14 +++++++------- layouts/section/memos.html | 38 +++++++++++++++++--------------------- 2 files changed, 24 insertions(+), 28 deletions(-) diff --git a/hugo.toml b/hugo.toml index a24d77b..bfc0213 100644 --- a/hugo.toml +++ b/hugo.toml @@ -14,19 +14,19 @@ theme = 'farallon' [[languages.zh-cn.menu.main]] name="影音" url="/movies/" - weight="5" + weight="3" [[languages.zh-cn.menu.main]] - name="分类" - url="/categories/" - weight="4" + name="说说" + url="/memos/" + weight="2" [[languages.zh-cn.menu.main]] name="标签" url="/tags/" - weight="3" + weight="4" [[languages.zh-cn.menu.main]] - name="文章" + name="归档" url="/archives/" - weight="2" + weight="5" [[languages.zh-cn.menu.main]] name="首页" url="/" diff --git a/layouts/section/memos.html b/layouts/section/memos.html index 1cd2e9e..6f4adde 100644 --- a/layouts/section/memos.html +++ b/layouts/section/memos.html @@ -1,24 +1,20 @@ {{ define "main" }} -
- {{- range (where (where .Site.Pages "Type" "in" "memo") "Kind" "page").GroupByDate "2006" }} - {{ if (where .Pages "Section" "memo") }} -

{{ .Key }}

- {{ range .Pages.ByPublishDate.Reverse.GroupByDate "January" }} -

{{ .Key }}

- - {{ end }} - {{ end }} - {{ end }} -
+ {{ end }} + + {{ $paginator := .Paginate (where .Pages "Type" "posts") }} + {{partial "pagination.html" .}} + {{ end }} \ No newline at end of file