mirror of
https://github.com/foo-dogsquared/hugo-theme-contentful.git
synced 2025-01-30 22:57:55 +00:00
Update the theme
This commit is contained in:
parent
d9ece82910
commit
2b5b98df3e
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: "{{ replace .Name "-" " " | title }}"
|
title: "{{ humanize .Name }}"
|
||||||
date: {{ .Date }}
|
date: {{ .Date }}
|
||||||
draft: true
|
draft: true
|
||||||
|
|
||||||
@ -10,7 +10,7 @@ tags:
|
|||||||
- "tag2"
|
- "tag2"
|
||||||
---
|
---
|
||||||
|
|
||||||
= {{ replace .Name "-" " " | title }}
|
= {{ humanize .Name }}
|
||||||
{{ .Site.Author.name }} {{ with .Site.Author.email }}<{{ . }}>{{ end }}
|
{{ .Site.Author.name }} {{ with .Site.Author.email }}<{{ . }}>{{ end }}
|
||||||
{{ dateFormat "2006-01-02 15:04 -0700" .Date }}
|
{{ dateFormat "2006-01-02 15:04:05 -0700" .Date }}
|
||||||
:stem: latexmath
|
:stem: latexmath
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: "{{ replace .Name "-" " " | title }}"
|
title: "{{ humanize .Name }}"
|
||||||
date: {{ .Date }}
|
date: {{ .Date }}
|
||||||
draft: true
|
draft: true
|
||||||
|
|
||||||
|
@ -9,11 +9,12 @@
|
|||||||
/* The fonts. */
|
/* The fonts. */
|
||||||
--body-family: serif;
|
--body-family: serif;
|
||||||
--header-family: sans-serif;
|
--header-family: sans-serif;
|
||||||
|
--mono-family: monospace;
|
||||||
|
|
||||||
/* Spacing options. */
|
/* Spacing options. */
|
||||||
--font-size: 20px;
|
--font-size: 20px;
|
||||||
--vertical-rhythm: 24px;
|
--vertical-rhythm: 24px;
|
||||||
--content-width: 900px;
|
--content-width: 750px;
|
||||||
|
|
||||||
--border-style: var(--foreground) solid 1px;
|
--border-style: var(--foreground) solid 1px;
|
||||||
}
|
}
|
||||||
@ -73,6 +74,7 @@ a:visited {
|
|||||||
}
|
}
|
||||||
|
|
||||||
code {
|
code {
|
||||||
|
font-family: var(--mono-family);
|
||||||
font-size: 0.9em;
|
font-size: 0.9em;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -104,6 +106,7 @@ tr:nth-child(even) {
|
|||||||
pre {
|
pre {
|
||||||
background: var(--background-light);
|
background: var(--background-light);
|
||||||
border: var(--background) solid 1px;
|
border: var(--background) solid 1px;
|
||||||
|
font-family: var(--mono-family);
|
||||||
font-size: 1rem;
|
font-size: 1rem;
|
||||||
line-height: 1.5;
|
line-height: 1.5;
|
||||||
margin-top: 1rem;
|
margin-top: 1rem;
|
||||||
@ -259,3 +262,11 @@ footer {
|
|||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Automatic color scheme detection */
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
:root {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Table of contents autogenerated from Hugo */
|
@ -25,6 +25,9 @@ other = "Updated"
|
|||||||
[available_translations]
|
[available_translations]
|
||||||
other = "Translations"
|
other = "Translations"
|
||||||
|
|
||||||
|
[table_of_contents]
|
||||||
|
other = "Table of contents"
|
||||||
|
|
||||||
|
|
||||||
# General
|
# General
|
||||||
[and]
|
[and]
|
||||||
@ -35,3 +38,6 @@ other = "Back to home"
|
|||||||
|
|
||||||
[multilingual]
|
[multilingual]
|
||||||
other = "Available in other languages"
|
other = "Available in other languages"
|
||||||
|
|
||||||
|
[page_not_found]
|
||||||
|
other = "Page not found"
|
||||||
|
@ -25,6 +25,9 @@ other = "Binago noong"
|
|||||||
[available_translations]
|
[available_translations]
|
||||||
other = "Mga pagsasalin"
|
other = "Mga pagsasalin"
|
||||||
|
|
||||||
|
[table_of_contents]
|
||||||
|
other = "Talaan ng nilalaman"
|
||||||
|
|
||||||
|
|
||||||
# General
|
# General
|
||||||
[and]
|
[and]
|
||||||
@ -35,3 +38,6 @@ other = "Balik sa homepage"
|
|||||||
|
|
||||||
[multilingual]
|
[multilingual]
|
||||||
other = "Ibang lengwahe"
|
other = "Ibang lengwahe"
|
||||||
|
|
||||||
|
[page_not_found]
|
||||||
|
other = "Hindi makita ang webpage na hinahanap mo"
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
<h1>404</h1>
|
<h2>404</h2>
|
||||||
|
<p>{{ i18n "page_not_found" }}</p>
|
||||||
{{ end }}
|
{{ end }}
|
@ -2,10 +2,13 @@
|
|||||||
<hr>
|
<hr>
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
|
|
||||||
|
{{- /* The homepage should show only pages from the given sections (with `$.Site.Params.mainSections`).
|
||||||
|
Otherwise, we take the pages of a section. */ -}}
|
||||||
{{ $pages := .Pages }}
|
{{ $pages := .Pages }}
|
||||||
{{ if .IsHome }}
|
{{ if .IsHome }}
|
||||||
{{ $pages = where $.Site.RegularPages "Type" "in" $.Site.Params.mainSections }}
|
{{ $pages = where $.Site.RegularPages "Type" "in" $.Site.Params.mainSections }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ range (where (.Paginate $pages).Pages "Params.hidden" "!=" true) }}
|
{{ range (where (.Paginate $pages).Pages "Params.hidden" "!=" true) }}
|
||||||
<article class="post">
|
<article class="post">
|
||||||
<a href="{{ .Permalink }}" aria-label="{{ .Title }}"><h1>{{ .Title }}</h1></a>
|
<a href="{{ .Permalink }}" aria-label="{{ .Title }}"><h1>{{ .Title }}</h1></a>
|
||||||
|
@ -35,6 +35,12 @@
|
|||||||
|
|
||||||
{{ $is_toc := cond (ne .Params.toc nil) .Params.toc $.Site.Params.toc }}
|
{{ $is_toc := cond (ne .Params.toc nil) .Params.toc $.Site.Params.toc }}
|
||||||
{{ if $is_toc }}
|
{{ if $is_toc }}
|
||||||
|
<style>
|
||||||
|
#TableOfContents:not(:empty)::before {
|
||||||
|
content: "{{ i18n "table_of_contents" }}";
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
{{ .TableOfContents }}
|
{{ .TableOfContents }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
<title>{{ if .IsHome }}{{ $.Site.Title | safeHTML }}{{ else }}{{ .Title | safeHTML }}{{ end }}</title>
|
<title>{{ if .IsHome }}{{ $.Site.Title | safeHTML }}{{ else }}{{ .Title | safeHTML }}{{ end }}</title>
|
||||||
<link rel="stylesheet" href="{{ "css/main.css" | absURL }}" />
|
|
||||||
|
{{- $style := resources.Get "css/main.css" | resources.Minify | resources.Fingerprint -}}
|
||||||
|
<link rel="stylesheet" href="{{ $style.Permalink }}" />
|
||||||
|
|
||||||
{{- /* Some sane <meta> tags default */ -}}
|
{{- /* Some sane <meta> tags default */ -}}
|
||||||
{{ hugo.Generator }}
|
{{ hugo.Generator }}
|
||||||
|
Loading…
Reference in New Issue
Block a user