Skip to content

Commit

Permalink
Made page theme color configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
cmahnke committed Sep 1, 2024
1 parent 57faedd commit fc3027f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
1 change: 1 addition & 0 deletions config/_default/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
disableScale = true
description = "Persönliche Homepage von Christian Mahnke"
debug = false
pagetheme = "#701611"

#[params.preview]
# outputPrefix = "ogPreview-overlay"
Expand Down
14 changes: 13 additions & 1 deletion layouts/partials/html/head/theme.html
Original file line number Diff line number Diff line change
@@ -1 +1,13 @@
<meta name="theme-color" content="#701611">
{{- $color := "" -}}

{{- if .Site.Params.pagetheme -}}
{{- $color := "" -}}
{{- end -}}

{{- if .Params.pagetheme -}}
{{- $color := "" -}}
{{- end -}}

{{- if ne $color "" -}}
<meta name="theme-color" content="#701611">
{{- end -}}

0 comments on commit fc3027f

Please sign in to comment.