@zonos/elements 1.3.8-alpha.0 → 1.3.8-alpha.1

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 (202) hide show
  1. package/dist/cjs/{cart-eee85bda.js → cart-c22d66c8.js} +98 -21
  2. package/dist/cjs/{getBorderRadius-d8f18958.js → getBorderRadius-d9a954a3.js} +1 -1
  3. package/dist/cjs/{isDarkColor-57860b44.js → isDarkColor-c01f24df.js} +1 -1
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/{submitGtag-a2e1f652.js → submitGtag-9c0a8038.js} +2 -2
  6. package/dist/cjs/zonos-address_4.cjs.entry.js +60 -7
  7. package/dist/cjs/zonos-badge_2.cjs.entry.js +1 -1
  8. package/dist/cjs/zonos-banner.cjs.entry.js +1 -1
  9. package/dist/cjs/zonos-button_3.cjs.entry.js +3 -3
  10. package/dist/cjs/zonos-card_2.cjs.entry.js +4 -4
  11. package/dist/cjs/zonos-cart-items_9.cjs.entry.js +32 -17
  12. package/dist/cjs/zonos-checkout.cjs.entry.js +5 -5
  13. package/dist/cjs/zonos-controller.cjs.entry.js +4 -4
  14. package/dist/cjs/zonos-country-flag.cjs.entry.js +4 -4
  15. package/dist/cjs/zonos-country-select_3.cjs.entry.js +4 -4
  16. package/dist/cjs/zonos-elements.cjs.js +1 -1
  17. package/dist/cjs/zonos-hello-dialog.cjs.entry.js +4 -4
  18. package/dist/cjs/zonos-hello.cjs.entry.js +4 -4
  19. package/dist/cjs/zonos-logo.cjs.entry.js +1 -1
  20. package/dist/cjs/zonos-notification.cjs.entry.js +1 -1
  21. package/dist/cjs/zonos-payment.cjs.entry.js +4 -4
  22. package/dist/cjs/zonos-select-dialog-header_2.cjs.entry.js +1 -1
  23. package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +2 -2
  24. package/dist/cjs/zonos-text.cjs.entry.js +1 -1
  25. package/dist/cjs/{zonosStore-138c5555.js → zonosStore-2a8612a4.js} +1 -0
  26. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js +3 -3
  27. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +27 -10
  28. package/dist/collection/components/store/checkout/stripe.js +3 -3
  29. package/dist/collection/components/store/translationStore/strings.arabic.js +3 -0
  30. package/dist/collection/components/store/translationStore/strings.base.js +3 -0
  31. package/dist/collection/components/store/translationStore/strings.chinese.js +3 -0
  32. package/dist/collection/components/store/translationStore/strings.danish.js +3 -0
  33. package/dist/collection/components/store/translationStore/strings.dutch.js +3 -0
  34. package/dist/collection/components/store/translationStore/strings.french.js +3 -0
  35. package/dist/collection/components/store/translationStore/strings.german.js +3 -0
  36. package/dist/collection/components/store/translationStore/strings.hebrew.js +3 -0
  37. package/dist/collection/components/store/translationStore/strings.indonesian.js +3 -0
  38. package/dist/collection/components/store/translationStore/strings.italian.js +3 -0
  39. package/dist/collection/components/store/translationStore/strings.japanese.js +3 -0
  40. package/dist/collection/components/store/translationStore/strings.korean.js +3 -0
  41. package/dist/collection/components/store/translationStore/strings.norwegian.js +3 -0
  42. package/dist/collection/components/store/translationStore/strings.polish.js +3 -0
  43. package/dist/collection/components/store/translationStore/strings.portuguese.js +3 -0
  44. package/dist/collection/components/store/translationStore/strings.russian.js +3 -0
  45. package/dist/collection/components/store/translationStore/strings.spanish.js +3 -0
  46. package/dist/collection/components/store/translationStore/strings.swedish.js +3 -0
  47. package/dist/collection/components/store/translationStore/strings.turkish.js +3 -0
  48. package/dist/collection/components/store/translationStore/strings.vietnamese.js +3 -0
  49. package/dist/collection/components/store/zonosStore.js +1 -0
  50. package/dist/collection/components/stripe/zonos-address/zonos-address.css +3 -0
  51. package/dist/collection/components/stripe/zonos-address/zonos-address.js +63 -4
  52. package/dist/collection/components/utils/containsNonLatinChars.js +13 -0
  53. package/dist/collection/styles/stripe/addressRuleStyle.js +32 -15
  54. package/dist/collection/types/generated/graphql.customer.types.js +37 -0
  55. package/dist/collection/types/generated/graphql.frontend.types.js +19 -0
  56. package/dist/components/stripe.js +95 -18
  57. package/dist/components/zonos-address2.js +67 -6
  58. package/dist/components/zonos-checkout-finish2.js +3 -3
  59. package/dist/components/zonos-customer-info2.js +35 -12
  60. package/dist/components/zonosStore.js +1 -0
  61. package/dist/esm/{cart-e261efc1.js → cart-f70b9be6.js} +98 -21
  62. package/dist/esm/{getBorderRadius-19787feb.js → getBorderRadius-0d133844.js} +1 -1
  63. package/dist/esm/{isDarkColor-2344e7a5.js → isDarkColor-8eeda28e.js} +1 -1
  64. package/dist/esm/loader.js +1 -1
  65. package/dist/esm/{submitGtag-dfc6f1dc.js → submitGtag-1d7ee6b8.js} +2 -2
  66. package/dist/esm/zonos-address_4.entry.js +61 -8
  67. package/dist/esm/zonos-badge_2.entry.js +1 -1
  68. package/dist/esm/zonos-banner.entry.js +1 -1
  69. package/dist/esm/zonos-button_3.entry.js +3 -3
  70. package/dist/esm/zonos-card_2.entry.js +4 -4
  71. package/dist/esm/zonos-cart-items_9.entry.js +32 -17
  72. package/dist/esm/zonos-checkout.entry.js +5 -5
  73. package/dist/esm/zonos-controller.entry.js +4 -4
  74. package/dist/esm/zonos-country-flag.entry.js +4 -4
  75. package/dist/esm/zonos-country-select_3.entry.js +4 -4
  76. package/dist/esm/zonos-elements.js +1 -1
  77. package/dist/esm/zonos-hello-dialog.entry.js +4 -4
  78. package/dist/esm/zonos-hello.entry.js +4 -4
  79. package/dist/esm/zonos-logo.entry.js +1 -1
  80. package/dist/esm/zonos-notification.entry.js +1 -1
  81. package/dist/esm/zonos-payment.entry.js +4 -4
  82. package/dist/esm/zonos-select-dialog-header_2.entry.js +1 -1
  83. package/dist/esm/zonos-shipping-rich-radio.entry.js +2 -2
  84. package/dist/esm/zonos-text.entry.js +1 -1
  85. package/dist/esm/{zonosStore-00bce01b.js → zonosStore-807f931f.js} +1 -0
  86. package/dist/esm-es5/cart-f70b9be6.js +1 -0
  87. package/dist/esm-es5/{getBorderRadius-19787feb.js → getBorderRadius-0d133844.js} +1 -1
  88. package/dist/esm-es5/{isDarkColor-2344e7a5.js → isDarkColor-8eeda28e.js} +1 -1
  89. package/dist/esm-es5/loader.js +1 -1
  90. package/dist/esm-es5/{submitGtag-dfc6f1dc.js → submitGtag-1d7ee6b8.js} +1 -1
  91. package/dist/esm-es5/zonos-address_4.entry.js +1 -1
  92. package/dist/esm-es5/zonos-badge_2.entry.js +1 -1
  93. package/dist/esm-es5/zonos-banner.entry.js +1 -1
  94. package/dist/esm-es5/zonos-button_3.entry.js +1 -1
  95. package/dist/esm-es5/zonos-card_2.entry.js +1 -1
  96. package/dist/esm-es5/zonos-cart-items_9.entry.js +1 -1
  97. package/dist/esm-es5/zonos-checkout.entry.js +1 -1
  98. package/dist/esm-es5/zonos-controller.entry.js +1 -1
  99. package/dist/esm-es5/zonos-country-flag.entry.js +1 -1
  100. package/dist/esm-es5/zonos-country-select_3.entry.js +1 -1
  101. package/dist/esm-es5/zonos-elements.js +1 -1
  102. package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -1
  103. package/dist/esm-es5/zonos-hello.entry.js +1 -1
  104. package/dist/esm-es5/zonos-logo.entry.js +1 -1
  105. package/dist/esm-es5/zonos-notification.entry.js +1 -1
  106. package/dist/esm-es5/zonos-payment.entry.js +1 -1
  107. package/dist/esm-es5/zonos-select-dialog-header_2.entry.js +1 -1
  108. package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +1 -1
  109. package/dist/esm-es5/zonos-text.entry.js +1 -1
  110. package/dist/esm-es5/{zonosStore-00bce01b.js → zonosStore-807f931f.js} +1 -1
  111. package/dist/scripts/loadZonos.js +1 -1
  112. package/dist/scripts/zonos.js +1 -1
  113. package/dist/scripts/zonosBase.js +1 -1
  114. package/dist/types/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.d.ts +9 -0
  115. package/dist/types/components/store/translationStore/strings.arabic.d.ts +3 -0
  116. package/dist/types/components/store/translationStore/strings.base.d.ts +3 -0
  117. package/dist/types/components/store/translationStore/strings.chinese.d.ts +3 -0
  118. package/dist/types/components/store/translationStore/strings.danish.d.ts +3 -0
  119. package/dist/types/components/store/translationStore/strings.dutch.d.ts +3 -0
  120. package/dist/types/components/store/translationStore/strings.french.d.ts +3 -0
  121. package/dist/types/components/store/translationStore/strings.german.d.ts +3 -0
  122. package/dist/types/components/store/translationStore/strings.hebrew.d.ts +3 -0
  123. package/dist/types/components/store/translationStore/strings.indonesian.d.ts +3 -0
  124. package/dist/types/components/store/translationStore/strings.italian.d.ts +3 -0
  125. package/dist/types/components/store/translationStore/strings.japanese.d.ts +3 -0
  126. package/dist/types/components/store/translationStore/strings.korean.d.ts +3 -0
  127. package/dist/types/components/store/translationStore/strings.norwegian.d.ts +3 -0
  128. package/dist/types/components/store/translationStore/strings.polish.d.ts +3 -0
  129. package/dist/types/components/store/translationStore/strings.portuguese.d.ts +3 -0
  130. package/dist/types/components/store/translationStore/strings.russian.d.ts +3 -0
  131. package/dist/types/components/store/translationStore/strings.spanish.d.ts +3 -0
  132. package/dist/types/components/store/translationStore/strings.swedish.d.ts +3 -0
  133. package/dist/types/components/store/translationStore/strings.turkish.d.ts +3 -0
  134. package/dist/types/components/store/translationStore/strings.vietnamese.d.ts +3 -0
  135. package/dist/types/components/stripe/zonos-address/zonos-address.d.ts +7 -0
  136. package/dist/types/components/utils/api/getLocaleMessages.d.ts +1 -1
  137. package/dist/types/components/utils/containsNonLatinChars.d.ts +16 -0
  138. package/dist/types/components.d.ts +19 -0
  139. package/dist/types/types/checkout/CheckoutConfig.d.ts +5 -0
  140. package/dist/types/types/generated/graphql.customer.types.d.ts +53 -0
  141. package/dist/types/types/generated/graphql.customer.types.ts +71 -0
  142. package/dist/types/types/generated/graphql.frontend.types.d.ts +20 -1
  143. package/dist/types/types/generated/graphql.frontend.types.ts +23 -1
  144. package/dist/zonos-elements/p-039803aa.system.js +1 -0
  145. package/dist/zonos-elements/{p-0c91720b.entry.js → p-04acf5ef.entry.js} +1 -1
  146. package/dist/zonos-elements/p-066c5893.system.js +1 -1
  147. package/dist/zonos-elements/{p-14c3ef38.entry.js → p-0ed00121.entry.js} +1 -1
  148. package/dist/zonos-elements/{p-143dc0d9.system.entry.js → p-121c551d.system.entry.js} +1 -1
  149. package/dist/zonos-elements/{p-f6eaef7b.system.entry.js → p-166ec0c2.system.entry.js} +1 -1
  150. package/dist/zonos-elements/{p-1e0dd491.entry.js → p-1691b167.entry.js} +1 -1
  151. package/dist/zonos-elements/{p-07966463.entry.js → p-25de098d.entry.js} +1 -1
  152. package/dist/zonos-elements/{p-c2e58ee1.system.entry.js → p-2eb62b45.system.entry.js} +1 -1
  153. package/dist/zonos-elements/{p-3a1e685f.entry.js → p-32f43296.entry.js} +1 -1
  154. package/dist/zonos-elements/{p-14d27ce1.system.entry.js → p-35e878eb.system.entry.js} +1 -1
  155. package/dist/zonos-elements/p-373e579c.entry.js +1 -0
  156. package/dist/zonos-elements/{p-354603b3.system.entry.js → p-3a406969.system.entry.js} +1 -1
  157. package/dist/zonos-elements/p-3d4fc5aa.js +1 -0
  158. package/dist/zonos-elements/{p-c060d475.js → p-4679840f.js} +1 -1
  159. package/dist/zonos-elements/{p-78ba2928.system.js → p-4c4ccf82.system.js} +1 -1
  160. package/dist/zonos-elements/{p-4fb77a38.system.entry.js → p-4da6d5bb.system.entry.js} +1 -1
  161. package/dist/zonos-elements/{p-328b7f6f.system.entry.js → p-50460bf4.system.entry.js} +1 -1
  162. package/dist/zonos-elements/{p-a3cc0f84.entry.js → p-55cbb4cd.entry.js} +1 -1
  163. package/dist/zonos-elements/{p-745cd869.system.entry.js → p-56318a1f.system.entry.js} +1 -1
  164. package/dist/zonos-elements/{p-f7c36fcc.entry.js → p-58a25a6a.entry.js} +1 -1
  165. package/dist/zonos-elements/{p-389599d3.system.entry.js → p-5d73cde0.system.entry.js} +1 -1
  166. package/dist/zonos-elements/{p-857cfe35.entry.js → p-6d2ba24a.entry.js} +1 -1
  167. package/dist/zonos-elements/p-6dc7222d.js +1 -0
  168. package/dist/zonos-elements/{p-ac0a7b8f.entry.js → p-701d0fef.entry.js} +1 -1
  169. package/dist/zonos-elements/{p-49f6a985.system.js → p-75490d7c.system.js} +1 -1
  170. package/dist/zonos-elements/{p-165d469e.system.entry.js → p-7736198d.system.entry.js} +1 -1
  171. package/dist/zonos-elements/{p-69e2c59e.entry.js → p-780ab968.entry.js} +1 -1
  172. package/dist/zonos-elements/{p-7f4f45b3.entry.js → p-7da1d7da.entry.js} +1 -1
  173. package/dist/zonos-elements/{p-1119dddf.system.entry.js → p-824882ce.system.entry.js} +1 -1
  174. package/dist/zonos-elements/p-86fe18ea.system.entry.js +1 -0
  175. package/dist/zonos-elements/{p-91797d4e.system.js → p-95dee6f4.system.js} +1 -1
  176. package/dist/zonos-elements/{p-279d1c5f.entry.js → p-96e2cde7.entry.js} +1 -1
  177. package/dist/zonos-elements/p-9a9902ca.entry.js +1 -0
  178. package/dist/zonos-elements/p-9cdc6b5f.js +1 -0
  179. package/dist/zonos-elements/{p-61e5cf29.system.entry.js → p-af946fb3.system.entry.js} +1 -1
  180. package/dist/zonos-elements/{p-b4725505.system.js → p-c476a347.system.js} +1 -1
  181. package/dist/zonos-elements/p-c97cb066.system.entry.js +1 -0
  182. package/dist/zonos-elements/p-cbc7edb4.entry.js +1 -0
  183. package/dist/zonos-elements/{p-17e87be1.entry.js → p-d427adf2.entry.js} +1 -1
  184. package/dist/zonos-elements/{p-5c176b23.system.entry.js → p-d93d74c1.system.entry.js} +1 -1
  185. package/dist/zonos-elements/{p-9e6b489d.system.entry.js → p-d9ba11cf.system.entry.js} +1 -1
  186. package/dist/zonos-elements/{p-dd9e8589.entry.js → p-e043e830.entry.js} +1 -1
  187. package/dist/zonos-elements/{p-7c45ce37.system.entry.js → p-e28d648c.system.entry.js} +1 -1
  188. package/dist/zonos-elements/{p-95e0fc06.js → p-e71fbec9.js} +1 -1
  189. package/dist/zonos-elements/{p-799d8a17.system.entry.js → p-e76069cc.system.entry.js} +1 -1
  190. package/dist/zonos-elements/{p-5f4ba44c.entry.js → p-fc0a051b.entry.js} +1 -1
  191. package/dist/zonos-elements/zonos-elements.esm.js +1 -1
  192. package/package.json +1 -1
  193. package/dist/esm-es5/cart-e261efc1.js +0 -1
  194. package/dist/zonos-elements/p-0c0aa552.js +0 -1
  195. package/dist/zonos-elements/p-3b23e462.entry.js +0 -1
  196. package/dist/zonos-elements/p-5496951a.system.js +0 -1
  197. package/dist/zonos-elements/p-5d9a000a.system.entry.js +0 -1
  198. package/dist/zonos-elements/p-79b24786.system.entry.js +0 -1
  199. package/dist/zonos-elements/p-7b87b82f.js +0 -1
  200. package/dist/zonos-elements/p-9f4e02a1.entry.js +0 -1
  201. package/dist/zonos-elements/p-da767f8b.js +0 -1
  202. package/dist/zonos-elements/p-f11a3d9e.entry.js +0 -1
@@ -1 +1 @@
1
- (function(){"use strict";const e=(e,t,...n)=>{var o,r;if(!(!!(null===(o=window.Zonos)||void 0===o?void 0:o.debug)||!!window.location.search.match(/\?.*(&*)zonosDebug=1/)))return void("error"===t&&console.error(e,...n));let s=document.querySelector("iframe#zonos---debug-logging-iframe");s||(s=document.createElement("iframe"),s.id="zonos---debug-logging-iframe",s.style.display="none",s.style.opacity="0",s.style.position="absolute",s.style.top="-9999px",s.style.left="-9999px",s.style.width="1px",s.style.height="1px",s.style.border="none",s.style.overflow="hidden",s.style.visibility="hidden",document.body.appendChild(s));const i=(null===(r=s.contentWindow)||void 0===r?void 0:r.window.console)||window.console;switch(t){case"warn":i.warn(e,...n);break;case"info":i.info(e,...n);break;case"error":i.error(e,...n);break;default:i.groupCollapsed(e,...n),i.trace(),i.groupEnd()}},t=(t,...n)=>{e(t,"error",...n)},n="https://js.stripe.com/v3",o=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,r="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used";let s=null;const i=e=>(null!==s||(s=new Promise(((s,i)=>{if("undefined"!=typeof window&&"undefined"!=typeof document)if(window.Stripe&&e&&console.warn(r),window.Stripe)s(window.Stripe);else try{let l=(()=>{const e=document.querySelectorAll(`script[src^="${n}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&o.test(n.src))return n}return null})();l&&e?console.warn(r):l||(l=(e=>{const o=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",r=document.createElement("script");r.src=`${n}${o}`;const s=document.head||document.body;return s?(s.appendChild(r),r):(t("Expected document.body not to be null. Stripe.js requires a <body> element."),null)})(e)),null==l||l.addEventListener("load",(()=>{window.Stripe?s(window.Stripe):i(new Error("Stripe.js not available"))})),null==l||l.addEventListener("error",(()=>{i(new Error("Failed to load Stripe.js"))}))}catch(e){return void i(e)}else s(null)}))),s),l=Promise.resolve().then((()=>i(null)));let c=!1;l.catch((e=>{c||console.warn(e)}));var d;const a=(()=>{const e=document.querySelector('script[src*="/zonos.js"]'),{currentLoadScriptUrl:t,isWhiteListed:n}=(({loadScriptSrc:e})=>{if(!e)return{currentLoadScriptUrl:"",isForceLoadVersionDomain:!1,isWhiteListed:!1};const t=new URL(e).origin,n=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"].some((e=>t.includes(e))),o=["qa.js.zonos.com"].some((e=>t.includes(e)));return{currentLoadScriptUrl:t,isForceLoadVersionDomain:o,isWhiteListed:n}})({loadScriptSrc:null==e?void 0:e.src});return n?t:null})()||"https://v1.3.8-alpha.0.js.zonos.com",u="https://unpkg.com/@zonos/elements@1.3.8-alpha.0",m="https://rsms.me",p="https://fonts.googleapis.com",h=/^https:\/\/rsms\.me\/inter\/inter\.css(.*)$/;class y{}d=y,y.doneInit=!1,y.debug=!!window.location.search.match(/\?.*(&*)zonosDebug=1/),y.isBigCommerce=!1,y.internationalHideSelector="",y.zonosQaUrl=null,y.version="v1.3.8-alpha.0",y.modeAlerted=!1,y.getCurrentTimestamp=()=>(new Date).getTime(),y.zonosController=null,y.init=async({appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s,storeId:i,zonosApiKey:l})=>{d.doneInit||(e(`====== ZONOS DEBUG MODE: on (${d.version}) ======`),l?(d.zonosApiKey=l,d.storeId=i,e("init zonos"),d.injectSentryScript(),d.injectZonosCdn(),d.injectZonosCss(),d.injectFonts(),d.injectController({config:{appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s},zonosApiKey:l}),d.doneInit=!0):t("Missing Zonos API key"))},y.displayCurrency=()=>{const e=document.querySelector("zonos-hello");e&&e.displayCurrency()},y.openHelloDialog=e=>{const t=document.querySelector("zonos-hello");t&&t.openHelloDialog(null==e||e)},y.showNotification=e=>{var t;null===(t=d.zonosController)||void 0===t||t.showNotification(e)},y.updateOrganizationName=e=>{var t;null===(t=d.zonosController)||void 0===t||t.updateOrganizationName(e)},y.disablePlaceOrderButtons=({autoEnable:e=!0,disable:t,placeOrderButtonSelector:n})=>{if(n){const o=document.querySelectorAll(n),r=e=>{e.target.getAttribute("disabled")&&(e.preventDefault(),e.stopPropagation())};o.forEach((e=>{e.getAttribute("data-zonos-checkout-attached")||(t?(e.setAttribute("disabled","true"),e.addEventListener("click",r)):(e.removeAttribute("disabled"),e.removeEventListener("click",r)))})),e&&t&&setTimeout((()=>{o.forEach((e=>{e.removeAttribute("disabled"),e.removeEventListener("click",r)}))}),5e3)}},y.injectController=({config:n,zonosApiKey:o})=>{var r;if(document.querySelector("zonos-controller"))return;if(null===(r=n.checkoutSettings)||void 0===r?void 0:r.placeOrderButtonSelector){const e=n.checkoutSettings.placeOrderButtonSelector;d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e});new MutationObserver((()=>{d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e})})).observe(document.body,{childList:!0,subtree:!0})}const s=document.createElement("zonos-controller");s.config=n,s.zonosApiKey=o,s.addEventListener("stripeInitEvent",(async n=>{const{detail:o}=n;e("loading Stripe");const r=await(async(...e)=>{c=!0;const t=Date.now();return l.then((n=>((e,t,n)=>{if(null===e)return null;const o=e.apply(void 0,t);return((e,t)=>{e&&e._registerWrapper&&e._registerWrapper({name:"stripe-js",startTime:t})})(o,n),o})(n,e,t)))})(o.publishableKey);r?(window.Zonos.stripe=r,s.initCheckoutElement(r)):t("API seems to be invalid or missing. Failed to load Stripe")})),document.body.appendChild(s),d.zonosController=s,e("Zonos controller injected!")},y.injectSentryScript=()=>{const n="https://browser.sentry-cdn.com/7.88.0/bundle.tracing.min.js";if(document.querySelector(`script[src="${n}"]`))return void e("Sentry script already exists in the document","warn");const o=document.head||document.body,r=document.createElement("script");r.crossOrigin="anonymous",r.src=n,r.integrity="sha384-z/aQww1Fr6Mes0MO/2wlzQd2nXBCdDcKPXDTsMDMNPgTGRPqii3a4bzH79I+Vo8l",r.setAttribute("data-lazy","no"),r.onerror=()=>{t(`Failed to load ${r.src}`)},r.onload=()=>{var e;null===(e=window.Sentry)||void 0===e||e.init({allowUrls:[/js.zonos.com/],dsn:"https://19168bd05af0e2e0e7520ad58953e4f2@o446983.ingest.sentry.io/4506400622837760",release:`zonos-elements@${d.version}`})},o.appendChild(r)},y.injectScript=({fallBackDomain:n,isModule:o,scriptDomain:r,theRestUrl:s})=>{const i=`${r}/${s}`;if(document.querySelector(`script[src="${i}"]`))return void e(`Zonos script "${i}" already exists in the document`,"warn");const l=document.head||document.body,c=document.createElement("script");o?c.type="module":c.noModule=!0,c.src=i,c.crossOrigin="anonymous",c.onerror=()=>{/\/\/v\d+\./g.test(r)?(n&&d.injectScript({isModule:o,scriptDomain:n,theRestUrl:s}),t(`Failed to load ${c.src}`)):e("No need to fallback since this is not a versioned domain","warn")},l.appendChild(c)},y.injectZonosCdn=()=>{d.injectScript({fallBackDomain:u,isModule:!0,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.esm.js"}),d.injectScript({fallBackDomain:u,isModule:!1,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.js"}),e("Zonos cdn script injected!")},y.injectStylesheet=({fallBackDomain:n,stylesheetDomain:o,theRestUrl:r})=>{const s=document.head||document.body,i=document.createElement("link");i.rel="preconnect",i.href=`${a}/`,s.appendChild(i);const l=document.createElement("link");l.rel="stylesheet",l.href=`${o}/${r}`,l.onerror=()=>{const s=/\/\/v\d+\./g.test(o);s?(n&&s&&d.injectStylesheet({stylesheetDomain:n,theRestUrl:r}),t(`Failed to load ${l.href}`)):e("No need to fallback since this is not a versioned domain","warn")},s.appendChild(l)},y.injectZonosCss=()=>{document.querySelector('link[rel="stylesheet"][href*="/dist/zonos-elements/zonos-elements.css"]')?e("Zonos style links already injected","warn"):(d.injectStylesheet({fallBackDomain:u,stylesheetDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.css"}),e("Zonos style css injected!"))},y.injectFonts=()=>{if((()=>{const e=document.querySelectorAll(`link[rel="stylesheet"][href^="${m}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&!h.test(n.href))return n}return null})())return void e("Inter font already injected","warn");const t=document.head||document.body,n=document.createElement("link");n.rel="preconnect",n.href=m,t.appendChild(n);const o=document.createElement("link");o.rel="stylesheet",o.href=`${m}/inter/inter.css`,t.appendChild(o),e("Zonos font injected!")},y.setupGoogleFont=e=>{var t;null===(t=d.zonosController)||void 0===t||t.setupGoogleFont(e)},y.injectSupportGoogleFont=t=>{var n;e(`[FONT] injecting ${t}`);const o=null===(n=t.match(/family=(.*?):/))||void 0===n?void 0:n[1],r=document.head||document.body;if(!document.querySelector(`link[rel="preconnect"][href^="${p}"]`)){const e=document.createElement("link");e.rel="preconnect",e.href=p,r.appendChild(e)}if(document.querySelector(`link[rel="stylesheet"][href="${t}"]`))return void e(`[FONT] ${o} font already injected`,"warn");const s=document.createElement("link");s.rel="stylesheet",s.href=t,r.appendChild(s),e(`[FONT] ${o} font injected!`)},window.Zonos=y})();
1
+ (function(){"use strict";const e=(e,t,...n)=>{var o,r;if(!(!!(null===(o=window.Zonos)||void 0===o?void 0:o.debug)||!!window.location.search.match(/\?.*(&*)zonosDebug=1/)))return void("error"===t&&console.error(e,...n));let s=document.querySelector("iframe#zonos---debug-logging-iframe");s||(s=document.createElement("iframe"),s.id="zonos---debug-logging-iframe",s.style.display="none",s.style.opacity="0",s.style.position="absolute",s.style.top="-9999px",s.style.left="-9999px",s.style.width="1px",s.style.height="1px",s.style.border="none",s.style.overflow="hidden",s.style.visibility="hidden",document.body.appendChild(s));const i=(null===(r=s.contentWindow)||void 0===r?void 0:r.window.console)||window.console;switch(t){case"warn":i.warn(e,...n);break;case"info":i.info(e,...n);break;case"error":i.error(e,...n);break;default:i.groupCollapsed(e,...n),i.trace(),i.groupEnd()}},t=(t,...n)=>{e(t,"error",...n)},n="https://js.stripe.com/v3",o=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,r="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used";let s=null;const i=e=>(null!==s||(s=new Promise(((s,i)=>{if("undefined"!=typeof window&&"undefined"!=typeof document)if(window.Stripe&&e&&console.warn(r),window.Stripe)s(window.Stripe);else try{let l=(()=>{const e=document.querySelectorAll(`script[src^="${n}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&o.test(n.src))return n}return null})();l&&e?console.warn(r):l||(l=(e=>{const o=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",r=document.createElement("script");r.src=`${n}${o}`;const s=document.head||document.body;return s?(s.appendChild(r),r):(t("Expected document.body not to be null. Stripe.js requires a <body> element."),null)})(e)),null==l||l.addEventListener("load",(()=>{window.Stripe?s(window.Stripe):i(new Error("Stripe.js not available"))})),null==l||l.addEventListener("error",(()=>{i(new Error("Failed to load Stripe.js"))}))}catch(e){return void i(e)}else s(null)}))),s),l=Promise.resolve().then((()=>i(null)));let c=!1;l.catch((e=>{c||console.warn(e)}));var d;const a=(()=>{const e=document.querySelector('script[src*="/zonos.js"]'),{currentLoadScriptUrl:t,isWhiteListed:n}=(({loadScriptSrc:e})=>{if(!e)return{currentLoadScriptUrl:"",isForceLoadVersionDomain:!1,isWhiteListed:!1};const t=new URL(e).origin,n=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"].some((e=>t.includes(e))),o=["qa.js.zonos.com"].some((e=>t.includes(e)));return{currentLoadScriptUrl:t,isForceLoadVersionDomain:o,isWhiteListed:n}})({loadScriptSrc:null==e?void 0:e.src});return n?t:null})()||"https://v1.3.8-alpha.1.js.zonos.com",u="https://unpkg.com/@zonos/elements@1.3.8-alpha.1",m="https://rsms.me",p="https://fonts.googleapis.com",h=/^https:\/\/rsms\.me\/inter\/inter\.css(.*)$/;class y{}d=y,y.doneInit=!1,y.debug=!!window.location.search.match(/\?.*(&*)zonosDebug=1/),y.isBigCommerce=!1,y.internationalHideSelector="",y.zonosQaUrl=null,y.version="v1.3.8-alpha.1",y.modeAlerted=!1,y.getCurrentTimestamp=()=>(new Date).getTime(),y.zonosController=null,y.init=async({appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s,storeId:i,zonosApiKey:l})=>{d.doneInit||(e(`====== ZONOS DEBUG MODE: on (${d.version}) ======`),l?(d.zonosApiKey=l,d.storeId=i,e("init zonos"),d.injectSentryScript(),d.injectZonosCdn(),d.injectZonosCss(),d.injectFonts(),d.injectController({config:{appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s},zonosApiKey:l}),d.doneInit=!0):t("Missing Zonos API key"))},y.displayCurrency=()=>{const e=document.querySelector("zonos-hello");e&&e.displayCurrency()},y.openHelloDialog=e=>{const t=document.querySelector("zonos-hello");t&&t.openHelloDialog(null==e||e)},y.showNotification=e=>{var t;null===(t=d.zonosController)||void 0===t||t.showNotification(e)},y.updateOrganizationName=e=>{var t;null===(t=d.zonosController)||void 0===t||t.updateOrganizationName(e)},y.disablePlaceOrderButtons=({autoEnable:e=!0,disable:t,placeOrderButtonSelector:n})=>{if(n){const o=document.querySelectorAll(n),r=e=>{e.target.getAttribute("disabled")&&(e.preventDefault(),e.stopPropagation())};o.forEach((e=>{e.getAttribute("data-zonos-checkout-attached")||(t?(e.setAttribute("disabled","true"),e.addEventListener("click",r)):(e.removeAttribute("disabled"),e.removeEventListener("click",r)))})),e&&t&&setTimeout((()=>{o.forEach((e=>{e.removeAttribute("disabled"),e.removeEventListener("click",r)}))}),5e3)}},y.injectController=({config:n,zonosApiKey:o})=>{var r;if(document.querySelector("zonos-controller"))return;if(null===(r=n.checkoutSettings)||void 0===r?void 0:r.placeOrderButtonSelector){const e=n.checkoutSettings.placeOrderButtonSelector;d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e});new MutationObserver((()=>{d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e})})).observe(document.body,{childList:!0,subtree:!0})}const s=document.createElement("zonos-controller");s.config=n,s.zonosApiKey=o,s.addEventListener("stripeInitEvent",(async n=>{const{detail:o}=n;e("loading Stripe");const r=await(async(...e)=>{c=!0;const t=Date.now();return l.then((n=>((e,t,n)=>{if(null===e)return null;const o=e.apply(void 0,t);return((e,t)=>{e&&e._registerWrapper&&e._registerWrapper({name:"stripe-js",startTime:t})})(o,n),o})(n,e,t)))})(o.publishableKey);r?(window.Zonos.stripe=r,s.initCheckoutElement(r)):t("API seems to be invalid or missing. Failed to load Stripe")})),document.body.appendChild(s),d.zonosController=s,e("Zonos controller injected!")},y.injectSentryScript=()=>{const n="https://browser.sentry-cdn.com/7.88.0/bundle.tracing.min.js";if(document.querySelector(`script[src="${n}"]`))return void e("Sentry script already exists in the document","warn");const o=document.head||document.body,r=document.createElement("script");r.crossOrigin="anonymous",r.src=n,r.integrity="sha384-z/aQww1Fr6Mes0MO/2wlzQd2nXBCdDcKPXDTsMDMNPgTGRPqii3a4bzH79I+Vo8l",r.setAttribute("data-lazy","no"),r.onerror=()=>{t(`Failed to load ${r.src}`)},r.onload=()=>{var e;null===(e=window.Sentry)||void 0===e||e.init({allowUrls:[/js.zonos.com/],dsn:"https://19168bd05af0e2e0e7520ad58953e4f2@o446983.ingest.sentry.io/4506400622837760",release:`zonos-elements@${d.version}`})},o.appendChild(r)},y.injectScript=({fallBackDomain:n,isModule:o,scriptDomain:r,theRestUrl:s})=>{const i=`${r}/${s}`;if(document.querySelector(`script[src="${i}"]`))return void e(`Zonos script "${i}" already exists in the document`,"warn");const l=document.head||document.body,c=document.createElement("script");o?c.type="module":c.noModule=!0,c.src=i,c.crossOrigin="anonymous",c.onerror=()=>{/\/\/v\d+\./g.test(r)?(n&&d.injectScript({isModule:o,scriptDomain:n,theRestUrl:s}),t(`Failed to load ${c.src}`)):e("No need to fallback since this is not a versioned domain","warn")},l.appendChild(c)},y.injectZonosCdn=()=>{d.injectScript({fallBackDomain:u,isModule:!0,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.esm.js"}),d.injectScript({fallBackDomain:u,isModule:!1,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.js"}),e("Zonos cdn script injected!")},y.injectStylesheet=({fallBackDomain:n,stylesheetDomain:o,theRestUrl:r})=>{const s=document.head||document.body,i=document.createElement("link");i.rel="preconnect",i.href=`${a}/`,s.appendChild(i);const l=document.createElement("link");l.rel="stylesheet",l.href=`${o}/${r}`,l.onerror=()=>{const s=/\/\/v\d+\./g.test(o);s?(n&&s&&d.injectStylesheet({stylesheetDomain:n,theRestUrl:r}),t(`Failed to load ${l.href}`)):e("No need to fallback since this is not a versioned domain","warn")},s.appendChild(l)},y.injectZonosCss=()=>{document.querySelector('link[rel="stylesheet"][href*="/dist/zonos-elements/zonos-elements.css"]')?e("Zonos style links already injected","warn"):(d.injectStylesheet({fallBackDomain:u,stylesheetDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.css"}),e("Zonos style css injected!"))},y.injectFonts=()=>{if((()=>{const e=document.querySelectorAll(`link[rel="stylesheet"][href^="${m}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&!h.test(n.href))return n}return null})())return void e("Inter font already injected","warn");const t=document.head||document.body,n=document.createElement("link");n.rel="preconnect",n.href=m,t.appendChild(n);const o=document.createElement("link");o.rel="stylesheet",o.href=`${m}/inter/inter.css`,t.appendChild(o),e("Zonos font injected!")},y.setupGoogleFont=e=>{var t;null===(t=d.zonosController)||void 0===t||t.setupGoogleFont(e)},y.injectSupportGoogleFont=t=>{var n;e(`[FONT] injecting ${t}`);const o=null===(n=t.match(/family=(.*?):/))||void 0===n?void 0:n[1],r=document.head||document.body;if(!document.querySelector(`link[rel="preconnect"][href^="${p}"]`)){const e=document.createElement("link");e.rel="preconnect",e.href=p,r.appendChild(e)}if(document.querySelector(`link[rel="stylesheet"][href="${t}"]`))return void e(`[FONT] ${o} font already injected`,"warn");const s=document.createElement("link");s.rel="stylesheet",s.href=t,r.appendChild(s),e(`[FONT] ${o} font injected!`)},window.Zonos=y})();
@@ -1 +1 @@
1
- (function(){"use strict";const e=(e,t,...n)=>{var o,r;if(!(!!(null===(o=window.Zonos)||void 0===o?void 0:o.debug)||!!window.location.search.match(/\?.*(&*)zonosDebug=1/)))return void("error"===t&&console.error(e,...n));let s=document.querySelector("iframe#zonos---debug-logging-iframe");s||(s=document.createElement("iframe"),s.id="zonos---debug-logging-iframe",s.style.display="none",s.style.opacity="0",s.style.position="absolute",s.style.top="-9999px",s.style.left="-9999px",s.style.width="1px",s.style.height="1px",s.style.border="none",s.style.overflow="hidden",s.style.visibility="hidden",document.body.appendChild(s));const i=(null===(r=s.contentWindow)||void 0===r?void 0:r.window.console)||window.console;switch(t){case"warn":i.warn(e,...n);break;case"info":i.info(e,...n);break;case"error":i.error(e,...n);break;default:i.groupCollapsed(e,...n),i.trace(),i.groupEnd()}},t=(t,...n)=>{e(t,"error",...n)},n="https://js.stripe.com/v3",o=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,r="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used";let s=null;const i=e=>(null!==s||(s=new Promise(((s,i)=>{if("undefined"!=typeof window&&"undefined"!=typeof document)if(window.Stripe&&e&&console.warn(r),window.Stripe)s(window.Stripe);else try{let l=(()=>{const e=document.querySelectorAll(`script[src^="${n}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&o.test(n.src))return n}return null})();l&&e?console.warn(r):l||(l=(e=>{const o=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",r=document.createElement("script");r.src=`${n}${o}`;const s=document.head||document.body;return s?(s.appendChild(r),r):(t("Expected document.body not to be null. Stripe.js requires a <body> element."),null)})(e)),null==l||l.addEventListener("load",(()=>{window.Stripe?s(window.Stripe):i(new Error("Stripe.js not available"))})),null==l||l.addEventListener("error",(()=>{i(new Error("Failed to load Stripe.js"))}))}catch(e){return void i(e)}else s(null)}))),s),l=Promise.resolve().then((()=>i(null)));let c=!1;l.catch((e=>{c||console.warn(e)}));var d;const a=(()=>{const e=document.querySelector('script[src*="/zonos.js"]'),{currentLoadScriptUrl:t,isWhiteListed:n}=(({loadScriptSrc:e})=>{if(!e)return{currentLoadScriptUrl:"",isForceLoadVersionDomain:!1,isWhiteListed:!1};const t=new URL(e).origin,n=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"].some((e=>t.includes(e))),o=["qa.js.zonos.com"].some((e=>t.includes(e)));return{currentLoadScriptUrl:t,isForceLoadVersionDomain:o,isWhiteListed:n}})({loadScriptSrc:null==e?void 0:e.src});return n?t:null})()||"https://v1.3.8-alpha.0.js.zonos.com",u="https://unpkg.com/@zonos/elements@1.3.8-alpha.0",m="https://rsms.me",p="https://fonts.googleapis.com",h=/^https:\/\/rsms\.me\/inter\/inter\.css(.*)$/;class y{}d=y,y.doneInit=!1,y.debug=!!window.location.search.match(/\?.*(&*)zonosDebug=1/),y.isBigCommerce=!1,y.internationalHideSelector="",y.zonosQaUrl=null,y.version="v1.3.8-alpha.0",y.modeAlerted=!1,y.getCurrentTimestamp=()=>(new Date).getTime(),y.zonosController=null,y.init=async({appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s,storeId:i,zonosApiKey:l})=>{d.doneInit||(e(`====== ZONOS DEBUG MODE: on (${d.version}) ======`),l?(d.zonosApiKey=l,d.storeId=i,e("init zonos"),d.injectSentryScript(),d.injectZonosCdn(),d.injectZonosCss(),d.injectFonts(),d.injectController({config:{appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s},zonosApiKey:l}),d.doneInit=!0):t("Missing Zonos API key"))},y.displayCurrency=()=>{const e=document.querySelector("zonos-hello");e&&e.displayCurrency()},y.openHelloDialog=e=>{const t=document.querySelector("zonos-hello");t&&t.openHelloDialog(null==e||e)},y.showNotification=e=>{var t;null===(t=d.zonosController)||void 0===t||t.showNotification(e)},y.updateOrganizationName=e=>{var t;null===(t=d.zonosController)||void 0===t||t.updateOrganizationName(e)},y.disablePlaceOrderButtons=({autoEnable:e=!0,disable:t,placeOrderButtonSelector:n})=>{if(n){const o=document.querySelectorAll(n),r=e=>{e.target.getAttribute("disabled")&&(e.preventDefault(),e.stopPropagation())};o.forEach((e=>{e.getAttribute("data-zonos-checkout-attached")||(t?(e.setAttribute("disabled","true"),e.addEventListener("click",r)):(e.removeAttribute("disabled"),e.removeEventListener("click",r)))})),e&&t&&setTimeout((()=>{o.forEach((e=>{e.removeAttribute("disabled"),e.removeEventListener("click",r)}))}),5e3)}},y.injectController=({config:n,zonosApiKey:o})=>{var r;if(document.querySelector("zonos-controller"))return;if(null===(r=n.checkoutSettings)||void 0===r?void 0:r.placeOrderButtonSelector){const e=n.checkoutSettings.placeOrderButtonSelector;d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e});new MutationObserver((()=>{d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e})})).observe(document.body,{childList:!0,subtree:!0})}const s=document.createElement("zonos-controller");s.config=n,s.zonosApiKey=o,s.addEventListener("stripeInitEvent",(async n=>{const{detail:o}=n;e("loading Stripe");const r=await(async(...e)=>{c=!0;const t=Date.now();return l.then((n=>((e,t,n)=>{if(null===e)return null;const o=e.apply(void 0,t);return((e,t)=>{e&&e._registerWrapper&&e._registerWrapper({name:"stripe-js",startTime:t})})(o,n),o})(n,e,t)))})(o.publishableKey);r?(window.Zonos.stripe=r,s.initCheckoutElement(r)):t("API seems to be invalid or missing. Failed to load Stripe")})),document.body.appendChild(s),d.zonosController=s,e("Zonos controller injected!")},y.injectSentryScript=()=>{const n="https://browser.sentry-cdn.com/7.88.0/bundle.tracing.min.js";if(document.querySelector(`script[src="${n}"]`))return void e("Sentry script already exists in the document","warn");const o=document.head||document.body,r=document.createElement("script");r.crossOrigin="anonymous",r.src=n,r.integrity="sha384-z/aQww1Fr6Mes0MO/2wlzQd2nXBCdDcKPXDTsMDMNPgTGRPqii3a4bzH79I+Vo8l",r.setAttribute("data-lazy","no"),r.onerror=()=>{t(`Failed to load ${r.src}`)},r.onload=()=>{var e;null===(e=window.Sentry)||void 0===e||e.init({allowUrls:[/js.zonos.com/],dsn:"https://19168bd05af0e2e0e7520ad58953e4f2@o446983.ingest.sentry.io/4506400622837760",release:`zonos-elements@${d.version}`})},o.appendChild(r)},y.injectScript=({fallBackDomain:n,isModule:o,scriptDomain:r,theRestUrl:s})=>{const i=`${r}/${s}`;if(document.querySelector(`script[src="${i}"]`))return void e(`Zonos script "${i}" already exists in the document`,"warn");const l=document.head||document.body,c=document.createElement("script");o?c.type="module":c.noModule=!0,c.src=i,c.crossOrigin="anonymous",c.onerror=()=>{/\/\/v\d+\./g.test(r)?(n&&d.injectScript({isModule:o,scriptDomain:n,theRestUrl:s}),t(`Failed to load ${c.src}`)):e("No need to fallback since this is not a versioned domain","warn")},l.appendChild(c)},y.injectZonosCdn=()=>{d.injectScript({fallBackDomain:u,isModule:!0,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.esm.js"}),d.injectScript({fallBackDomain:u,isModule:!1,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.js"}),e("Zonos cdn script injected!")},y.injectStylesheet=({fallBackDomain:n,stylesheetDomain:o,theRestUrl:r})=>{const s=document.head||document.body,i=document.createElement("link");i.rel="preconnect",i.href=`${a}/`,s.appendChild(i);const l=document.createElement("link");l.rel="stylesheet",l.href=`${o}/${r}`,l.onerror=()=>{const s=/\/\/v\d+\./g.test(o);s?(n&&s&&d.injectStylesheet({stylesheetDomain:n,theRestUrl:r}),t(`Failed to load ${l.href}`)):e("No need to fallback since this is not a versioned domain","warn")},s.appendChild(l)},y.injectZonosCss=()=>{document.querySelector('link[rel="stylesheet"][href*="/dist/zonos-elements/zonos-elements.css"]')?e("Zonos style links already injected","warn"):(d.injectStylesheet({fallBackDomain:u,stylesheetDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.css"}),e("Zonos style css injected!"))},y.injectFonts=()=>{if((()=>{const e=document.querySelectorAll(`link[rel="stylesheet"][href^="${m}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&!h.test(n.href))return n}return null})())return void e("Inter font already injected","warn");const t=document.head||document.body,n=document.createElement("link");n.rel="preconnect",n.href=m,t.appendChild(n);const o=document.createElement("link");o.rel="stylesheet",o.href=`${m}/inter/inter.css`,t.appendChild(o),e("Zonos font injected!")},y.setupGoogleFont=e=>{var t;null===(t=d.zonosController)||void 0===t||t.setupGoogleFont(e)},y.injectSupportGoogleFont=t=>{var n;e(`[FONT] injecting ${t}`);const o=null===(n=t.match(/family=(.*?):/))||void 0===n?void 0:n[1],r=document.head||document.body;if(!document.querySelector(`link[rel="preconnect"][href^="${p}"]`)){const e=document.createElement("link");e.rel="preconnect",e.href=p,r.appendChild(e)}if(document.querySelector(`link[rel="stylesheet"][href="${t}"]`))return void e(`[FONT] ${o} font already injected`,"warn");const s=document.createElement("link");s.rel="stylesheet",s.href=t,r.appendChild(s),e(`[FONT] ${o} font injected!`)},exports.Zonos=y})();
1
+ (function(){"use strict";const e=(e,t,...n)=>{var o,r;if(!(!!(null===(o=window.Zonos)||void 0===o?void 0:o.debug)||!!window.location.search.match(/\?.*(&*)zonosDebug=1/)))return void("error"===t&&console.error(e,...n));let s=document.querySelector("iframe#zonos---debug-logging-iframe");s||(s=document.createElement("iframe"),s.id="zonos---debug-logging-iframe",s.style.display="none",s.style.opacity="0",s.style.position="absolute",s.style.top="-9999px",s.style.left="-9999px",s.style.width="1px",s.style.height="1px",s.style.border="none",s.style.overflow="hidden",s.style.visibility="hidden",document.body.appendChild(s));const i=(null===(r=s.contentWindow)||void 0===r?void 0:r.window.console)||window.console;switch(t){case"warn":i.warn(e,...n);break;case"info":i.info(e,...n);break;case"error":i.error(e,...n);break;default:i.groupCollapsed(e,...n),i.trace(),i.groupEnd()}},t=(t,...n)=>{e(t,"error",...n)},n="https://js.stripe.com/v3",o=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,r="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used";let s=null;const i=e=>(null!==s||(s=new Promise(((s,i)=>{if("undefined"!=typeof window&&"undefined"!=typeof document)if(window.Stripe&&e&&console.warn(r),window.Stripe)s(window.Stripe);else try{let l=(()=>{const e=document.querySelectorAll(`script[src^="${n}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&o.test(n.src))return n}return null})();l&&e?console.warn(r):l||(l=(e=>{const o=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",r=document.createElement("script");r.src=`${n}${o}`;const s=document.head||document.body;return s?(s.appendChild(r),r):(t("Expected document.body not to be null. Stripe.js requires a <body> element."),null)})(e)),null==l||l.addEventListener("load",(()=>{window.Stripe?s(window.Stripe):i(new Error("Stripe.js not available"))})),null==l||l.addEventListener("error",(()=>{i(new Error("Failed to load Stripe.js"))}))}catch(e){return void i(e)}else s(null)}))),s),l=Promise.resolve().then((()=>i(null)));let c=!1;l.catch((e=>{c||console.warn(e)}));var d;const a=(()=>{const e=document.querySelector('script[src*="/zonos.js"]'),{currentLoadScriptUrl:t,isWhiteListed:n}=(({loadScriptSrc:e})=>{if(!e)return{currentLoadScriptUrl:"",isForceLoadVersionDomain:!1,isWhiteListed:!1};const t=new URL(e).origin,n=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"].some((e=>t.includes(e))),o=["qa.js.zonos.com"].some((e=>t.includes(e)));return{currentLoadScriptUrl:t,isForceLoadVersionDomain:o,isWhiteListed:n}})({loadScriptSrc:null==e?void 0:e.src});return n?t:null})()||"https://v1.3.8-alpha.1.js.zonos.com",u="https://unpkg.com/@zonos/elements@1.3.8-alpha.1",m="https://rsms.me",p="https://fonts.googleapis.com",h=/^https:\/\/rsms\.me\/inter\/inter\.css(.*)$/;class y{}d=y,y.doneInit=!1,y.debug=!!window.location.search.match(/\?.*(&*)zonosDebug=1/),y.isBigCommerce=!1,y.internationalHideSelector="",y.zonosQaUrl=null,y.version="v1.3.8-alpha.1",y.modeAlerted=!1,y.getCurrentTimestamp=()=>(new Date).getTime(),y.zonosController=null,y.init=async({appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s,storeId:i,zonosApiKey:l})=>{d.doneInit||(e(`====== ZONOS DEBUG MODE: on (${d.version}) ======`),l?(d.zonosApiKey=l,d.storeId=i,e("init zonos"),d.injectSentryScript(),d.injectZonosCdn(),d.injectZonosCss(),d.injectFonts(),d.injectController({config:{appearance:n,checkoutSettings:o,currencyConverter:r,helloSettings:s},zonosApiKey:l}),d.doneInit=!0):t("Missing Zonos API key"))},y.displayCurrency=()=>{const e=document.querySelector("zonos-hello");e&&e.displayCurrency()},y.openHelloDialog=e=>{const t=document.querySelector("zonos-hello");t&&t.openHelloDialog(null==e||e)},y.showNotification=e=>{var t;null===(t=d.zonosController)||void 0===t||t.showNotification(e)},y.updateOrganizationName=e=>{var t;null===(t=d.zonosController)||void 0===t||t.updateOrganizationName(e)},y.disablePlaceOrderButtons=({autoEnable:e=!0,disable:t,placeOrderButtonSelector:n})=>{if(n){const o=document.querySelectorAll(n),r=e=>{e.target.getAttribute("disabled")&&(e.preventDefault(),e.stopPropagation())};o.forEach((e=>{e.getAttribute("data-zonos-checkout-attached")||(t?(e.setAttribute("disabled","true"),e.addEventListener("click",r)):(e.removeAttribute("disabled"),e.removeEventListener("click",r)))})),e&&t&&setTimeout((()=>{o.forEach((e=>{e.removeAttribute("disabled"),e.removeEventListener("click",r)}))}),5e3)}},y.injectController=({config:n,zonosApiKey:o})=>{var r;if(document.querySelector("zonos-controller"))return;if(null===(r=n.checkoutSettings)||void 0===r?void 0:r.placeOrderButtonSelector){const e=n.checkoutSettings.placeOrderButtonSelector;d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e});new MutationObserver((()=>{d.disablePlaceOrderButtons({disable:!0,placeOrderButtonSelector:e})})).observe(document.body,{childList:!0,subtree:!0})}const s=document.createElement("zonos-controller");s.config=n,s.zonosApiKey=o,s.addEventListener("stripeInitEvent",(async n=>{const{detail:o}=n;e("loading Stripe");const r=await(async(...e)=>{c=!0;const t=Date.now();return l.then((n=>((e,t,n)=>{if(null===e)return null;const o=e.apply(void 0,t);return((e,t)=>{e&&e._registerWrapper&&e._registerWrapper({name:"stripe-js",startTime:t})})(o,n),o})(n,e,t)))})(o.publishableKey);r?(window.Zonos.stripe=r,s.initCheckoutElement(r)):t("API seems to be invalid or missing. Failed to load Stripe")})),document.body.appendChild(s),d.zonosController=s,e("Zonos controller injected!")},y.injectSentryScript=()=>{const n="https://browser.sentry-cdn.com/7.88.0/bundle.tracing.min.js";if(document.querySelector(`script[src="${n}"]`))return void e("Sentry script already exists in the document","warn");const o=document.head||document.body,r=document.createElement("script");r.crossOrigin="anonymous",r.src=n,r.integrity="sha384-z/aQww1Fr6Mes0MO/2wlzQd2nXBCdDcKPXDTsMDMNPgTGRPqii3a4bzH79I+Vo8l",r.setAttribute("data-lazy","no"),r.onerror=()=>{t(`Failed to load ${r.src}`)},r.onload=()=>{var e;null===(e=window.Sentry)||void 0===e||e.init({allowUrls:[/js.zonos.com/],dsn:"https://19168bd05af0e2e0e7520ad58953e4f2@o446983.ingest.sentry.io/4506400622837760",release:`zonos-elements@${d.version}`})},o.appendChild(r)},y.injectScript=({fallBackDomain:n,isModule:o,scriptDomain:r,theRestUrl:s})=>{const i=`${r}/${s}`;if(document.querySelector(`script[src="${i}"]`))return void e(`Zonos script "${i}" already exists in the document`,"warn");const l=document.head||document.body,c=document.createElement("script");o?c.type="module":c.noModule=!0,c.src=i,c.crossOrigin="anonymous",c.onerror=()=>{/\/\/v\d+\./g.test(r)?(n&&d.injectScript({isModule:o,scriptDomain:n,theRestUrl:s}),t(`Failed to load ${c.src}`)):e("No need to fallback since this is not a versioned domain","warn")},l.appendChild(c)},y.injectZonosCdn=()=>{d.injectScript({fallBackDomain:u,isModule:!0,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.esm.js"}),d.injectScript({fallBackDomain:u,isModule:!1,scriptDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.js"}),e("Zonos cdn script injected!")},y.injectStylesheet=({fallBackDomain:n,stylesheetDomain:o,theRestUrl:r})=>{const s=document.head||document.body,i=document.createElement("link");i.rel="preconnect",i.href=`${a}/`,s.appendChild(i);const l=document.createElement("link");l.rel="stylesheet",l.href=`${o}/${r}`,l.onerror=()=>{const s=/\/\/v\d+\./g.test(o);s?(n&&s&&d.injectStylesheet({stylesheetDomain:n,theRestUrl:r}),t(`Failed to load ${l.href}`)):e("No need to fallback since this is not a versioned domain","warn")},s.appendChild(l)},y.injectZonosCss=()=>{document.querySelector('link[rel="stylesheet"][href*="/dist/zonos-elements/zonos-elements.css"]')?e("Zonos style links already injected","warn"):(d.injectStylesheet({fallBackDomain:u,stylesheetDomain:a,theRestUrl:"dist/zonos-elements/zonos-elements.css"}),e("Zonos style css injected!"))},y.injectFonts=()=>{if((()=>{const e=document.querySelectorAll(`link[rel="stylesheet"][href^="${m}"]`);for(let t=0;t<e.length;t++){const n=e[t];if(n&&!h.test(n.href))return n}return null})())return void e("Inter font already injected","warn");const t=document.head||document.body,n=document.createElement("link");n.rel="preconnect",n.href=m,t.appendChild(n);const o=document.createElement("link");o.rel="stylesheet",o.href=`${m}/inter/inter.css`,t.appendChild(o),e("Zonos font injected!")},y.setupGoogleFont=e=>{var t;null===(t=d.zonosController)||void 0===t||t.setupGoogleFont(e)},y.injectSupportGoogleFont=t=>{var n;e(`[FONT] injecting ${t}`);const o=null===(n=t.match(/family=(.*?):/))||void 0===n?void 0:n[1],r=document.head||document.body;if(!document.querySelector(`link[rel="preconnect"][href^="${p}"]`)){const e=document.createElement("link");e.rel="preconnect",e.href=p,r.appendChild(e)}if(document.querySelector(`link[rel="stylesheet"][href="${t}"]`))return void e(`[FONT] ${o} font already injected`,"warn");const s=document.createElement("link");s.rel="stylesheet",s.href=t,r.appendChild(s),e(`[FONT] ${o} font injected!`)},exports.Zonos=y})();
@@ -1,6 +1,7 @@
1
1
  import { type EventEmitter } from '../../../../stencil-public-runtime';
2
2
  import { type ContactOption } from "../../../store/checkout/stripe";
3
3
  export declare class ZonosCustomerInfo {
4
+ el: HTMLZonosCustomerInfoElement;
4
5
  /**
5
6
  * Whether or not the continue button is loading
6
7
  */
@@ -26,6 +27,14 @@ export declare class ZonosCustomerInfo {
26
27
  * @default true
27
28
  */
28
29
  disabled: boolean;
30
+ /**
31
+ * Whether or not the shipping address contains invalid characters
32
+ */
33
+ hasInvalidShippingCharacters: boolean;
34
+ /**
35
+ * Whether or not the shipping address contains invalid characters
36
+ */
37
+ hasInvalidBillingCharacters: boolean;
29
38
  watchFormComplete(): void;
30
39
  /**
31
40
  * handler for continue button click
@@ -83,6 +83,9 @@ export declare const stringsArabic: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsBase: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsChinese: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsDanish: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsDutch: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsFrench: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsGerman: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsHebrew: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsIndonesian: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsItalian: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsJapanese: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsKorean: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsNorwegian: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsPolish: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsPortuguese: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsRussian: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsSpanish: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsSwedish: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsTurkish: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -83,6 +83,9 @@ export declare const stringsVietnamese: {
83
83
  "Payment processing. We'll update you when payment is received.": {
84
84
  value: string;
85
85
  };
86
+ 'Please ensure your text uses the Latin alphabet only (A-Z, a-z).': {
87
+ value: string;
88
+ };
86
89
  'Powered by': {
87
90
  value: string;
88
91
  };
@@ -1,3 +1,4 @@
1
+ import type { EventEmitter } from '../../../stencil-public-runtime';
1
2
  import type { ContactOption, Stripe } from '@stripe/stripe-js';
2
3
  export declare class ZonosAddress {
3
4
  /**
@@ -12,7 +13,12 @@ export declare class ZonosAddress {
12
13
  * Default address for stripe
13
14
  */
14
15
  defaultAddress: ContactOption | null;
16
+ /**
17
+ * Event to emit when address is not containing allowed character sets
18
+ */
19
+ invalidCharacters: EventEmitter<boolean>;
15
20
  stripe: Stripe | null;
21
+ hasInvalidCharacters: boolean;
16
22
  /**
17
23
  * Check if the address is dirty or not to scroll into view. When the component is mounted, if the data is filled with address line 1, it's considered dirty
18
24
  */
@@ -21,6 +27,7 @@ export declare class ZonosAddress {
21
27
  private getStripeAddressInstance;
22
28
  private updateAddressEventData;
23
29
  private updateAddressElement;
30
+ private checkInvalidCharacters;
24
31
  watchInitStripe(): Promise<void>;
25
32
  disconnectedCallback(): void;
26
33
  componentDidLoad(): void;
@@ -4,7 +4,7 @@ export declare const getLocaleMessages: ({ countryCode, localeTo, storeId, }: {
4
4
  localeTo?: string | undefined;
5
5
  storeId: number;
6
6
  }) => Promise<{
7
- countryCodes: string[] | null;
7
+ countryCodes: string[];
8
8
  countryCodesPageMessageLinks: {
9
9
  id: number;
10
10
  message: {
@@ -0,0 +1,16 @@
1
+ type Params = {
2
+ city: string;
3
+ country: string;
4
+ line1: string;
5
+ line2: string;
6
+ name: string;
7
+ postal_code: string;
8
+ state: string;
9
+ };
10
+ type Result = Partial<Record<keyof Params, boolean>>;
11
+ /**
12
+ * Check if the given address object contains non-latin characters
13
+ * @returns an object with the same keys as the input object, and a boolean value indicating if the value contains non-latin characters
14
+ */
15
+ export declare const containsNonLatinChars: (params: Params) => Result;
16
+ export {};
@@ -730,6 +730,10 @@ export namespace Components {
730
730
  "spacing": GridSpacing;
731
731
  }
732
732
  }
733
+ export interface ZonosAddressCustomEvent<T> extends CustomEvent<T> {
734
+ detail: T;
735
+ target: HTMLZonosAddressElement;
736
+ }
733
737
  export interface ZonosCheckboxCustomEvent<T> extends CustomEvent<T> {
734
738
  detail: T;
735
739
  target: HTMLZonosCheckboxElement;
@@ -767,7 +771,18 @@ export interface ZonosShippingRichRadioCustomEvent<T> extends CustomEvent<T> {
767
771
  target: HTMLZonosShippingRichRadioElement;
768
772
  }
769
773
  declare global {
774
+ interface HTMLZonosAddressElementEventMap {
775
+ "invalidCharacters": boolean;
776
+ }
770
777
  interface HTMLZonosAddressElement extends Components.ZonosAddress, HTMLStencilElement {
778
+ addEventListener<K extends keyof HTMLZonosAddressElementEventMap>(type: K, listener: (this: HTMLZonosAddressElement, ev: ZonosAddressCustomEvent<HTMLZonosAddressElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
779
+ addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
780
+ addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
781
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
782
+ removeEventListener<K extends keyof HTMLZonosAddressElementEventMap>(type: K, listener: (this: HTMLZonosAddressElement, ev: ZonosAddressCustomEvent<HTMLZonosAddressElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
783
+ removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
784
+ removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
785
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
771
786
  }
772
787
  var HTMLZonosAddressElement: {
773
788
  prototype: HTMLZonosAddressElement;
@@ -1141,6 +1156,10 @@ declare namespace LocalJSX {
1141
1156
  * Default address for stripe
1142
1157
  */
1143
1158
  "defaultAddress"?: ContactOption | null;
1159
+ /**
1160
+ * Event to emit when address is not containing allowed character sets
1161
+ */
1162
+ "onInvalidCharacters"?: (event: ZonosAddressCustomEvent<boolean>) => void;
1144
1163
  /**
1145
1164
  * The title text for the address element
1146
1165
  */
@@ -3,6 +3,11 @@ import type { BuildLandedCostParams, BuildLandedCostResponse } from "../../compo
3
3
  import type { AnalyticsProviderStatus, AnalyticsProviderType, CheckoutSubscriptionStatus, CheckoutSuccessBehavior, CheckoutVisibilityStatus, GetOrderQuery, NotificationActiveStatus } from "../generated/graphql.customer.types";
4
4
  export type ZonosOrder = GetOrderQuery['order'];
5
5
  export type CheckoutConfig = {
6
+ /**
7
+ * Validate address to allow specific character sets
8
+ * @default ALL
9
+ */
10
+ allowedCharacterSets?: 'ALL' | 'LATIN';
6
11
  analyticsProviders: Array<{
7
12
  status: AnalyticsProviderStatus;
8
13
  type: AnalyticsProviderType;
@@ -162,6 +162,11 @@ export declare const carrierAccountUsageCategoryCode: {
162
162
  readonly Shipping: "SHIPPING";
163
163
  };
164
164
  export type CarrierAccountUsageCategoryCode = (typeof carrierAccountUsageCategoryCode)[keyof typeof carrierAccountUsageCategoryCode];
165
+ export declare const carrierApiAccountIntegrationType: {
166
+ readonly Rest: "REST";
167
+ readonly Soap: "SOAP";
168
+ };
169
+ export type CarrierApiAccountIntegrationType = (typeof carrierApiAccountIntegrationType)[keyof typeof carrierApiAccountIntegrationType];
165
170
  export declare const carrierApiAccountProvider: {
166
171
  readonly General: "GENERAL";
167
172
  readonly Organization: "ORGANIZATION";
@@ -172,6 +177,44 @@ export declare const carrierApiRateTypeCode: {
172
177
  readonly Retail: "RETAIL";
173
178
  };
174
179
  export type CarrierApiRateTypeCode = (typeof carrierApiRateTypeCode)[keyof typeof carrierApiRateTypeCode];
180
+ export type CarrierApiRatingBatteryDetail = {
181
+ materialType: CarrierApiRatingBatteryMaterialType;
182
+ packingType: CarrierApiRatingBatteryPackingType;
183
+ };
184
+ export declare const carrierApiRatingBatteryMaterialType: {
185
+ readonly LithiumIon: "LITHIUM_ION";
186
+ readonly LithiumMetal: "LITHIUM_METAL";
187
+ };
188
+ export type CarrierApiRatingBatteryMaterialType = (typeof carrierApiRatingBatteryMaterialType)[keyof typeof carrierApiRatingBatteryMaterialType];
189
+ export declare const carrierApiRatingBatteryPackingType: {
190
+ readonly BatteryInsideEquipment: "BATTERY_INSIDE_EQUIPMENT";
191
+ readonly BatteryOnly: "BATTERY_ONLY";
192
+ readonly BatteryPackagedWithEquipment: "BATTERY_PACKAGED_WITH_EQUIPMENT";
193
+ };
194
+ export type CarrierApiRatingBatteryPackingType = (typeof carrierApiRatingBatteryPackingType)[keyof typeof carrierApiRatingBatteryPackingType];
195
+ export declare const carrierApiRatingSignatureOptionType: {
196
+ readonly Adult: "ADULT";
197
+ readonly Default: "DEFAULT";
198
+ readonly Direct: "DIRECT";
199
+ readonly Indirect: "INDIRECT";
200
+ };
201
+ export type CarrierApiRatingSignatureOptionType = (typeof carrierApiRatingSignatureOptionType)[keyof typeof carrierApiRatingSignatureOptionType];
202
+ export type CarrierApiRatingSpecialServiceDetail = {
203
+ batteryDetail?: InputMaybe<CarrierApiRatingBatteryDetail>;
204
+ serviceTypes: Array<CarrierApiRatingSpecialServiceType>;
205
+ signatureOptionType?: InputMaybe<CarrierApiRatingSignatureOptionType>;
206
+ };
207
+ export declare const carrierApiRatingSpecialServiceType: {
208
+ readonly Alcohol: "ALCOHOL";
209
+ readonly Battery: "BATTERY";
210
+ readonly CutFlowers: "CUT_FLOWERS";
211
+ readonly DangerousGoods: "DANGEROUS_GOODS";
212
+ readonly DryIce: "DRY_ICE";
213
+ readonly SaturdayDelivery: "SATURDAY_DELIVERY";
214
+ readonly SignatureOption: "SIGNATURE_OPTION";
215
+ readonly SundayDelivery: "SUNDAY_DELIVERY";
216
+ };
217
+ export type CarrierApiRatingSpecialServiceType = (typeof carrierApiRatingSpecialServiceType)[keyof typeof carrierApiRatingSpecialServiceType];
175
218
  export declare const carrierCode: {
176
219
  readonly Apc: "APC";
177
220
  readonly Dhl: "DHL";
@@ -221,6 +264,11 @@ export declare const carrierRateType: {
221
264
  readonly Retail: "RETAIL";
222
265
  };
223
266
  export type CarrierRateType = (typeof carrierRateType)[keyof typeof carrierRateType];
267
+ export declare const catalogItemExportJobAction: {
268
+ readonly Email: "EMAIL";
269
+ readonly None: "NONE";
270
+ };
271
+ export type CatalogItemExportJobAction = (typeof catalogItemExportJobAction)[keyof typeof catalogItemExportJobAction];
224
272
  export declare const catalogItemSource: {
225
273
  readonly Classification: "CLASSIFICATION";
226
274
  readonly LegacyMigration: "LEGACY_MIGRATION";
@@ -312,6 +360,11 @@ export declare const collectUploadStatus: {
312
360
  readonly SucceededWithErrors: "SUCCEEDED_WITH_ERRORS";
313
361
  };
314
362
  export type CollectUploadStatus = (typeof collectUploadStatus)[keyof typeof collectUploadStatus];
363
+ export declare const connectTransferOriginType: {
364
+ readonly Connect: "CONNECT";
365
+ readonly Platform: "PLATFORM";
366
+ };
367
+ export type ConnectTransferOriginType = (typeof connectTransferOriginType)[keyof typeof connectTransferOriginType];
315
368
  export declare const constraintType: {
316
369
  readonly Girth: "GIRTH";
317
370
  readonly GirthAndLength: "GIRTH_AND_LENGTH";
@@ -179,6 +179,13 @@ export const carrierAccountUsageCategoryCode = {
179
179
  export type CarrierAccountUsageCategoryCode =
180
180
  (typeof carrierAccountUsageCategoryCode)[keyof typeof carrierAccountUsageCategoryCode];
181
181
 
182
+ export const carrierApiAccountIntegrationType = {
183
+ Rest: 'REST',
184
+ Soap: 'SOAP',
185
+ } as const;
186
+
187
+ export type CarrierApiAccountIntegrationType =
188
+ (typeof carrierApiAccountIntegrationType)[keyof typeof carrierApiAccountIntegrationType];
182
189
  export const carrierApiAccountProvider = {
183
190
  General: 'GENERAL',
184
191
  Organization: 'ORGANIZATION',
@@ -194,6 +201,55 @@ export const carrierApiRateTypeCode = {
194
201
 
195
202
  export type CarrierApiRateTypeCode =
196
203
  (typeof carrierApiRateTypeCode)[keyof typeof carrierApiRateTypeCode];
204
+ export type CarrierApiRatingBatteryDetail = {
205
+ materialType: CarrierApiRatingBatteryMaterialType;
206
+ packingType: CarrierApiRatingBatteryPackingType;
207
+ };
208
+
209
+ export const carrierApiRatingBatteryMaterialType = {
210
+ LithiumIon: 'LITHIUM_ION',
211
+ LithiumMetal: 'LITHIUM_METAL',
212
+ } as const;
213
+
214
+ export type CarrierApiRatingBatteryMaterialType =
215
+ (typeof carrierApiRatingBatteryMaterialType)[keyof typeof carrierApiRatingBatteryMaterialType];
216
+ export const carrierApiRatingBatteryPackingType = {
217
+ BatteryInsideEquipment: 'BATTERY_INSIDE_EQUIPMENT',
218
+ BatteryOnly: 'BATTERY_ONLY',
219
+ BatteryPackagedWithEquipment: 'BATTERY_PACKAGED_WITH_EQUIPMENT',
220
+ } as const;
221
+
222
+ export type CarrierApiRatingBatteryPackingType =
223
+ (typeof carrierApiRatingBatteryPackingType)[keyof typeof carrierApiRatingBatteryPackingType];
224
+
225
+ export const carrierApiRatingSignatureOptionType = {
226
+ Adult: 'ADULT',
227
+ Default: 'DEFAULT',
228
+ Direct: 'DIRECT',
229
+ Indirect: 'INDIRECT',
230
+ } as const;
231
+
232
+ export type CarrierApiRatingSignatureOptionType =
233
+ (typeof carrierApiRatingSignatureOptionType)[keyof typeof carrierApiRatingSignatureOptionType];
234
+ export type CarrierApiRatingSpecialServiceDetail = {
235
+ batteryDetail?: InputMaybe<CarrierApiRatingBatteryDetail>;
236
+ serviceTypes: Array<CarrierApiRatingSpecialServiceType>;
237
+ signatureOptionType?: InputMaybe<CarrierApiRatingSignatureOptionType>;
238
+ };
239
+
240
+ export const carrierApiRatingSpecialServiceType = {
241
+ Alcohol: 'ALCOHOL',
242
+ Battery: 'BATTERY',
243
+ CutFlowers: 'CUT_FLOWERS',
244
+ DangerousGoods: 'DANGEROUS_GOODS',
245
+ DryIce: 'DRY_ICE',
246
+ SaturdayDelivery: 'SATURDAY_DELIVERY',
247
+ SignatureOption: 'SIGNATURE_OPTION',
248
+ SundayDelivery: 'SUNDAY_DELIVERY',
249
+ } as const;
250
+
251
+ export type CarrierApiRatingSpecialServiceType =
252
+ (typeof carrierApiRatingSpecialServiceType)[keyof typeof carrierApiRatingSpecialServiceType];
197
253
 
198
254
  export const carrierCode = {
199
255
  Apc: 'APC',
@@ -257,6 +313,14 @@ export const carrierRateType = {
257
313
  export type CarrierRateType =
258
314
  (typeof carrierRateType)[keyof typeof carrierRateType];
259
315
 
316
+ export const catalogItemExportJobAction = {
317
+ Email: 'EMAIL',
318
+ None: 'NONE',
319
+ } as const;
320
+
321
+ export type CatalogItemExportJobAction =
322
+ (typeof catalogItemExportJobAction)[keyof typeof catalogItemExportJobAction];
323
+
260
324
  export const catalogItemSource = {
261
325
  Classification: 'CLASSIFICATION',
262
326
  LegacyMigration: 'LEGACY_MIGRATION',
@@ -382,6 +446,13 @@ export const collectUploadStatus = {
382
446
 
383
447
  export type CollectUploadStatus =
384
448
  (typeof collectUploadStatus)[keyof typeof collectUploadStatus];
449
+ export const connectTransferOriginType = {
450
+ Connect: 'CONNECT',
451
+ Platform: 'PLATFORM',
452
+ } as const;
453
+
454
+ export type ConnectTransferOriginType =
455
+ (typeof connectTransferOriginType)[keyof typeof connectTransferOriginType];
385
456
 
386
457
  export const constraintType = {
387
458
  Girth: 'GIRTH',