@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
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import { a as zonosStoreFontFamily } from './zonosStore.js';
|
|
3
|
-
import { c as classes } from './classes.js';
|
|
4
|
-
import { d as defineCustomElement$1 } from './zonos-text2.js';
|
|
5
|
-
|
|
6
|
-
const zonosCardCss = ":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 .styled-card{border:var(--zonos-elements-border);border-radius:var(--zonos-elements-radius-6);padding:var(--spacing, 24px);text-align:left}:host .styled-card hr{margin-left:calc(var(--spacing, 24px) * -1);margin-right:calc(var(--spacing, 24px) * -1)}:host .styled-card .card-header{margin:calc(var(--spacing, 24px) * -1);padding:var(--spacing, 24px);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;margin-bottom:var(--spacing, 24px);border-bottom:var(--zonos-elements-border);height:65px;line-height:65px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}:host .styled-card .card-header h5{margin-bottom:0;-ms-flex:1;flex:1}:host .styled-card .card-footer{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;margin:calc(var(--spacing, 24px) * -1);padding:var(--spacing, 24px);border-top:var(--zonos-elements-border);background:var(--zonos-elements-surface-color-secondary);margin-top:var(--spacing, 24px);border-bottom-left-radius:var(--zonos-elements-radius-8);border-bottom-right-radius:var(--zonos-elements-radius-8);height:var(--footerHeight)}";
|
|
7
|
-
const ZonosCardStyle0 = zonosCardCss;
|
|
8
|
-
|
|
9
|
-
const ZonosCard = /*@__PURE__*/ proxyCustomElement(class ZonosCard extends HTMLElement {
|
|
10
|
-
constructor() {
|
|
11
|
-
super();
|
|
12
|
-
this.__registerHost();
|
|
13
|
-
this.__attachShadow();
|
|
14
|
-
this.actions = undefined;
|
|
15
|
-
this.footerActions = undefined;
|
|
16
|
-
this.footerContent = undefined;
|
|
17
|
-
this.footerHeight = undefined;
|
|
18
|
-
this.label = undefined;
|
|
19
|
-
this.spacing = '24px';
|
|
20
|
-
}
|
|
21
|
-
render() {
|
|
22
|
-
return (h(Host, { key: '206169280db67be5e74382c5beccfad87ec9068a', style: {
|
|
23
|
-
'--font-family': zonosStoreFontFamily(),
|
|
24
|
-
} }, h("div", { key: '4a1c7eab9b5420295ce3ec30cfd59985be35d912', class: classes(['styled-card']), style: { padding: this.spacing } }, this.label && (h("header", { key: '75454e5d9eacdfdf842a9a220deab467625e497b', class: "card-header", style: { padding: this.spacing } }, h("zonos-text", { key: 'bc9c7d3500cef41237dbe53f27ab398103be55dd', type: "subheader" }, this.label), h("h-stack", { key: '29d68a483bfc61ddfb9deeb63272a8221759513c', spacing: 8 }, this.actions))), h("slot", { key: '0ad416c6cdb0b1fc2c922b8569cf35a4009263cc' }), (this.footerActions || this.footerContent) && (h("footer", { key: '469110ce0f0f81cbee4ef67e79d3be17933bcf2e', class: "card-footer", style: {
|
|
25
|
-
height: this.footerHeight ? `${this.footerHeight}px` : 'auto',
|
|
26
|
-
padding: this.spacing,
|
|
27
|
-
} }, h("div", { key: '9044d9f3c81935119f668deb188f16cb1cb243bb' }, this.footerContent), h("h-stack", { key: '3f258ed6b07b8973b0bf753c7ab6427d67bf210c', spacing: 8 }, this.footerActions))))));
|
|
28
|
-
}
|
|
29
|
-
static get style() { return ZonosCardStyle0; }
|
|
30
|
-
}, [1, "zonos-card", {
|
|
31
|
-
"actions": [16],
|
|
32
|
-
"footerActions": [16],
|
|
33
|
-
"footerContent": [16],
|
|
34
|
-
"footerHeight": [2, "footer-height"],
|
|
35
|
-
"label": [16],
|
|
36
|
-
"spacing": [1]
|
|
37
|
-
}]);
|
|
38
|
-
function defineCustomElement() {
|
|
39
|
-
if (typeof customElements === "undefined") {
|
|
40
|
-
return;
|
|
41
|
-
}
|
|
42
|
-
const components = ["zonos-card", "zonos-text"];
|
|
43
|
-
components.forEach(tagName => { switch (tagName) {
|
|
44
|
-
case "zonos-card":
|
|
45
|
-
if (!customElements.get(tagName)) {
|
|
46
|
-
customElements.define(tagName, ZonosCard);
|
|
47
|
-
}
|
|
48
|
-
break;
|
|
49
|
-
case "zonos-text":
|
|
50
|
-
if (!customElements.get(tagName)) {
|
|
51
|
-
defineCustomElement$1();
|
|
52
|
-
}
|
|
53
|
-
break;
|
|
54
|
-
} });
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
export { ZonosCard as Z, defineCustomElement as d };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Components, JSX } from "../types/components";
|
|
2
|
-
|
|
3
|
-
interface ZonosCartItems extends Components.ZonosCartItems, HTMLElement {}
|
|
4
|
-
export const ZonosCartItems: {
|
|
5
|
-
prototype: ZonosCartItems;
|
|
6
|
-
new (): ZonosCartItems;
|
|
7
|
-
};
|
|
8
|
-
/**
|
|
9
|
-
* Used to define this component and all nested components recursively.
|
|
10
|
-
*/
|
|
11
|
-
export const defineCustomElement: () => void;
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement, getAssetPath, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import { c as cartStore } from './stripe.js';
|
|
3
|
-
import { f as formatCurrency } from './formatCurrency.js';
|
|
4
|
-
import { d as defineCustomElement$1 } from './zonos-text2.js';
|
|
5
|
-
|
|
6
|
-
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}";
|
|
7
|
-
const ZonosCartItemsStyle0 = zonosCartItemsCss;
|
|
8
|
-
|
|
9
|
-
const ZonosCartItems = /*@__PURE__*/ proxyCustomElement(class ZonosCartItems extends HTMLElement {
|
|
10
|
-
constructor() {
|
|
11
|
-
super();
|
|
12
|
-
this.__registerHost();
|
|
13
|
-
this.__attachShadow();
|
|
14
|
-
this.errorImages = [];
|
|
15
|
-
}
|
|
16
|
-
render() {
|
|
17
|
-
var _a;
|
|
18
|
-
const emptyItemImg = getAssetPath('./assets/empty-item.jpeg');
|
|
19
|
-
const rate = ((_a = cartStore.exchangeRate) === null || _a === void 0 ? void 0 : _a.rate) || 1;
|
|
20
|
-
const nonRestrictedItems = cartStore.items.filter(item => !item.isRestricted);
|
|
21
|
-
return (h(Host, { key: '2dc2189f79fe59260a9fcd8a61142ab628ff7f57', class: "zonos--cart-items zonos--elements" }, h("table", { key: 'd354007fffb5afa397038f319571e83c3fb3ad65', class: "zonos--cart-table" }, h("tbody", { key: '5f31a21b612495ee583650cbd71614cc10a799cc' }, nonRestrictedItems.map(item => {
|
|
22
|
-
const itemImg = item.imageUrl;
|
|
23
|
-
return (h("tr", { class: "zonos--cart-item" }, h("td", { class: "zonos--column zonos--cart-item-image" }, itemImg && !this.errorImages.includes(itemImg) ? (h("img", { alt: item.name, onError: () => {
|
|
24
|
-
this.errorImages = [...this.errorImages, itemImg];
|
|
25
|
-
}, src: item.imageUrl, style: {
|
|
26
|
-
'min-width': '40px',
|
|
27
|
-
}, width: 40 })) : (h("img", { alt: item.name, src: emptyItemImg, width: 40 }))), h("td", { class: "zonos--column zonos--cart-item-name" }, h("zonos-text", { type: "label" }, item.name)), h("td", { class: "zonos--column zonos--cart-item-price" }, h("zonos-text", { type: "semiBoldLabel" }, formatCurrency({
|
|
28
|
-
amount: item.amount * item.quantity * rate,
|
|
29
|
-
currency: cartStore.currency,
|
|
30
|
-
})))));
|
|
31
|
-
})))));
|
|
32
|
-
}
|
|
33
|
-
static get assetsDirs() { return ["assets"]; }
|
|
34
|
-
static get style() { return ZonosCartItemsStyle0; }
|
|
35
|
-
}, [1, "zonos-cart-items", {
|
|
36
|
-
"errorImages": [32]
|
|
37
|
-
}]);
|
|
38
|
-
function defineCustomElement() {
|
|
39
|
-
if (typeof customElements === "undefined") {
|
|
40
|
-
return;
|
|
41
|
-
}
|
|
42
|
-
const components = ["zonos-cart-items", "zonos-text"];
|
|
43
|
-
components.forEach(tagName => { switch (tagName) {
|
|
44
|
-
case "zonos-cart-items":
|
|
45
|
-
if (!customElements.get(tagName)) {
|
|
46
|
-
customElements.define(tagName, ZonosCartItems);
|
|
47
|
-
}
|
|
48
|
-
break;
|
|
49
|
-
case "zonos-text":
|
|
50
|
-
if (!customElements.get(tagName)) {
|
|
51
|
-
defineCustomElement$1();
|
|
52
|
-
}
|
|
53
|
-
break;
|
|
54
|
-
} });
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
export { ZonosCartItems as Z, defineCustomElement as d };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Components, JSX } from "../types/components";
|
|
2
|
-
|
|
3
|
-
interface ZonosCartRestrictedItems extends Components.ZonosCartRestrictedItems, HTMLElement {}
|
|
4
|
-
export const ZonosCartRestrictedItems: {
|
|
5
|
-
prototype: ZonosCartRestrictedItems;
|
|
6
|
-
new (): ZonosCartRestrictedItems;
|
|
7
|
-
};
|
|
8
|
-
/**
|
|
9
|
-
* Used to define this component and all nested components recursively.
|
|
10
|
-
*/
|
|
11
|
-
export const defineCustomElement: () => void;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { Z as ZonosCartRestrictedItems$1, d as defineCustomElement$1 } from './zonos-cart-restricted-items2.js';
|
|
2
|
-
|
|
3
|
-
const ZonosCartRestrictedItems = ZonosCartRestrictedItems$1;
|
|
4
|
-
const defineCustomElement = defineCustomElement$1;
|
|
5
|
-
|
|
6
|
-
export { ZonosCartRestrictedItems, defineCustomElement };
|
|
@@ -1,135 +0,0 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement, getAssetPath, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import { b as cartStoreHasOneEligibleItem, c as cartStore } from './stripe.js';
|
|
3
|
-
import { a as translate } from './translationStore.js';
|
|
4
|
-
import { c as classes } from './classes.js';
|
|
5
|
-
import { f as formatCurrency } from './formatCurrency.js';
|
|
6
|
-
import { d as defineCustomElement$4 } from './zonos-banner2.js';
|
|
7
|
-
import { d as defineCustomElement$3 } from './zonos-collapse2.js';
|
|
8
|
-
import { d as defineCustomElement$2 } from './zonos-icon2.js';
|
|
9
|
-
import { d as defineCustomElement$1 } from './zonos-text2.js';
|
|
10
|
-
|
|
11
|
-
const ChevronUpIcon = `<svg width="25" height="24" viewBox="0 0 25 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
12
|
-
<g filter="url(#filter0_dd_2052_3658)">
|
|
13
|
-
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.46967 14.5303C7.76256 14.8232 8.23744 14.8232 8.53033 14.5303L12.5 10.5607L16.4697 14.5303C16.7626 14.8232 17.2374 14.8232 17.5303 14.5303C17.8232 14.2374 17.8232 13.7626 17.5303 13.4697L13.0303 8.96967C12.7374 8.67678 12.2626 8.67678 11.9697 8.96967L7.46967 13.4697C7.17678 13.7626 7.17678 14.2374 7.46967 14.5303Z" fill="currentColor"/>
|
|
14
|
-
</g>
|
|
15
|
-
<defs>
|
|
16
|
-
<filter id="filter0_dd_2052_3658" x="-3.5" y="-2" width="32" height="32" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
|
17
|
-
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
|
18
|
-
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
|
|
19
|
-
<feOffset dy="2"/>
|
|
20
|
-
<feGaussianBlur stdDeviation="2"/>
|
|
21
|
-
<feComposite in2="hardAlpha" operator="out"/>
|
|
22
|
-
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.06 0"/>
|
|
23
|
-
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_2052_3658"/>
|
|
24
|
-
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
|
|
25
|
-
<feOffset dy="1"/>
|
|
26
|
-
<feGaussianBlur stdDeviation="1"/>
|
|
27
|
-
<feComposite in2="hardAlpha" operator="out"/>
|
|
28
|
-
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.04 0"/>
|
|
29
|
-
<feBlend mode="normal" in2="effect1_dropShadow_2052_3658" result="effect2_dropShadow_2052_3658"/>
|
|
30
|
-
<feBlend mode="normal" in="SourceGraphic" in2="effect2_dropShadow_2052_3658" result="shape"/>
|
|
31
|
-
</filter>
|
|
32
|
-
</defs>
|
|
33
|
-
</svg>
|
|
34
|
-
`;
|
|
35
|
-
|
|
36
|
-
const zonosCartRestrictedItemsCss = ":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{overflow:auto;position:relative}:host zonos-banner{margin-bottom:12px}:host .zonos--cart-title-collapse-trigger{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;gap:24px;-ms-flex-align:center;align-items:center;background:var(--zonos-elements-gray-0);width:100%;border:none;cursor:pointer;margin-bottom:16px;position:-webkit-sticky;position:sticky;top:0;z-index:1;-webkit-transition:0.5s all ease;transition:0.5s all ease}:host .zonos--cart-title-collapse-trigger zonos-icon{-webkit-transition:-webkit-transform 0.3s ease;transition:-webkit-transform 0.3s ease;transition:transform 0.3s ease;transition:transform 0.3s ease, -webkit-transform 0.3s ease}:host .zonos--cart-title-collapse-trigger.collapsed{margin-bottom:0}:host .zonos--cart-title-collapse-trigger.collapsed zonos-icon{-webkit-transform:rotate(180deg);transform:rotate(180deg)}:host .zonos--cart-title-collapse-trigger::before,:host .zonos--cart-title-collapse-trigger::after{content:\"\";display:block;width:80%;height:1px;background-color:var(--zonos-elements-border-color);-ms-flex-negative:1;flex-shrink:1}:host .zonos--cart-title-collapse-trigger .zonos--title-wrapper{-ms-flex-positive:1;flex-grow:1;-ms-flex-negative:0;flex-shrink:0;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-direction:row;flex-direction:row;gap:8px;-ms-flex-align:center;align-items:center}:host .zonos--cart-table{opacity:0.5;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}:host(.collapsed){-ms-flex-negative:0;flex-shrink:0}";
|
|
37
|
-
const ZonosCartRestrictedItemsStyle0 = zonosCartRestrictedItemsCss;
|
|
38
|
-
|
|
39
|
-
const ZonosCartRestrictedItems = /*@__PURE__*/ proxyCustomElement(class ZonosCartRestrictedItems extends HTMLElement {
|
|
40
|
-
constructor() {
|
|
41
|
-
super();
|
|
42
|
-
this.__registerHost();
|
|
43
|
-
this.__attachShadow();
|
|
44
|
-
this.hide = false;
|
|
45
|
-
this.errorImages = [];
|
|
46
|
-
this.internalCollapsed = true;
|
|
47
|
-
this.firstRender = true;
|
|
48
|
-
}
|
|
49
|
-
componentDidLoad() {
|
|
50
|
-
// Reset if it's first render
|
|
51
|
-
this.firstRender = true;
|
|
52
|
-
}
|
|
53
|
-
render() {
|
|
54
|
-
var _a;
|
|
55
|
-
const emptyItemImg = getAssetPath('./assets/empty-item.jpeg');
|
|
56
|
-
const rate = ((_a = cartStore.exchangeRate) === null || _a === void 0 ? void 0 : _a.rate) || 1;
|
|
57
|
-
const restrictedItemTotal = cartStore.restrictedItems.length;
|
|
58
|
-
if (this.hide || restrictedItemTotal === 0) {
|
|
59
|
-
// show nothing if the parent is collapsed or no restricted items
|
|
60
|
-
return null;
|
|
61
|
-
}
|
|
62
|
-
if (this.firstRender) {
|
|
63
|
-
// Auto expand if all items are restricted
|
|
64
|
-
this.internalCollapsed = cartStoreHasOneEligibleItem();
|
|
65
|
-
this.firstRender = false;
|
|
66
|
-
}
|
|
67
|
-
return (h(Host, { class: classes([
|
|
68
|
-
'zonos--cart-restricted-items',
|
|
69
|
-
'zonos--elements',
|
|
70
|
-
this.internalCollapsed && 'collapsed',
|
|
71
|
-
]) }, h("button", { class: classes([
|
|
72
|
-
'zonos--cart-title-collapse-trigger',
|
|
73
|
-
this.internalCollapsed && 'collapsed',
|
|
74
|
-
]), onClick: () => {
|
|
75
|
-
this.internalCollapsed = !this.internalCollapsed;
|
|
76
|
-
} }, h("div", { class: "zonos--title-wrapper" }, h("zonos-text", { textColor: "red-600", type: "label" }, `${translate(this.internalCollapsed ? 'Show' : 'Hide')} ${restrictedItemTotal} ${translate('restricted items')}`), h("zonos-icon", { content: ChevronUpIcon, iconColor: "red-600" }))), h("zonos-collapse", { collapsed: this.internalCollapsed }, h("zonos-banner", { bannerTitle: translate('The following items are unable to be shipped to your country and are not included in your cart total.'), intent: "error" }), h("table", { class: "zonos--cart-table" }, h("tbody", null, cartStore.restrictedItems.map((item, index) => {
|
|
77
|
-
var _a, _b;
|
|
78
|
-
const itemImg = item.imageUrl;
|
|
79
|
-
return (h("tr", { class: "zonos--cart-item" }, h("td", { class: "zonos--column zonos--cart-item-image" }, itemImg && !this.errorImages.includes(itemImg) ? (h("img", { alt:
|
|
80
|
-
// Use matched item name if available
|
|
81
|
-
((_a = item.matchedItem) === null || _a === void 0 ? void 0 : _a.name) ||
|
|
82
|
-
item.name ||
|
|
83
|
-
`Restricted item ${index + 1}`, onError: () => {
|
|
84
|
-
this.errorImages = [...this.errorImages, itemImg];
|
|
85
|
-
}, src: itemImg, style: {
|
|
86
|
-
'min-width': '40px',
|
|
87
|
-
}, width: 40 })) : (h("img", { alt: item.name || `Restricted item ${index + 1}`, src: emptyItemImg, width: 40 }))), h("td", { class: "zonos--column zonos--cart-item-name" }, h("zonos-text", { type: "label" }, ((_b = item.matchedItem) === null || _b === void 0 ? void 0 : _b.name) || item.name), h("zonos-text", { type: "caption" }, item.restriction.reason)), h("td", { class: "zonos--column zonos--cart-item-price" }, h("zonos-text", { type: "semiBoldLabel" }, formatCurrency({
|
|
88
|
-
amount: item.amount * item.quantity * rate,
|
|
89
|
-
currency: cartStore.currency,
|
|
90
|
-
})))));
|
|
91
|
-
}))))));
|
|
92
|
-
}
|
|
93
|
-
static get assetsDirs() { return ["assets"]; }
|
|
94
|
-
static get style() { return ZonosCartRestrictedItemsStyle0; }
|
|
95
|
-
}, [1, "zonos-cart-restricted-items", {
|
|
96
|
-
"hide": [4],
|
|
97
|
-
"errorImages": [32],
|
|
98
|
-
"internalCollapsed": [32],
|
|
99
|
-
"firstRender": [32]
|
|
100
|
-
}]);
|
|
101
|
-
function defineCustomElement() {
|
|
102
|
-
if (typeof customElements === "undefined") {
|
|
103
|
-
return;
|
|
104
|
-
}
|
|
105
|
-
const components = ["zonos-cart-restricted-items", "zonos-banner", "zonos-collapse", "zonos-icon", "zonos-text"];
|
|
106
|
-
components.forEach(tagName => { switch (tagName) {
|
|
107
|
-
case "zonos-cart-restricted-items":
|
|
108
|
-
if (!customElements.get(tagName)) {
|
|
109
|
-
customElements.define(tagName, ZonosCartRestrictedItems);
|
|
110
|
-
}
|
|
111
|
-
break;
|
|
112
|
-
case "zonos-banner":
|
|
113
|
-
if (!customElements.get(tagName)) {
|
|
114
|
-
defineCustomElement$4();
|
|
115
|
-
}
|
|
116
|
-
break;
|
|
117
|
-
case "zonos-collapse":
|
|
118
|
-
if (!customElements.get(tagName)) {
|
|
119
|
-
defineCustomElement$3();
|
|
120
|
-
}
|
|
121
|
-
break;
|
|
122
|
-
case "zonos-icon":
|
|
123
|
-
if (!customElements.get(tagName)) {
|
|
124
|
-
defineCustomElement$2();
|
|
125
|
-
}
|
|
126
|
-
break;
|
|
127
|
-
case "zonos-text":
|
|
128
|
-
if (!customElements.get(tagName)) {
|
|
129
|
-
defineCustomElement$1();
|
|
130
|
-
}
|
|
131
|
-
break;
|
|
132
|
-
} });
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
export { ZonosCartRestrictedItems as Z, defineCustomElement as d };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Components, JSX } from "../types/components";
|
|
2
|
-
|
|
3
|
-
interface ZonosCartSubtotal extends Components.ZonosCartSubtotal, HTMLElement {}
|
|
4
|
-
export const ZonosCartSubtotal: {
|
|
5
|
-
prototype: ZonosCartSubtotal;
|
|
6
|
-
new (): ZonosCartSubtotal;
|
|
7
|
-
};
|
|
8
|
-
/**
|
|
9
|
-
* Used to define this component and all nested components recursively.
|
|
10
|
-
*/
|
|
11
|
-
export const defineCustomElement: () => void;
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement, h, Host, Fragment } from '@stencil/core/internal/client';
|
|
2
|
-
import { b as cartStoreHasOneEligibleItem, c as cartStore } from './stripe.js';
|
|
3
|
-
import { a as translate } from './translationStore.js';
|
|
4
|
-
import { f as formatCurrency } from './formatCurrency.js';
|
|
5
|
-
import { d as defineCustomElement$4 } from './zonos-badge2.js';
|
|
6
|
-
import { d as defineCustomElement$3 } from './zonos-icon2.js';
|
|
7
|
-
import { d as defineCustomElement$2 } from './zonos-text2.js';
|
|
8
|
-
import { d as defineCustomElement$1 } from './zonos-tooltip2.js';
|
|
9
|
-
|
|
10
|
-
const InfoIcon = `<svg viewBox="0 0 17 16" fill="none" xmlns="https://www.w3.org/2000/svg">
|
|
11
|
-
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.96704 8.00065C1.96704 4.31875 4.93024 1.33398 8.58554 1.33398C12.2408 1.33398 15.204 4.31875 15.204 8.00065C15.204 11.6826 12.2408 14.6673 8.58554 14.6673C4.93024 14.6673 1.96704 11.6825 1.96704 8.00065Z" fill="#C5C6CA"/>
|
|
12
|
-
<path fill-rule="evenodd" clip-rule="evenodd" d="M8.58543 4.66016C8.95096 4.66016 9.24728 4.95863 9.24728 5.32682V5.33349C9.24728 5.70168 8.95096 6.00016 8.58543 6.00016C8.2199 6.00016 7.92358 5.70168 7.92358 5.33349V5.32682C7.92358 4.95863 8.2199 4.66016 8.58543 4.66016ZM8.58543 7.33349C8.95096 7.33349 9.24728 7.63197 9.24728 8.00016V10.6668C9.24728 11.035 8.95096 11.3335 8.58543 11.3335C8.2199 11.3335 7.92358 11.035 7.92358 10.6668V8.00016C7.92358 7.63197 8.2199 7.33349 8.58543 7.33349Z" fill="#4D505A"/>
|
|
13
|
-
</svg>
|
|
14
|
-
`;
|
|
15
|
-
|
|
16
|
-
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}";
|
|
17
|
-
const ZonosCartSubtotalStyle0 = zonosCartSubtotalCss;
|
|
18
|
-
|
|
19
|
-
const ZonosCartSubtotal = /*@__PURE__*/ proxyCustomElement(class ZonosCartSubtotal extends HTMLElement {
|
|
20
|
-
constructor() {
|
|
21
|
-
super();
|
|
22
|
-
this.__registerHost();
|
|
23
|
-
this.__attachShadow();
|
|
24
|
-
}
|
|
25
|
-
render() {
|
|
26
|
-
const showDutyTaxesInfo = cartStore.step === 'payment' || cartStore.step === 'shipping';
|
|
27
|
-
// Show 0 for subtotal and total when all items are restricted
|
|
28
|
-
const total = cartStoreHasOneEligibleItem() ? cartStore.total : 0;
|
|
29
|
-
const subtotal = cartStoreHasOneEligibleItem() ? cartStore.subtotal : 0;
|
|
30
|
-
const renderShippingInfo = () => {
|
|
31
|
-
if (!cartStore.selectedShippingOption) {
|
|
32
|
-
return (h(Fragment, null, h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, translate('Shipping')), h("zonos-text", { class: "zonos--caption", type: "caption" }, translate('No shipping method selected'))));
|
|
33
|
-
}
|
|
34
|
-
return (h(Fragment, null, h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, cartStore.selectedShippingOption.displayName), cartStore.selectedShippingOptionTransitTime && (h("zonos-text", { class: "zonos--caption", type: "caption" }, cartStore.selectedShippingOptionTransitTime, ' ', translate('business days')))));
|
|
35
|
-
};
|
|
36
|
-
return (h(Host, { class: "zonos--cart-subtotal zonos--elements" }, h("table", { class: "zonos--cart-table" }, h("tr", { class: "zonos--row zonos--cart-subtotal" }, h("td", { class: "zonos--column" }), h("td", { class: "zonos--column zonos--cart-subtotal-title" }, h("zonos-text", { type: "semiBoldLabel" }, translate('Cart subtotal'))), h("td", { class: "zonos--column zonos--cart-subtotal-price" }, h("zonos-text", { type: "semiBoldLabel" }, formatCurrency({
|
|
37
|
-
amount: subtotal,
|
|
38
|
-
currency: cartStore.currency,
|
|
39
|
-
})))), h("tr", { class: "zonos--row zonos--cart-shipping" }, h("td", { class: "zonos--column" }), h("td", { class: "zonos--column zonos--cart-subtotal-title" }, renderShippingInfo()), h("td", { class: "zonos--column zonos--cart-subtotal-price" }, cartStore.shipping
|
|
40
|
-
? formatCurrency({
|
|
41
|
-
amount: cartStore.shipping,
|
|
42
|
-
currency: cartStore.currency,
|
|
43
|
-
})
|
|
44
|
-
: '-')), showDutyTaxesInfo && (h("tr", { class: "zonos--row zonos--cart-duties" }, h("td", { class: "zonos--column" }), h("td", { class: "zonos--column zonos--cart-subtotal-title" }, h("div", { class: "zonos--title-with-icon" }, h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, translate('Duties, taxes, and fees')), h("zonos-tooltip", { label: translate('Nothing due at the door') }, h("zonos-icon", { "aria-label": "Learn more about duties, taxes, and fees", content: InfoIcon, size: 16 }))), !!cartStore.isSelectedShippingAboveDeminimis && (h("zonos-text", { textColor: "gray-800", type: "body" }, translate('Order is over the de minimis threshold for both duty and tax')))), h("td", { class: "zonos--column zonos--cart-subtotal-price" }, h("div", { class: "zonos--cart-duty-tax-price" }, cartStore.dutiesTaxFees
|
|
45
|
-
? formatCurrency({
|
|
46
|
-
amount: cartStore.dutiesTaxFees,
|
|
47
|
-
currency: cartStore.currency,
|
|
48
|
-
})
|
|
49
|
-
: '-', cartStore.isSelectedShippingGuarantee && (h("zonos-badge", null, translate('Guaranteed'))))))), h("tr", { class: "zonos--row zonos--cart-pay-total" }, h("td", { class: "zonos--column" }), h("td", { class: "zonos--column" }, h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, translate('Order total'))), h("td", { class: "zonos--column" }, h("zonos-text", { type: "semiBoldLabel" }, formatCurrency({
|
|
50
|
-
amount: total,
|
|
51
|
-
currency: cartStore.currency,
|
|
52
|
-
})))))));
|
|
53
|
-
}
|
|
54
|
-
static get assetsDirs() { return ["assets"]; }
|
|
55
|
-
static get style() { return ZonosCartSubtotalStyle0; }
|
|
56
|
-
}, [1, "zonos-cart-subtotal"]);
|
|
57
|
-
function defineCustomElement() {
|
|
58
|
-
if (typeof customElements === "undefined") {
|
|
59
|
-
return;
|
|
60
|
-
}
|
|
61
|
-
const components = ["zonos-cart-subtotal", "zonos-badge", "zonos-icon", "zonos-text", "zonos-tooltip"];
|
|
62
|
-
components.forEach(tagName => { switch (tagName) {
|
|
63
|
-
case "zonos-cart-subtotal":
|
|
64
|
-
if (!customElements.get(tagName)) {
|
|
65
|
-
customElements.define(tagName, ZonosCartSubtotal);
|
|
66
|
-
}
|
|
67
|
-
break;
|
|
68
|
-
case "zonos-badge":
|
|
69
|
-
if (!customElements.get(tagName)) {
|
|
70
|
-
defineCustomElement$4();
|
|
71
|
-
}
|
|
72
|
-
break;
|
|
73
|
-
case "zonos-icon":
|
|
74
|
-
if (!customElements.get(tagName)) {
|
|
75
|
-
defineCustomElement$3();
|
|
76
|
-
}
|
|
77
|
-
break;
|
|
78
|
-
case "zonos-text":
|
|
79
|
-
if (!customElements.get(tagName)) {
|
|
80
|
-
defineCustomElement$2();
|
|
81
|
-
}
|
|
82
|
-
break;
|
|
83
|
-
case "zonos-tooltip":
|
|
84
|
-
if (!customElements.get(tagName)) {
|
|
85
|
-
defineCustomElement$1();
|
|
86
|
-
}
|
|
87
|
-
break;
|
|
88
|
-
} });
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
export { ZonosCartSubtotal as Z, defineCustomElement as d };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Components, JSX } from "../types/components";
|
|
2
|
-
|
|
3
|
-
interface ZonosCheckbox extends Components.ZonosCheckbox, HTMLElement {}
|
|
4
|
-
export const ZonosCheckbox: {
|
|
5
|
-
prototype: ZonosCheckbox;
|
|
6
|
-
new (): ZonosCheckbox;
|
|
7
|
-
};
|
|
8
|
-
/**
|
|
9
|
-
* Used to define this component and all nested components recursively.
|
|
10
|
-
*/
|
|
11
|
-
export const defineCustomElement: () => void;
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import { a as zonosStoreFontFamily } from './zonosStore.js';
|
|
3
|
-
import { c as classes } from './classes.js';
|
|
4
|
-
import { g as getBorderRadius } from './getBorderRadius.js';
|
|
5
|
-
import { i as isDarkColor } from './isDarkColor.js';
|
|
6
|
-
import { d as defineCustomElement$1 } from './zonos-text2.js';
|
|
7
|
-
|
|
8
|
-
const colorPrefixes = [
|
|
9
|
-
'blue',
|
|
10
|
-
'cyan',
|
|
11
|
-
'green',
|
|
12
|
-
'orange',
|
|
13
|
-
'purple',
|
|
14
|
-
'red',
|
|
15
|
-
'gray',
|
|
16
|
-
'glass',
|
|
17
|
-
];
|
|
18
|
-
|
|
19
|
-
const zonosCheckboxCss = ":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;cursor:pointer}:host label{display:-ms-inline-flexbox;display:inline-flex;position:relative;gap:8px;-ms-flex-align:center;align-items:center}:host label.disabled{cursor:not-allowed;opacity:0.6}:host input[type=checkbox]{opacity:0;position:absolute;left:0;width:0;height:0;top:0;z-index:-99999}:host svg{opacity:0}:host .checkmark-container{height:var(--size);width:var(--size);background-color:transparent;border:1.5px solid var(--zonos-elements-gray-400);position:relative;border-radius:var(--border-radius, var(--zonos-elements-radius-4))}:host .checkmark{opacity:0;position:absolute;top:-1.5px;left:-1.5px;right:-1.5px;bottom:-1.5px;width:calc(100% + 3px);-webkit-transition:0.3s all cubic-bezier(0.175, 0.885, 0.32, 1.275);transition:0.3s all cubic-bezier(0.175, 0.885, 0.32, 1.275);-webkit-transform:scale(0.4);transform:scale(0.4);background-color:var(--background-color);border-radius:var(--border-radius, var(--zonos-elements-radius-4))}:host input[type=checkbox]:checked~.checkmark-container .checkmark{opacity:1;-webkit-transform:scale(1);transform:scale(1)}";
|
|
20
|
-
const ZonosCheckboxStyle0 = zonosCheckboxCss;
|
|
21
|
-
|
|
22
|
-
const ZonosCheckbox = /*@__PURE__*/ proxyCustomElement(class ZonosCheckbox extends HTMLElement {
|
|
23
|
-
constructor() {
|
|
24
|
-
super();
|
|
25
|
-
this.__registerHost();
|
|
26
|
-
this.__attachShadow();
|
|
27
|
-
this.checkboxSelected = createEvent(this, "checkboxSelected", 7);
|
|
28
|
-
this.backgroundColor = 'blue';
|
|
29
|
-
this.label = undefined;
|
|
30
|
-
this.isChecked = false;
|
|
31
|
-
this.isDisabled = false;
|
|
32
|
-
this.size = 12;
|
|
33
|
-
this.fontSize = 'base';
|
|
34
|
-
this.borderStyle = undefined;
|
|
35
|
-
}
|
|
36
|
-
onClick() {
|
|
37
|
-
if (this.isDisabled) {
|
|
38
|
-
return;
|
|
39
|
-
}
|
|
40
|
-
this.checkboxSelected.emit(!this.isChecked);
|
|
41
|
-
}
|
|
42
|
-
render() {
|
|
43
|
-
const isBackgroundVariable = colorPrefixes.includes(this.backgroundColor);
|
|
44
|
-
const backgroundColor = isBackgroundVariable
|
|
45
|
-
? `var(--zonos-elements-${this.backgroundColor}-600)`
|
|
46
|
-
: this.backgroundColor;
|
|
47
|
-
const checkmarkColor = isBackgroundVariable
|
|
48
|
-
? // use lighter color if the color is amino variable
|
|
49
|
-
`var(--zonos-elements-${this.backgroundColor}-200)`
|
|
50
|
-
: // if it's not an amino variable, use white if the background is dark, and dark if the background is light
|
|
51
|
-
!isDarkColor(backgroundColor)
|
|
52
|
-
? 'var(--zonos-elements-gray-800)'
|
|
53
|
-
: 'var(--zonos-elements-gray-0)';
|
|
54
|
-
const borderStyle = getBorderRadius({
|
|
55
|
-
customRoundRadius: '4px',
|
|
56
|
-
overrideBorderStyle: this.borderStyle,
|
|
57
|
-
});
|
|
58
|
-
return (h(Host, { key: 'be29586ffd5ae5227614622cfb402686ff5e0583', class: classes(['zonos--elements zonos--checkbox']), style: {
|
|
59
|
-
'--background-color': backgroundColor,
|
|
60
|
-
'--border-radius': borderStyle,
|
|
61
|
-
'--font-family': zonosStoreFontFamily(),
|
|
62
|
-
'--size': `${this.size}px`,
|
|
63
|
-
} }, h("label", { key: '091c2388668a94962d7b2bde4496856805f675e8', class: classes([this.isDisabled && 'disabled']) }, h("input", { key: 'c0f66d11f63591b03631cb1c970c0db201d435e2', checked: this.isChecked, disabled: this.isDisabled, hidden: true, onChange: e => {
|
|
64
|
-
this.checkboxSelected.emit(e.target.checked);
|
|
65
|
-
}, type: "checkbox" }), h("span", { key: 'ab6c4847d006a812829bd8e871520455da91c7b0', class: "checkmark-container" }, h("svg", { key: '617693bef302910db463cdf95b10700b72ea8d44', class: "checkmark", color: checkmarkColor, fill: "none", viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, h("path", { key: '410728b7d5edf27966e660e598f166ce8292015e', "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: '1b9a21e7ef15ad34684453bc25cb3744ba183cd0', size: this.fontSize }, this.label)))));
|
|
66
|
-
}
|
|
67
|
-
static get style() { return ZonosCheckboxStyle0; }
|
|
68
|
-
}, [1, "zonos-checkbox", {
|
|
69
|
-
"backgroundColor": [1, "background-color"],
|
|
70
|
-
"label": [1],
|
|
71
|
-
"isChecked": [4, "is-checked"],
|
|
72
|
-
"isDisabled": [4, "is-disabled"],
|
|
73
|
-
"size": [2],
|
|
74
|
-
"fontSize": [1, "font-size"],
|
|
75
|
-
"borderStyle": [1, "border-style"]
|
|
76
|
-
}, [[1, "click", "onClick"]]]);
|
|
77
|
-
function defineCustomElement() {
|
|
78
|
-
if (typeof customElements === "undefined") {
|
|
79
|
-
return;
|
|
80
|
-
}
|
|
81
|
-
const components = ["zonos-checkbox", "zonos-text"];
|
|
82
|
-
components.forEach(tagName => { switch (tagName) {
|
|
83
|
-
case "zonos-checkbox":
|
|
84
|
-
if (!customElements.get(tagName)) {
|
|
85
|
-
customElements.define(tagName, ZonosCheckbox);
|
|
86
|
-
}
|
|
87
|
-
break;
|
|
88
|
-
case "zonos-text":
|
|
89
|
-
if (!customElements.get(tagName)) {
|
|
90
|
-
defineCustomElement$1();
|
|
91
|
-
}
|
|
92
|
-
break;
|
|
93
|
-
} });
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export { ZonosCheckbox as Z, defineCustomElement as d };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Components, JSX } from "../types/components";
|
|
2
|
-
|
|
3
|
-
interface ZonosCheckoutFinish extends Components.ZonosCheckoutFinish, HTMLElement {}
|
|
4
|
-
export const ZonosCheckoutFinish: {
|
|
5
|
-
prototype: ZonosCheckoutFinish;
|
|
6
|
-
new (): ZonosCheckoutFinish;
|
|
7
|
-
};
|
|
8
|
-
/**
|
|
9
|
-
* Used to define this component and all nested components recursively.
|
|
10
|
-
*/
|
|
11
|
-
export const defineCustomElement: () => void;
|