diff options
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/_default/all_posts.html | 8 | ||||
-rw-r--r-- | layouts/_default/list.html | 13 | ||||
-rw-r--r-- | layouts/partials/article_list_item.html | 7 |
3 files changed, 11 insertions, 17 deletions
diff --git a/layouts/_default/all_posts.html b/layouts/_default/all_posts.html index 51c9d657..ea5de00f 100644 --- a/layouts/_default/all_posts.html +++ b/layouts/_default/all_posts.html @@ -5,13 +5,7 @@ </h2> <ul> {{ range where site.RegularPages "Type" "!=" "special"}} - <li> - <a href="{{ .Page.Permalink }}"> - <time>{{ .PublishDate.Format "2006-01-02" }}</time> - · - {{ .Page.Title }} - </a> - </li> + {{ partial "partials/article_list_item.html" . }} {{ end }} </ul> </article> diff --git a/layouts/_default/list.html b/layouts/_default/list.html index c27ce175..d0859265 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,18 +1,11 @@ {{ define "main" }} <article class="list taxonomy"> <h2> - {{ humanize .Title }} archives + {{ replace .Title "-" " " }} archives </h2> <ul> - {{ $pages := (.Data.Pages) }} - {{ range $pages }} - <li> - <a href="{{ .Page.Permalink }}"> - <time>{{ .PublishDate.Format "2006-01-02" }}</time> - · - {{ .Page.Title }} - </a> - </li> + {{ range .Data.Pages }} + {{ partial "partials/article_list_item.html" . }} {{ end }} </ul> </article> diff --git a/layouts/partials/article_list_item.html b/layouts/partials/article_list_item.html new file mode 100644 index 00000000..4190d027 --- /dev/null +++ b/layouts/partials/article_list_item.html @@ -0,0 +1,7 @@ +<li> + <a href="{{ .Page.Permalink }}"> + <time>{{ .PublishDate.Format "2006-01-02" }}</time> + · + {{ .Page.Title }} + </a> +</li> |