@zonos/elements 1.3.285 → 1.3.287

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 (660) hide show
  1. package/README.md +9 -1
  2. package/dist/cjs/RemoveIcon-CuM1YmjP.js +5 -0
  3. package/dist/cjs/{cart-94908542.js → cart-CV4buPlT.js} +43 -30
  4. package/dist/cjs/{collect-0c05e2b4.js → collect-jzWKzrV7.js} +17 -113
  5. package/dist/cjs/debounce-5sZmmlCI.js +9 -0
  6. package/dist/cjs/debounce-Nu2lJW4A.js +405 -0
  7. package/dist/cjs/{formatStringWithLinks-c25b4018.js → formatStringWithLinks-vOVkAjlu.js} +1 -1
  8. package/dist/cjs/{getBorderRadius-97fd5e02.js → getBorderRadius-DGZiQu09.js} +1 -1
  9. package/dist/cjs/{getContrastColor-956dfaf7.js → getContrastColor-B2Kn8XHA.js} +2 -2
  10. package/dist/cjs/{getMissingRequiredShippingFields-124b3f20.js → getMissingRequiredShippingFields-r5vYIqoX.js} +1 -1
  11. package/dist/cjs/{handleFetch-954f30e1.js → handleFetch-DQLhurnE.js} +4 -3
  12. package/dist/cjs/{hasInclusivePrice-d0cd2007.js → hasInclusivePrice-BZMQohG9.js} +1 -1
  13. package/dist/cjs/{helpers-5bdbb68c.js → helpers-ClOZ11A9.js} +0 -3
  14. package/dist/cjs/{index-b1f95d96.js → index-DAAr465v.js} +1252 -580
  15. package/dist/cjs/index.cjs.js +17 -21
  16. package/dist/cjs/{invoice-205fb5bc.js → invoice-CHw-mJdS.js} +6 -6
  17. package/dist/cjs/{isContrastColor-30f84a91.js → isContrastColor-B9ldIdpa.js} +1 -1
  18. package/dist/cjs/isDarkColor-f-fD9c2l.js +1187 -0
  19. package/dist/cjs/loader.cjs.js +3 -5
  20. package/dist/cjs/{localization-fb2ece37.js → localization-CxXsmxs5.js} +4 -4
  21. package/dist/cjs/{paypal-45ca5301.js → paypal-BLuHeOJH.js} +10 -9
  22. package/dist/cjs/{placeTestOrder-302b6862.js → placeTestOrder-VK_CMeq0.js} +3 -3
  23. package/dist/cjs/{renderCheckoutCurrency-1b0cd5f2.js → renderCheckoutCurrency-CC4CAy-a.js} +2 -2
  24. package/dist/cjs/{renderFallback-bc20ee20.js → renderFallback-Bme86uk8.js} +1 -1
  25. package/dist/cjs/{shouldRenderTaxIdInput-7d19556c.js → shouldRenderTaxIdInput-TxekHCp7.js} +2 -2
  26. package/dist/cjs/{shouldShowLanguageSelect-82985128.js → shouldShowLanguageSelect-Bj_jKWPK.js} +1 -1
  27. package/dist/cjs/{submitGtag-8a25f001.js → submitGtag-CcEL-w5D.js} +3 -3
  28. package/dist/cjs/throttle-BcxGntLr.js +87 -0
  29. package/dist/cjs/{updateCheckoutSessionAttributes-de7b1466.js → updateCheckoutSessionAttributes-Dltl5RBx.js} +3 -3
  30. package/dist/cjs/zonos-address-completion-dialog_7.cjs.entry.js +644 -692
  31. package/dist/cjs/zonos-address-display_2.cjs.entry.js +13 -17
  32. package/dist/cjs/zonos-address_4.cjs.entry.js +50 -40
  33. package/dist/cjs/zonos-airwallex-payment.cjs.entry.js +15 -16
  34. package/dist/cjs/zonos-badge.cjs.entry.js +7 -10
  35. package/dist/cjs/zonos-banner.cjs.entry.js +6 -9
  36. package/dist/cjs/zonos-button_3.cjs.entry.js +18 -21
  37. package/dist/cjs/zonos-card_5.cjs.entry.js +34 -35
  38. package/dist/cjs/zonos-cart-items_12.cjs.entry.js +101 -87
  39. package/dist/cjs/zonos-checkbox_2.cjs.entry.js +10 -14
  40. package/dist/cjs/zonos-checkout.cjs.entry.js +151 -37
  41. package/dist/cjs/zonos-collapse.cjs.entry.js +5 -8
  42. package/dist/cjs/zonos-collect-cart-items_3.cjs.entry.js +18 -23
  43. package/dist/cjs/zonos-collect-finish_6.cjs.entry.js +59 -55
  44. package/dist/cjs/zonos-collect.cjs.entry.js +20 -23
  45. package/dist/cjs/zonos-component.cjs.entry.js +3 -6
  46. package/dist/cjs/zonos-controller.cjs.entry.js +13 -16
  47. package/dist/cjs/zonos-country-flag.cjs.entry.js +8 -11
  48. package/dist/cjs/zonos-country-select_4.cjs.entry.js +68 -57
  49. package/dist/cjs/zonos-elements.cjs.js +7 -7
  50. package/dist/cjs/zonos-hello-dialog.cjs.entry.js +22 -23
  51. package/dist/cjs/zonos-hello.cjs.entry.js +19 -17
  52. package/dist/cjs/zonos-input.cjs.entry.js +10 -11
  53. package/dist/cjs/zonos-invoice-cart-items_2.cjs.entry.js +17 -21
  54. package/dist/cjs/zonos-invoice-finish_5.cjs.entry.js +57 -52
  55. package/dist/cjs/zonos-invoice.cjs.entry.js +19 -22
  56. package/dist/cjs/zonos-language-select_2.cjs.entry.js +11 -15
  57. package/dist/cjs/zonos-link.cjs.entry.js +3 -6
  58. package/dist/cjs/zonos-logo.cjs.entry.js +6 -9
  59. package/dist/cjs/zonos-policy-consent_2.cjs.entry.js +15 -19
  60. package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +11 -14
  61. package/dist/cjs/zonos-stripe-input.cjs.entry.js +15 -14
  62. package/dist/cjs/zonos-text.cjs.entry.js +8 -11
  63. package/dist/cjs/zonos-tooltip.cjs.entry.js +4 -7
  64. package/dist/cjs/zonos-v-stack.cjs.entry.js +6 -9
  65. package/dist/cjs/zonosStore-BCNYr6Tk.js +3808 -0
  66. package/dist/collection/__tests__/jsxWithChildren.types.js +13 -0
  67. package/dist/collection/collection-manifest.json +3 -2
  68. package/dist/collection/components/checkout/zonos-checkout/zonos-address-completion-dialog/zonos-address-completion-dialog.js +13 -10
  69. package/dist/collection/components/checkout/zonos-checkout/zonos-address-update-dialog/zonos-address-display/zonos-address-display.js +4 -3
  70. package/dist/collection/components/checkout/zonos-checkout/zonos-address-update-dialog/zonos-address-form/zonos-address-form.js +8 -5
  71. package/dist/collection/components/checkout/zonos-checkout/zonos-address-update-dialog/zonos-address-update-dialog.js +17 -13
  72. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-restricted-items/zonos-cart-restricted-items.js +1 -1
  73. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.js +21 -9
  74. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js +7 -5
  75. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.js +5 -4
  76. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-checkout-payment.js +8 -8
  77. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-empty-state-payment/zonos-empty-state-payment.js +5 -4
  78. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-store-credit/zonos-store-credit.js +1 -1
  79. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +121 -18
  80. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +13 -10
  81. package/dist/collection/components/checkout/zonos-checkout/zonos-review/zonos-review.js +2 -2
  82. package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +7 -7
  83. package/dist/collection/components/checkout/zonos-collect/zonos-collect-finish/zonos-collect-finish.js +8 -6
  84. package/dist/collection/components/checkout/zonos-collect/zonos-collect-footer/zonos-collect-footer.js +6 -5
  85. package/dist/collection/components/checkout/zonos-collect/zonos-collect-order-details/zonos-collect-order-details.js +4 -4
  86. package/dist/collection/components/checkout/zonos-collect/zonos-collect-payment/zonos-collect-payment.js +7 -7
  87. package/dist/collection/components/checkout/zonos-collect/zonos-collect-review/zonos-collect-review.js +3 -3
  88. package/dist/collection/components/checkout/zonos-collect/zonos-collect.js +2 -2
  89. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-cart-items/zonos-invoice-cart-items.js +1 -1
  90. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-finish/zonos-invoice-finish.js +8 -6
  91. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-footer/zonos-invoice-footer.js +6 -5
  92. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-order-details/zonos-invoice-order-details.js +4 -4
  93. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-payment/zonos-invoice-payment.js +7 -7
  94. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-review/zonos-invoice-review.js +3 -3
  95. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice-subtotal/zonos-invoice-subtotal.js +1 -1
  96. package/dist/collection/components/checkout/zonos-invoice/zonos-invoice.js +2 -2
  97. package/dist/collection/components/common/zonos-badge/zonos-badge.js +8 -7
  98. package/dist/collection/components/common/zonos-banner/zonos-banner.js +4 -4
  99. package/dist/collection/components/common/zonos-button/zonos-button.js +29 -25
  100. package/dist/collection/components/common/zonos-card/zonos-card.js +9 -8
  101. package/dist/collection/components/common/zonos-checkbox/zonos-checkbox.js +15 -12
  102. package/dist/collection/components/common/zonos-checkout-progress-tabs/zonos-checkout-progress-tabs.js +9 -6
  103. package/dist/collection/components/common/zonos-collapse/zonos-collapse.js +2 -2
  104. package/dist/collection/components/common/zonos-confirm-dialog/zonos-confirm-dialog.js +15 -15
  105. package/dist/collection/components/common/zonos-country-flag/zonos-country-flag.js +6 -5
  106. package/dist/collection/components/common/zonos-custom-message/zonos-custom-message.js +2 -2
  107. package/dist/collection/components/common/zonos-dialog/zonos-dialog.js +22 -21
  108. package/dist/collection/components/common/zonos-h-stack/zonos-h-stack.js +3 -2
  109. package/dist/collection/components/common/zonos-icon/zonos-icon.js +8 -7
  110. package/dist/collection/components/common/zonos-input/zonos-input.js +7 -7
  111. package/dist/collection/components/common/zonos-link/zonos-link.js +7 -7
  112. package/dist/collection/components/common/zonos-loading-overlay/zonos-loading-overlay.js +4 -4
  113. package/dist/collection/components/common/zonos-logo/zonos-logo.js +4 -3
  114. package/dist/collection/components/common/zonos-rest-state/zonos-rest-state.js +8 -7
  115. package/dist/collection/components/common/zonos-select-dialog-header/zonos-select-dialog-header.js +1 -1
  116. package/dist/collection/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.js +15 -12
  117. package/dist/collection/components/common/zonos-skeleton/zonos-skeleton.js +2 -2
  118. package/dist/collection/components/common/zonos-spinner/zonos-spinner.js +3 -3
  119. package/dist/collection/components/common/zonos-stripe-input/zonos-stripe-input.js +17 -17
  120. package/dist/collection/components/common/zonos-stripe-phone-input/zonos-stripe-phone-input.js +23 -20
  121. package/dist/collection/components/common/zonos-stripe-select/zonos-stripe-select.js +19 -19
  122. package/dist/collection/components/common/zonos-text/zonos-text.js +15 -11
  123. package/dist/collection/components/common/zonos-toggle/zonos-toggle.js +4 -3
  124. package/dist/collection/components/common/zonos-tooltip/zonos-tooltip.js +2 -2
  125. package/dist/collection/components/common/zonos-v-stack/zonos-v-stack.js +3 -2
  126. package/dist/collection/components/common/zonos-virtual-scroll/zonos-virtual-scroll.js +7 -6
  127. package/dist/collection/components/component-template/zonos-component/zonos-component.js +3 -3
  128. package/dist/collection/components/hello/zonos-hello/zonos-hello.js +16 -12
  129. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.js +3 -2
  130. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +14 -11
  131. package/dist/collection/components/main/zonos-controller.js +18 -10
  132. package/dist/collection/components/store/checkout/cart.js +14 -1
  133. package/dist/collection/components/store/checkout/stripe.js +1 -1
  134. package/dist/collection/components/stripe/zonos-address/zonos-address.js +9 -8
  135. package/dist/collection/components/stripe/zonos-custom-address/zonos-address-suggestions/zonos-address-suggestions.js +6 -4
  136. package/dist/collection/components/stripe/zonos-custom-address/zonos-custom-address.js +13 -10
  137. package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js +4 -4
  138. package/dist/collection/components/stripe/zonos-payment/zonos-payment.js +2 -2
  139. package/dist/collection/components/utils/checkout/isEuDapRemittance.js +1 -1
  140. package/dist/collection/components/utils/checkout/shouldRenderTaxIdInput.js +1 -1
  141. package/dist/collection/components/utils/validateCheckoutSession.js +11 -3
  142. package/dist/collection/scripts/cart/_setupCartData.js +2 -2
  143. package/dist/collection/scripts/cart/_setupCartDataWithSettings.js +2 -2
  144. package/dist/collection/types/generated/graphql.frontend.types.js +2 -0
  145. package/dist/collection/types/generated/graphql.internal.types.js +76 -6
  146. package/dist/esm/RemoveIcon-C2QMVeWW.js +3 -0
  147. package/dist/esm/{cart-2e407f7b.js → cart-ekBk_gxV.js} +42 -31
  148. package/dist/esm/{collect-19428e18.js → collect-33rMINDo.js} +17 -113
  149. package/dist/esm/debounce-D4ko2kvZ.js +403 -0
  150. package/dist/esm/debounce-DWPsxJsW.js +7 -0
  151. package/dist/esm/{formatStringWithLinks-0d48f183.js → formatStringWithLinks-BcMPqGl0.js} +1 -1
  152. package/dist/esm/{getBorderRadius-1f7be586.js → getBorderRadius-HwG64EKM.js} +1 -1
  153. package/dist/esm/{getContrastColor-4c0ae8c1.js → getContrastColor-CfCPlW9U.js} +2 -2
  154. package/dist/esm/{getMissingRequiredShippingFields-719b206f.js → getMissingRequiredShippingFields-u1nhQzJ1.js} +1 -1
  155. package/dist/esm/{handleFetch-a844cac1.js → handleFetch-D5GYDF-O.js} +4 -3
  156. package/dist/esm/{hasInclusivePrice-d801be22.js → hasInclusivePrice-CAVXi310.js} +1 -1
  157. package/dist/esm/{helpers-2f6955b1.js → helpers-DJIdCwJ5.js} +0 -3
  158. package/dist/esm/{index-cfd394c8.js → index-_lt63o7c.js} +1253 -561
  159. package/dist/esm/index.js +20 -22
  160. package/dist/esm/{invoice-67a47785.js → invoice-BNDWuVsD.js} +6 -6
  161. package/dist/esm/{isContrastColor-9fa0d013.js → isContrastColor-CWLU13s9.js} +1 -1
  162. package/dist/esm/isDarkColor-YdrG78th.js +1184 -0
  163. package/dist/esm/loader.js +4 -4
  164. package/dist/esm/{localization-36a4dc22.js → localization-AOqYXGdP.js} +5 -5
  165. package/dist/esm/{paypal-6dca6567.js → paypal-CW1D2XqZ.js} +10 -9
  166. package/dist/esm/{placeTestOrder-9563c89a.js → placeTestOrder-nhmsLLOA.js} +3 -3
  167. package/dist/esm/{renderCheckoutCurrency-282384f0.js → renderCheckoutCurrency-BQANmZyM.js} +2 -2
  168. package/dist/esm/{renderFallback-b250f4e9.js → renderFallback-Cy03ZcWE.js} +1 -1
  169. package/dist/esm/{shouldRenderTaxIdInput-ef7b5860.js → shouldRenderTaxIdInput-CKyZ6Zni.js} +2 -2
  170. package/dist/esm/{shouldShowLanguageSelect-328f50e2.js → shouldShowLanguageSelect-BQFCXouB.js} +1 -1
  171. package/dist/esm/{submitGtag-71c450b6.js → submitGtag-CCGQS060.js} +4 -4
  172. package/dist/esm/throttle-D5GyA3yr.js +85 -0
  173. package/dist/esm/{updateCheckoutSessionAttributes-23b222de.js → updateCheckoutSessionAttributes-eRSqdC74.js} +3 -3
  174. package/dist/esm/zonos-address-completion-dialog_7.entry.js +644 -690
  175. package/dist/esm/zonos-address-display_2.entry.js +13 -15
  176. package/dist/esm/zonos-address_4.entry.js +50 -38
  177. package/dist/esm/zonos-airwallex-payment.entry.js +15 -14
  178. package/dist/esm/zonos-badge.entry.js +7 -8
  179. package/dist/esm/zonos-banner.entry.js +6 -7
  180. package/dist/esm/zonos-button_3.entry.js +18 -19
  181. package/dist/esm/zonos-card_5.entry.js +34 -33
  182. package/dist/esm/zonos-cart-items_12.entry.js +101 -85
  183. package/dist/esm/zonos-checkbox_2.entry.js +10 -12
  184. package/dist/esm/zonos-checkout.entry.js +151 -35
  185. package/dist/esm/zonos-collapse.entry.js +5 -6
  186. package/dist/esm/zonos-collect-cart-items_3.entry.js +18 -21
  187. package/dist/esm/zonos-collect-finish_6.entry.js +59 -53
  188. package/dist/esm/zonos-collect.entry.js +20 -21
  189. package/dist/esm/zonos-component.entry.js +3 -4
  190. package/dist/esm/zonos-controller.entry.js +13 -14
  191. package/dist/esm/zonos-country-flag.entry.js +8 -9
  192. package/dist/esm/zonos-country-select_4.entry.js +68 -55
  193. package/dist/esm/zonos-elements.js +6 -5
  194. package/dist/esm/zonos-hello-dialog.entry.js +22 -21
  195. package/dist/esm/zonos-hello.entry.js +19 -15
  196. package/dist/esm/zonos-input.entry.js +10 -9
  197. package/dist/esm/zonos-invoice-cart-items_2.entry.js +17 -19
  198. package/dist/esm/zonos-invoice-finish_5.entry.js +57 -50
  199. package/dist/esm/zonos-invoice.entry.js +19 -20
  200. package/dist/esm/zonos-language-select_2.entry.js +11 -13
  201. package/dist/esm/zonos-link.entry.js +3 -4
  202. package/dist/esm/zonos-logo.entry.js +6 -7
  203. package/dist/esm/zonos-policy-consent_2.entry.js +15 -17
  204. package/dist/esm/zonos-shipping-rich-radio.entry.js +11 -12
  205. package/dist/esm/zonos-stripe-input.entry.js +15 -12
  206. package/dist/esm/zonos-text.entry.js +8 -9
  207. package/dist/esm/zonos-tooltip.entry.js +4 -5
  208. package/dist/esm/zonos-v-stack.entry.js +6 -7
  209. package/dist/esm/zonosStore-DrIOAz4M.js +3795 -0
  210. package/dist/esm-es5/{CheckoutConfig-724d7bae.js → CheckoutConfig-D5SpFsQJ.js} +5 -1
  211. package/dist/esm-es5/VarianceTest-BJmZPrZl.js +9 -0
  212. package/dist/esm-es5/{buildCartItemsByTempCart-a117f75d.js → buildCartItemsByTempCart-BycjkdlE.js} +4 -0
  213. package/dist/esm-es5/cart-ekBk_gxV.js +517 -0
  214. package/dist/esm-es5/classes-BJHSB96f.js +10 -0
  215. package/dist/esm-es5/cleanHtmlMarkdown-ByGDytaN.js +191 -0
  216. package/dist/esm-es5/collect-33rMINDo.js +241 -0
  217. package/dist/esm-es5/containsNonLatinChars-C04AWRC2.js +11 -0
  218. package/dist/esm-es5/createCustomEvent-XQfWgQLB.js +6 -0
  219. package/dist/esm-es5/debounce-D4ko2kvZ.js +153 -0
  220. package/dist/esm-es5/debounce-DWPsxJsW.js +1 -0
  221. package/dist/esm-es5/formatStringWithLinks-BcMPqGl0.js +8 -0
  222. package/dist/esm-es5/getBorderRadius-HwG64EKM.js +8 -0
  223. package/dist/esm-es5/getContrastColor-CfCPlW9U.js +14 -0
  224. package/dist/esm-es5/getGenericSettingsOverride-HeAZDwVW.js +4 -0
  225. package/dist/esm-es5/getMissingRequiredShippingFields-u1nhQzJ1.js +20 -0
  226. package/dist/esm-es5/handleFetch-D5GYDF-O.js +60 -0
  227. package/dist/esm-es5/hasInclusivePrice-CAVXi310.js +6 -0
  228. package/dist/esm-es5/helpers-DJIdCwJ5.js +23 -0
  229. package/dist/esm-es5/index-_lt63o7c.js +162 -0
  230. package/dist/esm-es5/index.js +227 -1
  231. package/dist/esm-es5/invoice-BNDWuVsD.js +13 -0
  232. package/dist/esm-es5/isColorVariable-DXXUq2Lv.js +11 -0
  233. package/dist/esm-es5/isContrastColor-CWLU13s9.js +5 -0
  234. package/dist/esm-es5/isDarkColor-YdrG78th.js +204 -0
  235. package/dist/esm-es5/isSameHostCheckoutLink-BxAHnL5J.js +16 -0
  236. package/dist/esm-es5/loader.js +1 -1
  237. package/dist/esm-es5/localization-AOqYXGdP.js +332 -0
  238. package/dist/esm-es5/paypal-CW1D2XqZ.js +192 -0
  239. package/dist/esm-es5/placeTestOrder-nhmsLLOA.js +1 -0
  240. package/dist/esm-es5/renderCheckoutCurrency-BQANmZyM.js +13 -0
  241. package/dist/esm-es5/{renderFallback-b250f4e9.js → renderFallback-Cy03ZcWE.js} +1 -1
  242. package/dist/esm-es5/shouldRenderTaxIdInput-CKyZ6Zni.js +17 -0
  243. package/dist/esm-es5/shouldShowLanguageSelect-BQFCXouB.js +7 -0
  244. package/dist/esm-es5/styles-BTIeCf3T.js +6 -0
  245. package/dist/esm-es5/submitGtag-CCGQS060.js +45 -0
  246. package/dist/esm-es5/throttle-D5GyA3yr.js +46 -0
  247. package/dist/esm-es5/updateCheckoutSessionAttributes-eRSqdC74.js +8 -0
  248. package/dist/esm-es5/zonos-address-completion-dialog_7.entry.js +2966 -1
  249. package/dist/esm-es5/zonos-address-display_2.entry.js +46 -1
  250. package/dist/esm-es5/zonos-address_4.entry.js +179 -1
  251. package/dist/esm-es5/zonos-airwallex-payment.entry.js +49 -1
  252. package/dist/esm-es5/zonos-badge.entry.js +25 -1
  253. package/dist/esm-es5/zonos-banner.entry.js +7 -1
  254. package/dist/esm-es5/zonos-button_3.entry.js +116 -1
  255. package/dist/esm-es5/zonos-card_5.entry.js +33 -1
  256. package/dist/esm-es5/zonos-cart-items_12.entry.js +666 -1
  257. package/dist/esm-es5/zonos-checkbox_2.entry.js +21 -1
  258. package/dist/esm-es5/zonos-checkout.entry.js +1043 -1
  259. package/dist/esm-es5/zonos-collapse.entry.js +15 -1
  260. package/dist/esm-es5/zonos-collect-cart-items_3.entry.js +13 -1
  261. package/dist/esm-es5/zonos-collect-finish_6.entry.js +157 -1
  262. package/dist/esm-es5/zonos-collect.entry.js +171 -1
  263. package/dist/esm-es5/zonos-component.entry.js +10 -1
  264. package/dist/esm-es5/zonos-controller.entry.js +198 -1
  265. package/dist/esm-es5/zonos-country-flag.entry.js +6 -1
  266. package/dist/esm-es5/zonos-country-select_4.entry.js +152 -1
  267. package/dist/esm-es5/zonos-elements.js +4 -1
  268. package/dist/esm-es5/zonos-hello-dialog.entry.js +63 -1
  269. package/dist/esm-es5/zonos-hello.entry.js +121 -1
  270. package/dist/esm-es5/zonos-input.entry.js +16 -1
  271. package/dist/esm-es5/zonos-invoice-cart-items_2.entry.js +7 -1
  272. package/dist/esm-es5/zonos-invoice-finish_5.entry.js +133 -1
  273. package/dist/esm-es5/zonos-invoice.entry.js +115 -1
  274. package/dist/esm-es5/zonos-language-select_2.entry.js +14 -1
  275. package/dist/esm-es5/zonos-link.entry.js +4 -1
  276. package/dist/esm-es5/zonos-logo.entry.js +7 -1
  277. package/dist/esm-es5/zonos-policy-consent_2.entry.js +31 -1
  278. package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +5 -1
  279. package/dist/esm-es5/zonos-stripe-input.entry.js +27 -1
  280. package/dist/esm-es5/zonos-text.entry.js +24 -1
  281. package/dist/esm-es5/zonos-tooltip.entry.js +7 -1
  282. package/dist/esm-es5/zonos-v-stack.entry.js +5 -1
  283. package/dist/esm-es5/zonosStore-DrIOAz4M.js +1153 -0
  284. package/dist/scripts/index.d.ts +1167 -514
  285. package/dist/scripts/index.js +1 -1
  286. package/dist/scripts/loadZonos.js +1 -1
  287. package/dist/scripts/zonos.js +1 -1
  288. package/dist/types/__tests__/jsxWithChildren.types.d.ts +14 -0
  289. package/dist/types/__tests__/vitest-globals.d.ts +1 -0
  290. package/dist/types/components/checkout/zonos-checkout/zonos-checkout.d.ts +14 -0
  291. package/dist/types/components/store/checkout/cart.d.ts +19 -10
  292. package/dist/types/components/utils/api/checkItemRestrictions.d.ts +2 -2
  293. package/dist/types/components/utils/api/getLocaleMessages.d.ts +5 -5
  294. package/dist/types/components/utils/checkout/isShippableCountry.d.ts +5 -1
  295. package/dist/types/components/utils/hello/detectItemRestrictions.d.ts +2 -2
  296. package/dist/types/components.d.ts +797 -147
  297. package/dist/types/scripts/cart/_setupCartDataWithSettings.d.ts +124 -124
  298. package/dist/types/stencil-public-runtime.d.ts +205 -12
  299. package/dist/types/types/generated/graphql.frontend.types.d.ts +62 -60
  300. package/dist/types/types/generated/graphql.frontend.types.ts +57 -55
  301. package/dist/types/types/generated/graphql.internal.types.d.ts +1346 -1251
  302. package/dist/types/types/generated/graphql.internal.types.ts +1187 -1075
  303. package/dist/zonos-elements/index.esm.js +1 -1
  304. package/dist/zonos-elements/p-02ef0f99.system.entry.js +6 -0
  305. package/dist/zonos-elements/{p-1be53c82.entry.js → p-0466650f.entry.js} +1 -1
  306. package/dist/zonos-elements/p-04bfcd72.system.entry.js +152 -0
  307. package/dist/zonos-elements/p-04cc0dac.system.entry.js +198 -0
  308. package/dist/zonos-elements/p-058f07aa.system.entry.js +7 -0
  309. package/dist/zonos-elements/p-0f603278.system.entry.js +5 -0
  310. package/dist/zonos-elements/{p-bb09ee50.entry.js → p-128485dc.entry.js} +1 -1
  311. package/dist/zonos-elements/p-1568ab06.system.entry.js +117 -0
  312. package/dist/zonos-elements/p-2ba738ec.entry.js +1 -0
  313. package/dist/zonos-elements/{p-6afd5fab.entry.js → p-31ac495f.entry.js} +1 -1
  314. package/dist/zonos-elements/p-34d1545a.entry.js +1 -0
  315. package/dist/zonos-elements/p-39c8a898.entry.js +1 -0
  316. package/dist/zonos-elements/p-3ERbuo5a.js +1 -0
  317. package/dist/zonos-elements/p-450ed170.system.entry.js +46 -0
  318. package/dist/zonos-elements/p-4973f8d8.system.entry.js +180 -0
  319. package/dist/zonos-elements/p-49e7bb1e.system.entry.js +7 -0
  320. package/dist/zonos-elements/p-4a54f664.entry.js +1 -0
  321. package/dist/zonos-elements/p-4ab1c533.system.entry.js +4 -0
  322. package/dist/zonos-elements/p-5024df2d.system.entry.js +666 -0
  323. package/dist/zonos-elements/p-5562a955.system.entry.js +7 -0
  324. package/dist/zonos-elements/p-5836d426.system.entry.js +49 -0
  325. package/dist/zonos-elements/p-5a631080.system.entry.js +13 -0
  326. package/dist/zonos-elements/{p-2ce039e5.entry.js → p-5c08d36b.entry.js} +1 -1
  327. package/dist/zonos-elements/{p-aed4ffb2.entry.js → p-5d3079e8.entry.js} +1 -1
  328. package/dist/zonos-elements/p-629f09dc.system.entry.js +171 -0
  329. package/dist/zonos-elements/p-64e7bc5b.entry.js +1 -0
  330. package/dist/zonos-elements/p-6b0afaa7.entry.js +1 -0
  331. package/dist/zonos-elements/p-6f742021.entry.js +1 -0
  332. package/dist/zonos-elements/p-7681798d.entry.js +1 -0
  333. package/dist/zonos-elements/p-7a5d2211.system.entry.js +115 -0
  334. package/dist/zonos-elements/{p-b1e95f95.entry.js → p-7ae48e31.entry.js} +1 -1
  335. package/dist/zonos-elements/{p-f37150e8.entry.js → p-8328f44d.entry.js} +1 -1
  336. package/dist/zonos-elements/{p-171a7e1e.entry.js → p-844a743a.entry.js} +1 -1
  337. package/dist/zonos-elements/p-891b47d7.entry.js +1 -0
  338. package/dist/zonos-elements/p-89ddab88.entry.js +1 -0
  339. package/dist/zonos-elements/p-8cd3f1e2.entry.js +1 -0
  340. package/dist/zonos-elements/p-9818f823.entry.js +1 -0
  341. package/dist/zonos-elements/p-9b399685.system.entry.js +10 -0
  342. package/dist/zonos-elements/p-9b6482ef.entry.js +1 -0
  343. package/dist/zonos-elements/{p-2c44e013.entry.js → p-9ebe9a36.entry.js} +1 -1
  344. package/dist/zonos-elements/p-B2EZRfoq.system.js +193 -0
  345. package/dist/zonos-elements/p-B3GRrRtL.system.js +5 -0
  346. package/dist/zonos-elements/p-BANhKkF2.system.js +1 -0
  347. package/dist/zonos-elements/p-BDopxBpR.system.js +6 -0
  348. package/dist/zonos-elements/p-BJufDgh3.js +1 -0
  349. package/dist/zonos-elements/p-BLQFeIez.system.js +191 -0
  350. package/dist/zonos-elements/p-BNtWsPPP.system.js +7 -0
  351. package/dist/zonos-elements/p-BSgVcCxT.system.js +9 -0
  352. package/dist/zonos-elements/p-BXjdMMUy.js +1 -0
  353. package/dist/zonos-elements/p-BbgqQIHv.system.js +9 -0
  354. package/dist/zonos-elements/p-BgSx82zO.system.js +11 -0
  355. package/dist/zonos-elements/p-Bi-s0fp_.system.js +17 -0
  356. package/dist/zonos-elements/p-Bu9WCfUC.system.js +5 -0
  357. package/dist/zonos-elements/p-C19J2XSh.js +1 -0
  358. package/dist/zonos-elements/p-C2QMVeWW.js +1 -0
  359. package/dist/zonos-elements/p-C2j7R11h.system.js +11 -0
  360. package/dist/zonos-elements/p-CEl4pzNq.js +1 -0
  361. package/dist/zonos-elements/p-CICjAi70.js +1 -0
  362. package/dist/zonos-elements/p-CIevpRv_.system.js +162 -0
  363. package/dist/zonos-elements/{p-e5c76a9b.js → p-CJCoACvU.js} +2 -2
  364. package/dist/zonos-elements/p-CKBbIU4b.system.js +14 -0
  365. package/dist/zonos-elements/p-CKTIJ2Gr.js +1 -0
  366. package/dist/zonos-elements/p-CKhl__Kc.system.js +4 -0
  367. package/dist/zonos-elements/p-CPnR_T0a.system.js +1153 -0
  368. package/dist/zonos-elements/p-CQqNJo0D.system.js +13 -0
  369. package/dist/zonos-elements/p-CYdt69j5.system.js +241 -0
  370. package/dist/zonos-elements/p-CZl1nwqv.system.js +46 -0
  371. package/dist/zonos-elements/p-CaAod213.system.js +8 -0
  372. package/dist/zonos-elements/p-CaUXHglQ.system.js +153 -0
  373. package/dist/zonos-elements/{p-45bd8072.system.js → p-CeLaK0Ff.system.js} +1 -1
  374. package/dist/zonos-elements/p-CtEsvWI6.js +1 -0
  375. package/dist/zonos-elements/p-D-DawUYF.system.js +1 -0
  376. package/dist/zonos-elements/p-D0erXw7p.js +1 -0
  377. package/dist/zonos-elements/p-D31lQiWo.system.js +21 -0
  378. package/dist/zonos-elements/p-D5AtAlJx.system.js +13 -0
  379. package/dist/zonos-elements/p-DBOI98r5.system.js +7 -0
  380. package/dist/zonos-elements/{p-41dd1cb8.js → p-DE4a-QD5.js} +1 -1
  381. package/dist/zonos-elements/p-DGsEWFDU.system.js +8 -0
  382. package/dist/zonos-elements/p-DHwpNxG9.js +1 -0
  383. package/dist/zonos-elements/p-DIJaXkiE.system.js +332 -0
  384. package/dist/zonos-elements/{p-eef5b0cc.js → p-DJIdCwJ5.js} +1 -1
  385. package/dist/zonos-elements/p-DPW1yXt9.system.js +517 -0
  386. package/dist/zonos-elements/{p-6bdc5c96.js → p-DTgv0QpG.js} +1 -1
  387. package/dist/zonos-elements/p-DW-fW8yR.system.js +205 -0
  388. package/dist/zonos-elements/p-Dj-O6VfM.system.js +7 -0
  389. package/dist/zonos-elements/p-DjuFsKLG.js +1 -0
  390. package/dist/zonos-elements/p-DkpYo2Fs.js +1 -0
  391. package/dist/zonos-elements/p-DnjGkbEy.js +1 -0
  392. package/dist/zonos-elements/p-Dw-5yD9y.system.js +227 -0
  393. package/dist/zonos-elements/{p-46cd14e5.js → p-LypTHRUC.js} +1 -1
  394. package/dist/zonos-elements/p-MfsSJh_D.system.js +8 -0
  395. package/dist/zonos-elements/p-YdrG78th.js +1 -0
  396. package/dist/zonos-elements/p-_lt63o7c.js +3 -0
  397. package/dist/zonos-elements/p-a38e62cc.entry.js +1 -0
  398. package/dist/zonos-elements/p-a6faab6a.entry.js +1 -0
  399. package/dist/zonos-elements/p-adfee3a3.entry.js +1 -0
  400. package/dist/zonos-elements/p-b14819ab.system.entry.js +14 -0
  401. package/dist/zonos-elements/{p-0c972ddf.entry.js → p-b68ca96f.entry.js} +1 -1
  402. package/dist/zonos-elements/p-b6deae2b.system.entry.js +5 -0
  403. package/dist/zonos-elements/p-bdba7d9e.system.entry.js +25 -0
  404. package/dist/zonos-elements/p-be64d823.system.entry.js +16 -0
  405. package/dist/zonos-elements/p-beeb9d36.system.entry.js +21 -0
  406. package/dist/zonos-elements/p-cadf6b63.system.entry.js +33 -0
  407. package/dist/zonos-elements/p-cc5306fe.system.entry.js +24 -0
  408. package/dist/zonos-elements/p-cc949df1.system.entry.js +7 -0
  409. package/dist/zonos-elements/{p-bced320e.entry.js → p-cdffc9b6.entry.js} +1 -1
  410. package/dist/zonos-elements/p-cf5688f7.entry.js +1 -0
  411. package/dist/zonos-elements/p-d05Ku7gM.system.js +24 -0
  412. package/dist/zonos-elements/p-d33dfc78.system.entry.js +2966 -0
  413. package/dist/zonos-elements/p-d55b9664.system.entry.js +157 -0
  414. package/dist/zonos-elements/p-daf9fa07.system.entry.js +133 -0
  415. package/dist/zonos-elements/p-dcdbc610.system.entry.js +27 -0
  416. package/dist/zonos-elements/p-e101d722.system.entry.js +63 -0
  417. package/dist/zonos-elements/{p-9639a8ed.entry.js → p-e284d329.entry.js} +1 -1
  418. package/dist/zonos-elements/{p-8311edc7.entry.js → p-e9320825.entry.js} +1 -1
  419. package/dist/zonos-elements/p-ea8790aa.entry.js +1 -0
  420. package/dist/zonos-elements/{p-6ee4e027.entry.js → p-eadaefdc.entry.js} +1 -1
  421. package/dist/zonos-elements/p-f27317d3.system.entry.js +31 -0
  422. package/dist/zonos-elements/p-f2cedbcd.system.entry.js +121 -0
  423. package/dist/zonos-elements/p-f57495dc.entry.js +1 -0
  424. package/dist/zonos-elements/p-f6e0aeba.system.entry.js +1043 -0
  425. package/dist/zonos-elements/p-f8fd756a.system.entry.js +15 -0
  426. package/dist/zonos-elements/{p-7ada039e.entry.js → p-fe778437.entry.js} +1 -1
  427. package/dist/zonos-elements/{p-adfbf57b.js → p-i1iCWKdv.js} +1 -1
  428. package/dist/zonos-elements/p-lGLcGvEA.js +1 -0
  429. package/dist/zonos-elements/p-nOb4xPLF.system.js +17 -0
  430. package/dist/zonos-elements/p-nU86HJ5w.js +1 -0
  431. package/dist/zonos-elements/p-pfIceXbY.js +1 -0
  432. package/dist/zonos-elements/p-smUku7Ku.system.js +5 -0
  433. package/dist/zonos-elements/p-t_ClFAJR.js +1 -0
  434. package/dist/zonos-elements/p-uV7m6KrY.system.js +46 -0
  435. package/dist/zonos-elements/p-vN6p_rO1.system.js +11 -0
  436. package/dist/zonos-elements/p-zRjRcLMp.js +1 -0
  437. package/dist/zonos-elements/p-zVLAvre1.system.js +60 -0
  438. package/dist/zonos-elements/zonos-elements.esm.js +1 -1
  439. package/dist/zonos-elements/zonos-elements.js +1 -1
  440. package/loader/index.d.ts +1 -1
  441. package/package.json +28 -32
  442. package/dist/cjs/RemoveIcon-081ac073.js +0 -5
  443. package/dist/cjs/debounce-7ca3c878.js +0 -357
  444. package/dist/cjs/isDarkColor-a6e6fd5e.js +0 -1202
  445. package/dist/cjs/throttle-366c204b.js +0 -76
  446. package/dist/cjs/zonosStore-0af0b937.js +0 -3030
  447. package/dist/esm/RemoveIcon-9dc5dd1a.js +0 -3
  448. package/dist/esm/debounce-84ade9c2.js +0 -355
  449. package/dist/esm/isDarkColor-939d8e9c.js +0 -1199
  450. package/dist/esm/throttle-c4c24e86.js +0 -74
  451. package/dist/esm/zonosStore-eca1e364.js +0 -3017
  452. package/dist/esm-es5/VarianceTest-572cecf5.js +0 -1
  453. package/dist/esm-es5/cart-2e407f7b.js +0 -1
  454. package/dist/esm-es5/classes-0d95c529.js +0 -1
  455. package/dist/esm-es5/cleanHtmlMarkdown-87d195f6.js +0 -1
  456. package/dist/esm-es5/collect-19428e18.js +0 -1
  457. package/dist/esm-es5/containsNonLatinChars-2d8810c3.js +0 -1
  458. package/dist/esm-es5/createCustomEvent-58159025.js +0 -1
  459. package/dist/esm-es5/debounce-84ade9c2.js +0 -1
  460. package/dist/esm-es5/formatStringWithLinks-0d48f183.js +0 -1
  461. package/dist/esm-es5/getBorderRadius-1f7be586.js +0 -1
  462. package/dist/esm-es5/getContrastColor-4c0ae8c1.js +0 -1
  463. package/dist/esm-es5/getGenericSettingsOverride-0bc3e118.js +0 -1
  464. package/dist/esm-es5/getMissingRequiredShippingFields-719b206f.js +0 -1
  465. package/dist/esm-es5/handleFetch-a844cac1.js +0 -1
  466. package/dist/esm-es5/hasInclusivePrice-d801be22.js +0 -1
  467. package/dist/esm-es5/helpers-2f6955b1.js +0 -1
  468. package/dist/esm-es5/index-cfd394c8.js +0 -13
  469. package/dist/esm-es5/invoice-67a47785.js +0 -1
  470. package/dist/esm-es5/isColorVariable-0a94004f.js +0 -1
  471. package/dist/esm-es5/isContrastColor-9fa0d013.js +0 -1
  472. package/dist/esm-es5/isDarkColor-939d8e9c.js +0 -1
  473. package/dist/esm-es5/isSameHostCheckoutLink-c1b88ab7.js +0 -1
  474. package/dist/esm-es5/localization-36a4dc22.js +0 -1
  475. package/dist/esm-es5/paypal-6dca6567.js +0 -17
  476. package/dist/esm-es5/placeTestOrder-9563c89a.js +0 -1
  477. package/dist/esm-es5/renderCheckoutCurrency-282384f0.js +0 -1
  478. package/dist/esm-es5/shouldRenderTaxIdInput-ef7b5860.js +0 -1
  479. package/dist/esm-es5/shouldShowLanguageSelect-328f50e2.js +0 -1
  480. package/dist/esm-es5/styles-6fc2fad9.js +0 -1
  481. package/dist/esm-es5/submitGtag-71c450b6.js +0 -1
  482. package/dist/esm-es5/throttle-c4c24e86.js +0 -1
  483. package/dist/esm-es5/updateCheckoutSessionAttributes-23b222de.js +0 -1
  484. package/dist/esm-es5/zonosStore-eca1e364.js +0 -1
  485. package/dist/zonos-elements/p-01174496.system.js +0 -1
  486. package/dist/zonos-elements/p-06f798ee.system.js +0 -1
  487. package/dist/zonos-elements/p-083a11cd.system.entry.js +0 -1
  488. package/dist/zonos-elements/p-08e7107d.js +0 -1
  489. package/dist/zonos-elements/p-0b29169b.js +0 -1
  490. package/dist/zonos-elements/p-0c9fec73.js +0 -1
  491. package/dist/zonos-elements/p-0d2f81ce.system.js +0 -1
  492. package/dist/zonos-elements/p-0e199a6c.system.entry.js +0 -1
  493. package/dist/zonos-elements/p-0ff845ec.js +0 -1
  494. package/dist/zonos-elements/p-1277abac.system.entry.js +0 -1
  495. package/dist/zonos-elements/p-14afffa8.system.js +0 -1
  496. package/dist/zonos-elements/p-1834f486.js +0 -1
  497. package/dist/zonos-elements/p-1aa93d1e.system.js +0 -1
  498. package/dist/zonos-elements/p-1ac0c631.system.js +0 -1
  499. package/dist/zonos-elements/p-1b8771bb.js +0 -1
  500. package/dist/zonos-elements/p-1cdd27ec.js +0 -1
  501. package/dist/zonos-elements/p-1f8648c8.system.entry.js +0 -1
  502. package/dist/zonos-elements/p-22e10b7d.entry.js +0 -1
  503. package/dist/zonos-elements/p-23e7c655.system.js +0 -1
  504. package/dist/zonos-elements/p-260ad739.system.entry.js +0 -1
  505. package/dist/zonos-elements/p-2670438c.system.js +0 -1
  506. package/dist/zonos-elements/p-27660512.js +0 -1
  507. package/dist/zonos-elements/p-29b60bf3.system.js +0 -1
  508. package/dist/zonos-elements/p-2b8c96e3.system.js +0 -1
  509. package/dist/zonos-elements/p-2b97f7ed.js +0 -1
  510. package/dist/zonos-elements/p-2bbe9d91.js +0 -1
  511. package/dist/zonos-elements/p-2c2afed4.entry.js +0 -1
  512. package/dist/zonos-elements/p-2c7a425d.entry.js +0 -1
  513. package/dist/zonos-elements/p-2cab1746.system.entry.js +0 -1
  514. package/dist/zonos-elements/p-2cdd1b49.system.entry.js +0 -1
  515. package/dist/zonos-elements/p-3490b6d0.entry.js +0 -1
  516. package/dist/zonos-elements/p-398d9022.system.js +0 -1
  517. package/dist/zonos-elements/p-3a13e58c.system.js +0 -1
  518. package/dist/zonos-elements/p-40a4c8a2.system.js +0 -1
  519. package/dist/zonos-elements/p-4160bbc2.system.js +0 -1
  520. package/dist/zonos-elements/p-4671fde7.entry.js +0 -1
  521. package/dist/zonos-elements/p-4a20893e.system.js +0 -1
  522. package/dist/zonos-elements/p-4b159ff3.system.js +0 -1
  523. package/dist/zonos-elements/p-502d6eeb.js +0 -1
  524. package/dist/zonos-elements/p-51e4e61a.system.entry.js +0 -1
  525. package/dist/zonos-elements/p-551fa762.system.js +0 -1
  526. package/dist/zonos-elements/p-5a491f28.js +0 -1
  527. package/dist/zonos-elements/p-5b990c91.entry.js +0 -1
  528. package/dist/zonos-elements/p-5ebb7ae6.entry.js +0 -1
  529. package/dist/zonos-elements/p-60832726.system.js +0 -1
  530. package/dist/zonos-elements/p-60a6b71d.system.js +0 -1
  531. package/dist/zonos-elements/p-62f6a757.entry.js +0 -1
  532. package/dist/zonos-elements/p-65c1f51e.entry.js +0 -1
  533. package/dist/zonos-elements/p-6695de06.system.js +0 -1
  534. package/dist/zonos-elements/p-67426156.system.js +0 -1
  535. package/dist/zonos-elements/p-6890e060.system.js +0 -1
  536. package/dist/zonos-elements/p-6dde1e85.system.entry.js +0 -1
  537. package/dist/zonos-elements/p-7176f582.entry.js +0 -1
  538. package/dist/zonos-elements/p-7261e245.system.js +0 -13
  539. package/dist/zonos-elements/p-76834a0a.system.entry.js +0 -1
  540. package/dist/zonos-elements/p-7ac8846c.system.js +0 -1
  541. package/dist/zonos-elements/p-7fbbdb0f.system.js +0 -1
  542. package/dist/zonos-elements/p-8a0b8175.system.entry.js +0 -1
  543. package/dist/zonos-elements/p-8a6c4017.js +0 -1
  544. package/dist/zonos-elements/p-8b298971.system.entry.js +0 -1
  545. package/dist/zonos-elements/p-8be02f3a.system.js +0 -1
  546. package/dist/zonos-elements/p-8bfe5b2b.entry.js +0 -1
  547. package/dist/zonos-elements/p-8e6338b9.entry.js +0 -1
  548. package/dist/zonos-elements/p-916228fb.system.js +0 -1
  549. package/dist/zonos-elements/p-94722bf6.system.entry.js +0 -1
  550. package/dist/zonos-elements/p-947e4402.system.entry.js +0 -1
  551. package/dist/zonos-elements/p-9ad640b2.system.entry.js +0 -1
  552. package/dist/zonos-elements/p-9ecb9afc.system.entry.js +0 -1
  553. package/dist/zonos-elements/p-a04e2750.system.entry.js +0 -1
  554. package/dist/zonos-elements/p-a07e5011.entry.js +0 -1
  555. package/dist/zonos-elements/p-a1bd3a53.system.js +0 -1
  556. package/dist/zonos-elements/p-a553e132.js +0 -1
  557. package/dist/zonos-elements/p-a9ad74e5.system.entry.js +0 -1
  558. package/dist/zonos-elements/p-acb7dee1.system.entry.js +0 -1
  559. package/dist/zonos-elements/p-ae0de3e4.entry.js +0 -1
  560. package/dist/zonos-elements/p-aecb5d61.entry.js +0 -1
  561. package/dist/zonos-elements/p-af19722c.system.js +0 -1
  562. package/dist/zonos-elements/p-b4ae66cb.system.entry.js +0 -1
  563. package/dist/zonos-elements/p-bcaffb85.system.entry.js +0 -1
  564. package/dist/zonos-elements/p-be6cd28c.system.entry.js +0 -1
  565. package/dist/zonos-elements/p-bf37ccc7.system.js +0 -1
  566. package/dist/zonos-elements/p-c1631c9c.js +0 -1
  567. package/dist/zonos-elements/p-c5d1217f.system.js +0 -1
  568. package/dist/zonos-elements/p-c77b049c.entry.js +0 -1
  569. package/dist/zonos-elements/p-ca87ada5.system.entry.js +0 -1
  570. package/dist/zonos-elements/p-cb49dcfe.entry.js +0 -1
  571. package/dist/zonos-elements/p-cb4cb5a3.system.js +0 -1
  572. package/dist/zonos-elements/p-ce75b047.js +0 -2
  573. package/dist/zonos-elements/p-d20fe2c2.system.entry.js +0 -1
  574. package/dist/zonos-elements/p-d42bd250.system.entry.js +0 -1
  575. package/dist/zonos-elements/p-d6a73125.system.entry.js +0 -1
  576. package/dist/zonos-elements/p-d938f42f.system.js +0 -1
  577. package/dist/zonos-elements/p-dc80cb87.js +0 -1
  578. package/dist/zonos-elements/p-dd3c00d6.system.entry.js +0 -1
  579. package/dist/zonos-elements/p-de58684b.system.js +0 -1
  580. package/dist/zonos-elements/p-e160b75f.js +0 -1
  581. package/dist/zonos-elements/p-e1ef3984.system.entry.js +0 -1
  582. package/dist/zonos-elements/p-e27b8e18.entry.js +0 -1
  583. package/dist/zonos-elements/p-e2b4c082.system.entry.js +0 -1
  584. package/dist/zonos-elements/p-e32ee011.system.entry.js +0 -1
  585. package/dist/zonos-elements/p-e4b07f7d.system.entry.js +0 -1
  586. package/dist/zonos-elements/p-e8587f9f.system.entry.js +0 -1
  587. package/dist/zonos-elements/p-eb5f3451.system.js +0 -18
  588. package/dist/zonos-elements/p-ebbda085.system.js +0 -1
  589. package/dist/zonos-elements/p-f4720b0a.js +0 -1
  590. package/dist/zonos-elements/p-f4acce01.js +0 -1
  591. package/dist/zonos-elements/p-f59a0129.system.entry.js +0 -1
  592. package/dist/zonos-elements/p-f8356934.system.entry.js +0 -1
  593. package/dist/zonos-elements/p-fe5f05fc.system.js +0 -1
  594. package/dist/zonos-elements/p-ff4e6811.entry.js +0 -1
  595. package/loader/package.json +0 -11
  596. /package/dist/cjs/{CheckoutConfig-27c82f94.js → CheckoutConfig-B7JRM7yr.js} +0 -0
  597. /package/dist/cjs/{ShortAddressCode-bec338b0.js → ShortAddressCode-C5l520-F.js} +0 -0
  598. /package/dist/cjs/{TaxId-cd9d490e.js → TaxId-Q6aDqqWv.js} +0 -0
  599. /package/dist/cjs/{VarianceTest-bec00ea8.js → VarianceTest-C98whVgO.js} +0 -0
  600. /package/dist/cjs/{app-globals-3a1e7e63.js → app-globals-V2Kpy_OQ.js} +0 -0
  601. /package/dist/cjs/{buildCartItemsByTempCart-edddbf4b.js → buildCartItemsByTempCart-ILzonEjb.js} +0 -0
  602. /package/dist/cjs/{classes-b7918f56.js → classes-D_DL168u.js} +0 -0
  603. /package/dist/cjs/{cleanHtmlMarkdown-57147de7.js → cleanHtmlMarkdown-DpT-nZLH.js} +0 -0
  604. /package/dist/cjs/{containsNonLatinChars-2be5129b.js → containsNonLatinChars-D_OggJN6.js} +0 -0
  605. /package/dist/cjs/{createCustomEvent-7b6fad95.js → createCustomEvent-Cs5zGImL.js} +0 -0
  606. /package/dist/cjs/{getGenericSettingsOverride-c0ca32b9.js → getGenericSettingsOverride-CL6l6wvX.js} +0 -0
  607. /package/dist/cjs/{getHasMoreSpaceOnRight-4c94667f.js → getHasMoreSpaceOnRight-Cl50u1mb.js} +0 -0
  608. /package/dist/cjs/{isCollectMobileTablet-884d4280.js → isCollectMobileTablet-Cx2nZ15_.js} +0 -0
  609. /package/dist/cjs/{isColorVariable-525dbfa7.js → isColorVariable-CKoJdu9G.js} +0 -0
  610. /package/dist/cjs/{isInvoiceMobileTablet-dde41e4e.js → isInvoiceMobileTablet-CCqFYV6m.js} +0 -0
  611. /package/dist/cjs/{isSameHostCheckoutLink-6148cabb.js → isSameHostCheckoutLink-DbmQ7Ha4.js} +0 -0
  612. /package/dist/cjs/{styles-d1e64fb9.js → styles-nowYls3K.js} +0 -0
  613. /package/dist/esm/{CheckoutConfig-724d7bae.js → CheckoutConfig-D5SpFsQJ.js} +0 -0
  614. /package/dist/esm/{ShortAddressCode-7620e622.js → ShortAddressCode-nJ6oI8-n.js} +0 -0
  615. /package/dist/esm/{TaxId-63a14057.js → TaxId-Cye-evFK.js} +0 -0
  616. /package/dist/esm/{VarianceTest-572cecf5.js → VarianceTest-BJmZPrZl.js} +0 -0
  617. /package/dist/esm/{app-globals-0f993ce5.js → app-globals-DQuL1Twl.js} +0 -0
  618. /package/dist/esm/{buildCartItemsByTempCart-a117f75d.js → buildCartItemsByTempCart-BycjkdlE.js} +0 -0
  619. /package/dist/esm/{classes-0d95c529.js → classes-BJHSB96f.js} +0 -0
  620. /package/dist/esm/{cleanHtmlMarkdown-87d195f6.js → cleanHtmlMarkdown-ByGDytaN.js} +0 -0
  621. /package/dist/esm/{containsNonLatinChars-2d8810c3.js → containsNonLatinChars-C04AWRC2.js} +0 -0
  622. /package/dist/esm/{createCustomEvent-58159025.js → createCustomEvent-XQfWgQLB.js} +0 -0
  623. /package/dist/esm/{getGenericSettingsOverride-0bc3e118.js → getGenericSettingsOverride-HeAZDwVW.js} +0 -0
  624. /package/dist/esm/{getHasMoreSpaceOnRight-70eb913a.js → getHasMoreSpaceOnRight-DAscqB23.js} +0 -0
  625. /package/dist/esm/{isCollectMobileTablet-111b0dd7.js → isCollectMobileTablet-DGlnuxEX.js} +0 -0
  626. /package/dist/esm/{isColorVariable-0a94004f.js → isColorVariable-DXXUq2Lv.js} +0 -0
  627. /package/dist/esm/{isInvoiceMobileTablet-1f7b614e.js → isInvoiceMobileTablet-Clej0Ffe.js} +0 -0
  628. /package/dist/esm/{isSameHostCheckoutLink-c1b88ab7.js → isSameHostCheckoutLink-BxAHnL5J.js} +0 -0
  629. /package/dist/esm/{styles-6fc2fad9.js → styles-BTIeCf3T.js} +0 -0
  630. /package/dist/esm-es5/{RemoveIcon-9dc5dd1a.js → RemoveIcon-C2QMVeWW.js} +0 -0
  631. /package/dist/esm-es5/{ShortAddressCode-7620e622.js → ShortAddressCode-nJ6oI8-n.js} +0 -0
  632. /package/dist/esm-es5/{TaxId-63a14057.js → TaxId-Cye-evFK.js} +0 -0
  633. /package/dist/esm-es5/{app-globals-0f993ce5.js → app-globals-DQuL1Twl.js} +0 -0
  634. /package/dist/esm-es5/{getHasMoreSpaceOnRight-70eb913a.js → getHasMoreSpaceOnRight-DAscqB23.js} +0 -0
  635. /package/dist/esm-es5/{isCollectMobileTablet-111b0dd7.js → isCollectMobileTablet-DGlnuxEX.js} +0 -0
  636. /package/dist/esm-es5/{isInvoiceMobileTablet-1f7b614e.js → isInvoiceMobileTablet-Clej0Ffe.js} +0 -0
  637. /package/dist/zonos-elements/{p-2770ba48.system.js → p-0D0aCMu6.system.js} +0 -0
  638. /package/dist/zonos-elements/{p-b4b7f705.js → p-BJHSB96f.js} +0 -0
  639. /package/dist/zonos-elements/{p-0a377722.js → p-BJmZPrZl.js} +0 -0
  640. /package/dist/zonos-elements/{p-96d77739.js → p-BTIeCf3T.js} +0 -0
  641. /package/dist/zonos-elements/{p-56ba5cbf.system.js → p-BbPAtVJG.system.js} +0 -0
  642. /package/dist/zonos-elements/{p-11206fe2.js → p-BxAHnL5J.js} +0 -0
  643. /package/dist/zonos-elements/{p-cc6ad18a.js → p-ByGDytaN.js} +0 -0
  644. /package/dist/zonos-elements/{p-83666056.js → p-BycjkdlE.js} +0 -0
  645. /package/dist/zonos-elements/{p-0c64dbbb.js → p-C04AWRC2.js} +0 -0
  646. /package/dist/zonos-elements/{p-655ec440.system.js → p-C29tlYn0.system.js} +0 -0
  647. /package/dist/zonos-elements/{p-2adbbce7.system.js → p-CLDnjFm5.system.js} +0 -0
  648. /package/dist/zonos-elements/{p-989cb22b.system.js → p-Cby4EkFu.system.js} +0 -0
  649. /package/dist/zonos-elements/{p-1f3549c6.js → p-Clej0Ffe.js} +0 -0
  650. /package/dist/zonos-elements/{p-bcf5cffb.js → p-Cye-evFK.js} +0 -0
  651. /package/dist/zonos-elements/{p-b2d81c98.js → p-D5SpFsQJ.js} +0 -0
  652. /package/dist/zonos-elements/{p-5883217a.js → p-DAscqB23.js} +0 -0
  653. /package/dist/zonos-elements/{p-579932a7.js → p-DGlnuxEX.js} +0 -0
  654. /package/dist/zonos-elements/{p-e1255160.js → p-DQuL1Twl.js} +0 -0
  655. /package/dist/zonos-elements/{p-ae393255.js → p-DXXUq2Lv.js} +0 -0
  656. /package/dist/zonos-elements/{p-e7b0c156.js → p-HeAZDwVW.js} +0 -0
  657. /package/dist/zonos-elements/{p-595f5dd2.js → p-XQfWgQLB.js} +0 -0
  658. /package/dist/zonos-elements/{p-bc7bf53e.system.js → p-Z99tSPFR.system.js} +0 -0
  659. /package/dist/zonos-elements/{p-6f23a26a.system.js → p-_GDmY2H7.system.js} +0 -0
  660. /package/dist/zonos-elements/{p-1d42cd20.js → p-nJ6oI8-n.js} +0 -0
@@ -0,0 +1,157 @@
1
+ var __awaiter=this&&this.__awaiter||function(o,e,t,n){function s(o){return o instanceof t?o:new t((function(e){e(o)}))}return new(t||(t=Promise))((function(t,a){function l(o){try{r(n.next(o))}catch(o){a(o)}}function i(o){try{r(n["throw"](o))}catch(o){a(o)}}function r(o){o.done?t(o.value):s(o.value).then(l,i)}r((n=n.apply(o,e||[])).next())}))};var __generator=this&&this.__generator||function(o,e){var t={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,s,a,l=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return l.next=i(0),l["throw"]=i(1),l["return"]=i(2),typeof Symbol==="function"&&(l[Symbol.iterator]=function(){return this}),l;function i(o){return function(e){return r([o,e])}}function r(i){if(n)throw new TypeError("Generator is already executing.");while(l&&(l=0,i[0]&&(t=0)),t)try{if(n=1,s&&(a=i[0]&2?s["return"]:i[0]?s["throw"]||((a=s["return"])&&a.call(s),0):s.next)&&!(a=a.call(s,i[1])).done)return a;if(s=0,a)i=[i[0]&2,a.value];switch(i[0]){case 0:case 1:a=i;break;case 4:t.label++;return{value:i[1],done:false};case 5:t.label++;s=i[1];i=[0];continue;case 7:i=t.ops.pop();t.trys.pop();continue;default:if(!(a=t.trys,a=a.length>0&&a[a.length-1])&&(i[0]===6||i[0]===2)){t=0;continue}if(i[0]===3&&(!a||i[1]>a[0]&&i[1]<a[3])){t.label=i[1];break}if(i[0]===6&&t.label<a[1]){t.label=a[1];a=i;break}if(a&&t.label<a[2]){t.label=a[2];t.ops.push(i);break}if(a[2])t.ops.pop();t.trys.pop();continue}i=e.call(o,t)}catch(o){i=[6,o];s=0}finally{n=a=0}if(i[0]&5)throw i[1];return{value:i[0]?i[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(o,e,t){if(t||arguments.length===2)for(var n=0,s=e.length,a;n<s;n++){if(a||!(n in e)){if(!a)a=Array.prototype.slice.call(e,0,n);a[n]=e[n]}}return o.concat(a||Array.prototype.slice.call(e))};System.register(["./p-CIevpRv_.system.js","./p-CYdt69j5.system.js","./p-DPW1yXt9.system.js","./p-B2EZRfoq.system.js","./p-DIJaXkiE.system.js","./p-CPnR_T0a.system.js","./p-zVLAvre1.system.js","./p-DBOI98r5.system.js","./p-BSgVcCxT.system.js","./p-BbgqQIHv.system.js","./p-_GDmY2H7.system.js","./p-C2j7R11h.system.js","./p-DGsEWFDU.system.js","./p-CQqNJo0D.system.js","./p-D-DawUYF.system.js","./p-CeLaK0Ff.system.js","./p-DW-fW8yR.system.js","./p-Cby4EkFu.system.js","./p-B3GRrRtL.system.js","./p-uV7m6KrY.system.js"],(function(o){"use strict";var e,t,n,s,a,l,i,r,c,d,u,f,h,p,m,b,y,z,g,v,x,w,k,C,_,I,L,S,j,H,P,D,Z,M,B,F,V,O,T,U,W,R,E,A,N,Y,q;return{setters:[function(o){e=o.r;t=o.d;n=o.h;s=o.F;a=o.a;l=o.g},function(o){i=o.b;r=o.d;c=o.j;d=o.e;u=o.k;f=o.c},function(o){h=o.b;p=o.c;m=o.t;b=o.P;y=o.H;z=o.Q;g=o.d;v=o.x;x=o.I},function(o){w=o.s;k=o.c;C=o.a;_=o.b},function(o){I=o.t;L=o.s;S=o.j;j=o.l;H=o.x},function(o){P=o.z},function(o){D=o.h;Z=o.s;M=o.g;B=o.i;F=o.a},function(o){V=o.c},function(o){O=o.g},function(o){T=o.l;U=o.b},function(o){W=o.i;R=o.a},function(o){E=o.c},function(o){A=o.s},function(o){N=o.r},function(o){Y=o.p},function(o){q=o.r},null,null,null,null],execute:function(){var G='<svg color="var(--zonos-elements-red-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" data-is-secondary-color="true" fill="var(--zonos-elements-red-200)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var Q='<svg color="var(--zonos-elements-blue-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Z" data-is-secondary-color="true" fill="var(--zonos-elements-blue-100)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M15.707 9.293a1 1 0 0 1 0 1.414l-3.646 3.647a1.5 1.5 0 0 1-2.122 0l-1.646-1.647a1 1 0 1 1 1.414-1.414L11 12.586l3.293-3.293a1 1 0 0 1 1.414 0Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var X=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100%}:host .zonos--group{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;margin-bottom:24px;border-radius:var(--zonos--border-radius, 10px);gap:24px;margin-top:24px;background-color:var(--zonos-elements-gray-50);padding:48px}:host .zonos--finish-details{max-width:640px;min-width:300px;line-height:24px;width:0 auto;margin:auto}:host zonos-button{width:100%}:host .loading-wrapper{min-height:300px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host .zonos--finish-button-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;gap:16px;margin:0 auto;margin-top:48px;max-width:300px}:host .zonos--button-container{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;gap:16px;margin:0 auto}:host .zonos--subtitle{text-align:center}:host .zonos--order-number{background-color:var(--zonos-elements-gray-0);border:1px solid var(--zonos-elements-gray-200);color:var(--zonos-elements-gray-800);border-radius:var(--zonos-elements-radius-6);padding:4px 8px}"};
2
+ /**
3
+ * Maximum number of retries to pull order info (gap between each retry is 1 second)
4
+ */var K=30;var J=o("zonos_collect_finish",/** @class */function(){function o(o){var n=this;e(this,o);this.closeClick=t(this,"closeClick",7);
5
+ /**
6
+ * The border radius style of the dialog
7
+ */this.borderRadius="ROUNDED";
8
+ /**
9
+ * The confirmation id for the collect order
10
+ */this.confirmationId=null;this.isLoading=true;this.notificationType="success";this.notificationTitle="";this.notificationMessages=[];this.notificationActionText=I("Keep shopping");this.order=null;
11
+ /**
12
+ * Is waiting to redirect to a different page
13
+ */this.isWaitingToRedirect=true;this.pullOrder=function(){return __awaiter(n,void 0,void 0,(function(){var o,e,t,n,s,a,l,i;return __generator(this,(function(r){switch(r.label){case 0:t=L.checkoutSessionId;n=new URLSearchParams;n.set("checkoutSessionId",t||"");return[4/*yield*/,D("/api/zonos-elements/get-order?".concat(n.toString()))];case 1:s=r.sent(),a=s.baseUrl,l=s.errors,i=s.json;if(l.length||!(i===null||i===void 0?void 0:i.id)){return[2/*return*/,{baseUrl:a,order:null}]}
14
+ // onOrderSuccess callback may be provided on Zonos.init
15
+ return[4/*yield*/,(e=(o=P.checkoutSettings).onOrderSuccess)===null||e===void 0?void 0:e.call(o,{zonosApiRoute:a,zonosOrder:i})];case 2:
16
+ // onOrderSuccess callback may be provided on Zonos.init
17
+ r.sent();return[2/*return*/,{baseUrl:a,order:i}]}}))}))};this.handleSuccessBehavior=function(){return __awaiter(n,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:
18
+ // Do nothing, display Zonos success page
19
+ this.isLoading=false;return[4/*yield*/,this.getPullOrder()];case 1:o.sent();return[2/*return*/]}}))}))};
20
+ // TODO: This method of pulling orders is temporary. Once we have a working event registry system, we will rely on that to tell us when the order is ready to trigger onOrderSuccess
21
+ this.getPullOrder=function(){var o=[];for(var e=0;e<arguments.length;e++){o[e]=arguments[e]}return __awaiter(n,__spreadArray([],o,true),void 0,(function(o){var e,t,n,s,a,l,i,r;if(o===void 0){o=0}return __generator(this,(function(c){switch(c.label){case 0:if(o===0){T("=== Start to poll for order info","info")}return[4/*yield*/,this.pullOrder()];case 1:n=c.sent(),s=n.baseUrl,a=n.order;l=!!((t=(e=a===null||a===void 0?void 0:a.references)===null||e===void 0?void 0:e.find((function(o){return(o===null||o===void 0?void 0:o.key)==="zonosOrderNumber"})))===null||t===void 0?void 0:t.value);i=L.checkoutSessionId;r=parseFloat(new URLSearchParams(window.location.search).get("maxPollingRetries")||"0")||K;T("=== Polling order (".concat(o," attemps)"),"info");if(!
22
+ // Order found, in legacy checkout facade and still haven't found the legacy order number
23
+ a)
24
+ // Order found, in legacy checkout facade and still haven't found the legacy order number
25
+ return[3/*break*/,2];T("=== CollectOrder info found","info");if(o>10){
26
+ // Log out all the logs if we have tried more than 10 times
27
+ void Z({endpoint:"".concat(s,"/api/zonos-elements/get-order?checkoutSessionId=").concat(i,"&orderId=").concat(a.id),errors:["Collect order found after ".concat(o," attempts")],metadata:{allLogs:U,checkoutSessionId:L.checkoutSessionId||"",orderId:a.id,storeId:P.storeId}})}this.order=a;return[3/*break*/,6];case 2:if(!((!a||!l)&&o<r))return[3/*break*/,5];
28
+ // Wait for 1 second before the next attempt
29
+ return[4/*yield*/,new Promise((function(o){return setTimeout(o,1e3)}))];case 3:
30
+ // Wait for 1 second before the next attempt
31
+ c.sent();return[4/*yield*/,this.getPullOrder(o+1)];case 4:c.sent();return[3/*break*/,6];case 5:void Z({endpoint:"".concat(s,"/api/zonos-elements/get-order?checkoutSessionId=").concat(i),errors:["Collect order not found after ".concat(r," attempts")],metadata:{allLogs:U,checkoutSessionId:L.checkoutSessionId||"",storeId:P.storeId}});c.label=6;case 6:return[2/*return*/]}}))}))};this.checkStripePaymentStatus=function(){return __awaiter(n,void 0,void 0,(function(){var o,e,t,n,s,a,l,i,r;return __generator(this,(function(c){switch(c.label){case 0:o=new URLSearchParams(window.location.search).get("payment_intent_client_secret")||h.clientSecret;if(!(o||this.storybookForceStatus))return[3/*break*/,4];return[4/*yield*/,p({clientSecret:o,storybookForceStatus:this.storybookForceStatus})];case 1:e=c.sent(),t=e.error,n=e.messages,s=e.status;a=s==="requires_action"||t;this.notificationType=a?"error":"success";this.notificationMessages=n||[];this.notificationTitle=a?I("Payment failed"):I("You're all set!");T("=== Payment intent retrieve status","info",{clientSecret:o,error:t,messages:n,status:s});l=new URL(window.location.href);l.searchParams.delete("payment_intent_client_secret");l.searchParams.delete("payment_intent");l.searchParams.delete("redirect_status");
32
+ // Clean up the url if it's a redirect behavior
33
+ l.searchParams.delete("zonosCheckoutSessionId");window.history.replaceState({},"",l.toString());if(!(t&&(n===null||n===void 0?void 0:n.length)))return[3/*break*/,2];w({event:"zonos-checkout-payment-fail"});void Z({endpoint:"Stripe payment failed",errors:['Payment intent "'.concat(o.split("_secret_")[0]||o,'" status: ').concat(s," - checkout session: ").concat(L.checkoutSessionId)],metadata:{allLogs:U,credentialToken:window.Zonos.zonosApiKey}});return[3/*break*/,4];case 2:w({event:"zonos-checkout-success"});i=L.checkoutSessionId;void m({checkoutSessionId:i,eventName:"checkout_orderCompleted"});r=V("zonos-checkout-success",{message:"Zonos Checkout successfully processed order"});document.dispatchEvent(r);
34
+ // wait this to finish before resetting store and checkout session id
35
+ return[4/*yield*/,this.handleSuccessBehavior()];case 3:
36
+ // wait this to finish before resetting store and checkout session id
37
+ c.sent();c.label=4;case 4:
38
+ // Make sure to stop the loading spinner even when there's an error
39
+ this.isLoading=false;
40
+ // reset promo when checkout is finished
41
+ b();y();L.checkoutSessionId=null;return[2/*return*/]}}))}))};
42
+ /**
43
+ * Resolve the Airwallex payment intent id, preferring the value already in the
44
+ * store and falling back to re-fetching the collect checkout session (e.g. when
45
+ * the page was reloaded after a redirect).
46
+ */this.getAirwallexSessionInfo=function(){return __awaiter(n,void 0,void 0,(function(){var o,e,t;return __generator(this,(function(n){switch(n.label){case 0:
47
+ // When the payment intent id is already in the store (e.g. the drop-in just
48
+ // succeeded this session), there's no completed session to re-fetch.
49
+ if(i.paymentIntentId){return[2/*return*/,{isCompleted:false,paymentIntentId:i.paymentIntentId}]}o=L.checkoutSessionId;if(!o){return[2/*return*/,{isCompleted:false,paymentIntentId:null}]}return[4/*yield*/,D("/api/zonos-elements/collect/get-checkout-session",{body:{checkoutSessionId:o},method:"POST"})];case 1:e=n.sent().json;t=e===null||e===void 0?void 0:e.checkoutSession;return[2/*return*/,{
50
+ // A completed session (or one with an order attached) is already paid.
51
+ isCompleted:!!((t===null||t===void 0?void 0:t.completedAt)||(t===null||t===void 0?void 0:t.order)),paymentIntentId:(t===null||t===void 0?void 0:t.paymentIntentId)||null}]}}))}))};this.checkAirwallexPaymentStatus=function(){return __awaiter(n,void 0,void 0,(function(){var o,e,t,n,s,a,l,f,h,p,z;return __generator(this,(function(g){switch(g.label){case 0:o=i.paymentConfirmed;e=this.storybookForceStatus==="succeeded";return[4/*yield*/,this.getAirwallexSessionInfo()];case 1:t=g.sent(),n=t.isCompleted,s=t.paymentIntentId;if(!s)return[3/*break*/,3];return[4/*yield*/,r(s)];case 2:l=g.sent();return[3/*break*/,4];case 3:l={status:null};g.label=4;case 4:a=l.status;f=o||e||n||d(a);h=(o||e||n?c("SUCCEEDED"):c(a)).messages;T("=== Airwallex payment intent retrieve status","info",{forcedSuccess:e,isCompleted:n,isPaid:f,paymentIntentId:s,sdkConfirmed:o,status:a});this.notificationType=f?"success":"error";this.notificationTitle=f?I("You're all set!"):I("Payment failed");this.notificationMessages=h;if(!f)return[3/*break*/,6];w({event:"zonos-checkout-success"});p=L.checkoutSessionId;void m({checkoutSessionId:p,eventName:"checkout_orderCompleted"});z=V("zonos-checkout-success",{message:"Zonos Checkout successfully processed order"});document.dispatchEvent(z);
52
+ // wait this to finish before resetting store and checkout session id
53
+ return[4/*yield*/,this.handleSuccessBehavior()];case 5:
54
+ // wait this to finish before resetting store and checkout session id
55
+ g.sent();return[3/*break*/,7];case 6:w({event:"zonos-checkout-payment-fail"});void Z({endpoint:"Airwallex payment failed",errors:['Payment intent "'.concat(s,'" status: ').concat(a," - checkout session: ").concat(L.checkoutSessionId)],metadata:{allLogs:U,credentialToken:window.Zonos.zonosApiKey}});g.label=7;case 7:
56
+ // Make sure to stop the loading spinner even when there's an error
57
+ this.isLoading=false;
58
+ // reset promo when checkout is finished
59
+ b();y();u();L.checkoutSessionId=null;return[2/*return*/]}}))}))};this.checkStagingOrderStatus=function(){return __awaiter(n,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:this.notificationType="success";this.notificationTitle=I("You're all set!");this.notificationMessages=z("succeeded").messages;return[4/*yield*/,this.handleSuccessBehavior()];case 1:o.sent();
60
+ // reset promo when checkout is finished
61
+ b();y();k();L.checkoutSessionId=null;return[2/*return*/]}}))}))};this.checkPaypalPaymentStatus=function(){return __awaiter(n,void 0,void 0,(function(){var o;return __generator(this,(function(e){switch(e.label){case 0:
62
+ // render error message if there's an error
63
+ if(C.paypalErrorMessage){this.notificationType="error";this.notificationTitle=I("Payment failed");this.notificationMessages=[C.paypalErrorMessage];this.isLoading=false;return[2/*return*/]}
64
+ // show success message right away when order id is already created
65
+ this.isLoading=false;if(!C.orderIdCreated)return[3/*break*/,2];w({event:"zonos-checkout-success"});o=L.checkoutSessionId;void m({checkoutSessionId:o,eventName:"checkout_orderCompleted"});this.notificationType="success";this.notificationTitle=I("You're all set!");this.notificationMessages=z("succeeded").messages;
66
+ // wait this to finish before resetting store and checkout session id
67
+ return[4/*yield*/,this.handleSuccessBehavior()];case 1:
68
+ // wait this to finish before resetting store and checkout session id
69
+ e.sent();e.label=2;case 2:
70
+ // reset promo when checkout is finished
71
+ b();y();k();L.checkoutSessionId=null;return[2/*return*/]}}))}))};this.getReceiptUrl=function(o){var e=o.cartId;var t=new URL("".concat(window.location.origin,"/receipt"));t.searchParams.set("referenceId",e);
72
+ // is test mode
73
+ var n=M();if(n){t.searchParams.set("zonosTestMode","1")}
74
+ // Carry over the zonosQaUrl if it exists
75
+ var s=new URLSearchParams(window.location.search).get("zonosQaUrl");if(s){t.searchParams.set("zonosQaUrl",s)}return t.toString()}}o.prototype.componentDidLoad=function(){if(this.overrideNotification){
76
+ // just show the notification and don't check any of the payment status
77
+ this.notificationType=this.overrideNotification.type;this.notificationTitle=this.overrideNotification.title;this.notificationMessages=this.overrideNotification.messages;this.isLoading=false;return}if(g.isStagingMode){void this.checkStagingOrderStatus()}else if(f.paymentProcessor==="AIRWALLEX"){void this.checkAirwallexPaymentStatus()}else if(C.orderIdCreated){void this.checkPaypalPaymentStatus()}else{void this.checkStripePaymentStatus()}};o.prototype.render=function(){var o=this;var e=window.Zonos.cartId;return n(a,{key:"af26499a2062cf495d4c46a7763ed988a4da0669",class:"zonos--checkout-finish zonos--elements",style:{"--zonos--border-radius":O({overrideBorderStyle:this.borderRadius})}},!this.isLoading&&n("div",{key:"54fb28be3daee7dd1d63f1dcbdb9a84354fcdb6c",class:"zonos--finish-details"},n("div",{key:"9c71e5dbd23e613e1038924f14c0465d94dbad07",class:"zonos--group"},this.notificationType==="success"?n("zonos-icon",{"aria-label":"Order success",content:Q,iconColor:"blue-800",size:50}):n("zonos-icon",{"aria-label":"Order failed",content:G,iconColor:"red-800",size:50}),n("zonos-text",{key:"3285f4bb8854d5bab6eef487d2b2ae3556794998",class:"zonos--title",type:"semiBoldSubheader"},this.notificationTitle),this.confirmationId&&n("zonos-badge",{key:"4cecd6f15ed26fe1e525c01a48e3961845e6f6d8",badgeColor:"gray"},this.confirmationId),n("zonos-text",{key:"dd7c4011d4d7f92fcd19d53e945adf42f2b3f05e",class:"zonos--subtitle",textColor:"gray-600"},this.notificationMessages.map((function(o){return n(s,null,o,n("br",null))}))),this.order&&e&&n("div",{key:"a11bd49a754d32dd15dc34f2311f9706d459f07b",class:"zonos--button-container"},n("zonos-button",{key:"305bcf958a1772cc123414285522e9e0f0b1a839",onClick:function(){window.open(o.getReceiptUrl({cartId:e}),"_blank")},size:"lg",variant:"primary"},I("View receipt"))))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());J.style=X();var $='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var oo='<svg width="24" height="24" viewBox="0 0 24 24" fill="none" color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg">\n<path fill-rule="evenodd" clip-rule="evenodd" d="M20 12C20 16.4183 16.4183 20 12 20C7.58172 20 4 16.4183 4 12C4 7.58172 7.58172 4 12 4C16.4183 4 20 7.58172 20 12ZM11.4709 5.80634C11.7686 5.53723 11.9541 5.5 12 5.5C12.0459 5.5 12.2314 5.53723 12.5291 5.80634C12.8115 6.06164 13.1289 6.46913 13.4271 7.03651C13.9505 8.03191 14.3838 9.46098 14.48 11.25H9.51996C9.61624 9.46098 10.0495 8.03191 10.5729 7.03651C10.8711 6.46913 11.1885 6.06164 11.4709 5.80634ZM8.01802 11.25C8.11591 9.23031 8.60319 7.55958 9.24516 6.33849C9.29983 6.23451 9.35585 6.13335 9.41312 6.03514C7.32916 6.94017 5.81218 8.90533 5.5428 11.25H8.01802ZM5.5428 12.75H8.01802C8.11591 14.7697 8.60319 16.4404 9.24516 17.6615C9.29983 17.7655 9.35585 17.8666 9.41312 17.9649C7.32916 17.0598 5.81218 15.0947 5.5428 12.75ZM9.51996 12.75H14.48C14.3838 14.539 13.9505 15.9681 13.4271 16.9635C13.1289 17.5309 12.8115 17.9384 12.5291 18.1937C12.2314 18.4628 12.0459 18.5 12 18.5C11.9541 18.5 11.7686 18.4628 11.4709 18.1937C11.1885 17.9384 10.8711 17.5309 10.5729 16.9635C10.0495 15.9681 9.61624 14.539 9.51996 12.75ZM15.982 12.75C15.8841 14.7697 15.3968 16.4404 14.7548 17.6615C14.7002 17.7655 14.6441 17.8666 14.5869 17.9649C16.6708 17.0598 18.1878 15.0947 18.4572 12.75H15.982ZM18.4572 11.25C18.1878 8.90533 16.6708 6.94017 14.5869 6.03514C14.6441 6.13335 14.7002 6.23451 14.7548 6.33849C15.3968 7.55958 15.8841 9.23031 15.982 11.25H18.4572Z" fill="currentColor"/>\n</svg>\n';var eo='<svg width="43" height="10" viewBox="0 0 43 10" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M7.35896 0.0640869H0.30768C0.166068 0.0640869 0.0512695 0.178886 0.0512695 0.320497V1.85896C0.0512695 2.00057 0.166068 2.11537 0.30768 2.11537H4.44439C4.54964 2.11537 4.61005 2.2352 4.54745 2.31982L0.151823 8.2615C0.0865163 8.34978 0.0512695 8.45669 0.0512695 8.56649V9.67947C0.0512695 9.82108 0.166068 9.93588 0.30768 9.93588H7.35896C7.50057 9.93588 7.61537 9.82108 7.61537 9.67947V8.14101C7.61537 7.9994 7.50057 7.8846 7.35896 7.8846H3.22226C3.117 7.8846 3.05659 7.76477 3.11919 7.68015L7.51482 1.73847C7.58013 1.65019 7.61537 1.54328 7.61537 1.43348V0.320497C7.61537 0.178886 7.50057 0.0640869 7.35896 0.0640869Z" fill="var(--zonos-elements-gray-800)"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M11.718 0C10.1602 0 8.89746 1.26279 8.89746 2.82051V7.17949C8.89746 8.73721 10.1602 10 11.718 10H13.6411C15.1988 10 16.4616 8.73721 16.4616 7.17949V2.82051C16.4616 1.26279 15.1988 0 13.6411 0H11.718ZM11.718 2.05128C11.2931 2.05128 10.9487 2.39568 10.9487 2.82051V7.17949C10.9487 7.60432 11.2931 7.94872 11.718 7.94872H13.6411C14.0659 7.94872 14.4103 7.60432 14.4103 7.17949V5V2.82051C14.4103 2.39568 14.0659 2.05128 13.6411 2.05128H11.718Z" fill="var(--zonos-elements-gray-800)"/>\n<path d="M17.7437 0.436316V9.71132C17.7437 9.85293 17.8585 9.96773 18.0001 9.96773H19.5385C19.6801 9.96773 19.7949 9.85293 19.7949 9.71132V3.74801C19.7949 3.44829 19.969 3.17587 20.241 3.04996L22.1641 2.15964C22.6739 1.92363 23.2565 2.29592 23.2565 2.85769V9.71132C23.2565 9.85293 23.3713 9.96773 23.5129 9.96773H25.0513C25.193 9.96773 25.3078 9.85293 25.3078 9.71132V2.85595C25.3078 0.79631 23.1718 -0.568775 21.3027 0.296257L19.9742 0.911055C19.8685 0.959946 19.7432 0.931536 19.669 0.84187L19.2748 0.365697C19.1773 0.248019 19.0325 0.179905 18.8797 0.179905H18.0001C17.8585 0.179905 17.7437 0.294704 17.7437 0.436316Z" fill="var(--zonos-elements-gray-800)"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M29.4104 0C27.8526 0 26.5898 1.26279 26.5898 2.82051V7.17949C26.5898 8.73721 27.8526 10 29.4104 10H31.3334C32.8912 10 34.1539 8.73721 34.1539 7.17949V2.82051C34.1539 1.26279 32.8912 0 31.3334 0H29.4104ZM29.4104 2.05128C28.9855 2.05128 28.6411 2.39568 28.6411 2.82051V7.17949C28.6411 7.60432 28.9855 7.94872 29.4104 7.94872H31.3334C31.7583 7.94872 32.1027 7.60432 32.1027 7.17949V2.82051C32.1027 2.39568 31.7583 2.05128 31.3334 2.05128H29.4104Z" fill="var(--zonos-elements-gray-800)"/>\n<path d="M38.2085 0.0640869H40.3889C41.8309 0.0640869 42.9999 1.23306 42.9999 2.67506C42.9999 2.79477 42.9108 2.89574 42.792 2.91059L41.1732 3.11293C41.054 3.12784 40.9486 3.03485 40.9486 2.91466C40.9486 2.47322 40.5908 2.11537 40.1493 2.11537H38.3397C37.8688 2.11537 37.4871 2.49712 37.4871 2.96803C37.4871 3.3685 37.7658 3.71501 38.1569 3.80087L40.7916 4.37922C42.0811 4.66229 42.9999 5.80462 42.9999 7.12486C42.9999 8.67735 41.7414 9.93588 40.1889 9.93588H38.0468C36.6048 9.93588 35.4358 8.76691 35.4358 7.32491C35.4358 7.2052 35.5249 7.10423 35.6437 7.08938L37.2625 6.88703C37.3817 6.87213 37.4871 6.96512 37.4871 7.08531C37.4871 7.52675 37.8449 7.8846 38.2864 7.8846H40.1176C40.5765 7.8846 40.9486 7.51252 40.9486 7.05354C40.9486 6.67478 40.6925 6.34394 40.3258 6.24901L37.5136 5.52093C36.2902 5.20422 35.4358 4.10042 35.4358 2.83676C35.4358 1.30545 36.6772 0.0640869 38.2085 0.0640869Z" fill="var(--zonos-elements-gray-700)"/>\n</svg>\n';var to=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{position:absolute;bottom:0;left:32px;right:32px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;z-index:2}:host .zonos--collect-footer{gap:16px;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;padding:12px;padding-left:0;-ms-flex-align:center;align-items:center;width:100%}:host .zonos--collect-footer .zonos--collect-footer-icon-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:16px}:host .zonos--collect-footer .zonos--collect-footer-icon-wrapper .zonos--collect-footer-logo{display:-ms-inline-flexbox;display:inline-flex;gap:8px;-ms-flex-align:center;align-items:center}:host .zonos--collect-footer .zonos--collect-footer-icon-wrapper .zonos--collect-footer-logo a{line-height:0}:host .zonos--collect-footer .zonos--collect-footer-icon-wrapper a{text-decoration:none}:host .zonos--collect-footer zonos-button button.outline{outline:1px solid var(--zonos-elements-gray-800)}:host .zonos--collect-footer .zonos--collect-locale-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:8px;position:relative}@media (max-width: 400px){:host .zonos--collect-footer .zonos--collect-locale-wrapper{gap:4px}}:host .zonos--collect-footer .zonos--collect-locale-wrapper .zonos--collect-locale-label{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;gap:4px}:host .zonos--collect-footer .zonos--collect-language-dialog{position:absolute;bottom:36px;left:var(--language-dialog-left);background:var(--zonos-elements-surface-color);-webkit-box-shadow:var(--zonos-elements-v3-shadow-xl);box-shadow:var(--zonos-elements-v3-shadow-xl);border-radius:var(--zonos-elements-radius-12);width:360px;max-width:100vw;max-height:500px;z-index:2147483011;overflow:auto;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:bottom left;transform-origin:bottom left;opacity:0;-webkit-transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;-ms-scroll-chaining:none;overscroll-behavior:contain}:host .zonos--collect-footer .zonos--collect-language-dialog::-webkit-scrollbar{width:10px}:host .zonos--collect-footer .zonos--collect-language-dialog::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}:host .zonos--collect-footer .zonos--collect-language-dialog::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}:host .zonos--collect-footer .zonos--collect-language-dialog::-webkit-scrollbar-thumb:hover{background:#d6d6d6}:host .zonos--collect-footer .zonos--collect-language-dialog::-webkit-scrollbar-track{border-top-right-radius:var(--zonos-elements-radius-12);border-bottom-right-radius:var(--zonos-elements-radius-12)}:host .zonos--collect-footer .zonos--collect-language-dialog.zonos--collect-language-dialog-open{opacity:1;-webkit-transform:scale(1);transform:scale(1)}:host .dot{display:-ms-inline-flexbox;display:inline-flex;background:var(--zonos-elements-gray-400);width:6px;height:6px;border-radius:50%}:host(.mobile),:host(.tablet){background-color:var(--zonos-elements-gray-0);width:100%;position:-webkit-sticky;position:sticky;bottom:0}:host(.tablet) .zonos--collect-footer{width:100%;max-width:800px;-ms-flex-pack:justify;justify-content:space-between;display:-ms-flexbox;display:flex}:host(.mobile) .zonos--collect-locale-wrapper{display:none}:host(.mobile) .zonos--collect-footer{-ms-flex-pack:center;justify-content:center}"};var no=o("zonos_collect_footer",/** @class */function(){function o(o){e(this,o);
78
+ /**
79
+ * Override mobile mode
80
+ */this.mobile=false;
81
+ /**
82
+ * Override tablet mode
83
+ */this.tablet=false;this.showLanguageDialog=false;this.isMobile=false;this.isTablet=false}o.prototype.handleGlobalClick=function(o){if(!this.el.contains(o.target)&&this.showLanguageDialog){this.showLanguageDialog=false}};o.prototype.toggleLanguageDialog=function(){this.showLanguageDialog=!this.showLanguageDialog};o.prototype.handleMobileChange=function(){this.isMobile=W(this.mobile)};o.prototype.handleTabletChange=function(){this.isTablet=R(this.tablet)};o.prototype.componentWillLoad=function(){this.isMobile=W(this.mobile);this.isTablet=R(this.tablet)};o.prototype.render=function(){var o=this;var e;
84
+ // label resolves against every language, not just the offered ones, so the current
85
+ // locale always renders even if the merchant later drops it from the selector
86
+ var t=(e=S.find((function(o){return o.code===j.selectedLocale})))===null||e===void 0?void 0:e.label;
87
+ // reverse color when on desktop. With the coversheet backdrop, the color should be white
88
+ var l="gray-1000";return n(a,{key:"7733eba3e2253cc976484a9da290f66afd6ef93d",class:E(["zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"])},n("div",{key:"2c5a058034844d818010f4002704fa17e6fd9a46",class:"zonos--collect-footer"},n("div",{key:"bffe2afd93ca0531b7eea825a7fd69d68b7aa308",class:"zonos--collect-locale-wrapper"},A()&&n(s,{key:"5469f522ea7b4b3f25fd7c0a63e717c29e34a84c"},n("zonos-button",{key:"1c88778482c2960cf2a5e55beeda3f3c7f21b950",buttonColor:l,class:"zonos--collect-footer-language-button",icon:n("zonos-icon",{"aria-label":"Language select",content:oo,iconColor:l}),onClick:function(){return o.toggleLanguageDialog()},variant:"subtle"},n("span",{key:"451485445df5f34ca64a36dddd5007ce9f229173",class:"zonos--collect-locale-label"},t,n("zonos-icon",{key:"a395943215ca541f3db4d3aa6e111c87930a6d08","aria-hidden":"true",class:"zonos--collect-locale-chevron",content:$,iconColor:l,size:18}))),n("div",{key:"46edba3f7fc8f9316b69626872e0cb478e72cbd4",class:E(["zonos--collect-language-dialog",this.showLanguageDialog&&"zonos--collect-language-dialog-open"])},n("zonos-language-select",{key:"e77a7197a218755149ee6b7f3e07a646bc95e930",handleOnClose:function(){return o.toggleLanguageDialog()}})))),n("div",{key:"b18dcfe4f0806f3abb6b5855321381334e5206a7",class:"zonos--collect-footer-icon-wrapper"},n("div",{key:"5c6c376fe1174cec16e9b6c029172138bc8b180a",class:"zonos--collect-footer-logo"},n("zonos-text",{key:"0899e6990f8f37cf2d604ef15ffd3db0571d5389",textColor:l},"Powered by"),n("a",{key:"853891db2db1a4d1297597a9857772503e5b4d10",href:"https://zonos.com",target:"_blank",title:"Zonos website"},n("zonos-icon",{key:"d8731023822bffdec3cfe821c67387df651de13a",autoHeight:true,content:eo,size:42}))),n("div",{key:"ba5ae7870c1ed277142ceccf1d44276270b967d0",class:"dot"}),n("a",{key:"253dd9112d0626981473d0d0a3309cc577ea5b54",href:"https://zonos.com/docs/legal/zonos-privacy-policy",target:"_blank"},n("zonos-text",{key:"a5117f4e2194a4b5d1a5de1696763ca1e174b004",textColor:l},"Privacy policy")))))};Object.defineProperty(o.prototype,"el",{get:function(){return l(this)},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{mobile:[{handleMobileChange:0}],tablet:[{handleTabletChange:0}]}},enumerable:false,configurable:true});return o}());no.style=to();var so='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var ao='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M17.707 14.707a1 1 0 0 1-1.414 0L12 10.414l-4.293 4.293a1 1 0 0 1-1.414-1.414l4.93-4.93a1.1 1.1 0 0 1 1.555 0l4.93 4.93a1 1 0 0 1 0 1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var lo=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{height:100%}:host *{-ms-scroll-chaining:none;overscroll-behavior:contain}:host *::-webkit-scrollbar{width:10px}:host *::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}:host *::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}:host *::-webkit-scrollbar-thumb:hover{background:#d6d6d6}:host .zonos--wrapper{overflow:auto;background-color:var(--zonos-elements-gray-50);border-radius:16px;height:100%;min-height:56px}:host .zonos--order-details-header{position:-webkit-sticky;position:sticky;top:0;z-index:1;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--zonos-elements-gray-50);border:none;display:-ms-flexbox;display:flex;padding:16px 16px 0 16px;width:100%;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .zonos--order-details-header:focus-visible{outline:none}:host .zonos--order-details-wrapper{position:relative;padding:0 16px 16px 16px}:host .zonos--collect-order-details-content{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:28px}:host .zonos--collect-order-info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:32px}:host .zonos--collect-order-info .zonos--collect-order-details-row{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:16px}:host .zonos--collect-order-info .zonos--collect-order-details-row>*{-ms-flex:1 1 150px;flex:1 1 150px}:host .zonos--collect-order-info .zonos--collect-order-details-column{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8px}:host .zonos--collect-order-info .zonos--collect-order-shipping-info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:0}"};var io=o("zonos_collect_order_details",/** @class */function(){function o(o){e(this,o);this.collapseClicked=t(this,"collapseClicked",7);
89
+ /**
90
+ * Whether or not the component is being rendered with mobile styles
91
+ */this.mobile=true;
92
+ /**
93
+ * The landed cost id that is used to fetch the shipping address
94
+ */this.landedCostId="";this.isMobile=false;this.collapseState=this.collapsed}o.prototype.handleCollapseChangeFromProp=function(o){this.collapseState=o};o.prototype.handleCollapseChange=function(o){this.collapseClicked.emit(o)};o.prototype.handleWindowResize=function(){this.isMobile=B(this.mobile)};o.prototype.componentWillLoad=function(){this.handleWindowResize()};o.prototype.renderShippingAddress=function(){if(f.isFetchingShippingInfo){return n("div",{class:"zonos--collect-order-details-column"},n("zonos-text",{type:"smallHeader"},n("zonos-skeleton",{skeletonWidth:"99px"})),n("div",{class:"zonos--collect-order-shipping-info"},n("zonos-skeleton",{skeletonWidth:"152px"}),n("zonos-h-stack",{spacing:8},n("zonos-skeleton",{skeletonWidth:"75px"}),n("zonos-skeleton",{skeletonWidth:"75px"})),n("zonos-skeleton",{skeletonWidth:"50px"})))}var o=f.shippingAddress;if(!o){return null}return n("div",{class:"zonos--collect-order-details-column"},n("zonos-text",{type:"smallHeader"},I("Shipping address")),n("div",{class:"zonos--collect-order-shipping-info"},[[o.location.line1,o.location.line2].filter(Boolean).join(" "),[o.location.locality,o.location.administrativeAreaCode,o.location.postalCode].filter(Boolean).join(", "),o.location.countryCode].map((function(o){return n("zonos-text",null,o)}))))};o.prototype.render=function(){var o=this;var e=function(){if(o.collapseState){return n("zonos-icon",{"aria-label":"Collapse expanded section",content:so,iconColor:"gray-1200"})}return n("zonos-icon",{"aria-label":"Expand collapsed section",content:ao,iconColor:"gray-1200"})};return n(a,{class:E(["zonos--collect-order-details zonos--elements",this.isMobile&&"mobile"])},n("div",{class:"zonos--wrapper"},n("button",{class:"zonos--order-details-header",onClick:function(){o.collapseState=!o.collapseState},type:"button"},n("zonos-text",{type:"semiBoldLabel"},I("Shipment details")),e()),n("div",{class:"zonos--order-details-wrapper"},n("zonos-collapse",{collapsed:this.collapseState},n("div",{class:"zonos--collect-order-details-content"},n("zonos-collect-cart-items",null),n("div",{class:"zonos--collect-order-info"},n("div",{class:"zonos--collect-order-details-row"},f.amountTotalPaid!==null&&n("div",{class:"zonos--collect-order-details-column"},n("zonos-text",{type:"smallHeader"},I("Total paid")),n("zonos-text",null,N({amount:f.amountTotalPaid||0,isForeign:true}))),f.originCompanyName&&n("div",{class:"zonos--collect-order-details-column"},n("zonos-text",{type:"smallHeader"},I("Ordered from")),n("zonos-text",null,f.originCompanyName||""))),this.renderShippingAddress()))))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{collapsed:[{handleCollapseChangeFromProp:0}],collapseState:[{handleCollapseChange:0}]}},enumerable:false,configurable:true});return o}());io.style=lo();var ro='<svg color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="var(--zonos-elements-gray-1000)" d="M15.342 10.21a.75.75 0 0 0-1.184-.92l-2.978 3.829-1.4-1.4a.75.75 0 1 0-1.06 1.061l1.8 1.8a1 1 0 0 0 1.496-.093l3.326-4.277Z"/><path fill="var(--zonos-elements-gray-1000)" fill-rule="evenodd" d="M12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-6.5 8a6.5 6.5 0 1 1 13 0 6.5 6.5 0 0 1-13 0Z" clip-rule="evenodd"/></svg>';var co='<svg color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="var(--zonos-elements-gray-1000)" d="M14.475 10.586a.75.75 0 1 0-1.06-1.06L12 10.938l-1.414-1.414a.75.75 0 0 0-1.06 1.06L10.938 12l-1.414 1.414a.75.75 0 1 0 1.06 1.06L12 13.062l1.414 1.414a.75.75 0 0 0 1.06-1.06L13.062 12l1.414-1.414Z"/><path fill="var(--zonos-elements-gray-1000)" fill-rule="evenodd" d="M12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-6.5 8a6.5 6.5 0 1 1 13 0 6.5 6.5 0 0 1-13 0Z" clip-rule="evenodd"/></svg>';var uo=function(){return".sc-zonos-collect-payment-h{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-collect-payment-h *.sc-zonos-collect-payment{font-family:var(--zonos--font-family, Inter), Inter}.sc-zonos-collect-payment-h img.sc-zonos-collect-payment{max-width:100%}.sc-zonos-collect-payment-h dl.sc-zonos-collect-payment,.sc-zonos-collect-payment-h dd.sc-zonos-collect-payment,.sc-zonos-collect-payment-h h1.sc-zonos-collect-payment,.sc-zonos-collect-payment-h h2.sc-zonos-collect-payment,.sc-zonos-collect-payment-h h3.sc-zonos-collect-payment,.sc-zonos-collect-payment-h h4.sc-zonos-collect-payment,.sc-zonos-collect-payment-h h5.sc-zonos-collect-payment,.sc-zonos-collect-payment-h h6.sc-zonos-collect-payment,.sc-zonos-collect-payment-h hr.sc-zonos-collect-payment,.sc-zonos-collect-payment-h figure.sc-zonos-collect-payment,.sc-zonos-collect-payment-h p.sc-zonos-collect-payment,.sc-zonos-collect-payment-h pre.sc-zonos-collect-payment{margin:0}.sc-zonos-collect-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-collect-payment-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1}.sc-zonos-collect-payment-h .zonos--title.sc-zonos-collect-payment{margin-bottom:24px}.sc-zonos-collect-payment-h .zonos--group.sc-zonos-collect-payment{margin-bottom:20px;overflow:visible;padding:5px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1}.sc-zonos-collect-payment-h .zonos--payment-error-banner.sc-zonos-collect-payment{margin-bottom:8px}.sc-zonos-collect-payment-h .zonos--error-banner.sc-zonos-collect-payment{margin-bottom:16px}.sc-zonos-collect-payment-h zonos-button.sc-zonos-collect-payment{-webkit-box-shadow:0 0 1px 0 var(--zonos-elements-gray-600);box-shadow:0 0 1px 0 var(--zonos-elements-gray-600)}.sc-zonos-collect-payment-h .zonos--pay-in-base-currency-btn.sc-zonos-collect-payment{-webkit-box-shadow:none;box-shadow:none}.sc-zonos-collect-payment-h .zonos--group-btn.sc-zonos-collect-payment{position:-webkit-sticky;position:sticky;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-direction:column;flex-direction:column;gap:12px;bottom:-4px;padding-top:12px;background:var(--zonos--primary-color, var(--zonos-elements-gray-0))}.sc-zonos-collect-payment-h .zonos--group-btn.sc-zonos-collect-payment zonos-text.sc-zonos-collect-payment{text-align:center}.sc-zonos-collect-payment-h .zonos--group-btn.sc-zonos-collect-payment zonos-button.sc-zonos-collect-payment{width:100%}.sc-zonos-collect-payment-h .zonos--test-cards.sc-zonos-collect-payment{margin-top:auto;padding-top:16px}"};var fo=o("zonos_collect_payment",/** @class */function(){function o(o){var n=this;e(this,o);this.continueClicked=t(this,"continueClicked",7);this.paypalSessionFailed=t(this,"paypalSessionFailed",7);this.paypalSessionDone=t(this,"paypalSessionDone",7);this.airwallexPaymentDone=t(this,"airwallexPaymentDone",7);this.storeUnsubscribeList=[];
95
+ /**
96
+ * Whether or not the continue button is loading
97
+ */this.continueLoading=false;
98
+ /**
99
+ * Show error banner when the form is not complete, and user clicks on `Submit` button
100
+ * @default false
101
+ */this.showErrorBanner=false;
102
+ /**
103
+ * Show payment error banner when the payment is failed
104
+ */this.hasStripePaymentError=false;
105
+ /**
106
+ * Error message when the staging order creation is failed
107
+ */this.stagingOrderCreateErrorMessage="";
108
+ /**
109
+ * Internal state to handle continue loading
110
+ */this.internalContinueLoading=this.continueLoading;this.handleValidate=function(){var o;return!!((o=h.stripePaymentEventData)===null||o===void 0?void 0:o.complete)};
111
+ /**
112
+ * handler for continue button click
113
+ */this.continueClickHandler=function(o){return __awaiter(n,[o],void 0,(function(o){var e,t;var n=this;var s=o.currencyCode;return __generator(this,(function(o){if(!this.handleValidate()){
114
+ // Attempt to get the value of the billing address element to validate the form
115
+ void((e=h.stripeBillingAddressElement)===null||e===void 0?void 0:e.getValue());this.showErrorBanner=true;
116
+ // Attempt to submit the form so the missing input error will be shown in Stripe
117
+ void((t=h.stripeElements)===null||t===void 0?void 0:t.submit());setTimeout((function(){var o;(o=n.ele.querySelector("zonos-banner"))===null||o===void 0?void 0:o.scrollIntoView({behavior:"smooth"})}),10);return[2/*return*/]}h.checkoutSettlementCurrency=s;
118
+ // submit google tag when the form is complete
119
+ w({event:"zonos-checkout-payment-info"});this.continueClicked.emit();return[2/*return*/]}))}))};this.copyCardToClipboard=function(o){return __awaiter(n,void 0,void 0,(function(){var e,t;return __generator(this,(function(n){switch(n.label){case 0:n.trys.push([0,2,,3]);return[4/*yield*/,navigator.clipboard.writeText(o)];case 1:n.sent();return[3/*break*/,3];case 2:e=n.sent();t=document.createElement("textarea");t.style.position="fixed";t.style.left="-1000px";t.style.top="-1000px";t.style.width="1px";t.style.height="1px";t.value=o;t.id="zonos-copy-card-number";document.body.appendChild(t);t.select();
120
+ // Have to use deprecated method execCommand because it's the only way to copy to the clipboard in the iframe
121
+ // eslint-disable-next-line deprecation/deprecation
122
+ document.execCommand("copy");document.body.removeChild(t);return[3/*break*/,3];case 3:window.Zonos.showNotification({message:I("Card number copied to clipboard"),timeout:4e3,type:"success"});return[2/*return*/]}}))}))};this.placeTestOrder=function(){return __awaiter(n,void 0,void 0,(function(){var o;return __generator(this,(function(e){switch(e.label){case 0:this.internalContinueLoading=true;return[4/*yield*/,Y()];case 1:o=e.sent().errors;if(o.length){this.stagingOrderCreateErrorMessage=o[0]||"Failed to create staging order. Please try again.";this.internalContinueLoading=false;return[2/*return*/]}this.internalContinueLoading=false;
123
+ // continue to the next step
124
+ v();return[2/*return*/]}}))}))}}o.prototype.continueLoadingWatcher=function(){this.internalContinueLoading=this.continueLoading};o.prototype.stripePaymentErrorWatcher=function(){var o=this;if(this.hasStripePaymentError){setTimeout((function(){var e;
125
+ // scroll to the top of the page when the payment error is shown
126
+ (e=o.ele.querySelector("zonos-banner"))===null||e===void 0?void 0:e.scrollIntoView({behavior:"smooth"})}),50)}};o.prototype.componentWillLoad=function(){this.storeUnsubscribeList=[x("currency",(function(){
127
+ // start init paypal with the presentment currency when landed cost is fetched
128
+ void _({currency:g.currency})}))];
129
+ // start init paypal with the presentment currency when landed cost is fetched
130
+ void _({currency:g.currency})};o.prototype.disconnectedCallback=function(){this.storeUnsubscribeList.forEach((function(o){return o()}))};o.prototype.render=function(){var o=this;var e;
131
+ // Airwallex (05CHECK-860) renders its own drop-in element which collects the
132
+ // payment details and exposes its own pay button, so it bypasses the Stripe
133
+ // elements/client-secret guards and the Stripe continue buttons below.
134
+ if(f.paymentProcessor==="AIRWALLEX"){return n(a,{class:"zonos--checkout-payment zonos--elements"},n("div",{class:"zonos--group"},n("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},I("Payment method")),n("zonos-airwallex-payment",{onAirwallexPaymentSuccess:function(){return o.airwallexPaymentDone.emit()}})))}this.hasStripePaymentError=h.hasPaymentError;if(!h.stripeElements){return null}if(!h.clientSecret){return null}
135
+ // start validate on typing after error banner is shown, and hide it if the form is complete
136
+ if(this.showErrorBanner){this.showErrorBanner=!this.handleValidate()}var t=M();var l=g.isStagingMode||F();var i=((e=h.stripePaymentEventData)===null||e===void 0?void 0:e.value.type)==="external_paypal";var r=function(){if(l){
137
+ // If in mobile, use the theme from the store since the UI is solely by theme
138
+ var e=P.appearance.theme;return n(s,null,o.stagingOrderCreateErrorMessage&&n("zonos-banner",{class:"zonos--error-banner",intent:"error"},o.stagingOrderCreateErrorMessage),n("zonos-empty-state-payment",{emptyStateText:I("No payment method needed for staging"),theme:e}),n("div",{class:"zonos--group-btn"},n("zonos-button",{backgroundColor:o.submitBtnColor,loading:o.internalContinueLoading,onClick:function(){void o.placeTestOrder()},size:"lg",
139
+ // use primary type when on mobile mode
140
+ variant:o.submitBtnType},I("Place test order"))))}if(h.isFetchingSession||f.isFetchingShippingInfo){return null}return n(s,null,o.showErrorBanner&&n("zonos-banner",{class:"zonos--error-banner",intent:"error"},I("Missing required fields. Make sure all fields are completed.")),o.hasStripePaymentError&&n("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},h.customErrorMessage||I("We couldn't complete your payment. Please verify the payment details and try again.")),C.paypalErrorMessage&&n("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},C.paypalErrorMessage),n("zonos-payment",null),n("div",{class:"zonos--group-btn"},!i&&n(s,null,n("zonos-button",{backgroundColor:o.submitBtnColor,bold:true,isDisabled:o.continueLoading&&h.checkoutSettlementCurrency==="USD",loading:o.continueLoading&&h.checkoutSettlementCurrency!=="USD",onClick:function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:if(!g.checkoutSession){T("Checkout session is not found");return[2/*return*/]}return[4/*yield*/,this.continueClickHandler({currencyCode:g.checkoutSession.subtotals.presentmentCurrencyCode})];case 1:o.sent();return[2/*return*/]}}))}))},size:"lg",
141
+ // use primary type when on mobile mode
142
+ variant:o.submitBtnType},I("Pay [orderTotal]",{orderTotal:N({amount:f.amountDutyTaxFeeTotal||0,isForeign:true})})),h.shouldRenderPayInUsdButton&&n("zonos-button",{class:"zonos--pay-in-base-currency-btn",isDisabled:o.continueLoading&&h.checkoutSettlementCurrency!=="USD",loading:o.continueLoading&&h.checkoutSettlementCurrency==="USD",onClick:function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:return[4/*yield*/,this.continueClickHandler({currencyCode:"USD"})];case 1:o.sent();return[2/*return*/]}}))}))},size:"lg",variant:"subtle"},I("Click to pay in USD"))),n("zonos-paypal-payment",{onPaypalSessionDone:function(e){var t=e.detail.orderId;o.paypalSessionDone.emit(t)},onPaypalSessionFail:function(){return o.paypalSessionFailed.emit()},style:{display:i?"block":"none"}})),t&&n("zonos-card",{backgroundColor:"gray-100",borderRadius:12,class:"zonos--test-cards"},n("zonos-v-stack",{spacing:16},n("div",null,n("zonos-text",{type:"semiBoldLabel"},I("Test cards")),n("zonos-text",{textColor:"gray-700"},I("Click to copy the card number. Use any future expiration date and three number CVC."))),n("zonos-button",{icon:n("zonos-icon",{content:ro}),justifyContent:"flex-start",onClick:function(){return o.copyCardToClipboard("4242424242424242")}},I("Success")," (****4242)"),n("zonos-button",{icon:n("zonos-icon",{content:co}),justifyContent:"flex-start",onClick:function(){return o.copyCardToClipboard("4000000000000002")}},I("Failure")," (****0002)")),n("zonos-notification",null)))};return n(a,{class:"zonos--checkout-payment zonos--elements"},n("div",{class:"zonos--group"},n("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},I("Payment method")),r()))};Object.defineProperty(o.prototype,"ele",{get:function(){return l(this)},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{continueLoading:[{continueLoadingWatcher:0}],hasStripePaymentError:[{stripePaymentErrorWatcher:0}]}},enumerable:false,configurable:true});return o}());fo.style=uo();var ho=function(){return':host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{position:-webkit-sticky;position:sticky;top:0;background-color:var(--zonos-elements-gray-0);z-index:1}:host .zonos--total-pay{margin:8px 0 24px;display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;gap:48px}:host .zonos--total-pay zonos-text{-ms-flex-negative:0;flex-shrink:0}:host .zonos--total-pay::after{content:"";position:relative;height:1px;width:100%;background:var(--zonos-elements-gray-200)}:host(.mobile),:host(.tablet){display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8px;padding:4px 0;background-color:transparent;position:relative}:host(.mobile) .zonos--total-pay,:host(.tablet) .zonos--total-pay{margin:0}'};var po=o("zonos_collect_review",/** @class */function(){function o(o){e(this,o);
143
+ /**
144
+ * Whether or not the component is being rendered with mobile styles
145
+ */this.mobile=false;
146
+ /**
147
+ * Whether or not the component is being rendered with tablet styles
148
+ */this.tablet=false;
149
+ /**
150
+ * Whether or not to show the collapse icon
151
+ * This is controled from the collapsed state of the zonos-collapse component
152
+ * to show the collapse icon
153
+ */this.collapsed=false;this.isMobile=false;this.isTablet=false;this.isLoading=true}o.prototype.handleWindowResize=function(){this.isMobile=W(this.mobile);this.isTablet=R(this.tablet)};o.prototype.componentWillLoad=function(){var o=this;this.handleWindowResize();
154
+ // Wait for the data to load
155
+ setTimeout((function(){o.isLoading=false}),1e3)};o.prototype.render=function(){var o=this.isMobile?"gray-1000":"gray-800";return n(a,{key:"2ed81c7a0a16b9414fe1ce3799efa3b85679f982",class:E(["zonos--collect-review zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"])},n("div",{key:"fcf9fbc8dd807289bcd1c70406495b0c3396bfb8",class:"zonos--title"},n("zonos-text",{key:"44cfb3b82b8e617687c212e108cacafb45713243",textColor:o,type:"semiBoldLabel"},I("Pay [organizationName] duties, taxes and fees for your shipment",{organizationName:P.organizationName}))),n("div",{key:"5472a1ccc61b49ce8c9578a4c3f801386cab1e7d",class:"zonos--total-pay"},q({content:n("zonos-text",{type:"secondaryPageHeader"},N({amount:f.amountDutyTaxFeeTotal||0,isForeign:true})),isLoading:f.isFetchingShippingInfo,skeletonHeight:"36px",skeletonWidth:"150px"})))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());po.style=ho();var mo=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{position:-webkit-sticky;position:sticky;bottom:60px}:host .zonos--collect-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--zonos-elements-font-size-base)}:host .zonos--collect-table .zonos--column{padding:8px 8px;vertical-align:top}:host .zonos--collect-table .zonos--column:last-child{text-align:right;padding-right:0}:host .zonos--collect-table .zonos--column:first-child{width:60px;max-width:100px}:host .zonos--title-with-icon{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:8px}:host .zonos--collect-subtotal-price{text-align:right}:host .zonos--collect-subtotal-price zonos-text{white-space:nowrap}:host .zonos--collect-total .zonos--column{padding:16px 0}:host .zonos--collect-total-subtotal .zonos--collect-subtotal-title,:host .zonos--collect-total-subtotal .zonos--collect-subtotal-price{border-bottom:1px solid var(--zonos-elements-gray-200)}:host .zonos--collect-subtotal-price zonos-text,:host .zonos--collect-pay-total zonos-text{white-space:nowrap}"};var bo=o("zonos_collect_subtotal",/** @class */function(){function o(o){var t=this;e(this,o);this.storeUnsubscribeList=[];this.subtotals={};this.initSubtotalData=function(){var o;var e;var n=(e=g.checkoutSession)===null||e===void 0?void 0:e.subtotals;if(!n){return}
156
+ // Some countries have same name for duties, taxes and fees in their language. If that happens, we need to group their values by name
157
+ var s=I("Duties");var a=I("Taxes");var l=I("Fees");var i=(o={},o[s]=0,o[l]=0,o[a]=0,o);var r=n.duties;var c=n.taxes;var d=n.fees;if(r!==undefined){i[s]||(i[s]=0);i[s]+=r}if(c!==undefined){i[a]||(i[a]=0);i[a]+=c}if(d!==undefined){i[l]||(i[l]=0);i[l]+=d}t.subtotals=i}}o.prototype.disconnectedCallback=function(){this.storeUnsubscribeList.forEach((function(o){return o()}))};o.prototype.componentWillLoad=function(){this.storeUnsubscribeList=[x("checkoutSession",this.initSubtotalData),H("translatedChunks",this.initSubtotalData)]};o.prototype.render=function(){this.initSubtotalData();return n(a,{key:"f014c2ae733fe652d7d74349c0e12f93f46d71f5",class:"zonos--collect-subtotal zonos--elements"},n("table",{key:"0bab186aa957c29f026151f5a112ff66bb42cb04",class:"zonos--collect-table"},!!this.subtotals[I("Duties")]&&n("tr",{key:"97c24d5f179f5b59bcb91bc156b1d3e15b811262",class:"zonos--row zonos--collect-duty"},n("td",{key:"cba67296a6d17c0cd665981eb19ba95706f68843",class:"zonos--column zonos--collect-subtotal-title"},n("zonos-text",{key:"6665f531a8656c4a1e0f9761d919c150587a36fb",type:"semiBoldLabel"},I("Duties"))),n("td",{key:"20aeeee1fde0e63aaa168f32a5400ea82758a14c",class:"zonos--column"}),n("td",{key:"14994ca56e814f68fa3511098f5299a0942a295a",class:"zonos--column zonos--collect-subtotal-price"},q({content:n("zonos-text",{type:"label"},N({amount:this.subtotals[I("Duties")]||0,isForeign:true})),isLoading:f.isFetchingShippingInfo,skeletonHeight:"14px",skeletonWidth:"150px"}))),!!this.subtotals[I("Taxes")]&&n("tr",{key:"cbbe4ddf13aabca9ff86b21317b067191f4155b8",class:"zonos--row zonos--collect-tax"},n("td",{key:"675a36a92e136f3afd1960616e842e152cba6256",class:"zonos--column zonos--collect-subtotal-title"},n("zonos-text",{key:"8896868f1e7f545d5b92c148a0f9812936ac2a9a",type:"semiBoldLabel"},I("Taxes"))),n("td",{key:"8a4c29f6d2d513fd7da8be7b1ab695794f3a99ab",class:"zonos--column"}),n("td",{key:"c15f7a872e59cce222a674acb55388dd18bfb74a",class:"zonos--column zonos--collect-subtotal-price"},q({content:n("zonos-text",{type:"label"},N({amount:this.subtotals[I("Taxes")]||0,isForeign:true})),isLoading:f.isFetchingShippingInfo,skeletonHeight:"14px",skeletonWidth:"150px"}))),!!this.subtotals[I("Fees")]&&n("tr",{key:"4cf155874e4446b9ecab121cbaceba2328323359",class:"zonos--row zonos--collect-fee"},n("td",{key:"3efcb4779f34f35a2398eb661f4b799b6b4480c7",class:"zonos--column zonos--collect-subtotal-title"},n("zonos-text",{key:"41d30bb15d216663cd507f2c92d6639b5559708c",type:"semiBoldLabel"},I("Fees"))),n("td",{key:"ef8259d337fb047d8979f5008d2d46f3fc76b007",class:"zonos--column"}),n("td",{key:"e0430efffbe23880a776953ba6a05b0cea268df4",class:"zonos--column zonos--collect-subtotal-price"},q({content:n("zonos-text",{type:"label"},N({amount:this.subtotals[I("Fees")]||0,isForeign:true})),isLoading:f.isFetchingShippingInfo,skeletonHeight:"14px",skeletonWidth:"150px"}))),n("tr",{key:"279ddddfc6e9fe88bc1f16aeaeb6464737ec212f",class:"zonos--row zonos--collect-spacing"},n("td",{key:"de88842e26eb39938b573fc2ac89915d9f6708ba",class:"zonos--column",colSpan:3})),n("tr",{key:"48ecfc5852f1cb25b7816503f3279a3cffc1a581",class:"zonos--row zonos--collect-total zonos--collect-total-subtotal"},n("td",{key:"06e65acfd5dd213481f415dc2475d9353e18ee53",class:"zonos--column"}),n("td",{key:"b5ae37799d471defdb983a9167b96aa5e176f78e",class:"zonos--column zonos--collect-subtotal-title"},n("zonos-text",{key:"52afa80c7b0eeda13093c26ce031dab4e4a62ee8",type:"label"},I("Subtotal"))),n("td",{key:"840e0413b9c0d651ba7de6529d7c6581f165c047",class:"zonos--column zonos--collect-subtotal-price"},q({content:n("zonos-text",{type:"label"},N({amount:f.amountDutyTaxFeeTotal||0,isForeign:true})),isLoading:f.isFetchingShippingInfo,skeletonHeight:"14px",skeletonWidth:"150px"}))),n("tr",{key:"62ffc4102084c920e8bde4527415ea93d8ae8292",class:"zonos--row zonos--collect-total"},n("td",{key:"ef199898aa67686f1c36d2d0c73d1695443e81a9",class:"zonos--column"}),n("td",{key:"1bd5949e640823841ac7425a46b519482b975c37",class:"zonos--column zonos--collect-subtotal-title"},n("zonos-text",{key:"96d53a1ffd935ac98cd5560419cc7d5395945da4",type:"semiBoldLabel"},I("Customs fees total"))),n("td",{key:"008f69a34b557f2660426acccafe925f6b554293",class:"zonos--column zonos--collect-subtotal-price"},q({content:n("zonos-text",{type:"semiBoldLabel"},N({amount:f.amountDutyTaxFeeTotal||0,isForeign:true})),isLoading:f.isFetchingShippingInfo,skeletonHeight:"14px",skeletonWidth:"150px"})))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());bo.style=mo()}}}));
@@ -0,0 +1,133 @@
1
+ var __awaiter=this&&this.__awaiter||function(o,e,n,t){function s(o){return o instanceof n?o:new n((function(e){e(o)}))}return new(n||(n=Promise))((function(n,i){function r(o){try{c(t.next(o))}catch(o){i(o)}}function a(o){try{c(t["throw"](o))}catch(o){i(o)}}function c(o){o.done?n(o.value):s(o.value).then(r,a)}c((t=t.apply(o,e||[])).next())}))};var __generator=this&&this.__generator||function(o,e){var n={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},t,s,i,r=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return r.next=a(0),r["throw"]=a(1),r["return"]=a(2),typeof Symbol==="function"&&(r[Symbol.iterator]=function(){return this}),r;function a(o){return function(e){return c([o,e])}}function c(a){if(t)throw new TypeError("Generator is already executing.");while(r&&(r=0,a[0]&&(n=0)),n)try{if(t=1,s&&(i=a[0]&2?s["return"]:a[0]?s["throw"]||((i=s["return"])&&i.call(s),0):s.next)&&!(i=i.call(s,a[1])).done)return i;if(s=0,i)a=[a[0]&2,i.value];switch(a[0]){case 0:case 1:i=a;break;case 4:n.label++;return{value:a[1],done:false};case 5:n.label++;s=a[1];a=[0];continue;case 7:a=n.ops.pop();n.trys.pop();continue;default:if(!(i=n.trys,i=i.length>0&&i[i.length-1])&&(a[0]===6||a[0]===2)){n=0;continue}if(a[0]===3&&(!i||a[1]>i[0]&&a[1]<i[3])){n.label=a[1];break}if(a[0]===6&&n.label<i[1]){n.label=i[1];i=a;break}if(i&&n.label<i[2]){n.label=i[2];n.ops.push(a);break}if(i[2])n.ops.pop();n.trys.pop();continue}a=e.call(o,n)}catch(o){a=[6,o];s=0}finally{t=i=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(o,e,n){if(n||arguments.length===2)for(var t=0,s=e.length,i;t<s;t++){if(i||!(t in e)){if(!i)i=Array.prototype.slice.call(e,0,t);i[t]=e[t]}}return o.concat(i||Array.prototype.slice.call(e))};System.register(["./p-CIevpRv_.system.js","./p-DPW1yXt9.system.js","./p-B2EZRfoq.system.js","./p-DIJaXkiE.system.js","./p-CPnR_T0a.system.js","./p-zVLAvre1.system.js","./p-DBOI98r5.system.js","./p-BSgVcCxT.system.js","./p-BbgqQIHv.system.js","./p-CLDnjFm5.system.js","./p-C2j7R11h.system.js","./p-DGsEWFDU.system.js","./p-D5AtAlJx.system.js","./p-CQqNJo0D.system.js","./p-D-DawUYF.system.js","./p-CeLaK0Ff.system.js","./p-DW-fW8yR.system.js","./p-Cby4EkFu.system.js","./p-B3GRrRtL.system.js","./p-uV7m6KrY.system.js"],(function(o){"use strict";var e,n,t,s,i,r,a,c,l,d,u,h,f,p,m,v,g,y,b,z,x,w,k,C,_,j,I,S,L,M,Z,H,P,D,V,U,B,O,R,F,T;return{setters:[function(o){e=o.r;n=o.d;t=o.h;s=o.F;i=o.a;r=o.g},function(o){a=o.b;c=o.c;l=o.t;d=o.P;u=o.H;h=o.Q;f=o.d;p=o.x;m=o.I},function(o){v=o.s;g=o.c;y=o.a;b=o.b},function(o){z=o.t;x=o.s;w=o.j;k=o.l},function(o){C=o.z},function(o){_=o.h;j=o.s;I=o.g;S=o.i;L=o.a},function(o){M=o.c},function(o){Z=o.g},function(o){H=o.l;P=o.b},function(o){D=o.i;V=o.a},function(o){U=o.c},function(o){B=o.s},function(o){O=o.c},function(o){R=o.r},function(o){F=o.p},function(o){T=o.r},null,null,null,null],execute:function(){var N='<svg color="var(--zonos-elements-red-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" data-is-secondary-color="true" fill="var(--zonos-elements-red-200)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var E='<svg color="var(--zonos-elements-blue-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Z" data-is-secondary-color="true" fill="var(--zonos-elements-blue-100)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M15.707 9.293a1 1 0 0 1 0 1.414l-3.646 3.647a1.5 1.5 0 0 1-2.122 0l-1.646-1.647a1 1 0 1 1 1.414-1.414L11 12.586l3.293-3.293a1 1 0 0 1 1.414 0Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var A=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100%}:host .zonos--group{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;margin-bottom:24px;border-radius:var(--zonos--border-radius, 10px);gap:24px;margin-top:24px;background-color:var(--zonos-elements-gray-50);padding:48px}:host .zonos--finish-details{max-width:640px;min-width:300px;line-height:24px;width:0 auto;margin:auto}:host zonos-button{width:100%}:host .loading-wrapper{min-height:300px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host .zonos--finish-button-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;gap:16px;margin:0 auto;margin-top:48px;max-width:300px}:host .zonos--button-container{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;gap:16px;margin:0 auto}:host .zonos--subtitle{text-align:center}:host .zonos--order-number{background-color:var(--zonos-elements-gray-0);border:1px solid var(--zonos-elements-gray-200);color:var(--zonos-elements-gray-800);border-radius:var(--zonos-elements-radius-6);padding:4px 8px}"};
2
+ /**
3
+ * Maximum number of retries to pull order info (gap between each retry is 1 second)
4
+ */var W=30;var q=o("zonos_invoice_finish",/** @class */function(){function o(o){var t=this;e(this,o);this.closeClick=n(this,"closeClick",7);
5
+ /**
6
+ * The border radius style of the dialog
7
+ */this.borderRadius="ROUNDED";
8
+ /**
9
+ * The confirmation id for the invoice order
10
+ */this.confirmationId=null;this.isLoading=true;this.notificationType="success";this.notificationTitle="";this.notificationMessages=[];this.notificationActionText=z("Keep shopping");this.order=null;
11
+ /**
12
+ * Is waiting to redirect to a different page
13
+ */this.isWaitingToRedirect=true;this.pullOrder=function(){return __awaiter(t,void 0,void 0,(function(){var o,e,n,t,s,i,r,a;return __generator(this,(function(c){switch(c.label){case 0:n=x.checkoutSessionId;t=new URLSearchParams;t.set("checkoutSessionId",n||"");return[4/*yield*/,_("/api/zonos-elements/get-order?".concat(t.toString()))];case 1:s=c.sent(),i=s.baseUrl,r=s.errors,a=s.json;if(r.length||!(a===null||a===void 0?void 0:a.id)){return[2/*return*/,{baseUrl:i,order:null}]}
14
+ // onOrderSuccess callback may be provided on Zonos.init
15
+ return[4/*yield*/,(e=(o=C.checkoutSettings).onOrderSuccess)===null||e===void 0?void 0:e.call(o,{zonosApiRoute:i,zonosOrder:a})];case 2:
16
+ // onOrderSuccess callback may be provided on Zonos.init
17
+ c.sent();return[2/*return*/,{baseUrl:i,order:a}]}}))}))};this.handleSuccessBehavior=function(){return __awaiter(t,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:
18
+ // Do nothing, display Zonos success page
19
+ this.isLoading=false;return[4/*yield*/,this.getPullOrder()];case 1:o.sent();return[2/*return*/]}}))}))};
20
+ // TODO: This method of pulling orders is temporary. Once we have a working event registry system, we will rely on that to tell us when the order is ready to trigger onOrderSuccess
21
+ this.getPullOrder=function(){var o=[];for(var e=0;e<arguments.length;e++){o[e]=arguments[e]}return __awaiter(t,__spreadArray([],o,true),void 0,(function(o){var e,n,t,s,i,r,a,c;if(o===void 0){o=0}return __generator(this,(function(l){switch(l.label){case 0:if(o===0){H("=== Start to poll for order info","info")}return[4/*yield*/,this.pullOrder()];case 1:t=l.sent(),s=t.baseUrl,i=t.order;r=!!((n=(e=i===null||i===void 0?void 0:i.references)===null||e===void 0?void 0:e.find((function(o){return(o===null||o===void 0?void 0:o.key)==="zonosOrderNumber"})))===null||n===void 0?void 0:n.value);a=x.checkoutSessionId;c=parseFloat(new URLSearchParams(window.location.search).get("maxPollingRetries")||"0")||W;H("=== Polling order (".concat(o," attemps)"),"info");if(!
22
+ // Order found, in legacy checkout facade and still haven't found the legacy order number
23
+ i)
24
+ // Order found, in legacy checkout facade and still haven't found the legacy order number
25
+ return[3/*break*/,2];H("=== InvoiceOrder info found","info");if(o>10){
26
+ // Log out all the logs if we have tried more than 10 times
27
+ void j({endpoint:"".concat(s,"/api/zonos-elements/get-order?checkoutSessionId=").concat(a,"&orderId=").concat(i.id),errors:["Invoice order found after ".concat(o," attempts")],metadata:{allLogs:P,checkoutSessionId:x.checkoutSessionId||"",orderId:i.id,storeId:C.storeId}})}this.order=i;return[3/*break*/,6];case 2:if(!((!i||!r)&&o<c))return[3/*break*/,5];
28
+ // Wait for 1 second before the next attempt
29
+ return[4/*yield*/,new Promise((function(o){return setTimeout(o,1e3)}))];case 3:
30
+ // Wait for 1 second before the next attempt
31
+ l.sent();return[4/*yield*/,this.getPullOrder(o+1)];case 4:l.sent();return[3/*break*/,6];case 5:void j({endpoint:"".concat(s,"/api/zonos-elements/get-order?checkoutSessionId=").concat(a),errors:["Invoice order not found after ".concat(c," attempts")],metadata:{allLogs:P,checkoutSessionId:x.checkoutSessionId||"",storeId:C.storeId}});l.label=6;case 6:return[2/*return*/]}}))}))};this.checkStripePaymentStatus=function(){return __awaiter(t,void 0,void 0,(function(){var o,e,n,t,s,i,r,h,f;return __generator(this,(function(p){switch(p.label){case 0:o=new URLSearchParams(window.location.search).get("payment_intent_client_secret")||a.clientSecret;if(!(o||this.storybookForceStatus))return[3/*break*/,4];return[4/*yield*/,c({clientSecret:o,storybookForceStatus:this.storybookForceStatus})];case 1:e=p.sent(),n=e.error,t=e.messages,s=e.status;i=s==="requires_action"||n;this.notificationType=i?"error":"success";this.notificationMessages=t||[];this.notificationTitle=i?z("Payment failed"):z("You're all set!");H("=== Payment intent retrieve status","info",{clientSecret:o,error:n,messages:t,status:s});r=new URL(window.location.href);r.searchParams.delete("payment_intent_client_secret");r.searchParams.delete("payment_intent");r.searchParams.delete("redirect_status");
32
+ // Clean up the url if it's a redirect behavior
33
+ r.searchParams.delete("zonosCheckoutSessionId");window.history.replaceState({},"",r.toString());if(!(n&&(t===null||t===void 0?void 0:t.length)))return[3/*break*/,2];v({event:"zonos-checkout-payment-fail"});void j({endpoint:"Stripe payment failed",errors:['Payment intent "'.concat(o.split("_secret_")[0]||o,'" status: ').concat(s," - checkout session: ").concat(x.checkoutSessionId)],metadata:{allLogs:P,credentialToken:window.Zonos.zonosApiKey}});return[3/*break*/,4];case 2:v({event:"zonos-checkout-success"});h=x.checkoutSessionId;void l({checkoutSessionId:h,eventName:"checkout_orderCompleted"});f=M("zonos-checkout-success",{message:"Zonos Checkout successfully processed order"});document.dispatchEvent(f);
34
+ // wait this to finish before resetting store and checkout session id
35
+ return[4/*yield*/,this.handleSuccessBehavior()];case 3:
36
+ // wait this to finish before resetting store and checkout session id
37
+ p.sent();p.label=4;case 4:
38
+ // Make sure to stop the loading spinner even when there's an error
39
+ this.isLoading=false;
40
+ // reset promo when checkout is finished
41
+ d();u();x.checkoutSessionId=null;return[2/*return*/]}}))}))};this.checkStagingOrderStatus=function(){return __awaiter(t,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:this.notificationType="success";this.notificationTitle=z("You're all set!");this.notificationMessages=h("succeeded").messages;return[4/*yield*/,this.handleSuccessBehavior()];case 1:o.sent();
42
+ // reset promo when checkout is finished
43
+ d();u();g();x.checkoutSessionId=null;return[2/*return*/]}}))}))};this.checkPaypalPaymentStatus=function(){return __awaiter(t,void 0,void 0,(function(){var o;return __generator(this,(function(e){switch(e.label){case 0:
44
+ // render error message if there's an error
45
+ if(y.paypalErrorMessage){this.notificationType="error";this.notificationTitle=z("Payment failed");this.notificationMessages=[y.paypalErrorMessage];this.isLoading=false;return[2/*return*/]}
46
+ // show success message right away when order id is already created
47
+ this.isLoading=false;if(!y.orderIdCreated)return[3/*break*/,2];v({event:"zonos-checkout-success"});o=x.checkoutSessionId;void l({checkoutSessionId:o,eventName:"checkout_orderCompleted"});this.notificationType="success";this.notificationTitle=z("You're all set!");this.notificationMessages=h("succeeded").messages;
48
+ // wait this to finish before resetting store and checkout session id
49
+ return[4/*yield*/,this.handleSuccessBehavior()];case 1:
50
+ // wait this to finish before resetting store and checkout session id
51
+ e.sent();e.label=2;case 2:
52
+ // reset promo when checkout is finished
53
+ d();u();g();x.checkoutSessionId=null;return[2/*return*/]}}))}))};this.getReceiptUrl=function(o){var e=o.cartId;var n=new URL("".concat(window.location.origin,"/receipt"));n.searchParams.set("referenceId",e);
54
+ // is test mode
55
+ var t=I();if(t){n.searchParams.set("zonosTestMode","1")}
56
+ // Carry over the zonosQaUrl if it exists
57
+ var s=new URLSearchParams(window.location.search).get("zonosQaUrl");if(s){n.searchParams.set("zonosQaUrl",s)}return n.toString()}}o.prototype.componentDidLoad=function(){if(this.overrideNotification){
58
+ // just show the notification and don't check any of the payment status
59
+ this.notificationType=this.overrideNotification.type;this.notificationTitle=this.overrideNotification.title;this.notificationMessages=this.overrideNotification.messages;this.isLoading=false;return}if(f.isStagingMode){void this.checkStagingOrderStatus()}else if(y.orderIdCreated){void this.checkPaypalPaymentStatus()}else{void this.checkStripePaymentStatus()}};o.prototype.render=function(){var o=this;var e=window.Zonos.cartId;return t(i,{key:"755581819b6a2e9d97e0faf671320e9390a3000a",class:"zonos--checkout-finish zonos--elements",style:{"--zonos--border-radius":Z({overrideBorderStyle:this.borderRadius})}},!this.isLoading&&t("div",{key:"a5112a4c35f95d80d567d1d9ca690c297f75bba8",class:"zonos--finish-details"},t("div",{key:"f17f25e741a7a846e4d0d653f2e67c6b36ebd77a",class:"zonos--group"},this.notificationType==="success"?t("zonos-icon",{"aria-label":"Order success",content:E,iconColor:"blue-800",size:50}):t("zonos-icon",{"aria-label":"Order failed",content:N,iconColor:"red-800",size:50}),t("zonos-text",{key:"1169bd299d16f1b063de9638c6c6fce00cf9d0a6",class:"zonos--title",type:"semiBoldSubheader"},this.notificationTitle),this.confirmationId&&t("zonos-badge",{key:"db6aebf906ad52207c8bc898c856b7a2a7f061e1",badgeColor:"gray"},this.confirmationId),t("zonos-text",{key:"fd5516196ec5f645718b7fbf0c9de66ab322505b",class:"zonos--subtitle",textColor:"gray-600"},this.notificationMessages.map((function(o){return t(s,null,o,t("br",null))}))),this.order&&e&&t("div",{key:"f50f1e9ed26e609346cdf3bdc1f93689d3c99d06",class:"zonos--button-container"},t("zonos-button",{key:"3dadbbfe5113e02412bb6b890b4d2923101e3c31",onClick:function(){window.open(o.getReceiptUrl({cartId:e}),"_blank")},size:"lg",variant:"primary"},z("View receipt"))))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());q.style=A();var Y='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var Q='<svg width="24" height="24" viewBox="0 0 24 24" fill="none" color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg">\n<path fill-rule="evenodd" clip-rule="evenodd" d="M20 12C20 16.4183 16.4183 20 12 20C7.58172 20 4 16.4183 4 12C4 7.58172 7.58172 4 12 4C16.4183 4 20 7.58172 20 12ZM11.4709 5.80634C11.7686 5.53723 11.9541 5.5 12 5.5C12.0459 5.5 12.2314 5.53723 12.5291 5.80634C12.8115 6.06164 13.1289 6.46913 13.4271 7.03651C13.9505 8.03191 14.3838 9.46098 14.48 11.25H9.51996C9.61624 9.46098 10.0495 8.03191 10.5729 7.03651C10.8711 6.46913 11.1885 6.06164 11.4709 5.80634ZM8.01802 11.25C8.11591 9.23031 8.60319 7.55958 9.24516 6.33849C9.29983 6.23451 9.35585 6.13335 9.41312 6.03514C7.32916 6.94017 5.81218 8.90533 5.5428 11.25H8.01802ZM5.5428 12.75H8.01802C8.11591 14.7697 8.60319 16.4404 9.24516 17.6615C9.29983 17.7655 9.35585 17.8666 9.41312 17.9649C7.32916 17.0598 5.81218 15.0947 5.5428 12.75ZM9.51996 12.75H14.48C14.3838 14.539 13.9505 15.9681 13.4271 16.9635C13.1289 17.5309 12.8115 17.9384 12.5291 18.1937C12.2314 18.4628 12.0459 18.5 12 18.5C11.9541 18.5 11.7686 18.4628 11.4709 18.1937C11.1885 17.9384 10.8711 17.5309 10.5729 16.9635C10.0495 15.9681 9.61624 14.539 9.51996 12.75ZM15.982 12.75C15.8841 14.7697 15.3968 16.4404 14.7548 17.6615C14.7002 17.7655 14.6441 17.8666 14.5869 17.9649C16.6708 17.0598 18.1878 15.0947 18.4572 12.75H15.982ZM18.4572 11.25C18.1878 8.90533 16.6708 6.94017 14.5869 6.03514C14.6441 6.13335 14.7002 6.23451 14.7548 6.33849C15.3968 7.55958 15.8841 9.23031 15.982 11.25H18.4572Z" fill="currentColor"/>\n</svg>\n';var G='<svg width="43" height="10" viewBox="0 0 43 10" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M7.35896 0.0640869H0.30768C0.166068 0.0640869 0.0512695 0.178886 0.0512695 0.320497V1.85896C0.0512695 2.00057 0.166068 2.11537 0.30768 2.11537H4.44439C4.54964 2.11537 4.61005 2.2352 4.54745 2.31982L0.151823 8.2615C0.0865163 8.34978 0.0512695 8.45669 0.0512695 8.56649V9.67947C0.0512695 9.82108 0.166068 9.93588 0.30768 9.93588H7.35896C7.50057 9.93588 7.61537 9.82108 7.61537 9.67947V8.14101C7.61537 7.9994 7.50057 7.8846 7.35896 7.8846H3.22226C3.117 7.8846 3.05659 7.76477 3.11919 7.68015L7.51482 1.73847C7.58013 1.65019 7.61537 1.54328 7.61537 1.43348V0.320497C7.61537 0.178886 7.50057 0.0640869 7.35896 0.0640869Z" fill="var(--zonos-elements-gray-800)"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M11.718 0C10.1602 0 8.89746 1.26279 8.89746 2.82051V7.17949C8.89746 8.73721 10.1602 10 11.718 10H13.6411C15.1988 10 16.4616 8.73721 16.4616 7.17949V2.82051C16.4616 1.26279 15.1988 0 13.6411 0H11.718ZM11.718 2.05128C11.2931 2.05128 10.9487 2.39568 10.9487 2.82051V7.17949C10.9487 7.60432 11.2931 7.94872 11.718 7.94872H13.6411C14.0659 7.94872 14.4103 7.60432 14.4103 7.17949V5V2.82051C14.4103 2.39568 14.0659 2.05128 13.6411 2.05128H11.718Z" fill="var(--zonos-elements-gray-800)"/>\n<path d="M17.7437 0.436316V9.71132C17.7437 9.85293 17.8585 9.96773 18.0001 9.96773H19.5385C19.6801 9.96773 19.7949 9.85293 19.7949 9.71132V3.74801C19.7949 3.44829 19.969 3.17587 20.241 3.04996L22.1641 2.15964C22.6739 1.92363 23.2565 2.29592 23.2565 2.85769V9.71132C23.2565 9.85293 23.3713 9.96773 23.5129 9.96773H25.0513C25.193 9.96773 25.3078 9.85293 25.3078 9.71132V2.85595C25.3078 0.79631 23.1718 -0.568775 21.3027 0.296257L19.9742 0.911055C19.8685 0.959946 19.7432 0.931536 19.669 0.84187L19.2748 0.365697C19.1773 0.248019 19.0325 0.179905 18.8797 0.179905H18.0001C17.8585 0.179905 17.7437 0.294704 17.7437 0.436316Z" fill="var(--zonos-elements-gray-800)"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M29.4104 0C27.8526 0 26.5898 1.26279 26.5898 2.82051V7.17949C26.5898 8.73721 27.8526 10 29.4104 10H31.3334C32.8912 10 34.1539 8.73721 34.1539 7.17949V2.82051C34.1539 1.26279 32.8912 0 31.3334 0H29.4104ZM29.4104 2.05128C28.9855 2.05128 28.6411 2.39568 28.6411 2.82051V7.17949C28.6411 7.60432 28.9855 7.94872 29.4104 7.94872H31.3334C31.7583 7.94872 32.1027 7.60432 32.1027 7.17949V2.82051C32.1027 2.39568 31.7583 2.05128 31.3334 2.05128H29.4104Z" fill="var(--zonos-elements-gray-800)"/>\n<path d="M38.2085 0.0640869H40.3889C41.8309 0.0640869 42.9999 1.23306 42.9999 2.67506C42.9999 2.79477 42.9108 2.89574 42.792 2.91059L41.1732 3.11293C41.054 3.12784 40.9486 3.03485 40.9486 2.91466C40.9486 2.47322 40.5908 2.11537 40.1493 2.11537H38.3397C37.8688 2.11537 37.4871 2.49712 37.4871 2.96803C37.4871 3.3685 37.7658 3.71501 38.1569 3.80087L40.7916 4.37922C42.0811 4.66229 42.9999 5.80462 42.9999 7.12486C42.9999 8.67735 41.7414 9.93588 40.1889 9.93588H38.0468C36.6048 9.93588 35.4358 8.76691 35.4358 7.32491C35.4358 7.2052 35.5249 7.10423 35.6437 7.08938L37.2625 6.88703C37.3817 6.87213 37.4871 6.96512 37.4871 7.08531C37.4871 7.52675 37.8449 7.8846 38.2864 7.8846H40.1176C40.5765 7.8846 40.9486 7.51252 40.9486 7.05354C40.9486 6.67478 40.6925 6.34394 40.3258 6.24901L37.5136 5.52093C36.2902 5.20422 35.4358 4.10042 35.4358 2.83676C35.4358 1.30545 36.6772 0.0640869 38.2085 0.0640869Z" fill="var(--zonos-elements-gray-700)"/>\n</svg>\n';var J=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{position:absolute;bottom:0;left:32px;right:32px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;z-index:2}:host .zonos--invoice-footer{gap:16px;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;padding:12px;padding-left:0;-ms-flex-align:center;align-items:center;width:100%}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:16px}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper .zonos--invoice-footer-logo{display:-ms-inline-flexbox;display:inline-flex;gap:8px;-ms-flex-align:center;align-items:center}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper .zonos--invoice-footer-logo a{line-height:0}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper a{text-decoration:none}:host .zonos--invoice-footer zonos-button button.outline{outline:1px solid var(--zonos-elements-gray-800)}:host .zonos--invoice-footer .zonos--invoice-locale-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:8px;position:relative}@media (max-width: 400px){:host .zonos--invoice-footer .zonos--invoice-locale-wrapper{gap:4px}}:host .zonos--invoice-footer .zonos--invoice-locale-wrapper .zonos--invoice-locale-label{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;gap:4px}:host .zonos--invoice-footer .zonos--invoice-language-dialog{position:absolute;bottom:36px;left:var(--language-dialog-left);background:var(--zonos-elements-surface-color);-webkit-box-shadow:var(--zonos-elements-v3-shadow-xl);box-shadow:var(--zonos-elements-v3-shadow-xl);border-radius:var(--zonos-elements-radius-12);width:360px;max-width:100vw;max-height:500px;z-index:2147483011;overflow:auto;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:bottom left;transform-origin:bottom left;opacity:0;-webkit-transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;-ms-scroll-chaining:none;overscroll-behavior:contain}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar{width:10px}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-thumb:hover{background:#d6d6d6}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-track{border-top-right-radius:var(--zonos-elements-radius-12);border-bottom-right-radius:var(--zonos-elements-radius-12)}:host .zonos--invoice-footer .zonos--invoice-language-dialog.zonos--invoice-language-dialog-open{opacity:1;-webkit-transform:scale(1);transform:scale(1)}:host .dot{display:-ms-inline-flexbox;display:inline-flex;background:var(--zonos-elements-gray-400);width:6px;height:6px;border-radius:50%}:host(.mobile),:host(.tablet){background-color:var(--zonos-elements-gray-0);width:100%;position:-webkit-sticky;position:sticky;bottom:0}:host(.tablet) .zonos--invoice-footer{width:100%;max-width:800px;-ms-flex-pack:justify;justify-content:space-between;display:-ms-flexbox;display:flex}:host(.mobile){-ms-flex-order:3;order:3}:host(.mobile) .zonos--invoice-locale-wrapper{display:none}:host(.mobile) .zonos--invoice-footer{-ms-flex-pack:center;justify-content:center}"};var K=o("zonos_invoice_footer",/** @class */function(){function o(o){e(this,o);
60
+ /**
61
+ * Override mobile mode
62
+ */this.mobile=false;
63
+ /**
64
+ * Override tablet mode
65
+ */this.tablet=false;this.showLanguageDialog=false;this.isMobile=false;this.isTablet=false}o.prototype.handleGlobalClick=function(o){if(!this.el.contains(o.target)&&this.showLanguageDialog){this.showLanguageDialog=false}};o.prototype.toggleLanguageDialog=function(){this.showLanguageDialog=!this.showLanguageDialog};o.prototype.handleMobileChange=function(){this.isMobile=D(this.mobile)};o.prototype.handleTabletChange=function(){this.isTablet=V(this.tablet)};o.prototype.componentWillLoad=function(){this.isMobile=D(this.mobile);this.isTablet=V(this.tablet)};o.prototype.render=function(){var o=this;var e;
66
+ // label resolves against every language, not just the offered ones, so the current
67
+ // locale always renders even if the merchant later drops it from the selector
68
+ var n=(e=w.find((function(o){return o.code===k.selectedLocale})))===null||e===void 0?void 0:e.label;
69
+ // reverse color when on desktop. With the coversheet backdrop, the color should be white
70
+ var r="gray-1000";return t(i,{key:"1cd5499e17c070498d65ebbca71d0cbe3c825456",class:U(["zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"])},t("div",{key:"2f31caade367c351d84571034eda59179c227084",class:"zonos--invoice-footer"},t("div",{key:"25f127514ad98939aee122c6b4772198e095b26d",class:"zonos--invoice-locale-wrapper"},B()&&t(s,{key:"03d37a0e0e94cf42d74a5c59905f7e7219533274"},t("zonos-button",{key:"76aab1e78afa3a51f579f865a24591acea0baadc",buttonColor:r,class:"zonos--invoice-footer-language-button",icon:t("zonos-icon",{"aria-label":"Language select",content:Q,iconColor:r}),onClick:function(){return o.toggleLanguageDialog()},variant:"subtle"},t("span",{key:"28642dac198b7c61bef48d211c8a820e0c8d1fcc",class:"zonos--invoice-locale-label"},n,t("zonos-icon",{key:"364b048befa8c5f45b6869f18b90b27da4b37056","aria-hidden":"true",class:"zonos--invoice-locale-chevron",content:Y,iconColor:r,size:18}))),t("div",{key:"ed4b425741e6aecc49882993be57da58de7d437b",class:U(["zonos--invoice-language-dialog",this.showLanguageDialog&&"zonos--invoice-language-dialog-open"])},t("zonos-language-select",{key:"e4c5e31e8cfdf0ca52a5b935743bda347f9fa7c1",handleOnClose:function(){return o.toggleLanguageDialog()}})))),t("div",{key:"1d0a2613e3a0d487b059fc66fb48f53858a4e6c7",class:"zonos--invoice-footer-icon-wrapper"},t("div",{key:"a27c7eebe0dca7fedbc1e6e22438393391ec9024",class:"zonos--invoice-footer-logo"},t("zonos-text",{key:"1013250d247fdb33ec365f8b3ffe9ca65d431d9d",textColor:r},z("Powered by")),t("a",{key:"ef93dda1f051f353da9e5f286942cc0a0e8015f7",href:"https://zonos.com",target:"_blank",title:"Zonos website"},t("zonos-icon",{key:"de7cc9e5027eb85e7c578afda15a3b3f4e260e91",autoHeight:true,content:G,size:42}))),t("div",{key:"180e60cdd756303a14a4a80b72b81b4a4e1c124a",class:"dot"}),t("a",{key:"7f46908aa8cd49974d7525d7110dbb25402586ab",href:"https://zonos.com/docs/legal/zonos-privacy-policy",target:"_blank"},t("zonos-text",{key:"bba7017be84a8e320ca4d8fb2074822cd7e9f917",textColor:r},z("Privacy policy"))))))};Object.defineProperty(o.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{mobile:[{handleMobileChange:0}],tablet:[{handleTabletChange:0}]}},enumerable:false,configurable:true});return o}());K.style=J();var X='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var $='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M17.707 14.707a1 1 0 0 1-1.414 0L12 10.414l-4.293 4.293a1 1 0 0 1-1.414-1.414l4.93-4.93a1.1 1.1 0 0 1 1.555 0l4.93 4.93a1 1 0 0 1 0 1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var oo=function(){return":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{height:100%}:host *{-ms-scroll-chaining:none;overscroll-behavior:contain}:host *::-webkit-scrollbar{width:10px}:host *::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}:host *::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}:host *::-webkit-scrollbar-thumb:hover{background:#d6d6d6}:host .zonos--order-details-header-text{display:-ms-flexbox;display:flex}:host .zonos--wrapper{overflow:auto;background-color:var(--zonos-elements-gray-50);border-radius:16px;height:100%;min-height:56px}:host .zonos--order-details-header-text{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:8px}:host .zonos--order-details-header{position:-webkit-sticky;position:sticky;top:0;z-index:1;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--zonos-elements-gray-50);border:none;display:-ms-flexbox;display:flex;padding:16px 16px 0 16px;width:100%;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .zonos--order-details-header:focus-visible{outline:none}:host .zonos--order-details-wrapper{position:relative;padding:0 16px 16px 16px}:host .zonos--invoice-order-details-content{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:16px}:host .zonos--invoice-order-info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:32px}:host .zonos--invoice-order-info .zonos--invoice-order-details-row{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:16px}:host .zonos--invoice-order-info .zonos--invoice-order-details-row>*{-ms-flex:1 1 150px;flex:1 1 150px}:host .zonos--invoice-order-info .zonos--invoice-order-details-column{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8px}:host .zonos--invoice-order-info .zonos--invoice-order-shipping-info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:0}"};var eo=o("zonos_invoice_order_details",/** @class */function(){function o(o){e(this,o);this.collapseClicked=n(this,"collapseClicked",7);
71
+ /**
72
+ * Whether or not the component is being rendered with mobile styles
73
+ */this.mobile=true;
74
+ /**
75
+ * The landed cost id that is used to fetch the shipping address
76
+ */this.landedCostId="";this.isMobile=false;this.collapseState=this.collapsed}o.prototype.handleCollapseChangeFromProp=function(o){this.collapseState=o};o.prototype.handleCollapseChange=function(o){this.collapseClicked.emit(o)};o.prototype.handleWindowResize=function(){this.isMobile=S(this.mobile)};o.prototype.componentWillLoad=function(){this.handleWindowResize()};o.prototype.render=function(){var o=this;var e=function(){if(o.collapseState){return t("zonos-icon",{"aria-label":"Collapse expanded section",content:X,iconColor:"gray-1200"})}return t("zonos-icon",{"aria-label":"Expand collapsed section",content:$,iconColor:"gray-1200"})};return t(i,{class:U(["zonos--invoice-order-details zonos--elements",this.isMobile&&"mobile"])},t("div",{class:"zonos--wrapper"},t("button",{class:"zonos--order-details-header",onClick:function(){o.collapseState=!o.collapseState},type:"button"},t("div",{class:"zonos--order-details-header-text"},t("zonos-text",{type:"boldSubheader"},z("Pay [organizationName]",{organizationName:C.organizationName})),e()),t("zonos-text",{type:"boldSubheader"},R({amount:O.amountTotalDue||0,isForeign:true}))),t("div",{class:"zonos--order-details-wrapper"},t("zonos-collapse",{collapsed:this.collapseState},t("div",{class:"zonos--invoice-order-details-content"},t("zonos-invoice-cart-items",{isMobile:this.isMobile}),t("zonos-invoice-subtotal",{isMobile:this.isMobile}))))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{collapsed:[{handleCollapseChangeFromProp:0}],collapseState:[{handleCollapseChange:0}]}},enumerable:false,configurable:true});return o}());eo.style=oo();var no='<svg color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="var(--zonos-elements-gray-1000)" d="M15.342 10.21a.75.75 0 0 0-1.184-.92l-2.978 3.829-1.4-1.4a.75.75 0 1 0-1.06 1.061l1.8 1.8a1 1 0 0 0 1.496-.093l3.326-4.277Z"/><path fill="var(--zonos-elements-gray-1000)" fill-rule="evenodd" d="M12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-6.5 8a6.5 6.5 0 1 1 13 0 6.5 6.5 0 0 1-13 0Z" clip-rule="evenodd"/></svg>';var to='<svg color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="var(--zonos-elements-gray-1000)" d="M14.475 10.586a.75.75 0 1 0-1.06-1.06L12 10.938l-1.414-1.414a.75.75 0 0 0-1.06 1.06L10.938 12l-1.414 1.414a.75.75 0 1 0 1.06 1.06L12 13.062l1.414 1.414a.75.75 0 0 0 1.06-1.06L13.062 12l1.414-1.414Z"/><path fill="var(--zonos-elements-gray-1000)" fill-rule="evenodd" d="M12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-6.5 8a6.5 6.5 0 1 1 13 0 6.5 6.5 0 0 1-13 0Z" clip-rule="evenodd"/></svg>';var so=function(){return".sc-zonos-invoice-payment-h{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-invoice-payment-h *.sc-zonos-invoice-payment{font-family:var(--zonos--font-family, Inter), Inter}.sc-zonos-invoice-payment-h img.sc-zonos-invoice-payment{max-width:100%}.sc-zonos-invoice-payment-h dl.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h dd.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h1.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h2.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h3.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h4.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h5.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h6.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h hr.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h figure.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h p.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h pre.sc-zonos-invoice-payment{margin:0}.sc-zonos-invoice-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-invoice-payment-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1}.sc-zonos-invoice-payment-h .zonos--title.sc-zonos-invoice-payment{margin-bottom:24px}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment{margin-bottom:20px;overflow:auto;padding:5px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1;-ms-scroll-chaining:none;overscroll-behavior:contain}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar{width:10px}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-invoice-payment-h .zonos--payment-error-banner.sc-zonos-invoice-payment{margin-bottom:8px}.sc-zonos-invoice-payment-h .zonos--error-banner.sc-zonos-invoice-payment{margin-bottom:16px}.sc-zonos-invoice-payment-h zonos-button.sc-zonos-invoice-payment{-webkit-box-shadow:0 0 1px 0 var(--zonos-elements-gray-600);box-shadow:0 0 1px 0 var(--zonos-elements-gray-600)}.sc-zonos-invoice-payment-h .zonos--pay-in-base-currency-btn.sc-zonos-invoice-payment{-webkit-box-shadow:none;box-shadow:none}.sc-zonos-invoice-payment-h .zonos--group-btn.sc-zonos-invoice-payment{position:-webkit-sticky;position:sticky;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-direction:column;flex-direction:column;gap:12px;bottom:-4px;padding-top:12px;background:var(--zonos--primary-color, var(--zonos-elements-gray-0))}.sc-zonos-invoice-payment-h .zonos--group-btn.sc-zonos-invoice-payment zonos-text.sc-zonos-invoice-payment{text-align:center}.sc-zonos-invoice-payment-h .zonos--group-btn.sc-zonos-invoice-payment zonos-button.sc-zonos-invoice-payment{width:100%}.sc-zonos-invoice-payment-h .zonos--test-cards.sc-zonos-invoice-payment{margin-top:auto;padding-top:16px}"};var io=o("zonos_invoice_payment",/** @class */function(){function o(o){var t=this;e(this,o);this.continueClicked=n(this,"continueClicked",7);this.paypalSessionFailed=n(this,"paypalSessionFailed",7);this.paypalSessionDone=n(this,"paypalSessionDone",7);this.storeUnsubscribeList=[];
77
+ /**
78
+ * Whether or not the continue button is loading
79
+ */this.continueLoading=false;
80
+ /**
81
+ * Show error banner when the form is not complete, and user clicks on `Submit` button
82
+ * @default false
83
+ */this.showErrorBanner=false;
84
+ /**
85
+ * Show payment error banner when the payment is failed
86
+ */this.hasStripePaymentError=false;
87
+ /**
88
+ * Error message when the staging order creation is failed
89
+ */this.stagingOrderCreateErrorMessage="";
90
+ /**
91
+ * Internal state to handle continue loading
92
+ */this.internalContinueLoading=this.continueLoading;this.handleValidate=function(){var o;return!!((o=a.stripePaymentEventData)===null||o===void 0?void 0:o.complete)};
93
+ /**
94
+ * handler for continue button click
95
+ */this.continueClickHandler=function(o){return __awaiter(t,[o],void 0,(function(o){var e,n;var t=this;var s=o.currencyCode;return __generator(this,(function(o){if(!this.handleValidate()){
96
+ // Attempt to get the value of the billing address element to validate the form
97
+ void((e=a.stripeBillingAddressElement)===null||e===void 0?void 0:e.getValue());this.showErrorBanner=true;
98
+ // Attempt to submit the form so the missing input error will be shown in Stripe
99
+ void((n=a.stripeElements)===null||n===void 0?void 0:n.submit());setTimeout((function(){var o;(o=t.ele.querySelector("zonos-banner"))===null||o===void 0?void 0:o.scrollIntoView({behavior:"smooth"})}),10);return[2/*return*/]}a.checkoutSettlementCurrency=s;
100
+ // submit google tag when the form is complete
101
+ v({event:"zonos-checkout-payment-info"});this.continueClicked.emit();return[2/*return*/]}))}))};this.copyCardToClipboard=function(o){return __awaiter(t,void 0,void 0,(function(){var e,n;return __generator(this,(function(t){switch(t.label){case 0:t.trys.push([0,2,,3]);return[4/*yield*/,navigator.clipboard.writeText(o)];case 1:t.sent();return[3/*break*/,3];case 2:e=t.sent();n=document.createElement("textarea");n.style.position="fixed";n.style.left="-1000px";n.style.top="-1000px";n.style.width="1px";n.style.height="1px";n.value=o;n.id="zonos-copy-card-number";document.body.appendChild(n);n.select();
102
+ // Have to use deprecated method execCommand because it's the only way to copy to the clipboard in the iframe
103
+ // eslint-disable-next-line deprecation/deprecation
104
+ document.execCommand("copy");document.body.removeChild(n);return[3/*break*/,3];case 3:window.Zonos.showNotification({message:z("Card number copied to clipboard"),timeout:4e3,type:"success"});return[2/*return*/]}}))}))};this.placeTestOrder=function(){return __awaiter(t,void 0,void 0,(function(){var o;return __generator(this,(function(e){switch(e.label){case 0:this.internalContinueLoading=true;return[4/*yield*/,F()];case 1:o=e.sent().errors;if(o.length){this.stagingOrderCreateErrorMessage=o[0]||"Failed to create staging order. Please try again.";this.internalContinueLoading=false;return[2/*return*/]}this.internalContinueLoading=false;
105
+ // continue to the next step
106
+ p();return[2/*return*/]}}))}))}}o.prototype.continueLoadingWatcher=function(){this.internalContinueLoading=this.continueLoading};o.prototype.stripePaymentErrorWatcher=function(){var o=this;if(this.hasStripePaymentError){setTimeout((function(){var e;
107
+ // scroll to the top of the page when the payment error is shown
108
+ (e=o.ele.querySelector("zonos-banner"))===null||e===void 0?void 0:e.scrollIntoView({behavior:"smooth"})}),50)}};o.prototype.componentWillLoad=function(){this.storeUnsubscribeList=[m("currency",(function(){
109
+ // start init paypal with the presentment currency when landed cost is fetched
110
+ void b({currency:f.currency})}))];
111
+ // start init paypal with the presentment currency when landed cost is fetched
112
+ void b({currency:f.currency})};o.prototype.disconnectedCallback=function(){this.storeUnsubscribeList.forEach((function(o){return o()}))};o.prototype.render=function(){var o=this;var e;this.hasStripePaymentError=a.hasPaymentError;if(!a.stripeElements){return null}if(!a.clientSecret){return null}
113
+ // start validate on typing after error banner is shown, and hide it if the form is complete
114
+ if(this.showErrorBanner){this.showErrorBanner=!this.handleValidate()}var n=I();var r=f.isStagingMode||L();var c=((e=a.stripePaymentEventData)===null||e===void 0?void 0:e.value.type)==="external_paypal";var l=function(){if(r){
115
+ // If in mobile, use the theme from the store since the UI is solely by theme
116
+ var e=C.appearance.theme;return t(s,null,o.stagingOrderCreateErrorMessage&&t("zonos-banner",{class:"zonos--error-banner",intent:"error"},o.stagingOrderCreateErrorMessage),t("zonos-empty-state-payment",{emptyStateText:z("No payment method needed for staging"),theme:e}),t("div",{class:"zonos--group-btn"},t("zonos-button",{backgroundColor:o.submitBtnColor,loading:o.internalContinueLoading,onClick:function(){void o.placeTestOrder()},size:"lg",
117
+ // use primary type when on mobile mode
118
+ variant:o.submitBtnType},z("Place test order"))))}if(a.isFetchingSession||O.isFetchingPayorInfo){return null}return t(s,null,o.showErrorBanner&&t("zonos-banner",{class:"zonos--error-banner",intent:"error"},z("Missing required fields. Make sure all fields are completed.")),o.hasStripePaymentError&&t("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},a.customErrorMessage||z("We couldn't complete your payment. Please verify the payment details and try again.")),y.paypalErrorMessage&&t("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},y.paypalErrorMessage),t("zonos-payment",null),t("div",{class:"zonos--group-btn"},!c&&t(s,null,t("zonos-button",{backgroundColor:o.submitBtnColor,bold:true,isDisabled:o.continueLoading&&a.checkoutSettlementCurrency==="USD",loading:o.continueLoading&&a.checkoutSettlementCurrency!=="USD",onClick:function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:if(!f.checkoutSession){H("Checkout session is not found");return[2/*return*/]}return[4/*yield*/,this.continueClickHandler({currencyCode:f.checkoutSession.subtotals.presentmentCurrencyCode})];case 1:o.sent();return[2/*return*/]}}))}))},size:"lg",
119
+ // use primary type when on mobile mode
120
+ variant:o.submitBtnType},z("Pay [orderTotal]",{orderTotal:R({amount:O.amountTotalDue||0,isForeign:true})})),a.shouldRenderPayInUsdButton&&t("zonos-button",{class:"zonos--pay-in-base-currency-btn",isDisabled:o.continueLoading&&a.checkoutSettlementCurrency!=="USD",loading:o.continueLoading&&a.checkoutSettlementCurrency==="USD",onClick:function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:return[4/*yield*/,this.continueClickHandler({currencyCode:"USD"})];case 1:o.sent();return[2/*return*/]}}))}))},size:"lg",variant:"subtle"},z("Click to pay in USD"))),t("zonos-paypal-payment",{onPaypalSessionDone:function(e){var n=e.detail.orderId;o.paypalSessionDone.emit(n)},onPaypalSessionFail:function(){return o.paypalSessionFailed.emit()},style:{display:c?"block":"none"}})),n&&t("zonos-card",{backgroundColor:"gray-100",borderRadius:12,class:"zonos--test-cards"},t("zonos-v-stack",{spacing:16},t("div",null,t("zonos-text",{type:"semiBoldLabel"},z("Test cards")),t("zonos-text",{textColor:"gray-700"},z("Click to copy the card number. Use any future expiration date and three number CVC."))),t("zonos-button",{icon:t("zonos-icon",{content:no}),justifyContent:"flex-start",onClick:function(){return o.copyCardToClipboard("4242424242424242")}},z("Success")," (****4242)"),t("zonos-button",{icon:t("zonos-icon",{content:to}),justifyContent:"flex-start",onClick:function(){return o.copyCardToClipboard("4000000000000002")}},z("Failure")," (****0002)")),t("zonos-notification",null)))};return t(i,{class:"zonos--checkout-payment zonos--elements"},t("div",{class:"zonos--group"},t("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},z("Payment method")),l()))};Object.defineProperty(o.prototype,"ele",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{continueLoading:[{continueLoadingWatcher:0}],hasStripePaymentError:[{stripePaymentErrorWatcher:0}]}},enumerable:false,configurable:true});return o}());io.style=so();var ro=function(){return':host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{position:-webkit-sticky;position:sticky;top:0;background-color:var(--zonos-elements-gray-0);z-index:1}:host .zonos--total-pay{margin:8px 0 24px;display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;gap:48px}:host .zonos--total-pay zonos-text{-ms-flex-negative:0;flex-shrink:0}:host .zonos--total-pay::after{content:"";position:relative;height:1px;width:100%;background:var(--zonos-elements-gray-200)}:host(.mobile),:host(.tablet){display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8px;padding:4px 0;background-color:transparent;position:relative}:host(.mobile) .zonos--total-pay,:host(.tablet) .zonos--total-pay{margin:0}'};var ao=o("zonos_invoice_review",/** @class */function(){function o(o){e(this,o);
121
+ /**
122
+ * Whether or not the component is being rendered with mobile styles
123
+ */this.mobile=false;
124
+ /**
125
+ * Whether or not the component is being rendered with tablet styles
126
+ */this.tablet=false;
127
+ /**
128
+ * Whether or not to show the collapse icon
129
+ * This is controled from the collapsed state of the zonos-collapse component
130
+ * to show the collapse icon
131
+ */this.collapsed=false;this.isMobile=false;this.isTablet=false;this.isLoading=true}o.prototype.handleWindowResize=function(){this.isMobile=D(this.mobile);this.isTablet=V(this.tablet)};o.prototype.componentWillLoad=function(){var o=this;this.handleWindowResize();
132
+ // Wait for the data to load
133
+ setTimeout((function(){o.isLoading=false}),1e3)};o.prototype.render=function(){var o=this.isMobile?"gray-1000":"gray-800";return t(i,{key:"46c130c8e6aeacdd5f74feb613ec5829c0be396d",class:U(["zonos--invoice-review zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"])},t("div",{key:"9649e31a3053c9772363620cf2acfe557ace8715",class:"zonos--title"},t("zonos-text",{key:"1b365c27c2280e61c4849c7382a945716ec2abf8",textColor:o,type:"semiBoldLabel"},z("Pay [organizationName]",{organizationName:C.organizationName}))),t("div",{key:"a1f24eb0f3080ec0ddad9ca323f49dd391117326",class:"zonos--total-pay"},T({content:t("zonos-text",{type:"secondaryPageHeader"},R({amount:O.amountTotalDue||0,isForeign:true})),isLoading:O.isFetchingPayorInfo,skeletonHeight:"36px",skeletonWidth:"150px"})))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());ao.style=ro()}}}));
@@ -0,0 +1,27 @@
1
+ System.register(["./p-CIevpRv_.system.js","./p-CPnR_T0a.system.js","./p-d05Ku7gM.system.js","./p-C2j7R11h.system.js","./p-BSgVcCxT.system.js","./p-DW-fW8yR.system.js","./p-BbgqQIHv.system.js"],(function(o){"use strict";var s,t,n,i,e,p,r,a,l,c,u,z;return{setters:[function(o){s=o.r;t=o.d;n=o.h;i=o.a;e=o.g},function(o){p=o.z;r=o.a},function(o){a=o.i;l=o.a},function(o){c=o.c},function(o){u=o.g},function(o){z=o.i},null],execute:function(){var d=function(){return'.sc-zonos-stripe-input-h{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-stripe-input-h *.sc-zonos-stripe-input{font-family:var(--zonos--font-family, Inter), Inter}.sc-zonos-stripe-input-h img.sc-zonos-stripe-input{max-width:100%}.sc-zonos-stripe-input-h dl.sc-zonos-stripe-input,.sc-zonos-stripe-input-h dd.sc-zonos-stripe-input,.sc-zonos-stripe-input-h h1.sc-zonos-stripe-input,.sc-zonos-stripe-input-h h2.sc-zonos-stripe-input,.sc-zonos-stripe-input-h h3.sc-zonos-stripe-input,.sc-zonos-stripe-input-h h4.sc-zonos-stripe-input,.sc-zonos-stripe-input-h h5.sc-zonos-stripe-input,.sc-zonos-stripe-input-h h6.sc-zonos-stripe-input,.sc-zonos-stripe-input-h hr.sc-zonos-stripe-input,.sc-zonos-stripe-input-h figure.sc-zonos-stripe-input,.sc-zonos-stripe-input-h p.sc-zonos-stripe-input,.sc-zonos-stripe-input-h pre.sc-zonos-stripe-input{margin:0}.sc-zonos-stripe-input-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-stripe-input-h{--zonos--background-color:#f1f1f1;--zonos--local-glowing-color:0 0 0 3px hsla(0, 0%, 100%, 25%), 0 0 0 1px var(--zonos--primary-color);--zonos--border:1px solid #e8e8e8}.dark.sc-zonos-stripe-input-h{color-scheme:dark;--zonos--background-color:#30313d;--zonos--local-glowing-color:0px 2px 4px rgba(0, 0, 0, 0.5), 0px 1px 6px rgba(0, 0, 0, 0.25), 0 0 0 3px hsla(0, 0%, 100%, 25%), 0 1px 1px 0 rgba(255, 255, 255, 0.12);--zonos--border:1px solid var(--zonos--primary-color)}.sc-zonos-stripe-input-h{margin:1px}.sc-zonos-stripe-input-h .zonos--label-wrapper.sc-zonos-stripe-input{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;width:100%;background:var(--zonos--background-color);border-radius:var(--zonos--border-radius);border:var(--zonos--border);outline-offset:0;outline-width:2px;height:calc(var(--zonos-elements-size-xl) - 2px)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input{-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;padding:0 16px;outline:none;-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);width:100%;border-radius:var(--zonos--border-radius);background:var(--zonos--background-color);border:var(--zonos--border);-ms-flex-order:2;order:2;font-weight:400;font-size:var(--zonos--font-size);color:var(--zonos-elements-text-color);height:auto}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input .sc-zonos-stripe-input:-internal-autofill-selected{border-radius:var(--zonos-elements-radius-6) 0 0 var(--zonos-elements-radius-6)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input .sc-zonos-stripe-input:-internal-autofill-selected+label.sc-zonos-stripe-input+div.sc-zonos-stripe-input{background-color:#e8f0fe}.sc-zonos-stripe-input-h .zonos--floated-input.has-label.sc-zonos-stripe-input{padding:24px 4px 2px 16px}.sc-zonos-stripe-input-h .zonos--floated-input.has-label.has-input-prefix.sc-zonos-stripe-input{padding-left:0}.sc-zonos-stripe-input-h .zonos--floated-input.has-label.has-input-prefix.sc-zonos-stripe-input~.zonos--floated-label.sc-zonos-stripe-input label.sc-zonos-stripe-input{margin-left:0}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:not(.has-label)::-webkit-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:not(.has-label)::-moz-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:not(.has-label):-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:not(.has-label)::-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:not(.has-label)::placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input::-webkit-input-placeholder{-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input::-moz-placeholder{-moz-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:-ms-input-placeholder{-ms-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input::-ms-input-placeholder{-ms-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input::placeholder{-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus{outline:none;border:var(--zonos--border)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus~.zonos--floated-label.sc-zonos-stripe-input::after{-webkit-box-shadow:var(--zonos--glowing-color, var(--zonos--local-glowing-color));box-shadow:var(--zonos--glowing-color, var(--zonos--local-glowing-color))}.sc-zonos-stripe-input-h .zonos--floated-input.has-error.sc-zonos-stripe-input~.zonos--floated-label.sc-zonos-stripe-input::after{-webkit-box-shadow:0 0 0 2px #df1b41;box-shadow:0 0 0 2px #df1b41}.sc-zonos-stripe-input-h .zonos--floated-input.has-content.sc-zonos-stripe-input::-webkit-input-placeholder,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus::-webkit-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.has-content.sc-zonos-stripe-input::-moz-placeholder,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus::-moz-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.has-content.sc-zonos-stripe-input:-ms-input-placeholder,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus:-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.has-content.sc-zonos-stripe-input::-ms-input-placeholder,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus::-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.has-content.sc-zonos-stripe-input::placeholder,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus::placeholder{opacity:var(--zonos-elements-opacity-disabled)}.sc-zonos-stripe-input-h .zonos--floated-input.has-content.sc-zonos-stripe-input~.zonos--floated-label.sc-zonos-stripe-input label.sc-zonos-stripe-input,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:focus~.zonos--floated-label.sc-zonos-stripe-input label.sc-zonos-stripe-input{top:11px;-webkit-transform:scale(0.8);transform:scale(0.8)}.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:-webkit-autofill,.sc-zonos-stripe-input-h .zonos--floated-input.sc-zonos-stripe-input:-moz-autofill{background-color:var(--zonos-elements-input-background);color:var(--zonos-elements-text-color)}.sc-zonos-stripe-input-h .zonos--floated-label.sc-zonos-stripe-input{display:block;max-height:0;pointer-events:none;-ms-flex-order:1;order:1}.sc-zonos-stripe-input-h .zonos--floated-label.sc-zonos-stripe-input label.sc-zonos-stripe-input{color:var(--zonos-elements-gray-800);position:absolute;font-size:16px;line-height:16px;display:inline-block;-webkit-filter:blur(0);filter:blur(0);-webkit-transform-origin:left top;transform-origin:left top;-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);margin-left:16px;top:calc(50% - 8px);z-index:1}.sc-zonos-stripe-input-h .zonos--floated-label.sc-zonos-stripe-input::after{content:"";position:absolute;left:0;right:0;top:0;bottom:0;border-radius:var(--zonos--border-radius)}.sc-zonos-stripe-input-h .disabled.sc-zonos-stripe-input .zonos--floated-label.sc-zonos-stripe-input{pointer-events:inherit}.sc-zonos-stripe-input-h .disabled.sc-zonos-stripe-input .zonos--floated-label.sc-zonos-stripe-input::after{cursor:not-allowed;z-index:1}.dark.sc-zonos-stripe-input-h .zonos--label-wrapper.sc-zonos-stripe-input{background:#30313d}'};var h=0;var f=o("zonos_stripe_input",/** @class */function(){function o(o){s(this,o);this.inputChange=t(this,"inputChange",7);
2
+ /**
3
+ * Inherited attributes from the host element
4
+ */this.inheritedAttributes={};this.inputId="zonos--input-".concat(++h);
5
+ /**
6
+ * Value of the stripeInput
7
+ */this.inputValue="";
8
+ /**
9
+ * Disables the input
10
+ */this.isDisabled=false;
11
+ /**
12
+ * Error state of the input
13
+ */this.isError=false;
14
+ /**
15
+ * Error message of the input
16
+ */this.error="";
17
+ /**
18
+ * Placeholder for the input
19
+ */this.inputPlaceholder="";
20
+ /**
21
+ * The value of the input.
22
+ */this.value="";
23
+ /**
24
+ * Whether the input is required
25
+ */this.required=false;this.internalValue=this.inputValue}o.prototype.onInputValueChange=function(o){this.internalValue=o;this.inputChange.emit(o);this.value=o};o.prototype.onValueChange=function(o){this.internalValue=o};o.prototype.componentWillLoad=function(){this.inheritedAttributes=Object.assign(Object.assign({},a(this.el)),l(this.el,["tabindex","title","data-form-type","dir"]))};o.prototype.render=function(){var o=this;var s=this.overridePrimaryColor||p.appearance.colorPrimary;var t=this.overrideSecondaryColor||p.appearance.colorSecondary;
26
+ // Always use theme from appearance settings if it's collect
27
+ var e=window.Zonos.isCollect||window.Zonos.isInvoice?p.appearance.theme==="DARK":s&&z(s);var a=p.appearance.fontSizeInputValue||16;return n(i,{key:"b527df7c911ed1d090805f89793b1db0d2e60935",class:c(["zonos--input zonos--elements",e&&"dark",(this.isError||!!this.error)&&"has-error"]),"data-theme":e?"DARK":"LIGHT",style:{"--zonos--border-radius":u(),"--zonos--font-family":r(),"--zonos--font-size":"".concat(a,"px"),"--zonos--primary-color":t}},n("div",{key:"34638283e1cc53399e0c06939698ab565cb45898",class:c(["zonos--label-wrapper",this.isDisabled&&"disabled"])},n("input",Object.assign({key:"3c6786e238870a22df24226b849df8c50285066f"},this.inheritedAttributes,{autoComplete:this.autoComplete,class:c(["zonos--floated-input",!!this.inputLabel&&"has-label",this.internalValue&&"has-content",(this.isError||!!this.error)&&"has-error"]),disabled:this.isDisabled,id:this.inputId,name:this.name,onInput:function(s){var t=s.target;o.inputChange.emit(t.value);o.el.inputValue=t.value;o.el.dispatchEvent(new Event("change"))},placeholder:this.inputPlaceholder||"",required:this.required,type:"text",value:this.internalValue})),n("div",{key:"32ef73f611becbc961b594a22976651eeb2547cd",class:"zonos--floated-label"},n("label",{key:"7ef5e3be28b12f1d17f20cd6698ccb877b74a28b",htmlFor:this.inputId},this.inputLabel))),this.error&&n("zonos-text",{key:"5d0e354d1ff22b9d0d9ab92a571029ce3b06be9b",textColor:"red-600",type:"caption"},this.error))};Object.defineProperty(o.prototype,"el",{get:function(){return e(this)},enumerable:false,configurable:true});Object.defineProperty(o,"watchers",{get:function(){return{inputValue:[{onInputValueChange:0}],value:[{onValueChange:0}]}},enumerable:false,configurable:true});return o}());f.style=d()}}}));