{% extends "minimal.html" %}
{% block content %}
<div class="bg-main" id='main-post'>
  {% if site.posts|length > 0 %}
  <div class="col-md-6">
    <h5>Latest post</h5>
    <h1><a href="{{ url("posts." + site.posts[0].slug) }}">{{ site.posts[0].title }}</a></h1>
    <p>{{ site.posts[0].short_content }}</p>
  </div>
  {% endif %}
</div>


<div class="row">
  <div class="col-md-12 col-lg-9">
    {% if page.paginator.index == 1 %}
      <h2>Older posts</h2>
    {% else %}
      <h2>Older posts - page {{page.paginator.index}}</h2>
    {% endif %}
    <hr>
    <ul id='post-list'>
      {% for post in page.paginator.posts %}
        {% include "post_front.html" %}
      {% endfor %}
    </ul>
    {% include 'pagination.html' %}
  </div>
  <div class="col-md-12 col-lg-3">
    {% include "tag_list.html" %}
  </div>
</div>

{% endblock content %}
