1<?php 2 3use Fisharebest\Webtrees\Individual; 4use Illuminate\Support\Collection; 5 6/** 7 * @var Collection|Individual[] $ancestors Indexed by sosa number 8 * @var int $generation Draw this generation 9 * @var int $generations Final generation to draw 10 * @var Collection|string[] $links Links to extend the tree 11 * @var int $sosa Draw this individual 12 * @var string $spacer 13 */ 14?> 15 16<div class="d-flex flex-column"> 17 <?php if ($generation < $generations) : ?> 18 <div class="d-flex"> 19 <?= view('modules/pedigree-chart/chart-up', ['ancestors' => $ancestors, 'sosa' => $sosa * 2, 'generation' => $generation + 1, 'generations' => $generations, 'links' => $links, 'spacer' => $spacer]) ?> 20 21 <?= view('modules/pedigree-chart/chart-up', ['ancestors' => $ancestors, 'sosa' => $sosa * 2 + 1, 'generation' => $generation + 1, 'generations' => $generations, 'links' => $links, 'spacer' => $spacer]) ?> 22 </div> 23 <?php endif ?> 24 25 <div class="position-relative d-flex justify-content-center wt-pedigree-generation wt-generation-fwd-<?= $generation ?> wt-generation-rev-<?= 1 + $generations - $generation ?>"> 26 <div class="d-flex flex-column align-items-center position-relative"> 27 <?php if ($generation === $generations) : ?> 28 <?= $links->get($sosa, $spacer) ?> 29 <?php endif ?> 30 31 <?= view('chart-box', ['individual' => $ancestors->get($sosa)]) ?> 32 33 <?php if ($sosa === 1) : ?> 34 <?= $links->get(1) ?> 35 <?php endif ?> 36 </div> 37 38 <!-- lines to the next generation --> 39 <?php if ($generation < $generations) : ?> 40 <div class="wt-pedigree-lines position-absolute"></div> 41 <?php endif ?> 42 </div> 43</div> 44 45