tf-checkout-react-native 1.0.47 → 2.0.0-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (711) hide show
  1. package/README.md +215 -3321
  2. package/dist/index.d.mts +10896 -0
  3. package/dist/index.d.ts +10896 -0
  4. package/dist/index.js +25684 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/index.mjs +25751 -0
  7. package/dist/index.mjs.map +1 -0
  8. package/package.json +45 -59
  9. package/scripts/build-seat-map.mjs +31 -0
  10. package/scripts/seat-map-entry.jsx +22 -0
  11. package/src/CardInput.tsx +110 -0
  12. package/src/EmbeddedCheckout.tsx +416 -0
  13. package/src/auth/AuthModal.tsx +305 -0
  14. package/src/auth/EmailCodeForm.tsx +91 -0
  15. package/src/auth/ForgotPasswordForm.tsx +98 -0
  16. package/src/auth/LoginForm.tsx +99 -0
  17. package/src/auth/PasswordInput.tsx +45 -0
  18. package/src/auth/RegisterForm.tsx +333 -0
  19. package/src/auth/ResetPasswordForm.tsx +112 -0
  20. package/src/auth/TwoFactorForm.tsx +74 -0
  21. package/src/auth/index.ts +11 -0
  22. package/src/configure.ts +33 -0
  23. package/src/confirmer.ts +272 -0
  24. package/src/generated/seatMapWidget.ts +3 -0
  25. package/src/index.tsx +25 -227
  26. package/src/instance.ts +13 -0
  27. package/src/sections/Accommodation.tsx +57 -0
  28. package/src/sections/AccountRewards.tsx +108 -0
  29. package/src/sections/AddOns.tsx +286 -0
  30. package/src/sections/BillingInfo.tsx +769 -0
  31. package/src/sections/Bundles.tsx +467 -0
  32. package/src/sections/Confirmation.tsx +143 -0
  33. package/src/sections/EventDiscussionView.tsx +633 -0
  34. package/src/sections/IDVerification.tsx +77 -0
  35. package/src/sections/OrderSummary.tsx +116 -0
  36. package/src/sections/Passes.tsx +177 -0
  37. package/src/sections/Payment.tsx +534 -0
  38. package/src/sections/PostReaction.tsx +122 -0
  39. package/src/sections/Rewards.tsx +320 -0
  40. package/src/sections/SeatMap.tsx +225 -0
  41. package/src/sections/SeatsIoMap.tsx +110 -0
  42. package/src/sections/TicketChange.tsx +379 -0
  43. package/src/sections/TicketGift.tsx +206 -0
  44. package/src/sections/TicketRefund.tsx +104 -0
  45. package/src/sections/Tickets.tsx +761 -0
  46. package/src/sections/Trips.tsx +87 -0
  47. package/src/sections/WaiverSigning.tsx +429 -0
  48. package/src/sections/billing/BillingAddressFields.tsx +126 -0
  49. package/src/sections/billing/BuyerField.tsx +78 -0
  50. package/src/sections/billing/PhoneIdentity.tsx +169 -0
  51. package/src/sections/billing/TicketHoldersCard.tsx +119 -0
  52. package/src/sections/billing/types.ts +10 -0
  53. package/src/sections/discussion/CommentImages.tsx +342 -0
  54. package/src/sections/discussion/SwipeReply.tsx +88 -0
  55. package/src/sections/index.ts +28 -0
  56. package/src/sections/rewards/RewardsLadder.tsx +167 -0
  57. package/src/sections/rewards/RewardsTree.tsx +117 -0
  58. package/src/storage.ts +26 -0
  59. package/src/ui/CheckoutProvider.tsx +152 -0
  60. package/src/ui/CustomFields.tsx +176 -0
  61. package/src/ui/Field.tsx +189 -0
  62. package/src/ui/Frozen.tsx +22 -0
  63. package/src/ui/InstallmentPicker.tsx +155 -0
  64. package/src/ui/PaymentMethods.tsx +180 -0
  65. package/src/ui/ProviderPages.tsx +134 -0
  66. package/src/ui/QuantitySelect.tsx +127 -0
  67. package/src/ui/Select.tsx +154 -0
  68. package/src/ui/SignaturePad.tsx +218 -0
  69. package/src/ui/Timer.tsx +69 -0
  70. package/src/ui/TimerBanner.tsx +95 -0
  71. package/src/ui/index.ts +18 -0
  72. package/src/ui/primitives.tsx +202 -0
  73. package/src/ui/theme.ts +89 -0
  74. package/src/ui/useAccountT.ts +16 -0
  75. package/src/useCheckout.ts +37 -0
  76. package/lib/brand-DA2IARBI.png +0 -0
  77. package/lib/ic_check-FLIJQ3BY.png +0 -0
  78. package/lib/ic_clock-BZ4Z7PIP.png +0 -0
  79. package/lib/ic_copy-VWMA4B7X.png +0 -0
  80. package/lib/ic_dropdown-BCS3QDNJ.png +0 -0
  81. package/lib/ic_error-KDEZUPSN.png +0 -0
  82. package/lib/ic_eye-WGXVXVAN.png +0 -0
  83. package/lib/ic_eye_off-XTCE6XSO.png +0 -0
  84. package/lib/ic_more-LZWKYCDU.png +0 -0
  85. package/lib/ic_next-LCNIGEDM.png +0 -0
  86. package/lib/index.js +0 -18222
  87. package/lib/index.js.map +0 -1
  88. package/lib/index.mjs +0 -18309
  89. package/lib/index.mjs.map +0 -1
  90. package/lib/typescript/package.json +0 -1
  91. package/lib/typescript/src/api/ApiClient.d.ts +0 -49
  92. package/lib/typescript/src/api/ApiClient.d.ts.map +0 -1
  93. package/lib/typescript/src/api/Constants.d.ts +0 -11
  94. package/lib/typescript/src/api/Constants.d.ts.map +0 -1
  95. package/lib/typescript/src/api/ErrorHandler.d.ts +0 -12
  96. package/lib/typescript/src/api/ErrorHandler.d.ts.map +0 -1
  97. package/lib/typescript/src/api/api.types.d.ts +0 -8
  98. package/lib/typescript/src/api/api.types.d.ts.map +0 -1
  99. package/lib/typescript/src/api/types.d.ts +0 -518
  100. package/lib/typescript/src/api/types.d.ts.map +0 -1
  101. package/lib/typescript/src/apiv2/index.d.ts +0 -3
  102. package/lib/typescript/src/apiv2/index.d.ts.map +0 -1
  103. package/lib/typescript/src/common/query.types.d.ts +0 -3
  104. package/lib/typescript/src/common/query.types.d.ts.map +0 -1
  105. package/lib/typescript/src/components/bottomSheetModal/BottomSheetModal.d.ts +0 -8
  106. package/lib/typescript/src/components/bottomSheetModal/BottomSheetModal.d.ts.map +0 -1
  107. package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalStyles.d.ts +0 -39
  108. package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalStyles.d.ts.map +0 -1
  109. package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalTypes.d.ts +0 -23
  110. package/lib/typescript/src/components/bottomSheetModal/BottomSheetModalTypes.d.ts.map +0 -1
  111. package/lib/typescript/src/components/button/Button.d.ts +0 -5
  112. package/lib/typescript/src/components/button/Button.d.ts.map +0 -1
  113. package/lib/typescript/src/components/button/styles.d.ts +0 -28
  114. package/lib/typescript/src/components/button/styles.d.ts.map +0 -1
  115. package/lib/typescript/src/components/button/types.d.ts +0 -15
  116. package/lib/typescript/src/components/button/types.d.ts.map +0 -1
  117. package/lib/typescript/src/components/cartTimer/CartTimer.d.ts +0 -5
  118. package/lib/typescript/src/components/cartTimer/CartTimer.d.ts.map +0 -1
  119. package/lib/typescript/src/components/cartTimer/styles.d.ts +0 -47
  120. package/lib/typescript/src/components/cartTimer/styles.d.ts.map +0 -1
  121. package/lib/typescript/src/components/cartTimer/types.d.ts +0 -19
  122. package/lib/typescript/src/components/cartTimer/types.d.ts.map +0 -1
  123. package/lib/typescript/src/components/checkbox/Checkbox.d.ts +0 -4
  124. package/lib/typescript/src/components/checkbox/Checkbox.d.ts.map +0 -1
  125. package/lib/typescript/src/components/checkbox/styles.d.ts +0 -39
  126. package/lib/typescript/src/components/checkbox/styles.d.ts.map +0 -1
  127. package/lib/typescript/src/components/checkbox/types.d.ts +0 -22
  128. package/lib/typescript/src/components/checkbox/types.d.ts.map +0 -1
  129. package/lib/typescript/src/components/datePicker/DatePicker.d.ts +0 -4
  130. package/lib/typescript/src/components/datePicker/DatePicker.d.ts.map +0 -1
  131. package/lib/typescript/src/components/datePicker/styles.d.ts +0 -35
  132. package/lib/typescript/src/components/datePicker/styles.d.ts.map +0 -1
  133. package/lib/typescript/src/components/datePicker/types.d.ts +0 -20
  134. package/lib/typescript/src/components/datePicker/types.d.ts.map +0 -1
  135. package/lib/typescript/src/components/dropdown/Dropdown.d.ts +0 -4
  136. package/lib/typescript/src/components/dropdown/Dropdown.d.ts.map +0 -1
  137. package/lib/typescript/src/components/dropdown/DropdownListItem.d.ts +0 -4
  138. package/lib/typescript/src/components/dropdown/DropdownListItem.d.ts.map +0 -1
  139. package/lib/typescript/src/components/dropdown/styles.d.ts +0 -85
  140. package/lib/typescript/src/components/dropdown/styles.d.ts.map +0 -1
  141. package/lib/typescript/src/components/dropdown/types.d.ts +0 -35
  142. package/lib/typescript/src/components/dropdown/types.d.ts.map +0 -1
  143. package/lib/typescript/src/components/dropdownMaterial/DropdownMaterial.d.ts +0 -4
  144. package/lib/typescript/src/components/dropdownMaterial/DropdownMaterial.d.ts.map +0 -1
  145. package/lib/typescript/src/components/dropdownMaterial/styles.d.ts +0 -79
  146. package/lib/typescript/src/components/dropdownMaterial/styles.d.ts.map +0 -1
  147. package/lib/typescript/src/components/dropdownMaterial/types.d.ts +0 -22
  148. package/lib/typescript/src/components/dropdownMaterial/types.d.ts.map +0 -1
  149. package/lib/typescript/src/components/enterPassword/EnterPassword.d.ts +0 -5
  150. package/lib/typescript/src/components/enterPassword/EnterPassword.d.ts.map +0 -1
  151. package/lib/typescript/src/components/enterPassword/styles.d.ts +0 -21
  152. package/lib/typescript/src/components/enterPassword/styles.d.ts.map +0 -1
  153. package/lib/typescript/src/components/enterPassword/types.d.ts +0 -24
  154. package/lib/typescript/src/components/enterPassword/types.d.ts.map +0 -1
  155. package/lib/typescript/src/components/formField/FormField.d.ts +0 -4
  156. package/lib/typescript/src/components/formField/FormField.d.ts.map +0 -1
  157. package/lib/typescript/src/components/formField/styles.d.ts +0 -35
  158. package/lib/typescript/src/components/formField/styles.d.ts.map +0 -1
  159. package/lib/typescript/src/components/formField/types.d.ts +0 -48
  160. package/lib/typescript/src/components/formField/types.d.ts.map +0 -1
  161. package/lib/typescript/src/components/index.d.ts +0 -21
  162. package/lib/typescript/src/components/index.d.ts.map +0 -1
  163. package/lib/typescript/src/components/input/Input.d.ts +0 -4
  164. package/lib/typescript/src/components/input/Input.d.ts.map +0 -1
  165. package/lib/typescript/src/components/input/styles.d.ts +0 -47
  166. package/lib/typescript/src/components/input/styles.d.ts.map +0 -1
  167. package/lib/typescript/src/components/input/types.d.ts +0 -28
  168. package/lib/typescript/src/components/input/types.d.ts.map +0 -1
  169. package/lib/typescript/src/components/loading/Loading.d.ts +0 -4
  170. package/lib/typescript/src/components/loading/Loading.d.ts.map +0 -1
  171. package/lib/typescript/src/components/loading/styles.d.ts +0 -30
  172. package/lib/typescript/src/components/loading/styles.d.ts.map +0 -1
  173. package/lib/typescript/src/components/loading/types.d.ts +0 -15
  174. package/lib/typescript/src/components/loading/types.d.ts.map +0 -1
  175. package/lib/typescript/src/components/loggedIn/LoggedIn.d.ts +0 -5
  176. package/lib/typescript/src/components/loggedIn/LoggedIn.d.ts.map +0 -1
  177. package/lib/typescript/src/components/loggedIn/styles.d.ts +0 -9
  178. package/lib/typescript/src/components/loggedIn/styles.d.ts.map +0 -1
  179. package/lib/typescript/src/components/loggedIn/types.d.ts +0 -24
  180. package/lib/typescript/src/components/loggedIn/types.d.ts.map +0 -1
  181. package/lib/typescript/src/components/login/Login.d.ts +0 -5
  182. package/lib/typescript/src/components/login/Login.d.ts.map +0 -1
  183. package/lib/typescript/src/components/login/LoginView.d.ts +0 -5
  184. package/lib/typescript/src/components/login/LoginView.d.ts.map +0 -1
  185. package/lib/typescript/src/components/login/components/LoginForm.d.ts +0 -5
  186. package/lib/typescript/src/components/login/components/LoginForm.d.ts.map +0 -1
  187. package/lib/typescript/src/components/login/components/types.d.ts +0 -19
  188. package/lib/typescript/src/components/login/components/types.d.ts.map +0 -1
  189. package/lib/typescript/src/components/login/styles.d.ts +0 -62
  190. package/lib/typescript/src/components/login/styles.d.ts.map +0 -1
  191. package/lib/typescript/src/components/login/types.d.ts +0 -144
  192. package/lib/typescript/src/components/login/types.d.ts.map +0 -1
  193. package/lib/typescript/src/components/phoneInput/PhoneInput.d.ts +0 -5
  194. package/lib/typescript/src/components/phoneInput/PhoneInput.d.ts.map +0 -1
  195. package/lib/typescript/src/components/phoneInput/styles.d.ts +0 -29
  196. package/lib/typescript/src/components/phoneInput/styles.d.ts.map +0 -1
  197. package/lib/typescript/src/components/phoneInput/types.d.ts +0 -31
  198. package/lib/typescript/src/components/phoneInput/types.d.ts.map +0 -1
  199. package/lib/typescript/src/components/promoCode/PromoCode.d.ts +0 -5
  200. package/lib/typescript/src/components/promoCode/PromoCode.d.ts.map +0 -1
  201. package/lib/typescript/src/components/promoCode/styles.d.ts +0 -61
  202. package/lib/typescript/src/components/promoCode/styles.d.ts.map +0 -1
  203. package/lib/typescript/src/components/promoCode/types.d.ts +0 -36
  204. package/lib/typescript/src/components/promoCode/types.d.ts.map +0 -1
  205. package/lib/typescript/src/components/radioButton/RadioButton.d.ts +0 -5
  206. package/lib/typescript/src/components/radioButton/RadioButton.d.ts.map +0 -1
  207. package/lib/typescript/src/components/radioButton/styles.d.ts +0 -25
  208. package/lib/typescript/src/components/radioButton/styles.d.ts.map +0 -1
  209. package/lib/typescript/src/components/radioButton/types.d.ts +0 -16
  210. package/lib/typescript/src/components/radioButton/types.d.ts.map +0 -1
  211. package/lib/typescript/src/components/radioGroup/RadioGroup.d.ts +0 -4
  212. package/lib/typescript/src/components/radioGroup/RadioGroup.d.ts.map +0 -1
  213. package/lib/typescript/src/components/radioGroup/index.d.ts +0 -4
  214. package/lib/typescript/src/components/radioGroup/index.d.ts.map +0 -1
  215. package/lib/typescript/src/components/radioGroup/types.d.ts +0 -24
  216. package/lib/typescript/src/components/radioGroup/types.d.ts.map +0 -1
  217. package/lib/typescript/src/components/restorePassword/RestorePassword.d.ts +0 -5
  218. package/lib/typescript/src/components/restorePassword/RestorePassword.d.ts.map +0 -1
  219. package/lib/typescript/src/components/restorePassword/ResultDialog.d.ts +0 -5
  220. package/lib/typescript/src/components/restorePassword/ResultDialog.d.ts.map +0 -1
  221. package/lib/typescript/src/components/restorePassword/styles.d.ts +0 -34
  222. package/lib/typescript/src/components/restorePassword/styles.d.ts.map +0 -1
  223. package/lib/typescript/src/components/restorePassword/types.d.ts +0 -49
  224. package/lib/typescript/src/components/restorePassword/types.d.ts.map +0 -1
  225. package/lib/typescript/src/components/separator/Separator.d.ts +0 -4
  226. package/lib/typescript/src/components/separator/Separator.d.ts.map +0 -1
  227. package/lib/typescript/src/components/separator/types.d.ts +0 -9
  228. package/lib/typescript/src/components/separator/types.d.ts.map +0 -1
  229. package/lib/typescript/src/components/stripePayment/StripePayment.d.ts +0 -5
  230. package/lib/typescript/src/components/stripePayment/StripePayment.d.ts.map +0 -1
  231. package/lib/typescript/src/components/stripePayment/styles.d.ts +0 -7
  232. package/lib/typescript/src/components/stripePayment/styles.d.ts.map +0 -1
  233. package/lib/typescript/src/components/stripePayment/types.d.ts +0 -14
  234. package/lib/typescript/src/components/stripePayment/types.d.ts.map +0 -1
  235. package/lib/typescript/src/components/waitingList/WaitingList.d.ts +0 -6
  236. package/lib/typescript/src/components/waitingList/WaitingList.d.ts.map +0 -1
  237. package/lib/typescript/src/components/waitingList/WaitingListView.d.ts +0 -5
  238. package/lib/typescript/src/components/waitingList/WaitingListView.d.ts.map +0 -1
  239. package/lib/typescript/src/components/waitingList/styles.d.ts +0 -9
  240. package/lib/typescript/src/components/waitingList/styles.d.ts.map +0 -1
  241. package/lib/typescript/src/components/waitingList/types.d.ts +0 -59
  242. package/lib/typescript/src/components/waitingList/types.d.ts.map +0 -1
  243. package/lib/typescript/src/containers/billingInfo/Billing.d.ts +0 -6
  244. package/lib/typescript/src/containers/billingInfo/Billing.d.ts.map +0 -1
  245. package/lib/typescript/src/containers/billingInfo/styles.d.ts +0 -61
  246. package/lib/typescript/src/containers/billingInfo/styles.d.ts.map +0 -1
  247. package/lib/typescript/src/containers/billingInfo/types.d.ts +0 -160
  248. package/lib/typescript/src/containers/billingInfo/types.d.ts.map +0 -1
  249. package/lib/typescript/src/containers/checkout/Checkout.d.ts +0 -7
  250. package/lib/typescript/src/containers/checkout/Checkout.d.ts.map +0 -1
  251. package/lib/typescript/src/containers/checkout/CheckoutData.d.ts +0 -3
  252. package/lib/typescript/src/containers/checkout/CheckoutData.d.ts.map +0 -1
  253. package/lib/typescript/src/containers/checkout/components/Conditions.d.ts +0 -4
  254. package/lib/typescript/src/containers/checkout/components/Conditions.d.ts.map +0 -1
  255. package/lib/typescript/src/containers/checkout/components/OrderReview.d.ts +0 -4
  256. package/lib/typescript/src/containers/checkout/components/OrderReview.d.ts.map +0 -1
  257. package/lib/typescript/src/containers/checkout/components/styles.d.ts +0 -26
  258. package/lib/typescript/src/containers/checkout/components/styles.d.ts.map +0 -1
  259. package/lib/typescript/src/containers/checkout/styles.d.ts +0 -42
  260. package/lib/typescript/src/containers/checkout/styles.d.ts.map +0 -1
  261. package/lib/typescript/src/containers/checkout/types.d.ts +0 -126
  262. package/lib/typescript/src/containers/checkout/types.d.ts.map +0 -1
  263. package/lib/typescript/src/containers/index.d.ts +0 -9
  264. package/lib/typescript/src/containers/index.d.ts.map +0 -1
  265. package/lib/typescript/src/containers/myOrderDetails/MyOrderDetails.d.ts +0 -6
  266. package/lib/typescript/src/containers/myOrderDetails/MyOrderDetails.d.ts.map +0 -1
  267. package/lib/typescript/src/containers/myOrderDetails/MyOrderDetailsView.d.ts +0 -5
  268. package/lib/typescript/src/containers/myOrderDetails/MyOrderDetailsView.d.ts.map +0 -1
  269. package/lib/typescript/src/containers/myOrderDetails/components/Notification.d.ts +0 -15
  270. package/lib/typescript/src/containers/myOrderDetails/components/Notification.d.ts.map +0 -1
  271. package/lib/typescript/src/containers/myOrderDetails/components/OrderListItem.d.ts +0 -3
  272. package/lib/typescript/src/containers/myOrderDetails/components/OrderListItem.d.ts.map +0 -1
  273. package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActions.d.ts +0 -5
  274. package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActions.d.ts.map +0 -1
  275. package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActionsTypes.d.ts +0 -30
  276. package/lib/typescript/src/containers/myOrderDetails/components/TicketActions/TicketActionsTypes.d.ts.map +0 -1
  277. package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItem.d.ts +0 -8
  278. package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItem.d.ts.map +0 -1
  279. package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemStyles.d.ts +0 -33
  280. package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemStyles.d.ts.map +0 -1
  281. package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemTypes.d.ts +0 -30
  282. package/lib/typescript/src/containers/myOrderDetails/components/TicketListItem/TicketListItemTypes.d.ts.map +0 -1
  283. package/lib/typescript/src/containers/myOrderDetails/components/styles.d.ts +0 -39
  284. package/lib/typescript/src/containers/myOrderDetails/components/styles.d.ts.map +0 -1
  285. package/lib/typescript/src/containers/myOrderDetails/styles.d.ts +0 -55
  286. package/lib/typescript/src/containers/myOrderDetails/styles.d.ts.map +0 -1
  287. package/lib/typescript/src/containers/myOrderDetails/types.d.ts +0 -126
  288. package/lib/typescript/src/containers/myOrderDetails/types.d.ts.map +0 -1
  289. package/lib/typescript/src/containers/myOrders/MyOrders.d.ts +0 -6
  290. package/lib/typescript/src/containers/myOrders/MyOrders.d.ts.map +0 -1
  291. package/lib/typescript/src/containers/myOrders/MyOrdersView.d.ts +0 -5
  292. package/lib/typescript/src/containers/myOrders/MyOrdersView.d.ts.map +0 -1
  293. package/lib/typescript/src/containers/myOrders/components/OrderListItem.d.ts +0 -5
  294. package/lib/typescript/src/containers/myOrders/components/OrderListItem.d.ts.map +0 -1
  295. package/lib/typescript/src/containers/myOrders/components/styles.d.ts +0 -56
  296. package/lib/typescript/src/containers/myOrders/components/styles.d.ts.map +0 -1
  297. package/lib/typescript/src/containers/myOrders/components/types.d.ts +0 -26
  298. package/lib/typescript/src/containers/myOrders/components/types.d.ts.map +0 -1
  299. package/lib/typescript/src/containers/myOrders/styles.d.ts +0 -37
  300. package/lib/typescript/src/containers/myOrders/styles.d.ts.map +0 -1
  301. package/lib/typescript/src/containers/myOrders/types.d.ts +0 -73
  302. package/lib/typescript/src/containers/myOrders/types.d.ts.map +0 -1
  303. package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmation.d.ts +0 -6
  304. package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmation.d.ts.map +0 -1
  305. package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmationView.d.ts +0 -5
  306. package/lib/typescript/src/containers/purchaseConfirmation/PurchaseConfirmationView.d.ts.map +0 -1
  307. package/lib/typescript/src/containers/purchaseConfirmation/styles.d.ts +0 -74
  308. package/lib/typescript/src/containers/purchaseConfirmation/styles.d.ts.map +0 -1
  309. package/lib/typescript/src/containers/purchaseConfirmation/types.d.ts +0 -66
  310. package/lib/typescript/src/containers/purchaseConfirmation/types.d.ts.map +0 -1
  311. package/lib/typescript/src/containers/resaleTickets/ResaleTickets.d.ts +0 -6
  312. package/lib/typescript/src/containers/resaleTickets/ResaleTickets.d.ts.map +0 -1
  313. package/lib/typescript/src/containers/resaleTickets/ResaleTicketsView.d.ts +0 -5
  314. package/lib/typescript/src/containers/resaleTickets/ResaleTicketsView.d.ts.map +0 -1
  315. package/lib/typescript/src/containers/resaleTickets/types.d.ts +0 -129
  316. package/lib/typescript/src/containers/resaleTickets/types.d.ts.map +0 -1
  317. package/lib/typescript/src/containers/resetPassword/ResetPassword.d.ts +0 -5
  318. package/lib/typescript/src/containers/resetPassword/ResetPassword.d.ts.map +0 -1
  319. package/lib/typescript/src/containers/resetPassword/ResetPasswordView.d.ts +0 -5
  320. package/lib/typescript/src/containers/resetPassword/ResetPasswordView.d.ts.map +0 -1
  321. package/lib/typescript/src/containers/resetPassword/styles.d.ts +0 -33
  322. package/lib/typescript/src/containers/resetPassword/styles.d.ts.map +0 -1
  323. package/lib/typescript/src/containers/resetPassword/types.d.ts +0 -48
  324. package/lib/typescript/src/containers/resetPassword/types.d.ts.map +0 -1
  325. package/lib/typescript/src/containers/tickets/Tickets.d.ts +0 -6
  326. package/lib/typescript/src/containers/tickets/Tickets.d.ts.map +0 -1
  327. package/lib/typescript/src/containers/tickets/TicketsView.d.ts +0 -4
  328. package/lib/typescript/src/containers/tickets/TicketsView.d.ts.map +0 -1
  329. package/lib/typescript/src/containers/tickets/components/TicketGroupListHeader.d.ts +0 -5
  330. package/lib/typescript/src/containers/tickets/components/TicketGroupListHeader.d.ts.map +0 -1
  331. package/lib/typescript/src/containers/tickets/components/TicketListItem.d.ts +0 -4
  332. package/lib/typescript/src/containers/tickets/components/TicketListItem.d.ts.map +0 -1
  333. package/lib/typescript/src/containers/tickets/components/styles.d.ts +0 -51
  334. package/lib/typescript/src/containers/tickets/components/styles.d.ts.map +0 -1
  335. package/lib/typescript/src/containers/tickets/components/types.d.ts +0 -40
  336. package/lib/typescript/src/containers/tickets/components/types.d.ts.map +0 -1
  337. package/lib/typescript/src/containers/tickets/styles.d.ts +0 -20
  338. package/lib/typescript/src/containers/tickets/styles.d.ts.map +0 -1
  339. package/lib/typescript/src/containers/tickets/types.d.ts +0 -114
  340. package/lib/typescript/src/containers/tickets/types.d.ts.map +0 -1
  341. package/lib/typescript/src/core/BillingCore/BillingCore.d.ts +0 -13
  342. package/lib/typescript/src/core/BillingCore/BillingCore.d.ts.map +0 -1
  343. package/lib/typescript/src/core/BillingCore/BillingCoreTypes.d.ts +0 -24
  344. package/lib/typescript/src/core/BillingCore/BillingCoreTypes.d.ts.map +0 -1
  345. package/lib/typescript/src/core/CheckoutCore/CheckoutCore.d.ts +0 -15
  346. package/lib/typescript/src/core/CheckoutCore/CheckoutCore.d.ts.map +0 -1
  347. package/lib/typescript/src/core/CheckoutCore/CheckoutCoreTypes.d.ts +0 -17
  348. package/lib/typescript/src/core/CheckoutCore/CheckoutCoreTypes.d.ts.map +0 -1
  349. package/lib/typescript/src/core/CoreProps.d.ts +0 -5
  350. package/lib/typescript/src/core/CoreProps.d.ts.map +0 -1
  351. package/lib/typescript/src/core/LoginCore/LoginCore.d.ts +0 -6
  352. package/lib/typescript/src/core/LoginCore/LoginCore.d.ts.map +0 -1
  353. package/lib/typescript/src/core/LoginCore/LoginCoreHelper.d.ts +0 -3
  354. package/lib/typescript/src/core/LoginCore/LoginCoreHelper.d.ts.map +0 -1
  355. package/lib/typescript/src/core/LoginCore/LoginCoreTypes.d.ts +0 -15
  356. package/lib/typescript/src/core/LoginCore/LoginCoreTypes.d.ts.map +0 -1
  357. package/lib/typescript/src/core/MyOrdersCore/MyOrdersCore.d.ts +0 -6
  358. package/lib/typescript/src/core/MyOrdersCore/MyOrdersCore.d.ts.map +0 -1
  359. package/lib/typescript/src/core/MyOrdersCore/MyOrdersCoreTypes.d.ts +0 -10
  360. package/lib/typescript/src/core/MyOrdersCore/MyOrdersCoreTypes.d.ts.map +0 -1
  361. package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCore.d.ts +0 -6
  362. package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCore.d.ts.map +0 -1
  363. package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCoreTypes.d.ts +0 -9
  364. package/lib/typescript/src/core/OrderDetailsCore/OrderDetailsCoreTypes.d.ts.map +0 -1
  365. package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCore.d.ts +0 -6
  366. package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCore.d.ts.map +0 -1
  367. package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCoreTypes.d.ts +0 -8
  368. package/lib/typescript/src/core/PurchaseConfirmationCore/PurchaseConfirmationCoreTypes.d.ts.map +0 -1
  369. package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCore.d.ts +0 -6
  370. package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCore.d.ts.map +0 -1
  371. package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCoreTypes.d.ts +0 -5
  372. package/lib/typescript/src/core/ResetPasswordCore/ResetPasswordCoreTypes.d.ts.map +0 -1
  373. package/lib/typescript/src/core/Session/SessionCoreTypes.d.ts +0 -9
  374. package/lib/typescript/src/core/Session/SessionCoreTypes.d.ts.map +0 -1
  375. package/lib/typescript/src/core/Session/SessionHandle.d.ts +0 -6
  376. package/lib/typescript/src/core/Session/SessionHandle.d.ts.map +0 -1
  377. package/lib/typescript/src/core/TicketsCore/TicketsCore.d.ts +0 -6
  378. package/lib/typescript/src/core/TicketsCore/TicketsCore.d.ts.map +0 -1
  379. package/lib/typescript/src/core/TicketsCore/TicketsCoreTypes.d.ts +0 -40
  380. package/lib/typescript/src/core/TicketsCore/TicketsCoreTypes.d.ts.map +0 -1
  381. package/lib/typescript/src/core/WaitingListCore/WaitingListCore.d.ts +0 -6
  382. package/lib/typescript/src/core/WaitingListCore/WaitingListCore.d.ts.map +0 -1
  383. package/lib/typescript/src/core/WaitingListCore/WaitingListCoreTypes.d.ts +0 -12
  384. package/lib/typescript/src/core/WaitingListCore/WaitingListCoreTypes.d.ts.map +0 -1
  385. package/lib/typescript/src/core/index.d.ts +0 -21
  386. package/lib/typescript/src/core/index.d.ts.map +0 -1
  387. package/lib/typescript/src/features/auth/api-hooks.d.ts +0 -178
  388. package/lib/typescript/src/features/auth/api-hooks.d.ts.map +0 -1
  389. package/lib/typescript/src/features/auth/types.d.ts +0 -51
  390. package/lib/typescript/src/features/auth/types.d.ts.map +0 -1
  391. package/lib/typescript/src/features/auth/utils.d.ts +0 -3
  392. package/lib/typescript/src/features/auth/utils.d.ts.map +0 -1
  393. package/lib/typescript/src/features/checkout-v2/components/AddonsContainer.d.ts +0 -37
  394. package/lib/typescript/src/features/checkout-v2/components/AddonsContainer.d.ts.map +0 -1
  395. package/lib/typescript/src/features/checkout-v2/components/Conditions.d.ts +0 -30
  396. package/lib/typescript/src/features/checkout-v2/components/Conditions.d.ts.map +0 -1
  397. package/lib/typescript/src/features/checkout-v2/components/OrderReview.d.ts +0 -25
  398. package/lib/typescript/src/features/checkout-v2/components/OrderReview.d.ts.map +0 -1
  399. package/lib/typescript/src/features/checkout-v2/components/TicketHoldersSection.d.ts +0 -14
  400. package/lib/typescript/src/features/checkout-v2/components/TicketHoldersSection.d.ts.map +0 -1
  401. package/lib/typescript/src/features/checkout-v2/form/config.d.ts +0 -61
  402. package/lib/typescript/src/features/checkout-v2/form/config.d.ts.map +0 -1
  403. package/lib/typescript/src/features/checkout-v2/form/index.d.ts +0 -22
  404. package/lib/typescript/src/features/checkout-v2/form/index.d.ts.map +0 -1
  405. package/lib/typescript/src/features/checkout-v2/form/styles.d.ts +0 -4501
  406. package/lib/typescript/src/features/checkout-v2/form/styles.d.ts.map +0 -1
  407. package/lib/typescript/src/features/checkout-v2/form/texts.d.ts +0 -4
  408. package/lib/typescript/src/features/checkout-v2/form/texts.d.ts.map +0 -1
  409. package/lib/typescript/src/features/checkout-v2/form/types.d.ts +0 -191
  410. package/lib/typescript/src/features/checkout-v2/form/types.d.ts.map +0 -1
  411. package/lib/typescript/src/features/checkout-v2/hooks/api-hooks.d.ts +0 -227
  412. package/lib/typescript/src/features/checkout-v2/hooks/api-hooks.d.ts.map +0 -1
  413. package/lib/typescript/src/features/checkout-v2/hooks/use-checkout.d.ts +0 -37
  414. package/lib/typescript/src/features/checkout-v2/hooks/use-checkout.d.ts.map +0 -1
  415. package/lib/typescript/src/features/checkout-v2/index.d.ts +0 -42
  416. package/lib/typescript/src/features/checkout-v2/index.d.ts.map +0 -1
  417. package/lib/typescript/src/features/checkout-v2/types.d.ts +0 -433
  418. package/lib/typescript/src/features/checkout-v2/types.d.ts.map +0 -1
  419. package/lib/typescript/src/features/checkout-v2/utils.d.ts +0 -12
  420. package/lib/typescript/src/features/checkout-v2/utils.d.ts.map +0 -1
  421. package/lib/typescript/src/features/event/api-hooks.d.ts +0 -171
  422. package/lib/typescript/src/features/event/api-hooks.d.ts.map +0 -1
  423. package/lib/typescript/src/features/event/types.d.ts +0 -58
  424. package/lib/typescript/src/features/event/types.d.ts.map +0 -1
  425. package/lib/typescript/src/features/form/index.d.ts +0 -24
  426. package/lib/typescript/src/features/form/index.d.ts.map +0 -1
  427. package/lib/typescript/src/features/form/styles.d.ts +0 -35
  428. package/lib/typescript/src/features/form/styles.d.ts.map +0 -1
  429. package/lib/typescript/src/features/form/types.d.ts +0 -33
  430. package/lib/typescript/src/features/form/types.d.ts.map +0 -1
  431. package/lib/typescript/src/features/geo/api-hooks.d.ts +0 -12
  432. package/lib/typescript/src/features/geo/api-hooks.d.ts.map +0 -1
  433. package/lib/typescript/src/features/geo/types.d.ts +0 -13
  434. package/lib/typescript/src/features/geo/types.d.ts.map +0 -1
  435. package/lib/typescript/src/helpers/Config.d.ts +0 -24
  436. package/lib/typescript/src/helpers/Config.d.ts.map +0 -1
  437. package/lib/typescript/src/helpers/CountryCodes.d.ts +0 -16
  438. package/lib/typescript/src/helpers/CountryCodes.d.ts.map +0 -1
  439. package/lib/typescript/src/helpers/Debounced.d.ts +0 -2
  440. package/lib/typescript/src/helpers/Debounced.d.ts.map +0 -1
  441. package/lib/typescript/src/helpers/Domains.d.ts +0 -3
  442. package/lib/typescript/src/helpers/Domains.d.ts.map +0 -1
  443. package/lib/typescript/src/helpers/LocalStorage.d.ts +0 -27
  444. package/lib/typescript/src/helpers/LocalStorage.d.ts.map +0 -1
  445. package/lib/typescript/src/helpers/RefreshAccessToken.d.ts +0 -3
  446. package/lib/typescript/src/helpers/RefreshAccessToken.d.ts.map +0 -1
  447. package/lib/typescript/src/helpers/StringsHelper.d.ts +0 -3
  448. package/lib/typescript/src/helpers/StringsHelper.d.ts.map +0 -1
  449. package/lib/typescript/src/helpers/Validators.d.ts +0 -16
  450. package/lib/typescript/src/helpers/Validators.d.ts.map +0 -1
  451. package/lib/typescript/src/index.d.ts +0 -49
  452. package/lib/typescript/src/index.d.ts.map +0 -1
  453. package/lib/typescript/src/res/colors.d.ts +0 -16
  454. package/lib/typescript/src/res/colors.d.ts.map +0 -1
  455. package/lib/typescript/src/res/icons.d.ts +0 -13
  456. package/lib/typescript/src/res/icons.d.ts.map +0 -1
  457. package/lib/typescript/src/res/images.d.ts +0 -5
  458. package/lib/typescript/src/res/images.d.ts.map +0 -1
  459. package/lib/typescript/src/res/index.d.ts +0 -32
  460. package/lib/typescript/src/res/index.d.ts.map +0 -1
  461. package/lib/typescript/src/types/IAccountTickets.d.ts +0 -71
  462. package/lib/typescript/src/types/IAccountTickets.d.ts.map +0 -1
  463. package/lib/typescript/src/types/ICountry.d.ts +0 -2
  464. package/lib/typescript/src/types/ICountry.d.ts.map +0 -1
  465. package/lib/typescript/src/types/IError.d.ts +0 -6
  466. package/lib/typescript/src/types/IError.d.ts.map +0 -1
  467. package/lib/typescript/src/types/IEvent.d.ts +0 -87
  468. package/lib/typescript/src/types/IEvent.d.ts.map +0 -1
  469. package/lib/typescript/src/types/ITicket.d.ts +0 -71
  470. package/lib/typescript/src/types/ITicket.d.ts.map +0 -1
  471. package/lib/typescript/src/types/IUserProfile.d.ts +0 -30
  472. package/lib/typescript/src/types/IUserProfile.d.ts.map +0 -1
  473. package/lib/typescript/src/types/index.d.ts +0 -6
  474. package/lib/typescript/src/types/index.d.ts.map +0 -1
  475. package/lib/typescript/src/utils/Logger.d.ts +0 -21
  476. package/lib/typescript/src/utils/Logger.d.ts.map +0 -1
  477. package/lib/typescript/src/utils/handlers.d.ts +0 -9
  478. package/lib/typescript/src/utils/handlers.d.ts.map +0 -1
  479. package/lib/typescript/src/utils/storageAdapter.d.ts +0 -14
  480. package/lib/typescript/src/utils/storageAdapter.d.ts.map +0 -1
  481. package/lib/typescript/src/utils/styleUtils.d.ts +0 -18
  482. package/lib/typescript/src/utils/styleUtils.d.ts.map +0 -1
  483. package/src/api/ApiClient.ts +0 -1539
  484. package/src/api/Constants.ts +0 -10
  485. package/src/api/ErrorHandler.ts +0 -36
  486. package/src/api/api.types.ts +0 -8
  487. package/src/api/types.ts +0 -593
  488. package/src/apiv2/index.ts +0 -143
  489. package/src/assets/icons/ic_check.png +0 -0
  490. package/src/assets/icons/ic_clock.png +0 -0
  491. package/src/assets/icons/ic_copy.png +0 -0
  492. package/src/assets/icons/ic_dropdown.png +0 -0
  493. package/src/assets/icons/ic_error.png +0 -0
  494. package/src/assets/icons/ic_eye.png +0 -0
  495. package/src/assets/icons/ic_eye_off.png +0 -0
  496. package/src/assets/icons/ic_more.png +0 -0
  497. package/src/assets/icons/ic_next.png +0 -0
  498. package/src/assets/images/brand.png +0 -0
  499. package/src/common/query.types.ts +0 -6
  500. package/src/components/bottomSheetModal/BottomSheetModal.tsx +0 -95
  501. package/src/components/bottomSheetModal/BottomSheetModalStyles.ts +0 -43
  502. package/src/components/bottomSheetModal/BottomSheetModalTypes.ts +0 -26
  503. package/src/components/button/Button.tsx +0 -53
  504. package/src/components/button/styles.tsx +0 -30
  505. package/src/components/button/types.ts +0 -16
  506. package/src/components/cartTimer/CartTimer.tsx +0 -68
  507. package/src/components/cartTimer/styles.ts +0 -44
  508. package/src/components/cartTimer/types.ts +0 -22
  509. package/src/components/checkbox/Checkbox.tsx +0 -53
  510. package/src/components/checkbox/styles.ts +0 -41
  511. package/src/components/checkbox/types.ts +0 -23
  512. package/src/components/datePicker/DatePicker.tsx +0 -81
  513. package/src/components/datePicker/styles.ts +0 -39
  514. package/src/components/datePicker/types.ts +0 -21
  515. package/src/components/dropdown/Dropdown.tsx +0 -111
  516. package/src/components/dropdown/DropdownListItem.tsx +0 -36
  517. package/src/components/dropdown/styles.ts +0 -97
  518. package/src/components/dropdown/types.ts +0 -38
  519. package/src/components/dropdownMaterial/DropdownMaterial.tsx +0 -129
  520. package/src/components/dropdownMaterial/styles.ts +0 -91
  521. package/src/components/dropdownMaterial/types.ts +0 -24
  522. package/src/components/enterPassword/EnterPassword.tsx +0 -50
  523. package/src/components/enterPassword/styles.ts +0 -23
  524. package/src/components/enterPassword/types.ts +0 -27
  525. package/src/components/formField/FormField.tsx +0 -131
  526. package/src/components/formField/styles.ts +0 -37
  527. package/src/components/formField/types.ts +0 -60
  528. package/src/components/index.ts +0 -20
  529. package/src/components/input/Input.tsx +0 -77
  530. package/src/components/input/styles.ts +0 -53
  531. package/src/components/input/types.ts +0 -38
  532. package/src/components/loading/Loading.tsx +0 -30
  533. package/src/components/loading/styles.ts +0 -32
  534. package/src/components/loading/types.ts +0 -16
  535. package/src/components/loggedIn/LoggedIn.tsx +0 -60
  536. package/src/components/loggedIn/styles.ts +0 -9
  537. package/src/components/loggedIn/types.ts +0 -27
  538. package/src/components/login/Login.tsx +0 -161
  539. package/src/components/login/LoginView.tsx +0 -259
  540. package/src/components/login/components/LoginForm.tsx +0 -92
  541. package/src/components/login/components/types.ts +0 -22
  542. package/src/components/login/styles.ts +0 -63
  543. package/src/components/login/types.ts +0 -189
  544. package/src/components/phoneInput/PhoneInput.tsx +0 -72
  545. package/src/components/phoneInput/styles.ts +0 -31
  546. package/src/components/phoneInput/types.ts +0 -35
  547. package/src/components/promoCode/PromoCode.tsx +0 -111
  548. package/src/components/promoCode/styles.ts +0 -63
  549. package/src/components/promoCode/types.ts +0 -43
  550. package/src/components/radioButton/RadioButton.tsx +0 -26
  551. package/src/components/radioButton/styles.ts +0 -32
  552. package/src/components/radioButton/types.ts +0 -17
  553. package/src/components/radioGroup/RadioGroup.tsx +0 -86
  554. package/src/components/radioGroup/index.ts +0 -4
  555. package/src/components/radioGroup/types.ts +0 -26
  556. package/src/components/restorePassword/RestorePassword.tsx +0 -63
  557. package/src/components/restorePassword/ResultDialog.tsx +0 -26
  558. package/src/components/restorePassword/styles.ts +0 -38
  559. package/src/components/restorePassword/types.ts +0 -61
  560. package/src/components/separator/Separator.tsx +0 -26
  561. package/src/components/separator/types.ts +0 -9
  562. package/src/components/stripePayment/StripePayment.tsx +0 -51
  563. package/src/components/stripePayment/styles.ts +0 -7
  564. package/src/components/stripePayment/types.ts +0 -22
  565. package/src/components/waitingList/WaitingList.tsx +0 -147
  566. package/src/components/waitingList/WaitingListView.tsx +0 -94
  567. package/src/components/waitingList/styles.ts +0 -9
  568. package/src/components/waitingList/types.ts +0 -68
  569. package/src/containers/billingInfo/Billing.tsx +0 -1902
  570. package/src/containers/billingInfo/styles.ts +0 -64
  571. package/src/containers/billingInfo/types.ts +0 -217
  572. package/src/containers/checkout/Checkout.tsx +0 -519
  573. package/src/containers/checkout/CheckoutData.ts +0 -29
  574. package/src/containers/checkout/components/Conditions.tsx +0 -22
  575. package/src/containers/checkout/components/OrderReview.tsx +0 -31
  576. package/src/containers/checkout/components/styles.ts +0 -28
  577. package/src/containers/checkout/styles.ts +0 -44
  578. package/src/containers/checkout/types.ts +0 -148
  579. package/src/containers/index.ts +0 -8
  580. package/src/containers/myOrderDetails/MyOrderDetails.tsx +0 -318
  581. package/src/containers/myOrderDetails/MyOrderDetailsView.tsx +0 -269
  582. package/src/containers/myOrderDetails/components/Notification.tsx +0 -40
  583. package/src/containers/myOrderDetails/components/OrderListItem.tsx +0 -12
  584. package/src/containers/myOrderDetails/components/TicketActions/TicketActions.tsx +0 -68
  585. package/src/containers/myOrderDetails/components/TicketActions/TicketActionsTypes.ts +0 -41
  586. package/src/containers/myOrderDetails/components/TicketListItem/TicketListItem.tsx +0 -63
  587. package/src/containers/myOrderDetails/components/TicketListItem/TicketListItemStyles.ts +0 -33
  588. package/src/containers/myOrderDetails/components/TicketListItem/TicketListItemTypes.ts +0 -39
  589. package/src/containers/myOrderDetails/components/styles.ts +0 -42
  590. package/src/containers/myOrderDetails/styles.ts +0 -57
  591. package/src/containers/myOrderDetails/types.ts +0 -173
  592. package/src/containers/myOrders/MyOrders.tsx +0 -340
  593. package/src/containers/myOrders/MyOrdersView.tsx +0 -182
  594. package/src/containers/myOrders/components/OrderListItem.tsx +0 -50
  595. package/src/containers/myOrders/components/styles.ts +0 -55
  596. package/src/containers/myOrders/components/types.ts +0 -28
  597. package/src/containers/myOrders/styles.ts +0 -42
  598. package/src/containers/myOrders/types.ts +0 -84
  599. package/src/containers/purchaseConfirmation/PurchaseConfirmation.tsx +0 -145
  600. package/src/containers/purchaseConfirmation/PurchaseConfirmationView.tsx +0 -82
  601. package/src/containers/purchaseConfirmation/styles.ts +0 -79
  602. package/src/containers/purchaseConfirmation/types.ts +0 -77
  603. package/src/containers/resaleTickets/ResaleTickets.tsx +0 -234
  604. package/src/containers/resaleTickets/ResaleTicketsView.tsx +0 -314
  605. package/src/containers/resaleTickets/types.ts +0 -154
  606. package/src/containers/resetPassword/ResetPassword.tsx +0 -110
  607. package/src/containers/resetPassword/ResetPasswordView.tsx +0 -81
  608. package/src/containers/resetPassword/styles.ts +0 -35
  609. package/src/containers/resetPassword/types.ts +0 -56
  610. package/src/containers/tickets/Tickets.tsx +0 -525
  611. package/src/containers/tickets/TicketsView.tsx +0 -164
  612. package/src/containers/tickets/components/TicketGroupListHeader.tsx +0 -12
  613. package/src/containers/tickets/components/TicketListItem.tsx +0 -124
  614. package/src/containers/tickets/components/styles.ts +0 -54
  615. package/src/containers/tickets/components/types.ts +0 -47
  616. package/src/containers/tickets/styles.ts +0 -22
  617. package/src/containers/tickets/types.ts +0 -158
  618. package/src/core/BillingCore/BillingCore.tsx +0 -129
  619. package/src/core/BillingCore/BillingCoreTypes.ts +0 -34
  620. package/src/core/BillingCore/README.md +0 -22
  621. package/src/core/CheckoutCore/CheckoutCore.tsx +0 -113
  622. package/src/core/CheckoutCore/CheckoutCoreTypes.ts +0 -23
  623. package/src/core/CheckoutCore/README.md +0 -20
  624. package/src/core/CoreProps.ts +0 -5
  625. package/src/core/LoginCore/LoginCore.tsx +0 -140
  626. package/src/core/LoginCore/LoginCoreHelper.ts +0 -22
  627. package/src/core/LoginCore/LoginCoreTypes.ts +0 -21
  628. package/src/core/MIGRATION.md +0 -148
  629. package/src/core/MyOrdersCore/MyOrdersCore.tsx +0 -44
  630. package/src/core/MyOrdersCore/MyOrdersCoreTypes.ts +0 -15
  631. package/src/core/OrderDetailsCore/OrderDetailsCore.tsx +0 -36
  632. package/src/core/OrderDetailsCore/OrderDetailsCoreTypes.ts +0 -10
  633. package/src/core/PurchaseConfirmationCore/PurchaseConfirmationCore.tsx +0 -37
  634. package/src/core/PurchaseConfirmationCore/PurchaseConfirmationCoreTypes.ts +0 -10
  635. package/src/core/ResetPasswordCore/ResetPasswordCore.tsx +0 -21
  636. package/src/core/ResetPasswordCore/ResetPasswordCoreTypes.ts +0 -5
  637. package/src/core/Session/SessionCoreTypes.ts +0 -10
  638. package/src/core/Session/SessionHandle.tsx +0 -23
  639. package/src/core/TicketsCore/TicketsCore.tsx +0 -216
  640. package/src/core/TicketsCore/TicketsCoreTypes.ts +0 -52
  641. package/src/core/WaitingListCore/WaitingListCore.tsx +0 -35
  642. package/src/core/WaitingListCore/WaitingListCoreTypes.ts +0 -16
  643. package/src/core/index.ts +0 -20
  644. package/src/features/auth/api-hooks.ts +0 -61
  645. package/src/features/auth/types.ts +0 -54
  646. package/src/features/auth/utils.ts +0 -27
  647. package/src/features/checkout-v2/components/AddonsContainer.tsx +0 -159
  648. package/src/features/checkout-v2/components/Conditions.tsx +0 -144
  649. package/src/features/checkout-v2/components/OrderReview.tsx +0 -96
  650. package/src/features/checkout-v2/components/TicketHoldersSection.tsx +0 -131
  651. package/src/features/checkout-v2/form/config.tsx +0 -194
  652. package/src/features/checkout-v2/form/index.tsx +0 -830
  653. package/src/features/checkout-v2/form/styles.ts +0 -241
  654. package/src/features/checkout-v2/form/texts.ts +0 -133
  655. package/src/features/checkout-v2/form/types.ts +0 -231
  656. package/src/features/checkout-v2/hooks/api-hooks.ts +0 -332
  657. package/src/features/checkout-v2/hooks/use-checkout.ts +0 -927
  658. package/src/features/checkout-v2/index.tsx +0 -289
  659. package/src/features/checkout-v2/types.ts +0 -475
  660. package/src/features/checkout-v2/utils.ts +0 -156
  661. package/src/features/event/api-hooks.ts +0 -28
  662. package/src/features/event/types.ts +0 -69
  663. package/src/features/form/index.tsx +0 -185
  664. package/src/features/form/styles.ts +0 -37
  665. package/src/features/form/types.ts +0 -38
  666. package/src/features/geo/api-hooks.ts +0 -43
  667. package/src/features/geo/types.ts +0 -15
  668. package/src/helpers/Config.ts +0 -81
  669. package/src/helpers/CountryCodes.ts +0 -3382
  670. package/src/helpers/Debounced.ts +0 -27
  671. package/src/helpers/Domains.ts +0 -32
  672. package/src/helpers/LocalStorage.tsx +0 -152
  673. package/src/helpers/RefreshAccessToken.ts +0 -25
  674. package/src/helpers/StringsHelper.ts +0 -5
  675. package/src/helpers/Validators.ts +0 -108
  676. package/src/packages/rn-material-ui-textfield/README.md +0 -149
  677. package/src/packages/rn-material-ui-textfield/components/affix/index.js +0 -61
  678. package/src/packages/rn-material-ui-textfield/components/affix/styles.js +0 -8
  679. package/src/packages/rn-material-ui-textfield/components/counter/index.js +0 -36
  680. package/src/packages/rn-material-ui-textfield/components/counter/styles.js +0 -12
  681. package/src/packages/rn-material-ui-textfield/components/field/index.js +0 -700
  682. package/src/packages/rn-material-ui-textfield/components/field/styles.js +0 -42
  683. package/src/packages/rn-material-ui-textfield/components/field-filled/index.js +0 -21
  684. package/src/packages/rn-material-ui-textfield/components/field-filled/styles.js +0 -10
  685. package/src/packages/rn-material-ui-textfield/components/field-outlined/index.js +0 -59
  686. package/src/packages/rn-material-ui-textfield/components/helper/index.js +0 -78
  687. package/src/packages/rn-material-ui-textfield/components/helper/styles.js +0 -12
  688. package/src/packages/rn-material-ui-textfield/components/label/index.js +0 -123
  689. package/src/packages/rn-material-ui-textfield/components/label/styles.js +0 -16
  690. package/src/packages/rn-material-ui-textfield/components/line/index.js +0 -117
  691. package/src/packages/rn-material-ui-textfield/components/line/styles.js +0 -18
  692. package/src/packages/rn-material-ui-textfield/components/outline/index.js +0 -139
  693. package/src/packages/rn-material-ui-textfield/components/outline/styles.js +0 -83
  694. package/src/packages/rn-material-ui-textfield/index.d.ts +0 -53
  695. package/src/packages/rn-material-ui-textfield/index.js +0 -5
  696. package/src/packages/rn-material-ui-textfield/license.txt +0 -28
  697. package/src/res/colors.ts +0 -16
  698. package/src/res/icons.ts +0 -11
  699. package/src/res/images.ts +0 -3
  700. package/src/res/index.ts +0 -11
  701. package/src/types/IAccountTickets.ts +0 -75
  702. package/src/types/ICountry.ts +0 -2
  703. package/src/types/IError.ts +0 -5
  704. package/src/types/IEvent.ts +0 -87
  705. package/src/types/ITicket.ts +0 -75
  706. package/src/types/IUserProfile.ts +0 -30
  707. package/src/types/index.ts +0 -5
  708. package/src/utils/Logger.ts +0 -75
  709. package/src/utils/handlers.ts +0 -49
  710. package/src/utils/storageAdapter.ts +0 -44
  711. package/src/utils/styleUtils.ts +0 -76
@@ -0,0 +1,534 @@
1
+ import { Accommodation } from './Accommodation'
2
+ /**
3
+ * `<Payment/>` — order review + payment-method selection + T&C, then place the
4
+ * order. The RN analogue of the web `Payment` section. Buyer details come from
5
+ * `<BillingInfo/>` (read back off the shared checkout). The method list is built
6
+ * from the event's gateway + `ttf.cart.preOrderMethods()` + the priced snapshot,
7
+ * and each selection maps to the right `placeOrder` rail.
8
+ *
9
+ * Native adaptations vs web (all behaviour-preserving where the platform allows):
10
+ * - No Stripe Payment Element / wallet widget: web folds Apple/Google Pay into
11
+ * the Element. Native offers Apple/Google Pay as explicit rows only when
12
+ * the backend enables the wallet and Stripe confirms device support.
13
+ * - The card slot renders the native `<CardInput/>` (Stripe `<CardField/>`) for
14
+ * the Stripe card + payment-plan-new-card paths. Xendit card entry tokenizes
15
+ * in a WebView sheet (deferred in `confirmer.ts`), so the Xendit card row
16
+ * shows a note instead of a field; `placeOrder({method:'xenditCard'})` returns
17
+ * the typed unsupported-gateway error until that WebView port is injected.
18
+ * - Redirect rails / Razorpay / PayPal / Xendit e-wallets render their rows and
19
+ * call `placeOrder` with the mapped request; the WebView `providerPage` port
20
+ * that presents them is likewise a follow-up (see `confirmer.ts` header).
21
+ * - Conditions render as plain text (HTML stripped) — no DOM to inject markup.
22
+ */
23
+ import React, { useEffect, useMemo, useState, type FC } from 'react'
24
+ import { Platform, View } from 'react-native'
25
+ import { isPlatformPaySupported } from '@stripe/stripe-react-native'
26
+
27
+ import {
28
+ ConfirmerBusyError,
29
+ CardClaimError,
30
+ cardClaimStep,
31
+ CartChangedError,
32
+ XENDIT_EWALLET_EXTRA_FIELD,
33
+ cartTicketCount,
34
+ getConfig,
35
+ errorMessage,
36
+ htmlToPlainText,
37
+ missingCheckoutDetails,
38
+ paymentAcknowledgementsMet,
39
+ paymentPlanTerms,
40
+ planConfirmLabel,
41
+ planTermsTitle,
42
+ stripeOffersOxxo,
43
+ planUsesSavedCard,
44
+ type CheckoutPaymentPlanPreview,
45
+ type EventCondition,
46
+ type LocaleCode,
47
+ type Messages,
48
+ type Translate,
49
+ type PaymentRequest,
50
+ type PlaceOrderResult,
51
+ hooks,
52
+ createTranslator,
53
+ } from 'tf-checkout-shared'
54
+
55
+ import { CardInput, claimCardField } from '../CardInput'
56
+ import { rnConfirmer } from '../instance'
57
+ import { useCheckoutContext, useCheckoutValidation } from '../ui/CheckoutProvider'
58
+ import { Checkbox } from '../ui/Field'
59
+ import { PaymentMethods, type PaymentMethodOption } from '../ui/PaymentMethods'
60
+ import {
61
+ BodyText,
62
+ Button,
63
+ Card,
64
+ ErrorText,
65
+ Loader,
66
+ MutedText,
67
+ SectionHeader,
68
+ } from '../ui/primitives'
69
+ import { FrozenFields } from '../ui/Frozen'
70
+ import { OrderSummary } from './OrderSummary'
71
+
72
+
73
+ /** Server spellings → display labels for Stripe redirect rails. */
74
+ const REDIRECT_LABELS: Record<string, string> = {
75
+ klarna: 'Klarna',
76
+ afterpay_clearpay: 'Afterpay / Clearpay',
77
+ affirm: 'Affirm',
78
+ ideal: 'iDEAL',
79
+ bancontact: 'Bancontact',
80
+ eps: 'EPS',
81
+ giropay: 'giropay',
82
+ p24: 'Przelewy24',
83
+ alipay: 'Alipay',
84
+ grabpay: 'GrabPay',
85
+ cashapp: 'Cash App Pay',
86
+ paypal: 'PayPal',
87
+ }
88
+ const redirectLabel = (t: string) =>
89
+ REDIRECT_LABELS[t] ?? t.replace(/_/g, ' ').replace(/\b\w/g, (c) => c.toUpperCase())
90
+
91
+ /** Condition copy as one line of plain text: native has no DOM to render
92
+ * markup into, and the copy is a checkbox label. */
93
+ const conditionText = (html: string) => htmlToPlainText(html).replace(/\s*\n\s*/g, ' ')
94
+
95
+ export interface PaymentProps {
96
+ onComplete?: (order: PlaceOrderResult) => void
97
+ /** Optional event context (parity with web; native `OrderSummary` reads the
98
+ * priced cart, not the event, so it is currently unused here). */
99
+ eventId?: string
100
+ /** Must match the policy used by the paired `<BillingInfo/>`. */
101
+ requireEmailConfirmation?: boolean
102
+ /** Must match the holder policy used by the paired `<BillingInfo/>`. */
103
+ collectTicketHolders?: boolean
104
+ /** Must match the holder-contact policy used by the paired `<BillingInfo/>`. */
105
+ requireHolderContact?: boolean
106
+ /** Host-owned acknowledgements such as a brand privacy policy. */
107
+ additionalConditions?: EventCondition[]
108
+ /** Require the privacy checkbox managed by BillingInfo before payment. */
109
+ requirePrivacyPolicy?: boolean
110
+ /** Called when payment is attempted before required privacy consent. */
111
+ onPrivacyRequired?: () => void
112
+ /** Test card copy is useful in examples, but should never appear by default. */
113
+ showTestCardHint?: boolean
114
+ /** The language of the section's messages (en by default). */
115
+ locale?: LocaleCode
116
+ messages?: Partial<Messages>
117
+ translate?: Translate
118
+ }
119
+
120
+ /**
121
+ * Payment-plan terms — the full hosted disclosure block (schedule, admin fee,
122
+ * non-refundable clause, brand message, activation note). Composed in the SDK
123
+ * so this matches web word for word; these are disclosures, not summary copy.
124
+ */
125
+ const PlanTerms: FC<{ plan: CheckoutPaymentPlanPreview }> = ({ plan }) => {
126
+ const parts = paymentPlanTerms(plan)
127
+ if (parts.length === 0) return null
128
+ return (
129
+ <View style={{ gap: 4 }}>
130
+ <BodyText style={{ fontWeight: '700' }}>{planTermsTitle(plan)}</BodyText>
131
+ {parts.map((part) => (
132
+ <MutedText key={part.id}>{part.text}</MutedText>
133
+ ))}
134
+ </View>
135
+ )
136
+ }
137
+
138
+ export const Payment: FC<PaymentProps> = ({
139
+ onComplete,
140
+ // `eventId` is accepted for prop-parity with web; the native `OrderSummary`
141
+ // reads the priced cart (not the event), so it is intentionally unused here.
142
+ eventId,
143
+ requireEmailConfirmation = false,
144
+ collectTicketHolders = false,
145
+ requireHolderContact = false,
146
+ additionalConditions = [],
147
+ requirePrivacyPolicy = false,
148
+ onPrivacyRequired,
149
+ showTestCardHint = false,
150
+ locale,
151
+ messages,
152
+ translate,
153
+ }) => {
154
+ const t = translate ?? createTranslator({ locale, messages })
155
+ const checkout = useCheckoutContext()
156
+ // This checkout's own card field: another checkout on the page has its own.
157
+ const cardOwner = hooks.useTicketCardOwner()
158
+ // A bundle purchase holds the payment SDK: Pay would do nothing now.
159
+ // Why a bundle holds the payment SDK (paying, or setting up a card form).
160
+ const bundleWait = hooks.useTicketGatewayWait(checkout.store)
161
+ const bundleStarting = bundleWait !== null
162
+ const validation = useCheckoutValidation()
163
+ const [error, setError] = useState('')
164
+ const paymentMethods = hooks.useCheckoutPaymentMethods(checkout.store)
165
+ const methods = paymentMethods.data ?? null
166
+ const [selected, setSelected] = useState('')
167
+ const [extras, setExtras] = useState<
168
+ Record<string, { cashtag?: string; phoneNumber?: string }>
169
+ >({})
170
+ const [useSavedCard, setUseSavedCard] = useState(true)
171
+ const [nativeWalletSupported, setNativeWalletSupported] = useState(false)
172
+
173
+ useEffect(() => {
174
+ let mounted = true
175
+ const env = getConfig().env
176
+ isPlatformPaySupported({ googlePay: { testEnv: env === 'STAG' || env === 'DEV' } })
177
+ .then((supported) => {
178
+ if (mounted) setNativeWalletSupported(supported)
179
+ })
180
+ .catch(() => {
181
+ if (mounted) setNativeWalletSupported(false)
182
+ })
183
+ return () => {
184
+ mounted = false
185
+ }
186
+ }, [])
187
+
188
+
189
+
190
+ const bd = checkout.breakdown
191
+ const isFree = bd !== undefined && Number(bd.total) === 0
192
+ const isXendit = checkout.gateway === 'xendit'
193
+ const offersOxxo = stripeOffersOxxo(checkout.stripeElementsConfig)
194
+
195
+ // Build the selectable method rows from gateway + probe + snapshot.
196
+ const options = useMemo<PaymentMethodOption[]>(() => {
197
+ if (isFree || !methods) return []
198
+ const out: PaymentMethodOption[] = []
199
+ if (isXendit) {
200
+ if (methods.xenditCard)
201
+ out.push({ id: { kind: 'xenditCard' }, value: 'xenditCard', label: 'Card' })
202
+ for (const w of methods.xenditEWallets)
203
+ out.push({
204
+ id: { kind: 'xenditEWallet', walletKey: w.key },
205
+ value: `ew:${w.key}`,
206
+ label: w.label,
207
+ iconUrl: w.icon,
208
+ extra: (XENDIT_EWALLET_EXTRA_FIELD[w.key] as 'cashtag' | 'phoneNumber') ?? null,
209
+ })
210
+ } else if (checkout.gateway === 'razorpay') {
211
+ out.push({ id: { kind: 'razorpay' }, value: 'razorpay', label: 'Razorpay' })
212
+ } else if (checkout.gateway === 'adyen') {
213
+ out.push({ id: { kind: 'adyen' }, value: 'adyen', label: 'Adyen' })
214
+ } else {
215
+ // Stripe (or unknown → fail open to card).
216
+ out.push({ id: { kind: 'card' }, value: 'card', label: 'Credit or debit card' })
217
+ // A device wallet is offered only when Stripe's server configuration AND
218
+ // the current device allow it. Never infer availability from the OS alone.
219
+ if (
220
+ nativeWalletSupported &&
221
+ checkout.walletAvailability?.applePay &&
222
+ Platform.OS === 'ios'
223
+ )
224
+ out.push({ id: { kind: 'applePay' }, value: 'applePay', label: 'Apple Pay' })
225
+ if (
226
+ nativeWalletSupported &&
227
+ checkout.walletAvailability?.googlePay &&
228
+ Platform.OS === 'android'
229
+ )
230
+ out.push({ id: { kind: 'googlePay' }, value: 'googlePay', label: 'Google Pay' })
231
+ for (const t of checkout.redirectPaymentMethods ?? []) {
232
+ if (t === 'paypal' && methods.paypal) continue // dedupe vs PayPal Standard
233
+ out.push({
234
+ id: { kind: 'redirect', methodType: t },
235
+ value: `rd:${t}`,
236
+ label: redirectLabel(t),
237
+ })
238
+ }
239
+ if (checkout.paymentPlan?.available)
240
+ out.push({
241
+ id: { kind: 'paymentPlan' },
242
+ value: 'paymentPlan',
243
+ label: 'Payment plan',
244
+ })
245
+ // The server applies merchant, event, date and capture restrictions.
246
+ if (offersOxxo)
247
+ out.push({ id: { kind: 'oxxo' }, value: 'oxxo', label: 'OXXO (pay in cash)' })
248
+ }
249
+ if (methods.paypal)
250
+ out.push({ id: { kind: 'paypal' }, value: 'paypal', label: 'PayPal' })
251
+ return out
252
+ }, [
253
+ isFree,
254
+ methods,
255
+ isXendit,
256
+ checkout.gateway,
257
+ checkout.redirectPaymentMethods,
258
+ checkout.paymentPlan,
259
+ checkout.breakdown,
260
+ checkout.walletAvailability,
261
+ nativeWalletSupported,
262
+ offersOxxo,
263
+ ])
264
+
265
+ // Default the selection to the first row once options exist.
266
+ useEffect(() => {
267
+ if (options.length && !options.some((o) => o.value === selected))
268
+ setSelected(options[0].value)
269
+ }, [options, selected])
270
+
271
+ const cardValue = isXendit ? 'xenditCard' : 'card'
272
+ const selectedOption = options.find((o) => o.value === selected)
273
+ const isCardSelected = selected === cardValue
274
+ const isPlanSelected = selectedOption?.id.kind === 'paymentPlan'
275
+ const savedLast4 = methods?.savedPlanCardLast4
276
+ const reuseSavedCard = planUsesSavedCard(savedLast4, useSavedCard)
277
+ // The native Stripe card field: shown for the Stripe card path and for a
278
+ // payment-plan NEW card (SetupIntent). Xendit card is a WebView sheet (below).
279
+ const showStripeCardField =
280
+ !isXendit && (isCardSelected || (isPlanSelected && !reuseSavedCard))
281
+ const showXenditCardNote = isXendit && isCardSelected
282
+ // One card form at a time owns the shared payment SDK (bundles and tickets
283
+ // alike): while another one does, this form offers "Continue paying here".
284
+ const ticketCard = hooks.useTicketCardForm({
285
+ confirmer: rnConfirmer,
286
+ store: checkout.store,
287
+ owner: cardOwner,
288
+ showsStripeField: showStripeCardField && !isFree,
289
+ })
290
+
291
+ // When there's only ONE way to pay and it's a card, there's nothing to
292
+ // *choose* — render the field directly, no radio wrapper (matching web).
293
+ const onlyOption = options.length === 1 ? options[0] : undefined
294
+ const singleCard =
295
+ onlyOption?.id.kind === 'card' || onlyOption?.id.kind === 'xenditCard'
296
+
297
+ // Gating: buyer + every configured holder/custom field complete, required
298
+ // conditions accepted, and payment-method extras filled.
299
+ const b = checkout.billing
300
+ const missingDetails = missingCheckoutDetails(
301
+ {
302
+ billing: b,
303
+ holders: checkout.holders,
304
+ selections: checkout.selections,
305
+ breakdown: checkout.breakdown,
306
+ holderNamesRequired: checkout.holderNamesRequired,
307
+ fieldGates: checkout.fieldGates,
308
+ customFields: checkout.customFields,
309
+ },
310
+ { requireEmailConfirmation, collectTicketHolders, requireHolderContact }
311
+ )
312
+ const billingReady = missingDetails.length === 0
313
+ const conditions = [...(checkout.conditions ?? []), ...additionalConditions]
314
+ const { conditionsOk, privacyOk } = paymentAcknowledgementsMet({
315
+ eventConditions: checkout.conditions,
316
+ additionalConditions,
317
+ acceptedConditions: checkout.acceptedConditions,
318
+ requirePrivacyPolicy,
319
+ privacyAccepted: checkout.consent.ttfOptIn,
320
+ })
321
+ const extra = selectedOption?.extra
322
+ const extrasOk =
323
+ !extra ||
324
+ (extra === 'cashtag'
325
+ ? Boolean(extras[selected]?.cashtag?.trim())
326
+ : Boolean(extras[selected]?.phoneNumber?.trim()))
327
+ // The plan CTA carries the brand's terminology ("Confirm Layaway"), and the
328
+ // terms sentence quotes this same label — they must agree.
329
+ const payLabel = isFree
330
+ ? 'Complete Registration'
331
+ : isPlanSelected
332
+ ? planConfirmLabel(checkout.paymentPlan?.configuration)
333
+ : 'Submit Payment'
334
+ // 'placing' → order in flight; 'succeeded' → placed, host navigating away.
335
+ // Both keep the CTA busy so it can't be re-clicked during the handoff.
336
+ const finalizing = checkout.status === 'placing' || checkout.status === 'succeeded'
337
+
338
+ const pay = () => {
339
+ setError('')
340
+ if (!billingReady || !conditionsOk || !extrasOk || !privacyOk) {
341
+ if (!privacyOk) onPrivacyRequired?.()
342
+ validation.requestValidation()
343
+ return
344
+ }
345
+ // This checkout's own card field is claimed inside the confirmer gateway,
346
+ // together with the order, so a bundle holding the payment SDK never
347
+ // loses its field to a click that cannot proceed.
348
+ const usesOwnCardField = showStripeCardField && !isFree
349
+ // Backfill one holder per ticket if billing was set without holders.
350
+ if (checkout.holders.length === 0 && b) {
351
+ const n = cartTicketCount(checkout)
352
+ // Marked as filled in, not entered: a guardian's signature may count
353
+ // under the buyer's name only on these (`holderBackfilledFrom`).
354
+ checkout.setHolders(
355
+ Array.from({ length: n }, () => ({
356
+ firstName: b.firstName,
357
+ lastName: b.lastName,
358
+ email: b.email,
359
+ })),
360
+ { backfilled: true }
361
+ )
362
+ }
363
+ let req: PaymentRequest = { method: 'auto' }
364
+ const id = selectedOption?.id
365
+ if (isFree || !id) req = { method: 'auto' }
366
+ else if (id.kind === 'xenditEWallet')
367
+ req = { method: 'xenditEWallet', walletKey: id.walletKey, extra: extras[selected] }
368
+ else if (id.kind === 'redirect')
369
+ req = { method: 'redirect', methodType: id.methodType }
370
+ else if (id.kind === 'paymentPlan') req = { method: 'paymentPlan', useSavedCard: reuseSavedCard }
371
+ else req = { method: id.kind } as PaymentRequest
372
+ // Called synchronously in the press handler — popup rails (e-wallet,
373
+ // redirect, razorpay, paypal) want the user gesture on their WebView host.
374
+ // `placeOrder` runs in the confirmer gateway, so a bundle or another
375
+ // checkout cannot point the one payment SDK elsewhere mid-order. It still
376
+ // starts inside this press.
377
+ // The card field is claimed inside the order, after the payment SDK holds
378
+ // the ticket order's keys and right before the card is confirmed. Whether
379
+ // a key change empties the field is decided in shared (`cardClaimStep`).
380
+ checkout
381
+ .placeOrder(
382
+ req,
383
+ usesOwnCardField
384
+ ? {
385
+ claimCard: cardClaimStep('nativeCard', () => claimCardField(cardOwner)),
386
+ }
387
+ : undefined
388
+ )
389
+ .then((order) => onComplete?.(order))
390
+ // Cart ownership and native field ownership each fail before a charge.
391
+ .catch((e) =>
392
+ setError(
393
+ e instanceof CartChangedError
394
+ ? t('checkout.error.cartChanged')
395
+ : e instanceof CardClaimError || e instanceof ConfirmerBusyError
396
+ ? createTranslator()(e.message)
397
+ : errorMessage(e)
398
+ )
399
+ )
400
+ }
401
+
402
+ // A card claim stores its translation key; a server message passes through.
403
+ const checkoutError = checkout.error ? createTranslator()(checkout.error) : ''
404
+
405
+ // The card/plan field + its note + plan terms. Rendered inside the selected
406
+ // method row when there's a choice, or directly when there's only a card.
407
+ const testHint = isXendit
408
+ ? 'Test card: 4000 0000 0000 0002 · any future date · any CVC'
409
+ : 'Test card: 4242 4242 4242 4242 · any future date · any CVC'
410
+ const paymentInput = (
411
+ <>
412
+ {showStripeCardField && ticketCard.cardElsewhere ? (
413
+ <>
414
+ <MutedText>{createTranslator()('bundles.payingElsewhere')}</MutedText>
415
+ <Button variant="ghost" onPress={ticketCard.payHere}>
416
+ {createTranslator()('bundles.payHere')}
417
+ </Button>
418
+ </>
419
+ ) : showStripeCardField ? (
420
+ <CardInput owner={cardOwner} />
421
+ ) : null}
422
+ {showXenditCardNote ? (
423
+ // Xendit card tokenizes in a WebView sheet (deferred — see confirmer.ts).
424
+ <MutedText>
425
+ Card details are entered in a secure Xendit window when you pay.
426
+ </MutedText>
427
+ ) : null}
428
+ {showTestCardHint && (showStripeCardField || showXenditCardNote) ? (
429
+ <MutedText>{testHint}</MutedText>
430
+ ) : null}
431
+ {isPlanSelected && checkout.paymentPlan?.configuration ? (
432
+ <PlanTerms plan={checkout.paymentPlan.configuration} />
433
+ ) : null}
434
+ {/* Returning plan buyer with a reusable card on file. Ticked by default,
435
+ and when it stays ticked the card field never mounts — the plan is
436
+ created straight off the saved payment method, like the hosted flow. */}
437
+ {isPlanSelected && savedLast4 ? (
438
+ <View style={{ gap: 4 }}>
439
+ <MutedText>
440
+ Your payment will proceed with the card ending in **** {savedLast4}
441
+ </MutedText>
442
+ <Checkbox
443
+ checked={useSavedCard}
444
+ onChange={setUseSavedCard}
445
+ label="Use this card"
446
+ />
447
+ </View>
448
+ ) : null}
449
+ </>
450
+ )
451
+
452
+ return (
453
+ <View style={{ gap: 12 }}>
454
+ {checkout.eventId && <Accommodation eventId={checkout.eventId} />}
455
+ <Card>
456
+ <SectionHeader title="Payment" />
457
+
458
+ {/* Payment method */}
459
+ {!isFree ? (
460
+ <>
461
+ {!singleCard ? <MutedText>Payment method</MutedText> : null}
462
+ {!methods ? (
463
+ <Loader />
464
+ ) : singleCard ? (
465
+ paymentInput
466
+ ) : (
467
+ <PaymentMethods
468
+ options={options}
469
+ selected={selected}
470
+ onSelect={setSelected}
471
+ extraValues={extras}
472
+ onExtraChange={(v, patch) =>
473
+ setExtras((s) => ({ ...s, [v]: { ...s[v], ...patch } }))
474
+ }
475
+ showValidation={validation.attempt > 0}
476
+ inputSlotFor={
477
+ isPlanSelected ? (reuseSavedCard ? undefined : 'paymentPlan') : cardValue
478
+ }
479
+ >
480
+ {paymentInput}
481
+ </PaymentMethods>
482
+ )}
483
+ </>
484
+ ) : null}
485
+
486
+ {/* Conditions */}
487
+ {conditions.map((c) => {
488
+ const invalid =
489
+ validation.attempt > 0 && c.isRequired && !checkout.acceptedConditions?.[c.id]
490
+ return (
491
+ <View key={c.id} style={{ gap: 4 }}>
492
+ <FrozenFields frozen={checkout.orderFixed}>
493
+ <Checkbox
494
+ checked={Boolean(checkout.acceptedConditions?.[c.id])}
495
+ invalid={invalid}
496
+ onChange={(next) => checkout.acceptCondition(c.id, next)}
497
+ label={`${conditionText(c.content || c.name)}${c.isRequired ? ' *' : ''}`}
498
+ />
499
+ </FrozenFields>
500
+ {invalid ? (
501
+ <ErrorText>You must accept this condition to continue.</ErrorText>
502
+ ) : null}
503
+ </View>
504
+ )
505
+ })}
506
+ </Card>
507
+
508
+ {!isFree && paymentMethods.error ? <Card><ErrorText>{paymentMethods.error.message}</ErrorText><Button onPress={()=>void paymentMethods.refetch()}>Try again</Button></Card> : null}
509
+ <OrderSummary />
510
+
511
+ <Button
512
+ onPress={() => pay()}
513
+ // Stay busy through 'succeeded' too: in redirect mode the checkout
514
+ // remains mounted while the host navigates away, so the button must not
515
+ // flip back to a clickable state before the redirect lands.
516
+ loading={finalizing}
517
+ disabled={
518
+ checkout.isBusy ||
519
+ finalizing ||
520
+ bundleStarting ||
521
+ ticketCard.cardElsewhere ||
522
+ (!isFree && !methods)
523
+ }
524
+ >
525
+ {finalizing ? 'Placing…' : payLabel}
526
+ </Button>
527
+ {bundleStarting ? (
528
+ <MutedText>{createTranslator()(bundleWait ?? 'tickets.waitBundle')}</MutedText>
529
+ ) : null}
530
+
531
+ {error || checkoutError ? <ErrorText>{error || checkoutError}</ErrorText> : null}
532
+ </View>
533
+ )
534
+ }
@@ -0,0 +1,122 @@
1
+ import React, { type ReactNode } from 'react'
2
+ import { Pressable, StyleSheet, Text, View } from 'react-native'
3
+ import { hooks, type WordPostReactionFlow } from 'tf-checkout-shared'
4
+ import { useAccountT } from '../ui/useAccountT'
5
+
6
+ export interface PostReactionControlsProps {
7
+ flow: WordPostReactionFlow
8
+ onSignIn?: () => void
9
+ renderIcon?: (choice: 'up' | 'down') => ReactNode
10
+ translate?: (english: string) => string
11
+ showFeedback?: boolean
12
+ }
13
+
14
+ /** Native hosts may supply their own icon assets without introducing a native dependency. */
15
+ export const PostReactionControls = ({
16
+ flow,
17
+ onSignIn,
18
+ renderIcon,
19
+ translate,
20
+ showFeedback = true,
21
+ }: PostReactionControlsProps) => {
22
+ const accountT = useAccountT()
23
+ const t = translate ?? accountT
24
+ const unavailable = flow.signedIn && !flow.query.data
25
+ return (
26
+ <View style={styles.root}>
27
+ <View style={styles.buttons} accessibilityLabel={t('Article reaction')}>
28
+ {(['up', 'down'] as const).map((choice) => (
29
+ <Pressable
30
+ key={choice}
31
+ accessibilityRole="button"
32
+ accessibilityLabel={t(choice === 'up' ? 'Like article' : 'Dislike article')}
33
+ accessibilityState={{
34
+ selected: flow.reaction === choice,
35
+ disabled: flow.busy || unavailable,
36
+ }}
37
+ disabled={flow.busy || unavailable}
38
+ style={[
39
+ styles.button,
40
+ flow.reaction === choice && styles.selected,
41
+ (flow.busy || unavailable) && styles.disabled,
42
+ ]}
43
+ onPress={() =>
44
+ flow.signedIn ? void flow.toggleReaction(choice) : onSignIn?.()
45
+ }
46
+ >
47
+ {renderIcon ? (
48
+ renderIcon(choice)
49
+ ) : (
50
+ <Text style={styles.icon}>{choice === 'up' ? '👍' : '👎'}</Text>
51
+ )}
52
+ </Pressable>
53
+ ))}
54
+ </View>
55
+ {showFeedback && <PostReactionFeedback flow={flow} translate={translate} />}
56
+ </View>
57
+ )
58
+ }
59
+
60
+ export const PostReactionFeedback = ({
61
+ flow,
62
+ translate,
63
+ }: Pick<PostReactionControlsProps, 'flow' | 'translate'>) => {
64
+ const accountT = useAccountT()
65
+ const t = translate ?? accountT
66
+ return (
67
+ <>
68
+ {flow.busy && (
69
+ <Text style={styles.message} accessibilityLiveRegion="polite">
70
+ {t('Saving reaction…')}
71
+ </Text>
72
+ )}
73
+ {(flow.error || flow.query.error) && (
74
+ <View style={styles.error}>
75
+ <Text style={styles.message} accessibilityRole="alert">
76
+ {t(
77
+ flow.error ||
78
+ flow.query.error?.message ||
79
+ 'Your reaction could not be saved. Please try again.'
80
+ )}
81
+ </Text>
82
+ <Pressable
83
+ accessibilityRole="button"
84
+ disabled={flow.busy}
85
+ onPress={() => void flow.retry()}
86
+ >
87
+ <Text style={styles.retry}>{t('Try again')}</Text>
88
+ </Pressable>
89
+ </View>
90
+ )}
91
+ </>
92
+ )
93
+ }
94
+
95
+ export const PostReaction = ({
96
+ postId,
97
+ ...props
98
+ }: Omit<PostReactionControlsProps, 'flow'> & { postId: string | number }) => {
99
+ const flow = hooks.useWordPostReaction(postId)
100
+ return <PostReactionControls {...props} flow={flow} />
101
+ }
102
+
103
+ const styles = StyleSheet.create({
104
+ root: { gap: 8 },
105
+ buttons: { flexDirection: 'row', gap: 8 },
106
+ button: {
107
+ width: 42,
108
+ height: 42,
109
+ borderRadius: 999,
110
+ alignItems: 'center',
111
+ justifyContent: 'center',
112
+ backgroundColor: 'rgba(11,10,21,.6)',
113
+ borderWidth: 1,
114
+ borderColor: 'rgba(196,181,255,.12)',
115
+ },
116
+ selected: { backgroundColor: '#6040B8', borderColor: '#C4B5FF' },
117
+ disabled: { opacity: 0.5 },
118
+ icon: { fontSize: 18 },
119
+ message: { color: '#BBBFF4', fontSize: 13 },
120
+ error: { gap: 6, maxWidth: 260 },
121
+ retry: { color: '#C4B5FF', textDecorationLine: 'underline' },
122
+ })