Merged in feat/BOOK-479-scandic-go-hotels-rm-brf- (pull request #3143)
feat(BOOK-479): Updated breakfast UI for ScandicGo hotels Approved-by: Erik Tiekstra
This commit is contained in:
@@ -15,7 +15,7 @@ import { ChildBedTypeEnum } from "@scandic-hotels/trpc/enums/childBedTypeEnum"
|
||||
|
||||
import { useBookingConfirmationStore } from "../../../../stores/booking-confirmation"
|
||||
import { getRoomFeatureDescription } from "../../../../utils/getRoomFeatureDescription"
|
||||
import Breakfast from "./Breakfast"
|
||||
import { SummaryBreakfast } from "../../../SummaryBreakfast"
|
||||
import RoomSkeletonLoader from "./RoomSkeletonLoader"
|
||||
|
||||
import styles from "./room.module.css"
|
||||
@@ -36,11 +36,12 @@ export function ReceiptRoom({
|
||||
showBookingCodeChip = false,
|
||||
}: BookingConfirmationReceiptRoomProps) {
|
||||
const intl = useIntl()
|
||||
const { currencyCode, isVatCurrency, bookingCode } =
|
||||
const { currencyCode, isVatCurrency, bookingCode, hotelOffersBreakfast } =
|
||||
useBookingConfirmationStore((state) => ({
|
||||
currencyCode: state.currencyCode,
|
||||
isVatCurrency: state.isVatCurrency,
|
||||
bookingCode: state.bookingCode,
|
||||
hotelOffersBreakfast: state.hotelOffersBreakfast,
|
||||
}))
|
||||
|
||||
if (!room) {
|
||||
@@ -80,6 +81,11 @@ export function ReceiptRoom({
|
||||
const showDiscounted =
|
||||
room.rateDefinition.isMemberRate || room.rateDefinition.isCampaignRate
|
||||
|
||||
const breakfastPrice = room.breakfast
|
||||
? room.breakfast?.totalPrice
|
||||
: room.breakfast
|
||||
const breakfastCurrency = room.breakfast ? room.breakfast?.currency : null
|
||||
|
||||
return (
|
||||
<>
|
||||
<div className={styles.room}>
|
||||
@@ -275,10 +281,12 @@ export function ReceiptRoom({
|
||||
</div>
|
||||
</Typography>
|
||||
) : null}
|
||||
<Breakfast
|
||||
breakfast={room.breakfast}
|
||||
<SummaryBreakfast
|
||||
breakfastPrice={breakfastPrice}
|
||||
breakfastCurrency={breakfastCurrency}
|
||||
breakfastIncluded={room.breakfastIncluded}
|
||||
guests={guests}
|
||||
hotelOffersBreakfast={hotelOffersBreakfast}
|
||||
/>
|
||||
|
||||
{showBookingCodeChip && (
|
||||
|
||||
Reference in New Issue
Block a user