Files
Vocaluxe/_includes/news.html
T

37 lines
1.4 KiB
HTML

<!-- News Section -->
{% assign post_1 = site.posts[0] %}
{% assign post_2 = site.posts[1] %}
{% assign post_3 = site.posts[2] %}
<section id="{{ page.section-type }}">
<div class="container">
<div class="row">
<h1 class="title">{{ page.title }}</h1>
{% if post_1 != nil %}
<div class="col-md-8">
<h2><a href="{{site.baseurl}}{{ post_1.url }}">{{post_1.title}} </a></h2>
<p>Published on {{ post_1.date | date: "%Y-%m-%d"}} by {{ post_1.author }}</p>
<img src="{{site.baseurl}}/img/posts/{{ post_1.image }}" class="img-responsive" />
{{ post_1.content | truncatewords: site.big-post-preview-words | markdownify }}
</div>
{% endif %}
<div class="col-md-4">
{% if post_2 != nil %}
<div class="col-lg-12">
<h3><a href="{{site.baseurl}}{{ post_2.url }}">{{ post_2.title }}</a></h3>
<p>Published on {{ post_2.date | date: "%Y-%m-%d"}} by {{ post_2.author }}</p>
{{ post_2.content | truncatewords: site.post-preview-words | markdownify }}
</div>
{% endif %}
{% if post_3 != nil %}
<div class="col-lg-12">
<h3><a href="{{site.baseurl}}{{ post_2.url }}">{{ post_3.title }}</a></h3>
<p>Published on {{ post_3.date | date: "%Y-%m-%d"}} by {{ post_3.author }}</p>
{{ post_3.content | truncatewords: site.post-preview-words | markdownify }}
</div>
{% endif %}
</div>
</div>
</div>
</section>
<!-- Help Section End -->