{% extends "base.twig" %}
{% block content %}

{% include 'components/title_page.twig'%}

	{% for item in posts %}
		<section class="row tpsF">
			<div class="sidebar col-md-4">
				<div class="title">
					<h3>{{item.title}}</h3>
					<div class="next_edition">
						<p>Prochaine Édition : <time>{{item.next_edition|date("F Y") }}</time>
						</p>
					</div>
				</div>
				<div class="content">
					{{item.text}}
				</div>
			</div>
			<div class="wrap_content col-md-8">
				<div class="slide">
			    {% for media in item.meta('slide') %}
						{% for add in media %}
							{% if add.acf_fc_layout == 'images' %}
								<div class="img">
									<img src="{{ Image(add.image).src }}" alt="{{ Image(add.image).title }}">
								</div>
							{% endif %}
							{% if add.acf_fc_layout == 'video' %}
								<div class="video">
									{{ add.video }}
								</div>
							{% endif %}
						{% endfor %}
					{% endfor %}
				</div>
			</div>
		</section>
	{% endfor %}
{% endblock %}
