boxpay-checkout-reactnative-sdk 1.0.16 → 1.0.17-beta1
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/android/build.gradle +1 -1
- package/android/src/main/java/com/reactnativemodule/BoxPayElementsView.kt +62 -0
- package/android/src/main/java/com/reactnativemodule/CrossPlaform.kt +48 -19
- package/android/src/main/java/com/reactnativemodule/ReactNativeModulePackage.kt +2 -3
- package/cross_platform_react_native_plugin.podspec +1 -1
- package/ios/BoxPayElementsView.m +10 -0
- package/ios/BoxPayElementsView.swift +63 -0
- package/ios/CrossPlatform.m +5 -2
- package/ios/CrossPlatform.swift +45 -19
- package/lib/module/index.js +108 -13
- package/lib/module/index.js.map +1 -1
- package/lib/module/interface.js +1 -43
- package/lib/module/interface.js.map +1 -1
- package/lib/module/native.js +31 -0
- package/lib/module/native.js.map +1 -0
- package/lib/typescript/src/index.d.ts +3 -3
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/interface.d.ts +8 -579
- package/lib/typescript/src/interface.d.ts.map +1 -1
- package/lib/typescript/src/native.d.ts +23 -0
- package/lib/typescript/src/native.d.ts.map +1 -0
- package/package.json +14 -20
- package/src/index.tsx +106 -13
- package/src/interface.ts +14 -672
- package/src/native.ts +64 -0
- package/assets/animations/boxpayLogo.json +0 -1135
- package/assets/animations/payment_failed.json +0 -487
- package/assets/animations/payment_status_pending.json +0 -750
- package/assets/animations/payment_successful.json +0 -1602
- package/assets/fonts/Inter_18pt-Bold.ttf +0 -0
- package/assets/fonts/Inter_18pt-ExtraBold.ttf +0 -0
- package/assets/fonts/Inter_18pt-Medium.ttf +0 -0
- package/assets/fonts/Inter_18pt-Regular.ttf +0 -0
- package/assets/fonts/Inter_18pt-SemiBold.ttf +0 -0
- package/assets/fonts/Poppins-Bold.ttf +0 -0
- package/assets/fonts/Poppins-ExtraBold.ttf +0 -0
- package/assets/fonts/Poppins-Medium.ttf +0 -0
- package/assets/fonts/Poppins-Regular.ttf +0 -0
- package/assets/fonts/Poppins-SemiBold.ttf +0 -0
- package/assets/images/Lock.png +0 -0
- package/assets/images/add_icon.png +0 -0
- package/assets/images/add_upi_id_background.png +0 -0
- package/assets/images/arrow-left.png +0 -0
- package/assets/images/chervon-down.png +0 -0
- package/assets/images/cvv_info_image.png +0 -0
- package/assets/images/cvv_info_image_amex.png +0 -0
- package/assets/images/favicon.png +0 -0
- package/assets/images/gpay-icon.png +0 -0
- package/assets/images/ic_amex.png +0 -0
- package/assets/images/ic_bnpl.png +0 -0
- package/assets/images/ic_bnpl_semi_bold.png +0 -0
- package/assets/images/ic_card.png +0 -0
- package/assets/images/ic_card_add.png +0 -0
- package/assets/images/ic_card_lock.png +0 -0
- package/assets/images/ic_cross.png +0 -0
- package/assets/images/ic_cvv_info.png +0 -0
- package/assets/images/ic_default_card.png +0 -0
- package/assets/images/ic_emi.png +0 -0
- package/assets/images/ic_home.png +0 -0
- package/assets/images/ic_info.png +0 -0
- package/assets/images/ic_location.png +0 -0
- package/assets/images/ic_maestro.png +0 -0
- package/assets/images/ic_masterCard.png +0 -0
- package/assets/images/ic_more.png +0 -0
- package/assets/images/ic_netbanking.png +0 -0
- package/assets/images/ic_netbanking_semi_bold.png +0 -0
- package/assets/images/ic_offer_tag.png +0 -0
- package/assets/images/ic_other.png +0 -0
- package/assets/images/ic_qr.png +0 -0
- package/assets/images/ic_rupay.png +0 -0
- package/assets/images/ic_search.png +0 -0
- package/assets/images/ic_trash.png +0 -0
- package/assets/images/ic_upi.png +0 -0
- package/assets/images/ic_upi_error.png +0 -0
- package/assets/images/ic_user.png +0 -0
- package/assets/images/ic_visa.png +0 -0
- package/assets/images/ic_wallet.png +0 -0
- package/assets/images/ic_wallet_semi_bold.png +0 -0
- package/assets/images/ic_work.png +0 -0
- package/assets/images/no_results_found.png +0 -0
- package/assets/images/other-intent-icon.png +0 -0
- package/assets/images/paytm-icon.png +0 -0
- package/assets/images/phonepe-icon.png +0 -0
- package/assets/images/splash-icon.png +0 -0
- package/assets/images/upi-icon.png +0 -0
- package/assets/images/upi-timer-sheet-upi-icon.png +0 -0
- package/assets/json/countryCodes.json +0 -1490
- package/ios/Framework/CrossPlatformSDK.xcframework/Info.plist +0 -48
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64/CrossPlatformSDK.framework/CrossPlatformSDK +0 -0
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64/CrossPlatformSDK.framework/Headers/CrossPlatformSDK.h +0 -168
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64/CrossPlatformSDK.framework/Info.plist +0 -35
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64/CrossPlatformSDK.framework/Modules/module.modulemap +0 -8
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64/dSYMs/CrossPlatformSDK.framework.dSYM/Contents/Info.plist +0 -20
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64_x86_64-simulator/CrossPlatformSDK.framework/CrossPlatformSDK +0 -0
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64_x86_64-simulator/CrossPlatformSDK.framework/Headers/CrossPlatformSDK.h +0 -168
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64_x86_64-simulator/CrossPlatformSDK.framework/Info.plist +0 -31
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64_x86_64-simulator/CrossPlatformSDK.framework/Modules/module.modulemap +0 -5
- package/ios/Framework/CrossPlatformSDK.xcframework/ios-arm64_x86_64-simulator/dSYMs/CrossPlatformSDK.framework.dSYM/Contents/Info.plist +0 -20
- package/lib/assets/animations/boxpayLogo.json +0 -1135
- package/lib/assets/animations/payment_failed.json +0 -487
- package/lib/assets/animations/payment_status_pending.json +0 -750
- package/lib/assets/animations/payment_successful.json +0 -1602
- package/lib/assets/assets/animations/boxpayLogo.json +0 -1135
- package/lib/assets/assets/animations/payment_failed.json +0 -487
- package/lib/assets/assets/animations/payment_status_pending.json +0 -750
- package/lib/assets/assets/animations/payment_successful.json +0 -1602
- package/lib/assets/assets/fonts/Inter_18pt-Bold.ttf +0 -0
- package/lib/assets/assets/fonts/Inter_18pt-ExtraBold.ttf +0 -0
- package/lib/assets/assets/fonts/Inter_18pt-Medium.ttf +0 -0
- package/lib/assets/assets/fonts/Inter_18pt-Regular.ttf +0 -0
- package/lib/assets/assets/fonts/Inter_18pt-SemiBold.ttf +0 -0
- package/lib/assets/assets/fonts/Poppins-Bold.ttf +0 -0
- package/lib/assets/assets/fonts/Poppins-ExtraBold.ttf +0 -0
- package/lib/assets/assets/fonts/Poppins-Medium.ttf +0 -0
- package/lib/assets/assets/fonts/Poppins-Regular.ttf +0 -0
- package/lib/assets/assets/fonts/Poppins-SemiBold.ttf +0 -0
- package/lib/assets/assets/images/Lock.png +0 -0
- package/lib/assets/assets/images/add_icon.png +0 -0
- package/lib/assets/assets/images/add_upi_id_background.png +0 -0
- package/lib/assets/assets/images/arrow-left.png +0 -0
- package/lib/assets/assets/images/chervon-down.png +0 -0
- package/lib/assets/assets/images/cvv_info_image.png +0 -0
- package/lib/assets/assets/images/cvv_info_image_amex.png +0 -0
- package/lib/assets/assets/images/favicon.png +0 -0
- package/lib/assets/assets/images/gpay-icon.png +0 -0
- package/lib/assets/assets/images/ic_amex.png +0 -0
- package/lib/assets/assets/images/ic_bnpl.png +0 -0
- package/lib/assets/assets/images/ic_bnpl_semi_bold.png +0 -0
- package/lib/assets/assets/images/ic_card.png +0 -0
- package/lib/assets/assets/images/ic_card_add.png +0 -0
- package/lib/assets/assets/images/ic_card_lock.png +0 -0
- package/lib/assets/assets/images/ic_cross.png +0 -0
- package/lib/assets/assets/images/ic_cvv_info.png +0 -0
- package/lib/assets/assets/images/ic_default_card.png +0 -0
- package/lib/assets/assets/images/ic_emi.png +0 -0
- package/lib/assets/assets/images/ic_home.png +0 -0
- package/lib/assets/assets/images/ic_info.png +0 -0
- package/lib/assets/assets/images/ic_location.png +0 -0
- package/lib/assets/assets/images/ic_maestro.png +0 -0
- package/lib/assets/assets/images/ic_masterCard.png +0 -0
- package/lib/assets/assets/images/ic_more.png +0 -0
- package/lib/assets/assets/images/ic_netbanking.png +0 -0
- package/lib/assets/assets/images/ic_netbanking_semi_bold.png +0 -0
- package/lib/assets/assets/images/ic_offer_tag.png +0 -0
- package/lib/assets/assets/images/ic_other.png +0 -0
- package/lib/assets/assets/images/ic_qr.png +0 -0
- package/lib/assets/assets/images/ic_rupay.png +0 -0
- package/lib/assets/assets/images/ic_search.png +0 -0
- package/lib/assets/assets/images/ic_trash.png +0 -0
- package/lib/assets/assets/images/ic_upi.png +0 -0
- package/lib/assets/assets/images/ic_upi_error.png +0 -0
- package/lib/assets/assets/images/ic_user.png +0 -0
- package/lib/assets/assets/images/ic_visa.png +0 -0
- package/lib/assets/assets/images/ic_wallet.png +0 -0
- package/lib/assets/assets/images/ic_wallet_semi_bold.png +0 -0
- package/lib/assets/assets/images/ic_work.png +0 -0
- package/lib/assets/assets/images/no_results_found.png +0 -0
- package/lib/assets/assets/images/other-intent-icon.png +0 -0
- package/lib/assets/assets/images/paytm-icon.png +0 -0
- package/lib/assets/assets/images/phonepe-icon.png +0 -0
- package/lib/assets/assets/images/splash-icon.png +0 -0
- package/lib/assets/assets/images/upi-icon.png +0 -0
- package/lib/assets/assets/images/upi-timer-sheet-upi-icon.png +0 -0
- package/lib/assets/assets/json/countryCodes.json +0 -1490
- package/lib/assets/fonts/Inter_18pt-Bold.ttf +0 -0
- package/lib/assets/fonts/Inter_18pt-ExtraBold.ttf +0 -0
- package/lib/assets/fonts/Inter_18pt-Medium.ttf +0 -0
- package/lib/assets/fonts/Inter_18pt-Regular.ttf +0 -0
- package/lib/assets/fonts/Inter_18pt-SemiBold.ttf +0 -0
- package/lib/assets/fonts/Poppins-Bold.ttf +0 -0
- package/lib/assets/fonts/Poppins-ExtraBold.ttf +0 -0
- package/lib/assets/fonts/Poppins-Medium.ttf +0 -0
- package/lib/assets/fonts/Poppins-Regular.ttf +0 -0
- package/lib/assets/fonts/Poppins-SemiBold.ttf +0 -0
- package/lib/assets/images/Lock.png +0 -0
- package/lib/assets/images/add_icon.png +0 -0
- package/lib/assets/images/add_upi_id_background.png +0 -0
- package/lib/assets/images/arrow-left.png +0 -0
- package/lib/assets/images/chervon-down.png +0 -0
- package/lib/assets/images/cvv_info_image.png +0 -0
- package/lib/assets/images/cvv_info_image_amex.png +0 -0
- package/lib/assets/images/favicon.png +0 -0
- package/lib/assets/images/gpay-icon.png +0 -0
- package/lib/assets/images/ic_amex.png +0 -0
- package/lib/assets/images/ic_bnpl.png +0 -0
- package/lib/assets/images/ic_bnpl_semi_bold.png +0 -0
- package/lib/assets/images/ic_card.png +0 -0
- package/lib/assets/images/ic_card_add.png +0 -0
- package/lib/assets/images/ic_card_lock.png +0 -0
- package/lib/assets/images/ic_cross.png +0 -0
- package/lib/assets/images/ic_cvv_info.png +0 -0
- package/lib/assets/images/ic_default_card.png +0 -0
- package/lib/assets/images/ic_emi.png +0 -0
- package/lib/assets/images/ic_home.png +0 -0
- package/lib/assets/images/ic_info.png +0 -0
- package/lib/assets/images/ic_location.png +0 -0
- package/lib/assets/images/ic_maestro.png +0 -0
- package/lib/assets/images/ic_masterCard.png +0 -0
- package/lib/assets/images/ic_more.png +0 -0
- package/lib/assets/images/ic_netbanking.png +0 -0
- package/lib/assets/images/ic_netbanking_semi_bold.png +0 -0
- package/lib/assets/images/ic_offer_tag.png +0 -0
- package/lib/assets/images/ic_other.png +0 -0
- package/lib/assets/images/ic_qr.png +0 -0
- package/lib/assets/images/ic_rupay.png +0 -0
- package/lib/assets/images/ic_search.png +0 -0
- package/lib/assets/images/ic_trash.png +0 -0
- package/lib/assets/images/ic_upi.png +0 -0
- package/lib/assets/images/ic_upi_error.png +0 -0
- package/lib/assets/images/ic_user.png +0 -0
- package/lib/assets/images/ic_visa.png +0 -0
- package/lib/assets/images/ic_wallet.png +0 -0
- package/lib/assets/images/ic_wallet_semi_bold.png +0 -0
- package/lib/assets/images/ic_work.png +0 -0
- package/lib/assets/images/no_results_found.png +0 -0
- package/lib/assets/images/other-intent-icon.png +0 -0
- package/lib/assets/images/paytm-icon.png +0 -0
- package/lib/assets/images/phonepe-icon.png +0 -0
- package/lib/assets/images/splash-icon.png +0 -0
- package/lib/assets/images/upi-icon.png +0 -0
- package/lib/assets/images/upi-timer-sheet-upi-icon.png +0 -0
- package/lib/assets/json/countryCodes.json +0 -1490
- package/lib/module/components/addressCard.js +0 -186
- package/lib/module/components/addressCard.js.map +0 -1
- package/lib/module/components/applyCouponCard.js +0 -145
- package/lib/module/components/applyCouponCard.js.map +0 -1
- package/lib/module/components/bankCard.js +0 -59
- package/lib/module/components/bankCard.js.map +0 -1
- package/lib/module/components/cancelPaymentModal.js +0 -74
- package/lib/module/components/cancelPaymentModal.js.map +0 -1
- package/lib/module/components/checkboxContainer.js +0 -75
- package/lib/module/components/checkboxContainer.js.map +0 -1
- package/lib/module/components/circularProgress.js +0 -75
- package/lib/module/components/circularProgress.js.map +0 -1
- package/lib/module/components/cvvInfoBottomSheet.js +0 -73
- package/lib/module/components/cvvInfoBottomSheet.js.map +0 -1
- package/lib/module/components/deleteAddressModal.js +0 -120
- package/lib/module/components/deleteAddressModal.js.map +0 -1
- package/lib/module/components/fontFamily.js +0 -30
- package/lib/module/components/fontFamily.js.map +0 -1
- package/lib/module/components/getInstalledUPI.js +0 -27
- package/lib/module/components/getInstalledUPI.js.map +0 -1
- package/lib/module/components/header.js +0 -127
- package/lib/module/components/header.js.map +0 -1
- package/lib/module/components/imageLoader.js +0 -93
- package/lib/module/components/imageLoader.js.map +0 -1
- package/lib/module/components/knowMoreBottomSheet.js +0 -113
- package/lib/module/components/knowMoreBottomSheet.js.map +0 -1
- package/lib/module/components/morePaymentContainer.js +0 -66
- package/lib/module/components/morePaymentContainer.js.map +0 -1
- package/lib/module/components/morePaymentMethods.js +0 -177
- package/lib/module/components/morePaymentMethods.js.map +0 -1
- package/lib/module/components/offerCard.js +0 -148
- package/lib/module/components/offerCard.js.map +0 -1
- package/lib/module/components/orderDetails.js +0 -404
- package/lib/module/components/orderDetails.js.map +0 -1
- package/lib/module/components/paymentFailed.js +0 -105
- package/lib/module/components/paymentFailed.js.map +0 -1
- package/lib/module/components/paymentSelector.js +0 -158
- package/lib/module/components/paymentSelector.js.map +0 -1
- package/lib/module/components/paymentSuccess.js +0 -239
- package/lib/module/components/paymentSuccess.js.map +0 -1
- package/lib/module/components/savedAddressBottomSheet.js +0 -130
- package/lib/module/components/savedAddressBottomSheet.js.map +0 -1
- package/lib/module/components/savedAddressCard.js +0 -117
- package/lib/module/components/savedAddressCard.js.map +0 -1
- package/lib/module/components/savedCardComponent.js +0 -238
- package/lib/module/components/savedCardComponent.js.map +0 -1
- package/lib/module/components/selectTenureCard.js +0 -393
- package/lib/module/components/selectTenureCard.js.map +0 -1
- package/lib/module/components/sessionExpire.js +0 -96
- package/lib/module/components/sessionExpire.js.map +0 -1
- package/lib/module/components/shimmerView.js +0 -40
- package/lib/module/components/shimmerView.js.map +0 -1
- package/lib/module/components/subscriptionRow.js +0 -33
- package/lib/module/components/subscriptionRow.js.map +0 -1
- package/lib/module/navigation.js +0 -88
- package/lib/module/navigation.js.map +0 -1
- package/lib/module/postRequest/callUIAnalytics.js +0 -43
- package/lib/module/postRequest/callUIAnalytics.js.map +0 -1
- package/lib/module/postRequest/cardPostRequest.js +0 -60
- package/lib/module/postRequest/cardPostRequest.js.map +0 -1
- package/lib/module/postRequest/deleteSavedAddress.js +0 -33
- package/lib/module/postRequest/deleteSavedAddress.js.map +0 -1
- package/lib/module/postRequest/emiPostRequest.js +0 -68
- package/lib/module/postRequest/emiPostRequest.js.map +0 -1
- package/lib/module/postRequest/fetchCardDetails.js +0 -26
- package/lib/module/postRequest/fetchCardDetails.js.map +0 -1
- package/lib/module/postRequest/fetchInstantOffer.js +0 -29
- package/lib/module/postRequest/fetchInstantOffer.js.map +0 -1
- package/lib/module/postRequest/fetchPaymentMethods.js +0 -30
- package/lib/module/postRequest/fetchPaymentMethods.js.map +0 -1
- package/lib/module/postRequest/fetchRecommendedInstruments.js +0 -30
- package/lib/module/postRequest/fetchRecommendedInstruments.js.map +0 -1
- package/lib/module/postRequest/fetchSavedAddress.js +0 -30
- package/lib/module/postRequest/fetchSavedAddress.js.map +0 -1
- package/lib/module/postRequest/fetchSessionDetails.js +0 -25
- package/lib/module/postRequest/fetchSessionDetails.js.map +0 -1
- package/lib/module/postRequest/fetchStatus.js +0 -25
- package/lib/module/postRequest/fetchStatus.js.map +0 -1
- package/lib/module/postRequest/fetchSurcharge.js +0 -36
- package/lib/module/postRequest/fetchSurcharge.js.map +0 -1
- package/lib/module/postRequest/methodsPostRequest.js +0 -48
- package/lib/module/postRequest/methodsPostRequest.js.map +0 -1
- package/lib/module/postRequest/upiPostRequest.js +0 -46
- package/lib/module/postRequest/upiPostRequest.js.map +0 -1
- package/lib/module/screens/addressScreen.js +0 -726
- package/lib/module/screens/addressScreen.js.map +0 -1
- package/lib/module/screens/bnplScreen.js +0 -262
- package/lib/module/screens/bnplScreen.js.map +0 -1
- package/lib/module/screens/cardScreen.js +0 -952
- package/lib/module/screens/cardScreen.js.map +0 -1
- package/lib/module/screens/emiScreen.js +0 -648
- package/lib/module/screens/emiScreen.js.map +0 -1
- package/lib/module/screens/instantOfferList.js +0 -113
- package/lib/module/screens/instantOfferList.js.map +0 -1
- package/lib/module/screens/mainScreen.js +0 -949
- package/lib/module/screens/mainScreen.js.map +0 -1
- package/lib/module/screens/netBankingScreen.js +0 -369
- package/lib/module/screens/netBankingScreen.js.map +0 -1
- package/lib/module/screens/savedAddressScreen.js +0 -274
- package/lib/module/screens/savedAddressScreen.js.map +0 -1
- package/lib/module/screens/selectTenureScreen.js +0 -105
- package/lib/module/screens/selectTenureScreen.js.map +0 -1
- package/lib/module/screens/upiScreen.js +0 -553
- package/lib/module/screens/upiScreen.js.map +0 -1
- package/lib/module/screens/upiTimerScreen.js +0 -215
- package/lib/module/screens/upiTimerScreen.js.map +0 -1
- package/lib/module/screens/walletScreen.js +0 -336
- package/lib/module/screens/walletScreen.js.map +0 -1
- package/lib/module/screens/webViewScreen.js +0 -89
- package/lib/module/screens/webViewScreen.js.map +0 -1
- package/lib/module/sdk-version.json +0 -1
- package/lib/module/serviceRequest.js +0 -27
- package/lib/module/serviceRequest.js.map +0 -1
- package/lib/module/sharedContext/checkoutDetailsHandler.js +0 -108
- package/lib/module/sharedContext/checkoutDetailsHandler.js.map +0 -1
- package/lib/module/sharedContext/getTextInputTheme.js +0 -15
- package/lib/module/sharedContext/getTextInputTheme.js.map +0 -1
- package/lib/module/sharedContext/handleAutoNavigation.js +0 -34
- package/lib/module/sharedContext/handleAutoNavigation.js.map +0 -1
- package/lib/module/sharedContext/handlePaymentResponseHandler.js +0 -280
- package/lib/module/sharedContext/handlePaymentResponseHandler.js.map +0 -1
- package/lib/module/sharedContext/paymentStatusHandler.js +0 -9
- package/lib/module/sharedContext/paymentStatusHandler.js.map +0 -1
- package/lib/module/sharedContext/userdataHandler.js +0 -50
- package/lib/module/sharedContext/userdataHandler.js.map +0 -1
- package/lib/module/styles/components/addressCardStyles.js +0 -55
- package/lib/module/styles/components/addressCardStyles.js.map +0 -1
- package/lib/module/styles/components/bankCardStyles.js +0 -61
- package/lib/module/styles/components/bankCardStyles.js.map +0 -1
- package/lib/module/styles/components/cancelPaymentModalStyles.js +0 -83
- package/lib/module/styles/components/cancelPaymentModalStyles.js.map +0 -1
- package/lib/module/styles/components/cvvInfoBottomSheetStyles.js +0 -52
- package/lib/module/styles/components/cvvInfoBottomSheetStyles.js.map +0 -1
- package/lib/module/styles/components/savedAddressCardStyles.js +0 -64
- package/lib/module/styles/components/savedAddressCardStyles.js.map +0 -1
- package/lib/module/styles/indexStyles.js +0 -70
- package/lib/module/styles/indexStyles.js.map +0 -1
- package/lib/module/styles/screens/addressScreenStyles..js +0 -61
- package/lib/module/styles/screens/addressScreenStyles..js.map +0 -1
- package/lib/module/styles/screens/bnplScreenStyles.js +0 -80
- package/lib/module/styles/screens/bnplScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/cardScreenStyles.js +0 -178
- package/lib/module/styles/screens/cardScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/emiScreenStyles.js +0 -130
- package/lib/module/styles/screens/emiScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/instantOfferScreenStyles.js +0 -45
- package/lib/module/styles/screens/instantOfferScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/netBankingScreenStyles.js +0 -101
- package/lib/module/styles/screens/netBankingScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/savedAddressScreenStyles.js +0 -52
- package/lib/module/styles/screens/savedAddressScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/selectTenureScreenStyles.js +0 -45
- package/lib/module/styles/screens/selectTenureScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/upiScreenStyles.js +0 -172
- package/lib/module/styles/screens/upiScreenStyles.js.map +0 -1
- package/lib/module/styles/screens/upiTimerScreenStyle.js +0 -97
- package/lib/module/styles/screens/upiTimerScreenStyle.js.map +0 -1
- package/lib/module/styles/screens/walletScreenStyles.js +0 -98
- package/lib/module/styles/screens/walletScreenStyles.js.map +0 -1
- package/lib/module/utility.js +0 -195
- package/lib/module/utility.js.map +0 -1
- package/lib/typescript/src/components/addressCard.d.ts +0 -7
- package/lib/typescript/src/components/addressCard.d.ts.map +0 -1
- package/lib/typescript/src/components/applyCouponCard.d.ts +0 -15
- package/lib/typescript/src/components/applyCouponCard.d.ts.map +0 -1
- package/lib/typescript/src/components/bankCard.d.ts +0 -11
- package/lib/typescript/src/components/bankCard.d.ts.map +0 -1
- package/lib/typescript/src/components/cancelPaymentModal.d.ts +0 -8
- package/lib/typescript/src/components/cancelPaymentModal.d.ts.map +0 -1
- package/lib/typescript/src/components/checkboxContainer.d.ts +0 -8
- package/lib/typescript/src/components/checkboxContainer.d.ts.map +0 -1
- package/lib/typescript/src/components/circularProgress.d.ts +0 -10
- package/lib/typescript/src/components/circularProgress.d.ts.map +0 -1
- package/lib/typescript/src/components/cvvInfoBottomSheet.d.ts +0 -7
- package/lib/typescript/src/components/cvvInfoBottomSheet.d.ts.map +0 -1
- package/lib/typescript/src/components/deleteAddressModal.d.ts +0 -9
- package/lib/typescript/src/components/deleteAddressModal.d.ts.map +0 -1
- package/lib/typescript/src/components/fontFamily.d.ts +0 -14
- package/lib/typescript/src/components/fontFamily.d.ts.map +0 -1
- package/lib/typescript/src/components/getInstalledUPI.d.ts +0 -2
- package/lib/typescript/src/components/getInstalledUPI.d.ts.map +0 -1
- package/lib/typescript/src/components/header.d.ts +0 -10
- package/lib/typescript/src/components/header.d.ts.map +0 -1
- package/lib/typescript/src/components/imageLoader.d.ts +0 -8
- package/lib/typescript/src/components/imageLoader.d.ts.map +0 -1
- package/lib/typescript/src/components/knowMoreBottomSheet.d.ts +0 -6
- package/lib/typescript/src/components/knowMoreBottomSheet.d.ts.map +0 -1
- package/lib/typescript/src/components/morePaymentContainer.d.ts +0 -10
- package/lib/typescript/src/components/morePaymentContainer.d.ts.map +0 -1
- package/lib/typescript/src/components/morePaymentMethods.d.ts +0 -11
- package/lib/typescript/src/components/morePaymentMethods.d.ts.map +0 -1
- package/lib/typescript/src/components/offerCard.d.ts +0 -15
- package/lib/typescript/src/components/offerCard.d.ts.map +0 -1
- package/lib/typescript/src/components/orderDetails.d.ts +0 -23
- package/lib/typescript/src/components/orderDetails.d.ts.map +0 -1
- package/lib/typescript/src/components/paymentFailed.d.ts +0 -9
- package/lib/typescript/src/components/paymentFailed.d.ts.map +0 -1
- package/lib/typescript/src/components/paymentSelector.d.ts +0 -12
- package/lib/typescript/src/components/paymentSelector.d.ts.map +0 -1
- package/lib/typescript/src/components/paymentSuccess.d.ts +0 -10
- package/lib/typescript/src/components/paymentSuccess.d.ts.map +0 -1
- package/lib/typescript/src/components/savedAddressBottomSheet.d.ts +0 -14
- package/lib/typescript/src/components/savedAddressBottomSheet.d.ts.map +0 -1
- package/lib/typescript/src/components/savedAddressCard.d.ts +0 -9
- package/lib/typescript/src/components/savedAddressCard.d.ts.map +0 -1
- package/lib/typescript/src/components/savedCardComponent.d.ts +0 -12
- package/lib/typescript/src/components/savedCardComponent.d.ts.map +0 -1
- package/lib/typescript/src/components/selectTenureCard.d.ts +0 -21
- package/lib/typescript/src/components/selectTenureCard.d.ts.map +0 -1
- package/lib/typescript/src/components/sessionExpire.d.ts +0 -7
- package/lib/typescript/src/components/sessionExpire.d.ts.map +0 -1
- package/lib/typescript/src/components/shimmerView.d.ts +0 -3
- package/lib/typescript/src/components/shimmerView.d.ts.map +0 -1
- package/lib/typescript/src/components/subscriptionRow.d.ts +0 -9
- package/lib/typescript/src/components/subscriptionRow.d.ts.map +0 -1
- package/lib/typescript/src/navigation.d.ts +0 -17
- package/lib/typescript/src/navigation.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/callUIAnalytics.d.ts +0 -4
- package/lib/typescript/src/postRequest/callUIAnalytics.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/cardPostRequest.d.ts +0 -4
- package/lib/typescript/src/postRequest/cardPostRequest.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/deleteSavedAddress.d.ts +0 -4
- package/lib/typescript/src/postRequest/deleteSavedAddress.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/emiPostRequest.d.ts +0 -13
- package/lib/typescript/src/postRequest/emiPostRequest.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchCardDetails.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchCardDetails.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchInstantOffer.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchInstantOffer.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchPaymentMethods.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchPaymentMethods.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchRecommendedInstruments.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchRecommendedInstruments.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchSavedAddress.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchSavedAddress.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchSessionDetails.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchSessionDetails.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchStatus.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchStatus.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/fetchSurcharge.d.ts +0 -4
- package/lib/typescript/src/postRequest/fetchSurcharge.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/methodsPostRequest.d.ts +0 -4
- package/lib/typescript/src/postRequest/methodsPostRequest.d.ts.map +0 -1
- package/lib/typescript/src/postRequest/upiPostRequest.d.ts +0 -4
- package/lib/typescript/src/postRequest/upiPostRequest.d.ts.map +0 -1
- package/lib/typescript/src/screens/addressScreen.d.ts +0 -11
- package/lib/typescript/src/screens/addressScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/bnplScreen.d.ts +0 -11
- package/lib/typescript/src/screens/bnplScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/cardScreen.d.ts +0 -11
- package/lib/typescript/src/screens/cardScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/emiScreen.d.ts +0 -11
- package/lib/typescript/src/screens/emiScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/instantOfferList.d.ts +0 -19
- package/lib/typescript/src/screens/instantOfferList.d.ts.map +0 -1
- package/lib/typescript/src/screens/mainScreen.d.ts +0 -11
- package/lib/typescript/src/screens/mainScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/netBankingScreen.d.ts +0 -11
- package/lib/typescript/src/screens/netBankingScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/savedAddressScreen.d.ts +0 -9
- package/lib/typescript/src/screens/savedAddressScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/selectTenureScreen.d.ts +0 -12
- package/lib/typescript/src/screens/selectTenureScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/upiScreen.d.ts +0 -20
- package/lib/typescript/src/screens/upiScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/upiTimerScreen.d.ts +0 -11
- package/lib/typescript/src/screens/upiTimerScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/walletScreen.d.ts +0 -11
- package/lib/typescript/src/screens/walletScreen.d.ts.map +0 -1
- package/lib/typescript/src/screens/webViewScreen.d.ts +0 -9
- package/lib/typescript/src/screens/webViewScreen.d.ts.map +0 -1
- package/lib/typescript/src/serviceRequest.d.ts +0 -3
- package/lib/typescript/src/serviceRequest.d.ts.map +0 -1
- package/lib/typescript/src/sharedContext/checkoutDetailsHandler.d.ts +0 -8
- package/lib/typescript/src/sharedContext/checkoutDetailsHandler.d.ts.map +0 -1
- package/lib/typescript/src/sharedContext/getTextInputTheme.d.ts +0 -7
- package/lib/typescript/src/sharedContext/getTextInputTheme.d.ts.map +0 -1
- package/lib/typescript/src/sharedContext/handleAutoNavigation.d.ts +0 -3
- package/lib/typescript/src/sharedContext/handleAutoNavigation.d.ts.map +0 -1
- package/lib/typescript/src/sharedContext/handlePaymentResponseHandler.d.ts +0 -16
- package/lib/typescript/src/sharedContext/handlePaymentResponseHandler.d.ts.map +0 -1
- package/lib/typescript/src/sharedContext/paymentStatusHandler.d.ts +0 -7
- package/lib/typescript/src/sharedContext/paymentStatusHandler.d.ts.map +0 -1
- package/lib/typescript/src/sharedContext/userdataHandler.d.ts +0 -8
- package/lib/typescript/src/sharedContext/userdataHandler.d.ts.map +0 -1
- package/lib/typescript/src/styles/components/addressCardStyles.d.ts +0 -52
- package/lib/typescript/src/styles/components/addressCardStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/components/bankCardStyles.d.ts +0 -58
- package/lib/typescript/src/styles/components/bankCardStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/components/cancelPaymentModalStyles.d.ts +0 -80
- package/lib/typescript/src/styles/components/cancelPaymentModalStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/components/cvvInfoBottomSheetStyles.d.ts +0 -49
- package/lib/typescript/src/styles/components/cvvInfoBottomSheetStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/components/savedAddressCardStyles.d.ts +0 -61
- package/lib/typescript/src/styles/components/savedAddressCardStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/indexStyles.d.ts +0 -67
- package/lib/typescript/src/styles/indexStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/addressScreenStyles..d.ts +0 -58
- package/lib/typescript/src/styles/screens/addressScreenStyles..d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/bnplScreenStyles.d.ts +0 -77
- package/lib/typescript/src/styles/screens/bnplScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/cardScreenStyles.d.ts +0 -175
- package/lib/typescript/src/styles/screens/cardScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/emiScreenStyles.d.ts +0 -127
- package/lib/typescript/src/styles/screens/emiScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/instantOfferScreenStyles.d.ts +0 -42
- package/lib/typescript/src/styles/screens/instantOfferScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/netBankingScreenStyles.d.ts +0 -98
- package/lib/typescript/src/styles/screens/netBankingScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/savedAddressScreenStyles.d.ts +0 -49
- package/lib/typescript/src/styles/screens/savedAddressScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/selectTenureScreenStyles.d.ts +0 -42
- package/lib/typescript/src/styles/screens/selectTenureScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/upiScreenStyles.d.ts +0 -168
- package/lib/typescript/src/styles/screens/upiScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/upiTimerScreenStyle.d.ts +0 -94
- package/lib/typescript/src/styles/screens/upiTimerScreenStyle.d.ts.map +0 -1
- package/lib/typescript/src/styles/screens/walletScreenStyles.d.ts +0 -95
- package/lib/typescript/src/styles/screens/walletScreenStyles.d.ts.map +0 -1
- package/lib/typescript/src/utility.d.ts +0 -66
- package/lib/typescript/src/utility.d.ts.map +0 -1
- package/src/components/addressCard.tsx +0 -219
- package/src/components/applyCouponCard.tsx +0 -197
- package/src/components/bankCard.tsx +0 -50
- package/src/components/cancelPaymentModal.tsx +0 -68
- package/src/components/checkboxContainer.tsx +0 -75
- package/src/components/circularProgress.tsx +0 -74
- package/src/components/cvvInfoBottomSheet.tsx +0 -58
- package/src/components/deleteAddressModal.tsx +0 -105
- package/src/components/fontFamily.tsx +0 -33
- package/src/components/getInstalledUPI.ts +0 -32
- package/src/components/header.tsx +0 -112
- package/src/components/imageLoader.tsx +0 -110
- package/src/components/knowMoreBottomSheet.tsx +0 -111
- package/src/components/morePaymentContainer.tsx +0 -66
- package/src/components/morePaymentMethods.tsx +0 -236
- package/src/components/offerCard.tsx +0 -173
- package/src/components/orderDetails.tsx +0 -503
- package/src/components/paymentFailed.tsx +0 -103
- package/src/components/paymentSelector.tsx +0 -186
- package/src/components/paymentSuccess.tsx +0 -264
- package/src/components/savedAddressBottomSheet.tsx +0 -123
- package/src/components/savedAddressCard.tsx +0 -113
- package/src/components/savedCardComponent.tsx +0 -271
- package/src/components/selectTenureCard.tsx +0 -475
- package/src/components/sessionExpire.tsx +0 -89
- package/src/components/shimmerView.tsx +0 -31
- package/src/components/subscriptionRow.tsx +0 -19
- package/src/navigation.tsx +0 -82
- package/src/postRequest/callUIAnalytics.ts +0 -36
- package/src/postRequest/cardPostRequest.ts +0 -57
- package/src/postRequest/deleteSavedAddress.ts +0 -20
- package/src/postRequest/emiPostRequest.ts +0 -77
- package/src/postRequest/fetchCardDetails.ts +0 -16
- package/src/postRequest/fetchInstantOffer.ts +0 -19
- package/src/postRequest/fetchPaymentMethods.ts +0 -25
- package/src/postRequest/fetchRecommendedInstruments.tsx +0 -17
- package/src/postRequest/fetchSavedAddress.ts +0 -16
- package/src/postRequest/fetchSessionDetails.tsx +0 -13
- package/src/postRequest/fetchStatus.tsx +0 -14
- package/src/postRequest/fetchSurcharge.ts +0 -23
- package/src/postRequest/methodsPostRequest.tsx +0 -41
- package/src/postRequest/upiPostRequest.tsx +0 -37
- package/src/screens/addressScreen.tsx +0 -843
- package/src/screens/bnplScreen.tsx +0 -321
- package/src/screens/cardScreen.tsx +0 -1166
- package/src/screens/emiScreen.tsx +0 -868
- package/src/screens/instantOfferList.tsx +0 -176
- package/src/screens/mainScreen.tsx +0 -1101
- package/src/screens/netBankingScreen.tsx +0 -468
- package/src/screens/savedAddressScreen.tsx +0 -294
- package/src/screens/selectTenureScreen.tsx +0 -137
- package/src/screens/upiScreen.tsx +0 -654
- package/src/screens/upiTimerScreen.tsx +0 -266
- package/src/screens/walletScreen.tsx +0 -408
- package/src/screens/webViewScreen.tsx +0 -92
- package/src/sdk-version.json +0 -1
- package/src/serviceRequest.ts +0 -27
- package/src/sharedContext/checkoutDetailsHandler.ts +0 -114
- package/src/sharedContext/getTextInputTheme.ts +0 -12
- package/src/sharedContext/handleAutoNavigation.ts +0 -53
- package/src/sharedContext/handlePaymentResponseHandler.ts +0 -304
- package/src/sharedContext/paymentStatusHandler.ts +0 -12
- package/src/sharedContext/userdataHandler.ts +0 -55
- package/src/styles/components/addressCardStyles.ts +0 -55
- package/src/styles/components/bankCardStyles.ts +0 -58
- package/src/styles/components/cancelPaymentModalStyles.ts +0 -82
- package/src/styles/components/cvvInfoBottomSheetStyles.ts +0 -49
- package/src/styles/components/savedAddressCardStyles.ts +0 -60
- package/src/styles/indexStyles.ts +0 -60
- package/src/styles/screens/addressScreenStyles..ts +0 -60
- package/src/styles/screens/bnplScreenStyles.ts +0 -77
- package/src/styles/screens/cardScreenStyles.ts +0 -157
- package/src/styles/screens/emiScreenStyles.ts +0 -112
- package/src/styles/screens/instantOfferScreenStyles.ts +0 -43
- package/src/styles/screens/netBankingScreenStyles.ts +0 -83
- package/src/styles/screens/savedAddressScreenStyles.ts +0 -49
- package/src/styles/screens/selectTenureScreenStyles.ts +0 -37
- package/src/styles/screens/upiScreenStyles.ts +0 -167
- package/src/styles/screens/upiTimerScreenStyle.ts +0 -91
- package/src/styles/screens/walletScreenStyles.ts +0 -95
- package/src/utility.ts +0 -238
|
@@ -1,219 +0,0 @@
|
|
|
1
|
-
import { View, Text, Pressable, Image } from 'react-native';
|
|
2
|
-
import { checkoutDetailsHandler } from '../sharedContext/checkoutDetailsHandler';
|
|
3
|
-
import { userDataHandler } from '../sharedContext/userdataHandler';
|
|
4
|
-
import styles from '../styles/components/addressCardStyles';
|
|
5
|
-
|
|
6
|
-
interface AddressCardProps {
|
|
7
|
-
address:string,
|
|
8
|
-
navigateToAddressScreen : ()=> void,
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
const AddressComponent = ({address, navigateToAddressScreen} : AddressCardProps) => {
|
|
12
|
-
const {checkoutDetails} = checkoutDetailsHandler
|
|
13
|
-
const {userData} = userDataHandler
|
|
14
|
-
return (
|
|
15
|
-
<View>
|
|
16
|
-
{address != '' && checkoutDetails.isShippingAddressEnabled && (
|
|
17
|
-
<View>
|
|
18
|
-
<Text
|
|
19
|
-
style={[styles.titleText, {fontFamily : checkoutDetails.fontFamily.semiBold}]}
|
|
20
|
-
>
|
|
21
|
-
Address
|
|
22
|
-
</Text>
|
|
23
|
-
<Pressable
|
|
24
|
-
style={[styles.pressableContainer, {borderRadius: checkoutDetails.ctaBorderRadius,}]}
|
|
25
|
-
onPress={() => {
|
|
26
|
-
if (checkoutDetails.isShippingAddressEditable) {
|
|
27
|
-
navigateToAddressScreen();
|
|
28
|
-
}
|
|
29
|
-
}}
|
|
30
|
-
>
|
|
31
|
-
<Image
|
|
32
|
-
source={require('../../assets/images/ic_location.png')}
|
|
33
|
-
style={styles.imageStyle}
|
|
34
|
-
/>
|
|
35
|
-
<View
|
|
36
|
-
style={styles.insideContainer}
|
|
37
|
-
>
|
|
38
|
-
<Text
|
|
39
|
-
style={[styles.insideContainerNormalText, {fontFamily: checkoutDetails.fontFamily.regular}]}
|
|
40
|
-
>
|
|
41
|
-
Deliver at{' '}
|
|
42
|
-
<Text
|
|
43
|
-
style={[styles.insideContainerHighlighedText, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
44
|
-
>
|
|
45
|
-
{userData.labelType === 'Other' ? userData.labelName : userData.labelType}
|
|
46
|
-
</Text>
|
|
47
|
-
</Text>
|
|
48
|
-
<Text
|
|
49
|
-
numberOfLines={1}
|
|
50
|
-
ellipsizeMode="tail"
|
|
51
|
-
style={[styles.insideContainerDesc, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
52
|
-
>
|
|
53
|
-
{address}
|
|
54
|
-
</Text>
|
|
55
|
-
</View>
|
|
56
|
-
{checkoutDetails.isShippingAddressEditable && (
|
|
57
|
-
<Image
|
|
58
|
-
source={require('../../assets/images/chervon-down.png')}
|
|
59
|
-
style={{
|
|
60
|
-
alignSelf: 'center',
|
|
61
|
-
height: 6,
|
|
62
|
-
width: 14,
|
|
63
|
-
marginTop : 4,
|
|
64
|
-
marginRight :10,
|
|
65
|
-
transform: [
|
|
66
|
-
{
|
|
67
|
-
rotate: '270deg',
|
|
68
|
-
},
|
|
69
|
-
],
|
|
70
|
-
}}
|
|
71
|
-
/>
|
|
72
|
-
)}
|
|
73
|
-
</Pressable>
|
|
74
|
-
</View>
|
|
75
|
-
)}
|
|
76
|
-
|
|
77
|
-
{address == '' && checkoutDetails.isShippingAddressEnabled && (
|
|
78
|
-
<View>
|
|
79
|
-
<Text
|
|
80
|
-
style={[styles.titleText, {fontFamily : checkoutDetails.fontFamily.semiBold}]}
|
|
81
|
-
>
|
|
82
|
-
Address
|
|
83
|
-
</Text>
|
|
84
|
-
<Pressable
|
|
85
|
-
style={[styles.pressableContainer, {borderRadius: checkoutDetails.ctaBorderRadius,}]}
|
|
86
|
-
onPress={() => {
|
|
87
|
-
if (checkoutDetails.isShippingAddressEditable) {
|
|
88
|
-
navigateToAddressScreen();
|
|
89
|
-
}
|
|
90
|
-
}}
|
|
91
|
-
>
|
|
92
|
-
<Image
|
|
93
|
-
source={require('../../assets/images/add_icon.png')}
|
|
94
|
-
style={[styles.imageStyle, {tintColor: checkoutDetails.buttonColor}]}
|
|
95
|
-
/>
|
|
96
|
-
<Text
|
|
97
|
-
numberOfLines={1}
|
|
98
|
-
ellipsizeMode="tail"
|
|
99
|
-
style={[styles.insideContainerClickableText, {color: checkoutDetails.buttonColor,
|
|
100
|
-
fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
101
|
-
>
|
|
102
|
-
Add new address
|
|
103
|
-
</Text>
|
|
104
|
-
{checkoutDetails.isShippingAddressEditable && (
|
|
105
|
-
<Image
|
|
106
|
-
source={require('../../assets/images/chervon-down.png')}
|
|
107
|
-
style={{
|
|
108
|
-
alignSelf: 'center',
|
|
109
|
-
height: 6,
|
|
110
|
-
width: 14,
|
|
111
|
-
marginTop : 14,
|
|
112
|
-
marginRight :10,
|
|
113
|
-
marginLeft: 'auto',
|
|
114
|
-
transform: [
|
|
115
|
-
{
|
|
116
|
-
rotate: '270deg',
|
|
117
|
-
},
|
|
118
|
-
],
|
|
119
|
-
}}
|
|
120
|
-
/>
|
|
121
|
-
)}
|
|
122
|
-
</Pressable>
|
|
123
|
-
</View>
|
|
124
|
-
)}
|
|
125
|
-
|
|
126
|
-
{(checkoutDetails.isFullNameEnabled || checkoutDetails.isPhoneEnabled || checkoutDetails.isEmailEnabled) &&
|
|
127
|
-
!checkoutDetails.isShippingAddressEnabled && (
|
|
128
|
-
<View>
|
|
129
|
-
<Text
|
|
130
|
-
style={[styles.titleText, {fontFamily : checkoutDetails.fontFamily.semiBold}]}
|
|
131
|
-
>
|
|
132
|
-
Personal Details
|
|
133
|
-
</Text>
|
|
134
|
-
<Pressable
|
|
135
|
-
style={[styles.pressableContainer, {borderRadius: checkoutDetails.ctaBorderRadius,}]}
|
|
136
|
-
onPress={() => {
|
|
137
|
-
if (
|
|
138
|
-
checkoutDetails.isFullNameEditable ||
|
|
139
|
-
checkoutDetails.isPhoneEditable ||
|
|
140
|
-
checkoutDetails.isEmailEditable
|
|
141
|
-
) {
|
|
142
|
-
navigateToAddressScreen();
|
|
143
|
-
}
|
|
144
|
-
}}
|
|
145
|
-
>
|
|
146
|
-
{(userData.firstName != '' || userData.completePhoneNumber != '' || userData.email != '') && (
|
|
147
|
-
<>
|
|
148
|
-
<Image
|
|
149
|
-
source={require('../../assets/images/ic_user.png')}
|
|
150
|
-
style={styles.imageStyle}
|
|
151
|
-
/>
|
|
152
|
-
<View
|
|
153
|
-
style={styles.insideContainer}
|
|
154
|
-
>
|
|
155
|
-
<Text
|
|
156
|
-
style={[styles.insideContainerHighlighedText, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
157
|
-
>
|
|
158
|
-
{userData.firstName} {userData.lastName} | {' '}
|
|
159
|
-
<Text
|
|
160
|
-
style={[styles.insideContainerHighlighedText, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
161
|
-
>
|
|
162
|
-
{userData.completePhoneNumber}
|
|
163
|
-
</Text>
|
|
164
|
-
</Text>
|
|
165
|
-
<Text
|
|
166
|
-
numberOfLines={1}
|
|
167
|
-
ellipsizeMode="tail"
|
|
168
|
-
style={[styles.insideContainerDesc, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
169
|
-
>
|
|
170
|
-
{userData.email}
|
|
171
|
-
</Text>
|
|
172
|
-
</View>
|
|
173
|
-
</>
|
|
174
|
-
)}
|
|
175
|
-
{(userData.firstName == '' || userData.completePhoneNumber == '' || userData.email == '') && (
|
|
176
|
-
<>
|
|
177
|
-
<Image
|
|
178
|
-
source={require('../../assets/images/add_icon.png')}
|
|
179
|
-
style={styles.imageStyle}
|
|
180
|
-
/>
|
|
181
|
-
<Text
|
|
182
|
-
numberOfLines={1}
|
|
183
|
-
ellipsizeMode="tail"
|
|
184
|
-
style={[styles.insideContainerClickableText, {color: checkoutDetails.buttonColor,
|
|
185
|
-
fontFamily: checkoutDetails.fontFamily.semiBold,}]}
|
|
186
|
-
>
|
|
187
|
-
Add personal details
|
|
188
|
-
</Text>
|
|
189
|
-
</>
|
|
190
|
-
)}
|
|
191
|
-
|
|
192
|
-
{(checkoutDetails.isFullNameEditable ||
|
|
193
|
-
checkoutDetails.isPhoneEditable ||
|
|
194
|
-
checkoutDetails.isEmailEditable) && (
|
|
195
|
-
<Image
|
|
196
|
-
source={require('../../assets/images/chervon-down.png')}
|
|
197
|
-
style={{
|
|
198
|
-
alignSelf: 'center',
|
|
199
|
-
height: 6,
|
|
200
|
-
width: 14,
|
|
201
|
-
marginTop : 14,
|
|
202
|
-
marginRight :4,
|
|
203
|
-
marginLeft: 'auto',
|
|
204
|
-
transform: [
|
|
205
|
-
{
|
|
206
|
-
rotate: '270deg',
|
|
207
|
-
},
|
|
208
|
-
],
|
|
209
|
-
}}
|
|
210
|
-
/>
|
|
211
|
-
)}
|
|
212
|
-
</Pressable>
|
|
213
|
-
</View>
|
|
214
|
-
)}
|
|
215
|
-
</View>
|
|
216
|
-
)
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
export default AddressComponent
|
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
View,
|
|
4
|
-
Text,
|
|
5
|
-
StyleSheet,
|
|
6
|
-
TouchableOpacity,
|
|
7
|
-
Image,
|
|
8
|
-
} from 'react-native';
|
|
9
|
-
import { checkoutDetailsHandler } from '../sharedContext/checkoutDetailsHandler';
|
|
10
|
-
|
|
11
|
-
interface Props {
|
|
12
|
-
selectedColor: string;
|
|
13
|
-
code: string;
|
|
14
|
-
description: string;
|
|
15
|
-
discountAmount: string;
|
|
16
|
-
currencySymbol: string;
|
|
17
|
-
isCodeApplied: boolean;
|
|
18
|
-
|
|
19
|
-
onClickApply: (code: string) => void;
|
|
20
|
-
onClickRemove: () => void;
|
|
21
|
-
onClickViewAll: () => void;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
const ApplyCouponCard: React.FC<Props> = ({
|
|
25
|
-
selectedColor,
|
|
26
|
-
code,
|
|
27
|
-
description,
|
|
28
|
-
discountAmount,
|
|
29
|
-
currencySymbol,
|
|
30
|
-
isCodeApplied,
|
|
31
|
-
onClickApply,
|
|
32
|
-
onClickRemove,
|
|
33
|
-
onClickViewAll,
|
|
34
|
-
}) => {
|
|
35
|
-
const {checkoutDetails} = checkoutDetailsHandler
|
|
36
|
-
return (
|
|
37
|
-
<View style={styles.container}>
|
|
38
|
-
{/* Top Row */}
|
|
39
|
-
<View style={styles.row}>
|
|
40
|
-
{/* Offer Icon */}
|
|
41
|
-
<View style={styles.iconWrapper}>
|
|
42
|
-
<Image
|
|
43
|
-
source={require('../../assets/images/ic_offer_tag.png')}
|
|
44
|
-
style={[
|
|
45
|
-
styles.icon,{
|
|
46
|
-
transform: [
|
|
47
|
-
{
|
|
48
|
-
rotate: '180deg',
|
|
49
|
-
},
|
|
50
|
-
],
|
|
51
|
-
}
|
|
52
|
-
]}
|
|
53
|
-
resizeMode="contain"
|
|
54
|
-
/>
|
|
55
|
-
</View>
|
|
56
|
-
|
|
57
|
-
{/* Text Section */}
|
|
58
|
-
<View style={styles.textContainer}>
|
|
59
|
-
<Text style={[styles.codeText, {fontFamily : checkoutDetails.fontFamily.semiBold}]}>
|
|
60
|
-
{isCodeApplied ? `${code} Applied!` : code}
|
|
61
|
-
</Text>
|
|
62
|
-
|
|
63
|
-
{isCodeApplied ? (
|
|
64
|
-
<Text style={[styles.savedText, {fontFamily : checkoutDetails.fontFamily.regular}]}>
|
|
65
|
-
Yay! You saved{' '}
|
|
66
|
-
<Text style={[styles.currency, {fontFamily : checkoutDetails.fontFamily.semiBold}]}>
|
|
67
|
-
{currencySymbol}
|
|
68
|
-
</Text>
|
|
69
|
-
{discountAmount} on this order
|
|
70
|
-
</Text>
|
|
71
|
-
) : (
|
|
72
|
-
<Text
|
|
73
|
-
numberOfLines={1}
|
|
74
|
-
ellipsizeMode="tail"
|
|
75
|
-
style={[styles.description, {fontFamily : checkoutDetails.fontFamily.regular}]}
|
|
76
|
-
>
|
|
77
|
-
{description}
|
|
78
|
-
</Text>
|
|
79
|
-
)}
|
|
80
|
-
</View>
|
|
81
|
-
|
|
82
|
-
{/* Apply / Remove */}
|
|
83
|
-
<TouchableOpacity
|
|
84
|
-
onPress={() =>
|
|
85
|
-
isCodeApplied
|
|
86
|
-
? onClickRemove()
|
|
87
|
-
: onClickApply(code)
|
|
88
|
-
}
|
|
89
|
-
>
|
|
90
|
-
<Text
|
|
91
|
-
style={[
|
|
92
|
-
styles.actionText,
|
|
93
|
-
{
|
|
94
|
-
color: isCodeApplied
|
|
95
|
-
? '#E84142'
|
|
96
|
-
: selectedColor,
|
|
97
|
-
},
|
|
98
|
-
]}
|
|
99
|
-
>
|
|
100
|
-
{isCodeApplied ? 'Remove' : 'Apply'}
|
|
101
|
-
</Text>
|
|
102
|
-
</TouchableOpacity>
|
|
103
|
-
</View>
|
|
104
|
-
|
|
105
|
-
{/* Divider */}
|
|
106
|
-
<View style={styles.divider} />
|
|
107
|
-
|
|
108
|
-
{/* View All */}
|
|
109
|
-
<TouchableOpacity onPress={onClickViewAll}>
|
|
110
|
-
<Text
|
|
111
|
-
style={[
|
|
112
|
-
styles.viewAll,
|
|
113
|
-
{ color: selectedColor,
|
|
114
|
-
fontFamily : checkoutDetails.fontFamily.semiBold
|
|
115
|
-
},
|
|
116
|
-
]}
|
|
117
|
-
>
|
|
118
|
-
View All >
|
|
119
|
-
</Text>
|
|
120
|
-
</TouchableOpacity>
|
|
121
|
-
</View>
|
|
122
|
-
);
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
export default ApplyCouponCard;
|
|
126
|
-
|
|
127
|
-
const styles = StyleSheet.create({
|
|
128
|
-
container: {
|
|
129
|
-
backgroundColor: '#FFF',
|
|
130
|
-
borderRadius: 10,
|
|
131
|
-
overflow: 'hidden',
|
|
132
|
-
},
|
|
133
|
-
|
|
134
|
-
row: {
|
|
135
|
-
flexDirection: 'row',
|
|
136
|
-
alignItems: 'center',
|
|
137
|
-
paddingHorizontal: 16,
|
|
138
|
-
paddingVertical: 8,
|
|
139
|
-
},
|
|
140
|
-
|
|
141
|
-
iconWrapper: {
|
|
142
|
-
borderWidth: 1,
|
|
143
|
-
borderColor: '#E6E6E6',
|
|
144
|
-
borderRadius: 6,
|
|
145
|
-
padding: 6,
|
|
146
|
-
},
|
|
147
|
-
|
|
148
|
-
icon: {
|
|
149
|
-
width: 24,
|
|
150
|
-
height: 24,
|
|
151
|
-
},
|
|
152
|
-
|
|
153
|
-
textContainer: {
|
|
154
|
-
flex: 1,
|
|
155
|
-
marginLeft: 6,
|
|
156
|
-
marginRight: 18,
|
|
157
|
-
},
|
|
158
|
-
|
|
159
|
-
codeText: {
|
|
160
|
-
fontSize: 14,
|
|
161
|
-
fontWeight: '600',
|
|
162
|
-
color: '#1C1D20',
|
|
163
|
-
},
|
|
164
|
-
|
|
165
|
-
description: {
|
|
166
|
-
fontSize: 12,
|
|
167
|
-
color: '#1C1D20',
|
|
168
|
-
marginTop: 2,
|
|
169
|
-
},
|
|
170
|
-
|
|
171
|
-
savedText: {
|
|
172
|
-
fontSize: 12,
|
|
173
|
-
color: '#019939',
|
|
174
|
-
marginTop: 2,
|
|
175
|
-
},
|
|
176
|
-
|
|
177
|
-
currency: {
|
|
178
|
-
fontWeight: '600',
|
|
179
|
-
},
|
|
180
|
-
|
|
181
|
-
actionText: {
|
|
182
|
-
fontSize: 14,
|
|
183
|
-
fontWeight: '600',
|
|
184
|
-
},
|
|
185
|
-
|
|
186
|
-
divider: {
|
|
187
|
-
height: 1,
|
|
188
|
-
backgroundColor: '#E6E6E6',
|
|
189
|
-
},
|
|
190
|
-
|
|
191
|
-
viewAll: {
|
|
192
|
-
textAlign: 'center',
|
|
193
|
-
paddingVertical: 10,
|
|
194
|
-
fontSize: 14,
|
|
195
|
-
fontWeight: '600',
|
|
196
|
-
},
|
|
197
|
-
});
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { View, Text, Image, TouchableOpacity } from 'react-native';
|
|
3
|
-
import styles from '../styles/components/bankCardStyles';
|
|
4
|
-
import ImageLoader from './imageLoader';
|
|
5
|
-
import { checkoutDetailsHandler } from '../sharedContext/checkoutDetailsHandler';
|
|
6
|
-
|
|
7
|
-
interface BankCardProps {
|
|
8
|
-
name: string;
|
|
9
|
-
iconUrl: string;
|
|
10
|
-
hasNoCostEmi: boolean;
|
|
11
|
-
hasLowCostEmi: boolean;
|
|
12
|
-
onPress: () => void;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
const BankCard: React.FC<BankCardProps> = ({
|
|
16
|
-
name,
|
|
17
|
-
iconUrl,
|
|
18
|
-
hasNoCostEmi,
|
|
19
|
-
hasLowCostEmi,
|
|
20
|
-
onPress,
|
|
21
|
-
}) => {
|
|
22
|
-
const {checkoutDetails} = checkoutDetailsHandler
|
|
23
|
-
return (
|
|
24
|
-
<TouchableOpacity style={styles.container} onPress={onPress}>
|
|
25
|
-
<ImageLoader image={iconUrl} errorImage={require('../../assets/images/ic_netbanking_semi_bold.png')}/>
|
|
26
|
-
<View style={styles.detailsContainer}>
|
|
27
|
-
<Text style={[styles.bankName, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}>{name}</Text>
|
|
28
|
-
<View style={styles.tagsContainer}>
|
|
29
|
-
{hasNoCostEmi && (
|
|
30
|
-
<View style={styles.tag}>
|
|
31
|
-
<Text style={[styles.tagText, {fontFamily: checkoutDetails.fontFamily.medium,}]}>NO COST EMI</Text>
|
|
32
|
-
</View>
|
|
33
|
-
)}
|
|
34
|
-
{hasLowCostEmi && (
|
|
35
|
-
<View style={styles.tag}>
|
|
36
|
-
<Text style={[styles.tagText, {fontFamily: checkoutDetails.fontFamily.medium,}]}>LOW COST EMI</Text>
|
|
37
|
-
</View>
|
|
38
|
-
)}
|
|
39
|
-
</View>
|
|
40
|
-
</View>
|
|
41
|
-
|
|
42
|
-
<Image
|
|
43
|
-
source={require('../../assets/images/chervon-down.png')}
|
|
44
|
-
style={styles.chervonImage}
|
|
45
|
-
/>
|
|
46
|
-
</TouchableOpacity>
|
|
47
|
-
);
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
export default BankCard;
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { View, Text, Image, Pressable } from 'react-native';
|
|
3
|
-
import Modal from 'react-native-modal';
|
|
4
|
-
import { checkoutDetailsHandler } from '../sharedContext/checkoutDetailsHandler';
|
|
5
|
-
import styles from '../styles/components/cancelPaymentModalStyles';
|
|
6
|
-
|
|
7
|
-
interface CancelPaymentModalProps {
|
|
8
|
-
onYesClick: () => void;
|
|
9
|
-
onNoClick: () => void;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
const CancelPaymentModal: React.FC<CancelPaymentModalProps> = ({
|
|
13
|
-
onYesClick,
|
|
14
|
-
onNoClick,
|
|
15
|
-
}) => {
|
|
16
|
-
const { checkoutDetails } = checkoutDetailsHandler;
|
|
17
|
-
|
|
18
|
-
return (
|
|
19
|
-
<View style={styles.modalContainer}>
|
|
20
|
-
<Modal isVisible={true} style={styles.modal}>
|
|
21
|
-
<View style={styles.modalContent}>
|
|
22
|
-
<View style={styles.iconContainer}>
|
|
23
|
-
<Image
|
|
24
|
-
source={require('../../assets/images/ic_info.png')}
|
|
25
|
-
style={styles.iconImage}
|
|
26
|
-
/>
|
|
27
|
-
<Text style={[styles.modalTitle, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}>Cancel Transaction?</Text>
|
|
28
|
-
</View>
|
|
29
|
-
<Text style={[styles.modalText, {fontFamily: checkoutDetails.fontFamily.regular,}]}>
|
|
30
|
-
Are you sure you want to cancel the transaction?
|
|
31
|
-
</Text>
|
|
32
|
-
|
|
33
|
-
<View style={styles.buttonContainer}>
|
|
34
|
-
<Pressable
|
|
35
|
-
style={[
|
|
36
|
-
styles.cancelButton,
|
|
37
|
-
{ borderColor: '#E6E6E6', borderWidth: 1, borderRadius: checkoutDetails.ctaBorderRadius, },
|
|
38
|
-
]}
|
|
39
|
-
onPress={onNoClick}
|
|
40
|
-
>
|
|
41
|
-
<Text
|
|
42
|
-
style={[
|
|
43
|
-
styles.buttonText,
|
|
44
|
-
{ color: checkoutDetails.buttonColor,
|
|
45
|
-
fontFamily: checkoutDetails.fontFamily.regular,
|
|
46
|
-
},
|
|
47
|
-
]}
|
|
48
|
-
>
|
|
49
|
-
Not now
|
|
50
|
-
</Text>
|
|
51
|
-
</Pressable>
|
|
52
|
-
<Pressable
|
|
53
|
-
style={[
|
|
54
|
-
styles.confirmButton,
|
|
55
|
-
{ backgroundColor: checkoutDetails.buttonColor, borderRadius: checkoutDetails.ctaBorderRadius, },
|
|
56
|
-
]}
|
|
57
|
-
onPress={onYesClick}
|
|
58
|
-
>
|
|
59
|
-
<Text style={[styles.confirmButtonText, {fontFamily: checkoutDetails.fontFamily.semiBold,}]}>Yes</Text>
|
|
60
|
-
</Pressable>
|
|
61
|
-
</View>
|
|
62
|
-
</View>
|
|
63
|
-
</Modal>
|
|
64
|
-
</View>
|
|
65
|
-
);
|
|
66
|
-
};
|
|
67
|
-
|
|
68
|
-
export default CancelPaymentModal;
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import { View, Text, TouchableOpacity, StyleSheet } from 'react-native';
|
|
2
|
-
import { checkoutDetailsHandler } from '../sharedContext/checkoutDetailsHandler';
|
|
3
|
-
|
|
4
|
-
interface CheckBoxContainerProps {
|
|
5
|
-
text : string,
|
|
6
|
-
isCheckBoxSelected : boolean,
|
|
7
|
-
onCheckBoxClicked : () => void
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const CheckBoxContainer = ({text, isCheckBoxSelected, onCheckBoxClicked} : CheckBoxContainerProps) =>{
|
|
11
|
-
const {checkoutDetails} = checkoutDetailsHandler
|
|
12
|
-
const {isSICheckboxEnabled} = checkoutDetails
|
|
13
|
-
return(
|
|
14
|
-
<View
|
|
15
|
-
style={styles.checkBoxContainer}>
|
|
16
|
-
<TouchableOpacity
|
|
17
|
-
onPress={() => onCheckBoxClicked()}
|
|
18
|
-
disabled={!isSICheckboxEnabled}
|
|
19
|
-
>
|
|
20
|
-
<View style={[
|
|
21
|
-
styles.checkboxBox,
|
|
22
|
-
{ borderColor: checkoutDetails.buttonColor },
|
|
23
|
-
!isSICheckboxEnabled && styles.disabledBox,
|
|
24
|
-
isCheckBoxSelected && { backgroundColor: checkoutDetails.buttonColor }
|
|
25
|
-
]}>
|
|
26
|
-
{isCheckBoxSelected && (
|
|
27
|
-
<Text style={styles.checkmark}>✓</Text>
|
|
28
|
-
)}
|
|
29
|
-
</View>
|
|
30
|
-
</TouchableOpacity>
|
|
31
|
-
<Text
|
|
32
|
-
style={[styles.checkBoxText, {fontFamily: checkoutDetails.fontFamily.regular},!isSICheckboxEnabled && styles.disabledText]}
|
|
33
|
-
>
|
|
34
|
-
{text}
|
|
35
|
-
</Text>
|
|
36
|
-
</View>
|
|
37
|
-
)
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
const styles = StyleSheet.create({
|
|
41
|
-
checkBoxContainer : {
|
|
42
|
-
flexDirection: 'row',
|
|
43
|
-
marginTop: 10,
|
|
44
|
-
alignItems: 'center',
|
|
45
|
-
marginHorizontal: 16
|
|
46
|
-
},
|
|
47
|
-
checkBoxText : {
|
|
48
|
-
color: '#2D2B32',
|
|
49
|
-
fontSize: 14,
|
|
50
|
-
marginLeft: 6
|
|
51
|
-
},
|
|
52
|
-
checkboxBox: {
|
|
53
|
-
width: 20,
|
|
54
|
-
height: 20,
|
|
55
|
-
borderWidth: 2,
|
|
56
|
-
borderRadius: 3,
|
|
57
|
-
justifyContent: 'center',
|
|
58
|
-
alignItems: 'center'
|
|
59
|
-
},
|
|
60
|
-
checkmark: {
|
|
61
|
-
color: '#fff',
|
|
62
|
-
fontSize: 13,
|
|
63
|
-
fontWeight: 'bold',
|
|
64
|
-
lineHeight: 16,
|
|
65
|
-
},
|
|
66
|
-
disabledBox: {
|
|
67
|
-
opacity: 0.4
|
|
68
|
-
},
|
|
69
|
-
disabledText: {
|
|
70
|
-
opacity: 0.4
|
|
71
|
-
}
|
|
72
|
-
});
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
export default CheckBoxContainer
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import { useEffect, useRef } from 'react';
|
|
2
|
-
import { View, Text, Animated, Easing } from 'react-native';
|
|
3
|
-
import { Svg, Circle } from 'react-native-svg';
|
|
4
|
-
import { checkoutDetailsHandler } from '../sharedContext/checkoutDetailsHandler';
|
|
5
|
-
|
|
6
|
-
const AnimatedCircle = Animated.createAnimatedComponent(Circle);
|
|
7
|
-
|
|
8
|
-
const CircularProgressBar = ({
|
|
9
|
-
size = 100,
|
|
10
|
-
strokeWidth = 10,
|
|
11
|
-
progress = 75,
|
|
12
|
-
textColor = '#3498db',
|
|
13
|
-
formatTime = '05:00',
|
|
14
|
-
progressColor = '#3498db',
|
|
15
|
-
}) => {
|
|
16
|
-
const animatedValue = useRef(new Animated.Value(0)).current;
|
|
17
|
-
const radius = (size - strokeWidth) / 2;
|
|
18
|
-
const circumference = 2 * Math.PI * radius;
|
|
19
|
-
const {fontFamily} = checkoutDetailsHandler.checkoutDetails
|
|
20
|
-
|
|
21
|
-
useEffect(() => {
|
|
22
|
-
Animated.timing(animatedValue, {
|
|
23
|
-
toValue: (progress / (5 * 60)) * 100, // Convert timerValue to percentage
|
|
24
|
-
duration: 500, // Smooth animation
|
|
25
|
-
easing: Easing.linear,
|
|
26
|
-
useNativeDriver: false,
|
|
27
|
-
}).start();
|
|
28
|
-
}, [progress]);
|
|
29
|
-
|
|
30
|
-
const strokeDashoffset = animatedValue.interpolate({
|
|
31
|
-
inputRange: [0, 100],
|
|
32
|
-
outputRange: [circumference, 0], // Full circle to empty
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
return (
|
|
36
|
-
<View style={{ alignItems: 'center', justifyContent: 'center' }}>
|
|
37
|
-
<Svg width={size} height={size}>
|
|
38
|
-
{/* Background Circle */}
|
|
39
|
-
<Circle
|
|
40
|
-
cx={size / 2}
|
|
41
|
-
cy={size / 2}
|
|
42
|
-
r={radius}
|
|
43
|
-
stroke="#e0e0e0"
|
|
44
|
-
strokeWidth={strokeWidth}
|
|
45
|
-
fill="none"
|
|
46
|
-
/>
|
|
47
|
-
{/* Animated Progress Circle */}
|
|
48
|
-
<AnimatedCircle
|
|
49
|
-
cx={size / 2}
|
|
50
|
-
cy={size / 2}
|
|
51
|
-
r={radius}
|
|
52
|
-
stroke={progressColor}
|
|
53
|
-
strokeWidth={strokeWidth}
|
|
54
|
-
fill="none"
|
|
55
|
-
strokeDasharray={circumference}
|
|
56
|
-
strokeDashoffset={strokeDashoffset}
|
|
57
|
-
strokeLinecap="round"
|
|
58
|
-
/>
|
|
59
|
-
</Svg>
|
|
60
|
-
<Text
|
|
61
|
-
style={{
|
|
62
|
-
position: 'absolute',
|
|
63
|
-
fontSize: 22,
|
|
64
|
-
fontFamily: fontFamily.semiBold,
|
|
65
|
-
color: textColor,
|
|
66
|
-
}}
|
|
67
|
-
>
|
|
68
|
-
{formatTime}
|
|
69
|
-
</Text>
|
|
70
|
-
</View>
|
|
71
|
-
);
|
|
72
|
-
};
|
|
73
|
-
|
|
74
|
-
export default CircularProgressBar;
|