@justifi/webcomponents 6.5.1-rc.3 → 6.5.1-rc.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 (524) hide show
  1. package/dist/cjs/{GooglePay-40aEKdDF.js → Refund-Blquw3jZ.js} +0 -446
  2. package/dist/cjs/bank-account-document-form-inputs_6.cjs.entry.js +4 -5
  3. package/dist/cjs/bank-account-form.cjs.entry.js +2 -2
  4. package/dist/cjs/{business.service-BggHdPOV.js → business.service-DrBmfEbR.js} +1 -1
  5. package/dist/cjs/card-form.cjs.entry.js +2 -2
  6. package/dist/cjs/{check-pkg-version-DuPkU5qI.js → check-pkg-version-T54BeR4n.js} +2 -2
  7. package/dist/cjs/{checkout.service-BUcIs9az.js → checkout.service-BEU6CI0t.js} +1 -1
  8. package/dist/cjs/checkout.store-BA6h-dp2.js +107 -0
  9. package/dist/cjs/checkouts-list-core.cjs.entry.js +2 -3
  10. package/dist/cjs/custom-popper.cjs.entry.js +2 -2
  11. package/dist/cjs/{dispute.service-CxWqivLc.js → dispute.service-c0CZxPpe.js} +1 -1
  12. package/dist/cjs/form-control-checkbox.cjs.entry.js +2 -2
  13. package/dist/cjs/form-control-date.cjs.entry.js +2 -2
  14. package/dist/cjs/form-control-file-v2_2.cjs.entry.js +3 -3
  15. package/dist/cjs/form-control-monetary.cjs.entry.js +2 -2
  16. package/dist/cjs/form-control-number-masked_3.cjs.entry.js +2 -2
  17. package/dist/cjs/form-control-number.cjs.entry.js +2 -2
  18. package/dist/cjs/form-control-radio.cjs.entry.js +2 -2
  19. package/dist/cjs/form-control-select_3.cjs.entry.js +4 -4
  20. package/dist/cjs/{get-payment-details-D_dDxsPG.js → get-payment-details-D8UQRtX1.js} +2 -2
  21. package/dist/cjs/{get-subaccounts-_D9lzD5O.js → get-subaccounts-fKcKqvrx.js} +2 -2
  22. package/dist/cjs/gross-payment-chart-core.cjs.entry.js +1 -1
  23. package/dist/cjs/hidden-input_2.cjs.entry.js +5 -5
  24. package/dist/cjs/{index-CajjbB9t.js → index-C2ITzalN.js} +0 -1
  25. package/dist/cjs/index.cjs.js +1 -1
  26. package/dist/cjs/internal-tokenize-payment-method_7.cjs.entry.js +23 -22
  27. package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +5 -6
  28. package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +2 -3
  29. package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +8 -8
  30. package/dist/cjs/{justifi-apple-pay_8.cjs.entry.js → justifi-apple-pay_7.cjs.entry.js} +253 -1124
  31. package/dist/cjs/justifi-bank-account-billing-form-simple_3.cjs.entry.js +2 -2
  32. package/dist/cjs/justifi-business-details.cjs.entry.js +4 -5
  33. package/dist/cjs/justifi-business-form.cjs.entry.js +4 -5
  34. package/dist/cjs/justifi-checkout.cjs.entry.js +15 -14
  35. package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +9 -10
  36. package/dist/cjs/justifi-checkouts-list.cjs.entry.js +7 -8
  37. package/dist/cjs/justifi-dispute-management-core.cjs.entry.js +1 -1
  38. package/dist/cjs/justifi-dispute-management.cjs.entry.js +5 -6
  39. package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +8 -9
  40. package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +3 -4
  41. package/dist/cjs/justifi-order-terminals.cjs.entry.js +9 -10
  42. package/dist/cjs/justifi-owner-form_3.cjs.entry.js +2 -3
  43. package/dist/cjs/justifi-payment-details.cjs.entry.js +5 -6
  44. package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +4 -5
  45. package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +6 -7
  46. package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +2 -2
  47. package/dist/cjs/justifi-payments-list.cjs.entry.js +6 -7
  48. package/dist/cjs/justifi-payout-details.cjs.entry.js +5 -6
  49. package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +6 -7
  50. package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +2 -2
  51. package/dist/cjs/justifi-payouts-list.cjs.entry.js +7 -8
  52. package/dist/cjs/justifi-refund-payment.cjs.entry.js +9 -10
  53. package/dist/cjs/justifi-saved-payment-method.cjs.entry.js +1 -1
  54. package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +8 -7
  55. package/dist/cjs/justifi-skeleton.cjs.entry.js +1 -1
  56. package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +11 -12
  57. package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +6 -7
  58. package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +7 -8
  59. package/dist/cjs/justifi-terminals-list.cjs.entry.js +7 -8
  60. package/dist/cjs/justifi-tokenize-payment-method.cjs.entry.js +1 -1
  61. package/dist/cjs/loader.cjs.js +1 -1
  62. package/dist/cjs/{package-C6nOTkVV.js → package-JstJdxIu.js} +1 -1
  63. package/dist/cjs/pagination-menu.cjs.entry.js +3 -3
  64. package/dist/cjs/payment-details-core.cjs.entry.js +10 -11
  65. package/dist/cjs/payment-method-option.cjs.entry.js +1 -1
  66. package/dist/cjs/{payment.service-wWZTmyFv.js → payment.service-DXbR13Kq.js} +1 -1
  67. package/dist/cjs/payments-list-core.cjs.entry.js +2 -3
  68. package/dist/cjs/payout-details-core.cjs.entry.js +3 -3
  69. package/dist/cjs/{payout.service-CWAem5VG.js → payout.service-D0U6kzXJ.js} +1 -1
  70. package/dist/cjs/payouts-list-core.cjs.entry.js +2 -3
  71. package/dist/cjs/table-filters-menu.cjs.entry.js +1 -1
  72. package/dist/cjs/terminal-orders-list-core.cjs.entry.js +3 -4
  73. package/dist/cjs/{terminal-orders-table-DBNG4K5I.js → terminal-orders-table-BByfBAEK.js} +3 -3
  74. package/dist/cjs/terminal-quantity-selector.cjs.entry.js +1 -1
  75. package/dist/cjs/{terminal.service-DSlqCGxE.js → terminal.service-BqXeiERV.js} +1 -1
  76. package/dist/cjs/terminals-list-core.cjs.entry.js +2 -3
  77. package/dist/cjs/webcomponents.cjs.js +1 -1
  78. package/dist/collection/api/index.js +0 -2
  79. package/dist/collection/collection-manifest.json +0 -1
  80. package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +2 -2
  81. package/dist/collection/components/checkout/card-form/card-form.js +2 -2
  82. package/dist/collection/components/checkout/checkout.js +2 -2
  83. package/dist/collection/components/checkout/save-new-payment-method.js +1 -1
  84. package/dist/collection/components/checkout/saved-payment-method.js +1 -1
  85. package/dist/collection/components/checkouts-list/checkouts-list-core.js +1 -1
  86. package/dist/collection/components/checkouts-list/checkouts-list-filters.js +1 -1
  87. package/dist/collection/components/checkouts-list/checkouts-list.js +1 -1
  88. package/dist/collection/components/dispute-management/dispute-management-core.js +1 -1
  89. package/dist/collection/components/dispute-management/dispute-management.js +1 -1
  90. package/dist/collection/components/dispute-management/dispute-notification.js +2 -2
  91. package/dist/collection/components/dispute-management/dispute-response/additional-statement.js +1 -1
  92. package/dist/collection/components/dispute-management/dispute-response/cancellation-policy.js +1 -1
  93. package/dist/collection/components/dispute-management/dispute-response/customer-details.js +1 -1
  94. package/dist/collection/components/dispute-management/dispute-response/dispute-response-core.js +1 -1
  95. package/dist/collection/components/dispute-management/dispute-response/dispute-response.js +1 -1
  96. package/dist/collection/components/dispute-management/dispute-response/duplicate-charge.js +1 -1
  97. package/dist/collection/components/dispute-management/dispute-response/electronic-evidence.js +1 -1
  98. package/dist/collection/components/dispute-management/dispute-response/product-or-service.js +1 -1
  99. package/dist/collection/components/dispute-management/dispute-response/refund-policy.js +1 -1
  100. package/dist/collection/components/dispute-management/dispute-response/shipping-details.js +1 -1
  101. package/dist/collection/components/filters/table-filters-menu.js +1 -1
  102. package/dist/collection/components/gross-payment-chart/gross-payment-chart-core.js +1 -1
  103. package/dist/collection/components/modular-checkout/ModularCheckout.js +0 -1
  104. package/dist/collection/components/modular-checkout/modular-checkout.js +6 -44
  105. package/dist/collection/components/modular-checkout/sub-components/bank-account-billing-form-simple.js +1 -1
  106. package/dist/collection/components/modular-checkout/sub-components/bank-account.js +2 -2
  107. package/dist/collection/components/modular-checkout/sub-components/card-billing-form-simple.js +1 -1
  108. package/dist/collection/components/modular-checkout/sub-components/card-form.js +2 -2
  109. package/dist/collection/components/modular-checkout/sub-components/payment-method-option.js +1 -1
  110. package/dist/collection/components/modular-checkout/sub-components/summary.js +1 -1
  111. package/dist/collection/components/order-terminals/order-terminals.js +1 -1
  112. package/dist/collection/components/order-terminals/terminal-quantity-selector/terminal-quantity-selector.js +1 -1
  113. package/dist/collection/components/payment-details/payment-details-core.js +8 -8
  114. package/dist/collection/components/payment-transactions-list/payment-transactions-list.js +1 -1
  115. package/dist/collection/components/payments-list/payments-list-core.js +1 -1
  116. package/dist/collection/components/payments-list/payments-list-filters.js +2 -2
  117. package/dist/collection/components/payments-list/payments-list.js +1 -1
  118. package/dist/collection/components/payout-details/payout-details-core.js +3 -3
  119. package/dist/collection/components/payout-transactions-list/payout-transactions-list.js +1 -1
  120. package/dist/collection/components/payouts-list/payouts-list-core.js +1 -1
  121. package/dist/collection/components/payouts-list/payouts-list-filters.js +2 -2
  122. package/dist/collection/components/payouts-list/payouts-list.js +1 -1
  123. package/dist/collection/components/terminal-orders-list/terminal-orders-list-core.js +1 -1
  124. package/dist/collection/components/terminal-orders-list/terminal-orders-list-filters.js +2 -2
  125. package/dist/collection/components/terminal-orders-list/terminal-orders-list.js +1 -1
  126. package/dist/collection/components/terminals-list/terminals-list-core.js +1 -1
  127. package/dist/collection/components/terminals-list/terminals-list-filters.js +1 -1
  128. package/dist/collection/components/terminals-list/terminals-list.js +1 -1
  129. package/dist/collection/components/tokenize-payment-method/internal-tokenize-payment-method.js +1 -1
  130. package/dist/collection/components/tokenize-payment-method/tokenize-payment-method.js +1 -1
  131. package/dist/collection/store/checkout.store.js +0 -4
  132. package/dist/collection/ui-components/custom-popper/custom-popper.js +2 -2
  133. package/dist/collection/ui-components/form/form-control-checkbox.js +2 -2
  134. package/dist/collection/ui-components/form/form-control-date.js +2 -2
  135. package/dist/collection/ui-components/form/form-control-file-v2.js +1 -1
  136. package/dist/collection/ui-components/form/form-control-file.js +2 -2
  137. package/dist/collection/ui-components/form/form-control-monetary.js +2 -2
  138. package/dist/collection/ui-components/form/form-control-number-masked.js +2 -2
  139. package/dist/collection/ui-components/form/form-control-number.js +2 -2
  140. package/dist/collection/ui-components/form/form-control-radio.js +2 -2
  141. package/dist/collection/ui-components/form/form-control-select.js +2 -2
  142. package/dist/collection/ui-components/form/form-control-text.js +2 -2
  143. package/dist/collection/ui-components/form/form-control-textarea.js +2 -2
  144. package/dist/collection/ui-components/form/hidden-input.js +1 -1
  145. package/dist/collection/ui-components/form/iframe-input.js +3 -3
  146. package/dist/collection/ui-components/pagination-menu/pagination-menu.js +3 -3
  147. package/dist/collection/ui-components/shadow-dom-components/justifi-button.js +1 -1
  148. package/dist/collection/ui-components/shadow-dom-components/justifi-header.js +1 -1
  149. package/dist/collection/ui-components/shadow-dom-components/justifi-skeleton.js +1 -1
  150. package/dist/docs.json +3 -540
  151. package/dist/esm/{GooglePay-f7mYX17c.js → Refund-BugCdfRo.js} +1 -436
  152. package/dist/esm/bank-account-document-form-inputs_6.entry.js +3 -4
  153. package/dist/esm/bank-account-form.entry.js +2 -2
  154. package/dist/esm/{business.service-CzHfftZk.js → business.service-pWcc3kfX.js} +1 -1
  155. package/dist/esm/card-form.entry.js +2 -2
  156. package/dist/esm/{check-pkg-version-Cqb7EhvC.js → check-pkg-version-C8hgGLFx.js} +2 -2
  157. package/dist/esm/{checkout.service-BWdnJLVG.js → checkout.service-B4xSV2-X.js} +1 -1
  158. package/dist/esm/checkout.store-CaS_htQd.js +101 -0
  159. package/dist/esm/checkouts-list-core.entry.js +2 -3
  160. package/dist/esm/custom-popper.entry.js +2 -2
  161. package/dist/esm/{dispute.service-CqX5HR5o.js → dispute.service-3Kbbh1J9.js} +1 -1
  162. package/dist/esm/form-control-checkbox.entry.js +2 -2
  163. package/dist/esm/form-control-date.entry.js +2 -2
  164. package/dist/esm/form-control-file-v2_2.entry.js +3 -3
  165. package/dist/esm/form-control-monetary.entry.js +2 -2
  166. package/dist/esm/form-control-number-masked_3.entry.js +2 -2
  167. package/dist/esm/form-control-number.entry.js +2 -2
  168. package/dist/esm/form-control-radio.entry.js +2 -2
  169. package/dist/esm/form-control-select_3.entry.js +4 -4
  170. package/dist/esm/{get-payment-details-D0T7bd_-.js → get-payment-details-CakzKvOr.js} +1 -1
  171. package/dist/esm/{get-subaccounts-Gil-SOoF.js → get-subaccounts-Cw1Adtmo.js} +1 -1
  172. package/dist/esm/gross-payment-chart-core.entry.js +1 -1
  173. package/dist/esm/hidden-input_2.entry.js +5 -5
  174. package/dist/esm/{index-DkoufM1t.js → index-DCIW8z1f.js} +0 -1
  175. package/dist/esm/index.js +1 -1
  176. package/dist/esm/internal-tokenize-payment-method_7.entry.js +12 -11
  177. package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +1 -2
  178. package/dist/esm/justifi-additional-questions-form-step_9.entry.js +2 -3
  179. package/dist/esm/justifi-additional-statement_8.entry.js +8 -8
  180. package/dist/esm/{justifi-apple-pay_8.entry.js → justifi-apple-pay_7.entry.js} +137 -1007
  181. package/dist/esm/justifi-bank-account-billing-form-simple_3.entry.js +2 -2
  182. package/dist/esm/justifi-business-details.entry.js +4 -5
  183. package/dist/esm/justifi-business-form.entry.js +4 -5
  184. package/dist/esm/justifi-checkout.entry.js +8 -7
  185. package/dist/esm/justifi-checkouts-list-filters.entry.js +2 -3
  186. package/dist/esm/justifi-checkouts-list.entry.js +6 -7
  187. package/dist/esm/justifi-dispute-management-core.entry.js +1 -1
  188. package/dist/esm/justifi-dispute-management.entry.js +5 -6
  189. package/dist/esm/justifi-dispute-notification_3.entry.js +8 -9
  190. package/dist/esm/justifi-gross-payment-chart.entry.js +3 -4
  191. package/dist/esm/justifi-order-terminals.entry.js +6 -7
  192. package/dist/esm/justifi-owner-form_3.entry.js +2 -3
  193. package/dist/esm/justifi-payment-details.entry.js +5 -6
  194. package/dist/esm/justifi-payment-provisioning.entry.js +4 -5
  195. package/dist/esm/justifi-payment-transactions-list.entry.js +5 -6
  196. package/dist/esm/justifi-payments-list-filters.entry.js +2 -2
  197. package/dist/esm/justifi-payments-list.entry.js +5 -6
  198. package/dist/esm/justifi-payout-details.entry.js +4 -5
  199. package/dist/esm/justifi-payout-transactions-list.entry.js +5 -6
  200. package/dist/esm/justifi-payouts-list-filters.entry.js +2 -2
  201. package/dist/esm/justifi-payouts-list.entry.js +6 -7
  202. package/dist/esm/justifi-refund-payment.entry.js +5 -6
  203. package/dist/esm/justifi-saved-payment-method.entry.js +1 -1
  204. package/dist/esm/justifi-season-interruption-insurance.entry.js +5 -4
  205. package/dist/esm/justifi-skeleton.entry.js +1 -1
  206. package/dist/esm/justifi-terminal-orders-list-filters.entry.js +3 -4
  207. package/dist/esm/justifi-terminal-orders-list.entry.js +5 -6
  208. package/dist/esm/justifi-terminals-list-filters.entry.js +2 -3
  209. package/dist/esm/justifi-terminals-list.entry.js +6 -7
  210. package/dist/esm/justifi-tokenize-payment-method.entry.js +1 -1
  211. package/dist/esm/loader.js +1 -1
  212. package/dist/esm/{package-CzedYX3W.js → package-DEhd71m_.js} +1 -1
  213. package/dist/esm/pagination-menu.entry.js +3 -3
  214. package/dist/esm/payment-details-core.entry.js +9 -10
  215. package/dist/esm/payment-method-option.entry.js +1 -1
  216. package/dist/esm/{payment.service-CWyZF34P.js → payment.service-nExZY_sU.js} +1 -1
  217. package/dist/esm/payments-list-core.entry.js +2 -3
  218. package/dist/esm/payout-details-core.entry.js +3 -3
  219. package/dist/esm/{payout.service-CkTievFG.js → payout.service-B9-JQqU6.js} +1 -1
  220. package/dist/esm/payouts-list-core.entry.js +2 -3
  221. package/dist/esm/table-filters-menu.entry.js +1 -1
  222. package/dist/esm/terminal-orders-list-core.entry.js +3 -4
  223. package/dist/esm/{terminal-orders-table-OX3ZvzZy.js → terminal-orders-table-DsrpmD9F.js} +1 -1
  224. package/dist/esm/terminal-quantity-selector.entry.js +1 -1
  225. package/dist/esm/{terminal.service-Bu5-dhum.js → terminal.service-DvFiKAKV.js} +1 -1
  226. package/dist/esm/terminals-list-core.entry.js +2 -3
  227. package/dist/esm/webcomponents.js +1 -1
  228. package/dist/module/Analytics.js +0 -2
  229. package/dist/module/ModularCheckout.js +0 -1
  230. package/dist/module/additional-statement.js +1 -1
  231. package/dist/module/apple-pay.js +120 -1
  232. package/dist/module/bank-account-billing-form-simple.js +1 -1
  233. package/dist/module/bank-account-document-inputs.js +0 -2
  234. package/dist/module/bank-account-form.js +2 -2
  235. package/dist/module/bank-account.js +2 -2
  236. package/dist/module/business-bank-account-form-step-core.js +0 -2
  237. package/dist/module/business-bank-account-form-step.js +0 -2
  238. package/dist/module/business-terms-conditions-form-step.js +0 -2
  239. package/dist/module/business.service.js +0 -2
  240. package/dist/module/cancellation-policy.js +1 -1
  241. package/dist/module/card-billing-form-simple.js +1 -1
  242. package/dist/module/card-form.js +2 -2
  243. package/dist/module/card-form2.js +2 -2
  244. package/dist/module/checkout.service.js +0 -2
  245. package/dist/module/checkout.store.js +0 -4
  246. package/dist/module/checkouts-list-core2.js +1 -3
  247. package/dist/module/custom-popper2.js +2 -2
  248. package/dist/module/customer-details.js +1 -1
  249. package/dist/module/dispute-management-core.js +1 -1
  250. package/dist/module/dispute-notification.js +2 -2
  251. package/dist/module/dispute-response-actions.js +0 -2
  252. package/dist/module/dispute-response-core.js +1 -1
  253. package/dist/module/dispute-response.js +1 -1
  254. package/dist/module/duplicate-charge.js +1 -1
  255. package/dist/module/electronic-evidence.js +1 -1
  256. package/dist/module/form-control-checkbox2.js +2 -2
  257. package/dist/module/form-control-date2.js +2 -2
  258. package/dist/module/form-control-file-v22.js +1 -1
  259. package/dist/module/form-control-file2.js +2 -2
  260. package/dist/module/form-control-monetary2.js +2 -2
  261. package/dist/module/form-control-number-masked2.js +2 -2
  262. package/dist/module/form-control-number.js +2 -2
  263. package/dist/module/form-control-radio2.js +2 -2
  264. package/dist/module/form-control-select2.js +2 -2
  265. package/dist/module/form-control-text2.js +2 -2
  266. package/dist/module/form-control-textarea2.js +2 -2
  267. package/dist/module/get-payment-details.js +0 -2
  268. package/dist/module/get-subaccounts.js +0 -2
  269. package/dist/module/gross-payment-chart-core2.js +1 -1
  270. package/dist/module/hidden-input2.js +1 -1
  271. package/dist/module/iframe-input2.js +3 -3
  272. package/dist/module/internal-tokenize-payment-method2.js +1 -3
  273. package/dist/module/justifi-business-form.js +0 -2
  274. package/dist/module/justifi-button2.js +1 -1
  275. package/dist/module/justifi-checkout.js +40 -46
  276. package/dist/module/justifi-checkouts-list-filters.js +1 -3
  277. package/dist/module/justifi-checkouts-list.js +1 -3
  278. package/dist/module/justifi-dispute-management.js +1 -1
  279. package/dist/module/justifi-gross-payment-chart.js +0 -2
  280. package/dist/module/justifi-header2.js +1 -1
  281. package/dist/module/justifi-order-terminals.js +1 -3
  282. package/dist/module/justifi-payment-provisioning.js +0 -2
  283. package/dist/module/justifi-payment-transactions-list.js +1 -3
  284. package/dist/module/justifi-payments-list-filters.js +2 -2
  285. package/dist/module/justifi-payments-list.js +1 -3
  286. package/dist/module/justifi-payout-details.js +0 -2
  287. package/dist/module/justifi-payout-transactions-list.js +1 -3
  288. package/dist/module/justifi-payouts-list-filters.js +2 -2
  289. package/dist/module/justifi-payouts-list.js +1 -3
  290. package/dist/module/justifi-refund-payment.js +0 -2
  291. package/dist/module/justifi-saved-payment-method.js +1 -1
  292. package/dist/module/justifi-season-interruption-insurance.js +0 -2
  293. package/dist/module/justifi-skeleton.js +1 -1
  294. package/dist/module/justifi-terminal-orders-list-filters.js +2 -4
  295. package/dist/module/justifi-terminal-orders-list.js +1 -3
  296. package/dist/module/justifi-terminals-list-filters.js +1 -3
  297. package/dist/module/justifi-terminals-list.js +1 -3
  298. package/dist/module/justifi-tokenize-payment-method.js +1 -1
  299. package/dist/module/modular-checkout.js +6 -46
  300. package/dist/module/package.js +1 -1
  301. package/dist/module/pagination-menu2.js +3 -3
  302. package/dist/module/payment-details-core2.js +8 -10
  303. package/dist/module/payment-method-option.js +1 -1
  304. package/dist/module/payment.service.js +0 -2
  305. package/dist/module/payments-list-core2.js +1 -3
  306. package/dist/module/payout-details-core2.js +3 -3
  307. package/dist/module/payout.service.js +0 -2
  308. package/dist/module/payouts-list-core2.js +1 -3
  309. package/dist/module/plaid.service.js +0 -2
  310. package/dist/module/product-or-service.js +1 -1
  311. package/dist/module/refund-policy.js +1 -1
  312. package/dist/module/save-new-payment-method.js +1 -1
  313. package/dist/module/shipping-details.js +1 -1
  314. package/dist/module/summary.js +1 -1
  315. package/dist/module/table-filters-menu2.js +1 -1
  316. package/dist/module/terminal-orders-list-core2.js +1 -3
  317. package/dist/module/terminal-quantity-selector2.js +1 -1
  318. package/dist/module/terminal.service.js +0 -2
  319. package/dist/module/terminals-list-core2.js +1 -3
  320. package/dist/types/api/Checkout.d.ts +0 -2
  321. package/dist/types/api/index.d.ts +0 -2
  322. package/dist/types/components/checkout/checkout.d.ts +0 -1
  323. package/dist/types/components/modular-checkout/ModularCheckout.d.ts +1 -2
  324. package/dist/types/components/modular-checkout/modular-checkout.d.ts +0 -5
  325. package/dist/types/components.d.ts +0 -140
  326. package/dist/types/store/checkout.store.d.ts +0 -1
  327. package/dist/webcomponents/index.esm.js +1 -1
  328. package/dist/webcomponents/{p-a22d1078.entry.js → p-0082f428.entry.js} +1 -1
  329. package/dist/webcomponents/p-04b23547.entry.js +1 -0
  330. package/dist/webcomponents/p-04ed045b.entry.js +1 -0
  331. package/dist/webcomponents/{p-19dabeab.entry.js → p-1193a1ac.entry.js} +1 -1
  332. package/dist/webcomponents/p-159d8ae7.entry.js +1 -0
  333. package/dist/webcomponents/{p-86111a0a.entry.js → p-1edec396.entry.js} +1 -1
  334. package/dist/webcomponents/p-20608f0c.entry.js +1 -0
  335. package/dist/webcomponents/p-266a9aee.entry.js +1 -0
  336. package/dist/webcomponents/p-2bafa257.entry.js +1 -0
  337. package/dist/webcomponents/p-30f61f44.entry.js +1 -0
  338. package/dist/webcomponents/p-3101565c.entry.js +1 -0
  339. package/dist/webcomponents/p-34aa9298.entry.js +1 -0
  340. package/dist/webcomponents/p-3c38cec5.entry.js +1 -0
  341. package/dist/webcomponents/p-3c40eefe.entry.js +1 -0
  342. package/dist/webcomponents/p-42c3bda4.entry.js +1 -0
  343. package/dist/webcomponents/p-44a94dac.entry.js +1 -0
  344. package/dist/webcomponents/p-4dcbc0af.entry.js +1 -0
  345. package/dist/webcomponents/{p-f2650bfc.entry.js → p-4e23116c.entry.js} +1 -1
  346. package/dist/webcomponents/{p-3bacf834.entry.js → p-58ae4f9e.entry.js} +1 -1
  347. package/dist/webcomponents/p-5a3687bf.entry.js +1 -0
  348. package/dist/webcomponents/p-5c8c88c6.entry.js +1 -0
  349. package/dist/webcomponents/p-614b0adc.entry.js +1 -0
  350. package/dist/webcomponents/p-7081eb35.entry.js +1 -0
  351. package/dist/webcomponents/p-7128920a.entry.js +1 -0
  352. package/dist/webcomponents/p-7218c312.entry.js +1 -0
  353. package/dist/webcomponents/p-73388c68.entry.js +1 -0
  354. package/dist/webcomponents/p-77b76007.entry.js +1 -0
  355. package/dist/webcomponents/p-77bd4fb0.entry.js +1 -0
  356. package/dist/webcomponents/p-7a3d9c24.entry.js +1 -0
  357. package/dist/webcomponents/p-8c07d9f0.entry.js +1 -0
  358. package/dist/webcomponents/p-8cfda6c1.entry.js +1 -0
  359. package/dist/webcomponents/p-90de8098.entry.js +1 -0
  360. package/dist/webcomponents/p-98b8028e.entry.js +1 -0
  361. package/dist/webcomponents/p-9efd1bce.entry.js +1 -0
  362. package/dist/webcomponents/p-9fef2496.entry.js +1 -0
  363. package/dist/webcomponents/{p-DUs94fK3.js → p-B4ZUYyNh.js} +1 -1
  364. package/dist/webcomponents/{p-B4W3my_D.js → p-BCPutgAi.js} +1 -1
  365. package/dist/webcomponents/p-BojLBYsY.js +1 -0
  366. package/dist/webcomponents/p-BpaE8q5f.js +1 -0
  367. package/dist/webcomponents/{p-DXnwIxTB.js → p-C6wS5-M7.js} +1 -1
  368. package/dist/webcomponents/{p-DeX_cIoV.js → p-C8QOezo8.js} +1 -1
  369. package/dist/webcomponents/{p-aZ8YkDMZ.js → p-CFevTCAJ.js} +1 -1
  370. package/dist/webcomponents/{p-CPRPR6fJ.js → p-CPtsjcdm.js} +1 -1
  371. package/dist/webcomponents/p-Ch9cTPyq.js +1 -0
  372. package/dist/webcomponents/p-DCIW8z1f.js +1 -0
  373. package/dist/webcomponents/p-DEhd71m_.js +1 -0
  374. package/dist/webcomponents/p-DU8dqq9U.js +1 -0
  375. package/dist/webcomponents/{p-TKWqvm_A.js → p-D_IJC4HG.js} +1 -1
  376. package/dist/webcomponents/p-MQxr_LMC.js +1 -0
  377. package/dist/webcomponents/p-a54b8901.entry.js +1 -0
  378. package/dist/webcomponents/p-a655b996.entry.js +1 -0
  379. package/dist/webcomponents/p-a7f8cacb.entry.js +1 -0
  380. package/dist/webcomponents/p-a9bd4e27.entry.js +1 -0
  381. package/dist/webcomponents/{p-03c8c754.entry.js → p-aec9185f.entry.js} +1 -1
  382. package/dist/webcomponents/{p-4e71de94.entry.js → p-af48a6bb.entry.js} +1 -1
  383. package/dist/webcomponents/p-b24a2971.entry.js +1 -0
  384. package/dist/webcomponents/p-bf8cf72d.entry.js +1 -0
  385. package/dist/webcomponents/p-c364c76d.entry.js +1 -0
  386. package/dist/webcomponents/p-c3b71a1f.entry.js +1 -0
  387. package/dist/webcomponents/{p-f528da70.entry.js → p-cd10cd05.entry.js} +1 -1
  388. package/dist/webcomponents/p-cfd858be.entry.js +1 -0
  389. package/dist/webcomponents/p-d1951301.entry.js +1 -0
  390. package/dist/webcomponents/p-d39598e4.entry.js +1 -0
  391. package/dist/webcomponents/p-dc0d3484.entry.js +1 -0
  392. package/dist/webcomponents/{p-88074dd7.entry.js → p-de35abb6.entry.js} +1 -1
  393. package/dist/webcomponents/p-e47a2592.entry.js +1 -0
  394. package/dist/webcomponents/p-eb56ba9b.entry.js +1 -0
  395. package/dist/webcomponents/{p-e7e5fee9.entry.js → p-ed55d333.entry.js} +1 -1
  396. package/dist/webcomponents/p-edcb84bf.entry.js +1 -0
  397. package/dist/webcomponents/{p-aaed4997.entry.js → p-f0957fca.entry.js} +1 -1
  398. package/dist/webcomponents/p-f0fc86ce.entry.js +1 -0
  399. package/dist/webcomponents/p-f223fabb.entry.js +1 -0
  400. package/dist/webcomponents/p-f26db2e6.entry.js +1 -0
  401. package/dist/webcomponents/p-fab28b02.entry.js +1 -0
  402. package/dist/webcomponents/webcomponents.esm.js +1 -1
  403. package/docs/.eslintrc.cjs +17 -0
  404. package/docs/changelog/index.mdx +17 -0
  405. package/docs/entities/businessdetails/index.mdx +158 -0
  406. package/docs/entities/businessform/index.mdx +241 -0
  407. package/docs/entities/index.mdx +19 -0
  408. package/docs/entities/payment-provisioning/index.mdx +131 -0
  409. package/docs/frameworks/angular/index.mdx +112 -0
  410. package/docs/frameworks/index.mdx +18 -0
  411. package/docs/frameworks/react/index.mdx +125 -0
  412. package/docs/frameworks/vue/index.mdx +102 -0
  413. package/docs/helpers/PartsTable.js +50 -0
  414. package/docs/helpers/PartsTable.ts +55 -0
  415. package/docs/helpers/PropsTable.js +56 -0
  416. package/docs/helpers/PropsTable.ts +63 -0
  417. package/docs/helpers/index.js +4 -0
  418. package/docs/helpers/index.ts +3 -0
  419. package/docs/helpers/version.js +32 -0
  420. package/docs/helpers/version.ts +32 -0
  421. package/docs/introduction/index.mdx +125 -0
  422. package/docs/merchant-tools/checkouts-list/index.mdx +107 -0
  423. package/docs/merchant-tools/gross-payments-chart/index.mdx +81 -0
  424. package/docs/merchant-tools/index.mdx +25 -0
  425. package/docs/merchant-tools/order-terminals/index.mdx +84 -0
  426. package/docs/merchant-tools/payment-details/index.mdx +130 -0
  427. package/docs/merchant-tools/payment-transactions-list/index.mdx +85 -0
  428. package/docs/merchant-tools/payments-list/index.mdx +111 -0
  429. package/docs/merchant-tools/payout-details/index.mdx +90 -0
  430. package/docs/merchant-tools/payout-transactions-list/index.mdx +84 -0
  431. package/docs/merchant-tools/payouts-list/index.mdx +94 -0
  432. package/docs/merchant-tools/terminal-orders-list/index.mdx +85 -0
  433. package/docs/merchant-tools/terminals-list/index.mdx +93 -0
  434. package/docs/modular-checkout/complete-examples/index.mdx +20 -0
  435. package/docs/modular-checkout/docs/index.mdx +32 -0
  436. package/docs/modular-checkout/example/index.mdx +25 -0
  437. package/docs/modular-checkout/index.mdx +25 -0
  438. package/docs/modular-checkout/introduction/index.mdx +100 -0
  439. package/docs/modular-checkout/sub-components/apple-pay.mdx +96 -0
  440. package/docs/modular-checkout/sub-components/bank-account-form.mdx +162 -0
  441. package/docs/modular-checkout/sub-components/card-form.mdx +177 -0
  442. package/docs/modular-checkout/sub-components/index.mdx +23 -0
  443. package/docs/modular-checkout/sub-components/payment-method-options.mdx +85 -0
  444. package/docs/modular-checkout/sub-components/plaid-payment-method.mdx +175 -0
  445. package/docs/modular-checkout/sub-components/saved-payment-methods.mdx +177 -0
  446. package/docs/modular-checkout/sub-components/season-interruption-insurance.mdx +219 -0
  447. package/docs/modular-checkout/sub-components/sezzle-payment-method.mdx +183 -0
  448. package/docs/modular-checkout/sub-components/summary.mdx +107 -0
  449. package/docs/payment-facilitation/dispute-management/index.mdx +98 -0
  450. package/docs/payment-facilitation/index.mdx +21 -0
  451. package/docs/payment-facilitation/refund-payment/index.mdx +229 -0
  452. package/docs/payment-facilitation/tokenize-payment-method/index.mdx +361 -0
  453. package/docs/payment-facilitation/unified-fintech-checkout/342/204/242/index.mdx +164 -0
  454. package/package.json +21 -6
  455. package/dist/collection/api/GooglePay.js +0 -212
  456. package/dist/collection/api/services/google-pay.service.js +0 -368
  457. package/dist/collection/components/modular-checkout/sub-components/google-pay-skeleton.js +0 -10
  458. package/dist/collection/components/modular-checkout/sub-components/google-pay.js +0 -706
  459. package/dist/collection/ui-components/google-pay-button.js +0 -251
  460. package/dist/module/ApplePay.js +0 -121
  461. package/dist/module/GooglePay.js +0 -215
  462. package/dist/module/google-pay.js +0 -1006
  463. package/dist/module/justifi-google-pay.d.ts +0 -11
  464. package/dist/module/justifi-google-pay.js +0 -6
  465. package/dist/types/api/GooglePay.d.ts +0 -271
  466. package/dist/types/api/services/google-pay.service.d.ts +0 -60
  467. package/dist/types/components/modular-checkout/sub-components/google-pay-skeleton.d.ts +0 -6
  468. package/dist/types/components/modular-checkout/sub-components/google-pay.d.ts +0 -59
  469. package/dist/types/ui-components/google-pay-button.d.ts +0 -18
  470. package/dist/webcomponents/p-0437c330.entry.js +0 -1
  471. package/dist/webcomponents/p-065b24c3.entry.js +0 -1
  472. package/dist/webcomponents/p-0772719b.entry.js +0 -1
  473. package/dist/webcomponents/p-136b29e3.entry.js +0 -1
  474. package/dist/webcomponents/p-14cbf366.entry.js +0 -1
  475. package/dist/webcomponents/p-1e014ee7.entry.js +0 -1
  476. package/dist/webcomponents/p-1f196690.entry.js +0 -1
  477. package/dist/webcomponents/p-20e66fc0.entry.js +0 -1
  478. package/dist/webcomponents/p-22fdf7a4.entry.js +0 -1
  479. package/dist/webcomponents/p-25755af4.entry.js +0 -1
  480. package/dist/webcomponents/p-270bf699.entry.js +0 -1
  481. package/dist/webcomponents/p-2da4e6ca.entry.js +0 -1
  482. package/dist/webcomponents/p-2eb123a3.entry.js +0 -1
  483. package/dist/webcomponents/p-3ae12b98.entry.js +0 -1
  484. package/dist/webcomponents/p-3d3a65ca.entry.js +0 -1
  485. package/dist/webcomponents/p-3f291e6b.entry.js +0 -1
  486. package/dist/webcomponents/p-44011a41.entry.js +0 -1
  487. package/dist/webcomponents/p-4ccd753b.entry.js +0 -1
  488. package/dist/webcomponents/p-4f102cfd.entry.js +0 -1
  489. package/dist/webcomponents/p-4f16a3ce.entry.js +0 -1
  490. package/dist/webcomponents/p-50a32503.entry.js +0 -1
  491. package/dist/webcomponents/p-57ed105e.entry.js +0 -1
  492. package/dist/webcomponents/p-5e3bc1dc.entry.js +0 -1
  493. package/dist/webcomponents/p-62cfe9b6.entry.js +0 -1
  494. package/dist/webcomponents/p-6a075da4.entry.js +0 -1
  495. package/dist/webcomponents/p-8c16e4aa.entry.js +0 -1
  496. package/dist/webcomponents/p-8ee61443.entry.js +0 -1
  497. package/dist/webcomponents/p-8efea1e4.entry.js +0 -1
  498. package/dist/webcomponents/p-914b590d.entry.js +0 -1
  499. package/dist/webcomponents/p-A2FbmAEt.js +0 -1
  500. package/dist/webcomponents/p-BrazW3nF.js +0 -1
  501. package/dist/webcomponents/p-CIOILVyM.js +0 -1
  502. package/dist/webcomponents/p-CzedYX3W.js +0 -1
  503. package/dist/webcomponents/p-DkoufM1t.js +0 -1
  504. package/dist/webcomponents/p-Yp5v6wmS.js +0 -1
  505. package/dist/webcomponents/p-a020c889.entry.js +0 -1
  506. package/dist/webcomponents/p-a6e816f6.entry.js +0 -1
  507. package/dist/webcomponents/p-aa42e3c1.entry.js +0 -1
  508. package/dist/webcomponents/p-ad0f8d85.entry.js +0 -1
  509. package/dist/webcomponents/p-ad9307c1.entry.js +0 -1
  510. package/dist/webcomponents/p-b8c47cb1.entry.js +0 -1
  511. package/dist/webcomponents/p-c11e6c03.entry.js +0 -1
  512. package/dist/webcomponents/p-c41191e7.entry.js +0 -1
  513. package/dist/webcomponents/p-c5af7149.entry.js +0 -1
  514. package/dist/webcomponents/p-c621e7af.entry.js +0 -1
  515. package/dist/webcomponents/p-c7df4370.entry.js +0 -1
  516. package/dist/webcomponents/p-cf9d8e1a.entry.js +0 -1
  517. package/dist/webcomponents/p-d3663663.entry.js +0 -1
  518. package/dist/webcomponents/p-daedfe82.entry.js +0 -1
  519. package/dist/webcomponents/p-dd11e67b.entry.js +0 -1
  520. package/dist/webcomponents/p-e3ab5fe2.entry.js +0 -1
  521. package/dist/webcomponents/p-e95e27af.entry.js +0 -1
  522. package/dist/webcomponents/p-f4cb581f.entry.js +0 -1
  523. package/dist/webcomponents/p-f66778b8.entry.js +0 -1
  524. package/dist/webcomponents/p-ff212635.entry.js +0 -1
@@ -2,28 +2,149 @@
2
2
 
3
3
  var index = require('./index-BhI7cJcE.js');
4
4
  var Api = require('./Api-BeSnjEuW.js');
5
- var GooglePay$1 = require('./GooglePay-40aEKdDF.js');
6
5
  var styledHost = require('./styled-host-D5g7INLE.js');
7
6
  require('./event-types-YOY5TKUN.js');
8
7
  var skeleton = require('./skeleton-BF3HGL9X.js');
8
+ var checkout_store = require('./checkout.store-BA6h-dp2.js');
9
9
  var parts = require('./parts-Pb06tUMp.js');
10
10
  var utils = require('./utils-Bab-tddY.js');
11
- var index$1 = require('./index-CajjbB9t.js');
12
11
  var header1 = require('./header-1-CBO8uDuZ.js');
13
12
  var insuranceState = require('./insurance-state-BMHITXoD.js');
14
13
  var header3 = require('./header-3-CPWtI1t0.js');
15
- var checkPkgVersion = require('./check-pkg-version-DuPkU5qI.js');
14
+ var checkPkgVersion = require('./check-pkg-version-T54BeR4n.js');
16
15
  require('./config-state-CYoBVAca.js');
17
16
  require('./dinero-BwNN_k7x.js');
18
17
  var ComponentError = require('./ComponentError-D4OLnOkg.js');
18
+ var Refund = require('./Refund-Blquw3jZ.js');
19
19
  require('./Pagination-Dediz133.js');
20
20
  require('./Business-DWHy_-z9.js');
21
21
  require('./Dispute-CruQTF6_.js');
22
22
  var utils$1 = require('./utils-DvUQQLmR.js');
23
- var checkout_service = require('./checkout.service-BUcIs9az.js');
23
+ var checkout_service = require('./checkout.service-BEU6CI0t.js');
24
+ var index$1 = require('./index-C2ITzalN.js');
24
25
  var paymentMethodOptionUtils = require('./payment-method-option-utils-WYHIHy-l.js');
25
26
  require('./index-mmd0OhmD.js');
26
- require('./package-C6nOTkVV.js');
27
+ require('./package-JstJdxIu.js');
28
+
29
+ var ApplePaySessionStatus;
30
+ (function (ApplePaySessionStatus) {
31
+ ApplePaySessionStatus["STATUS_SUCCESS"] = "STATUS_SUCCESS";
32
+ ApplePaySessionStatus["STATUS_FAILURE"] = "STATUS_FAILURE";
33
+ })(ApplePaySessionStatus || (ApplePaySessionStatus = {}));
34
+ var ApplePayButtonType;
35
+ (function (ApplePayButtonType) {
36
+ ApplePayButtonType["PLAIN"] = "plain";
37
+ ApplePayButtonType["BUY"] = "buy";
38
+ ApplePayButtonType["SET_UP"] = "set-up";
39
+ ApplePayButtonType["DONATE"] = "donate";
40
+ ApplePayButtonType["CHECK_OUT"] = "check-out";
41
+ ApplePayButtonType["BOOK"] = "book";
42
+ ApplePayButtonType["SUBSCRIBE"] = "subscribe";
43
+ })(ApplePayButtonType || (ApplePayButtonType = {}));
44
+ var ApplePayButtonStyle;
45
+ (function (ApplePayButtonStyle) {
46
+ ApplePayButtonStyle["BLACK"] = "black";
47
+ ApplePayButtonStyle["WHITE"] = "white";
48
+ ApplePayButtonStyle["WHITE_OUTLINE"] = "white-outline";
49
+ })(ApplePayButtonStyle || (ApplePayButtonStyle = {}));
50
+ var ApplePayMerchantCapability;
51
+ (function (ApplePayMerchantCapability) {
52
+ ApplePayMerchantCapability["SUPPORTS_3DS"] = "supports3DS";
53
+ ApplePayMerchantCapability["SUPPORTS_EMV"] = "supportsEMV";
54
+ ApplePayMerchantCapability["SUPPORTS_CREDIT"] = "supportsCredit";
55
+ ApplePayMerchantCapability["SUPPORTS_DEBIT"] = "supportsDebit";
56
+ })(ApplePayMerchantCapability || (ApplePayMerchantCapability = {}));
57
+ class ApplePayConfig {
58
+ constructor(data) {
59
+ this.merchantIdentifier = data.merchantIdentifier;
60
+ this.displayName = data.displayName;
61
+ this.initiative = data.initiative;
62
+ this.initiativeContext = data.initiativeContext;
63
+ this.buttonType = data.buttonType || ApplePayButtonType.PLAIN;
64
+ this.buttonStyle = data.buttonStyle || ApplePayButtonStyle.BLACK;
65
+ this.buttonLocale = data.buttonLocale || 'en-US';
66
+ }
67
+ get isValid() {
68
+ return !!(this.merchantIdentifier &&
69
+ this.displayName &&
70
+ this.initiative &&
71
+ this.initiativeContext);
72
+ }
73
+ }
74
+ class ApplePayPaymentRequest {
75
+ constructor(data) {
76
+ this.countryCode = data.countryCode;
77
+ this.currencyCode = data.currencyCode;
78
+ this.merchantCapabilities = data.merchantCapabilities;
79
+ this.supportedNetworks = data.supportedNetworks;
80
+ this.total = data.total;
81
+ this.lineItems = data.lineItems;
82
+ this.shippingMethods = data.shippingMethods;
83
+ this.applicationData = data.applicationData;
84
+ this.supportedCountries = data.supportedCountries;
85
+ }
86
+ get isValid() {
87
+ var _a, _b, _c, _d;
88
+ return !!(this.countryCode &&
89
+ this.currencyCode &&
90
+ ((_a = this.merchantCapabilities) === null || _a === void 0 ? void 0 : _a.length) &&
91
+ ((_b = this.supportedNetworks) === null || _b === void 0 ? void 0 : _b.length) &&
92
+ ((_c = this.total) === null || _c === void 0 ? void 0 : _c.label) &&
93
+ ((_d = this.total) === null || _d === void 0 ? void 0 : _d.amount));
94
+ }
95
+ }
96
+ class ApplePayHelpers {
97
+ static isApplePaySupported() {
98
+ var _a;
99
+ return (typeof window !== 'undefined' &&
100
+ 'ApplePaySession' in window &&
101
+ ((_a = window.ApplePaySession) === null || _a === void 0 ? void 0 : _a.supportsVersion(3)));
102
+ }
103
+ static canMakePayments() {
104
+ var _a;
105
+ if (!this.isApplePaySupported()) {
106
+ return false;
107
+ }
108
+ return ((_a = window.ApplePaySession) === null || _a === void 0 ? void 0 : _a.canMakePayments()) || false;
109
+ }
110
+ static async canMakePaymentsWithActiveCard(merchantIdentifier) {
111
+ var _a;
112
+ if (!this.isApplePaySupported()) {
113
+ return false;
114
+ }
115
+ try {
116
+ return ((await ((_a = window.ApplePaySession) === null || _a === void 0 ? void 0 : _a.canMakePaymentsWithActiveCard(merchantIdentifier))) || false);
117
+ }
118
+ catch (error) {
119
+ console.error('Error checking Apple Pay active card:', error);
120
+ return false;
121
+ }
122
+ }
123
+ static formatAmount(amount) {
124
+ return (amount / 100).toFixed(2);
125
+ }
126
+ static parseAmount(amount) {
127
+ return Math.round(parseFloat(amount) * 100);
128
+ }
129
+ static createLineItem(label, amount, type = 'final') {
130
+ return {
131
+ label,
132
+ amount: this.formatAmount(amount),
133
+ type,
134
+ };
135
+ }
136
+ static getDefaultSupportedNetworks() {
137
+ return ['amex', 'discover', 'masterCard', 'visa'];
138
+ }
139
+ static getDefaultMerchantCapabilities() {
140
+ return [
141
+ ApplePayMerchantCapability.SUPPORTS_3DS,
142
+ ApplePayMerchantCapability.SUPPORTS_EMV,
143
+ ApplePayMerchantCapability.SUPPORTS_CREDIT,
144
+ ApplePayMerchantCapability.SUPPORTS_DEBIT,
145
+ ];
146
+ }
147
+ }
27
148
 
28
149
  // Centralized error codes for Apple Pay service
29
150
  var ApplePayServiceErrorCode;
@@ -42,7 +163,7 @@ class ApplePayService {
42
163
  * Initialize Apple Pay configuration
43
164
  */
44
165
  initialize(applePayConfig) {
45
- this.applePayConfig = new GooglePay$1.ApplePayConfig(applePayConfig);
166
+ this.applePayConfig = new ApplePayConfig(applePayConfig);
46
167
  if (!this.applePayConfig.isValid) {
47
168
  throw new Error('Invalid Apple Pay configuration provided');
48
169
  }
@@ -93,7 +214,7 @@ class ApplePayService {
93
214
  * Check if Apple Pay is available on this device/browser
94
215
  */
95
216
  isAvailable() {
96
- return (GooglePay$1.ApplePayHelpers.isApplePaySupported() && GooglePay$1.ApplePayHelpers.canMakePayments());
217
+ return (ApplePayHelpers.isApplePaySupported() && ApplePayHelpers.canMakePayments());
97
218
  }
98
219
  /**
99
220
  * Check if the user has an active card for the merchant
@@ -102,7 +223,7 @@ class ApplePayService {
102
223
  if (!this.applePayConfig) {
103
224
  throw new Error('Apple Pay not initialized. Call initialize() first.');
104
225
  }
105
- return await GooglePay$1.ApplePayHelpers.canMakePaymentsWithActiveCard(this.applePayConfig.merchantIdentifier);
226
+ return await ApplePayHelpers.canMakePaymentsWithActiveCard(this.applePayConfig.merchantIdentifier);
106
227
  }
107
228
  /**
108
229
  * Start Apple Pay session
@@ -116,7 +237,7 @@ class ApplePayService {
116
237
  // if (!this.isAvailable()) {
117
238
  // throw new Error('Apple Pay is not available on this device/browser');
118
239
  // }
119
- const request = new GooglePay$1.ApplePayPaymentRequest(paymentRequest);
240
+ const request = new ApplePayPaymentRequest(paymentRequest);
120
241
  if (!request.isValid) {
121
242
  const missingFields = [];
122
243
  if (!request.countryCode)
@@ -227,13 +348,13 @@ class ApplePayService {
227
348
  const payment = event.payment;
228
349
  const paymentPayload = Object.assign(Object.assign({}, payment.token), { product_details: {
229
350
  name: this.currentPaymentRequest.total.label,
230
- price: GooglePay$1.ApplePayHelpers.parseAmount(this.currentPaymentRequest.total.amount),
351
+ price: ApplePayHelpers.parseAmount(this.currentPaymentRequest.total.amount),
231
352
  description: this.currentPaymentRequest.total.label,
232
353
  } });
233
354
  const paymentResult = await this.processPayment(authToken, accountId, paymentPayload);
234
355
  if (paymentResult.success) {
235
356
  this.currentSession.completePayment({
236
- status: GooglePay$1.ApplePaySessionStatus.STATUS_SUCCESS,
357
+ status: ApplePaySessionStatus.STATUS_SUCCESS,
237
358
  });
238
359
  resolve({
239
360
  success: true,
@@ -244,7 +365,7 @@ class ApplePayService {
244
365
  else {
245
366
  console.error('PSP reported payment failure:', paymentResult.data);
246
367
  this.currentSession.completePayment({
247
- status: GooglePay$1.ApplePaySessionStatus.STATUS_FAILURE,
368
+ status: ApplePaySessionStatus.STATUS_FAILURE,
248
369
  });
249
370
  reject({
250
371
  success: false,
@@ -262,7 +383,7 @@ class ApplePayService {
262
383
  console.error('Error stack:', error.stack);
263
384
  }
264
385
  this.currentSession.completePayment({
265
- status: GooglePay$1.ApplePaySessionStatus.STATUS_FAILURE,
386
+ status: ApplePaySessionStatus.STATUS_FAILURE,
266
387
  });
267
388
  reject({
268
389
  success: false,
@@ -294,7 +415,7 @@ class ApplePayService {
294
415
  };
295
416
  this.currentSession.onshippingmethodselected = () => {
296
417
  this.currentSession.completeShippingMethodSelection({
297
- status: GooglePay$1.ApplePaySessionStatus.STATUS_SUCCESS,
418
+ status: ApplePaySessionStatus.STATUS_SUCCESS,
298
419
  newTotal: this.currentPaymentRequest.total,
299
420
  newLineItems: this.currentPaymentRequest.lineItems || [],
300
421
  });
@@ -354,9 +475,9 @@ class ApplePayService {
354
475
  return {
355
476
  countryCode,
356
477
  currencyCode,
357
- merchantCapabilities: GooglePay$1.ApplePayHelpers.getDefaultMerchantCapabilities(),
358
- supportedNetworks: GooglePay$1.ApplePayHelpers.getDefaultSupportedNetworks(),
359
- total: GooglePay$1.ApplePayHelpers.createLineItem(label, amount),
478
+ merchantCapabilities: ApplePayHelpers.getDefaultMerchantCapabilities(),
479
+ supportedNetworks: ApplePayHelpers.getDefaultSupportedNetworks(),
480
+ total: ApplePayHelpers.createLineItem(label, amount),
360
481
  };
361
482
  }
362
483
  /**
@@ -375,30 +496,30 @@ const ApplePaySkeleton = (props) => {
375
496
  return (index.h("div", { class: 'container-fluid p-0' }, index.h("div", { class: 'row mb-3' }, index.h("div", { class: 'col-12 align-content-center' }, index.h(skeleton.Skeleton, { height: '44px', width: '100%', styles: { borderRadius: "8px" } })))));
376
497
  };
377
498
 
378
- const ProcessingSpinner$1 = () => (index.h("div", { class: 'processing-overlay' }, index.h("div", { class: 'spinner' }), index.h("span", null, "Processing...")));
499
+ const ProcessingSpinner = () => (index.h("div", { class: 'processing-overlay' }, index.h("div", { class: 'spinner' }), index.h("span", null, "Processing...")));
379
500
  const ApplePayButton = (props) => {
380
501
  const getApplePayButtonClass = () => {
381
502
  let classes = "apple-pay-button";
382
503
  switch (props.buttonStyle) {
383
- case GooglePay$1.ApplePayButtonStyle.WHITE:
504
+ case ApplePayButtonStyle.WHITE:
384
505
  classes += " apple-pay-button-white";
385
506
  break;
386
- case GooglePay$1.ApplePayButtonStyle.WHITE_OUTLINE:
507
+ case ApplePayButtonStyle.WHITE_OUTLINE:
387
508
  classes += " apple-pay-button-white-outline";
388
509
  break;
389
- case GooglePay$1.ApplePayButtonStyle.BLACK:
510
+ case ApplePayButtonStyle.BLACK:
390
511
  default:
391
512
  classes += " apple-pay-button-black";
392
513
  break;
393
514
  }
394
515
  switch (props.buttonType) {
395
- case GooglePay$1.ApplePayButtonType.BUY:
516
+ case ApplePayButtonType.BUY:
396
517
  classes += " apple-pay-button-type-buy";
397
518
  break;
398
- case GooglePay$1.ApplePayButtonType.DONATE:
519
+ case ApplePayButtonType.DONATE:
399
520
  classes += " apple-pay-button-type-donate";
400
521
  break;
401
- case GooglePay$1.ApplePayButtonType.PLAIN:
522
+ case ApplePayButtonType.PLAIN:
402
523
  default:
403
524
  classes += " apple-pay-button-type-plain";
404
525
  break;
@@ -419,7 +540,7 @@ const ApplePayButton = (props) => {
419
540
  return (index.h("div", { class: 'apple-pay-button-container' }, index.h("button", Object.assign({ class: getApplePayButtonClass(), style: {
420
541
  width: props.width,
421
542
  height: props.height,
422
- }, onClick: handleClick, disabled: props.disabled || props.isProcessing || !props.isAvailable, "aria-label": 'Pay with Apple Pay', type: 'button' }, props), props.isProcessing && ProcessingSpinner$1()), index.h("style", null, `
543
+ }, onClick: handleClick, disabled: props.disabled || props.isProcessing || !props.isAvailable, "aria-label": 'Pay with Apple Pay', type: 'button' }, props), props.isProcessing && ProcessingSpinner()), index.h("style", null, `
423
544
  .apple-pay-button-container {
424
545
  display: block;
425
546
  position: relative;
@@ -529,8 +650,8 @@ const ApplePay = class {
529
650
  this.merchantIdentifier = "merchant.com.staging-justifi.checkout-dev";
530
651
  this.merchantDisplayName = "JustiFi Checkout";
531
652
  this.initiativeContext = "dev-checkout.justifi-staging.com";
532
- this.buttonType = GooglePay$1.ApplePayButtonType.PLAIN;
533
- this.buttonStyle = GooglePay$1.ApplePayButtonStyle.BLACK;
653
+ this.buttonType = ApplePayButtonType.PLAIN;
654
+ this.buttonStyle = ApplePayButtonStyle.BLACK;
534
655
  this.disabled = false;
535
656
  this.showSkeleton = true;
536
657
  this.width = "100%";
@@ -552,16 +673,16 @@ const ApplePay = class {
552
673
  this.applePayStarted.emit();
553
674
  const paymentRequest = {
554
675
  countryCode: this.countryCode,
555
- currencyCode: GooglePay$1.checkoutStore.paymentCurrency,
676
+ currencyCode: checkout_store.checkoutStore.paymentCurrency,
556
677
  merchantCapabilities: [
557
- GooglePay$1.ApplePayMerchantCapability.SUPPORTS_3DS,
558
- GooglePay$1.ApplePayMerchantCapability.SUPPORTS_CREDIT,
559
- GooglePay$1.ApplePayMerchantCapability.SUPPORTS_DEBIT,
678
+ ApplePayMerchantCapability.SUPPORTS_3DS,
679
+ ApplePayMerchantCapability.SUPPORTS_CREDIT,
680
+ ApplePayMerchantCapability.SUPPORTS_DEBIT,
560
681
  ],
561
- supportedNetworks: GooglePay$1.ApplePayHelpers.getDefaultSupportedNetworks(),
562
- total: GooglePay$1.ApplePayHelpers.createLineItem(GooglePay$1.checkoutStore.paymentDescription, GooglePay$1.checkoutStore.paymentAmount),
682
+ supportedNetworks: ApplePayHelpers.getDefaultSupportedNetworks(),
683
+ total: ApplePayHelpers.createLineItem(checkout_store.checkoutStore.paymentDescription, checkout_store.checkoutStore.paymentAmount),
563
684
  };
564
- const result = await this.applePayService.startPaymentSession(paymentRequest, GooglePay$1.checkoutStore.authToken, GooglePay$1.checkoutStore.accountId);
685
+ const result = await this.applePayService.startPaymentSession(paymentRequest, checkout_store.checkoutStore.authToken, checkout_store.checkoutStore.accountId);
565
686
  if (result.success) {
566
687
  this.applePayCompleted.emit({
567
688
  success: true,
@@ -599,24 +720,24 @@ const ApplePay = class {
599
720
  this.isLoading = true;
600
721
  this.error = null;
601
722
  this.isConfigValid = true;
602
- const hasRequiredConfig = Boolean(GooglePay$1.checkoutStore.paymentAmount) &&
603
- Boolean(GooglePay$1.checkoutStore.paymentCurrency) &&
604
- Boolean(GooglePay$1.checkoutStore.authToken);
723
+ const hasRequiredConfig = Boolean(checkout_store.checkoutStore.paymentAmount) &&
724
+ Boolean(checkout_store.checkoutStore.paymentCurrency) &&
725
+ Boolean(checkout_store.checkoutStore.authToken);
605
726
  if (!hasRequiredConfig) {
606
727
  this.error = "Missing required Apple Pay configuration";
607
728
  this.isConfigValid = false;
608
729
  console.error("Apple Pay config error: missing required values", {
609
- paymentAmount: GooglePay$1.checkoutStore.paymentAmount,
610
- paymentCurrency: GooglePay$1.checkoutStore.paymentCurrency,
611
- hasAuthToken: Boolean(GooglePay$1.checkoutStore.authToken),
612
- accountId: GooglePay$1.checkoutStore.accountId,
730
+ paymentAmount: checkout_store.checkoutStore.paymentAmount,
731
+ paymentCurrency: checkout_store.checkoutStore.paymentCurrency,
732
+ hasAuthToken: Boolean(checkout_store.checkoutStore.authToken),
733
+ accountId: checkout_store.checkoutStore.accountId,
613
734
  });
614
735
  this.applePayError.emit({ error: this.error, code: ApplePay.ErrorCode.CONFIG_ERROR });
615
736
  this.isLoading = false;
616
737
  return;
617
738
  }
618
- this.isAvailable = GooglePay$1.ApplePayHelpers.isApplePaySupported();
619
- this.canMakePayments = GooglePay$1.ApplePayHelpers.canMakePayments();
739
+ this.isAvailable = ApplePayHelpers.isApplePaySupported();
740
+ this.canMakePayments = ApplePayHelpers.canMakePayments();
620
741
  if (!this.isAvailable) {
621
742
  this.error = "Apple Pay is not supported on this device";
622
743
  console.error(this.error);
@@ -665,7 +786,7 @@ const ApplePay = class {
665
786
  if (!this.isAvailable) {
666
787
  return [];
667
788
  }
668
- return GooglePay$1.ApplePayHelpers.getDefaultSupportedNetworks();
789
+ return ApplePayHelpers.getDefaultSupportedNetworks();
669
790
  }
670
791
  async abort() {
671
792
  this.applePayService.abortPaymentSession();
@@ -673,7 +794,7 @@ const ApplePay = class {
673
794
  this.applePayCancelled.emit();
674
795
  }
675
796
  render() {
676
- if (!GooglePay$1.checkoutStore.applePayEnabled) {
797
+ if (!checkout_store.checkoutStore.applePayEnabled) {
677
798
  // Render nothing when Apple Pay is disabled at the checkout settings level
678
799
  return null;
679
800
  }
@@ -681,7 +802,7 @@ const ApplePay = class {
681
802
  this.isAvailable &&
682
803
  this.canMakePayments &&
683
804
  this.isConfigValid;
684
- return (index.h(styledHost.StyledHost, null, GooglePay$1.checkoutStore.checkoutLoaded && (index.h("script", { async: true, src: 'https://applepay.cdn-apple.com/jsapi/1.latest/apple-pay-sdk.js', onLoad: () => {
805
+ return (index.h(styledHost.StyledHost, null, checkout_store.checkoutStore.checkoutLoaded && (index.h("script", { async: true, src: 'https://applepay.cdn-apple.com/jsapi/1.latest/apple-pay-sdk.js', onLoad: () => {
685
806
  this.initializeApplePay();
686
807
  } })), index.h("div", { class: 'apple-pay-container' }, index.h(ApplePaySkeleton, { isLoading: this.isLoading }), isReady && (index.h(ApplePayButton, { buttonType: this.buttonType, buttonStyle: this.buttonStyle, disabled: this.disabled, isProcessing: this.isProcessing, isAvailable: this.isAvailable, clickHandler: this.handleApplePayClick, width: this.width, height: this.height }))), index.h("style", null, `
687
808
  .apple-pay-container {
@@ -704,963 +825,10 @@ const Summary = class {
704
825
  index.registerInstance(this, hostRef);
705
826
  }
706
827
  render() {
707
- return (index.h(styledHost.StyledHost, { key: '3ebaf90f9085614d44043d9b5ba7de3f926bf6f1' }, index.h("section", { key: '888ea6f17ece8e78b7ddf9302be5b1b355cd54c6' }, index.h("div", { key: 'bb7db155a31ceb9e824c5290b8fb8d8713622bdd' }, index.h("div", { key: 'dc954f18e824dabfb09fc727aeb87685020e2d1e', part: parts.text }, GooglePay$1.checkoutStore === null || GooglePay$1.checkoutStore === void 0 ? void 0 : GooglePay$1.checkoutStore.paymentDescription), index.h("div", { key: 'e7f6b12c142655fc967bd6a37e00193b9f743f84' }, index.h("span", { key: '25996f66626d428385422d72f5e2bba1a8301628', part: parts.text }, "Total"), "\u00A0", index.h("span", { key: '958bd1242ac23e13e66b73563d2c6f73499d2574', part: parts.text }, utils.formatCurrency(+(GooglePay$1.checkoutStore === null || GooglePay$1.checkoutStore === void 0 ? void 0 : GooglePay$1.checkoutStore.totalAmount))))))));
828
+ return (index.h(styledHost.StyledHost, { key: 'fd2c61dcafdc800d0064c19d29c6e007aed5adb5' }, index.h("section", { key: 'f2abef1233f3ccad3982d10c61ec5765e13e27a5' }, index.h("div", { key: '713d66ef6f7e2fc73135e765069baba6df976f52' }, index.h("div", { key: 'b8dd28f257948aa317366fe3ea6d2bc4911ef164', part: parts.text }, checkout_store.checkoutStore === null || checkout_store.checkoutStore === void 0 ? void 0 : checkout_store.checkoutStore.paymentDescription), index.h("div", { key: '675676b40de7dc27d07bfafc0eee77eb855a3d26' }, index.h("span", { key: 'cbd47994d9c3f1518741a298de3f5d62a0ad5313', part: parts.text }, "Total"), "\u00A0", index.h("span", { key: '614748853f666f1b072d4fa9b14ee15ef5717112', part: parts.text }, utils.formatCurrency(+(checkout_store.checkoutStore === null || checkout_store.checkoutStore === void 0 ? void 0 : checkout_store.checkoutStore.totalAmount))))))));
708
829
  }
709
830
  };
710
831
 
711
- const PROCESS_TOKEN_ENDPOINT = 'google_pay/process_token';
712
- class GooglePayService {
713
- constructor() {
714
- this.api = Api.Api();
715
- }
716
- /**
717
- * Initialize Google Pay configuration
718
- */
719
- initialize(googlePayConfig) {
720
- console.log('[GooglePayService] initialize: Starting initialization', {
721
- config: googlePayConfig,
722
- });
723
- this.googlePayConfig = new GooglePay$1.GooglePayConfig(googlePayConfig);
724
- console.log('[GooglePayService] initialize: Config object created', {
725
- isValid: this.googlePayConfig.isValid,
726
- environment: this.googlePayConfig.environment,
727
- merchantId: this.googlePayConfig.merchantId,
728
- });
729
- if (!this.googlePayConfig.isValid) {
730
- console.error('[GooglePayService] initialize: Invalid configuration');
731
- throw new Error('Invalid Google Pay configuration provided');
732
- }
733
- // Create Google Pay client
734
- console.log('[GooglePayService] initialize: Creating Google Pay client', {
735
- environment: this.googlePayConfig.environment,
736
- });
737
- this.googlePayClient = GooglePay$1.GooglePayHelpers.createGooglePayClient(this.googlePayConfig.environment);
738
- if (!this.googlePayClient) {
739
- console.error('[GooglePayService] initialize: Failed to create client');
740
- throw new Error('Failed to create Google Pay client');
741
- }
742
- console.log('[GooglePayService] initialize: Client created successfully', {
743
- hasClient: !!this.googlePayClient,
744
- });
745
- }
746
- /**
747
- * Process Google Pay payment via API
748
- */
749
- async processPayment(authToken, accountId, payload) {
750
- var _a;
751
- const endpoint = PROCESS_TOKEN_ENDPOINT;
752
- console.log('[GooglePayService] processPayment: Starting', {
753
- endpoint,
754
- hasAuthToken: !!authToken,
755
- accountId,
756
- payload,
757
- });
758
- try {
759
- const result = await this.api.post({
760
- endpoint,
761
- authToken,
762
- body: payload,
763
- headers: {
764
- 'sub-account': accountId,
765
- },
766
- });
767
- console.log('[GooglePayService] processPayment: API response received', {
768
- hasId: !!result.id,
769
- hasToken: !!((_a = result.data) === null || _a === void 0 ? void 0 : _a.token),
770
- result,
771
- });
772
- const success = result.id && !!result.data.token;
773
- console.log('[GooglePayService] processPayment: Result', { success });
774
- return {
775
- success,
776
- data: result,
777
- };
778
- }
779
- catch (error) {
780
- console.error('[GooglePayService] processPayment: API error', error);
781
- throw new Error('Google Pay payment processing failed');
782
- }
783
- }
784
- /**
785
- * Check if Google Pay is available on this device/browser
786
- */
787
- isAvailable() {
788
- const isSupported = GooglePay$1.GooglePayHelpers.isGooglePaySupported();
789
- const hasClient = !!this.googlePayClient;
790
- const result = isSupported && hasClient;
791
- console.log('[GooglePayService] isAvailable:', {
792
- isSupported,
793
- hasClient,
794
- result,
795
- });
796
- return result;
797
- }
798
- /**
799
- * Check if the user can make payments with Google Pay
800
- */
801
- async canMakePayments() {
802
- console.log('[GooglePayService] canMakePayments: Checking', {
803
- hasClient: !!this.googlePayClient,
804
- hasConfig: !!this.googlePayConfig,
805
- });
806
- if (!this.googlePayClient || !this.googlePayConfig) {
807
- console.warn('[GooglePayService] canMakePayments: Missing client or config');
808
- return false;
809
- }
810
- try {
811
- const baseRequest = GooglePay$1.GooglePayHelpers.createBasePaymentDataRequest();
812
- console.log('[GooglePayService] canMakePayments: Calling isReadyToPay', {
813
- baseRequest,
814
- });
815
- const response = await this.googlePayClient.isReadyToPay(baseRequest);
816
- console.log('[GooglePayService] canMakePayments: Response received', {
817
- result: response.result,
818
- response,
819
- });
820
- return response.result;
821
- }
822
- catch (error) {
823
- console.error('[GooglePayService] canMakePayments: Error', error);
824
- return false;
825
- }
826
- }
827
- /**
828
- * Start Google Pay payment session
829
- */
830
- async startPaymentSession(paymentDataRequest, authToken, accountId) {
831
- var _a;
832
- console.log('[GooglePayService] startPaymentSession: Starting', {
833
- hasConfig: !!this.googlePayConfig,
834
- hasClient: !!this.googlePayClient,
835
- hasAuthToken: !!authToken,
836
- accountId,
837
- paymentDataRequest,
838
- });
839
- if (!this.googlePayConfig || !this.googlePayClient) {
840
- console.error('[GooglePayService] startPaymentSession: Not initialized');
841
- throw new Error('Google Pay not initialized. Call initialize() first.');
842
- }
843
- if (!this.isAvailable()) {
844
- console.error('[GooglePayService] startPaymentSession: Not available');
845
- throw new Error('Google Pay is not available on this device/browser');
846
- }
847
- const request = new GooglePay$1.GooglePayPaymentDataRequest(paymentDataRequest);
848
- console.log('[GooglePayService] startPaymentSession: Request object created', {
849
- isValid: request.isValid,
850
- request,
851
- });
852
- if (!request.isValid) {
853
- console.error('[GooglePayService] startPaymentSession: Invalid request');
854
- throw new Error('Invalid payment data request provided');
855
- }
856
- try {
857
- console.log('[GooglePayService] startPaymentSession: Loading payment data...');
858
- const paymentData = await this.googlePayClient.loadPaymentData(request);
859
- console.log('[GooglePayService] startPaymentSession: Payment data loaded', {
860
- hasPaymentData: !!paymentData,
861
- paymentMethodData: paymentData === null || paymentData === void 0 ? void 0 : paymentData.paymentMethodData,
862
- });
863
- // Build top-level snake_case fields from Google Pay tokenizationData
864
- const tokenizationData = (_a = paymentData === null || paymentData === void 0 ? void 0 : paymentData.paymentMethodData) === null || _a === void 0 ? void 0 : _a.tokenizationData;
865
- console.log('[GooglePayService] startPaymentSession: Extracted tokenization data', {
866
- hasTokenizationData: !!tokenizationData,
867
- tokenizationData,
868
- });
869
- const tokenObj = (() => {
870
- if ((tokenizationData === null || tokenizationData === void 0 ? void 0 : tokenizationData.token) &&
871
- typeof tokenizationData.token === 'string') {
872
- try {
873
- const parsed = JSON.parse(tokenizationData.token);
874
- console.log('[GooglePayService] startPaymentSession: Parsed token', parsed);
875
- return parsed;
876
- }
877
- catch (_e) {
878
- console.warn('[GooglePayService] startPaymentSession: Failed to parse token, using raw', _e);
879
- return tokenizationData;
880
- }
881
- }
882
- return tokenizationData;
883
- })();
884
- const tokenProcessRequest = {
885
- protocolVersion: tokenObj === null || tokenObj === void 0 ? void 0 : tokenObj.protocolVersion,
886
- signature: tokenObj === null || tokenObj === void 0 ? void 0 : tokenObj.signature,
887
- intermediateSigningKey: (tokenObj === null || tokenObj === void 0 ? void 0 : tokenObj.intermediateSigningKey)
888
- ? {
889
- signedKey: tokenObj.intermediateSigningKey.signedKey,
890
- signatures: tokenObj.intermediateSigningKey.signatures,
891
- }
892
- : undefined,
893
- signedMessage: tokenObj === null || tokenObj === void 0 ? void 0 : tokenObj.signedMessage,
894
- };
895
- console.log('[GooglePayService] startPaymentSession: Token process request created', {
896
- hasProtocolVersion: !!tokenProcessRequest.protocolVersion,
897
- hasSignature: !!tokenProcessRequest.signature,
898
- hasSignedMessage: !!tokenProcessRequest.signedMessage,
899
- hasIntermediateSigningKey: !!tokenProcessRequest.intermediateSigningKey,
900
- });
901
- console.log('[GooglePayService] startPaymentSession: Processing payment...');
902
- const paymentResult = await this.processPayment(authToken, accountId, tokenProcessRequest);
903
- console.log('[GooglePayService] startPaymentSession: Payment processed', paymentResult);
904
- if (paymentResult.success) {
905
- console.log('[GooglePayService] startPaymentSession: Payment successful', {
906
- paymentMethodId: paymentResult.data.id,
907
- });
908
- return {
909
- success: true,
910
- paymentData: paymentData,
911
- paymentMethodId: paymentResult.data.id,
912
- };
913
- }
914
- else {
915
- console.error('[GooglePayService] startPaymentSession: Payment processing failed');
916
- return {
917
- success: false,
918
- error: {
919
- code: 'PAYMENT_PROCESSING_ERROR',
920
- message: 'Payment processing failed',
921
- },
922
- };
923
- }
924
- }
925
- catch (error) {
926
- console.error('[GooglePayService] startPaymentSession: Exception caught', error);
927
- // Handle different types of errors
928
- if (error && typeof error === 'object' && 'statusCode' in error) {
929
- const googlePayError = error;
930
- console.log('[GooglePayService] startPaymentSession: Google Pay error', {
931
- statusCode: googlePayError.statusCode,
932
- statusMessage: googlePayError.statusMessage,
933
- });
934
- switch (googlePayError.statusCode) {
935
- case 'CANCELED':
936
- console.log('[GooglePayService] startPaymentSession: User cancelled');
937
- return {
938
- success: false,
939
- error: {
940
- code: 'USER_CANCELLED',
941
- message: 'User cancelled the Google Pay session',
942
- },
943
- };
944
- case 'DEVELOPER_ERROR':
945
- console.error('[GooglePayService] startPaymentSession: Developer error');
946
- return {
947
- success: false,
948
- error: {
949
- code: 'DEVELOPER_ERROR',
950
- message: 'Google Pay configuration error',
951
- },
952
- };
953
- default:
954
- console.error('[GooglePayService] startPaymentSession: Unknown error', {
955
- statusCode: googlePayError.statusCode,
956
- });
957
- return {
958
- success: false,
959
- error: {
960
- code: 'PAYMENT_ERROR',
961
- message: googlePayError.statusMessage || 'Google Pay payment failed',
962
- },
963
- };
964
- }
965
- }
966
- console.error('[GooglePayService] startPaymentSession: Generic error', error);
967
- return {
968
- success: false,
969
- error: {
970
- code: 'PAYMENT_ERROR',
971
- message: error instanceof Error
972
- ? error.message
973
- : 'Google Pay payment failed',
974
- },
975
- };
976
- }
977
- }
978
- /**
979
- * Create Google Pay button element
980
- */
981
- createButton(options) {
982
- if (!this.googlePayClient || !this.googlePayConfig) {
983
- return null;
984
- }
985
- try {
986
- return this.googlePayClient.createButton({
987
- onClick: options.onClick,
988
- buttonType: options.buttonType,
989
- buttonSizeMode: options.buttonSizeMode,
990
- buttonColor: options.buttonColor,
991
- buttonLocale: options.buttonLocale,
992
- });
993
- }
994
- catch (_error) {
995
- return null;
996
- }
997
- }
998
- /**
999
- * Prefetch payment data for faster loading
1000
- */
1001
- prefetchPaymentData(paymentDataRequest) {
1002
- console.log('[GooglePayService] prefetchPaymentData: Starting', {
1003
- hasClient: !!this.googlePayClient,
1004
- paymentDataRequest,
1005
- });
1006
- if (!this.googlePayClient) {
1007
- console.warn('[GooglePayService] prefetchPaymentData: No client available');
1008
- return;
1009
- }
1010
- const request = new GooglePay$1.GooglePayPaymentDataRequest(paymentDataRequest);
1011
- console.log('[GooglePayService] prefetchPaymentData: Request created', {
1012
- isValid: request.isValid,
1013
- });
1014
- if (!request.isValid) {
1015
- console.warn('[GooglePayService] prefetchPaymentData: Invalid request');
1016
- return;
1017
- }
1018
- try {
1019
- console.log('[GooglePayService] prefetchPaymentData: Calling prefetchPaymentData');
1020
- this.googlePayClient.prefetchPaymentData(request);
1021
- console.log('[GooglePayService] prefetchPaymentData: Prefetch complete');
1022
- }
1023
- catch (error) {
1024
- console.error('[GooglePayService] prefetchPaymentData: Error', error);
1025
- }
1026
- }
1027
- /**
1028
- * Create a basic payment data request
1029
- */
1030
- static createPaymentDataRequest(amount, label, countryCode = 'US', currencyCode = 'USD', merchantName, merchantId) {
1031
- var _a;
1032
- console.log('[GooglePayService] createPaymentDataRequest: Creating request', {
1033
- amount,
1034
- label,
1035
- countryCode,
1036
- currencyCode,
1037
- merchantName,
1038
- });
1039
- const request = {
1040
- apiVersion: 2,
1041
- apiVersionMinor: 0,
1042
- allowedPaymentMethods: [GooglePay$1.GooglePayHelpers.createPaymentMethodData()],
1043
- transactionInfo: {
1044
- countryCode,
1045
- currencyCode,
1046
- totalPriceStatus: 'FINAL',
1047
- totalPrice: GooglePay$1.GooglePayHelpers.formatAmount(amount),
1048
- totalPriceLabel: label,
1049
- },
1050
- merchantInfo: {
1051
- merchantId,
1052
- merchantName,
1053
- },
1054
- };
1055
- console.log('[GooglePayService] createPaymentDataRequest: Request created', {
1056
- apiVersion: request.apiVersion,
1057
- apiVersionMinor: request.apiVersionMinor,
1058
- transactionInfo: request.transactionInfo,
1059
- merchantInfo: request.merchantInfo,
1060
- allowedPaymentMethodsCount: (_a = request.allowedPaymentMethods) === null || _a === void 0 ? void 0 : _a.length,
1061
- });
1062
- return request;
1063
- }
1064
- /**
1065
- * Get current configuration
1066
- */
1067
- getGooglePayConfig() {
1068
- return this.googlePayConfig;
1069
- }
1070
- /**
1071
- * Get current Google Pay client
1072
- */
1073
- getGooglePayClient() {
1074
- return this.googlePayClient;
1075
- }
1076
- }
1077
-
1078
- const GooglePaySkeleton = (props) => {
1079
- const { isLoading } = props;
1080
- if (!isLoading) {
1081
- return null;
1082
- }
1083
- return (index.h("div", { class: 'container-fluid p-0' }, index.h("div", { class: 'row mb-3' }, index.h("div", { class: 'col-12 align-content-center' }, index.h(skeleton.Skeleton, { height: '44px', width: '100%', styles: { borderRadius: "8px" } })))));
1084
- };
1085
-
1086
- const ProcessingSpinner = () => (index.h("div", { class: 'processing-overlay' }, index.h("div", { class: 'spinner' }), index.h("span", null, "Processing...")));
1087
- const GooglePayButton = (props) => {
1088
- const getGooglePayButtonClass = () => {
1089
- let classes = "google-pay-button";
1090
- // Button style
1091
- switch (props.buttonStyle) {
1092
- case GooglePay$1.GooglePayButtonStyle.WHITE:
1093
- classes += " google-pay-button-white";
1094
- break;
1095
- case GooglePay$1.GooglePayButtonStyle.BLACK:
1096
- default:
1097
- classes += " google-pay-button-black";
1098
- break;
1099
- }
1100
- // Button type
1101
- switch (props.buttonType) {
1102
- case GooglePay$1.GooglePayButtonType.BUY:
1103
- classes += " google-pay-button-type-buy";
1104
- break;
1105
- case GooglePay$1.GooglePayButtonType.BOOK:
1106
- classes += " google-pay-button-type-book";
1107
- break;
1108
- case GooglePay$1.GooglePayButtonType.CHECKOUT:
1109
- classes += " google-pay-button-type-checkout";
1110
- break;
1111
- case GooglePay$1.GooglePayButtonType.DONATE:
1112
- classes += " google-pay-button-type-donate";
1113
- break;
1114
- case GooglePay$1.GooglePayButtonType.ORDER:
1115
- classes += " google-pay-button-type-order";
1116
- break;
1117
- case GooglePay$1.GooglePayButtonType.PAY:
1118
- classes += " google-pay-button-type-pay";
1119
- break;
1120
- case GooglePay$1.GooglePayButtonType.SUBSCRIBE:
1121
- classes += " google-pay-button-type-subscribe";
1122
- break;
1123
- case GooglePay$1.GooglePayButtonType.PLAIN:
1124
- default:
1125
- classes += " google-pay-button-type-plain";
1126
- break;
1127
- }
1128
- // Size mode
1129
- switch (props.buttonSizeMode) {
1130
- case GooglePay$1.GooglePayButtonSizeMode.FILL:
1131
- classes += " google-pay-button-fill";
1132
- break;
1133
- case GooglePay$1.GooglePayButtonSizeMode.STATIC:
1134
- default:
1135
- classes += " google-pay-button-static";
1136
- break;
1137
- }
1138
- if (props.disabled || props.isProcessing || !props.isAvailable) {
1139
- classes += " disabled";
1140
- }
1141
- return classes;
1142
- };
1143
- const getButtonStyles = () => {
1144
- const styles = {};
1145
- if (props.buttonSizeMode === GooglePay$1.GooglePayButtonSizeMode.FILL) {
1146
- styles.width = '100%';
1147
- styles.minWidth = '200px';
1148
- }
1149
- else {
1150
- styles.width = props.width || '200px';
1151
- }
1152
- styles.height = props.height || '48px';
1153
- return styles;
1154
- };
1155
- const handleClick = () => {
1156
- if (!props.disabled &&
1157
- !props.isProcessing &&
1158
- props.isAvailable &&
1159
- props.clickHandler) {
1160
- props.clickHandler();
1161
- }
1162
- };
1163
- return (index.h("div", { class: "google-pay-button-container" }, index.h("button", Object.assign({ class: getGooglePayButtonClass(), style: getButtonStyles(), onClick: handleClick, disabled: props.disabled || props.isProcessing || !props.isAvailable, "aria-label": "Google Pay", type: "button" }, props), props.isProcessing && ProcessingSpinner(), index.h("div", { class: 'google-pay-button-content' }, index.h("svg", { width: "41", height: "17", xmlns: "http://www.w3.org/2000/svg" }, index.h("g", { fill: "none", "fill-rule": "evenodd" }, index.h("path", { d: "M19.526 2.635v4.083h2.518c.6 0 1.096-.202 1.488-.605.403-.402.605-.882.605-1.437 0-.544-.202-1.018-.605-1.422-.392-.413-.888-.62-1.488-.62h-2.518zm0 5.52v4.736h-1.504V1.198h3.99c1.013 0 1.873.337 2.582 1.012.72.675 1.08 1.497 1.08 2.466 0 .991-.36 1.819-1.08 2.482-.697.665-1.559.996-2.583.996h-2.485v.001zm7.668 2.287c0 .392.166.718.499.98.332.26.722.391 1.168.391.633 0 1.196-.234 1.692-.701.497-.469.744-1.019.744-1.65-.469-.37-1.123-.555-1.962-.555-.61 0-1.12.148-1.528.442-.409.294-.613.657-.613 1.093m1.946-5.815c1.112 0 1.989.297 2.633.89.642.594.964 1.408.964 2.442v4.932h-1.439v-1.11h-.065c-.622.914-1.45 1.372-2.486 1.372-.882 0-1.621-.262-2.215-.784-.594-.523-.891-1.176-.891-1.96 0-.828.313-1.486.94-1.976s1.463-.735 2.51-.735c.892 0 1.629.163 2.206.49v-.344c0-.522-.207-.966-.621-1.33a2.132 2.132 0 0 0-1.455-.547c-.84 0-1.504.353-1.995 1.062l-1.324-.834c.73-1.045 1.81-1.568 3.238-1.568m11.853.262l-5.02 11.53H34.42l1.864-4.034-3.302-7.496h1.635l2.387 5.749h.032l2.322-5.75z", fill: "#FFF" }), index.h("path", { d: "M13.448 7.134c0-.473-.04-.93-.116-1.366H6.988v2.588h3.634a3.11 3.11 0 0 1-1.344 2.042v1.68h2.169c1.27-1.17 2.001-2.9 2.001-4.944", fill: "#4285F4" }), index.h("path", { d: "M6.988 13.7c1.816 0 3.344-.595 4.459-1.621l-2.169-1.681c-.603.406-1.38.643-2.29.643-1.754 0-3.244-1.182-3.776-2.774H.978v1.731a6.728 6.728 0 0 0 6.01 3.703", fill: "#34A853" }), index.h("path", { d: "M3.212 8.267a4.034 4.034 0 0 1 0-2.572V3.964H.978A6.678 6.678 0 0 0 .261 6.98c0 1.085.26 2.11.717 3.017l2.234-1.731z", fill: "#FABB05" }), index.h("path", { d: "M6.988 2.921c.992 0 1.88.34 2.58 1.008v.001l1.92-1.918C10.324.928 8.804.262 6.989.262a6.728 6.728 0 0 0-6.01 3.702l2.234 1.731c.532-1.592 2.022-2.774 3.776-2.774", fill: "#E94235" }))))), index.h("style", null, `
1164
- .google-pay-button-container {
1165
- display: block;
1166
- position: relative;
1167
- }
1168
-
1169
- .google-pay-button {
1170
- display: flex;
1171
- align-items: center;
1172
- justify-content: center;
1173
- border: none;
1174
- border-radius: 4px;
1175
- cursor: pointer;
1176
- font-size: 14px;
1177
- font-weight: 500;
1178
- letter-spacing: 0.25px;
1179
- line-height: 16px;
1180
- outline: none;
1181
- padding: 0 20px;
1182
- position: relative;
1183
- min-width: 140px;
1184
- min-height: 48px;
1185
- }
1186
-
1187
- /* Button styles */
1188
- .google-pay-button.google-pay-button-black {
1189
- background-color: #000;
1190
- color: #fff;
1191
- }
1192
-
1193
- .google-pay-button.google-pay-button-white {
1194
- background-color: #fff;
1195
- color: #3c4043;
1196
- }
1197
-
1198
- /* Button content */
1199
- .google-pay-button-content {
1200
- display: flex;
1201
- align-items: center;
1202
- justify-content: center;
1203
- gap: 8px;
1204
- white-space: nowrap;
1205
- }
1206
-
1207
- .google-g-logo {
1208
- width: 20px;
1209
- height: 20px;
1210
- flex-shrink: 0;
1211
- }
1212
-
1213
- .pay-text {
1214
- font-family: 'Google Sans', arial, sans-serif;
1215
- font-size: 14px;
1216
- font-weight: 500;
1217
- margin-left: 8px;
1218
- }
1219
-
1220
- /* Button types - text content handled by ::before pseudo-element */
1221
- .google-pay-button-type-buy .google-pay-button-content::before {
1222
- content: 'Buy with';
1223
- margin-right: 8px;
1224
- }
1225
-
1226
- .google-pay-button-type-book .google-pay-button-content::before {
1227
- content: 'Book with';
1228
- margin-right: 8px;
1229
- }
1230
-
1231
- .google-pay-button-type-checkout .google-pay-button-content::before {
1232
- content: 'Checkout with';
1233
- margin-right: 8px;
1234
- }
1235
-
1236
- .google-pay-button-type-donate .google-pay-button-content::before {
1237
- content: 'Donate with';
1238
- margin-right: 8px;
1239
- }
1240
-
1241
- .google-pay-button-type-order .google-pay-button-content::before {
1242
- content: 'Order with';
1243
- margin-right: 8px;
1244
- }
1245
-
1246
- .google-pay-button-type-pay .google-pay-button-content::before {
1247
- content: 'Pay with';
1248
- margin-right: 8px;
1249
- }
1250
-
1251
- .google-pay-button-type-subscribe .google-pay-button-content::before {
1252
- content: 'Subscribe with';
1253
- margin-right: 8px;
1254
- }
1255
-
1256
- /* Size modes */
1257
- .google-pay-button.google-pay-button-fill {
1258
- width: 100%;
1259
- min-width: 200px;
1260
- }
1261
-
1262
- .google-pay-button.google-pay-button-static {
1263
- width: auto;
1264
- }
1265
-
1266
- /* Hover and focus states */
1267
- .google-pay-button:hover:not(.disabled) {
1268
- box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.15), 0 1px 3px 1px rgba(0, 0, 0, 0.30);
1269
- }
1270
-
1271
- .google-pay-button:focus:not(.disabled) {
1272
- box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.15), 0 1px 3px 1px rgba(0, 0, 0, 0.30);
1273
- }
1274
-
1275
- .google-pay-button:active:not(.disabled) {
1276
- box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.15), 0 1px 3px 1px rgba(0, 0, 0, 0.30);
1277
- transform: translateY(1px);
1278
- }
1279
-
1280
- /* Disabled state */
1281
- .google-pay-button.disabled {
1282
- opacity: 0.5;
1283
- cursor: not-allowed;
1284
- box-shadow: none;
1285
- }
1286
-
1287
- .google-pay-button.disabled:hover,
1288
- .google-pay-button.disabled:focus,
1289
- .google-pay-button.disabled:active {
1290
- box-shadow: none;
1291
- transform: none;
1292
- }
1293
-
1294
- /* Processing overlay */
1295
- .processing-overlay {
1296
- position: absolute;
1297
- top: 0;
1298
- left: 0;
1299
- right: 0;
1300
- bottom: 0;
1301
- display: flex;
1302
- align-items: center;
1303
- justify-content: center;
1304
- gap: 8px;
1305
- background: rgba(0, 0, 0, 0.8);
1306
- color: white;
1307
- border-radius: 4px;
1308
- font-size: 14px;
1309
- font-weight: 500;
1310
- }
1311
-
1312
- .spinner {
1313
- width: 16px;
1314
- height: 16px;
1315
- border: 2px solid rgba(255, 255, 255, 0.3);
1316
- border-top: 2px solid #fff;
1317
- border-radius: 50%;
1318
- animation: spin 1s linear infinite;
1319
- }
1320
-
1321
- @keyframes spin {
1322
- 0% { transform: rotate(0deg); }
1323
- 100% { transform: rotate(360deg); }
1324
- }
1325
-
1326
- /* Responsive design */
1327
- @media (max-width: 480px) {
1328
- .google-pay-button {
1329
- width: 100% !important;
1330
- min-width: 200px;
1331
- }
1332
- }
1333
- `)));
1334
- };
1335
-
1336
- const GooglePay = class {
1337
- constructor(hostRef) {
1338
- index.registerInstance(this, hostRef);
1339
- this.googlePayCancelled = index.createEvent(this, "googlePayCancelled");
1340
- this.googlePayCompleted = index.createEvent(this, "googlePayCompleted");
1341
- this.googlePayStarted = index.createEvent(this, "googlePayStarted");
1342
- this.unsubscribes = [];
1343
- this.canMakePayments = false;
1344
- this.error = null;
1345
- this.isAvailable = false;
1346
- this.isLoading = true;
1347
- this.isProcessing = false;
1348
- this.buttonSizeMode = GooglePay$1.GooglePayButtonSizeMode.FILL;
1349
- this.buttonStyle = GooglePay$1.GooglePayButtonStyle.BLACK;
1350
- this.buttonType = GooglePay$1.GooglePayButtonType.PLAIN;
1351
- this.countryCode = "US";
1352
- this.disabled = false;
1353
- this.environment = GooglePay$1.GooglePayEnvironment.PRODUCTION;
1354
- this.merchantId = "gateway:justifi";
1355
- this.merchantName = "justifi";
1356
- this.showSkeleton = true;
1357
- this.handleGooglePayClick = async () => {
1358
- var _a;
1359
- console.log('[GooglePay] handleGooglePayClick: Button clicked', {
1360
- isProcessing: this.isProcessing,
1361
- disabled: this.disabled,
1362
- isAvailable: this.isAvailable,
1363
- canMakePayments: this.canMakePayments,
1364
- });
1365
- if (this.isProcessing ||
1366
- this.disabled ||
1367
- !this.isAvailable ||
1368
- !this.canMakePayments) {
1369
- console.warn('[GooglePay] handleGooglePayClick: Payment blocked', {
1370
- reason: this.isProcessing ? 'isProcessing' :
1371
- this.disabled ? 'disabled' :
1372
- !this.isAvailable ? 'notAvailable' :
1373
- !this.canMakePayments ? 'cannotMakePayments' : 'unknown',
1374
- });
1375
- return;
1376
- }
1377
- try {
1378
- console.log('[GooglePay] handleGooglePayClick: Starting payment session');
1379
- this.isProcessing = true;
1380
- this.error = null;
1381
- this.googlePayStarted.emit();
1382
- console.log('[GooglePay] handleGooglePayClick: googlePayStarted event emitted');
1383
- const paymentDataRequest = this.createPaymentDataRequest();
1384
- console.log('[GooglePay] handleGooglePayClick: Starting payment session with service', {
1385
- hasAuthToken: !!GooglePay$1.checkoutStore.authToken,
1386
- accountId: GooglePay$1.checkoutStore.accountId,
1387
- });
1388
- const result = await this.googlePayService.startPaymentSession(paymentDataRequest, GooglePay$1.checkoutStore.authToken, GooglePay$1.checkoutStore.accountId);
1389
- console.log('[GooglePay] handleGooglePayClick: Payment session result', result);
1390
- if (result.success) {
1391
- console.log('[GooglePay] handleGooglePayClick: Payment successful', {
1392
- paymentMethodId: result.paymentMethodId,
1393
- hasPaymentData: !!result.paymentData,
1394
- });
1395
- this.googlePayCompleted.emit({
1396
- success: true,
1397
- paymentData: result.paymentData,
1398
- paymentMethodId: result.paymentMethodId,
1399
- });
1400
- }
1401
- else {
1402
- console.error('[GooglePay] handleGooglePayClick: Payment failed', {
1403
- error: result.error,
1404
- });
1405
- this.googlePayCompleted.emit({
1406
- success: false,
1407
- error: result.error,
1408
- });
1409
- if (((_a = result.error) === null || _a === void 0 ? void 0 : _a.code) === "USER_CANCELLED") {
1410
- console.log('[GooglePay] handleGooglePayClick: User cancelled payment');
1411
- this.googlePayCancelled.emit();
1412
- }
1413
- }
1414
- }
1415
- catch (error) {
1416
- console.error('[GooglePay] handleGooglePayClick: Exception during payment', error);
1417
- const errorMessage = error instanceof Error ? error.message : "Payment failed";
1418
- this.error = errorMessage;
1419
- this.googlePayCompleted.emit({
1420
- success: false,
1421
- error: errorMessage,
1422
- });
1423
- }
1424
- finally {
1425
- this.isProcessing = false;
1426
- console.log('[GooglePay] handleGooglePayClick: Payment flow complete', {
1427
- isProcessing: this.isProcessing,
1428
- error: this.error,
1429
- });
1430
- }
1431
- };
1432
- }
1433
- watchConfigChange() {
1434
- console.log('[GooglePay] watchConfigChange: Configuration changed', {
1435
- merchantId: this.merchantId,
1436
- environment: this.environment,
1437
- });
1438
- this.initializeGooglePay();
1439
- }
1440
- componentWillLoad() {
1441
- console.log('[GooglePay] componentWillLoad: Initializing GooglePayService');
1442
- this.googlePayService = new GooglePayService();
1443
- console.log('[GooglePay] componentWillLoad: GooglePayService created', {
1444
- service: this.googlePayService,
1445
- });
1446
- }
1447
- componentDidLoad() {
1448
- console.log('[GooglePay] componentDidLoad: Setting up store subscriptions', {
1449
- checkoutLoaded: GooglePay$1.checkoutStore.checkoutLoaded,
1450
- paymentAmount: GooglePay$1.checkoutStore.paymentAmount,
1451
- paymentCurrency: GooglePay$1.checkoutStore.paymentCurrency,
1452
- paymentDescription: GooglePay$1.checkoutStore.paymentDescription,
1453
- });
1454
- const unsub = GooglePay$1.onChange("paymentAmount", () => {
1455
- console.log('[GooglePay] paymentAmount changed:', GooglePay$1.checkoutStore.paymentAmount);
1456
- this.prefetchPaymentData();
1457
- });
1458
- if (typeof unsub === 'function')
1459
- this.unsubscribes.push(unsub);
1460
- const unsubCurrency = GooglePay$1.onChange("paymentCurrency", () => {
1461
- console.log('[GooglePay] paymentCurrency changed:', GooglePay$1.checkoutStore.paymentCurrency);
1462
- this.prefetchPaymentData();
1463
- });
1464
- if (typeof unsubCurrency === 'function')
1465
- this.unsubscribes.push(unsubCurrency);
1466
- const unsubDesc = GooglePay$1.onChange("paymentDescription", () => {
1467
- console.log('[GooglePay] paymentDescription changed:', GooglePay$1.checkoutStore.paymentDescription);
1468
- this.prefetchPaymentData();
1469
- });
1470
- if (typeof unsubDesc === 'function')
1471
- this.unsubscribes.push(unsubDesc);
1472
- }
1473
- disconnectedCallback() {
1474
- this.unsubscribes.forEach((fn) => {
1475
- try {
1476
- fn();
1477
- }
1478
- catch (_a) { }
1479
- });
1480
- this.unsubscribes = [];
1481
- }
1482
- /**
1483
- * Returns supported authentication methods when Google Pay is available.
1484
- */
1485
- async getSupportedAuthMethods() {
1486
- if (!this.isAvailable) {
1487
- return [];
1488
- }
1489
- return GooglePay$1.GooglePayHelpers.getDefaultAuthMethods();
1490
- }
1491
- /**
1492
- * Returns supported card networks when Google Pay is available.
1493
- */
1494
- async getSupportedNetworks() {
1495
- if (!this.isAvailable) {
1496
- return [];
1497
- }
1498
- return GooglePay$1.GooglePayHelpers.getDefaultSupportedNetworks();
1499
- }
1500
- /**
1501
- * Select Google Pay in the modular checkout parent.
1502
- */
1503
- async handleSelectionClick() {
1504
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.GOOGLE_PAY };
1505
- }
1506
- /**
1507
- * Returns whether Google Pay is both available and can make payments.
1508
- */
1509
- async isSupported() {
1510
- return this.isAvailable && this.canMakePayments;
1511
- }
1512
- /**
1513
- * Prefetch payment data for faster load times of the Google Pay sheet.
1514
- */
1515
- async prefetchPaymentData() {
1516
- console.log('[GooglePay] prefetchPaymentData: Called', {
1517
- isAvailable: this.isAvailable,
1518
- canMakePayments: this.canMakePayments,
1519
- });
1520
- if (!this.isAvailable || !this.canMakePayments) {
1521
- console.warn('[GooglePay] prefetchPaymentData: Skipped - not available or cannot make payments');
1522
- return;
1523
- }
1524
- const paymentDataRequest = this.createPaymentDataRequest();
1525
- console.log('[GooglePay] prefetchPaymentData: Prefetching', { paymentDataRequest });
1526
- this.googlePayService.prefetchPaymentData(paymentDataRequest);
1527
- console.log('[GooglePay] prefetchPaymentData: Prefetch complete');
1528
- }
1529
- async initializeGooglePay() {
1530
- console.log('[GooglePay] initializeGooglePay: Starting initialization');
1531
- try {
1532
- this.isLoading = true;
1533
- this.error = null;
1534
- console.log('[GooglePay] initializeGooglePay: Checking payment amount', {
1535
- paymentAmount: GooglePay$1.checkoutStore.paymentAmount,
1536
- paymentCurrency: GooglePay$1.checkoutStore.paymentCurrency,
1537
- paymentDescription: GooglePay$1.checkoutStore.paymentDescription,
1538
- });
1539
- if (!GooglePay$1.checkoutStore.paymentAmount) {
1540
- console.error('[GooglePay] initializeGooglePay: Missing payment amount');
1541
- this.error = "Missing required Google Pay configuration";
1542
- this.isLoading = false;
1543
- return;
1544
- }
1545
- const googlePayConfig = {
1546
- environment: this.environment,
1547
- merchantId: this.merchantId,
1548
- merchantName: this.merchantName,
1549
- buttonType: this.buttonType,
1550
- buttonStyle: this.buttonStyle,
1551
- buttonSizeMode: this.buttonSizeMode,
1552
- };
1553
- console.log('[GooglePay] initializeGooglePay: Config created', googlePayConfig);
1554
- this.googlePayService.initialize(googlePayConfig);
1555
- console.log('[GooglePay] initializeGooglePay: Service initialized');
1556
- this.isAvailable = this.googlePayService.isAvailable();
1557
- console.log('[GooglePay] initializeGooglePay: Availability check', {
1558
- isAvailable: this.isAvailable,
1559
- });
1560
- if (!this.isAvailable) {
1561
- console.warn('[GooglePay] initializeGooglePay: Google Pay not available on device');
1562
- this.error = "Google Pay is not supported on this device";
1563
- this.isLoading = false;
1564
- return;
1565
- }
1566
- console.log('[GooglePay] initializeGooglePay: Checking canMakePayments...');
1567
- this.canMakePayments = await this.googlePayService.canMakePayments();
1568
- console.log('[GooglePay] initializeGooglePay: canMakePayments result', {
1569
- canMakePayments: this.canMakePayments,
1570
- });
1571
- if (!this.canMakePayments) {
1572
- console.warn('[GooglePay] initializeGooglePay: Cannot make payments');
1573
- this.error = "Google Pay is not available for payments";
1574
- this.isLoading = false;
1575
- return;
1576
- }
1577
- const paymentDataRequest = this.createPaymentDataRequest();
1578
- console.log('[GooglePay] initializeGooglePay: Prefetching payment data', {
1579
- paymentDataRequest,
1580
- });
1581
- this.googlePayService.prefetchPaymentData(paymentDataRequest);
1582
- console.log('[GooglePay] initializeGooglePay: Initialization complete');
1583
- }
1584
- catch (error) {
1585
- console.error('[GooglePay] initializeGooglePay: Error during initialization', error);
1586
- this.error =
1587
- error instanceof Error
1588
- ? error.message
1589
- : "Failed to initialize Google Pay";
1590
- }
1591
- finally {
1592
- this.isLoading = false;
1593
- console.log('[GooglePay] initializeGooglePay: Final state', {
1594
- isLoading: this.isLoading,
1595
- isAvailable: this.isAvailable,
1596
- canMakePayments: this.canMakePayments,
1597
- error: this.error,
1598
- });
1599
- }
1600
- }
1601
- createPaymentDataRequest() {
1602
- const request = GooglePayService.createPaymentDataRequest(GooglePay$1.checkoutStore.paymentAmount, GooglePay$1.checkoutStore.paymentDescription, this.countryCode, GooglePay$1.checkoutStore.paymentCurrency, this.merchantName, this.merchantId);
1603
- console.log('[GooglePay] createPaymentDataRequest: Created request', {
1604
- amount: GooglePay$1.checkoutStore.paymentAmount,
1605
- currency: GooglePay$1.checkoutStore.paymentCurrency,
1606
- description: GooglePay$1.checkoutStore.paymentDescription,
1607
- countryCode: this.countryCode,
1608
- merchantName: this.merchantName,
1609
- request,
1610
- });
1611
- return request;
1612
- }
1613
- render() {
1614
- const showError = !this.isLoading && !!this.error;
1615
- const showDeviceUnavailable = !this.isLoading && !this.error && !this.isAvailable;
1616
- const showPaymentsUnavailable = !this.isLoading && !this.error && this.isAvailable && !this.canMakePayments;
1617
- const showButton = !this.isLoading && !this.error && this.isAvailable && this.canMakePayments;
1618
- return (index.h(styledHost.StyledHost, { key: 'cf4dcfa14dd83683c0d6e811ea464968c38f38d6' }, GooglePay$1.checkoutStore.checkoutLoaded && (index.h("script", { key: 'e942fe8e2eb80ee0d2119e864c62d89a79d9d12a', async: true, src: 'https://pay.google.com/gp/p/js/pay.js', onLoad: () => {
1619
- console.log('[GooglePay] Script loaded: Google Pay JS library loaded successfully');
1620
- this.initializeGooglePay();
1621
- }, onError: (e) => {
1622
- console.error('[GooglePay] Script error: Failed to load Google Pay JS library', e);
1623
- } })), index.h("div", { key: '7ce1234392d3ea3abdcb1a385462cf740f4b98bb', class: 'google-pay-container' }, index.h(GooglePaySkeleton, { key: '3532e93f39bb69d76663c159bc6b1322a39e1361', isLoading: this.isLoading }), showError && (index.h("div", { key: '9e42e567d383522d03bc361008cb470fd2e2d602', class: 'google-pay-error', role: 'alert', "data-testid": 'gp-error' }, index.h("span", { key: '8b49d628ff8f5175d36f82e32191f1f3291e826f', class: 'error-icon' }, "\u26A0\uFE0F"), index.h("span", { key: 'b01e94934cd30b8dbad3127239ea625c51511d35', class: 'error-message' }, this.error))), showDeviceUnavailable && (index.h("div", { key: '12ad123c7516e9ce2ad1084f6b0c366e8bb5b9d5', class: 'google-pay-unavailable', "data-testid": 'gp-device-unavailable' }, index.h("span", { key: 'e0fa8f13423b6b545b340cc4b2b0411e833202c6', class: 'unavailable-message' }, "Google Pay is not available on this device"))), showPaymentsUnavailable && (index.h("div", { key: 'acb4c6661ca0aa6b944c8ed67642c4ad9effa1e5', class: 'google-pay-unavailable', "data-testid": 'gp-payments-unavailable' }, index.h("span", { key: '8a83dc8f5140d3ecade1fd68f69b5ebeaeb020d2', class: 'unavailable-message' }, "Google Pay is not available for payments"))), showButton && (index.h(GooglePayButton, { key: '46ea586c90aaa5eb909af4f1dfcb873a7ac50069', "data-testid": 'gp-button', buttonType: this.buttonType, buttonStyle: this.buttonStyle, buttonSizeMode: this.buttonSizeMode, disabled: this.disabled, isProcessing: this.isProcessing, isAvailable: this.isAvailable, clickHandler: this.handleGooglePayClick }))), index.h("style", { key: '8f77166ec7d772f0c51c74cdb166f9e8ae295088' }, `
1624
- .google-pay-container {
1625
- width: 100%;
1626
- }
1627
-
1628
- .google-pay-error {
1629
- display: flex;
1630
- align-items: center;
1631
- gap: 8px;
1632
- padding: 12px;
1633
- background: #fef2f2;
1634
- border: 1px solid #fecaca;
1635
- border-radius: 8px;
1636
- color: #dc2626;
1637
- font-size: 14px;
1638
- }
1639
-
1640
- .google-pay-unavailable {
1641
- display: flex;
1642
- align-items: center;
1643
- justify-content: center;
1644
- padding: 12px;
1645
- background: #f9fafb;
1646
- border: 1px solid #e5e7eb;
1647
- border-radius: 8px;
1648
- color: #6b7280;
1649
- font-size: 14px;
1650
- }
1651
-
1652
- .error-icon {
1653
- font-size: 16px;
1654
- }
1655
-
1656
- `)));
1657
- }
1658
- static get watchers() { return {
1659
- "merchantId": ["watchConfigChange"],
1660
- "environment": ["watchConfigChange"]
1661
- }; }
1662
- };
1663
-
1664
832
  const Header = class {
1665
833
  constructor(hostRef) {
1666
834
  index.registerInstance(this, hostRef);
@@ -1673,7 +841,7 @@ const Header = class {
1673
841
  }
1674
842
  render() {
1675
843
  const HeaderComponent = this.levels[this.level];
1676
- return (index.h(styledHost.StyledHost, { key: '73104ea086f8a9948e69f86451adf19e0f39fb32' }, index.h(HeaderComponent, { key: 'a8582109634299a24e2a9b3c7181c6bba511fde7', text: this.text, class: this.class })));
844
+ return (index.h(styledHost.StyledHost, { key: 'd4871da09451d40b27220a207ee72317ed9b1b9f' }, index.h(HeaderComponent, { key: 'f7de159fa6395ef4024f48b868369f8d10edf64e', text: this.text, class: this.class })));
1677
845
  }
1678
846
  };
1679
847
 
@@ -1759,30 +927,11 @@ const ModularCheckout = class {
1759
927
  this.submitEvent = index.createEvent(this, "submit-event");
1760
928
  this.checkoutChangedEvent = index.createEvent(this, "checkout-changed");
1761
929
  this.plaidService = new PlaidService();
1762
- this.handleGooglePayCompleted = (event) => {
1763
- const { success, paymentMethodId, error } = event.detail || {};
1764
- if (success && paymentMethodId) {
1765
- GooglePay$1.checkoutStore.paymentToken = paymentMethodId;
1766
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.GOOGLE_PAY };
1767
- this.submitCheckout();
1768
- }
1769
- else {
1770
- this.errorEvent.emit({
1771
- message: (error && error.message) || "Google Pay payment failed",
1772
- errorCode: ComponentError.ComponentErrorCodes.TOKENIZE_ERROR,
1773
- severity: ComponentError.ComponentErrorSeverity.ERROR,
1774
- });
1775
- }
1776
- };
1777
- this.handleGooglePayCancelled = () => {
1778
- GooglePay$1.checkoutStore.paymentToken = undefined;
1779
- GooglePay$1.checkoutStore.selectedPaymentMethod = undefined;
1780
- };
1781
930
  this.handleApplePayCompleted = (event) => {
1782
931
  const { success, token, paymentMethodId, error } = event.detail;
1783
932
  if (success && token) {
1784
- GooglePay$1.checkoutStore.paymentToken = paymentMethodId;
1785
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.APPLE_PAY };
933
+ checkout_store.checkoutStore.paymentToken = paymentMethodId;
934
+ checkout_store.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.APPLE_PAY };
1786
935
  this.submitCheckout();
1787
936
  }
1788
937
  else {
@@ -1805,21 +954,20 @@ const ModularCheckout = class {
1805
954
  });
1806
955
  };
1807
956
  this.handleApplePayCancelled = () => {
1808
- GooglePay$1.checkoutStore.paymentToken = undefined;
1809
- GooglePay$1.checkoutStore.selectedPaymentMethod = undefined;
957
+ checkout_store.checkoutStore.paymentToken = undefined;
958
+ checkout_store.checkoutStore.selectedPaymentMethod = undefined;
1810
959
  };
1811
960
  }
1812
961
  connectedCallback() {
1813
962
  this.observer = new MutationObserver(() => {
1814
963
  this.queryFormRefs();
1815
964
  this.setupApplePayListeners(); // set up again listeners when DOM changes
1816
- this.setupGooglePayListeners();
1817
965
  });
1818
966
  this.observer.observe(this.hostEl, {
1819
967
  childList: true,
1820
968
  subtree: true,
1821
969
  });
1822
- GooglePay$1.checkoutStore.checkoutId = this.checkoutId;
970
+ checkout_store.checkoutStore.checkoutId = this.checkoutId;
1823
971
  const config = {
1824
972
  authToken: this.authToken,
1825
973
  checkoutId: this.checkoutId,
@@ -1828,14 +976,14 @@ const ModularCheckout = class {
1828
976
  this.getCheckout = makeGetCheckout(config);
1829
977
  this.completeCheckout = makeCheckoutComplete(config);
1830
978
  // Emit checkout-changed whenever any store key changes
1831
- GooglePay$1.onAnyChange(() => {
979
+ checkout_store.onAnyChange(() => {
1832
980
  this.emitCheckoutChanged();
1833
981
  });
1834
982
  }
1835
983
  componentWillLoad() {
1836
984
  this.analytics = new checkPkgVersion.JustifiAnalytics(this);
1837
985
  checkPkgVersion.checkPkgVersion();
1838
- GooglePay$1.checkoutStore.authToken = this.authToken;
986
+ checkout_store.checkoutStore.authToken = this.authToken;
1839
987
  this.fetchCheckout();
1840
988
  // Refresh the checkout data when insurance values actually change (not on initial load)
1841
989
  insuranceState.insuranceValuesOn("set", (key) => {
@@ -1848,13 +996,11 @@ const ModularCheckout = class {
1848
996
  componentDidLoad() {
1849
997
  this.queryFormRefs();
1850
998
  this.setupApplePayListeners();
1851
- this.setupGooglePayListeners();
1852
999
  }
1853
1000
  disconnectedCallback() {
1854
1001
  var _a;
1855
1002
  (_a = this.observer) === null || _a === void 0 ? void 0 : _a.disconnect();
1856
1003
  this.removeApplePayListeners();
1857
- this.removeGooglePayListeners();
1858
1004
  }
1859
1005
  fetchCheckout() {
1860
1006
  if (!this.authToken || !this.checkoutId) {
@@ -1869,7 +1015,7 @@ const ModularCheckout = class {
1869
1015
  this.getCheckout({
1870
1016
  onSuccess: ({ checkout }) => {
1871
1017
  this.updateStore(checkout);
1872
- if (checkout.status === GooglePay$1.ICheckoutStatus.completed) {
1018
+ if (checkout.status === Refund.ICheckoutStatus.completed) {
1873
1019
  this.errorEvent.emit({
1874
1020
  message: ComponentError.ComponentErrorMessages.CHECKOUT_ALREADY_COMPLETED,
1875
1021
  errorCode: ComponentError.ComponentErrorCodes.CHECKOUT_ALREADY_COMPLETED,
@@ -1877,7 +1023,7 @@ const ModularCheckout = class {
1877
1023
  });
1878
1024
  return;
1879
1025
  }
1880
- else if (checkout.status === GooglePay$1.ICheckoutStatus.expired) {
1026
+ else if (checkout.status === Refund.ICheckoutStatus.expired) {
1881
1027
  this.errorEvent.emit({
1882
1028
  message: ComponentError.ComponentErrorMessages.CHECKOUT_EXPIRED,
1883
1029
  errorCode: ComponentError.ComponentErrorCodes.CHECKOUT_EXPIRED,
@@ -1897,37 +1043,35 @@ const ModularCheckout = class {
1897
1043
  }
1898
1044
  }
1899
1045
  updateStore(checkout) {
1900
- var _a, _b, _c, _d, _e, _f, _g;
1901
- GooglePay$1.checkoutStore.accountId = checkout.account_id;
1902
- GooglePay$1.checkoutStore.checkoutLoaded = true;
1903
- GooglePay$1.checkoutStore.paymentMethods = checkout.payment_methods.map((paymentMethod) => new index$1.PaymentMethod(paymentMethod));
1904
- GooglePay$1.checkoutStore.paymentMethodGroupId = checkout.payment_method_group_id;
1905
- GooglePay$1.checkoutStore.paymentDescription = checkout.payment_description;
1906
- GooglePay$1.checkoutStore.totalAmount = checkout.total_amount;
1907
- GooglePay$1.checkoutStore.paymentAmount = checkout.payment_amount;
1908
- GooglePay$1.checkoutStore.bnplEnabled = checkout.payment_settings.bnpl_payments;
1909
- GooglePay$1.checkoutStore.insuranceEnabled = checkout.payment_settings.insurance_payments;
1910
- GooglePay$1.checkoutStore.bankAccountVerification = (_a = checkout.payment_settings) === null || _a === void 0 ? void 0 : _a.bank_account_verification;
1911
- GooglePay$1.checkoutStore.applePayEnabled = (_b = checkout.payment_settings) === null || _b === void 0 ? void 0 : _b.apple_payments;
1912
- GooglePay$1.checkoutStore.googlePayEnabled = (_c = checkout.payment_settings) === null || _c === void 0 ? void 0 : _c.google_payments;
1913
- GooglePay$1.checkoutStore.bnplProviderClientId = (_d = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _d === void 0 ? void 0 : _d.provider_client_id;
1914
- GooglePay$1.checkoutStore.bnplProviderMode = (_e = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _e === void 0 ? void 0 : _e.provider_mode;
1915
- GooglePay$1.checkoutStore.bnplProviderApiVersion = (_f = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _f === void 0 ? void 0 : _f.provider_api_version;
1916
- GooglePay$1.checkoutStore.bnplProviderCheckoutUrl =
1917
- (_g = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _g === void 0 ? void 0 : _g.provider_checkout_url;
1046
+ var _a, _b, _c, _d, _e, _f;
1047
+ checkout_store.checkoutStore.accountId = checkout.account_id;
1048
+ checkout_store.checkoutStore.checkoutLoaded = true;
1049
+ checkout_store.checkoutStore.paymentMethods = checkout.payment_methods.map((paymentMethod) => new index$1.PaymentMethod(paymentMethod));
1050
+ checkout_store.checkoutStore.paymentMethodGroupId = checkout.payment_method_group_id;
1051
+ checkout_store.checkoutStore.paymentDescription = checkout.payment_description;
1052
+ checkout_store.checkoutStore.totalAmount = checkout.total_amount;
1053
+ checkout_store.checkoutStore.paymentAmount = checkout.payment_amount;
1054
+ checkout_store.checkoutStore.bnplEnabled = checkout.payment_settings.bnpl_payments;
1055
+ checkout_store.checkoutStore.insuranceEnabled = checkout.payment_settings.insurance_payments;
1056
+ checkout_store.checkoutStore.bankAccountVerification = (_a = checkout.payment_settings) === null || _a === void 0 ? void 0 : _a.bank_account_verification;
1057
+ checkout_store.checkoutStore.applePayEnabled = (_b = checkout.payment_settings) === null || _b === void 0 ? void 0 : _b.apple_payments;
1058
+ checkout_store.checkoutStore.bnplProviderClientId = (_c = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _c === void 0 ? void 0 : _c.provider_client_id;
1059
+ checkout_store.checkoutStore.bnplProviderMode = (_d = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _d === void 0 ? void 0 : _d.provider_mode;
1060
+ checkout_store.checkoutStore.bnplProviderApiVersion = (_e = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _e === void 0 ? void 0 : _e.provider_api_version;
1061
+ checkout_store.checkoutStore.bnplProviderCheckoutUrl =
1062
+ (_f = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _f === void 0 ? void 0 : _f.provider_checkout_url;
1918
1063
  }
1919
1064
  emitCheckoutChanged() {
1920
1065
  const detail = {
1921
- availablePaymentMethodTypes: GooglePay$1.getAvailablePaymentMethodTypes(),
1922
- selectedPaymentMethod: GooglePay$1.checkoutStore.selectedPaymentMethod,
1923
- savedPaymentMethods: GooglePay$1.checkoutStore.paymentMethods,
1066
+ availablePaymentMethodTypes: checkout_store.getAvailablePaymentMethodTypes(),
1067
+ selectedPaymentMethod: checkout_store.checkoutStore.selectedPaymentMethod,
1068
+ savedPaymentMethods: checkout_store.checkoutStore.paymentMethods,
1924
1069
  };
1925
1070
  this.checkoutChangedEvent.emit(detail);
1926
1071
  }
1927
1072
  queryFormRefs() {
1928
1073
  this.billingFormRef = this.hostEl.querySelector("justifi-billing-form, justifi-bank-account-billing-form-simple, justifi-card-billing-form-simple, justifi-billing-form-full");
1929
1074
  this.applePayRef = this.hostEl.querySelector("justifi-apple-pay");
1930
- this.googlePayRef = this.hostEl.querySelector("justifi-google-pay");
1931
1075
  this.paymentMethodFormRef =
1932
1076
  this.hostEl.querySelector('justifi-card-form, justifi-bank-account-form, justifi-tokenize-payment-method');
1933
1077
  this.insuranceFormRef = this.hostEl.querySelector('justifi-season-interruption-insurance');
@@ -1946,52 +1090,40 @@ const ModularCheckout = class {
1946
1090
  this.applePayRef.removeEventListener("applePayCancelled", this.handleApplePayCancelled);
1947
1091
  }
1948
1092
  }
1949
- setupGooglePayListeners() {
1950
- if (this.googlePayRef) {
1951
- this.googlePayRef.addEventListener("googlePayCompleted", this.handleGooglePayCompleted);
1952
- this.googlePayRef.addEventListener("googlePayCancelled", this.handleGooglePayCancelled);
1953
- }
1954
- }
1955
- removeGooglePayListeners() {
1956
- if (this.googlePayRef) {
1957
- this.googlePayRef.removeEventListener("googlePayCompleted", this.handleGooglePayCompleted);
1958
- this.googlePayRef.removeEventListener("googlePayCancelled", this.handleGooglePayCancelled);
1959
- }
1960
- }
1961
1093
  async tokenizePaymentMethod(tokenizeArgs) {
1962
1094
  var _a, _b, _c;
1963
1095
  const billingInfoValues = (_b = (await ((_a = this.billingFormRef) === null || _a === void 0 ? void 0 : _a.getValues()))) !== null && _b !== void 0 ? _b : {};
1964
1096
  const combinedBillingInfo = Object.assign(Object.assign({}, tokenizeArgs), billingInfoValues);
1965
- const paymentMethodMetadata = Object.assign({ accountId: GooglePay$1.checkoutStore.accountId, payment_method_group_id: undefined }, combinedBillingInfo);
1966
- if (GooglePay$1.checkoutStore.savePaymentMethod) {
1097
+ const paymentMethodMetadata = Object.assign({ accountId: checkout_store.checkoutStore.accountId, payment_method_group_id: undefined }, combinedBillingInfo);
1098
+ if (checkout_store.checkoutStore.savePaymentMethod) {
1967
1099
  paymentMethodMetadata.payment_method_group_id =
1968
- GooglePay$1.checkoutStore.paymentMethodGroupId;
1100
+ checkout_store.checkoutStore.paymentMethodGroupId;
1969
1101
  }
1970
1102
  const tokenizeResult = await ((_c = this.paymentMethodFormRef) === null || _c === void 0 ? void 0 : _c.tokenize({
1971
1103
  clientId: this.authToken,
1972
1104
  paymentMethodMetadata,
1973
- account: GooglePay$1.checkoutStore.accountId,
1105
+ account: checkout_store.checkoutStore.accountId,
1974
1106
  }));
1975
1107
  if (tokenizeResult.error) {
1976
1108
  return tokenizeResult;
1977
1109
  }
1978
- GooglePay$1.checkoutStore.paymentToken = tokenizeResult.id;
1110
+ checkout_store.checkoutStore.paymentToken = tokenizeResult.id;
1979
1111
  return tokenizeResult.id;
1980
1112
  }
1981
1113
  // set the selected payment method to the checkout store from outside the component
1982
1114
  async setSelectedPaymentMethod(paymentMethod) {
1983
- GooglePay$1.checkoutStore.selectedPaymentMethod = paymentMethod;
1984
- GooglePay$1.checkoutStore.paymentToken = paymentMethod.id || undefined;
1115
+ checkout_store.checkoutStore.selectedPaymentMethod = paymentMethod;
1116
+ checkout_store.checkoutStore.paymentToken = paymentMethod.id || undefined;
1985
1117
  }
1986
1118
  // if validation fails, the error will be emitted by the component
1987
1119
  async validate() {
1988
1120
  var _a, _b;
1989
1121
  const promises = [];
1990
- if (GooglePay$1.checkoutStore.insuranceEnabled && this.insuranceFormRef) {
1122
+ if (checkout_store.checkoutStore.insuranceEnabled && this.insuranceFormRef) {
1991
1123
  promises.push(this.insuranceFormRef.validate());
1992
1124
  }
1993
- const isNewCard = ((_a = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.NEW_CARD;
1994
- const isNewBankAccount = ((_b = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _b === void 0 ? void 0 : _b.type) === index$1.PAYMENT_METHODS.NEW_BANK_ACCOUNT;
1125
+ const isNewCard = ((_a = checkout_store.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.NEW_CARD;
1126
+ const isNewBankAccount = ((_b = checkout_store.checkoutStore.selectedPaymentMethod) === null || _b === void 0 ? void 0 : _b.type) === index$1.PAYMENT_METHODS.NEW_BANK_ACCOUNT;
1995
1127
  // For new card/bank account, validate payment method + billing.
1996
1128
  if (isNewCard || isNewBankAccount) {
1997
1129
  if (this.paymentMethodFormRef)
@@ -2025,7 +1157,7 @@ const ModularCheckout = class {
2025
1157
  async submitCheckout(submitCheckoutArgs) {
2026
1158
  var _a, _b, _c, _d, _e;
2027
1159
  const isValid = await this.validate();
2028
- if (!GooglePay$1.checkoutStore.selectedPaymentMethod) {
1160
+ if (!checkout_store.checkoutStore.selectedPaymentMethod) {
2029
1161
  this.errorEvent.emit({
2030
1162
  message: 'No payment method selected.',
2031
1163
  errorCode: ComponentError.ComponentErrorCodes.VALIDATION_ERROR,
@@ -2033,9 +1165,9 @@ const ModularCheckout = class {
2033
1165
  });
2034
1166
  return;
2035
1167
  }
2036
- const isNewCard = ((_a = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.NEW_CARD;
2037
- const isNewBankAccount = ((_b = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _b === void 0 ? void 0 : _b.type) === index$1.PAYMENT_METHODS.NEW_BANK_ACCOUNT;
2038
- const isPlaid = ((_c = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _c === void 0 ? void 0 : _c.type) === index$1.PAYMENT_METHODS.PLAID;
1168
+ const isNewCard = ((_a = checkout_store.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.NEW_CARD;
1169
+ const isNewBankAccount = ((_b = checkout_store.checkoutStore.selectedPaymentMethod) === null || _b === void 0 ? void 0 : _b.type) === index$1.PAYMENT_METHODS.NEW_BANK_ACCOUNT;
1170
+ const isPlaid = ((_c = checkout_store.checkoutStore.selectedPaymentMethod) === null || _c === void 0 ? void 0 : _c.type) === index$1.PAYMENT_METHODS.PLAID;
2039
1171
  const shouldTokenize = isNewCard || isNewBankAccount;
2040
1172
  if (shouldTokenize) {
2041
1173
  const tokenizeResult = await this.tokenizePaymentMethod(submitCheckoutArgs);
@@ -2049,9 +1181,9 @@ const ModularCheckout = class {
2049
1181
  }
2050
1182
  }
2051
1183
  // For Plaid, perform exchange at submit time using stored public token and link token id
2052
- if (isPlaid && !GooglePay$1.checkoutStore.paymentToken) {
2053
- const publicToken = GooglePay$1.checkoutStore.plaidPublicToken;
2054
- const linkTokenId = GooglePay$1.checkoutStore.plaidLinkTokenId;
1184
+ if (isPlaid && !checkout_store.checkoutStore.paymentToken) {
1185
+ const publicToken = checkout_store.checkoutStore.plaidPublicToken;
1186
+ const linkTokenId = checkout_store.checkoutStore.plaidLinkTokenId;
2055
1187
  if (!publicToken) {
2056
1188
  this.errorEvent.emit({
2057
1189
  message: 'Missing Plaid public token. Please connect your bank.',
@@ -2061,7 +1193,7 @@ const ModularCheckout = class {
2061
1193
  return;
2062
1194
  }
2063
1195
  try {
2064
- const response = await this.plaidService.tokenizeBankAccount(GooglePay$1.checkoutStore.authToken, GooglePay$1.checkoutStore.accountId, publicToken, linkTokenId || undefined, GooglePay$1.checkoutStore.savePaymentMethod ? GooglePay$1.checkoutStore.paymentMethodGroupId : undefined);
1196
+ const response = await this.plaidService.tokenizeBankAccount(checkout_store.checkoutStore.authToken, checkout_store.checkoutStore.accountId, publicToken, linkTokenId || undefined, checkout_store.checkoutStore.savePaymentMethod ? checkout_store.checkoutStore.paymentMethodGroupId : undefined);
2065
1197
  if (response === null || response === void 0 ? void 0 : response.error) {
2066
1198
  this.errorEvent.emit({
2067
1199
  message: typeof response.error === 'string' ? response.error : response.error.message || 'Failed to tokenize bank account',
@@ -2072,7 +1204,7 @@ const ModularCheckout = class {
2072
1204
  }
2073
1205
  const paymentMethod = response === null || response === void 0 ? void 0 : response.data;
2074
1206
  const token = ((_d = paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.bank_account) === null || _d === void 0 ? void 0 : _d.token) || (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.token) || (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id);
2075
- GooglePay$1.checkoutStore.paymentToken = token;
1207
+ checkout_store.checkoutStore.paymentToken = token;
2076
1208
  }
2077
1209
  catch (err) {
2078
1210
  this.errorEvent.emit({
@@ -2091,7 +1223,7 @@ const ModularCheckout = class {
2091
1223
  });
2092
1224
  return;
2093
1225
  }
2094
- if (!GooglePay$1.checkoutStore.paymentToken) {
1226
+ if (!checkout_store.checkoutStore.paymentToken) {
2095
1227
  this.errorEvent.emit({
2096
1228
  message: 'Payment token not found.',
2097
1229
  errorCode: ComponentError.ComponentErrorCodes.TOKENIZE_ERROR,
@@ -2112,18 +1244,16 @@ const ModularCheckout = class {
2112
1244
  return index$1.PAYMENT_MODE.BNPL;
2113
1245
  case index$1.PAYMENT_METHODS.APPLE_PAY:
2114
1246
  return index$1.PAYMENT_MODE.APPLE_PAY;
2115
- case index$1.PAYMENT_METHODS.GOOGLE_PAY:
2116
- return index$1.PAYMENT_MODE.GOOGLE_PAY;
2117
1247
  default:
2118
1248
  return undefined;
2119
1249
  }
2120
1250
  };
2121
1251
  payment = {
2122
- payment_mode: mapTypeToPaymentMode((_e = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _e === void 0 ? void 0 : _e.type),
2123
- payment_token: GooglePay$1.checkoutStore.paymentToken,
1252
+ payment_mode: mapTypeToPaymentMode((_e = checkout_store.checkoutStore.selectedPaymentMethod) === null || _e === void 0 ? void 0 : _e.type),
1253
+ payment_token: checkout_store.checkoutStore.paymentToken,
2124
1254
  };
2125
1255
  if (this.preCompleteHook) {
2126
- const state = GooglePay$1.getCheckoutState();
1256
+ const state = checkout_store.getCheckoutState();
2127
1257
  try {
2128
1258
  await new Promise((resolve, reject) => {
2129
1259
  this.preCompleteHook(state, () => resolve(), () => reject());
@@ -2151,7 +1281,7 @@ const ModularCheckout = class {
2151
1281
  });
2152
1282
  }
2153
1283
  render() {
2154
- return index.h(index.Host, { key: '43f4be87e218b23251f2ccac90e0c980bf157d68' });
1284
+ return index.h(index.Host, { key: '56a003ca1e1ac4bdc1baa8f862cdb05b2d8af4b1' });
2155
1285
  }
2156
1286
  get hostEl() { return index.getElement(this); }
2157
1287
  };
@@ -2230,7 +1360,7 @@ const PlaidPaymentMethod = class {
2230
1360
  this.hasLoggedDisabledWarning = false;
2231
1361
  this.waitForStoreAndInitialize = () => {
2232
1362
  // Check if store has necessary data
2233
- if (GooglePay$1.checkoutStore.authToken && GooglePay$1.checkoutStore.accountId && GooglePay$1.checkoutStore.checkoutId) {
1363
+ if (checkout_store.checkoutStore.authToken && checkout_store.checkoutStore.accountId && checkout_store.checkoutStore.checkoutId) {
2234
1364
  this.initializePlaidLink();
2235
1365
  }
2236
1366
  else {
@@ -2289,7 +1419,7 @@ const PlaidPaymentMethod = class {
2289
1419
  this.getLinkToken = async () => {
2290
1420
  var _a, _b, _c, _d, _e;
2291
1421
  try {
2292
- if (!GooglePay$1.checkoutStore.authToken || !GooglePay$1.checkoutStore.accountId) {
1422
+ if (!checkout_store.checkoutStore.authToken || !checkout_store.checkoutStore.accountId) {
2293
1423
  this.handleError({
2294
1424
  code: PlaidErrorCodes.PLAID_LINK_TOKEN_FAILED,
2295
1425
  message: 'Missing authentication. Please refresh the page and try again.',
@@ -2306,7 +1436,7 @@ const PlaidPaymentMethod = class {
2306
1436
  var _a;
2307
1437
  (_a = this.abortController) === null || _a === void 0 ? void 0 : _a.abort();
2308
1438
  }, 30000); // 30 second timeout
2309
- const response = await this.plaidService.getLinkToken(GooglePay$1.checkoutStore.authToken, GooglePay$1.checkoutStore.accountId, GooglePay$1.checkoutStore.checkoutId, this.abortController.signal);
1439
+ const response = await this.plaidService.getLinkToken(checkout_store.checkoutStore.authToken, checkout_store.checkoutStore.accountId, checkout_store.checkoutStore.checkoutId, this.abortController.signal);
2310
1440
  // Clear timeout
2311
1441
  if (this.timeoutId) {
2312
1442
  clearTimeout(this.timeoutId);
@@ -2323,7 +1453,7 @@ const PlaidPaymentMethod = class {
2323
1453
  // Try to capture link token id if present in envelope
2324
1454
  this.linkTokenId = (response === null || response === void 0 ? void 0 : response.id) || ((_a = response === null || response === void 0 ? void 0 : response.data) === null || _a === void 0 ? void 0 : _a.id) || null;
2325
1455
  if (this.linkTokenId) {
2326
- GooglePay$1.checkoutStore.plaidLinkTokenId = this.linkTokenId;
1456
+ checkout_store.checkoutStore.plaidLinkTokenId = this.linkTokenId;
2327
1457
  }
2328
1458
  }
2329
1459
  catch (error) {
@@ -2396,7 +1526,7 @@ const PlaidPaymentMethod = class {
2396
1526
  // Ensure the component remains selected after successful authentication
2397
1527
  if (!this.isSelected) {
2398
1528
  this.isSelected = true;
2399
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
1529
+ checkout_store.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
2400
1530
  }
2401
1531
  // Emit success event for parent components
2402
1532
  this.plaidErrorRecovered.emit({
@@ -2405,7 +1535,7 @@ const PlaidPaymentMethod = class {
2405
1535
  severity: ComponentError.ComponentErrorSeverity.INFO
2406
1536
  });
2407
1537
  // Store public token in checkout store; exchange will be handled on submit
2408
- GooglePay$1.checkoutStore.plaidPublicToken = publicToken;
1538
+ checkout_store.checkoutStore.plaidPublicToken = publicToken;
2409
1539
  };
2410
1540
  // Exchange logic moved to Modular Checkout submit flow.
2411
1541
  this.handlePlaidExit = (err, _metadata) => {
@@ -2547,7 +1677,7 @@ const PlaidPaymentMethod = class {
2547
1677
  // Watch for store changes to sync component state
2548
1678
  this.syncWithStore = () => {
2549
1679
  var _a;
2550
- const shouldBeSelected = ((_a = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.PLAID;
1680
+ const shouldBeSelected = ((_a = checkout_store.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.PLAID;
2551
1681
  if (this.isSelected !== shouldBeSelected) {
2552
1682
  this.isSelected = shouldBeSelected;
2553
1683
  }
@@ -2556,8 +1686,8 @@ const PlaidPaymentMethod = class {
2556
1686
  onSelectionChange(newValue) {
2557
1687
  var _a;
2558
1688
  // Ensure store is updated when component selection changes
2559
- if (newValue && ((_a = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) !== index$1.PAYMENT_METHODS.PLAID) {
2560
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
1689
+ if (newValue && ((_a = checkout_store.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) !== index$1.PAYMENT_METHODS.PLAID) {
1690
+ checkout_store.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
2561
1691
  }
2562
1692
  // Auto-start Plaid flow when selected and ready
2563
1693
  if (newValue &&
@@ -2589,7 +1719,7 @@ const PlaidPaymentMethod = class {
2589
1719
  componentWillLoad() {
2590
1720
  var _a;
2591
1721
  // Initialize selection state based on store
2592
- this.isSelected = ((_a = GooglePay$1.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.PLAID;
1722
+ this.isSelected = ((_a = checkout_store.checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === index$1.PAYMENT_METHODS.PLAID;
2593
1723
  }
2594
1724
  async resolvePaymentMethod() {
2595
1725
  if (!this.publicToken) {
@@ -2606,13 +1736,13 @@ const PlaidPaymentMethod = class {
2606
1736
  // Returns a usable payment method token for checkout completion.
2607
1737
  // Will perform the backend exchange if the token is not yet present in the store.
2608
1738
  async getPaymentToken() {
2609
- return GooglePay$1.checkoutStore.paymentToken;
1739
+ return checkout_store.checkoutStore.paymentToken;
2610
1740
  }
2611
1741
  async handleSelectionClick() {
2612
1742
  // Update local selection state
2613
1743
  this.isSelected = true;
2614
1744
  // Update store selection
2615
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
1745
+ checkout_store.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
2616
1746
  // If there's an error, clear it and try to initialize again
2617
1747
  if (this.error) {
2618
1748
  this.clearError();
@@ -2628,7 +1758,7 @@ const PlaidPaymentMethod = class {
2628
1758
  async setSelected(selected) {
2629
1759
  this.isSelected = selected;
2630
1760
  if (selected) {
2631
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
1761
+ checkout_store.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.PLAID };
2632
1762
  }
2633
1763
  }
2634
1764
  // Method to check if component is currently selected
@@ -2677,7 +1807,7 @@ const PlaidPaymentMethod = class {
2677
1807
  }
2678
1808
  componentDidLoad() {
2679
1809
  // Set up store change listener to keep component in sync
2680
- const unsubscribe = GooglePay$1.onChange('selectedPaymentMethod', this.syncWithStore);
1810
+ const unsubscribe = checkout_store.onChange('selectedPaymentMethod', this.syncWithStore);
2681
1811
  // Store unsubscribe function for cleanup
2682
1812
  this.unsubscribeFromStore = unsubscribe;
2683
1813
  }
@@ -2696,7 +1826,7 @@ const PlaidPaymentMethod = class {
2696
1826
  }
2697
1827
  render() {
2698
1828
  // Only allow use if enabled in checkout settings
2699
- if (GooglePay$1.checkoutStore.bankAccountVerification !== true) {
1829
+ if (checkout_store.checkoutStore.bankAccountVerification !== true) {
2700
1830
  if (!this.hasLoggedDisabledWarning) {
2701
1831
  // Log once per component lifecycle
2702
1832
  console.warn('[PlaidPaymentMethod] bank_account_verification is disabled. Component will not render.');
@@ -2747,36 +1877,36 @@ const SavedPaymentMethods = class {
2747
1877
  index.registerInstance(this, hostRef);
2748
1878
  this.onPaymentMethodOptionClick = (paymentMethod) => (e) => {
2749
1879
  e.preventDefault();
2750
- GooglePay$1.checkoutStore.selectedPaymentMethod = { id: paymentMethod.id, type: paymentMethod.type };
2751
- GooglePay$1.checkoutStore.paymentToken = paymentMethod.id;
1880
+ checkout_store.checkoutStore.selectedPaymentMethod = { id: paymentMethod.id, type: paymentMethod.type };
1881
+ checkout_store.checkoutStore.paymentToken = paymentMethod.id;
2752
1882
  };
2753
1883
  this.isAllowedPaymentMethod = (paymentMethodType) => {
2754
1884
  const isCard = paymentMethodType === index$1.PAYMENT_METHODS.SAVED_CARD;
2755
1885
  const isBankAccount = paymentMethodType === index$1.PAYMENT_METHODS.SAVED_BANK_ACCOUNT;
2756
- if (isCard && GooglePay$1.checkoutStore.disableCreditCard) {
1886
+ if (isCard && checkout_store.checkoutStore.disableCreditCard) {
2757
1887
  return false;
2758
1888
  }
2759
- if (isBankAccount && GooglePay$1.checkoutStore.disableBankAccount) {
1889
+ if (isBankAccount && checkout_store.checkoutStore.disableBankAccount) {
2760
1890
  return false;
2761
1891
  }
2762
1892
  return true;
2763
1893
  };
2764
1894
  }
2765
1895
  componentWillLoad() {
2766
- if (!GooglePay$1.checkoutStore.paymentMethods.length) {
1896
+ if (!checkout_store.checkoutStore.paymentMethods.length) {
2767
1897
  console.warn('No saved payment methods available.');
2768
1898
  }
2769
- if (GooglePay$1.checkoutStore.disablePaymentMethodGroup) {
1899
+ if (checkout_store.checkoutStore.disablePaymentMethodGroup) {
2770
1900
  console.warn('Payment method group is disabled.');
2771
1901
  }
2772
1902
  }
2773
1903
  render() {
2774
- if (GooglePay$1.checkoutStore.disablePaymentMethodGroup) {
1904
+ if (checkout_store.checkoutStore.disablePaymentMethodGroup) {
2775
1905
  return null;
2776
1906
  }
2777
- return (index.h(styledHost.StyledHost, null, index.h("div", { class: "saved-payment-methods" }, GooglePay$1.checkoutStore.paymentMethods.length ? GooglePay$1.checkoutStore.paymentMethods
1907
+ return (index.h(styledHost.StyledHost, null, index.h("div", { class: "saved-payment-methods" }, checkout_store.checkoutStore.paymentMethods.length ? checkout_store.checkoutStore.paymentMethods
2778
1908
  .filter((paymentMethod) => this.isAllowedPaymentMethod(paymentMethod.type))
2779
- .map((paymentMethod) => (index.h("div", { class: "radio-list-item p-3", part: parts.radioListItem, onClick: this.onPaymentMethodOptionClick(paymentMethod) }, index.h("form-control-radio", { name: "paymentMethodType", value: paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id, checked: GooglePay$1.checkoutStore.paymentToken === (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id), label: `${paymentMethodOptionUtils.CardBrandLabels[paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.brand] || ''} *${paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.acct_last_four}` })))) : null)));
1909
+ .map((paymentMethod) => (index.h("div", { class: "radio-list-item p-3", part: parts.radioListItem, onClick: this.onPaymentMethodOptionClick(paymentMethod) }, index.h("form-control-radio", { name: "paymentMethodType", value: paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id, checked: checkout_store.checkoutStore.paymentToken === (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id), label: `${paymentMethodOptionUtils.CardBrandLabels[paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.brand] || ''} *${paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.acct_last_four}` })))) : null)));
2780
1910
  }
2781
1911
  };
2782
1912
 
@@ -2794,20 +1924,20 @@ const SezzlePaymentMethod = class {
2794
1924
  this.initializeSezzleCheckout = () => {
2795
1925
  let resolveSezzlePromise;
2796
1926
  this.sezzlePromise = new Promise((resolve) => { resolveSezzlePromise = resolve; });
2797
- const amount = Number(GooglePay$1.checkoutStore.paymentAmount);
1927
+ const amount = Number(checkout_store.checkoutStore.paymentAmount);
2798
1928
  const Checkout = window.Checkout;
2799
1929
  const checkout = new Checkout({
2800
1930
  mode: 'popup',
2801
- publicKey: GooglePay$1.checkoutStore.bnplProviderClientId,
2802
- apiMode: GooglePay$1.checkoutStore.bnplProviderMode,
2803
- apiVersion: GooglePay$1.checkoutStore.bnplProviderApiVersion,
1931
+ publicKey: checkout_store.checkoutStore.bnplProviderClientId,
1932
+ apiMode: checkout_store.checkoutStore.bnplProviderMode,
1933
+ apiVersion: checkout_store.checkoutStore.bnplProviderApiVersion,
2804
1934
  });
2805
1935
  checkout.sezzleButtonElement = this.sezzleButtonRef;
2806
1936
  checkout.init({
2807
1937
  onClick: function (event) {
2808
1938
  event.preventDefault();
2809
1939
  checkout.startCheckout({
2810
- checkout_url: GooglePay$1.checkoutStore.bnplProviderCheckoutUrl,
1940
+ checkout_url: checkout_store.checkoutStore.bnplProviderCheckoutUrl,
2811
1941
  });
2812
1942
  },
2813
1943
  onComplete: (event) => resolveSezzlePromise({ bnpl: event.data }),
@@ -2834,12 +1964,12 @@ const SezzlePaymentMethod = class {
2834
1964
  return this.sezzlePromise;
2835
1965
  }
2836
1966
  async handleSelectionClick() {
2837
- GooglePay$1.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.SEZZLE };
1967
+ checkout_store.checkoutStore.selectedPaymentMethod = { type: index$1.PAYMENT_METHODS.SEZZLE };
2838
1968
  this.paymentMethodOptionSelected.emit(this.paymentMethodOptionId);
2839
1969
  }
2840
1970
  render() {
2841
1971
  var _a, _b;
2842
- if (!GooglePay$1.checkoutStore.bnplEnabled) {
1972
+ if (!checkout_store.checkoutStore.bnplEnabled) {
2843
1973
  console.warn('justifi-sezzle-payment-method: BNPL is not enabled for this account.');
2844
1974
  return null;
2845
1975
  }
@@ -2849,7 +1979,6 @@ const SezzlePaymentMethod = class {
2849
1979
 
2850
1980
  exports.justifi_apple_pay = ApplePay;
2851
1981
  exports.justifi_checkout_summary = Summary;
2852
- exports.justifi_google_pay = GooglePay;
2853
1982
  exports.justifi_header = Header;
2854
1983
  exports.justifi_modular_checkout = ModularCheckout;
2855
1984
  exports.justifi_plaid_payment_method = PlaidPaymentMethod;