Add post: 暗黑能天使

This commit is contained in:
2022-05-10 01:13:38 +08:00
parent e0a0b033ae
commit 90b654e708
104 changed files with 3185 additions and 7 deletions

View File

@@ -0,0 +1,29 @@
{{- $paginator := .Paginate .Pages }}
{{- $pages := .Paginator.Pages }}
{{- if eq .Type "authors" }}
{{- $pages = .Pages }}
{{- end }}
{{- with $pages }}
<script type="application/ld+json">
{
"@context":"https://schema.org",
"@type":"ItemList",
"itemListElement":[
{{- range $index, $value := . -}}
{{- if gt $index 0 -}},{{- end -}}
{
"@type":"ListItem",
"position": {{ add $index 1 }},
"name": {{ .Title }},
"description": {{ if .Description }}{{ .Description }}{{ else if .Summary }}{{ .Summary }}{{ else if .Site.Params.Description }}{{ .Site.Params.Description }}{{ end }},
{{- $img := partial "utils/get-image" (dict "context" . "url" .Params.featuredImage "keyword" "*featured*") }}
{{- with $img }}
"image": {{ . }},
{{- end }}
"url": {{ .Permalink }}
}
{{- end }}
]
}
</script>
{{- end }}