1<?php 2 3use Fisharebest\Webtrees\Functions\FunctionsPrint; 4 5?> 6<?php use Fisharebest\Webtrees\Functions\FunctionsPrintFacts; ?> 7<?php use Fisharebest\Webtrees\I18N; ?> 8<?php use Fisharebest\Webtrees\View; ?> 9 10<div class="wt-tab-facts py-4"> 11 <table class="table wt-facts-table"> 12 <tbody> 13 <tr> 14 <td colspan="2"> 15 <label> 16 <input id="show-relatives-facts" type="checkbox" data-toggle="collapse" data-target=".wt-relation-fact"> 17 <?= I18N::translate('Events of close relatives') ?> 18 </label> 19 <?php if ($has_historical_facts) : ?> 20 <label> 21 <input id="show-historical-facts" type="checkbox" data-toggle="collapse" data-target=".wt-historic-fact"> 22 <?= I18N::translate('Historic events') ?> 23 </label> 24 <?php endif ?> 25 </td> 26 </tr> 27 28 <?php foreach ($facts as $fact) : ?> 29 <?php FunctionsPrintFacts::printFact($fact, $individual) ?> 30 <?php endforeach ?> 31 32 <?php if ($facts->isEmpty()) : ?> 33 <tr> 34 <td colspan="2"> 35 <?= I18N::translate('There are no facts for this individual.') ?> 36 </td> 37 </tr> 38 <?php endif ?> 39 40 <?php if ($individual->canEdit()) : ?> 41 <?= view('edit/paste-fact-row', ['record' => $individual, 'facts' => $clipboard_facts]) ?> 42 43 <?php FunctionsPrint::printAddNewFact($individual, $facts, 'INDI') ?> 44 <?php endif ?> 45 </tbody> 46 </table> 47</div> 48 49<?php View::push('javascript') ?> 50<script> 51 'use strict'; 52 53 persistent_toggle('show-relatives-facts'); 54 persistent_toggle('show-historical-facts'); 55</script> 56<?php View::endpush() ?> 57