wip: make theme workable with hugoBasicExample site
This commit is contained in:
parent
07e816219f
commit
e7b2fba1b0
24 changed files with 343 additions and 34 deletions
5
layouts/partials/helpers/get-author-image.html
Normal file
5
layouts/partials/helpers/get-author-image.html
Normal file
|
@ -0,0 +1,5 @@
|
|||
{{ $authorImage:= "/assets/images/default-avatar.svg"}}
|
||||
{{ if isset .author "image" }}
|
||||
{{ $authorImage = .author.image }}
|
||||
{{ end }}
|
||||
{{ return $authorImage }}
|
5
layouts/partials/helpers/get-author-name.html
Normal file
5
layouts/partials/helpers/get-author-name.html
Normal file
|
@ -0,0 +1,5 @@
|
|||
{{ $authorName:= "John Doe"}}
|
||||
{{ if isset .author "name" }}
|
||||
{{ $authorName = .author.name }}
|
||||
{{ end }}
|
||||
{{ return $authorName }}
|
5
layouts/partials/helpers/get-categories.html
Normal file
5
layouts/partials/helpers/get-categories.html
Normal file
|
@ -0,0 +1,5 @@
|
|||
{{ $categories:= ""}}
|
||||
{{ if .categories }}
|
||||
{{ $categories = delimit .categories "," }}
|
||||
{{ end }}
|
||||
{{ return $categories }}
|
5
layouts/partials/helpers/get-hero.html
Normal file
5
layouts/partials/helpers/get-hero.html
Normal file
|
@ -0,0 +1,5 @@
|
|||
{{ $heroImage:= "/assets/images/default-hero.jpg"}}
|
||||
{{ if .hero }}
|
||||
{{ $heroImage = .hero }}
|
||||
{{ end }}
|
||||
{{ return $heroImage }}
|
5
layouts/partials/helpers/get-profile-image.html
Normal file
5
layouts/partials/helpers/get-profile-image.html
Normal file
|
@ -0,0 +1,5 @@
|
|||
{{ $profileImage:= "/assets/images/default-avatar.svg"}}
|
||||
{{ if .Site.Data.home.image }}
|
||||
{{ $profileImage = .Site.Data.home.image }}
|
||||
{{ end }}
|
||||
{{ return $profileImage }}
|
Loading…
Add table
Add a link
Reference in a new issue