 {{- end }}
    {{- end }}
{{- end -}}

{{- define "li" -}}
    {{- $descending := and (eq $.Kind "term") (eq $.Data.Plural "series") }}
    {{- $pages := .Data.Pages }}
    {{- if .IsHome }}
        {{- $pages =  where site.RegularPages "Type" (or "post" "articles") }}
    {{- end }}
    {{- $yearGroup := $pages.GroupByDate "2006" }}
    {{- if $descending }}
        {{- $yearGroup = $yearGroup.Reverse }}
    {{- end }}
    {{- range $yearGroup }}
    {{- $year := .Key }}
    <div class="list-year textwidt