<?php

use Fisharebest\Webtrees\I18N;

?>

<form method="post" action="<?= e(route('add-media-file', ['xref' => $media->xref(), 'tree' => $media->tree()->name()])) ?>" enctype="multipart/form-data">
    <?= csrf_field() ?>

    <?= view('modals/header', ['title' => I18N::translate('Add a media file')]) ?>

    <div class="modal-body">
        <?= view('modals/media-file-fields', ['max_upload_size' => $max_upload_size, 'unused_files' => $unused_files, 'media_file' => null, 'tree' => $tree]) ?>
    </div>

    <?= view('modals/footer-save-cancel') ?>
</form>
