#162, Add docs/date partial, for date customization
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
{{ if and .GitInfo .Site.Params.BookRepo }}
|
||||
<div>
|
||||
{{ $date := .GitInfo.AuthorDate.Local.Format (default "January 2, 2006" .Site.Params.BookDateFormat) }}
|
||||
{{- $date := partial "docs/date" (dict "Date" .GitInfo.AuthorDate.Local "Format" .Site.Params.BookDateFormat) -}}
|
||||
<a class="flex align-center" href="{{ .Site.Params.BookRepo }}/commit/{{ .GitInfo.Hash }}" title='{{ i18n "Last modified by" }} {{ .GitInfo.AuthorName }} | {{ $date }}' target="_blank" rel="noopener">
|
||||
<img src="{{ "svg/calendar.svg" | relURL }}" class="book-icon" alt="Calendar" />
|
||||
<span>{{ $date }}</span>
|
||||
|
||||
Reference in New Issue
Block a user