{% extends 'base.html.twig' %}
{% block title %}{{ setting.siteName }} : Catégories du Blog{% endblock %}
{% block body %}
{# <h1>BlogCategory index</h1>
<table class="table">
<thead>
<tr>
<th>Id</th>
<th>Title</th>
<th>actions</th>
</tr>
</thead>
<tbody>
{% for category in categories %}
<tr>
<td>{{ category.id }}</td>
<td>{{ category.title }}</td>
<td>
<a href="{{ path('app_blog_category_show', {'slug': category.slug}) }}">show</a>
<a href="{{ path('app_blog_category_edit', {'id': blog_category.id}) }}">edit</a>
</td>
</tr>
{% else %}
<tr>
<td colspan="3">no records found</td>
</tr>
{% endfor %}
</tbody>
</table>
<a href="{{ path('app_blog_category_new') }}">Create new</a> #}
{# {{ dump() }} #}
<section class="container py-5 mb-5">
<div class="row">
<div class="col">
{# Breadcrumbs #}
<div class="row">
<div class="col small">
<nav style="--bs-breadcrumb-divider: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8'%3E%3Cpath d='M2.5 0L1 1.5 3.5 4 1 6.5 2.5 8l4-4-4-4z' fill='%236c757d'/%3E%3C/svg%3E");"
aria-label="breadcrumb">
<ol class="breadcrumb small">
<li class="breadcrumb-item"><a href="{{ path('app_home') }}" class="text-decoration-none text-dark">Accueil</a></li>
<li class="breadcrumb-item"><a href="{{ path('app_blog_article_index') }}" class="text-decoration-none text-dark">Blog</a></li>
<li class="breadcrumb-item active" aria-current="page">Catégories</li>
</ol>
</nav>
</div>
</div>
</div>
</div>
<h1 class="text-center mb-4 color1 fw-700 text-uppercase" data-aos="fade-down" data-aos-duration="2000">Toutes les Catégories du Blog</h1>
<div class="row row-cols-1 row-cols-md-4 g-4 mt-4">
{% for category in categories %}
<div class="col">
<div class="card h-100">
<div class="card-body">
<h4 class="card-title text-center color1">
{{ category.title }}
<span class="text-xsmall px-2 py-1 border">
{{ category.blogArticles|length }}
</span>
</h4>
<p class="text-center">
<a href="{{ path('app_blog_category_show', {'slug': category.slug}) }}" class="text-decoration-none">
<span class="button-categories text-uppercase">Tous les articles de la Catégorie</span>
</a>
</p>
</div>
</div>
</div>
{% endfor %}
</div>
</section>
{% endblock %}