Initial commit: Bocken theme for webtrees
Nord-themed dark/light mode family tree theme with: - Floating glass-morphism header bar - Auto/light/dark theme toggle with Lucide icons - Smart SVG logo with theme-aware fill colors - Active page highlighting with per-menu Nord icon colors - Language button showing 2-letter abbreviation - Start page search form - Mobile responsive icon-only nav - Custom views inherited from ArgonLight
This commit is contained in:
@@ -0,0 +1,155 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\Auth;
|
||||
use Fisharebest\Webtrees\Fact;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\AddNewFact;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\DeleteRecord;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\EditFactPage;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\EditRawRecordPage;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\ReorderFamiliesPage;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\ReorderMediaPage;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\ReorderNamesPage;
|
||||
use Fisharebest\Webtrees\I18N;
|
||||
use Fisharebest\Webtrees\Individual;
|
||||
use Illuminate\Support\Collection;
|
||||
|
||||
// Added by me
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\AddSpouseToIndividualPage;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\LinkSpouseToIndividualPage;
|
||||
use Fisharebest\Webtrees\Http\RequestHandlers\AddChildToIndividualPage;
|
||||
// End added
|
||||
|
||||
/**
|
||||
* @var bool $can_upload_media
|
||||
* @var Collection<int,Fact> $clipboard_facts
|
||||
* @var Individual $record
|
||||
* @var Collection<int,string> $shares
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<div class="dropdown wt-page-menu">
|
||||
<button class="btn btn-primary dropdown-toggle wt-page-menu-button" type="button" id="page-menu" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<?= view('icons/menu') ?>
|
||||
<?= I18N::translate('edit') ?>
|
||||
</button>
|
||||
|
||||
<div class="dropdown-menu dropdown-menu-end wt-page-menu-items" aria-labelledby="page-menu">
|
||||
<?php if ($shares->isNotEmpty()) : ?>
|
||||
<button class="dropdown-item" data-bs-toggle="modal" data-bs-target="#wt-shares-modal">
|
||||
<?= view('icons/share') ?>
|
||||
<?= I18N::translate('Share') ?>
|
||||
</button>
|
||||
|
||||
<hr>
|
||||
<?php endif ?>
|
||||
|
||||
<a class="dropdown-item" href="<?= e(route(AddNewFact::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref(), 'fact' => 'NAME'])) ?>">
|
||||
<?= view('icons/add') ?>
|
||||
<?= I18N::translate('Add a name') ?>
|
||||
</a>
|
||||
|
||||
<?php if ($record->facts(['NAME'], false, null, true)->count() > 1) : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(ReorderNamesPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/reorder') ?>
|
||||
<?= I18N::translate('Re-order names') ?>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<div class="dropdown-item disabled">
|
||||
<?= view('icons/spacer') ?>
|
||||
<?= I18N::translate('Re-order names') ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<div class="dropdown-divider"></div>
|
||||
|
||||
<?php if ($record->facts(['SEX'], false, null, true)->isEmpty()) : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(AddNewFact::class, ['fact' => 'SEX', 'tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/edit') ?>
|
||||
<?= I18N::translate('Edit the sex') ?>
|
||||
</a>
|
||||
<?php endif ?>
|
||||
|
||||
<?php foreach ($record->facts(['SEX'], false, null, true) as $fact) : ?>
|
||||
<?php if ($fact->canEdit()) : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(EditFactPage::class, ['xref' => $record->xref(), 'fact_id' => $fact->id(), 'tree' => $record->tree()->name()])) ?>">
|
||||
<?= view('icons/edit') ?>
|
||||
<?= I18N::translate('Edit the sex') ?>
|
||||
</a>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
|
||||
<div class="dropdown-divider"></div>
|
||||
|
||||
<?php if ($record->spouseFamilies()->count() > 1 || $record->childFamilies()->count() > 1) : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(ReorderFamiliesPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/reorder') ?>
|
||||
<?= I18N::translate('Re-order families') ?>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<div class="dropdown-item disabled">
|
||||
<?= view('icons/spacer') ?>
|
||||
<?= I18N::translate('Re-order families') ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<!-- ADDED BY ME -->
|
||||
<a class="dropdown-item" href="<?= e(route(AddSpouseToIndividualPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/add') ?>
|
||||
<?= I18N::translate($record->sex() === 'F' ? 'Add a husband' : 'Add a wife') ?>
|
||||
</a>
|
||||
<a class="dropdown-item" href="<?= e(route(LinkSpouseToIndividualPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/link') ?>
|
||||
<?= I18N::translate($record->sex() === 'F' ? 'Add a husband using an existing individual' : 'Add a wife using an existing individual') ?>
|
||||
</a>
|
||||
|
||||
<a class="dropdown-item" href="<?= e(route(AddChildToIndividualPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/individual') ?>
|
||||
<?= I18N::translate('Add a child') ?>
|
||||
</a>
|
||||
<!-- END ADDED -->
|
||||
|
||||
<div class="dropdown-divider"></div>
|
||||
|
||||
<?php if ($can_upload_media) : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(AddNewFact::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref(), 'fact' => 'OBJE'])) ?>">
|
||||
<?= view('icons/add') ?>
|
||||
<?= I18N::translate('Add a media object') ?>
|
||||
</a>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if ($record->facts(['OBJE'], false, null, true)->count() > 1) : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(ReorderMediaPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/reorder') ?>
|
||||
<?= I18N::translate('Re-order media') ?>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<div class="dropdown-item disabled">
|
||||
<?= view('icons/spacer') ?>
|
||||
<?= I18N::translate('Re-order media') ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if ($clipboard_facts->isNotEmpty()) : ?>
|
||||
<div class="dropdown-divider"></div>
|
||||
|
||||
<?= view('record-page-menu-clipboard', ['clipboard_facts' => $clipboard_facts, 'record' => $record]) ?>
|
||||
<?php endif ?>
|
||||
|
||||
<div class="dropdown-divider"></div>
|
||||
|
||||
<a class="dropdown-item" href="#" data-wt-confirm="<?= I18N::translate('Are you sure you want to delete “%s”?', strip_tags($record->fullName())) ?>" data-wt-post-url="<?= e(route(DeleteRecord::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/delete') ?>
|
||||
<?= I18N::translate('Delete') ?>
|
||||
</a>
|
||||
|
||||
<?php if (Auth::isAdmin() || $record->tree()->getPreference('SHOW_GEDCOM_RECORD') === '1') : ?>
|
||||
<a class="dropdown-item" href="<?= e(route(EditRawRecordPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>">
|
||||
<?= view('icons/edit') ?>
|
||||
<?= I18N::translate('Edit the raw GEDCOM') ?>
|
||||
</a>
|
||||
<?php endif ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,25 @@
|
||||
<input type="number" id="family-page" />
|
||||
|
||||
<?= view('::lists/families-table', get_defined_vars()); ?>
|
||||
|
||||
<script>
|
||||
window.onload = function() {
|
||||
var table = $(".wt-table-family").DataTable();
|
||||
var pageInput = $("#family-page");
|
||||
var queries = new URLSearchParams(window.location.search);
|
||||
|
||||
pageInput.on('keyup', function () {
|
||||
setPage(this.value);
|
||||
});
|
||||
table.on('page.dt', function () {
|
||||
pageInput.val(table.page() + 1);
|
||||
queries.set("page", table.page() + 1);
|
||||
window.history.pushState( {} , '', '?' + queries.toString() );
|
||||
});
|
||||
|
||||
setPage(queries.get("page"));
|
||||
function setPage(page){
|
||||
table.page(page - 1).draw('page');
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,25 @@
|
||||
<input type="number" id="individual-page" />
|
||||
|
||||
<?= view('::lists/individuals-table', get_defined_vars()); ?>
|
||||
|
||||
<script>
|
||||
window.onload = function() {
|
||||
var table = $(".wt-table-individual").DataTable();
|
||||
var pageInput = $("#individual-page");
|
||||
var queries = new URLSearchParams(window.location.search);
|
||||
|
||||
pageInput.on('keyup', function () {
|
||||
setPage(this.value);
|
||||
});
|
||||
table.on('page.dt', function () {
|
||||
pageInput.val(table.page() + 1);
|
||||
queries.set("page", table.page() + 1);
|
||||
window.history.pushState( {} , '', '?' + queries.toString() );
|
||||
});
|
||||
|
||||
setPage(queries.get("page"));
|
||||
function setPage(page){
|
||||
table.page(page - 1).draw('page');
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\I18N;
|
||||
|
||||
/**
|
||||
* @var string $block
|
||||
* @var string $content
|
||||
* @var string $config_url
|
||||
* @var int $id
|
||||
* @var string $title
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<div class="mb-4 wt-block wt-block-<?= e($block) ?>" id="block-<?= e($id) ?>">
|
||||
<h3 class="wt-block-header wt-block-header-<?= e($block) ?>">
|
||||
<?php if ($config_url !== '') : ?>
|
||||
<a class="btn btn-link" href="<?= e($config_url) ?>" title="<?= I18N::translate('Preferences') ?>">
|
||||
<?= view('icons/preferences') ?>
|
||||
<span class="visually-hidden"><?= I18N::translate('Preferences') ?></span>
|
||||
</a>
|
||||
<?php endif ?>
|
||||
<?= $title ?>
|
||||
</h3>
|
||||
<div class="wt-block-content wt-block-content-<?= e($block) ?>">
|
||||
<?= $content ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,69 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\I18N;
|
||||
use Fisharebest\Webtrees\Tree;
|
||||
use Fisharebest\Webtrees\View;
|
||||
|
||||
/**
|
||||
* @var string $individual_list
|
||||
* @var Tree $tree
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<form method="post" action="<?= e(route('module', ['module' => 'descendancy', 'action' => 'Descendants', 'tree' => $tree->name()])) ?>" onsubmit="return false;">
|
||||
<div class="form-group">
|
||||
<input type="search" name="sb_desc_name" id="sb_desc_name" class="form-control" placeholder="<?= I18N::translate('Search') ?>">
|
||||
<?= csrf_field() ?>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<div id="sb_desc_content">
|
||||
<ul>
|
||||
<?= $individual_list ?>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<?php View::push('javascript') ?>
|
||||
<script>
|
||||
function dsearchQ() {
|
||||
var query = $("#sb_desc_name").val();
|
||||
if (query.length>1) {
|
||||
$("#sb_desc_content").load(<?= json_encode(route('module', ['module' => 'descendancy', 'action' => 'Search', 'tree' => $tree->name(), 'search' => '']), JSON_THROW_ON_ERROR) ?> + encodeURIComponent(query));
|
||||
}
|
||||
}
|
||||
|
||||
$("#sb_desc_name").focus(function(){this.select();});
|
||||
$("#sb_desc_name").blur(function(){if (this.value === "") this.value="<?= I18N::translate('Search') ?>";});
|
||||
var dtimerid = null;
|
||||
$("#sb_desc_name").keyup(function(e) {
|
||||
if (dtimerid) window.clearTimeout(dtimerid);
|
||||
dtimerid = window.setTimeout("dsearchQ()", 500);
|
||||
});
|
||||
|
||||
$("#sb_desc_content").on("click", ".sb_desc_indi", function() {
|
||||
var self = $(this),
|
||||
state = self.children(".plusminus"),
|
||||
target = self.siblings("div");
|
||||
if(state.hasClass("icon-plus")) {
|
||||
if (jQuery.trim(target.html())) {
|
||||
target.show("fast"); // already got content so just show it
|
||||
} else if (this.dataset.wtHref !== "#") {
|
||||
target
|
||||
.hide()
|
||||
.load(this.dataset.wtHref, function(response, status, xhr) {
|
||||
if(status === "success" && response !== "") {
|
||||
target.show("fast");
|
||||
}
|
||||
})
|
||||
}
|
||||
} else {
|
||||
target.hide("fast");
|
||||
}
|
||||
state.toggleClass("icon-minus icon-plus");
|
||||
return false;
|
||||
});
|
||||
</script>
|
||||
<?php View::endpush() ?>
|
||||
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\I18N;
|
||||
|
||||
/**
|
||||
* @var array<int,object{
|
||||
* block_id: int,
|
||||
* block_order: int,
|
||||
* gedcom_id: int,
|
||||
* header: string,
|
||||
* faqbody: string,
|
||||
* languages: string
|
||||
* }> $faqs
|
||||
* @var string $title
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<h2 class="wt-page-title"><?= $title ?></h2>
|
||||
|
||||
<ul class="faq">
|
||||
<?php foreach ($faqs as $id => $faq) : ?>
|
||||
<li>
|
||||
<a href="#faq<?= e($id) ?>"><?= e($faq->header) ?></a>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
||||
<?php foreach ($faqs as $id => $faq) : ?>
|
||||
<article class="faq_article">
|
||||
<header class="faq_title" id="faq<?= $id ?>">
|
||||
<h3><?= e($faq->header) ?></h3>
|
||||
<span class="faq_top faq_italic">
|
||||
<a href="#content"><?= I18N::translate('back to top') ?></a>
|
||||
</span>
|
||||
</header>
|
||||
<main class="faq_body">
|
||||
<?= str_starts_with($faq->faqbody, '<') ? $faq->faqbody : nl2br(e($faq->faqbody), false) ?>
|
||||
</main>
|
||||
</article>
|
||||
<?php endforeach ?>
|
||||
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\Gedcom;
|
||||
use Fisharebest\Webtrees\Individual;
|
||||
|
||||
/**
|
||||
* @var string $dir
|
||||
* @var int $end_year
|
||||
* @var array<object{
|
||||
* background: string,
|
||||
* birth_year: int,
|
||||
* death_year: int,
|
||||
* id: string,
|
||||
* individual: Individual,
|
||||
* row: int
|
||||
* }> $lifespans
|
||||
* @var int $max_rows
|
||||
* @var int $start_year
|
||||
* @var string $subtitle
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<p class="wt-lifespans-subtitle">
|
||||
<?= $subtitle ?>
|
||||
</p>
|
||||
|
||||
<div class="wt-lifespans-scale">
|
||||
<?php for ($year = $start_year; $year < $end_year; $year += 10) :
|
||||
?><div class="wt-lifespans-decade"><?= $year ?></div><?php
|
||||
endfor ?>
|
||||
</div>
|
||||
|
||||
<div class="wt-lifespans-individuals position-relative" style="height: <?= (5 + $max_rows) * 1.5 ?>rem; width: <?= ($end_year - $start_year) * 7 ?>px;">
|
||||
<?php foreach ($lifespans as $lifespan) : ?>
|
||||
<a href="#" data-bs-toggle="collapse" data-bs-target="#<?= e($lifespan->id) ?>" aria-expanded="false" aria-controls="<?= e($lifespan->id) ?>">
|
||||
<div class="wt-lifespans-individual position-absolute text-nowrap text-truncate <?= 'wt-sex-'.strtolower($lifespan->individual->sex() ?? 'u') ?>" dir="auto" style="<?= $dir === 'ltr' ? 'left' : 'right' ?>:<?= ($lifespan->birth_year - $start_year) * 7 ?>px; top:<?= $lifespan->row * 2.5 ?>rem; width:<?= ($lifespan->death_year - $lifespan->birth_year) * 7 + 5 ?>px;">
|
||||
<?= $lifespan->individual->fullName() ?>
|
||||
<?= strip_tags($lifespan->individual->lifespan()) ?>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
<div class="wt-lifespans-summary collapse position-absolute" id="<?= e($lifespan->id) ?>" style="<?= $dir === 'ltr' ? 'left' : 'right' ?>:<?= (min($lifespan->birth_year, $end_year - 50) - $start_year) * 7 ?>px; top:<?= ($lifespan->row + 1.2) * 2.5 ?>rem; width:350px;">
|
||||
<a class="wt-lifespans-summary-link" href="<?= e($lifespan->individual->url()) ?>">
|
||||
<?= $lifespan->individual->fullName() ?>
|
||||
</a>
|
||||
|
||||
<?php foreach ($lifespan->individual->facts(array_merge(Gedcom::BIRTH_EVENTS, Gedcom::DEATH_EVENTS), true) as $fact) : ?>
|
||||
<?= $fact->summary() ?>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\Media;
|
||||
use Illuminate\Support\Collection;
|
||||
|
||||
/**
|
||||
* @var Collection<int,Media> $media_list
|
||||
*/
|
||||
|
||||
?>
|
||||
<div class="wt-tab-album container px-0 py-4">
|
||||
<div class="row">
|
||||
<?php foreach ($media_list as $media) : ?>
|
||||
<figure class="figure text-center col-sm-6 col-md-4 col-lg-3 col-xl-3 wt-album-tab-figure">
|
||||
<?php foreach ($media->mediaFiles() as $media_file) : ?>
|
||||
<?= $media_file->displayImage(100, 100, 'contain', ['class' => 'img-thumbnail wt-album-tab-image']) ?>
|
||||
<?php endforeach ?>
|
||||
<figcaption class="figure-caption wt-album-tab-caption">
|
||||
<a href="<?= e($media->url()) ?>">
|
||||
<?= $media->fullName() ?>
|
||||
</a>
|
||||
</figcaption>
|
||||
</figure>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\I18N;
|
||||
use Fisharebest\Webtrees\Place;
|
||||
|
||||
/**
|
||||
* @var array<array<Place>> $columns
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
<h5 class="col list_label text-center">
|
||||
<?= I18N::translate('Place list') ?>
|
||||
</h5>
|
||||
</div>
|
||||
<div class="row">
|
||||
<?php foreach ($columns as $column) : ?>
|
||||
<ul class="col wt-page-options-value me-1 list-unstyled">
|
||||
<?php foreach ($column as $place) : ?>
|
||||
<li><?= $place->fullName(true) ?></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Fisharebest\Webtrees\Contracts\TimestampInterface;
|
||||
use Fisharebest\Webtrees\Contracts\UserInterface;
|
||||
use Fisharebest\Webtrees\GedcomRecord;
|
||||
use Fisharebest\Webtrees\I18N;
|
||||
use Fisharebest\Webtrees\View;
|
||||
use Illuminate\Support\Collection;
|
||||
|
||||
/**
|
||||
* @var int $id
|
||||
* @var int $limit_low
|
||||
* @var int $limit_high
|
||||
* @var Collection<int,object{record:GedcomRecord,time:TimestampInterface,user:UserInterface}> $rows
|
||||
* @var bool $show_date
|
||||
* @var bool $show_user
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<div class="list-group">
|
||||
<?php foreach ($rows as $n => $row): ?>
|
||||
<?php if ($n === $limit_low && $rows->count() > $limit_high): ?>
|
||||
<div>
|
||||
<button class="btn btn-sm btn-secondary my-3" id="show-more-<?= e($id) ?>">
|
||||
<?= view('icons/add') ?>
|
||||
<?= /* I18N: button label */ I18N::translate('show more') ?>
|
||||
</button>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<a href="<?= e($row->record->url()) ?>" class="<?= $n >= $limit_low && $rows->count() > $limit_high ? 'd-none' : '' ?> list-group-item list-group-item-action">
|
||||
<span class="d-block"><?= $row->record->fullName() ?></span>
|
||||
|
||||
<small class="d-block">
|
||||
<?php if ($show_user && $show_date): ?>
|
||||
<?= /* I18N: [a record was] Changed on <date/time> by <user> */ I18N::translate('Changed on %1$s by %2$s', view('components/datetime', ['timestamp' => $row->time]), e($row->record->lastChangeUser())) ?>
|
||||
<?php elseif ($show_date): ?>
|
||||
<?= /* I18N: [a record was] Changed on <date/time> */ I18N::translate('Changed on %1$s', view('components/datetime', ['timestamp' => $row->time])) ?>
|
||||
<?php elseif ($show_user): ?>
|
||||
<?= /* I18N: [a record was] Changed by <user> */ I18N::translate('Changed by %1$s', e($row->user->userName())) ?>
|
||||
<?php endif ?>
|
||||
</small>
|
||||
</a>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
|
||||
<?php View::push('javascript') ?>
|
||||
<script>
|
||||
document.getElementById("show-more-<?= e($id) ?>").addEventListener("click", function (ev) {
|
||||
document.querySelectorAll("#block-<?= e($id) ?> .d-none").forEach(function (el) {
|
||||
el.classList.remove("d-none");
|
||||
});
|
||||
ev.target.parentNode.removeChild(ev.target);
|
||||
});
|
||||
</script>
|
||||
<?php View::endpush() ?>
|
||||
Reference in New Issue
Block a user