{% extends '/client/common/base.html.twig' %}
{% block title %}Home{% endblock %}
{% block body %}
<div class="uk-container uk-container-large uk-margin-large uk-margin-large-top">
<h1>{{ title }}</h1>
<div uk-grid class="uk-child-width-1-2@s">
{% for entry in entries %}
<div>
<div class="uk-card uk-card-default">
<div class="uk-card-media-top">
{% if (entry.imageIntro.imageName) %}
<picture>
<source srcset="{{ vich_uploader_asset(entry.imageIntro, 'imageFile') | imagine_filter('blog_list_webp') }}" type="image/webp">
<source srcset="{{ vich_uploader_asset(entry.imageIntro, 'imageFile') | imagine_filter('blog_list') }}" type="image/jpeg">
<img src="{{ vich_uploader_asset(entry.imageFull, 'imageFile') | imagine_filter('blog_list') }}" alt="{{ entry.title }}">
</picture>
{% endif %}
</div>
<div class="uk-card-body">
<h3 class="uk-card-title">{{ entry.title }}</h3>
<div class="uk-text-meta uk-margin-small">
{{ 'Created at'|trans }}: {{ entry.createdAt|date("d/m/Y") }},
{{ 'Posted at'|trans }}:
{% for category in entry.blogCategories %}
<a href="{{ path('client_blog_category_article_list', {'slug': category.slug }) }}">{{ category.title }}</a>
{% if not (loop.last) %}, {% endif %}
{% endfor %}
</div>
<div>{{ entry.introText|raw }}</div>
<div>
<a class="uk-button uk-button-primary" href="{{ path('client_blog_article_view', {'slug': entry.slug}) }}">{{ 'Read more...'|trans }}</a>
</div>
</div>
</div>
</div>
{% endfor %}
</div>
<hr />
{{ include('/client/common/parts/pagination.html.twig') }}
</div>
{% endblock %}