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:
@@ -18,6 +18,7 @@ interface BreakfastProps {
|
||||
childrenInRoom: Child[] | undefined
|
||||
currency: string
|
||||
nights: number
|
||||
hotelOffersBreakfast?: boolean
|
||||
}
|
||||
|
||||
export default function Breakfast({
|
||||
@@ -28,6 +29,7 @@ export default function Breakfast({
|
||||
childrenInRoom = [],
|
||||
currency,
|
||||
nights,
|
||||
hotelOffersBreakfast = true,
|
||||
}: BreakfastProps) {
|
||||
const intl = useIntl()
|
||||
|
||||
@@ -194,7 +196,10 @@ export default function Breakfast({
|
||||
})
|
||||
return (
|
||||
<Tbody>
|
||||
<BoldRow label={breakfastBuffet} value={noBreakfast} />
|
||||
<BoldRow
|
||||
label={hotelOffersBreakfast ? breakfastBuffet : undefined}
|
||||
value={noBreakfast}
|
||||
/>
|
||||
</Tbody>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ import { Typography } from "@scandic-hotels/design-system/Typography"
|
||||
import styles from "./row.module.css"
|
||||
|
||||
interface RowProps {
|
||||
label: string
|
||||
label?: string
|
||||
value: string
|
||||
regularValue?: string
|
||||
isDiscounted?: boolean
|
||||
@@ -19,11 +19,13 @@ export default function BoldRow({
|
||||
}: RowProps) {
|
||||
return (
|
||||
<tr className={styles.row}>
|
||||
<td>
|
||||
<Typography variant="Body/Supporting text (caption)/smBold">
|
||||
<span>{label}</span>
|
||||
</Typography>
|
||||
</td>
|
||||
{label ? (
|
||||
<td>
|
||||
<Typography variant="Body/Supporting text (caption)/smBold">
|
||||
<span>{label}</span>
|
||||
</Typography>
|
||||
</td>
|
||||
) : null}
|
||||
<td className={styles.price}>
|
||||
{isDiscounted && regularValue ? (
|
||||
<Typography variant="Body/Supporting text (caption)/smRegular">
|
||||
|
||||
@@ -66,6 +66,7 @@ export interface PriceDetailsTableProps {
|
||||
totalPrice: Price
|
||||
vat: number
|
||||
defaultCurrency: CurrencyEnum
|
||||
hotelOffersBreakfast?: boolean
|
||||
}
|
||||
|
||||
export default function PriceDetailsTable({
|
||||
@@ -77,6 +78,7 @@ export default function PriceDetailsTable({
|
||||
totalPrice,
|
||||
vat,
|
||||
defaultCurrency,
|
||||
hotelOffersBreakfast,
|
||||
}: PriceDetailsTableProps) {
|
||||
const intl = useIntl()
|
||||
const lang = useLang()
|
||||
@@ -217,6 +219,7 @@ export default function PriceDetailsTable({
|
||||
childrenInRoom={room.childrenInRoom}
|
||||
currency={currency}
|
||||
nights={nights}
|
||||
hotelOffersBreakfast={hotelOffersBreakfast}
|
||||
/>
|
||||
{rooms.length !== 1 &&
|
||||
(room.rateDefinition.isCampaignRate || !!bookingCode) && (
|
||||
|
||||
Reference in New Issue
Block a user