don't show collapsable sections that are empty
This commit is contained in:
parent
b0142b4c21
commit
7c4e5d52b8
2 changed files with 20 additions and 16 deletions
|
|
@ -220,7 +220,7 @@ img.show {
|
|||
.main-nav a,
|
||||
.main-footer a,
|
||||
.hero__text a,
|
||||
.collapsable__content a {
|
||||
.collapsable__content a:not(.ticket-link) {
|
||||
display: block;
|
||||
scale: 1;
|
||||
transition: scale 0.5s var(--curve-quick);
|
||||
|
|
@ -239,7 +239,7 @@ img.show {
|
|||
.main-nav a:hover,
|
||||
.main-footer a:hover,
|
||||
.hero__text a:hover,
|
||||
.collapsable__content a:hover,
|
||||
.collapsable__content a:not(.ticket-link):hover,
|
||||
.anchors-strip a:hover {
|
||||
scale: var(--scale-up);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -117,23 +117,25 @@
|
|||
<?php endif ?>
|
||||
<?php endsnippet() ?>
|
||||
|
||||
<?php snippet('collapsable-section', ['title' => 'Distribution et production'], slots: true) ?>
|
||||
<?php slot('content') ?>
|
||||
<div class="production">
|
||||
<?php foreach ($page->production()->toLayouts() as $layout): ?>
|
||||
<div class="collapsable__item--padding grid" id="<?= $layout->id() ?>">
|
||||
<?php foreach ($layout->columns() as $column): ?>
|
||||
<div class="grid__item" style="--span:<?= $column->span() ?>">
|
||||
<div class="blocks">
|
||||
<?= $column->blocks() ?>
|
||||
<?php if ($page->production()->isNotEmpty()): ?>
|
||||
<?php snippet('collapsable-section', ['title' => 'Distribution et production'], slots: true) ?>
|
||||
<?php slot('content') ?>
|
||||
<div class="production">
|
||||
<?php foreach ($page->production()->toLayouts() as $layout): ?>
|
||||
<div class="collapsable__item--padding grid" id="<?= $layout->id() ?>">
|
||||
<?php foreach ($layout->columns() as $column): ?>
|
||||
<div class="grid__item" style="--span:<?= $column->span() ?>">
|
||||
<div class="blocks">
|
||||
<?= $column->blocks() ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
<?php endslot() ?>
|
||||
<?php endsnippet() ?>
|
||||
<?php endslot() ?>
|
||||
<?php endsnippet() ?>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if ($page->resources()->isNotEmpty()): ?>
|
||||
<?php snippet('collapsable-section', ['title' => 'Ressources'], slots: true) ?>
|
||||
|
|
@ -152,7 +154,9 @@
|
|||
<?php endif ?>
|
||||
</section>
|
||||
|
||||
<?php snippet('events-grid', ['title' => 'Pour aller plus loin', 'events' => $page->linkedPages()->toPages()]) ?>
|
||||
<?php if ($page->linkedPages()->isNotEmpty()): ?>
|
||||
<?php snippet('events-grid', ['title' => 'Pour aller plus loin', 'events' => $page->linkedPages()->toPages()]) ?>
|
||||
<?php endif ?>
|
||||
|
||||
<?php snippet('callout') ?>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue