@@ -962,7 +962,7 @@ discard block |
||
| 962 | 962 | |
| 963 | 963 | $data = [ |
| 964 | 964 | array_merge( |
| 965 | - [ I18N::translate('Century') ], |
|
| 965 | + [I18N::translate('Century')], |
|
| 966 | 966 | array_values($z_axis) |
| 967 | 967 | ) |
| 968 | 968 | ]; |
@@ -979,7 +979,7 @@ discard block |
||
| 979 | 979 | |
| 980 | 980 | foreach ($intermediate as $key => $values) { |
| 981 | 981 | $data[] = array_merge( |
| 982 | - [ $x_axis[$key] ], |
|
| 982 | + [$x_axis[$key]], |
|
| 983 | 983 | $values |
| 984 | 984 | ); |
| 985 | 985 | } |
@@ -177,7 +177,7 @@ |
||
| 177 | 177 | |
| 178 | 178 | // Father’s ancestors link to the father’s pedigree |
| 179 | 179 | // Mother’s ancestors link to the mother’s pedigree.. |
| 180 | - $links = $ancestors->map(function (?Individual $individual, $sosa) use ($ancestors, $orientation, $generations): string { |
|
| 180 | + $links = $ancestors->map(function (?Individual $individual, $sosa) use ($ancestors, $orientation, $generations) : string { |
|
| 181 | 181 | if ($individual instanceof Individual && $sosa >= 2 ** $generations / 2 && !empty($individual->childFamilies())) { |
| 182 | 182 | // The last row/column, and there are more generations. |
| 183 | 183 | if ($sosa >= 2 ** $generations * 3 / 4) { |
@@ -259,7 +259,7 @@ discard block |
||
| 259 | 259 | echo '<td>'; |
| 260 | 260 | foreach ($person->childFamilies() as $cfamily) { |
| 261 | 261 | foreach ($cfamily->spouses() as $parent) { |
| 262 | - echo '<a href="' . e($this->chartUrl($parent, ['generations' => $generations])) . '" title="' . I18N::translate('Start at parents') . '">' . view('icons/arrow-up') . '<span class="sr-only">' . I18N::translate('Start at parents') . '</span></a>'; |
|
| 262 | + echo '<a href="' . e($this->chartUrl($parent, ['generations' => $generations])) . '" title="' . I18N::translate('Start at parents') . '">' . view('icons/arrow-up') . '<span class="sr-only">' . I18N::translate('Start at parents') . '</span></a>'; |
|
| 263 | 263 | // only show the arrow for one of the parents |
| 264 | 264 | break; |
| 265 | 265 | } |
@@ -338,7 +338,7 @@ discard block |
||
| 338 | 338 | if ($spouse) { |
| 339 | 339 | foreach ($spouse->childFamilies() as $cfamily) { |
| 340 | 340 | foreach ($cfamily->spouses() as $parent) { |
| 341 | - echo '<a href="' . e($this->chartUrl($parent, ['generations' => $generations])) . '" title="' . strip_tags($this->chartTitle($parent)) . '">' . view('icons/arrow-up') . '<span class="sr-only">' . strip_tags($this->chartTitle($parent)) . '</span></a>'; |
|
| 341 | + echo '<a href="' . e($this->chartUrl($parent, ['generations' => $generations])) . '" title="' . strip_tags($this->chartTitle($parent)) . '">' . view('icons/arrow-up') . '<span class="sr-only">' . strip_tags($this->chartTitle($parent)) . '</span></a>'; |
|
| 342 | 342 | // only show the arrow for one of the parents |
| 343 | 343 | break; |
| 344 | 344 | } |
@@ -103,11 +103,11 @@ |
||
| 103 | 103 | $record = GedcomRecord::getInstance('HEAD', $tree); |
| 104 | 104 | $fact = $record->facts(['COPR'])->first(); |
| 105 | 105 | if ($fact instanceof Fact) { |
| 106 | - $COPR = "\n1 COPR " .$fact->value(); |
|
| 106 | + $COPR = "\n1 COPR " . $fact->value(); |
|
| 107 | 107 | } |
| 108 | - $fact = $record->facts(['LANG'])->first(); |
|
| 108 | + $fact = $record->facts(['LANG'])->first(); |
|
| 109 | 109 | if ($fact instanceof Fact) { |
| 110 | - $LANG = "\n1 LANG " .$fact->value(); |
|
| 110 | + $LANG = "\n1 LANG " . $fact->value(); |
|
| 111 | 111 | } |
| 112 | 112 | // Link to actual SUBM/SUBN records, if they exist |
| 113 | 113 | $subn = DB::table('other') |
@@ -110,7 +110,7 @@ discard block |
||
| 110 | 110 | 'generations' => 3, |
| 111 | 111 | 'layout' => PedigreeChartModule::ORIENTATION_RIGHT, |
| 112 | 112 | ]); |
| 113 | - $content = view('modules/charts/chart', [ |
|
| 113 | + $content = view('modules/charts/chart', [ |
|
| 114 | 114 | 'block_id' => $block_id, |
| 115 | 115 | 'chart_url' => $chart_url, |
| 116 | 116 | ]); |
@@ -125,7 +125,7 @@ discard block |
||
| 125 | 125 | 'generations' => 2, |
| 126 | 126 | 'chart_style' => DescendancyChartModule::CHART_STYLE_LIST, |
| 127 | 127 | ]); |
| 128 | - $content = view('modules/charts/chart', [ |
|
| 128 | + $content = view('modules/charts/chart', [ |
|
| 129 | 129 | 'block_id' => $block_id, |
| 130 | 130 | 'chart_url' => $chart_url, |
| 131 | 131 | ]); |
@@ -139,7 +139,7 @@ discard block |
||
| 139 | 139 | 'ajax' => true, |
| 140 | 140 | 'generations' => 2, |
| 141 | 141 | ]); |
| 142 | - $content = view('modules/charts/chart', [ |
|
| 142 | + $content = view('modules/charts/chart', [ |
|
| 143 | 143 | 'block_id' => $block_id, |
| 144 | 144 | 'chart_url' => $chart_url, |
| 145 | 145 | ]); |
@@ -125,10 +125,10 @@ discard block |
||
| 125 | 125 | switch ($show_marnm) { |
| 126 | 126 | case 'no': |
| 127 | 127 | case 'yes': |
| 128 | - $user->setPreference($families?'family-list-marnm':'individual-list-marnm', $show_marnm); |
|
| 128 | + $user->setPreference($families ? 'family-list-marnm' : 'individual-list-marnm', $show_marnm); |
|
| 129 | 129 | break; |
| 130 | 130 | default: |
| 131 | - $show_marnm = $user->getPreference($families?'family-list-marnm':'individual-list-marnm'); |
|
| 131 | + $show_marnm = $user->getPreference($families ? 'family-list-marnm' : 'individual-list-marnm'); |
|
| 132 | 132 | } |
| 133 | 133 | |
| 134 | 134 | // Make sure selections are consistent. |
@@ -160,7 +160,7 @@ discard block |
||
| 160 | 160 | 'ged' => $tree->name(), |
| 161 | 161 | 'show_all' => 'yes', |
| 162 | 162 | ]; |
| 163 | - $show = $request->get('show', 'surn'); |
|
| 163 | + $show = $request->get('show', 'surn'); |
|
| 164 | 164 | } |
| 165 | 165 | } elseif ($surname) { |
| 166 | 166 | $alpha = $this->localization_service->initialLetter($surname); // so we can highlight the initial letter |
@@ -233,7 +233,8 @@ discard block |
||
| 233 | 233 | <li class="wt-initials-list-item d-flex"> |
| 234 | 234 | <?php if ($count > 0) : ?> |
| 235 | 235 | <a href="<?= e(route('module', ['module' => $module, 'action' => $action, 'alpha' => $letter, 'ged' => $tree->name()])) ?>" class="wt-initial px-1<?= $letter === $alpha ? ' active' : '' ?> '" title="<?= I18N::number($count) ?>"><?= $this->surnameInitial((string) $letter) ?></a> |
| 236 | - <?php else : ?> |
|
| 236 | + <?php else { |
|
| 237 | + : ?> |
|
| 237 | 238 | <span class="wt-initial px-1 text-muted"><?= $this->surnameInitial((string) $letter) ?></span> |
| 238 | 239 | |
| 239 | 240 | <?php endif ?> |
@@ -287,6 +288,7 @@ discard block |
||
| 287 | 288 | |
| 288 | 289 | if ($show === 'indi' || $show === 'surn') { |
| 289 | 290 | $surns = $this->individual_list_service->surnames($surname, $alpha, $show_marnm === 'yes', $families, WT_LOCALE, I18N::collation()); |
| 291 | +} |
|
| 290 | 292 | if ($show === 'surn') { |
| 291 | 293 | // Show the surname list |
| 292 | 294 | switch ($tree->getPreference('SURNAME_LIST_STYLE')) { |
@@ -49,7 +49,7 @@ |
||
| 49 | 49 | */ |
| 50 | 50 | public function __construct(Tree $tree) |
| 51 | 51 | { |
| 52 | - $this->tree = $tree; |
|
| 52 | + $this->tree = $tree; |
|
| 53 | 53 | $this->country_service = new CountryService(); |
| 54 | 54 | } |
| 55 | 55 | |
@@ -87,7 +87,7 @@ |
||
| 87 | 87 | public function getMenu(Tree $tree): ?Menu |
| 88 | 88 | { |
| 89 | 89 | $submenus = $this->module_service->findByComponent(ModuleListInterface::class, $tree, Auth::user()) |
| 90 | - ->map(function (ModuleListInterface $module) use ($tree): ?Menu { |
|
| 90 | + ->map(function (ModuleListInterface $module) use ($tree) : ?Menu { |
|
| 91 | 91 | return $module->listMenu($tree); |
| 92 | 92 | }) |
| 93 | 93 | ->filter() |
@@ -2616,7 +2616,7 @@ |
||
| 2616 | 2616 | /** @var ModuleBlockInterface|null $module */ |
| 2617 | 2617 | $module = $this->module_service |
| 2618 | 2618 | ->findByComponent(ModuleBlockInterface::class, $this->tree, Auth::user()) |
| 2619 | - ->filter(function (ModuleInterface $module) use ($block): bool { |
|
| 2619 | + ->filter(function (ModuleInterface $module) use ($block) : bool { |
|
| 2620 | 2620 | return $module->name() === $block && $module->name() !== 'html'; |
| 2621 | 2621 | }) |
| 2622 | 2622 | ->first(); |