{% extends 'base.html.twig' %}
{% block title %}ブログ{% endblock %}
{% block meta_og_title %}ブログ{% endblock %}
{% block meta_twitter_title %}ブログ{% endblock %}
{% block meta_description %}{{ parent() }}{% endblock %}
{% block meta_og_description %}{{ parent() }}{% endblock %}
{% block extraHeader %}
<link rel="canonical" content="{{ absolute_url(path('blog_index')) }}">
{% endblock %}
{% block body %}
<main id="blog">
<div class="breadcrumbs">
<div class="breadcrumbsContainer">
<a href="/">TOP</a>
<span></span>
<div>ブログ</div>
</div>
</div>
<div class="pageTitle">
<h1>AOI BLOG</h1>
<span>アオイのブログ</span>
</div>
<section class="c_cmsCategory">
<a href="{{ path('blog_index') }}" class="c_cmsCategory__item{% if not current_category %} c_cmsCategory__item--active{% endif %}">
ALL
</a>
{% for category in categories %}
<a href="{{ path('blog_index') }}?category={{ category[0].id }}" class="c_cmsCategory__item{% if current_category == category[0].id %} c_cmsCategory__item--active{% endif %}">
{{ category[0].name }}{# ({{ category.entry_count }})#}
</a>
{% endfor %}
</section>
<div class="blog">
{% for entry in data %}
<a class="blog__link" href="{{ path('blog_detail', {"id": entry.id}) }}">
<div class="blogLink__img">
{% if entry.hasThumbnailImage %}
<img src="{{ path("blog_image", {"filename": entry.getThumbnailRemote}) }}" alt="{{ entry.title }}">
{% else %}
<img src="{{ asset('images/no-image.jpg') }}" alt="{{ entry.title }}">
{% endif %}
</div>
<time class="blogLink__date">
{{ entry.entryDate|date('Y.m.d') }}
</time>
<h1 class="blogLink__content">
{{ entry.title }}
</h1>
</a>
{% endfor %}
</div>
<div id="news">
{% include "components/_pagination.html.twig" with [paginate] %}
</div>
</main>
{% endblock %}