2024-07-24 09:43:31 +02:00
< ? php snippet ( 'header' ) ?>
2024-07-31 08:50:49 +02:00
< section class = " hero " >
2024-07-30 12:07:47 +02:00
< div class = " hero__text " >
< ? = $site -> heroText () -> toBlocks () ?>
</ div >
< div class = " hero__image " >
< ? php snippet ( 'picture' , [ 'file' => $site -> heroImage () -> toFile ()]) ?>
</ div >
2024-07-31 08:50:49 +02:00
</ section >
2024-08-26 17:03:32 +02:00
< ? php //snippet('calendar-strip') ?>
2024-07-31 08:50:49 +02:00
2024-07-30 19:03:01 +02:00
< ? php
$currentSeason = page ( 'programme' ) -> children () -> first () -> children ();
$orderedEvents = $currentSeason -> sortBy ( function ( $event ) {
if ( $event -> isMapadoEvent () == 'true' ) {
return $event -> remoteSessions () -> toStructure () -> toArray ()[ 0 ][ 'date' ];
} else {
return $event -> sessions () -> toStructure () -> toArray ()[ 0 ][ 'date' ];
}
},
'asc'
);
2024-07-31 11:20:08 +02:00
snippet ( 'events-grid' , [ 'events' => $orderedEvents -> slice ( 0 , 2 )])
2024-07-30 19:03:01 +02:00
?>
2024-07-31 08:50:49 +02:00
< ? php snippet ( 'newsletter-section' ) ?>
2024-07-31 11:20:08 +02:00
< ? php snippet ( 'events-grid' , [ 'events' => $orderedEvents -> slice ( 2 , 5 )]) ?>
2024-07-31 12:09:03 +02:00
< section class = " callout " >
< h4 >< ? = $site -> callout () ?> </h4>
2024-08-28 10:34:08 +02:00
< a class = " to-blank ticket-link " href = " <?= option('ticketingUrl') ?> " target = " _blank " title = " Aller à la billetterie " >< ? php snippet ( 'ticket' ) ?> Billetterie</a>
2024-07-31 12:09:03 +02:00
</ section >
2024-07-24 09:43:31 +02:00
< ? php snippet ( 'footer' ) ?>