xref: /webtrees/resources/views/modules/edit-block-config.phtml (revision ac71572d8462e396ed5a307f05b29381e49f9e6e)
1<?php
2
3declare(strict_types=1);
4
5use Fisharebest\Webtrees\I18N;
6use Fisharebest\Webtrees\Module\ModuleBlockInterface;
7use Fisharebest\Webtrees\Tree;
8
9/**
10 * @var ModuleBlockInterface $block
11 * @var int                  $block_id
12 * @var string               $cancel_url
13 * @var string               $save_url
14 * @var string               $title
15 * @var Tree                 $tree
16 */
17
18?>
19
20<h2 class="wt-page-title">
21    <?= $title ?>
22</h2>
23
24<p>
25    <?= $block->description() ?>
26</p>
27
28<form method="post" action="<?= e($save_url) ?>">
29    <?= $block->editBlockConfiguration($tree, $block_id) ?>
30
31    <div class="row mb-3">
32        <div class="offset-sm-3 col-sm-9">
33            <button type="submit" class="btn btn-primary">
34                <?= view('icons/save') ?>
35                <?= I18N::translate('save') ?>
36            </button>
37            <a class="btn btn-secondary" href="<?= e($cancel_url) ?>">
38                <?= view('icons/cancel') ?>
39                <?= I18N::translate('cancel') ?>
40            </a>
41        </div>
42    </div>
43
44    <?= csrf_field() ?>
45</form>
46