@zonos/elements 1.3.50 → 1.3.51
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-688d674d.js → cart-546d1602.js} +7 -2
- package/dist/cjs/{createCustomEvent-01bacaea.js → createCustomEvent-9b91480b.js} +1 -1
- package/dist/cjs/index.cjs.js +7 -7
- package/dist/cjs/{paypal-ce1516ba.js → paypal-83f49f9a.js} +1 -1
- package/dist/cjs/zonos-address_8.cjs.entry.js +1 -1
- package/dist/cjs/zonos-cart-items_12.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_4.cjs.entry.js +1 -1
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +1 -1
- package/dist/cjs/zonos-hello.cjs.entry.js +1 -1
- package/dist/cjs/zonos-language-select_2.cjs.entry.js +1 -1
- package/dist/cjs/zonos-notification_3.cjs.entry.js +2 -2
- package/dist/collection/components/utils/api/triggerBuildLandedCost.js +2 -2
- package/dist/collection/components/utils/handleFetch.js +6 -1
- package/dist/esm/{cart-4f300fcb.js → cart-51529af2.js} +7 -2
- package/dist/esm/{createCustomEvent-c5ed9070.js → createCustomEvent-b8bbdf5e.js} +1 -1
- package/dist/esm/index.js +7 -7
- package/dist/esm/{paypal-70caf283.js → paypal-905325d0.js} +1 -1
- package/dist/esm/zonos-address_8.entry.js +1 -1
- package/dist/esm/zonos-cart-items_12.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_4.entry.js +1 -1
- package/dist/esm/zonos-hello-dialog.entry.js +1 -1
- package/dist/esm/zonos-hello.entry.js +1 -1
- package/dist/esm/zonos-language-select_2.entry.js +1 -1
- package/dist/esm/zonos-notification_3.entry.js +2 -2
- package/dist/esm-es5/{cart-4f300fcb.js → cart-51529af2.js} +1 -1
- package/dist/esm-es5/{createCustomEvent-c5ed9070.js → createCustomEvent-b8bbdf5e.js} +1 -1
- package/dist/esm-es5/index.js +1 -1
- package/dist/esm-es5/{paypal-70caf283.js → paypal-905325d0.js} +1 -1
- package/dist/esm-es5/zonos-address_8.entry.js +1 -1
- package/dist/esm-es5/zonos-cart-items_12.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_4.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-language-select_2.entry.js +1 -1
- package/dist/esm-es5/zonos-notification_3.entry.js +1 -1
- package/dist/scripts/index.js +1 -1
- package/dist/scripts/loadZonos.js +1 -1
- package/dist/scripts/zonos.js +1 -1
- package/dist/zonos-elements/assets/RemoveIcon.svg +1 -1
- package/dist/zonos-elements/index.esm.js +1 -1
- package/dist/zonos-elements/{p-d1cd0a5f.system.entry.js → p-00100b17.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-595d406e.entry.js → p-101c41bf.entry.js} +1 -1
- package/dist/zonos-elements/{p-322600aa.system.entry.js → p-1828a4ff.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-31905b60.system.js → p-2c323311.system.js} +1 -1
- package/dist/zonos-elements/{p-d709ad28.system.entry.js → p-3c4eec63.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-5beccdce.system.entry.js → p-47945026.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-40d52dd6.system.entry.js → p-496e040f.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-27f2e8af.system.entry.js → p-4e77ed65.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-4849604d.entry.js → p-58d9803d.entry.js} +1 -1
- package/dist/zonos-elements/{p-e7e73693.system.entry.js → p-59e85369.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-fe198a6c.entry.js → p-5e56828a.entry.js} +1 -1
- package/dist/zonos-elements/{p-22e8d4ad.system.entry.js → p-6b42fa1b.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-ec31cd17.system.entry.js → p-8473f99a.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-1f2db2ff.entry.js → p-8b8ef484.entry.js} +1 -1
- package/dist/zonos-elements/{p-480a6094.entry.js → p-9a0401fd.entry.js} +1 -1
- package/dist/zonos-elements/{p-1719bedd.entry.js → p-9e976332.entry.js} +1 -1
- package/dist/zonos-elements/{p-124e3426.js → p-aa5d669b.js} +1 -1
- package/dist/zonos-elements/{p-8af4a9e7.system.entry.js → p-b1a8b874.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-00f219bd.entry.js → p-b57d24f2.entry.js} +1 -1
- package/dist/zonos-elements/{p-4452dddc.entry.js → p-ba0289f9.entry.js} +1 -1
- package/dist/zonos-elements/p-c78dd680.system.js +1 -1
- package/dist/zonos-elements/{p-ceb8b836.system.js → p-c89859cf.system.js} +2 -2
- package/dist/zonos-elements/p-c8a3303b.js +1 -0
- package/dist/zonos-elements/{p-a67578ae.entry.js → p-cc7a4fca.entry.js} +1 -1
- package/dist/zonos-elements/{p-2018969a.js → p-d413cd13.js} +1 -1
- package/dist/zonos-elements/{p-81540fd6.system.js → p-e758ec31.system.js} +1 -1
- package/dist/zonos-elements/{p-6ab615e6.system.js → p-fcfde531.system.js} +1 -1
- package/dist/zonos-elements/{p-89b1f4a5.entry.js → p-ffd76226.entry.js} +1 -1
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +2 -1
- package/dist/zonos-elements/p-05dff37f.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(n,e,t,r){function o(n){return n instanceof t?n:new t((function(e){e(n)}))}return new(t||(t=Promise))((function(t,i){function u(n){try{c(r.next(n))}catch(n){i(n)}}function s(n){try{c(r["throw"](n))}catch(n){i(n)}}function c(n){n.done?t(n.value):o(n.value).then(u,s)}c((r=r.apply(n,e||[])).next())}))};var __generator=this&&this.__generator||function(n,e){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},r,o,i,u;return u={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(u[Symbol.iterator]=function(){return this}),u;function s(n){return function(e){return c([n,e])}}function c(s){if(r)throw new TypeError("Generator is already executing.");while(u&&(u=0,s[0]&&(t=0)),t)try{if(r=1,o&&(i=s[0]&2?o["return"]:s[0]?o["throw"]||((i=o["return"])&&i.call(o),0):o.next)&&!(i=i.call(o,s[1])).done)return i;if(o=0,i)s=[s[0]&2,i.value];switch(s[0]){case 0:case 1:i=s;break;case 4:t.label++;return{value:s[1],done:false};case 5:t.label++;o=s[1];s=[0];continue;case 7:s=t.ops.pop();t.trys.pop();continue;default:if(!(i=t.trys,i=i.length>0&&i[i.length-1])&&(s[0]===6||s[0]===2)){t=0;continue}if(s[0]===3&&(!i||s[1]>i[0]&&s[1]<i[3])){t.label=s[1];break}if(s[0]===6&&t.label<i[1]){t.label=i[1];i=s;break}if(i&&t.label<i[2]){t.label=i[2];t.ops.push(s);break}if(i[2])t.ops.pop();t.trys.pop();continue}s=e.call(n,t)}catch(n){s=[6,n];o=0}finally{r=i=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};System.register(["./p-63db40b9.system.js"],(function(n){"use strict";var e,t;return{setters:[function(n){e=n.l;t=n.a}],execute:function(){var r=this;var o=function(n){var e=n.loadScriptSrc;if(!e){return{currentLoadScriptUrl:"",isForceLoadVersionDomain:false,isWhiteListed:false}}var t=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"];var r=["qa.js.zonos.com"];var o=new URL(e).origin;var i=t.some((function(n){return o.includes(n)}));var u=r.some((function(n){return o.includes(n)}));return{currentLoadScriptUrl:o,isForceLoadVersionDomain:u,isWhiteListed:i}};var i=["jsdelivr","cdnjs","unpkg","vercel"];var u=function(n){var e=i.indexOf(n);var t=i[e+1];return t||null};var s=function(n){if(!n){return null}var e=new URL(n).searchParams;var t=e.get("zonosQaUrl");if(!t){return null}var r=/[^a-zA-Z0-9-_]+/.test(t);if(!!r){return null}return t};var c=function(){var n=window&&window.location.href.includes("forceLoadCdn");if(typeof window==="undefined"||n){return null}var t=s(window.location.href);var r="https://v1.3.50.js.zonos.com";if(!t&&(r.includes("test.")||r.includes("test-"))){return r}if(!t&&["dev.demo.elements.zonos.com"].includes(window.location.hostname)){return"https://dev.elements.zonos.com"}if(!t){return null}if(t==="dev-elements"){return"https://dev.elements.zonos.com"}var o="preview.js.zonos.com";var i="https://".concat(t,".").concat(o);e("[ZONOS-WARNING] using '".concat(i,"' for loading script"),"warn");void fetch(i).then((function(){window.sessionStorage.removeItem("zonos--checkout-session-id");window.sessionStorage.removeItem("zonos--client-secret")})).catch((function(){alert("[ZONOS-WARNING] '".concat(i,"' IS NO LONGER AVAILABLE. REMOVING zonosQaUrl PARAM AND RELOADING THE PAGE"));var n=new URLSearchParams(window.location.search);n.delete("zonosQaUrl");var e=window.location.pathname;var t="".concat(e,"?").concat(n.toString());window.history.replaceState(window.history.state,"",t);window.location.reload();return null}));return i};var a="https://js.stripe.com/v3";var l=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/;var d="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used";var f=function(){var n=document.querySelectorAll('script[src^="'.concat(a,'"]'));for(var e=0;e<n.length;e++){var t=n[e];if(!t){continue}if(!l.test(t.src)){continue}return t}return null};var v=null;var m=function(n){var e=n&&!n.advancedFraudSignals?"?advancedFraudSignals=false":"";var r=document.createElement("script");r.src="".concat(a).concat(e);var o=document.head||document.body;if(!o){t("Expected document.body not to be null. Stripe.js requires a <body> element.");return null}o.appendChild(r);return r};var w=function(n){if(v!==null){return v}v=new Promise((function(e,t){if(typeof window==="undefined"||typeof document==="undefined"){e(null);return}if(window.Stripe&&n){console.warn(d)}if(window.Stripe){e(window.Stripe);return}try{var r=f();if(r&&n){console.warn(d)}else if(!r){r=m(n)}r===null||r===void 0?void 0:r.addEventListener("load",(function(){if(window.Stripe){e(window.Stripe)}else{t(new Error("Stripe.js not available"))}}));r===null||r===void 0?void 0:r.addEventListener("error",(function(){t(new Error("Failed to load Stripe.js"))}))}catch(n){t(n);return}}));return v};var p=function(n,e){if(!n||!n._registerWrapper){return}n._registerWrapper({name:"stripe-js",startTime:e})};var h=function(n,e,t){if(n===null){return null}var r=n.apply(undefined,e);p(r,t);return r};var y=Promise.resolve().then((function(){return w(null)}));var z=false;y.catch((function(n){if(!z){console.warn(n)}}));var j=function(){var n=[];for(var e=0;e<arguments.length;e++){n[e]=arguments[e]}return __awaiter(r,void 0,void 0,(function(){var e;return __generator(this,(function(t){z=true;e=Date.now();return[2,y.then((function(t){return h(t,n,e)}))]}))}))};var g;var b=function(){if(typeof document==="undefined"){return null}var n=document.querySelector('script[src*="/zonos.js"]');var e=o({loadScriptSrc:n===null||n===void 0?void 0:n.src}),t=e.currentLoadScriptUrl,r=e.isWhiteListed;if(r){return t}return null}();var k="https://v1.3.50.js.zonos.com";var S=b||"https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.50";var O="https://unpkg.com/@zonos/elements@1.3.50";var _="https://cdnjs.cloudflare.com/ajax/libs/zonos-elements/1.3.50";var L="jsdelivr";var N="https://rsms.me";var A="https://fonts.googleapis.com";var R=/^https:\/\/rsms\.me\/inter\/inter\.css(.*)$/;var U=function(){function n(){}return n}();n("Zonos",U);g=U;U.doneInit=false;U.debug=typeof window!=="undefined"&&!!window.location.search.match(/\?.*(&*)zonosDebug=1/);U.zonosConversionTest=typeof window!=="undefined"&&!!window.location.search.match(/\?.*(&*)zonosConversionTest/);U._paypalMockResponse=null;U.isBigCommerce=false;U.releaseDate="1726504733366";U.isNpm=true;U.zonosQaUrl=null;U.version="v".concat("1.3.50");U.modeAlerted=false;U.tempCartData=null;U.paypal=null;U.getCurrentTimestamp=function(){return(new Date).getTime()};U.zonosController=null;U.init=function(n){return __awaiter(r,[n],void 0,(function(n){var r=n.appearance,o=n.checkoutSettings,i=n.currencyConverter,u=n.helloSettings,s=n.onCountryChange,c=n.overrideCurrencyFormat,a=n.storeId,l=n.zonosApiKey;return __generator(this,(function(n){if(g.doneInit){return[2]}e("====== ZONOS DEBUG MODE: on (".concat(g.version,") ======"));if(!l){t("Missing Zonos API key");return[2]}g.zonosApiKey=l;g.storeId=a;e("init zonos");g.injectZonosCdn();g.injectZonosCss();g.injectFonts();g.injectController({config:{appearance:r,checkoutSettings:o,currencyConverter:i,helloSettings:u,onCountryChange:s,overrideCurrencyFormat:c},zonosApiKey:l});g.doneInit=true;return[2]}))}))};U.displayCurrency=function(){var n=document.querySelector("zonos-hello");if(n){void n.displayCurrency()}};U.openHelloDialog=function(n){var e=document.querySelector("zonos-hello");if(e){void e.openHelloDialog(n!==null&&n!==void 0?n:true)}};U.showNotification=function(n){var e;void((e=g.zonosController)===null||e===void 0?void 0:e.showNotification(n))};U.updateOrganizationName=function(n){var e;void((e=g.zonosController)===null||e===void 0?void 0:e.updateOrganizationName(n))};U.disablePlaceOrderButtons=function(n){var e=n.autoEnable,t=e===void 0?true:e,r=n.config,o=n.disable,i=n.placeOrderButtonSelector;var u;if((u=r.checkoutSettings)===null||u===void 0?void 0:u.disablePlaceOrderButtonActivation){return}if(i){var s=document.querySelectorAll(i);var c=function(n){var e=n.target;if(e.getAttribute("disabled")){n.preventDefault();n.stopPropagation()}};s.forEach((function(n){var e=n.getAttribute("data-zonos-checkout-attached");if(e){return}if(o){n.setAttribute("disabled","true");n.addEventListener("click",c)}else{n.removeAttribute("disabled");n.removeEventListener("click",c)}}));if(t&&o){setTimeout((function(){s.forEach((function(n){n.removeAttribute("disabled");n.removeEventListener("click",c)}))}),5e3)}}};U.injectController=function(n){var o=n.config,i=n.zonosApiKey;var u;if(document.querySelector("zonos-controller")){return}if((u=o.checkoutSettings)===null||u===void 0?void 0:u.placeOrderButtonSelector){var s=o.checkoutSettings.placeOrderButtonSelector;g.disablePlaceOrderButtons({config:o,disable:true,placeOrderButtonSelector:s});var c=new MutationObserver((function(){g.disablePlaceOrderButtons({config:o,disable:true,placeOrderButtonSelector:s})}));c.observe(document.body,{childList:true,subtree:true})}var a=document.createElement("zonos-controller");a.config=o;a.zonosApiKey=i;a.addEventListener("stripeInitEvent",(function(n){return __awaiter(r,void 0,void 0,(function(){var r,o;return __generator(this,(function(i){switch(i.label){case 0:r=n.detail;e("loading Stripe");return[4,j(r.publishableKey)];case 1:o=i.sent();if(!o){t("API seems to be invalid or missing. Failed to load Stripe");return[2]}window.Zonos.stripe=o;void a.initCheckoutElement(o);return[2]}}))}))}));document.body.appendChild(a);g.zonosController=a;e("Zonos controller injected!")};U.injectScript=function(n){var r=n.cdnType,o=n.isModule,i=n.theRestUrl;var s=g.getZonosUrl(r);var c="".concat(s,"/").concat(i);var a=function(){var n=document.querySelector('script[src="'.concat(c,'"]'));return!!n};if(a()){e('Zonos script "'.concat(c,'" already exists in the document'),"warn");return}var l=document.head||document.body;var d=document.createElement("script");if(!!o){d.type="module"}else{d.noModule=true}d.src=c;d.crossOrigin="anonymous";d.onerror=function(){t("Failed to load ".concat(d.src));var n=u(r);if(!n){return}g.injectScript({cdnType:n,isModule:o,theRestUrl:i})};l.appendChild(d)};U.getZonosUrl=function(n){var e=function(){switch(n){case"jsdelivr":return S;case"unpkg":return O;case"cdnjs":return _;case"vercel":return k}};if(g.isNpm){var t=c();return t||e()}return e()};U.injectZonosCdn=function(){g.injectScript({cdnType:L,isModule:true,theRestUrl:"dist/zonos-elements/zonos-elements.esm.js"});g.injectScript({cdnType:L,isModule:false,theRestUrl:"dist/zonos-elements/zonos-elements.js"});e("Zonos cdn script injected!")};U.injectStylesheet=function(n){var e=n.cdnType,r=n.theRestUrl;var o=g.getZonosUrl(e);var i=document.head||document.body;var s=document.createElement("link");s.rel="preconnect";s.href="".concat(k,"/");i.appendChild(s);var c=document.createElement("link");c.rel="stylesheet";c.href="".concat(o,"/").concat(r);c.onerror=function(){t("Failed to load ".concat(c.href));var n=u(e);if(!n){return}g.injectStylesheet({cdnType:n,theRestUrl:r})};i.appendChild(c)};U.injectZonosCss=function(){var n=function(){return!!document.querySelector('link[rel="stylesheet"][href*="/dist/zonos-elements/zonos-elements.css"]')};if(n()){e("Zonos style links already injected","warn");return}g.injectStylesheet({cdnType:L,theRestUrl:"dist/zonos-elements/zonos-elements.css"});e("Zonos style css injected!")};U.injectFonts=function(){var n=function(){var n=document.querySelectorAll('link[rel="stylesheet"][href^="'.concat(N,'"]'));for(var e=0;e<n.length;e++){var t=n[e];if(!t){continue}if(R.test(t.href)){continue}return t}return null};if(n()){e("Inter font already injected","warn");return}var t=document.head||document.body;var r=document.createElement("link");r.rel="preconnect";r.href=N;t.appendChild(r);var o=document.createElement("link");o.rel="stylesheet";o.href="".concat(N,"/inter/inter.css");t.appendChild(o);e("Zonos font injected!")};U.setupGoogleFont=function(n){var e;void((e=g.zonosController)===null||e===void 0?void 0:e.setupGoogleFont(n))};U.injectSupportGoogleFont=function(n){var t;e("[FONT] injecting ".concat(n));var r=(t=n.match(/family=(.*?):/))===null||t===void 0?void 0:t[1];var o=document.head||document.body;if(!document.querySelector('link[rel="preconnect"][href^="'.concat(A,'"]'))){var i=document.createElement("link");i.rel="preconnect";i.href=A;o.appendChild(i)}if(document.querySelector('link[rel="stylesheet"][href="'.concat(n,'"]'))){e("[FONT] ".concat(r," font already injected"),"warn");return}var u=document.createElement("link");u.rel="stylesheet";u.href=n;o.appendChild(u);e("[FONT] ".concat(r," font injected!"))}}}}));
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(n,e,t,r){function o(n){return n instanceof t?n:new t((function(e){e(n)}))}return new(t||(t=Promise))((function(t,i){function u(n){try{c(r.next(n))}catch(n){i(n)}}function s(n){try{c(r["throw"](n))}catch(n){i(n)}}function c(n){n.done?t(n.value):o(n.value).then(u,s)}c((r=r.apply(n,e||[])).next())}))};var __generator=this&&this.__generator||function(n,e){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},r,o,i,u;return u={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(u[Symbol.iterator]=function(){return this}),u;function s(n){return function(e){return c([n,e])}}function c(s){if(r)throw new TypeError("Generator is already executing.");while(u&&(u=0,s[0]&&(t=0)),t)try{if(r=1,o&&(i=s[0]&2?o["return"]:s[0]?o["throw"]||((i=o["return"])&&i.call(o),0):o.next)&&!(i=i.call(o,s[1])).done)return i;if(o=0,i)s=[s[0]&2,i.value];switch(s[0]){case 0:case 1:i=s;break;case 4:t.label++;return{value:s[1],done:false};case 5:t.label++;o=s[1];s=[0];continue;case 7:s=t.ops.pop();t.trys.pop();continue;default:if(!(i=t.trys,i=i.length>0&&i[i.length-1])&&(s[0]===6||s[0]===2)){t=0;continue}if(s[0]===3&&(!i||s[1]>i[0]&&s[1]<i[3])){t.label=s[1];break}if(s[0]===6&&t.label<i[1]){t.label=i[1];i=s;break}if(i&&t.label<i[2]){t.label=i[2];t.ops.push(s);break}if(i[2])t.ops.pop();t.trys.pop();continue}s=e.call(n,t)}catch(n){s=[6,n];o=0}finally{r=i=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};System.register(["./p-63db40b9.system.js"],(function(n){"use strict";var e,t;return{setters:[function(n){e=n.l;t=n.a}],execute:function(){var r=this;var o=function(n){var e=n.loadScriptSrc;if(!e){return{currentLoadScriptUrl:"",isForceLoadVersionDomain:false,isWhiteListed:false}}var t=["dev.elements.zonos.com",".js.zonos.com","zonos-elements-test-git","zonos-elements-git"];var r=["qa.js.zonos.com"];var o=new URL(e).origin;var i=t.some((function(n){return o.includes(n)}));var u=r.some((function(n){return o.includes(n)}));return{currentLoadScriptUrl:o,isForceLoadVersionDomain:u,isWhiteListed:i}};var i=["jsdelivr","cdnjs","unpkg","vercel"];var u=function(n){var e=i.indexOf(n);var t=i[e+1];return t||null};var s=function(n){if(!n){return null}var e=new URL(n).searchParams;var t=e.get("zonosQaUrl");if(!t){return null}var r=/[^a-zA-Z0-9-_]+/.test(t);if(!!r){return null}return t};var c=function(){var n=window&&window.location.href.includes("forceLoadCdn");if(typeof window==="undefined"||n){return null}var t=s(window.location.href);var r="https://v1.3.51.js.zonos.com";if(!t&&(r.includes("test.")||r.includes("test-"))){return r}if(!t&&["dev.demo.elements.zonos.com"].includes(window.location.hostname)){return"https://dev.elements.zonos.com"}if(!t){return null}if(t==="dev-elements"){return"https://dev.elements.zonos.com"}var o="preview.js.zonos.com";var i="https://".concat(t,".").concat(o);e("[ZONOS-WARNING] using '".concat(i,"' for loading script"),"warn");void fetch(i).then((function(){window.sessionStorage.removeItem("zonos--checkout-session-id");window.sessionStorage.removeItem("zonos--client-secret")})).catch((function(){alert("[ZONOS-WARNING] '".concat(i,"' IS NO LONGER AVAILABLE. REMOVING zonosQaUrl PARAM AND RELOADING THE PAGE"));var n=new URLSearchParams(window.location.search);n.delete("zonosQaUrl");var e=window.location.pathname;var t="".concat(e,"?").concat(n.toString());window.history.replaceState(window.history.state,"",t);window.location.reload();return null}));return i};var a="https://js.stripe.com/v3";var l=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/;var d="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used";var f=function(){var n=document.querySelectorAll('script[src^="'.concat(a,'"]'));for(var e=0;e<n.length;e++){var t=n[e];if(!t){continue}if(!l.test(t.src)){continue}return t}return null};var v=null;var m=function(n){var e=n&&!n.advancedFraudSignals?"?advancedFraudSignals=false":"";var r=document.createElement("script");r.src="".concat(a).concat(e);var o=document.head||document.body;if(!o){t("Expected document.body not to be null. Stripe.js requires a <body> element.");return null}o.appendChild(r);return r};var w=function(n){if(v!==null){return v}v=new Promise((function(e,t){if(typeof window==="undefined"||typeof document==="undefined"){e(null);return}if(window.Stripe&&n){console.warn(d)}if(window.Stripe){e(window.Stripe);return}try{var r=f();if(r&&n){console.warn(d)}else if(!r){r=m(n)}r===null||r===void 0?void 0:r.addEventListener("load",(function(){if(window.Stripe){e(window.Stripe)}else{t(new Error("Stripe.js not available"))}}));r===null||r===void 0?void 0:r.addEventListener("error",(function(){t(new Error("Failed to load Stripe.js"))}))}catch(n){t(n);return}}));return v};var p=function(n,e){if(!n||!n._registerWrapper){return}n._registerWrapper({name:"stripe-js",startTime:e})};var h=function(n,e,t){if(n===null){return null}var r=n.apply(undefined,e);p(r,t);return r};var y=Promise.resolve().then((function(){return w(null)}));var z=false;y.catch((function(n){if(!z){console.warn(n)}}));var j=function(){var n=[];for(var e=0;e<arguments.length;e++){n[e]=arguments[e]}return __awaiter(r,void 0,void 0,(function(){var e;return __generator(this,(function(t){z=true;e=Date.now();return[2,y.then((function(t){return h(t,n,e)}))]}))}))};var g;var b=function(){if(typeof document==="undefined"){return null}var n=document.querySelector('script[src*="/zonos.js"]');var e=o({loadScriptSrc:n===null||n===void 0?void 0:n.src}),t=e.currentLoadScriptUrl,r=e.isWhiteListed;if(r){return t}return null}();var k="https://v1.3.51.js.zonos.com";var S=b||"https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.51";var O="https://unpkg.com/@zonos/elements@1.3.51";var _="https://cdnjs.cloudflare.com/ajax/libs/zonos-elements/1.3.51";var L="jsdelivr";var N="https://rsms.me";var A="https://fonts.googleapis.com";var R=/^https:\/\/rsms\.me\/inter\/inter\.css(.*)$/;var U=function(){function n(){}return n}();n("Zonos",U);g=U;U.doneInit=false;U.debug=typeof window!=="undefined"&&!!window.location.search.match(/\?.*(&*)zonosDebug=1/);U.zonosConversionTest=typeof window!=="undefined"&&!!window.location.search.match(/\?.*(&*)zonosConversionTest/);U._paypalMockResponse=null;U.isBigCommerce=false;U.releaseDate="1726523859808";U.isNpm=true;U.zonosQaUrl=null;U.version="v".concat("1.3.51");U.modeAlerted=false;U.tempCartData=null;U.paypal=null;U.getCurrentTimestamp=function(){return(new Date).getTime()};U.zonosController=null;U.init=function(n){return __awaiter(r,[n],void 0,(function(n){var r=n.appearance,o=n.checkoutSettings,i=n.currencyConverter,u=n.helloSettings,s=n.onCountryChange,c=n.overrideCurrencyFormat,a=n.storeId,l=n.zonosApiKey;return __generator(this,(function(n){if(g.doneInit){return[2]}e("====== ZONOS DEBUG MODE: on (".concat(g.version,") ======"));if(!l){t("Missing Zonos API key");return[2]}g.zonosApiKey=l;g.storeId=a;e("init zonos");g.injectZonosCdn();g.injectZonosCss();g.injectFonts();g.injectController({config:{appearance:r,checkoutSettings:o,currencyConverter:i,helloSettings:u,onCountryChange:s,overrideCurrencyFormat:c},zonosApiKey:l});g.doneInit=true;return[2]}))}))};U.displayCurrency=function(){var n=document.querySelector("zonos-hello");if(n){void n.displayCurrency()}};U.openHelloDialog=function(n){var e=document.querySelector("zonos-hello");if(e){void e.openHelloDialog(n!==null&&n!==void 0?n:true)}};U.showNotification=function(n){var e;void((e=g.zonosController)===null||e===void 0?void 0:e.showNotification(n))};U.updateOrganizationName=function(n){var e;void((e=g.zonosController)===null||e===void 0?void 0:e.updateOrganizationName(n))};U.disablePlaceOrderButtons=function(n){var e=n.autoEnable,t=e===void 0?true:e,r=n.config,o=n.disable,i=n.placeOrderButtonSelector;var u;if((u=r.checkoutSettings)===null||u===void 0?void 0:u.disablePlaceOrderButtonActivation){return}if(i){var s=document.querySelectorAll(i);var c=function(n){var e=n.target;if(e.getAttribute("disabled")){n.preventDefault();n.stopPropagation()}};s.forEach((function(n){var e=n.getAttribute("data-zonos-checkout-attached");if(e){return}if(o){n.setAttribute("disabled","true");n.addEventListener("click",c)}else{n.removeAttribute("disabled");n.removeEventListener("click",c)}}));if(t&&o){setTimeout((function(){s.forEach((function(n){n.removeAttribute("disabled");n.removeEventListener("click",c)}))}),5e3)}}};U.injectController=function(n){var o=n.config,i=n.zonosApiKey;var u;if(document.querySelector("zonos-controller")){return}if((u=o.checkoutSettings)===null||u===void 0?void 0:u.placeOrderButtonSelector){var s=o.checkoutSettings.placeOrderButtonSelector;g.disablePlaceOrderButtons({config:o,disable:true,placeOrderButtonSelector:s});var c=new MutationObserver((function(){g.disablePlaceOrderButtons({config:o,disable:true,placeOrderButtonSelector:s})}));c.observe(document.body,{childList:true,subtree:true})}var a=document.createElement("zonos-controller");a.config=o;a.zonosApiKey=i;a.addEventListener("stripeInitEvent",(function(n){return __awaiter(r,void 0,void 0,(function(){var r,o;return __generator(this,(function(i){switch(i.label){case 0:r=n.detail;e("loading Stripe");return[4,j(r.publishableKey)];case 1:o=i.sent();if(!o){t("API seems to be invalid or missing. Failed to load Stripe");return[2]}window.Zonos.stripe=o;void a.initCheckoutElement(o);return[2]}}))}))}));document.body.appendChild(a);g.zonosController=a;e("Zonos controller injected!")};U.injectScript=function(n){var r=n.cdnType,o=n.isModule,i=n.theRestUrl;var s=g.getZonosUrl(r);var c="".concat(s,"/").concat(i);var a=function(){var n=document.querySelector('script[src="'.concat(c,'"]'));return!!n};if(a()){e('Zonos script "'.concat(c,'" already exists in the document'),"warn");return}var l=document.head||document.body;var d=document.createElement("script");if(!!o){d.type="module"}else{d.noModule=true}d.src=c;d.crossOrigin="anonymous";d.onerror=function(){t("Failed to load ".concat(d.src));var n=u(r);if(!n){return}g.injectScript({cdnType:n,isModule:o,theRestUrl:i})};l.appendChild(d)};U.getZonosUrl=function(n){var e=function(){switch(n){case"jsdelivr":return S;case"unpkg":return O;case"cdnjs":return _;case"vercel":return k}};if(g.isNpm){var t=c();return t||e()}return e()};U.injectZonosCdn=function(){g.injectScript({cdnType:L,isModule:true,theRestUrl:"dist/zonos-elements/zonos-elements.esm.js"});g.injectScript({cdnType:L,isModule:false,theRestUrl:"dist/zonos-elements/zonos-elements.js"});e("Zonos cdn script injected!")};U.injectStylesheet=function(n){var e=n.cdnType,r=n.theRestUrl;var o=g.getZonosUrl(e);var i=document.head||document.body;var s=document.createElement("link");s.rel="preconnect";s.href="".concat(k,"/");i.appendChild(s);var c=document.createElement("link");c.rel="stylesheet";c.href="".concat(o,"/").concat(r);c.onerror=function(){t("Failed to load ".concat(c.href));var n=u(e);if(!n){return}g.injectStylesheet({cdnType:n,theRestUrl:r})};i.appendChild(c)};U.injectZonosCss=function(){var n=function(){return!!document.querySelector('link[rel="stylesheet"][href*="/dist/zonos-elements/zonos-elements.css"]')};if(n()){e("Zonos style links already injected","warn");return}g.injectStylesheet({cdnType:L,theRestUrl:"dist/zonos-elements/zonos-elements.css"});e("Zonos style css injected!")};U.injectFonts=function(){var n=function(){var n=document.querySelectorAll('link[rel="stylesheet"][href^="'.concat(N,'"]'));for(var e=0;e<n.length;e++){var t=n[e];if(!t){continue}if(R.test(t.href)){continue}return t}return null};if(n()){e("Inter font already injected","warn");return}var t=document.head||document.body;var r=document.createElement("link");r.rel="preconnect";r.href=N;t.appendChild(r);var o=document.createElement("link");o.rel="stylesheet";o.href="".concat(N,"/inter/inter.css");t.appendChild(o);e("Zonos font injected!")};U.setupGoogleFont=function(n){var e;void((e=g.zonosController)===null||e===void 0?void 0:e.setupGoogleFont(n))};U.injectSupportGoogleFont=function(n){var t;e("[FONT] injecting ".concat(n));var r=(t=n.match(/family=(.*?):/))===null||t===void 0?void 0:t[1];var o=document.head||document.body;if(!document.querySelector('link[rel="preconnect"][href^="'.concat(A,'"]'))){var i=document.createElement("link");i.rel="preconnect";i.href=A;o.appendChild(i)}if(document.querySelector('link[rel="stylesheet"][href="'.concat(n,'"]'))){e("[FONT] ".concat(r," font already injected"),"warn");return}var u=document.createElement("link");u.rel="stylesheet";u.href=n;o.appendChild(u);e("[FONT] ".concat(r," font injected!"))}}}}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as o,h as s,H as n,d as t,c as a}from"./p-5b7da777.js";import{d as e}from"./p-9dd6b00d.js";import{c as i}from"./p-b4b7f705.js";import{k as p}from"./p-
|
|
1
|
+
import{r as o,h as s,H as n,d as t,c as a}from"./p-5b7da777.js";import{d as e}from"./p-9dd6b00d.js";import{c as i}from"./p-b4b7f705.js";import{k as p}from"./p-d413cd13.js";import{a as c,l as m}from"./p-eaa335e1.js";import{d as l}from"./p-aa5d669b.js";import"./p-23a84835.js";import"./p-f05f3e27.js";const r=class{constructor(s){o(this,s),this.notificationArray=[]}async showNotification(o){const s=`id-${Math.random().toString(36).substring(2,9)}`,n=Object.assign(Object.assign({},o),{id:s,timeout:o.timeout||5e3,transitionClass:"",type:o.type||"success"});this.notificationArray=[...this.notificationArray,n],setTimeout((()=>{this.updateTransitionClass({id:s,transitionClass:"show"})}),50),setTimeout((()=>{this.removeNotification(s)}),n.timeout)}updateTransitionClass({id:o,transitionClass:s}){this.notificationArray=this.notificationArray.map((n=>n.id===o?Object.assign(Object.assign({},n),{transitionClass:s}):n))}removeNotification(o){this.updateTransitionClass({id:o,transitionClass:""}),setTimeout((()=>{this.notificationArray=this.notificationArray.filter((s=>s.id!==o))}),300)}render(){return s(n,{key:"17c08c90c6c1dfade4e43451c196127a0f53429e",class:i(["zonos--elements zonos--notification"]),style:{"--font-family":e()}},s("div",{key:"6624419d86a5c7518539069dbc5c9d7c08262c75",class:"zonos--notification-items"},this.notificationArray.map((o=>s("div",{"aria-hidden":"true",class:i(["zonos--notification-item",o.type,o.transitionClass]),key:o.id,onClick:()=>{this.removeNotification(o.id)}},s("zonos-text",{textColor:"gray-0"},o.message))))))}};r.style=":host{font-family:var(--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .zonos--notification-items{position:fixed;z-index:9999999999;bottom:24px;gap:8px;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-direction:column;flex-direction:column}:host .zonos--notification-item{cursor:pointer;-webkit-transition:all 0.3s ease;transition:all 0.3s ease;padding:8px;border-radius:var(--border-radius, var(--zonos-elements-radius-6));opacity:0;-ms-flex-negative:0.0001;flex-shrink:0.0001;-webkit-transform:translateY(100%);transform:translateY(100%)}:host .zonos--notification-item+:host .zonos--notification-item{margin-top:8px}:host .zonos--notification-item.show{opacity:1;-webkit-transform:translateY(0);transform:translateY(0);-ms-flex-positive:1000;flex-grow:1000}:host .zonos--notification-item.success{background-color:var(--zonos-elements-green-700)}:host .zonos--notification-item.error{background-color:var(--zonos-elements-red-700)}:host .zonos--notification-item.warning{background-color:var(--zonos-elements-orange-700)}";const y=class{constructor(s){o(this,s),this.titleText=void 0,this.stripe=p.stripe,this.stripeElements=p.stripeElements}watchInitStripe(){if(!this.stripeElements)return;const o=p.stripePaymentElement||this.stripeElements.create("payment",{layout:"accordion"}),s=this.el.querySelector(".zonos--payment-component");s?(o.mount(s),o.on("change",(o=>{p.stripePaymentEventData=o})),p.stripePaymentElement=o):c("Cannot find container element for paymentElement")}componentDidLoad(){this.watchInitStripe()}render(){return s(n,{key:"ab601d9a0cc6fe2fee19f45d6321dcc81b418cff",class:"zonos--payment zonos--elements"},this.titleText&&s("zonos-text",{key:"27857c99c59e4913fa403ef5b23b5b7d7f32bd45",class:"zonos--title",type:"semiBoldLabel"},this.titleText),s("div",{key:"329b5a5617f0c5942b209df1ccf3bfcb4ddabb0c",class:"zonos--payment-component"}),s("div",{key:"7abb08922e9f607314713fc9fa762a3bb8a35b13",class:"zonos--payment-paypal-container"}))}get el(){return t(this)}static get watchers(){return{stripeElements:["watchInitStripe"],stripe:["watchInitStripe"]}}};y.style=".sc-zonos-payment-h{font-family:var(--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-payment-h *.sc-zonos-payment{font-family:var(--font-family, Inter), Inter}.sc-zonos-payment-h img.sc-zonos-payment{max-width:100%}.sc-zonos-payment-h dl.sc-zonos-payment,.sc-zonos-payment-h dd.sc-zonos-payment,.sc-zonos-payment-h h1.sc-zonos-payment,.sc-zonos-payment-h h2.sc-zonos-payment,.sc-zonos-payment-h h3.sc-zonos-payment,.sc-zonos-payment-h h4.sc-zonos-payment,.sc-zonos-payment-h h5.sc-zonos-payment,.sc-zonos-payment-h h6.sc-zonos-payment,.sc-zonos-payment-h hr.sc-zonos-payment,.sc-zonos-payment-h figure.sc-zonos-payment,.sc-zonos-payment-h p.sc-zonos-payment,.sc-zonos-payment-h pre.sc-zonos-payment{margin:0}.sc-zonos-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-payment-h .zonos--title.sc-zonos-payment{margin-bottom:16px}";const h=class{constructor(s){o(this,s),this.paypalSessionDone=a(this,"paypalSessionDone",7),this.paypalSessionFail=a(this,"paypalSessionFail",7)}async loadPaypal(){if(!window.Zonos.paypal)return void m("Paypal is not available");const o=l({onPaypalFail:()=>{m("onPaypalFail"),this.paypalSessionFail.emit()},onPaypalSessionDone:({orderId:o})=>{m("onPaypalSessionDone","info",{orderId:o}),this.paypalSessionDone.emit({orderId:o})}});if(!(null==o?void 0:o.length))return void m("There are no paypal buttons available");const s=this.el.querySelector(".zonos--payment-paypal-container");s?o.forEach((async o=>{await o.render(s)})):m("Cannot find container element for paypal buttons")}componentDidLoad(){this.loadPaypal()}render(){return s(n,{key:"a09fe5b66b1ac971c10529ecb6213479f2870f08",class:"zonos--paypal-payment zonos--elements"},s("div",{key:"6ba337785b8a90965e0cba05fd62681bc92633fe",class:"zonos--payment-paypal-container"}))}get el(){return t(this)}};h.style=".sc-zonos-paypal-payment-h{font-family:var(--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-paypal-payment-h *.sc-zonos-paypal-payment{font-family:var(--font-family, Inter), Inter}.sc-zonos-paypal-payment-h img.sc-zonos-paypal-payment{max-width:100%}.sc-zonos-paypal-payment-h dl.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h dd.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h h1.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h h2.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h h3.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h h4.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h h5.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h h6.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h hr.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h figure.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h p.sc-zonos-paypal-payment,.sc-zonos-paypal-payment-h pre.sc-zonos-paypal-payment{margin:0}.sc-zonos-paypal-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-paypal-payment-h{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-direction:column;flex-direction:column}";export{r as zonos_notification,y as zonos_payment,h as zonos_paypal_payment}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e,b as o}from"./p-5b7da777.js";export{s as setNonce}from"./p-5b7da777.js";import{g as t}from"./p-e1255160.js";(()=>{const o=import.meta.url,t={};return""!==o&&(t.resourcesUrl=new URL(".",o).href),e(t)})().then((async e=>(await t(),o([["p-
|
|
1
|
+
import{p as e,b as o}from"./p-5b7da777.js";export{s as setNonce}from"./p-5b7da777.js";import{g as t}from"./p-e1255160.js";(()=>{const o=import.meta.url,t={};return""!==o&&(t.resourcesUrl=new URL(".",o).href),e(t)})().then((async e=>(await t(),o([["p-ba0289f9",[[2,"zonos-checkout",{appearanceSettingsOverride:[16],preview:[4],mobile:[4],defaultAddress:[16],forceDialogOpen:[4,"force-dialog-open"],open:[32],stripe:[32],submitLoading:[32],collapseReviewMobile:[32],isAttachError:[32],isMobile:[32],zonosReviewRef:[32],storybookPaymentStatusOverride:[32],domesticRedirectedBtnSelector:[32],legacyCheckoutHiddenBtnSelector:[32],isLegacyCheckout:[32],confirmDialogOpen:[32],inventoryCheckErrorMessage:[32],closeDialogHandler:[64],init:[64],setToFinishStep:[64]},[[16,"zonos--init-cart-info","initCartInfoHandler"],[4,"keydown","handleKeyPress"],[9,"resize","handleWindowResize"]],{appearanceSettingsOverride:["appearanceSettingsOverrideChanged","handleAppearanceSettingsOverrideChange"],mobile:["handleMobileChange"],defaultAddress:["handleAddressChange"]}]]],["p-9e976332",[[1,"zonos-hello",{mobileLocationOverride:[1,"mobile-location-override"],animateFromLeftOverride:[4,"animate-from-left-override"],appearanceSettingsOverride:[16],showPeekMessage:[32],zonosStoreHelloSettings:[32],showDialog:[32],peekMessage:[32],initialUrl:[32],allRestrictedItems:[32],allFoundProducts:[32],productsOnPage:[32],isHelloWidgetRendered:[32],isMobile:[32],getCountryList:[64],displayCurrency:[64],convertAndFormat:[64],convert:[64],format:[64],openHelloDialog:[64]},[[9,"resize","handleResize"]],{appearanceSettingsOverride:["handleAppearanceSettingsOverrideChange"]}]]],["p-8b8ef484",[[1,"zonos-controller",{config:[16],zonosApiKey:[1,"zonos-api-key"],initCheckoutElement:[64],setupGoogleFont:[64],showNotification:[64],reset:[64],overrideConfig:[64],overrideCountry:[64],getAppearanceSetting:[64],updateOrganizationName:[64]},[[8,"locationchange","handleLocationChange"]]]]],["p-6de38759",[[1,"zonos-component",{first:[1],middle:[1],last:[1]}]]],["p-25633055",[[1,"zonos-link",{href:[1],rel:[1],target:[1],linkTitle:[1,"link-title"]}]]],["p-70bb4a25",[[1,"zonos-logo",{theme:[1],width:[1]}]]],["p-5f7f51bd",[[1,"zonos-text",{textColor:[1,"text-color"],size:[1],type:[1],weight:[2],ready:[32]}]]],["p-101c41bf",[[1,"zonos-hello-dialog",{isOpen:[4,"is-open"],setIsOpen:[16],mobileLocationOverride:[1,"mobile-location-override"],animateFromLeftOverride:[4,"animate-from-left-override"],appearanceSettings:[16],restrictedItems:[16],welcomeMessage:[32],showCountrySelect:[32],showLanguageSelect:[32]},[[4,"click","globalClickHandler"]],{isOpen:["isOpenHandler"]}]]],["p-cf9a46e8",[[1,"zonos-shipping-rich-radio",{items:[16],borderColor:[1,"border-color"],borderStyle:[1,"border-style"],theme:[1],initialSelectedValue:[8,"initial-selected-value"],selectedItem:[32]}]]],["p-6013e370",[[1,"zonos-badge",{bold:[4],badgeColor:[1,"badge-color"],icon:[16],iconRight:[4,"icon-right"],size:[1],rounded:[4]}],[1,"zonos-tooltip",{label:[1],subtitle:[1],showTooltip:[32]}]]],["p-a4309beb",[[1,"zonos-input",{inputValue:[1,"input-value"],inputLabel:[1,"input-label"],inputSize:[1,"input-size"],isDisabled:[4,"is-disabled"],isError:[4,"is-error"],inputPlaceholder:[1,"input-placeholder"],value:[32]},null,{inputValue:["onInputValueChange"]}]]],["p-8e9dcaa3",[[1,"zonos-card",{actions:[16],backgroundColor:[1,"background-color"],borderRadius:[2,"border-radius"],footerActions:[16],footerContent:[16],footerHeight:[2,"footer-height"],label:[16],spacing:[1]}]]],["p-ffd76226",[[2,"zonos-payment",{titleText:[1,"title-text"],stripe:[32],stripeElements:[32]},null,{stripeElements:["watchInitStripe"],stripe:["watchInitStripe"]}],[2,"zonos-paypal-payment"],[1,"zonos-notification",{notificationArray:[32],showNotification:[64]}]]],["p-6dcef5ce",[[1,"zonos-banner",{bannerTitle:[1,"banner-title"],intent:[1],hasContent:[32]}]]],["p-cc7a4fca",[[1,"zonos-country-flag",{countryCode:[1,"country-code"],size:[2]}]]],["p-eb3520e7",[[1,"zonos-v-stack",{spacing:[2]}]]],["p-54f66cd1",[[17,"zonos-button",{buttonColor:[1,"button-color"],backgroundColor:[1,"background-color"],borderStyle:[1,"border-style"],isDisabled:[4,"is-disabled"],icon:[16],iconRight:[4,"icon-right"],size:[1],variant:[1],noBackground:[4,"no-background"],withBoxShadow:[4,"with-box-shadow"],noPaddingLeft:[4,"no-padding-left"],noPaddingRight:[4,"no-padding-right"],loading:[4],justifyContent:[1,"justify-content"],theme:[1],hasIcon:[32],hasContent:[32]},[[2,"click","clickHandler"]],{icon:["iconChangeHandler"]}],[1,"zonos-spinner",{size:[2],spinnerColor:[1,"spinner-color"]}],[1,"zonos-icon",{autoHeight:[4,"auto-height"],iconColor:[1,"icon-color"],content:[1],size:[2]}]]],["p-5e56828a",[[1,"zonos-language-select",{handleOnClose:[16]}],[1,"zonos-select-dialog-header",{handleOnClose:[16],label:[1]}]]],["p-58d9803d",[[1,"zonos-country-select",{handleOnClose:[16],inputValue:[32]}],[1,"zonos-hello-dialog-footer",{appearanceSettings:[16],setShowCountrySelect:[16],setShowLanguageSelect:[16]}],[1,"zonos-custom-message",{icon:[1],message:[1]}],[2,"zonos-virtual-scroll",{renderItem:[16],itemWidth:[2,"item-width"],fallbackItemHeight:[2,"fallback-item-height"],itemHeights:[16],container:[32],scrollTop:[32],totalHeight:[32]},null,{itemHeights:["updateTotalHeight"],fallbackItemHeight:["updateTotalHeight"]}]]],["p-9a0401fd",[[1,"zonos-address-update-dialog",{continueLoading:[4,"continue-loading"],dialogLoading:[4,"dialog-loading"],dialogOpen:[4,"dialog-open"],submitBtnType:[1,"submit-btn-type"],submitBtnColor:[1,"submit-btn-color"],isMobile:[4,"is-mobile"],shippingAddress:[16],billingAddress:[16],translatedShippingAddress:[16],translatedBillingAddress:[16],showErrorBanner:[32],translatedShippingAddressState:[32],translatedBillingAddressState:[32]},null,{translatedShippingAddress:["watchTranslatedShippingAddress"],translatedBillingAddress:["watchTranslatedBillingAddress"]}],[2,"zonos-address",{type:[1],titleText:[1,"title-text"],defaultAddress:[16],stripe:[32],isDirtyAddress:[32]},null,{stripe:["watchInitStripe"]}],[1,"zonos-checkbox",{backgroundColor:[1,"background-color"],label:[1],isChecked:[4,"is-checked"],isDisabled:[4,"is-disabled"],size:[2],fontSize:[1,"font-size"],borderStyle:[1,"border-style"]},[[1,"click","onClick"]]],[2,"zonos-link-authentication",{titleText:[1,"title-text"],defaultEmail:[1,"default-email"],stripe:[32]},null,{stripe:["watchInitStripe"]}],[1,"zonos-dialog",{open:[4],headerText:[1,"header-text"],width:[1],height:[1],minHeight:[1,"min-height"],noHeader:[4,"no-header"],noBodyPadding:[4,"no-body-padding"],noBorder:[4,"no-border"],borderStyle:[1,"border-style"],noCloseButton:[4,"no-close-button"],noClickOutside:[4,"no-click-outside"],mobile:[4],isLoading:[4,"is-loading"],isMobile:[32]},[[9,"resize","handleWindowResize"],[4,"keydown","handleKeyDown"]]],[1,"zonos-address-display",{currentAddress:[16],addressType:[1,"address-type"]}],[1,"zonos-address-form",{currentAddress:[16],translatedAddress:[16],addressType:[1,"address-type"],localAddress:[32]},null,{translatedAddress:["watchCurrentAddress"]}],[1,"zonos-collapse",{collapsed:[4],collapseSize:[2,"collapse-size"],height:[32],iframe:[32]}]]],["p-b57d24f2",[[2,"zonos-customer-info",{continueLoading:[4,"continue-loading"],submitBtnType:[1,"submit-btn-type"],submitBtnColor:[1,"submit-btn-color"],isMobile:[4,"is-mobile"],defaultAddress:[16],showErrorBanner:[32],shippingCountry:[32],isCheckingForRestrictedItems:[32],isValidatingAddress:[32],invalidShippingCharacterList:[32],invalidBillingCharacterList:[32],openAddressValidationDialog:[32]}],[2,"zonos-checkout-payment",{submitBtnType:[1,"submit-btn-type"],continueLoading:[4,"continue-loading"],submitBtnColor:[1,"submit-btn-color"],showErrorBanner:[32]}],[1,"zonos-checkout-footer",{mobile:[4],dataTheme:[1,"data-theme"],showLanguageDialog:[32],isMobile:[32]},[[4,"click","handleGlobalClick"]],{mobile:["handleMobileChange"]}],[2,"zonos-shipping",{continueLoading:[4,"continue-loading"],submitBtnColor:[1,"submit-btn-color"],submitBtnType:[1,"submit-btn-type"],selectedShippingMethod:[32],isSelecting:[32],showErrorBanner:[32],serviceLevels:[32]}],[1,"zonos-cart-restricted-items",{hide:[4],errorImages:[32],internalCollapsed:[32],firstRender:[32]}],[1,"zonos-cart-subtotal"],[1,"zonos-checkout-finish",{borderRadius:[1,"border-radius"],storybookForceStatus:[1,"storybook-force-status"],overrideNotification:[16],isLoading:[32],notificationType:[32],notificationTitle:[32],notificationMessages:[32],notificationActionText:[32],order:[32]}],[1,"zonos-confirm-dialog",{dialogTitle:[1,"dialog-title"],dialogIntent:[1,"dialog-intent"],dialogSubtitle:[1,"dialog-subtitle"],submitBtnColor:[1,"submit-btn-color"],dialogConfirmBtnText:[1,"dialog-confirm-btn-text"],dialogCancelBtnText:[1,"dialog-cancel-btn-text"],dialogType:[1,"dialog-type"],isMobile:[4,"is-mobile"],dialogOpen:[4,"dialog-open"],noClickOutside:[4,"no-click-outside"]},[[4,"keydown","handleKeyDown"]]],[1,"zonos-checkout-progress-tabs",{tabColor:[1,"tab-color"],backgroundColor:[1,"background-color"],setTabItems:[64],setTabSelected:[64]}],[1,"zonos-review",{mobile:[4],collapsed:[4],isMobile:[32]},[[9,"resize","handleWindowResize"]]],[1,"zonos-cart-items",{errorImages:[32]}],[1,"zonos-rest-state",{restStateSubtitle:[1,"rest-state-subtitle"],restStateTitle:[1,"rest-state-title"],restStateType:[1,"rest-state-type"],isErrorImageLoad:[32]}]]]],e))));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zonos/elements",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.51",
|
|
4
4
|
"description": "Zonos component UI for Stripe elements",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "dist/index.cjs.js",
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
"dist/",
|
|
21
21
|
"loader/"
|
|
22
22
|
],
|
|
23
|
+
"packageManager": "pnpm@8.15.8",
|
|
23
24
|
"scripts": {
|
|
24
25
|
"build": "pnpm build:css && mkdir -p dist && pnpm build:components && pnpm build:scripts && pnpm css:copy",
|
|
25
26
|
"build:components": "stencil build --docs",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{x as o,e as n,l as t}from"./p-2018969a.js";import{z as e}from"./p-9dd6b00d.js";const i=async(i,a)=>{var s,d;if((window.location.href.includes("zonos.com")||window.location.href.includes("checkout.iglobalstores.com")||(null===(s=window.Zonos)||void 0===s?void 0:s.zonosQaUrl)||(null===(d=window.Zonos)||void 0===d?void 0:d.debug))&&!window.Zonos.zonosConversionTest)return;const r=n.checkoutSessionId;if(!r)return;const c={checkoutSessionId:r,countryCode:t.selectedCountryCode,eventName:i,metadata:a,organizationId:e.organizationId};await o("/api/zonos-elements/track-conversion-event",{body:c,method:"POST"})},a=()=>{var o;return null===(o=window.Zonos.zonosApiKey)||void 0===o?void 0:o.includes("test")},s=(o,n)=>new CustomEvent(o,{detail:n});export{s as c,a as g,i as t}
|