xref: /webtrees/resources/views/individual-page.phtml (revision 10e0649788c8d7d4974d81c048ca2b225df8f22e)
12c3dad18SGreg Roach<?php
2852ede8cSGreg Roach
3*10e06497SGreg Roachdeclare(strict_types=1);
4*10e06497SGreg Roach
5dc270d8cSGreg Roachuse Fisharebest\Webtrees\Fact;
62c3dad18SGreg Roachuse Fisharebest\Webtrees\I18N;
72c3dad18SGreg Roachuse Fisharebest\Webtrees\Individual;
8dc270d8cSGreg Roachuse Fisharebest\Webtrees\Media;
9dc270d8cSGreg Roachuse Fisharebest\Webtrees\Module\ModuleSidebarInterface;
10dc270d8cSGreg Roachuse Fisharebest\Webtrees\Module\ModuleTabInterface;
11054771e9SGreg Roachuse Fisharebest\Webtrees\Tree;
12828e3b20SGreg Roachuse Fisharebest\Webtrees\User;
132c3dad18SGreg Roachuse Illuminate\Support\Collection;
142c3dad18SGreg Roach
152c3dad18SGreg Roach/**
16054771e9SGreg Roach * @var string                                 $age
170ea4a3f2SGreg Roach * @var bool                                   $can_upload_media
1836779af1SGreg Roach * @var Collection<int,Fact>                   $clipboard_facts
1936779af1SGreg Roach * @var Collection<int,Media>                  $individual_media
200f5fd22fSGreg Roach * @var Individual                             $record
2136779af1SGreg Roach * @var Collection<int,string>                 $shares
2236779af1SGreg Roach * @var Collection<int,ModuleSidebarInterface> $sidebars
2336779af1SGreg Roach * @var Collection<int,ModuleTabInterface>     $tabs
24054771e9SGreg Roach * @var Tree                                   $tree
2536779af1SGreg Roach * @var Collection<int,User>                   $users
262c3dad18SGreg Roach */
272c3dad18SGreg Roach?>
28dd6b2bfcSGreg Roach
290f5fd22fSGreg Roach<?= view('individual-page-pending', ['record' => $record]) ?>
30dd6b2bfcSGreg Roach
31dd6b2bfcSGreg Roach<div class="d-flex mb-4">
32dd6b2bfcSGreg Roach    <h2 class="wt-page-title mx-auto">
33e12592bcSGreg Roach        <?= view('individual-page-title', ['age' => $age, 'record' => $record, 'users' => $users]) ?>
34dd6b2bfcSGreg Roach    </h2>
350f5fd22fSGreg Roach
360f5fd22fSGreg Roach    <?php if ($record->canEdit()) : ?>
370ea4a3f2SGreg Roach        <?= view('individual-page-menu', ['can_upload_media' => $can_upload_media, 'clipboard_facts' => $clipboard_facts, 'record' => $record, 'shares' => $shares]) ?>
38dd6b2bfcSGreg Roach    <?php endif ?>
39dd6b2bfcSGreg Roach</div>
40dd6b2bfcSGreg Roach
41c1f982bdSGreg Roach<?php if ($sidebars->isEmpty()) : ?>
42c1f982bdSGreg Roach    <div class="row mb-4">
43c1f982bdSGreg Roach        <?= view('individual-page-images', ['can_upload_media' => $can_upload_media, 'individual_media' => $individual_media, 'record' => $record, 'tree' => $tree]) ?>
44c1f982bdSGreg Roach
45c1f982bdSGreg Roach        <?= view('individual-page-names', ['record' => $record]) ?>
46c1f982bdSGreg Roach    </div>
47c1f982bdSGreg Roach
48c1f982bdSGreg Roach    <?= view('individual-page-tabs', ['record' => $record, 'tabs' => $tabs]) ?>
49c1f982bdSGreg Roach<?php else : ?>
50dd6b2bfcSGreg Roach    <div class="row">
51c1f982bdSGreg Roach        <div class="col-sm-8">
52dd6b2bfcSGreg Roach            <div class="row mb-4">
530ea4a3f2SGreg Roach                <?= view('individual-page-images', ['can_upload_media' => $can_upload_media, 'individual_media' => $individual_media, 'record' => $record, 'tree' => $tree]) ?>
54dd6b2bfcSGreg Roach
55a53fba7eSGreg Roach                <?= view('individual-page-names', ['record' => $record]) ?>
56dd6b2bfcSGreg Roach            </div>
57dd6b2bfcSGreg Roach
580f5fd22fSGreg Roach            <?= view('individual-page-tabs', ['record' => $record, 'tabs' => $tabs]) ?>
590f5fd22fSGreg Roach        </div>
606a4003b9SGreg Roach
61c1f982bdSGreg Roach        <div class="col-sm-4">
620f5fd22fSGreg Roach            <?= view('individual-page-sidebars', ['record' => $record, 'sidebars' => $sidebars]) ?>
63dd6b2bfcSGreg Roach        </div>
64c1f982bdSGreg Roach    </div>
65c1f982bdSGreg Roach<?php endif ?>
66dd6b2bfcSGreg Roach
67dd6b2bfcSGreg Roach<?= view('modals/ajax') ?>
680f5fd22fSGreg Roach<?= view('modals/shares', ['shares' => $shares, 'title' => I18N::translate('Share') . ' — ' . $record->fullName()]) ?>
69