Merged in feature/select-room-ux-one-page (pull request #523)

This updates the select room page according to the new UX. It has different sections on the same page, but with specific URLs per section. Since neither UX, UI nor API is completely done both design and data structures are a bit temporary.

Approved-by: Simon.Emanuelsson
This commit is contained in:
Niclas Edenvin
2024-08-29 13:38:14 +00:00
parent 00fc2af3dd
commit f178f7fde0
35 changed files with 794 additions and 372 deletions

View File

@@ -468,14 +468,24 @@ export const getHotelDataSchema = z.object({
included: z.array(roomSchema).optional(),
})
const flexibilityPrice = z.object({
standard: z.number(),
member: z.number(),
})
const rate = z.object({
id: z.number(),
name: z.string(),
description: z.string(),
size: z.string(),
pricePerNight: z.number(),
currency: z.string(),
imageSrc: z.string(),
breakfastIncluded: z.boolean(),
prices: z.object({
currency: z.string(),
nonRefundable: flexibilityPrice,
freeRebooking: flexibilityPrice,
freeCancellation: flexibilityPrice,
}),
})
export const getRatesSchema = z.array(rate)

View File

@@ -4,53 +4,101 @@
"name": "Cabin",
"description": "Stylish, peaceful and air-conditioned room. The rooms have small clerestory windows.",
"size": "17 - 24 m² (1 - 2 persons)",
"pricePerNight": 1348,
"currency": "SEK",
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg"
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg",
"breakfastIncluded": false,
"prices": {
"currency": "SEK",
"nonRefundable": {
"standard": 2315,
"member": 2247
},
"freeRebooking": { "standard": 2437, "member": 2365 },
"freeCancellation": { "standard": 2620, "member": 2542 }
}
},
{
"id": 2,
"name": "Standard",
"description": "Stylish, peaceful and air-conditioned room. The rooms have small clerestory windows.",
"size": "19 - 30 m² (1 - 2 persons)",
"pricePerNight": 1548,
"currency": "SEK",
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg"
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg",
"breakfastIncluded": false,
"prices": {
"currency": "SEK",
"nonRefundable": {
"standard": 2315,
"member": 2247
},
"freeRebooking": { "standard": 2437, "member": 2365 },
"freeCancellation": { "standard": 2620, "member": 2542 }
}
},
{
"id": 3,
"name": "Superior",
"description": "Stylish, peaceful and air-conditioned room. The rooms have small clerestory windows.",
"size": "22 - 40 m² (1 - 3 persons)",
"pricePerNight": 1744,
"currency": "SEK",
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg"
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg",
"breakfastIncluded": false,
"prices": {
"currency": "SEK",
"nonRefundable": {
"standard": 2315,
"member": 2247
},
"freeRebooking": { "standard": 2437, "member": 2365 },
"freeCancellation": { "standard": 2620, "member": 2542 }
}
},
{
"id": 4,
"name": "Superior Family",
"description": "Stylish, peaceful and air-conditioned room. The rooms have small clerestory windows.",
"size": "29 - 49 m² (3 - 4 persons)",
"pricePerNight": 2032,
"currency": "SEK",
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg"
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg",
"breakfastIncluded": false,
"prices": {
"currency": "SEK",
"nonRefundable": {
"standard": 2315,
"member": 2247
},
"freeRebooking": { "standard": 2437, "member": 2365 },
"freeCancellation": { "standard": 2620, "member": 2542 }
}
},
{
"id": 5,
"name": "Superior PLUS",
"description": "Stylish, peaceful and air-conditioned room. The rooms have small clerestory windows.",
"size": "21 - 28 m² (2 - 3 persons)",
"pricePerNight": 2065,
"currency": "SEK",
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg"
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg",
"breakfastIncluded": false,
"prices": {
"currency": "SEK",
"nonRefundable": {
"standard": 2315,
"member": 2247
},
"freeRebooking": { "standard": 2437, "member": 2365 },
"freeCancellation": { "standard": 2620, "member": 2542 }
}
},
{
"id": 6,
"name": "Junior Suite",
"description": "Stylish, peaceful and air-conditioned room. The rooms have small clerestory windows.",
"size": "35 - 43 m² (2 - 4 persons)",
"pricePerNight": 3012,
"currency": "SEK",
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg"
"imageSrc": "https://www.scandichotels.se/imageVault/publishedmedia/xnmqnmz6mz0uhuat0917/scandic-helsinki-hub-room-standard-KR-7.jpg",
"breakfastIncluded": false,
"prices": {
"currency": "SEK",
"nonRefundable": {
"standard": 2315,
"member": 2247
},
"freeRebooking": { "standard": 2437, "member": 2365 },
"freeCancellation": { "standard": 2620, "member": 2542 }
}
}
]