@zonos/elements 1.3.18-alpha.2 → 1.3.18-alpha.4
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/README.md +341 -96
- package/dist/cjs/{cart-941a31dd.js → cart-72b0bccc.js} +34 -85
- package/dist/cjs/index.cjs.js +628 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/logError-4e2f2020.js +58 -0
- package/dist/cjs/{submitGtag-9210b4fe.js → submitGtag-b0c8de90.js} +3 -2
- package/dist/cjs/zonos-address_8.cjs.entry.js +13 -12
- package/dist/cjs/zonos-badge_2.cjs.entry.js +3 -3
- package/dist/cjs/zonos-button_3.cjs.entry.js +3 -3
- package/dist/cjs/zonos-card_2.cjs.entry.js +7 -6
- package/dist/cjs/zonos-cart-items_11.cjs.entry.js +11 -10
- package/dist/cjs/zonos-checkout.cjs.entry.js +20 -15
- package/dist/cjs/zonos-controller.cjs.entry.js +47 -20
- package/dist/cjs/zonos-country-flag.cjs.entry.js +2 -1
- package/dist/cjs/zonos-country-select_3.cjs.entry.js +6 -5
- package/dist/cjs/zonos-elements.cjs.js +1 -1
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +2 -1
- package/dist/cjs/zonos-hello.cjs.entry.js +10 -9
- package/dist/cjs/zonos-input.cjs.entry.js +4 -4
- package/dist/cjs/zonos-link.cjs.entry.js +1 -1
- package/dist/cjs/zonos-payment.cjs.entry.js +3 -2
- package/dist/collection/__mocks__/zonos-url/index.js +1 -0
- package/dist/collection/__tests__/build-utils/urlCheckOne.js +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js +4 -9
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +8 -4
- package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +3 -3
- package/dist/collection/components/common/zonos-badge/zonos-badge.js +3 -3
- package/dist/collection/components/common/zonos-button/zonos-button.js +3 -3
- package/dist/collection/components/common/zonos-card/zonos-card.js +3 -3
- package/dist/collection/components/common/zonos-checkbox/zonos-checkbox.js +3 -3
- package/dist/collection/components/common/zonos-checkout-progress-tabs/zonos-checkout-progress-tabs.js +3 -3
- package/dist/collection/components/common/zonos-collapse/zonos-collapse.js +2 -2
- package/dist/collection/components/common/zonos-confirm-dialog/zonos-confirm-dialog.js +3 -3
- package/dist/collection/components/common/zonos-country-select/zonos-country-select.js +2 -2
- package/dist/collection/components/common/zonos-custom-message/zonos-custom-message.js +2 -2
- package/dist/collection/components/common/zonos-dialog/zonos-dialog.js +3 -3
- package/dist/collection/components/common/zonos-input/zonos-input.js +4 -4
- package/dist/collection/components/common/zonos-language-select/zonos-language-select.js +2 -2
- package/dist/collection/components/common/{component-template/zonos-link → zonos-link}/zonos-link.js +1 -1
- package/dist/collection/components/main/zonos-controller.js +41 -6
- package/dist/collection/components/stripe/zonos-address/zonos-address.js +3 -3
- package/dist/collection/components/utils/hello/setZCountryUrlParam.js +5 -1
- package/dist/collection/environment.js +0 -2
- package/dist/collection/index.js +1 -0
- package/dist/collection/scripts/_extractZonosQaUrl.js +26 -0
- package/dist/collection/scripts/_getZonosQaUrl.js +44 -0
- package/dist/collection/scripts/{loadStripe.js → _loadStripe.js} +1 -1
- package/dist/collection/scripts/{zonosBase.js → _zonosBase.js} +29 -6
- package/dist/collection/scripts/index.js +2 -0
- package/dist/collection/types/generated/graphql.customer.types.js +1 -0
- package/dist/collection/types/generated/graphql.frontend.types.js +1 -0
- package/dist/esm/{cart-cc593c2b.js → cart-1a37e002.js} +7 -56
- package/dist/esm/index.js +625 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/logError-c456c092.js +55 -0
- package/dist/esm/{submitGtag-e50f903f.js → submitGtag-754935b4.js} +2 -1
- package/dist/esm/zonos-address_8.entry.js +11 -10
- package/dist/esm/zonos-badge_2.entry.js +3 -3
- package/dist/esm/zonos-button_3.entry.js +3 -3
- package/dist/esm/zonos-card_2.entry.js +7 -6
- package/dist/esm/zonos-cart-items_11.entry.js +11 -10
- package/dist/esm/zonos-checkout.entry.js +8 -3
- package/dist/esm/zonos-controller.entry.js +30 -3
- package/dist/esm/zonos-country-flag.entry.js +2 -1
- package/dist/esm/zonos-country-select_3.entry.js +6 -5
- package/dist/esm/zonos-elements.js +1 -1
- package/dist/esm/zonos-hello-dialog.entry.js +2 -1
- package/dist/esm/zonos-hello.entry.js +2 -1
- package/dist/esm/zonos-input.entry.js +4 -4
- package/dist/esm/zonos-link.entry.js +1 -1
- package/dist/esm/zonos-payment.entry.js +2 -1
- package/dist/esm-es5/cart-1a37e002.js +1 -0
- package/dist/esm-es5/index.js +1 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/logError-c456c092.js +1 -0
- package/dist/esm-es5/submitGtag-754935b4.js +1 -0
- 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-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-link.entry.js +1 -1
- package/dist/esm-es5/zonos-payment.entry.js +1 -1
- package/dist/scripts/index.d.ts +3908 -0
- package/dist/scripts/index.js +1 -0
- package/dist/scripts/loadZonos.d.ts +3954 -0
- package/dist/scripts/loadZonos.js +1 -1
- package/dist/scripts/zonos.js +1 -1
- package/dist/types/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.d.ts +5 -7
- package/dist/types/components/checkout/zonos-checkout/zonos-checkout.d.ts +2 -2
- package/dist/types/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.d.ts +2 -2
- package/dist/types/components/main/zonos-controller.d.ts +6 -1
- package/dist/types/components/store/checkout/stripe.d.ts +1 -1
- package/dist/types/components/store/zonosStore.d.ts +1 -1
- package/dist/types/components/stripe/zonos-address/zonos-address.d.ts +2 -2
- package/dist/types/components/utils/styles.d.ts +1 -0
- package/dist/types/components.d.ts +22 -14
- package/dist/types/index.d.ts +1 -0
- package/dist/types/scripts/_extractZonosQaUrl.d.ts +11 -0
- package/dist/types/scripts/_getZonosQaUrl.d.ts +4 -0
- package/dist/types/scripts/{loadStripe.d.ts → _loadStripe.d.ts} +1 -1
- package/dist/types/scripts/{zonosBase.d.ts → _zonosBase.d.ts} +36 -2
- package/dist/types/scripts/index.d.ts +2 -0
- package/dist/types/types/checkout/CheckoutConfig.d.ts +5 -0
- package/dist/types/types/checkout/api/CalculateLandedCostRequest.d.ts +9 -0
- package/dist/types/types/generated/graphql.customer.types.d.ts +1 -0
- package/dist/types/types/generated/graphql.customer.types.ts +3 -0
- package/dist/types/types/generated/graphql.frontend.types.d.ts +1 -0
- package/dist/types/types/generated/graphql.frontend.types.ts +1 -0
- package/dist/types/types/global.d.ts +1 -1
- package/dist/zonos-elements/index.esm.js +1 -0
- package/dist/zonos-elements/p-0878369a.entry.js +1 -0
- package/dist/zonos-elements/p-0d1c06d7.entry.js +1 -0
- package/dist/zonos-elements/{p-9aab3ad7.entry.js → p-0d5b5bcc.entry.js} +1 -1
- package/dist/zonos-elements/p-1491717a.entry.js +1 -0
- package/dist/zonos-elements/p-14ff42fe.system.entry.js +1 -0
- package/dist/zonos-elements/p-2800c274.system.entry.js +1 -0
- package/dist/zonos-elements/p-2e02a76f.system.entry.js +1 -0
- package/dist/zonos-elements/{p-020a9b86.entry.js → p-3ba8838a.entry.js} +1 -1
- package/dist/zonos-elements/p-4594a125.js +1 -0
- package/dist/zonos-elements/p-483e1724.entry.js +1 -0
- package/dist/zonos-elements/{p-d0bc8902.system.entry.js → p-4f72bfee.system.entry.js} +1 -1
- package/dist/zonos-elements/p-58be220f.system.js +1 -0
- package/dist/zonos-elements/{p-9e9c318b.entry.js → p-58fc8ec1.entry.js} +1 -1
- package/dist/zonos-elements/p-63db40b9.system.js +1 -0
- package/dist/zonos-elements/p-6449c92b.js +1 -0
- package/dist/zonos-elements/p-6746455b.system.entry.js +1 -0
- package/dist/zonos-elements/{p-c20e5430.entry.js → p-6cb9812b.entry.js} +1 -1
- package/dist/zonos-elements/p-7487ef47.entry.js +1 -0
- package/dist/zonos-elements/p-7b2d367b.entry.js +1 -0
- package/dist/zonos-elements/p-9389cc42.system.entry.js +1 -0
- package/dist/zonos-elements/p-9be6c62b.system.js +1 -0
- package/dist/zonos-elements/p-9c242e4b.system.entry.js +1 -0
- package/dist/zonos-elements/p-a37796e1.entry.js +1 -0
- package/dist/zonos-elements/p-afb89d65.entry.js +1 -0
- package/dist/zonos-elements/p-bbb84165.system.entry.js +1 -0
- package/dist/zonos-elements/{p-96b8c9ba.system.entry.js → p-bdfa3705.system.entry.js} +1 -1
- package/dist/zonos-elements/p-c195e980.system.entry.js +1 -0
- package/dist/zonos-elements/p-c87c76d4.entry.js +1 -0
- package/dist/zonos-elements/p-d9011df9.entry.js +1 -0
- package/dist/zonos-elements/{p-3e26d7b3.system.entry.js → p-dda78e8e.system.entry.js} +1 -1
- package/dist/zonos-elements/p-de9e610d.system.entry.js +1 -0
- package/dist/zonos-elements/p-e0bf9666.system.js +1 -1
- package/dist/zonos-elements/p-eaa335e1.js +1 -0
- package/dist/zonos-elements/{p-e13bfbda.system.entry.js → p-ed3524ae.system.entry.js} +1 -1
- package/dist/zonos-elements/p-f5b14bab.system.js +1 -0
- package/dist/zonos-elements/p-f9a42a3c.system.entry.js +1 -0
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +4 -2
- package/dist/components/ILanguage.js +0 -24
- package/dist/components/classes.js +0 -12
- package/dist/components/containsNonLatinChars.js +0 -21
- package/dist/components/formatCurrency.js +0 -11
- package/dist/components/getBorderRadius.js +0 -18
- package/dist/components/index.d.ts +0 -33
- package/dist/components/index.js +0 -1
- package/dist/components/isCheckoutMobile.js +0 -6
- package/dist/components/isColorVariable.js +0 -14
- package/dist/components/isDarkColor.js +0 -1199
- package/dist/components/stripe.js +0 -1691
- package/dist/components/submitGtag.js +0 -19
- package/dist/components/trackConversionEvent.js +0 -37
- package/dist/components/translationStore.js +0 -5611
- package/dist/components/zonos-address-display.d.ts +0 -11
- package/dist/components/zonos-address-display.js +0 -6
- package/dist/components/zonos-address-display2.js +0 -64
- package/dist/components/zonos-address-form.d.ts +0 -11
- package/dist/components/zonos-address-form.js +0 -6
- package/dist/components/zonos-address-form2.js +0 -84
- package/dist/components/zonos-address-update-dialog.d.ts +0 -11
- package/dist/components/zonos-address-update-dialog.js +0 -6
- package/dist/components/zonos-address-update-dialog2.js +0 -264
- package/dist/components/zonos-address.d.ts +0 -11
- package/dist/components/zonos-address.js +0 -6
- package/dist/components/zonos-address2.js +0 -176
- package/dist/components/zonos-badge.d.ts +0 -11
- package/dist/components/zonos-badge.js +0 -6
- package/dist/components/zonos-badge2.js +0 -61
- package/dist/components/zonos-banner.d.ts +0 -11
- package/dist/components/zonos-banner.js +0 -6
- package/dist/components/zonos-banner2.js +0 -95
- package/dist/components/zonos-button.d.ts +0 -11
- package/dist/components/zonos-button.js +0 -6
- package/dist/components/zonos-button2.js +0 -186
- package/dist/components/zonos-card.d.ts +0 -11
- package/dist/components/zonos-card.js +0 -6
- package/dist/components/zonos-card2.js +0 -57
- package/dist/components/zonos-cart-items.d.ts +0 -11
- package/dist/components/zonos-cart-items.js +0 -6
- package/dist/components/zonos-cart-items2.js +0 -57
- package/dist/components/zonos-cart-restricted-items.d.ts +0 -11
- package/dist/components/zonos-cart-restricted-items.js +0 -6
- package/dist/components/zonos-cart-restricted-items2.js +0 -135
- package/dist/components/zonos-cart-subtotal.d.ts +0 -11
- package/dist/components/zonos-cart-subtotal.js +0 -6
- package/dist/components/zonos-cart-subtotal2.js +0 -91
- package/dist/components/zonos-checkbox.d.ts +0 -11
- package/dist/components/zonos-checkbox.js +0 -6
- package/dist/components/zonos-checkbox2.js +0 -96
- package/dist/components/zonos-checkout-finish.d.ts +0 -11
- package/dist/components/zonos-checkout-finish.js +0 -6
- package/dist/components/zonos-checkout-finish2.js +0 -246
- package/dist/components/zonos-checkout-footer.d.ts +0 -11
- package/dist/components/zonos-checkout-footer.js +0 -6
- package/dist/components/zonos-checkout-footer2.js +0 -125
- package/dist/components/zonos-checkout-payment.d.ts +0 -11
- package/dist/components/zonos-checkout-payment.js +0 -6
- package/dist/components/zonos-checkout-payment2.js +0 -104
- package/dist/components/zonos-checkout-progress-tabs.d.ts +0 -11
- package/dist/components/zonos-checkout-progress-tabs.js +0 -6
- package/dist/components/zonos-checkout-progress-tabs2.js +0 -138
- package/dist/components/zonos-checkout.d.ts +0 -11
- package/dist/components/zonos-checkout.js +0 -1051
- package/dist/components/zonos-collapse.d.ts +0 -11
- package/dist/components/zonos-collapse.js +0 -6
- package/dist/components/zonos-collapse2.js +0 -78
- package/dist/components/zonos-component.d.ts +0 -11
- package/dist/components/zonos-component.js +0 -48
- package/dist/components/zonos-confirm-dialog.d.ts +0 -11
- package/dist/components/zonos-confirm-dialog.js +0 -6
- package/dist/components/zonos-confirm-dialog2.js +0 -161
- package/dist/components/zonos-controller.d.ts +0 -11
- package/dist/components/zonos-controller.js +0 -309
- package/dist/components/zonos-country-flag.d.ts +0 -11
- package/dist/components/zonos-country-flag.js +0 -6
- package/dist/components/zonos-country-flag2.js +0 -54
- package/dist/components/zonos-country-select.d.ts +0 -11
- package/dist/components/zonos-country-select.js +0 -6
- package/dist/components/zonos-country-select2.js +0 -1891
- package/dist/components/zonos-custom-message.d.ts +0 -11
- package/dist/components/zonos-custom-message.js +0 -6
- package/dist/components/zonos-custom-message2.js +0 -72
- package/dist/components/zonos-customer-info.d.ts +0 -11
- package/dist/components/zonos-customer-info.js +0 -6
- package/dist/components/zonos-customer-info2.js +0 -316
- package/dist/components/zonos-dialog.d.ts +0 -11
- package/dist/components/zonos-dialog.js +0 -6
- package/dist/components/zonos-dialog2.js +0 -136
- package/dist/components/zonos-hello-dialog-footer.d.ts +0 -11
- package/dist/components/zonos-hello-dialog-footer.js +0 -6
- package/dist/components/zonos-hello-dialog-footer2.js +0 -83
- package/dist/components/zonos-hello-dialog.d.ts +0 -11
- package/dist/components/zonos-hello-dialog.js +0 -6
- package/dist/components/zonos-hello-dialog2.js +0 -305
- package/dist/components/zonos-hello.d.ts +0 -11
- package/dist/components/zonos-hello.js +0 -879
- package/dist/components/zonos-icon.d.ts +0 -11
- package/dist/components/zonos-icon.js +0 -6
- package/dist/components/zonos-icon2.js +0 -55
- package/dist/components/zonos-input.d.ts +0 -11
- package/dist/components/zonos-input.js +0 -6
- package/dist/components/zonos-input2.js +0 -78
- package/dist/components/zonos-language-select.d.ts +0 -11
- package/dist/components/zonos-language-select.js +0 -6
- package/dist/components/zonos-language-select2.js +0 -88
- package/dist/components/zonos-link-authentication.d.ts +0 -11
- package/dist/components/zonos-link-authentication.js +0 -6
- package/dist/components/zonos-link-authentication2.js +0 -80
- package/dist/components/zonos-link.d.ts +0 -11
- package/dist/components/zonos-link.js +0 -43
- package/dist/components/zonos-logo.d.ts +0 -11
- package/dist/components/zonos-logo.js +0 -49
- package/dist/components/zonos-notification.d.ts +0 -11
- package/dist/components/zonos-notification.js +0 -6
- package/dist/components/zonos-notification2.js +0 -92
- package/dist/components/zonos-payment.d.ts +0 -11
- package/dist/components/zonos-payment.js +0 -6
- package/dist/components/zonos-payment2.js +0 -77
- package/dist/components/zonos-review.d.ts +0 -11
- package/dist/components/zonos-review.js +0 -6
- package/dist/components/zonos-review2.js +0 -89
- package/dist/components/zonos-select-dialog-header.d.ts +0 -11
- package/dist/components/zonos-select-dialog-header.js +0 -6
- package/dist/components/zonos-select-dialog-header2.js +0 -71
- package/dist/components/zonos-shipping-rich-radio.d.ts +0 -11
- package/dist/components/zonos-shipping-rich-radio.js +0 -6
- package/dist/components/zonos-shipping-rich-radio2.js +0 -88
- package/dist/components/zonos-shipping.d.ts +0 -11
- package/dist/components/zonos-shipping.js +0 -6
- package/dist/components/zonos-shipping2.js +0 -159
- package/dist/components/zonos-spinner.d.ts +0 -11
- package/dist/components/zonos-spinner.js +0 -6
- package/dist/components/zonos-spinner2.js +0 -43
- package/dist/components/zonos-text.d.ts +0 -11
- package/dist/components/zonos-text.js +0 -6
- package/dist/components/zonos-text2.js +0 -182
- package/dist/components/zonos-tooltip.d.ts +0 -11
- package/dist/components/zonos-tooltip.js +0 -6
- package/dist/components/zonos-tooltip2.js +0 -48
- package/dist/components/zonos-v-stack.d.ts +0 -11
- package/dist/components/zonos-v-stack.js +0 -6
- package/dist/components/zonos-v-stack2.js +0 -38
- package/dist/components/zonosStore.js +0 -2881
- package/dist/esm-es5/cart-cc593c2b.js +0 -1
- package/dist/esm-es5/submitGtag-e50f903f.js +0 -1
- package/dist/scripts/checkIfLoadVersionDomain.js +0 -1
- package/dist/scripts/extractZonosQaUrl.js +0 -1
- package/dist/scripts/getTempCartById.js +0 -1
- package/dist/scripts/loadStripe.js +0 -1
- package/dist/scripts/stripe.js +0 -1
- package/dist/scripts/zonosBase.js +0 -1
- package/dist/zonos-elements/p-04030a48.entry.js +0 -1
- package/dist/zonos-elements/p-0e892292.entry.js +0 -1
- package/dist/zonos-elements/p-0fac99e7.entry.js +0 -1
- package/dist/zonos-elements/p-1795c760.system.entry.js +0 -1
- package/dist/zonos-elements/p-24ac1c6f.entry.js +0 -1
- package/dist/zonos-elements/p-26a60a6e.entry.js +0 -1
- package/dist/zonos-elements/p-32744531.entry.js +0 -1
- package/dist/zonos-elements/p-35ac375a.system.entry.js +0 -1
- package/dist/zonos-elements/p-3bc88c3c.system.entry.js +0 -1
- package/dist/zonos-elements/p-4caaaaeb.system.entry.js +0 -1
- package/dist/zonos-elements/p-50ea2036.system.js +0 -1
- package/dist/zonos-elements/p-5e783394.entry.js +0 -1
- package/dist/zonos-elements/p-6366e7e3.entry.js +0 -1
- package/dist/zonos-elements/p-7c8ee4b9.system.entry.js +0 -1
- package/dist/zonos-elements/p-80ea85b8.entry.js +0 -1
- package/dist/zonos-elements/p-8da16d53.system.js +0 -1
- package/dist/zonos-elements/p-98a0b694.system.entry.js +0 -1
- package/dist/zonos-elements/p-b98cdf39.system.entry.js +0 -1
- package/dist/zonos-elements/p-d7b8c1c1.system.entry.js +0 -1
- package/dist/zonos-elements/p-dd0fd351.entry.js +0 -1
- package/dist/zonos-elements/p-e015cb0e.js +0 -1
- package/dist/zonos-elements/p-e1fbd05d.system.entry.js +0 -1
- package/dist/zonos-elements/p-e553dd19.js +0 -1
- package/dist/zonos-elements/p-e6fa0ebc.system.js +0 -1
- package/dist/zonos-elements/p-f6546bf4.system.entry.js +0 -1
- /package/dist/collection/components/common/{component-template/zonos-link → zonos-link}/zonos-link.css +0 -0
- /package/dist/collection/scripts/{checkIfLoadVersionDomain.js → _checkIfLoadVersionDomain.js} +0 -0
- /package/dist/collection/scripts/{stripe.js → _stripe.js} +0 -0
- /package/dist/types/components/common/{component-template/zonos-link → zonos-link}/zonos-link.d.ts +0 -0
- /package/dist/types/scripts/{checkIfLoadVersionDomain.d.ts → _checkIfLoadVersionDomain.d.ts} +0 -0
- /package/dist/types/scripts/{stripe.d.ts → _stripe.d.ts} +0 -0
package/dist/esm/loader.js
CHANGED
|
@@ -5,7 +5,7 @@ import { g as globalScripts } from './app-globals-0f993ce5.js';
|
|
|
5
5
|
const defineCustomElements = async (win, options) => {
|
|
6
6
|
if (typeof window === 'undefined') return undefined;
|
|
7
7
|
await globalScripts();
|
|
8
|
-
return bootstrapLazy([["zonos-checkout",[[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",[[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",[[1,"zonos-controller",{"config":[16],"zonosApiKey":[1,"zonos-api-key"],"initCheckoutElement":[64],"setupGoogleFont":[64],"showNotification":[64],"overrideConfig":[64],"overrideCountry":[64],"getAppearanceSetting":[64],"updateOrganizationName":[64]}]]],["zonos-component",[[1,"zonos-component",{"first":[1],"middle":[1],"last":[1]}]]],["zonos-link",[[1,"zonos-link",{"href":[1],"rel":[1],"target":[1],"linkTitle":[1,"link-title"]}]]],["zonos-logo",[[1,"zonos-logo",{"theme":[1],"width":[1]}]]],["zonos-text",[[1,"zonos-text",{"textColor":[1,"text-color"],"size":[1],"type":[1],"weight":[2],"content":[1],"ready":[32]}]]],["zonos-hello-dialog",[[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",[[1,"zonos-notification",{"notificationArray":[32],"showNotification":[64]}]]],["zonos-payment",[[2,"zonos-payment",{"titleText":[1,"title-text"],"stripe":[32],"stripeElements":[32]},null,{"stripeElements":["watchInitStripe"],"stripe":["watchInitStripe"]}]]],["zonos-shipping-rich-radio",[[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",[[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",[[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",[[1,"zonos-banner",{"bannerTitle":[1,"banner-title"],"intent":[1],"hasContent":[32]}]]],["zonos-button_3",[[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",[[1,"zonos-select-dialog-header",{"handleOnClose":[16],"label":[1]}],[1,"zonos-v-stack",{"spacing":[2]}]]],["zonos-card_2",[[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",[[1,"zonos-country-flag",{"countryCode":[1,"country-code"],"size":[2]}]]],["zonos-country-select_3",[[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",[[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",[[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);
|
|
8
|
+
return bootstrapLazy([["zonos-checkout",[[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",[[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",[[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",[[1,"zonos-component",{"first":[1],"middle":[1],"last":[1]}]]],["zonos-link",[[1,"zonos-link",{"href":[1],"rel":[1],"target":[1],"linkTitle":[1,"link-title"]}]]],["zonos-logo",[[1,"zonos-logo",{"theme":[1],"width":[1]}]]],["zonos-text",[[1,"zonos-text",{"textColor":[1,"text-color"],"size":[1],"type":[1],"weight":[2],"content":[1],"ready":[32]}]]],["zonos-hello-dialog",[[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",[[1,"zonos-notification",{"notificationArray":[32],"showNotification":[64]}]]],["zonos-payment",[[2,"zonos-payment",{"titleText":[1,"title-text"],"stripe":[32],"stripeElements":[32]},null,{"stripeElements":["watchInitStripe"],"stripe":["watchInitStripe"]}]]],["zonos-shipping-rich-radio",[[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",[[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",[[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",[[1,"zonos-banner",{"bannerTitle":[1,"banner-title"],"intent":[1],"hasContent":[32]}]]],["zonos-button_3",[[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",[[1,"zonos-select-dialog-header",{"handleOnClose":[16],"label":[1]}],[1,"zonos-v-stack",{"spacing":[2]}]]],["zonos-card_2",[[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",[[1,"zonos-country-flag",{"countryCode":[1,"country-code"],"size":[2]}]]],["zonos-country-select_3",[[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",[[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",[[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);
|
|
9
9
|
};
|
|
10
10
|
|
|
11
11
|
export { defineCustomElements };
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
const log = (message, type, ...additionalInfo) => {
|
|
2
|
+
var _a, _b;
|
|
3
|
+
const isDebug = !!((_a = window.Zonos) === null || _a === void 0 ? void 0 : _a.debug) ||
|
|
4
|
+
!!window.location.search.match(/\?.*(&*)zonosDebug=1/);
|
|
5
|
+
// if debug is false, do not log
|
|
6
|
+
if (!isDebug) {
|
|
7
|
+
// log errors to the console if the type is error
|
|
8
|
+
if (type === 'error') {
|
|
9
|
+
// eslint-disable-next-line no-console
|
|
10
|
+
console.error(message, ...additionalInfo);
|
|
11
|
+
}
|
|
12
|
+
return;
|
|
13
|
+
}
|
|
14
|
+
let loggingIframe = document.querySelector('iframe#zonos---debug-logging-iframe');
|
|
15
|
+
if (!loggingIframe) {
|
|
16
|
+
// add a hidden iframe
|
|
17
|
+
loggingIframe = document.createElement('iframe');
|
|
18
|
+
loggingIframe.id = 'zonos---debug-logging-iframe';
|
|
19
|
+
loggingIframe.style.display = 'none';
|
|
20
|
+
loggingIframe.style.opacity = '0';
|
|
21
|
+
loggingIframe.style.position = 'absolute';
|
|
22
|
+
loggingIframe.style.top = '-9999px';
|
|
23
|
+
loggingIframe.style.left = '-9999px';
|
|
24
|
+
loggingIframe.style.width = '1px';
|
|
25
|
+
loggingIframe.style.height = '1px';
|
|
26
|
+
loggingIframe.style.border = 'none';
|
|
27
|
+
loggingIframe.style.overflow = 'hidden';
|
|
28
|
+
loggingIframe.style.visibility = 'hidden';
|
|
29
|
+
document.body.appendChild(loggingIframe);
|
|
30
|
+
}
|
|
31
|
+
// use the logging iframe's console to log just in case the console is disabled (overriden) by the site owner
|
|
32
|
+
const zConsole = ((_b = loggingIframe.contentWindow) === null || _b === void 0 ? void 0 : _b.window.console) || window.console;
|
|
33
|
+
switch (type) {
|
|
34
|
+
case 'warn':
|
|
35
|
+
zConsole.warn(message, ...additionalInfo);
|
|
36
|
+
break;
|
|
37
|
+
case 'info':
|
|
38
|
+
zConsole.info(message, ...additionalInfo);
|
|
39
|
+
break;
|
|
40
|
+
case 'error':
|
|
41
|
+
zConsole.error(message, ...additionalInfo);
|
|
42
|
+
break;
|
|
43
|
+
default:
|
|
44
|
+
zConsole.groupCollapsed(message, ...additionalInfo);
|
|
45
|
+
zConsole.trace();
|
|
46
|
+
zConsole.groupEnd();
|
|
47
|
+
break;
|
|
48
|
+
}
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
const logError = (message, ...rest) => {
|
|
52
|
+
log(message, 'error', ...rest);
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
export { logError as a, log as l };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { r as handleFetch, d as cartStore, l as localizationStore } from './cart-1a37e002.js';
|
|
2
2
|
import { z as zonosStore } from './zonosStore-32e33a45.js';
|
|
3
|
+
import { l as log } from './logError-c456c092.js';
|
|
3
4
|
|
|
4
5
|
const trackConversionEvent = async (eventName, metadata) => {
|
|
5
6
|
var _a, _b;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host, d as getElement } from './index-3b46f3c3.js';
|
|
2
|
-
import {
|
|
2
|
+
import { h as stripeStore, l as localizationStore, t as translate } from './cart-1a37e002.js';
|
|
3
3
|
import { i as isCheckoutMobile } from './isCheckoutMobile-8846dccb.js';
|
|
4
|
+
import { a as logError } from './logError-c456c092.js';
|
|
4
5
|
import { i as isTextContainsNonLatinChars, c as containsNonLatinChars } from './containsNonLatinChars-2d8810c3.js';
|
|
5
6
|
import { z as zonosStore, d as zonosStoreFontFamily } from './zonosStore-32e33a45.js';
|
|
6
7
|
import { c as classes } from './classes-0d95c529.js';
|
|
@@ -142,7 +143,7 @@ const ZonosAddress = class {
|
|
|
142
143
|
}
|
|
143
144
|
render() {
|
|
144
145
|
// this component loads iframe from the stripe elements and puts here, so we don't need to do anything here
|
|
145
|
-
return (h(Host, { key: '
|
|
146
|
+
return (h(Host, { key: '9ef595622320579d43ac54bdfdf0e8a24ab5132b', class: "zonos--address zonos--elements" }, h("zonos-text", { key: '82925c3c426f384a266cfe62c2899d1ec30d0920', class: "zonos--title", type: "semiBoldLabel" }, this.titleText), h("div", { key: 'bb3b99783a75434a5a7cc6856ccf9218f1cfd212', class: "zonos--address-component" })));
|
|
146
147
|
}
|
|
147
148
|
get el() { return getElement(this); }
|
|
148
149
|
static get watchers() { return {
|
|
@@ -441,14 +442,14 @@ const ZonosCheckbox = class {
|
|
|
441
442
|
customRoundRadius: '4px',
|
|
442
443
|
overrideBorderStyle: this.borderStyle,
|
|
443
444
|
});
|
|
444
|
-
return (h(Host, { key: '
|
|
445
|
+
return (h(Host, { key: '8a1adb8ba23d34a7730e5b5a81bc6b5ada58cb83', class: classes(['zonos--elements zonos--checkbox']), style: {
|
|
445
446
|
'--background-color': backgroundColor,
|
|
446
447
|
'--border-radius': borderStyle,
|
|
447
448
|
'--font-family': zonosStoreFontFamily(),
|
|
448
449
|
'--size': `${this.size}px`,
|
|
449
|
-
} }, h("label", { key: '
|
|
450
|
+
} }, h("label", { key: 'e954bcef9e021bfbb98031f030542a89d8faf0f3', class: classes([this.isDisabled && 'disabled']) }, h("input", { key: '17788f6c205a139dde1b42cc91579d0975233e77', checked: this.isChecked, disabled: this.isDisabled, hidden: true, onChange: e => {
|
|
450
451
|
this.checkboxSelected.emit(e.target.checked);
|
|
451
|
-
}, type: "checkbox" }), h("span", { key: '
|
|
452
|
+
}, type: "checkbox" }), h("span", { key: '589486a19b7b0b42ce8eabd2230a8b4620ca3216', class: "checkmark-container" }, h("svg", { key: 'd56ce06c20e0c3460b6222d323d0a17059147157', class: "checkmark", color: checkmarkColor, fill: "none", viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, h("path", { key: '5e6af8d520bcb7c3b0fe2891ce0c2e783976b501', "clip-rule": "evenodd", d: "M17.456 7.404a.75.75 0 0 1 .14 1.052l-6.5 8.5a.75.75 0 0 1-1.126.074l-4-4a.75.75 0 0 1 1.06-1.06l3.395 3.394 5.98-7.82a.75.75 0 0 1 1.05-.14Z", fill: "currentColor", "fill-rule": "evenodd" }))), this.label && (h("zonos-text", { key: '18c5a586756ddc0808c05f305c89dbb07f1b7d16', size: this.fontSize }, this.label)))));
|
|
452
453
|
}
|
|
453
454
|
};
|
|
454
455
|
ZonosCheckbox.style = ZonosCheckboxStyle0;
|
|
@@ -498,10 +499,10 @@ const ZonosCollapse = class {
|
|
|
498
499
|
// set overflow to hidden to prevent content from showing when collapsed
|
|
499
500
|
this.el.style.overflow = 'hidden';
|
|
500
501
|
}
|
|
501
|
-
return (h(Host, { key: '
|
|
502
|
+
return (h(Host, { key: 'c268257dcef8e8def5e34bf5b3ea432136c06d6a', class: 'zonos--elements zonos--collapse', style: {
|
|
502
503
|
'--font-family': zonosStoreFontFamily(),
|
|
503
504
|
height: this.getElementHeight(),
|
|
504
|
-
} }, h("div", { key: '
|
|
505
|
+
} }, h("div", { key: 'ea4abe6a03ffed6f4fd1248e668d123c1a8cef77' }, h("iframe", { key: 'dc010404892272fece7a913149e75171bb6e786c', class: "height-change-listener", tabindex: "-1", title: "collapse-height-change-listener" }), h("slot", { key: 'c9dc7dd83363211d249ee417111f3a36057f0af0' }))));
|
|
505
506
|
}
|
|
506
507
|
get el() { return getElement(this); }
|
|
507
508
|
};
|
|
@@ -568,7 +569,7 @@ const ZonosDialog = class {
|
|
|
568
569
|
const borderStyle = getBorderRadius({
|
|
569
570
|
overrideBorderStyle: this.borderStyle,
|
|
570
571
|
});
|
|
571
|
-
return (h(Host, { key: '
|
|
572
|
+
return (h(Host, { key: 'fe812c0c5a81b0b09ad6e0b554d036711e12c0ed', class: classes([
|
|
572
573
|
'zonos--elements',
|
|
573
574
|
this.open && 'open',
|
|
574
575
|
this.isLoading && 'is-loading',
|
|
@@ -580,10 +581,10 @@ const ZonosDialog = class {
|
|
|
580
581
|
'--height': this.height || 'initial',
|
|
581
582
|
'--min-height': this.minHeight || '500px',
|
|
582
583
|
'--width': this.width,
|
|
583
|
-
} }, h("div", { key: '
|
|
584
|
+
} }, h("div", { key: 'aaa10008c2eecf00efc29124448d2cbc8567f440', class: "zonos--backdrop" }), h("div", { key: 'b45a8f56ed413a7cb935d84b342d2ac50812ba6b', "aria-hidden": "true", class: "zonos--dialog-layout", onClick: this.clickOutsideDialogHandler }, h("div", { key: '80d2312742cfa766e171f1e3d79aba9df26bcba5', class: "zonos--dialog" }, this.isLoading && (h("div", { key: 'f35bfdd001b0687d683b7d416c812035bd1bcb10', class: "zonos--loading" }, h("zonos-spinner", { key: 'df7e9af43340ce3e1ca66126c0d68a6950cad9e7', size: 30 }))), (this.headerText || !this.noCloseButton) && (h("div", { key: '8248f4104881ee8c3d3202b1bbc07f7b969d86f5', class: "zonos--header" }, this.headerText && (h("h3", { key: '88620497b42f82f122b8e1c675490e566da27af6', class: "zonos--header-text" }, this.headerText)), !this.noCloseButton && (h("zonos-button", { key: '9b17424799dbb772b51a87f246285642ec621f0b', class: "zonos--close-button", icon: h("zonos-icon", { "aria-label": "Close dialog", content: RemoveIcon }), noBackground: true, onClick: this.closeButtonHandler, variant: "subtle" })))), h("div", { key: '904ba64d8c82826baffed469f5b09ef7189c4aff', class: classes([
|
|
584
585
|
'zonos--body',
|
|
585
586
|
this.noBodyPadding && 'zonos--no-body-padding',
|
|
586
|
-
]) }, h("slot", { key: '
|
|
587
|
+
]) }, h("slot", { key: '24f85c3c84100217db0866a10d6f3443b64c39d2' })), h("slot", { key: 'aabf202487d080a8277aeb641b602cf507a39061', name: "dialog-footer" })))));
|
|
587
588
|
}
|
|
588
589
|
static get assetsDirs() { return ["assets"]; }
|
|
589
590
|
};
|
|
@@ -16,16 +16,16 @@ const ZonosBadge = class {
|
|
|
16
16
|
this.rounded = false;
|
|
17
17
|
}
|
|
18
18
|
render() {
|
|
19
|
-
return (h(Host, { key: '
|
|
19
|
+
return (h(Host, { key: '6abf1f29bb6368710b45414baca9643421de2643', class: classes(['zonos--elements zonos--badge']), style: {
|
|
20
20
|
'--font-family': zonosStoreFontFamily(),
|
|
21
|
-
} }, h("div", { key: '
|
|
21
|
+
} }, h("div", { key: 'fb0b246a59f0350313673d4430ac4f2bcd9d6b80', class: classes([
|
|
22
22
|
'zonos--badge-content',
|
|
23
23
|
this.badgeColor,
|
|
24
24
|
this.rounded && 'rounded',
|
|
25
25
|
this.iconRight && 'icon-right',
|
|
26
26
|
this.size,
|
|
27
27
|
this.bold && 'bold',
|
|
28
|
-
]) }, this.icon, h("zonos-text", { key: '
|
|
28
|
+
]) }, this.icon, h("zonos-text", { key: '2d6024af48ce0e082d3a1332794978cfd42793d6' }, h("slot", { key: '9cb7e771b0a949b912c6fa5946018cbf072ed018' })))));
|
|
29
29
|
}
|
|
30
30
|
};
|
|
31
31
|
ZonosBadge.style = ZonosBadgeStyle0;
|
|
@@ -114,12 +114,12 @@ const ZonosButton = class {
|
|
|
114
114
|
const spinnerColor = backgroundActualColor && isDarkColor(backgroundActualColor)
|
|
115
115
|
? 'white'
|
|
116
116
|
: 'black';
|
|
117
|
-
return (h(Host, { key: '
|
|
117
|
+
return (h(Host, { key: '00d085d600a759366f4a2de8617d81831c0ce16b', class: classes(['zonos--elements']), "data-theme": this.theme || buttonTheme, disabled: disabled, style: styles({
|
|
118
118
|
'--background-color': overrideBackground,
|
|
119
119
|
'--border-radius': borderStyle,
|
|
120
120
|
'--color': contrastColor,
|
|
121
121
|
'--font-family': zonosStoreFontFamily(),
|
|
122
|
-
}) }, h("button", { key: '
|
|
122
|
+
}) }, h("button", { key: 'b79ffdb0212630598e95f07059bb3b41049cff47', class: classes([
|
|
123
123
|
this.hasIcon && 'has-icon',
|
|
124
124
|
this.hasContent && 'has-content',
|
|
125
125
|
this.noBackground && 'no-background',
|
|
@@ -133,7 +133,7 @@ const ZonosButton = class {
|
|
|
133
133
|
overrideBackground &&
|
|
134
134
|
variant === 'standard' &&
|
|
135
135
|
'override-background',
|
|
136
|
-
]), disabled: disabled }, this.loading && (h("div", { key: '
|
|
136
|
+
]), disabled: disabled }, this.loading && (h("div", { key: '4462430185736b45b11bd18f08d1e3c6177f192f', class: "zonos--spinner-wrapper" }, h("zonos-spinner", { key: 'c866ff989b95929e8d6a44d950dc943531f1dc0c', size: 16, spinnerColor: spinnerColor }))), !this.loading && !this.iconRight && this.icon, h("slot", { key: 'a57d0b3924eef51bf3938261c8d823e9d8aa0206', onSlotchange: this.handleSlotChange }), !this.loading && this.iconRight && this.icon)));
|
|
137
137
|
}
|
|
138
138
|
static get delegatesFocus() { return true; }
|
|
139
139
|
get ele() { return getElement(this); }
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host } from './index-3b46f3c3.js';
|
|
2
2
|
import { d as zonosStoreFontFamily } from './zonosStore-32e33a45.js';
|
|
3
3
|
import { c as classes } from './classes-0d95c529.js';
|
|
4
|
-
import {
|
|
4
|
+
import { H as localizationStoreUpdateSelectedLocale, t as translate, l as localizationStore } from './cart-1a37e002.js';
|
|
5
5
|
import { l as languages } from './ILanguage-97790bee.js';
|
|
6
|
+
import './logError-c456c092.js';
|
|
6
7
|
import './isDarkColor-39a36e82.js';
|
|
7
8
|
import './getBorderRadius-d244b4b1.js';
|
|
8
9
|
|
|
@@ -20,12 +21,12 @@ const ZonosCard = class {
|
|
|
20
21
|
this.spacing = '24px';
|
|
21
22
|
}
|
|
22
23
|
render() {
|
|
23
|
-
return (h(Host, { key: '
|
|
24
|
+
return (h(Host, { key: '0e52ca31db6c2f956da1910d6e0a222b588c1bcc', style: {
|
|
24
25
|
'--font-family': zonosStoreFontFamily(),
|
|
25
|
-
} }, h("div", { key: '
|
|
26
|
+
} }, h("div", { key: '69f391d821f88cbee4b0c586a8323b1dd68d7fd3', class: classes(['styled-card']), style: { padding: this.spacing } }, this.label && (h("header", { key: '4568a1d7c354830e6e65e31b20b38140aaab9d01', class: "card-header", style: { padding: this.spacing } }, h("zonos-text", { key: 'e0a6b7a3776916f8208c27373878041807d91960', type: "subheader" }, this.label), h("h-stack", { key: 'c5f8d01b2f477b16ab9387081987eae64b156e76', spacing: 8 }, this.actions))), h("slot", { key: '6001acfaae8ba37456a7c23bae5c44a91da074f9' }), (this.footerActions || this.footerContent) && (h("footer", { key: '78b926a323a5f1375c8120d5aa8b1ab2a4f3fa4a', class: "card-footer", style: {
|
|
26
27
|
height: this.footerHeight ? `${this.footerHeight}px` : 'auto',
|
|
27
28
|
padding: this.spacing,
|
|
28
|
-
} }, h("div", { key: '
|
|
29
|
+
} }, h("div", { key: '2bd0c86b75096c2ee786d4a9b16a3d6e385fbbf1' }, this.footerContent), h("h-stack", { key: '7a3f840ac9678a905338a99b8327115bc8199789', spacing: 8 }, this.footerActions))))));
|
|
29
30
|
}
|
|
30
31
|
};
|
|
31
32
|
ZonosCard.style = ZonosCardStyle0;
|
|
@@ -51,9 +52,9 @@ const ZonosLanguageSelect = class {
|
|
|
51
52
|
}
|
|
52
53
|
render() {
|
|
53
54
|
const { selectedLocale } = localizationStore;
|
|
54
|
-
return (h(Host, { key: '
|
|
55
|
+
return (h(Host, { key: '34580123b768ce983c0c9c6fa309bdb1d6756a5a', class: "zonos--elements", style: {
|
|
55
56
|
'--font-family': zonosStoreFontFamily(),
|
|
56
|
-
} }, h("div", { key: '
|
|
57
|
+
} }, h("div", { key: '6e86352a45b5d9ad0e5ed5dac330367a49a6c6fe', class: "zonos--language-select" }, h("zonos-select-dialog-header", { key: 'd5b55cbb2858a2c0a6aa6ce0ea0d50eecc7360e8', handleOnClose: () => this.handleOnClose(), label: translate('Select a language') }), h("div", { key: 'c9aeb075428357c4cb15d9a2b09df7c8d6b01b11', class: "zonos--language-select-content" }, languages.map(language => (h("button", { class: "zonos--language-select-button", onClick: () => this.languageSelected(language.code) }, h("zonos-text", { textColor: "gray-800" }, language.translatedLabel), language.code === selectedLocale && (h("zonos-icon", { content: GreenCheckDuotoneIcon, size: 16 })))))))));
|
|
57
58
|
}
|
|
58
59
|
};
|
|
59
60
|
ZonosLanguageSelect.style = ZonosLanguageSelectStyle0;
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { r as registerInstance, a as getAssetPath, h, H as Host, F as Fragment, c as createEvent, d as getElement } from './index-3b46f3c3.js';
|
|
2
|
-
import {
|
|
2
|
+
import { d as cartStore, C as cartStoreHasOneEligibleItem, t as translate, r as handleFetch, p as stripeStoreReset, h as stripeStore, D as stripeStoreRetrievePayment, l as localizationStore, E as stripeStoreTranslateAddressToLatin, F as cartStoreUpdateSelectedShippingOption, G as cartStoreGetShippingTransitInfo } from './cart-1a37e002.js';
|
|
3
3
|
import { c as classes } from './classes-0d95c529.js';
|
|
4
4
|
import { z as zonosStore, g as getZonosStoreTheme, d as zonosStoreFontFamily } from './zonosStore-32e33a45.js';
|
|
5
|
-
import { t as trackConversionEvent, s as sendErrorLog, a as submitGtag, c as createCustomEvent } from './submitGtag-
|
|
5
|
+
import { t as trackConversionEvent, s as sendErrorLog, a as submitGtag, c as createCustomEvent } from './submitGtag-754935b4.js';
|
|
6
6
|
import { g as getBorderRadius } from './getBorderRadius-d244b4b1.js';
|
|
7
7
|
import { i as isCheckoutMobile } from './isCheckoutMobile-8846dccb.js';
|
|
8
8
|
import { l as languages } from './ILanguage-97790bee.js';
|
|
9
9
|
import { t as tinycolor, i as isDarkColor } from './isDarkColor-39a36e82.js';
|
|
10
10
|
import { i as isColorVariable } from './isColorVariable-82457bef.js';
|
|
11
11
|
import { c as containsNonLatinChars } from './containsNonLatinChars-2d8810c3.js';
|
|
12
|
+
import './logError-c456c092.js';
|
|
12
13
|
|
|
13
14
|
const formatCurrency = ({ amount, currency, showCurrencyText, }) => showCurrencyText
|
|
14
15
|
? `${new Intl.NumberFormat('en-US', {
|
|
@@ -330,11 +331,11 @@ const ZonosCheckoutFinish = class {
|
|
|
330
331
|
// const totalItems = this.order?.items?.reduce((acc, item) => {
|
|
331
332
|
// return acc + item.quantity;
|
|
332
333
|
// }, 0);
|
|
333
|
-
return (h(Host, { key: '
|
|
334
|
+
return (h(Host, { key: '1e4627e936e0508761c12d842523adb51d3c797e', class: "zonos--checkout-finish zonos--elements", style: {
|
|
334
335
|
'--border-radius': getBorderRadius({
|
|
335
336
|
overrideBorderStyle: this.borderRadius,
|
|
336
337
|
}),
|
|
337
|
-
} }, this.isLoading && (h("div", { key: '
|
|
338
|
+
} }, this.isLoading && (h("div", { key: '4d3be87aec252946c5b6fb516c882830232a83e5', class: "loading-wrapper" }, h("zonos-spinner", { key: '25e9bafaaebed75582efd936c57121921c8f2f8a' }))), !this.isLoading && (h(Fragment, null, h("div", { key: '49c211db17af433b3936e69722c3c76c9197c170', class: "zonos--group" }, this.notificationType === 'success' ? (h("zonos-icon", { "aria-label": "Order success", content: SuccessIcon, iconColor: 'blue-800', size: 50 })) : (h("zonos-icon", { "aria-label": "Order failed", content: RemoveIcon, iconColor: 'red-800', size: 50 })), h("zonos-text", { key: '4cb90069dcf385886cb9235ee0854d63781e4452', class: "zonos--title", type: "semiBoldSubheader" }, this.notificationTitle), h("zonos-text", { key: '8e16be3b15d7fba7b697ba9ed41332c9794f3551' }, this.notificationMessages.map(message => (h(Fragment, null, message, h("br", null))))), h("zonos-button", { key: 'e1bfacd92d36c303defc464c7eaf10b8853175c1', onClick: () => this.closeClickHandler(), size: "md", variant: "primary" }, translate('Keep shopping')))))));
|
|
338
339
|
}
|
|
339
340
|
static get assetsDirs() { return ["assets"]; }
|
|
340
341
|
};
|
|
@@ -521,17 +522,17 @@ const ZonosCheckoutProgressTabs = class {
|
|
|
521
522
|
color: labelSelectedColor,
|
|
522
523
|
})
|
|
523
524
|
: labelSelectedColor;
|
|
524
|
-
return (h(Host, { key: '
|
|
525
|
+
return (h(Host, { key: '1c51be111b22f45ad33d430dc4d0a250f8e4d911', class: "zonos--elements", style: {
|
|
525
526
|
'--color': contrastLabelColor,
|
|
526
527
|
'--progress-percent': this.getTotalSuccessStep(),
|
|
527
|
-
} }, h("div", { key: '
|
|
528
|
+
} }, h("div", { key: '01e24d42123318aa23982e742b5f2053f5b5392d', class: "zonos--tab-wrapper" }, Object.values(cartStore.tabItems).map((tab, index) => {
|
|
528
529
|
const isSelected = tab.value === selectedStep;
|
|
529
530
|
return (h("button", { class: classes([
|
|
530
531
|
'zonos--tab-item',
|
|
531
532
|
tab.value === selectedStep && 'selected',
|
|
532
533
|
tab.isDone && 'done',
|
|
533
534
|
]), disabled: !this.isTabClickable(tab.value), key: tab.value, onClick: () => (cartStore.step = tab.value) }, h("div", { class: "zonos--tab-index" }, h("zonos-text", { class: "zonos--tab-index-label", textColor: isSelected ? contrastLabelColor : 'gray-1200', type: "label" }, index + 1), h("zonos-icon", { class: "zonos--tab-index-done-icon", content: TabCheckmark, iconColor: isSelected ? contrastLabelColor : 'gray-1200' })), h("zonos-text", { textColor: isSelected ? contrastLabelColor : 'gray-1200', type: "label" }, translate(tab.label))));
|
|
534
|
-
})), h("div", { key: '
|
|
535
|
+
})), h("div", { key: '55832cb123f7efa019ccddfe6bd82938d9f02206', class: "zonos--tab-progress" }, h("div", { key: '15fd9749c64530f09854a297cbc35fe97d3398e3', class: "zonos--progress-bar-fill" }))));
|
|
535
536
|
}
|
|
536
537
|
static get assetsDirs() { return ["assets"]; }
|
|
537
538
|
get ele() { return getElement(this); }
|
|
@@ -631,12 +632,12 @@ const ZonosConfirmDialog = class {
|
|
|
631
632
|
const borderStyle = getBorderRadius();
|
|
632
633
|
// Get theme for the update dialog, inherit from the theme, no from this component theme
|
|
633
634
|
const theme = getZonosStoreTheme(zonosStore.appearance.theme);
|
|
634
|
-
return (h(Host, { key: '
|
|
635
|
+
return (h(Host, { key: 'e52030ffc052c699daa87c5b62ee8b44ddad7f7f', class: classes([this.dialogOpen && 'open', 'zonos--elements']), "data-theme": theme, style: {
|
|
635
636
|
'--border-radius': borderStyle,
|
|
636
637
|
'--font-family': zonosStoreFontFamily(),
|
|
637
|
-
} }, h("div", { key: '
|
|
638
|
+
} }, h("div", { key: 'a34d31946f198b2593f142b582aec18f69fe74c5', class: "zonos--backdrop", tabIndex: -1 }), h("div", { key: '2f3dfa27dfbfbc4080eb710dd3db530521b63d36', "aria-hidden": "true", class: classes(['zonos--confirm-layout', this.dialogIntent]), onClick: e => this.clickOutsideDialogHandler(e) }, h("div", { key: '8f61424a8899c81f9510deda0adc3ff3e2da102b', class: "zonos--confirm-dialog", onBlur: () => {
|
|
638
639
|
this.focusDialog();
|
|
639
|
-
} }, h("div", { key: '
|
|
640
|
+
} }, h("div", { key: '2fca3f071d7f9d2af628d909770bb12a3acabfe2', class: "wrapper" }, h("div", { key: 'fed312e492a9fcac175a9cac7501255aeb975c10', class: "icon-wrapper" }, this.renderIcon()), h("div", { key: '131651e201a8d6b2ee9e0c82bd1990bc9a8dc702', class: "content" }, h("div", { key: 'a42e1a9271bdfb9fba133e9af330bdb8b16be230', class: "title" }, h("zonos-text", { key: '91461b9e572e3eb0e6e8616612cce56cf723678f', type: "subheader" }, this.dialogTitle)), this.dialogSubtitle && (h("div", { key: 'fde989f7ef37692173c1476b5cfd98f6cc71bb6e', class: "subtitle" }, h("zonos-text", { key: '2e273099ff036b1aa62bba923fff696d1d291867', textColor: "gray-800" }, this.dialogSubtitle)))), h("div", { key: '3b7f50adf490388feb759f2e09a626ece5f29c20', class: "footer" }, h("zonos-button", { key: '9686f10d831470273543cf3b5217a8e59bb5160a', backgroundColor: "gray-0", class: "cancel-button", onClick: () => this.closeDialogHandler(), size: "lg", withBoxShadow: true }, this.dialogCancelBtnText), h("zonos-button", { key: '3781a86d62efe11e8dc08886e3b4ad885c64776a', class: "confirm-button", onClick: () => this.confirmDialogHandler(), size: "lg", variant: this.getButtonConfirmVariant() }, this.dialogConfirmBtnText)))))));
|
|
640
641
|
}
|
|
641
642
|
static get assetsDirs() { return ["assets"]; }
|
|
642
643
|
get el() { return getElement(this); }
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { r as registerInstance, h, F as Fragment, H as Host } from './index-3b46f3c3.js';
|
|
2
|
-
import { l as localizationStore,
|
|
2
|
+
import { l as localizationStore, s as stripeStoreGetDomesticShippingSession, a as localizationStoreUpdateSelectedCountryCode, b as stripeStoreCleanupDomesticShippingSession, c as stripeStoreSaveDomesticShippingSession, i as initStripeElements, d as cartStore, e as cartStoreUpdateItems, f as cartStoreReset, g as cartStoreResetTabItems, h as stripeStore, j as stripeStoreInitCheckoutSession, k as cartStoreUpdateToErrorState, t as translate, m as stripeStorePrefetchLandedCost, n as cartStoreNextStep, o as stripeStoreConfirmPayment, p as stripeStoreReset, q as localizationStoreOnUpdate } from './cart-1a37e002.js';
|
|
3
3
|
import { z as zonosStore, g as getZonosStoreTheme, m as mergeConfig } from './zonosStore-32e33a45.js';
|
|
4
|
-
import { c as createCustomEvent, s as sendErrorLog, a as submitGtag, t as trackConversionEvent } from './submitGtag-
|
|
4
|
+
import { c as createCustomEvent, s as sendErrorLog, a as submitGtag, t as trackConversionEvent } from './submitGtag-754935b4.js';
|
|
5
5
|
import { i as isCheckoutMobile } from './isCheckoutMobile-8846dccb.js';
|
|
6
|
+
import { l as log, a as logError } from './logError-c456c092.js';
|
|
6
7
|
import { c as classes } from './classes-0d95c529.js';
|
|
7
8
|
import { g as getBorderRadius } from './getBorderRadius-d244b4b1.js';
|
|
8
9
|
import { i as isDarkColor } from './isDarkColor-39a36e82.js';
|
|
@@ -674,7 +675,11 @@ const ZonosCheckout = class {
|
|
|
674
675
|
// Remove query parameters
|
|
675
676
|
const cleanUrl = url.split('?')[0];
|
|
676
677
|
// Update the URL without query parameters
|
|
677
|
-
|
|
678
|
+
/**
|
|
679
|
+
* Setting the state to null in window.history.replaceState can cause issues with rendering when using next/link and pressing the back button.
|
|
680
|
+
* @ref https://github.com/vercel/next.js/issues/33233#issuecomment-1052349396
|
|
681
|
+
**/
|
|
682
|
+
window.history.replaceState(window.history.state, document.title, cleanUrl);
|
|
678
683
|
this.open = false;
|
|
679
684
|
// Reload the page
|
|
680
685
|
window.location.reload();
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host } from './index-3b46f3c3.js';
|
|
2
|
-
import {
|
|
2
|
+
import { r as handleFetch, u as isValidSelector, h as stripeStore, v as initLocalizationStore, a as localizationStoreUpdateSelectedCountryCode } from './cart-1a37e002.js';
|
|
3
3
|
import { z as zonosStore, b as zonosStoreInitSetting, d as zonosStoreFontFamily } from './zonosStore-32e33a45.js';
|
|
4
|
+
import { a as logError, l as log } from './logError-c456c092.js';
|
|
4
5
|
import './isDarkColor-39a36e82.js';
|
|
5
6
|
import './getBorderRadius-d244b4b1.js';
|
|
6
7
|
|
|
@@ -176,7 +177,29 @@ const ZonosController = class {
|
|
|
176
177
|
log(`[FONT] ${overrideFont} font override applied`);
|
|
177
178
|
zonosStore.appearance = Object.assign(Object.assign({}, zonosStore.appearance), { fontFamily: overrideFont });
|
|
178
179
|
}
|
|
180
|
+
handleLocationChange() {
|
|
181
|
+
// re-inject hello component if the location changes
|
|
182
|
+
void initHello(zonosStore.helloSettings);
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Init history listener to know when the location changes to re-inject hello component
|
|
186
|
+
*/
|
|
187
|
+
initHistoryListener() {
|
|
188
|
+
const oldPushState = history.pushState;
|
|
189
|
+
history.pushState = function pushState() {
|
|
190
|
+
window.dispatchEvent(new window.Event('pushstate'));
|
|
191
|
+
window.dispatchEvent(new window.Event('locationchange'));
|
|
192
|
+
return oldPushState.apply(this, arguments);
|
|
193
|
+
};
|
|
194
|
+
const oldReplaceState = history.replaceState;
|
|
195
|
+
history.replaceState = function replaceState() {
|
|
196
|
+
window.dispatchEvent(new window.Event('replacestate'));
|
|
197
|
+
window.dispatchEvent(new window.Event('locationchange'));
|
|
198
|
+
return oldReplaceState.apply(this, arguments);
|
|
199
|
+
};
|
|
200
|
+
}
|
|
179
201
|
async componentWillLoad() {
|
|
202
|
+
this.initHistoryListener();
|
|
180
203
|
zonosStore.zonosApiKey = this.zonosApiKey;
|
|
181
204
|
// running with scope async function to avoid blocking the main thread
|
|
182
205
|
(async () => {
|
|
@@ -188,9 +211,13 @@ const ZonosController = class {
|
|
|
188
211
|
}
|
|
189
212
|
// init zonos notification
|
|
190
213
|
this.initZonosNotification();
|
|
214
|
+
const config = Object.assign(Object.assign({}, this.config), {
|
|
215
|
+
// override subscription status
|
|
216
|
+
subscriptionStatus: undefined
|
|
217
|
+
});
|
|
191
218
|
// load default setting if fail to load user setting
|
|
192
219
|
zonosStoreInitSetting({
|
|
193
|
-
overrideSettings:
|
|
220
|
+
overrideSettings: config,
|
|
194
221
|
zonosSettings: json,
|
|
195
222
|
});
|
|
196
223
|
// setup google font after store loaded
|
|
@@ -263,7 +290,7 @@ const ZonosController = class {
|
|
|
263
290
|
zonosStore.organizationName = organizationName;
|
|
264
291
|
}
|
|
265
292
|
render() {
|
|
266
|
-
return h(Host, { key: '
|
|
293
|
+
return h(Host, { key: '5085618e4664aa12a2d48d289ae5b2c3ac15d83b', class: "zonos--elements" });
|
|
267
294
|
}
|
|
268
295
|
};
|
|
269
296
|
ZonosController.style = ZonosControllerStyle0;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, d as getElement } from './index-3b46f3c3.js';
|
|
2
|
-
import { l as localizationStore } from './cart-
|
|
2
|
+
import { l as localizationStore } from './cart-1a37e002.js';
|
|
3
3
|
import { d as zonosStoreFontFamily } from './zonosStore-32e33a45.js';
|
|
4
4
|
import { c as classes } from './classes-0d95c529.js';
|
|
5
|
+
import './logError-c456c092.js';
|
|
5
6
|
import './isDarkColor-39a36e82.js';
|
|
6
7
|
import './getBorderRadius-d244b4b1.js';
|
|
7
8
|
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, d as getElement } from './index-3b46f3c3.js';
|
|
2
|
-
import {
|
|
2
|
+
import { a as localizationStoreUpdateSelectedCountryCode, l as localizationStore } from './cart-1a37e002.js';
|
|
3
3
|
import { d as zonosStoreFontFamily } from './zonosStore-32e33a45.js';
|
|
4
4
|
import { f as formatStringWithLinks } from './formatStringWithLinks-9e819405.js';
|
|
5
5
|
import { i as isDarkColor } from './isDarkColor-39a36e82.js';
|
|
6
6
|
import { l as languages } from './ILanguage-97790bee.js';
|
|
7
|
+
import './logError-c456c092.js';
|
|
7
8
|
import './getBorderRadius-d244b4b1.js';
|
|
8
9
|
|
|
9
10
|
/**
|
|
@@ -1824,9 +1825,9 @@ const ZonosCountrySelect = class {
|
|
|
1824
1825
|
const filteredCountries = this.inputValue
|
|
1825
1826
|
? fuseObject.map(country => country.item)
|
|
1826
1827
|
: countries.sort((a, b) => a.displayName.localeCompare(b.displayName));
|
|
1827
|
-
return (h(Host, { key: '
|
|
1828
|
+
return (h(Host, { key: '36b388d67c25bfe93dee6a7fd3c444ce0764c832', class: "zonos--elements", style: {
|
|
1828
1829
|
'--font-family': zonosStoreFontFamily(),
|
|
1829
|
-
} }, h("div", { key: '
|
|
1830
|
+
} }, h("div", { key: '80c2a2b8a38f5183c583a240b4702fe234df58e9', class: "zonos--country-select" }, h("zonos-v-stack", { key: 'fee57e283cc49f7b1d48cb6564003d77a75f02a6', class: "zonos--country-select-header", spacing: 8 }, h("zonos-select-dialog-header", { key: '030338d8bc4f52c0bf4fbcdef1415321f59de05b', handleOnClose: () => this.handleOnClose(), label: "Select a country" }, h("input", { key: '855653189b575ad697b9b90cb733ef912e7f2b83', class: "zonos--country-select-input", onInput: this.handleInputChange, placeholder: "Search countries", value: this.inputValue }))), h("div", { key: '353bf39d18d2aad7c2f4096592c6e13572bc5a16', class: "zonos--country-select-content" }, filteredCountries.map(country => (h("button", { class: "zonos--country-select-country", onClick: () => this.countrySelected(country.code) }, h("zonos-country-flag", { class: "zonos--country-flag", countryCode: country.code }), h("zonos-text", { textColor: "gray-800" }, country.displayName), country.code === localizationStore.selectedCountryCode && (h("zonos-icon", { content: GreenCheckDuotoneIcon, size: 20 })))))))));
|
|
1830
1831
|
}
|
|
1831
1832
|
get ele() { return getElement(this); }
|
|
1832
1833
|
};
|
|
@@ -1843,9 +1844,9 @@ const ZonosCustomMessage = class {
|
|
|
1843
1844
|
}
|
|
1844
1845
|
render() {
|
|
1845
1846
|
const messageWithLinks = formatStringWithLinks(this.message);
|
|
1846
|
-
return (h(Host, { key: '
|
|
1847
|
+
return (h(Host, { key: 'a0c9c81f42cc74f53f497ea37d9f1fcfe2853c25', class: "zonos--elements", style: {
|
|
1847
1848
|
'--font-family': zonosStoreFontFamily(),
|
|
1848
|
-
} }, this.message && (h("zonos-card", { key: '
|
|
1849
|
+
} }, this.message && (h("zonos-card", { key: '334b1d76339667cd873d966b069429b9a2c08249', class: "zonos--custom-message", spacing: "12px" }, h("div", { key: 'c3a72d8c248acc2ac36b45d5afe0c69428eb1a75', class: "zonos--flex-message" }, h("zonos-icon", { key: 'c8ca45558e2dc0e389a0fb99943b81dfd0328f3e', "aria-label": "Custom message icon", content: this.icon }), h("zonos-text", { key: '9a1ce78aba237d325a0b3d1c61b62ca4f3b89c18', innerHTML: messageWithLinks }))))));
|
|
1849
1850
|
}
|
|
1850
1851
|
};
|
|
1851
1852
|
ZonosCustomMessage.style = ZonosCustomMessageStyle0;
|