summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/Http/RequestHandlers/SetupWizard.php2
-rw-r--r--app/Module/YahrzeitModule.php18
-rw-r--r--resources/views/calendar-list.phtml5
-rw-r--r--resources/views/individual-page.phtml22
-rw-r--r--resources/views/lists/anniversaries-table.phtml4
-rw-r--r--resources/views/lists/surnames-table.phtml11
-rw-r--r--resources/views/media-page.phtml22
-rw-r--r--resources/views/modules/family-book-chart/children.phtml5
-rw-r--r--resources/views/modules/favorites/favorites.phtml10
-rw-r--r--resources/views/modules/hourglass-chart/children.phtml7
-rw-r--r--resources/views/modules/media-list/pagination.phtml3
-rw-r--r--resources/views/modules/pedigree-map/chart.phtml4
-rw-r--r--resources/views/modules/place-hierarchy/sidebar.phtml10
-rw-r--r--resources/views/modules/recent_changes/changes-table.phtml2
-rw-r--r--resources/views/modules/relatives/family.phtml2
-rw-r--r--resources/views/modules/statistics-chart/families.phtml6
-rw-r--r--resources/views/modules/statistics-chart/individuals.phtml6
-rw-r--r--resources/views/modules/statistics-chart/other.phtml6
-rw-r--r--resources/views/modules/todo/research-tasks.phtml4
-rw-r--r--resources/views/modules/upcoming_events/empty.phtml7
-rw-r--r--resources/views/modules/user_blog/edit.phtml8
-rw-r--r--resources/views/modules/user_blog/list.phtml11
-rw-r--r--resources/views/modules/user_welcome/welcome.phtml7
-rw-r--r--resources/views/modules/yahrzeit/config.phtml11
-rw-r--r--resources/views/modules/yahrzeit/list.phtml7
-rw-r--r--resources/views/modules/yahrzeit/table.phtml11
-rw-r--r--resources/views/password-request-page.phtml4
-rw-r--r--resources/views/password-reset-page.phtml7
-rw-r--r--resources/views/place-hierarchy.phtml6
-rw-r--r--resources/views/register-page.phtml14
-rw-r--r--resources/views/register-success-page.phtml6
-rw-r--r--resources/views/report-page.phtml7
-rw-r--r--resources/views/report-select-page.phtml7
-rw-r--r--resources/views/repository-page.phtml12
-rw-r--r--resources/views/robots-txt.phtml9
-rw-r--r--resources/views/search-advanced-page.phtml25
-rw-r--r--resources/views/search-general-page.phtml57
-rw-r--r--resources/views/search-phonetic-page.phtml15
-rw-r--r--resources/views/search-replace-page.phtml9
-rw-r--r--resources/views/search-results.phtml23
-rw-r--r--resources/views/selects/family.phtml9
-rw-r--r--resources/views/selects/individual.phtml5
-rw-r--r--resources/views/selects/location.phtml9
-rw-r--r--resources/views/selects/media.phtml9
-rw-r--r--resources/views/selects/note.phtml9
-rw-r--r--resources/views/selects/place.phtml9
-rw-r--r--resources/views/selects/repository.phtml9
-rw-r--r--resources/views/selects/source.phtml9
-rw-r--r--resources/views/selects/submission.phtml9
-rw-r--r--resources/views/selects/submitter.phtml9
-rw-r--r--resources/views/setup/config.ini.phtml15
-rw-r--r--resources/views/setup/step-1-language.phtml20
-rw-r--r--resources/views/setup/step-2-server-checks.phtml20
-rw-r--r--resources/views/setup/step-3-database-type.phtml18
-rw-r--r--resources/views/setup/step-4-database-mysql.phtml18
-rw-r--r--resources/views/setup/step-4-database-pgsql.phtml18
-rw-r--r--resources/views/setup/step-4-database-sqlite.phtml20
-rw-r--r--resources/views/setup/step-4-database-sqlsvr.phtml18
-rw-r--r--resources/views/setup/step-5-administrator.phtml18
-rw-r--r--resources/views/setup/step-6-failed.phtml4
-rw-r--r--resources/views/source-page.phtml18
-rw-r--r--resources/views/statistics/families/top10-list-age.phtml10
-rw-r--r--resources/views/statistics/families/top10-list-grand.phtml7
-rw-r--r--resources/views/statistics/families/top10-list-spouses.phtml7
-rw-r--r--resources/views/statistics/families/top10-list.phtml7
-rw-r--r--resources/views/statistics/families/top10-nolist-age.phtml8
-rw-r--r--resources/views/statistics/families/top10-nolist-grand.phtml7
-rw-r--r--resources/views/statistics/families/top10-nolist-spouses.phtml6
-rw-r--r--resources/views/statistics/families/top10-nolist.phtml7
-rw-r--r--resources/views/statistics/families/total-records.phtml1
-rw-r--r--resources/views/statistics/hit-count.phtml4
-rw-r--r--resources/views/statistics/individuals/top10-list.phtml8
-rw-r--r--resources/views/statistics/individuals/top10-nolist.phtml6
-rw-r--r--resources/views/statistics/other/charts/column.phtml9
-rw-r--r--resources/views/statistics/other/charts/combo.phtml6
-rw-r--r--resources/views/statistics/other/charts/custom.phtml9
-rw-r--r--resources/views/statistics/other/charts/geo.phtml9
-rw-r--r--resources/views/statistics/other/charts/pie.phtml7
-rw-r--r--resources/views/statistics/other/top10-list.phtml8
-rw-r--r--resources/views/submitter-page.phtml14
-rw-r--r--resources/views/tree-page-block.phtml7
-rw-r--r--resources/views/tree-page.phtml12
-rw-r--r--resources/views/user-page-block.phtml7
-rw-r--r--resources/views/user-page.phtml13
-rw-r--r--resources/views/verify-failure-page.phtml4
-rw-r--r--resources/views/verify-success-page.phtml4
86 files changed, 725 insertions, 147 deletions
diff --git a/app/Http/RequestHandlers/SetupWizard.php b/app/Http/RequestHandlers/SetupWizard.php
index 795ba0c674..e202267f90 100644
--- a/app/Http/RequestHandlers/SetupWizard.php
+++ b/app/Http/RequestHandlers/SetupWizard.php
@@ -164,7 +164,7 @@ class SetupWizard implements RequestHandlerInterface
I18N::init($data['lang'], true);
$data['cpu_limit'] = $this->maxExecutionTime();
- $data['locales'] = $locales->all();
+ $data['locales'] = $locales;
$data['memory_limit'] = $this->memoryLimit();
// Only show database errors after the user has chosen a driver.
diff --git a/app/Module/YahrzeitModule.php b/app/Module/YahrzeitModule.php
index f8a1076edf..cf6cabdd73 100644
--- a/app/Module/YahrzeitModule.php
+++ b/app/Module/YahrzeitModule.php
@@ -248,9 +248,9 @@ class YahrzeitModule extends AbstractModule implements ModuleBlockInterface
*/
public function editBlockConfiguration(Tree $tree, int $block_id): string
{
- $calendar = $this->getBlockSetting($block_id, 'calendar', 'jewish');
- $days = $this->getBlockSetting($block_id, 'days', self::DEFAULT_DAYS);
- $infoStyle = $this->getBlockSetting($block_id, 'infoStyle', 'table');
+ $calendar = $this->getBlockSetting($block_id, 'calendar', 'jewish');
+ $days = $this->getBlockSetting($block_id, 'days', self::DEFAULT_DAYS);
+ $info_style = $this->getBlockSetting($block_id, 'infoStyle', 'table');
$styles = [
/* I18N: An option in a list-box */
@@ -265,12 +265,12 @@ class YahrzeitModule extends AbstractModule implements ModuleBlockInterface
];
return view('modules/yahrzeit/config', [
- 'calendar' => $calendar,
- 'calendars' => $calendars,
- 'days' => $days,
- 'infoStyle' => $infoStyle,
- 'max_days' => self::MAX_DAYS,
- 'styles' => $styles,
+ 'calendar' => $calendar,
+ 'calendars' => $calendars,
+ 'days' => $days,
+ 'info_style' => $info_style,
+ 'max_days' => self::MAX_DAYS,
+ 'styles' => $styles,
]);
}
}
diff --git a/resources/views/calendar-list.phtml b/resources/views/calendar-list.phtml
index efcbdcd9b2..881999461e 100644
--- a/resources/views/calendar-list.phtml
+++ b/resources/views/calendar-list.phtml
@@ -2,10 +2,11 @@
use Fisharebest\Webtrees\Fact;
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
/**
- * @var array<Fact> $family_anniversaries
- * @var array<Fact> $individual_anniversaries
+ * @var Collection<Fact> $family_anniversaries
+ * @var Collection<Fact> $individual_anniversaries
*/
?>
diff --git a/resources/views/individual-page.phtml b/resources/views/individual-page.phtml
index a59a8ee87c..a640ad3392 100644
--- a/resources/views/individual-page.phtml
+++ b/resources/views/individual-page.phtml
@@ -1,25 +1,29 @@
<?php
use Fisharebest\Webtrees\Auth;
+use Fisharebest\Webtrees\Fact;
use Fisharebest\Webtrees\Http\RequestHandlers\AddNewFact;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptRecord;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectRecord;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Media;
+use Fisharebest\Webtrees\Module\ModuleSidebarInterface;
+use Fisharebest\Webtrees\Module\ModuleTabInterface;
use Fisharebest\Webtrees\Tree;
use Fisharebest\Webtrees\View;
use Illuminate\Support\Collection;
/**
- * @var string $age
- * @var Individual $individual
- * @var string $user_link
- * @var Collection $sidebars
- * @var Collection $individual_media
- * @var Collection $name_records
- * @var Collection $sex_records
- * @var Collection $tabs
- * @var Tree $tree
+ * @var string $age
+ * @var Individual $individual
+ * @var string $user_link
+ * @var Collection<ModuleSidebarInterface> $sidebars
+ * @var Collection<Media> $individual_media
+ * @var Collection<Fact> $name_records
+ * @var Collection<Fact> $sex_records
+ * @var Collection<ModuleTabInterface $tabs
+ * @var Tree $tree
*/
?>
diff --git a/resources/views/lists/anniversaries-table.phtml b/resources/views/lists/anniversaries-table.phtml
index da37d3e442..e52d7d79d5 100644
--- a/resources/views/lists/anniversaries-table.phtml
+++ b/resources/views/lists/anniversaries-table.phtml
@@ -19,9 +19,7 @@ use Illuminate\Support\Collection;
<table
class="table table-sm datatable wt-table-events"
<?= view('lists/datatables-attributes') ?>
- <?php if ($facts->count() < e($limit_high)) : ?>
- data-paging="false"
- <?php endif ?>
+ data-paging="<?= $facts->count() >= $limit_high ? 'true' : 'false' ?>"
data-filter="false"
data-info="false"
data-length-change="false"
diff --git a/resources/views/lists/surnames-table.phtml b/resources/views/lists/surnames-table.phtml
index 177bde0fe5..781d2a8b06 100644
--- a/resources/views/lists/surnames-table.phtml
+++ b/resources/views/lists/surnames-table.phtml
@@ -1,8 +1,15 @@
<?php
use Fisharebest\Webtrees\I18N;
-use Fisharebest\Webtrees\Module\FamilyListModule;
use Fisharebest\Webtrees\Module\IndividualListModule;
+use Fisharebest\Webtrees\Tree;
+
+/**
+ * @var bool $families
+ * @var IndividualListModule|null $module
+ * @var array<string,array<string,string>> $surnames
+ * @var Tree $tree
+ */
?>
@@ -38,7 +45,7 @@ use Fisharebest\Webtrees\Module\IndividualListModule;
<td data-sort="<?= e($surn) ?>">
<!-- Multiple surname variants, e.g. von Groot, van Groot, van der Groot, etc. -->
<?php foreach ($surns as $spfxsurn => $indis) : ?>
- <?php if ($module instanceof IndividualListModule || $module instanceof FamilyListModule) : ?>
+ <?php if ($module instanceof IndividualListModule) : ?>
<?php if ($spfxsurn) : ?>
<?php if ($surn !== '') : ?>
<a href="<?= $module->listUrl($tree, ['surname' => $surn]) ?>" dir="auto">
diff --git a/resources/views/media-page.phtml b/resources/views/media-page.phtml
index 384812d773..7fd0fd62df 100644
--- a/resources/views/media-page.phtml
+++ b/resources/views/media-page.phtml
@@ -1,6 +1,8 @@
<?php
use Fisharebest\Webtrees\Auth;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\Functions\FunctionsPrint;
use Fisharebest\Webtrees\Functions\FunctionsPrintFacts;
use Fisharebest\Webtrees\Http\RequestHandlers\AddMediaFileModal;
@@ -10,20 +12,24 @@ use Fisharebest\Webtrees\Http\RequestHandlers\EditMediaFileModal;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptRecord;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectRecord;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Individual;
use Fisharebest\Webtrees\Media;
+use Fisharebest\Webtrees\Note;
use Fisharebest\Webtrees\Registry;
+use Fisharebest\Webtrees\Source;
use Fisharebest\Webtrees\Tree;
use Illuminate\Support\Collection;
/**
- * @var Collection $clipboard_facts
- * @var Collection $facts
- * @var Collection $families
- * @var Collection $individuals
- * @var Media $media
- * @var Collection $notes
- * @var Collection $sources
- * @var Tree $tree
+ * @var Collection<Fact $clipboard_facts
+ * @var \League\Flysystem\FilesystemInterface $data_filesystem
+ * @var Collection<Fact> $facts
+ * @var Collection<Family> $families
+ * @var Collection<Individual> $individuals
+ * @var Media $media
+ * @var Collection<Note> $notes
+ * @var Collection<Source> $sources
+ * @var Tree $tree
*/
?>
diff --git a/resources/views/modules/family-book-chart/children.phtml b/resources/views/modules/family-book-chart/children.phtml
index 061e7ecff9..12e4841320 100644
--- a/resources/views/modules/family-book-chart/children.phtml
+++ b/resources/views/modules/family-book-chart/children.phtml
@@ -1,11 +1,12 @@
<?php
use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
use Illuminate\Support\Collection;
/**
- * @var Collection $children
- * @var int $generations
+ * @var Collection<Individual> $children
+ * @var int $generations
*/
?>
diff --git a/resources/views/modules/favorites/favorites.phtml b/resources/views/modules/favorites/favorites.phtml
index 9e458381e5..30c59e4cd6 100644
--- a/resources/views/modules/favorites/favorites.phtml
+++ b/resources/views/modules/favorites/favorites.phtml
@@ -6,11 +6,11 @@ use Fisharebest\Webtrees\Tree;
use Illuminate\Support\Collection;
/**
- * @var int $block_id
- * @var bool $can_edit
- * @var Collection $favorites
- * @var string $module_name
- * @var Tree $tree
+ * @var int $block_id
+ * @var bool $can_edit
+ * @var Collection<stdClass> $favorites
+ * @var string $module_name
+ * @var Tree $tree
*/
?>
diff --git a/resources/views/modules/hourglass-chart/children.phtml b/resources/views/modules/hourglass-chart/children.phtml
index 2c4d2990c1..53c047c6b2 100644
--- a/resources/views/modules/hourglass-chart/children.phtml
+++ b/resources/views/modules/hourglass-chart/children.phtml
@@ -1,12 +1,13 @@
<?php
use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
use Illuminate\Support\Collection;
/**
- * @var Collection $children
- * @var int $generations
- * @var bool $spouses
+ * @var Collection<Individual> $children
+ * @var int $generations
+ * @var bool $spouses
*/
?>
diff --git a/resources/views/modules/media-list/pagination.phtml b/resources/views/modules/media-list/pagination.phtml
index 48bb7366c2..b5c8dd5356 100644
--- a/resources/views/modules/media-list/pagination.phtml
+++ b/resources/views/modules/media-list/pagination.phtml
@@ -8,6 +8,7 @@ use Fisharebest\Webtrees\Tree;
* @var string $filter
* @var string $folder
* @var string $format
+ * @var int $max
* @var ModuleListInterface $module
* @var int $page
* @var int $pages
@@ -35,7 +36,7 @@ use Fisharebest\Webtrees\Tree;
</div>
<div class="col">
- <?= I18N::translate('Page %s of %s', $page, $pages) ?>
+ <?= I18N::translate('Page %s of %s', I18N::number($page), I18N::number($pages)) ?>
</div>
<div class="col">
diff --git a/resources/views/modules/pedigree-map/chart.phtml b/resources/views/modules/pedigree-map/chart.phtml
index 82ebfa3dd9..b3556a80bc 100644
--- a/resources/views/modules/pedigree-map/chart.phtml
+++ b/resources/views/modules/pedigree-map/chart.phtml
@@ -4,8 +4,8 @@ use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\View;
/**
- * @var array $data
- * @var array $provider
+ * @var array<mixed> $data
+ * @var array<mixed> $provider
*/
?>
diff --git a/resources/views/modules/place-hierarchy/sidebar.phtml b/resources/views/modules/place-hierarchy/sidebar.phtml
index 63b7aadd51..ed609b541a 100644
--- a/resources/views/modules/place-hierarchy/sidebar.phtml
+++ b/resources/views/modules/place-hierarchy/sidebar.phtml
@@ -4,11 +4,11 @@ use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Place;
/**
- * @var bool $showlink
- * @var Place $place
- * @var int $id
- * @var string $sidebar_class
- * @var array $stats
+ * @var bool $showlink
+ * @var Place $place
+ * @var int $id
+ * @var string $sidebar_class
+ * @var array<string,string> $stats
*/
?>
diff --git a/resources/views/modules/recent_changes/changes-table.phtml b/resources/views/modules/recent_changes/changes-table.phtml
index 9d5465fc4f..8d31fb0f1b 100644
--- a/resources/views/modules/recent_changes/changes-table.phtml
+++ b/resources/views/modules/recent_changes/changes-table.phtml
@@ -25,7 +25,7 @@ use Illuminate\Support\Collection;
<table
class="table table-sm wt-table-changes datatables d-none"
<?= view('lists/datatables-attributes') ?>
- data-paging="<?= e(json_encode($rows->count() >= e($limit_high))) ?>"
+ data-paging="<?= $rows->count() >= $limit_high ? 'true' : 'false' ?>"
data-filter="false"
data-info="false"
data-length-change="false"
diff --git a/resources/views/modules/relatives/family.phtml b/resources/views/modules/relatives/family.phtml
index 6323648f60..6ce5ed6b58 100644
--- a/resources/views/modules/relatives/family.phtml
+++ b/resources/views/modules/relatives/family.phtml
@@ -178,7 +178,7 @@ use Fisharebest\Webtrees\Individual;
<?= view('icons/warning') ?>
<?php endif ?>
- <?php $months = round($days / 30); ?>
+ <?php $months = intdiv($days + 15 , 30); ?>
<?php if (abs($months) === 12 || abs($months) >= 24) : ?>
<?= I18N::plural('%s year', '%s years', round($months / 12), I18N::number(round($months / 12))) ?>
<?php elseif ($months !== 0) : ?>
diff --git a/resources/views/modules/statistics-chart/families.phtml b/resources/views/modules/statistics-chart/families.phtml
index 4c79d5da60..8623774ca6 100644
--- a/resources/views/modules/statistics-chart/families.phtml
+++ b/resources/views/modules/statistics-chart/families.phtml
@@ -1,9 +1,11 @@
<?php
-/** @var Statistics $stats */
-
use Fisharebest\Webtrees\Statistics;
+/**
+ * @var Statistics $stats
+ */
+
?>
<div class="container pt-3">
diff --git a/resources/views/modules/statistics-chart/individuals.phtml b/resources/views/modules/statistics-chart/individuals.phtml
index 499f9444b8..a394fcd3fb 100644
--- a/resources/views/modules/statistics-chart/individuals.phtml
+++ b/resources/views/modules/statistics-chart/individuals.phtml
@@ -1,9 +1,11 @@
<?php
-/** @var Statistics $stats */
-
use Fisharebest\Webtrees\Statistics;
+/**
+ * @var Statistics $stats
+ */
+
?>
<div class="container pt-3">
diff --git a/resources/views/modules/statistics-chart/other.phtml b/resources/views/modules/statistics-chart/other.phtml
index fa2e7c24d2..f293d5ddab 100644
--- a/resources/views/modules/statistics-chart/other.phtml
+++ b/resources/views/modules/statistics-chart/other.phtml
@@ -2,10 +2,12 @@
declare(strict_types=1);
-/** @var Statistics $stats */
-
use Fisharebest\Webtrees\Statistics;
+/**
+ * @var Statistics $stats
+ */
+
?>
<div class="container pt-3">
diff --git a/resources/views/modules/todo/research-tasks.phtml b/resources/views/modules/todo/research-tasks.phtml
index cc19968fed..836189991d 100644
--- a/resources/views/modules/todo/research-tasks.phtml
+++ b/resources/views/modules/todo/research-tasks.phtml
@@ -15,9 +15,7 @@ use Illuminate\Support\Collection;
<table
class="table table-bordered table-sm wt-table-tasks datatables d-none"
<?= view('lists/datatables-attributes') ?>
- <?php if ($tasks->count() < e($limit_high)) : ?>
- data-paging="false"
- <?php endif ?>
+ data-paging="<?= $tasks->count() >= $limit_high ? 'true' : 'false' ?>"
data-filter="false"
data-info="false"
data-length-change="false"
diff --git a/resources/views/modules/upcoming_events/empty.phtml b/resources/views/modules/upcoming_events/empty.phtml
index f9c6b56089..5cd5bb3efc 100644
--- a/resources/views/modules/upcoming_events/empty.phtml
+++ b/resources/views/modules/upcoming_events/empty.phtml
@@ -1,3 +1,10 @@
+<?php
+
+/**
+ * @var string $message
+ */
+
+?>
<div class="details_label">
<?= $message ?>
</div>
diff --git a/resources/views/modules/user_blog/edit.phtml b/resources/views/modules/user_blog/edit.phtml
index c6b8194998..cec530b499 100644
--- a/resources/views/modules/user_blog/edit.phtml
+++ b/resources/views/modules/user_blog/edit.phtml
@@ -2,6 +2,14 @@
use Fisharebest\Webtrees\Http\RequestHandlers\UserPage;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Tree;
+
+/**
+ * @var string $body
+ * @var string $subject
+ * @var string $title
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/modules/user_blog/list.phtml b/resources/views/modules/user_blog/list.phtml
index 3415332a06..8db664af04 100644
--- a/resources/views/modules/user_blog/list.phtml
+++ b/resources/views/modules/user_blog/list.phtml
@@ -2,6 +2,15 @@
use Fisharebest\Webtrees\Auth;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<stdClass> $articles
+ * @var int $block_id
+ * @var int $limit
+ * @var Tree $tree
+ */
?>
@@ -10,7 +19,7 @@ use Fisharebest\Webtrees\I18N;
<?php endif ?>
<?php foreach ($articles as $n => $article) : ?>
- <?php if ($n === 5 && count($articles) > 5) : ?>
+ <?php if ($n === 5 && count($articles) > $limit) : ?>
<p>
<button class="btn btn-sm btn-secondary" data-toggle="collapse" data-target="#more-news-<?= e($block_id) ?>" role="button" aria-expanded="false" aria-controls="more-news-<?= e($block_id) ?>">
<?= view('icons/add') ?>
diff --git a/resources/views/modules/user_welcome/welcome.phtml b/resources/views/modules/user_welcome/welcome.phtml
index ef54eaf536..70d1893456 100644
--- a/resources/views/modules/user_welcome/welcome.phtml
+++ b/resources/views/modules/user_welcome/welcome.phtml
@@ -1,3 +1,10 @@
+<?php
+
+/**
+ * @var array<array<string,string>> $links
+ */
+
+?>
<div class="d-flex flex-wrap justify-content-around">
<?php foreach ($links as $link) : ?>
<div class="text-center m-1">
diff --git a/resources/views/modules/yahrzeit/config.phtml b/resources/views/modules/yahrzeit/config.phtml
index 9440d62fb4..4559cf56ec 100644
--- a/resources/views/modules/yahrzeit/config.phtml
+++ b/resources/views/modules/yahrzeit/config.phtml
@@ -2,6 +2,15 @@
use Fisharebest\Webtrees\I18N;
+/**
+ * @var string $calendar
+ * @var array<string,string> $calendars
+ * @var string $days
+ * @var string $info_style
+ * @var array<string,string> $styles
+ * @var int $max_days
+ */
+
?>
<div class="form-group row">
@@ -21,7 +30,7 @@ use Fisharebest\Webtrees\I18N;
<?= I18N::translate('Presentation style') ?>
</label>
<div class="col-sm-9">
- <?= view('components/select', ['name' => 'infoStyle', 'selected' => $infoStyle, 'options' => $styles]) ?>
+ <?= view('components/select', ['name' => 'infoStyle', 'selected' => $info_style, 'options' => $styles]) ?>
</div>
</div>
diff --git a/resources/views/modules/yahrzeit/list.phtml b/resources/views/modules/yahrzeit/list.phtml
index 5c638814c0..b2d9913c2d 100644
--- a/resources/views/modules/yahrzeit/list.phtml
+++ b/resources/views/modules/yahrzeit/list.phtml
@@ -5,9 +5,10 @@ use Fisharebest\Webtrees\View;
use Illuminate\Support\Collection;
/**
- * @var int $limit_low
- * @var int $limit_high
- * @var Collection $yahrzeits
+ * @var int $id
+ * @var int $limit_low
+ * @var int $limit_high
+ * @var Collection<stdClass> $yahrzeits
*/
?>
diff --git a/resources/views/modules/yahrzeit/table.phtml b/resources/views/modules/yahrzeit/table.phtml
index f87d8b38a3..16d6182680 100644
--- a/resources/views/modules/yahrzeit/table.phtml
+++ b/resources/views/modules/yahrzeit/table.phtml
@@ -4,8 +4,9 @@ use Fisharebest\Webtrees\I18N;
use Illuminate\Support\Collection;
/**
- * @var int $limit_low
- * @var Collection $yahrzeits
+ * @var int $limit_high
+ * @var int $limit_low
+ * @var Collection<stdClass> $yahrzeits
*/
?>
@@ -13,10 +14,8 @@ use Illuminate\Support\Collection;
<div class="table-responsive">
<table
class="table table-sm datatable wt-table-yahrzeits"
- <?= view('lists/datatables-attributes') ?>
- <?php if ($yahrzeits->count() < e($limit_high)) : ?>
- data-paging="false"
- <?php endif ?>
+ <?= view('lists/datatables-attributes') ?>
+ data-paging="<?= $yahrzeits->count() >= $limit_high ? 'true' : 'false' ?>"
data-filter="false"
data-info="false"
data-length-change="false"
diff --git a/resources/views/password-request-page.phtml b/resources/views/password-request-page.phtml
index a1b8ca86a6..b9d0afac2c 100644
--- a/resources/views/password-request-page.phtml
+++ b/resources/views/password-request-page.phtml
@@ -5,8 +5,10 @@ use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Tree;
/**
- * @var string $title
+ * @var string $title
+ * @var Tree|null $tree
*/
+
?>
<h2 class="wt-page-title">
diff --git a/resources/views/password-reset-page.phtml b/resources/views/password-reset-page.phtml
index c13d72065a..f232f79ca4 100644
--- a/resources/views/password-reset-page.phtml
+++ b/resources/views/password-reset-page.phtml
@@ -7,9 +7,10 @@ use Fisharebest\Webtrees\User;
use Fisharebest\Webtrees\View;
/**
- * @var string $title
- * @var string $token
- * @var User $user
+ * @var string $title
+ * @var string $token
+ * @var Tree|null $tree
+ * @var User $user
*/
?>
diff --git a/resources/views/place-hierarchy.phtml b/resources/views/place-hierarchy.phtml
index c7195e319a..0fc3c93bd9 100644
--- a/resources/views/place-hierarchy.phtml
+++ b/resources/views/place-hierarchy.phtml
@@ -1,6 +1,12 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Place;
+
+/**
+ * @var string $col_class
+ * @var array<array<Place>> $columns
+ */
?>
diff --git a/resources/views/register-page.phtml b/resources/views/register-page.phtml
index 0e16c34a94..c609d9a190 100644
--- a/resources/views/register-page.phtml
+++ b/resources/views/register-page.phtml
@@ -6,12 +6,14 @@ use Fisharebest\Webtrees\Tree;
use Fisharebest\Webtrees\View;
/**
- * @var string $comments
- * @var string $email
- * @var string $realname
- * @var bool $show_caution
- * @var string $title
- * @var string $username
+ * @var string $captcha
+ * @var string $comments
+ * @var string $email
+ * @var string $realname
+ * @var bool $show_caution
+ * @var string $title
+ * @var Tree|null $tree
+ * @var string $username
*/
?>
diff --git a/resources/views/register-success-page.phtml b/resources/views/register-success-page.phtml
index c9a0c954a4..7c5f0b547b 100644
--- a/resources/views/register-success-page.phtml
+++ b/resources/views/register-success-page.phtml
@@ -1,7 +1,13 @@
<?php
+use Fisharebest\Webtrees\Contracts\UserInterface;
use Fisharebest\Webtrees\I18N;
+/**
+ * @var string $title
+ * @var UserInterface $user
+ */
+
?>
<h2 class="wt-page-title">
diff --git a/resources/views/report-page.phtml b/resources/views/report-page.phtml
index 4f02edabdb..189c7bbac6 100644
--- a/resources/views/report-page.phtml
+++ b/resources/views/report-page.phtml
@@ -1 +1,8 @@
+<?php
+
+/**
+ * @var string $content
+ */
+
+?>
<?= $content ?>
diff --git a/resources/views/report-select-page.phtml b/resources/views/report-select-page.phtml
index 20c048efb4..323e884ee3 100644
--- a/resources/views/report-select-page.phtml
+++ b/resources/views/report-select-page.phtml
@@ -1,6 +1,13 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Module\ModuleReportInterface;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<ModuleReportInterface> $reports
+ * @var string $title
+ */
?>
diff --git a/resources/views/repository-page.phtml b/resources/views/repository-page.phtml
index b0101c9070..7b4fe1b977 100644
--- a/resources/views/repository-page.phtml
+++ b/resources/views/repository-page.phtml
@@ -1,12 +1,24 @@
<?php
use Fisharebest\Webtrees\Auth;
+use Fisharebest\Webtrees\Fact;
use Fisharebest\Webtrees\Functions\FunctionsPrint;
use Fisharebest\Webtrees\Functions\FunctionsPrintFacts;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptRecord;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectRecord;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Repository;
+use Fisharebest\Webtrees\Source;
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<Fact> $clipboard_facts
+ * @var Collection<Fact> $facts
+ * @var Collection<Source> $sources
+ * @var Repository $repository
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/robots-txt.phtml b/resources/views/robots-txt.phtml
index 77e4792948..a2e3d3710c 100644
--- a/resources/views/robots-txt.phtml
+++ b/resources/views/robots-txt.phtml
@@ -1,3 +1,12 @@
+<?php
+
+/**
+ * @var string $base_path
+ * @var string $base_url
+ * @var string $sitemap_url
+ */
+
+?>
# robots.txt for <?= $base_url ?>
<?php if ($base_path !== '') : ?>
diff --git a/resources/views/search-advanced-page.phtml b/resources/views/search-advanced-page.phtml
index d140faed12..7d7e1235aa 100644
--- a/resources/views/search-advanced-page.phtml
+++ b/resources/views/search-advanced-page.phtml
@@ -3,16 +3,19 @@
use Fisharebest\Webtrees\GedcomTag;
use Fisharebest\Webtrees\Http\RequestHandlers\SearchAdvancedAction;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Individual;
use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
/**
- * @var array<string,string> $date_options
- * @var array<string,string> $fields
- * @var array<string,string> $field_labels
- * @var array<string,string> $name_options
- * @var array<string,string> $other_options
- * @var string $title
- * @var Tree $tree
+ * @var array<string,string> $date_options
+ * @var array<string,string> $fields
+ * @var array<string,string> $field_labels
+ * @var Collection<Individual> $individuals
+ * @var array<string,string> $name_options
+ * @var array<string,string> $other_fields
+ * @var string $title
+ * @var Tree $tree
*/
?>
@@ -32,7 +35,7 @@ use Fisharebest\Webtrees\Tree;
</div>
<?php foreach ($fields as $field_name => $field_value) : ?>
- <?php if (substr($field_name, 0, 5) !== 'FAMC:') : ?>
+ <?php if (!str_starts_with($field_name, 'FAMC:')) : ?>
<?= view('search-advanced-field', ['field_label' => $field_labels[$field_name] ?? GedcomTag::getLabel($field_name), 'field_name' => $field_name, 'field_value' => $field_value, 'modifier' => $modifiers[$field_name] ?? '', 'date_options' => $date_options, 'name_options' => $name_options]) ?>
<?php endif ?>
<?php endforeach ?>
@@ -61,7 +64,7 @@ use Fisharebest\Webtrees\Tree;
</div>
<?php foreach ($fields as $field_name => $field_value) : ?>
- <?php if (substr($field_name, 0, 10) === 'FAMC:HUSB:') : ?>
+ <?php if (str_starts_with($field_name, 'FAMC:HUSB:')) : ?>
<?= view('search-advanced-field', ['field_label' => $field_labels[$field_name], 'field_name' => $field_name, 'field_value' => $field_value, 'modifier' => $modifiers[$field_name] ?? '', 'date_options' => $date_options, 'name_options' => $name_options]) ?>
<?php endif ?>
<?php endforeach ?>
@@ -73,7 +76,7 @@ use Fisharebest\Webtrees\Tree;
</div>
<?php foreach ($fields as $field_name => $field_value) : ?>
- <?php if (substr($field_name, 0, 10) === 'FAMC:WIFE:') : ?>
+ <?php if (str_starts_with($field_name, 'FAMC:WIFE:')) : ?>
<?= view('search-advanced-field', ['field_label' => $field_labels[$field_name], 'field_name' => $field_name, 'field_value' => $field_value, 'modifier' => $modifiers[$field_name] ?? '', 'date_options' => $date_options, 'name_options' => $name_options]) ?>
<?php endif ?>
<?php endforeach ?>
@@ -87,7 +90,7 @@ use Fisharebest\Webtrees\Tree;
</form>
</div>
-<?php if (true) : ?>
+<?php if (array_filter($fields) !== []) : ?>
<?php if ($individuals->isEmpty()) : ?>
<div class="alert alert-info row">
<?= I18N::translate('No results found.') ?>
diff --git a/resources/views/search-general-page.phtml b/resources/views/search-general-page.phtml
index 032d83ec00..38832d7b2c 100644
--- a/resources/views/search-general-page.phtml
+++ b/resources/views/search-general-page.phtml
@@ -2,6 +2,25 @@
use Fisharebest\Webtrees\Http\RequestHandlers\SearchGeneralAction;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Tree;
+
+/**
+ * @var array<Tree> $all_trees
+ * @var \Illuminate\Support\Collection<\Fisharebest\Webtrees\Family> $families
+ * @var \Illuminate\Support\Collection<\Fisharebest\Webtrees\Individual> $individuals
+ * @var \Illuminate\Support\Collection<\Fisharebest\Webtrees\Note> $notes
+ * @var string $query
+ * @var \Illuminate\Support\Collection<\Fisharebest\Webtrees\Repository> $repositories
+ * @var \Illuminate\Support\Collection<\Fisharebest\Webtrees\Source> $sources
+ * @var bool $search_families
+ * @var bool $search_individuals
+ * @var bool $search_notes
+ * @var bool $search_repositories
+ * @var bool $search_sources
+ * @var array<Tree> $search_trees
+ * @var string $title
+ * @var Tree $tree
+ */
?>
@@ -9,7 +28,8 @@ use Fisharebest\Webtrees\I18N;
<?= $title ?>
</h2>
-<form method="post" action="<?= e(route(SearchGeneralAction::class, ['tree' => $tree->name()])) ?>" class="wt-page-options wt-page-options-search hidden-print mb-4" name="searchform">
+<form method="post" action="<?= e(route(SearchGeneralAction::class, ['tree' => $tree->name()])) ?>"
+ class="wt-page-options wt-page-options-search hidden-print mb-4" name="searchform">
<?= csrf_field() ?>
<div class="row form-group">
<label class="col-sm-3 col-form-label wt-page-options-label" for="query">
@@ -30,35 +50,40 @@ use Fisharebest\Webtrees\I18N;
<div class="col-sm-9 wt-page-options-value">
<div class="form-check form-check-inline">
<label class="form-check-label">
- <input class="form-check-input" <?= $search_individuals ? 'checked' : '' ?> name="search_individuals" type="checkbox">
+ <input class="form-check-input" <?= $search_individuals ? 'checked' : '' ?>
+ name="search_individuals" type="checkbox">
<?= I18N::translate('Individuals') ?>
</label>
</div>
<div class="form-check form-check-inline">
<label class="form-check-label">
- <input class="form-check-input" <?= $search_families ? 'checked' : '' ?> name="search_families" type="checkbox">
+ <input class="form-check-input" <?= $search_families ? 'checked' : '' ?> name="search_families"
+ type="checkbox">
<?= I18N::translate('Families') ?>
</label>
</div>
<div class="form-check form-check-inline">
<label class="form-check-label">
- <input class="form-check-input" <?= $search_sources ? 'checked' : '' ?> name="search_sources" type="checkbox">
+ <input class="form-check-input" <?= $search_sources ? 'checked' : '' ?> name="search_sources"
+ type="checkbox">
<?= I18N::translate('Sources') ?>
</label>
</div>
<div class="form-check form-check-inline">
<label class="form-check-label">
- <input class="form-check-input" <?= $search_repositories ? 'checked' : '' ?> name="search_repositories" type="checkbox">
+ <input class="form-check-input" <?= $search_repositories ? 'checked' : '' ?>
+ name="search_repositories" type="checkbox">
<?= I18N::translate('Repositories') ?>
</label>
</div>
<div class="form-check form-check-inline">
<label class="form-check-label">
- <input class="form-check-input" <?= $search_notes ? 'checked' : '' ?> name="search_notes" type="checkbox">
+ <input class="form-check-input" <?= $search_notes ? 'checked' : '' ?> name="search_notes"
+ type="checkbox">
<?= I18N::translate('Shared notes') ?>
</label>
</div>
@@ -78,7 +103,9 @@ use Fisharebest\Webtrees\I18N;
<?php foreach ($all_trees as $tree) : ?>
<div class="col px-0">
<label class="form-check-label">
- <input class="form-check form-check-input" type="checkbox" <?= in_array($tree, $search_trees, true) ? 'checked' : '' ?> value="<?= $tree->name() ?>" name="search_trees[]">
+ <input class="form-check form-check-input"
+ type="checkbox" <?= in_array($tree, $search_trees, true) ? 'checked' : '' ?>
+ value="<?= $tree->name() ?>" name="search_trees[]">
<?= e($tree->title()) ?>
</label>
</div>
@@ -86,10 +113,17 @@ use Fisharebest\Webtrees\I18N;
</div>
<?php if (count($all_trees) > 3) : ?>
<div class="d-row align-self-end mb-2">
- <input type="button" class="btn btn-sm btn-secondary mx-1" value="<?= /* I18N: select all (of the family trees) */ I18N::translate('select all') ?>" onclick="$('#search-trees :checkbox').each(function(){$(this).attr('checked', true);});return false;">
- <input type="button" class="btn btn-sm btn-secondary mx-1" value="<?= /* I18N: select none (of the family trees) */ I18N::translate('select none') ?>" onclick="$('#search-trees :checkbox').each(function(){$(this).attr('checked', false);});return false;">
+ <input type="button" class="btn btn-sm btn-secondary mx-1"
+ value="<?= /* I18N: select all (of the family trees) */
+ I18N::translate('select all') ?>"
+ onclick="$('#search-trees :checkbox').each(function(){$(this).attr('checked', true);});return false;">
+ <input type="button" class="btn btn-sm btn-secondary mx-1"
+ value="<?= /* I18N: select none (of the family trees) */
+ I18N::translate('select none') ?>"
+ onclick="$('#search-trees :checkbox').each(function(){$(this).attr('checked', false);});return false;">
<?php if (count($all_trees) > 10) : ?>
- <input type="button" value="<?= I18N::translate('invert selection') ?>" onclick="$('#search-trees :checkbox').each(function(){$(this).attr('checked', !$(this).attr('checked'));});return false;">
+ <input type="button" value="<?= I18N::translate('invert selection') ?>"
+ onclick="$('#search-trees :checkbox').each(function(){$(this).attr('checked', !$(this).attr('checked'));});return false;">
<?php endif ?>
</div>
<?php endif ?>
@@ -102,7 +136,8 @@ use Fisharebest\Webtrees\I18N;
<div class="row form-group">
<label class="col-sm-3 col-form-label wt-page-options-label"></label>
<div class="col-sm-9 wt-page-options-value">
- <input type="submit" class="btn btn-primary" value="<?= /* I18N: A button label. */ I18N::translate('search') ?>">
+ <input type="submit" class="btn btn-primary" value="<?= /* I18N: A button label. */
+ I18N::translate('search') ?>">
</div>
</div>
</form>
diff --git a/resources/views/search-phonetic-page.phtml b/resources/views/search-phonetic-page.phtml
index 3ebe495dc4..8815ad4ed2 100644
--- a/resources/views/search-phonetic-page.phtml
+++ b/resources/views/search-phonetic-page.phtml
@@ -2,6 +2,21 @@
use Fisharebest\Webtrees\Http\RequestHandlers\SearchPhoneticAction;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var array<Tree> $all_trees
+ * @var string $firstname
+ * @var Collection<Individual> $individuals
+ * @var string $lastname
+ * @var string $place
+ * @var array<Tree> $search_trees
+ * @var string $soundex
+ * @var string $title
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/search-replace-page.phtml b/resources/views/search-replace-page.phtml
index 37e5775261..3b9a1e969e 100644
--- a/resources/views/search-replace-page.phtml
+++ b/resources/views/search-replace-page.phtml
@@ -2,6 +2,15 @@
use Fisharebest\Webtrees\Http\RequestHandlers\SearchReplaceAction;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Tree;
+
+/**
+ * @var string $context
+ * @var string $replace
+ * @var string $search
+ * @var string $title
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/search-results.phtml b/resources/views/search-results.phtml
index 4bc57bf9be..cc82602854 100644
--- a/resources/views/search-results.phtml
+++ b/resources/views/search-results.phtml
@@ -1,9 +1,30 @@
<?php
+use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Note;
+use Fisharebest\Webtrees\Repository;
+use Fisharebest\Webtrees\Source;
+use Fisharebest\Webtrees\Tree;
+use Fisharebest\Webtrees\View;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<Family> $families
+ * @var Collection<Individual> $individuals
+ * @var Collection<Note> $notes
+ * @var Collection<Repository> $repositories
+ * @var Collection<Source> $sources
+ * @var bool $search_families
+ * @var bool $search_individuals
+ * @var bool $search_notes
+ * @var bool $search_repositories
+ * @var bool $search_sources
+ * @var Tree $tree
+ */
?>
-<?php use Fisharebest\Webtrees\View; ?>
<div class="wt-search-results">
<ul class="nav nav-tabs wt-search-results-tabs" role="tablist">
diff --git a/resources/views/selects/family.phtml b/resources/views/selects/family.phtml
index 38e4c51504..1b3ed10c9b 100644
--- a/resources/views/selects/family.phtml
+++ b/resources/views/selects/family.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Family;
+
+/**
+ * @var Family $family
+ */
+
+?>
<?= $family->fullName() ?>
diff --git a/resources/views/selects/individual.phtml b/resources/views/selects/individual.phtml
index dab41f909c..95b762154e 100644
--- a/resources/views/selects/individual.phtml
+++ b/resources/views/selects/individual.phtml
@@ -1,7 +1,12 @@
<?php
+use Fisharebest\Webtrees\Individual;
use Fisharebest\Webtrees\MediaFile;
+/**
+ * @var Individual $individual
+ */
+
?>
<?php if ($individual->findHighlightedMediaFile() instanceof MediaFile) : ?>
diff --git a/resources/views/selects/location.phtml b/resources/views/selects/location.phtml
index 83fd755db9..dae7cf38a9 100644
--- a/resources/views/selects/location.phtml
+++ b/resources/views/selects/location.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Location;
+
+/**
+ * @var Location $location
+ */
+
+?>
<?= $location->fullName() ?>
diff --git a/resources/views/selects/media.phtml b/resources/views/selects/media.phtml
index e011a97f90..d77a8a5665 100644
--- a/resources/views/selects/media.phtml
+++ b/resources/views/selects/media.phtml
@@ -1,3 +1,12 @@
+<?php
+
+use Fisharebest\Webtrees\Media;
+
+/**
+ * @var Media $media
+ */
+
+?>
<?php foreach ($media->mediaFiles() as $media_file) : ?>
<?= $media_file->displayImage(30, 40, 'crop', []) ?>
<?php endforeach ?>
diff --git a/resources/views/selects/note.phtml b/resources/views/selects/note.phtml
index e27434a074..41d81a9648 100644
--- a/resources/views/selects/note.phtml
+++ b/resources/views/selects/note.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Note;
+
+/**
+ * @var Note $note
+ */
+
+?>
<?= $note->fullName() ?>
diff --git a/resources/views/selects/place.phtml b/resources/views/selects/place.phtml
index 8d100b7c43..86e945e173 100644
--- a/resources/views/selects/place.phtml
+++ b/resources/views/selects/place.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Place;
+
+/**
+ * @var Place $place
+ */
+
+?>
<?= $place->fullName() ?>
diff --git a/resources/views/selects/repository.phtml b/resources/views/selects/repository.phtml
index 72143f4b79..6de7864a3b 100644
--- a/resources/views/selects/repository.phtml
+++ b/resources/views/selects/repository.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Repository;
+
+/**
+ * @var Repository $repository
+ */
+
+?>
<?= $repository->fullName() ?>
diff --git a/resources/views/selects/source.phtml b/resources/views/selects/source.phtml
index f5fe21604c..a57b2e5cf0 100644
--- a/resources/views/selects/source.phtml
+++ b/resources/views/selects/source.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Source;
+
+/**
+ * @var Source $source
+ */
+
+?>
<?= $source->fullName() ?>
diff --git a/resources/views/selects/submission.phtml b/resources/views/selects/submission.phtml
index ba5d929991..38beb27e30 100644
--- a/resources/views/selects/submission.phtml
+++ b/resources/views/selects/submission.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Submission;
+
+/**
+ * @var Submission $submission
+ */
+
+?>
<?= $submission->fullName() ?>
diff --git a/resources/views/selects/submitter.phtml b/resources/views/selects/submitter.phtml
index b00adddcc1..1b5274417b 100644
--- a/resources/views/selects/submitter.phtml
+++ b/resources/views/selects/submitter.phtml
@@ -1 +1,10 @@
+<?php
+
+use Fisharebest\Webtrees\Submitter;
+
+/**
+ * @var Submitter $submitter
+ */
+
+?>
<?= $submitter->fullName() ?>
diff --git a/resources/views/setup/config.ini.phtml b/resources/views/setup/config.ini.phtml
index c4d534b49b..a190458c96 100644
--- a/resources/views/setup/config.ini.phtml
+++ b/resources/views/setup/config.ini.phtml
@@ -1,3 +1,18 @@
+<?php
+
+/**
+ * @var string $baseurl
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbuser
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var string $tblpfx
+ */
+
+?>
; <<?= '?php' ?> return; ?> DO NOT DELETE THIS LINE
dbtype="<?= addcslashes($dbtype, '"') ?>"
dbhost="<?= addcslashes($dbhost, '"') ?>"
diff --git a/resources/views/setup/step-1-language.phtml b/resources/views/setup/step-1-language.phtml
index bed2d82c0a..cb03cfc244 100644
--- a/resources/views/setup/step-1-language.phtml
+++ b/resources/views/setup/step-1-language.phtml
@@ -1,6 +1,26 @@
<?php
+use Fisharebest\Localization\Locale\LocaleInterface;
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var Collection<LocaleInterface> $locales
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-2-server-checks.phtml b/resources/views/setup/step-2-server-checks.phtml
index 316dfc77a6..0cb7e2e034 100644
--- a/resources/views/setup/step-2-server-checks.phtml
+++ b/resources/views/setup/step-2-server-checks.phtml
@@ -1,6 +1,26 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var int $cpu_limit
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var int $memory_limit
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-3-database-type.phtml b/resources/views/setup/step-3-database-type.phtml
index 7842cf1956..17a4568ceb 100644
--- a/resources/views/setup/step-3-database-type.phtml
+++ b/resources/views/setup/step-3-database-type.phtml
@@ -1,6 +1,24 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-4-database-mysql.phtml b/resources/views/setup/step-4-database-mysql.phtml
index 166a4e383f..2cadad728f 100644
--- a/resources/views/setup/step-4-database-mysql.phtml
+++ b/resources/views/setup/step-4-database-mysql.phtml
@@ -1,6 +1,24 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-4-database-pgsql.phtml b/resources/views/setup/step-4-database-pgsql.phtml
index f4a1b21906..04905a92c5 100644
--- a/resources/views/setup/step-4-database-pgsql.phtml
+++ b/resources/views/setup/step-4-database-pgsql.phtml
@@ -1,6 +1,24 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-4-database-sqlite.phtml b/resources/views/setup/step-4-database-sqlite.phtml
index fc3d08f313..458277dde5 100644
--- a/resources/views/setup/step-4-database-sqlite.phtml
+++ b/resources/views/setup/step-4-database-sqlite.phtml
@@ -2,6 +2,24 @@
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Webtrees;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
@@ -37,7 +55,7 @@ use Fisharebest\Webtrees\Webtrees;
<div class="col-sm-9">
<div class="input-group" dir="ltr">
<div class="input-group-prepend">
- <span class="input-group-text"><?=e(realpath(Webtrees::ROOT_DIR)) ?>/data/</span>
+ <span class="input-group-text"><?=e((string) realpath(Webtrees::ROOT_DIR)) ?>/data/</span>
</div>
<input class="form-control" id="dbname" name="dbname" pattern="[a-zA-Z0-9_]{1,63}" type="text" value="<?= e($dbname) ?>">
diff --git a/resources/views/setup/step-4-database-sqlsvr.phtml b/resources/views/setup/step-4-database-sqlsvr.phtml
index 8fdece33d9..497df08ec1 100644
--- a/resources/views/setup/step-4-database-sqlsvr.phtml
+++ b/resources/views/setup/step-4-database-sqlsvr.phtml
@@ -1,6 +1,24 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-5-administrator.phtml b/resources/views/setup/step-5-administrator.phtml
index 9a1e32e249..cfa192e609 100644
--- a/resources/views/setup/step-5-administrator.phtml
+++ b/resources/views/setup/step-5-administrator.phtml
@@ -1,6 +1,24 @@
<?php
use Fisharebest\Webtrees\I18N;
+use Illuminate\Support\Collection;
+
+/**
+ * @var string $dbhost
+ * @var string $dbname
+ * @var string $dbpass
+ * @var string $dbport
+ * @var string $dbtype
+ * @var string $dbuser
+ * @var Collection<string> $errors
+ * @var string $lang
+ * @var string $tblpfx
+ * @var Collection<string> $warnings
+ * @var string $wtemail
+ * @var string $wtname
+ * @var string $wtpass
+ * @var string $wtuser
+ */
?>
diff --git a/resources/views/setup/step-6-failed.phtml b/resources/views/setup/step-6-failed.phtml
index 0c35e82055..b6ab68daa2 100644
--- a/resources/views/setup/step-6-failed.phtml
+++ b/resources/views/setup/step-6-failed.phtml
@@ -2,6 +2,10 @@
use Fisharebest\Webtrees\I18N;
+/**
+ * @var Throwable $exception
+ */
+
?>
<p>
diff --git a/resources/views/source-page.phtml b/resources/views/source-page.phtml
index b7ee0409a5..cae4ba8d3a 100644
--- a/resources/views/source-page.phtml
+++ b/resources/views/source-page.phtml
@@ -1,13 +1,31 @@
<?php
use Fisharebest\Webtrees\Auth;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\Functions\FunctionsPrint;
use Fisharebest\Webtrees\Functions\FunctionsPrintFacts;
use Fisharebest\Webtrees\Http\RequestHandlers\AddNewFact;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptRecord;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectRecord;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Media;
+use Fisharebest\Webtrees\Note;
use Fisharebest\Webtrees\Source;
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<Fact> $clipboard_facts
+ * @var Collection<Fact> $facts
+ * @var \Illuminate\Support\Collection<Family> $families
+ * @var \Illuminate\Support\Collection<Individual> $individuals
+ * @var \Illuminate\Support\Collection<Media> $media_objects
+ * @var \Illuminate\Support\Collection<Note> $notes
+ * @var Source $source
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/statistics/families/top10-list-age.phtml b/resources/views/statistics/families/top10-list-age.phtml
index 299ca92579..0cc0e8a80d 100644
--- a/resources/views/statistics/families/top10-list-age.phtml
+++ b/resources/views/statistics/families/top10-list-age.phtml
@@ -2,14 +2,12 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
-use Fisharebest\Webtrees\Individual;
-/* @var array $records */
-/* @var Family $family */
-/* @var Individual $child1 */
-/* @var Individual $child2 */
+/**
+ * @var array<array> $records
+ */
+
?>
<?php if ($records) : ?>
diff --git a/resources/views/statistics/families/top10-list-grand.phtml b/resources/views/statistics/families/top10-list-grand.phtml
index f505f810d0..08bf46a8a8 100644
--- a/resources/views/statistics/families/top10-list-grand.phtml
+++ b/resources/views/statistics/families/top10-list-grand.phtml
@@ -2,11 +2,12 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
-/* @var array $records */
-/* @var Family $family */
+/**
+ * @var array<array> $records
+ */
+
?>
<?php if ($records) : ?>
diff --git a/resources/views/statistics/families/top10-list-spouses.phtml b/resources/views/statistics/families/top10-list-spouses.phtml
index a8d2303bee..d1517beeb6 100644
--- a/resources/views/statistics/families/top10-list-spouses.phtml
+++ b/resources/views/statistics/families/top10-list-spouses.phtml
@@ -2,11 +2,12 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
-/* @var array $records */
-/* @var Family $family */
+/**
+ * @var array<array> $records
+ */
+
?>
<?php if ($records) : ?>
diff --git a/resources/views/statistics/families/top10-list.phtml b/resources/views/statistics/families/top10-list.phtml
index d21f075aa0..aca891a57b 100644
--- a/resources/views/statistics/families/top10-list.phtml
+++ b/resources/views/statistics/families/top10-list.phtml
@@ -2,11 +2,12 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
-/* @var array $records */
-/* @var Family $family */
+/**
+ * @var array<array> $records
+ */
+
?>
<?php if ($records) : ?>
diff --git a/resources/views/statistics/families/top10-nolist-age.phtml b/resources/views/statistics/families/top10-nolist-age.phtml
index f98d604734..0870712387 100644
--- a/resources/views/statistics/families/top10-nolist-age.phtml
+++ b/resources/views/statistics/families/top10-nolist-age.phtml
@@ -6,10 +6,10 @@ use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/* @var array $record */
-/* @var Family $family */
-/* @var Individual $child1 */
-/* @var Individual $child2 */
+/**
+ * @var array<Family|Individual> $record
+ */
+
?>
<?php $child1 = $record['child1']; ?>
diff --git a/resources/views/statistics/families/top10-nolist-grand.phtml b/resources/views/statistics/families/top10-nolist-grand.phtml
index 612165032e..c94275a6a3 100644
--- a/resources/views/statistics/families/top10-nolist-grand.phtml
+++ b/resources/views/statistics/families/top10-nolist-grand.phtml
@@ -2,11 +2,12 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
-/* @var array $records */
-/* @var Family $family */
+/**
+ * @var array<array> $records
+ */
+
?>
<?php foreach ($records as $record) : ?>
diff --git a/resources/views/statistics/families/top10-nolist-spouses.phtml b/resources/views/statistics/families/top10-nolist-spouses.phtml
index 313cf562f2..554a5ab8d8 100644
--- a/resources/views/statistics/families/top10-nolist-spouses.phtml
+++ b/resources/views/statistics/families/top10-nolist-spouses.phtml
@@ -2,10 +2,10 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
+/**
+ * @var array<array> $records
+ */
-/* @var array $records */
-/* @var Family $family */
?>
<?php foreach ($records as $record) : ?>
diff --git a/resources/views/statistics/families/top10-nolist.phtml b/resources/views/statistics/families/top10-nolist.phtml
index 5281927097..f427c7fefb 100644
--- a/resources/views/statistics/families/top10-nolist.phtml
+++ b/resources/views/statistics/families/top10-nolist.phtml
@@ -2,11 +2,12 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\I18N;
-/* @var array $records */
-/* @var Family $family */
+/**
+ * @var array<array> $records
+ */
+
?>
<?php foreach ($records as $record) : ?>
diff --git a/resources/views/statistics/families/total-records.phtml b/resources/views/statistics/families/total-records.phtml
index 232852dc2e..81032a3155 100644
--- a/resources/views/statistics/families/total-records.phtml
+++ b/resources/views/statistics/families/total-records.phtml
@@ -6,6 +6,7 @@ use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Statistics;
/** @var Statistics $stats */
+
?>
<h4 class="border-bottom p-2 mb-4">
diff --git a/resources/views/statistics/hit-count.phtml b/resources/views/statistics/hit-count.phtml
index caab456a00..5d5c8ab686 100644
--- a/resources/views/statistics/hit-count.phtml
+++ b/resources/views/statistics/hit-count.phtml
@@ -4,6 +4,10 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
+/**
+ * @var int $count
+ */
+
?>
<span class="odometer">
<?= I18N::digits($count) ?>
diff --git a/resources/views/statistics/individuals/top10-list.phtml b/resources/views/statistics/individuals/top10-list.phtml
index 084dcd6c99..e9a59e3be8 100644
--- a/resources/views/statistics/individuals/top10-list.phtml
+++ b/resources/views/statistics/individuals/top10-list.phtml
@@ -5,11 +5,13 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/* @var array $records */
-/* @var Individual $person */
+/**
+ * @var array<array> $records
+ */
+
?>
-<?php if ($records) : ?>
+<?php if ($records !== []) : ?>
<ul class="list-group list-group-flush">
<?php foreach ($records as $record) : ?>
<?php $person = $record['person']; ?>
diff --git a/resources/views/statistics/individuals/top10-nolist.phtml b/resources/views/statistics/individuals/top10-nolist.phtml
index 484f06c039..cbc420e1d3 100644
--- a/resources/views/statistics/individuals/top10-nolist.phtml
+++ b/resources/views/statistics/individuals/top10-nolist.phtml
@@ -2,10 +2,10 @@
declare(strict_types=1);
-use Fisharebest\Webtrees\Individual;
+/**
+ * @var array<array> $records
+ */
-/* @var array $records */
-/* @var Individual $person */
?>
<?php foreach ($records as $record) : ?>
diff --git a/resources/views/statistics/other/charts/column.phtml b/resources/views/statistics/other/charts/column.phtml
index 0bec119fbf..e1cc7e724e 100644
--- a/resources/views/statistics/other/charts/column.phtml
+++ b/resources/views/statistics/other/charts/column.phtml
@@ -4,6 +4,13 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
+/**
+ * @var array<mixed> $chart_options
+ * @var string $chart_title
+ * @var array<array> $data
+ * @var string $language
+ */
+
$id = 'google-chart-' . bin2hex(random_bytes(8));
$name = 'callback_' . bin2hex(random_bytes(12));
?>
@@ -11,7 +18,7 @@ $name = 'callback_' . bin2hex(random_bytes(12));
<?php if (count($data) === 1) : ?>
<?= I18N::translate('This information is not available.') ?>
<?php else : ?>
- <div id="<?= $id ?>" title="<?= $chart_title ?? '' ?>"></div>
+ <div id="<?= $id ?>" title="<?= $chart_title ?>"></div>
<script>
let <?= $name ?> = function () {
diff --git a/resources/views/statistics/other/charts/combo.phtml b/resources/views/statistics/other/charts/combo.phtml
index cd5ee04d82..cfa8121c26 100644
--- a/resources/views/statistics/other/charts/combo.phtml
+++ b/resources/views/statistics/other/charts/combo.phtml
@@ -4,6 +4,12 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
+/**
+ * @var array<mixed> $chart_options
+ * @var array<array> $data
+ * @var string $language
+ */
+
$id = 'google-chart-' . bin2hex(random_bytes(8));
$name = 'callback_' . bin2hex(random_bytes(12));
?>
diff --git a/resources/views/statistics/other/charts/custom.phtml b/resources/views/statistics/other/charts/custom.phtml
index cacba3647c..ff846c74b1 100644
--- a/resources/views/statistics/other/charts/custom.phtml
+++ b/resources/views/statistics/other/charts/custom.phtml
@@ -4,6 +4,13 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
+/**
+ * @var array<mixed> $chart_options
+ * @var string $chart_title
+ * @var array<array> $data
+ * @var string $language
+ */
+
?>
<?php if (count($data) === 1) : ?>
@@ -17,7 +24,7 @@ use Fisharebest\Webtrees\I18N;
<?= $chart_title ?>
</div>
<div class="card-body">
- <?= view('statistics/other/charts/column', [ 'data' => $data, 'chart_options' => $chart_options, 'language' => $language]) ?>
+ <?= view('statistics/other/charts/column', [ 'data' => $data, 'chart_options' => $chart_options, 'chart_title' => '', 'language' => $language]) ?>
</div>
</div>
</div>
diff --git a/resources/views/statistics/other/charts/geo.phtml b/resources/views/statistics/other/charts/geo.phtml
index 72a5e09e89..d0434aadb4 100644
--- a/resources/views/statistics/other/charts/geo.phtml
+++ b/resources/views/statistics/other/charts/geo.phtml
@@ -4,6 +4,15 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
+/**
+ * @var string $chart_color2
+ * @var string $chart_color3
+ * @var string $chart_title
+ * @var array<array> $data
+ * @var string $language
+ * @var string $region
+ */
+
$id = 'google-chart-' . bin2hex(random_bytes(8));
$name = 'callback_' . bin2hex(random_bytes(12));
?>
diff --git a/resources/views/statistics/other/charts/pie.phtml b/resources/views/statistics/other/charts/pie.phtml
index a617116b38..5dbaaa75b4 100644
--- a/resources/views/statistics/other/charts/pie.phtml
+++ b/resources/views/statistics/other/charts/pie.phtml
@@ -4,6 +4,13 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
+/**
+ * @var array<string> $colors
+ * @var array<array> $data
+ * @var string $language
+ * @var string $title
+ */
+
$id = 'google-chart-' . bin2hex(random_bytes(8));
$name = 'callback_' . bin2hex(random_bytes(12));
?>
diff --git a/resources/views/statistics/other/top10-list.phtml b/resources/views/statistics/other/top10-list.phtml
index 8512f663da..84588a3ee5 100644
--- a/resources/views/statistics/other/top10-list.phtml
+++ b/resources/views/statistics/other/top10-list.phtml
@@ -5,11 +5,13 @@ declare(strict_types=1);
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Place;
-/* @var array $records */
-/* @var Place $place */
+/**
+ * @var array<array> $records
+ * @var Place $place
+ */
?>
-<?php if ($records) : ?>
+<?php if ($records !== []) : ?>
<ul class="list-group list-group-flush">
<?php foreach ($records as $record) : ?>
<?php $place = $record['place']; ?>
diff --git a/resources/views/submitter-page.phtml b/resources/views/submitter-page.phtml
index 666e4bffc4..1e01a2e432 100644
--- a/resources/views/submitter-page.phtml
+++ b/resources/views/submitter-page.phtml
@@ -1,10 +1,24 @@
<?php
use Fisharebest\Webtrees\Auth;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\Functions\FunctionsPrintFacts;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptRecord;
use Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectRecord;
use Fisharebest\Webtrees\I18N;
+use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Submitter;
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<Fact> $facts
+ * @var Collection<Family> $families
+ * @var Collection<Individual> $individuals
+ * @var Submitter $submitter
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/tree-page-block.phtml b/resources/views/tree-page-block.phtml
index 6f12ae435a..24a8bfb669 100644
--- a/resources/views/tree-page-block.phtml
+++ b/resources/views/tree-page-block.phtml
@@ -2,6 +2,13 @@
use Fisharebest\Webtrees\Http\RequestHandlers\TreePageBlock;
use Fisharebest\Webtrees\Module\ModuleBlockInterface;
+use Fisharebest\Webtrees\Tree;
+
+/**
+ * @var ModuleBlockInterface $block
+ * @var int $block_id
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/tree-page.phtml b/resources/views/tree-page.phtml
index b511971f02..62523edb31 100644
--- a/resources/views/tree-page.phtml
+++ b/resources/views/tree-page.phtml
@@ -1,3 +1,15 @@
+<?php
+
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<int,string> $main_blocks
+ * @var Collection<int,string> $side_blocks
+ * @var Tree $tree
+ */
+
+?>
<div class="row">
<?php if ($main_blocks->isEmpty() || $side_blocks->isEmpty()) : ?>
<div class="col-md-12 wt-main-blocks">
diff --git a/resources/views/user-page-block.phtml b/resources/views/user-page-block.phtml
index 577b39b4c0..59f8e278c6 100644
--- a/resources/views/user-page-block.phtml
+++ b/resources/views/user-page-block.phtml
@@ -2,6 +2,13 @@
use Fisharebest\Webtrees\Http\RequestHandlers\UserPageBlock;
use Fisharebest\Webtrees\Module\ModuleBlockInterface;
+use Fisharebest\Webtrees\Tree;
+
+/**
+ * @var ModuleBlockInterface $block
+ * @var int $block_id
+ * @var Tree $tree
+ */
?>
diff --git a/resources/views/user-page.phtml b/resources/views/user-page.phtml
index 0c2e4e2a8c..743159aa05 100644
--- a/resources/views/user-page.phtml
+++ b/resources/views/user-page.phtml
@@ -1,3 +1,16 @@
+<?php
+
+use Fisharebest\Webtrees\Tree;
+use Illuminate\Support\Collection;
+
+/**
+ * @var Collection<int,string> $main_blocks
+ * @var Collection<int,string> $side_blocks
+ * @var string $title
+ * @var Tree $tree
+ */
+
+?>
<h2 class="text-center">
<?= $title ?>
</h2>
diff --git a/resources/views/verify-failure-page.phtml b/resources/views/verify-failure-page.phtml
index 0e009f4ec2..6c23c660cb 100644
--- a/resources/views/verify-failure-page.phtml
+++ b/resources/views/verify-failure-page.phtml
@@ -2,6 +2,10 @@
use Fisharebest\Webtrees\I18N;
+/**
+ * @var string $title
+ */
+
?>
<h2 class="wt-page-title">
diff --git a/resources/views/verify-success-page.phtml b/resources/views/verify-success-page.phtml
index 0cc476aba5..5a643d793c 100644
--- a/resources/views/verify-success-page.phtml
+++ b/resources/views/verify-success-page.phtml
@@ -2,6 +2,10 @@
use Fisharebest\Webtrees\I18N;
+/**
+ * @var string $title
+ */
+
?>
<h2 class="wt-page-title">