Display content search header with results number

This commit is contained in:
Yuriy Bakhtin 2024-03-07 17:50:44 +01:00
parent eae0d494aa
commit 7ecd808d72
3 changed files with 14 additions and 1 deletions

View File

@ -42,6 +42,9 @@ $hasResults = $resultSet !== null && count($resultSet->results);
<?php endif; ?>
<?php if ($hasResults): ?>
<div class="search-results-header">
<?= Yii::t('ContentModule.search', 'Results ({count})', ['count' => $resultSet->pagination->totalCount]) ?>
</div>
<div class="search-results">
<?php foreach ($resultSet->results as $result): ?>
<?= StreamEntryWidget::renderStreamEntry($result->getModel(),

View File

@ -1,3 +1,4 @@
// Dropdown/Modal search window:
#dropdown-search.dropdown-menu {
left: auto;
right: 0;
@ -215,3 +216,12 @@
}
}
}
// Search results page list:
.search-results-header {
font-size: 12px;
line-height: 1.5;
padding: 10px 0 15px;
margin-bottom: 10px;
border-bottom: 1px solid #ddd;
}

File diff suppressed because one or more lines are too long