{% extends 'base.html.twig' %}

{% block title %}Categories | Alex Daniels{% endblock %}

{% block body %}
    <section class="category">
        {% if posts|length %}
            <div class="posts">
                <h2>Posts</h2>
                <ul>
                    {% for post in posts %}
                        <li><a href="/words/{{post.url}}">{{post.title}}</a></li>
                    {% endfor %}
                </ul>
            </div>
        {% endif %}
        {% if photos|length %}
            <div class="photos">
                <h2>Photos</h2>
                <ul>
                    {% for photo in photos %}
                        <li><a href="/photos/{{photo.url}}">{{photo.title}}</a></li>
                    {% endfor %}
                </ul>
            </div>
        {% endif %}
    </section>
{% endblock %}
