From d7708b682a7173d62e477ce08e54d2145641157b Mon Sep 17 00:00:00 2001 From: Niclas Edenvin Date: Fri, 2 May 2025 07:45:37 +0000 Subject: [PATCH] Merged in fix/sw-2543-toc-text (pull request #1921) fix(SW-2543): Change terms and conditions text for flex * fix(SW-2543): Change terms and conditions text for flex Approved-by: Michael Zetterberg --- .../EnterDetails/Confirm/index.tsx | 4 +- .../EnterDetails/Payment/PaymentClient.tsx | 2 +- .../Payment/TermsAndConditions/index.tsx | 103 ++++++++++++------ .../GuaranteeLateArrival/Form/index.tsx | 2 +- .../hotelReservation/enterDetails/payment.ts | 4 + 5 files changed, 78 insertions(+), 37 deletions(-) diff --git a/apps/scandic-web/components/HotelReservation/EnterDetails/Confirm/index.tsx b/apps/scandic-web/components/HotelReservation/EnterDetails/Confirm/index.tsx index 6cff51a81..fc918b96b 100644 --- a/apps/scandic-web/components/HotelReservation/EnterDetails/Confirm/index.tsx +++ b/apps/scandic-web/components/HotelReservation/EnterDetails/Confirm/index.tsx @@ -135,7 +135,7 @@ export default function ConfirmBooking({ ) : null}
- +
) @@ -156,7 +156,7 @@ export function ConfirmBookingRedemption() {
- +
) diff --git a/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/PaymentClient.tsx b/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/PaymentClient.tsx index 15431a792..3d8e0e3fd 100644 --- a/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/PaymentClient.tsx +++ b/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/PaymentClient.tsx @@ -586,7 +586,7 @@ export default function PaymentClient({
- +
)} diff --git a/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/TermsAndConditions/index.tsx b/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/TermsAndConditions/index.tsx index 014ea5e33..1eaa7be40 100644 --- a/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/TermsAndConditions/index.tsx +++ b/apps/scandic-web/components/HotelReservation/EnterDetails/Payment/TermsAndConditions/index.tsx @@ -12,45 +12,82 @@ import useLang from "@/hooks/useLang" import styles from "../payment.module.css" -export default function TermsAndConditions() { +import type { TermsAndConditionsProps } from "@/types/components/hotelReservation/enterDetails/payment" + +export default function TermsAndConditions({ + isFlexBookingTerms, +}: TermsAndConditionsProps) { const intl = useIntl() const lang = useLang() return ( <> - {intl.formatMessage( - { - defaultMessage: - "I accept the terms for this booking and the general Terms & Conditions, and understand that Scandic will process my personal data for this booking in accordance with Scandic's Privacy policy. I also accept that Scandic requires a valid payment card during my visit in case anything is left unpaid.", - }, - { - termsAndConditionsLink: (str) => ( - - {str} - - ), - privacyPolicyLink: (str) => ( - - {str} - - ), - } - )} + {isFlexBookingTerms + ? intl.formatMessage( + { + defaultMessage: + "I accept the terms for this booking and the general Terms & Conditions, and understand that Scandic will process my personal data for this booking in accordance with Scandic's Privacy policy.", + }, + { + termsAndConditionsLink: (str) => ( + + {str} + + ), + privacyPolicyLink: (str) => ( + + {str} + + ), + } + ) + : intl.formatMessage( + { + defaultMessage: + "By paying with any of the payment methods available, I accept the terms for this booking and the general Terms & Conditions, and understand that Scandic will process my personal data for this booking in accordance with Scandic's Privacy policy. I also accept that Scandic requires a valid payment card during my visit in case anything is left unpaid.", + }, + { + termsAndConditionsLink: (str) => ( + + {str} + + ), + privacyPolicyLink: (str) => ( + + {str} + + ), + } + )} diff --git a/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/NotCancelled/ManageStay/Actions/GuaranteeLateArrival/Form/index.tsx b/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/NotCancelled/ManageStay/Actions/GuaranteeLateArrival/Form/index.tsx index a042331c1..911d976f5 100644 --- a/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/NotCancelled/ManageStay/Actions/GuaranteeLateArrival/Form/index.tsx +++ b/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/NotCancelled/ManageStay/Actions/GuaranteeLateArrival/Form/index.tsx @@ -105,7 +105,7 @@ export default function Form() { const guaranteeMsg = intl.formatMessage( { defaultMessage: - "By guaranteeing with any of the payment methods available, I accept the terms for this stay and the general Terms & Conditions, and understand Scandic will process my personal data for this stay in accordance with Scandic's Privacy Policy. I accept Scandic requiring a valid credit card during my visit in case anything is left unpaid.", + "I accept the terms for this stay and the general Terms & Conditions, and understand Scandic will process my personal data for this stay in accordance with Scandic's Privacy Policy. ", }, { termsAndConditionsLink: (str) => ( diff --git a/apps/scandic-web/types/components/hotelReservation/enterDetails/payment.ts b/apps/scandic-web/types/components/hotelReservation/enterDetails/payment.ts index f64f89e6c..816eb1aa4 100644 --- a/apps/scandic-web/types/components/hotelReservation/enterDetails/payment.ts +++ b/apps/scandic-web/types/components/hotelReservation/enterDetails/payment.ts @@ -17,3 +17,7 @@ export type PriceChangeData = Array<{ totalPrice: number packagePrice?: number } | null> + +export interface TermsAndConditionsProps { + isFlexBookingTerms: boolean +}