{% extends "@templates/"~template~"/view/base.html.twig" %}

{% block meta %}{{ getMeta()|raw }}{% endblock %}

{% block stylesheets %}
    {{ parent() }}
    <link rel="stylesheet" href="{{ asset('templates/koszulkiart/assets/css/podstrona.css' ~ vStyle) }}">
{% endblock %}

{% block javascript %}
    {{ parent() }}
{% endblock %}

{% block breadcrumbs %}
    <section class="breadcrumbSection">
        <div class="grid-container">
            <div class="grid-x grid-padding-x">
                <div class="cell">
                    {{ wo_render_breadcrumbs() }}
                </div>
            </div>
        </div>
    </section>
{% endblock %}

{% block content %}
    <section class="article NewsIndex frontNews">
        <div class="grid-container">
            <div class="grid-x grid-margin-x">
                <div class="cell">
                    <h1>{{ category is not null ? category.name : "Aktualności" }}</h1>
                </div>
            </div>
            <div class="grid-x grid-margin-x">

                        {% for News in news %}
                            <div class="cell medium-6 large-6">
                                <div class="frontNewsSingle">
                                    <div class="newsFrontImage">
                                        <img src="{{ asset(News.getImage('thumbnail')) }}">
                                    </div>
                                    <div class="newsFrontTitle">
                                        <p>{{ News.title }}</p>
                                    </div>
                                    <div class="newsFrontShortcut">
                                        <p style="text-align: justify">{{ News.shortcut }}</p>
                                    </div>
                                    <div class="newsFrontMore">
                                        <a class="button" href="{{ getCanonical(News) }}">więcej <img class="strzlaka" src="/templates/Front/habitat/assets/img/strzalka.png"></a>
                                    </div>
                                </div>
                            </div>
                        {% endfor %}
                        <div class="navigation">
                            {{ knp_pagination_render(news, '@KnpPaginator/Pagination/sliding.html.twig') }}
                        </div>

        </div>
        </div>
    </section>
{% endblock %}

{% block footer %}
    <div style="margin-bottom: 70px"></div>
    {{ parent() }}
{% endblock %}
