Hugo内容

This commit is contained in:
2026-02-27 11:41:19 +08:00
parent 544c97c013
commit 4f7f72b65f
37 changed files with 795 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
<!DOCTYPE html>
<html lang="{{ $.Site.LanguageCode }}">
{{- partial "head.html" . -}}
<body a="{{ $.Site.Params.theme_config.appearance | default "auto" }}">
<main class="page-content" aria-label="Content">
<div class="w">
{{- block "main" . }}{{- end }}
{{ partial "footer.html" }}
</div>
</main>
</body>
</html>

View File

@@ -0,0 +1,8 @@
{{ define "main" }}
{{ partial "back_link.html" .}}
<h1>{{ .Title }}</h1>
{{ .Content }}
{{ partial "post_list.html" (dict "context" . "section" .Section)}}
{{ end }}

View File

@@ -0,0 +1,21 @@
{{ define "main" }}
{{ partial "back_link.html" .}}
<article>
<p class="post-meta">
<time datetime="{{ .Date }}">
{{ .Date | time.Format site.Params.theme_config.date_format }}
</time>
</p>
<h1>{{ .Title }}</h1>
{{ if .Params.toc }}
<aside {{ if .Params.tocBorder }} class="toc" {{ end }}>
{{ .TableOfContents }}
</aside>
{{ end }}
{{ .Content }}
</article>
{{ end }}

View File

@@ -0,0 +1,8 @@
{{ define "main" }}
{{ partial "back_link.html" .}}
<h1>{{ .Title }}</h1>
{{ .Content }}
{{ partial "post_list.html" (dict "context" .)}}
{{ end }}

View File

@@ -0,0 +1,8 @@
{{ define "main" }}
{{ partial "back_link.html" .}}
<h1>{{ .Title }}</h1>
{{ .Content }}
{{ partial "post_list.html" (dict "context" .)}}
{{ end }}