Fix issue with deprecated class and make accent a config var
This commit is contained in:
parent
2c8d89e4c3
commit
b4fe04727f
6 changed files with 12 additions and 21 deletions
7
.gitignore
vendored
7
.gitignore
vendored
|
|
@ -1,6 +1,3 @@
|
||||||
.hugo_build.lock
|
public/*
|
||||||
.DS_Store
|
|
||||||
resources/
|
|
||||||
todo.md
|
|
||||||
exampleSite/public/
|
|
||||||
.env
|
.env
|
||||||
|
.hugo_build.lock
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@
|
||||||
font-size: 75%;
|
font-size: 75%;
|
||||||
--color-dark: #1a1a1a;
|
--color-dark: #1a1a1a;
|
||||||
--color-light: #faf8f4;
|
--color-light: #faf8f4;
|
||||||
--color-primary: #EF9F27;
|
--color-primary: {{ .Site.Params.accentColor }};
|
||||||
--size: 1rem;
|
--size: 1rem;
|
||||||
--spacing: calc(var(--size) * 2.4);
|
--spacing: calc(var(--size) * 2.4);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
[params]
|
||||||
|
accentColor = "#EF9F27"
|
||||||
[module]
|
[module]
|
||||||
[[module.imports]]
|
[[module.imports]]
|
||||||
path = 'forge.alexselimov.com/aselimov/hugo-unified-git-activity'
|
path = 'forge.alexselimov.com/aselimov/hugo-unified-git-activity'
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="{{ with .Site.LanguageCode }}{{ . }}{{ else }}en-US{{ end }}">
|
<html lang="{{ with .Site.Language.Lang }}{{ . }}{{ else }}en-US{{ end }}">
|
||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta http-equiv="X-Clacks-Overhead" content="GNU Terry Pratchett" />
|
<meta http-equiv="X-Clacks-Overhead" content="GNU Terry Pratchett" />
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,3 @@
|
||||||
{{- /* Deprecate site.Author.email in favor of site.Params.author.email */}}
|
|
||||||
{{- $authorEmail := "" }}
|
{{- $authorEmail := "" }}
|
||||||
{{- with site.Params.author }}
|
{{- with site.Params.author }}
|
||||||
{{- if reflect.IsMap . }}
|
{{- if reflect.IsMap . }}
|
||||||
|
|
@ -6,14 +5,8 @@
|
||||||
{{- $authorEmail = . }}
|
{{- $authorEmail = . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- else }}
|
|
||||||
{{- with site.Author.email }}
|
|
||||||
{{- $authorEmail = . }}
|
|
||||||
{{- warnf "The author key in site configuration is deprecated. Use params.author.email instead." }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
{{- /* Deprecate site.Author.name in favor of site.Params.author.name */}}
|
|
||||||
{{- $authorName := "" }}
|
{{- $authorName := "" }}
|
||||||
{{- with site.Params.author }}
|
{{- with site.Params.author }}
|
||||||
{{- if reflect.IsMap . }}
|
{{- if reflect.IsMap . }}
|
||||||
|
|
@ -21,12 +14,7 @@
|
||||||
{{- $authorName = . }}
|
{{- $authorName = . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- else }}
|
{{- else }}
|
||||||
{{- $authorName = . }}
|
|
||||||
{{- end }}
|
|
||||||
{{- else }}
|
|
||||||
{{- with site.Author.name }}
|
|
||||||
{{- $authorName = . }}
|
{{- $authorName = . }}
|
||||||
{{- warnf "The author key in site configuration is deprecated. Use params.author.name instead." }}
|
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
|
|
@ -49,7 +37,11 @@
|
||||||
<link>{{ .Permalink }}</link>
|
<link>{{ .Permalink }}</link>
|
||||||
<description>Recent content {{ if not .IsHome }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ .Site.Title }}</description>
|
<description>Recent content {{ if not .IsHome }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ .Site.Title }}</description>
|
||||||
<generator>Hugo -- gohugo.io</generator>
|
<generator>Hugo -- gohugo.io</generator>
|
||||||
<language>{{ site.Language.LanguageCode }}</language>{{ with $authorEmail }}
|
{{ with site.Language.Lang }}
|
||||||
|
<language>{{ . }}</language>
|
||||||
|
{{ else }}
|
||||||
|
<language>en</language>
|
||||||
|
{{ end }}{{ with $authorEmail }}
|
||||||
<managingEditor>{{.}}{{ with $authorName }} ({{ . }}){{ end }}</managingEditor>{{ end }}{{ with $authorEmail }}
|
<managingEditor>{{.}}{{ with $authorName }} ({{ . }}){{ end }}</managingEditor>{{ end }}{{ with $authorEmail }}
|
||||||
<webMaster>{{ . }}{{ with $authorName }} ({{ . }}){{ end }}</webMaster>{{ end }}{{ with .Site.Copyright }}
|
<webMaster>{{ . }}{{ with $authorName }} ({{ . }}){{ end }}</webMaster>{{ end }}{{ with .Site.Copyright }}
|
||||||
<copyright>{{ . }}</copyright>{{ end }}{{ if not .Date.IsZero }}
|
<copyright>{{ . }}</copyright>{{ end }}{{ if not .Date.IsZero }}
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ https://forge.alexselimov.com/aselimov/upvoters server to handle anonymous upvot
|
||||||
homepage = "https://forge.alexselimov.com/aselimov/hugo-bearcub"
|
homepage = "https://forge.alexselimov.com/aselimov/hugo-bearcub"
|
||||||
|
|
||||||
tags = ["blog", "responsive", "minimal", "personal", "dark", "multilingual"]
|
tags = ["blog", "responsive", "minimal", "personal", "dark", "multilingual"]
|
||||||
features = ["favicon", "seo", "no javascript", "rss", "social cards"]
|
features = ["favicon", "seo", "rss", "social cards"]
|
||||||
|
|
||||||
# If the theme has a single author
|
# If the theme has a single author
|
||||||
[author]
|
[author]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue