{{ if .posts }}
{{ $highlight := index .posts 0 }} {{ $highlight = site.GetPage (printf "/posts/%s" $highlight)}} {{ $list := .posts }} {{ with $highlight }}
{{ partial "posts/post" (dict "post" . "heading" "h3" ) }}
{{ end }} {{ with $list }} {{ $first := true }}
{{ range after 1 . }} {{ with site.GetPage (printf "/posts/%s" .) }}
{{- $title := partial "PrepareHTML" .Title -}}

{{ $title }}

{{ if site.Params.posts.index.show_categories }} {{- partial "posts/categories" . -}} {{ end }} {{- if (partial "GetTextFromHTML" .Params.summary) -}} {{ if site.Params.posts.index.truncate_description }}

{{ partial "GetTruncateContent" ( dict "text" .Params.summary "length" site.Params.posts.index.truncate_description ) }}

{{ else }}

{{ partial "PrepareText" .Params.summary }}

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