@zonos/elements 1.2.1 → 1.2.2
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-7b70853c.js → cart-d4b52ae8.js} +1 -1
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/{localization-387a8a65.js → localization-d7fe7290.js} +40 -13
- package/dist/cjs/{submitGtag-bf6e7c5e.js → submitGtag-d65003f9.js} +1 -1
- package/dist/cjs/zonos-address_2.cjs.entry.js +7 -2
- package/dist/cjs/zonos-cart-items_10.cjs.entry.js +6 -7
- package/dist/cjs/zonos-checkout.cjs.entry.js +4 -4
- package/dist/cjs/zonos-controller.cjs.entry.js +2 -2
- package/dist/cjs/zonos-country-flag_4.cjs.entry.js +1 -1
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +15 -7
- package/dist/cjs/zonos-hello.cjs.entry.js +1 -1
- package/dist/cjs/zonos-payment.cjs.entry.js +2 -2
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.css +2 -2
- package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +3 -5
- package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +15 -7
- package/dist/collection/components/store/hello/localization.js +31 -9
- package/dist/collection/components/stripe/zonos-address/zonos-address.js +5 -0
- package/dist/collection/components/utils/api/getExchangeRate.js +9 -4
- package/dist/components/localization.js +40 -13
- package/dist/components/zonos-address2.js +5 -0
- package/dist/components/zonos-checkout.js +1 -1
- package/dist/components/zonos-hello-dialog2.js +15 -7
- package/dist/components/zonos-shipping2.js +4 -5
- package/dist/esm/{cart-07091d2a.js → cart-e1b93711.js} +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/{localization-b3c2a9a9.js → localization-f3828793.js} +40 -13
- package/dist/esm/{submitGtag-c0b655ad.js → submitGtag-a901ece5.js} +1 -1
- package/dist/esm/zonos-address_2.entry.js +7 -2
- package/dist/esm/zonos-cart-items_10.entry.js +6 -7
- package/dist/esm/zonos-checkout.entry.js +4 -4
- package/dist/esm/zonos-controller.entry.js +2 -2
- package/dist/esm/zonos-country-flag_4.entry.js +1 -1
- package/dist/esm/zonos-hello-dialog.entry.js +15 -7
- package/dist/esm/zonos-hello.entry.js +1 -1
- package/dist/esm/zonos-payment.entry.js +2 -2
- package/dist/esm-es5/{cart-07091d2a.js → cart-e1b93711.js} +1 -1
- package/dist/esm-es5/index.js +1 -1
- package/dist/esm-es5/{localization-b3c2a9a9.js → localization-f3828793.js} +1 -1
- package/dist/esm-es5/{submitGtag-c0b655ad.js → submitGtag-a901ece5.js} +1 -1
- package/dist/esm-es5/zonos-address_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_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-payment.entry.js +1 -1
- package/dist/scripts/loadZonos.js +3 -3
- package/dist/scripts/zonos.js +3 -3
- package/dist/types/components/store/hello/localization.d.ts +2 -0
- package/dist/types/components/utils/api/getExchangeRate.d.ts +9 -3
- package/dist/types/components/utils/changeDeepProperty.d.ts +1 -1
- package/dist/types/components/utils/changeDeepPropertyAtIndex.d.ts +1 -1
- package/dist/types/types/generated/graphql.customer.types.d.ts +1 -0
- package/dist/types/types/generated/graphql.customer.types.ts +1 -0
- package/dist/zonos-elements/assets/RemoveIcon.svg +1 -1
- package/dist/zonos-elements/index.esm.js +1 -1
- package/dist/zonos-elements/{p-37db3842.system.entry.js → p-05256415.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-42ba069d.system.js → p-164fae93.system.js} +1 -1
- package/dist/zonos-elements/{p-30fd29fb.js → p-25db3885.js} +1 -1
- package/dist/zonos-elements/{p-9dc9cbc8.entry.js → p-28681677.entry.js} +1 -1
- package/dist/zonos-elements/{p-d43749bd.entry.js → p-34a49bce.entry.js} +1 -1
- package/dist/zonos-elements/p-365970ff.entry.js +1 -0
- package/dist/zonos-elements/p-3f3fbcea.entry.js +1 -0
- package/dist/zonos-elements/p-40083e93.system.entry.js +1 -0
- package/dist/zonos-elements/{p-98105ede.entry.js → p-40778e43.entry.js} +1 -1
- package/dist/zonos-elements/{p-b64bbf38.system.js → p-53649e16.system.js} +1 -1
- package/dist/zonos-elements/{p-0a788f68.entry.js → p-5d7ffddb.entry.js} +1 -1
- package/dist/zonos-elements/{p-87f324c5.entry.js → p-60821b2a.entry.js} +1 -1
- package/dist/zonos-elements/{p-bb36a9f8.js → p-770c959e.js} +1 -1
- package/dist/zonos-elements/{p-0f7233fd.system.entry.js → p-81c699f7.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-f23749e4.system.js → p-8aabbb9b.system.js} +1 -1
- package/dist/zonos-elements/{p-79f9e330.system.js → p-8db8cc05.system.js} +1 -1
- package/dist/zonos-elements/{p-9b86e655.system.entry.js → p-a3641931.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-a20b97e9.system.entry.js → p-aca66238.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-c28157ec.system.entry.js → p-c8ad044e.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-343071d5.entry.js → p-cc070c1c.entry.js} +1 -1
- package/dist/zonos-elements/{p-4524a84f.system.entry.js → p-cc1c785c.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-23b0b4a2.system.entry.js → p-de9d8a4f.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-6df1eaee.js → p-f7875c40.js} +1 -1
- package/dist/zonos-elements/p-f8491335.system.js +1 -1
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +1 -1
- package/dist/zonos-elements/p-2c20c082.entry.js +0 -1
- package/dist/zonos-elements/p-37fc9f6b.entry.js +0 -1
- package/dist/zonos-elements/p-9adf546f.system.entry.js +0 -1
|
@@ -60,7 +60,7 @@ import type { IDeepKeyofAtIndex, IDeepPropertyTypeAtIndex } from "../../types/in
|
|
|
60
60
|
},
|
|
61
61
|
};
|
|
62
62
|
*/
|
|
63
|
-
export declare const changeDeepPropertyAtIndex: <T extends object, P extends IDeepKeyofAtIndex<T, Depth>, Depth extends 0 | 8 | 1 | 2 |
|
|
63
|
+
export declare const changeDeepPropertyAtIndex: <T extends object, P extends IDeepKeyofAtIndex<T, Depth>, Depth extends 0 | 8 | 1 | 2 | 5 | 3 | 4 | 6 | 7 | 9 = 4>({ index, obj, propertyPath, value, }: {
|
|
64
64
|
index: number;
|
|
65
65
|
obj: T;
|
|
66
66
|
propertyPath: P;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
<svg color="var(--amino-
|
|
1
|
+
<svg color="var(--amino-gray-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" data-is-secondary-color="true" fill="var(--amino-gray-200)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{c as cartStore,a as cartStoreApplySubtotals,b as cartStoreGetShippingTransitInfo,d as cartStoreNextStep,e as cartStorePreviousStep,f as cartStoreReCalculateTotal,g as cartStoreReset,h as cartStoreUpdateItems,i as cartStoreUpdateSelectedShippingOption,j as cartStoreUpdateToErrorState}from"./p-
|
|
1
|
+
export{c as cartStore,a as cartStoreApplySubtotals,b as cartStoreGetShippingTransitInfo,d as cartStoreNextStep,e as cartStorePreviousStep,f as cartStoreReCalculateTotal,g as cartStoreReset,h as cartStoreUpdateItems,i as cartStoreUpdateSelectedShippingOption,j as cartStoreUpdateToErrorState}from"./p-25db3885.js";import"./p-08695f4e.js";import"./p-dc8d7000.js";import"./p-770c959e.js";import"./p-bf070bf6.js";import"./p-0e0b46a5.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(o,t,s,e){function n(o){return o instanceof s?o:new s((function(t){t(o)}))}return new(s||(s=Promise))((function(s,i){function a(o){try{c(e.next(o))}catch(o){i(o)}}function r(o){try{c(e["throw"](o))}catch(o){i(o)}}function c(o){o.done?s(o.value):n(o.value).then(a,r)}c((e=e.apply(o,t||[])).next())}))};var __generator=this&&this.__generator||function(o,t){var s={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},e,n,i,a;return a={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function r(o){return function(t){return c([o,t])}}function c(r){if(e)throw new TypeError("Generator is already executing.");while(a&&(a=0,r[0]&&(s=0)),s)try{if(e=1,n&&(i=r[0]&2?n["return"]:r[0]?n["throw"]||((i=n["return"])&&i.call(n),0):n.next)&&!(i=i.call(n,r[1])).done)return i;if(n=0,i)r=[r[0]&2,i.value];switch(r[0]){case 0:case 1:i=r;break;case 4:s.label++;return{value:r[1],done:false};case 5:s.label++;n=r[1];r=[0];continue;case 7:r=s.ops.pop();s.trys.pop();continue;default:if(!(i=s.trys,i=i.length>0&&i[i.length-1])&&(r[0]===6||r[0]===2)){s=0;continue}if(r[0]===3&&(!i||r[1]>i[0]&&r[1]<i[3])){s.label=r[1];break}if(r[0]===6&&s.label<i[1]){s.label=i[1];i=r;break}if(i&&s.label<i[2]){s.label=i[2];s.ops.push(r);break}if(i[2])s.ops.pop();s.trys.pop();continue}r=t.call(o,s)}catch(o){r=[6,o];n=0}finally{e=i=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(o,t,s){if(s||arguments.length===2)for(var e=0,n=t.length,i;e<n;e++){if(i||!(e in t)){if(!i)i=Array.prototype.slice.call(t,0,e);i[e]=t[e]}}return o.concat(i||Array.prototype.slice.call(t))};System.register(["./p-68d06767.system.js","./p-79f9e330.system.js","./p-42ba069d.system.js","./p-8c867835.system.js","./p-f23749e4.system.js","./p-23e7c655.system.js","./p-6dcd752e.system.js","./p-85ab35c9.system.js"],(function(o){"use strict";var t,s,e,n,i,a,r,c,l,h,d,u,p,m,f,g,z,b,y;return{setters:[function(o){t=o.r;s=o.a;e=o.h;n=o.H;i=o.F;a=o.c;r=o.d},function(o){c=o.c;l=o.s;h=o.p;d=o.o;u=o.i;p=o.b},function(o){m=o.t},function(o){f=o.g},function(o){g=o.s;z=o.i},function(o){b=o.c},function(o){y=o.z},function(){}],execute:function(){var v=function(o){var t=o.amount,s=o.currency,e=o.showCurrencyText;return e?"".concat(new Intl.NumberFormat("en-US",{currency:s,style:"currency"}).format(t)," ").concat(s):new Intl.NumberFormat("en-US",{currency:s,style:"currency"}).format(t)};var x=":host{font-family:Inter;display:block}: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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--amino-font-size-base)}:host .zonos--cart-table .zonos--column{padding:var(--amino-space-8);font-size:var(--amino-font-size-base)}:host .zonos--cart-table .zonos--column:last-child{text-align:right}:host .zonos--cart-table .zonos--column:first-child{width:60px}:host img{min-width:40px}";var w=o("zonos_cart_items",function(){function o(o){t(this,o);this.errorImages=[]}o.prototype.render=function(){var o=this;var t;var i=s("./assets/empty-item.jpeg");var a=((t=c.exchangeRate)===null||t===void 0?void 0:t.rate)||1;return e(n,{class:"zonos--cart-items zonos--elements"},e("table",{class:"zonos--cart-table"},e("tbody",null,c.items.map((function(t){var s=t.imageUrl;return e("tr",{class:"zonos--cart-item"},e("td",{class:"zonos--column zonos--cart-item-image"},s&&!o.errorImages.includes(s)?e("img",{alt:t.name,onError:function(){o.errorImages=__spreadArray(__spreadArray([],o.errorImages,true),[s],false)},src:t.imageUrl,style:{"min-width":"40px"},width:40}):e("img",{alt:t.name,src:i,width:40})),e("td",{class:"zonos--column zonos--cart-item-name"},e("zonos-text",{type:"label"},t.name)),e("td",{class:"zonos--column zonos--cart-item-price"},e("zonos-text",{type:"semiBoldLabel"},v({amount:t.amount*t.quantity*a,currency:c.currency}))))})))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());w.style=x;var k='<svg viewBox="0 0 17 16" fill="none" xmlns="https://www.w3.org/2000/svg">\n<path fill-rule="evenodd" clip-rule="evenodd" d="M1.96704 8.00065C1.96704 4.31875 4.93024 1.33398 8.58554 1.33398C12.2408 1.33398 15.204 4.31875 15.204 8.00065C15.204 11.6826 12.2408 14.6673 8.58554 14.6673C4.93024 14.6673 1.96704 11.6825 1.96704 8.00065Z" fill="#C5C6CA"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M8.58543 4.66016C8.95096 4.66016 9.24728 4.95863 9.24728 5.32682V5.33349C9.24728 5.70168 8.95096 6.00016 8.58543 6.00016C8.2199 6.00016 7.92358 5.70168 7.92358 5.33349V5.32682C7.92358 4.95863 8.2199 4.66016 8.58543 4.66016ZM8.58543 7.33349C8.95096 7.33349 9.24728 7.63197 9.24728 8.00016V10.6668C9.24728 11.035 8.95096 11.3335 8.58543 11.3335C8.2199 11.3335 7.92358 11.035 7.92358 10.6668V8.00016C7.92358 7.63197 8.2199 7.33349 8.58543 7.33349Z" fill="#4D505A"/>\n</svg>\n';var C=":host{font-family:Inter;display:block}: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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--amino-font-size-base)}:host .zonos--cart-table .zonos--column{padding:var(--amino-space-20) var(--amino-space-8);vertical-align:top}:host .zonos--cart-table .zonos--column:last-child{text-align:right}:host .zonos--cart-table .zonos--column:first-child{width:60px}:host .zonos--title-with-icon{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:var(--amino-space-8)}:host .zonos--cart-subtotal-title,:host .zonos--cart-subtotal-price{border-bottom:1px solid var(--amino-gray-200)}:host .zonos--cart-duty-tax-price{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:end;align-items:flex-end;gap:5px}:host .zonos--cart-subtotal-price{text-align:right}";var S=o("zonos_cart_subtotal",function(){function o(o){t(this,o)}o.prototype.render=function(){var o=c.total-c.dutiesTaxFees;var t=c.step==="payment"||c.step==="shipping";var s=function(){if(!c.selectedShippingOption){return e(i,null,e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},m("Shipping")),e("zonos-text",{class:"zonos--caption",type:"caption"},m("No shipping method selected")))}return e(i,null,e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},c.selectedShippingOption.displayName),c.selectedShippingOptionTransitTime&&e("zonos-text",{class:"zonos--caption",type:"caption"},c.selectedShippingOptionTransitTime," ",m("business days")))};return e(n,{class:"zonos--cart-subtotal zonos--elements"},e("table",{class:"zonos--cart-table"},e("tr",{class:"zonos--row zonos--cart-subtotal"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column zonos--cart-subtotal-title"},e("zonos-text",{type:"semiBoldLabel"},m("Cart subtotal"))),e("td",{class:"zonos--column zonos--cart-subtotal-price"},e("zonos-text",{type:"semiBoldLabel"},v({amount:c.subtotal,currency:c.currency})))),e("tr",{class:"zonos--row zonos--cart-shipping"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column zonos--cart-subtotal-title"},s()),e("td",{class:"zonos--column zonos--cart-subtotal-price"},c.shipping?v({amount:c.shipping,currency:c.currency}):"-")),t&&e("tr",{class:"zonos--row zonos--cart-duties"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column zonos--cart-subtotal-title"},e("div",{class:"zonos--title-with-icon"},e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},m("Duties, taxes, and fees")),e("zonos-icon",{content:k,size:16})),!!c.isSelectedShippingAboveDeminimis&&e("zonos-text",{color:"gray-800",type:"body"},m("Order is over the de minimis threshold for both duty and tax"))),e("td",{class:"zonos--column zonos--cart-subtotal-price"},e("div",{class:"zonos--cart-duty-tax-price"},c.dutiesTaxFees?v({amount:c.dutiesTaxFees,currency:c.currency}):"-",c.isSelectedShippingGuarantee&&e("zonos-badge",null,m("Guaranteed"))))),e("tr",{class:"zonos--row zonos--cart-pay-total"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column"},e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},m("Order total"))),e("td",{class:"zonos--column"},e("zonos-text",{type:"semiBoldLabel"},v({amount:c.step==="shipping"?o:c.total,currency:c.currency}))))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());S.style=C;var L='<svg color="var(--amino-red-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" data-is-secondary-color="true" fill="var(--amino-red-200)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var B='<svg color="var(--amino-blue-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Z" data-is-secondary-color="true" fill="var(--amino-blue-100)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M15.707 9.293a1 1 0 0 1 0 1.414l-3.646 3.647a1.5 1.5 0 0 1-2.122 0l-1.646-1.647a1 1 0 1 1 1.414-1.414L11 12.586l3.293-3.293a1 1 0 0 1 1.414 0Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var _=":host{font-family:Inter;display:block}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .zonos--group{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;margin-bottom:var(--amino-space-24);border-radius:var(--border-radius, 10px);gap:var(--amino-space-24);max-width:360px;width:auto;margin:auto;margin-top:var(--amino-space-24);background-color:var(--amino-gray-50);padding:var(--amino-space-20)}:host zonos-button{width:100%}:host .loading-wrapper{min-height:300px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}";var M=o("zonos_checkout_finish",function(){function o(o){var s=this;t(this,o);this.closeClick=a(this,"closeClick",7);this.checkPaymentStatus=function(){return __awaiter(s,void 0,void 0,(function(){var o,t,s,e,n;return __generator(this,(function(i){switch(i.label){case 0:this.isLoading=true;o=new URLSearchParams(window.location.search).get("payment_intent_client_secret")||l.clientSecret;if(!(o||this.storybookForceStatus))return[3,2];return[4,h({clientSecret:o,storybookForceStatus:this.storybookForceStatus})];case 1:t=i.sent(),s=t.error,e=t.messages;this.notificationType=s?"error":"success";this.notificationMessages=e||[];this.notificationTitle=s?m("Payment failed"):m("You're all set!");if(s){g("zonos-checkout-payment-fail")}else{g("zonos-checkout-success");n=new CustomEvent("zonos-checkout-success",{detail:{message:"Zonos Checkout successfully processed order"}});document.dispatchEvent(n)}i.label=2;case 2:d();this.isLoading=false;return[2]}}))}))};this.closeClickHandler=function(){s.closeClick.emit()};this.borderRadius="ROUNDED";this.storybookForceStatus=undefined;this.overrideNotification=undefined;this.isLoading=true;this.notificationType="success";this.notificationTitle="";this.notificationMessages=[]}o.prototype.componentDidLoad=function(){if(this.overrideNotification){this.notificationType=this.overrideNotification.type;this.notificationTitle=this.overrideNotification.title;this.notificationMessages=this.overrideNotification.messages;this.isLoading=false;return}void this.checkPaymentStatus()};o.prototype.render=function(){var o=this;return e(n,{class:"zonos--checkout-finish zonos--elements",style:{"--border-radius":f(this.borderRadius)}},this.isLoading&&e("div",{class:"loading-wrapper"},e("zonos-spinner",null)),!this.isLoading&&e("div",{class:"zonos--group"},this.notificationType==="success"?e("zonos-icon",{color:"blue-800",content:B,size:50}):e("zonos-icon",{color:"red-800",content:L,size:50}),e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},this.notificationTitle),e("zonos-text",null,this.notificationMessages.map((function(o){return e(i,null,o,e("br",null))}))),e("zonos-button",{onClick:function(){return o.closeClickHandler()},size:"md",variant:"primary"},m("Keep shopping"))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());M.style=_;var T=".sc-zonos-checkout-payment-h{font-family:Inter;display:block}.sc-zonos-checkout-payment-h img.sc-zonos-checkout-payment{max-width:100%}.sc-zonos-checkout-payment-h dl.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h dd.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h1.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h2.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h3.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h4.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h5.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h6.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h hr.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h figure.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h p.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h pre.sc-zonos-checkout-payment{margin:0}.sc-zonos-checkout-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-checkout-payment-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-checkout-payment-h .zonos--title.sc-zonos-checkout-payment{margin-bottom:var(--amino-space-24)}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment{margin-bottom:var(--amino-space-20);overflow:auto;padding:5px}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar{width:10px}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar-track{background:var(--amino-gray-50)}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-checkout-payment-h .zonos--payment-error-banner.sc-zonos-checkout-payment{margin-bottom:var(--amino-space-8)}.sc-zonos-checkout-payment-h .zonos--group-btn.sc-zonos-checkout-payment{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.sc-zonos-checkout-payment-h .zonos--group-btn.sc-zonos-checkout-payment zonos-button.sc-zonos-checkout-payment{width:calc(100% - 10px)}";var D=o("zonos_checkout_payment",function(){function o(o){var s=this;t(this,o);this.continueClicked=a(this,"continueClicked",7);this.continueClickHandler=function(){s.continueClicked.emit()};this.paymentError=false;this.submitBtnType=undefined;this.continueLoading=false;this.submitBtnColor=undefined;this.disabled=true}o.prototype.watchFormComplete=function(){if(!this.disabled){g("zonos-checkout-payment-info")}};o.prototype.render=function(){var o=this;var t;if(!l.stripeElements){return null}this.disabled=!((t=l.stripePaymentEventData)===null||t===void 0?void 0:t.complete);return e(n,{class:"zonos--checkout-payment zonos--elements"},e("div",{class:"zonos--group"},e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},m("Payment method")),this.paymentError&&e("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},m("We couldn't complete your payment. Please verify the payment details and try again.")),e("zonos-payment",null)),e("div",{class:"zonos--group-btn"},e("zonos-button",{backgroundColor:this.submitBtnColor,"is-disabled":this.disabled,loading:this.continueLoading,onClick:function(){return o.continueClickHandler()},size:"lg",variant:this.submitBtnType},"Pay"," ",v({amount:c.total,currency:c.currency}))))};Object.defineProperty(o,"watchers",{get:function(){return{disabled:["watchFormComplete"]}},enumerable:false,configurable:true});return o}());D.style=T;var j=":host{font-family:Inter;display:block}: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{-webkit-transition:all 0.3s ease-in-out;transition:all 0.3s ease-in-out;overflow:hidden}:host div{position:relative}:host iframe{width:0;height:100%;position:absolute;top:0;border:0}";var A=o("zonos_collapse",function(){function o(o){t(this,o);this.collapsed=false;this.collapseSize=0;this.height=this.el.scrollHeight}o.prototype.getElementHeight=function(){var o="".concat(this.height,"px");var t="".concat(this.collapseSize,"px");return this.collapsed?t:o};o.prototype.componentDidLoad=function(){this.height=this.el.scrollHeight};o.prototype.componentDidRender=function(){var o=this;var t,s,e;(e=(s=(t=this.el.shadowRoot)===null||t===void 0?void 0:t.querySelector("iframe"))===null||s===void 0?void 0:s.contentWindow)===null||e===void 0?void 0:e.addEventListener("resize",(function(){o.height=o.el.scrollHeight}))};o.prototype.render=function(){this.height=this.el.scrollHeight;return e(n,{class:"zonos--elements zonos--collapse",style:{height:this.getElementHeight()}},e("div",null,e("iframe",{class:"height-change-listener",tabindex:"-1",title:"collapse-height-change-listener"}),e("slot",null)))};Object.defineProperty(o.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});return o}());A.style=j;var P=".sc-zonos-customer-info-h{font-family:Inter;display:block}.sc-zonos-customer-info-h img.sc-zonos-customer-info{max-width:100%}.sc-zonos-customer-info-h dl.sc-zonos-customer-info,.sc-zonos-customer-info-h dd.sc-zonos-customer-info,.sc-zonos-customer-info-h h1.sc-zonos-customer-info,.sc-zonos-customer-info-h h2.sc-zonos-customer-info,.sc-zonos-customer-info-h h3.sc-zonos-customer-info,.sc-zonos-customer-info-h h4.sc-zonos-customer-info,.sc-zonos-customer-info-h h5.sc-zonos-customer-info,.sc-zonos-customer-info-h h6.sc-zonos-customer-info,.sc-zonos-customer-info-h hr.sc-zonos-customer-info,.sc-zonos-customer-info-h figure.sc-zonos-customer-info,.sc-zonos-customer-info-h p.sc-zonos-customer-info,.sc-zonos-customer-info-h pre.sc-zonos-customer-info{margin:0}.sc-zonos-customer-info-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-customer-info-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-customer-info-h .zonos--title.sc-zonos-customer-info{margin-bottom:var(--amino-space-20)}.sc-zonos-customer-info-h .zonos--link-authentication.sc-zonos-customer-info{margin-bottom:var(--amino-space-32)}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info{margin-bottom:var(--amino-space-20);overflow:auto;padding:5px}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar{width:10px}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar-track{background:var(--amino-gray-50)}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-customer-info-h .zonos--group-btn.sc-zonos-customer-info{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.sc-zonos-customer-info-h .zonos--group-btn.sc-zonos-customer-info zonos-button.sc-zonos-customer-info{width:calc(100% - 10px)}";var H=o("zonos_customer_info",function(){function o(o){var s=this;t(this,o);this.continueClicked=a(this,"continueClicked",7);this.continueClickHandler=function(){s.continueClicked.emit()};this.continueLoading=false;this.submitBtnType=undefined;this.submitBtnColor=undefined;this.defaultAddress=null;this.disabled=true}o.prototype.watchFormComplete=function(){if(!this.disabled){g("zonos-checkout-customer-info")}};o.prototype.render=function(){var o=this;var t,s;if(!l.stripeElements){return null}this.disabled=!((t=l.stripeAddressEventData)===null||t===void 0?void 0:t.complete)||!((s=l.stripeLinkEventData)===null||s===void 0?void 0:s.complete);return e(n,{class:"zonos--customer-info zonos--elements"},e("div",{class:"zonos--group"},e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},m("Customer information")),e("zonos-link-authentication",{titleText:m("Contact")}),e("zonos-address",{defaultAddress:this.defaultAddress,titleText:m("Address"),type:"shipping"})),e("div",{class:"zonos--group-btn"},e("zonos-button",{backgroundColor:this.submitBtnColor,isDisabled:this.disabled,loading:this.continueLoading,onClick:function(){return o.continueClickHandler()},size:"lg",variant:this.submitBtnType},m("Continue to shipping"))))};Object.defineProperty(o,"watchers",{get:function(){return{disabled:["watchFormComplete"]}},enumerable:false,configurable:true});return o}());H.style=P;var O='<svg xmlns="https://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="#C5C6CA" fill-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" clip-rule="evenodd"/><path fill="#4D505A" fill-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" clip-rule="evenodd"/></svg>';var E=":host{font-family:Inter;display:block}: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 .zonos--backdrop,:host .zonos--dialog-layout{opacity:0;z-index:-999;visibility:hidden;-webkit-transition:0.3s all ease;transition:0.3s all ease}:host .zonos--backdrop{width:100vw;height:100vh;left:0px;top:0px;background:var(--amino-backdrop-color);z-index:-999;opacity:0;visibility:hidden;position:fixed}:host .zonos--loading{position:absolute;left:0;right:0;bottom:0;top:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;z-index:1002;background:white}:host .zonos--dialog-layout{width:100vw;height:100vh;left:0;top:0;position:fixed;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;color:var(--amino-text-color);visibility:hidden}:host .zonos--dialog{position:relative;z-index:1001;background:var(--amino-gray-0);max-width:90vw;max-height:90vh;min-height:500px;height:var(--height, auto);width:var(--width, auto);border-radius:var(--border-radius, var(--amino-radius-10));outline:none;-webkit-box-shadow:var(--amino-v3-shadow-xxl);box-shadow:var(--amino-v3-shadow-xxl);border:var(--amino-border);overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .zonos--header{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;padding:var(--amino-space-16) var(--amino-space-24)}:host .zonos--header .-zonos-stencil-library--header-text{-ms-flex-positive:1;flex-grow:1}:host .zonos--header .zonos--close-button{width:var(--amino-size-md);height:var(--amino-size-md);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;cursor:pointer;border-radius:var(--amino-radius-10)}:host .zonos--header .zonos--close-button:hover{background:var(--amino-hover-color)}:host .zonos--body{padding:var(--amino-space-8) var(--amino-space-24);max-height:100%;height:100%;overflow:auto}:host .zonos--body.zonos--no-body-padding{padding:0}:host .zonos--footer{padding:var(--amino-space-16) var(--amino-space-24)}:host(.open) .zonos--dialog-layout,:host(.open) .zonos--backdrop{visibility:visible}:host(.open) .zonos--backdrop{z-index:1001;opacity:0.65}:host(.open) .zonos--dialog-layout{opacity:1;z-index:1002;-webkit-transform:scale(1);transform:scale(1)}:host(.no-border) .zonos--dialog{border:none}:host(.mobile) .zonos--dialog{max-width:100vw;max-height:100vh;height:100%;width:100%;border-radius:0;-webkit-box-shadow:none;box-shadow:none;border:none}";var F=o("zonos_dialog",function(){function o(o){var s=this;t(this,o);this.closeDialog=a(this,"closeDialog",7);this.isMobileMode=function(){return s.mobile||window.innerWidth<=768};this.closeButtonHandler=function(){s.closeDialog.emit()};this.clickOutsideDialogHandler=function(o){if(o.target===o.currentTarget&&!s.noClickOutside){s.closeDialog.emit()}};this.open=false;this.headerText="";this.width="460px";this.height=undefined;this.noHeader=false;this.noBodyPadding=false;this.noBorder=false;this.footerRightAction=null;this.borderStyle=undefined;this.noCloseButton=false;this.noClickOutside=false;this.mobile=false;this.isLoading=true;this.isMobile=false}o.prototype.handleWindowResize=function(){this.isMobile=this.isMobileMode()};o.prototype.componentDidLoad=function(){this.isMobile=this.isMobileMode()};o.prototype.render=function(){if(this.open){document.body.style.overflow="hidden"}else{document.body.style.overflow="auto"}var o=f(this.borderStyle);return e(n,{class:b(["zonos--elements",this.open&&"open",this.isLoading&&"is-loading",this.noBorder&&"no-border",this.isMobile&&"mobile"]),style:{"--border-radius":o,"--height":this.height||"initial","--width":this.width}},e("div",{class:"zonos--backdrop"}),e("div",{"aria-hidden":"true",class:"zonos--dialog-layout",onClick:this.clickOutsideDialogHandler},e("div",{class:"zonos--dialog"},this.isLoading&&e("div",{class:"zonos--loading"},e("zonos-spinner",{size:30})),(this.headerText||!this.noCloseButton)&&e("div",{class:"zonos--header"},this.headerText&&e("h3",{class:"zonos--header-text"},this.headerText),!this.noCloseButton&&e("zonos-button",{class:"zonos--close-button",icon:e("zonos-icon",{content:O}),noBackground:true,onClick:this.closeButtonHandler})),e("div",{class:b(["zonos--body",this.noBodyPadding&&"zonos--no-body-padding"])},e("slot",null)),this.footerRightAction&&e("div",{class:"zonos--footer"},e("div",{class:"zonos--footer-right-action"},this.footerRightAction)))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());F.style=E;var I=":host{font-family:Inter;display:block}: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-inline-flexbox;display:inline-flex}:host img{-webkit-filter:var(--filter-color);filter:var(--filter-color);width:var(--width)}";var R=o("zonos_logo",function(){function o(o){t(this,o);this.theme="LIGHT";this.width="auto";this.class=""}o.prototype.render=function(){var o=this.theme==="DARK"?"invert(100%) sepia(100%) saturate(0%) hue-rotate(288deg) brightness(102%) contrast(102%)":"whiteinvert(0%) sepia(100%) saturate(32%) hue-rotate(92deg) brightness(107%) contrast(107%)";return e(n,{class:b(["zonos--elements zonos--logo",this.class]),style:{"--filter-color":o,"--width":this.width}},e("img",{alt:"Zonos Logo",src:s("./assets/ZonosLogo.png")}))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());R.style=I;var Z='<svg color="var(--amino-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var N='<svg color="var(--amino-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M17.707 14.707a1 1 0 0 1-1.414 0L12 10.414l-4.293 4.293a1 1 0 0 1-1.414-1.414l4.93-4.93a1.1 1.1 0 0 1 1.555 0l4.93 4.93a1 1 0 0 1 0 1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var U=":host{font-family:Inter;display:block}: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 .zonos--total-pay{margin:var(--amino-space-16) 0 var(--amino-space-32)}:host(.mobile){display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;gap:var(--amino-space-24);-ms-flex-pack:justify;justify-content:space-between;padding:var(--amino-space-4) 0;margin-bottom:var(--amino-space-8)}:host(.mobile) .zonos--title{display:-ms-flexbox;display:flex;-ms-flex-item-align:center;align-self:center;gap:var(--amino-space-8)}:host(.mobile) .zonos--total-pay{margin:0}";var W=o("zonos_review",function(){function o(o){t(this,o);this.mobile=false;this.collapsed=false;this.isMobile=false}o.prototype.handleWindowResize=function(){this.isMobile=z(this.mobile)};o.prototype.componentWillLoad=function(){this.isMobile=z(this.mobile)};o.prototype.render=function(){var o=this;var t=this.isMobile?"boldSubheader":"semiBoldLabel";var s=this.isMobile?"boldSubheader":"secondaryPageHeader";var i=this.isMobile?"gray-1200":"gray-800";var a=c.total-c.dutiesTaxFees;var r=function(){if(!o.isMobile){return null}if(!o.collapsed){return e("zonos-icon",{color:"gray-1200",content:Z})}return e("zonos-icon",{color:"gray-1200",content:N})};return e(n,{class:b(["zonos--review zonos--elements",this.isMobile&&"mobile"])},e("div",{class:"zonos--title"},e("zonos-text",{color:i,type:t},m("Pay")," ",y.organizationName),r()),e("div",{class:"zonos--total-pay"},e("zonos-text",{type:s},v({amount:c.step==="shipping"?a:c.total,currency:c.currency}))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());W.style=U;var G=".sc-zonos-shipping-h{font-family:Inter;display:block}.sc-zonos-shipping-h img.sc-zonos-shipping{max-width:100%}.sc-zonos-shipping-h dl.sc-zonos-shipping,.sc-zonos-shipping-h dd.sc-zonos-shipping,.sc-zonos-shipping-h h1.sc-zonos-shipping,.sc-zonos-shipping-h h2.sc-zonos-shipping,.sc-zonos-shipping-h h3.sc-zonos-shipping,.sc-zonos-shipping-h h4.sc-zonos-shipping,.sc-zonos-shipping-h h5.sc-zonos-shipping,.sc-zonos-shipping-h h6.sc-zonos-shipping,.sc-zonos-shipping-h hr.sc-zonos-shipping,.sc-zonos-shipping-h figure.sc-zonos-shipping,.sc-zonos-shipping-h p.sc-zonos-shipping,.sc-zonos-shipping-h pre.sc-zonos-shipping{margin:0}.sc-zonos-shipping-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-shipping-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-shipping-h .zonos--title.sc-zonos-shipping{margin-bottom:var(--amino-space-24)}.sc-zonos-shipping-h .zonos--shipping-method-title.sc-zonos-shipping{margin-bottom:var(--amino-space-16)}.sc-zonos-shipping-h .zonos-shipping-rich-radio.sc-zonos-shipping{margin-bottom:var(--amino-space-24)}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping{margin-bottom:var(--amino-space-20);overflow:auto;padding:5px}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar{width:10px}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar-track{background:var(--amino-gray-50)}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-shipping-h .zonos--group-btn.sc-zonos-shipping{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.sc-zonos-shipping-h .zonos--group-btn.sc-zonos-shipping zonos-button.sc-zonos-shipping{width:calc(100% - 10px)}.sc-zonos-shipping-h zonos-banner.sc-zonos-shipping{margin-top:var(--amino-space-24)}";var V=o("zonos_shipping",function(){function o(o){var s=this;t(this,o);this.continueClicked=a(this,"continueClicked",7);this.handleRadioSelected=function(o){return __awaiter(s,void 0,void 0,(function(){var t,s,e;var n=this;return __generator(this,(function(i){switch(i.label){case 0:this.selectedShippingMethod=o.detail;if(!this.selectedShippingMethod){return[2]}s=((t=c.shippingData)===null||t===void 0?void 0:t.find((function(o){var t;return o.id===((t=n.selectedShippingMethod)===null||t===void 0?void 0:t.value)})))||null;if(!s){return[2]}return[4,u(s)];case 1:e=i.sent();if(!e){return[2]}this.disabled=false;return[2]}}))}))};this.continueClickHandler=function(){s.continueClicked.emit()};this.continueLoading=false;this.submitBtnColor=undefined;this.submitBtnType=undefined;this.selectedShippingMethod=null;this.disabled=true}o.prototype.watchFormComplete=function(){if(!this.disabled){g("zonos-checkout-shipping-info")}};o.prototype.render=function(){var o=this;var t,s;var i=(t=l.stripeAddressEventData)===null||t===void 0?void 0:t.value.address.country;var a=(s=c.shippingData)===null||s===void 0?void 0:s.flatMap((function(o){var t,s;var e=p(o),n=e.expectedDate,i=e.maxTransit,a=e.minTransit;var r=n?"".concat(m("Expected delivery")," ").concat(n):"";var l=a&&i?"(".concat(a,"-").concat(i," ").concat(m("business days"),")"):"";var h=((s=(t=c.landedCostData)===null||t===void 0?void 0:t.find((function(t){var s;return((s=t.landedCost)===null||s===void 0?void 0:s.shipmentRating.id)===o.id})))===null||s===void 0?void 0:s.subtotals.shipping)||0;return{caption:l,label:o.displayName,price:v({amount:h,currency:c.currency}),sublabel:r,value:o.id}}));return e(n,{class:"zonos--shipping zonos--elements"},e("div",{class:"zonos--group"},e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},m("Shipping information")),e("zonos-text",{class:"zonos--shipping-method-title",type:"semiBoldLabel"},m("Shipping method")),!(a===null||a===void 0?void 0:a.length)?e("zonos-banner",{bannerTitle:"No shipping methods found - try editing your address or contacting support if the error persists",intent:"error"}):e("zonos-shipping-rich-radio",{items:a||[],onRadioSelected:function(t){return o.handleRadioSelected(t)}}),c.isSelectedShippingAboveDeminimis&&e("zonos-banner",{intent:"warning"},m("Above de minimis threshold for")," ",i,"."," ",m("Duties and taxes will be applied to items and shipping."))),e("zonos-button",{backgroundColor:this.submitBtnColor,"is-disabled":this.disabled,loading:this.continueLoading,onClick:function(){return o.continueClickHandler()},size:"lg",variant:this.submitBtnType},m("Go to payment")))};Object.defineProperty(o,"watchers",{get:function(){return{disabled:["watchFormComplete"]}},enumerable:false,configurable:true});return o}());V.style=G}}}));
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(o,t,s,e){function n(o){return o instanceof s?o:new s((function(t){t(o)}))}return new(s||(s=Promise))((function(s,i){function a(o){try{c(e.next(o))}catch(o){i(o)}}function r(o){try{c(e["throw"](o))}catch(o){i(o)}}function c(o){o.done?s(o.value):n(o.value).then(a,r)}c((e=e.apply(o,t||[])).next())}))};var __generator=this&&this.__generator||function(o,t){var s={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},e,n,i,a;return a={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function r(o){return function(t){return c([o,t])}}function c(r){if(e)throw new TypeError("Generator is already executing.");while(a&&(a=0,r[0]&&(s=0)),s)try{if(e=1,n&&(i=r[0]&2?n["return"]:r[0]?n["throw"]||((i=n["return"])&&i.call(n),0):n.next)&&!(i=i.call(n,r[1])).done)return i;if(n=0,i)r=[r[0]&2,i.value];switch(r[0]){case 0:case 1:i=r;break;case 4:s.label++;return{value:r[1],done:false};case 5:s.label++;n=r[1];r=[0];continue;case 7:r=s.ops.pop();s.trys.pop();continue;default:if(!(i=s.trys,i=i.length>0&&i[i.length-1])&&(r[0]===6||r[0]===2)){s=0;continue}if(r[0]===3&&(!i||r[1]>i[0]&&r[1]<i[3])){s.label=r[1];break}if(r[0]===6&&s.label<i[1]){s.label=i[1];i=r;break}if(i&&s.label<i[2]){s.label=i[2];s.ops.push(r);break}if(i[2])s.ops.pop();s.trys.pop();continue}r=t.call(o,s)}catch(o){r=[6,o];n=0}finally{e=i=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(o,t,s){if(s||arguments.length===2)for(var e=0,n=t.length,i;e<n;e++){if(i||!(e in t)){if(!i)i=Array.prototype.slice.call(t,0,e);i[e]=t[e]}}return o.concat(i||Array.prototype.slice.call(t))};System.register(["./p-68d06767.system.js","./p-8db8cc05.system.js","./p-164fae93.system.js","./p-8c867835.system.js","./p-8aabbb9b.system.js","./p-23e7c655.system.js","./p-6dcd752e.system.js","./p-85ab35c9.system.js"],(function(o){"use strict";var t,s,e,n,i,a,r,c,l,h,d,u,p,m,f,g,z,b,y;return{setters:[function(o){t=o.r;s=o.a;e=o.h;n=o.H;i=o.F;a=o.c;r=o.d},function(o){c=o.c;l=o.s;h=o.p;d=o.o;u=o.i;p=o.b},function(o){m=o.t},function(o){f=o.g},function(o){g=o.s;z=o.i},function(o){b=o.c},function(o){y=o.z},function(){}],execute:function(){var v=function(o){var t=o.amount,s=o.currency,e=o.showCurrencyText;return e?"".concat(new Intl.NumberFormat("en-US",{currency:s,style:"currency"}).format(t)," ").concat(s):new Intl.NumberFormat("en-US",{currency:s,style:"currency"}).format(t)};var x=":host{font-family:Inter;display:block}: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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--amino-font-size-base)}:host .zonos--cart-table .zonos--column{padding:var(--amino-space-8);font-size:var(--amino-font-size-base)}:host .zonos--cart-table .zonos--column:last-child{text-align:right}:host .zonos--cart-table .zonos--column:first-child{width:60px}:host img{min-width:40px}";var w=o("zonos_cart_items",function(){function o(o){t(this,o);this.errorImages=[]}o.prototype.render=function(){var o=this;var t;var i=s("./assets/empty-item.jpeg");var a=((t=c.exchangeRate)===null||t===void 0?void 0:t.rate)||1;return e(n,{class:"zonos--cart-items zonos--elements"},e("table",{class:"zonos--cart-table"},e("tbody",null,c.items.map((function(t){var s=t.imageUrl;return e("tr",{class:"zonos--cart-item"},e("td",{class:"zonos--column zonos--cart-item-image"},s&&!o.errorImages.includes(s)?e("img",{alt:t.name,onError:function(){o.errorImages=__spreadArray(__spreadArray([],o.errorImages,true),[s],false)},src:t.imageUrl,style:{"min-width":"40px"},width:40}):e("img",{alt:t.name,src:i,width:40})),e("td",{class:"zonos--column zonos--cart-item-name"},e("zonos-text",{type:"label"},t.name)),e("td",{class:"zonos--column zonos--cart-item-price"},e("zonos-text",{type:"semiBoldLabel"},v({amount:t.amount*t.quantity*a,currency:c.currency}))))})))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());w.style=x;var k='<svg viewBox="0 0 17 16" fill="none" xmlns="https://www.w3.org/2000/svg">\n<path fill-rule="evenodd" clip-rule="evenodd" d="M1.96704 8.00065C1.96704 4.31875 4.93024 1.33398 8.58554 1.33398C12.2408 1.33398 15.204 4.31875 15.204 8.00065C15.204 11.6826 12.2408 14.6673 8.58554 14.6673C4.93024 14.6673 1.96704 11.6825 1.96704 8.00065Z" fill="#C5C6CA"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M8.58543 4.66016C8.95096 4.66016 9.24728 4.95863 9.24728 5.32682V5.33349C9.24728 5.70168 8.95096 6.00016 8.58543 6.00016C8.2199 6.00016 7.92358 5.70168 7.92358 5.33349V5.32682C7.92358 4.95863 8.2199 4.66016 8.58543 4.66016ZM8.58543 7.33349C8.95096 7.33349 9.24728 7.63197 9.24728 8.00016V10.6668C9.24728 11.035 8.95096 11.3335 8.58543 11.3335C8.2199 11.3335 7.92358 11.035 7.92358 10.6668V8.00016C7.92358 7.63197 8.2199 7.33349 8.58543 7.33349Z" fill="#4D505A"/>\n</svg>\n';var C=":host{font-family:Inter;display:block}: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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--amino-font-size-base)}:host .zonos--cart-table .zonos--column{padding:var(--amino-space-20) var(--amino-space-8);vertical-align:top}:host .zonos--cart-table .zonos--column:last-child{text-align:right}:host .zonos--cart-table .zonos--column:first-child{width:60px}:host .zonos--title-with-icon{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:var(--amino-space-8)}:host .zonos--cart-subtotal-title,:host .zonos--cart-subtotal-price{border-bottom:1px solid var(--amino-gray-200)}:host .zonos--cart-duty-tax-price{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:end;align-items:flex-end;gap:5px}:host .zonos--cart-subtotal-price{text-align:right}";var L=o("zonos_cart_subtotal",function(){function o(o){t(this,o)}o.prototype.render=function(){var o=c.total-c.dutiesTaxFees;var t=c.step==="payment"||c.step==="shipping";var s=function(){if(!c.selectedShippingOption){return e(i,null,e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},m("Shipping")),e("zonos-text",{class:"zonos--caption",type:"caption"},m("No shipping method selected")))}return e(i,null,e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},c.selectedShippingOption.displayName),c.selectedShippingOptionTransitTime&&e("zonos-text",{class:"zonos--caption",type:"caption"},c.selectedShippingOptionTransitTime," ",m("business days")))};return e(n,{class:"zonos--cart-subtotal zonos--elements"},e("table",{class:"zonos--cart-table"},e("tr",{class:"zonos--row zonos--cart-subtotal"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column zonos--cart-subtotal-title"},e("zonos-text",{type:"semiBoldLabel"},m("Cart subtotal"))),e("td",{class:"zonos--column zonos--cart-subtotal-price"},e("zonos-text",{type:"semiBoldLabel"},v({amount:c.subtotal,currency:c.currency})))),e("tr",{class:"zonos--row zonos--cart-shipping"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column zonos--cart-subtotal-title"},s()),e("td",{class:"zonos--column zonos--cart-subtotal-price"},c.shipping?v({amount:c.shipping,currency:c.currency}):"-")),t&&e("tr",{class:"zonos--row zonos--cart-duties"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column zonos--cart-subtotal-title"},e("div",{class:"zonos--title-with-icon"},e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},m("Duties, taxes, and fees")),e("zonos-icon",{content:k,size:16})),!!c.isSelectedShippingAboveDeminimis&&e("zonos-text",{color:"gray-800",type:"body"},m("Order is over the de minimis threshold for both duty and tax"))),e("td",{class:"zonos--column zonos--cart-subtotal-price"},e("div",{class:"zonos--cart-duty-tax-price"},c.dutiesTaxFees?v({amount:c.dutiesTaxFees,currency:c.currency}):"-",c.isSelectedShippingGuarantee&&e("zonos-badge",null,m("Guaranteed"))))),e("tr",{class:"zonos--row zonos--cart-pay-total"},e("td",{class:"zonos--column"}),e("td",{class:"zonos--column"},e("zonos-text",{class:"zonos--title",type:"semiBoldLabel"},m("Order total"))),e("td",{class:"zonos--column"},e("zonos-text",{type:"semiBoldLabel"},v({amount:c.step==="shipping"?o:c.total,currency:c.currency}))))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());L.style=C;var S='<svg color="var(--amino-red-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" data-is-secondary-color="true" fill="var(--amino-red-200)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var B='<svg color="var(--amino-blue-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Z" data-is-secondary-color="true" fill="var(--amino-blue-100)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M15.707 9.293a1 1 0 0 1 0 1.414l-3.646 3.647a1.5 1.5 0 0 1-2.122 0l-1.646-1.647a1 1 0 1 1 1.414-1.414L11 12.586l3.293-3.293a1 1 0 0 1 1.414 0Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var _=":host{font-family:Inter;display:block}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .zonos--group{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;margin-bottom:var(--amino-space-24);border-radius:var(--border-radius, 10px);gap:var(--amino-space-24);max-width:360px;width:auto;margin:auto;margin-top:var(--amino-space-24);background-color:var(--amino-gray-50);padding:var(--amino-space-20)}:host zonos-button{width:100%}:host .loading-wrapper{min-height:300px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}";var M=o("zonos_checkout_finish",function(){function o(o){var s=this;t(this,o);this.closeClick=a(this,"closeClick",7);this.checkPaymentStatus=function(){return __awaiter(s,void 0,void 0,(function(){var o,t,s,e,n;return __generator(this,(function(i){switch(i.label){case 0:this.isLoading=true;o=new URLSearchParams(window.location.search).get("payment_intent_client_secret")||l.clientSecret;if(!(o||this.storybookForceStatus))return[3,2];return[4,h({clientSecret:o,storybookForceStatus:this.storybookForceStatus})];case 1:t=i.sent(),s=t.error,e=t.messages;this.notificationType=s?"error":"success";this.notificationMessages=e||[];this.notificationTitle=s?m("Payment failed"):m("You're all set!");if(s){g("zonos-checkout-payment-fail")}else{g("zonos-checkout-success");n=new CustomEvent("zonos-checkout-success",{detail:{message:"Zonos Checkout successfully processed order"}});document.dispatchEvent(n)}i.label=2;case 2:d();this.isLoading=false;return[2]}}))}))};this.closeClickHandler=function(){s.closeClick.emit()};this.borderRadius="ROUNDED";this.storybookForceStatus=undefined;this.overrideNotification=undefined;this.isLoading=true;this.notificationType="success";this.notificationTitle="";this.notificationMessages=[]}o.prototype.componentDidLoad=function(){if(this.overrideNotification){this.notificationType=this.overrideNotification.type;this.notificationTitle=this.overrideNotification.title;this.notificationMessages=this.overrideNotification.messages;this.isLoading=false;return}void this.checkPaymentStatus()};o.prototype.render=function(){var o=this;return e(n,{class:"zonos--checkout-finish zonos--elements",style:{"--border-radius":f(this.borderRadius)}},this.isLoading&&e("div",{class:"loading-wrapper"},e("zonos-spinner",null)),!this.isLoading&&e("div",{class:"zonos--group"},this.notificationType==="success"?e("zonos-icon",{color:"blue-800",content:B,size:50}):e("zonos-icon",{color:"red-800",content:S,size:50}),e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},this.notificationTitle),e("zonos-text",null,this.notificationMessages.map((function(o){return e(i,null,o,e("br",null))}))),e("zonos-button",{onClick:function(){return o.closeClickHandler()},size:"md",variant:"primary"},m("Keep shopping"))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());M.style=_;var T=".sc-zonos-checkout-payment-h{font-family:Inter;display:block}.sc-zonos-checkout-payment-h img.sc-zonos-checkout-payment{max-width:100%}.sc-zonos-checkout-payment-h dl.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h dd.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h1.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h2.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h3.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h4.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h5.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h h6.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h hr.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h figure.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h p.sc-zonos-checkout-payment,.sc-zonos-checkout-payment-h pre.sc-zonos-checkout-payment{margin:0}.sc-zonos-checkout-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-checkout-payment-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-checkout-payment-h .zonos--title.sc-zonos-checkout-payment{margin-bottom:var(--amino-space-24)}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment{margin-bottom:var(--amino-space-20);overflow:auto;padding:5px}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar{width:10px}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar-track{background:var(--amino-gray-50)}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-checkout-payment-h .zonos--group.sc-zonos-checkout-payment::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-checkout-payment-h .zonos--payment-error-banner.sc-zonos-checkout-payment{margin-bottom:var(--amino-space-8)}.sc-zonos-checkout-payment-h .zonos--group-btn.sc-zonos-checkout-payment{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.sc-zonos-checkout-payment-h .zonos--group-btn.sc-zonos-checkout-payment zonos-button.sc-zonos-checkout-payment{width:calc(100% - 10px)}";var j=o("zonos_checkout_payment",function(){function o(o){var s=this;t(this,o);this.continueClicked=a(this,"continueClicked",7);this.continueClickHandler=function(){s.continueClicked.emit()};this.paymentError=false;this.submitBtnType=undefined;this.continueLoading=false;this.submitBtnColor=undefined;this.disabled=true}o.prototype.watchFormComplete=function(){if(!this.disabled){g("zonos-checkout-payment-info")}};o.prototype.render=function(){var o=this;var t;if(!l.stripeElements){return null}this.disabled=!((t=l.stripePaymentEventData)===null||t===void 0?void 0:t.complete);return e(n,{class:"zonos--checkout-payment zonos--elements"},e("div",{class:"zonos--group"},e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},m("Payment method")),this.paymentError&&e("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},m("We couldn't complete your payment. Please verify the payment details and try again.")),e("zonos-payment",null)),e("div",{class:"zonos--group-btn"},e("zonos-button",{backgroundColor:this.submitBtnColor,"is-disabled":this.disabled,loading:this.continueLoading,onClick:function(){return o.continueClickHandler()},size:"lg",variant:this.submitBtnType},"Pay"," ",v({amount:c.total,currency:c.currency}))))};Object.defineProperty(o,"watchers",{get:function(){return{disabled:["watchFormComplete"]}},enumerable:false,configurable:true});return o}());j.style=T;var D=":host{font-family:Inter;display:block}: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{-webkit-transition:all 0.3s ease-in-out;transition:all 0.3s ease-in-out;overflow:hidden}:host div{position:relative}:host iframe{width:0;height:100%;position:absolute;top:0;border:0}";var P=o("zonos_collapse",function(){function o(o){t(this,o);this.collapsed=false;this.collapseSize=0;this.height=this.el.scrollHeight}o.prototype.getElementHeight=function(){var o="".concat(this.height,"px");var t="".concat(this.collapseSize,"px");return this.collapsed?t:o};o.prototype.componentDidLoad=function(){this.height=this.el.scrollHeight};o.prototype.componentDidRender=function(){var o=this;var t,s,e;(e=(s=(t=this.el.shadowRoot)===null||t===void 0?void 0:t.querySelector("iframe"))===null||s===void 0?void 0:s.contentWindow)===null||e===void 0?void 0:e.addEventListener("resize",(function(){o.height=o.el.scrollHeight}))};o.prototype.render=function(){this.height=this.el.scrollHeight;return e(n,{class:"zonos--elements zonos--collapse",style:{height:this.getElementHeight()}},e("div",null,e("iframe",{class:"height-change-listener",tabindex:"-1",title:"collapse-height-change-listener"}),e("slot",null)))};Object.defineProperty(o.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});return o}());P.style=D;var H=".sc-zonos-customer-info-h{font-family:Inter;display:block}.sc-zonos-customer-info-h img.sc-zonos-customer-info{max-width:100%}.sc-zonos-customer-info-h dl.sc-zonos-customer-info,.sc-zonos-customer-info-h dd.sc-zonos-customer-info,.sc-zonos-customer-info-h h1.sc-zonos-customer-info,.sc-zonos-customer-info-h h2.sc-zonos-customer-info,.sc-zonos-customer-info-h h3.sc-zonos-customer-info,.sc-zonos-customer-info-h h4.sc-zonos-customer-info,.sc-zonos-customer-info-h h5.sc-zonos-customer-info,.sc-zonos-customer-info-h h6.sc-zonos-customer-info,.sc-zonos-customer-info-h hr.sc-zonos-customer-info,.sc-zonos-customer-info-h figure.sc-zonos-customer-info,.sc-zonos-customer-info-h p.sc-zonos-customer-info,.sc-zonos-customer-info-h pre.sc-zonos-customer-info{margin:0}.sc-zonos-customer-info-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-customer-info-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-customer-info-h .zonos--title.sc-zonos-customer-info{margin-bottom:var(--amino-space-20)}.sc-zonos-customer-info-h .zonos--link-authentication.sc-zonos-customer-info{margin-bottom:var(--amino-space-32)}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info{margin-bottom:var(--amino-space-20);overflow:auto;padding:5px}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar{width:10px}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar-track{background:var(--amino-gray-50)}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-customer-info-h .zonos--group.sc-zonos-customer-info::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-customer-info-h .zonos--group-btn.sc-zonos-customer-info{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.sc-zonos-customer-info-h .zonos--group-btn.sc-zonos-customer-info zonos-button.sc-zonos-customer-info{width:calc(100% - 10px)}";var O=o("zonos_customer_info",function(){function o(o){var s=this;t(this,o);this.continueClicked=a(this,"continueClicked",7);this.continueClickHandler=function(){s.continueClicked.emit()};this.continueLoading=false;this.submitBtnType=undefined;this.submitBtnColor=undefined;this.defaultAddress=null;this.disabled=true}o.prototype.watchFormComplete=function(){if(!this.disabled){g("zonos-checkout-customer-info")}};o.prototype.render=function(){var o=this;var t,s;if(!l.stripeElements){return null}this.disabled=!((t=l.stripeAddressEventData)===null||t===void 0?void 0:t.complete)||!((s=l.stripeLinkEventData)===null||s===void 0?void 0:s.complete);return e(n,{class:"zonos--customer-info zonos--elements"},e("div",{class:"zonos--group"},e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},m("Customer information")),e("zonos-link-authentication",{titleText:m("Contact")}),e("zonos-address",{defaultAddress:this.defaultAddress,titleText:m("Address"),type:"shipping"})),e("div",{class:"zonos--group-btn"},e("zonos-button",{backgroundColor:this.submitBtnColor,isDisabled:this.disabled,loading:this.continueLoading,onClick:function(){return o.continueClickHandler()},size:"lg",variant:this.submitBtnType},m("Continue to shipping"))))};Object.defineProperty(o,"watchers",{get:function(){return{disabled:["watchFormComplete"]}},enumerable:false,configurable:true});return o}());O.style=H;var A='<svg xmlns="https://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="#C5C6CA" fill-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" clip-rule="evenodd"/><path fill="#4D505A" fill-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" clip-rule="evenodd"/></svg>';var F=":host{font-family:Inter;display:block}: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 .zonos--backdrop,:host .zonos--dialog-layout{opacity:0;z-index:-999;visibility:hidden;-webkit-transition:0.3s all ease;transition:0.3s all ease}:host .zonos--backdrop{width:100vw;height:100vh;left:0px;top:0px;background:var(--amino-backdrop-color);z-index:-999;opacity:0;visibility:hidden;position:fixed}:host .zonos--loading{position:absolute;left:0;right:0;bottom:0;top:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;z-index:1002;background:white}:host .zonos--dialog-layout{width:100vw;height:100vh;left:0;top:0;position:fixed;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;color:var(--amino-text-color);visibility:hidden}:host .zonos--dialog{position:relative;z-index:1001;background:var(--amino-gray-0);max-width:90vw;max-height:90vh;min-height:500px;height:var(--height, auto);width:var(--width, auto);border-radius:var(--border-radius, var(--amino-radius-10));outline:none;-webkit-box-shadow:var(--amino-v3-shadow-xxl);box-shadow:var(--amino-v3-shadow-xxl);border:var(--amino-border);overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .zonos--header{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;padding:var(--amino-space-16) var(--amino-space-24)}:host .zonos--header .-zonos-stencil-library--header-text{-ms-flex-positive:1;flex-grow:1}:host .zonos--header .zonos--close-button{width:var(--amino-size-md);height:var(--amino-size-md);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;cursor:pointer;border-radius:var(--amino-radius-10)}:host .zonos--header .zonos--close-button:hover{background:var(--amino-hover-color)}:host .zonos--body{padding:var(--amino-space-8) var(--amino-space-24);max-height:100%;height:100%;overflow:auto}:host .zonos--body.zonos--no-body-padding{padding:0}:host .zonos--footer{padding:var(--amino-space-16) var(--amino-space-24)}:host(.open) .zonos--dialog-layout,:host(.open) .zonos--backdrop{visibility:visible}:host(.open) .zonos--backdrop{z-index:1001;opacity:0.65}:host(.open) .zonos--dialog-layout{opacity:1;z-index:1002;-webkit-transform:scale(1);transform:scale(1)}:host(.no-border) .zonos--dialog{border:none}:host(.mobile) .zonos--dialog{max-width:100vw;max-height:100vh;height:100%;width:100%;border-radius:0;-webkit-box-shadow:none;box-shadow:none;border:none}";var I=o("zonos_dialog",function(){function o(o){var s=this;t(this,o);this.closeDialog=a(this,"closeDialog",7);this.isMobileMode=function(){return s.mobile||window.innerWidth<=768};this.closeButtonHandler=function(){s.closeDialog.emit()};this.clickOutsideDialogHandler=function(o){if(o.target===o.currentTarget&&!s.noClickOutside){s.closeDialog.emit()}};this.open=false;this.headerText="";this.width="460px";this.height=undefined;this.noHeader=false;this.noBodyPadding=false;this.noBorder=false;this.footerRightAction=null;this.borderStyle=undefined;this.noCloseButton=false;this.noClickOutside=false;this.mobile=false;this.isLoading=true;this.isMobile=false}o.prototype.handleWindowResize=function(){this.isMobile=this.isMobileMode()};o.prototype.componentDidLoad=function(){this.isMobile=this.isMobileMode()};o.prototype.render=function(){if(this.open){document.body.style.overflow="hidden"}else{document.body.style.overflow="auto"}var o=f(this.borderStyle);return e(n,{class:b(["zonos--elements",this.open&&"open",this.isLoading&&"is-loading",this.noBorder&&"no-border",this.isMobile&&"mobile"]),style:{"--border-radius":o,"--height":this.height||"initial","--width":this.width}},e("div",{class:"zonos--backdrop"}),e("div",{"aria-hidden":"true",class:"zonos--dialog-layout",onClick:this.clickOutsideDialogHandler},e("div",{class:"zonos--dialog"},this.isLoading&&e("div",{class:"zonos--loading"},e("zonos-spinner",{size:30})),(this.headerText||!this.noCloseButton)&&e("div",{class:"zonos--header"},this.headerText&&e("h3",{class:"zonos--header-text"},this.headerText),!this.noCloseButton&&e("zonos-button",{class:"zonos--close-button",icon:e("zonos-icon",{content:A}),noBackground:true,onClick:this.closeButtonHandler})),e("div",{class:b(["zonos--body",this.noBodyPadding&&"zonos--no-body-padding"])},e("slot",null)),this.footerRightAction&&e("div",{class:"zonos--footer"},e("div",{class:"zonos--footer-right-action"},this.footerRightAction)))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());I.style=F;var R=":host{font-family:Inter;display:block}: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-inline-flexbox;display:inline-flex}:host img{-webkit-filter:var(--filter-color);filter:var(--filter-color);width:var(--width)}";var E=o("zonos_logo",function(){function o(o){t(this,o);this.theme="LIGHT";this.width="auto";this.class=""}o.prototype.render=function(){var o=this.theme==="DARK"?"invert(100%) sepia(100%) saturate(0%) hue-rotate(288deg) brightness(102%) contrast(102%)":"whiteinvert(0%) sepia(100%) saturate(32%) hue-rotate(92deg) brightness(107%) contrast(107%)";return e(n,{class:b(["zonos--elements zonos--logo",this.class]),style:{"--filter-color":o,"--width":this.width}},e("img",{alt:"Zonos Logo",src:s("./assets/ZonosLogo.png")}))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());E.style=R;var Z='<svg color="var(--amino-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var N='<svg color="var(--amino-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M17.707 14.707a1 1 0 0 1-1.414 0L12 10.414l-4.293 4.293a1 1 0 0 1-1.414-1.414l4.93-4.93a1.1 1.1 0 0 1 1.555 0l4.93 4.93a1 1 0 0 1 0 1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var U=":host{font-family:Inter;display:block}: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 .zonos--total-pay{margin:var(--amino-space-16) 0 var(--amino-space-32)}:host(.mobile){display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;gap:var(--amino-space-24);-ms-flex-pack:justify;justify-content:space-between;padding:var(--amino-space-4) 0;margin-bottom:var(--amino-space-8)}:host(.mobile) .zonos--title{display:-ms-flexbox;display:flex;-ms-flex-item-align:center;align-self:center;gap:var(--amino-space-8)}:host(.mobile) .zonos--total-pay{margin:0}";var W=o("zonos_review",function(){function o(o){t(this,o);this.mobile=false;this.collapsed=false;this.isMobile=false}o.prototype.handleWindowResize=function(){this.isMobile=z(this.mobile)};o.prototype.componentWillLoad=function(){this.isMobile=z(this.mobile)};o.prototype.render=function(){var o=this;var t=this.isMobile?"boldSubheader":"semiBoldLabel";var s=this.isMobile?"boldSubheader":"secondaryPageHeader";var i=this.isMobile?"gray-1200":"gray-800";var a=c.total-c.dutiesTaxFees;var r=function(){if(!o.isMobile){return null}if(!o.collapsed){return e("zonos-icon",{color:"gray-1200",content:Z})}return e("zonos-icon",{color:"gray-1200",content:N})};return e(n,{class:b(["zonos--review zonos--elements",this.isMobile&&"mobile"])},e("div",{class:"zonos--title"},e("zonos-text",{color:i,type:t},m("Pay")," ",y.organizationName),r()),e("div",{class:"zonos--total-pay"},e("zonos-text",{type:s},v({amount:c.step==="shipping"?a:c.total,currency:c.currency}))))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());W.style=U;var G=".sc-zonos-shipping-h{font-family:Inter;display:block}.sc-zonos-shipping-h img.sc-zonos-shipping{max-width:100%}.sc-zonos-shipping-h dl.sc-zonos-shipping,.sc-zonos-shipping-h dd.sc-zonos-shipping,.sc-zonos-shipping-h h1.sc-zonos-shipping,.sc-zonos-shipping-h h2.sc-zonos-shipping,.sc-zonos-shipping-h h3.sc-zonos-shipping,.sc-zonos-shipping-h h4.sc-zonos-shipping,.sc-zonos-shipping-h h5.sc-zonos-shipping,.sc-zonos-shipping-h h6.sc-zonos-shipping,.sc-zonos-shipping-h hr.sc-zonos-shipping,.sc-zonos-shipping-h figure.sc-zonos-shipping,.sc-zonos-shipping-h p.sc-zonos-shipping,.sc-zonos-shipping-h pre.sc-zonos-shipping{margin:0}.sc-zonos-shipping-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-shipping-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-shipping-h .zonos--title.sc-zonos-shipping{margin-bottom:var(--amino-space-24)}.sc-zonos-shipping-h .zonos--shipping-method-title.sc-zonos-shipping{margin-bottom:var(--amino-space-16)}.sc-zonos-shipping-h .zonos-shipping-rich-radio.sc-zonos-shipping{margin-bottom:var(--amino-space-24)}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping{margin-bottom:var(--amino-space-20);overflow:auto;padding:5px}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar{width:10px}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar-track{background:var(--amino-gray-50)}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-shipping-h .zonos--group.sc-zonos-shipping::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-shipping-h .zonos--group-btn.sc-zonos-shipping{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.sc-zonos-shipping-h .zonos--group-btn.sc-zonos-shipping zonos-button.sc-zonos-shipping{width:calc(100% - 10px)}.sc-zonos-shipping-h zonos-banner.sc-zonos-shipping{margin-top:var(--amino-space-24)}";var V=o("zonos_shipping",function(){function o(o){var s=this;t(this,o);this.continueClicked=a(this,"continueClicked",7);this.handleRadioSelected=function(o){return __awaiter(s,void 0,void 0,(function(){var t,s,e;var n=this;return __generator(this,(function(i){switch(i.label){case 0:this.selectedShippingMethod=o.detail;if(!this.selectedShippingMethod){return[2]}s=((t=c.shippingData)===null||t===void 0?void 0:t.find((function(o){var t;return o.id===((t=n.selectedShippingMethod)===null||t===void 0?void 0:t.value)})))||null;if(!s){return[2]}return[4,u(s)];case 1:e=i.sent();if(!e){return[2]}this.disabled=false;return[2]}}))}))};this.continueClickHandler=function(){s.continueClicked.emit()};this.continueLoading=false;this.submitBtnColor=undefined;this.submitBtnType=undefined;this.selectedShippingMethod=null;this.disabled=true}o.prototype.watchFormComplete=function(){if(!this.disabled){g("zonos-checkout-shipping-info")}};o.prototype.render=function(){var o=this;var t;var s=(t=c.shippingData)===null||t===void 0?void 0:t.flatMap((function(o){var t,s;var e=p(o),n=e.expectedDate,i=e.maxTransit,a=e.minTransit;var r=n?"".concat(m("Expected delivery")," ").concat(n):"";var l=a&&i?"(".concat(a,"-").concat(i," ").concat(m("business days"),")"):"";var h=((s=(t=c.landedCostData)===null||t===void 0?void 0:t.find((function(t){var s;return((s=t.landedCost)===null||s===void 0?void 0:s.shipmentRating.id)===o.id})))===null||s===void 0?void 0:s.subtotals.shipping)||0;return{caption:l,label:o.displayName,price:v({amount:h,currency:c.currency}),sublabel:r,value:o.id}}));return e(n,{class:"zonos--shipping zonos--elements"},e("div",{class:"zonos--group"},e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},m("Shipping information")),e("zonos-text",{class:"zonos--shipping-method-title",type:"semiBoldLabel"},m("Shipping method")),!(s===null||s===void 0?void 0:s.length)?e("zonos-banner",{bannerTitle:"No shipping methods found - try editing your address or contacting support if the error persists",intent:"error"}):e("zonos-shipping-rich-radio",{items:s||[],onRadioSelected:function(t){return o.handleRadioSelected(t)}})),e("zonos-button",{backgroundColor:this.submitBtnColor,"is-disabled":this.disabled,loading:this.continueLoading,onClick:function(){return o.continueClickHandler()},size:"lg",variant:this.submitBtnType},m("Go to payment")))};Object.defineProperty(o,"watchers",{get:function(){return{disabled:["watchFormComplete"]}},enumerable:false,configurable:true});return o}());V.style=G}}}));
|