1820b62dfSGreg Roach<?php 2820b62dfSGreg Roach 310e06497SGreg Roachdeclare(strict_types=1); 410e06497SGreg Roach 5820b62dfSGreg Roachuse Fisharebest\Webtrees\I18N; 69ba2a180SGreg Roachuse Fisharebest\Webtrees\Services\GedcomEditService; 77c2c99faSGreg Roachuse Fisharebest\Webtrees\Tree; 8820b62dfSGreg Roach 9820b62dfSGreg Roach/** 109ba2a180SGreg Roach * @var GedcomEditService $gedcom_edit_service 11efd4768bSGreg Roach * @var string $post_url 125d7ac018SGreg Roach * @var string $title 137c2c99faSGreg Roach * @var Tree $tree 14efd4768bSGreg Roach * @var string $url 15820b62dfSGreg Roach */ 16820b62dfSGreg Roach 17820b62dfSGreg Roach?> 18dd6b2bfcSGreg Roach 19dd6b2bfcSGreg Roach<h2 class="wt-page-title"><?= $title ?></h2> 20dd6b2bfcSGreg Roach 21efd4768bSGreg Roach<form method="post" action="<?= e($post_url) ?>"> 22efd4768bSGreg Roach <?php foreach ($facts ?? [] as $prefix => $prefix_facts) : ?> 23629892f1SGreg Roach <?php foreach ($prefix_facts as $n => $fact) : ?> 24efd4768bSGreg Roach <div class="card mb-2"> 25efd4768bSGreg Roach <div class="card-header"> 26f0ecc9a9SGreg Roach <button class="btn btn-small btn-link" type="button" data-bs-toggle="collapse" data-bs-target="#fact-<?= $prefix ?>-<?= $n ?>" aria-expanded="false" aria-controls="fact-<?= $prefix ?>-<?= $n ?>" data-wt-persist="<?= e($fact->tag()) ?>"> 27629892f1SGreg Roach <?= view('icons/expand') ?> 28629892f1SGreg Roach <?= view('icons/collapse') ?> 29629892f1SGreg Roach </button> 30efd4768bSGreg Roach <?= $fact->label() ?> 31efd4768bSGreg Roach </div> 32f0ecc9a9SGreg Roach <div class="card-body pb-1 collapse" id="fact-<?= $prefix ?>-<?= $n ?>"> 339ba2a180SGreg Roach <?= view('edit/edit-gedcom-fields', ['gedcom' => $gedcom_edit_service->insertMissingFactSubtags($fact, false), 'hierarchy' => explode(':', $fact->tag()), 'tree' => $fact->record()->tree(), 'prefix' => $prefix]) ?> 34efd4768bSGreg Roach </div> 35efd4768bSGreg Roach </div> 36efd4768bSGreg Roach <?php endforeach ?> 37efd4768bSGreg Roach <?php endforeach ?> 38dd6b2bfcSGreg Roach 399e3c2cf9SGreg Roach <div class="row mb-3"> 40dd6b2bfcSGreg Roach <div class="col-sm-9 offset-sm-3"> 41efd4768bSGreg Roach <button class="btn btn-primary" type="submit" name="url" value="<?= e($url) ?>"> 42d993d560SGreg Roach <?= view('icons/save') ?> 43dd6b2bfcSGreg Roach <?= /* I18N: A button label. */ 44dd6b2bfcSGreg Roach I18N::translate('save') ?> 45dd6b2bfcSGreg Roach </button> 46efd4768bSGreg Roach <button class="btn btn-primary" type="submit"> 47d993d560SGreg Roach <?= view('icons/save') ?> 48dd6b2bfcSGreg Roach <?= /* I18N: A button label. */ 49dd6b2bfcSGreg Roach I18N::translate('go to new individual') ?> 50dd6b2bfcSGreg Roach </button> 51*e765e953SGreg Roach <a class="btn btn-secondary" href="<?= e($url) ?>"> 52d993d560SGreg Roach <?= view('icons/cancel') ?> 53dd6b2bfcSGreg Roach <?= /* I18N: A button label. */ 54dd6b2bfcSGreg Roach I18N::translate('cancel') ?> 55dd6b2bfcSGreg Roach </a> 56dd6b2bfcSGreg Roach </div> 57dd6b2bfcSGreg Roach </div> 5881443e3cSGreg Roach 5981443e3cSGreg Roach <?= csrf_field() ?> 60dd6b2bfcSGreg Roach</form> 61dd6b2bfcSGreg Roach 62dd6b2bfcSGreg Roach<?= view('modals/on-screen-keyboard') ?> 63dd6b2bfcSGreg Roach<?= view('modals/ajax') ?> 64dd6b2bfcSGreg Roach<?= view('edit/initialize-calendar-popup') ?> 65