Merged in fix/remove-b-code-check (pull request #2091)
fix/removed temp block for b codes * fix/removed temp block for b codes * Removed dead css Approved-by: Michael Zetterberg
This commit is contained in:
@@ -11,11 +11,6 @@
|
||||
padding: var(--Spacing-x1) var(--Spacing-x-one-and-half);
|
||||
}
|
||||
|
||||
.bookingCodeErrorContainer {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.bookingCodeLabel {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -57,10 +52,6 @@
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.bookingCodeError {
|
||||
white-space: normal;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
@media screen and (max-width: 767px) {
|
||||
.hideOnMobile {
|
||||
display: none;
|
||||
|
||||
@@ -8,7 +8,6 @@ import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon"
|
||||
|
||||
import { REDEMPTION } from "@/constants/booking"
|
||||
|
||||
import ButtonLink from "@/components/ButtonLink"
|
||||
import Modal from "@/components/Modal"
|
||||
import Button from "@/components/TempDesignSystem/Button"
|
||||
import Checkbox from "@/components/TempDesignSystem/Form/Checkbox"
|
||||
@@ -291,26 +290,7 @@ function BookingCodeError({ codeError }: { codeError: FieldError }) {
|
||||
}
|
||||
className={styles.errorIcon}
|
||||
/>
|
||||
{codeError.message === bookingWidgetErrors.BOOKING_CODE_ONLY_ENGLISH ? (
|
||||
<div className={styles.bookingCodeErrorContainer}>
|
||||
<span className={styles.bookingCodeError}>
|
||||
{
|
||||
/* eslint-disable-next-line formatjs/no-literal-string-in-jsx */
|
||||
"Dieser Code ist nur auf unserer englischen Website gültig"
|
||||
}
|
||||
</span>
|
||||
<ButtonLink
|
||||
target="_self"
|
||||
href="https://www.scandichotels.com"
|
||||
variant="Tertiary"
|
||||
>
|
||||
{/* eslint-disable-next-line formatjs/no-literal-string-in-jsx */}
|
||||
{"Englischen Website"}
|
||||
</ButtonLink>
|
||||
</div>
|
||||
) : (
|
||||
getErrorMessage(intl, codeError.message)
|
||||
)}
|
||||
{getErrorMessage(intl, codeError.message)}
|
||||
</Caption>
|
||||
{isMultiroomErr ? (
|
||||
<RemoveExtraRooms className={styles.hideOnMobile} />
|
||||
|
||||
@@ -9,7 +9,6 @@ export const bookingWidgetErrors = {
|
||||
BED_CHOICE_REQUIRED: "BED_CHOICE_REQUIRED",
|
||||
CHILDREN_EXCEEDS_ADULTS: "CHILDREN_EXCEEDS_ADULTS",
|
||||
BOOKING_CODE_INVALID: "BOOKING_CODE_INVALID",
|
||||
BOOKING_CODE_ONLY_ENGLISH: "BOOKING_CODE_ONLY_ENGLISH",
|
||||
REQUIRED: "REQUIRED",
|
||||
DESTINATION_REQUIRED: "DESTINATION_REQUIRED",
|
||||
MULTIROOM_BOOKING_CODE_UNAVAILABLE: "MULTIROOM_BOOKING_CODE_UNAVAILABLE",
|
||||
@@ -61,9 +60,6 @@ export const bookingCodeSchema = z
|
||||
),
|
||||
{ message: bookingWidgetErrors.BOOKING_CODE_INVALID }
|
||||
)
|
||||
.refine((value) => !value.startsWith("B") && !value.startsWith("b"), {
|
||||
message: bookingWidgetErrors.BOOKING_CODE_ONLY_ENGLISH,
|
||||
})
|
||||
.default(""),
|
||||
remember: z.boolean().default(false),
|
||||
flag: z.boolean().default(false),
|
||||
|
||||
Reference in New Issue
Block a user