fix(SW-302): show max. 2 images per grid

This commit is contained in:
Matilda Landström
2024-10-01 13:54:34 +02:00
parent c3fbd35cff
commit e7f6cc7268

View File

@@ -86,7 +86,8 @@ export async function setFacilityCards(
const grid: Array<CardProps> = []
let card: CardProps = {}
facility.heroImages.forEach((image) => {
facility.heroImages.slice(0, 2).forEach((image) => {
// Can be a maximum 2 images per grid
const img: CardProps = {}
;(img.backgroundImage = {
url: image.imageSizes.large,