40 lines
1.5 KiB
HTML
40 lines
1.5 KiB
HTML
<section class="stack-lg" aria-labelledby="media-title">
|
||
<header class="page-header">
|
||
<div>
|
||
<h1 class="page-title" id="media-title">Médiathèque</h1>
|
||
<p class="field-help">Parcourir les images par page évite de charger toute la bibliothèque d'un coup.</p>
|
||
</div>
|
||
|
||
<div class="page-actions">
|
||
<a class="button button--ghost" href="{{ 'dashboard' | alias }}">Retour</a>
|
||
</div>
|
||
</header>
|
||
|
||
<form class="panel stack" method="post" action="{{ 'media_upload' | alias }}" enctype="multipart/form-data">
|
||
<include href="partials/csrf_field.html" />
|
||
<label class="field">
|
||
<span class="field-label">Nouvelle image</span>
|
||
<input class="control" type="file" name="image" accept="image/jpeg,image/png,image/webp" required>
|
||
<span class="field-help">Formats acceptés : JPG, PNG, WebP. Limite : 10 Mo, 8000 × 8000 px et 40 mégapixels.</span>
|
||
</label>
|
||
<button class="button" type="submit">Envoyer</button>
|
||
</form>
|
||
|
||
<check if="{{ @items }}">
|
||
<true>
|
||
<div class="card-grid">
|
||
<repeat group="{{ @items }}" value="{{ @item }}">
|
||
<include href="partials/media_card.html" />
|
||
</repeat>
|
||
</div>
|
||
<include href="partials/pagination.html" />
|
||
</true>
|
||
<false>
|
||
<section class="empty-state" aria-labelledby="media-empty-title">
|
||
<h2 class="card-title" id="media-empty-title">Aucune image</h2>
|
||
<p>Ajoute ta première image.</p>
|
||
</section>
|
||
</false>
|
||
</check>
|
||
</section>
|