xref: /webtrees/resources/views/modules/random_media/config.phtml (revision 0e3117798ee1781780c6cc2f31abb8b65e3655ac)
1<?php
2
3use Fisharebest\Webtrees\I18N;
4
5/**
6 * @var string               $controls
7 * @var string               $filter
8 * @var array<string,string> $filters
9 * @var array<string,string> $formats
10 * @var string               $start
11 */
12
13?>
14
15<div class="row mb-3">
16    <label class="col-sm-3 col-form-label" for="filter">
17        <?= I18N::translate('Show only individuals, events, or all') ?>
18    </label>
19    <div class="col-sm-9">
20        <?= view('components/select', ['name' => 'filter', 'selected' => $filter, 'options' => ['indi' => I18N::translate('Individuals'), 'event' => I18N::translate('Facts and events'), 'all' => I18N::translate('All')]]) ?>
21    </div>
22</div>
23
24<fieldset class="row mb-3">
25    <legend class="col-form-label col-sm-3">
26        <?= I18N::translate('Type') ?>
27    </legend>
28    <div class="col-sm-9">
29        <?php foreach ($formats as $type => $label) : ?>
30            <?= view('components/checkbox', ['label' => $label, 'name' => $type, 'checked' => (bool) $filters[$type]]) ?>
31        <?php endforeach ?>
32    </div>
33</fieldset>
34
35<div class="row mb-3">
36    <label class="col-sm-3 col-form-label" for="controls">
37        <?= I18N::translate('Show slide show controls') ?>
38    </label>
39    <div class="col-sm-9">
40        <?= view('components/radios-inline', ['name' => 'controls', 'options' => [I18N::translate('no'), I18N::translate('yes')], 'selected' => (int) $controls]) ?>
41    </div>
42</div>
43
44<div class="row mb-3">
45    <label class="col-sm-3 col-form-label" for="start">
46        <?= I18N::translate('Start slide show on page load') ?>
47    </label>
48    <div class="col-sm-9">
49        <?= view('components/radios-inline', ['name' => 'start', 'options' => [I18N::translate('no'), I18N::translate('yes')], 'selected' => (int) $start]) ?>
50    </div>
51</div>
52