@zonos/elements 1.3.20 → 1.3.22
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-921f0a47.js → cart-f963b239.js} +69 -30
- package/dist/cjs/{getBorderRadius-9ad763e1.js → getBorderRadius-332422ab.js} +1 -1
- package/dist/cjs/index.cjs.js +5 -4
- package/dist/cjs/{isDarkColor-3d021ecc.js → isDarkColor-3ddf6511.js} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{submitGtag-71790233.js → submitGtag-8d562ad4.js} +2 -2
- package/dist/cjs/zonos-address_8.cjs.entry.js +4 -4
- package/dist/cjs/zonos-badge_2.cjs.entry.js +1 -1
- package/dist/cjs/zonos-banner.cjs.entry.js +1 -1
- package/dist/cjs/zonos-button_3.cjs.entry.js +82 -43
- package/dist/cjs/zonos-card_2.cjs.entry.js +4 -4
- package/dist/cjs/zonos-cart-items_11.cjs.entry.js +19 -29
- package/dist/cjs/zonos-checkout.cjs.entry.js +11 -7
- package/dist/cjs/zonos-controller.cjs.entry.js +4 -4
- package/dist/cjs/zonos-country-flag.cjs.entry.js +4 -4
- package/dist/cjs/zonos-country-select_3.cjs.entry.js +11 -9
- package/dist/cjs/zonos-elements.cjs.js +1 -1
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +12 -12
- package/dist/cjs/zonos-hello.cjs.entry.js +10 -6
- package/dist/cjs/zonos-input.cjs.entry.js +2 -2
- package/dist/cjs/zonos-logo.cjs.entry.js +1 -1
- package/dist/cjs/zonos-notification.cjs.entry.js +1 -1
- package/dist/cjs/zonos-payment.cjs.entry.js +4 -4
- package/dist/cjs/zonos-select-dialog-header_2.cjs.entry.js +1 -1
- package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +2 -2
- package/dist/cjs/zonos-text.cjs.entry.js +1 -2
- package/dist/cjs/{zonosStore-1063de5e.js → zonosStore-768d6ca0.js} +2 -1
- package/dist/collection/components/checkout/zonos-checkout/zonos-cart-items/zonos-cart-items.css +7 -0
- package/dist/collection/components/checkout/zonos-checkout/zonos-cart-items/zonos-cart-items.js +4 -4
- package/dist/collection/components/checkout/zonos-checkout/zonos-cart-restricted-items/zonos-cart-restricted-items.js +2 -2
- package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.css +7 -0
- package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.js +5 -5
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-checkout-payment.js +2 -2
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +6 -2
- package/dist/collection/components/checkout/zonos-checkout/zonos-review/zonos-review.js +2 -2
- package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +3 -3
- package/dist/collection/components/common/zonos-button/zonos-button.css +7 -2
- package/dist/collection/components/common/zonos-button/zonos-button.js +74 -39
- package/dist/collection/components/common/zonos-text/zonos-text.js +0 -18
- package/dist/collection/components/hello/zonos-hello/zonos-hello.js +6 -3
- package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.js +8 -5
- package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +8 -8
- package/dist/collection/components/main/zonos-controller.js +2 -2
- package/dist/collection/components/store/hello/localization.js +2 -2
- package/dist/collection/components/store/zonosStore.js +3 -2
- package/dist/collection/components/utils/api/getExchangeRate.js +20 -5
- package/dist/collection/components/utils/hello/currencyConversion/currencyConvertAndFormat.js +1 -1
- package/dist/collection/components/utils/hello/currencyConversion/currencyDisplay.js +1 -1
- package/dist/collection/components/utils/hello/currencyConversion/currencyFormat.js +32 -17
- package/dist/collection/components/utils/hello/currencyConversion/defaultCurrencyConverter.js +12 -2
- package/dist/collection/components/utils/isElementUsingDarkTheme.js +5 -0
- package/dist/collection/scripts/_zonosBase.js +2 -1
- package/dist/esm/{cart-d3c98a81.js → cart-efecbea6.js} +69 -30
- package/dist/esm/{getBorderRadius-393bf797.js → getBorderRadius-a2e46e26.js} +1 -1
- package/dist/esm/index.js +5 -4
- package/dist/esm/{isDarkColor-454ec221.js → isDarkColor-69ed8e39.js} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{submitGtag-acdb8bd7.js → submitGtag-a7b8a86e.js} +2 -2
- package/dist/esm/zonos-address_8.entry.js +4 -4
- package/dist/esm/zonos-badge_2.entry.js +1 -1
- package/dist/esm/zonos-banner.entry.js +1 -1
- package/dist/esm/zonos-button_3.entry.js +82 -43
- package/dist/esm/zonos-card_2.entry.js +4 -4
- package/dist/esm/zonos-cart-items_11.entry.js +19 -29
- package/dist/esm/zonos-checkout.entry.js +11 -7
- package/dist/esm/zonos-controller.entry.js +4 -4
- package/dist/esm/zonos-country-flag.entry.js +4 -4
- package/dist/esm/zonos-country-select_3.entry.js +11 -9
- package/dist/esm/zonos-elements.js +1 -1
- package/dist/esm/zonos-hello-dialog.entry.js +12 -12
- package/dist/esm/zonos-hello.entry.js +10 -6
- package/dist/esm/zonos-input.entry.js +2 -2
- package/dist/esm/zonos-logo.entry.js +1 -1
- package/dist/esm/zonos-notification.entry.js +1 -1
- package/dist/esm/zonos-payment.entry.js +4 -4
- package/dist/esm/zonos-select-dialog-header_2.entry.js +1 -1
- package/dist/esm/zonos-shipping-rich-radio.entry.js +2 -2
- package/dist/esm/zonos-text.entry.js +1 -2
- package/dist/esm/{zonosStore-0ce57f37.js → zonosStore-93da32b4.js} +2 -1
- package/dist/esm-es5/{cart-d3c98a81.js → cart-efecbea6.js} +1 -1
- package/dist/esm-es5/{getBorderRadius-393bf797.js → getBorderRadius-a2e46e26.js} +1 -1
- package/dist/esm-es5/index.js +1 -1
- package/dist/esm-es5/{isDarkColor-454ec221.js → isDarkColor-69ed8e39.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/{submitGtag-acdb8bd7.js → submitGtag-a7b8a86e.js} +1 -1
- package/dist/esm-es5/zonos-address_8.entry.js +1 -1
- package/dist/esm-es5/zonos-badge_2.entry.js +1 -1
- package/dist/esm-es5/zonos-banner.entry.js +1 -1
- package/dist/esm-es5/zonos-button_3.entry.js +1 -1
- package/dist/esm-es5/zonos-card_2.entry.js +1 -1
- package/dist/esm-es5/zonos-cart-items_11.entry.js +1 -1
- package/dist/esm-es5/zonos-checkout.entry.js +1 -1
- package/dist/esm-es5/zonos-controller.entry.js +1 -1
- package/dist/esm-es5/zonos-country-flag.entry.js +1 -1
- package/dist/esm-es5/zonos-country-select_3.entry.js +1 -1
- package/dist/esm-es5/zonos-elements.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-input.entry.js +1 -1
- package/dist/esm-es5/zonos-logo.entry.js +1 -1
- package/dist/esm-es5/zonos-notification.entry.js +1 -1
- package/dist/esm-es5/zonos-payment.entry.js +1 -1
- package/dist/esm-es5/zonos-select-dialog-header_2.entry.js +1 -1
- package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +1 -1
- package/dist/esm-es5/zonos-text.entry.js +1 -1
- package/dist/esm-es5/{zonosStore-0ce57f37.js → zonosStore-93da32b4.js} +1 -1
- package/dist/scripts/index.d.ts +29 -13
- package/dist/scripts/index.js +1 -1
- package/dist/scripts/loadZonos.js +1 -1
- package/dist/scripts/zonos.js +1 -1
- package/dist/types/components/common/zonos-button/zonos-button.d.ts +1 -0
- package/dist/types/components/common/zonos-text/zonos-text.d.ts +0 -4
- package/dist/types/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.d.ts +1 -0
- package/dist/types/components/store/hello/localization.d.ts +2 -2
- package/dist/types/components/store/zonosStore.d.ts +6 -2
- package/dist/types/components/utils/api/getExchangeRate.d.ts +9 -10
- package/dist/types/components/utils/api/triggerBuildLandedCost.d.ts +3 -3
- package/dist/types/components/utils/hello/currencyConversion/currencyFormat.d.ts +5 -1
- package/dist/types/components/utils/isElementUsingDarkTheme.d.ts +1 -0
- package/dist/types/components.d.ts +0 -8
- package/dist/types/scripts/_zonosBase.d.ts +21 -1
- package/dist/types/types/checkout/CheckoutConfig.d.ts +7 -3
- package/dist/zonos-elements/index.esm.js +1 -1
- package/dist/zonos-elements/p-102c670d.entry.js +1 -0
- package/dist/zonos-elements/{p-3668f365.entry.js → p-13940c52.entry.js} +1 -1
- package/dist/zonos-elements/{p-0e6fe6c8.system.entry.js → p-140bb400.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-15c903ff.js → p-18432252.js} +1 -1
- package/dist/zonos-elements/{p-f03b33ec.system.entry.js → p-1e07c616.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-42a7a726.system.entry.js → p-20ab8daf.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-fc2f3e2a.system.entry.js → p-2641f474.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-c15b36c1.system.entry.js → p-283aa6f9.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-3c97c44d.entry.js → p-298b5d95.entry.js} +1 -1
- package/dist/zonos-elements/p-2d3940dc.entry.js +1 -0
- package/dist/zonos-elements/{p-d1b8dcd8.system.entry.js → p-33f83b9a.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-b13e630b.js → p-348adf28.js} +1 -1
- package/dist/zonos-elements/p-36f8a3df.system.js +1 -0
- package/dist/zonos-elements/{p-b9ed8a66.system.entry.js → p-3bee1a04.system.entry.js} +1 -1
- package/dist/zonos-elements/p-49061c5d.entry.js +1 -0
- package/dist/zonos-elements/{p-b202a015.entry.js → p-57d70603.entry.js} +1 -1
- package/dist/zonos-elements/{p-d18990b0.entry.js → p-5b7438ef.entry.js} +1 -1
- package/dist/zonos-elements/p-5ca32f4f.entry.js +1 -0
- package/dist/zonos-elements/p-5edc4f18.system.entry.js +1 -0
- package/dist/zonos-elements/p-678daa20.system.entry.js +1 -0
- package/dist/zonos-elements/{p-14bea5e6.system.entry.js → p-68e3ef26.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-9da3b3b3.system.entry.js → p-6e717c40.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-2d3e3735.js → p-795a3ed5.js} +1 -1
- package/dist/zonos-elements/{p-67373528.entry.js → p-7d2fc0fd.entry.js} +1 -1
- package/dist/zonos-elements/{p-1406d696.system.entry.js → p-85a49fb8.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-3115e7a7.system.js → p-884b41a8.system.js} +1 -1
- package/dist/zonos-elements/p-8a65433a.entry.js +1 -0
- package/dist/zonos-elements/{p-d03e101b.system.entry.js → p-8df58197.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-d5feef4c.js → p-95ffff25.js} +1 -1
- package/dist/zonos-elements/{p-ebb36e4d.entry.js → p-968df90a.entry.js} +1 -1
- package/dist/zonos-elements/{p-23393abc.system.entry.js → p-9a299a98.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-ce4c48f6.entry.js → p-a20f6ba3.entry.js} +1 -1
- package/dist/zonos-elements/{p-f0afca6c.system.js → p-a52afd83.system.js} +1 -1
- package/dist/zonos-elements/{p-0a4f341b.entry.js → p-bbe5d0f0.entry.js} +1 -1
- package/dist/zonos-elements/{p-dd02f2eb.entry.js → p-c0f0edbe.entry.js} +1 -1
- package/dist/zonos-elements/{p-971e73c3.system.entry.js → p-c2328652.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-474cb030.entry.js → p-c53f7199.entry.js} +1 -1
- package/dist/zonos-elements/{p-8f3f1a1b.system.js → p-c7360a6c.system.js} +1 -1
- package/dist/zonos-elements/{p-72191005.system.entry.js → p-c77c056d.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-bfe6f84f.system.entry.js → p-d0a2b1ba.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-f16b80a3.system.js → p-d0c53fba.system.js} +1 -1
- package/dist/zonos-elements/p-d6f829c2.entry.js +1 -0
- package/dist/zonos-elements/{p-2c57097c.entry.js → p-d8255adf.entry.js} +1 -1
- package/dist/zonos-elements/{p-824e1e83.system.js → p-dafc6260.system.js} +1 -1
- package/dist/zonos-elements/{p-eb6ddb2f.js → p-df267420.js} +1 -1
- package/dist/zonos-elements/p-e0bf9666.system.js +1 -1
- package/dist/zonos-elements/{p-f4c921f8.entry.js → p-e5f7ff0f.entry.js} +1 -1
- package/dist/zonos-elements/{p-75d52d98.system.entry.js → p-e625f68d.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-b925e897.system.entry.js → p-ecaed308.system.entry.js} +1 -1
- package/dist/zonos-elements/p-edfb5021.entry.js +1 -0
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +4 -1
- package/dist/collection/components/utils/formatCurrency.js +0 -9
- package/dist/types/components/utils/formatCurrency.d.ts +0 -5
- package/dist/zonos-elements/p-14da9ed0.entry.js +0 -1
- package/dist/zonos-elements/p-2d08c612.system.js +0 -1
- package/dist/zonos-elements/p-3edcbb56.entry.js +0 -1
- package/dist/zonos-elements/p-5968c6ad.entry.js +0 -1
- package/dist/zonos-elements/p-59913049.entry.js +0 -1
- package/dist/zonos-elements/p-957301d0.system.entry.js +0 -1
- package/dist/zonos-elements/p-9e4b35d4.system.entry.js +0 -1
- package/dist/zonos-elements/p-d79e83bd.entry.js +0 -1
- package/dist/zonos-elements/p-eb765228.entry.js +0 -1
- package/dist/zonos-elements/p-f3a6de62.entry.js +0 -1
|
@@ -3,29 +3,19 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
|
-
const zonosStore = require('./zonosStore-
|
|
9
|
-
const submitGtag = require('./submitGtag-
|
|
10
|
-
const getBorderRadius = require('./getBorderRadius-
|
|
8
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
9
|
+
const submitGtag = require('./submitGtag-8d562ad4.js');
|
|
10
|
+
const getBorderRadius = require('./getBorderRadius-332422ab.js');
|
|
11
11
|
const isCheckoutMobile = require('./isCheckoutMobile-f491ca7c.js');
|
|
12
12
|
const ILanguage = require('./ILanguage-d247b45b.js');
|
|
13
|
-
const isDarkColor = require('./isDarkColor-
|
|
13
|
+
const isDarkColor = require('./isDarkColor-3ddf6511.js');
|
|
14
14
|
const isColorVariable = require('./isColorVariable-6f5a9608.js');
|
|
15
15
|
const containsNonLatinChars = require('./containsNonLatinChars-2be5129b.js');
|
|
16
16
|
require('./logError-4e2f2020.js');
|
|
17
17
|
|
|
18
|
-
const
|
|
19
|
-
? `${new Intl.NumberFormat('en-US', {
|
|
20
|
-
currency,
|
|
21
|
-
style: 'currency',
|
|
22
|
-
}).format(amount)} ${currency}`
|
|
23
|
-
: new Intl.NumberFormat('en-US', {
|
|
24
|
-
currency,
|
|
25
|
-
style: 'currency',
|
|
26
|
-
}).format(amount);
|
|
27
|
-
|
|
28
|
-
const zonosCartItemsCss = ":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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--zonos-elements-font-size-base)}:host .zonos--cart-table .zonos--column{padding:8px;font-size:var(--zonos-elements-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}";
|
|
18
|
+
const zonosCartItemsCss = ":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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--zonos-elements-font-size-base)}:host .zonos--cart-table .zonos--column{padding:8px;font-size:var(--zonos-elements-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 .zonos--cart-table td{vertical-align:top}:host .zonos--cart-item-price zonos-text{white-space:nowrap}:host img{min-width:40px;margin-top:6px}";
|
|
29
19
|
const ZonosCartItemsStyle0 = zonosCartItemsCss;
|
|
30
20
|
|
|
31
21
|
const ZonosCartItems = class {
|
|
@@ -38,14 +28,14 @@ const ZonosCartItems = class {
|
|
|
38
28
|
const emptyItemImg = index.getAssetPath('./assets/empty-item.jpeg');
|
|
39
29
|
const rate = ((_a = cart.cartStore.exchangeRate) === null || _a === void 0 ? void 0 : _a.rate) || 1;
|
|
40
30
|
const nonRestrictedItems = cart.cartStore.items.filter(item => !item.isRestricted);
|
|
41
|
-
return (index.h(index.Host, { key: '
|
|
31
|
+
return (index.h(index.Host, { key: '054ea5ed2f86b2d802dd89fe77e010cb2a1a574d', class: "zonos--cart-items zonos--elements" }, index.h("table", { key: '6fcd4c1f30ba1d438a7ef8831ae6475171aa2f79', class: "zonos--cart-table" }, index.h("tbody", { key: 'd82fea259e5f70e43979512e86759b167c7cece8' }, nonRestrictedItems.map(item => {
|
|
42
32
|
const itemImg = item.imageUrl;
|
|
43
33
|
return (index.h("tr", { class: "zonos--cart-item" }, index.h("td", { class: "zonos--column zonos--cart-item-image" }, itemImg && !this.errorImages.includes(itemImg) ? (index.h("img", { alt: item.name, onError: () => {
|
|
44
34
|
this.errorImages = [...this.errorImages, itemImg];
|
|
45
35
|
}, src: item.imageUrl, style: {
|
|
46
36
|
'min-width': '40px',
|
|
47
|
-
}, width: 40 })) : (index.h("img", { alt: item.name, src: emptyItemImg, width: 40 }))), index.h("td", { class: "zonos--column zonos--cart-item-name" }, index.h("zonos-text", { type: "label" }, item.name)), index.h("td", { class: "zonos--column zonos--cart-item-price" }, index.h("zonos-text", { type: "semiBoldLabel" },
|
|
48
|
-
amount: item.amount * item.quantity
|
|
37
|
+
}, width: 40 })) : (index.h("img", { alt: item.name, src: emptyItemImg, width: 40 }))), index.h("td", { class: "zonos--column zonos--cart-item-name" }, index.h("zonos-text", { type: "label" }, item.name)), index.h("td", { class: "zonos--column zonos--cart-item-price" }, index.h("zonos-text", { type: "semiBoldLabel" }, cart.currencyFormat({
|
|
38
|
+
amount: item.amount * rate * item.quantity,
|
|
49
39
|
currency: cart.cartStore.currency,
|
|
50
40
|
})))));
|
|
51
41
|
})))));
|
|
@@ -128,7 +118,7 @@ const ZonosCartRestrictedItems = class {
|
|
|
128
118
|
this.errorImages = [...this.errorImages, itemImg];
|
|
129
119
|
}, src: itemImg, style: {
|
|
130
120
|
'min-width': '40px',
|
|
131
|
-
}, width: 40 })) : (index.h("img", { alt: item.name || `Restricted item ${index$1 + 1}`, src: emptyItemImg, width: 40 }))), index.h("td", { class: "zonos--column zonos--cart-item-name" }, index.h("zonos-text", { type: "label" }, ((_b = item.matchedItem) === null || _b === void 0 ? void 0 : _b.name) || item.name), index.h("zonos-text", { type: "caption" }, item.restriction.reason)), index.h("td", { class: "zonos--column zonos--cart-item-price" }, index.h("zonos-text", { type: "semiBoldLabel" },
|
|
121
|
+
}, width: 40 })) : (index.h("img", { alt: item.name || `Restricted item ${index$1 + 1}`, src: emptyItemImg, width: 40 }))), index.h("td", { class: "zonos--column zonos--cart-item-name" }, index.h("zonos-text", { type: "label" }, ((_b = item.matchedItem) === null || _b === void 0 ? void 0 : _b.name) || item.name), index.h("zonos-text", { type: "caption" }, item.restriction.reason)), index.h("td", { class: "zonos--column zonos--cart-item-price" }, index.h("zonos-text", { type: "semiBoldLabel" }, cart.currencyFormat({
|
|
132
122
|
amount: item.amount * item.quantity * rate,
|
|
133
123
|
currency: cart.cartStore.currency,
|
|
134
124
|
})))));
|
|
@@ -144,7 +134,7 @@ const InfoIcon = `<svg viewBox="0 0 17 16" fill="none" xmlns="https://www.w3.org
|
|
|
144
134
|
</svg>
|
|
145
135
|
`;
|
|
146
136
|
|
|
147
|
-
const zonosCartSubtotalCss = ":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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--zonos-elements-font-size-base)}:host .zonos--cart-table .zonos--column{padding:20px 8px;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:8px}:host .zonos--cart-subtotal-title,:host .zonos--cart-subtotal-price{border-bottom:1px solid var(--zonos-elements-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}";
|
|
137
|
+
const zonosCartSubtotalCss = ":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 .zonos--cart-table{width:100%;border:none;border-collapse:collapse;overflow:auto;font-size:var(--zonos-elements-font-size-base)}:host .zonos--cart-table .zonos--column{padding:20px 8px;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:8px}:host .zonos--cart-subtotal-title,:host .zonos--cart-subtotal-price{border-bottom:1px solid var(--zonos-elements-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}:host .zonos--cart-subtotal-price zonos-text{white-space:nowrap}:host .zonos--cart-subtotal-price zonos-text,:host .zonos--cart-pay-total zonos-text{white-space:nowrap}";
|
|
148
138
|
const ZonosCartSubtotalStyle0 = zonosCartSubtotalCss;
|
|
149
139
|
|
|
150
140
|
const ZonosCartSubtotal = class {
|
|
@@ -162,20 +152,20 @@ const ZonosCartSubtotal = class {
|
|
|
162
152
|
}
|
|
163
153
|
return (index.h(index.Fragment, null, index.h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, cart.cartStore.selectedShippingOption.displayName), cart.cartStore.selectedShippingOptionTransitTime && (index.h("zonos-text", { class: "zonos--caption", type: "caption" }, cart.cartStore.selectedShippingOptionTransitTime, ' ', cart.translate('business days')))));
|
|
164
154
|
};
|
|
165
|
-
return (index.h(index.Host, { class: "zonos--cart-subtotal zonos--elements" }, index.h("table", { class: "zonos--cart-table" }, index.h("tr", { class: "zonos--row zonos--cart-subtotal" }, index.h("td", { class: "zonos--column" }), index.h("td", { class: "zonos--column zonos--cart-subtotal-title" }, index.h("zonos-text", { type: "semiBoldLabel" }, cart.translate('Cart subtotal'))), index.h("td", { class: "zonos--column zonos--cart-subtotal-price" }, index.h("zonos-text", { type: "semiBoldLabel" },
|
|
155
|
+
return (index.h(index.Host, { class: "zonos--cart-subtotal zonos--elements" }, index.h("table", { class: "zonos--cart-table" }, index.h("tr", { class: "zonos--row zonos--cart-subtotal" }, index.h("td", { class: "zonos--column" }), index.h("td", { class: "zonos--column zonos--cart-subtotal-title" }, index.h("zonos-text", { type: "semiBoldLabel" }, cart.translate('Cart subtotal'))), index.h("td", { class: "zonos--column zonos--cart-subtotal-price" }, index.h("zonos-text", { type: "semiBoldLabel" }, cart.currencyFormat({
|
|
166
156
|
amount: subtotal,
|
|
167
157
|
currency: cart.cartStore.currency,
|
|
168
158
|
})))), index.h("tr", { class: "zonos--row zonos--cart-shipping" }, index.h("td", { class: "zonos--column" }), index.h("td", { class: "zonos--column zonos--cart-subtotal-title" }, renderShippingInfo()), index.h("td", { class: "zonos--column zonos--cart-subtotal-price" }, cart.cartStore.shipping
|
|
169
|
-
?
|
|
159
|
+
? cart.currencyFormat({
|
|
170
160
|
amount: cart.cartStore.shipping,
|
|
171
161
|
currency: cart.cartStore.currency,
|
|
172
162
|
})
|
|
173
163
|
: '-')), showDutyTaxesInfo && (index.h("tr", { class: "zonos--row zonos--cart-duties" }, index.h("td", { class: "zonos--column" }), index.h("td", { class: "zonos--column zonos--cart-subtotal-title" }, index.h("div", { class: "zonos--title-with-icon" }, index.h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, cart.translate('Duties, taxes, and fees')), index.h("zonos-tooltip", { label: cart.translate('Nothing due at the door') }, index.h("zonos-icon", { "aria-label": "Learn more about duties, taxes, and fees", content: InfoIcon, size: 16 }))), !!cart.cartStore.isSelectedShippingAboveDeminimis && (index.h("zonos-text", { textColor: "gray-800", type: "body" }, cart.translate('Order is over the de minimis threshold for both duty and tax')))), index.h("td", { class: "zonos--column zonos--cart-subtotal-price" }, index.h("div", { class: "zonos--cart-duty-tax-price" }, cart.cartStore.dutiesTaxFees
|
|
174
|
-
?
|
|
164
|
+
? cart.currencyFormat({
|
|
175
165
|
amount: cart.cartStore.dutiesTaxFees,
|
|
176
166
|
currency: cart.cartStore.currency,
|
|
177
167
|
})
|
|
178
|
-
: '-', cart.cartStore.isSelectedShippingGuarantee && (index.h("zonos-badge", null, cart.translate('Guaranteed'))))))), index.h("tr", { class: "zonos--row zonos--cart-pay-total" }, index.h("td", { class: "zonos--column" }), index.h("td", { class: "zonos--column" }, index.h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, cart.translate('Order total'))), index.h("td", { class: "zonos--column" }, index.h("zonos-text", { type: "semiBoldLabel" },
|
|
168
|
+
: '-', cart.cartStore.isSelectedShippingGuarantee && (index.h("zonos-badge", null, cart.translate('Guaranteed'))))))), index.h("tr", { class: "zonos--row zonos--cart-pay-total" }, index.h("td", { class: "zonos--column" }), index.h("td", { class: "zonos--column" }, index.h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, cart.translate('Order total'))), index.h("td", { class: "zonos--column" }, index.h("zonos-text", { type: "semiBoldLabel" }, cart.currencyFormat({
|
|
179
169
|
amount: total,
|
|
180
170
|
currency: cart.cartStore.currency,
|
|
181
171
|
})))))));
|
|
@@ -438,7 +428,7 @@ const ZonosCheckoutPayment = class {
|
|
|
438
428
|
}
|
|
439
429
|
return (index.h(index.Host, { class: "zonos--checkout-payment zonos--elements" }, index.h("div", { class: "zonos--group" }, index.h("zonos-text", { class: "zonos--title", type: "semiBoldSubheader" }, cart.translate('Payment method')), this.showErrorBanner && (index.h("zonos-banner", { class: "zonos--error-banner", intent: "error" }, cart.translate('Missing required fields. Make sure all fields are completed.'))), this.paymentError && (index.h("zonos-banner", { class: "zonos--payment-error-banner", intent: "error" }, cart.translate("We couldn't complete your payment. Please verify the payment details and try again."))), index.h("zonos-payment", null), index.h("div", { class: "zonos--group-btn" }, index.h("zonos-button", { backgroundColor: this.submitBtnColor, loading: this.continueLoading, onClick: () => this.continueClickHandler(), size: "lg",
|
|
440
430
|
// use primary type when on mobile mode
|
|
441
|
-
variant: this.submitBtnType }, "Pay", ' ',
|
|
431
|
+
variant: this.submitBtnType }, "Pay", ' ', cart.currencyFormat({
|
|
442
432
|
amount: cart.cartStore.total,
|
|
443
433
|
currency: cart.cartStore.currency,
|
|
444
434
|
}))))));
|
|
@@ -878,7 +868,7 @@ const ZonosReview = class {
|
|
|
878
868
|
return (index.h(index.Host, { class: classes.classes([
|
|
879
869
|
'zonos--review zonos--elements',
|
|
880
870
|
this.isMobile && 'mobile',
|
|
881
|
-
]) }, index.h("div", { class: "zonos--title" }, index.h("zonos-text", { textColor: titleTextColor, type: titleTextType }, cart.translate('Pay'), " ", zonosStore.zonosStore.organizationName), renderCollapseIcon()), index.h("div", { class: "zonos--total-pay" }, index.h("zonos-text", { type: totalTextType },
|
|
871
|
+
]) }, index.h("div", { class: "zonos--title" }, index.h("zonos-text", { textColor: titleTextColor, type: titleTextType }, cart.translate('Pay'), " ", zonosStore.zonosStore.organizationName), renderCollapseIcon()), index.h("div", { class: "zonos--total-pay" }, index.h("zonos-text", { type: totalTextType }, cart.currencyFormat({
|
|
882
872
|
amount: total,
|
|
883
873
|
currency: cart.cartStore.currency,
|
|
884
874
|
})))));
|
|
@@ -964,7 +954,7 @@ const ZonosShipping = class {
|
|
|
964
954
|
amount: shippingAmount,
|
|
965
955
|
caption,
|
|
966
956
|
label: item.displayName,
|
|
967
|
-
price:
|
|
957
|
+
price: cart.currencyFormat({
|
|
968
958
|
amount: shippingAmount,
|
|
969
959
|
currency: cart.cartStore.currency,
|
|
970
960
|
}),
|
|
@@ -1005,7 +995,7 @@ const ZonosShipping = class {
|
|
|
1005
995
|
if (this.showErrorBanner) {
|
|
1006
996
|
this.showErrorBanner = !this.handleValidate();
|
|
1007
997
|
}
|
|
1008
|
-
return (index.h(index.Host, { key: '
|
|
998
|
+
return (index.h(index.Host, { key: '11734c7c14a3a63e733a7fa4f2e202bf3b069fd4', class: "zonos--shipping zonos--elements" }, index.h("div", { key: 'ac22237e620e0b65c9b3920d57373207f991d926', class: "zonos--group" }, index.h("zonos-text", { key: 'ee4c12ab90bcd029027284d00ab304ea4dd5a71a', class: "zonos--title", type: "semiBoldSubheader" }, cart.translate('Delivery options')), this.showErrorBanner && !!((_a = this.serviceLevels) === null || _a === void 0 ? void 0 : _a.length) && (index.h("zonos-banner", { key: '4b641aaf9270a8bf022d66878096768fe2956e4a', class: "zonos--error-banner", intent: "error" }, cart.translate('No shipping method selected'))), index.h("zonos-text", { key: '6b29f4338c0920040599cdf01154b43d274ecfed', class: "zonos--shipping-method-title", type: "semiBoldLabel" }, cart.translate('Shipping method')), !((_b = this.serviceLevels) === null || _b === void 0 ? void 0 : _b.length) ? (index.h("zonos-banner", { bannerTitle: cart.translate('No shipping methods found - please review and update your address details by selecting the "Customer" tab above. If you continue to encounter issues, contact our support team for assistance.'), intent: "error" })) : (index.h("zonos-shipping-rich-radio", { initialSelectedValue: (_c = this.selectedShippingMethod) === null || _c === void 0 ? void 0 : _c.value, items: this.serviceLevels, onRadioSelected: e => this.handleRadioSelected(e) })), index.h("div", { key: '7b649c6c3da3c8023edc177077679bc2f397a91f', class: "zonos--group-btn" }, index.h("zonos-button", { key: '18181ad177d5beb7cdd8a3d0e437b332dd20f669', backgroundColor: this.submitBtnColor, loading: this.continueLoading || this.isSelecting, onClick: () => this.continueClickHandler(), size: "lg",
|
|
1009
999
|
// use primary type when on mobile mode
|
|
1010
1000
|
variant: this.submitBtnType }, cart.translate('Go to payment'))))));
|
|
1011
1001
|
}
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
7
|
-
const zonosStore = require('./zonosStore-
|
|
8
|
-
const submitGtag = require('./submitGtag-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
8
|
+
const submitGtag = require('./submitGtag-8d562ad4.js');
|
|
9
9
|
const isCheckoutMobile = require('./isCheckoutMobile-f491ca7c.js');
|
|
10
10
|
const logError = require('./logError-4e2f2020.js');
|
|
11
11
|
const classes = require('./classes-b7918f56.js');
|
|
12
|
-
const getBorderRadius = require('./getBorderRadius-
|
|
13
|
-
const isDarkColor = require('./isDarkColor-
|
|
12
|
+
const getBorderRadius = require('./getBorderRadius-332422ab.js');
|
|
13
|
+
const isDarkColor = require('./isDarkColor-3ddf6511.js');
|
|
14
14
|
const RemoveIcon = require('./RemoveIcon-081ac073.js');
|
|
15
15
|
|
|
16
16
|
/**
|
|
@@ -389,9 +389,13 @@ const ZonosCheckout = class {
|
|
|
389
389
|
const tempCartData = buildCartItemsByTempCart(window.Zonos.tempCartData);
|
|
390
390
|
await cart.cartStoreUpdateItems(tempCartData);
|
|
391
391
|
}
|
|
392
|
-
else if (zonosStore.zonosStore.checkoutSettings.buildCartDetail
|
|
392
|
+
else if (zonosStore.zonosStore.checkoutSettings.buildCartDetail &&
|
|
393
|
+
cart.localizationStore.selectedCountryCode) {
|
|
393
394
|
logError.log('build cart detail');
|
|
394
|
-
const cartItems = await zonosStore.zonosStore.checkoutSettings.buildCartDetail(
|
|
395
|
+
const cartItems = await zonosStore.zonosStore.checkoutSettings.buildCartDetail({
|
|
396
|
+
countryCode: cart.localizationStore.selectedCountryCode,
|
|
397
|
+
currencyCode: cart.localizationStore.targetCurrency,
|
|
398
|
+
});
|
|
395
399
|
await cart.cartStoreUpdateItems(cartItems);
|
|
396
400
|
}
|
|
397
401
|
// if client secret doesn't exist, request a new one.
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
7
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
8
8
|
const logError = require('./logError-4e2f2020.js');
|
|
9
|
-
require('./isDarkColor-
|
|
10
|
-
require('./getBorderRadius-
|
|
9
|
+
require('./isDarkColor-3ddf6511.js');
|
|
10
|
+
require('./getBorderRadius-332422ab.js');
|
|
11
11
|
|
|
12
12
|
const getZonosSettings = async () => {
|
|
13
13
|
const url = `${"https://v1.route.js.zonos.com"}/api/zonos-elements/zonos-settings`;
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
7
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
8
8
|
const classes = require('./classes-b7918f56.js');
|
|
9
9
|
require('./logError-4e2f2020.js');
|
|
10
|
-
require('./isDarkColor-
|
|
11
|
-
require('./getBorderRadius-
|
|
10
|
+
require('./isDarkColor-3ddf6511.js');
|
|
11
|
+
require('./getBorderRadius-332422ab.js');
|
|
12
12
|
|
|
13
13
|
const zonosCountryFlagCss = ":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-inline-flexbox;display:inline-flex}:host .flag-container{position:relative;overflow:hidden;width:100%;height:100%}:host .flag-icon{position:absolute;top:0;left:0;width:100%;height:100%;background-position:center;background-repeat:no-repeat;background-size:cover}";
|
|
14
14
|
const ZonosCountryFlagStyle0 = zonosCountryFlagCss;
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
7
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
8
8
|
const formatStringWithLinks = require('./formatStringWithLinks-52341fc7.js');
|
|
9
|
-
const isDarkColor = require('./isDarkColor-
|
|
9
|
+
const isDarkColor = require('./isDarkColor-3ddf6511.js');
|
|
10
10
|
const ILanguage = require('./ILanguage-d247b45b.js');
|
|
11
11
|
require('./logError-4e2f2020.js');
|
|
12
|
-
require('./getBorderRadius-
|
|
12
|
+
require('./getBorderRadius-332422ab.js');
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* Fuse.js v7.0.0 - Lightweight fuzzy-search (http://fusejs.io)
|
|
@@ -1878,14 +1878,16 @@ const ZonosHelloDialogFooter = class {
|
|
|
1878
1878
|
this.setShowLanguageSelect = () => { };
|
|
1879
1879
|
}
|
|
1880
1880
|
render() {
|
|
1881
|
-
var _a, _b
|
|
1881
|
+
var _a, _b;
|
|
1882
1882
|
const primaryColor = (_a = this.appearanceSettings) === null || _a === void 0 ? void 0 : _a.colorPrimary;
|
|
1883
|
-
const footerTheme = primaryColor && isDarkColor.isDarkColor(primaryColor) ? 'DARK' : 'LIGHT';
|
|
1884
1883
|
const language = (_b = ILanguage.languages.find(x => x.code === cart.localizationStore.selectedLocale)) === null || _b === void 0 ? void 0 : _b.translatedLabel;
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1884
|
+
// Only use gray-0 (white) when the background color is dark (apply inverted color if the element is using dark theme variable)
|
|
1885
|
+
const mainColor = primaryColor && isDarkColor.isDarkColor(primaryColor) ? 'white' : 'black';
|
|
1886
|
+
return (index.h(index.Host, { key: '056e6cead0dd21acc085689ea850ba4a53f67bf9', class: "zonos--elements" }, index.h("div", { key: '00f61e795abc81d6e2f0be7e64eeae298248b34e', class: "zonos--hello-dialog-footer", style: {
|
|
1887
|
+
'--primary-color': primaryColor,
|
|
1888
|
+
} }, index.h("a", { key: '79235722e7f4caaeac2d2a400665603e07b14614', href: "https://zonos.com", target: "_blank", title: "Zonos website" }, index.h("zonos-icon", { key: '7a92af7024dfc3e21de1a0789623b1c1fdb8a33e', "aria-label": "Zonos Logo", autoHeight: true, content: ZonosIcon, iconColor: mainColor, size: 108 })), index.h("div", { key: '04d44adc9941688bc7ae7bef0ea8c9d26a33a401', class: "zonos--hello-locale-wrapper" }, index.h("zonos-button", { key: 'b9f3debc0c965f1ebd8745cb020c10f6e8c17285', buttonColor: mainColor, icon: index.h("zonos-icon", { "aria-label": "Open language select", content: Globe, iconColor: mainColor }), onClick: () => this.setShowLanguageSelect(true), variant: "subtle" }, language), index.h("zonos-button", { key: 'cc3ec6a8ece0ed8e94a85ec3a7a38c3c87fbf95e', buttonColor: mainColor, icon: index.h("zonos-country-flag", { "aria-label": "Open country select", class: "zonos--footer-country-flag", countryCode: cart.localizationStore.selectedCountryCode }), onClick: () => this.setShowCountrySelect(true), variant: "subtle" }, cart.localizationStore.selectedCountryCode)))));
|
|
1888
1889
|
}
|
|
1890
|
+
get ele() { return index.getElement(this); }
|
|
1889
1891
|
};
|
|
1890
1892
|
ZonosHelloDialogFooter.style = ZonosHelloDialogFooterStyle0;
|
|
1891
1893
|
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["zonos-checkout.cjs",[[2,"zonos-checkout",{"appearanceSettingsOverride":[16],"preview":[4],"mobile":[4],"defaultAddress":[16],"forceDialogOpen":[4,"force-dialog-open"],"open":[32],"stripe":[32],"submitLoading":[32],"paymentError":[32],"collapseReviewMobile":[32],"isAttachError":[32],"isMobile":[32],"zonosReviewRef":[32],"storybookPaymentStatusOverride":[32],"domesticRedirectedBtnSelector":[32],"legacyCheckoutHiddenBtnSelector":[32],"isLegacyCheckout":[32],"confirmDialogOpen":[32],"closeDialogHandler":[64],"init":[64],"setToFinishStep":[64]},[[16,"zonos--init-cart-info","initCartInfoHandler"],[4,"keydown","handleKeyPress"],[9,"resize","handleWindowResize"]],{"appearanceSettingsOverride":["appearanceSettingsOverrideChanged","handleAppearanceSettingsOverrideChange"],"mobile":["handleMobileChange"]}]]],["zonos-hello.cjs",[[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],"displayCurrency":[64],"convertAndFormat":[64],"convert":[64],"format":[64],"openHelloDialog":[64]},[[9,"resize","handleResize"]],{"appearanceSettingsOverride":["handleAppearanceSettingsOverrideChange"]}]]],["zonos-controller.cjs",[[1,"zonos-controller",{"config":[16],"zonosApiKey":[1,"zonos-api-key"],"initCheckoutElement":[64],"setupGoogleFont":[64],"showNotification":[64],"overrideConfig":[64],"overrideCountry":[64],"getAppearanceSetting":[64],"updateOrganizationName":[64]},[[8,"locationchange","handleLocationChange"]]]]],["zonos-component.cjs",[[1,"zonos-component",{"first":[1],"middle":[1],"last":[1]}]]],["zonos-link.cjs",[[1,"zonos-link",{"href":[1],"rel":[1],"target":[1],"linkTitle":[1,"link-title"]}]]],["zonos-logo.cjs",[[1,"zonos-logo",{"theme":[1],"width":[1]}]]],["zonos-text.cjs",[[1,"zonos-text",{"textColor":[1,"text-color"],"size":[1],"type":[1],"weight":[2],"
|
|
22
|
+
return index.bootstrapLazy([["zonos-checkout.cjs",[[2,"zonos-checkout",{"appearanceSettingsOverride":[16],"preview":[4],"mobile":[4],"defaultAddress":[16],"forceDialogOpen":[4,"force-dialog-open"],"open":[32],"stripe":[32],"submitLoading":[32],"paymentError":[32],"collapseReviewMobile":[32],"isAttachError":[32],"isMobile":[32],"zonosReviewRef":[32],"storybookPaymentStatusOverride":[32],"domesticRedirectedBtnSelector":[32],"legacyCheckoutHiddenBtnSelector":[32],"isLegacyCheckout":[32],"confirmDialogOpen":[32],"closeDialogHandler":[64],"init":[64],"setToFinishStep":[64]},[[16,"zonos--init-cart-info","initCartInfoHandler"],[4,"keydown","handleKeyPress"],[9,"resize","handleWindowResize"]],{"appearanceSettingsOverride":["appearanceSettingsOverrideChanged","handleAppearanceSettingsOverrideChange"],"mobile":["handleMobileChange"]}]]],["zonos-hello.cjs",[[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],"displayCurrency":[64],"convertAndFormat":[64],"convert":[64],"format":[64],"openHelloDialog":[64]},[[9,"resize","handleResize"]],{"appearanceSettingsOverride":["handleAppearanceSettingsOverrideChange"]}]]],["zonos-controller.cjs",[[1,"zonos-controller",{"config":[16],"zonosApiKey":[1,"zonos-api-key"],"initCheckoutElement":[64],"setupGoogleFont":[64],"showNotification":[64],"overrideConfig":[64],"overrideCountry":[64],"getAppearanceSetting":[64],"updateOrganizationName":[64]},[[8,"locationchange","handleLocationChange"]]]]],["zonos-component.cjs",[[1,"zonos-component",{"first":[1],"middle":[1],"last":[1]}]]],["zonos-link.cjs",[[1,"zonos-link",{"href":[1],"rel":[1],"target":[1],"linkTitle":[1,"link-title"]}]]],["zonos-logo.cjs",[[1,"zonos-logo",{"theme":[1],"width":[1]}]]],["zonos-text.cjs",[[1,"zonos-text",{"textColor":[1,"text-color"],"size":[1],"type":[1],"weight":[2],"ready":[32]}]]],["zonos-hello-dialog.cjs",[[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"]}]]],["zonos-notification.cjs",[[1,"zonos-notification",{"notificationArray":[32],"showNotification":[64]}]]],["zonos-payment.cjs",[[2,"zonos-payment",{"titleText":[1,"title-text"],"stripe":[32],"stripeElements":[32]},null,{"stripeElements":["watchInitStripe"],"stripe":["watchInitStripe"]}]]],["zonos-shipping-rich-radio.cjs",[[1,"zonos-shipping-rich-radio",{"items":[16],"borderColor":[1,"border-color"],"borderStyle":[1,"border-style"],"theme":[1],"initialSelectedValue":[8,"initial-selected-value"],"selectedItem":[32]}]]],["zonos-badge_2.cjs",[[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]}]]],["zonos-input.cjs",[[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"]}]]],["zonos-banner.cjs",[[1,"zonos-banner",{"bannerTitle":[1,"banner-title"],"intent":[1],"hasContent":[32]}]]],["zonos-button_3.cjs",[[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],"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]}]]],["zonos-select-dialog-header_2.cjs",[[1,"zonos-select-dialog-header",{"handleOnClose":[16],"label":[1]}],[1,"zonos-v-stack",{"spacing":[2]}]]],["zonos-card_2.cjs",[[1,"zonos-language-select",{"handleOnClose":[16]}],[1,"zonos-card",{"actions":[16],"footerActions":[16],"footerContent":[16],"footerHeight":[2,"footer-height"],"label":[16],"spacing":[1]}]]],["zonos-country-flag.cjs",[[1,"zonos-country-flag",{"countryCode":[1,"country-code"],"size":[2]}]]],["zonos-country-select_3.cjs",[[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]}]]],["zonos-address_8.cjs",[[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]}]]],["zonos-cart-items_11.cjs",[[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]}],[1,"zonos-checkout-footer",{"mobile":[4],"dataTheme":[1,"data-theme"],"showLanguageDialog":[32],"isMobile":[32]},[[4,"click","handleGlobalClick"]],{"mobile":["handleMobileChange"]}],[2,"zonos-checkout-payment",{"paymentError":[4,"payment-error"],"submitBtnType":[1,"submit-btn-type"],"continueLoading":[4,"continue-loading"],"submitBtnColor":[1,"submit-btn-color"],"showErrorBanner":[32]}],[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],"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"],"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]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
7
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
8
8
|
const classes = require('./classes-b7918f56.js');
|
|
9
9
|
const formatStringWithLinks = require('./formatStringWithLinks-52341fc7.js');
|
|
10
10
|
const getHasMoreSpaceOnRight = require('./getHasMoreSpaceOnRight-4c94667f.js');
|
|
11
11
|
require('./logError-4e2f2020.js');
|
|
12
|
-
require('./isDarkColor-
|
|
13
|
-
require('./getBorderRadius-
|
|
12
|
+
require('./isDarkColor-3ddf6511.js');
|
|
13
|
+
require('./getBorderRadius-332422ab.js');
|
|
14
14
|
|
|
15
15
|
const getHasMoreSpaceAbove = (ref) => {
|
|
16
16
|
const componentRect = ref.getBoundingClientRect();
|
|
@@ -78,7 +78,7 @@ const ZonosHelloDialog = class {
|
|
|
78
78
|
const { countryLandedCost } = cart.localizationStore;
|
|
79
79
|
// Our Robby API spells deminimis wrong here
|
|
80
80
|
const dutyDeminimis = (countryLandedCost === null || countryLandedCost === void 0 ? void 0 : countryLandedCost.dutyDeminimus)
|
|
81
|
-
? cart.currencyFormat(countryLandedCost.dutyDeminimus)
|
|
81
|
+
? cart.currencyFormat({ amount: countryLandedCost.dutyDeminimus })
|
|
82
82
|
: null;
|
|
83
83
|
// If deminimis is undefined or null, assume it's $0
|
|
84
84
|
return dutyDeminimis
|
|
@@ -89,7 +89,7 @@ const ZonosHelloDialog = class {
|
|
|
89
89
|
const { countryLandedCost } = cart.localizationStore;
|
|
90
90
|
// Our Robby API spells deminimis wrong here
|
|
91
91
|
const taxDeminimis = (countryLandedCost === null || countryLandedCost === void 0 ? void 0 : countryLandedCost.vatTaxDeminimus)
|
|
92
|
-
? cart.currencyFormat(countryLandedCost.vatTaxDeminimus)
|
|
92
|
+
? cart.currencyFormat({ amount: countryLandedCost.vatTaxDeminimus })
|
|
93
93
|
: null;
|
|
94
94
|
return taxDeminimis
|
|
95
95
|
? `${cart.translate('Spend')} ${taxDeminimis} ${cart.translate('tax free')}`
|
|
@@ -103,19 +103,19 @@ const ZonosHelloDialog = class {
|
|
|
103
103
|
const dutyDeminimis = landedCost.dutyDeminimus;
|
|
104
104
|
return cart.translate('Orders to ${countryName} must be over ${threshold} to ship.', {
|
|
105
105
|
countryName: 'United Kingdom',
|
|
106
|
-
threshold: cart.currencyFormat(dutyDeminimis),
|
|
106
|
+
threshold: cart.currencyFormat({ amount: dutyDeminimis }),
|
|
107
107
|
});
|
|
108
108
|
};
|
|
109
109
|
this.getAustraliaDutyTaxMessage = (landedCost) => {
|
|
110
110
|
return cart.translate('${percentage} GST due on any order above ${threshold}.', {
|
|
111
111
|
percentage: `${landedCost.vatTaxRate * 100}%`,
|
|
112
|
-
threshold: cart.currencyFormat(landedCost.vatTaxDeminimus),
|
|
112
|
+
threshold: cart.currencyFormat({ amount: landedCost.vatTaxDeminimus }),
|
|
113
113
|
});
|
|
114
114
|
};
|
|
115
115
|
this.getNewZealandDutyTaxMessge = (landedCost) => {
|
|
116
116
|
return cart.translate('${percentage} GST due on any order above ${threshold} along with an import entry transaction fee and MPI levy.', {
|
|
117
117
|
percentage: `${landedCost.vatTaxRate * 100}%`,
|
|
118
|
-
threshold: cart.currencyFormat(landedCost.vatTaxDeminimus),
|
|
118
|
+
threshold: cart.currencyFormat({ amount: landedCost.vatTaxDeminimus }),
|
|
119
119
|
});
|
|
120
120
|
};
|
|
121
121
|
/**
|
|
@@ -179,17 +179,17 @@ const ZonosHelloDialog = class {
|
|
|
179
179
|
const defaultMessage = formatStringWithLinks.formatStringWithLinks(defaultMessageStr);
|
|
180
180
|
const currentPage = this.getCurrentPageEnum();
|
|
181
181
|
const filteredMessages = customMessages.filter(x => x.pageName === currentPage);
|
|
182
|
-
return (index.h(index.Host, { key: '
|
|
182
|
+
return (index.h(index.Host, { key: 'ec64ed364328acba99227ccb40371ff6b7e0c1e2', class: "zonos--elements" }, index.h("div", { key: '441d4a9ae4274b0fffbd22771b8f1ffe3839230a', "aria-hidden": "true", class: classes.classes([
|
|
183
183
|
'zonos--hello-dialog',
|
|
184
184
|
animateLeft && 'zonos--hello-dialog-animate-from-left',
|
|
185
185
|
animateFromBottom && 'zonos--hello-dialog-animate-from-bottom',
|
|
186
186
|
!!this.mobileLocationOverride &&
|
|
187
187
|
'zonos--hello-dialog-mobile-override',
|
|
188
188
|
this.isOpen && 'zonos--hello-dialog-open',
|
|
189
|
-
]), ref: el => el && (this.dialogRef = el) }, !this.showCountrySelect && !this.showLanguageSelect && (index.h("div", { key: '
|
|
189
|
+
]), ref: el => el && (this.dialogRef = el) }, !this.showCountrySelect && !this.showLanguageSelect && (index.h("div", { key: '9d53c5dd06b5f1b1a0800bfdaee9615e851b3338' }, index.h("div", { key: '43b424d7d115ead896f0ce743d60db1775468ada', class: "zonos--hello-dialog-content" }, index.h("zonos-button", { key: '2dacf61dfd6976de8a37f63697a927b00c70500c', class: "zonos--close-button", icon: index.h("zonos-icon", { "aria-label": "Close Zonos Hello dialog", content: RemoveIcon }), noBackground: true, onClick: () => this.setIsOpen(false) }), index.h("zonos-v-stack", { key: '75d1b83b6e7bcefe592bd90e1fbcfd97154f0b4c', spacing: 24 }, index.h("zonos-country-flag", { key: '051019e1d01cc12d38d82c5c1d2765b280cf87e4', class: "zonos--hello-country-flag", countryCode: selectedCountryCode }), index.h("zonos-v-stack", { key: '4dd4f2bb7b8f88fcdb8c27ebaca86bbaa4f8459a', class: "zonos--hello-dialog-header", spacing: 4 }, index.h("zonos-text", { key: '33a2430d344b0613fda2597e5e8d52e852398a3c', type: "boldSubheader" }, welcomeMessage), index.h("zonos-text", { key: '5e0785c9e190be41d5c1b22736a73031de0f0a8b', innerHTML: defaultMessage, textColor: "gray-800" })), index.h("zonos-v-stack", { key: '460c1914c7f91ad7d3495e77f2f0de412e0d2f78', spacing: 8 }, this.restrictedItems.map(item => {
|
|
190
190
|
var _a;
|
|
191
191
|
return item && (index.h("zonos-banner", { bannerTitle: item.name, intent: "error" }, (_a = item.itemRestrictions) === null || _a === void 0 ? void 0 : _a.map(x => (index.h("zonos-text", { textColor: "red-800" }, x === null || x === void 0 ? void 0 : x.note)))));
|
|
192
|
-
}), index.h("zonos-card", { key: '
|
|
192
|
+
}), index.h("zonos-card", { key: '290e82532fc85421c08c0049755f2d03de5f4848', spacing: "12px" }, index.h("zonos-v-stack", { key: 'de37e3b7c156a952ff4906463f4e57c0e384af18', spacing: 12 }, index.h("div", { key: '3ce588bffccb7c41d5043d813fb6b9b0043d4fab', class: "zonos--flex-message" }, index.h("zonos-icon", { key: '3c955c3aa1a27566e503188a4a4f495c2daed5b1', "aria-label": "Duty de minimis", content: ImportIcon }), index.h("zonos-text", { key: '8b283197b31e82a8c15eff248e1ab55b28eba3d2' }, dutyDeMinimisMessage)), index.h("div", { key: '720af84433106750661c5d2e847c58ba673ee71c', class: "zonos--flex-message" }, index.h("zonos-icon", { key: '036e93ccbdafd6c6e911cc978f331c84ee542c73', "aria-label": "Tax de minimis", content: MoneyIcon }), index.h("zonos-text", { key: 'ca33772a3fce849a35536502d95ca81d3e9b29cb' }, taxDeMinimisMessage)), additionalInformation && (index.h("div", { key: '254ac11735d2e3f5b3804d58c22847414df19753', class: "zonos--flex-message" }, index.h("zonos-icon", { key: '28d85fa72b8d0754ba5f1633f17bd0caf78abe36', "aria-label": "Low value order shipping restriction", content: BagIcon }), index.h("zonos-text", { key: '6ff2d5231f7fd942c0ff7b3391589984f5d0e7d2' }, additionalInformation))))), filteredMessages.map(x => (index.h("zonos-custom-message", { icon: MessageIcon, message: x.message })))))), index.h("zonos-hello-dialog-footer", { key: '4d6593ce36f883bb538970008aa75ba3338654e5', appearanceSettings: this.appearanceSettings, setShowCountrySelect: value => this.setShowCountrySelect(value), setShowLanguageSelect: value => this.setShowLanguageSelect(value) }))), this.showCountrySelect && (index.h("div", { key: '66362e6aac0c8d9b5fe922c3af4d74642ff6fe8a' }, index.h("zonos-country-select", { key: '53fc96743eb427f76e6c658b1b3541f43afab25a', handleOnClose: () => this.setShowCountrySelect(false) }))), this.showLanguageSelect && (index.h("div", { key: 'e4cc485d4574d11b5759e485be18e3e2cb0af966' }, index.h("zonos-language-select", { key: '579c3018f84fedf257253b6db0b0c172908662e2', handleOnClose: () => this.setShowLanguageSelect(false) }))))));
|
|
193
193
|
}
|
|
194
194
|
static get assetsDirs() { return ["assets"]; }
|
|
195
195
|
static get watchers() { return {
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
7
|
-
const cart = require('./cart-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
|
+
const cart = require('./cart-f963b239.js');
|
|
8
8
|
const classes = require('./classes-b7918f56.js');
|
|
9
9
|
const logError = require('./logError-4e2f2020.js');
|
|
10
10
|
const getHasMoreSpaceOnRight = require('./getHasMoreSpaceOnRight-4c94667f.js');
|
|
11
|
-
require('./isDarkColor-
|
|
12
|
-
require('./getBorderRadius-
|
|
11
|
+
require('./isDarkColor-3ddf6511.js');
|
|
12
|
+
require('./getBorderRadius-332422ab.js');
|
|
13
13
|
|
|
14
14
|
var root = zonosStore._root;
|
|
15
15
|
|
|
@@ -673,8 +673,12 @@ const ZonosHello = class {
|
|
|
673
673
|
* @returns void
|
|
674
674
|
*/
|
|
675
675
|
async displayCurrency() {
|
|
676
|
+
if (zonosStore.zonosStore.helloSettings.currencyBehavior === 'DISABLED') {
|
|
677
|
+
// do nothing if currency behavior is disabled
|
|
678
|
+
return;
|
|
679
|
+
}
|
|
676
680
|
if (!cart.localizationStore.exchangeRate) {
|
|
677
|
-
logError.
|
|
681
|
+
logError.log('Could not display currency. Exchange rate and format data is not available.', 'warn');
|
|
678
682
|
return;
|
|
679
683
|
}
|
|
680
684
|
cart.currencyDisplay();
|
|
@@ -698,7 +702,7 @@ const ZonosHello = class {
|
|
|
698
702
|
* @returns number
|
|
699
703
|
*/
|
|
700
704
|
async format(value) {
|
|
701
|
-
return cart.currencyFormat(value);
|
|
705
|
+
return cart.currencyFormat({ amount: value });
|
|
702
706
|
}
|
|
703
707
|
/**
|
|
704
708
|
* This method show the hello dialog
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
|
-
const getBorderRadius = require('./getBorderRadius-
|
|
8
|
+
const getBorderRadius = require('./getBorderRadius-332422ab.js');
|
|
9
9
|
|
|
10
10
|
const zonosInputCss = ":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{margin:1px;}:host .zonos--label-wrapper{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;height:100%;width:100%;background:var(--zonos-elements-input-background);border-radius:var(--border-radius);border:var(--zonos-elements-border)}:host .zonos--label-wrapper:hover{border:1px solid var(--zonos-elements-gray-300)}:host .zonos--floated-input{-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;padding:0 16px;outline:none;-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);width:100%;border-radius:var(--border-radius);background:var(--zonos-elements-input-background);border:0;-ms-flex-order:2;order:2;font-weight:500}:host .zonos--floated-input :-internal-autofill-selected{border-radius:var(--zonos-elements-radius-6) 0 0 var(--zonos-elements-radius-6)}:host .zonos--floated-input :-internal-autofill-selected+label+div{background-color:#e8f0fe}:host .zonos--floated-input.has-label{padding:16px 4px 8px 16px}:host .zonos--floated-input.has-label.has-input-prefix{padding-left:0}:host .zonos--floated-input.has-label.has-input-prefix+.zonos--floated-label::before{margin-left:0}:host .zonos--floated-input:not(.has-label)::-webkit-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input:not(.has-label)::-moz-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input:not(.has-label):-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input:not(.has-label)::-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input:not(.has-label)::placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input::-webkit-input-placeholder{-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}:host .zonos--floated-input::-moz-placeholder{-moz-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}:host .zonos--floated-input:-ms-input-placeholder{-ms-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}:host .zonos--floated-input::-ms-input-placeholder{-ms-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}:host .zonos--floated-input::placeholder{-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);opacity:0}:host .zonos--floated-input:focus{outline:none}:host .zonos--floated-input:focus+.zonos--floated-label::after{-webkit-box-shadow:var(--zonos-elements-glow-blue);box-shadow:var(--zonos-elements-glow-blue)}:host .zonos--floated-input.has-error+.zonos--floated-label::after{-webkit-box-shadow:var(--zonos-elements-glow-error);box-shadow:var(--zonos-elements-glow-error)}:host .zonos--floated-input.has-content::-webkit-input-placeholder,:host .zonos--floated-input:focus::-webkit-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input.has-content::-moz-placeholder,:host .zonos--floated-input:focus::-moz-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input.has-content:-ms-input-placeholder,:host .zonos--floated-input:focus:-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input.has-content::-ms-input-placeholder,:host .zonos--floated-input:focus::-ms-input-placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input.has-content::placeholder,:host .zonos--floated-input:focus::placeholder{opacity:var(--zonos-elements-opacity-disabled)}:host .zonos--floated-input.has-content+.zonos--floated-label::before,:host .zonos--floated-input:focus+.zonos--floated-label::before{top:11px;-webkit-transform:scale(0.8);transform:scale(0.8)}:host .zonos--floated-input:-webkit-autofill,:host .zonos--floated-input:-moz-autofill{background-color:var(--zonos-elements-input-background);color:var(--zonos-elements-text-color)}:host .zonos--floated-label{display:block;max-height:0;pointer-events:none;-ms-flex-order:1;order:1}:host .zonos--floated-label::before{content:attr(data-label);color:var(--zonos-elements-gray-800);position:absolute;font-size:var(--zonos-elements-font-size-base);line-height:var(--zonos-elements-font-size-base);display:inline-block;-webkit-filter:blur(0);filter:blur(0);-webkit-transform-origin:left top;transform-origin:left top;-webkit-transition:var(--zonos-elements-transition);transition:var(--zonos-elements-transition);margin-left:16px;top:calc(50% - var(--zonos-elements-font-size-base) / 2);z-index:1}:host .zonos--floated-label::after{content:\"\";position:absolute;left:0;right:0;top:0;bottom:0;border-radius:var(--border-radius)}:host .disabled .zonos--floated-label{pointer-events:inherit}:host .disabled .zonos--floated-label::after{cursor:not-allowed;z-index:1}:host(.sm){height:calc(var(--zonos-elements-size-sm) - 2px)}:host(.sm) .zonos--floated-input.has-label{padding-top:13px;padding-bottom:0}:host(.sm) .zonos--floated-input.has-label:focus+.zonos--floated-label::before,:host(.sm) .zonos--floated-input.has-label.has-content+.zonos--floated-label::before{top:2px}:host(.md){height:calc(var(--zonos-elements-size-md) - 2px)}:host(.md) .zonos--floated-input.has-label{padding-top:20px}:host(.md) .zonos--floated-input.has-label:focus+.zonos--floated-label::before,:host(.md) .zonos--floated-input.has-label.has-content+.zonos--floated-label::before{top:6px}:host(.lg){height:calc(var(--zonos-elements-size-lg) - 2px)}:host(.lg) .zonos--floated-input.has-label:focus+.zonos--floated-label::before,:host(.lg) .zonos--floated-input.has-label.has-content+.zonos--floated-label::before{top:10px}:host(.xl){height:calc(var(--zonos-elements-size-xl) - 2px)}:host(.xl) .zonos--floated-input.has-label{padding-bottom:2px}";
|
|
11
11
|
const ZonosInputStyle0 = zonosInputCss;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
8
|
|
|
9
9
|
const zonosLogoCss = ":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-inline-flexbox;display:inline-flex}:host img{-webkit-filter:var(--filter-color);filter:var(--filter-color);width:var(--width)}";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
8
|
|
|
9
9
|
const zonosNotificationCss = ":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:9999999;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)}";
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const cart = require('./cart-
|
|
6
|
+
const cart = require('./cart-f963b239.js');
|
|
7
7
|
const logError = require('./logError-4e2f2020.js');
|
|
8
|
-
require('./zonosStore-
|
|
9
|
-
require('./isDarkColor-
|
|
10
|
-
require('./getBorderRadius-
|
|
8
|
+
require('./zonosStore-768d6ca0.js');
|
|
9
|
+
require('./isDarkColor-3ddf6511.js');
|
|
10
|
+
require('./getBorderRadius-332422ab.js');
|
|
11
11
|
|
|
12
12
|
const zonosPaymentCss = ".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}";
|
|
13
13
|
const ZonosPaymentStyle0 = zonosPaymentCss;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
8
|
|
|
9
9
|
const RemoveIcon = `<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>`;
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
|
-
const getBorderRadius = require('./getBorderRadius-
|
|
8
|
+
const getBorderRadius = require('./getBorderRadius-332422ab.js');
|
|
9
9
|
const isColorVariable = require('./isColorVariable-6f5a9608.js');
|
|
10
10
|
|
|
11
11
|
const zonosShippingRichRadioCss = ":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-direction:column;flex-direction:column}:host input{margin:0;accent-color:var(--selected-border-color, var(--zonos-elements-blue-600))}:host .zonos--shipping-rich-radio-item{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;padding:16px;-ms-flex-align:center;align-items:center;gap:16px;cursor:pointer;border:1px solid var(--zonos-elements-gray-200)}:host .zonos--shipping-rich-radio-item:first-child{border-top-left-radius:var(--border-radius, var(--zonos-elements-radius-10));border-top-right-radius:var(--border-radius, var(--zonos-elements-radius-10))}:host .zonos--shipping-rich-radio-item:last-child{border-bottom-right-radius:var(--border-radius, var(--zonos-elements-radius-10));border-bottom-left-radius:var(--border-radius, var(--zonos-elements-radius-10))}:host .zonos--shipping-rich-radio-item:not(:last-child){border-bottom:none}:host .zonos--shipping-rich-radio-item.selected{outline:1px solid var(--selected-border-color, var(--zonos-elements-blue-600));outline-offset:-1px}:host .zonos--shipping-info{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex:1;flex:1}:host .zonos--shipping-detail{-ms-flex:1;flex:1}:host .zonos--sub-detail{display:-ms-inline-flexbox;display:inline-flex;gap:8px;-ms-flex-wrap:wrap;flex-wrap:wrap}";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-b071017b.js');
|
|
6
|
-
const zonosStore = require('./zonosStore-
|
|
6
|
+
const zonosStore = require('./zonosStore-768d6ca0.js');
|
|
7
7
|
const classes = require('./classes-b7918f56.js');
|
|
8
8
|
const isColorVariable = require('./isColorVariable-6f5a9608.js');
|
|
9
9
|
|
|
@@ -117,7 +117,6 @@ const ZonosText = class {
|
|
|
117
117
|
this.size = undefined;
|
|
118
118
|
this.type = 'body';
|
|
119
119
|
this.weight = undefined;
|
|
120
|
-
this.content = undefined;
|
|
121
120
|
this.ready = false;
|
|
122
121
|
}
|
|
123
122
|
componentDidRender() {
|