events : carte cliquable, template event, ajustement padding
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
8df354bfcb
commit
4df018d5cb
3 changed files with 18 additions and 14 deletions
|
|
@ -2,7 +2,7 @@
|
|||
.events-grid {
|
||||
box-sizing: border-box;
|
||||
padding: 0 var(--space-body);
|
||||
padding-top: 6rem;
|
||||
padding-top: 7rem;
|
||||
width: 100%;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,3 @@
|
|||
<?php snippet('head') ?>
|
||||
<?php snippet('header') ?>
|
||||
<?php snippet('footer') ?>
|
||||
|
|
@ -4,19 +4,20 @@
|
|||
<ul class="events-grid">
|
||||
<?php foreach($page->children() as $event): ?>
|
||||
<li class="event-card">
|
||||
<h2><?= $event->title() ?></h2>
|
||||
<a href="<?= $event->url() ?>"></a>
|
||||
<div class="cover-wrapper">
|
||||
<?php if ($event->isLive()): ?>
|
||||
<div class="playing-now"><p>En ce moment</p></div>
|
||||
<?php endif ?>
|
||||
<?php snippet('picture', [
|
||||
'file' => $event->cover()->toFile(),
|
||||
'srcsetName' => 'event-card',
|
||||
'sizes' => '(min-width: 800px) 30vw, 100vw',
|
||||
'alt' => $event->title()->value(),
|
||||
]) ?>
|
||||
</div>
|
||||
<a href="<?= $event->url() ?>">
|
||||
<h2><?= $event->title() ?></h2>
|
||||
<div class="cover-wrapper">
|
||||
<?php if ($event->isLive()): ?>
|
||||
<div class="playing-now"><p>En ce moment</p></div>
|
||||
<?php endif ?>
|
||||
<?php snippet('picture', [
|
||||
'file' => $event->cover()->toFile(),
|
||||
'srcsetName' => 'event-card',
|
||||
'sizes' => '(min-width: 800px) 30vw, 100vw',
|
||||
'alt' => $event->title()->value(),
|
||||
]) ?>
|
||||
</div>
|
||||
</a>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue