refactored colors, moved them to separate data/colors.yml
This commit is contained in:
parent
84c245d47c
commit
a9b0deb581
4 changed files with 160 additions and 88 deletions
|
|
@ -4,8 +4,14 @@
|
|||
"short_name": "{{ .Site.Title }}",
|
||||
"start_url": "/",
|
||||
"display": "standalone",
|
||||
"background_color": "{{ .Site.Params.backgroundColor | default "#242629" }}",
|
||||
"theme_color": "{{ .Site.Params.accentColor | default "#db5793" }}"
|
||||
{{ $bg := (.Site.Data.colors.dark.bg | default "#242629") }}
|
||||
{{ $accent := (.Site.Data.colors.dark.accent | default "#db5793") }}
|
||||
{{ if eq .Site.Data.colors.default "light" }}
|
||||
{{ $bg = (.Site.Data.colors.light.bg | default "#f5f5f5") }}
|
||||
{{ $accent = (.Site.Data.colors.light.accent | default "#db5793") }}
|
||||
{{ end }}
|
||||
"background_color": "{{ $bg }}",
|
||||
"theme_color": "{{ $accent }}"
|
||||
{{ if .Site.Params.description }}
|
||||
,
|
||||
"description": "{{ .Site.Params.description }}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue