related.html 734 B
{{ if .Pages }}
<section class="related-posts" id="{{ urlize (i18n "programs.toc.related") }}">
<div class="container">
<div class="content">
<h2 id="page-posts">{{ i18n "posts.title" }}</h2>
<a href="{{ .Permalink }}" class="category-link">
{{ $category_name := safeHTML .Title | truncate 30 }}
{{ i18n "posts.see_all_in_program" (dict "Title" $category_name) }}
</a>
{{/* Related posts */}}
{{ $posts := first site.Params.programs.related_posts.quantity .Pages }}
{{ if gt (len $posts) 0 }}
<div class="blocks">
{{ partial "posts/block-posts-layout.html" (dict "posts" $posts ) }}
</div>
{{ end }}
</div>
</div>
</section>
{{ end }}