fix/SW-2247 enter details fixes

* fix(SW-2247): Removed accordion like special requests block and changed button variant

* fix(SW-2247): Added additional info for bedtype selection

Approved-by: Tobias Johansson
Approved-by: Niclas Edenvin
This commit is contained in:
Erik Tiekstra
2025-04-16 09:49:53 +00:00
parent 700141f45e
commit 7108537cb8
19 changed files with 154 additions and 208 deletions

View File

@@ -0,0 +1,25 @@
import type { IntlShape } from "react-intl"
export function getBedTypeInfoText(
intl: IntlShape,
hasChildWithExtraBed: boolean,
hasMultipleBedTypes: boolean
) {
const availabilityText = intl.formatMessage({
defaultMessage: "Subject to availability",
})
const extraBedText = intl.formatMessage({
defaultMessage: "Extra bed will be provided additionally",
})
if (hasMultipleBedTypes && hasChildWithExtraBed) {
return `${availabilityText}. ${extraBedText}`
} else if (hasMultipleBedTypes) {
return availabilityText
} else if (hasChildWithExtraBed) {
return extraBedText
}
return null
}