1<?php 2 3declare(strict_types=1); 4 5use Fisharebest\Webtrees\Family; 6use Fisharebest\Webtrees\Http\RequestHandlers\AddSpouseToFamilyPage; 7use Fisharebest\Webtrees\I18N; 8use Fisharebest\Webtrees\Individual; 9 10/** 11 * @var Family $family 12 */ 13 14?> 15<div class="d-flex"> 16 <div class="align-self-center"> 17 <div class="d-flex"> 18 <div class="wt-chart-horizontal-spacer"> 19 <div class="wt-chart-horizontal-first-parent"></div> 20 </div> 21 22 <div class="align-self-center"> 23 <?php if ($family->husband() instanceof Individual) : ?> 24 <?= view('chart-box', ['individual' => $family->husband()]) ?> 25 <?php else : ?> 26 <div class="wt-chart-box"> 27 <?php if ($family->canEdit()) : ?> 28 <a class="btn btn-link" href="<?= e(route(AddSpouseToFamilyPage::class, ['tree' => $family->tree()->name(), 'xref' => $family->xref(), 'sex' => 'M'])) ?>"> 29 <?= I18N::translate('Add a husband')?> 30 </a> 31 <?php endif ?> 32 </div> 33 <?php endif ?> 34 </div> 35 36 <?= view('family-page-grandparents', ['family' => $family, 'parent_family' => $family->husband()?->childFamilies()->first(), 'individual' => $family->husband()]) ?> 37 </div> 38 39 <div class="d-flex"> 40 <div class="wt-chart-horizontal-spacer"> 41 <div class="wt-chart-horizontal-last-parent"></div> 42 </div> 43 44 <div class="align-self-center"> 45 <?php if ($family->wife() instanceof Individual) : ?> 46 <?= view('chart-box', ['individual' => $family->wife()]) ?> 47 <?php else : ?> 48 <div class="wt-chart-box"> 49 <?php if ($family->canEdit()) : ?> 50 <a class="btn btn-link" href="<?= e(route(AddSpouseToFamilyPage::class, ['tree' => $family->tree()->name(), 'xref' => $family->xref(), 'sex' => 'F'])) ?>"> 51 <?= I18N::translate('Add a wife')?> 52 </a> 53 <?php endif ?> 54 </div> 55 <?php endif ?> 56 </div> 57 58 <?= view('family-page-grandparents', ['family' => $family, 'parent_family' => $family->wife()?->childFamilies()->first(), 'individual' => $family->wife()]) ?> 59 </div> 60 </div> 61</div> 62