Allow for personalized titles for Blog and Note pages (#951)
This commit is contained in:
parent
05dce9c509
commit
d0329531d7
1 changed files with 4 additions and 2 deletions
|
@ -1,6 +1,8 @@
|
|||
{{/* variables for enabling/disabling various features */}}
|
||||
{{ $blogEnabled := site.Params.features.blog.enable | default false }}
|
||||
{{ $blogTitle := site.Params.features.blog.title | default (i18n "posts") }}
|
||||
{{ $notesEnabled := site.Params.features.notes.enable | default false }}
|
||||
{{ $notesTitle := site.Params.features.notes.title | default (i18n "notes") }}
|
||||
{{ $maxVisibleSections := site.Params.topNavbar.maxVisibleSections | default 5 }}
|
||||
|
||||
{{/* keep backward compatibility for blog post */}}
|
||||
|
@ -121,12 +123,12 @@
|
|||
{{ end }}
|
||||
{{ if $blogEnabled }}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" id="blog-link" href="{{ path.Join (site.BaseURL | relLangURL) "posts" }}">{{ i18n "posts" }}</a>
|
||||
<a class="nav-link" id="blog-link" href="{{ path.Join (site.BaseURL | relLangURL) "posts" }}">{{ $blogTitle }}</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ if $notesEnabled }}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" id="note-link" href="{{ path.Join (site.BaseURL | relLangURL) "notes" }}">{{ i18n "notes" }}</a>
|
||||
<a class="nav-link" id="note-link" href="{{ path.Join (site.BaseURL | relLangURL) "notes" }}">{{ $notesTitle }}</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ range $customMenus }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue