@zonos/elements 1.3.12-alpha.7 → 1.3.12-alpha.9
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.
- package/dist/cjs/{cart-fe91535c.js → cart-37e23be9.js} +199 -3
- package/dist/cjs/{sendErrorLog-fb356701.js → sendErrorLog-7b3d82e4.js} +1 -1
- package/dist/cjs/{submitGtag-62c97f6b.js → submitGtag-d0718b63.js} +1 -1
- package/dist/cjs/zonos-address_4.cjs.entry.js +2 -2
- package/dist/cjs/zonos-card_2.cjs.entry.js +1 -1
- package/dist/cjs/zonos-cart-items_10.cjs.entry.js +3 -3
- package/dist/cjs/zonos-checkout.cjs.entry.js +3 -3
- package/dist/cjs/zonos-controller.cjs.entry.js +1 -1
- package/dist/cjs/zonos-country-flag.cjs.entry.js +1 -1
- package/dist/cjs/zonos-country-select_3.cjs.entry.js +1 -1
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +90 -26
- package/dist/cjs/zonos-hello.cjs.entry.js +1 -1
- package/dist/cjs/zonos-payment.cjs.entry.js +1 -1
- package/dist/collection/components/hello/zonos-hello-dialog/assets/importIcon.svg +4 -0
- package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +85 -25
- package/dist/collection/components/store/translationStore/strings.arabic.js +9 -0
- package/dist/collection/components/store/translationStore/strings.base.js +9 -0
- package/dist/collection/components/store/translationStore/strings.chinese.js +9 -0
- package/dist/collection/components/store/translationStore/strings.danish.js +9 -0
- package/dist/collection/components/store/translationStore/strings.dutch.js +9 -0
- package/dist/collection/components/store/translationStore/strings.french.js +9 -0
- package/dist/collection/components/store/translationStore/strings.german.js +9 -0
- package/dist/collection/components/store/translationStore/strings.hebrew.js +9 -0
- package/dist/collection/components/store/translationStore/strings.indonesian.js +9 -0
- package/dist/collection/components/store/translationStore/strings.italian.js +9 -0
- package/dist/collection/components/store/translationStore/strings.japanese.js +9 -0
- package/dist/collection/components/store/translationStore/strings.korean.js +9 -0
- package/dist/collection/components/store/translationStore/strings.norwegian.js +9 -0
- package/dist/collection/components/store/translationStore/strings.polish.js +9 -0
- package/dist/collection/components/store/translationStore/strings.portuguese.js +9 -0
- package/dist/collection/components/store/translationStore/strings.russian.js +9 -0
- package/dist/collection/components/store/translationStore/strings.spanish.js +9 -0
- package/dist/collection/components/store/translationStore/strings.swedish.js +9 -0
- package/dist/collection/components/store/translationStore/strings.turkish.js +9 -0
- package/dist/collection/components/store/translationStore/strings.vietnamese.js +9 -0
- package/dist/collection/components/store/translationStore.js +19 -3
- package/dist/collection/components/utils/logging/getNavigatorConnection.js +16 -0
- package/dist/collection/components/utils/logging/sendLoadScriptLog.js +2 -13
- package/dist/collection/types/generated/graphql.customer.types.js +3 -0
- package/dist/components/stripe.js +199 -3
- package/dist/components/zonos-hello-dialog2.js +89 -25
- package/dist/esm/{cart-53f5c10c.js → cart-7961927b.js} +199 -3
- package/dist/esm/{sendErrorLog-1c2f093d.js → sendErrorLog-4d9581da.js} +1 -1
- package/dist/esm/{submitGtag-d2658ed5.js → submitGtag-4c1f09dc.js} +1 -1
- package/dist/esm/zonos-address_4.entry.js +2 -2
- package/dist/esm/zonos-card_2.entry.js +1 -1
- package/dist/esm/zonos-cart-items_10.entry.js +3 -3
- package/dist/esm/zonos-checkout.entry.js +3 -3
- package/dist/esm/zonos-controller.entry.js +1 -1
- package/dist/esm/zonos-country-flag.entry.js +1 -1
- package/dist/esm/zonos-country-select_3.entry.js +1 -1
- package/dist/esm/zonos-hello-dialog.entry.js +90 -26
- package/dist/esm/zonos-hello.entry.js +1 -1
- package/dist/esm/zonos-payment.entry.js +1 -1
- package/dist/esm-es5/cart-7961927b.js +1 -0
- package/dist/esm-es5/{sendErrorLog-1c2f093d.js → sendErrorLog-4d9581da.js} +1 -1
- package/dist/esm-es5/{submitGtag-d2658ed5.js → submitGtag-4c1f09dc.js} +1 -1
- package/dist/esm-es5/zonos-address_4.entry.js +1 -1
- package/dist/esm-es5/zonos-card_2.entry.js +1 -1
- package/dist/esm-es5/zonos-cart-items_10.entry.js +1 -1
- package/dist/esm-es5/zonos-checkout.entry.js +1 -1
- package/dist/esm-es5/zonos-controller.entry.js +1 -1
- package/dist/esm-es5/zonos-country-flag.entry.js +1 -1
- package/dist/esm-es5/zonos-country-select_3.entry.js +1 -1
- package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -1
- package/dist/esm-es5/zonos-hello.entry.js +1 -1
- package/dist/esm-es5/zonos-payment.entry.js +1 -1
- package/dist/scripts/loadZonos.js +1 -1
- package/dist/scripts/zonos.js +1 -1
- package/dist/scripts/zonosBase.js +1 -1
- package/dist/types/components/hello/zonos-hello-dialog/zonos-hello-dialog.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.arabic.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.base.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.chinese.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.danish.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.dutch.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.french.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.german.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.hebrew.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.indonesian.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.italian.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.japanese.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.korean.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.norwegian.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.polish.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.portuguese.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.russian.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.spanish.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.swedish.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.turkish.d.ts +9 -0
- package/dist/types/components/store/translationStore/strings.vietnamese.d.ts +9 -0
- package/dist/types/components/store/translationStore.d.ts +24 -1
- package/dist/types/components/utils/api/getCountryLandedCost.d.ts +10 -1
- package/dist/types/components/utils/logging/getNavigatorConnection.d.ts +8 -0
- package/dist/types/types/generated/graphql.customer.types.d.ts +16 -0
- package/dist/types/types/generated/graphql.customer.types.ts +28 -0
- package/dist/zonos-elements/assets/RemoveIcon.svg +1 -1
- package/dist/zonos-elements/assets/importIcon.svg +4 -0
- package/dist/zonos-elements/p-0bdac452.system.js +1 -0
- package/dist/zonos-elements/{p-beb55ff1.js → p-0c5d3595.js} +1 -1
- package/dist/zonos-elements/{p-6f6850aa.entry.js → p-2191b884.entry.js} +1 -1
- package/dist/zonos-elements/{p-c30554b1.system.entry.js → p-2da8e12a.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-0cc5cfbd.system.entry.js → p-339c505b.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-969f36b3.entry.js → p-33f5634a.entry.js} +1 -1
- package/dist/zonos-elements/{p-7e6bc603.entry.js → p-3eb402c8.entry.js} +1 -1
- package/dist/zonos-elements/{p-9f4b0222.system.entry.js → p-431648d8.system.entry.js} +1 -1
- package/dist/zonos-elements/p-44842b39.system.entry.js +1 -0
- package/dist/zonos-elements/{p-df6fd81f.entry.js → p-44f4dd4b.entry.js} +1 -1
- package/dist/zonos-elements/{p-09d7a0f8.system.entry.js → p-4b3923d2.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-af17ec7f.entry.js → p-4eba3abe.entry.js} +1 -1
- package/dist/zonos-elements/p-5a3ceb49.entry.js +1 -0
- package/dist/zonos-elements/{p-bc25e1aa.js → p-63775f6d.js} +1 -1
- package/dist/zonos-elements/p-6e81adba.system.js +1 -1
- package/dist/zonos-elements/{p-fd7ab92d.system.entry.js → p-7efb9c12.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-ac576bd7.system.entry.js → p-8eb876e8.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-d24296a6.system.js → p-a6c9c505.system.js} +1 -1
- package/dist/zonos-elements/{p-e9732f93.system.entry.js → p-bdb72353.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-b6c83e0b.system.entry.js → p-d6aa3011.system.entry.js} +1 -1
- package/dist/zonos-elements/p-dd4f3724.system.js +1 -0
- package/dist/zonos-elements/{p-bece7adb.entry.js → p-e1796e2a.entry.js} +1 -1
- package/dist/zonos-elements/{p-ff32ea53.entry.js → p-e4919505.entry.js} +1 -1
- package/dist/zonos-elements/p-e4be7bd8.js +1 -0
- package/dist/zonos-elements/{p-ea1afd2d.system.entry.js → p-e5fd850c.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-19dbd8c2.entry.js → p-e90e2126.entry.js} +1 -1
- package/dist/zonos-elements/{p-125043b5.entry.js → p-f0b5d2fb.entry.js} +1 -1
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +1 -1
- package/dist/esm-es5/cart-53f5c10c.js +0 -1
- package/dist/zonos-elements/p-176f65e1.system.entry.js +0 -1
- package/dist/zonos-elements/p-3555ce7c.system.js +0 -1
- package/dist/zonos-elements/p-4cc4aba3.system.js +0 -1
- package/dist/zonos-elements/p-aa46e052.js +0 -1
- package/dist/zonos-elements/p-ecc72526.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(){"use strict";"function"==typeof SuppressedError&&SuppressedError;const e=async({response:e,shouldLog:o=!0,shouldThrow:t=!1})=>{try{return await e.json()}catch(e){if(t)throw e;return o&&console.error(e),null}};const o=async(o,t)=>{const n=(function(e,o){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&o.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)o.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(t[n[r]]=e[n[r]])}return t})(t||{},[]),r=n.body?JSON.stringify(n.body):void 0,s=n.method||"GET",i=new URL(o);i.searchParams.set("zToken",(function(e){try{return btoa(e).replace(/=/g,"")}catch(o){return e.replace(/[^A-Za-z0-9]/g,"").split("").reverse().join("")}})(window.location.hostname));const a=Object.assign({"Content-Type":"application/json","Zonos-Is-BigCommerce":window.Zonos.isBigCommerce.toString(),"Zonos-Referer":window.location.hostname,"Zonos-Version":window.Zonos.version,credentialtoken:window.Zonos.zonosApiKey||"Empty credential token from zonos-elements"},n.headers),c=Object.assign(Object.assign({},n),{body:"GET"===s?void 0:r,headers:a,method:s});return(async(o,t)=>{let n;try{n=await fetch(o,t)}catch(e){return e instanceof Error?{errors:[{message:e.message,type:"unknown"}],json:null,response:null}:{errors:[{message:"Fail to fetch",type:"unknown"}],json:null,response:null}}const r=n.headers.get("Zonos-Mode"),s=window.Zonos.zonosQaUrl;if(!window.Zonos.modeAlerted&&r&&s&&("production"===r&&alert("Please be aware that you are currently operating in the production environment. Any interactions with the customer store, including payments, will be processed as real transactions!"),"test"===r&&alert("For testing payments, you can utilize the test payment information provided at this link: https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#web-test-the-integration"),window.Zonos.modeAlerted=!0),n.ok)return{errors:[],json:await e({response:n}),response:n};const i=n.status.toString();try{const o=await e({response:n,shouldThrow:!0});return{errors:[{message:`${i}: ${JSON.stringify(o)}`,type:i}],json:null,response:n}}catch(e){return{errors:[{message:`${i}: Unknown error`,type:i}],json:null,response:null}}})(i.toString(),c)},t=(e,o,...t)=>{var n,r;if(!(!!(null===(n=window.Zonos)||void 0===n?void 0:n.debug)||!!window.location.search.match(/\?.*(&*)zonosDebug=1/)))return void("error"===o&&console.error(e,...t));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(o){case"warn":i.warn(e,...t);break;case"info":i.info(e,...t);break;case"error":i.error(e,...t);break;default:i.groupCollapsed(e,...t),i.trace(),i.groupEnd()}},n=(e,...o)=>{t(e,"error",...o)},r=async({endpoint:e,errors:t,metadata:n})=>{const r="userAgentData"in window.navigator?window.navigator.userAgentData:null,s={endpoint:e,errors:t,metadata:Object.assign({href:window.location.href,userAgent:r&&r.brands.length>0?r:window.navigator.userAgent},n)};o("https://v1.route.js.zonos.com/api/zonos-elements/log-error",{body:s,method:"POST"})};var s;const i=(()=>{const e=(e=>{if(!e)return null;const o=new URL(e).searchParams.get("zonosQaUrl");return o?/[^a-zA-Z0-9-_]+/.test(o)?null:o:null})(window.location.href);if(!e)return null;const o=`https://${e}.preview.js.zonos.com`;return t(`[ZONOS-WARNING] using '${o}' for loading script`,"warn"),fetch(o).then((()=>{window.sessionStorage.removeItem("zonos--checkout-session-id"),window.sessionStorage.removeItem("zonos--client-secret")})).catch((()=>{alert(`[ZONOS-WARNING] '${o}' IS NO LONGER AVAILABLE. REMOVING zonosQaUrl PARAM AND RELOADING THE PAGE`);const e=new URLSearchParams(window.location.search);e.delete("zonosQaUrl");const{pathname:t}=window.location,n=`${t}?${e.toString()}`;return window.history.replaceState({},"",n),window.location.reload(),null})),o})();class a{}s=a,a.isBigCommerce=!1,a.requested=!1,a.internationalHideSelector="",a.zonosQaUrl=null,a.tempCartData=null,a.zonosApiKey=null,a.isLegacyCheckout=!1,a.legacyStoreLogo=null,a.legacyStoreFavicon=null,a.loadScriptLogHandler=async({fallbackLoadTime:e,scriptLoadUrl:t,storeId:n,type:r})=>{try{const s=window.performance.getEntriesByType("resource").find((e=>{const o=e;return o.name.includes(t)&&"script"===o.initiatorType}));(async e=>{const t="userAgentData"in window.navigator?window.navigator.userAgentData:null,n="connection"in window.navigator?window.navigator.connection:null,r="mozConnection"in window.navigator?window.navigator.mozConnection:null,s="webkitConnection"in window.navigator?window.navigator.webkitConnection:null,i=n||r||s,a=Object.assign(Object.assign({href:window.location.href},e),{metadata:Object.assign({connectionDownlink:null==i?void 0:i.downlink,connectionEffectiveType:null==i?void 0:i.effectiveType,connectionRtt:null==i?void 0:i.rtt,connectionSaveData:null==i?void 0:i.saveData,userAgent:t&&t.brands.length>0?t:window.navigator.userAgent},e.metadata)});o("https://v1.route.js.zonos.com/api/zonos-elements/log-script-load",{body:a,method:"POST"})})({cache:0===(null==s?void 0:s.transferSize)?"hit":"miss",eventName:r,loadTime:s&&(null==s?void 0:s.duration)>0?parseFloat(s.duration.toFixed(2)):parseFloat(e.toFixed(2)),metadata:{decodedBodySize:null==s?void 0:s.decodedBodySize,encodedBodySize:null==s?void 0:s.encodedBodySize,fallbackLoadTime:e},scriptLoadUrl:t,storeId:n})}catch(e){}},a.legacyCheckoutErrorHandler=({message:e,tempCartUUID:o})=>{n(`[ZONOS - loadZonos] ${e}`),r({endpoint:"LegacyCheckoutInit",errors:[e],metadata:{tempCartUUID:o}}),document.dispatchEvent(new CustomEvent("legacyCheckoutError",{detail:e}))},a.injectZonos=({initConfig:e,isGithubCdn:o=!1,url:n,version:a})=>{const c=i||n,l=c.replace("https://","").replace("http://",""),d=document.createElement("script"),p=a&&a<"1.2.5"?"loadZonos.js":"zonos.js";d.src=`https://${l}/dist/scripts/${p}`,t(`[ZONOS - loadZonos] Injecting "${p}" from "${l}"`,"info");const u=performance.now();d.addEventListener("load",(()=>{if(s.loadScriptLogHandler({fallbackLoadTime:performance.now()-u,scriptLoadUrl:d.src,storeId:s.storeId,type:o?"jsdelivr":"vercel"}),s.isBigCommerce||(s.isBigCommerce=!!window.stencilBootstrap||!!window.bcConfig||!!document.querySelector('script[src*="bigcommerce.com"]')),window.Zonos.zonosQaUrl=i,window.Zonos.internationalHideSelector=s.internationalHideSelector,window.Zonos.isBigCommerce=s.isBigCommerce,s.isLegacyCheckout){if(!s.zonosApiKey)throw s.legacyCheckoutErrorHandler({message:"zonosApiKey is required for legacy checkout",tempCartUUID:e.tempCartUUID}),new Error("zonosApiKey is required for legacy checkout");if(!s.tempCartData)throw s.legacyCheckoutErrorHandler({message:"tempCartData is required for legacy checkout",tempCartUUID:e.tempCartUUID}),new Error("zonosApiKey is required for legacy checkout");if(s.legacyStoreFavicon){const e=document.createElement("link");e.rel="shortcut icon",e.type="image/x-icon",e.href=s.legacyStoreFavicon,document.head.appendChild(e)}window.Zonos.tempCartData=s.tempCartData;const o=Object.assign(Object.assign({},e),{appearance:Object.assign(Object.assign({},e.appearance),{logoUrl:s.legacyStoreLogo||""}),checkoutSettings:Object.assign(Object.assign({},e.checkoutSettings),{successBehavior:"ZONOS_SUCCESS_PAGE",successRedirectUrl:s.tempCartData.contShoppingURL}),zonosApiKey:s.zonosApiKey});e=o}window.Zonos.version&&(t(`[ZONOS - loadZonos] Execute "Zonos.init" from "${p}" from "${l}"`,"info"),window.Zonos.init(e))})),d.addEventListener("error",(async()=>{if(!o){const o="https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.12-alpha.7",t=a?o.replace(/@zonos\/elements@(.+)/,`@zonos/elements@${a}`):o;s.injectZonos({initConfig:e,isGithubCdn:!0,url:t,version:a})}["localhost",".zonos.com"].some((e=>window.location.href.includes(e)))||i||r(o?{endpoint:d.src,errors:["zonos.js - Failed to fetch github CDN."],metadata:{loadUrl:c,version:a}}:{endpoint:n,errors:["[Info] Using alternative CDN. Failed to fetch script"],metadata:{}})})),document.head.appendChild(d)},a.setupCartData=async e=>{const r=await(async e=>{const{errors:t,json:n}=await o("https://v1.route.js.zonos.com/api/bigcommerce/legacy-migration/get-temp-cart",{body:{tempCartUUID:e},headers:{"Content-Type":"application/json"},method:"POST"});return!n||t.length?null:n})(e);if(t("[ZONOS - loadZonos] getting temp cart data","info",r),!r)throw n("[ZONOS - loadZonos] Error getting temp cart data, stop checkout process."),s.legacyCheckoutErrorHandler({message:"Error getting temp cart data",tempCartUUID:e}),new Error("Error getting temp cart data");return s.tempCartData=r.tempCart,s.legacyStoreLogo=r.storeLogoUrl,s.legacyStoreFavicon=r.storeFaviconUrl,{storeId:r.tempCart.storeId,zonosApiKey:r.zonosApiKey}},a.init=async e=>{var r;const i="https://v1.3.12-alpha.7.js.zonos.com",a=null===(r=document.querySelector("script[src*='/loadZonos.js']"))||void 0===r?void 0:r.src,c=document.querySelector('script[src*="/zonos.js"]'),l=null==a?void 0:a.includes("timestamp=");if(!a||!l)return void n("[ZONOS - loadZonos] A timestamp is required as a query parameter in the loadZonos.js script source. This timestamp ensures that you are loading the most recent version of the script, avoiding any cached versions.");if(c||!a||s.requested)return void t("[ZONOS - loadZonos] script is already loaded or requested","info");s.requested=!0;let d=e.storeId;if(e.tempCartUUID){const o=await s.setupCartData(e.tempCartUUID);d=o.storeId,s.zonosApiKey=o.zonosApiKey,s.isLegacyCheckout=!0}if(!d)return t("[ZONOS - loadZonos] loading latest script since storeId is not provided."),void s.injectZonos({initConfig:e,url:i,version:null});s.storeId=d;const p=new URL("https://v1.route.js.zonos.com/api/get-store-version");p.searchParams.set("storeId",e.storeId.toString());const{errors:u,json:m}=await o(p.toString());if(u.length||!m)return t("[ZONOS - loadZonos] Error getting store version, loadding the latest version.","error"),void s.injectZonos({initConfig:e,url:i,version:null});const{version:g}=m;if(!c){const{currentLoadScriptUrl:o,isForceLoadVersionDomain:n,isWhiteListed:r}=(({loadScriptSrc:e})=>{if(!e)return{currentLoadScriptUrl:"",isForceLoadVersionDomain:!1,isWhiteListed:!1};const o=new URL(e).origin,t=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"].some((e=>o.includes(e))),n=["qa.js.zonos.com"].some((e=>o.includes(e)));return{currentLoadScriptUrl:o,isForceLoadVersionDomain:n,isWhiteListed:t}})({loadScriptSrc:a}),i=r&&!n?o:`${"alpha"===g?"alpha":`v${g}`}.js.zonos.com`,c=r&&!n?null:g;t("[ZONOS - loadZonos] injecting zonos script","info",{currentLoadScriptUrl:o,isForceLoadVersionDomain:n,isWhiteListed:r,loadUrl:i,loadVersion:c,version:g}),s.injectZonos({initConfig:e,url:i,version:c})}},void 0===window.Zonos&&(window.Zonos=a)})();
|
|
1
|
+
(function(){"use strict";"function"==typeof SuppressedError&&SuppressedError;const e=async({response:e,shouldLog:o=!0,shouldThrow:t=!1})=>{try{return await e.json()}catch(e){if(t)throw e;return o&&console.error(e),null}};const o=async(o,t)=>{const n=(function(e,o){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&o.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)o.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(t[n[r]]=e[n[r]])}return t})(t||{},[]),r=n.body?JSON.stringify(n.body):void 0,s=n.method||"GET",i=new URL(o);i.searchParams.set("zToken",(function(e){try{return btoa(e).replace(/=/g,"")}catch(o){return e.replace(/[^A-Za-z0-9]/g,"").split("").reverse().join("")}})(window.location.hostname));const a=Object.assign({"Content-Type":"application/json","Zonos-Is-BigCommerce":window.Zonos.isBigCommerce.toString(),"Zonos-Referer":window.location.hostname,"Zonos-Version":window.Zonos.version,credentialtoken:window.Zonos.zonosApiKey||"Empty credential token from zonos-elements"},n.headers),c=Object.assign(Object.assign({},n),{body:"GET"===s?void 0:r,headers:a,method:s});return(async(o,t)=>{let n;try{n=await fetch(o,t)}catch(e){return e instanceof Error?{errors:[{message:e.message,type:"unknown"}],json:null,response:null}:{errors:[{message:"Fail to fetch",type:"unknown"}],json:null,response:null}}const r=n.headers.get("Zonos-Mode"),s=window.Zonos.zonosQaUrl;if(!window.Zonos.modeAlerted&&r&&s&&("production"===r&&alert("Please be aware that you are currently operating in the production environment. Any interactions with the customer store, including payments, will be processed as real transactions!"),"test"===r&&alert("For testing payments, you can utilize the test payment information provided at this link: https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#web-test-the-integration"),window.Zonos.modeAlerted=!0),n.ok)return{errors:[],json:await e({response:n}),response:n};const i=n.status.toString();try{const o=await e({response:n,shouldThrow:!0});return{errors:[{message:`${i}: ${JSON.stringify(o)}`,type:i}],json:null,response:n}}catch(e){return{errors:[{message:`${i}: Unknown error`,type:i}],json:null,response:null}}})(i.toString(),c)},t=()=>{const e="connection"in window.navigator?window.navigator.connection:null,o="mozConnection"in window.navigator?window.navigator.mozConnection:null,t="webkitConnection"in window.navigator?window.navigator.webkitConnection:null;return e||o||t},n=(e,o,...t)=>{var n,r;if(!(!!(null===(n=window.Zonos)||void 0===n?void 0:n.debug)||!!window.location.search.match(/\?.*(&*)zonosDebug=1/)))return void("error"===o&&console.error(e,...t));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(o){case"warn":i.warn(e,...t);break;case"info":i.info(e,...t);break;case"error":i.error(e,...t);break;default:i.groupCollapsed(e,...t),i.trace(),i.groupEnd()}},r=(e,...o)=>{n(e,"error",...o)},s=async({endpoint:e,errors:t,metadata:n})=>{const r="userAgentData"in window.navigator?window.navigator.userAgentData:null,s={endpoint:e,errors:t,metadata:Object.assign({href:window.location.href,userAgent:r&&r.brands.length>0?r:window.navigator.userAgent},n)};o("https://v1.route.js.zonos.com/api/zonos-elements/log-error",{body:s,method:"POST"})};var i;const a=(()=>{const e=(e=>{if(!e)return null;const o=new URL(e).searchParams.get("zonosQaUrl");return o?/[^a-zA-Z0-9-_]+/.test(o)?null:o:null})(window.location.href);if(!e)return null;const o=`https://${e}.preview.js.zonos.com`;return n(`[ZONOS-WARNING] using '${o}' for loading script`,"warn"),fetch(o).then((()=>{window.sessionStorage.removeItem("zonos--checkout-session-id"),window.sessionStorage.removeItem("zonos--client-secret")})).catch((()=>{alert(`[ZONOS-WARNING] '${o}' IS NO LONGER AVAILABLE. REMOVING zonosQaUrl PARAM AND RELOADING THE PAGE`);const e=new URLSearchParams(window.location.search);e.delete("zonosQaUrl");const{pathname:t}=window.location,n=`${t}?${e.toString()}`;return window.history.replaceState({},"",n),window.location.reload(),null})),o})();class c{}i=c,c.isBigCommerce=!1,c.requested=!1,c.internationalHideSelector="",c.zonosQaUrl=null,c.tempCartData=null,c.zonosApiKey=null,c.isLegacyCheckout=!1,c.legacyStoreLogo=null,c.legacyStoreFavicon=null,c.parallelLoadTimes=[],c.loadScriptLogHandler=async({fallbackLoadTime:e,isError:n,metadata:r,scriptLoadUrl:s,storeId:i,type:a})=>{try{const c=window.performance.getEntriesByType("resource").find((e=>{const o=e;return o.name.includes(s)&&"script"===o.initiatorType}));(async e=>{const n="userAgentData"in window.navigator?window.navigator.userAgentData:null,r=t(),s=Object.assign(Object.assign({href:window.location.href},e),{metadata:Object.assign({connectionDownlink:null==r?void 0:r.downlink,connectionEffectiveType:null==r?void 0:r.effectiveType,connectionRtt:null==r?void 0:r.rtt,connectionSaveData:null==r?void 0:r.saveData,userAgent:n&&n.brands.length>0?n:window.navigator.userAgent},e.metadata)});o("https://v1.route.js.zonos.com/api/zonos-elements/log-script-load",{body:s,method:"POST"})})({cache:0===(null==c?void 0:c.transferSize)?"hit":"miss",eventName:a,loadTime:c&&(null==c?void 0:c.duration)>0?parseFloat(c.duration.toFixed(2)):parseFloat(e.toFixed(2)),metadata:Object.assign({decodedBodySize:null==c?void 0:c.decodedBodySize,encodedBodySize:null==c?void 0:c.encodedBodySize,fallbackLoadTime:e,isError:!!n},r),scriptLoadUrl:s,storeId:i})}catch(e){}},c.loadScriptLogParallelHandler=async e=>{try{if(i.parallelLoadTimes.push(e),2===i.parallelLoadTimes.length){const e=i.parallelLoadTimes.find((e=>"vercel"===e.type)),o=i.parallelLoadTimes.find((e=>"jsdelivr"===e.type));if(!e||!o)return;if(e.isError&&o.isError)return void s({endpoint:`<${e.scriptLoadUrl}> <${o.scriptLoadUrl}>`,errors:["Failed to fetch both Vercel and jsdelivr CDN. Perhaps network issue on customer site."],metadata:{cdnLoadTime:o.fallbackLoadTime,cdnType:o.type,vercelLoadTime:e.fallbackLoadTime}});i.loadScriptLogHandler({fallbackLoadTime:e.fallbackLoadTime,isError:e.isError,metadata:{cdnScriptFallbackTime:o.fallbackLoadTime,cdnScriptIsError:!!o.isError,cdnScriptLoadUrl:o.scriptLoadUrl,cdnScriptType:o.type},scriptLoadUrl:e.scriptLoadUrl,storeId:e.storeId,type:e.type})}}catch(e){}},c.legacyCheckoutErrorHandler=({message:e,tempCartUUID:o})=>{r(`[ZONOS - loadZonos] ${e}`),s({endpoint:"LegacyCheckoutInit",errors:[e],metadata:{tempCartUUID:o}}),document.dispatchEvent(new CustomEvent("legacyCheckoutError",{detail:e}))},c.injectZonos=({initConfig:e,isGithubCdn:o=!1,parallelLoaded:r,url:c,version:l})=>{var d;const p=()=>{const e="https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.12-alpha.9";return l?e.replace(/@zonos\/elements@(.+)/,`@zonos/elements@${l}`):e},m=a||c,u=m.replace("https://","").replace("http://",""),g=document.createElement("script"),w=l&&l<"1.2.5"?"loadZonos.js":"zonos.js";g.src=`https://${u}/dist/scripts/${w}`,n(`[ZONOS - loadZonos] Injecting "${w}" from "${u}"`,"info");const h="4g"===(null===(d=t())||void 0===d?void 0:d.effectiveType)&&!o;if(h){const o=p();i.injectZonos({initConfig:e,isGithubCdn:!0,parallelLoaded:!0,url:o,version:l})}const y=performance.now();g.addEventListener("load",(()=>{if(h||r?i.loadScriptLogParallelHandler({fallbackLoadTime:performance.now()-y,scriptLoadUrl:g.src,storeId:i.storeId,type:o?"jsdelivr":"vercel"}):i.loadScriptLogHandler({fallbackLoadTime:performance.now()-y,scriptLoadUrl:g.src,storeId:i.storeId,type:o?"jsdelivr":"vercel"}),i.isBigCommerce||(i.isBigCommerce=!!window.stencilBootstrap||!!window.bcConfig||!!document.querySelector('script[src*="bigcommerce.com"]')),window.Zonos.zonosQaUrl=a,window.Zonos.internationalHideSelector=i.internationalHideSelector,window.Zonos.isBigCommerce=i.isBigCommerce,i.isLegacyCheckout){if(!i.zonosApiKey)throw i.legacyCheckoutErrorHandler({message:"zonosApiKey is required for legacy checkout",tempCartUUID:e.tempCartUUID}),new Error("zonosApiKey is required for legacy checkout");if(!i.tempCartData)throw i.legacyCheckoutErrorHandler({message:"tempCartData is required for legacy checkout",tempCartUUID:e.tempCartUUID}),new Error("zonosApiKey is required for legacy checkout");if(i.legacyStoreFavicon){const e=document.createElement("link");e.rel="shortcut icon",e.type="image/x-icon",e.href=i.legacyStoreFavicon,document.head.appendChild(e)}window.Zonos.tempCartData=i.tempCartData;const o=Object.assign(Object.assign({},e),{appearance:Object.assign(Object.assign({},e.appearance),{logoUrl:i.legacyStoreLogo||""}),checkoutSettings:Object.assign(Object.assign({},e.checkoutSettings),{successBehavior:"ZONOS_SUCCESS_PAGE",successRedirectUrl:i.tempCartData.contShoppingURL}),zonosApiKey:i.zonosApiKey});e=o}window.Zonos.version&&(n(`[ZONOS - loadZonos] Execute "Zonos.init" from "${w}" from "${u}"`,"info"),window.Zonos.init(e))})),g.addEventListener("error",(async()=>{if(!h&&!r){const o=p();i.injectZonos({initConfig:e,isGithubCdn:!0,url:o,version:l})}["localhost",".zonos.com"].some((e=>window.location.href.includes(e)))||a||(h||r?i.loadScriptLogParallelHandler({fallbackLoadTime:performance.now()-y,isError:!0,scriptLoadUrl:g.src,storeId:i.storeId,type:o?"jsdelivr":"vercel"}):s(o?{endpoint:g.src,errors:["zonos.js - Failed to fetch github CDN."],metadata:{cdnLoadTime:performance.now()-y,cdnType:"jsdelivr",loadUrl:m,version:l}}:{endpoint:g.src,errors:["[Info] Using alternative CDN. Failed to fetch script"],metadata:{vercelLoadTime:performance.now()-y}}))})),document.head.appendChild(g)},c.setupCartData=async e=>{const t=await(async e=>{const{errors:t,json:n}=await o("https://v1.route.js.zonos.com/api/bigcommerce/legacy-migration/get-temp-cart",{body:{tempCartUUID:e},headers:{"Content-Type":"application/json"},method:"POST"});return!n||t.length?null:n})(e);if(n("[ZONOS - loadZonos] getting temp cart data","info",t),!t)throw r("[ZONOS - loadZonos] Error getting temp cart data, stop checkout process."),i.legacyCheckoutErrorHandler({message:"Error getting temp cart data",tempCartUUID:e}),new Error("Error getting temp cart data");return i.tempCartData=t.tempCart,i.legacyStoreLogo=t.storeLogoUrl,i.legacyStoreFavicon=t.storeFaviconUrl,{storeId:t.tempCart.storeId,zonosApiKey:t.zonosApiKey}},c.init=async e=>{var t;const s="https://v1.3.12-alpha.9.js.zonos.com",a=null===(t=document.querySelector("script[src*='/loadZonos.js']"))||void 0===t?void 0:t.src,c=document.querySelector('script[src*="/zonos.js"]'),l=null==a?void 0:a.includes("timestamp=");if(!a||!l)return void r("[ZONOS - loadZonos] A timestamp is required as a query parameter in the loadZonos.js script source. This timestamp ensures that you are loading the most recent version of the script, avoiding any cached versions.");if(c||!a||i.requested)return void n("[ZONOS - loadZonos] script is already loaded or requested","info");i.requested=!0;let d=e.storeId;if(e.tempCartUUID){const o=await i.setupCartData(e.tempCartUUID);d=o.storeId,i.zonosApiKey=o.zonosApiKey,i.isLegacyCheckout=!0}if(!d)return n("[ZONOS - loadZonos] loading latest script since storeId is not provided."),void i.injectZonos({initConfig:e,url:s,version:null});i.storeId=d;const p=new URL("https://v1.route.js.zonos.com/api/get-store-version");p.searchParams.set("storeId",e.storeId.toString());const{errors:m,json:u}=await o(p.toString());if(m.length||!u)return n("[ZONOS - loadZonos] Error getting store version, loadding the latest version.","error"),void i.injectZonos({initConfig:e,url:s,version:null});const{version:g}=u;if(!c){const{currentLoadScriptUrl:o,isForceLoadVersionDomain:t,isWhiteListed:r}=(({loadScriptSrc:e})=>{if(!e)return{currentLoadScriptUrl:"",isForceLoadVersionDomain:!1,isWhiteListed:!1};const o=new URL(e).origin,t=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"].some((e=>o.includes(e))),n=["qa.js.zonos.com"].some((e=>o.includes(e)));return{currentLoadScriptUrl:o,isForceLoadVersionDomain:n,isWhiteListed:t}})({loadScriptSrc:a}),s=r&&!t?o:`${"alpha"===g?"alpha":`v${g}`}.js.zonos.com`,c=r&&!t?null:g;n("[ZONOS - loadZonos] injecting zonos script","info",{currentLoadScriptUrl:o,isForceLoadVersionDomain:t,isWhiteListed:r,loadUrl:s,loadVersion:c,version:g}),i.injectZonos({initConfig:e,url:s,version:c})}},void 0===window.Zonos&&(window.Zonos=c)})();
|
package/dist/scripts/zonos.js
CHANGED
|
@@ -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.12-alpha.
|
|
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.12-alpha.9.js.zonos.com",u="https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.12-alpha.9",p="https://rsms.me",m="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.12-alpha.9",y.modeAlerted=!1,y.tempCartData=null,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\/dist\/scripts/],dsn:"https://19168bd05af0e2e0e7520ad58953e4f2@o446983.ingest.sentry.io/4506400622837760",ignoreErrors:["Failed to load Stripe.js"],release:`zonos-elements@${d.version}`,tracesSampler:({transactionContext:e})=>"pageload"===e.op?1:.25})},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^="${p}"]`);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=p,t.appendChild(n);const o=document.createElement("link");o.rel="stylesheet",o.href=`${p}/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^="${m}"]`)){const e=document.createElement("link");e.rel="preconnect",e.href=m,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&&window.Zonos.doneInit||(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.12-alpha.
|
|
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.12-alpha.9.js.zonos.com",u="https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.12-alpha.9",p="https://rsms.me",m="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.12-alpha.9",y.modeAlerted=!1,y.tempCartData=null,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\/dist\/scripts/],dsn:"https://19168bd05af0e2e0e7520ad58953e4f2@o446983.ingest.sentry.io/4506400622837760",ignoreErrors:["Failed to load Stripe.js"],release:`zonos-elements@${d.version}`,tracesSampler:({transactionContext:e})=>"pageload"===e.op?1:.25})},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^="${p}"]`);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=p,t.appendChild(n);const o=document.createElement("link");o.rel="stylesheet",o.href=`${p}/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^="${m}"]`)){const e=document.createElement("link");e.rel="preconnect",e.href=m,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})();
|
|
@@ -45,5 +45,14 @@ export declare class ZonosHelloDialog {
|
|
|
45
45
|
private setShowLanguageSelect;
|
|
46
46
|
globalClickHandler(e: MouseEvent): void;
|
|
47
47
|
isOpenHandler(isOpen: boolean): void;
|
|
48
|
+
private getDutyMessage;
|
|
49
|
+
private getTaxMessage;
|
|
50
|
+
private getUkDutyTaxMessage;
|
|
51
|
+
private getAustraliaDutyTaxMessage;
|
|
52
|
+
private getNewZealandDutyTaxMessge;
|
|
53
|
+
/**
|
|
54
|
+
* Get additional duty tax message if selected country has tax id
|
|
55
|
+
*/
|
|
56
|
+
private getAdditionalDutyTaxMessage;
|
|
48
57
|
render(): any;
|
|
49
58
|
}
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsArabic: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsArabic: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsBase: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsBase: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsChinese: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsChinese: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsDanish: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsDanish: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsDutch: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsDutch: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsFrench: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsFrench: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsGerman: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsGerman: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsHebrew: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsHebrew: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsIndonesian: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsIndonesian: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsItalian: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsItalian: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsJapanese: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsJapanese: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsKorean: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsKorean: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsNorwegian: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsNorwegian: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsPolish: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsPolish: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsPortuguese: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsPortuguese: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsRussian: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsRussian: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsSpanish: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsSpanish: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsSwedish: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsSwedish: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsTurkish: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsTurkish: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
export declare const stringsVietnamese: {
|
|
2
|
+
'${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.': {
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
'${percentage} GST due on any order above ${threshold}.': {
|
|
6
|
+
value: string;
|
|
7
|
+
};
|
|
2
8
|
'Above de minimis threshold for': {
|
|
3
9
|
value: string;
|
|
4
10
|
};
|
|
@@ -92,6 +98,9 @@ export declare const stringsVietnamese: {
|
|
|
92
98
|
'Order total': {
|
|
93
99
|
value: string;
|
|
94
100
|
};
|
|
101
|
+
'Orders to ${countryName} must be over ${threshold} to ship.': {
|
|
102
|
+
value: string;
|
|
103
|
+
};
|
|
95
104
|
Pay: {
|
|
96
105
|
value: string;
|
|
97
106
|
};
|