diff --git a/assets/css/src/calendar-strip.css b/assets/css/src/calendar-strip.css index cb77f28..df67b7c 100644 --- a/assets/css/src/calendar-strip.css +++ b/assets/css/src/calendar-strip.css @@ -88,7 +88,8 @@ .calendar-strip .session { position: relative; display: grid; - grid-template-columns: 1fr 1fr 0.5fr 1.5fr 1.5fr; + grid-template-columns: 0.7fr 1.4fr 0.8fr 1.2fr 1.6fr; + column-gap: 2vw; padding: var(--padding-vertical) var(--space-m); } @@ -98,6 +99,19 @@ z-index: 1; } +.calendar-strip .session__info--duration p { + margin-bottom: 0; +} + +.calendar-strip .session__info--book .ticket-link { + width: fit-content; +} +.calendar-strip .session__info--book { + text-align: right; + text-align: -moz-right; + text-align: -webkit-right; +} + @media screen and (max-width: 800px) { .calendar-strip { --padding-vertical: 1rem; diff --git a/site/config/routes/get-current-season-calendar.php b/site/config/routes/get-current-season-calendar.php index 200e51e..5366380 100644 --- a/site/config/routes/get-current-season-calendar.php +++ b/site/config/routes/get-current-season-calendar.php @@ -56,8 +56,6 @@ return [ $request = createMapadoEventRequest($event); $mapadoEvent = fetchMapadoEvent($request); - $duration = null; - $sessionsToSave = []; foreach ($mapadoEvent->eventDateList as $session) { @@ -73,17 +71,13 @@ return [ $ticketingUrl = option('ticketingUrl') . 'event/' . $mapadoEvent->slug . '?eventDate=' . $eventDateId; $bookableStock = $session->notInStockContingentBookableStock; - if (isset($session->endDate) && !$duration) { - $endTime = substr($session->endDate, 11 , 5); - $duration = getTimeDifference($startTime, $endTime); - } - $calendar[$sessionMonth][$sessionDay]['sessions'][] = array_merge($eventInfos, [ "color" => $event->color()->value(), "day" => $sessionDay, "time" => str_replace(':', 'h', $startTime), - "duration" => $duration, + "duration" => $event->duration()->value(), "place" => $event->place()->value(), + "public" => $event->public()->value(), "eventUrl" => $event->url(), "ticketingUrl" => $ticketingUrl, "bookableStock" => $bookableStock, diff --git a/site/snippets/calendar-strip.php b/site/snippets/calendar-strip.php index 5556371..ec396bd 100644 --- a/site/snippets/calendar-strip.php +++ b/site/snippets/calendar-strip.php @@ -1,6 +1,5 @@

-

+

@@ -175,7 +174,12 @@

-
+ +
+

+

+
+