1dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Functions\Functions; ?> 2dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\I18N; ?> 3dd6b2bfcSGreg Roach 4dd6b2bfcSGreg Roach<table class="table table-sm wt-facts-table wt-family-navigator-family"> 5dd6b2bfcSGreg Roach <caption class="text-center wt-family-navigator-family-heading"> 6dd6b2bfcSGreg Roach <a href="<?= e($family->url()) ?>"> 7dd6b2bfcSGreg Roach <?= $title ?> 8dd6b2bfcSGreg Roach </a> 9dd6b2bfcSGreg Roach </caption> 10dd6b2bfcSGreg Roach <tbody> 1139ca88baSGreg Roach <?php foreach ($family->spouses() as $spouse) : ?> 1239ca88baSGreg Roach <tr class="text-center wt-family-navigator-parent wt-gender-<?= $spouse->sex() ?>"> 13*eb414fd9SGreg Roach <th class="align-middle wt-family-navigator-label" scope="row"> 14dd6b2bfcSGreg Roach <?php if ($spouse === $individual) : ?> 15dd6b2bfcSGreg Roach <?= Functions::getCloseRelationshipName($individual, $spouse) ?> 16dd6b2bfcSGreg Roach <i class="icon-selected"></i> 1739ca88baSGreg Roach <?php elseif ($spouse->primaryChildFamily() !== null) : ?> 18dd6b2bfcSGreg Roach <div class="dropdown"> 19c0935879SGreg Roach <a class="dropdown-toggle" href="#" role="button" id="dropdown-<?= e($spouse->xref()) ?>" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> 20dd6b2bfcSGreg Roach <?= Functions::getCloseRelationshipName($individual, $spouse) ?> 21dd6b2bfcSGreg Roach </a> 22dd6b2bfcSGreg Roach 23dd6b2bfcSGreg Roach <div class="dropdown-menu wt-family-navigator-dropdown"> 24dd6b2bfcSGreg Roach <div class="dropdown-header wt-family-navigator-dropdown-heading"> 25dd6b2bfcSGreg Roach <?= I18N::translate('Parents') ?> 26dd6b2bfcSGreg Roach </div> 2739ca88baSGreg Roach <?php foreach ($spouse->primaryChildFamily()->spouses() as $parent) : ?> 28dd6b2bfcSGreg Roach <a class="dropdown-item" href="<?= e($parent->url()) ?>"> 2939ca88baSGreg Roach <?= $parent->fullName() ?> 30dd6b2bfcSGreg Roach </a> 31dd6b2bfcSGreg Roach <?php endforeach ?> 32dd6b2bfcSGreg Roach </div> 33dd6b2bfcSGreg Roach </div> 34dd6b2bfcSGreg Roach <?php else : ?> 35dd6b2bfcSGreg Roach <?= Functions::getCloseRelationshipName($individual, $spouse) ?> 36dd6b2bfcSGreg Roach <?php endif ?> 37dd6b2bfcSGreg Roach </th> 38dd6b2bfcSGreg Roach 39dd6b2bfcSGreg Roach <td class="wt-family-navigator-name"> 40dd6b2bfcSGreg Roach <?php if ($spouse->canShow()) : ?> 41dd6b2bfcSGreg Roach <a href="<?= e($spouse->url()) ?>"> 4239ca88baSGreg Roach <?= $spouse->fullName() ?> 43dd6b2bfcSGreg Roach </a> 44dd6b2bfcSGreg Roach <div class="small"> 45dd6b2bfcSGreg Roach <?= $spouse->getLifeSpan() ?> 46dd6b2bfcSGreg Roach </div> 47dd6b2bfcSGreg Roach <?php else : ?> 4839ca88baSGreg Roach <?= $spouse->fullName() ?> 49dd6b2bfcSGreg Roach <?php endif ?> 50dd6b2bfcSGreg Roach </td> 51dd6b2bfcSGreg Roach </tr> 52dd6b2bfcSGreg Roach <?php endforeach ?> 53dd6b2bfcSGreg Roach 5439ca88baSGreg Roach <?php foreach ($family->children() as $child) : ?> 5539ca88baSGreg Roach <tr class="text-center wt-family-navigator-child wt-gender-<?= $child->sex() ?>"> 56dd6b2bfcSGreg Roach <th class="text-nowrap align-middle" scope="row"> 57dd6b2bfcSGreg Roach <?php if ($child === $individual) : ?> 58dd6b2bfcSGreg Roach <?= Functions::getCloseRelationshipName($individual, $child) ?> 59dd6b2bfcSGreg Roach <i class="icon-selected"></i> 60da7f6dd7SGreg Roach <?php elseif ($child->spouseFamilies()->isNotEmpty()) : ?> 61dd6b2bfcSGreg Roach <div class="dropdown"> 62c0935879SGreg Roach <a class="dropdown-toggle" href="#" role="button" id="dropdown-<?= e($child->xref()) ?>" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> 63dd6b2bfcSGreg Roach <?= Functions::getCloseRelationshipName($individual, $child) ?> 64dd6b2bfcSGreg Roach </a> 65dd6b2bfcSGreg Roach 66dd6b2bfcSGreg Roach <div class="dropdown-menu"> 6739ca88baSGreg Roach <?php foreach ($child->spouseFamilies() as $n => $in_laws) : ?> 68dd6b2bfcSGreg Roach <?php if ($n > 0) : ?> 69dd6b2bfcSGreg Roach <div class="dropdown-divider"></div> 70dd6b2bfcSGreg Roach <?php endif ?> 71dd6b2bfcSGreg Roach <div class="dropdown-header wt-family-navigator-dropdown-heading"> 72dd6b2bfcSGreg Roach <?= I18N::translate('Family') ?> 73dd6b2bfcSGreg Roach </div> 74dd6b2bfcSGreg Roach 7539ca88baSGreg Roach <?php foreach ($in_laws->spouses() as $sibling_in_law) : ?> 76dd6b2bfcSGreg Roach <?php if ($sibling_in_law !== $child) : ?> 77dd6b2bfcSGreg Roach <a class="dropdown-item" href="<?= e($sibling_in_law->url()) ?>"> 7839ca88baSGreg Roach <?= $sibling_in_law->fullName() ?> 79dd6b2bfcSGreg Roach </a> 80dd6b2bfcSGreg Roach <?php endif ?> 81dd6b2bfcSGreg Roach <?php endforeach ?> 82dd6b2bfcSGreg Roach 83dd6b2bfcSGreg Roach <ul> 8439ca88baSGreg Roach <?php foreach ($in_laws->children() as $child_in_law) : ?> 85dd6b2bfcSGreg Roach <li> 86dd6b2bfcSGreg Roach <a class="dropdown-item" href="<?= e($child_in_law->url()) ?>"> 8739ca88baSGreg Roach <?= $child_in_law->fullName() ?> 88dd6b2bfcSGreg Roach </a> 89dd6b2bfcSGreg Roach </li> 90dd6b2bfcSGreg Roach <?php endforeach ?> 91dd6b2bfcSGreg Roach </ul> 92dd6b2bfcSGreg Roach <?php endforeach ?> 93dd6b2bfcSGreg Roach </div> 94dd6b2bfcSGreg Roach </div> 95dd6b2bfcSGreg Roach <?php else : ?> 96dd6b2bfcSGreg Roach <?= Functions::getCloseRelationshipName($individual, $child) ?> 97dd6b2bfcSGreg Roach <?php endif ?> 98dd6b2bfcSGreg Roach </th> 99dd6b2bfcSGreg Roach 100dd6b2bfcSGreg Roach <td> 101dd6b2bfcSGreg Roach <?php if ($child->canShow()) : ?> 102dd6b2bfcSGreg Roach <a href="<?= e($child->url()) ?>"> 10339ca88baSGreg Roach <?= $child->fullName() ?> 104dd6b2bfcSGreg Roach </a> 105dd6b2bfcSGreg Roach <div class="small"> 106dd6b2bfcSGreg Roach <?= $child->getLifeSpan() ?> 107dd6b2bfcSGreg Roach </div> 108dd6b2bfcSGreg Roach <?php else : ?> 10939ca88baSGreg Roach <?= $child->fullName() ?> 110dd6b2bfcSGreg Roach <?php endif ?> 111dd6b2bfcSGreg Roach </td> 112dd6b2bfcSGreg Roach </tr> 113dd6b2bfcSGreg Roach <?php endforeach ?> 114dd6b2bfcSGreg Roach </tbody> 115dd6b2bfcSGreg Roach</table> 116