<?php

use Fisharebest\Webtrees\Http\RequestHandlers\ControlPanel;
use Fisharebest\Webtrees\I18N;

?>

<?= view('components/breadcrumbs', ['links' => [route(ControlPanel::class) => I18N::translate('Control panel'), route('manage-trees', ['tree' => $tree->name()]) => I18N::translate('Manage family trees'), $title]]) ?>

<h1><?= $title ?></h1>

<ul class="list-group">
    <li class="list-group-item">
        <strong><?= I18N::translate('GEDCOM errors') ?></strong>
    </li>

    <?php foreach ($errors as $error) : ?>
        <li class="list-group-item list-group-item-danger"><?= $error ?></li>
    <?php endforeach ?>

    <?php foreach ($warnings as $warning) : ?>
        <li class="list-group-item list-group-item-warning"><?= $warning ?></li>
    <?php endforeach ?>

    <?php if ($errors === [] && $warnings === []) : ?>
        <li class="list-group-item"><?= I18N::translate('No errors have been found.') ?></li>
    <?php endif ?>
</ul>
