-
+
@@ -55,9 +55,9 @@
{{ partial "helpers/get-author-name.html" . }}
{{ .Page.Date.Format "January 2, 2006" }}
diff --git a/README.md b/README.md index 5067719..fbdcc21 100644 --- a/README.md +++ b/README.md @@ -98,9 +98,9 @@ params: # transparent navbar and the main logo will be used in the non-transparent navbar. # It will be default to the theme logos if not provided. logo: - main: assets/images/main-logo.png - inverted: assets/images/inverted-logo.png - favicon: assets/images/favicon.png + main: /assets/images/main-logo.png + inverted: /assets/images/inverted-logo.png + favicon: /assets/images/favicon.png # GitHub repo URL of your site gitRepo: https://github.com/hossainemruz/toha-example-site diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index b549904..4b5c584 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -15,7 +15,7 @@ languages: bn: languageName: বাংলা weight: 3 - de: + de: languageName: Deutsch weight: 4 id: @@ -54,9 +54,9 @@ params: # transparent navbar and the main logo will be used in the non-transparent navbar. # It will be default to the theme logos if not provided. logo: - main: assets/images/main-logo.png - inverted: assets/images/inverted-logo.png - favicon: assets/images/favicon.png + main: /assets/images/main-logo.png + inverted: /assets/images/inverted-logo.png + favicon: /assets/images/favicon.png # GitHub repo URL of your site gitRepo: https://github.com/hossainemruz/toha-example-site diff --git a/layouts/404.html b/layouts/404.html index bcf8eab..941ecc1 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -3,7 +3,7 @@ {{ end }} {{ define "navbar" }} - {{ partial "navigators/navbar-2.html" (dict "baseURL" .Site.BaseURL "title" .Site.Title "hasToggleButton" false) }} + {{ partial "navigators/navbar-2.html" (dict "baseURL" site.BaseURL "title" site.Title "hasToggleButton" false) }} {{ end }} {{ define "content" }} diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index e47c959..2a5935f 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -9,7 +9,7 @@ {{ block "header" . }} {{ end }} - {{ if .Site.GoogleAnalytics }} + {{ if site.GoogleAnalytics }} {{ template "_internal/google_analytics_async.html" . }} {{ end }} diff --git a/layouts/_default/list.html b/layouts/_default/list.html index cccfd77..3ce168c 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -21,7 +21,7 @@
{{ i18n "newsletter_text" }}
diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 5d9e40f..a1f34dc 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -13,7 +13,7 @@ - + diff --git a/layouts/partials/helpers/get-author-image.html b/layouts/partials/helpers/get-author-image.html index 9ab6360..8142ddc 100644 --- a/layouts/partials/helpers/get-author-image.html +++ b/layouts/partials/helpers/get-author-image.html @@ -1,7 +1,12 @@ -{{ $authorImage:= "/assets/images/default-avatar.png"}} -{{ if .Site.Data.site.author}} - {{ $authorImage = .Site.Data.site.author.image | relURL }} -{{ end}} +{{ $author:= site.Data.author }} +{{ if (index site.Data site.Language.Lang).author }} + {{ $author = (index site.Data site.Language.Lang).author }} +{{ end }} +{{ $authorImage:= "/assets/images/default-avatar.png" }} +{{ if $author.image }} + {{ $authorImage = $author.image }} +{{ end }} + {{ if eq (printf "%T" .Params.author ) "maps.Params" }} {{ with .Params.author }} {{ if .image }} diff --git a/layouts/partials/helpers/get-author-name.html b/layouts/partials/helpers/get-author-name.html index 1ad3612..63c0846 100644 --- a/layouts/partials/helpers/get-author-name.html +++ b/layouts/partials/helpers/get-author-name.html @@ -1,6 +1,6 @@ -{{ $authorName:= .Site.Params.author.name }} -{{ if .Site.Data.site.author}} - {{ $authorName = .Site.Data.site.author.name }} +{{ $authorName:= site.Params.author.name }} +{{ if site.Data.site.author}} + {{ $authorName = site.Data.site.author.name }} {{ end}} {{ if eq (printf "%T" .Params.author ) "maps.Params" }} {{ with .Params.author }} diff --git a/layouts/partials/navigators/floating-lang-selector.html b/layouts/partials/navigators/floating-lang-selector.html index 6c59479..ec891d6 100644 --- a/layouts/partials/navigators/floating-lang-selector.html +++ b/layouts/partials/navigators/floating-lang-selector.html @@ -1,12 +1,12 @@ {{ $pageURL:= .RelPermalink }} -{{ if .Site.IsMultiLingual }} +{{ if site.IsMultiLingual }} {{ $pageURL = strings.TrimPrefix (path.Join "/" .Language.Lang) $pageURL }} {{ end }}