@tonder.io/rn-sdk 0.1.0-beta.DEV1355.1
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/LICENSE +20 -0
- package/README.md +33 -0
- package/lib/commonjs/core/3DSHandler.js +108 -0
- package/lib/commonjs/core/3DSHandler.js.map +1 -0
- package/lib/commonjs/core/BaseCheckout/index.js +337 -0
- package/lib/commonjs/core/BaseCheckout/index.js.map +1 -0
- package/lib/commonjs/core/BaseEnrollment/index.js +86 -0
- package/lib/commonjs/core/BaseEnrollment/index.js.map +1 -0
- package/lib/commonjs/core/BaseSDK/index.js +75 -0
- package/lib/commonjs/core/BaseSDK/index.js.map +1 -0
- package/lib/commonjs/core/EnrollmentContainer/index.js +87 -0
- package/lib/commonjs/core/EnrollmentContainer/index.js.map +1 -0
- package/lib/commonjs/core/PaymentInlineContainer/index.js +111 -0
- package/lib/commonjs/core/PaymentInlineContainer/index.js.map +1 -0
- package/lib/commonjs/core/PaymentLiteContainer/index.js +158 -0
- package/lib/commonjs/core/PaymentLiteContainer/index.js.map +1 -0
- package/lib/commonjs/core/Tonder/index.js +134 -0
- package/lib/commonjs/core/Tonder/index.js.map +1 -0
- package/lib/commonjs/hooks/useTonder/index-old.js +37 -0
- package/lib/commonjs/hooks/useTonder/index-old.js.map +1 -0
- package/lib/commonjs/hooks/useTonder/index.js +16 -0
- package/lib/commonjs/hooks/useTonder/index.js.map +1 -0
- package/lib/commonjs/index.js +121 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/infrastructure/HttpClient.js +108 -0
- package/lib/commonjs/infrastructure/HttpClient.js.map +1 -0
- package/lib/commonjs/infrastructure/ServiceManager.js +32 -0
- package/lib/commonjs/infrastructure/ServiceManager.js.map +1 -0
- package/lib/commonjs/infrastructure/index.js +28 -0
- package/lib/commonjs/infrastructure/index.js.map +1 -0
- package/lib/commonjs/services/BusinessService.js +36 -0
- package/lib/commonjs/services/BusinessService.js.map +1 -0
- package/lib/commonjs/services/CardService.js +89 -0
- package/lib/commonjs/services/CardService.js.map +1 -0
- package/lib/commonjs/services/CheckoutService.js +121 -0
- package/lib/commonjs/services/CheckoutService.js.map +1 -0
- package/lib/commonjs/services/CustomerService.js +62 -0
- package/lib/commonjs/services/CustomerService.js.map +1 -0
- package/lib/commonjs/services/MercadoPagoService.js +27 -0
- package/lib/commonjs/services/MercadoPagoService.js.map +1 -0
- package/lib/commonjs/services/OpenPayService.js +25 -0
- package/lib/commonjs/services/OpenPayService.js.map +1 -0
- package/lib/commonjs/services/PaymentMethodService.js +37 -0
- package/lib/commonjs/services/PaymentMethodService.js.map +1 -0
- package/lib/commonjs/services/SkyflowService.js +53 -0
- package/lib/commonjs/services/SkyflowService.js.map +1 -0
- package/lib/commonjs/services/StorageService.js +49 -0
- package/lib/commonjs/services/StorageService.js.map +1 -0
- package/lib/commonjs/services/TokenService.js +46 -0
- package/lib/commonjs/services/TokenService.js.map +1 -0
- package/lib/commonjs/services/TransactionService.js +26 -0
- package/lib/commonjs/services/TransactionService.js.map +1 -0
- package/lib/commonjs/services/index.js +127 -0
- package/lib/commonjs/services/index.js.map +1 -0
- package/lib/commonjs/shared/catalog/cardBrandCatalog.js +19 -0
- package/lib/commonjs/shared/catalog/cardBrandCatalog.js.map +1 -0
- package/lib/commonjs/shared/catalog/paymentMethodsCatalog.js +252 -0
- package/lib/commonjs/shared/catalog/paymentMethodsCatalog.js.map +1 -0
- package/lib/commonjs/shared/constants/environments.js +13 -0
- package/lib/commonjs/shared/constants/environments.js.map +1 -0
- package/lib/commonjs/shared/constants/index.js +28 -0
- package/lib/commonjs/shared/constants/index.js.map +1 -0
- package/lib/commonjs/shared/constants/messages.js +101 -0
- package/lib/commonjs/shared/constants/messages.js.map +1 -0
- package/lib/commonjs/shared/constants/paymentMethods.js +68 -0
- package/lib/commonjs/shared/constants/paymentMethods.js.map +1 -0
- package/lib/commonjs/shared/constants/skyflow.js +47 -0
- package/lib/commonjs/shared/constants/skyflow.js.map +1 -0
- package/lib/commonjs/shared/enum/ErrorKeyEnum.js +55 -0
- package/lib/commonjs/shared/enum/ErrorKeyEnum.js.map +1 -0
- package/lib/commonjs/shared/enum/index.js +17 -0
- package/lib/commonjs/shared/enum/index.js.map +1 -0
- package/lib/commonjs/shared/index.js +39 -0
- package/lib/commonjs/shared/index.js.map +1 -0
- package/lib/commonjs/shared/utils/common.js +47 -0
- package/lib/commonjs/shared/utils/common.js.map +1 -0
- package/lib/commonjs/shared/utils/errors.js +21 -0
- package/lib/commonjs/shared/utils/errors.js.map +1 -0
- package/lib/commonjs/shared/utils/numberUtils.js +17 -0
- package/lib/commonjs/shared/utils/numberUtils.js.map +1 -0
- package/lib/commonjs/shared/utils/paymentMethodUtils.js +21 -0
- package/lib/commonjs/shared/utils/paymentMethodUtils.js.map +1 -0
- package/lib/commonjs/shared/utils/stringUtils.js +11 -0
- package/lib/commonjs/shared/utils/stringUtils.js.map +1 -0
- package/lib/commonjs/shared/utils/styleUtils.js +21 -0
- package/lib/commonjs/shared/utils/styleUtils.js.map +1 -0
- package/lib/commonjs/types/base.js +14 -0
- package/lib/commonjs/types/base.js.map +1 -0
- package/lib/commonjs/types/baseCheckout.js +6 -0
- package/lib/commonjs/types/baseCheckout.js.map +1 -0
- package/lib/commonjs/types/baseEnrollment.js +6 -0
- package/lib/commonjs/types/baseEnrollment.js.map +1 -0
- package/lib/commonjs/types/baseSDK.js +6 -0
- package/lib/commonjs/types/baseSDK.js.map +1 -0
- package/lib/commonjs/types/business.js +2 -0
- package/lib/commonjs/types/business.js.map +1 -0
- package/lib/commonjs/types/card.js +2 -0
- package/lib/commonjs/types/card.js.map +1 -0
- package/lib/commonjs/types/checkout.js +6 -0
- package/lib/commonjs/types/checkout.js.map +1 -0
- package/lib/commonjs/types/common.js +6 -0
- package/lib/commonjs/types/common.js.map +1 -0
- package/lib/commonjs/types/customer.js +2 -0
- package/lib/commonjs/types/customer.js.map +1 -0
- package/lib/commonjs/types/enrollment.js +6 -0
- package/lib/commonjs/types/enrollment.js.map +1 -0
- package/lib/commonjs/types/index.js +204 -0
- package/lib/commonjs/types/index.js.map +1 -0
- package/lib/commonjs/types/inlineCheckout.js +6 -0
- package/lib/commonjs/types/inlineCheckout.js.map +1 -0
- package/lib/commonjs/types/input.js +6 -0
- package/lib/commonjs/types/input.js.map +1 -0
- package/lib/commonjs/types/liteCheckout.js +6 -0
- package/lib/commonjs/types/liteCheckout.js.map +1 -0
- package/lib/commonjs/types/openpay-react-native.d.js +2 -0
- package/lib/commonjs/types/openpay-react-native.d.js.map +1 -0
- package/lib/commonjs/types/openpay.js +2 -0
- package/lib/commonjs/types/openpay.js.map +1 -0
- package/lib/commonjs/types/payment.js +6 -0
- package/lib/commonjs/types/payment.js.map +1 -0
- package/lib/commonjs/types/secure.js +2 -0
- package/lib/commonjs/types/secure.js.map +1 -0
- package/lib/commonjs/types/skyflow-react-native.d.js +2 -0
- package/lib/commonjs/types/skyflow-react-native.d.js.map +1 -0
- package/lib/commonjs/types/threeDSHandler.js +6 -0
- package/lib/commonjs/types/threeDSHandler.js.map +1 -0
- package/lib/commonjs/types/transaction.js +2 -0
- package/lib/commonjs/types/transaction.js.map +1 -0
- package/lib/commonjs/ui/components/Button/ProcessButton.js +50 -0
- package/lib/commonjs/ui/components/Button/ProcessButton.js.map +1 -0
- package/lib/commonjs/ui/components/CardForm/index.js +80 -0
- package/lib/commonjs/ui/components/CardForm/index.js.map +1 -0
- package/lib/commonjs/ui/components/Checkbox/Checkbox.js +62 -0
- package/lib/commonjs/ui/components/Checkbox/Checkbox.js.map +1 -0
- package/lib/commonjs/ui/components/Input/CardCVVInput.js +83 -0
- package/lib/commonjs/ui/components/Input/CardCVVInput.js.map +1 -0
- package/lib/commonjs/ui/components/Input/CardExpirationDateInput.js +91 -0
- package/lib/commonjs/ui/components/Input/CardExpirationDateInput.js.map +1 -0
- package/lib/commonjs/ui/components/Input/CardExpirationMonthInput.js +84 -0
- package/lib/commonjs/ui/components/Input/CardExpirationMonthInput.js.map +1 -0
- package/lib/commonjs/ui/components/Input/CardExpirationYearInput.js +84 -0
- package/lib/commonjs/ui/components/Input/CardExpirationYearInput.js.map +1 -0
- package/lib/commonjs/ui/components/Input/CardHolderInput.js +83 -0
- package/lib/commonjs/ui/components/Input/CardHolderInput.js.map +1 -0
- package/lib/commonjs/ui/components/Input/CardNumberInput.js +83 -0
- package/lib/commonjs/ui/components/Input/CardNumberInput.js.map +1 -0
- package/lib/commonjs/ui/components/PaymentMethodsList/index.js +105 -0
- package/lib/commonjs/ui/components/PaymentMethodsList/index.js.map +1 -0
- package/lib/commonjs/ui/components/RadioButton/index.js +57 -0
- package/lib/commonjs/ui/components/RadioButton/index.js.map +1 -0
- package/lib/commonjs/ui/components/SavedCardsList/index.js +126 -0
- package/lib/commonjs/ui/components/SavedCardsList/index.js.map +1 -0
- package/lib/commonjs/ui/components/Skeleton/CardFormSkeleton.js +102 -0
- package/lib/commonjs/ui/components/Skeleton/CardFormSkeleton.js.map +1 -0
- package/lib/commonjs/ui/components/WebView/ThreeDSWebView.js +105 -0
- package/lib/commonjs/ui/components/WebView/ThreeDSWebView.js.map +1 -0
- package/lib/commonjs/ui/features/TonderEnrollment/index.js +119 -0
- package/lib/commonjs/ui/features/TonderEnrollment/index.js.map +1 -0
- package/lib/commonjs/ui/features/TonderPayment/index.js +195 -0
- package/lib/commonjs/ui/features/TonderPayment/index.js.map +1 -0
- package/lib/commonjs/ui/providers/InnerProvider/index.js +25 -0
- package/lib/commonjs/ui/providers/InnerProvider/index.js.map +1 -0
- package/lib/commonjs/ui/providers/SkyflowContainerWrapper/index.js +31 -0
- package/lib/commonjs/ui/providers/SkyflowContainerWrapper/index.js.map +1 -0
- package/lib/commonjs/ui/providers/TonderProvider/context.js +16 -0
- package/lib/commonjs/ui/providers/TonderProvider/context.js.map +1 -0
- package/lib/commonjs/ui/providers/TonderProvider/hook.js +15 -0
- package/lib/commonjs/ui/providers/TonderProvider/hook.js.map +1 -0
- package/lib/commonjs/ui/providers/TonderProvider/index.js +96 -0
- package/lib/commonjs/ui/providers/TonderProvider/index.js.map +1 -0
- package/lib/commonjs/ui/providers/TonderProvider/uiWrapper.js +61 -0
- package/lib/commonjs/ui/providers/TonderProvider/uiWrapper.js.map +1 -0
- package/lib/commonjs/ui/styles/payment.js +27 -0
- package/lib/commonjs/ui/styles/payment.js.map +1 -0
- package/lib/commonjs/ui/styles/skyflow.js +54 -0
- package/lib/commonjs/ui/styles/skyflow.js.map +1 -0
- package/lib/module/core/3DSHandler.js +102 -0
- package/lib/module/core/3DSHandler.js.map +1 -0
- package/lib/module/core/BaseCheckout/index.js +332 -0
- package/lib/module/core/BaseCheckout/index.js.map +1 -0
- package/lib/module/core/BaseEnrollment/index.js +81 -0
- package/lib/module/core/BaseEnrollment/index.js.map +1 -0
- package/lib/module/core/BaseSDK/index.js +70 -0
- package/lib/module/core/BaseSDK/index.js.map +1 -0
- package/lib/module/core/EnrollmentContainer/index.js +81 -0
- package/lib/module/core/EnrollmentContainer/index.js.map +1 -0
- package/lib/module/core/PaymentInlineContainer/index.js +106 -0
- package/lib/module/core/PaymentInlineContainer/index.js.map +1 -0
- package/lib/module/core/PaymentLiteContainer/index.js +153 -0
- package/lib/module/core/PaymentLiteContainer/index.js.map +1 -0
- package/lib/module/core/Tonder/index.js +129 -0
- package/lib/module/core/Tonder/index.js.map +1 -0
- package/lib/module/hooks/useTonder/index-old.js +37 -0
- package/lib/module/hooks/useTonder/index-old.js.map +1 -0
- package/lib/module/hooks/useTonder/index.js +11 -0
- package/lib/module/hooks/useTonder/index.js.map +1 -0
- package/lib/module/index.js +14 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/infrastructure/HttpClient.js +102 -0
- package/lib/module/infrastructure/HttpClient.js.map +1 -0
- package/lib/module/infrastructure/ServiceManager.js +27 -0
- package/lib/module/infrastructure/ServiceManager.js.map +1 -0
- package/lib/module/infrastructure/index.js +5 -0
- package/lib/module/infrastructure/index.js.map +1 -0
- package/lib/module/services/BusinessService.js +30 -0
- package/lib/module/services/BusinessService.js.map +1 -0
- package/lib/module/services/CardService.js +83 -0
- package/lib/module/services/CardService.js.map +1 -0
- package/lib/module/services/CheckoutService.js +115 -0
- package/lib/module/services/CheckoutService.js.map +1 -0
- package/lib/module/services/CustomerService.js +56 -0
- package/lib/module/services/CustomerService.js.map +1 -0
- package/lib/module/services/MercadoPagoService.js +22 -0
- package/lib/module/services/MercadoPagoService.js.map +1 -0
- package/lib/module/services/OpenPayService.js +20 -0
- package/lib/module/services/OpenPayService.js.map +1 -0
- package/lib/module/services/PaymentMethodService.js +31 -0
- package/lib/module/services/PaymentMethodService.js.map +1 -0
- package/lib/module/services/SkyflowService.js +47 -0
- package/lib/module/services/SkyflowService.js.map +1 -0
- package/lib/module/services/StorageService.js +43 -0
- package/lib/module/services/StorageService.js.map +1 -0
- package/lib/module/services/TokenService.js +40 -0
- package/lib/module/services/TokenService.js.map +1 -0
- package/lib/module/services/TransactionService.js +20 -0
- package/lib/module/services/TransactionService.js.map +1 -0
- package/lib/module/services/index.js +15 -0
- package/lib/module/services/index.js.map +1 -0
- package/lib/module/shared/catalog/cardBrandCatalog.js +14 -0
- package/lib/module/shared/catalog/cardBrandCatalog.js.map +1 -0
- package/lib/module/shared/catalog/paymentMethodsCatalog.js +247 -0
- package/lib/module/shared/catalog/paymentMethodsCatalog.js.map +1 -0
- package/lib/module/shared/constants/environments.js +10 -0
- package/lib/module/shared/constants/environments.js.map +1 -0
- package/lib/module/shared/constants/index.js +5 -0
- package/lib/module/shared/constants/index.js.map +1 -0
- package/lib/module/shared/constants/messages.js +97 -0
- package/lib/module/shared/constants/messages.js.map +1 -0
- package/lib/module/shared/constants/paymentMethods.js +65 -0
- package/lib/module/shared/constants/paymentMethods.js.map +1 -0
- package/lib/module/shared/constants/skyflow.js +43 -0
- package/lib/module/shared/constants/skyflow.js.map +1 -0
- package/lib/module/shared/enum/ErrorKeyEnum.js +51 -0
- package/lib/module/shared/enum/ErrorKeyEnum.js.map +1 -0
- package/lib/module/shared/enum/index.js +4 -0
- package/lib/module/shared/enum/index.js.map +1 -0
- package/lib/module/shared/index.js +6 -0
- package/lib/module/shared/index.js.map +1 -0
- package/lib/module/shared/utils/common.js +41 -0
- package/lib/module/shared/utils/common.js.map +1 -0
- package/lib/module/shared/utils/errors.js +17 -0
- package/lib/module/shared/utils/errors.js.map +1 -0
- package/lib/module/shared/utils/numberUtils.js +13 -0
- package/lib/module/shared/utils/numberUtils.js.map +1 -0
- package/lib/module/shared/utils/paymentMethodUtils.js +16 -0
- package/lib/module/shared/utils/paymentMethodUtils.js.map +1 -0
- package/lib/module/shared/utils/stringUtils.js +6 -0
- package/lib/module/shared/utils/stringUtils.js.map +1 -0
- package/lib/module/shared/utils/styleUtils.js +17 -0
- package/lib/module/shared/utils/styleUtils.js.map +1 -0
- package/lib/module/types/base.js +13 -0
- package/lib/module/types/base.js.map +1 -0
- package/lib/module/types/baseCheckout.js +4 -0
- package/lib/module/types/baseCheckout.js.map +1 -0
- package/lib/module/types/baseEnrollment.js +4 -0
- package/lib/module/types/baseEnrollment.js.map +1 -0
- package/lib/module/types/baseSDK.js +4 -0
- package/lib/module/types/baseSDK.js.map +1 -0
- package/lib/module/types/business.js +2 -0
- package/lib/module/types/business.js.map +1 -0
- package/lib/module/types/card.js +2 -0
- package/lib/module/types/card.js.map +1 -0
- package/lib/module/types/checkout.js +4 -0
- package/lib/module/types/checkout.js.map +1 -0
- package/lib/module/types/common.js +4 -0
- package/lib/module/types/common.js.map +1 -0
- package/lib/module/types/customer.js +2 -0
- package/lib/module/types/customer.js.map +1 -0
- package/lib/module/types/enrollment.js +4 -0
- package/lib/module/types/enrollment.js.map +1 -0
- package/lib/module/types/index.js +21 -0
- package/lib/module/types/index.js.map +1 -0
- package/lib/module/types/inlineCheckout.js +4 -0
- package/lib/module/types/inlineCheckout.js.map +1 -0
- package/lib/module/types/input.js +4 -0
- package/lib/module/types/input.js.map +1 -0
- package/lib/module/types/liteCheckout.js +4 -0
- package/lib/module/types/liteCheckout.js.map +1 -0
- package/lib/module/types/openpay-react-native.d.js +2 -0
- package/lib/module/types/openpay-react-native.d.js.map +1 -0
- package/lib/module/types/openpay.js +2 -0
- package/lib/module/types/openpay.js.map +1 -0
- package/lib/module/types/payment.js +4 -0
- package/lib/module/types/payment.js.map +1 -0
- package/lib/module/types/secure.js +2 -0
- package/lib/module/types/secure.js.map +1 -0
- package/lib/module/types/skyflow-react-native.d.js +2 -0
- package/lib/module/types/skyflow-react-native.d.js.map +1 -0
- package/lib/module/types/threeDSHandler.js +4 -0
- package/lib/module/types/threeDSHandler.js.map +1 -0
- package/lib/module/types/transaction.js +2 -0
- package/lib/module/types/transaction.js.map +1 -0
- package/lib/module/ui/components/Button/ProcessButton.js +44 -0
- package/lib/module/ui/components/Button/ProcessButton.js.map +1 -0
- package/lib/module/ui/components/CardForm/index.js +74 -0
- package/lib/module/ui/components/CardForm/index.js.map +1 -0
- package/lib/module/ui/components/Checkbox/Checkbox.js +56 -0
- package/lib/module/ui/components/Checkbox/Checkbox.js.map +1 -0
- package/lib/module/ui/components/Input/CardCVVInput.js +75 -0
- package/lib/module/ui/components/Input/CardCVVInput.js.map +1 -0
- package/lib/module/ui/components/Input/CardExpirationDateInput.js +84 -0
- package/lib/module/ui/components/Input/CardExpirationDateInput.js.map +1 -0
- package/lib/module/ui/components/Input/CardExpirationMonthInput.js +77 -0
- package/lib/module/ui/components/Input/CardExpirationMonthInput.js.map +1 -0
- package/lib/module/ui/components/Input/CardExpirationYearInput.js +76 -0
- package/lib/module/ui/components/Input/CardExpirationYearInput.js.map +1 -0
- package/lib/module/ui/components/Input/CardHolderInput.js +75 -0
- package/lib/module/ui/components/Input/CardHolderInput.js.map +1 -0
- package/lib/module/ui/components/Input/CardNumberInput.js +75 -0
- package/lib/module/ui/components/Input/CardNumberInput.js.map +1 -0
- package/lib/module/ui/components/PaymentMethodsList/index.js +100 -0
- package/lib/module/ui/components/PaymentMethodsList/index.js.map +1 -0
- package/lib/module/ui/components/RadioButton/index.js +50 -0
- package/lib/module/ui/components/RadioButton/index.js.map +1 -0
- package/lib/module/ui/components/SavedCardsList/index.js +121 -0
- package/lib/module/ui/components/SavedCardsList/index.js.map +1 -0
- package/lib/module/ui/components/Skeleton/CardFormSkeleton.js +97 -0
- package/lib/module/ui/components/Skeleton/CardFormSkeleton.js.map +1 -0
- package/lib/module/ui/components/WebView/ThreeDSWebView.js +96 -0
- package/lib/module/ui/components/WebView/ThreeDSWebView.js.map +1 -0
- package/lib/module/ui/features/TonderEnrollment/index.js +114 -0
- package/lib/module/ui/features/TonderEnrollment/index.js.map +1 -0
- package/lib/module/ui/features/TonderPayment/index.js +188 -0
- package/lib/module/ui/features/TonderPayment/index.js.map +1 -0
- package/lib/module/ui/providers/InnerProvider/index.js +19 -0
- package/lib/module/ui/providers/InnerProvider/index.js.map +1 -0
- package/lib/module/ui/providers/SkyflowContainerWrapper/index.js +24 -0
- package/lib/module/ui/providers/SkyflowContainerWrapper/index.js.map +1 -0
- package/lib/module/ui/providers/TonderProvider/context.js +10 -0
- package/lib/module/ui/providers/TonderProvider/context.js.map +1 -0
- package/lib/module/ui/providers/TonderProvider/hook.js +10 -0
- package/lib/module/ui/providers/TonderProvider/hook.js.map +1 -0
- package/lib/module/ui/providers/TonderProvider/index.js +88 -0
- package/lib/module/ui/providers/TonderProvider/index.js.map +1 -0
- package/lib/module/ui/providers/TonderProvider/uiWrapper.js +57 -0
- package/lib/module/ui/providers/TonderProvider/uiWrapper.js.map +1 -0
- package/lib/module/ui/styles/payment.js +25 -0
- package/lib/module/ui/styles/payment.js.map +1 -0
- package/lib/module/ui/styles/skyflow.js +52 -0
- package/lib/module/ui/styles/skyflow.js.map +1 -0
- package/lib/typescript/commonjs/package.json +1 -0
- package/lib/typescript/commonjs/src/core/3DSHandler.d.ts +23 -0
- package/lib/typescript/commonjs/src/core/3DSHandler.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/BaseCheckout/index.d.ts +28 -0
- package/lib/typescript/commonjs/src/core/BaseCheckout/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/BaseEnrollment/index.d.ts +16 -0
- package/lib/typescript/commonjs/src/core/BaseEnrollment/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/BaseSDK/index.d.ts +19 -0
- package/lib/typescript/commonjs/src/core/BaseSDK/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/EnrollmentContainer/index.d.ts +15 -0
- package/lib/typescript/commonjs/src/core/EnrollmentContainer/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/PaymentInlineContainer/index.d.ts +17 -0
- package/lib/typescript/commonjs/src/core/PaymentInlineContainer/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/PaymentLiteContainer/index.d.ts +21 -0
- package/lib/typescript/commonjs/src/core/PaymentLiteContainer/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/core/Tonder/index.d.ts +33 -0
- package/lib/typescript/commonjs/src/core/Tonder/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/hooks/useTonder/index-old.d.ts +1 -0
- package/lib/typescript/commonjs/src/hooks/useTonder/index-old.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/hooks/useTonder/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/hooks/useTonder/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/index.d.ts +12 -0
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/infrastructure/HttpClient.d.ts +20 -0
- package/lib/typescript/commonjs/src/infrastructure/HttpClient.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/infrastructure/ServiceManager.d.ts +19 -0
- package/lib/typescript/commonjs/src/infrastructure/ServiceManager.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/infrastructure/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/infrastructure/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/BusinessService.d.ts +15 -0
- package/lib/typescript/commonjs/src/services/BusinessService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/CardService.d.ts +28 -0
- package/lib/typescript/commonjs/src/services/CardService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/CheckoutService.d.ts +37 -0
- package/lib/typescript/commonjs/src/services/CheckoutService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/CustomerService.d.ts +24 -0
- package/lib/typescript/commonjs/src/services/CustomerService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/MercadoPagoService.d.ts +4 -0
- package/lib/typescript/commonjs/src/services/MercadoPagoService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/OpenPayService.d.ts +4 -0
- package/lib/typescript/commonjs/src/services/OpenPayService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/PaymentMethodService.d.ts +15 -0
- package/lib/typescript/commonjs/src/services/PaymentMethodService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/SkyflowService.d.ts +15 -0
- package/lib/typescript/commonjs/src/services/SkyflowService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/StorageService.d.ts +7 -0
- package/lib/typescript/commonjs/src/services/StorageService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/TokenService.d.ts +16 -0
- package/lib/typescript/commonjs/src/services/TokenService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/TransactionService.d.ts +8 -0
- package/lib/typescript/commonjs/src/services/TransactionService.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/services/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/services/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/catalog/cardBrandCatalog.d.ts +2 -0
- package/lib/typescript/commonjs/src/shared/catalog/cardBrandCatalog.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/catalog/paymentMethodsCatalog.d.ts +5 -0
- package/lib/typescript/commonjs/src/shared/catalog/paymentMethodsCatalog.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/constants/environments.d.ts +8 -0
- package/lib/typescript/commonjs/src/shared/constants/environments.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/constants/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/shared/constants/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/constants/messages.d.ts +94 -0
- package/lib/typescript/commonjs/src/shared/constants/messages.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/constants/paymentMethods.d.ts +63 -0
- package/lib/typescript/commonjs/src/shared/constants/paymentMethods.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/constants/skyflow.d.ts +38 -0
- package/lib/typescript/commonjs/src/shared/constants/skyflow.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/enum/ErrorKeyEnum.d.ts +48 -0
- package/lib/typescript/commonjs/src/shared/enum/ErrorKeyEnum.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/enum/index.d.ts +2 -0
- package/lib/typescript/commonjs/src/shared/enum/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/shared/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/utils/common.d.ts +9 -0
- package/lib/typescript/commonjs/src/shared/utils/common.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/utils/errors.d.ts +16 -0
- package/lib/typescript/commonjs/src/shared/utils/errors.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/utils/numberUtils.d.ts +2 -0
- package/lib/typescript/commonjs/src/shared/utils/numberUtils.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/utils/paymentMethodUtils.d.ts +2 -0
- package/lib/typescript/commonjs/src/shared/utils/paymentMethodUtils.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/utils/stringUtils.d.ts +2 -0
- package/lib/typescript/commonjs/src/shared/utils/stringUtils.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/shared/utils/styleUtils.d.ts +8 -0
- package/lib/typescript/commonjs/src/shared/utils/styleUtils.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/base.d.ts +48 -0
- package/lib/typescript/commonjs/src/types/base.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/baseCheckout.d.ts +29 -0
- package/lib/typescript/commonjs/src/types/baseCheckout.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/baseEnrollment.d.ts +11 -0
- package/lib/typescript/commonjs/src/types/baseEnrollment.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/baseSDK.d.ts +10 -0
- package/lib/typescript/commonjs/src/types/baseSDK.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/business.d.ts +36 -0
- package/lib/typescript/commonjs/src/types/business.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/card.d.ts +33 -0
- package/lib/typescript/commonjs/src/types/card.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/checkout.d.ts +150 -0
- package/lib/typescript/commonjs/src/types/checkout.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/common.d.ts +60 -0
- package/lib/typescript/commonjs/src/types/common.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/customer.d.ts +28 -0
- package/lib/typescript/commonjs/src/types/customer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/enrollment.d.ts +66 -0
- package/lib/typescript/commonjs/src/types/enrollment.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/index.d.ts +19 -0
- package/lib/typescript/commonjs/src/types/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/inlineCheckout.d.ts +78 -0
- package/lib/typescript/commonjs/src/types/inlineCheckout.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/input.d.ts +13 -0
- package/lib/typescript/commonjs/src/types/input.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/liteCheckout.d.ts +90 -0
- package/lib/typescript/commonjs/src/types/liteCheckout.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/openpay.d.ts +11 -0
- package/lib/typescript/commonjs/src/types/openpay.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/payment.d.ts +59 -0
- package/lib/typescript/commonjs/src/types/payment.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/secure.d.ts +4 -0
- package/lib/typescript/commonjs/src/types/secure.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/threeDSHandler.d.ts +7 -0
- package/lib/typescript/commonjs/src/types/threeDSHandler.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/transaction.d.ts +103 -0
- package/lib/typescript/commonjs/src/types/transaction.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Button/ProcessButton.d.ts +11 -0
- package/lib/typescript/commonjs/src/ui/components/Button/ProcessButton.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/CardForm/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/ui/components/CardForm/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Checkbox/Checkbox.d.ts +9 -0
- package/lib/typescript/commonjs/src/ui/components/Checkbox/Checkbox.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardCVVInput.d.ts +4 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardCVVInput.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardExpirationDateInput.d.ts +10 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardExpirationDateInput.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardExpirationMonthInput.d.ts +4 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardExpirationMonthInput.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardExpirationYearInput.d.ts +4 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardExpirationYearInput.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardHolderInput.d.ts +4 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardHolderInput.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardNumberInput.d.ts +4 -0
- package/lib/typescript/commonjs/src/ui/components/Input/CardNumberInput.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/PaymentMethodsList/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/ui/components/PaymentMethodsList/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/RadioButton/index.d.ts +14 -0
- package/lib/typescript/commonjs/src/ui/components/RadioButton/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/SavedCardsList/index.d.ts +14 -0
- package/lib/typescript/commonjs/src/ui/components/SavedCardsList/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/Skeleton/CardFormSkeleton.d.ts +5 -0
- package/lib/typescript/commonjs/src/ui/components/Skeleton/CardFormSkeleton.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/WebView/ThreeDSWebView.d.ts +9 -0
- package/lib/typescript/commonjs/src/ui/components/WebView/ThreeDSWebView.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/features/TonderEnrollment/index.d.ts +6 -0
- package/lib/typescript/commonjs/src/ui/features/TonderEnrollment/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/features/TonderPayment/index.d.ts +6 -0
- package/lib/typescript/commonjs/src/ui/features/TonderPayment/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/providers/InnerProvider/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/ui/providers/InnerProvider/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/providers/SkyflowContainerWrapper/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/ui/providers/SkyflowContainerWrapper/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/context.d.ts +5 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/hook.d.ts +4 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/hook.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/uiWrapper.d.ts +10 -0
- package/lib/typescript/commonjs/src/ui/providers/TonderProvider/uiWrapper.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/styles/payment.d.ts +20 -0
- package/lib/typescript/commonjs/src/ui/styles/payment.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/styles/skyflow.d.ts +44 -0
- package/lib/typescript/commonjs/src/ui/styles/skyflow.d.ts.map +1 -0
- package/lib/typescript/module/package.json +1 -0
- package/lib/typescript/module/src/core/3DSHandler.d.ts +23 -0
- package/lib/typescript/module/src/core/3DSHandler.d.ts.map +1 -0
- package/lib/typescript/module/src/core/BaseCheckout/index.d.ts +28 -0
- package/lib/typescript/module/src/core/BaseCheckout/index.d.ts.map +1 -0
- package/lib/typescript/module/src/core/BaseEnrollment/index.d.ts +16 -0
- package/lib/typescript/module/src/core/BaseEnrollment/index.d.ts.map +1 -0
- package/lib/typescript/module/src/core/BaseSDK/index.d.ts +19 -0
- package/lib/typescript/module/src/core/BaseSDK/index.d.ts.map +1 -0
- package/lib/typescript/module/src/core/EnrollmentContainer/index.d.ts +15 -0
- package/lib/typescript/module/src/core/EnrollmentContainer/index.d.ts.map +1 -0
- package/lib/typescript/module/src/core/PaymentInlineContainer/index.d.ts +17 -0
- package/lib/typescript/module/src/core/PaymentInlineContainer/index.d.ts.map +1 -0
- package/lib/typescript/module/src/core/PaymentLiteContainer/index.d.ts +21 -0
- package/lib/typescript/module/src/core/PaymentLiteContainer/index.d.ts.map +1 -0
- package/lib/typescript/module/src/core/Tonder/index.d.ts +33 -0
- package/lib/typescript/module/src/core/Tonder/index.d.ts.map +1 -0
- package/lib/typescript/module/src/hooks/useTonder/index-old.d.ts +1 -0
- package/lib/typescript/module/src/hooks/useTonder/index-old.d.ts.map +1 -0
- package/lib/typescript/module/src/hooks/useTonder/index.d.ts +4 -0
- package/lib/typescript/module/src/hooks/useTonder/index.d.ts.map +1 -0
- package/lib/typescript/module/src/index.d.ts +12 -0
- package/lib/typescript/module/src/index.d.ts.map +1 -0
- package/lib/typescript/module/src/infrastructure/HttpClient.d.ts +20 -0
- package/lib/typescript/module/src/infrastructure/HttpClient.d.ts.map +1 -0
- package/lib/typescript/module/src/infrastructure/ServiceManager.d.ts +19 -0
- package/lib/typescript/module/src/infrastructure/ServiceManager.d.ts.map +1 -0
- package/lib/typescript/module/src/infrastructure/index.d.ts +3 -0
- package/lib/typescript/module/src/infrastructure/index.d.ts.map +1 -0
- package/lib/typescript/module/src/services/BusinessService.d.ts +15 -0
- package/lib/typescript/module/src/services/BusinessService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/CardService.d.ts +28 -0
- package/lib/typescript/module/src/services/CardService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/CheckoutService.d.ts +37 -0
- package/lib/typescript/module/src/services/CheckoutService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/CustomerService.d.ts +24 -0
- package/lib/typescript/module/src/services/CustomerService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/MercadoPagoService.d.ts +4 -0
- package/lib/typescript/module/src/services/MercadoPagoService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/OpenPayService.d.ts +4 -0
- package/lib/typescript/module/src/services/OpenPayService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/PaymentMethodService.d.ts +15 -0
- package/lib/typescript/module/src/services/PaymentMethodService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/SkyflowService.d.ts +15 -0
- package/lib/typescript/module/src/services/SkyflowService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/StorageService.d.ts +7 -0
- package/lib/typescript/module/src/services/StorageService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/TokenService.d.ts +16 -0
- package/lib/typescript/module/src/services/TokenService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/TransactionService.d.ts +8 -0
- package/lib/typescript/module/src/services/TransactionService.d.ts.map +1 -0
- package/lib/typescript/module/src/services/index.d.ts +13 -0
- package/lib/typescript/module/src/services/index.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/catalog/cardBrandCatalog.d.ts +2 -0
- package/lib/typescript/module/src/shared/catalog/cardBrandCatalog.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/catalog/paymentMethodsCatalog.d.ts +5 -0
- package/lib/typescript/module/src/shared/catalog/paymentMethodsCatalog.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/constants/environments.d.ts +8 -0
- package/lib/typescript/module/src/shared/constants/environments.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/constants/index.d.ts +3 -0
- package/lib/typescript/module/src/shared/constants/index.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/constants/messages.d.ts +94 -0
- package/lib/typescript/module/src/shared/constants/messages.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/constants/paymentMethods.d.ts +63 -0
- package/lib/typescript/module/src/shared/constants/paymentMethods.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/constants/skyflow.d.ts +38 -0
- package/lib/typescript/module/src/shared/constants/skyflow.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/enum/ErrorKeyEnum.d.ts +48 -0
- package/lib/typescript/module/src/shared/enum/ErrorKeyEnum.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/enum/index.d.ts +2 -0
- package/lib/typescript/module/src/shared/enum/index.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/index.d.ts +4 -0
- package/lib/typescript/module/src/shared/index.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/utils/common.d.ts +9 -0
- package/lib/typescript/module/src/shared/utils/common.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/utils/errors.d.ts +16 -0
- package/lib/typescript/module/src/shared/utils/errors.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/utils/numberUtils.d.ts +2 -0
- package/lib/typescript/module/src/shared/utils/numberUtils.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/utils/paymentMethodUtils.d.ts +2 -0
- package/lib/typescript/module/src/shared/utils/paymentMethodUtils.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/utils/stringUtils.d.ts +2 -0
- package/lib/typescript/module/src/shared/utils/stringUtils.d.ts.map +1 -0
- package/lib/typescript/module/src/shared/utils/styleUtils.d.ts +8 -0
- package/lib/typescript/module/src/shared/utils/styleUtils.d.ts.map +1 -0
- package/lib/typescript/module/src/types/base.d.ts +48 -0
- package/lib/typescript/module/src/types/base.d.ts.map +1 -0
- package/lib/typescript/module/src/types/baseCheckout.d.ts +29 -0
- package/lib/typescript/module/src/types/baseCheckout.d.ts.map +1 -0
- package/lib/typescript/module/src/types/baseEnrollment.d.ts +11 -0
- package/lib/typescript/module/src/types/baseEnrollment.d.ts.map +1 -0
- package/lib/typescript/module/src/types/baseSDK.d.ts +10 -0
- package/lib/typescript/module/src/types/baseSDK.d.ts.map +1 -0
- package/lib/typescript/module/src/types/business.d.ts +36 -0
- package/lib/typescript/module/src/types/business.d.ts.map +1 -0
- package/lib/typescript/module/src/types/card.d.ts +33 -0
- package/lib/typescript/module/src/types/card.d.ts.map +1 -0
- package/lib/typescript/module/src/types/checkout.d.ts +150 -0
- package/lib/typescript/module/src/types/checkout.d.ts.map +1 -0
- package/lib/typescript/module/src/types/common.d.ts +60 -0
- package/lib/typescript/module/src/types/common.d.ts.map +1 -0
- package/lib/typescript/module/src/types/customer.d.ts +28 -0
- package/lib/typescript/module/src/types/customer.d.ts.map +1 -0
- package/lib/typescript/module/src/types/enrollment.d.ts +66 -0
- package/lib/typescript/module/src/types/enrollment.d.ts.map +1 -0
- package/lib/typescript/module/src/types/index.d.ts +19 -0
- package/lib/typescript/module/src/types/index.d.ts.map +1 -0
- package/lib/typescript/module/src/types/inlineCheckout.d.ts +78 -0
- package/lib/typescript/module/src/types/inlineCheckout.d.ts.map +1 -0
- package/lib/typescript/module/src/types/input.d.ts +13 -0
- package/lib/typescript/module/src/types/input.d.ts.map +1 -0
- package/lib/typescript/module/src/types/liteCheckout.d.ts +90 -0
- package/lib/typescript/module/src/types/liteCheckout.d.ts.map +1 -0
- package/lib/typescript/module/src/types/openpay.d.ts +11 -0
- package/lib/typescript/module/src/types/openpay.d.ts.map +1 -0
- package/lib/typescript/module/src/types/payment.d.ts +59 -0
- package/lib/typescript/module/src/types/payment.d.ts.map +1 -0
- package/lib/typescript/module/src/types/secure.d.ts +4 -0
- package/lib/typescript/module/src/types/secure.d.ts.map +1 -0
- package/lib/typescript/module/src/types/threeDSHandler.d.ts +7 -0
- package/lib/typescript/module/src/types/threeDSHandler.d.ts.map +1 -0
- package/lib/typescript/module/src/types/transaction.d.ts +103 -0
- package/lib/typescript/module/src/types/transaction.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Button/ProcessButton.d.ts +11 -0
- package/lib/typescript/module/src/ui/components/Button/ProcessButton.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/CardForm/index.d.ts +13 -0
- package/lib/typescript/module/src/ui/components/CardForm/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Checkbox/Checkbox.d.ts +9 -0
- package/lib/typescript/module/src/ui/components/Checkbox/Checkbox.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Input/CardCVVInput.d.ts +4 -0
- package/lib/typescript/module/src/ui/components/Input/CardCVVInput.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Input/CardExpirationDateInput.d.ts +10 -0
- package/lib/typescript/module/src/ui/components/Input/CardExpirationDateInput.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Input/CardExpirationMonthInput.d.ts +4 -0
- package/lib/typescript/module/src/ui/components/Input/CardExpirationMonthInput.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Input/CardExpirationYearInput.d.ts +4 -0
- package/lib/typescript/module/src/ui/components/Input/CardExpirationYearInput.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Input/CardHolderInput.d.ts +4 -0
- package/lib/typescript/module/src/ui/components/Input/CardHolderInput.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Input/CardNumberInput.d.ts +4 -0
- package/lib/typescript/module/src/ui/components/Input/CardNumberInput.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/PaymentMethodsList/index.d.ts +11 -0
- package/lib/typescript/module/src/ui/components/PaymentMethodsList/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/RadioButton/index.d.ts +14 -0
- package/lib/typescript/module/src/ui/components/RadioButton/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/SavedCardsList/index.d.ts +14 -0
- package/lib/typescript/module/src/ui/components/SavedCardsList/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/Skeleton/CardFormSkeleton.d.ts +5 -0
- package/lib/typescript/module/src/ui/components/Skeleton/CardFormSkeleton.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/WebView/ThreeDSWebView.d.ts +9 -0
- package/lib/typescript/module/src/ui/components/WebView/ThreeDSWebView.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/features/TonderEnrollment/index.d.ts +6 -0
- package/lib/typescript/module/src/ui/features/TonderEnrollment/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/features/TonderPayment/index.d.ts +6 -0
- package/lib/typescript/module/src/ui/features/TonderPayment/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/providers/InnerProvider/index.d.ts +10 -0
- package/lib/typescript/module/src/ui/providers/InnerProvider/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/providers/SkyflowContainerWrapper/index.d.ts +10 -0
- package/lib/typescript/module/src/ui/providers/SkyflowContainerWrapper/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/context.d.ts +5 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/context.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/hook.d.ts +4 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/hook.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/index.d.ts +8 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/uiWrapper.d.ts +10 -0
- package/lib/typescript/module/src/ui/providers/TonderProvider/uiWrapper.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/styles/payment.d.ts +20 -0
- package/lib/typescript/module/src/ui/styles/payment.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/styles/skyflow.d.ts +44 -0
- package/lib/typescript/module/src/ui/styles/skyflow.d.ts.map +1 -0
- package/package.json +206 -0
- package/src/core/3DSHandler.ts +140 -0
- package/src/core/BaseCheckout/index.ts +420 -0
- package/src/core/BaseEnrollment/index.ts +99 -0
- package/src/core/BaseSDK/index.ts +93 -0
- package/src/core/EnrollmentContainer/index.ts +105 -0
- package/src/core/PaymentInlineContainer/index.ts +127 -0
- package/src/core/PaymentLiteContainer/index.ts +201 -0
- package/src/core/Tonder/index.ts +147 -0
- package/src/hooks/useTonder/index-old.ts +35 -0
- package/src/hooks/useTonder/index.ts +10 -0
- package/src/index.tsx +11 -0
- package/src/infrastructure/HttpClient.ts +121 -0
- package/src/infrastructure/ServiceManager.ts +54 -0
- package/src/infrastructure/index.ts +2 -0
- package/src/services/BusinessService.ts +33 -0
- package/src/services/CardService.ts +118 -0
- package/src/services/CheckoutService.ts +135 -0
- package/src/services/CustomerService.ts +59 -0
- package/src/services/MercadoPagoService.ts +19 -0
- package/src/services/OpenPayService.ts +22 -0
- package/src/services/PaymentMethodService.ts +38 -0
- package/src/services/SkyflowService.ts +50 -0
- package/src/services/StorageService.ts +56 -0
- package/src/services/TokenService.ts +45 -0
- package/src/services/TransactionService.ts +23 -0
- package/src/services/index.ts +12 -0
- package/src/shared/catalog/cardBrandCatalog.ts +16 -0
- package/src/shared/catalog/paymentMethodsCatalog.ts +252 -0
- package/src/shared/constants/environments.ts +8 -0
- package/src/shared/constants/index.ts +2 -0
- package/src/shared/constants/messages.ts +119 -0
- package/src/shared/constants/paymentMethods.ts +63 -0
- package/src/shared/constants/skyflow.ts +60 -0
- package/src/shared/enum/ErrorKeyEnum.ts +47 -0
- package/src/shared/enum/index.ts +1 -0
- package/src/shared/index.ts +3 -0
- package/src/shared/utils/common.ts +46 -0
- package/src/shared/utils/errors.ts +25 -0
- package/src/shared/utils/numberUtils.ts +10 -0
- package/src/shared/utils/paymentMethodUtils.ts +17 -0
- package/src/shared/utils/stringUtils.ts +3 -0
- package/src/shared/utils/styleUtils.ts +11 -0
- package/src/types/base.ts +79 -0
- package/src/types/baseCheckout.ts +42 -0
- package/src/types/baseEnrollment.ts +17 -0
- package/src/types/baseSDK.ts +10 -0
- package/src/types/business.ts +34 -0
- package/src/types/card.ts +38 -0
- package/src/types/checkout.ts +157 -0
- package/src/types/common.ts +68 -0
- package/src/types/customer.ts +29 -0
- package/src/types/enrollment.ts +70 -0
- package/src/types/index.ts +18 -0
- package/src/types/inlineCheckout.ts +96 -0
- package/src/types/input.ts +17 -0
- package/src/types/liteCheckout.ts +108 -0
- package/src/types/openpay-react-native.d.ts +3 -0
- package/src/types/openpay.ts +8 -0
- package/src/types/payment.ts +66 -0
- package/src/types/secure.ts +3 -0
- package/src/types/skyflow-react-native.d.ts +81 -0
- package/src/types/threeDSHandler.ts +10 -0
- package/src/types/transaction.ts +106 -0
- package/src/ui/components/Button/ProcessButton.tsx +57 -0
- package/src/ui/components/CardForm/index.tsx +91 -0
- package/src/ui/components/Checkbox/Checkbox.tsx +56 -0
- package/src/ui/components/Input/CardCVVInput.tsx +91 -0
- package/src/ui/components/Input/CardExpirationDateInput.tsx +95 -0
- package/src/ui/components/Input/CardExpirationMonthInput.tsx +90 -0
- package/src/ui/components/Input/CardExpirationYearInput.tsx +91 -0
- package/src/ui/components/Input/CardHolderInput.tsx +91 -0
- package/src/ui/components/Input/CardNumberInput.tsx +90 -0
- package/src/ui/components/PaymentMethodsList/index.tsx +103 -0
- package/src/ui/components/RadioButton/index.tsx +57 -0
- package/src/ui/components/SavedCardsList/index.tsx +137 -0
- package/src/ui/components/Skeleton/CardFormSkeleton.tsx +109 -0
- package/src/ui/components/WebView/ThreeDSWebView.tsx +110 -0
- package/src/ui/features/TonderEnrollment/index.tsx +141 -0
- package/src/ui/features/TonderPayment/index.tsx +243 -0
- package/src/ui/providers/InnerProvider/index.tsx +24 -0
- package/src/ui/providers/SkyflowContainerWrapper/index.tsx +35 -0
- package/src/ui/providers/TonderProvider/context.tsx +11 -0
- package/src/ui/providers/TonderProvider/hook.ts +10 -0
- package/src/ui/providers/TonderProvider/index.tsx +110 -0
- package/src/ui/providers/TonderProvider/uiWrapper.ts +67 -0
- package/src/ui/styles/payment.ts +23 -0
- package/src/ui/styles/skyflow.ts +58 -0
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
// @ts-nocheck
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import { DEFAULT_SKYFLOW_lABELS, DEFAULT_SKYFLOW_PLACEHOLDERS } from '@shared/constants/skyflow';
|
|
6
|
+
import { StyleSheet, Text, View } from 'react-native';
|
|
7
|
+
import { DEFAULT_SKYFLOW_INPUT_STYLES, DEFAULT_SKYFLOW_lABEL_STYLES } from '@ui/styles/skyflow';
|
|
8
|
+
import { DEFAULT_INPUT_CONTAINER_STYLES } from '@ui/styles/payment';
|
|
9
|
+
import { CardExpirationMonthInput } from '@ui/components/Input/CardExpirationMonthInput';
|
|
10
|
+
import { CardExpirationYearInput } from '@ui/components/Input/CardExpirationYearInput';
|
|
11
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
|
+
export const CardExpirationDateInput = ({
|
|
13
|
+
yearPlaceholder = DEFAULT_SKYFLOW_PLACEHOLDERS.expiryYearPlaceholder,
|
|
14
|
+
monthPlaceholder = DEFAULT_SKYFLOW_PLACEHOLDERS.expiryMonthPlaceholder,
|
|
15
|
+
label = DEFAULT_SKYFLOW_lABELS.expiryDateLabel,
|
|
16
|
+
style
|
|
17
|
+
}) => {
|
|
18
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
19
|
+
style: styles.container,
|
|
20
|
+
children: [/*#__PURE__*/_jsx(Text, {
|
|
21
|
+
style: {
|
|
22
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES.base,
|
|
23
|
+
...(style?.labelStyles?.base || {})
|
|
24
|
+
},
|
|
25
|
+
children: label
|
|
26
|
+
}), /*#__PURE__*/_jsxs(View, {
|
|
27
|
+
style: styles.row,
|
|
28
|
+
children: [/*#__PURE__*/_jsx(CardExpirationMonthInput, {
|
|
29
|
+
label: '',
|
|
30
|
+
placeholder: monthPlaceholder,
|
|
31
|
+
style: {
|
|
32
|
+
...{
|
|
33
|
+
...style,
|
|
34
|
+
inputStyles: {
|
|
35
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES,
|
|
36
|
+
...(style?.inputStyles || {}),
|
|
37
|
+
container: {
|
|
38
|
+
...DEFAULT_INPUT_CONTAINER_STYLES.base,
|
|
39
|
+
...{
|
|
40
|
+
marginVertical: 0
|
|
41
|
+
},
|
|
42
|
+
...(style?.inputStyles?.container || {})
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}), /*#__PURE__*/_jsx(CardExpirationYearInput, {
|
|
48
|
+
label: '',
|
|
49
|
+
placeholder: yearPlaceholder,
|
|
50
|
+
style: {
|
|
51
|
+
...{
|
|
52
|
+
...style,
|
|
53
|
+
inputStyles: {
|
|
54
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES,
|
|
55
|
+
...(style?.inputStyles || {}),
|
|
56
|
+
container: {
|
|
57
|
+
...DEFAULT_INPUT_CONTAINER_STYLES.base,
|
|
58
|
+
...{
|
|
59
|
+
marginVertical: 0
|
|
60
|
+
},
|
|
61
|
+
...(style?.inputStyles?.container || {})
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
})]
|
|
67
|
+
})]
|
|
68
|
+
});
|
|
69
|
+
};
|
|
70
|
+
const styles = StyleSheet.create({
|
|
71
|
+
container: {
|
|
72
|
+
flex: 2,
|
|
73
|
+
marginVertical: 5
|
|
74
|
+
},
|
|
75
|
+
row: {
|
|
76
|
+
flexDirection: 'row',
|
|
77
|
+
justifyContent: 'space-between',
|
|
78
|
+
gap: 10
|
|
79
|
+
},
|
|
80
|
+
inputContainerCustom: {
|
|
81
|
+
flex: 1
|
|
82
|
+
}
|
|
83
|
+
});
|
|
84
|
+
//# sourceMappingURL=CardExpirationDateInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","DEFAULT_SKYFLOW_lABELS","DEFAULT_SKYFLOW_PLACEHOLDERS","StyleSheet","Text","View","DEFAULT_SKYFLOW_INPUT_STYLES","DEFAULT_SKYFLOW_lABEL_STYLES","DEFAULT_INPUT_CONTAINER_STYLES","CardExpirationMonthInput","CardExpirationYearInput","jsx","_jsx","jsxs","_jsxs","CardExpirationDateInput","yearPlaceholder","expiryYearPlaceholder","monthPlaceholder","expiryMonthPlaceholder","label","expiryDateLabel","style","styles","container","children","base","labelStyles","row","placeholder","inputStyles","marginVertical","create","flex","flexDirection","justifyContent","gap","inputContainerCustom"],"sourceRoot":"../../../../../src","sources":["ui/components/Input/CardExpirationDateInput.tsx"],"mappings":";;AAAA;AACA,OAAOA,KAAK,MAAM,OAAO;AAEzB,SACEC,sBAAsB,EACtBC,4BAA4B,QACvB,2BAA2B;AAClC,SAASC,UAAU,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AAErD,SACEC,4BAA4B,EAC5BC,4BAA4B,QACvB,oBAAoB;AAC3B,SAASC,8BAA8B,QAAQ,oBAAoB;AACnE,SAASC,w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AGA,KAAK;YACRQ,WAAW,EAAE;cACX,GAAGxB,4BAA4B;cAC/B,IAAIgB,KAAK,EAAEQ,WAAW,IAAI,CAAC,CAAC,CAAC;cAC7BN,SAAS,EAAE;gBACT,GAAGhB,8BAA8B,CAACkB,IAAI;gBACtC,GAAG;kBAAEK,cAAc,EAAE;gBAAE,CAAC;gBACxB,IAAIT,KAAK,EAAEQ,WAAW,EAAEN,SAAS,IAAI,CAAC,CAAC;cACzC;YACF;UACF;QACF;MAAE,CACH,CAAC;IAAA,CACE,CAAC;EAAA,CACH,CAAC;AAEX,CAAC;AAED,MAAMD,MAAM,GAAGpB,UAAU,CAAC6B,MAAM,CAAC;EAC/BR,SAAS,EAAE;IACTS,IAAI,EAAE,CAAC;IACPF,cAAc,EAAE;EAClB,CAAC;EACDH,GAAG,EAAE;IACHM,aAAa,EAAE,KAAK;IACpBC,cAAc,EAAE,eAAe;IAC/BC,GAAG,EAAE;EACP,CAAC;EACDC,oBAAoB,EAAE;IACpBJ,IAAI,EAAE;EACR;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { useState } from 'react';
|
|
4
|
+
import { ExpirationMonthElement } from 'skyflow-react-native';
|
|
5
|
+
import { getErrorField, regexMatchRule } from '@shared/constants/skyflow';
|
|
6
|
+
import { DEFAULT_SKYFLOW_lABELS, DEFAULT_SKYFLOW_PLACEHOLDERS } from '@shared/constants/skyflow';
|
|
7
|
+
import { Text, View } from 'react-native';
|
|
8
|
+
import { DEFAULT_INPUT_CONTAINER_STYLES } from '@ui/styles/payment';
|
|
9
|
+
import { DEFAULT_SKYFLOW_ERROR_TEXT_STYLES, DEFAULT_SKYFLOW_INPUT_STYLES, DEFAULT_SKYFLOW_lABEL_STYLES, SKYFLOW_HIDDEN_ERROR_TEXT_STYLES } from '@ui/styles/skyflow';
|
|
10
|
+
import useTonderContext from '@ui/providers/TonderProvider/hook';
|
|
11
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
12
|
+
export const CardExpirationMonthInput = ({
|
|
13
|
+
placeholder = DEFAULT_SKYFLOW_PLACEHOLDERS.expiryMonthPlaceholder,
|
|
14
|
+
label = DEFAULT_SKYFLOW_lABELS.expiryMonthLabel,
|
|
15
|
+
style
|
|
16
|
+
}) => {
|
|
17
|
+
const {
|
|
18
|
+
state
|
|
19
|
+
} = useTonderContext();
|
|
20
|
+
const [errorText, setErrorText] = useState('');
|
|
21
|
+
return /*#__PURE__*/_jsx(_Fragment, {
|
|
22
|
+
children: state?.skyflowContainer && state?.isCreated && !state?.isCreating && /*#__PURE__*/_jsxs(View, {
|
|
23
|
+
style: {
|
|
24
|
+
...(style?.inputStyles?.container ? {
|
|
25
|
+
...style.inputStyles.container
|
|
26
|
+
} : DEFAULT_INPUT_CONTAINER_STYLES.base)
|
|
27
|
+
},
|
|
28
|
+
children: [/*#__PURE__*/_jsx(ExpirationMonthElement, {
|
|
29
|
+
container: state.skyflowContainer,
|
|
30
|
+
table: "cards",
|
|
31
|
+
column: "expiration_month",
|
|
32
|
+
options: {},
|
|
33
|
+
placeholder: placeholder,
|
|
34
|
+
label: label,
|
|
35
|
+
validations: [regexMatchRule],
|
|
36
|
+
inputStyles: {
|
|
37
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES,
|
|
38
|
+
...(style?.inputStyles ? {
|
|
39
|
+
...style?.inputStyles,
|
|
40
|
+
base: {
|
|
41
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES.base,
|
|
42
|
+
...style?.inputStyles.base
|
|
43
|
+
}
|
|
44
|
+
} : {})
|
|
45
|
+
},
|
|
46
|
+
errorTextStyles: {
|
|
47
|
+
...SKYFLOW_HIDDEN_ERROR_TEXT_STYLES
|
|
48
|
+
},
|
|
49
|
+
labelStyles: {
|
|
50
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES,
|
|
51
|
+
...(style?.labelStyles ? {
|
|
52
|
+
...style?.labelStyles,
|
|
53
|
+
base: {
|
|
54
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES.base,
|
|
55
|
+
...style?.labelStyles.base
|
|
56
|
+
}
|
|
57
|
+
} : {})
|
|
58
|
+
},
|
|
59
|
+
onChange: () => {
|
|
60
|
+
setErrorText('');
|
|
61
|
+
}
|
|
62
|
+
// onFocus={props.onFocus}
|
|
63
|
+
,
|
|
64
|
+
onBlur: e => {
|
|
65
|
+
setErrorText(getErrorField(e, label));
|
|
66
|
+
}
|
|
67
|
+
// onReady={props.onReady}
|
|
68
|
+
}), errorText && /*#__PURE__*/_jsx(Text, {
|
|
69
|
+
style: {
|
|
70
|
+
...DEFAULT_SKYFLOW_ERROR_TEXT_STYLES.base
|
|
71
|
+
},
|
|
72
|
+
children: errorText
|
|
73
|
+
})]
|
|
74
|
+
})
|
|
75
|
+
});
|
|
76
|
+
};
|
|
77
|
+
//# sourceMappingURL=CardExpirationMonthInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useState","ExpirationMonthElement","getErrorField","regexMatchRule","DEFAULT_SKYFLOW_lABELS","DEFAULT_SKYFLOW_PLACEHOLDERS","Text","View","DEFAULT_INPUT_CONTAINER_STYLES","DEFAULT_SKYFLOW_ERROR_TEXT_STYLES","DEFAULT_SKYFLOW_INPUT_STYLES","DEFAULT_SKYFLOW_lABEL_STYLES","SKYFLOW_HIDDEN_ERROR_TEXT_STYLES","useTonderContext","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","CardExpirationMonthInput","placeholder","expiryMonthPlaceholder","label","expiryMonthLabel","style","state","errorText","setErrorText","children","skyflowContainer","isCreated","isCreating","inputStyles","container","base","table","column","options","validations","errorTextStyles","labelStyles","onChange","onBlur","e"],"sourceRoot":"../../../../../src","sources":["ui/components/Input/CardExpirationMonthInput.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,QAAQ,QAAQ,OAAO;AAEvC,SAASC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E,KAAK,EAAEA,KAAM;QACbgB,WAAW,EAAE,CAACpC,cAAc,CAAE;QAC9B8B,WAAW,EAAE;UACX,GAAGvB,4BAA4B;UAC/B,IAAIe,KAAK,EAAEQ,WAAW,GAClB;YACE,GAAGR,KAAK,EAAEQ,WAAW;YACrBE,IAAI,EAAE;cACJ,GAAGzB,4BAA4B,CAACyB,IAAI;cACpC,GAAGV,KAAK,EAAEQ,WAAW,CAACE;YACxB;UACF,CAAC,GACD,CAAC,CAAC;QACR,CAAE;QACFK,eAAe,EAAE;UACf,GAAG5B;QACL,CAAE;QACF6B,WAAW,EAAE;UACX,GAAG9B,4BAA4B;UAC/B,IAAIc,KAAK,EAAEgB,WAAW,GAClB;YACE,GAAGhB,KAAK,EAAEgB,WAAW;YACrBN,IAAI,EAAE;cACJ,GAAGxB,4BAA4B,CAACwB,IAAI;cACpC,GAAGV,KAAK,EAAEgB,WAAW,CAACN;YACxB;UACF,CAAC,GACD,CAAC,CAAC;QACR,CAAE;QACFO,QAAQ,EAAEA,CAAA,KAAM;UACdd,YAAY,CAAC,EAAE,CAAC;QAClB;QACA;QAAA;QACAe,MAAM,EAAGC,CAAC,IAAK;UACbhB,YAAY,CAAC1B,aAAa,CAAC0C,CAAC,EAAErB,KAAK,CAAC,CAAC;QACvC;QACA;MAAA,CACD,CAAC,EACDI,SAAS,iBACRZ,IAAA,CAACT,IAAI;QAACmB,KAAK,EAAE;UAAE,GAAGhB,iCAAiC,CAAC0B;QAAK,CAAE;QAAAN,QAAA,EACxDF;MAAS,CACN,CACP;IAAA,CACG;EACP,CACD,CAAC;AAEP,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { useState } from 'react';
|
|
4
|
+
import { ExpirationYearElement } from 'skyflow-react-native';
|
|
5
|
+
import { getErrorField, regexMatchRule, DEFAULT_SKYFLOW_lABELS, DEFAULT_SKYFLOW_PLACEHOLDERS } from '@shared/constants/skyflow';
|
|
6
|
+
import { Text, View } from 'react-native';
|
|
7
|
+
import { DEFAULT_INPUT_CONTAINER_STYLES } from '@ui/styles/payment';
|
|
8
|
+
import { DEFAULT_SKYFLOW_ERROR_TEXT_STYLES, DEFAULT_SKYFLOW_INPUT_STYLES, DEFAULT_SKYFLOW_lABEL_STYLES, SKYFLOW_HIDDEN_ERROR_TEXT_STYLES } from '@ui/styles/skyflow';
|
|
9
|
+
import useTonderContext from '@ui/providers/TonderProvider/hook';
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
11
|
+
export const CardExpirationYearInput = ({
|
|
12
|
+
placeholder = DEFAULT_SKYFLOW_PLACEHOLDERS.expiryYearPlaceholder,
|
|
13
|
+
label = DEFAULT_SKYFLOW_lABELS.expiryYearLabel,
|
|
14
|
+
style
|
|
15
|
+
}) => {
|
|
16
|
+
const {
|
|
17
|
+
state
|
|
18
|
+
} = useTonderContext();
|
|
19
|
+
const [errorText, setErrorText] = useState('');
|
|
20
|
+
return /*#__PURE__*/_jsx(_Fragment, {
|
|
21
|
+
children: state?.skyflowContainer && state?.isCreated && !state?.isCreating && /*#__PURE__*/_jsxs(View, {
|
|
22
|
+
style: {
|
|
23
|
+
...(style?.inputStyles?.container ? {
|
|
24
|
+
...style.inputStyles.container
|
|
25
|
+
} : DEFAULT_INPUT_CONTAINER_STYLES.base)
|
|
26
|
+
},
|
|
27
|
+
children: [/*#__PURE__*/_jsx(ExpirationYearElement, {
|
|
28
|
+
container: state.skyflowContainer,
|
|
29
|
+
table: "cards",
|
|
30
|
+
column: "expiration_year",
|
|
31
|
+
options: {},
|
|
32
|
+
placeholder: placeholder,
|
|
33
|
+
label: label,
|
|
34
|
+
validations: [regexMatchRule],
|
|
35
|
+
inputStyles: {
|
|
36
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES,
|
|
37
|
+
...(style?.inputStyles ? {
|
|
38
|
+
...style?.inputStyles,
|
|
39
|
+
base: {
|
|
40
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES.base,
|
|
41
|
+
...style?.inputStyles.base
|
|
42
|
+
}
|
|
43
|
+
} : {})
|
|
44
|
+
},
|
|
45
|
+
errorTextStyles: {
|
|
46
|
+
...SKYFLOW_HIDDEN_ERROR_TEXT_STYLES
|
|
47
|
+
},
|
|
48
|
+
labelStyles: {
|
|
49
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES,
|
|
50
|
+
...(style?.labelStyles ? {
|
|
51
|
+
...style?.labelStyles,
|
|
52
|
+
base: {
|
|
53
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES.base,
|
|
54
|
+
...style?.labelStyles.base
|
|
55
|
+
}
|
|
56
|
+
} : {})
|
|
57
|
+
},
|
|
58
|
+
onChange: () => {
|
|
59
|
+
setErrorText('');
|
|
60
|
+
}
|
|
61
|
+
// onFocus={props.onFocus}
|
|
62
|
+
,
|
|
63
|
+
onBlur: e => {
|
|
64
|
+
setErrorText(getErrorField(e, label));
|
|
65
|
+
}
|
|
66
|
+
// onReady={props.onReady}
|
|
67
|
+
}), errorText && /*#__PURE__*/_jsx(Text, {
|
|
68
|
+
style: {
|
|
69
|
+
...DEFAULT_SKYFLOW_ERROR_TEXT_STYLES.base
|
|
70
|
+
},
|
|
71
|
+
children: errorText
|
|
72
|
+
})]
|
|
73
|
+
})
|
|
74
|
+
});
|
|
75
|
+
};
|
|
76
|
+
//# sourceMappingURL=CardExpirationYearInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useState","ExpirationYearElement","getErrorField","regexMatchRule","DEFAULT_SKYFLOW_lABELS","DEFAULT_SKYFLOW_PLACEHOLDERS","Text","View","DEFAULT_INPUT_CONTAINER_STYLES","DEFAULT_SKYFLOW_ERROR_TEXT_STYLES","DEFAULT_SKYFLOW_INPUT_STYLES","DEFAULT_SKYFLOW_lABEL_STYLES","SKYFLOW_HIDDEN_ERROR_TEXT_STYLES","useTonderContext","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","CardExpirationYearInput","placeholder","expiryYearPlaceholder","label","expiryYearLabel","style","state","errorText","setErrorText","children","skyflowContainer","isCreated","isCreating","inputStyles","container","base","table","column","options","validations","errorTextStyles","labelStyles","onChange","onBlur","e"],"sourceRoot":"../../../../../src","sources":["ui/components/Input/CardExpirationYearInput.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,QAAQ,QAAQ,OAAO;AAEvC,SAASC,qBAAqB,QAAQ,sBAAsB;AAC5D,SACEC,aAAa,EACbC,cAAc,EACdC,sBAAsB,EACtBC,4BAA4B,QACvB,2BAA2B;AAClC,SAASC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzC,SAASC,8BAA8B,QAAQ,oBAAoB;AACnE,SACEC,iCAAiC,EACjCC,4BAA4B,EAC5BC,4BAA4B,EAC5BC,gCAAgC,QAC3B,oBAAoB;AAC3B,OAAOC,gBAAgB,MAAM,mCAAmC;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAEjE,OAAO,MAAMC,uBAA6C,GAAGA,CAAC;EAC5DC,WAAW,GAAGhB,4BAA4B,CAACiB,qBAAqB;EAChEC,KAAK,GAAGnB,sBAAsB,CAACoB,eAAe;EAC9CC;AACF,CAAC,KAAK;EACJ,MAAM;IAAEC;EAAM,CAAC,GAAGb,gBAAgB,CAAC,CAAC;EACpC,MAAM,CAACc,SAAS,EAAEC,YAAY,CAAC,GAAG5B,QAAQ,CAAC,EAAE,CAAC;EAE9C,oBACEe,IAAA,CAAAI,SAAA;IAAAU,QAAA,EACGH,KAAK,EAAEI,gBAAgB,IAAIJ,KAAK,EAAEK,SAAS,IAAI,CAACL,KAAK,EAAEM,UAAU,iBAChEf,KAAA,CAACV,IAAI;MACHkB,KAAK,EAAE;QACL,IAAIA,KAAK,EAAEQ,WAAW,EAAEC,SAAS,GAC7B;UAAE,GAAGT,KAAK,C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,CACG;EACP,CACD,CAAC;AAEP,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { useState } from 'react';
|
|
4
|
+
import { getErrorField, lengthMatchRule, regexMatchRule, DEFAULT_SKYFLOW_lABELS, DEFAULT_SKYFLOW_PLACEHOLDERS } from '@shared/constants/skyflow';
|
|
5
|
+
import { Text, View } from 'react-native';
|
|
6
|
+
import { CardHolderNameElement } from 'skyflow-react-native';
|
|
7
|
+
import { DEFAULT_SKYFLOW_ERROR_TEXT_STYLES, DEFAULT_SKYFLOW_INPUT_STYLES, DEFAULT_SKYFLOW_lABEL_STYLES, SKYFLOW_HIDDEN_ERROR_TEXT_STYLES } from '@ui/styles/skyflow';
|
|
8
|
+
import { DEFAULT_INPUT_CONTAINER_STYLES } from '@ui/styles/payment';
|
|
9
|
+
import useTonderContext from '@ui/providers/TonderProvider/hook';
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
11
|
+
export const CardHolderInput = ({
|
|
12
|
+
placeholder = DEFAULT_SKYFLOW_PLACEHOLDERS.namePlaceholder,
|
|
13
|
+
label = DEFAULT_SKYFLOW_lABELS.nameLabel,
|
|
14
|
+
style
|
|
15
|
+
}) => {
|
|
16
|
+
const {
|
|
17
|
+
state
|
|
18
|
+
} = useTonderContext();
|
|
19
|
+
const [errorText, setErrorText] = useState('');
|
|
20
|
+
return /*#__PURE__*/_jsx(_Fragment, {
|
|
21
|
+
children: state?.skyflowContainer && state?.isCreated && !state?.isCreating && /*#__PURE__*/_jsxs(View, {
|
|
22
|
+
style: {
|
|
23
|
+
...(style?.inputStyles?.container ? {
|
|
24
|
+
...style.inputStyles.container
|
|
25
|
+
} : DEFAULT_INPUT_CONTAINER_STYLES.base)
|
|
26
|
+
},
|
|
27
|
+
children: [/*#__PURE__*/_jsx(CardHolderNameElement, {
|
|
28
|
+
container: state.skyflowContainer,
|
|
29
|
+
table: "cards",
|
|
30
|
+
column: "cardholder_name",
|
|
31
|
+
validations: [lengthMatchRule, regexMatchRule],
|
|
32
|
+
placeholder: placeholder,
|
|
33
|
+
label: label,
|
|
34
|
+
inputStyles: {
|
|
35
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES,
|
|
36
|
+
...(style?.inputStyles ? {
|
|
37
|
+
...style?.inputStyles,
|
|
38
|
+
base: {
|
|
39
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES.base,
|
|
40
|
+
...style?.inputStyles.base
|
|
41
|
+
}
|
|
42
|
+
} : {})
|
|
43
|
+
},
|
|
44
|
+
errorTextStyles: {
|
|
45
|
+
...SKYFLOW_HIDDEN_ERROR_TEXT_STYLES
|
|
46
|
+
},
|
|
47
|
+
labelStyles: {
|
|
48
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES,
|
|
49
|
+
...(style?.labelStyles ? {
|
|
50
|
+
...style?.labelStyles,
|
|
51
|
+
base: {
|
|
52
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES.base,
|
|
53
|
+
...style?.labelStyles.base
|
|
54
|
+
}
|
|
55
|
+
} : {})
|
|
56
|
+
},
|
|
57
|
+
onChange: () => {
|
|
58
|
+
setErrorText('');
|
|
59
|
+
}
|
|
60
|
+
// onFocus={props.onFocus}
|
|
61
|
+
,
|
|
62
|
+
onBlur: e => {
|
|
63
|
+
setErrorText(getErrorField(e, label));
|
|
64
|
+
}
|
|
65
|
+
// onReady={props.onReady}
|
|
66
|
+
}), errorText && /*#__PURE__*/_jsx(Text, {
|
|
67
|
+
style: {
|
|
68
|
+
...DEFAULT_SKYFLOW_ERROR_TEXT_STYLES.base
|
|
69
|
+
},
|
|
70
|
+
children: errorText
|
|
71
|
+
})]
|
|
72
|
+
})
|
|
73
|
+
});
|
|
74
|
+
};
|
|
75
|
+
//# sourceMappingURL=CardHolderInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useState","getErrorField","lengthMatchRule","regexMatchRule","DEFAULT_SKYFLOW_lABELS","DEFAULT_SKYFLOW_PLACEHOLDERS","Text","View","CardHolderNameElement","DEFAULT_SKYFLOW_ERROR_TEXT_STYLES","DEFAULT_SKYFLOW_INPUT_STYLES","DEFAULT_SKYFLOW_lABEL_STYLES","SKYFLOW_HIDDEN_ERROR_TEXT_STYLES","DEFAULT_INPUT_CONTAINER_STYLES","useTonderContext","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","CardHolderInput","placeholder","namePlaceholder","label","nameLabel","style","state","errorText","setErrorText","children","skyflowContainer","isCreated","isCreating","inputStyles","container","base","table","column","validations","errorTextStyles","labelStyles","onChange","onBlur","e"],"sourceRoot":"../../../../../src","sources":["ui/components/Input/CardHolderInput.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,QAAQ,QAAQ,OAAO;AAEvC,SACEC,aAAa,EACbC,eAAe,EACfC,cAAc,EACdC,sBAAsB,EACtBC,4BAA4B,QACvB,2BAA2B;AAClC,SAASC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzC,SAASC,qBAAqB,QAAQ,sBAAsB;AAC5D,SACEC,iCAAiC,EACjCC,4BAA4B,EAC5BC,4BAA4B,EAC5BC,gCAAgC,QAC3B,oBAAoB;AAC3B,SAASC,8BAA8B,QAAQ,oBAAoB;AACnE,OAAOC,gBAAgB,MAAM,mCAAmC;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAEjE,OAAO,MAAMC,eAAqC,GAAGA,CAAC;EACpDC,WAAW,GAAGjB,4BAA4B,CAACkB,eAAe;EAC1DC,KAAK,GAAGpB,sBAAsB,CAACqB,SAAS;EACxCC;AACF,CAAC,KAAK;EACJ,MAAM;IAAEC;EAAM,CAAC,GAAGb,gBAAgB,CAAC,CAAC;EAEpC,MAAM,CAACc,SAAS,EAAEC,YAAY,CAAC,GAAG7B,QAAQ,CAAC,EAA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K;UACbf,YAAY,CAAC5B,aAAa,CAAC2C,CAAC,EAAEpB,KAAK,CAAC,CAAC;QACvC;QACA;MAAA,CACD,CAAC,EACDI,SAAS,iBACRZ,IAAA,CAACV,IAAI;QAACoB,KAAK,EAAE;UAAE,GAAGjB,iCAAiC,CAAC2B;QAAK,CAAE;QAAAN,QAAA,EACxDF;MAAS,CACN,CACP;IAAA,CACG;EACP,CACD,CAAC;AAEP,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { useState } from 'react';
|
|
4
|
+
import { CardNumberElement } from 'skyflow-react-native';
|
|
5
|
+
import { getErrorField, regexMatchRule, DEFAULT_SKYFLOW_lABELS, DEFAULT_SKYFLOW_PLACEHOLDERS } from '@shared/constants/skyflow';
|
|
6
|
+
import { Text, View } from 'react-native';
|
|
7
|
+
import { DEFAULT_INPUT_CONTAINER_STYLES } from '@ui/styles/payment';
|
|
8
|
+
import { DEFAULT_SKYFLOW_ERROR_TEXT_STYLES, DEFAULT_SKYFLOW_INPUT_STYLES, DEFAULT_SKYFLOW_lABEL_STYLES, SKYFLOW_HIDDEN_ERROR_TEXT_STYLES } from '@ui/styles/skyflow';
|
|
9
|
+
import useTonderContext from '@ui/providers/TonderProvider/hook';
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
11
|
+
export const CardNumberInput = ({
|
|
12
|
+
placeholder = DEFAULT_SKYFLOW_PLACEHOLDERS.cardPlaceholder,
|
|
13
|
+
label = DEFAULT_SKYFLOW_lABELS.cardLabel,
|
|
14
|
+
style
|
|
15
|
+
}) => {
|
|
16
|
+
const {
|
|
17
|
+
state
|
|
18
|
+
} = useTonderContext();
|
|
19
|
+
const [errorText, setErrorText] = useState('');
|
|
20
|
+
return /*#__PURE__*/_jsx(_Fragment, {
|
|
21
|
+
children: state?.skyflowContainer && state?.isCreated && !state?.isCreating && /*#__PURE__*/_jsxs(View, {
|
|
22
|
+
style: {
|
|
23
|
+
...(style?.inputStyles?.container ? {
|
|
24
|
+
...style.inputStyles.container
|
|
25
|
+
} : DEFAULT_INPUT_CONTAINER_STYLES.base)
|
|
26
|
+
},
|
|
27
|
+
children: [/*#__PURE__*/_jsx(CardNumberElement, {
|
|
28
|
+
container: state.skyflowContainer,
|
|
29
|
+
table: "cards",
|
|
30
|
+
column: "card_number",
|
|
31
|
+
placeholder: placeholder,
|
|
32
|
+
label: label,
|
|
33
|
+
validations: [regexMatchRule],
|
|
34
|
+
inputStyles: {
|
|
35
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES,
|
|
36
|
+
...(style?.inputStyles ? {
|
|
37
|
+
...style?.inputStyles,
|
|
38
|
+
base: {
|
|
39
|
+
...DEFAULT_SKYFLOW_INPUT_STYLES.base,
|
|
40
|
+
...style?.inputStyles.base
|
|
41
|
+
}
|
|
42
|
+
} : {})
|
|
43
|
+
},
|
|
44
|
+
errorTextStyles: {
|
|
45
|
+
...SKYFLOW_HIDDEN_ERROR_TEXT_STYLES
|
|
46
|
+
},
|
|
47
|
+
labelStyles: {
|
|
48
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES,
|
|
49
|
+
...(style?.labelStyles ? {
|
|
50
|
+
...style?.labelStyles,
|
|
51
|
+
base: {
|
|
52
|
+
...DEFAULT_SKYFLOW_lABEL_STYLES.base,
|
|
53
|
+
...style?.labelStyles.base
|
|
54
|
+
}
|
|
55
|
+
} : {})
|
|
56
|
+
},
|
|
57
|
+
onChange: () => {
|
|
58
|
+
setErrorText('');
|
|
59
|
+
}
|
|
60
|
+
// onFocus={props.onFocus}
|
|
61
|
+
,
|
|
62
|
+
onBlur: e => {
|
|
63
|
+
setErrorText(getErrorField(e, label));
|
|
64
|
+
}
|
|
65
|
+
// onReady={props.onReady}
|
|
66
|
+
}), errorText && /*#__PURE__*/_jsx(Text, {
|
|
67
|
+
style: {
|
|
68
|
+
...DEFAULT_SKYFLOW_ERROR_TEXT_STYLES.base
|
|
69
|
+
},
|
|
70
|
+
children: errorText
|
|
71
|
+
})]
|
|
72
|
+
})
|
|
73
|
+
});
|
|
74
|
+
};
|
|
75
|
+
//# sourceMappingURL=CardNumberInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useState","CardNumberElement","getErrorField","regexMatchRule","DEFAULT_SKYFLOW_lABELS","DEFAULT_SKYFLOW_PLACEHOLDERS","Text","View","DEFAULT_INPUT_CONTAINER_STYLES","DEFAULT_SKYFLOW_ERROR_TEXT_STYLES","DEFAULT_SKYFLOW_INPUT_STYLES","DEFAULT_SKYFLOW_lABEL_STYLES","SKYFLOW_HIDDEN_ERROR_TEXT_STYLES","useTonderContext","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","CardNumberInput","placeholder","cardPlaceholder","label","cardLabel","style","state","errorText","setErrorText","children","skyflowContainer","isCreated","isCreating","inputStyles","container","base","table","column","validations","errorTextStyles","labelStyles","onChange","onBlur","e"],"sourceRoot":"../../../../../src","sources":["ui/components/Input/CardNumberInput.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,QAAQ,QAAQ,OAAO;AAEvC,SAASC,iBAAiB,QAAQ,sBAAsB;AACxD,SACEC,aAAa,EACbC,cAAc,EACdC,sBAAsB,EACtBC,4BAA4B,QACvB,2BAA2B;AAClC,SAASC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzC,SAASC,8BAA8B,QAAQ,oBAAoB;AACnE,SACEC,iCAAiC,EACjCC,4BAA4B,EAC5BC,4BAA4B,EAC5BC,gCAAgC,QAC3B,oBAAoB;AAC3B,OAAOC,gBAAgB,MAAM,mCAAmC;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAEjE,OAAO,MAAMC,eAAqC,GAAGA,CAAC;EACpDC,WAAW,GAAGhB,4BAA4B,CAACiB,eAAe;EAC1DC,KAA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e,WAAW,CAACL;YACxB;UACF,CAAC,GACD,CAAC,CAAC;QACR,CAAE;QACFM,QAAQ,EAAEA,CAAA,KAAM;UACdb,YAAY,CAAC,EAAE,CAAC;QAClB;QACA;QAAA;QACAc,MAAM,EAAGC,CAAC,IAAK;UACbf,YAAY,CAAC1B,aAAa,CAACyC,CAAC,EAAEpB,KAAK,CAAC,CAAC;QACvC;QACA;MAAA,CACD,CAAC,EACDI,SAAS,iBACRZ,IAAA,CAACT,IAAI;QAACmB,KAAK,EAAE;UAAE,GAAGhB,iCAAiC,CAAC0B;QAAK,CAAE;QAAAN,QAAA,EACxDF;MAAS,CACN,CACP;IAAA,CACG;EACP,CACD,CAAC;AAEP,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { View, StyleSheet, Text, Image, ScrollView } from 'react-native';
|
|
5
|
+
import { getPaymentMethodDetails } from '@shared/catalog/paymentMethodsCatalog';
|
|
6
|
+
import { RadioButton } from '@components/RadioButton';
|
|
7
|
+
import { buildBaseStyleText } from '@shared/utils/styleUtils';
|
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
+
const PaymentMethodsList = ({
|
|
10
|
+
methods,
|
|
11
|
+
selectedMethod,
|
|
12
|
+
onMethodSelect,
|
|
13
|
+
style
|
|
14
|
+
}) => {
|
|
15
|
+
if (!methods.length) return null;
|
|
16
|
+
return /*#__PURE__*/_jsx(ScrollView, {
|
|
17
|
+
style: {
|
|
18
|
+
...styles.container,
|
|
19
|
+
...(style?.base || {})
|
|
20
|
+
},
|
|
21
|
+
children: methods.map(method => {
|
|
22
|
+
const details = getPaymentMethodDetails(method.payment_method);
|
|
23
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
24
|
+
style: styles.methodItem,
|
|
25
|
+
children: [/*#__PURE__*/_jsx(RadioButton, {
|
|
26
|
+
style: {
|
|
27
|
+
base: style?.radioBase,
|
|
28
|
+
selected: style?.radioSelected,
|
|
29
|
+
inner: style?.radioInner
|
|
30
|
+
},
|
|
31
|
+
value: method.id,
|
|
32
|
+
selected: selectedMethod === method.id,
|
|
33
|
+
onSelect: () => onMethodSelect(method.id)
|
|
34
|
+
}), /*#__PURE__*/_jsxs(View, {
|
|
35
|
+
style: styles.methodIconContainer,
|
|
36
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
37
|
+
style: styles.methodIconBorder
|
|
38
|
+
}), /*#__PURE__*/_jsx(Image, {
|
|
39
|
+
source: {
|
|
40
|
+
uri: details.icon
|
|
41
|
+
},
|
|
42
|
+
style: {
|
|
43
|
+
...styles.methodIcon,
|
|
44
|
+
...(style?.cardIcon || {})
|
|
45
|
+
},
|
|
46
|
+
resizeMode: "contain"
|
|
47
|
+
})]
|
|
48
|
+
}), /*#__PURE__*/_jsx(Text, {
|
|
49
|
+
style: {
|
|
50
|
+
...styles.methodName,
|
|
51
|
+
...buildBaseStyleText(style)
|
|
52
|
+
},
|
|
53
|
+
children: details.label
|
|
54
|
+
})]
|
|
55
|
+
}, method.id);
|
|
56
|
+
})
|
|
57
|
+
});
|
|
58
|
+
};
|
|
59
|
+
const styles = StyleSheet.create({
|
|
60
|
+
container: {
|
|
61
|
+
padding: 0
|
|
62
|
+
},
|
|
63
|
+
methodItem: {
|
|
64
|
+
flexDirection: 'row',
|
|
65
|
+
alignItems: 'center',
|
|
66
|
+
paddingVertical: 5,
|
|
67
|
+
paddingHorizontal: 20,
|
|
68
|
+
borderBottomWidth: 1,
|
|
69
|
+
borderBottomColor: '#e2e8f0'
|
|
70
|
+
},
|
|
71
|
+
methodIconContainer: {
|
|
72
|
+
width: 25,
|
|
73
|
+
height: 25,
|
|
74
|
+
marginLeft: 15,
|
|
75
|
+
position: 'relative',
|
|
76
|
+
justifyContent: 'center',
|
|
77
|
+
alignItems: 'center'
|
|
78
|
+
},
|
|
79
|
+
methodIcon: {
|
|
80
|
+
width: '100%',
|
|
81
|
+
height: '100%'
|
|
82
|
+
},
|
|
83
|
+
methodIconBorder: {
|
|
84
|
+
position: 'absolute',
|
|
85
|
+
top: 0,
|
|
86
|
+
left: 0,
|
|
87
|
+
right: 0,
|
|
88
|
+
bottom: 0,
|
|
89
|
+
borderWidth: 1,
|
|
90
|
+
borderColor: '#bababa36',
|
|
91
|
+
borderRadius: 4
|
|
92
|
+
},
|
|
93
|
+
methodName: {
|
|
94
|
+
fontSize: 12,
|
|
95
|
+
color: '#1D1D1D',
|
|
96
|
+
marginLeft: 10
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
export default PaymentMethodsList;
|
|
100
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","View","StyleSheet","Text","Image","ScrollView","getPaymentMethodDetails","RadioButton","buildBaseStyleText","jsx","_jsx","jsxs","_jsxs","PaymentMethodsList","methods","selectedMethod","onMethodSelect","style","length","styles","container","base","children","map","method","details","payment_method","methodItem","radioBase","selected","radioSelected","inner","radioInner","value","id","onSelect","methodIconContainer","methodIconBorder","source","uri","icon","methodIcon","cardIcon","resizeMode","methodName","label","create","padding","flexDirection","alignItems","paddingVertical","paddingHorizontal","borderBottomWidth","borderBottomColor","width","height","marginLeft","position","justifyContent","top","left","right","bottom","borderWidth","borderColor","borderRadius","fontSize","color"],"sourceRoot":"../../../../../src","sources":["ui/components/PaymentMethodsList/index.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,UAAU,EAAEC,IAAI,EAAEC,KAAK,EAAEC,UAAU,QAAQ,cAAc;AAExE,SAASC,uBAAuB,QAAQ,uCAAuC;AAC/E,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,kBAAkB,QAAQ,0BAA0B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAS9D,MAAMC,kBAAqD,GAAGA,CAAC;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
|
2
|
+
|
|
3
|
+
// RadioButton.tsx
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import { View, TouchableOpacity, StyleSheet } from 'react-native';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
export const RadioButton = ({
|
|
8
|
+
selected,
|
|
9
|
+
onSelect,
|
|
10
|
+
style
|
|
11
|
+
}) => /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
12
|
+
onPress: onSelect,
|
|
13
|
+
children: /*#__PURE__*/_jsx(View, {
|
|
14
|
+
style: {
|
|
15
|
+
...styles.radio,
|
|
16
|
+
...(style?.base || {}),
|
|
17
|
+
...(selected ? {
|
|
18
|
+
...styles.radioSelected,
|
|
19
|
+
...(style?.selected || {})
|
|
20
|
+
} : {})
|
|
21
|
+
},
|
|
22
|
+
children: selected && /*#__PURE__*/_jsx(View, {
|
|
23
|
+
style: {
|
|
24
|
+
...styles.radioInner,
|
|
25
|
+
...(style?.inner || {})
|
|
26
|
+
}
|
|
27
|
+
})
|
|
28
|
+
})
|
|
29
|
+
});
|
|
30
|
+
const styles = StyleSheet.create({
|
|
31
|
+
radio: {
|
|
32
|
+
width: 16,
|
|
33
|
+
height: 16,
|
|
34
|
+
borderRadius: 8,
|
|
35
|
+
borderWidth: 1,
|
|
36
|
+
borderColor: '#bababa',
|
|
37
|
+
justifyContent: 'center',
|
|
38
|
+
alignItems: 'center'
|
|
39
|
+
},
|
|
40
|
+
radioSelected: {
|
|
41
|
+
borderColor: '#3bc635'
|
|
42
|
+
},
|
|
43
|
+
radioInner: {
|
|
44
|
+
width: 8,
|
|
45
|
+
height: 8,
|
|
46
|
+
borderRadius: 4,
|
|
47
|
+
backgroundColor: '#3bc635'
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","View","TouchableOpacity","StyleSheet","jsx","_jsx","RadioButton","selected","onSelect","style","onPress","children","styles","radio","base","radioSelected","radioInner","inner","create","width","height","borderRadius","borderWidth","borderColor","justifyContent","alignItems","backgroundColor"],"sourceRoot":"../../../../../src","sources":["ui/components/RadioButton/index.tsx"],"mappings":";;AAAA;AACA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,gBAAgB,EAAEC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAalE,OAAO,MAAMC,WAAuC,GAAGA,CAAC;EACtDC,QAAQ;EACRC,QAAQ;EACRC;AACF,CAAC,kBACCJ,IAAA,CAACH,gBAAgB;EAACQ,OAAO,EAAEF,QAAS;EAAAG,QAAA,eAClCN,IAAA,CAACJ,IAAI;IACHQ,KAAK,EAAE;MACL,GAAGG,MAAM,CAACC,KAAK;MACf,IAAIJ,KAAK,EAAEK,IAAI,IAAI,CAAC,CAAC,CAAC;MACtB,IAAIP,QAAQ,GACR;QAAE,GAAGK,MAAM,CAACG,aAAa;QAAE,IAAIN,KAAK,EAAEF,QAAQ,IAAI,CAAC,CAAC;MAAE,CAAC,GACvD,CAAC,CAAC;IACR,CAAE;IAAAI,QAAA,EAEDJ,QAAQ,iBACPF,IAAA,CAACJ,IAAI;MAACQ,KAAK,EAAE;QAAE,GAAGG,MAAM,CAACI,UAAU;QAAE,IAAIP,KAAK,EAAEQ,KAAK,IAAI,CAAC,CAAC;MAAE;IAAE,CAAE;EAClE,CACG;AAAC,CACS,CACnB;AAED,MAAML,MAAM,GAAGT,UAAU,CAACe,MAAM,CAAC;EAC/BL,KAAK,EAAE;IACLM,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE,EAAE;IACVC,YAAY,EAAE,CAAC;IACfC,WAAW,EAAE,CAAC;IACdC,WAAW,EAAE,SAAS;IACtBC,cAAc,EAAE,QAAQ;IACxBC,UAAU,EAAE;EACd,CAAC;EACDV,aAAa,EAAE;IACbQ,WAAW,EAAE;EACf,CAAC;EACDP,UAAU,EAAE;IACVG,KAAK,EAAE,CAA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