@stripe/stripe-react-native 0.41.0 → 0.43.0

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.
Files changed (314) hide show
  1. package/.husky/pre-commit +0 -3
  2. package/CHANGELOG.md +27 -0
  3. package/README.md +3 -0
  4. package/android/.gradle/8.11.1/checksums/checksums.lock +0 -0
  5. package/android/.gradle/8.11.1/checksums/md5-checksums.bin +0 -0
  6. package/android/.gradle/8.11.1/checksums/sha1-checksums.bin +0 -0
  7. package/android/.gradle/8.11.1/executionHistory/executionHistory.lock +0 -0
  8. package/android/.gradle/8.11.1/fileChanges/last-build.bin +0 -0
  9. package/android/.gradle/8.11.1/fileHashes/fileHashes.lock +0 -0
  10. package/android/.gradle/8.11.1/gc.properties +0 -0
  11. package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  12. package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
  13. package/android/.gradle/vcs-1/gc.properties +0 -0
  14. package/android/build.gradle +7 -1
  15. package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  16. package/android/gradle/wrapper/gradle-wrapper.properties +7 -0
  17. package/android/gradle.properties +4 -1
  18. package/android/gradlew +249 -0
  19. package/android/gradlew.bat +92 -0
  20. package/android/spotless.gradle +19 -0
  21. package/android/src/main/java/com/reactnativestripesdk/AuBECSDebitFormView.kt +30 -34
  22. package/android/src/main/java/com/reactnativestripesdk/AuBECSDebitFormViewManager.kt +20 -10
  23. package/android/src/main/java/com/reactnativestripesdk/CardChangedEvent.kt +12 -13
  24. package/android/src/main/java/com/reactnativestripesdk/CardFieldView.kt +242 -105
  25. package/android/src/main/java/com/reactnativestripesdk/CardFieldViewManager.kt +58 -20
  26. package/android/src/main/java/com/reactnativestripesdk/CardFocusEvent.kt +8 -11
  27. package/android/src/main/java/com/reactnativestripesdk/CardFormCompleteEvent.kt +10 -12
  28. package/android/src/main/java/com/reactnativestripesdk/CardFormView.kt +135 -87
  29. package/android/src/main/java/com/reactnativestripesdk/CardFormViewManager.kt +57 -22
  30. package/android/src/main/java/com/reactnativestripesdk/CollectBankAccountLauncherFragment.kt +53 -23
  31. package/android/src/main/java/com/reactnativestripesdk/FinancialConnectionsSheetFragment.kt +125 -83
  32. package/android/src/main/java/com/reactnativestripesdk/FormCompleteEvent.kt +9 -11
  33. package/android/src/main/java/com/reactnativestripesdk/GooglePayButtonManager.kt +16 -9
  34. package/android/src/main/java/com/reactnativestripesdk/GooglePayButtonView.kt +36 -28
  35. package/android/src/main/java/com/reactnativestripesdk/GooglePayLauncherFragment.kt +67 -43
  36. package/android/src/main/java/com/reactnativestripesdk/GooglePayPaymentMethodLauncherFragment.kt +21 -16
  37. package/android/src/main/java/com/reactnativestripesdk/GooglePayRequestHelper.kt +101 -56
  38. package/android/src/main/java/com/reactnativestripesdk/PaymentLauncherFragment.kt +244 -166
  39. package/android/src/main/java/com/reactnativestripesdk/PaymentMethodCreateParamsFactory.kt +183 -123
  40. package/android/src/main/java/com/reactnativestripesdk/PaymentSheetAppearance.kt +181 -57
  41. package/android/src/main/java/com/reactnativestripesdk/PaymentSheetFragment.kt +402 -258
  42. package/android/src/main/java/com/reactnativestripesdk/StripeContainerManager.kt +11 -4
  43. package/android/src/main/java/com/reactnativestripesdk/StripeContainerView.kt +5 -1
  44. package/android/src/main/java/com/reactnativestripesdk/StripeSdkModule.kt +654 -299
  45. package/android/src/main/java/com/reactnativestripesdk/StripeSdkPackage.kt +12 -14
  46. package/android/src/main/java/com/reactnativestripesdk/addresssheet/AddressLauncherFragment.kt +42 -37
  47. package/android/src/main/java/com/reactnativestripesdk/addresssheet/AddressSheetEvent.kt +12 -11
  48. package/android/src/main/java/com/reactnativestripesdk/addresssheet/AddressSheetView.kt +29 -29
  49. package/android/src/main/java/com/reactnativestripesdk/addresssheet/AddressSheetViewManager.kt +50 -18
  50. package/android/src/main/java/com/reactnativestripesdk/customersheet/CustomerSheetFragment.kt +227 -147
  51. package/android/src/main/java/com/reactnativestripesdk/customersheet/ReactNativeCustomerAdapter.kt +15 -18
  52. package/android/src/main/java/com/reactnativestripesdk/pushprovisioning/AddToWalletButtonManager.kt +33 -15
  53. package/android/src/main/java/com/reactnativestripesdk/pushprovisioning/AddToWalletButtonView.kt +63 -37
  54. package/android/src/main/java/com/reactnativestripesdk/pushprovisioning/AddToWalletCompleteEvent.kt +9 -13
  55. package/android/src/main/java/com/reactnativestripesdk/pushprovisioning/EphemeralKeyProvider.kt +15 -17
  56. package/android/src/main/java/com/reactnativestripesdk/pushprovisioning/PushProvisioningProxy.kt +76 -60
  57. package/android/src/main/java/com/reactnativestripesdk/pushprovisioning/TapAndPayProxy.kt +71 -47
  58. package/android/src/main/java/com/reactnativestripesdk/utils/Errors.kt +117 -51
  59. package/android/src/main/java/com/reactnativestripesdk/utils/Extensions.kt +4 -3
  60. package/android/src/main/java/com/reactnativestripesdk/utils/KeepJsAwakeTask.kt +39 -0
  61. package/android/src/main/java/com/reactnativestripesdk/utils/Mappers.kt +337 -250
  62. package/android/src/main/java/com/reactnativestripesdk/utils/PostalCodeUtilities.kt +2 -11
  63. package/ios/CustomerSheet/CustomerSheetUtils.swift +3 -1
  64. package/ios/FinancialConnections.swift +18 -2
  65. package/ios/Mappers.swift +23 -0
  66. package/ios/PaymentMethodFactory.swift +31 -29
  67. package/ios/StripeSdk+CustomerSheet.swift +2 -1
  68. package/ios/StripeSdk+PaymentSheet.swift +42 -0
  69. package/ios/StripeSdk.m +2 -0
  70. package/ios/StripeSdk.swift +116 -24
  71. package/lib/commonjs/NativeStripeSdk.js +1 -1
  72. package/lib/commonjs/NativeStripeSdk.js.map +1 -1
  73. package/lib/commonjs/components/AddToWalletButton.js +1 -1
  74. package/lib/commonjs/components/AddToWalletButton.js.map +1 -1
  75. package/lib/commonjs/components/AddressSheet.js +1 -1
  76. package/lib/commonjs/components/AddressSheet.js.map +1 -1
  77. package/lib/commonjs/components/ApplePayButtonNative.js +1 -1
  78. package/lib/commonjs/components/ApplePayButtonNative.js.map +1 -1
  79. package/lib/commonjs/components/AuBECSDebitForm.js +1 -1
  80. package/lib/commonjs/components/AuBECSDebitForm.js.map +1 -1
  81. package/lib/commonjs/components/CardField.js +1 -1
  82. package/lib/commonjs/components/CardField.js.map +1 -1
  83. package/lib/commonjs/components/CardForm.js +1 -1
  84. package/lib/commonjs/components/CardForm.js.map +1 -1
  85. package/lib/commonjs/components/CustomerSheet.js +1 -1
  86. package/lib/commonjs/components/CustomerSheet.js.map +1 -1
  87. package/lib/commonjs/components/GooglePayButtonNative.js +1 -1
  88. package/lib/commonjs/components/GooglePayButtonNative.js.map +1 -1
  89. package/lib/commonjs/components/PlatformPayButton.js +1 -1
  90. package/lib/commonjs/components/PlatformPayButton.js.map +1 -1
  91. package/lib/commonjs/components/StripeContainer.js +1 -1
  92. package/lib/commonjs/components/StripeContainer.js.map +1 -1
  93. package/lib/commonjs/components/StripeProvider.js +1 -1
  94. package/lib/commonjs/components/StripeProvider.js.map +1 -1
  95. package/lib/commonjs/functions.js +1 -1
  96. package/lib/commonjs/functions.js.map +1 -1
  97. package/lib/commonjs/helpers.js +1 -1
  98. package/lib/commonjs/helpers.js.map +1 -1
  99. package/lib/commonjs/hooks/useConfirmPayment.js.map +1 -1
  100. package/lib/commonjs/hooks/useConfirmSetupIntent.js.map +1 -1
  101. package/lib/commonjs/hooks/useFinancialConnectionsSheet.js +1 -1
  102. package/lib/commonjs/hooks/useFinancialConnectionsSheet.js.map +1 -1
  103. package/lib/commonjs/hooks/usePaymentSheet.js.map +1 -1
  104. package/lib/commonjs/hooks/usePlatformPay.js.map +1 -1
  105. package/lib/commonjs/hooks/useStripe.js +1 -1
  106. package/lib/commonjs/hooks/useStripe.js.map +1 -1
  107. package/lib/commonjs/index.js.map +1 -1
  108. package/lib/commonjs/package.json +1 -0
  109. package/lib/commonjs/plugin/withStripe.js +1 -1
  110. package/lib/commonjs/plugin/withStripe.js.map +1 -1
  111. package/lib/commonjs/types/ApplePay.js.map +1 -1
  112. package/lib/commonjs/types/Common.js +1 -1
  113. package/lib/commonjs/types/Common.js.map +1 -1
  114. package/lib/commonjs/types/CustomerSheet.js.map +1 -1
  115. package/lib/commonjs/types/Errors.js +1 -1
  116. package/lib/commonjs/types/Errors.js.map +1 -1
  117. package/lib/commonjs/types/FinancialConnections.js +1 -1
  118. package/lib/commonjs/types/FinancialConnections.js.map +1 -1
  119. package/lib/commonjs/types/NextAction.js.map +1 -1
  120. package/lib/commonjs/types/PaymentIntent.js +1 -1
  121. package/lib/commonjs/types/PaymentIntent.js.map +1 -1
  122. package/lib/commonjs/types/PaymentMethod.js.map +1 -1
  123. package/lib/commonjs/types/PaymentSheet.js +1 -1
  124. package/lib/commonjs/types/PaymentSheet.js.map +1 -1
  125. package/lib/commonjs/types/PlatformPay.js +1 -1
  126. package/lib/commonjs/types/PlatformPay.js.map +1 -1
  127. package/lib/commonjs/types/PushProvisioning.js +1 -1
  128. package/lib/commonjs/types/PushProvisioning.js.map +1 -1
  129. package/lib/commonjs/types/SetupIntent.js +1 -1
  130. package/lib/commonjs/types/SetupIntent.js.map +1 -1
  131. package/lib/commonjs/types/ThreeDSecure.js +1 -1
  132. package/lib/commonjs/types/ThreeDSecure.js.map +1 -1
  133. package/lib/commonjs/types/Token.js.map +1 -1
  134. package/lib/commonjs/types/components/ApplePayButtonComponent.js.map +1 -1
  135. package/lib/commonjs/types/components/AuBECSDebitFormComponent.js.map +1 -1
  136. package/lib/commonjs/types/components/CardFieldInput.js +1 -1
  137. package/lib/commonjs/types/components/CardFieldInput.js.map +1 -1
  138. package/lib/commonjs/types/components/CardFormView.js.map +1 -1
  139. package/lib/commonjs/types/components/GooglePayButtonComponent.js.map +1 -1
  140. package/lib/commonjs/types/index.js +1 -1
  141. package/lib/commonjs/types/index.js.map +1 -1
  142. package/lib/module/NativeStripeSdk.js +1 -1
  143. package/lib/module/NativeStripeSdk.js.map +1 -1
  144. package/lib/module/components/AddToWalletButton.js +1 -1
  145. package/lib/module/components/AddToWalletButton.js.map +1 -1
  146. package/lib/module/components/AddressSheet.js +1 -1
  147. package/lib/module/components/AddressSheet.js.map +1 -1
  148. package/lib/module/components/ApplePayButtonNative.js +1 -1
  149. package/lib/module/components/ApplePayButtonNative.js.map +1 -1
  150. package/lib/module/components/AuBECSDebitForm.js +1 -1
  151. package/lib/module/components/AuBECSDebitForm.js.map +1 -1
  152. package/lib/module/components/CardField.js +1 -1
  153. package/lib/module/components/CardField.js.map +1 -1
  154. package/lib/module/components/CardForm.js +1 -1
  155. package/lib/module/components/CardForm.js.map +1 -1
  156. package/lib/module/components/CustomerSheet.js +1 -1
  157. package/lib/module/components/CustomerSheet.js.map +1 -1
  158. package/lib/module/components/GooglePayButtonNative.js +1 -1
  159. package/lib/module/components/GooglePayButtonNative.js.map +1 -1
  160. package/lib/module/components/PlatformPayButton.js +1 -1
  161. package/lib/module/components/PlatformPayButton.js.map +1 -1
  162. package/lib/module/components/StripeContainer.js +1 -1
  163. package/lib/module/components/StripeContainer.js.map +1 -1
  164. package/lib/module/components/StripeProvider.js +1 -1
  165. package/lib/module/components/StripeProvider.js.map +1 -1
  166. package/lib/module/functions.js +1 -1
  167. package/lib/module/functions.js.map +1 -1
  168. package/lib/module/helpers.js +1 -1
  169. package/lib/module/helpers.js.map +1 -1
  170. package/lib/module/hooks/useConfirmPayment.js.map +1 -1
  171. package/lib/module/hooks/useConfirmSetupIntent.js.map +1 -1
  172. package/lib/module/hooks/useFinancialConnectionsSheet.js +1 -1
  173. package/lib/module/hooks/useFinancialConnectionsSheet.js.map +1 -1
  174. package/lib/module/hooks/usePaymentSheet.js.map +1 -1
  175. package/lib/module/hooks/usePlatformPay.js.map +1 -1
  176. package/lib/module/hooks/useStripe.js +1 -1
  177. package/lib/module/hooks/useStripe.js.map +1 -1
  178. package/lib/module/index.js.map +1 -1
  179. package/lib/module/package.json +1 -0
  180. package/lib/module/plugin/withStripe.js +1 -1
  181. package/lib/module/plugin/withStripe.js.map +1 -1
  182. package/lib/module/types/ApplePay.js.map +1 -1
  183. package/lib/module/types/Common.js +1 -1
  184. package/lib/module/types/Common.js.map +1 -1
  185. package/lib/module/types/CustomerSheet.js.map +1 -1
  186. package/lib/module/types/Errors.js +1 -1
  187. package/lib/module/types/Errors.js.map +1 -1
  188. package/lib/module/types/FinancialConnections.js +1 -1
  189. package/lib/module/types/FinancialConnections.js.map +1 -1
  190. package/lib/module/types/NextAction.js.map +1 -1
  191. package/lib/module/types/PaymentIntent.js +1 -1
  192. package/lib/module/types/PaymentIntent.js.map +1 -1
  193. package/lib/module/types/PaymentMethod.js.map +1 -1
  194. package/lib/module/types/PaymentSheet.js +1 -1
  195. package/lib/module/types/PaymentSheet.js.map +1 -1
  196. package/lib/module/types/PlatformPay.js +1 -1
  197. package/lib/module/types/PlatformPay.js.map +1 -1
  198. package/lib/module/types/PushProvisioning.js +1 -1
  199. package/lib/module/types/PushProvisioning.js.map +1 -1
  200. package/lib/module/types/SetupIntent.js +1 -1
  201. package/lib/module/types/SetupIntent.js.map +1 -1
  202. package/lib/module/types/ThreeDSecure.js +1 -1
  203. package/lib/module/types/ThreeDSecure.js.map +1 -1
  204. package/lib/module/types/Token.js.map +1 -1
  205. package/lib/module/types/components/ApplePayButtonComponent.js.map +1 -1
  206. package/lib/module/types/components/AuBECSDebitFormComponent.js.map +1 -1
  207. package/lib/module/types/components/CardFieldInput.js +1 -1
  208. package/lib/module/types/components/CardFieldInput.js.map +1 -1
  209. package/lib/module/types/components/CardFormView.js.map +1 -1
  210. package/lib/module/types/components/GooglePayButtonComponent.js.map +1 -1
  211. package/lib/module/types/index.js +1 -1
  212. package/lib/module/types/index.js.map +1 -1
  213. package/lib/typescript/src/NativeStripeSdk.d.ts +5 -4
  214. package/lib/typescript/src/NativeStripeSdk.d.ts.map +1 -0
  215. package/lib/typescript/src/components/AddToWalletButton.d.ts +3 -1
  216. package/lib/typescript/src/components/AddToWalletButton.d.ts.map +1 -0
  217. package/lib/typescript/src/components/AddressSheet.d.ts +4 -2
  218. package/lib/typescript/src/components/AddressSheet.d.ts.map +1 -0
  219. package/lib/typescript/src/components/ApplePayButtonNative.d.ts +1 -0
  220. package/lib/typescript/src/components/ApplePayButtonNative.d.ts.map +1 -0
  221. package/lib/typescript/src/components/AuBECSDebitForm.d.ts +3 -1
  222. package/lib/typescript/src/components/AuBECSDebitForm.d.ts.map +1 -0
  223. package/lib/typescript/src/components/CardField.d.ts +1 -0
  224. package/lib/typescript/src/components/CardField.d.ts.map +1 -0
  225. package/lib/typescript/src/components/CardForm.d.ts +1 -0
  226. package/lib/typescript/src/components/CardForm.d.ts.map +1 -0
  227. package/lib/typescript/src/components/CustomerSheet.d.ts +2 -1
  228. package/lib/typescript/src/components/CustomerSheet.d.ts.map +1 -0
  229. package/lib/typescript/src/components/GooglePayButtonNative.d.ts +1 -0
  230. package/lib/typescript/src/components/GooglePayButtonNative.d.ts.map +1 -0
  231. package/lib/typescript/src/components/PlatformPayButton.d.ts +3 -1
  232. package/lib/typescript/src/components/PlatformPayButton.d.ts.map +1 -0
  233. package/lib/typescript/src/components/StripeContainer.d.ts +2 -1
  234. package/lib/typescript/src/components/StripeContainer.d.ts.map +1 -0
  235. package/lib/typescript/src/components/StripeProvider.d.ts +3 -2
  236. package/lib/typescript/src/components/StripeProvider.d.ts.map +1 -0
  237. package/lib/typescript/src/functions.d.ts +12 -7
  238. package/lib/typescript/src/functions.d.ts.map +1 -0
  239. package/lib/typescript/src/helpers.d.ts +1 -0
  240. package/lib/typescript/src/helpers.d.ts.map +1 -0
  241. package/lib/typescript/src/hooks/useConfirmPayment.d.ts +2 -1
  242. package/lib/typescript/src/hooks/useConfirmPayment.d.ts.map +1 -0
  243. package/lib/typescript/src/hooks/useConfirmSetupIntent.d.ts +1 -0
  244. package/lib/typescript/src/hooks/useConfirmSetupIntent.d.ts.map +1 -0
  245. package/lib/typescript/src/hooks/useFinancialConnectionsSheet.d.ts +5 -2
  246. package/lib/typescript/src/hooks/useFinancialConnectionsSheet.d.ts.map +1 -0
  247. package/lib/typescript/src/hooks/usePaymentSheet.d.ts +2 -1
  248. package/lib/typescript/src/hooks/usePaymentSheet.d.ts.map +1 -0
  249. package/lib/typescript/src/hooks/usePlatformPay.d.ts +4 -3
  250. package/lib/typescript/src/hooks/usePlatformPay.d.ts.map +1 -0
  251. package/lib/typescript/src/hooks/useStripe.d.ts +11 -8
  252. package/lib/typescript/src/hooks/useStripe.d.ts.map +1 -0
  253. package/lib/typescript/src/index.d.ts +1 -0
  254. package/lib/typescript/src/index.d.ts.map +1 -0
  255. package/lib/typescript/src/plugin/withStripe.d.ts +2 -1
  256. package/lib/typescript/src/plugin/withStripe.d.ts.map +1 -0
  257. package/lib/typescript/src/types/ApplePay.d.ts +6 -5
  258. package/lib/typescript/src/types/ApplePay.d.ts.map +1 -0
  259. package/lib/typescript/src/types/Common.d.ts +4 -1
  260. package/lib/typescript/src/types/Common.d.ts.map +1 -0
  261. package/lib/typescript/src/types/CustomerSheet.d.ts +12 -4
  262. package/lib/typescript/src/types/CustomerSheet.d.ts.map +1 -0
  263. package/lib/typescript/src/types/Errors.d.ts +2 -1
  264. package/lib/typescript/src/types/Errors.d.ts.map +1 -0
  265. package/lib/typescript/src/types/FinancialConnections.d.ts +82 -14
  266. package/lib/typescript/src/types/FinancialConnections.d.ts.map +1 -0
  267. package/lib/typescript/src/types/NextAction.d.ts +9 -8
  268. package/lib/typescript/src/types/NextAction.d.ts.map +1 -0
  269. package/lib/typescript/src/types/PaymentIntent.d.ts +41 -14
  270. package/lib/typescript/src/types/PaymentIntent.d.ts.map +1 -0
  271. package/lib/typescript/src/types/PaymentMethod.d.ts +27 -15
  272. package/lib/typescript/src/types/PaymentMethod.d.ts.map +1 -0
  273. package/lib/typescript/src/types/PaymentSheet.d.ts +72 -22
  274. package/lib/typescript/src/types/PaymentSheet.d.ts.map +1 -0
  275. package/lib/typescript/src/types/PlatformPay.d.ts +22 -21
  276. package/lib/typescript/src/types/PlatformPay.d.ts.map +1 -0
  277. package/lib/typescript/src/types/PushProvisioning.d.ts +5 -4
  278. package/lib/typescript/src/types/PushProvisioning.d.ts.map +1 -0
  279. package/lib/typescript/src/types/SetupIntent.d.ts +4 -3
  280. package/lib/typescript/src/types/SetupIntent.d.ts.map +1 -0
  281. package/lib/typescript/src/types/ThreeDSecure.d.ts +1 -0
  282. package/lib/typescript/src/types/ThreeDSecure.d.ts.map +1 -0
  283. package/lib/typescript/src/types/Token.d.ts +10 -9
  284. package/lib/typescript/src/types/Token.d.ts.map +1 -0
  285. package/lib/typescript/src/types/components/ApplePayButtonComponent.d.ts +3 -2
  286. package/lib/typescript/src/types/components/ApplePayButtonComponent.d.ts.map +1 -0
  287. package/lib/typescript/src/types/components/AuBECSDebitFormComponent.d.ts +1 -0
  288. package/lib/typescript/src/types/components/AuBECSDebitFormComponent.d.ts.map +1 -0
  289. package/lib/typescript/src/types/components/CardFieldInput.d.ts +8 -5
  290. package/lib/typescript/src/types/components/CardFieldInput.d.ts.map +1 -0
  291. package/lib/typescript/src/types/components/CardFormView.d.ts +9 -6
  292. package/lib/typescript/src/types/components/CardFormView.d.ts.map +1 -0
  293. package/lib/typescript/src/types/components/GooglePayButtonComponent.d.ts +1 -0
  294. package/lib/typescript/src/types/components/GooglePayButtonComponent.d.ts.map +1 -0
  295. package/lib/typescript/src/types/index.d.ts +24 -23
  296. package/lib/typescript/src/types/index.d.ts.map +1 -0
  297. package/package.json +33 -42
  298. package/src/NativeStripeSdk.tsx +5 -3
  299. package/src/components/CardField.tsx +1 -1
  300. package/src/components/CardForm.tsx +12 -9
  301. package/src/components/CustomerSheet.tsx +4 -6
  302. package/src/components/StripeProvider.tsx +17 -0
  303. package/src/functions.ts +70 -16
  304. package/src/hooks/useFinancialConnectionsSheet.tsx +12 -4
  305. package/src/hooks/useStripe.tsx +10 -4
  306. package/src/types/Common.ts +3 -0
  307. package/src/types/CustomerSheet.ts +7 -0
  308. package/src/types/FinancialConnections.ts +72 -0
  309. package/src/types/PaymentIntent.ts +30 -1
  310. package/src/types/PaymentMethod.ts +13 -1
  311. package/src/types/PaymentSheet.ts +65 -5
  312. package/src/types/components/CardFieldInput.ts +8 -4
  313. package/src/types/components/CardFormView.ts +8 -4
  314. package/stripe-react-native.podspec +2 -1
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.default=void 0;exports.setApplePayEntitlement=setApplePayEntitlement;exports.setGooglePayMetaData=setGooglePayMetaData;exports.withNoopSwiftFile=void 0;var _configPlugins=require("@expo/config-plugins");var _AndroidConfig$Manife=_configPlugins.AndroidConfig.Manifest,addMetaDataItemToMainApplication=_AndroidConfig$Manife.addMetaDataItemToMainApplication,getMainApplicationOrThrow=_AndroidConfig$Manife.getMainApplicationOrThrow,removeMetaDataItemFromMainApplication=_AndroidConfig$Manife.removeMetaDataItemFromMainApplication;var pkg=require('@stripe/stripe-react-native/package.json');var withStripe=function withStripe(config,props){config=withStripeIos(config,props);config=withNoopSwiftFile(config);config=withStripeAndroid(config,props);return config;};var withStripeIos=function withStripeIos(expoConfig,_ref){var merchantIdentifier=_ref.merchantIdentifier;return(0,_configPlugins.withEntitlementsPlist)(expoConfig,function(config){config.modResults=setApplePayEntitlement(merchantIdentifier,config.modResults);return config;});};function setApplePayEntitlement(merchantIdentifiers,entitlements){var _entitlements$key;var key='com.apple.developer.in-app-payments';var merchants=(_entitlements$key=entitlements[key])!=null?_entitlements$key:[];if(!Array.isArray(merchantIdentifiers)){merchantIdentifiers=[merchantIdentifiers];}for(var id of merchantIdentifiers){if(id&&!merchants.includes(id)){merchants.push(id);}}if(merchants.length){entitlements[key]=merchants;}return entitlements;}var withNoopSwiftFile=function withNoopSwiftFile(config){return _configPlugins.IOSConfig.XcodeProjectFile.withBuildSourceFile(config,{filePath:'noop-file.swift',contents:['//','// @generated','// A blank Swift file must be created for native modules with Swift files to work correctly.','//',''].join('\n')});};exports.withNoopSwiftFile=withNoopSwiftFile;var withStripeAndroid=function withStripeAndroid(expoConfig,_ref2){var _ref2$enableGooglePay=_ref2.enableGooglePay,enableGooglePay=_ref2$enableGooglePay===void 0?false:_ref2$enableGooglePay;return(0,_configPlugins.withAndroidManifest)(expoConfig,function(config){config.modResults=setGooglePayMetaData(enableGooglePay,config.modResults);return config;});};function setGooglePayMetaData(enabled,modResults){var GOOGLE_PAY_META_NAME='com.google.android.gms.wallet.api.enabled';var mainApplication=getMainApplicationOrThrow(modResults);if(enabled){addMetaDataItemToMainApplication(mainApplication,GOOGLE_PAY_META_NAME,'true');}else{removeMetaDataItemFromMainApplication(mainApplication,GOOGLE_PAY_META_NAME);}return modResults;}var _default=(0,_configPlugins.createRunOncePlugin)(withStripe,pkg.name,pkg.version);exports.default=_default;
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.default=void 0;exports.setApplePayEntitlement=setApplePayEntitlement;exports.setGooglePayMetaData=setGooglePayMetaData;exports.withNoopSwiftFile=void 0;var _configPlugins=require("@expo/config-plugins");var _AndroidConfig$Manife=_configPlugins.AndroidConfig.Manifest,addMetaDataItemToMainApplication=_AndroidConfig$Manife.addMetaDataItemToMainApplication,getMainApplicationOrThrow=_AndroidConfig$Manife.getMainApplicationOrThrow,removeMetaDataItemFromMainApplication=_AndroidConfig$Manife.removeMetaDataItemFromMainApplication;var pkg=require('@stripe/stripe-react-native/package.json');var withStripe=function withStripe(config,props){config=withStripeIos(config,props);config=withNoopSwiftFile(config);config=withStripeAndroid(config,props);return config;};var withStripeIos=function withStripeIos(expoConfig,_ref){var merchantIdentifier=_ref.merchantIdentifier;return(0,_configPlugins.withEntitlementsPlist)(expoConfig,function(config){config.modResults=setApplePayEntitlement(merchantIdentifier,config.modResults);return config;});};function setApplePayEntitlement(merchantIdentifiers,entitlements){var _entitlements$key;var key='com.apple.developer.in-app-payments';var merchants=(_entitlements$key=entitlements[key])!=null?_entitlements$key:[];if(!Array.isArray(merchantIdentifiers)){merchantIdentifiers=[merchantIdentifiers];}for(var id of merchantIdentifiers){if(id&&!merchants.includes(id)){merchants.push(id);}}if(merchants.length){entitlements[key]=merchants;}return entitlements;}var withNoopSwiftFile=exports.withNoopSwiftFile=function withNoopSwiftFile(config){return _configPlugins.IOSConfig.XcodeProjectFile.withBuildSourceFile(config,{filePath:'noop-file.swift',contents:['//','// @generated','// A blank Swift file must be created for native modules with Swift files to work correctly.','//',''].join('\n')});};var withStripeAndroid=function withStripeAndroid(expoConfig,_ref2){var _ref2$enableGooglePay=_ref2.enableGooglePay,enableGooglePay=_ref2$enableGooglePay===void 0?false:_ref2$enableGooglePay;return(0,_configPlugins.withAndroidManifest)(expoConfig,function(config){config.modResults=setGooglePayMetaData(enableGooglePay,config.modResults);return config;});};function setGooglePayMetaData(enabled,modResults){var GOOGLE_PAY_META_NAME='com.google.android.gms.wallet.api.enabled';var mainApplication=getMainApplicationOrThrow(modResults);if(enabled){addMetaDataItemToMainApplication(mainApplication,GOOGLE_PAY_META_NAME,'true');}else{removeMetaDataItemFromMainApplication(mainApplication,GOOGLE_PAY_META_NAME);}return modResults;}var _default=exports.default=(0,_configPlugins.createRunOncePlugin)(withStripe,pkg.name,pkg.version);
2
2
  //# sourceMappingURL=withStripe.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["AndroidConfig","Manifest","addMetaDataItemToMainApplication","getMainApplicationOrThrow","removeMetaDataItemFromMainApplication","pkg","require","withStripe","config","props","withStripeIos","withNoopSwiftFile","withStripeAndroid","expoConfig","merchantIdentifier","withEntitlementsPlist","modResults","setApplePayEntitlement","merchantIdentifiers","entitlements","key","merchants","Array","isArray","id","includes","push","length","IOSConfig","XcodeProjectFile","withBuildSourceFile","filePath","contents","join","enableGooglePay","withAndroidManifest","setGooglePayMetaData","enabled","GOOGLE_PAY_META_NAME","mainApplication","createRunOncePlugin","name","version"],"sources":["withStripe.ts"],"sourcesContent":["import {\n AndroidConfig,\n ConfigPlugin,\n createRunOncePlugin,\n IOSConfig,\n withAndroidManifest,\n withEntitlementsPlist,\n} from '@expo/config-plugins';\n\nconst {\n addMetaDataItemToMainApplication,\n getMainApplicationOrThrow,\n removeMetaDataItemFromMainApplication,\n} = AndroidConfig.Manifest;\n\nconst pkg = require('@stripe/stripe-react-native/package.json');\n\ntype StripePluginProps = {\n /**\n * The iOS merchant ID used for enabling Apple Pay.\n * Without this, the error \"Missing merchant identifier\" will be thrown on iOS.\n */\n merchantIdentifier: string | string[];\n enableGooglePay: boolean;\n};\n\nconst withStripe: ConfigPlugin<StripePluginProps> = (config, props) => {\n config = withStripeIos(config, props);\n config = withNoopSwiftFile(config);\n config = withStripeAndroid(config, props);\n return config;\n};\n\nconst withStripeIos: ConfigPlugin<StripePluginProps> = (\n expoConfig,\n { merchantIdentifier }\n) => {\n return withEntitlementsPlist(expoConfig, (config) => {\n config.modResults = setApplePayEntitlement(\n merchantIdentifier,\n config.modResults\n );\n return config;\n });\n};\n\n/**\n * Adds the following to the entitlements:\n *\n * <key>com.apple.developer.in-app-payments</key>\n * <array>\n *\t <string>[MERCHANT_IDENTIFIER]</string>\n * </array>\n */\nexport function setApplePayEntitlement(\n merchantIdentifiers: string | string[],\n entitlements: Record<string, any>\n): Record<string, any> {\n const key = 'com.apple.developer.in-app-payments';\n\n const merchants: string[] = entitlements[key] ?? [];\n\n if (!Array.isArray(merchantIdentifiers)) {\n merchantIdentifiers = [merchantIdentifiers];\n }\n\n for (const id of merchantIdentifiers) {\n if (id && !merchants.includes(id)) {\n merchants.push(id);\n }\n }\n\n if (merchants.length) {\n entitlements[key] = merchants;\n }\n return entitlements;\n}\n\n/**\n * Add a blank Swift file to the Xcode project for Swift compatibility.\n */\nexport const withNoopSwiftFile: ConfigPlugin = (config) => {\n return IOSConfig.XcodeProjectFile.withBuildSourceFile(config, {\n filePath: 'noop-file.swift',\n contents: [\n '//',\n '// @generated',\n '// A blank Swift file must be created for native modules with Swift files to work correctly.',\n '//',\n '',\n ].join('\\n'),\n });\n};\n\nconst withStripeAndroid: ConfigPlugin<StripePluginProps> = (\n expoConfig,\n { enableGooglePay = false }\n) => {\n return withAndroidManifest(expoConfig, (config) => {\n config.modResults = setGooglePayMetaData(\n enableGooglePay,\n config.modResults\n );\n\n return config;\n });\n};\n\n/**\n * Adds the following to AndroidManifest.xml:\n *\n * <application>\n * ...\n *\t <meta-data\n * android:name=\"com.google.android.gms.wallet.api.enabled\"\n * android:value=\"true|false\" />\n * </application>\n */\nexport function setGooglePayMetaData(\n enabled: boolean,\n modResults: AndroidConfig.Manifest.AndroidManifest\n): AndroidConfig.Manifest.AndroidManifest {\n const GOOGLE_PAY_META_NAME = 'com.google.android.gms.wallet.api.enabled';\n const mainApplication = getMainApplicationOrThrow(modResults);\n if (enabled) {\n addMetaDataItemToMainApplication(\n mainApplication,\n GOOGLE_PAY_META_NAME,\n 'true'\n );\n } else {\n removeMetaDataItemFromMainApplication(\n mainApplication,\n GOOGLE_PAY_META_NAME\n );\n }\n\n return modResults;\n}\n\nexport default createRunOncePlugin(withStripe, pkg.name, pkg.version);\n"],"mappings":"yNAAA,mDASA,0BAIIA,4BAAa,CAACC,QAAQ,CAHxBC,gCAAgC,uBAAhCA,gCAAgC,CAChCC,yBAAyB,uBAAzBA,yBAAyB,CACzBC,qCAAqC,uBAArCA,qCAAqC,CAGvC,GAAMC,IAAG,CAAGC,OAAO,CAAC,0CAA0C,CAAC,CAW/D,GAAMC,WAA2C,CAAG,QAA9CA,WAA2C,CAAIC,MAAM,CAAEC,KAAK,CAAK,CACrED,MAAM,CAAGE,aAAa,CAACF,MAAM,CAAEC,KAAK,CAAC,CACrCD,MAAM,CAAGG,iBAAiB,CAACH,MAAM,CAAC,CAClCA,MAAM,CAAGI,iBAAiB,CAACJ,MAAM,CAAEC,KAAK,CAAC,CACzC,MAAOD,OAAM,CACf,CAAC,CAED,GAAME,cAA8C,CAAG,QAAjDA,cAA8C,CAClDG,UAAU,MAEP,IADDC,mBAAkB,MAAlBA,kBAAkB,CAEpB,MAAO,GAAAC,oCAAqB,EAACF,UAAU,CAAE,SAACL,MAAM,CAAK,CACnDA,MAAM,CAACQ,UAAU,CAAGC,sBAAsB,CACxCH,kBAAkB,CAClBN,MAAM,CAACQ,UAAU,CAClB,CACD,MAAOR,OAAM,CACf,CAAC,CAAC,CACJ,CAAC,CAUM,QAASS,uBAAsB,CACpCC,mBAAsC,CACtCC,YAAiC,CACZ,uBACrB,GAAMC,IAAG,CAAG,qCAAqC,CAEjD,GAAMC,UAAmB,oBAAGF,YAAY,CAACC,GAAG,CAAC,0BAAI,EAAE,CAEnD,GAAI,CAACE,KAAK,CAACC,OAAO,CAACL,mBAAmB,CAAC,CAAE,CACvCA,mBAAmB,CAAG,CAACA,mBAAmB,CAAC,CAC7C,CAEA,IAAK,GAAMM,GAAE,GAAIN,oBAAmB,CAAE,CACpC,GAAIM,EAAE,EAAI,CAACH,SAAS,CAACI,QAAQ,CAACD,EAAE,CAAC,CAAE,CACjCH,SAAS,CAACK,IAAI,CAACF,EAAE,CAAC,CACpB,CACF,CAEA,GAAIH,SAAS,CAACM,MAAM,CAAE,CACpBR,YAAY,CAACC,GAAG,CAAC,CAAGC,SAAS,CAC/B,CACA,MAAOF,aAAY,CACrB,CAKO,GAAMR,kBAA+B,CAAG,QAAlCA,kBAA+B,CAAIH,MAAM,CAAK,CACzD,MAAOoB,yBAAS,CAACC,gBAAgB,CAACC,mBAAmB,CAACtB,MAAM,CAAE,CAC5DuB,QAAQ,CAAE,iBAAiB,CAC3BC,QAAQ,CAAE,CACR,IAAI,CACJ,eAAe,CACf,8FAA8F,CAC9F,IAAI,CACJ,EAAE,CACH,CAACC,IAAI,CAAC,IAAI,CACb,CAAC,CAAC,CACJ,CAAC,CAAC,4CAEF,GAAMrB,kBAAkD,CAAG,QAArDA,kBAAkD,CACtDC,UAAU,OAEP,iCADDqB,eAAe,CAAfA,eAAe,gCAAG,KAAK,uBAEzB,MAAO,GAAAC,kCAAmB,EAACtB,UAAU,CAAE,SAACL,MAAM,CAAK,CACjDA,MAAM,CAACQ,UAAU,CAAGoB,oBAAoB,CACtCF,eAAe,CACf1B,MAAM,CAACQ,UAAU,CAClB,CAED,MAAOR,OAAM,CACf,CAAC,CAAC,CACJ,CAAC,CAYM,QAAS4B,qBAAoB,CAClCC,OAAgB,CAChBrB,UAAkD,CACV,CACxC,GAAMsB,qBAAoB,CAAG,2CAA2C,CACxE,GAAMC,gBAAe,CAAGpC,yBAAyB,CAACa,UAAU,CAAC,CAC7D,GAAIqB,OAAO,CAAE,CACXnC,gCAAgC,CAC9BqC,eAAe,CACfD,oBAAoB,CACpB,MAAM,CACP,CACH,CAAC,IAAM,CACLlC,qCAAqC,CACnCmC,eAAe,CACfD,oBAAoB,CACrB,CACH,CAEA,MAAOtB,WAAU,CACnB,CAAC,aAEc,GAAAwB,kCAAmB,EAACjC,UAAU,CAAEF,GAAG,CAACoC,IAAI,CAAEpC,GAAG,CAACqC,OAAO,CAAC"}
1
+ {"version":3,"names":["_configPlugins","require","_AndroidConfig$Manife","AndroidConfig","Manifest","addMetaDataItemToMainApplication","getMainApplicationOrThrow","removeMetaDataItemFromMainApplication","pkg","withStripe","config","props","withStripeIos","withNoopSwiftFile","withStripeAndroid","expoConfig","_ref","merchantIdentifier","withEntitlementsPlist","modResults","setApplePayEntitlement","merchantIdentifiers","entitlements","_entitlements$key","key","merchants","Array","isArray","id","includes","push","length","exports","IOSConfig","XcodeProjectFile","withBuildSourceFile","filePath","contents","join","_ref2","_ref2$enableGooglePay","enableGooglePay","withAndroidManifest","setGooglePayMetaData","enabled","GOOGLE_PAY_META_NAME","mainApplication","_default","default","createRunOncePlugin","name","version"],"sourceRoot":"../../../src","sources":["plugin/withStripe.ts"],"mappings":"yNAAA,IAAAA,cAAA,CAAAC,OAAA,yBASA,IAAAC,qBAAA,CAIIC,4BAAa,CAACC,QAAQ,CAHxBC,gCAAgC,CAAAH,qBAAA,CAAhCG,gCAAgC,CAChCC,yBAAyB,CAAAJ,qBAAA,CAAzBI,yBAAyB,CACzBC,qCAAqC,CAAAL,qBAAA,CAArCK,qCAAqC,CAGvC,GAAM,CAAAC,GAAG,CAAGP,OAAO,CAAC,0CAA0C,CAAC,CAW/D,GAAM,CAAAQ,UAA2C,CAAG,QAA9C,CAAAA,UAA2CA,CAAIC,MAAM,CAAEC,KAAK,CAAK,CACrED,MAAM,CAAGE,aAAa,CAACF,MAAM,CAAEC,KAAK,CAAC,CACrCD,MAAM,CAAGG,iBAAiB,CAACH,MAAM,CAAC,CAClCA,MAAM,CAAGI,iBAAiB,CAACJ,MAAM,CAAEC,KAAK,CAAC,CACzC,MAAO,CAAAD,MAAM,CACf,CAAC,CAED,GAAM,CAAAE,aAA8C,CAAG,QAAjD,CAAAA,aAA8CA,CAClDG,UAAU,CAAAC,IAAA,CAEP,IADD,CAAAC,kBAAkB,CAAAD,IAAA,CAAlBC,kBAAkB,CAEpB,MAAO,GAAAC,oCAAqB,EAACH,UAAU,CAAE,SAACL,MAAM,CAAK,CACnDA,MAAM,CAACS,UAAU,CAAGC,sBAAsB,CACxCH,kBAAkB,CAClBP,MAAM,CAACS,UACT,CAAC,CACD,MAAO,CAAAT,MAAM,CACf,CAAC,CAAC,CACJ,CAAC,CAUM,QAAS,CAAAU,sBAAsBA,CACpCC,mBAAsC,CACtCC,YAAiC,CACZ,KAAAC,iBAAA,CACrB,GAAM,CAAAC,GAAG,CAAG,qCAAqC,CAEjD,GAAM,CAAAC,SAAmB,EAAAF,iBAAA,CAAGD,YAAY,CAACE,GAAG,CAAC,QAAAD,iBAAA,CAAI,EAAE,CAEnD,GAAI,CAACG,KAAK,CAACC,OAAO,CAACN,mBAAmB,CAAC,CAAE,CACvCA,mBAAmB,CAAG,CAACA,mBAAmB,CAAC,CAC7C,CAEA,IAAK,GAAM,CAAAO,EAAE,GAAI,CAAAP,mBAAmB,CAAE,CACpC,GAAIO,EAAE,EAAI,CAACH,SAAS,CAACI,QAAQ,CAACD,EAAE,CAAC,CAAE,CACjCH,SAAS,CAACK,IAAI,CAACF,EAAE,CAAC,CACpB,CACF,CAEA,GAAIH,SAAS,CAACM,MAAM,CAAE,CACpBT,YAAY,CAACE,GAAG,CAAC,CAAGC,SAAS,CAC/B,CACA,MAAO,CAAAH,YAAY,CACrB,CAKO,GAAM,CAAAT,iBAA+B,CAAAmB,OAAA,CAAAnB,iBAAA,CAAG,QAAlC,CAAAA,iBAA+BA,CAAIH,MAAM,CAAK,CACzD,MAAO,CAAAuB,wBAAS,CAACC,gBAAgB,CAACC,mBAAmB,CAACzB,MAAM,CAAE,CAC5D0B,QAAQ,CAAE,iBAAiB,CAC3BC,QAAQ,CAAE,CACR,IAAI,CACJ,eAAe,CACf,8FAA8F,CAC9F,IAAI,CACJ,EAAE,CACH,CAACC,IAAI,CAAC,IAAI,CACb,CAAC,CAAC,CACJ,CAAC,CAED,GAAM,CAAAxB,iBAAkD,CAAG,QAArD,CAAAA,iBAAkDA,CACtDC,UAAU,CAAAwB,KAAA,CAEP,KAAAC,qBAAA,CAAAD,KAAA,CADDE,eAAe,CAAfA,eAAe,CAAAD,qBAAA,UAAG,KAAK,CAAAA,qBAAA,CAEzB,MAAO,GAAAE,kCAAmB,EAAC3B,UAAU,CAAE,SAACL,MAAM,CAAK,CACjDA,MAAM,CAACS,UAAU,CAAGwB,oBAAoB,CACtCF,eAAe,CACf/B,MAAM,CAACS,UACT,CAAC,CAED,MAAO,CAAAT,MAAM,CACf,CAAC,CAAC,CACJ,CAAC,CAYM,QAAS,CAAAiC,oBAAoBA,CAClCC,OAAgB,CAChBzB,UAAkD,CACV,CACxC,GAAM,CAAA0B,oBAAoB,CAAG,2CAA2C,CACxE,GAAM,CAAAC,eAAe,CAAGxC,yBAAyB,CAACa,UAAU,CAAC,CAC7D,GAAIyB,OAAO,CAAE,CACXvC,gCAAgC,CAC9ByC,eAAe,CACfD,oBAAoB,CACpB,MACF,CAAC,CACH,CAAC,IAAM,CACLtC,qCAAqC,CACnCuC,eAAe,CACfD,oBACF,CAAC,CACH,CAEA,MAAO,CAAA1B,UAAU,CACnB,CAAC,IAAA4B,QAAA,CAAAf,OAAA,CAAAgB,OAAA,CAEc,GAAAC,kCAAmB,EAACxC,UAAU,CAAED,GAAG,CAAC0C,IAAI,CAAE1C,GAAG,CAAC2C,OAAO,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["ApplePay.ts"],"sourcesContent":["export type CartSummaryItem =\n | DeferredCartSummaryItem\n | ImmediateCartSummaryItem\n | RecurringCartSummaryItem;\n\nexport type CartSummaryItemType = 'Deferred' | 'Immediate' | 'Recurring';\n\n/** Use this type for a payment that occurs in the future, such as a pre-order. Only available on iOS 15 and up, otherwise falls back to ImmediateCartSummaryItem. */\nexport type DeferredCartSummaryItem = {\n paymentType: 'Deferred';\n /** The unix timestamp of the date, in the future, of the payment. Measured in seconds. */\n deferredDate: number;\n label: string;\n amount: string;\n};\n\n/** Use this type for payments that will occur immediately. */\nexport type ImmediateCartSummaryItem = {\n paymentType: 'Immediate';\n /** When creating items for estimates or charges whose final value is not yet known, set this to true. */\n isPending?: boolean;\n label: string;\n amount: string;\n};\n\n/** Use this type for payments that occur more than once, such as a subscription. Only available on iOS 15 and up, otherwise falls back to ImmediateCartSummaryItem.*/\nexport type RecurringCartSummaryItem = {\n paymentType: 'Recurring';\n /** The amount of time – in calendar units such as day, month, or year – that represents a fraction of the total payment interval. For example, if you set the intervalUnit to 'month' and intervalCount to 3, then the payment interval is three months.*/\n intervalUnit: 'minute' | 'hour' | 'day' | 'month' | 'year';\n /** The number of interval units that make up the total payment interval. For example, if you set the intervalUnit to 'month' and intervalCount to 3, then the payment interval is three months.*/\n intervalCount: number;\n /** The unix timestamp of the start date. Measured in seconds. */\n startDate?: number;\n /** The unix timestamp of the end date. Measured in seconds. */\n endDate?: number;\n label: string;\n amount: string;\n};\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/ApplePay.ts"],"mappings":"","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.CardBrand=void 0;var CardBrand;exports.CardBrand=CardBrand;(function(CardBrand){CardBrand[CardBrand["JCB"]=0]="JCB";CardBrand[CardBrand["Amex"]=1]="Amex";CardBrand[CardBrand["CartesBancaires"]=2]="CartesBancaires";CardBrand[CardBrand["DinersClub"]=3]="DinersClub";CardBrand[CardBrand["Discover"]=4]="Discover";CardBrand[CardBrand["Mastercard"]=5]="Mastercard";CardBrand[CardBrand["UnionPay"]=6]="UnionPay";CardBrand[CardBrand["Visa"]=7]="Visa";CardBrand[CardBrand["Unknown"]=8]="Unknown";})(CardBrand||(exports.CardBrand=CardBrand={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.CardBrand=void 0;var CardBrand=exports.CardBrand=function(CardBrand){CardBrand[CardBrand["JCB"]=0]="JCB";CardBrand[CardBrand["Amex"]=1]="Amex";CardBrand[CardBrand["CartesBancaires"]=2]="CartesBancaires";CardBrand[CardBrand["DinersClub"]=3]="DinersClub";CardBrand[CardBrand["Discover"]=4]="Discover";CardBrand[CardBrand["Mastercard"]=5]="Mastercard";CardBrand[CardBrand["UnionPay"]=6]="UnionPay";CardBrand[CardBrand["Visa"]=7]="Visa";CardBrand[CardBrand["Unknown"]=8]="Unknown";return CardBrand;}({});
2
2
  //# sourceMappingURL=Common.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["CardBrand"],"sources":["Common.ts"],"sourcesContent":["export interface BillingDetails {\n email?: string;\n phone?: string;\n name?: string;\n address?: Address;\n}\n\nexport interface Address {\n city?: string;\n country?: string;\n line1?: string;\n line2?: string;\n postalCode?: string;\n state?: string;\n}\n\nexport type AddressDetails = {\n /** The customer's full name. */\n name?: string;\n /** The customer's address. */\n address?: Address;\n /** The customer's phone number. */\n phone?: string;\n /** Whether or not the checkbox is initally selected. Defaults to false.\n * Note: The checkbox is displayed below the other fields when additionalFields.checkboxLabel is set.\n * */\n isCheckboxSelected?: boolean;\n};\n\nexport enum CardBrand {\n JCB = 0,\n Amex = 1,\n CartesBancaires = 2,\n DinersClub = 3,\n Discover = 4,\n Mastercard = 5,\n UnionPay = 6,\n Visa = 7,\n Unknown = 8,\n}\n"],"mappings":"qFA6BYA,UAAS,uCAATA,SAAS,EAATA,SAAS,CAATA,SAAS,iBAATA,SAAS,CAATA,SAAS,mBAATA,SAAS,CAATA,SAAS,yCAATA,SAAS,CAATA,SAAS,+BAATA,SAAS,CAATA,SAAS,2BAATA,SAAS,CAATA,SAAS,+BAATA,SAAS,CAATA,SAAS,2BAATA,SAAS,CAATA,SAAS,mBAATA,SAAS,CAATA,SAAS,4BAATA,SAAS,qBAATA,SAAS"}
1
+ {"version":3,"names":["CardBrand","exports"],"sourceRoot":"../../../src","sources":["types/Common.ts"],"mappings":"qFA6BY,CAAAA,SAAS,CAAAC,OAAA,CAAAD,SAAA,UAATA,SAAS,EAATA,SAAS,CAATA,SAAS,iBAATA,SAAS,CAATA,SAAS,mBAATA,SAAS,CAATA,SAAS,yCAATA,SAAS,CAATA,SAAS,+BAATA,SAAS,CAATA,SAAS,2BAATA,SAAS,CAATA,SAAS,+BAATA,SAAS,CAATA,SAAS,2BAATA,SAAS,CAATA,SAAS,mBAATA,SAAS,CAATA,SAAS,+BAAT,CAAAA,SAAS","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["CustomerSheet.ts"],"sourcesContent":["import type {\n PaymentSheet,\n StripeError,\n CustomerSheetError,\n BillingDetails,\n PaymentMethod,\n CardBrand,\n} from '../types';\n\nexport type CustomerSheetInitParams = {\n /** The color styling to use for PaymentSheet UI. Defaults to 'automatic'. iOS only. */\n style?: 'alwaysLight' | 'alwaysDark' | 'automatic';\n /** Configuration for the look and feel of the UI. */\n appearance?: PaymentSheet.AppearanceParams;\n /** Optional but recommended for cards, required for other payment methods. The SetupIntent client secret that will be used to confirm a new payment method. If this is missing, you will only be able to add cards without authentication steps. */\n setupIntentClientSecret?: string;\n /** The identifier of the Stripe Customer object. See https://stripe.com/docs/api/customers/object#customer_object-id */\n customerId: string;\n /** A short-lived token that allows the SDK to access a Customer's payment methods. */\n customerEphemeralKeySecret: string;\n /** Your customer-facing business name. The default value is the name of your app. */\n merchantDisplayName?: string;\n /** Optional configuration for setting the header text of the Payment Method selection screen */\n headerTextForSelectionScreen?: string;\n /** CustomerSheet pre-populates fields with the values provided. If `billingDetailsCollectionConfiguration.attachDefaultsToPaymentMethod` is `true`, these values will be attached to the payment method even if they are not collected by the CustomerSheet UI. */\n defaultBillingDetails?: BillingDetails;\n /** Describes how billing details should be collected. All values default to `AUTOMATIC`. If `NEVER` is used for a required field for the Payment Method, you must provide an appropriate value as part of `defaultBillingDetails`. */\n billingDetailsCollectionConfiguration?: PaymentSheet.BillingDetailsCollectionConfiguration;\n /** A URL that redirects back to your app that CustomerSheet can use to auto-dismiss web views used for additional authentication, e.g. 3DS2 */\n returnURL?: string;\n /** Optional configuration to display a custom message when a saved payment method is removed. iOS only. */\n removeSavedPaymentMethodMessage?: string;\n /** Whether to show Apple Pay as an option. Defaults to false. */\n applePayEnabled?: boolean;\n /** Whether to show Google Pay as an option. Defaults to false. */\n googlePayEnabled?: boolean;\n /** The list of preferred networks that should be used to process payments made with a co-branded card.\n * This value will only be used if your user hasn't selected a network themselves. */\n preferredNetworks?: Array<CardBrand>;\n /** Optional override. It is generally recommended to rely on the default behavior, but- provide a CustomerAdapter here if\n * you would prefer retrieving and updating your Stripe customer object via your own backend instead.\n * WARNING: When implementing your own CustomerAdapter, ensure your application complies with all applicable laws and regulations, including data privacy and consumer protection.\n */\n customerAdapter?: CustomerAdapter;\n /** This is an experimental feature that may be removed at any time.\n * Defaults to true. If true, the customer can delete all saved payment methods.\n * If false, the customer can't delete if they only have one saved payment method remaining.\n */\n allowsRemovalOfLastSavedPaymentMethod?: boolean;\n};\n\nexport type CustomerSheetPresentParams = {\n /** Controls how the modal is presented (after animation). iOS only. Defaults to `popover`. See https://developer.apple.com/documentation/uikit/uimodalpresentationstyle for more info. */\n presentationStyle?:\n | 'fullscreen'\n | 'popover'\n | 'pageSheet'\n | 'formSheet'\n | 'automatic'\n | 'overFullScreen';\n /** Controls how the modal animates. iOS only. */\n animationStyle?: 'flip' | 'curl' | 'slide' | 'dissolve';\n /** Time (in milliseconds) before the Customer Sheet will automatically dismiss. */\n timeout?: number;\n};\n\nexport type CustomerSheetResult = {\n /** The users selected payment option, if one exists. */\n paymentOption?: PaymentSheet.PaymentOption;\n /** The Stripe PaymentMethod associated with the paymentOption, if it exists. */\n paymentMethod?: PaymentMethod.Result;\n /** The error that occurred. */\n error?: StripeError<CustomerSheetError>;\n};\n\nexport interface CustomerAdapter {\n /** Retrieves a list of Payment Methods attached to a customer.\n * If you are implementing your own CustomerAdapter:\n * Call the list method ( https://stripe.com/docs/api/payment_methods/list )\n * with the Stripe customer. Return the list of payment methods in JSON format.\n */\n fetchPaymentMethods?(): Promise<Array<object>>;\n /** Adds a Payment Method to a customer.\n * If you are implementing your own CustomerAdapter:\n * On your backend, retrieve the Stripe customer associated with your logged-in user.\n * Then, call the Attach method on the Payment Method with that customer's ID\n * ( https://stripe.com/docs/api/payment_methods/attach ).\n * - Parameters:\n * - paymentMethod: A valid Stripe Payment Method ID\n * Return the payment method in JSON format.\n */\n attachPaymentMethod?(paymentMethodId: string): Promise<object>;\n /** Deletes the given Payment Method from the customer.\n * If you are implementing your own CustomerAdapter:\n * Call the Detach method ( https://stripe.com/docs/api/payment_methods/detach )\n * on the Payment Method.\n * - Parameters:\n * - paymentMethod: The Stripe Payment Method ID to delete from the customer\n * Return the payment method in JSON format.\n */\n detachPaymentMethod?(paymentMethodId: String): Promise<object>;\n /** Set the last selected payment method for the customer.\n * To unset the default payment method, `null` is passed as the `paymentOption`.\n * If you are implementing your own CustomerAdapter:\n * Save a representation of the passed `paymentOption` as the customer's default payment method.\n */\n setSelectedPaymentOption?(\n paymentOption: CustomerPaymentOption | null\n ): Promise<void>;\n /** Retrieve the last selected payment method for the customer.\n * If you are implementing your own CustomerAdapter:\n * Return a CustomerPaymentOption for the customer's default selected payment method.\n * If no default payment method is selected, return null.\n */\n fetchSelectedPaymentOption?(): Promise<CustomerPaymentOption | null>;\n /** Creates a SetupIntent configured to attach a new payment method to a customer,\n * then returns the client secret for the created SetupIntent.\n */\n setupIntentClientSecretForCustomerAttach?(): Promise<String>;\n}\n\nexport type CustomerPaymentOption =\n | 'apple_pay'\n | 'google_pay'\n | 'link'\n | string;\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/CustomerSheet.ts"],"mappings":"","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.VerifyMicrodepositsError=exports.RetrieveSetupIntentError=exports.RetrievePaymentIntentError=exports.PlatformPayError=exports.PaymentSheetError=exports.MissingRoutingNumber=exports.GooglePayError=exports.CustomerSheetError=exports.CreateTokenError=exports.CreatePaymentMethodError=exports.ConfirmSetupIntentError=exports.ConfirmPaymentError=exports.CollectBankAccountError=exports.CardActionError=exports.ApplePayError=exports.AddressSheetError=void 0;var ConfirmPaymentError;exports.ConfirmPaymentError=ConfirmPaymentError;(function(ConfirmPaymentError){ConfirmPaymentError["Canceled"]="Canceled";ConfirmPaymentError["Failed"]="Failed";ConfirmPaymentError["Unknown"]="Unknown";})(ConfirmPaymentError||(exports.ConfirmPaymentError=ConfirmPaymentError={}));var CardActionError;exports.CardActionError=CardActionError;(function(CardActionError){CardActionError["Canceled"]="Canceled";CardActionError["Failed"]="Failed";CardActionError["Unknown"]="Unknown";})(CardActionError||(exports.CardActionError=CardActionError={}));var ConfirmSetupIntentError;exports.ConfirmSetupIntentError=ConfirmSetupIntentError;(function(ConfirmSetupIntentError){ConfirmSetupIntentError["Canceled"]="Canceled";ConfirmSetupIntentError["Failed"]="Failed";ConfirmSetupIntentError["Unknown"]="Unknown";})(ConfirmSetupIntentError||(exports.ConfirmSetupIntentError=ConfirmSetupIntentError={}));var CreatePaymentMethodError;exports.CreatePaymentMethodError=CreatePaymentMethodError;(function(CreatePaymentMethodError){CreatePaymentMethodError["Failed"]="Failed";})(CreatePaymentMethodError||(exports.CreatePaymentMethodError=CreatePaymentMethodError={}));var CreateTokenError;exports.CreateTokenError=CreateTokenError;(function(CreateTokenError){CreateTokenError["Failed"]="Failed";})(CreateTokenError||(exports.CreateTokenError=CreateTokenError={}));var RetrievePaymentIntentError;exports.RetrievePaymentIntentError=RetrievePaymentIntentError;(function(RetrievePaymentIntentError){RetrievePaymentIntentError["Unknown"]="Unknown";})(RetrievePaymentIntentError||(exports.RetrievePaymentIntentError=RetrievePaymentIntentError={}));var RetrieveSetupIntentError;exports.RetrieveSetupIntentError=RetrieveSetupIntentError;(function(RetrieveSetupIntentError){RetrieveSetupIntentError["Unknown"]="Unknown";})(RetrieveSetupIntentError||(exports.RetrieveSetupIntentError=RetrieveSetupIntentError={}));var ApplePayError;exports.ApplePayError=ApplePayError;(function(ApplePayError){ApplePayError["Canceled"]="Canceled";ApplePayError["Failed"]="Failed";ApplePayError["Unknown"]="Unknown";})(ApplePayError||(exports.ApplePayError=ApplePayError={}));var PaymentSheetError;exports.PaymentSheetError=PaymentSheetError;(function(PaymentSheetError){PaymentSheetError["Failed"]="Failed";PaymentSheetError["Canceled"]="Canceled";PaymentSheetError["Timeout"]="Timeout";})(PaymentSheetError||(exports.PaymentSheetError=PaymentSheetError={}));var GooglePayError;exports.GooglePayError=GooglePayError;(function(GooglePayError){GooglePayError["Failed"]="Failed";GooglePayError["Canceled"]="Canceled";GooglePayError["Unknown"]="Unknown";})(GooglePayError||(exports.GooglePayError=GooglePayError={}));var MissingRoutingNumber={code:CreateTokenError.Failed,message:'You must provide a routing number for US bank accounts. This should be the ACH routing number.'};exports.MissingRoutingNumber=MissingRoutingNumber;var VerifyMicrodepositsError;exports.VerifyMicrodepositsError=VerifyMicrodepositsError;(function(VerifyMicrodepositsError){VerifyMicrodepositsError["Canceled"]="Canceled";VerifyMicrodepositsError["Failed"]="Failed";VerifyMicrodepositsError["Unknown"]="Unknown";})(VerifyMicrodepositsError||(exports.VerifyMicrodepositsError=VerifyMicrodepositsError={}));var CollectBankAccountError;exports.CollectBankAccountError=CollectBankAccountError;(function(CollectBankAccountError){CollectBankAccountError["Canceled"]="Canceled";CollectBankAccountError["Failed"]="Failed";CollectBankAccountError["Unknown"]="Unknown";})(CollectBankAccountError||(exports.CollectBankAccountError=CollectBankAccountError={}));var AddressSheetError;exports.AddressSheetError=AddressSheetError;(function(AddressSheetError){AddressSheetError["Failed"]="Failed";AddressSheetError["Canceled"]="Canceled";})(AddressSheetError||(exports.AddressSheetError=AddressSheetError={}));var CustomerSheetError;exports.CustomerSheetError=CustomerSheetError;(function(CustomerSheetError){CustomerSheetError["Failed"]="Failed";CustomerSheetError["Canceled"]="Canceled";})(CustomerSheetError||(exports.CustomerSheetError=CustomerSheetError={}));var PlatformPayError;exports.PlatformPayError=PlatformPayError;(function(PlatformPayError){PlatformPayError["Canceled"]="Canceled";PlatformPayError["Failed"]="Failed";PlatformPayError["Unknown"]="Unknown";})(PlatformPayError||(exports.PlatformPayError=PlatformPayError={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.VerifyMicrodepositsError=exports.RetrieveSetupIntentError=exports.RetrievePaymentIntentError=exports.PlatformPayError=exports.PaymentSheetError=exports.MissingRoutingNumber=exports.GooglePayError=exports.CustomerSheetError=exports.CreateTokenError=exports.CreatePaymentMethodError=exports.ConfirmSetupIntentError=exports.ConfirmPaymentError=exports.CollectBankAccountError=exports.CardActionError=exports.ApplePayError=exports.AddressSheetError=void 0;var ConfirmPaymentError=exports.ConfirmPaymentError=function(ConfirmPaymentError){ConfirmPaymentError["Canceled"]="Canceled";ConfirmPaymentError["Failed"]="Failed";ConfirmPaymentError["Unknown"]="Unknown";return ConfirmPaymentError;}({});var CardActionError=exports.CardActionError=function(CardActionError){CardActionError["Canceled"]="Canceled";CardActionError["Failed"]="Failed";CardActionError["Unknown"]="Unknown";return CardActionError;}({});var ConfirmSetupIntentError=exports.ConfirmSetupIntentError=function(ConfirmSetupIntentError){ConfirmSetupIntentError["Canceled"]="Canceled";ConfirmSetupIntentError["Failed"]="Failed";ConfirmSetupIntentError["Unknown"]="Unknown";return ConfirmSetupIntentError;}({});var CreatePaymentMethodError=exports.CreatePaymentMethodError=function(CreatePaymentMethodError){CreatePaymentMethodError["Failed"]="Failed";return CreatePaymentMethodError;}({});var CreateTokenError=exports.CreateTokenError=function(CreateTokenError){CreateTokenError["Failed"]="Failed";return CreateTokenError;}({});var RetrievePaymentIntentError=exports.RetrievePaymentIntentError=function(RetrievePaymentIntentError){RetrievePaymentIntentError["Unknown"]="Unknown";return RetrievePaymentIntentError;}({});var RetrieveSetupIntentError=exports.RetrieveSetupIntentError=function(RetrieveSetupIntentError){RetrieveSetupIntentError["Unknown"]="Unknown";return RetrieveSetupIntentError;}({});var ApplePayError=exports.ApplePayError=function(ApplePayError){ApplePayError["Canceled"]="Canceled";ApplePayError["Failed"]="Failed";ApplePayError["Unknown"]="Unknown";return ApplePayError;}({});var PaymentSheetError=exports.PaymentSheetError=function(PaymentSheetError){PaymentSheetError["Failed"]="Failed";PaymentSheetError["Canceled"]="Canceled";PaymentSheetError["Timeout"]="Timeout";return PaymentSheetError;}({});var GooglePayError=exports.GooglePayError=function(GooglePayError){GooglePayError["Failed"]="Failed";GooglePayError["Canceled"]="Canceled";GooglePayError["Unknown"]="Unknown";return GooglePayError;}({});var MissingRoutingNumber=exports.MissingRoutingNumber={code:CreateTokenError.Failed,message:'You must provide a routing number for US bank accounts. This should be the ACH routing number.'};var VerifyMicrodepositsError=exports.VerifyMicrodepositsError=function(VerifyMicrodepositsError){VerifyMicrodepositsError["Canceled"]="Canceled";VerifyMicrodepositsError["Failed"]="Failed";VerifyMicrodepositsError["Unknown"]="Unknown";return VerifyMicrodepositsError;}({});var CollectBankAccountError=exports.CollectBankAccountError=function(CollectBankAccountError){CollectBankAccountError["Canceled"]="Canceled";CollectBankAccountError["Failed"]="Failed";CollectBankAccountError["Unknown"]="Unknown";return CollectBankAccountError;}({});var AddressSheetError=exports.AddressSheetError=function(AddressSheetError){AddressSheetError["Failed"]="Failed";AddressSheetError["Canceled"]="Canceled";return AddressSheetError;}({});var CustomerSheetError=exports.CustomerSheetError=function(CustomerSheetError){CustomerSheetError["Failed"]="Failed";CustomerSheetError["Canceled"]="Canceled";return CustomerSheetError;}({});var PlatformPayError=exports.PlatformPayError=function(PlatformPayError){PlatformPayError["Canceled"]="Canceled";PlatformPayError["Failed"]="Failed";PlatformPayError["Unknown"]="Unknown";return PlatformPayError;}({});
2
2
  //# sourceMappingURL=Errors.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["ConfirmPaymentError","CardActionError","ConfirmSetupIntentError","CreatePaymentMethodError","CreateTokenError","RetrievePaymentIntentError","RetrieveSetupIntentError","ApplePayError","PaymentSheetError","GooglePayError","MissingRoutingNumber","code","Failed","message","VerifyMicrodepositsError","CollectBankAccountError","AddressSheetError","CustomerSheetError","PlatformPayError"],"sources":["Errors.ts"],"sourcesContent":["export enum ConfirmPaymentError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n\nexport enum CardActionError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n\nexport enum ConfirmSetupIntentError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n\nexport enum CreatePaymentMethodError {\n Failed = 'Failed',\n}\n\nexport enum CreateTokenError {\n Failed = 'Failed',\n}\n\nexport enum RetrievePaymentIntentError {\n Unknown = 'Unknown',\n}\n\nexport enum RetrieveSetupIntentError {\n Unknown = 'Unknown',\n}\n\nexport enum ApplePayError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n\nexport enum PaymentSheetError {\n Failed = 'Failed',\n Canceled = 'Canceled',\n Timeout = 'Timeout',\n}\n\nexport type ErrorType =\n | 'api_connection_error'\n | 'api_error'\n | 'authentication_error'\n | 'card_error'\n | 'idempotency_error'\n | 'invalid_request_error'\n | 'rate_limit_error';\n\nexport interface StripeError<T> {\n code: T;\n message: string;\n localizedMessage?: string;\n declineCode?: string;\n stripeErrorCode?: string;\n type?: ErrorType;\n}\n\nexport enum GooglePayError {\n Failed = 'Failed',\n Canceled = 'Canceled',\n Unknown = 'Unknown',\n}\n\nexport const MissingRoutingNumber = {\n code: CreateTokenError.Failed,\n message:\n 'You must provide a routing number for US bank accounts. This should be the ACH routing number.',\n};\n\nexport enum VerifyMicrodepositsError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n\nexport enum CollectBankAccountError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n\nexport enum AddressSheetError {\n Failed = 'Failed',\n Canceled = 'Canceled',\n}\n\nexport enum CustomerSheetError {\n Failed = 'Failed',\n Canceled = 'Canceled',\n}\n\nexport enum PlatformPayError {\n Canceled = 'Canceled',\n Failed = 'Failed',\n Unknown = 'Unknown',\n}\n"],"mappings":"wgBAAYA,oBAAmB,2DAAnBA,mBAAmB,EAAnBA,mBAAmB,wBAAnBA,mBAAmB,oBAAnBA,mBAAmB,yBAAnBA,mBAAmB,+BAAnBA,mBAAmB,SAMnBC,gBAAe,mDAAfA,eAAe,EAAfA,eAAe,wBAAfA,eAAe,oBAAfA,eAAe,yBAAfA,eAAe,2BAAfA,eAAe,SAMfC,wBAAuB,mEAAvBA,uBAAuB,EAAvBA,uBAAuB,wBAAvBA,uBAAuB,oBAAvBA,uBAAuB,yBAAvBA,uBAAuB,mCAAvBA,uBAAuB,SAMvBC,yBAAwB,qEAAxBA,wBAAwB,EAAxBA,wBAAwB,uBAAxBA,wBAAwB,oCAAxBA,wBAAwB,SAIxBC,iBAAgB,qDAAhBA,gBAAgB,EAAhBA,gBAAgB,uBAAhBA,gBAAgB,4BAAhBA,gBAAgB,SAIhBC,2BAA0B,yEAA1BA,0BAA0B,EAA1BA,0BAA0B,yBAA1BA,0BAA0B,sCAA1BA,0BAA0B,SAI1BC,yBAAwB,qEAAxBA,wBAAwB,EAAxBA,wBAAwB,yBAAxBA,wBAAwB,oCAAxBA,wBAAwB,SAIxBC,cAAa,+CAAbA,aAAa,EAAbA,aAAa,wBAAbA,aAAa,oBAAbA,aAAa,yBAAbA,aAAa,yBAAbA,aAAa,SAMbC,kBAAiB,uDAAjBA,iBAAiB,EAAjBA,iBAAiB,oBAAjBA,iBAAiB,wBAAjBA,iBAAiB,yBAAjBA,iBAAiB,6BAAjBA,iBAAiB,SAwBjBC,eAAc,iDAAdA,cAAc,EAAdA,cAAc,oBAAdA,cAAc,wBAAdA,cAAc,yBAAdA,cAAc,0BAAdA,cAAc,MAMnB,GAAMC,qBAAoB,CAAG,CAClCC,IAAI,CAAEP,gBAAgB,CAACQ,MAAM,CAC7BC,OAAO,CACL,gGACJ,CAAC,CAAC,qDAEUC,yBAAwB,qEAAxBA,wBAAwB,EAAxBA,wBAAwB,wBAAxBA,wBAAwB,oBAAxBA,wBAAwB,yBAAxBA,wBAAwB,oCAAxBA,wBAAwB,SAMxBC,wBAAuB,mEAAvBA,uBAAuB,EAAvBA,uBAAuB,wBAAvBA,uBAAuB,oBAAvBA,uBAAuB,yBAAvBA,uBAAuB,mCAAvBA,uBAAuB,SAMvBC,kBAAiB,uDAAjBA,iBAAiB,EAAjBA,iBAAiB,oBAAjBA,iBAAiB,2BAAjBA,iBAAiB,6BAAjBA,iBAAiB,SAKjBC,mBAAkB,yDAAlBA,kBAAkB,EAAlBA,kBAAkB,oBAAlBA,kBAAkB,2BAAlBA,kBAAkB,8BAAlBA,kBAAkB,SAKlBC,iBAAgB,qDAAhBA,gBAAgB,EAAhBA,gBAAgB,wBAAhBA,gBAAgB,oBAAhBA,gBAAgB,yBAAhBA,gBAAgB,4BAAhBA,gBAAgB"}
1
+ {"version":3,"names":["ConfirmPaymentError","exports","CardActionError","ConfirmSetupIntentError","CreatePaymentMethodError","CreateTokenError","RetrievePaymentIntentError","RetrieveSetupIntentError","ApplePayError","PaymentSheetError","GooglePayError","MissingRoutingNumber","code","Failed","message","VerifyMicrodepositsError","CollectBankAccountError","AddressSheetError","CustomerSheetError","PlatformPayError"],"sourceRoot":"../../../src","sources":["types/Errors.ts"],"mappings":"wgBAAY,CAAAA,mBAAmB,CAAAC,OAAA,CAAAD,mBAAA,UAAnBA,mBAAmB,EAAnBA,mBAAmB,wBAAnBA,mBAAmB,oBAAnBA,mBAAmB,4BAAnB,CAAAA,mBAAmB,UAMnB,CAAAE,eAAe,CAAAD,OAAA,CAAAC,eAAA,UAAfA,eAAe,EAAfA,eAAe,wBAAfA,eAAe,oBAAfA,eAAe,4BAAf,CAAAA,eAAe,UAMf,CAAAC,uBAAuB,CAAAF,OAAA,CAAAE,uBAAA,UAAvBA,uBAAuB,EAAvBA,uBAAuB,wBAAvBA,uBAAuB,oBAAvBA,uBAAuB,4BAAvB,CAAAA,uBAAuB,UAMvB,CAAAC,wBAAwB,CAAAH,OAAA,CAAAG,wBAAA,UAAxBA,wBAAwB,EAAxBA,wBAAwB,0BAAxB,CAAAA,wBAAwB,UAIxB,CAAAC,gBAAgB,CAAAJ,OAAA,CAAAI,gBAAA,UAAhBA,gBAAgB,EAAhBA,gBAAgB,0BAAhB,CAAAA,gBAAgB,UAIhB,CAAAC,0BAA0B,CAAAL,OAAA,CAAAK,0BAAA,UAA1BA,0BAA0B,EAA1BA,0BAA0B,4BAA1B,CAAAA,0BAA0B,UAI1B,CAAAC,wBAAwB,CAAAN,OAAA,CAAAM,wBAAA,UAAxBA,wBAAwB,EAAxBA,wBAAwB,4BAAxB,CAAAA,wBAAwB,UAIxB,CAAAC,aAAa,CAAAP,OAAA,CAAAO,aAAA,UAAbA,aAAa,EAAbA,aAAa,wBAAbA,aAAa,oBAAbA,aAAa,4BAAb,CAAAA,aAAa,UAMb,CAAAC,iBAAiB,CAAAR,OAAA,CAAAQ,iBAAA,UAAjBA,iBAAiB,EAAjBA,iBAAiB,oBAAjBA,iBAAiB,wBAAjBA,iBAAiB,4BAAjB,CAAAA,iBAAiB,UAwBjB,CAAAC,cAAc,CAAAT,OAAA,CAAAS,cAAA,UAAdA,cAAc,EAAdA,cAAc,oBAAdA,cAAc,wBAAdA,cAAc,4BAAd,CAAAA,cAAc,OAMnB,GAAM,CAAAC,oBAAoB,CAAAV,OAAA,CAAAU,oBAAA,CAAG,CAClCC,IAAI,CAAEP,gBAAgB,CAACQ,MAAM,CAC7BC,OAAO,CACL,gGACJ,CAAC,CAAC,GAEU,CAAAC,wBAAwB,CAAAd,OAAA,CAAAc,wBAAA,UAAxBA,wBAAwB,EAAxBA,wBAAwB,wBAAxBA,wBAAwB,oBAAxBA,wBAAwB,4BAAxB,CAAAA,wBAAwB,UAMxB,CAAAC,uBAAuB,CAAAf,OAAA,CAAAe,uBAAA,UAAvBA,uBAAuB,EAAvBA,uBAAuB,wBAAvBA,uBAAuB,oBAAvBA,uBAAuB,4BAAvB,CAAAA,uBAAuB,UAMvB,CAAAC,iBAAiB,CAAAhB,OAAA,CAAAgB,iBAAA,UAAjBA,iBAAiB,EAAjBA,iBAAiB,oBAAjBA,iBAAiB,8BAAjB,CAAAA,iBAAiB,UAKjB,CAAAC,kBAAkB,CAAAjB,OAAA,CAAAiB,kBAAA,UAAlBA,kBAAkB,EAAlBA,kBAAkB,oBAAlBA,kBAAkB,8BAAlB,CAAAA,kBAAkB,UAKlB,CAAAC,gBAAgB,CAAAlB,OAAA,CAAAkB,gBAAA,UAAhBA,gBAAgB,EAAhBA,gBAAgB,wBAAhBA,gBAAgB,oBAAhBA,gBAAgB,4BAAhB,CAAAA,gBAAgB","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.FinancialConnectionsSheetError=void 0;var FinancialConnectionsSheetError;exports.FinancialConnectionsSheetError=FinancialConnectionsSheetError;(function(FinancialConnectionsSheetError){FinancialConnectionsSheetError["Failed"]="Failed";FinancialConnectionsSheetError["Canceled"]="Canceled";})(FinancialConnectionsSheetError||(exports.FinancialConnectionsSheetError=FinancialConnectionsSheetError={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.FinancialConnectionsSheetError=exports.FinancialConnectionsEventName=exports.FinancialConnectionsEventErrorCode=void 0;var FinancialConnectionsSheetError=exports.FinancialConnectionsSheetError=function(FinancialConnectionsSheetError){FinancialConnectionsSheetError["Failed"]="Failed";FinancialConnectionsSheetError["Canceled"]="Canceled";return FinancialConnectionsSheetError;}({});var FinancialConnectionsEventName=exports.FinancialConnectionsEventName=function(FinancialConnectionsEventName){FinancialConnectionsEventName["Open"]="open";FinancialConnectionsEventName["ManualEntryInitiated"]="manual_entry_initiated";FinancialConnectionsEventName["ConsentAcquired"]="consent_acquired";FinancialConnectionsEventName["SearchInitiated"]="search_initiated";FinancialConnectionsEventName["InstitutionSelected"]="institution_selected";FinancialConnectionsEventName["InstitutionAuthorized"]="institution_authorized";FinancialConnectionsEventName["AccountsSelected"]="accounts_selected";FinancialConnectionsEventName["Success"]="success";FinancialConnectionsEventName["Error"]="error";FinancialConnectionsEventName["Cancel"]="cancel";FinancialConnectionsEventName["FlowLaunchedInBrowser"]="flow_launched_in_browser";return FinancialConnectionsEventName;}({});var FinancialConnectionsEventErrorCode=exports.FinancialConnectionsEventErrorCode=function(FinancialConnectionsEventErrorCode){FinancialConnectionsEventErrorCode["AccountNumbersUnavailable"]="account_numbers_unavailable";FinancialConnectionsEventErrorCode["AccountsUnavailable"]="accounts_unavailable";FinancialConnectionsEventErrorCode["NoDebitableAccount"]="no_debitable_account";FinancialConnectionsEventErrorCode["AuthorizationFailed"]="authorization_failed";FinancialConnectionsEventErrorCode["InstitutionUnavailablePlanned"]="institution_unavailable_planned";FinancialConnectionsEventErrorCode["InstitutionUnavailableUnplanned"]="institution_unavailable_unplanned";FinancialConnectionsEventErrorCode["InstitutionTimeout"]="institution_timeout";FinancialConnectionsEventErrorCode["UnexpectedError"]="unexpected_error";FinancialConnectionsEventErrorCode["SessionExpired"]="session_expired";FinancialConnectionsEventErrorCode["FailedBotDetection"]="failed_bot_detection";return FinancialConnectionsEventErrorCode;}({});
2
2
  //# sourceMappingURL=FinancialConnections.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["FinancialConnectionsSheetError"],"sources":["FinancialConnections.ts"],"sourcesContent":["import type { BankAccount } from './Token';\nimport type { StripeError } from './Errors';\n\nexport type SessionResult =\n | {\n /** The updated Financial Connections Session object. */\n session: Session;\n error?: undefined;\n }\n | {\n session?: undefined;\n error: StripeError<FinancialConnectionsSheetError>;\n };\n\nexport type TokenResult =\n | {\n /** The updated Financial Connections Session object. */\n session: Session;\n /** The Stripe token object associated with the bank account. */\n token: BankAccountToken;\n error?: undefined;\n }\n | {\n session?: undefined;\n token?: undefined;\n error: StripeError<FinancialConnectionsSheetError>;\n };\n\nexport type Session = {\n /** A unique ID for this session. */\n id: string;\n /** The client secret for this session. */\n clientSecret: string;\n /** Has the value true if the object exists in live mode or the value false if the object exists in test mode. */\n livemode: boolean;\n /** The accounts that were collected as part of this Session. */\n accounts: Array<Account>;\n};\n\nexport type BankAccountToken = {\n /** Bank account details. */\n bankAccount: BankAccount | null;\n /** Has the value true if the object exists in live mode or the value false if the object exists in test mode. */\n livemode: boolean;\n /** A unique ID for this token. */\n id: string | null;\n used: boolean;\n type: 'BankAccount';\n /** The UNIX timestamp (in milliseconds) of the date this token was created. */\n created: number | null;\n};\n\nexport type Account = {\n /** A unique ID for this Financial Connections Account. */\n id: string;\n /** Has the value true if the object exists in live mode or the value false if the object exists in test mode. */\n livemode: boolean;\n displayName: string | null;\n /** The current status of the account. Either active, inactive, or disconnected. */\n status: AccountStatus;\n institutionName: string;\n last4: string | null;\n /** The UNIX timestamp (in milliseconds) of the date this account was created. */\n created: number;\n /** The balance of this account. */\n balance: Balance | null;\n /** The last balance refresh. Includes the timestamp and the status. */\n balanceRefresh: BalanceRefresh | null;\n /** The category of this account, either cash, credit, investment, or other. */\n category: Category;\n /** The subcategory of this account, either checking, credit_card, line_of_credit, mortgage, savings, or other. */\n subcategory: Subcategory;\n /** Permissions requested for accounts collected during this session. */\n permissions: Array<Permission> | null;\n /** The supported payment method types for this account. */\n supportedPaymentMethodTypes: Array<PaymentMethodType>;\n};\n\nexport type AccountStatus = 'active' | 'inactive' | 'disconnected';\n\nexport type Category = 'cash' | 'credit' | 'investment' | 'other';\n\nexport type PaymentMethodType = 'us_bank_account' | 'link';\n\nexport type Subcategory =\n | 'checking'\n | 'creditCard'\n | 'lineOfCredit'\n | 'mortgage'\n | 'other'\n | 'savings';\n\nexport type Permission =\n | 'balances'\n | 'ownership'\n | 'paymentMethod'\n | 'transactions'\n | 'accountNumbers';\n\nexport type Balance = {\n /** The UNIX timestamp (in milliseconds) of time that the external institution calculated this balance. */\n asOf: number;\n /** The type of this balance, either cash or credit. */\n type: BalanceType;\n /** The funds available to the account holder. Typically this is the current balance less any holds. Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Each value is an integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder. */\n cash: { available: Map<String, number> | null };\n /** The credit that has been used by the account holder. Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Each value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder. */\n credit: { used: Map<String, number> | null };\n /** The balances owed to (or by) the account holder. Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Each value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder. */\n current: Map<String, number>;\n};\n\nexport type BalanceRefresh = {\n status: BalanceRefreshStatus;\n /** The UNIX timestamp (in milliseconds) of the time at which the last refresh attempt was initiated. */\n lastAttemptedAt: number;\n};\n\nexport type BalanceType = 'cash' | 'credit';\n\nexport type BalanceRefreshStatus = 'failed' | 'pending' | 'succeeded';\n\nexport enum FinancialConnectionsSheetError {\n Failed = 'Failed',\n Canceled = 'Canceled',\n}\n"],"mappings":"0GA0HYA,+BAA8B,iFAA9BA,8BAA8B,EAA9BA,8BAA8B,oBAA9BA,8BAA8B,2BAA9BA,8BAA8B,0CAA9BA,8BAA8B"}
1
+ {"version":3,"names":["FinancialConnectionsSheetError","exports","FinancialConnectionsEventName","FinancialConnectionsEventErrorCode"],"sourceRoot":"../../../src","sources":["types/FinancialConnections.ts"],"mappings":"2LAkIY,CAAAA,8BAA8B,CAAAC,OAAA,CAAAD,8BAAA,UAA9BA,8BAA8B,EAA9BA,8BAA8B,oBAA9BA,8BAA8B,8BAA9B,CAAAA,8BAA8B,UAY9B,CAAAE,6BAA6B,CAAAD,OAAA,CAAAC,6BAAA,UAA7BA,6BAA6B,EAA7BA,6BAA6B,gBAA7BA,6BAA6B,kDAA7BA,6BAA6B,uCAA7BA,6BAA6B,uCAA7BA,6BAA6B,+CAA7BA,6BAA6B,mDAA7BA,6BAA6B,yCAA7BA,6BAA6B,sBAA7BA,6BAA6B,kBAA7BA,6BAA6B,oBAA7BA,6BAA6B,2DAA7B,CAAAA,6BAA6B,UAkC7B,CAAAC,kCAAkC,CAAAF,OAAA,CAAAE,kCAAA,UAAlCA,kCAAkC,EAAlCA,kCAAkC,4DAAlCA,kCAAkC,+CAAlCA,kCAAkC,8CAAlCA,kCAAkC,+CAAlCA,kCAAkC,oEAAlCA,kCAAkC,wEAAlCA,kCAAkC,6CAAlCA,kCAAkC,uCAAlCA,kCAAkC,qCAAlCA,kCAAkC,oDAAlC,CAAAA,kCAAkC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["NextAction.ts"],"sourcesContent":["export type NextAction =\n | VerifyWithMicrodepositsAction\n | UrlRedirectAction\n | WeChatRedirectAction\n | AlipayRedirectAction\n | BoletoVoucherAction\n | OxxoVoucherAction;\n\nexport type VerifyWithMicrodepositsAction = {\n type: 'verifyWithMicrodeposits';\n redirectUrl: string;\n microdepositType: string;\n arrivalDate: string;\n};\n\nexport type UrlRedirectAction = {\n type: 'urlRedirect';\n redirectUrl: string;\n};\n\nexport type WeChatRedirectAction = {\n type: 'weChatRedirect';\n redirectUrl: string;\n};\n\nexport type AlipayRedirectAction = {\n type: 'alipayRedirect';\n redirectUrl: string;\n nativeRedirectUrl: string;\n};\n\nexport type BoletoVoucherAction = {\n type: 'boletoVoucher';\n voucherURL: string;\n};\n\nexport type KonbiniVoucherAction = {\n type: 'konbiniVoucher';\n voucherURL: string;\n};\n\nexport type OxxoVoucherAction = {\n type: 'oxxoVoucher';\n expiration: number;\n voucherURL: string;\n voucherNumber: string;\n};\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/NextAction.ts"],"mappings":"","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.Status=void 0;var Status;exports.Status=Status;(function(Status){Status["Succeeded"]="Succeeded";Status["RequiresPaymentMethod"]="RequiresPaymentMethod";Status["RequiresConfirmation"]="RequiresConfirmation";Status["Canceled"]="Canceled";Status["Processing"]="Processing";Status["RequiresAction"]="RequiresAction";Status["RequiresCapture"]="RequiresCapture";Status["Unknown"]="Unknown";})(Status||(exports.Status=Status={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.Status=void 0;var Status=exports.Status=function(Status){Status["Succeeded"]="Succeeded";Status["RequiresPaymentMethod"]="RequiresPaymentMethod";Status["RequiresConfirmation"]="RequiresConfirmation";Status["Canceled"]="Canceled";Status["Processing"]="Processing";Status["RequiresAction"]="RequiresAction";Status["RequiresCapture"]="RequiresCapture";Status["Unknown"]="Unknown";return Status;}({});
2
2
  //# sourceMappingURL=PaymentIntent.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["Status"],"sources":["PaymentIntent.ts"],"sourcesContent":["import type { StripeError } from '.';\nimport type { Address, BillingDetails } from './Common';\nimport type { Result as PaymentMethodResult } from './PaymentMethod';\nimport type { NextAction } from './NextAction';\nimport type * as PaymentMethod from './PaymentMethod';\nimport type { FormDetails } from './components/AuBECSDebitFormComponent';\nimport type { BankAcccountHolderType, BankAcccountType } from './Token';\nexport interface Result {\n id: string;\n amount: number;\n /** The UNIX timestamp (in milliseconds) of the date this PaymentIntent was created. */\n created: string;\n currency: string;\n status: Status;\n description: string | null;\n receiptEmail: string | null;\n canceledAt: string | null;\n clientSecret: string;\n livemode: boolean;\n /** @deprecated Use paymentMethod.id instead. */\n paymentMethodId: string;\n paymentMethod: PaymentMethodResult | null;\n captureMethod: CaptureMethod;\n confirmationMethod: CaptureMethod;\n lastPaymentError: LastPaymentError | null;\n shipping: ShippingDetails | null;\n nextAction: NextAction | null;\n}\n\nexport type CaptureMethod = 'Automatic' | 'Manual';\n\nexport type ConfirmParams =\n | CardParams\n | IdealParams\n | OxxoParams\n | P24Params\n | AlipayParams\n | GiropayParams\n | SepaParams\n | EpsParams\n | AuBecsDebitParams\n | SofortParams\n | GrabPayParams\n | FPXParams\n | AfterpayClearpayParams\n | KlarnaParams\n // | WeChatPayParams\n | BancontactParams\n | USBankAccountParams\n | PayPalParams\n | AffirmParams\n | CashAppParams\n | RevolutPayParams;\n\nexport type ConfirmOptions = PaymentMethod.ConfirmOptions;\n\nexport type LastPaymentError = StripeError<string> & {\n paymentMethod: PaymentMethodResult;\n};\n\nexport type FutureUsage = 'OffSession' | 'OnSession';\n\nexport interface ShippingDetails {\n address: Required<Address>;\n name: string;\n carrier: string;\n phone: string;\n trackingNumber: string;\n}\n\nexport enum Status {\n Succeeded = 'Succeeded',\n RequiresPaymentMethod = 'RequiresPaymentMethod',\n RequiresConfirmation = 'RequiresConfirmation',\n Canceled = 'Canceled',\n Processing = 'Processing',\n RequiresAction = 'RequiresAction',\n RequiresCapture = 'RequiresCapture',\n Unknown = 'Unknown',\n}\n\nexport type MandateData = {\n customerAcceptance: {\n online: {\n ipAddress: string;\n userAgent: string;\n };\n };\n};\n\nexport type CardParams =\n | {\n paymentMethodType: 'Card';\n paymentMethodData?: {\n token?: string;\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n }\n | {\n paymentMethodType: 'Card';\n paymentMethodData: {\n paymentMethodId: string;\n cvc?: string;\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n };\n\nexport interface IdealParams {\n paymentMethodType: 'Ideal';\n paymentMethodData?: {\n bankName?: string;\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface FPXParams {\n paymentMethodType: 'Fpx';\n paymentMethodData?: { testOfflineBank?: boolean; mandateData?: MandateData };\n}\n\nexport interface AlipayParams {\n paymentMethodType: 'Alipay';\n paymentMethodData?: {\n mandateData?: MandateData;\n };\n}\n\nexport interface OxxoParams {\n paymentMethodType: 'Oxxo';\n paymentMethodData: {\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface SofortParams {\n paymentMethodType: 'Sofort';\n paymentMethodData: {\n country: string;\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\nexport interface GrabPayParams {\n paymentMethodType: 'GrabPay';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface BancontactParams {\n paymentMethodType: 'Bancontact';\n paymentMethodData: {\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface SepaParams {\n paymentMethodType: 'SepaDebit';\n paymentMethodData: {\n iban: string;\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface GiropayParams {\n paymentMethodType: 'Giropay';\n paymentMethodData: {\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface AfterpayClearpayParams {\n paymentMethodType: 'AfterpayClearpay';\n paymentMethodData: {\n shippingDetails: BillingDetails;\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport type KlarnaParams = {\n paymentMethodType: 'Klarna';\n paymentMethodData: {\n billingDetails: Pick<Required<BillingDetails>, 'email'> & {\n address: Pick<Required<Address>, 'country'>;\n } & BillingDetails;\n shippingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n};\n\nexport interface EpsParams {\n paymentMethodType: 'Eps';\n paymentMethodData: {\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface P24Params {\n paymentMethodType: 'P24';\n paymentMethodData: {\n billingDetails: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface WeChatPayParams {\n paymentMethodType: 'WeChatPay';\n paymentMethodData: {\n appId: string;\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n}\n\nexport interface AuBecsDebitParams {\n paymentMethodType: 'AuBecsDebit';\n paymentMethodData: { formDetails: FormDetails; mandateData?: MandateData };\n}\n\nexport type AffirmParams = {\n paymentMethodType: 'Affirm';\n paymentMethodData?: {\n /** Affirm requires that shipping is present for the payment to succeed because it significantly helps with loan approval rates. Shipping details can either be provided here or via the Payment Intent- https://stripe.com/docs/api/payment_intents/create#create_payment_intent-shipping. */\n shippingDetails?: BillingDetails;\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n};\n\n/**\n * If paymentMethodData is null, it is assumed that the bank account details have already been attached\n * via `collectBankAccountForPayment` or `collectBankAccountForSetup`.\n */\nexport type USBankAccountParams = {\n paymentMethodType: 'USBankAccount';\n paymentMethodData?: {\n billingDetails: Pick<Required<BillingDetails>, 'name'> & BillingDetails;\n accountNumber: string;\n routingNumber: string;\n /** Defaults to Individual */\n accountHolderType?: BankAcccountHolderType;\n /** Defaults to Checking */\n accountType?: BankAcccountType;\n mandateData?: MandateData;\n };\n};\n\nexport type PayPalParams = {\n paymentMethodType: 'PayPal';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n};\n\nexport type CashAppParams = {\n paymentMethodType: 'CashApp';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n};\n\nexport type RevolutPayParams = {\n paymentMethodType: 'RevolutPay';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n mandateData?: MandateData;\n };\n};\n\nexport type CollectBankAccountParams = {\n paymentMethodType: 'USBankAccount';\n paymentMethodData: {\n billingDetails: {\n name: string;\n email?: string;\n };\n mandateData?: MandateData;\n };\n};\n"],"mappings":"kFAsEYA,OAAM,iCAANA,MAAM,EAANA,MAAM,0BAANA,MAAM,kDAANA,MAAM,gDAANA,MAAM,wBAANA,MAAM,4BAANA,MAAM,oCAANA,MAAM,sCAANA,MAAM,yBAANA,MAAM,kBAANA,MAAM"}
1
+ {"version":3,"names":["Status","exports"],"sourceRoot":"../../../src","sources":["types/PaymentIntent.ts"],"mappings":"kFAsEY,CAAAA,MAAM,CAAAC,OAAA,CAAAD,MAAA,UAANA,MAAM,EAANA,MAAM,0BAANA,MAAM,kDAANA,MAAM,gDAANA,MAAM,wBAANA,MAAM,4BAANA,MAAM,oCAANA,MAAM,sCAANA,MAAM,4BAAN,CAAAA,MAAM","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["PaymentMethod.ts"],"sourcesContent":["import type { FormDetails } from './components/AuBECSDebitFormComponent';\nimport type {\n CardBrand,\n BankAcccountHolderType,\n BankAcccountType,\n} from './Token';\nimport type { FutureUsage } from './PaymentIntent';\nimport type { Address, BillingDetails } from './Common';\n\nexport interface Result {\n id: string;\n liveMode: boolean;\n customerId: string;\n billingDetails: BillingDetails;\n paymentMethodType: Type;\n AuBecsDebit: AuBecsDebitResult;\n BacsDebit: BacsDebitResult;\n Card: CardResult;\n Fpx: FpxResult;\n Ideal: IdealResult;\n SepaDebit: SepaDebitResult;\n Sofort: SofortResult;\n Upi: UpiResult;\n USBankAccount: USBankAccountResult;\n}\n\nexport type CreateParams =\n | CardParams\n | IdealParams\n | OxxoParams\n | P24Params\n | AlipayParams\n | GiropayParams\n | SepaParams\n | EpsParams\n | AuBecsDebitParams\n | SofortParams\n | GrabPayParams\n | FPXParams\n | AfterpayClearpayParams\n | KlarnaParams\n // | WeChatPayParams\n | BancontactParams\n | USBankAccountParams\n | PayPalParams\n | AffirmParams\n | CashAppParams;\n\nexport type ConfirmParams = CreateParams;\n\nexport type CreateOptions = {\n setupFutureUsage?: FutureUsage;\n};\n\nexport type ConfirmOptions = CreateOptions;\n\nexport type ShippingDetails = BillingDetails;\n\nexport type CardParams =\n | {\n paymentMethodType: 'Card';\n paymentMethodData?: {\n token?: string;\n billingDetails?: BillingDetails;\n };\n }\n | {\n paymentMethodType: 'Card';\n paymentMethodData: {\n paymentMethodId: string;\n cvc?: string;\n billingDetails?: BillingDetails;\n };\n };\n\nexport interface IdealParams {\n paymentMethodType: 'Ideal';\n paymentMethodData?: {\n bankName?: string;\n billingDetails?: BillingDetails;\n };\n}\n\nexport interface FPXParams {\n paymentMethodType: 'Fpx';\n paymentMethodData?: { testOfflineBank?: boolean };\n}\n\nexport interface AlipayParams {\n paymentMethodType: 'Alipay';\n}\n\nexport interface OxxoParams {\n paymentMethodType: 'Oxxo';\n paymentMethodData: {\n billingDetails: BillingDetails;\n };\n}\n\nexport interface SofortParams {\n paymentMethodType: 'Sofort';\n paymentMethodData: {\n country: string;\n billingDetails: BillingDetails;\n };\n}\nexport interface GrabPayParams {\n paymentMethodType: 'GrabPay';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n };\n}\n\nexport interface BancontactParams {\n paymentMethodType: 'Bancontact';\n paymentMethodData: {\n billingDetails: BillingDetails;\n };\n}\n\nexport interface SepaParams {\n paymentMethodType: 'SepaDebit';\n paymentMethodData: {\n iban: string;\n billingDetails: BillingDetails;\n };\n}\n\nexport interface GiropayParams {\n paymentMethodType: 'Giropay';\n paymentMethodData: {\n billingDetails: BillingDetails;\n };\n}\n\nexport interface AfterpayClearpayParams {\n paymentMethodType: 'AfterpayClearpay';\n paymentMethodData: {\n shippingDetails: ShippingDetails;\n billingDetails: BillingDetails;\n };\n}\n\nexport type KlarnaParams = {\n paymentMethodType: 'Klarna';\n paymentMethodData: {\n billingDetails: Pick<Required<BillingDetails>, 'email'> & {\n address: Pick<Required<Address>, 'country'>;\n } & BillingDetails;\n shippingDetails?: ShippingDetails;\n };\n};\n\nexport interface EpsParams {\n paymentMethodType: 'Eps';\n paymentMethodData: {\n billingDetails: BillingDetails;\n };\n}\n\nexport interface P24Params {\n paymentMethodType: 'P24';\n paymentMethodData: {\n billingDetails: BillingDetails;\n };\n}\n\nexport interface WeChatPayParams {\n paymentMethodType: 'WeChatPay';\n paymentMethodData: {\n appId: string;\n billingDetails?: BillingDetails;\n };\n}\n\nexport interface AuBecsDebitParams {\n paymentMethodType: 'AuBecsDebit';\n paymentMethodData: { formDetails: FormDetails };\n}\n\nexport type AffirmParams = {\n paymentMethodType: 'Affirm';\n paymentMethodData?: {\n /** Affirm requires that shipping is present for the payment to succeed because it significantly helps with loan approval rates. Shipping details can either be provided here or via the Payment Intent- https://stripe.com/docs/api/payment_intents/create#create_payment_intent-shipping. */\n shippingDetails?: ShippingDetails;\n billingDetails?: BillingDetails;\n };\n};\n\n/**\n * If paymentMethodData is null, it is assumed that the bank account details have already been attached\n * via `collectBankAccountForPayment` or `collectBankAccountForSetup`.\n */\nexport type USBankAccountParams = {\n paymentMethodType: 'USBankAccount';\n paymentMethodData?: {\n billingDetails: Pick<Required<BillingDetails>, 'name'> & BillingDetails;\n accountNumber: string;\n routingNumber: string;\n /** Defaults to Individual */\n accountHolderType?: BankAcccountHolderType;\n /** Defaults to Checking */\n accountType?: BankAcccountType;\n };\n};\n\nexport type PayPalParams = {\n paymentMethodType: 'PayPal';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n };\n};\n\nexport type CashAppParams = {\n paymentMethodType: 'CashApp';\n paymentMethodData?: {\n billingDetails?: BillingDetails;\n };\n};\n\nexport interface AuBecsDebitResult {\n fingerprint?: string;\n last4?: string;\n bsbNumber?: string;\n}\n\nexport interface BacsDebitResult {\n sortCode?: string;\n last4?: string;\n fingerprint?: string;\n}\n\nexport interface CardResult {\n brand?: CardBrand;\n country?: string;\n expYear?: number;\n expMonth?: number;\n fingerprint?: string;\n funding?: string;\n last4?: string;\n preferredNetwork?: string;\n availableNetworks?: Array<string>;\n threeDSecureUsage?: ThreeDSecureUsage;\n}\n\nexport interface ThreeDSecureUsage {\n isSupported?: boolean;\n}\n\nexport interface FpxResult {\n bank?: string;\n}\n\nexport interface IdealResult {\n bankIdentifierCode?: string;\n bank?: string;\n}\n\nexport interface SepaDebitResult {\n bankCode?: string;\n country?: string;\n fingerprint?: string;\n last4?: string;\n}\n\nexport interface SofortResult {\n country?: string;\n}\n\nexport interface UpiResult {\n vpa?: string;\n}\n\nexport type USBankAccountResult = {\n routingNumber?: string;\n accountHolderType?: BankAcccountHolderType;\n accountType?: BankAcccountType;\n last4?: string;\n bankName?: string;\n linkedAccount?: string;\n fingerprint?: string;\n preferredNetwork?: string;\n supportedNetworks?: string[];\n};\n\nexport type Type =\n | 'AfterpayClearpay'\n | 'Card'\n | 'Alipay'\n | 'GrabPay'\n | 'Ideal'\n | 'Fpx'\n | 'CardPresent'\n | 'SepaDebit'\n | 'AuBecsDebit'\n | 'BacsDebit'\n | 'Giropay'\n | 'P24'\n | 'Eps'\n | 'Bancontact'\n | 'Oxxo'\n | 'Sofort'\n | 'Upi'\n | 'USBankAccount'\n | 'PayPal'\n | 'Unknown';\n\nexport type CollectBankAccountParams = {\n paymentMethodType: 'USBankAccount';\n paymentMethodData: {\n billingDetails: {\n name: string;\n email?: string;\n };\n };\n};\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/PaymentMethod.ts"],"mappings":"","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.PaymentMethodLayout=exports.CollectionMode=exports.CaptureMethod=exports.AddressCollectionMode=void 0;var CollectionMode;exports.CollectionMode=CollectionMode;(function(CollectionMode){CollectionMode["AUTOMATIC"]="automatic";CollectionMode["NEVER"]="never";CollectionMode["ALWAYS"]="always";})(CollectionMode||(exports.CollectionMode=CollectionMode={}));var AddressCollectionMode;exports.AddressCollectionMode=AddressCollectionMode;(function(AddressCollectionMode){AddressCollectionMode["AUTOMATIC"]="automatic";AddressCollectionMode["NEVER"]="never";AddressCollectionMode["FULL"]="full";})(AddressCollectionMode||(exports.AddressCollectionMode=AddressCollectionMode={}));var CaptureMethod;exports.CaptureMethod=CaptureMethod;(function(CaptureMethod){CaptureMethod["Automatic"]="Automatic";CaptureMethod["Manual"]="Manual";CaptureMethod["AutomaticAsync"]="AutomaticAsync";})(CaptureMethod||(exports.CaptureMethod=CaptureMethod={}));var PaymentMethodLayout;exports.PaymentMethodLayout=PaymentMethodLayout;(function(PaymentMethodLayout){PaymentMethodLayout["Horizontal"]="Horizontal";PaymentMethodLayout["Vertical"]="Vertical";PaymentMethodLayout["Automatic"]="Automatic";})(PaymentMethodLayout||(exports.PaymentMethodLayout=PaymentMethodLayout={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.PaymentMethodLayout=exports.CollectionMode=exports.CardBrandCategory=exports.CardBrandAcceptanceFilter=exports.CaptureMethod=exports.AddressCollectionMode=void 0;var CollectionMode=exports.CollectionMode=function(CollectionMode){CollectionMode["AUTOMATIC"]="automatic";CollectionMode["NEVER"]="never";CollectionMode["ALWAYS"]="always";return CollectionMode;}({});var AddressCollectionMode=exports.AddressCollectionMode=function(AddressCollectionMode){AddressCollectionMode["AUTOMATIC"]="automatic";AddressCollectionMode["NEVER"]="never";AddressCollectionMode["FULL"]="full";return AddressCollectionMode;}({});var CaptureMethod=exports.CaptureMethod=function(CaptureMethod){CaptureMethod["Automatic"]="Automatic";CaptureMethod["Manual"]="Manual";CaptureMethod["AutomaticAsync"]="AutomaticAsync";return CaptureMethod;}({});var PaymentMethodLayout=exports.PaymentMethodLayout=function(PaymentMethodLayout){PaymentMethodLayout["Horizontal"]="Horizontal";PaymentMethodLayout["Vertical"]="Vertical";PaymentMethodLayout["Automatic"]="Automatic";return PaymentMethodLayout;}({});var CardBrandCategory=exports.CardBrandCategory=function(CardBrandCategory){CardBrandCategory["Visa"]="visa";CardBrandCategory["Mastercard"]="mastercard";CardBrandCategory["Amex"]="amex";CardBrandCategory["Discover"]="discover";return CardBrandCategory;}({});var CardBrandAcceptanceFilter=exports.CardBrandAcceptanceFilter=function(CardBrandAcceptanceFilter){CardBrandAcceptanceFilter["All"]="all";CardBrandAcceptanceFilter["Allowed"]="allowed";CardBrandAcceptanceFilter["Disallowed"]="disallowed";return CardBrandAcceptanceFilter;}({});
2
2
  //# sourceMappingURL=PaymentSheet.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["CollectionMode","AddressCollectionMode","CaptureMethod","PaymentMethodLayout"],"sources":["PaymentSheet.ts"],"sourcesContent":["import type { BillingDetails, AddressDetails, CardBrand } from './Common';\nimport type { CartSummaryItem } from './ApplePay';\nimport type {\n ButtonType,\n RecurringPaymentRequest,\n AutomaticReloadPaymentRequest,\n MultiMerchantRequest,\n} from './PlatformPay';\nimport type { FutureUsage } from './PaymentIntent';\nimport type { Result } from './PaymentMethod';\nimport type { StripeError } from './Errors';\n\ntype SetupParamsBase = IntentParams & {\n /** Your customer-facing business name. On Android, this is required and cannot be an empty string. */\n merchantDisplayName: string;\n /** The identifier of the Stripe Customer object. See https://stripe.com/docs/api/customers/object#customer_object-id */\n customerId?: string;\n /** When set to true, separates out the payment method selection & confirmation steps.\n * If true, you must call `confirmPaymentSheetPayment` on your own. Defaults to false. */\n customFlow?: boolean;\n /** iOS only. Enable Apple Pay in the Payment Sheet by passing an ApplePayParams object. */\n applePay?: ApplePayParams;\n /** Android only. Enable Google Pay in the Payment Sheet by passing a GooglePayParams object. */\n googlePay?: GooglePayParams;\n /** The color styling to use for PaymentSheet UI. Defaults to 'automatic'. */\n style?: 'alwaysLight' | 'alwaysDark' | 'automatic';\n /** A URL that redirects back to your app that PaymentSheet can use to auto-dismiss web views used for additional authentication, e.g. 3DS2 */\n returnURL?: string;\n /** Configuration for how billing details are collected during checkout. */\n billingDetailsCollectionConfiguration?: BillingDetailsCollectionConfiguration;\n /** PaymentSheet pre-populates the billing fields that are displayed in the Payment Sheet (only country and postal code, as of this version) with the values provided. */\n defaultBillingDetails?: BillingDetails;\n /**\n * The shipping information for the customer. If set, PaymentSheet will pre-populate the form fields with the values provided.\n * This is used to display a \"Billing address is same as shipping\" checkbox if `defaultBillingDetails` is not provided.\n * If `name` and `line1` are populated, it's also [attached to the PaymentIntent](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-shipping) during payment.\n */\n defaultShippingDetails?: AddressDetails;\n /** If true, allows payment methods that do not move money at the end of the checkout. Defaults to false.\n *\n * Some payment methods can’t guarantee you will receive funds from your customer at the end of the checkout\n * because they take time to settle (eg. most bank debits, like SEPA or ACH) or require customer action to\n * complete (e.g. OXXO, Konbini, Boleto). If this is set to true, make sure your integration listens to webhooks\n * for notifications on whether a payment has succeeded or not.\n */\n allowsDelayedPaymentMethods?: boolean;\n /** Customizes the appearance of PaymentSheet */\n appearance?: AppearanceParams;\n /** The label to use for the primary button. If not set, Payment Sheet will display suitable default labels for payment and setup intents. */\n primaryButtonLabel?: string;\n /** Optional configuration to display a custom message when a saved payment method is removed. iOS only. */\n removeSavedPaymentMethodMessage?: string;\n /** The list of preferred networks that should be used to process payments made with a co-branded card.\n * This value will only be used if your user hasn't selected a network themselves. */\n preferredNetworks?: Array<CardBrand>;\n /** By default, PaymentSheet will use a dynamic ordering that optimizes payment method display for the customer.\n * You can override the default order in which payment methods are displayed in PaymentSheet with a list of payment method types.\n * See https://stripe.com/docs/api/payment_methods/object#payment_method_object-type for the list of valid types. You may also pass external payment methods.\n * - Example: [\"card\", \"external_paypal\", \"klarna\"]\n * - Note: If you omit payment methods from this list, they’ll be automatically ordered by Stripe after the ones you provide. Invalid payment methods are ignored.\n */\n paymentMethodOrder?: Array<String>;\n /** This is an experimental feature that may be removed at any time.\n * Defaults to true. If true, the customer can delete all saved payment methods.\n * If false, the customer can't delete if they only have one saved payment method remaining.\n */\n allowsRemovalOfLastSavedPaymentMethod?: boolean;\n /**\n * Defines the layout orientations available for displaying payment methods in PaymentSheet.\n * - Note: Defaults to `Automatic` if not set\n */\n paymentMethodLayout?: PaymentMethodLayout;\n};\n\nexport type SetupParams =\n | (SetupParamsBase & {\n /** A short-lived token that allows the SDK to access a Customer’s payment methods. */\n customerEphemeralKeySecret: string;\n customerSessionClientSecret?: never;\n })\n | (SetupParamsBase & {\n customerEphemeralKeySecret?: never;\n /** (Experimental) This parameter can be changed or removed at any time (use at your own risk).\n * The client secret of this Customer Session. Used on the client to set up secure access to the given customer.\n */\n customerSessionClientSecret: string;\n })\n | SetupParamsBase;\n\nexport type IntentParams =\n | {\n paymentIntentClientSecret: string;\n setupIntentClientSecret?: undefined;\n intentConfiguration?: never;\n }\n | {\n setupIntentClientSecret: string;\n paymentIntentClientSecret?: undefined;\n intentConfiguration?: never;\n }\n | {\n setupIntentClientSecret?: never;\n paymentIntentClientSecret?: never;\n intentConfiguration: IntentConfiguration;\n };\n\nexport type ApplePayParams = {\n /** The two-letter ISO 3166 code of the country of your business, e.g. \"US\" */\n merchantCountryCode: string;\n /**\n * An array of CartSummaryItem item objects that summarize the amount of the payment. If you're using a SetupIntent\n * for a recurring payment, you should set this to display the amount you intend to charge. */\n cartItems?: CartSummaryItem[];\n /** Sets the text displayed by the call to action button in the Apple Pay sheet. */\n buttonType?: ButtonType;\n /** A typical request is for a one-time payment. To support different types of payment requests, include a PaymentRequestType. Only supported on iOS 16 and up. */\n request?:\n | RecurringPaymentRequest\n | AutomaticReloadPaymentRequest\n | MultiMerchantRequest;\n /** Callback function for setting the order details (retrieved from your server) to give users the\n * ability to track and manage their purchases in Wallet. Stripe calls your implementation after the\n * payment is complete, but before iOS dismisses the Apple Pay sheet. You must call the `completion`\n * function, or else the Apple Pay sheet will hang. */\n setOrderTracking?: (\n completion: (\n orderIdentifier: string,\n orderTypeIdentifier: string,\n authenticationToken: string,\n webServiceUrl: string\n ) => void\n ) => void;\n};\n\nexport type GooglePayParams = {\n /** The two-letter ISO 3166 code of the country of your business, e.g. \"US\" */\n merchantCountryCode: string;\n /** The three-letter ISO 4217 alphabetic currency code, e.g. \"USD\" or \"EUR\". Required in order to support Google Pay when processing a Setup Intent. */\n currencyCode?: string;\n /** Whether or not to use the Google Pay test environment. Set to `true` until you have applied for and been granted access to the Production environment. */\n testEnv?: boolean;\n /** An optional label to display with the amount. Google Pay may or may not display this label depending on its own internal logic. Defaults to a generic label if none is provided. */\n label?: string;\n /** An optional amount to display for setup intents. Google Pay may or may not display this amount depending on its own internal logic. Defaults to 0 if none is provided. */\n amount?: string;\n /** The Google Pay button type to use. Set to \"Pay\" by default. See\n * [Google's documentation](https://developers.google.com/android/reference/com/google/android/gms/wallet/Wallet.WalletOptions#environment)\n * for more information on button types. */\n buttonType?: ButtonType;\n};\n\n/**\n * Used to customize the appearance of your PaymentSheet\n */\nexport type AppearanceParams = RecursivePartial<{\n /** Describes the appearance of fonts in your PaymentSheet */\n font: FontConfig;\n /** Describes the colors in your PaymentSheet. Provide either a base config, or both `light` and `dark` configs, which will be useed based on whether the user is in Light or Dark mode. */\n colors:\n | GlobalColorConfig\n | { light: GlobalColorConfig; dark: GlobalColorConfig };\n /** Describes the appearance of shapes in the PaymentSheet, such as buttons, inputs, and tabs. */\n shapes: {\n /** The border radius used for buttons, inputs, and tabs in your PaymentSheet.\n * @default 6.0\n */\n borderRadius: number;\n /** The border width used for inputs and tabs in your PaymentSheet.\n * @default 1.0\n */\n borderWidth: number;\n /** iOS only. The shadow used for buttons, inputs, and tabs in your PaymentSheet */\n shadow: ShadowConfig;\n };\n /** Describes the appearance of the primary \"Pay\" button at the bottom of your Payment Sheet */\n primaryButton: PrimaryButtonConfig;\n}>;\n\nexport type FontConfig = {\n /**\n * The font used for regular text. PaymentSheet will attempt to use medium and bold versions of this font if they exist.\n *\n * On iOS, this should be the \"PostScript name\" found in Font Book after installing the font.\n * On Android, this should be the name of the font file (containing only lowercase alphanumeric characters) in android/app/src/main/res/font\n *\n * @default The OS's system font\n */\n family: string;\n /** The scale factor for all fonts in your PaymentSheet. This value is required to be greater than 0. Font sizes are multiplied by this value before being displayed. For example, setting this to 1.2 increases the size of all text by 20%.\n * @default 1.0\n */\n scale: number;\n};\n\nexport type ShadowConfig = {\n /** The color of the shadow.\n * @default \"#000000\"\n * */\n color: string;\n /** The alpha or opacity of the shadow.\n * @default 0.05\n */\n opacity: number;\n /** The positioning of the shadow relative to the component. For example, a negative x and y will result in a shadow placed below and to the left of the component.\n * @default {x: 0, y: 2}\n */\n offset: { x: number; y: number };\n /** The blur radius of the shadow.\n * @default 4\n */\n blurRadius: number;\n};\n\nexport type GlobalColorConfig = {\n /** A primary color used throughout your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System blue color on iOS, and \"#007AFF\" (light) / \"#0074D4\" (dark) on Android.\n */\n primary: string;\n /** The color used for the background of your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System background color on iOS, and \"#ffffff\" (light) / \"#2e2e2e\" (dark) on Android.\n */\n background: string;\n /** The color used for the background of inputs, tabs, and other components in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System background color (light) / System secondary background color (dark) on iOS, and \"#ffffff\" (light) / \"#a9a9a9\" (dark) on Android.\n */\n componentBackground: string;\n /** The color used for the external border of inputs, tabs, and other components in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System gray (3) color on iOS, and \"#33787880\" (light) / \"#787880\" (dark) on Android.\n */\n componentBorder: string;\n /** The color used for the internal border (meaning the border is shared with another component) of inputs, tabs, and other components in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System gray (3) color on iOS, and \"#33787880\" (light) / \"#787880\" (dark) on Android.\n */\n componentDivider: string;\n /** The color of the header text in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System label color on iOS, and \"#000000\" (light) / \"#ffffff\" (dark) on Android.\n */\n primaryText: string;\n /** The color of the label text of input fields, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System seconday label color on iOS, and \"#000000\" (light) / \"#ffffff\" (dark) on Android.\n */\n secondaryText: string;\n /** The color of the input text in your PaymentSheet components, such as the user's card number or zip code, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default \"#000000\"\n */\n componentText: string;\n /** The color of the placeholder text of input fields, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System label color on iOS, and \"#99000000\" (light) / \"#99ffffff\" (dark) on Android.\n */\n placeholderText: string;\n /** The color used for icons in your Payment Sheet, such as the close or back icons, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System seconday label color on iOS, and \"#99000000\" (light) / \"#ffffff\" (dark) on Android.\n */\n icon: string;\n /** The color used to indicate errors or destructive actions in your Payment Sheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System red color on iOS, and \"#ff0000\" (light) / \"#ff0000\" (dark) on Android.\n */\n error: string;\n};\n\nexport type PrimaryButtonConfig = {\n /** The font family used specifically for the primary button.\n * @default The root `appearance.font.family`\n */\n font: Pick<FontConfig, 'family'>;\n /** The colors used specifically for the primary button. Provide either a base config, or both `light` and `dark` configs, which will be useed based on whether the user is in Light or Dark mode. */\n colors:\n | PrimaryButtonColorConfig\n | { light: PrimaryButtonColorConfig; dark: PrimaryButtonColorConfig };\n /** Describes the border and shadow of the primary button. */\n shapes: {\n /** The border radius used for the primary button in your PaymentSheet\n * @default The root `appearance.shapes.borderRadius`\n */\n borderRadius: number;\n /** The border width used for the primary button in your PaymentSheet\n * @default The root `appearance.shapes.borderWidth`\n */\n borderWidth: number;\n /** iOS only. The shadow used for the primary button in your PaymentSheet\n * @default The root `appearance.shapes.shadow`\n */\n shadow: ShadowConfig;\n };\n};\n\nexport type PrimaryButtonColorConfig = {\n /** The background color used for the primary button in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The root `appearance.colors.primary`\n */\n background: string;\n /** The color of the text for the primary button in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default White or black, depending on the color of the button.\n */\n text: string;\n /** The border color used for the primary button in your PaymentSheet, represented as a hex string with format #RRGGBB or #AARRGGBB.\n * @default The System quaternary label on iOS, transparent on Android.\n */\n border: string;\n};\n\ntype RecursivePartial<T> = {\n [P in keyof T]?: T[P] extends (infer U)[]\n ? RecursivePartial<U>[]\n : T[P] extends object\n ? RecursivePartial<T[P]>\n : T[P];\n};\nexport interface PaymentOption {\n label: string;\n image: string;\n}\n\nexport type PresentOptions = {\n /** The number of milliseconds (after presenting) before the Payment Sheet closes automatically, at which point\n *`presentPaymentSheet` will resolve with an `error.code` of `PaymentSheetError.Timeout`. The default is no timeout.\n */\n timeout?: number;\n};\n\nexport type BillingDetailsCollectionConfiguration = {\n /** How to collect the name field. Defaults to `CollectionMode.automatic`. */\n name?: CollectionMode;\n /** How to collect the phone field. Defaults to `CollectionMode.automatic`. */\n phone?: CollectionMode;\n /** How to collect the email field. Defaults to `CollectionMode.automatic`. */\n email?: CollectionMode;\n /** How to collect the billing address. Defaults to `CollectionMode.automatic`. */\n address?: AddressCollectionMode;\n /** Whether the values included in `Configuration.defaultBillingDetails` should be attached to the payment method, this includes fields that aren't displayed in the form. If `false` (the default), those values will only be used to prefill the corresponding fields in the form. */\n attachDefaultsToPaymentMethod?: Boolean;\n};\n\nexport enum CollectionMode {\n /** The field may or may not be collected depending on the Payment Method's requirements. */\n AUTOMATIC = 'automatic',\n /** The field will never be collected. If this field is required by the Payment Method, you must provide it as part of `defaultBillingDetails`. */\n NEVER = 'never',\n /** The field will always be collected, even if it isn't required for the Payment Method. */\n ALWAYS = 'always',\n}\n\nexport enum AddressCollectionMode {\n /** Only the fields required by the Payment Method will be collected, which may be none. */\n AUTOMATIC = 'automatic',\n /** Billing address will never be collected. If the Payment Method requires a billing address, you must provide it as part of `defaultBillingDetails`. */\n NEVER = 'never',\n /** Collect the full billing address, regardless of the Payment Method's requirements. */\n FULL = 'full',\n}\n\nexport type IntentCreationError = StripeError<'Failed'>;\n\nexport type IntentCreationCallbackParams =\n | {\n clientSecret: string;\n error?: never;\n }\n | {\n clientSecret?: never;\n error: IntentCreationError;\n };\n\nexport type IntentConfiguration = {\n /*\n Called when the customer confirms payment. Your implementation should create a PaymentIntent or SetupIntent on your server and call the `intentCreationCallback` with its client secret or an error if one occurred.\n - Note: You must create the PaymentIntent or SetupIntent with the same values used as the `IntentConfiguration` e.g. the same amount, currency, etc.\n - Parameters:\n - paymentMethod: The PaymentMethod representing the customer's payment details.\n - shouldSavePaymentMethod: This is `true` if the customer selected the \"Save this payment method for future use\" checkbox. Set `setup_future_usage` on the PaymentIntent to `off_session` if this is `true`.\n - intentCreationCallback: Call this with the `client_secret` of the PaymentIntent or SetupIntent created by your server or the error that occurred. If you're using customFlow: false (default), the error's localizedMessage will be displayed to the customer in the sheet. If you're using customFlow: true, the `confirm` method fails with the error.\n */\n confirmHandler: (\n paymentMethod: Result,\n shouldSavePaymentMethod: boolean,\n intentCreationCallback: (result: IntentCreationCallbackParams) => void\n ) => void;\n /* Information about the payment (PaymentIntent) or setup (SetupIntent).*/\n mode: Mode;\n /* A list of payment method types to display to the customer. If undefined or empty, we dynamically determine the payment methods using your Stripe Dashboard settings. */\n paymentMethodTypes?: Array<string>;\n};\n\nexport type Mode = PaymentMode | SetupMode;\n\n/**\n * Controls when the funds will be captured. Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-capture_method\n */\nexport enum CaptureMethod {\n /** (Default) Stripe automatically captures funds when the customer authorizes the payment. */\n Automatic = 'Automatic',\n /** Place a hold on the funds when the customer authorizes the payment, but don’t capture the funds until later. (Not all payment methods support this.) */\n Manual = 'Manual',\n /** Asynchronously capture funds when the customer authorizes the payment.\n - Note: Recommended over `CaptureMethod.Automatic` due to improved latency, but may require additional integration changes.\n - Seealso: https://stripe.com/docs/payments/payment-intents/asynchronous-capture-automatic-async */\n AutomaticAsync = 'AutomaticAsync',\n}\n\n/* Use this if your integration creates a PaymentIntent */\nexport type PaymentMode = {\n /* Amount intended to be collected in the smallest currency unit (e.g. 100 cents to charge $1.00). Shown in Apple Pay, Google Pay, Buy now pay later UIs, the Pay button, and influences available payment methods.\n Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-amount */\n amount: number;\n /* Three-letter ISO currency code. Filters out payment methods based on supported currency.\n Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-currency */\n currencyCode: string;\n /* Indicates that you intend to make future payments.\n Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage */\n setupFutureUsage?: FutureUsage;\n /* Controls when the funds will be captured.\n Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-capture_method */\n captureMethod?: CaptureMethod;\n};\n\n/* Use this if your integration creates a SetupIntent */\nexport type SetupMode = {\n /* Three-letter ISO currency code. Filters out payment methods based on supported currency.\n Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-currency */\n currencyCode?: string;\n /* Indicates that you intend to make future payments.\n Seealso: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage */\n setupFutureUsage: FutureUsage;\n};\n\nexport enum PaymentMethodLayout {\n /**\n * Payment methods are arranged horizontally.\n * Users can swipe left or right to navigate through different payment methods.\n */\n Horizontal = 'Horizontal',\n\n /**\n * Payment methods are arranged vertically.\n * Users can scroll up or down to navigate through different payment methods.\n */\n Vertical = 'Vertical',\n\n /**\n * This lets Stripe choose the best layout for payment methods in the sheet.\n */\n Automatic = 'Automatic',\n}\n"],"mappings":"0KA6UYA,eAAc,iDAAdA,cAAc,EAAdA,cAAc,0BAAdA,cAAc,kBAAdA,cAAc,uBAAdA,cAAc,0BAAdA,cAAc,SASdC,sBAAqB,+DAArBA,qBAAqB,EAArBA,qBAAqB,0BAArBA,qBAAqB,kBAArBA,qBAAqB,mBAArBA,qBAAqB,iCAArBA,qBAAqB,SA8CrBC,cAAa,+CAAbA,aAAa,EAAbA,aAAa,0BAAbA,aAAa,oBAAbA,aAAa,uCAAbA,aAAa,yBAAbA,aAAa,SAqCbC,oBAAmB,2DAAnBA,mBAAmB,EAAnBA,mBAAmB,4BAAnBA,mBAAmB,wBAAnBA,mBAAmB,6BAAnBA,mBAAmB,+BAAnBA,mBAAmB"}
1
+ {"version":3,"names":["CollectionMode","exports","AddressCollectionMode","CaptureMethod","PaymentMethodLayout","CardBrandCategory","CardBrandAcceptanceFilter"],"sourceRoot":"../../../src","sources":["types/PaymentSheet.ts"],"mappings":"sOAyVY,CAAAA,cAAc,CAAAC,OAAA,CAAAD,cAAA,UAAdA,cAAc,EAAdA,cAAc,0BAAdA,cAAc,kBAAdA,cAAc,0BAAd,CAAAA,cAAc,UASd,CAAAE,qBAAqB,CAAAD,OAAA,CAAAC,qBAAA,UAArBA,qBAAqB,EAArBA,qBAAqB,0BAArBA,qBAAqB,kBAArBA,qBAAqB,sBAArB,CAAAA,qBAAqB,UA8CrB,CAAAC,aAAa,CAAAF,OAAA,CAAAE,aAAA,UAAbA,aAAa,EAAbA,aAAa,0BAAbA,aAAa,oBAAbA,aAAa,0CAAb,CAAAA,aAAa,UAqCb,CAAAC,mBAAmB,CAAAH,OAAA,CAAAG,mBAAA,UAAnBA,mBAAmB,EAAnBA,mBAAmB,4BAAnBA,mBAAmB,wBAAnBA,mBAAmB,gCAAnB,CAAAA,mBAAmB,UAoBnB,CAAAC,iBAAiB,CAAAJ,OAAA,CAAAI,iBAAA,UAAjBA,iBAAiB,EAAjBA,iBAAiB,gBAAjBA,iBAAiB,4BAAjBA,iBAAiB,gBAAjBA,iBAAiB,8BAAjB,CAAAA,iBAAiB,UAejB,CAAAC,yBAAyB,CAAAL,OAAA,CAAAK,yBAAA,UAAzBA,yBAAyB,EAAzBA,yBAAyB,cAAzBA,yBAAyB,sBAAzBA,yBAAyB,kCAAzB,CAAAA,yBAAyB","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.PaymentType=exports.PaymentRequestType=exports.InvalidShippingField=exports.IntervalUnit=exports.ContactField=exports.ButtonType=exports.ButtonStyle=exports.BillingAddressFormat=exports.ApplePayShippingType=exports.ApplePaySheetErrorType=exports.ApplePayMerchantCapability=void 0;var ApplePaySheetErrorType;exports.ApplePaySheetErrorType=ApplePaySheetErrorType;(function(ApplePaySheetErrorType){ApplePaySheetErrorType["InvalidShippingAddress"]="InvalidShippingAddress";ApplePaySheetErrorType["UnserviceableShippingAddress"]="UnserviceableShippingAddress";ApplePaySheetErrorType["InvalidCouponCode"]="InvalidCouponCode";ApplePaySheetErrorType["ExpiredCouponCode"]="ExpiredCouponCode";})(ApplePaySheetErrorType||(exports.ApplePaySheetErrorType=ApplePaySheetErrorType={}));var ContactField;exports.ContactField=ContactField;(function(ContactField){ContactField["EmailAddress"]="emailAddress";ContactField["Name"]="name";ContactField["PhoneNumber"]="phoneNumber";ContactField["PhoneticName"]="phoneticName";ContactField["PostalAddress"]="postalAddress";})(ContactField||(exports.ContactField=ContactField={}));var InvalidShippingField;exports.InvalidShippingField=InvalidShippingField;(function(InvalidShippingField){InvalidShippingField["Street"]="street";InvalidShippingField["City"]="city";InvalidShippingField["SubAdministrativeArea"]="subAdministrativeArea";InvalidShippingField["State"]="state";InvalidShippingField["PostalCode"]="postalCode";InvalidShippingField["Country"]="country";InvalidShippingField["CountryCode"]="countryCode";InvalidShippingField["SubLocality"]="subLocality";})(InvalidShippingField||(exports.InvalidShippingField=InvalidShippingField={}));var PaymentRequestType;exports.PaymentRequestType=PaymentRequestType;(function(PaymentRequestType){PaymentRequestType["Recurring"]="Recurring";PaymentRequestType["AutomaticReload"]="AutomaticReload";PaymentRequestType["MultiMerchant"]="MultiMerchant";})(PaymentRequestType||(exports.PaymentRequestType=PaymentRequestType={}));var ApplePayMerchantCapability;exports.ApplePayMerchantCapability=ApplePayMerchantCapability;(function(ApplePayMerchantCapability){ApplePayMerchantCapability["Supports3DS"]="supports3DS";ApplePayMerchantCapability["SupportsCredit"]="supportsCredit";ApplePayMerchantCapability["SupportsDebit"]="supportsDebit";})(ApplePayMerchantCapability||(exports.ApplePayMerchantCapability=ApplePayMerchantCapability={}));var ApplePayShippingType;exports.ApplePayShippingType=ApplePayShippingType;(function(ApplePayShippingType){ApplePayShippingType["Shipping"]="shipping";ApplePayShippingType["Delivery"]="delivery";ApplePayShippingType["StorePickup"]="storePickup";ApplePayShippingType["ServicePickup"]="servicePickup";})(ApplePayShippingType||(exports.ApplePayShippingType=ApplePayShippingType={}));var BillingAddressFormat;exports.BillingAddressFormat=BillingAddressFormat;(function(BillingAddressFormat){BillingAddressFormat["Full"]="FULL";BillingAddressFormat["Min"]="MIN";})(BillingAddressFormat||(exports.BillingAddressFormat=BillingAddressFormat={}));var ButtonType;exports.ButtonType=ButtonType;(function(ButtonType){ButtonType[ButtonType["Default"]=0]="Default";ButtonType[ButtonType["Buy"]=1]="Buy";ButtonType[ButtonType["Book"]=6]="Book";ButtonType[ButtonType["Checkout"]=5]="Checkout";ButtonType[ButtonType["Donate"]=4]="Donate";ButtonType[ButtonType["Order"]=11]="Order";ButtonType[ButtonType["Subscribe"]=7]="Subscribe";ButtonType[ButtonType["SetUp"]=2]="SetUp";ButtonType[ButtonType["InStore"]=3]="InStore";ButtonType[ButtonType["Reload"]=8]="Reload";ButtonType[ButtonType["AddMoney"]=9]="AddMoney";ButtonType[ButtonType["TopUp"]=10]="TopUp";ButtonType[ButtonType["Rent"]=12]="Rent";ButtonType[ButtonType["Support"]=13]="Support";ButtonType[ButtonType["Contribute"]=14]="Contribute";ButtonType[ButtonType["Tip"]=15]="Tip";ButtonType[ButtonType["Continue"]=16]="Continue";ButtonType[ButtonType["Pay"]=1000]="Pay";ButtonType[ButtonType["GooglePayMark"]=1001]="GooglePayMark";})(ButtonType||(exports.ButtonType=ButtonType={}));var ButtonStyle;exports.ButtonStyle=ButtonStyle;(function(ButtonStyle){ButtonStyle[ButtonStyle["White"]=0]="White";ButtonStyle[ButtonStyle["WhiteOutline"]=1]="WhiteOutline";ButtonStyle[ButtonStyle["Black"]=2]="Black";ButtonStyle[ButtonStyle["Automatic"]=3]="Automatic";})(ButtonStyle||(exports.ButtonStyle=ButtonStyle={}));var PaymentType;exports.PaymentType=PaymentType;(function(PaymentType){PaymentType["Deferred"]="Deferred";PaymentType["Immediate"]="Immediate";PaymentType["Recurring"]="Recurring";})(PaymentType||(exports.PaymentType=PaymentType={}));var IntervalUnit;exports.IntervalUnit=IntervalUnit;(function(IntervalUnit){IntervalUnit["Minute"]="minute";IntervalUnit["Hour"]="hour";IntervalUnit["Day"]="day";IntervalUnit["Month"]="month";IntervalUnit["Year"]="year";})(IntervalUnit||(exports.IntervalUnit=IntervalUnit={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.PaymentType=exports.PaymentRequestType=exports.InvalidShippingField=exports.IntervalUnit=exports.ContactField=exports.ButtonType=exports.ButtonStyle=exports.BillingAddressFormat=exports.ApplePayShippingType=exports.ApplePaySheetErrorType=exports.ApplePayMerchantCapability=void 0;var ApplePaySheetErrorType=exports.ApplePaySheetErrorType=function(ApplePaySheetErrorType){ApplePaySheetErrorType["InvalidShippingAddress"]="InvalidShippingAddress";ApplePaySheetErrorType["UnserviceableShippingAddress"]="UnserviceableShippingAddress";ApplePaySheetErrorType["InvalidCouponCode"]="InvalidCouponCode";ApplePaySheetErrorType["ExpiredCouponCode"]="ExpiredCouponCode";return ApplePaySheetErrorType;}({});var ContactField=exports.ContactField=function(ContactField){ContactField["EmailAddress"]="emailAddress";ContactField["Name"]="name";ContactField["PhoneNumber"]="phoneNumber";ContactField["PhoneticName"]="phoneticName";ContactField["PostalAddress"]="postalAddress";return ContactField;}({});var InvalidShippingField=exports.InvalidShippingField=function(InvalidShippingField){InvalidShippingField["Street"]="street";InvalidShippingField["City"]="city";InvalidShippingField["SubAdministrativeArea"]="subAdministrativeArea";InvalidShippingField["State"]="state";InvalidShippingField["PostalCode"]="postalCode";InvalidShippingField["Country"]="country";InvalidShippingField["CountryCode"]="countryCode";InvalidShippingField["SubLocality"]="subLocality";return InvalidShippingField;}({});var PaymentRequestType=exports.PaymentRequestType=function(PaymentRequestType){PaymentRequestType["Recurring"]="Recurring";PaymentRequestType["AutomaticReload"]="AutomaticReload";PaymentRequestType["MultiMerchant"]="MultiMerchant";return PaymentRequestType;}({});var ApplePayMerchantCapability=exports.ApplePayMerchantCapability=function(ApplePayMerchantCapability){ApplePayMerchantCapability["Supports3DS"]="supports3DS";ApplePayMerchantCapability["SupportsCredit"]="supportsCredit";ApplePayMerchantCapability["SupportsDebit"]="supportsDebit";return ApplePayMerchantCapability;}({});var ApplePayShippingType=exports.ApplePayShippingType=function(ApplePayShippingType){ApplePayShippingType["Shipping"]="shipping";ApplePayShippingType["Delivery"]="delivery";ApplePayShippingType["StorePickup"]="storePickup";ApplePayShippingType["ServicePickup"]="servicePickup";return ApplePayShippingType;}({});var BillingAddressFormat=exports.BillingAddressFormat=function(BillingAddressFormat){BillingAddressFormat["Full"]="FULL";BillingAddressFormat["Min"]="MIN";return BillingAddressFormat;}({});var ButtonType=exports.ButtonType=function(ButtonType){ButtonType[ButtonType["Default"]=0]="Default";ButtonType[ButtonType["Buy"]=1]="Buy";ButtonType[ButtonType["Book"]=6]="Book";ButtonType[ButtonType["Checkout"]=5]="Checkout";ButtonType[ButtonType["Donate"]=4]="Donate";ButtonType[ButtonType["Order"]=11]="Order";ButtonType[ButtonType["Subscribe"]=7]="Subscribe";ButtonType[ButtonType["SetUp"]=2]="SetUp";ButtonType[ButtonType["InStore"]=3]="InStore";ButtonType[ButtonType["Reload"]=8]="Reload";ButtonType[ButtonType["AddMoney"]=9]="AddMoney";ButtonType[ButtonType["TopUp"]=10]="TopUp";ButtonType[ButtonType["Rent"]=12]="Rent";ButtonType[ButtonType["Support"]=13]="Support";ButtonType[ButtonType["Contribute"]=14]="Contribute";ButtonType[ButtonType["Tip"]=15]="Tip";ButtonType[ButtonType["Continue"]=16]="Continue";ButtonType[ButtonType["Pay"]=1000]="Pay";ButtonType[ButtonType["GooglePayMark"]=1001]="GooglePayMark";return ButtonType;}({});var ButtonStyle=exports.ButtonStyle=function(ButtonStyle){ButtonStyle[ButtonStyle["White"]=0]="White";ButtonStyle[ButtonStyle["WhiteOutline"]=1]="WhiteOutline";ButtonStyle[ButtonStyle["Black"]=2]="Black";ButtonStyle[ButtonStyle["Automatic"]=3]="Automatic";return ButtonStyle;}({});var PaymentType=exports.PaymentType=function(PaymentType){PaymentType["Deferred"]="Deferred";PaymentType["Immediate"]="Immediate";PaymentType["Recurring"]="Recurring";return PaymentType;}({});var IntervalUnit=exports.IntervalUnit=function(IntervalUnit){IntervalUnit["Minute"]="minute";IntervalUnit["Hour"]="hour";IntervalUnit["Day"]="day";IntervalUnit["Month"]="month";IntervalUnit["Year"]="year";return IntervalUnit;}({});
2
2
  //# sourceMappingURL=PlatformPay.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["ApplePaySheetErrorType","ContactField","InvalidShippingField","PaymentRequestType","ApplePayMerchantCapability","ApplePayShippingType","BillingAddressFormat","ButtonType","ButtonStyle","PaymentType","IntervalUnit"],"sources":["PlatformPay.ts"],"sourcesContent":["import type { Result as Token } from './Token';\nimport type { Result as PaymentMethod } from './PaymentMethod';\nimport type { Result as PaymentIntent } from './PaymentIntent';\nimport type { Result as SetupIntent } from './SetupIntent';\nimport type { StripeError, PlatformPayError } from './Errors';\n\nexport type ApplePaySheetError =\n | {\n errorType: ApplePaySheetErrorType.InvalidShippingAddress;\n field: InvalidShippingField;\n message?: string;\n }\n | {\n errorType:\n | ApplePaySheetErrorType.UnserviceableShippingAddress\n | ApplePaySheetErrorType.InvalidCouponCode\n | ApplePaySheetErrorType.ExpiredCouponCode;\n message?: string;\n };\n\nexport enum ApplePaySheetErrorType {\n InvalidShippingAddress = 'InvalidShippingAddress',\n UnserviceableShippingAddress = 'UnserviceableShippingAddress',\n InvalidCouponCode = 'InvalidCouponCode',\n ExpiredCouponCode = 'ExpiredCouponCode',\n}\n\nexport enum ContactField {\n EmailAddress = 'emailAddress',\n Name = 'name',\n PhoneNumber = 'phoneNumber',\n PhoneticName = 'phoneticName',\n PostalAddress = 'postalAddress',\n}\n\nexport enum InvalidShippingField {\n Street = 'street',\n City = 'city',\n SubAdministrativeArea = 'subAdministrativeArea',\n State = 'state',\n PostalCode = 'postalCode',\n Country = 'country',\n CountryCode = 'countryCode',\n SubLocality = 'subLocality',\n}\n\nexport type ApplePayBaseParams = {\n /** ISO 3166-1 alpha-2 country code where the transaction is processed. */\n merchantCountryCode: string;\n /** ISO 4217 alphabetic currency code. */\n currencyCode: string;\n /** The SDK accepts Amex, Mastercard, Visa, and Discover for Apple Pay by default. Set this property to enable other card networks, for example: [\"JCB\", \"barcode\", \"chinaUnionPay\"]. A full list of possible networks can be found at https://developer.apple.com/documentation/passkit/pkpaymentnetwork. */\n additionalEnabledNetworks?: Array<string>;\n /** The list of items that describe a purchase. For example: total, tax, discount, and grand total. */\n cartItems: Array<CartSummaryItem>;\n /** The list of fields that you need for a shipping contact in order to process the transaction. If you include ContactField.PostalAddress in this array, you must implement the PlatformPayButton component's `onShippingContactSelected` callback and call `updatePlatformPaySheet` from there.*/\n requiredShippingAddressFields?: Array<ContactField>;\n /** The list of fields that you need for a billing contact in order to process the transaction. */\n requiredBillingContactFields?: Array<ContactField>;\n /** An array of shipping method objects that describe the supported shipping methods. If provided, you must implement the PlatformPayButton component's `onShippingMethodSelected` callback and call `updatePlatformPaySheet` from there. */\n shippingMethods?: Array<ShippingMethod>;\n /** Set the payment capabilities you support. If set, 3DS is required. */\n merchantCapabilities?: Array<ApplePayMerchantCapability>;\n /** An optional value that indicates how to ship purchased items. Defaults to 'Shipping'.*/\n shippingType?: ApplePayShippingType;\n /** A list of two-letter ISO 3166 country codes for limiting payment to cards from specific countries or regions. */\n supportedCountries?: Array<string>;\n};\n\nexport type ApplePayConfirmParams = {\n /** A typical request is for a one-time payment. To support different types of payment requests, include a PaymentRequestType. Only supported on iOS 16 and up. */\n request?:\n | RecurringPaymentRequest\n | AutomaticReloadPaymentRequest\n | MultiMerchantRequest;\n};\n\nexport enum PaymentRequestType {\n Recurring = 'Recurring',\n AutomaticReload = 'AutomaticReload',\n MultiMerchant = 'MultiMerchant',\n}\n\n/** Use this for a recurring payment, typically a subscription. */\nexport type RecurringPaymentRequest = {\n type: PaymentRequestType.Recurring;\n /** A description that you provide of the recurring payment and that Apple Pay displays to the user in the sheet. */\n description: string;\n /** A URL to a web page where the user can update or delete the payment method for the recurring payment. */\n managementUrl: string;\n /** The regular billing cycle for the payment, including start and end dates, an interval, and an interval count. */\n billing: RecurringCartSummaryItem;\n /** Same as the billing property, but use this if the purchase has a trial period. */\n trialBilling?: RecurringCartSummaryItem;\n /** A localized billing agreement that the sheet displays to the user before the user authorizes the payment. */\n billingAgreement?: string;\n /** A URL you provide to receive life-cycle notifications from the Apple Pay servers about the Apple Pay merchant token for the recurring payment.\n * For more information about handling merchant token life-cycle notifications, see Receiving and handling merchant token notifications.\n */\n tokenNotificationURL?: string;\n};\n\n/** Use this for an automatic reload or refill payment, such as a store card top-up. */\nexport type AutomaticReloadPaymentRequest = {\n type: PaymentRequestType.AutomaticReload;\n /** A description that you provide of the recurring payment and that Apple Pay displays to the user in the sheet. */\n description: string;\n /** A URL to a web page where the user can update or delete the payment method for the recurring payment. */\n managementUrl: string;\n /** A short, localized description of the item. */\n label: string;\n /** This is the amount that is automatically applied to the account when the account balance drops below the threshold amount. */\n reloadAmount: string;\n /** The balance an account reaches before you apply the automatic reload amount. */\n thresholdAmount: string;\n /** A localized billing agreement that the sheet displays to the user before the user authorizes the payment. */\n billingAgreement?: string;\n /** A URL you provide to receive life-cycle notifications from the Apple Pay servers about the Apple Pay merchant token for the recurring payment.\n * For more information about handling merchant token life-cycle notifications, see Receiving and handling merchant token notifications.\n */\n tokenNotificationURL?: string;\n};\n\n/** Use this to indicate payments for multiple merchants. */\nexport type MultiMerchantRequest = {\n type: PaymentRequestType.MultiMerchant;\n merchants: Array<{\n /** The Apple Pay merchant identifier. */\n merchantIdentifier: string;\n /** An external identifier for the merchant. */\n externalIdentifier: string;\n /** The merchant’s display name that the Apple Pay server associates with the payment token. */\n merchantName: string;\n /** The merchant’s top-level domain that the Apple Pay server associates with the payment token. */\n merchantDomain?: string;\n /** The amount to authorize for the payment token. */\n amount: string;\n }>;\n};\n\nexport type ApplePayPaymentMethodParams = {\n /** Set this value to true to display the coupon code field, or pass the 'couponCode' field to autofill with a coupon code. Defaults to false. If true, you must implement the PlatformPayButton component's `onCouponCodeEntered` callback and call `updatePlatformPaySheet` from there. */\n supportsCouponCode?: boolean;\n /** Set this value to autofill with a coupon code. If provided, you must implement the PlatformPayButton component's `onCouponCodeEntered` callback and call `updatePlatformPaySheet` from there. */\n couponCode?: string;\n};\n\nexport enum ApplePayMerchantCapability {\n /** Required. This value must be supplied. */\n Supports3DS = 'supports3DS',\n /** Optional. If present, only transactions that are categorized as credit cards are allowed. */\n SupportsCredit = 'supportsCredit',\n /** Optional. If present, only transactions that are categorized as debit cards are allowed. */\n SupportsDebit = 'supportsDebit',\n}\n\n/** A type that indicates how to ship purchased items. */\nexport enum ApplePayShippingType {\n /** Default. */\n Shipping = 'shipping',\n Delivery = 'delivery',\n StorePickup = 'storePickup',\n ServicePickup = 'servicePickup',\n}\n\nexport type GooglePayBaseParams = {\n /**\n * Set to true to run in a test environment with relaxed application / merchant requirements. This environment is suggested for early development and for easily testing SDK.\n - Does not require the application to be uploaded to the Google Play Store.\n - Does not require a Google Pay Developer Profile.\n - It uses production data, but at the end of the transaction you will receive a fake and non chargeable payment credential.\n - The user will see a warning message that the app is not recognized/verified.\n */\n testEnv: boolean;\n /** ISO 3166-1 alpha-2 country code where the transaction is processed. */\n merchantCountryCode: string;\n /** ISO 4217 alphabetic currency code. */\n currencyCode: string;\n /** Your merchant name, displayed in the Google Pay sheet. */\n merchantName?: string;\n /** Set to true to request an email address. Defaults to false. */\n isEmailRequired?: boolean;\n /** Set to false if you don't support credit cards. Defaults to true. */\n allowCreditCards?: boolean;\n /** If true, Google Pay is considered \"available\" if the customer's Google Pay wallet has an existing payment method. Defaults to false. */\n existingPaymentMethodRequired?: boolean;\n /** Describes the configuration for billing address collection in the Google Pay sheet. */\n billingAddressConfig?: {\n /** Set to true if billing address is required for payment. Defaults to false. */\n isRequired?: boolean;\n /** Set to true if phone number is required for payment. Defaults to false. */\n isPhoneNumberRequired?: boolean;\n /** Defines what address fields to collect. Defaults to BillingAddressFormat.Min */\n format?: BillingAddressFormat;\n };\n /** An optional label to display with the amount. Google Pay may or may not display this label depending on its own internal logic. Defaults to a generic label if none is provided. */\n label?: string;\n /** An optional amount to display for setup intents. Google Pay may or may not display this amount depending on its own internal logic. Defaults to 0 if none is provided. Provide this value in the currency’s smallest unit. */\n amount?: number;\n};\n\nexport type GooglePayPaymentMethodParams = {\n /** Describes the configuration for shipping address collection in the Google Pay sheet. */\n shippingAddressConfig?: {\n /** Set to true if shipping address is required for payment. Defaults to false. */\n isRequired?: boolean;\n /** Set to true if phone number is required for payment. Defaults to false. */\n isPhoneNumberRequired?: boolean;\n /** Set of ISO 3166-1 alpha-2 country code values of the countries where shipping is allowed. Defaults to all shipping address countries. */\n allowedCountryCodes?: Array<string>;\n };\n};\n\nexport enum BillingAddressFormat {\n /** Collect name, street address, locality, region, country code, and postal code. */\n Full = 'FULL',\n /** Collect name, country code, and postal code (default). */\n Min = 'MIN',\n}\n\nexport type PaymentMethodParams = {\n /** Defines Google Pay behavior. Android only. */\n googlePay?: GooglePayBaseParams & GooglePayPaymentMethodParams;\n /** Defines Apple Pay behavior. iOS only. */\n applePay?: ApplePayBaseParams & ApplePayPaymentMethodParams;\n};\n\nexport type ConfirmParams = {\n /** Defines Google Pay behavior. Android only. */\n googlePay?: GooglePayBaseParams;\n /** Defines Apple Pay behavior. iOS only. */\n applePay?: ApplePayBaseParams & ApplePayConfirmParams;\n};\n\nexport enum ButtonType {\n /** A button with the Apple Pay or Google Pay logo only, useful when an additional call to action isn't needed. */\n Default = 0,\n /** A button useful for product purchases. */\n Buy = 1,\n /** A button useful for booking trips, flights, or other experiences. */\n Book = 6,\n /** A button useful for purchase experiences that include other payment buttons that start with “Check out”. */\n Checkout = 5,\n /** A button used by approved nonprofit organization that lets people make donations. */\n Donate = 4,\n /** A button useful for placing orders for such as like meals or flowers. */\n Order = 11,\n /** A button useful for purchasing a subscription such as a gym membership or meal-kit delivery service. */\n Subscribe = 7,\n /** iOS only. A button useful for prompting the user to set up a card. */\n SetUp = 2,\n /** iOS only. A button useful for paying bills or invoices. */\n InStore = 3,\n /** iOS only. A button useful for adding money to a card, account, or payment system.*/\n Reload = 8,\n /** iOS only. A button useful for adding money to a card, account, or payment system. */\n AddMoney = 9,\n /** iOS only. A button useful for adding money to a card, account, or payment system. */\n TopUp = 10,\n /** iOS only. A button useful for renting items such as cars or scooters. */\n Rent = 12,\n /** iOS only. A button useful supporting people give money to projects, causes, organizations, and other entities.*/\n Support = 13,\n /** iOS only. A button useful to help people contribute money to projects, causes, organizations, and other entities. */\n Contribute = 14,\n /** iOS only. A button useful useful for letting people tip for goods or services. */\n Tip = 15,\n /** iOS only. A button useful for general purchases. */\n Continue = 16,\n /** Android only. A button useful for general payments. */\n Pay = 1000,\n /** Android only. The Google Pay payment button without the additional text. */\n GooglePayMark = 1001,\n}\n\n/** iOS only. */\nexport enum ButtonStyle {\n /** A white button with black lettering. */\n White = 0,\n /** A white button with black lettering and a black outline. */\n WhiteOutline = 1,\n /** A black button with white lettering. */\n Black = 2,\n /** Default. A button that automatically changes its appearance when the user switches between Light Mode and Dark Mode. */\n Automatic = 3,\n}\n\n/** iOS only. */\nexport type CartSummaryItem =\n | DeferredCartSummaryItem\n | ImmediateCartSummaryItem\n | RecurringCartSummaryItem;\n\n/** iOS only. */\nexport enum PaymentType {\n Deferred = 'Deferred',\n Immediate = 'Immediate',\n Recurring = 'Recurring',\n}\n\n/** iOS only. Use this type for a payment that occurs in the future, such as a pre-order. Only available on iOS 15 and up, otherwise falls back to ImmediateCartSummaryItem. */\nexport type DeferredCartSummaryItem = {\n paymentType: PaymentType.Deferred;\n /** The unix timestamp of the date, in the future, of the payment. Measured in seconds. */\n deferredDate: number;\n label: string;\n amount: string;\n};\n\n/** iOS only. Use this type for payments that will occur immediately. */\nexport type ImmediateCartSummaryItem = {\n paymentType: PaymentType.Immediate;\n /** When creating items for estimates or charges whose final value is not yet known, set this to true. */\n isPending?: boolean;\n label: string;\n amount: string;\n};\n\n/** iOS only. Use this type for payments that occur more than once, such as a subscription. Only available on iOS 15 and up, otherwise falls back to ImmediateCartSummaryItem.*/\nexport type RecurringCartSummaryItem = {\n paymentType: PaymentType.Recurring;\n /** The amount of time – in calendar units such as Day, Month, or Year – that represents a fraction of the total payment interval. For example, if you set the intervalUnit to 'Month' and intervalCount to 3, then the payment interval is three months.*/\n intervalUnit: IntervalUnit;\n /** The number of interval units that make up the total payment interval. For example, if you set the intervalUnit to 'Month' and intervalCount to 3, then the payment interval is three months.*/\n intervalCount: number;\n /** The unix timestamp of the start date. Measured in seconds. */\n startDate?: number;\n /** The unix timestamp of the end date. Measured in seconds. */\n endDate?: number;\n label: string;\n amount: string;\n};\n\n/** iOS only. */\nexport enum IntervalUnit {\n Minute = 'minute',\n Hour = 'hour',\n Day = 'day',\n Month = 'month',\n Year = 'year',\n}\n\n/** iOS only. */\nexport type ShippingMethod = {\n /** A short, localized description. */\n label: string;\n /** The cost associated with this shipping option. */\n amount: string;\n /** When creating items for estimates or charges whose final value is not yet known, set this to true. */\n isPending?: boolean;\n /** A unique identifier for the shipping method. */\n identifier: string;\n /** A user-readable description of the shipping method. For example “Ships in 24 hours.” Don't repeat the content of the 'label' property. */\n detail?: string;\n /** The unix timestamp of the start date of the expected range of delivery or shipping dates for a package, or the time range when an item is available for pickup. Measured in seconds. */\n startDate?: number;\n /** The unix timestamp of the end date of the expected range of delivery or shipping dates for a package, or the time range when an item is available for pickup. Measured in seconds. */\n endDate?: number;\n};\n\ninterface PostalAddress {\n city?: string;\n country?: string;\n postalCode?: string;\n state?: string;\n street?: string;\n isoCountryCode?: string;\n subAdministrativeArea?: string;\n subLocality?: string;\n}\n\ninterface ContactName {\n familyName?: string;\n namePrefix?: string;\n nameSuffix?: string;\n givenName?: string;\n middleName?: string;\n nickname?: string;\n}\n\nexport interface ShippingContact {\n emailAddress?: string;\n name: ContactName;\n phoneNumber?: string;\n postalAddress: PostalAddress;\n}\n\n/** Android only. */\nexport type IsGooglePaySupportedParams = {\n /** Set to true to run in a test environment with relaxed application / merchant requirements. This environment is suggested for early development and for easily testing SDK. Defaults to false. */\n testEnv?: boolean;\n /**\n * If `true`, Google Pay is considered ready if the customer's Google Pay wallet\n * has an existing payment method. Defaults to false.\n */\n existingPaymentMethodRequired?: boolean;\n};\n\nexport type PaymentMethodResult =\n | {\n paymentMethod: PaymentMethod;\n shippingContact?: ShippingContact;\n error?: undefined;\n }\n | {\n paymentMethod?: undefined;\n shippingContact?: undefined;\n error: StripeError<PlatformPayError>;\n };\n\nexport type TokenResult =\n | {\n token: Token;\n shippingContact?: ShippingContact;\n error?: undefined;\n }\n | {\n token?: undefined;\n shippingContact?: undefined;\n error: StripeError<PlatformPayError>;\n };\n\nexport type ConfirmPaymentResult =\n | {\n paymentIntent: PaymentIntent;\n error?: StripeError<PlatformPayError>;\n }\n | {\n paymentIntent?: undefined;\n error: StripeError<PlatformPayError>;\n };\n\nexport type ConfirmSetupIntentResult =\n | {\n setupIntent: SetupIntent;\n error?: StripeError<PlatformPayError>;\n }\n | {\n setupIntent?: undefined;\n error: StripeError<PlatformPayError>;\n };\n"],"mappings":"4VAoBYA,uBAAsB,iEAAtBA,sBAAsB,EAAtBA,sBAAsB,oDAAtBA,sBAAsB,gEAAtBA,sBAAsB,0CAAtBA,sBAAsB,6CAAtBA,sBAAsB,kCAAtBA,sBAAsB,SAOtBC,aAAY,6CAAZA,YAAY,EAAZA,YAAY,gCAAZA,YAAY,gBAAZA,YAAY,8BAAZA,YAAY,gCAAZA,YAAY,qCAAZA,YAAY,wBAAZA,YAAY,SAQZC,qBAAoB,6DAApBA,oBAAoB,EAApBA,oBAAoB,oBAApBA,oBAAoB,gBAApBA,oBAAoB,kDAApBA,oBAAoB,kBAApBA,oBAAoB,4BAApBA,oBAAoB,sBAApBA,oBAAoB,8BAApBA,oBAAoB,iCAApBA,oBAAoB,gCAApBA,oBAAoB,SA0CpBC,mBAAkB,yDAAlBA,kBAAkB,EAAlBA,kBAAkB,0BAAlBA,kBAAkB,sCAAlBA,kBAAkB,qCAAlBA,kBAAkB,8BAAlBA,kBAAkB,SAsElBC,2BAA0B,yEAA1BA,0BAA0B,EAA1BA,0BAA0B,8BAA1BA,0BAA0B,oCAA1BA,0BAA0B,qCAA1BA,0BAA0B,sCAA1BA,0BAA0B,SAU1BC,qBAAoB,6DAApBA,oBAAoB,EAApBA,oBAAoB,wBAApBA,oBAAoB,wBAApBA,oBAAoB,8BAApBA,oBAAoB,qCAApBA,oBAAoB,gCAApBA,oBAAoB,SAwDpBC,qBAAoB,6DAApBA,oBAAoB,EAApBA,oBAAoB,gBAApBA,oBAAoB,iBAApBA,oBAAoB,gCAApBA,oBAAoB,SAqBpBC,WAAU,yCAAVA,UAAU,EAAVA,UAAU,CAAVA,UAAU,yBAAVA,UAAU,CAAVA,UAAU,iBAAVA,UAAU,CAAVA,UAAU,mBAAVA,UAAU,CAAVA,UAAU,2BAAVA,UAAU,CAAVA,UAAU,uBAAVA,UAAU,CAAVA,UAAU,sBAAVA,UAAU,CAAVA,UAAU,6BAAVA,UAAU,CAAVA,UAAU,qBAAVA,UAAU,CAAVA,UAAU,yBAAVA,UAAU,CAAVA,UAAU,uBAAVA,UAAU,CAAVA,UAAU,2BAAVA,UAAU,CAAVA,UAAU,sBAAVA,UAAU,CAAVA,UAAU,oBAAVA,UAAU,CAAVA,UAAU,0BAAVA,UAAU,CAAVA,UAAU,gCAAVA,UAAU,CAAVA,UAAU,kBAAVA,UAAU,CAAVA,UAAU,4BAAVA,UAAU,CAAVA,UAAU,oBAAVA,UAAU,CAAVA,UAAU,2CAAVA,UAAU,sBAAVA,UAAU,SA0CVC,YAAW,2CAAXA,WAAW,EAAXA,WAAW,CAAXA,WAAW,qBAAXA,WAAW,CAAXA,WAAW,mCAAXA,WAAW,CAAXA,WAAW,qBAAXA,WAAW,CAAXA,WAAW,gCAAXA,WAAW,uBAAXA,WAAW,SAkBXC,YAAW,2CAAXA,WAAW,EAAXA,WAAW,wBAAXA,WAAW,0BAAXA,WAAW,6BAAXA,WAAW,uBAAXA,WAAW,SAwCXC,aAAY,6CAAZA,YAAY,EAAZA,YAAY,oBAAZA,YAAY,gBAAZA,YAAY,cAAZA,YAAY,kBAAZA,YAAY,mBAAZA,YAAY,wBAAZA,YAAY"}
1
+ {"version":3,"names":["ApplePaySheetErrorType","exports","ContactField","InvalidShippingField","PaymentRequestType","ApplePayMerchantCapability","ApplePayShippingType","BillingAddressFormat","ButtonType","ButtonStyle","PaymentType","IntervalUnit"],"sourceRoot":"../../../src","sources":["types/PlatformPay.ts"],"mappings":"4VAoBY,CAAAA,sBAAsB,CAAAC,OAAA,CAAAD,sBAAA,UAAtBA,sBAAsB,EAAtBA,sBAAsB,oDAAtBA,sBAAsB,gEAAtBA,sBAAsB,0CAAtBA,sBAAsB,gDAAtB,CAAAA,sBAAsB,UAOtB,CAAAE,YAAY,CAAAD,OAAA,CAAAC,YAAA,UAAZA,YAAY,EAAZA,YAAY,gCAAZA,YAAY,gBAAZA,YAAY,8BAAZA,YAAY,gCAAZA,YAAY,wCAAZ,CAAAA,YAAY,UAQZ,CAAAC,oBAAoB,CAAAF,OAAA,CAAAE,oBAAA,UAApBA,oBAAoB,EAApBA,oBAAoB,oBAApBA,oBAAoB,gBAApBA,oBAAoB,kDAApBA,oBAAoB,kBAApBA,oBAAoB,4BAApBA,oBAAoB,sBAApBA,oBAAoB,8BAApBA,oBAAoB,oCAApB,CAAAA,oBAAoB,UA0CpB,CAAAC,kBAAkB,CAAAH,OAAA,CAAAG,kBAAA,UAAlBA,kBAAkB,EAAlBA,kBAAkB,0BAAlBA,kBAAkB,sCAAlBA,kBAAkB,wCAAlB,CAAAA,kBAAkB,UAsElB,CAAAC,0BAA0B,CAAAJ,OAAA,CAAAI,0BAAA,UAA1BA,0BAA0B,EAA1BA,0BAA0B,8BAA1BA,0BAA0B,oCAA1BA,0BAA0B,wCAA1B,CAAAA,0BAA0B,UAU1B,CAAAC,oBAAoB,CAAAL,OAAA,CAAAK,oBAAA,UAApBA,oBAAoB,EAApBA,oBAAoB,wBAApBA,oBAAoB,wBAApBA,oBAAoB,8BAApBA,oBAAoB,wCAApB,CAAAA,oBAAoB,UAwDpB,CAAAC,oBAAoB,CAAAN,OAAA,CAAAM,oBAAA,UAApBA,oBAAoB,EAApBA,oBAAoB,gBAApBA,oBAAoB,oBAApB,CAAAA,oBAAoB,UAqBpB,CAAAC,UAAU,CAAAP,OAAA,CAAAO,UAAA,UAAVA,UAAU,EAAVA,UAAU,CAAVA,UAAU,yBAAVA,UAAU,CAAVA,UAAU,iBAAVA,UAAU,CAAVA,UAAU,mBAAVA,UAAU,CAAVA,UAAU,2BAAVA,UAAU,CAAVA,UAAU,uBAAVA,UAAU,CAAVA,UAAU,sBAAVA,UAAU,CAAVA,UAAU,6BAAVA,UAAU,CAAVA,UAAU,qBAAVA,UAAU,CAAVA,UAAU,yBAAVA,UAAU,CAAVA,UAAU,uBAAVA,UAAU,CAAVA,UAAU,2BAAVA,UAAU,CAAVA,UAAU,sBAAVA,UAAU,CAAVA,UAAU,oBAAVA,UAAU,CAAVA,UAAU,0BAAVA,UAAU,CAAVA,UAAU,gCAAVA,UAAU,CAAVA,UAAU,kBAAVA,UAAU,CAAVA,UAAU,4BAAVA,UAAU,CAAVA,UAAU,oBAAVA,UAAU,CAAVA,UAAU,8CAAV,CAAAA,UAAU,UA0CV,CAAAC,WAAW,CAAAR,OAAA,CAAAQ,WAAA,UAAXA,WAAW,EAAXA,WAAW,CAAXA,WAAW,qBAAXA,WAAW,CAAXA,WAAW,mCAAXA,WAAW,CAAXA,WAAW,qBAAXA,WAAW,CAAXA,WAAW,mCAAX,CAAAA,WAAW,UAkBX,CAAAC,WAAW,CAAAT,OAAA,CAAAS,WAAA,UAAXA,WAAW,EAAXA,WAAW,wBAAXA,WAAW,0BAAXA,WAAW,gCAAX,CAAAA,WAAW,UAwCX,CAAAC,YAAY,CAAAV,OAAA,CAAAU,YAAA,UAAZA,YAAY,EAAZA,YAAY,oBAAZA,YAAY,gBAAZA,YAAY,cAAZA,YAAY,kBAAZA,YAAY,sBAAZ,CAAAA,YAAY","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.GooglePayCardTokenStatus=exports.CanAddCardToWalletStatus=void 0;var GooglePayCardTokenStatus;exports.GooglePayCardTokenStatus=GooglePayCardTokenStatus;(function(GooglePayCardTokenStatus){GooglePayCardTokenStatus["TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION"]="TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION";GooglePayCardTokenStatus["TOKEN_STATE_PENDING"]="TOKEN_STATE_PENDING";GooglePayCardTokenStatus["TOKEN_STATE_SUSPENDED"]="TOKEN_STATE_SUSPENDED";GooglePayCardTokenStatus["TOKEN_STATE_ACTIVE"]="TOKEN_STATE_ACTIVE";GooglePayCardTokenStatus["TOKEN_STATE_FELICA_PENDING_PROVISIONING"]="TOKEN_STATE_FELICA_PENDING_PROVISIONING";GooglePayCardTokenStatus["TOKEN_STATE_UNTOKENIZED"]="TOKEN_STATE_UNTOKENIZED";})(GooglePayCardTokenStatus||(exports.GooglePayCardTokenStatus=GooglePayCardTokenStatus={}));var CanAddCardToWalletStatus;exports.CanAddCardToWalletStatus=CanAddCardToWalletStatus;(function(CanAddCardToWalletStatus){CanAddCardToWalletStatus["MISSING_CONFIGURATION"]="MISSING_CONFIGURATION";CanAddCardToWalletStatus["UNSUPPORTED_DEVICE"]="UNSUPPORTED_DEVICE";CanAddCardToWalletStatus["CARD_ALREADY_EXISTS"]="CARD_ALREADY_EXISTS";CanAddCardToWalletStatus["CARD_EXISTS_ON_CURRENT_DEVICE"]="CARD_EXISTS_ON_CURRENT_DEVICE";CanAddCardToWalletStatus["CARD_EXISTS_ON_PAIRED_DEVICE"]="CARD_EXISTS_ON_PAIRED_DEVICE";})(CanAddCardToWalletStatus||(exports.CanAddCardToWalletStatus=CanAddCardToWalletStatus={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.GooglePayCardTokenStatus=exports.CanAddCardToWalletStatus=void 0;var GooglePayCardTokenStatus=exports.GooglePayCardTokenStatus=function(GooglePayCardTokenStatus){GooglePayCardTokenStatus["TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION"]="TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION";GooglePayCardTokenStatus["TOKEN_STATE_PENDING"]="TOKEN_STATE_PENDING";GooglePayCardTokenStatus["TOKEN_STATE_SUSPENDED"]="TOKEN_STATE_SUSPENDED";GooglePayCardTokenStatus["TOKEN_STATE_ACTIVE"]="TOKEN_STATE_ACTIVE";GooglePayCardTokenStatus["TOKEN_STATE_FELICA_PENDING_PROVISIONING"]="TOKEN_STATE_FELICA_PENDING_PROVISIONING";GooglePayCardTokenStatus["TOKEN_STATE_UNTOKENIZED"]="TOKEN_STATE_UNTOKENIZED";return GooglePayCardTokenStatus;}({});var CanAddCardToWalletStatus=exports.CanAddCardToWalletStatus=function(CanAddCardToWalletStatus){CanAddCardToWalletStatus["MISSING_CONFIGURATION"]="MISSING_CONFIGURATION";CanAddCardToWalletStatus["UNSUPPORTED_DEVICE"]="UNSUPPORTED_DEVICE";CanAddCardToWalletStatus["CARD_ALREADY_EXISTS"]="CARD_ALREADY_EXISTS";CanAddCardToWalletStatus["CARD_EXISTS_ON_CURRENT_DEVICE"]="CARD_EXISTS_ON_CURRENT_DEVICE";CanAddCardToWalletStatus["CARD_EXISTS_ON_PAIRED_DEVICE"]="CARD_EXISTS_ON_PAIRED_DEVICE";return CanAddCardToWalletStatus;}({});
2
2
  //# sourceMappingURL=PushProvisioning.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["GooglePayCardTokenStatus","CanAddCardToWalletStatus"],"sources":["PushProvisioning.ts"],"sourcesContent":["import type { StripeError, GooglePayError } from './Errors';\n\nexport type GooglePayCardToken = {\n /** The token reference ID. */\n id: string;\n /** Last four digits of the FPAN */\n fpanLastFour: string;\n /** Last four digits of the DPAN */\n dpanLastFour: string;\n network: number;\n serviceProvider: number;\n /** The name of the issuer. */\n issuer: string;\n /** The GooglePayCardTokenStatus. */\n status: GooglePayCardTokenStatus;\n /** Deprecated. Use fpanLastFour or dpanLastFour. */\n cardLastFour: string;\n};\n\nexport enum GooglePayCardTokenStatus {\n /** */\n TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION = 'TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION',\n /** */\n TOKEN_STATE_PENDING = 'TOKEN_STATE_PENDING',\n /** */\n TOKEN_STATE_SUSPENDED = 'TOKEN_STATE_SUSPENDED',\n /** */\n TOKEN_STATE_ACTIVE = 'TOKEN_STATE_ACTIVE',\n /** */\n TOKEN_STATE_FELICA_PENDING_PROVISIONING = 'TOKEN_STATE_FELICA_PENDING_PROVISIONING',\n /** */\n TOKEN_STATE_UNTOKENIZED = 'TOKEN_STATE_UNTOKENIZED',\n}\n\nexport type IsCardInWalletResult =\n | {\n isInWallet: boolean;\n token?: GooglePayCardToken;\n error?: undefined;\n }\n | {\n isInWallet?: undefined;\n token?: undefined;\n error: StripeError<GooglePayError>;\n };\n\nexport type CanAddCardToWalletParams = {\n /** The `primary_account_identifier` value from the issued card. Can be an empty string. */\n primaryAccountIdentifier: string | null;\n /** Last 4 digits of the card number. Required for Android. */\n cardLastFour: string;\n /** iOS only. Set this to `true` until shipping through TestFlight || App Store. If false, you must be using live cards, and have the proper iOS entitlement set up. See https://stripe.com/docs/issuing/cards/digital-wallets?platform=react-native#requesting-access-for-ios */\n testEnv?: boolean;\n /** iOS only. Set this to `true` if: your user has an Apple Watch device currently paired, and you want to check that device for the presence of the specified card. */\n hasPairedAppleWatch?: boolean;\n /** Android only, defaults to `true`. Set this to `false` if you'd like to allow users without NFC-enabled devices to add cards to the wallet. NFC is required for paying in stores. */\n supportsTapToPay?: boolean;\n};\n\nexport type CanAddCardToWalletResult =\n | {\n canAddCard: boolean;\n details?: {\n token?: GooglePayCardToken;\n status?: CanAddCardToWalletStatus;\n };\n error?: undefined;\n }\n | {\n canAddCard?: undefined;\n details?: undefined;\n error: StripeError<GooglePayError>;\n };\n\nexport enum CanAddCardToWalletStatus {\n /** You are missing configuration required for Push Provisioning. Make sure you've completed all steps at https://stripe.com/docs/issuing/cards/digital-wallets?platform=react-native. */\n MISSING_CONFIGURATION = 'MISSING_CONFIGURATION',\n /** This device doesn't support adding a card to the native wallet. */\n UNSUPPORTED_DEVICE = 'UNSUPPORTED_DEVICE',\n /** This card already exists on this device and any paired devices. */\n CARD_ALREADY_EXISTS = 'CARD_ALREADY_EXISTS',\n /** This card already exists on this device, but not on the paired device. */\n CARD_EXISTS_ON_CURRENT_DEVICE = 'CARD_EXISTS_ON_CURRENT_DEVICE',\n /** This card already exists on the paired device, but not on this device. */\n CARD_EXISTS_ON_PAIRED_DEVICE = 'CARD_EXISTS_ON_PAIRED_DEVICE',\n}\n"],"mappings":"qIAmBYA,yBAAwB,qEAAxBA,wBAAwB,EAAxBA,wBAAwB,sFAAxBA,wBAAwB,8CAAxBA,wBAAwB,kDAAxBA,wBAAwB,4CAAxBA,wBAAwB,sFAAxBA,wBAAwB,yDAAxBA,wBAAwB,oCAAxBA,wBAAwB,SAuDxBC,yBAAwB,qEAAxBA,wBAAwB,EAAxBA,wBAAwB,kDAAxBA,wBAAwB,4CAAxBA,wBAAwB,8CAAxBA,wBAAwB,kEAAxBA,wBAAwB,mEAAxBA,wBAAwB,oCAAxBA,wBAAwB"}
1
+ {"version":3,"names":["GooglePayCardTokenStatus","exports","CanAddCardToWalletStatus"],"sourceRoot":"../../../src","sources":["types/PushProvisioning.ts"],"mappings":"qIAmBY,CAAAA,wBAAwB,CAAAC,OAAA,CAAAD,wBAAA,UAAxBA,wBAAwB,EAAxBA,wBAAwB,sFAAxBA,wBAAwB,8CAAxBA,wBAAwB,kDAAxBA,wBAAwB,4CAAxBA,wBAAwB,sFAAxBA,wBAAwB,4DAAxB,CAAAA,wBAAwB,UAuDxB,CAAAE,wBAAwB,CAAAD,OAAA,CAAAC,wBAAA,UAAxBA,wBAAwB,EAAxBA,wBAAwB,kDAAxBA,wBAAwB,4CAAxBA,wBAAwB,8CAAxBA,wBAAwB,kEAAxBA,wBAAwB,sEAAxB,CAAAA,wBAAwB","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.Status=void 0;var Status;exports.Status=Status;(function(Status){Status["Succeeded"]="Succeeded";Status["RequiresPaymentMethod"]="RequiresPaymentMethod";Status["RequiresConfirmation"]="RequiresConfirmation";Status["Canceled"]="Canceled";Status["Processing"]="Processing";Status["RequiresAction"]="RequiresAction";Status["Unknown"]="Unknown";})(Status||(exports.Status=Status={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.Status=void 0;var Status=exports.Status=function(Status){Status["Succeeded"]="Succeeded";Status["RequiresPaymentMethod"]="RequiresPaymentMethod";Status["RequiresConfirmation"]="RequiresConfirmation";Status["Canceled"]="Canceled";Status["Processing"]="Processing";Status["RequiresAction"]="RequiresAction";Status["Unknown"]="Unknown";return Status;}({});
2
2
  //# sourceMappingURL=SetupIntent.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["Status"],"sources":["SetupIntent.ts"],"sourcesContent":["import type { Type } from './PaymentMethod';\nimport type {\n LastPaymentError,\n ConfirmParams as PaymentIntentConfirmParams,\n ConfirmOptions as PaymentIntentConfirmOptions,\n} from './PaymentIntent';\nimport type { NextAction } from './NextAction';\nimport type * as PaymentMethod from './PaymentMethod';\nexport interface Result {\n id: string;\n clientSecret: string;\n lastSetupError: LastPaymentError | null;\n /** The UNIX timestamp (in milliseconds) of the date this Setup Intent was created. */\n created: string | null;\n livemode: boolean;\n /** @deprecated Use paymentMethod.id instead. */\n paymentMethodId: string | null;\n paymentMethod: PaymentMethod.Result | null;\n status: Status;\n paymentMethodTypes: Type[];\n usage: FutureUsage;\n description: string | null;\n nextAction: NextAction | null;\n}\n\nexport type ConfirmParams = PaymentIntentConfirmParams;\n\nexport type ConfirmOptions = PaymentIntentConfirmOptions;\n\nexport type FutureUsage =\n | 'Unknown'\n | 'None'\n | 'OnSession'\n | 'OffSession'\n | 'OneTime';\n\nexport enum Status {\n Succeeded = 'Succeeded',\n RequiresPaymentMethod = 'RequiresPaymentMethod',\n RequiresConfirmation = 'RequiresConfirmation',\n Canceled = 'Canceled',\n Processing = 'Processing',\n RequiresAction = 'RequiresAction',\n Unknown = 'Unknown',\n}\n"],"mappings":"kFAoCYA,OAAM,iCAANA,MAAM,EAANA,MAAM,0BAANA,MAAM,kDAANA,MAAM,gDAANA,MAAM,wBAANA,MAAM,4BAANA,MAAM,oCAANA,MAAM,yBAANA,MAAM,kBAANA,MAAM"}
1
+ {"version":3,"names":["Status","exports"],"sourceRoot":"../../../src","sources":["types/SetupIntent.ts"],"mappings":"kFAoCY,CAAAA,MAAM,CAAAC,OAAA,CAAAD,MAAA,UAANA,MAAM,EAANA,MAAM,0BAANA,MAAM,kDAANA,MAAM,gDAANA,MAAM,wBAANA,MAAM,4BAANA,MAAM,oCAANA,MAAM,4BAAN,CAAAA,MAAM","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.NavigationBarStyle=void 0;var NavigationBarStyle;exports.NavigationBarStyle=NavigationBarStyle;(function(NavigationBarStyle){NavigationBarStyle[NavigationBarStyle["default"]=0]="default";NavigationBarStyle[NavigationBarStyle["black"]=1]="black";NavigationBarStyle[NavigationBarStyle["blackTranslucent"]=2]="blackTranslucent";})(NavigationBarStyle||(exports.NavigationBarStyle=NavigationBarStyle={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.NavigationBarStyle=void 0;var NavigationBarStyle=exports.NavigationBarStyle=function(NavigationBarStyle){NavigationBarStyle[NavigationBarStyle["default"]=0]="default";NavigationBarStyle[NavigationBarStyle["black"]=1]="black";NavigationBarStyle[NavigationBarStyle["blackTranslucent"]=2]="blackTranslucent";return NavigationBarStyle;}({});
2
2
  //# sourceMappingURL=ThreeDSecure.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["NavigationBarStyle"],"sources":["ThreeDSecure.ts"],"sourcesContent":["export interface ConfigurationParams extends Props {\n timeout?: number;\n label?: LabelProps;\n navigationBar?: NavigationBarProps;\n textField?: TextFieldProps;\n submitButton?: ButtonProps;\n cancelButton?: ButtonProps;\n continueButton?: ButtonProps;\n nextButton?: ButtonProps;\n resendButton?: ButtonProps;\n}\n\nexport interface Props extends IOSProps, AndroidProps {}\n\nexport enum NavigationBarStyle {\n default = 0,\n black = 1,\n blackTranslucent = 2,\n}\n\nexport interface IOSProps {\n backgroundColor?: string;\n footer?: FooterProps;\n}\nexport interface IOSNavigationBarProps {\n barStyle?: NavigationBarStyle;\n translucent?: boolean;\n barTintColor?: string;\n}\n\nexport interface AndroidProps {\n accentColor?: string;\n}\nexport interface AndroidNavigationBarProps {\n statusBarColor?: string;\n backgroundColor?: string;\n}\n\nexport interface NavigationBarProps\n extends IOSNavigationBarProps,\n AndroidNavigationBarProps {\n headerText?: string;\n buttonText?: string;\n textColor?: string;\n textFontSize?: number;\n}\n\nexport interface FooterProps {\n backgroundColor?: string;\n chevronColor?: string;\n headingTextColor?: string;\n textColor?: string;\n}\n\nexport interface LabelProps {\n headingTextColor?: string;\n textColor?: string;\n textFontSize?: number;\n headingFontSize?: number;\n}\n\nexport interface TextFieldProps {\n borderColor?: string;\n borderWidth?: number;\n borderRadius?: number;\n textColor?: string;\n textFontSize?: number;\n}\n\nexport interface ButtonProps {\n backgroundColor?: string;\n borderRadius?: number;\n textColor?: string;\n textFontSize?: number;\n}\n"],"mappings":"8FAcYA,mBAAkB,yDAAlBA,kBAAkB,EAAlBA,kBAAkB,CAAlBA,kBAAkB,yBAAlBA,kBAAkB,CAAlBA,kBAAkB,qBAAlBA,kBAAkB,CAAlBA,kBAAkB,8CAAlBA,kBAAkB,8BAAlBA,kBAAkB"}
1
+ {"version":3,"names":["NavigationBarStyle","exports"],"sourceRoot":"../../../src","sources":["types/ThreeDSecure.ts"],"mappings":"8FAcY,CAAAA,kBAAkB,CAAAC,OAAA,CAAAD,kBAAA,UAAlBA,kBAAkB,EAAlBA,kBAAkB,CAAlBA,kBAAkB,yBAAlBA,kBAAkB,CAAlBA,kBAAkB,qBAAlBA,kBAAkB,CAAlBA,kBAAkB,iDAAlB,CAAAA,kBAAkB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["Token.ts"],"sourcesContent":["import type { Address } from './Common';\n\nexport type CardBrand =\n | 'AmericanExpress'\n | 'DinersClub'\n | 'Discover'\n | 'JCB'\n | 'MasterCard'\n | 'UnionPay'\n | 'Visa'\n | 'Unknown';\n\nexport type Type =\n | 'Account'\n | 'BankAccount'\n | 'Card'\n | 'CvcUpdate'\n | 'Person'\n | 'Pii';\n\nexport interface Result {\n id: string;\n /** The UNIX timestamp (in milliseconds) of the date this token was created. */\n created: string;\n type: Type;\n used: boolean;\n livemode: boolean;\n card?: Card;\n bankAccount?: BankAccount;\n}\n\nexport interface BankAccount {\n /** A unique ID for this bank account. */\n id: string;\n /** The name of the associated bank. */\n bankName: string | null;\n /** The name of the person or business that owns the bank account. This field is required when attaching the bank account to a Customer object. */\n accountHolderName: string | null;\n /** The type of entity that holds the account. */\n accountHolderType: BankAcccountHolderType | null;\n /** The currency the bank account is in. This must be a country/currency pairing that Stripe supports. */\n currency: string | null;\n /** The country in which the bank account is located. */\n country: string | null;\n routingNumber: string | null;\n status: BankAccountStatus | null;\n fingerprint: string | null;\n last4: string | null;\n}\n\nexport type BankAccountStatus =\n | 'Errored'\n | 'New'\n | 'Validated'\n | 'VerificationFailed'\n | 'Verified';\n\nexport interface Card {\n id: string;\n country: string;\n brand: CardBrand;\n currency?: string;\n expMonth: number;\n expYear: number;\n last4: string;\n funding: 'Credit' | 'Debit' | 'Prepaid' | 'Unknown';\n address: Address;\n name?: string;\n}\n\nexport type CreateParams =\n | CreateCardTokenParams\n | CreateBankAccountTokenParams\n | CreatePiiTokenParams;\n\n/** Creates a single-use token that represents a credit card’s details. Use this in combination with either the CardField or CardForm components. This token can be used in place of a credit card object with any API method. See https://stripe.com/docs/api/tokens/create_card*/\nexport type CreateCardTokenParams = {\n type: 'Card';\n address?: Address;\n name?: string;\n currency?: string;\n};\n\nexport type BankAcccountHolderType = 'Company' | 'Individual';\n\nexport type BankAcccountType = 'Checking' | 'Savings';\n\n/** Creates a single-use token that represents a bank account’s details. This token can be used with any API method in place of a bank account object. See https://stripe.com/docs/api/tokens/create_bank_account */\nexport type CreateBankAccountTokenParams = {\n type: 'BankAccount';\n accountHolderName?: string;\n accountHolderType?: BankAcccountHolderType;\n accountNumber: string;\n country: string;\n currency: string;\n routingNumber?: string;\n};\n\n/** Creates a single-use token that represents the details of personally identifiable information (PII). See https://stripe.com/docs/api/tokens/create_pii */\nexport type CreatePiiTokenParams = {\n type: 'Pii';\n /** The user's personal ID number */\n personalId: string;\n};\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/Token.ts"],"mappings":"","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["ApplePayButtonComponent.ts"],"sourcesContent":["import type { StyleProp, ViewStyle, NativeSyntheticEvent } from 'react-native';\nimport type { ShippingMethod, ShippingContact } from '../PlatformPay';\nexport interface NativeProps {\n style?: StyleProp<ViewStyle>;\n disabled?: boolean;\n type?: number;\n buttonStyle?: number;\n borderRadius?: number;\n onPressAction?(): void;\n onShippingMethodSelectedAction?: (\n value: NativeSyntheticEvent<{\n shippingMethod: ShippingMethod;\n }>\n ) => void;\n onShippingContactSelectedAction?: (\n value: NativeSyntheticEvent<{\n shippingContact: ShippingContact;\n }>\n ) => void;\n onCouponCodeEnteredAction?: (\n value: NativeSyntheticEvent<{\n couponCode: string;\n }>\n ) => void;\n onOrderTrackingAction?: () => void;\n}\n\nexport type Type =\n | 'plain'\n | 'buy'\n | 'setUp'\n | 'inStore'\n | 'donate'\n | 'checkout'\n | 'book'\n | 'subscribe'\n | 'reload'\n | 'addMoney'\n | 'topUp'\n | 'order'\n | 'rent'\n | 'support'\n | 'contribute'\n | 'tip'\n | 'continue';\n\nexport type Style = 'white' | 'whiteOutline' | 'black' | 'automatic';\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../../src","sources":["types/components/ApplePayButtonComponent.ts"],"mappings":"","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["AuBECSDebitFormComponent.ts"],"sourcesContent":["import type { NativeSyntheticEvent, StyleProp, ViewStyle } from 'react-native';\n\n/**\n * @ignore\n */\nexport interface NativeProps {\n companyName: string;\n style?: StyleProp<ViewStyle>;\n formStyle: Styles;\n onCompleteAction(value: NativeSyntheticEvent<FormDetails>): void;\n}\n\nexport interface FormDetails {\n accountNumber: string;\n bsbNumber: string;\n email: string;\n name: string;\n}\n\nexport interface Styles {\n borderWidth?: number;\n backgroundColor?: string;\n borderColor?: string;\n borderRadius?: number;\n textColor?: string;\n fontSize?: number;\n placeholderColor?: string;\n textErrorColor?: string;\n}\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../../src","sources":["types/components/AuBECSDebitFormComponent.ts"],"mappings":"","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,"__esModule",{value:true});exports.ValidationState=void 0;var ValidationState;exports.ValidationState=ValidationState;(function(ValidationState){ValidationState["Valid"]="Valid";ValidationState["Invalid"]="Invalid";ValidationState["Incomplete"]="Incomplete";ValidationState["Unknown"]="Unknown";})(ValidationState||(exports.ValidationState=ValidationState={}));
1
+ Object.defineProperty(exports,"__esModule",{value:true});exports.ValidationState=void 0;var ValidationState=exports.ValidationState=function(ValidationState){ValidationState["Valid"]="Valid";ValidationState["Invalid"]="Invalid";ValidationState["Incomplete"]="Incomplete";ValidationState["Unknown"]="Unknown";return ValidationState;}({});
2
2
  //# sourceMappingURL=CardFieldInput.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["ValidationState"],"sources":["CardFieldInput.ts"],"sourcesContent":["import type { NativeSyntheticEvent, StyleProp, ViewStyle } from 'react-native';\nimport type { CardBrand } from '../Token';\n\nexport type FieldName = 'CardNumber' | 'Cvc' | 'ExpiryDate' | 'PostalCode';\n\nexport enum ValidationState {\n Valid = 'Valid',\n Invalid = 'Invalid',\n Incomplete = 'Incomplete',\n Unknown = 'Unknown',\n}\n\nexport interface Details {\n last4: string;\n expiryMonth: number;\n expiryYear: number;\n postalCode?: string;\n brand: CardBrand;\n complete: boolean;\n validExpiryDate: ValidationState;\n validCVC: ValidationState;\n validNumber: ValidationState;\n /**\n * WARNING: Full card details are only returned when the `dangerouslyGetFullCardDetails` prop\n * on the `CardField` component is set to `true`.\n * Only do this if you're certain that you fulfill the necessary PCI compliance requirements.\n * Make sure that you're not mistakenly logging or storing full card details!\n * See the docs for details: https://stripe.com/docs/security/guide#validating-pci-compliance\n */\n number?: string;\n cvc?: string;\n}\n\nexport interface Styles {\n borderWidth?: number;\n backgroundColor?: string;\n borderColor?: string;\n borderRadius?: number;\n textColor?: string;\n fontSize?: number;\n placeholderColor?: string;\n cursorColor?: string;\n textErrorColor?: string;\n fontFamily?: string;\n}\n\nexport interface Placeholders {\n number?: string;\n expiration?: string;\n cvc?: string;\n postalCode?: string;\n}\n\n/**\n * @ignore\n */\nexport interface NativeProps {\n style?: StyleProp<ViewStyle>;\n value?: Partial<Details>;\n postalCodeEnabled?: boolean;\n autofocus?: boolean;\n countryCode: string | null;\n onCardChange(event: NativeSyntheticEvent<Details>): void;\n onFocusChange(\n event: NativeSyntheticEvent<{ focusedField: FieldName | null }>\n ): void;\n cardStyle?: Styles;\n placeholders?: Placeholders;\n disabled?: boolean;\n}\n\nexport interface Methods {\n focus(): void;\n blur(): void;\n clear(): void;\n}\n"],"mappings":"2FAKYA,gBAAe,mDAAfA,eAAe,EAAfA,eAAe,kBAAfA,eAAe,sBAAfA,eAAe,4BAAfA,eAAe,yBAAfA,eAAe,2BAAfA,eAAe"}
1
+ {"version":3,"names":["ValidationState","exports"],"sourceRoot":"../../../../src","sources":["types/components/CardFieldInput.ts"],"mappings":"2FAKY,CAAAA,eAAe,CAAAC,OAAA,CAAAD,eAAA,UAAfA,eAAe,EAAfA,eAAe,kBAAfA,eAAe,sBAAfA,eAAe,4BAAfA,eAAe,4BAAf,CAAAA,eAAe","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["CardFormView.ts"],"sourcesContent":["import type { NativeSyntheticEvent, StyleProp, ViewStyle } from 'react-native';\nimport type { CardBrand } from '../Token';\n\nexport type FieldName = 'CardNumber' | 'Cvc' | 'ExpiryDate' | 'PostalCode';\n\nexport interface Details {\n last4: string;\n expiryMonth: number;\n expiryYear: number;\n postalCode?: string;\n brand: CardBrand;\n complete: boolean;\n country: string;\n /**\n * WARNING: Full card details are only returned when the `dangerouslyGetFullCardDetails` prop\n * on the `CardField` component is set to `true`.\n * Only do this if you're certain that you fulfill the necessary PCI compliance requirements.\n * Make sure that you're not mistakenly logging or storing full card details!\n * See the docs for details: https://stripe.com/docs/security/guide#validating-pci-compliance\n */\n number?: string;\n cvc?: string;\n}\n\nexport interface Styles {\n backgroundColor?: string;\n // disabledBackgroundColor?: string;\n // type?: 'borderless' | 'standard';\n borderWidth?: number;\n borderColor?: string;\n borderRadius?: number;\n textColor?: string;\n fontSize?: number;\n placeholderColor?: string;\n cursorColor?: string;\n textErrorColor?: string;\n fontFamily?: string;\n}\n\nexport interface Placeholders {\n number?: string;\n expiration?: string;\n cvc?: string;\n postalCode?: string;\n}\n\nexport type DefaultValues = {\n /** The 2-letter country code for the country selected by default on Android. If this is null, it is set by the device's configured region in the Settings app. */\n countryCode?: string;\n};\n\n/**\n * @ignore\n */\nexport interface NativeProps {\n style?: StyleProp<ViewStyle>;\n autofocus?: boolean;\n cardStyle?: Styles;\n /** Android only */\n placeholders?: Placeholders;\n /** Android only */\n defaultValues?: DefaultValues;\n // postalCodeEnabled: boolean;\n onFocusChange(\n event: NativeSyntheticEvent<{ focusedField: FieldName | null }>\n ): void;\n onFormComplete(event: NativeSyntheticEvent<Details>): void;\n disabled?: boolean;\n}\n\nexport interface Methods {\n focus(): void;\n blur(): void;\n}\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../../src","sources":["types/components/CardFormView.ts"],"mappings":"","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["GooglePayButtonComponent.ts"],"sourcesContent":["import type { StyleProp, ViewStyle } from 'react-native';\nexport interface NativeProps {\n style?: StyleProp<ViewStyle>;\n type?: number;\n appearance?: number;\n borderRadius?: number;\n}\n"],"mappings":""}
1
+ {"version":3,"names":[],"sourceRoot":"../../../../src","sources":["types/components/GooglePayButtonComponent.ts"],"mappings":"","ignoreList":[]}