Merged in feat/SW-588-payment-saved-card (pull request #697)

feat(SW-588): Added saved card to payment step

* feat(SW-588): Added saved card to payment step

* feat(SW-588): Add proper label for saved card

* feat(SW-588): fix from PR feedback

* feat(SW-588): Add preloading of data

* feat(SW-588): remove onChange logic for PaymentOption

* feat(SW-588): moved payment files to correct folder

* feat(SW-588): moved preload to layout

* fix: remove unused prop


Approved-by: Simon.Emanuelsson
This commit is contained in:
Tobias Johansson
2024-10-21 10:39:19 +00:00
parent 62b9a66569
commit b33381d1b4
21 changed files with 536 additions and 381 deletions

View File

@@ -0,0 +1,11 @@
import { z } from "zod"
export const paymentSchema = z.object({
paymentMethod: z.string(),
smsConfirmation: z.boolean(),
termsAndConditions: z.boolean().refine((value) => value === true, {
message: "You must accept the terms and conditions",
}),
})
export interface PaymentFormData extends z.output<typeof paymentSchema> {}