{% extends 'layout.html.twig' %} {% import "macros.html.twig" as macros %} {% set breadcrumb = buildBreadcrumb([{'route': 'app_album_index', 'trans': 'menu.albums'}], album) %} {% block title %} {{ renderTitle(breadcrumb) }} {% endblock %} {% block breadcrumb %} {{ renderBreadcrumb(breadcrumb) }} {% endblock %} {% block meta %} {% if context == 'user' %} {{ include('App/_partials/_meta.html.twig', { 'title': renderTitle(breadcrumb), 'description': 'menu.collections_user'|trans({'%username%': app.request.get('username')}), 'image': album.image }) }} {% else %} {{ parent() }} {% endif %} {% endblock %} {% block content %}
{% if album.image != null %} {% else %} {{album.title|first|upper}} {% endif %}

{{ album.title }}

{% if context == 'default' %} {% if isFeatureEnabled('history') %} {% endif %} {% endif %}
{% if children is not empty %}

{{ 'title.album_children'|trans }}

{{ include('App/Album/_list.html.twig', {'albums': children|naturalSorting}) }}
{% endif %} {% if photos is not empty %}

{{ 'title.photos'|trans }}

{% for photo in photos %}
{% set photoText = include('App/Album/_photo_text.html.twig') %} {% if photo.image %} {{ macros.lazyImage(photo.imageSmallThumbnail, 'aria.photo'|trans({'%title%': photo.title}), photo.title) }} {% else %} {% endif %}
{% endfor %}
{% endif %}
{% endblock %} {% block footer %} {{ renderFooter(album) }} {% endblock %} {% block modals %} {% if context == 'default' %} {{ include('App/_partials/_modal/_share.html.twig', {'entity': album, 'route': url('app_user_album_show', {id: album.id, username: app.user.username})}) }} {{ include('App/_partials/_modal/_delete.html.twig', {'id': 'delete', 'route': url('app_album_delete', {id: album.id}), transKey: 'message.delete.album'}) }} {% for photo in photos %} {{ include('App/_partials/_modal/_delete.html.twig', {'id': 'delete-' ~ photo.id , 'route': url('app_photo_delete', {id: photo.id}), transKey: 'message.delete.photo'}) }} {% endfor %} {% endif %} {% endblock %}