Skip to content
Snippets Groups Projects
Commit a80cdf9e authored by alexisben's avatar alexisben
Browse files

fix block posts layout highlight

parent 5763e35a
No related branches found
No related tags found
No related merge requests found
......@@ -11,18 +11,22 @@
{{ end }}
{{ with $list }}
{{ $first := true }}
<div class="list">
{{ range . }}
{{ with site.GetPage (printf "/posts/%s" .) }}
<article>
{{- $title := partial "PrepareHTML" .Title -}}
<h1 itemprop="headline"><a href="{{ .Permalink }}" title="{{ safeHTML (i18n "commons.more_aria" (dict "Title" $title)) }}">{{ $title }}</a></h1>
{{- if (partial "GetTextFromHTML" .Params.description_short) -}}
<p itemprop="articleBody">{{ partial "PrepareHTML" .Params.description_short }}</p>
{{- end -}}
<time itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02T15:04" }}">{{ .Date | time.Format ":date_long" }}</time>
</article>
{{ if not $first }}
{{ with site.GetPage (printf "/posts/%s" .) }}
<article>
{{- $title := partial "PrepareHTML" .Title -}}
<h1 itemprop="headline"><a href="{{ .Permalink }}" title="{{ safeHTML (i18n "commons.more_aria" (dict "Title" $title)) }}">{{ $title }}</a></h1>
{{- if (partial "GetTextFromHTML" .Params.description_short) -}}
<p itemprop="articleBody">{{ partial "PrepareHTML" .Params.description_short }}</p>
{{- end -}}
<time itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02T15:04" }}">{{ .Date | time.Format ":date_long" }}</time>
</article>
{{ end }}
{{ end }}
{{ $first = false }}
{{ end }}
</div>
{{ end }}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment