tf-checkout-react-native 1.0.47 → 2.0.0-beta.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +215 -3321
- package/dist/index.d.mts +10896 -0
- package/dist/index.d.ts +10896 -0
- package/dist/index.js +25684 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +25751 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +45 -59
- package/scripts/build-seat-map.mjs +31 -0
- package/scripts/seat-map-entry.jsx +22 -0
- package/src/CardInput.tsx +110 -0
- package/src/EmbeddedCheckout.tsx +416 -0
- package/src/auth/AuthModal.tsx +305 -0
- package/src/auth/EmailCodeForm.tsx +91 -0
- package/src/auth/ForgotPasswordForm.tsx +98 -0
- package/src/auth/LoginForm.tsx +99 -0
- package/src/auth/PasswordInput.tsx +45 -0
- package/src/auth/RegisterForm.tsx +333 -0
- package/src/auth/ResetPasswordForm.tsx +112 -0
- package/src/auth/TwoFactorForm.tsx +74 -0
- package/src/auth/index.ts +11 -0
- package/src/configure.ts +33 -0
- package/src/confirmer.ts +272 -0
- package/src/generated/seatMapWidget.ts +3 -0
- package/src/index.tsx +25 -227
- package/src/instance.ts +13 -0
- package/src/sections/Accommodation.tsx +57 -0
- package/src/sections/AccountRewards.tsx +108 -0
- package/src/sections/AddOns.tsx +286 -0
- package/src/sections/BillingInfo.tsx +769 -0
- package/src/sections/Bundles.tsx +467 -0
- package/src/sections/Confirmation.tsx +143 -0
- package/src/sections/EventDiscussionView.tsx +633 -0
- package/src/sections/IDVerification.tsx +77 -0
- package/src/sections/OrderSummary.tsx +116 -0
- package/src/sections/Passes.tsx +177 -0
- package/src/sections/Payment.tsx +534 -0
- package/src/sections/PostReaction.tsx +122 -0
- package/src/sections/Rewards.tsx +320 -0
- package/src/sections/SeatMap.tsx +225 -0
- package/src/sections/SeatsIoMap.tsx +110 -0
- package/src/sections/TicketChange.tsx +379 -0
- package/src/sections/TicketGift.tsx +206 -0
- package/src/sections/TicketRefund.tsx +104 -0
- package/src/sections/Tickets.tsx +761 -0
- package/src/sections/Trips.tsx +87 -0
- package/src/sections/WaiverSigning.tsx +429 -0
- package/src/sections/billing/BillingAddressFields.tsx +126 -0
- package/src/sections/billing/BuyerField.tsx +78 -0
- package/src/sections/billing/PhoneIdentity.tsx +169 -0
- package/src/sections/billing/TicketHoldersCard.tsx +119 -0
- package/src/sections/billing/types.ts +10 -0
- package/src/sections/discussion/CommentImages.tsx +342 -0
- package/src/sections/discussion/SwipeReply.tsx +88 -0
- package/src/sections/index.ts +28 -0
- package/src/sections/rewards/RewardsLadder.tsx +167 -0
- package/src/sections/rewards/RewardsTree.tsx +117 -0
- package/src/storage.ts +26 -0
- package/src/ui/CheckoutProvider.tsx +152 -0
- package/src/ui/CustomFields.tsx +176 -0
- package/src/ui/Field.tsx +189 -0
- package/src/ui/Frozen.tsx +22 -0
- package/src/ui/InstallmentPicker.tsx +155 -0
- package/src/ui/PaymentMethods.tsx +180 -0
- package/src/ui/ProviderPages.tsx +134 -0
- package/src/ui/QuantitySelect.tsx +127 -0
- package/src/ui/Select.tsx +154 -0
- package/src/ui/SignaturePad.tsx +218 -0
- package/src/ui/Timer.tsx +69 -0
- package/src/ui/TimerBanner.tsx +95 -0
- package/src/ui/index.ts +18 -0
- package/src/ui/primitives.tsx +202 -0
- package/src/ui/theme.ts +89 -0
- package/src/ui/useAccountT.ts +16 -0
- package/src/useCheckout.ts +37 -0
- package/lib/brand-DA2IARBI.png +0 -0
- package/lib/ic_check-FLIJQ3BY.png +0 -0
- package/lib/ic_clock-BZ4Z7PIP.png +0 -0
- package/lib/ic_copy-VWMA4B7X.png +0 -0
- package/lib/ic_dropdown-BCS3QDNJ.png +0 -0
- package/lib/ic_error-KDEZUPSN.png +0 -0
- package/lib/ic_eye-WGXVXVAN.png +0 -0
- package/lib/ic_eye_off-XTCE6XSO.png +0 -0
- package/lib/ic_more-LZWKYCDU.png +0 -0
- package/lib/ic_next-LCNIGEDM.png +0 -0
- package/lib/index.js +0 -18222
- package/lib/index.js.map +0 -1
- package/lib/index.mjs +0 -18309
- package/lib/index.mjs.map +0 -1
- package/lib/typescript/package.json +0 -1
- package/lib/typescript/src/api/ApiClient.d.ts +0 -49
- package/lib/typescript/src/api/ApiClient.d.ts.map +0 -1
- package/lib/typescript/src/api/Constants.d.ts +0 -11
- package/lib/typescript/src/api/Constants.d.ts.map +0 -1
- package/lib/typescript/src/api/ErrorHandler.d.ts +0 -12
- package/lib/typescript/src/api/ErrorHandler.d.ts.map +0 -1
- package/lib/typescript/src/api/api.types.d.ts +0 -8
- package/lib/typescript/src/api/api.types.d.ts.map +0 -1
- package/lib/typescript/src/api/types.d.ts +0 -518
- package/lib/typescript/src/api/types.d.ts.map +0 -1
- package/lib/typescript/src/apiv2/index.d.ts +0 -3
- package/lib/typescript/src/apiv2/index.d.ts.map +0 -1
- package/lib/typescript/src/common/query.types.d.ts +0 -3
- package/lib/typescript/src/common/query.types.d.ts.map +0 -1
- package/lib/typescript/src/components/bottomSheetModal/BottomSheetModal.d.ts +0 -8
- package/lib/typescript/src/components/bottomSheetModal/BottomSheetModal.d.ts.map +0 -1
- package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalStyles.d.ts +0 -39
- package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalStyles.d.ts.map +0 -1
- package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalTypes.d.ts +0 -23
- package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalTypes.d.ts.map +0 -1
- package/lib/typescript/src/components/button/Button.d.ts +0 -5
- package/lib/typescript/src/components/button/Button.d.ts.map +0 -1
- package/lib/typescript/src/components/button/styles.d.ts +0 -28
- package/lib/typescript/src/components/button/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/button/types.d.ts +0 -15
- package/lib/typescript/src/components/button/types.d.ts.map +0 -1
- package/lib/typescript/src/components/cartTimer/CartTimer.d.ts +0 -5
- package/lib/typescript/src/components/cartTimer/CartTimer.d.ts.map +0 -1
- package/lib/typescript/src/components/cartTimer/styles.d.ts +0 -47
- package/lib/typescript/src/components/cartTimer/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/cartTimer/types.d.ts +0 -19
- package/lib/typescript/src/components/cartTimer/types.d.ts.map +0 -1
- package/lib/typescript/src/components/checkbox/Checkbox.d.ts +0 -4
- package/lib/typescript/src/components/checkbox/Checkbox.d.ts.map +0 -1
- package/lib/typescript/src/components/checkbox/styles.d.ts +0 -39
- package/lib/typescript/src/components/checkbox/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/checkbox/types.d.ts +0 -22
- package/lib/typescript/src/components/checkbox/types.d.ts.map +0 -1
- package/lib/typescript/src/components/datePicker/DatePicker.d.ts +0 -4
- package/lib/typescript/src/components/datePicker/DatePicker.d.ts.map +0 -1
- package/lib/typescript/src/components/datePicker/styles.d.ts +0 -35
- package/lib/typescript/src/components/datePicker/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/datePicker/types.d.ts +0 -20
- package/lib/typescript/src/components/datePicker/types.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdown/Dropdown.d.ts +0 -4
- package/lib/typescript/src/components/dropdown/Dropdown.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdown/DropdownListItem.d.ts +0 -4
- package/lib/typescript/src/components/dropdown/DropdownListItem.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdown/styles.d.ts +0 -85
- package/lib/typescript/src/components/dropdown/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdown/types.d.ts +0 -35
- package/lib/typescript/src/components/dropdown/types.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdownMaterial/DropdownMaterial.d.ts +0 -4
- package/lib/typescript/src/components/dropdownMaterial/DropdownMaterial.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdownMaterial/styles.d.ts +0 -79
- package/lib/typescript/src/components/dropdownMaterial/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/dropdownMaterial/types.d.ts +0 -22
- package/lib/typescript/src/components/dropdownMaterial/types.d.ts.map +0 -1
- package/lib/typescript/src/components/enterPassword/EnterPassword.d.ts +0 -5
- package/lib/typescript/src/components/enterPassword/EnterPassword.d.ts.map +0 -1
- package/lib/typescript/src/components/enterPassword/styles.d.ts +0 -21
- package/lib/typescript/src/components/enterPassword/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/enterPassword/types.d.ts +0 -24
- package/lib/typescript/src/components/enterPassword/types.d.ts.map +0 -1
- package/lib/typescript/src/components/formField/FormField.d.ts +0 -4
- package/lib/typescript/src/components/formField/FormField.d.ts.map +0 -1
- package/lib/typescript/src/components/formField/styles.d.ts +0 -35
- package/lib/typescript/src/components/formField/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/formField/types.d.ts +0 -48
- package/lib/typescript/src/components/formField/types.d.ts.map +0 -1
- package/lib/typescript/src/components/index.d.ts +0 -21
- package/lib/typescript/src/components/index.d.ts.map +0 -1
- package/lib/typescript/src/components/input/Input.d.ts +0 -4
- package/lib/typescript/src/components/input/Input.d.ts.map +0 -1
- package/lib/typescript/src/components/input/styles.d.ts +0 -47
- package/lib/typescript/src/components/input/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/input/types.d.ts +0 -28
- package/lib/typescript/src/components/input/types.d.ts.map +0 -1
- package/lib/typescript/src/components/loading/Loading.d.ts +0 -4
- package/lib/typescript/src/components/loading/Loading.d.ts.map +0 -1
- package/lib/typescript/src/components/loading/styles.d.ts +0 -30
- package/lib/typescript/src/components/loading/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/loading/types.d.ts +0 -15
- package/lib/typescript/src/components/loading/types.d.ts.map +0 -1
- package/lib/typescript/src/components/loggedIn/LoggedIn.d.ts +0 -5
- package/lib/typescript/src/components/loggedIn/LoggedIn.d.ts.map +0 -1
- package/lib/typescript/src/components/loggedIn/styles.d.ts +0 -9
- package/lib/typescript/src/components/loggedIn/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/loggedIn/types.d.ts +0 -24
- package/lib/typescript/src/components/loggedIn/types.d.ts.map +0 -1
- package/lib/typescript/src/components/login/Login.d.ts +0 -5
- package/lib/typescript/src/components/login/Login.d.ts.map +0 -1
- package/lib/typescript/src/components/login/LoginView.d.ts +0 -5
- package/lib/typescript/src/components/login/LoginView.d.ts.map +0 -1
- package/lib/typescript/src/components/login/components/LoginForm.d.ts +0 -5
- package/lib/typescript/src/components/login/components/LoginForm.d.ts.map +0 -1
- package/lib/typescript/src/components/login/components/types.d.ts +0 -19
- package/lib/typescript/src/components/login/components/types.d.ts.map +0 -1
- package/lib/typescript/src/components/login/styles.d.ts +0 -62
- package/lib/typescript/src/components/login/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/login/types.d.ts +0 -144
- package/lib/typescript/src/components/login/types.d.ts.map +0 -1
- package/lib/typescript/src/components/phoneInput/PhoneInput.d.ts +0 -5
- package/lib/typescript/src/components/phoneInput/PhoneInput.d.ts.map +0 -1
- package/lib/typescript/src/components/phoneInput/styles.d.ts +0 -29
- package/lib/typescript/src/components/phoneInput/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/phoneInput/types.d.ts +0 -31
- package/lib/typescript/src/components/phoneInput/types.d.ts.map +0 -1
- package/lib/typescript/src/components/promoCode/PromoCode.d.ts +0 -5
- package/lib/typescript/src/components/promoCode/PromoCode.d.ts.map +0 -1
- package/lib/typescript/src/components/promoCode/styles.d.ts +0 -61
- package/lib/typescript/src/components/promoCode/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/promoCode/types.d.ts +0 -36
- package/lib/typescript/src/components/promoCode/types.d.ts.map +0 -1
- package/lib/typescript/src/components/radioButton/RadioButton.d.ts +0 -5
- package/lib/typescript/src/components/radioButton/RadioButton.d.ts.map +0 -1
- package/lib/typescript/src/components/radioButton/styles.d.ts +0 -25
- package/lib/typescript/src/components/radioButton/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/radioButton/types.d.ts +0 -16
- package/lib/typescript/src/components/radioButton/types.d.ts.map +0 -1
- package/lib/typescript/src/components/radioGroup/RadioGroup.d.ts +0 -4
- package/lib/typescript/src/components/radioGroup/RadioGroup.d.ts.map +0 -1
- package/lib/typescript/src/components/radioGroup/index.d.ts +0 -4
- package/lib/typescript/src/components/radioGroup/index.d.ts.map +0 -1
- package/lib/typescript/src/components/radioGroup/types.d.ts +0 -24
- package/lib/typescript/src/components/radioGroup/types.d.ts.map +0 -1
- package/lib/typescript/src/components/restorePassword/RestorePassword.d.ts +0 -5
- package/lib/typescript/src/components/restorePassword/RestorePassword.d.ts.map +0 -1
- package/lib/typescript/src/components/restorePassword/ResultDialog.d.ts +0 -5
- package/lib/typescript/src/components/restorePassword/ResultDialog.d.ts.map +0 -1
- package/lib/typescript/src/components/restorePassword/styles.d.ts +0 -34
- package/lib/typescript/src/components/restorePassword/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/restorePassword/types.d.ts +0 -49
- package/lib/typescript/src/components/restorePassword/types.d.ts.map +0 -1
- package/lib/typescript/src/components/separator/Separator.d.ts +0 -4
- package/lib/typescript/src/components/separator/Separator.d.ts.map +0 -1
- package/lib/typescript/src/components/separator/types.d.ts +0 -9
- package/lib/typescript/src/components/separator/types.d.ts.map +0 -1
- package/lib/typescript/src/components/stripePayment/StripePayment.d.ts +0 -5
- package/lib/typescript/src/components/stripePayment/StripePayment.d.ts.map +0 -1
- package/lib/typescript/src/components/stripePayment/styles.d.ts +0 -7
- package/lib/typescript/src/components/stripePayment/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/stripePayment/types.d.ts +0 -14
- package/lib/typescript/src/components/stripePayment/types.d.ts.map +0 -1
- package/lib/typescript/src/components/waitingList/WaitingList.d.ts +0 -6
- package/lib/typescript/src/components/waitingList/WaitingList.d.ts.map +0 -1
- package/lib/typescript/src/components/waitingList/WaitingListView.d.ts +0 -5
- package/lib/typescript/src/components/waitingList/WaitingListView.d.ts.map +0 -1
- package/lib/typescript/src/components/waitingList/styles.d.ts +0 -9
- package/lib/typescript/src/components/waitingList/styles.d.ts.map +0 -1
- package/lib/typescript/src/components/waitingList/types.d.ts +0 -59
- package/lib/typescript/src/components/waitingList/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/billingInfo/Billing.d.ts +0 -6
- package/lib/typescript/src/containers/billingInfo/Billing.d.ts.map +0 -1
- package/lib/typescript/src/containers/billingInfo/styles.d.ts +0 -61
- package/lib/typescript/src/containers/billingInfo/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/billingInfo/types.d.ts +0 -160
- package/lib/typescript/src/containers/billingInfo/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/Checkout.d.ts +0 -7
- package/lib/typescript/src/containers/checkout/Checkout.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/CheckoutData.d.ts +0 -3
- package/lib/typescript/src/containers/checkout/CheckoutData.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/components/Conditions.d.ts +0 -4
- package/lib/typescript/src/containers/checkout/components/Conditions.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/components/OrderReview.d.ts +0 -4
- package/lib/typescript/src/containers/checkout/components/OrderReview.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/components/styles.d.ts +0 -26
- package/lib/typescript/src/containers/checkout/components/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/styles.d.ts +0 -42
- package/lib/typescript/src/containers/checkout/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/checkout/types.d.ts +0 -126
- package/lib/typescript/src/containers/checkout/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/index.d.ts +0 -9
- package/lib/typescript/src/containers/index.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/MyOrderDetails.d.ts +0 -6
- package/lib/typescript/src/containers/myOrderDetails/MyOrderDetails.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/MyOrderDetailsView.d.ts +0 -5
- package/lib/typescript/src/containers/myOrderDetails/MyOrderDetailsView.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/Notification.d.ts +0 -15
- package/lib/typescript/src/containers/myOrderDetails/components/Notification.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/OrderListItem.d.ts +0 -3
- package/lib/typescript/src/containers/myOrderDetails/components/OrderListItem.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActions.d.ts +0 -5
- package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActions.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActionsTypes.d.ts +0 -30
- package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActionsTypes.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItem.d.ts +0 -8
- package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItem.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemStyles.d.ts +0 -33
- package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemStyles.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemTypes.d.ts +0 -30
- package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemTypes.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/components/styles.d.ts +0 -39
- package/lib/typescript/src/containers/myOrderDetails/components/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/styles.d.ts +0 -55
- package/lib/typescript/src/containers/myOrderDetails/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrderDetails/types.d.ts +0 -126
- package/lib/typescript/src/containers/myOrderDetails/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/MyOrders.d.ts +0 -6
- package/lib/typescript/src/containers/myOrders/MyOrders.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/MyOrdersView.d.ts +0 -5
- package/lib/typescript/src/containers/myOrders/MyOrdersView.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/components/OrderListItem.d.ts +0 -5
- package/lib/typescript/src/containers/myOrders/components/OrderListItem.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/components/styles.d.ts +0 -56
- package/lib/typescript/src/containers/myOrders/components/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/components/types.d.ts +0 -26
- package/lib/typescript/src/containers/myOrders/components/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/styles.d.ts +0 -37
- package/lib/typescript/src/containers/myOrders/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/myOrders/types.d.ts +0 -73
- package/lib/typescript/src/containers/myOrders/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmation.d.ts +0 -6
- package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmation.d.ts.map +0 -1
- package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmationView.d.ts +0 -5
- package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmationView.d.ts.map +0 -1
- package/lib/typescript/src/containers/purchaseConfirmation/styles.d.ts +0 -74
- package/lib/typescript/src/containers/purchaseConfirmation/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/purchaseConfirmation/types.d.ts +0 -66
- package/lib/typescript/src/containers/purchaseConfirmation/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/resaleTickets/ResaleTickets.d.ts +0 -6
- package/lib/typescript/src/containers/resaleTickets/ResaleTickets.d.ts.map +0 -1
- package/lib/typescript/src/containers/resaleTickets/ResaleTicketsView.d.ts +0 -5
- package/lib/typescript/src/containers/resaleTickets/ResaleTicketsView.d.ts.map +0 -1
- package/lib/typescript/src/containers/resaleTickets/types.d.ts +0 -129
- package/lib/typescript/src/containers/resaleTickets/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/resetPassword/ResetPassword.d.ts +0 -5
- package/lib/typescript/src/containers/resetPassword/ResetPassword.d.ts.map +0 -1
- package/lib/typescript/src/containers/resetPassword/ResetPasswordView.d.ts +0 -5
- package/lib/typescript/src/containers/resetPassword/ResetPasswordView.d.ts.map +0 -1
- package/lib/typescript/src/containers/resetPassword/styles.d.ts +0 -33
- package/lib/typescript/src/containers/resetPassword/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/resetPassword/types.d.ts +0 -48
- package/lib/typescript/src/containers/resetPassword/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/Tickets.d.ts +0 -6
- package/lib/typescript/src/containers/tickets/Tickets.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/TicketsView.d.ts +0 -4
- package/lib/typescript/src/containers/tickets/TicketsView.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/components/TicketGroupListHeader.d.ts +0 -5
- package/lib/typescript/src/containers/tickets/components/TicketGroupListHeader.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/components/TicketListItem.d.ts +0 -4
- package/lib/typescript/src/containers/tickets/components/TicketListItem.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/components/styles.d.ts +0 -51
- package/lib/typescript/src/containers/tickets/components/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/components/types.d.ts +0 -40
- package/lib/typescript/src/containers/tickets/components/types.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/styles.d.ts +0 -20
- package/lib/typescript/src/containers/tickets/styles.d.ts.map +0 -1
- package/lib/typescript/src/containers/tickets/types.d.ts +0 -114
- package/lib/typescript/src/containers/tickets/types.d.ts.map +0 -1
- package/lib/typescript/src/core/BillingCore/BillingCore.d.ts +0 -13
- package/lib/typescript/src/core/BillingCore/BillingCore.d.ts.map +0 -1
- package/lib/typescript/src/core/BillingCore/BillingCoreTypes.d.ts +0 -24
- package/lib/typescript/src/core/BillingCore/BillingCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/CheckoutCore/CheckoutCore.d.ts +0 -15
- package/lib/typescript/src/core/CheckoutCore/CheckoutCore.d.ts.map +0 -1
- package/lib/typescript/src/core/CheckoutCore/CheckoutCoreTypes.d.ts +0 -17
- package/lib/typescript/src/core/CheckoutCore/CheckoutCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/CoreProps.d.ts +0 -5
- package/lib/typescript/src/core/CoreProps.d.ts.map +0 -1
- package/lib/typescript/src/core/LoginCore/LoginCore.d.ts +0 -6
- package/lib/typescript/src/core/LoginCore/LoginCore.d.ts.map +0 -1
- package/lib/typescript/src/core/LoginCore/LoginCoreHelper.d.ts +0 -3
- package/lib/typescript/src/core/LoginCore/LoginCoreHelper.d.ts.map +0 -1
- package/lib/typescript/src/core/LoginCore/LoginCoreTypes.d.ts +0 -15
- package/lib/typescript/src/core/LoginCore/LoginCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/MyOrdersCore/MyOrdersCore.d.ts +0 -6
- package/lib/typescript/src/core/MyOrdersCore/MyOrdersCore.d.ts.map +0 -1
- package/lib/typescript/src/core/MyOrdersCore/MyOrdersCoreTypes.d.ts +0 -10
- package/lib/typescript/src/core/MyOrdersCore/MyOrdersCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCore.d.ts +0 -6
- package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCore.d.ts.map +0 -1
- package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCoreTypes.d.ts +0 -9
- package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCore.d.ts +0 -6
- package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCore.d.ts.map +0 -1
- package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCoreTypes.d.ts +0 -8
- package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCore.d.ts +0 -6
- package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCore.d.ts.map +0 -1
- package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCoreTypes.d.ts +0 -5
- package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/Session/SessionCoreTypes.d.ts +0 -9
- package/lib/typescript/src/core/Session/SessionCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/Session/SessionHandle.d.ts +0 -6
- package/lib/typescript/src/core/Session/SessionHandle.d.ts.map +0 -1
- package/lib/typescript/src/core/TicketsCore/TicketsCore.d.ts +0 -6
- package/lib/typescript/src/core/TicketsCore/TicketsCore.d.ts.map +0 -1
- package/lib/typescript/src/core/TicketsCore/TicketsCoreTypes.d.ts +0 -40
- package/lib/typescript/src/core/TicketsCore/TicketsCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/WaitingListCore/WaitingListCore.d.ts +0 -6
- package/lib/typescript/src/core/WaitingListCore/WaitingListCore.d.ts.map +0 -1
- package/lib/typescript/src/core/WaitingListCore/WaitingListCoreTypes.d.ts +0 -12
- package/lib/typescript/src/core/WaitingListCore/WaitingListCoreTypes.d.ts.map +0 -1
- package/lib/typescript/src/core/index.d.ts +0 -21
- package/lib/typescript/src/core/index.d.ts.map +0 -1
- package/lib/typescript/src/features/auth/api-hooks.d.ts +0 -178
- package/lib/typescript/src/features/auth/api-hooks.d.ts.map +0 -1
- package/lib/typescript/src/features/auth/types.d.ts +0 -51
- package/lib/typescript/src/features/auth/types.d.ts.map +0 -1
- package/lib/typescript/src/features/auth/utils.d.ts +0 -3
- package/lib/typescript/src/features/auth/utils.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/components/AddonsContainer.d.ts +0 -37
- package/lib/typescript/src/features/checkout-v2/components/AddonsContainer.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/components/Conditions.d.ts +0 -30
- package/lib/typescript/src/features/checkout-v2/components/Conditions.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/components/OrderReview.d.ts +0 -25
- package/lib/typescript/src/features/checkout-v2/components/OrderReview.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/components/TicketHoldersSection.d.ts +0 -14
- package/lib/typescript/src/features/checkout-v2/components/TicketHoldersSection.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/form/config.d.ts +0 -61
- package/lib/typescript/src/features/checkout-v2/form/config.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/form/index.d.ts +0 -22
- package/lib/typescript/src/features/checkout-v2/form/index.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/form/styles.d.ts +0 -4501
- package/lib/typescript/src/features/checkout-v2/form/styles.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/form/texts.d.ts +0 -4
- package/lib/typescript/src/features/checkout-v2/form/texts.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/form/types.d.ts +0 -191
- package/lib/typescript/src/features/checkout-v2/form/types.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/hooks/api-hooks.d.ts +0 -227
- package/lib/typescript/src/features/checkout-v2/hooks/api-hooks.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/hooks/use-checkout.d.ts +0 -37
- package/lib/typescript/src/features/checkout-v2/hooks/use-checkout.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/index.d.ts +0 -42
- package/lib/typescript/src/features/checkout-v2/index.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/types.d.ts +0 -433
- package/lib/typescript/src/features/checkout-v2/types.d.ts.map +0 -1
- package/lib/typescript/src/features/checkout-v2/utils.d.ts +0 -12
- package/lib/typescript/src/features/checkout-v2/utils.d.ts.map +0 -1
- package/lib/typescript/src/features/event/api-hooks.d.ts +0 -171
- package/lib/typescript/src/features/event/api-hooks.d.ts.map +0 -1
- package/lib/typescript/src/features/event/types.d.ts +0 -58
- package/lib/typescript/src/features/event/types.d.ts.map +0 -1
- package/lib/typescript/src/features/form/index.d.ts +0 -24
- package/lib/typescript/src/features/form/index.d.ts.map +0 -1
- package/lib/typescript/src/features/form/styles.d.ts +0 -35
- package/lib/typescript/src/features/form/styles.d.ts.map +0 -1
- package/lib/typescript/src/features/form/types.d.ts +0 -33
- package/lib/typescript/src/features/form/types.d.ts.map +0 -1
- package/lib/typescript/src/features/geo/api-hooks.d.ts +0 -12
- package/lib/typescript/src/features/geo/api-hooks.d.ts.map +0 -1
- package/lib/typescript/src/features/geo/types.d.ts +0 -13
- package/lib/typescript/src/features/geo/types.d.ts.map +0 -1
- package/lib/typescript/src/helpers/Config.d.ts +0 -24
- package/lib/typescript/src/helpers/Config.d.ts.map +0 -1
- package/lib/typescript/src/helpers/CountryCodes.d.ts +0 -16
- package/lib/typescript/src/helpers/CountryCodes.d.ts.map +0 -1
- package/lib/typescript/src/helpers/Debounced.d.ts +0 -2
- package/lib/typescript/src/helpers/Debounced.d.ts.map +0 -1
- package/lib/typescript/src/helpers/Domains.d.ts +0 -3
- package/lib/typescript/src/helpers/Domains.d.ts.map +0 -1
- package/lib/typescript/src/helpers/LocalStorage.d.ts +0 -27
- package/lib/typescript/src/helpers/LocalStorage.d.ts.map +0 -1
- package/lib/typescript/src/helpers/RefreshAccessToken.d.ts +0 -3
- package/lib/typescript/src/helpers/RefreshAccessToken.d.ts.map +0 -1
- package/lib/typescript/src/helpers/StringsHelper.d.ts +0 -3
- package/lib/typescript/src/helpers/StringsHelper.d.ts.map +0 -1
- package/lib/typescript/src/helpers/Validators.d.ts +0 -16
- package/lib/typescript/src/helpers/Validators.d.ts.map +0 -1
- package/lib/typescript/src/index.d.ts +0 -49
- package/lib/typescript/src/index.d.ts.map +0 -1
- package/lib/typescript/src/res/colors.d.ts +0 -16
- package/lib/typescript/src/res/colors.d.ts.map +0 -1
- package/lib/typescript/src/res/icons.d.ts +0 -13
- package/lib/typescript/src/res/icons.d.ts.map +0 -1
- package/lib/typescript/src/res/images.d.ts +0 -5
- package/lib/typescript/src/res/images.d.ts.map +0 -1
- package/lib/typescript/src/res/index.d.ts +0 -32
- package/lib/typescript/src/res/index.d.ts.map +0 -1
- package/lib/typescript/src/types/IAccountTickets.d.ts +0 -71
- package/lib/typescript/src/types/IAccountTickets.d.ts.map +0 -1
- package/lib/typescript/src/types/ICountry.d.ts +0 -2
- package/lib/typescript/src/types/ICountry.d.ts.map +0 -1
- package/lib/typescript/src/types/IError.d.ts +0 -6
- package/lib/typescript/src/types/IError.d.ts.map +0 -1
- package/lib/typescript/src/types/IEvent.d.ts +0 -87
- package/lib/typescript/src/types/IEvent.d.ts.map +0 -1
- package/lib/typescript/src/types/ITicket.d.ts +0 -71
- package/lib/typescript/src/types/ITicket.d.ts.map +0 -1
- package/lib/typescript/src/types/IUserProfile.d.ts +0 -30
- package/lib/typescript/src/types/IUserProfile.d.ts.map +0 -1
- package/lib/typescript/src/types/index.d.ts +0 -6
- package/lib/typescript/src/types/index.d.ts.map +0 -1
- package/lib/typescript/src/utils/Logger.d.ts +0 -21
- package/lib/typescript/src/utils/Logger.d.ts.map +0 -1
- package/lib/typescript/src/utils/handlers.d.ts +0 -9
- package/lib/typescript/src/utils/handlers.d.ts.map +0 -1
- package/lib/typescript/src/utils/storageAdapter.d.ts +0 -14
- package/lib/typescript/src/utils/storageAdapter.d.ts.map +0 -1
- package/lib/typescript/src/utils/styleUtils.d.ts +0 -18
- package/lib/typescript/src/utils/styleUtils.d.ts.map +0 -1
- package/src/api/ApiClient.ts +0 -1539
- package/src/api/Constants.ts +0 -10
- package/src/api/ErrorHandler.ts +0 -36
- package/src/api/api.types.ts +0 -8
- package/src/api/types.ts +0 -593
- package/src/apiv2/index.ts +0 -143
- package/src/assets/icons/ic_check.png +0 -0
- package/src/assets/icons/ic_clock.png +0 -0
- package/src/assets/icons/ic_copy.png +0 -0
- package/src/assets/icons/ic_dropdown.png +0 -0
- package/src/assets/icons/ic_error.png +0 -0
- package/src/assets/icons/ic_eye.png +0 -0
- package/src/assets/icons/ic_eye_off.png +0 -0
- package/src/assets/icons/ic_more.png +0 -0
- package/src/assets/icons/ic_next.png +0 -0
- package/src/assets/images/brand.png +0 -0
- package/src/common/query.types.ts +0 -6
- package/src/components/bottomSheetModal/BottomSheetModal.tsx +0 -95
- package/src/components/bottomSheetModal/BottomSheetModalStyles.ts +0 -43
- package/src/components/bottomSheetModal/BottomSheetModalTypes.ts +0 -26
- package/src/components/button/Button.tsx +0 -53
- package/src/components/button/styles.tsx +0 -30
- package/src/components/button/types.ts +0 -16
- package/src/components/cartTimer/CartTimer.tsx +0 -68
- package/src/components/cartTimer/styles.ts +0 -44
- package/src/components/cartTimer/types.ts +0 -22
- package/src/components/checkbox/Checkbox.tsx +0 -53
- package/src/components/checkbox/styles.ts +0 -41
- package/src/components/checkbox/types.ts +0 -23
- package/src/components/datePicker/DatePicker.tsx +0 -81
- package/src/components/datePicker/styles.ts +0 -39
- package/src/components/datePicker/types.ts +0 -21
- package/src/components/dropdown/Dropdown.tsx +0 -111
- package/src/components/dropdown/DropdownListItem.tsx +0 -36
- package/src/components/dropdown/styles.ts +0 -97
- package/src/components/dropdown/types.ts +0 -38
- package/src/components/dropdownMaterial/DropdownMaterial.tsx +0 -129
- package/src/components/dropdownMaterial/styles.ts +0 -91
- package/src/components/dropdownMaterial/types.ts +0 -24
- package/src/components/enterPassword/EnterPassword.tsx +0 -50
- package/src/components/enterPassword/styles.ts +0 -23
- package/src/components/enterPassword/types.ts +0 -27
- package/src/components/formField/FormField.tsx +0 -131
- package/src/components/formField/styles.ts +0 -37
- package/src/components/formField/types.ts +0 -60
- package/src/components/index.ts +0 -20
- package/src/components/input/Input.tsx +0 -77
- package/src/components/input/styles.ts +0 -53
- package/src/components/input/types.ts +0 -38
- package/src/components/loading/Loading.tsx +0 -30
- package/src/components/loading/styles.ts +0 -32
- package/src/components/loading/types.ts +0 -16
- package/src/components/loggedIn/LoggedIn.tsx +0 -60
- package/src/components/loggedIn/styles.ts +0 -9
- package/src/components/loggedIn/types.ts +0 -27
- package/src/components/login/Login.tsx +0 -161
- package/src/components/login/LoginView.tsx +0 -259
- package/src/components/login/components/LoginForm.tsx +0 -92
- package/src/components/login/components/types.ts +0 -22
- package/src/components/login/styles.ts +0 -63
- package/src/components/login/types.ts +0 -189
- package/src/components/phoneInput/PhoneInput.tsx +0 -72
- package/src/components/phoneInput/styles.ts +0 -31
- package/src/components/phoneInput/types.ts +0 -35
- package/src/components/promoCode/PromoCode.tsx +0 -111
- package/src/components/promoCode/styles.ts +0 -63
- package/src/components/promoCode/types.ts +0 -43
- package/src/components/radioButton/RadioButton.tsx +0 -26
- package/src/components/radioButton/styles.ts +0 -32
- package/src/components/radioButton/types.ts +0 -17
- package/src/components/radioGroup/RadioGroup.tsx +0 -86
- package/src/components/radioGroup/index.ts +0 -4
- package/src/components/radioGroup/types.ts +0 -26
- package/src/components/restorePassword/RestorePassword.tsx +0 -63
- package/src/components/restorePassword/ResultDialog.tsx +0 -26
- package/src/components/restorePassword/styles.ts +0 -38
- package/src/components/restorePassword/types.ts +0 -61
- package/src/components/separator/Separator.tsx +0 -26
- package/src/components/separator/types.ts +0 -9
- package/src/components/stripePayment/StripePayment.tsx +0 -51
- package/src/components/stripePayment/styles.ts +0 -7
- package/src/components/stripePayment/types.ts +0 -22
- package/src/components/waitingList/WaitingList.tsx +0 -147
- package/src/components/waitingList/WaitingListView.tsx +0 -94
- package/src/components/waitingList/styles.ts +0 -9
- package/src/components/waitingList/types.ts +0 -68
- package/src/containers/billingInfo/Billing.tsx +0 -1902
- package/src/containers/billingInfo/styles.ts +0 -64
- package/src/containers/billingInfo/types.ts +0 -217
- package/src/containers/checkout/Checkout.tsx +0 -519
- package/src/containers/checkout/CheckoutData.ts +0 -29
- package/src/containers/checkout/components/Conditions.tsx +0 -22
- package/src/containers/checkout/components/OrderReview.tsx +0 -31
- package/src/containers/checkout/components/styles.ts +0 -28
- package/src/containers/checkout/styles.ts +0 -44
- package/src/containers/checkout/types.ts +0 -148
- package/src/containers/index.ts +0 -8
- package/src/containers/myOrderDetails/MyOrderDetails.tsx +0 -318
- package/src/containers/myOrderDetails/MyOrderDetailsView.tsx +0 -269
- package/src/containers/myOrderDetails/components/Notification.tsx +0 -40
- package/src/containers/myOrderDetails/components/OrderListItem.tsx +0 -12
- package/src/containers/myOrderDetails/components/TicketActions/TicketActions.tsx +0 -68
- package/src/containers/myOrderDetails/components/TicketActions/TicketActionsTypes.ts +0 -41
- package/src/containers/myOrderDetails/components/TicketListItem/TicketListItem.tsx +0 -63
- package/src/containers/myOrderDetails/components/TicketListItem/TicketListItemStyles.ts +0 -33
- package/src/containers/myOrderDetails/components/TicketListItem/TicketListItemTypes.ts +0 -39
- package/src/containers/myOrderDetails/components/styles.ts +0 -42
- package/src/containers/myOrderDetails/styles.ts +0 -57
- package/src/containers/myOrderDetails/types.ts +0 -173
- package/src/containers/myOrders/MyOrders.tsx +0 -340
- package/src/containers/myOrders/MyOrdersView.tsx +0 -182
- package/src/containers/myOrders/components/OrderListItem.tsx +0 -50
- package/src/containers/myOrders/components/styles.ts +0 -55
- package/src/containers/myOrders/components/types.ts +0 -28
- package/src/containers/myOrders/styles.ts +0 -42
- package/src/containers/myOrders/types.ts +0 -84
- package/src/containers/purchaseConfirmation/PurchaseConfirmation.tsx +0 -145
- package/src/containers/purchaseConfirmation/PurchaseConfirmationView.tsx +0 -82
- package/src/containers/purchaseConfirmation/styles.ts +0 -79
- package/src/containers/purchaseConfirmation/types.ts +0 -77
- package/src/containers/resaleTickets/ResaleTickets.tsx +0 -234
- package/src/containers/resaleTickets/ResaleTicketsView.tsx +0 -314
- package/src/containers/resaleTickets/types.ts +0 -154
- package/src/containers/resetPassword/ResetPassword.tsx +0 -110
- package/src/containers/resetPassword/ResetPasswordView.tsx +0 -81
- package/src/containers/resetPassword/styles.ts +0 -35
- package/src/containers/resetPassword/types.ts +0 -56
- package/src/containers/tickets/Tickets.tsx +0 -525
- package/src/containers/tickets/TicketsView.tsx +0 -164
- package/src/containers/tickets/components/TicketGroupListHeader.tsx +0 -12
- package/src/containers/tickets/components/TicketListItem.tsx +0 -124
- package/src/containers/tickets/components/styles.ts +0 -54
- package/src/containers/tickets/components/types.ts +0 -47
- package/src/containers/tickets/styles.ts +0 -22
- package/src/containers/tickets/types.ts +0 -158
- package/src/core/BillingCore/BillingCore.tsx +0 -129
- package/src/core/BillingCore/BillingCoreTypes.ts +0 -34
- package/src/core/BillingCore/README.md +0 -22
- package/src/core/CheckoutCore/CheckoutCore.tsx +0 -113
- package/src/core/CheckoutCore/CheckoutCoreTypes.ts +0 -23
- package/src/core/CheckoutCore/README.md +0 -20
- package/src/core/CoreProps.ts +0 -5
- package/src/core/LoginCore/LoginCore.tsx +0 -140
- package/src/core/LoginCore/LoginCoreHelper.ts +0 -22
- package/src/core/LoginCore/LoginCoreTypes.ts +0 -21
- package/src/core/MIGRATION.md +0 -148
- package/src/core/MyOrdersCore/MyOrdersCore.tsx +0 -44
- package/src/core/MyOrdersCore/MyOrdersCoreTypes.ts +0 -15
- package/src/core/OrderDetailsCore/OrderDetailsCore.tsx +0 -36
- package/src/core/OrderDetailsCore/OrderDetailsCoreTypes.ts +0 -10
- package/src/core/PurchaseConfirmationCore/PurchaseConfirmationCore.tsx +0 -37
- package/src/core/PurchaseConfirmationCore/PurchaseConfirmationCoreTypes.ts +0 -10
- package/src/core/ResetPasswordCore/ResetPasswordCore.tsx +0 -21
- package/src/core/ResetPasswordCore/ResetPasswordCoreTypes.ts +0 -5
- package/src/core/Session/SessionCoreTypes.ts +0 -10
- package/src/core/Session/SessionHandle.tsx +0 -23
- package/src/core/TicketsCore/TicketsCore.tsx +0 -216
- package/src/core/TicketsCore/TicketsCoreTypes.ts +0 -52
- package/src/core/WaitingListCore/WaitingListCore.tsx +0 -35
- package/src/core/WaitingListCore/WaitingListCoreTypes.ts +0 -16
- package/src/core/index.ts +0 -20
- package/src/features/auth/api-hooks.ts +0 -61
- package/src/features/auth/types.ts +0 -54
- package/src/features/auth/utils.ts +0 -27
- package/src/features/checkout-v2/components/AddonsContainer.tsx +0 -159
- package/src/features/checkout-v2/components/Conditions.tsx +0 -144
- package/src/features/checkout-v2/components/OrderReview.tsx +0 -96
- package/src/features/checkout-v2/components/TicketHoldersSection.tsx +0 -131
- package/src/features/checkout-v2/form/config.tsx +0 -194
- package/src/features/checkout-v2/form/index.tsx +0 -830
- package/src/features/checkout-v2/form/styles.ts +0 -241
- package/src/features/checkout-v2/form/texts.ts +0 -133
- package/src/features/checkout-v2/form/types.ts +0 -231
- package/src/features/checkout-v2/hooks/api-hooks.ts +0 -332
- package/src/features/checkout-v2/hooks/use-checkout.ts +0 -927
- package/src/features/checkout-v2/index.tsx +0 -289
- package/src/features/checkout-v2/types.ts +0 -475
- package/src/features/checkout-v2/utils.ts +0 -156
- package/src/features/event/api-hooks.ts +0 -28
- package/src/features/event/types.ts +0 -69
- package/src/features/form/index.tsx +0 -185
- package/src/features/form/styles.ts +0 -37
- package/src/features/form/types.ts +0 -38
- package/src/features/geo/api-hooks.ts +0 -43
- package/src/features/geo/types.ts +0 -15
- package/src/helpers/Config.ts +0 -81
- package/src/helpers/CountryCodes.ts +0 -3382
- package/src/helpers/Debounced.ts +0 -27
- package/src/helpers/Domains.ts +0 -32
- package/src/helpers/LocalStorage.tsx +0 -152
- package/src/helpers/RefreshAccessToken.ts +0 -25
- package/src/helpers/StringsHelper.ts +0 -5
- package/src/helpers/Validators.ts +0 -108
- package/src/packages/rn-material-ui-textfield/README.md +0 -149
- package/src/packages/rn-material-ui-textfield/components/affix/index.js +0 -61
- package/src/packages/rn-material-ui-textfield/components/affix/styles.js +0 -8
- package/src/packages/rn-material-ui-textfield/components/counter/index.js +0 -36
- package/src/packages/rn-material-ui-textfield/components/counter/styles.js +0 -12
- package/src/packages/rn-material-ui-textfield/components/field/index.js +0 -700
- package/src/packages/rn-material-ui-textfield/components/field/styles.js +0 -42
- package/src/packages/rn-material-ui-textfield/components/field-filled/index.js +0 -21
- package/src/packages/rn-material-ui-textfield/components/field-filled/styles.js +0 -10
- package/src/packages/rn-material-ui-textfield/components/field-outlined/index.js +0 -59
- package/src/packages/rn-material-ui-textfield/components/helper/index.js +0 -78
- package/src/packages/rn-material-ui-textfield/components/helper/styles.js +0 -12
- package/src/packages/rn-material-ui-textfield/components/label/index.js +0 -123
- package/src/packages/rn-material-ui-textfield/components/label/styles.js +0 -16
- package/src/packages/rn-material-ui-textfield/components/line/index.js +0 -117
- package/src/packages/rn-material-ui-textfield/components/line/styles.js +0 -18
- package/src/packages/rn-material-ui-textfield/components/outline/index.js +0 -139
- package/src/packages/rn-material-ui-textfield/components/outline/styles.js +0 -83
- package/src/packages/rn-material-ui-textfield/index.d.ts +0 -53
- package/src/packages/rn-material-ui-textfield/index.js +0 -5
- package/src/packages/rn-material-ui-textfield/license.txt +0 -28
- package/src/res/colors.ts +0 -16
- package/src/res/icons.ts +0 -11
- package/src/res/images.ts +0 -3
- package/src/res/index.ts +0 -11
- package/src/types/IAccountTickets.ts +0 -75
- package/src/types/ICountry.ts +0 -2
- package/src/types/IError.ts +0 -5
- package/src/types/IEvent.ts +0 -87
- package/src/types/ITicket.ts +0 -75
- package/src/types/IUserProfile.ts +0 -30
- package/src/types/index.ts +0 -5
- package/src/utils/Logger.ts +0 -75
- package/src/utils/handlers.ts +0 -49
- package/src/utils/storageAdapter.ts +0 -44
- package/src/utils/styleUtils.ts +0 -76
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import React, { type FC } from 'react'
|
|
2
|
+
import { View } from 'react-native'
|
|
3
|
+
import {
|
|
4
|
+
createTranslator,
|
|
5
|
+
resolveLocale,
|
|
6
|
+
tripCopy,
|
|
7
|
+
tripsView,
|
|
8
|
+
type TripsProps,
|
|
9
|
+
} from 'tf-checkout-shared'
|
|
10
|
+
import { BodyText, Button, Card, ErrorText, SectionHeader } from '../ui/primitives'
|
|
11
|
+
|
|
12
|
+
/** onOpen delegates authenticated first-party browser/navigation handoff to the host app. */
|
|
13
|
+
export const Trips: FC<TripsProps> = ({
|
|
14
|
+
data,
|
|
15
|
+
locale,
|
|
16
|
+
loading,
|
|
17
|
+
errorMessage,
|
|
18
|
+
onRetry,
|
|
19
|
+
onOpen,
|
|
20
|
+
onPage,
|
|
21
|
+
}) => {
|
|
22
|
+
const copy = tripCopy(locale)
|
|
23
|
+
const t = createTranslator({ locale: resolveLocale(locale) })
|
|
24
|
+
const view = data ? tripsView(data, locale) : null
|
|
25
|
+
return (
|
|
26
|
+
<View accessibilityLabel={copy.title} accessibilityState={{ busy: Boolean(loading) }}>
|
|
27
|
+
{loading ? <BodyText>{t('common.loading')}</BodyText> : null}
|
|
28
|
+
{errorMessage ? (
|
|
29
|
+
<View accessibilityRole="alert">
|
|
30
|
+
<ErrorText>{errorMessage}</ErrorText>
|
|
31
|
+
{onRetry ? <Button onPress={onRetry}>{t('rewards.retry')}</Button> : null}
|
|
32
|
+
</View>
|
|
33
|
+
) : null}
|
|
34
|
+
{view ? (
|
|
35
|
+
<>
|
|
36
|
+
<SectionHeader title={view.title} subtitle={view.subtitle} />
|
|
37
|
+
{view.sections.map((section) => (
|
|
38
|
+
<View key={section.key}>
|
|
39
|
+
{section.title ? <SectionHeader title={section.title} /> : null}
|
|
40
|
+
{section.cards.length === 0 ? <BodyText>{section.empty}</BodyText> : null}
|
|
41
|
+
{section.cards.map((card) => (
|
|
42
|
+
<Card key={card.key}>
|
|
43
|
+
<SectionHeader title={card.title} />
|
|
44
|
+
{card.lines.map((line, index) => (
|
|
45
|
+
<BodyText key={index}>{line}</BodyText>
|
|
46
|
+
))}
|
|
47
|
+
{card.actions.map((action) => (
|
|
48
|
+
<Button
|
|
49
|
+
key={action.url}
|
|
50
|
+
variant="ghost"
|
|
51
|
+
onPress={() => onOpen(action.url)}
|
|
52
|
+
>
|
|
53
|
+
{action.label}
|
|
54
|
+
</Button>
|
|
55
|
+
))}
|
|
56
|
+
</Card>
|
|
57
|
+
))}
|
|
58
|
+
{section.page > 1 ? (
|
|
59
|
+
<Button
|
|
60
|
+
disabled={loading}
|
|
61
|
+
variant="ghost"
|
|
62
|
+
onPress={() =>
|
|
63
|
+
onPage({ page: section.page - 1, section: section.section })
|
|
64
|
+
}
|
|
65
|
+
>
|
|
66
|
+
{copy.previous}
|
|
67
|
+
</Button>
|
|
68
|
+
) : null}
|
|
69
|
+
{section.hasMore ? (
|
|
70
|
+
<Button
|
|
71
|
+
disabled={loading}
|
|
72
|
+
variant="ghost"
|
|
73
|
+
onPress={() =>
|
|
74
|
+
onPage({ page: section.page + 1, section: section.section })
|
|
75
|
+
}
|
|
76
|
+
>
|
|
77
|
+
{copy.next}
|
|
78
|
+
</Button>
|
|
79
|
+
) : null}
|
|
80
|
+
</View>
|
|
81
|
+
))}
|
|
82
|
+
</>
|
|
83
|
+
) : null}
|
|
84
|
+
</View>
|
|
85
|
+
)
|
|
86
|
+
}
|
|
87
|
+
export type { TripsProps } from 'tf-checkout-shared'
|
|
@@ -0,0 +1,429 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `<WaiverSigning/>` — the RN analogue of the web section: sign the event's
|
|
3
|
+
* waiver at checkout, one signature per ticket it covers. Each signature is
|
|
4
|
+
* uploaded on its own and the order carries only its reference. When the
|
|
5
|
+
* organiser made signing optional, a buyer can skip it: each guest gets a
|
|
6
|
+
* link to sign later.
|
|
7
|
+
*
|
|
8
|
+
* The signer draws a signature (`SignaturePad`, React Native core only, no
|
|
9
|
+
* native module) or types their name, from the methods the backend accepts
|
|
10
|
+
* for the event (`waiverSignatureMethods`).
|
|
11
|
+
*
|
|
12
|
+
* Renders nothing when the event has no waiver.
|
|
13
|
+
*/
|
|
14
|
+
import React, { useMemo, useRef, useState, type FC } from 'react'
|
|
15
|
+
import { Pressable, ScrollView, StyleSheet, Text, View } from 'react-native'
|
|
16
|
+
|
|
17
|
+
import {
|
|
18
|
+
createTranslator,
|
|
19
|
+
draftWithAllowedMethod,
|
|
20
|
+
emptyWaiverDraft,
|
|
21
|
+
formatDateDigits,
|
|
22
|
+
hooks,
|
|
23
|
+
htmlToPlainText,
|
|
24
|
+
holderBackfilledFrom,
|
|
25
|
+
signatureMatchesHolder,
|
|
26
|
+
waiverTicketFormKey,
|
|
27
|
+
waiverTickets,
|
|
28
|
+
withSignatureMethod,
|
|
29
|
+
type LocaleCode,
|
|
30
|
+
type Messages,
|
|
31
|
+
type Translate,
|
|
32
|
+
type WaiverSignatureDraft,
|
|
33
|
+
type WaiverSignatureMethod,
|
|
34
|
+
type WaiverTicket,
|
|
35
|
+
waiverSignableAtCheckout,
|
|
36
|
+
waiverSignatureMethods,
|
|
37
|
+
} from 'tf-checkout-shared'
|
|
38
|
+
|
|
39
|
+
import { useCheckoutContext, useTheme } from '../ui/CheckoutProvider'
|
|
40
|
+
import { SignaturePad } from '../ui/SignaturePad'
|
|
41
|
+
import { Checkbox, Field, Input } from '../ui/Field'
|
|
42
|
+
import { Button, Card, ErrorText, SectionHeader } from '../ui/primitives'
|
|
43
|
+
import type { ResolvedTheme } from '../ui/theme'
|
|
44
|
+
|
|
45
|
+
export interface WaiverSigningProps {
|
|
46
|
+
eventId: string
|
|
47
|
+
locale?: LocaleCode
|
|
48
|
+
messages?: Partial<Messages>
|
|
49
|
+
translate?: Translate
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export const WaiverSigning: FC<WaiverSigningProps> = ({
|
|
53
|
+
eventId,
|
|
54
|
+
locale,
|
|
55
|
+
messages,
|
|
56
|
+
translate,
|
|
57
|
+
}) => {
|
|
58
|
+
const checkout = useCheckoutContext()
|
|
59
|
+
// While the order is placed or charged its signatures are fixed (`orderFixed`).
|
|
60
|
+
const locked = Boolean(checkout.orderFixed)
|
|
61
|
+
const theme = useTheme()
|
|
62
|
+
const s = useWaiverStyles(theme)
|
|
63
|
+
const t = translate ?? createTranslator({ locale, messages })
|
|
64
|
+
const waiver = checkout.waiver
|
|
65
|
+
const signing = hooks.useWaiverSigning(
|
|
66
|
+
eventId,
|
|
67
|
+
waiver,
|
|
68
|
+
checkout.setWaiverSignature,
|
|
69
|
+
checkout.holdWaiverSigning
|
|
70
|
+
)
|
|
71
|
+
const [open, setOpen] = useState<Record<string, boolean>>({})
|
|
72
|
+
const [reloading, setReloading] = useState(false)
|
|
73
|
+
|
|
74
|
+
// The waiver could not be read: the order waits until it is.
|
|
75
|
+
if (checkout.unavailableDetails?.includes('waiver')) {
|
|
76
|
+
return (
|
|
77
|
+
<Card>
|
|
78
|
+
<SectionHeader title={t('waivers.heading')} />
|
|
79
|
+
<ErrorText>{t('waivers.error.load')}</ErrorText>
|
|
80
|
+
<Button
|
|
81
|
+
variant="ghost"
|
|
82
|
+
loading={reloading}
|
|
83
|
+
onPress={() => {
|
|
84
|
+
setReloading(true)
|
|
85
|
+
checkout.reloadCheckoutDetails().finally(() => setReloading(false))
|
|
86
|
+
}}
|
|
87
|
+
>
|
|
88
|
+
{t('waivers.retry')}
|
|
89
|
+
</Button>
|
|
90
|
+
</Card>
|
|
91
|
+
)
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
const tickets = waiverTickets(waiver, checkout)
|
|
95
|
+
if (!waiver || tickets.length === 0) return null
|
|
96
|
+
// The backend accepts no method this checkout offers: the guests sign
|
|
97
|
+
// through the emailed link, and payment does not wait.
|
|
98
|
+
if (!waiverSignableAtCheckout(waiver)) {
|
|
99
|
+
return (
|
|
100
|
+
<Card>
|
|
101
|
+
<SectionHeader title={waiver.title || t('waivers.heading')} />
|
|
102
|
+
<Text style={s.muted}>{t('waivers.signLater')}</Text>
|
|
103
|
+
</Card>
|
|
104
|
+
)
|
|
105
|
+
}
|
|
106
|
+
const signatures = checkout.waiverSignatures ?? {}
|
|
107
|
+
|
|
108
|
+
return (
|
|
109
|
+
<Card>
|
|
110
|
+
<SectionHeader title={waiver.title || t('waivers.heading')} />
|
|
111
|
+
<Text style={s.muted}>
|
|
112
|
+
{t(
|
|
113
|
+
waiver.checkoutMode === 'required'
|
|
114
|
+
? 'waivers.intro.required'
|
|
115
|
+
: 'waivers.intro.optional'
|
|
116
|
+
)}
|
|
117
|
+
</Text>
|
|
118
|
+
<ScrollView style={[s.textBox, { borderColor: theme.border }]} nestedScrollEnabled>
|
|
119
|
+
<Text style={s.body}>{htmlToPlainText(waiver.bodyHtml)}</Text>
|
|
120
|
+
</ScrollView>
|
|
121
|
+
|
|
122
|
+
{tickets.map((ticket) => {
|
|
123
|
+
const signed = signatures[ticket.index]
|
|
124
|
+
// Another event, waiver text or ticket is another form, with its own draft.
|
|
125
|
+
const formKey = waiverTicketFormKey(checkout.eventId, waiver, ticket)
|
|
126
|
+
// A signature counts only for the ticket's holder now.
|
|
127
|
+
const forHolder =
|
|
128
|
+
!signed ||
|
|
129
|
+
signatureMatchesHolder(
|
|
130
|
+
signed,
|
|
131
|
+
checkout.holders[ticket.index],
|
|
132
|
+
holderBackfilledFrom(checkout, ticket.index)
|
|
133
|
+
)
|
|
134
|
+
const label = ticket.holderName
|
|
135
|
+
? t('waivers.ticketFor', {
|
|
136
|
+
number: ticket.ticketNumber,
|
|
137
|
+
name: ticket.holderName,
|
|
138
|
+
})
|
|
139
|
+
: t('waivers.ticket', { number: ticket.ticketNumber })
|
|
140
|
+
return (
|
|
141
|
+
<View key={formKey} style={[s.ticket, { borderTopColor: theme.border }]}>
|
|
142
|
+
<Text style={s.strong}>{label}</Text>
|
|
143
|
+
{signed ? (
|
|
144
|
+
<View style={s.row}>
|
|
145
|
+
<Text style={s.body}>
|
|
146
|
+
{t(
|
|
147
|
+
!forHolder
|
|
148
|
+
? 'waivers.signedForSomeoneElse'
|
|
149
|
+
: signed.signerRole === 'guardian'
|
|
150
|
+
? 'waivers.signedByGuardian'
|
|
151
|
+
: 'waivers.signedBy',
|
|
152
|
+
{ name: signed.signerName }
|
|
153
|
+
)}
|
|
154
|
+
</Text>
|
|
155
|
+
<Button
|
|
156
|
+
variant="ghost"
|
|
157
|
+
disabled={locked}
|
|
158
|
+
onPress={() => {
|
|
159
|
+
checkout.setWaiverSignature(ticket.index, null)
|
|
160
|
+
setOpen((o) => ({ ...o, [formKey]: true }))
|
|
161
|
+
}}
|
|
162
|
+
>
|
|
163
|
+
{t('waivers.signAgain')}
|
|
164
|
+
</Button>
|
|
165
|
+
</View>
|
|
166
|
+
) : open[formKey] ? (
|
|
167
|
+
<TicketForm
|
|
168
|
+
ticket={ticket}
|
|
169
|
+
consentText={waiver.consentText}
|
|
170
|
+
t={t}
|
|
171
|
+
methods={waiverSignatureMethods(waiver)}
|
|
172
|
+
busy={signing.isBusy(ticket.index)}
|
|
173
|
+
locked={locked}
|
|
174
|
+
error={signing.errors[ticket.index]}
|
|
175
|
+
onSign={(draft, currentDraft) =>
|
|
176
|
+
signing.sign(ticket.index, draft, currentDraft)
|
|
177
|
+
}
|
|
178
|
+
/>
|
|
179
|
+
) : (
|
|
180
|
+
<Button
|
|
181
|
+
variant="ghost"
|
|
182
|
+
disabled={locked}
|
|
183
|
+
onPress={() => setOpen((o) => ({ ...o, [formKey]: true }))}
|
|
184
|
+
>
|
|
185
|
+
{t('waivers.signThis')}
|
|
186
|
+
</Button>
|
|
187
|
+
)}
|
|
188
|
+
</View>
|
|
189
|
+
)
|
|
190
|
+
})}
|
|
191
|
+
</Card>
|
|
192
|
+
)
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
const TicketForm: FC<{
|
|
196
|
+
ticket: WaiverTicket
|
|
197
|
+
consentText: string | null
|
|
198
|
+
t: Translate
|
|
199
|
+
/** The methods the backend accepts, its default first. */
|
|
200
|
+
methods: WaiverSignatureMethod[]
|
|
201
|
+
/** A signing for this ticket runs (perhaps started before the buyer came back). */
|
|
202
|
+
busy: boolean
|
|
203
|
+
/** The order is being placed: signing waits until it ends. */
|
|
204
|
+
locked?: boolean
|
|
205
|
+
error?: string
|
|
206
|
+
/** `currentDraft` reads the form's draft when the upload ends. */
|
|
207
|
+
onSign: (
|
|
208
|
+
draft: WaiverSignatureDraft,
|
|
209
|
+
currentDraft: () => WaiverSignatureDraft
|
|
210
|
+
) => Promise<string[]>
|
|
211
|
+
}> = ({ ticket, consentText, t, methods, busy, locked = false, error, onSign }) => {
|
|
212
|
+
const theme = useTheme()
|
|
213
|
+
const s = useWaiverStyles(theme)
|
|
214
|
+
const [heldDraft, setDraft] = useState<WaiverSignatureDraft>(() =>
|
|
215
|
+
emptyWaiverDraft(
|
|
216
|
+
{ firstName: ticket.holderFirstName, lastName: ticket.holderLastName },
|
|
217
|
+
{ signatureMethods: methods }
|
|
218
|
+
)
|
|
219
|
+
)
|
|
220
|
+
// Always a method this waiver accepts, so the form can always be signed.
|
|
221
|
+
const draft = draftWithAllowedMethod(heldDraft, methods)
|
|
222
|
+
const [problems, setProblems] = useState<string[]>([])
|
|
223
|
+
// True while this form's own press is being saved; otherwise a busy ticket
|
|
224
|
+
// is still saving a change from before.
|
|
225
|
+
const [pressed, setPressed] = useState(false)
|
|
226
|
+
// While a signature is saved or the order is placed, the draft cannot change.
|
|
227
|
+
const frozen = busy || locked
|
|
228
|
+
const draftRef = useRef(draft)
|
|
229
|
+
draftRef.current = draft
|
|
230
|
+
const patch = (next: Partial<WaiverSignatureDraft>) => {
|
|
231
|
+
if (!frozen) setDraft((d) => ({ ...d, ...next }))
|
|
232
|
+
}
|
|
233
|
+
const guardian = draft.signerRole === 'guardian'
|
|
234
|
+
|
|
235
|
+
return (
|
|
236
|
+
<View style={s.form}>
|
|
237
|
+
<Text style={s.strong}>{t('waivers.role.label')}</Text>
|
|
238
|
+
{(['holder', 'guardian'] as const).map((role) => (
|
|
239
|
+
<Pressable
|
|
240
|
+
key={role}
|
|
241
|
+
accessibilityRole="radio"
|
|
242
|
+
accessibilityState={{ selected: draft.signerRole === role, disabled: frozen }}
|
|
243
|
+
disabled={frozen}
|
|
244
|
+
onPress={() =>
|
|
245
|
+
patch(
|
|
246
|
+
role === 'guardian'
|
|
247
|
+
? {
|
|
248
|
+
signerRole: role,
|
|
249
|
+
minorName: draft.minorName ?? ticket.holderName ?? '',
|
|
250
|
+
}
|
|
251
|
+
: { signerRole: role }
|
|
252
|
+
)
|
|
253
|
+
}
|
|
254
|
+
style={s.choice}
|
|
255
|
+
>
|
|
256
|
+
<View
|
|
257
|
+
style={[
|
|
258
|
+
s.radio,
|
|
259
|
+
{ borderColor: theme.accent },
|
|
260
|
+
draft.signerRole === role && { backgroundColor: theme.accent },
|
|
261
|
+
]}
|
|
262
|
+
/>
|
|
263
|
+
<Text style={s.body}>{t(`waivers.role.${role}`)}</Text>
|
|
264
|
+
</Pressable>
|
|
265
|
+
))}
|
|
266
|
+
|
|
267
|
+
<Field label={t('waivers.firstName')}>
|
|
268
|
+
<Input
|
|
269
|
+
editable={!frozen}
|
|
270
|
+
value={draft.firstName}
|
|
271
|
+
autoCapitalize="words"
|
|
272
|
+
onChangeText={(firstName) => patch({ firstName })}
|
|
273
|
+
/>
|
|
274
|
+
</Field>
|
|
275
|
+
<Field label={t('waivers.lastName')}>
|
|
276
|
+
<Input
|
|
277
|
+
editable={!frozen}
|
|
278
|
+
value={draft.lastName}
|
|
279
|
+
autoCapitalize="words"
|
|
280
|
+
onChangeText={(lastName) => patch({ lastName })}
|
|
281
|
+
/>
|
|
282
|
+
</Field>
|
|
283
|
+
{guardian ? (
|
|
284
|
+
<>
|
|
285
|
+
<Field label={t('waivers.minorName')}>
|
|
286
|
+
<Input
|
|
287
|
+
editable={!frozen}
|
|
288
|
+
value={draft.minorName ?? ''}
|
|
289
|
+
autoCapitalize="words"
|
|
290
|
+
onChangeText={(minorName) => patch({ minorName })}
|
|
291
|
+
/>
|
|
292
|
+
</Field>
|
|
293
|
+
<Field label={t('waivers.relationship')}>
|
|
294
|
+
<Input
|
|
295
|
+
editable={!frozen}
|
|
296
|
+
value={draft.guardianRelationship ?? ''}
|
|
297
|
+
onChangeText={(guardianRelationship) => patch({ guardianRelationship })}
|
|
298
|
+
/>
|
|
299
|
+
</Field>
|
|
300
|
+
<Field label={t('waivers.minorDob')}>
|
|
301
|
+
<Input
|
|
302
|
+
editable={!frozen}
|
|
303
|
+
value={draft.minorDob ?? ''}
|
|
304
|
+
placeholder="YYYY-MM-DD"
|
|
305
|
+
keyboardType="number-pad"
|
|
306
|
+
autoCapitalize="none"
|
|
307
|
+
onChangeText={(minorDob) =>
|
|
308
|
+
patch({ minorDob: formatDateDigits(minorDob) || undefined })
|
|
309
|
+
}
|
|
310
|
+
/>
|
|
311
|
+
</Field>
|
|
312
|
+
</>
|
|
313
|
+
) : null}
|
|
314
|
+
|
|
315
|
+
{methods.length > 1
|
|
316
|
+
? methods.map((method) => (
|
|
317
|
+
<Pressable
|
|
318
|
+
key={method}
|
|
319
|
+
accessibilityRole="radio"
|
|
320
|
+
accessibilityState={{ selected: draft.method === method }}
|
|
321
|
+
disabled={frozen}
|
|
322
|
+
onPress={() => setDraft((d) => withSignatureMethod(d, method))}
|
|
323
|
+
style={s.choice}
|
|
324
|
+
>
|
|
325
|
+
<View
|
|
326
|
+
style={[
|
|
327
|
+
s.radio,
|
|
328
|
+
{ borderColor: theme.accent },
|
|
329
|
+
draft.method === method && { backgroundColor: theme.accent },
|
|
330
|
+
]}
|
|
331
|
+
/>
|
|
332
|
+
<Text style={s.body}>{t(`waivers.method.${method}`)}</Text>
|
|
333
|
+
</Pressable>
|
|
334
|
+
))
|
|
335
|
+
: null}
|
|
336
|
+
{draft.method === 'typed' ? (
|
|
337
|
+
<Field label={t('waivers.typedName')}>
|
|
338
|
+
<Input
|
|
339
|
+
editable={!frozen}
|
|
340
|
+
value={draft.typedName ?? ''}
|
|
341
|
+
autoCapitalize="words"
|
|
342
|
+
onChangeText={(typedName) => patch({ typedName })}
|
|
343
|
+
/>
|
|
344
|
+
</Field>
|
|
345
|
+
) : (
|
|
346
|
+
<SignaturePad
|
|
347
|
+
label={t('waivers.draw')}
|
|
348
|
+
clearLabel={t('waivers.clear')}
|
|
349
|
+
disabled={frozen}
|
|
350
|
+
onChange={(imageDataUrl, inkLength) => patch({ imageDataUrl, inkLength })}
|
|
351
|
+
/>
|
|
352
|
+
)}
|
|
353
|
+
<Checkbox
|
|
354
|
+
checked={draft.agreeElectronic}
|
|
355
|
+
onChange={(agreeElectronic) => patch({ agreeElectronic })}
|
|
356
|
+
label={consentText || t('waivers.agree')}
|
|
357
|
+
/>
|
|
358
|
+
|
|
359
|
+
{problems.map((key) => (
|
|
360
|
+
<ErrorText key={key}>{t(key)}</ErrorText>
|
|
361
|
+
))}
|
|
362
|
+
{error ? <ErrorText>{error}</ErrorText> : null}
|
|
363
|
+
{busy && !pressed ? (
|
|
364
|
+
<Text style={s.muted} accessibilityLiveRegion="polite">
|
|
365
|
+
{t('common.stillSaving')}
|
|
366
|
+
</Text>
|
|
367
|
+
) : null}
|
|
368
|
+
|
|
369
|
+
<Button
|
|
370
|
+
loading={busy}
|
|
371
|
+
disabled={busy || locked}
|
|
372
|
+
onPress={() => {
|
|
373
|
+
setPressed(true)
|
|
374
|
+
void onSign(draft, () => draftRef.current)
|
|
375
|
+
.then(setProblems)
|
|
376
|
+
.finally(() => setPressed(false))
|
|
377
|
+
}}
|
|
378
|
+
>
|
|
379
|
+
{busy ? t('waivers.signing') : t('waivers.sign')}
|
|
380
|
+
</Button>
|
|
381
|
+
</View>
|
|
382
|
+
)
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
const useWaiverStyles = (theme: ResolvedTheme) =>
|
|
386
|
+
useMemo(
|
|
387
|
+
() =>
|
|
388
|
+
StyleSheet.create({
|
|
389
|
+
muted: {
|
|
390
|
+
color: theme.muted,
|
|
391
|
+
fontSize: theme.fontSize - 1,
|
|
392
|
+
fontFamily: theme.fontFamily,
|
|
393
|
+
},
|
|
394
|
+
body: {
|
|
395
|
+
color: theme.text,
|
|
396
|
+
fontSize: theme.fontSize - 1,
|
|
397
|
+
fontFamily: theme.fontFamily,
|
|
398
|
+
flexShrink: 1,
|
|
399
|
+
},
|
|
400
|
+
strong: {
|
|
401
|
+
color: theme.text,
|
|
402
|
+
fontSize: theme.fontSize,
|
|
403
|
+
fontWeight: '600',
|
|
404
|
+
fontFamily: theme.fontFamily,
|
|
405
|
+
},
|
|
406
|
+
textBox: {
|
|
407
|
+
maxHeight: 220,
|
|
408
|
+
borderWidth: StyleSheet.hairlineWidth,
|
|
409
|
+
borderRadius: 8,
|
|
410
|
+
padding: 12,
|
|
411
|
+
},
|
|
412
|
+
ticket: { gap: 8, paddingTop: 12, borderTopWidth: StyleSheet.hairlineWidth },
|
|
413
|
+
row: {
|
|
414
|
+
flexDirection: 'row',
|
|
415
|
+
alignItems: 'center',
|
|
416
|
+
justifyContent: 'space-between',
|
|
417
|
+
gap: 12,
|
|
418
|
+
},
|
|
419
|
+
form: { gap: 10 },
|
|
420
|
+
choice: {
|
|
421
|
+
flexDirection: 'row',
|
|
422
|
+
alignItems: 'center',
|
|
423
|
+
gap: 8,
|
|
424
|
+
paddingVertical: 4,
|
|
425
|
+
},
|
|
426
|
+
radio: { width: 18, height: 18, borderRadius: 9, borderWidth: 2 },
|
|
427
|
+
}),
|
|
428
|
+
[theme]
|
|
429
|
+
)
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
import React, { type Dispatch, type FC, type SetStateAction } from 'react'
|
|
2
|
+
import { StyleSheet, View } from 'react-native'
|
|
3
|
+
|
|
4
|
+
import { Field, Input } from '../../ui/Field'
|
|
5
|
+
import { BodyText } from '../../ui/primitives'
|
|
6
|
+
import { Select, type SelectOption } from '../../ui/Select'
|
|
7
|
+
import type { BillingDraft, BillingFieldError, LocationOption } from './types'
|
|
8
|
+
|
|
9
|
+
interface BillingAddressFieldsProps {
|
|
10
|
+
billing: BillingDraft
|
|
11
|
+
countries: LocationOption[]
|
|
12
|
+
states: LocationOption[]
|
|
13
|
+
fieldError: BillingFieldError
|
|
14
|
+
setBilling: Dispatch<SetStateAction<BillingDraft>>
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Address fields shared by the embedded and stepped billing experiences. The RN
|
|
19
|
+
* analogue of the web `BillingAddressFields`: country/state `<select>` become the
|
|
20
|
+
* native `../ui/Select`; text inputs keep the same placeholder copy.
|
|
21
|
+
*/
|
|
22
|
+
export const BillingAddressFields: FC<BillingAddressFieldsProps> = ({
|
|
23
|
+
billing,
|
|
24
|
+
countries,
|
|
25
|
+
states,
|
|
26
|
+
fieldError,
|
|
27
|
+
setBilling,
|
|
28
|
+
}) => {
|
|
29
|
+
const setValue = (key: keyof BillingDraft) => (value: string) =>
|
|
30
|
+
setBilling((current) => ({ ...current, [key]: value }))
|
|
31
|
+
|
|
32
|
+
const countryOptions: SelectOption[] = countries.map((country) => ({
|
|
33
|
+
label: country.name,
|
|
34
|
+
value: String(country.id),
|
|
35
|
+
}))
|
|
36
|
+
const stateOptions: SelectOption[] = states.map((state) => ({
|
|
37
|
+
label: state.name,
|
|
38
|
+
value: String(state.id),
|
|
39
|
+
}))
|
|
40
|
+
|
|
41
|
+
return (
|
|
42
|
+
<>
|
|
43
|
+
<BodyText style={styles.sectionLabel}>Billing address *</BodyText>
|
|
44
|
+
<Field error={fieldError('Street address', 'Street address is required.')}>
|
|
45
|
+
<Input
|
|
46
|
+
placeholder="Street address *"
|
|
47
|
+
value={billing.streetAddress ?? ''}
|
|
48
|
+
onChangeText={setValue('streetAddress')}
|
|
49
|
+
invalid={Boolean(fieldError('Street address'))}
|
|
50
|
+
/>
|
|
51
|
+
</Field>
|
|
52
|
+
<View style={styles.row}>
|
|
53
|
+
<View style={styles.col}>
|
|
54
|
+
<Field error={fieldError('City', 'City is required.')}>
|
|
55
|
+
<Input
|
|
56
|
+
placeholder="City *"
|
|
57
|
+
value={billing.city ?? ''}
|
|
58
|
+
onChangeText={setValue('city')}
|
|
59
|
+
invalid={Boolean(fieldError('City'))}
|
|
60
|
+
/>
|
|
61
|
+
</Field>
|
|
62
|
+
</View>
|
|
63
|
+
<View style={styles.col}>
|
|
64
|
+
<Field error={fieldError('ZIP / postcode', 'ZIP / postcode is required.')}>
|
|
65
|
+
<Input
|
|
66
|
+
placeholder="ZIP / Postcode *"
|
|
67
|
+
value={billing.zip ?? ''}
|
|
68
|
+
onChangeText={setValue('zip')}
|
|
69
|
+
keyboardType="numbers-and-punctuation"
|
|
70
|
+
invalid={Boolean(fieldError('ZIP / postcode'))}
|
|
71
|
+
/>
|
|
72
|
+
</Field>
|
|
73
|
+
</View>
|
|
74
|
+
</View>
|
|
75
|
+
<View style={styles.row}>
|
|
76
|
+
<View style={styles.col}>
|
|
77
|
+
<Field error={fieldError('Country', 'Country is required.')}>
|
|
78
|
+
<Select
|
|
79
|
+
value={billing.countryId ?? undefined}
|
|
80
|
+
onChange={(value) => {
|
|
81
|
+
const country = countries.find(
|
|
82
|
+
(candidate) => String(candidate.id) === value
|
|
83
|
+
)
|
|
84
|
+
setBilling((current) => ({
|
|
85
|
+
...current,
|
|
86
|
+
countryId: value,
|
|
87
|
+
countryCode: country?.code?.toUpperCase(),
|
|
88
|
+
stateId: undefined,
|
|
89
|
+
stateCode: undefined,
|
|
90
|
+
}))
|
|
91
|
+
}}
|
|
92
|
+
options={countryOptions}
|
|
93
|
+
placeholder="— country * —"
|
|
94
|
+
invalid={Boolean(fieldError('Country'))}
|
|
95
|
+
/>
|
|
96
|
+
</Field>
|
|
97
|
+
</View>
|
|
98
|
+
<View style={styles.col}>
|
|
99
|
+
<Field error={fieldError('State / county', 'State / county is required.')}>
|
|
100
|
+
<Select
|
|
101
|
+
value={billing.stateId ?? undefined}
|
|
102
|
+
onChange={(value) => {
|
|
103
|
+
const state = states.find((candidate) => String(candidate.id) === value)
|
|
104
|
+
setBilling((current) => ({
|
|
105
|
+
...current,
|
|
106
|
+
stateId: value,
|
|
107
|
+
stateCode: state?.code,
|
|
108
|
+
}))
|
|
109
|
+
}}
|
|
110
|
+
options={stateOptions}
|
|
111
|
+
placeholder={`— state / county${states.length > 0 ? ' *' : ''} —`}
|
|
112
|
+
disabled={!billing.countryId || states.length === 0}
|
|
113
|
+
invalid={Boolean(fieldError('State / county'))}
|
|
114
|
+
/>
|
|
115
|
+
</Field>
|
|
116
|
+
</View>
|
|
117
|
+
</View>
|
|
118
|
+
</>
|
|
119
|
+
)
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
const styles = StyleSheet.create({
|
|
123
|
+
sectionLabel: { fontWeight: '600' },
|
|
124
|
+
row: { flexDirection: 'row', gap: 10 },
|
|
125
|
+
col: { flex: 1 },
|
|
126
|
+
})
|