@zonos/elements 1.3.11-alpha.0 → 1.3.11-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{cart-7e28f026.js → cart-d9e9ecfc.js} +29 -25
- package/dist/cjs/{getBorderRadius-d795f526.js → getBorderRadius-9d619bf6.js} +1 -1
- package/dist/cjs/getContrastColor-af2386af.js +20 -0
- package/dist/cjs/{isColorVariable-41cacd82.js → isColorVariable-fff5e469.js} +1 -1
- package/dist/cjs/{isDarkColor-33fb96a7.js → isDarkColor-a68274cf.js} +2 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{submitGtag-586d3206.js → submitGtag-b7ef5d5b.js} +2 -2
- package/dist/cjs/zonos-address_4.cjs.entry.js +11 -11
- package/dist/cjs/zonos-badge_2.cjs.entry.js +6 -6
- package/dist/cjs/zonos-banner.cjs.entry.js +1 -1
- package/dist/cjs/{zonos-button_3.cjs.entry.js → zonos-button_2.cjs.entry.js} +34 -36
- package/dist/cjs/zonos-card_2.cjs.entry.js +8 -8
- package/dist/cjs/{zonos-cart-items_9.cjs.entry.js → zonos-cart-items_10.cjs.entry.js} +161 -48
- package/dist/cjs/zonos-checkout.cjs.entry.js +20 -22
- package/dist/cjs/zonos-component.cjs.entry.js +1 -1
- package/dist/cjs/zonos-controller.cjs.entry.js +5 -5
- package/dist/cjs/zonos-country-flag.cjs.entry.js +4 -4
- package/dist/cjs/zonos-country-select_3.cjs.entry.js +9 -9
- package/dist/cjs/zonos-elements.cjs.js +1 -1
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +5 -5
- package/dist/cjs/zonos-hello.cjs.entry.js +4 -4
- package/dist/cjs/zonos-icon.cjs.entry.js +39 -0
- package/dist/cjs/zonos-link.cjs.entry.js +1 -1
- package/dist/cjs/zonos-logo.cjs.entry.js +3 -3
- package/dist/cjs/zonos-notification.cjs.entry.js +1 -1
- package/dist/cjs/zonos-payment.cjs.entry.js +5 -5
- package/dist/cjs/zonos-select-dialog-header_2.cjs.entry.js +5 -5
- package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +13 -4
- package/dist/cjs/zonos-text.cjs.entry.js +6 -2
- package/dist/cjs/{zonosStore-d3f0173b.js → zonosStore-21334303.js} +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.css +32 -22
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.js +76 -16
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.css +2 -4
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +15 -17
- package/dist/collection/components/checkout/zonos-checkout/zonos-review/zonos-review.css +1 -1
- package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +43 -24
- package/dist/collection/components/common/component-template/zonos-link/zonos-link.js +1 -1
- package/dist/collection/components/common/zonos-badge/zonos-badge.js +3 -3
- package/dist/collection/components/common/zonos-button/zonos-button.css +1 -1
- package/dist/collection/components/common/zonos-button/zonos-button.js +18 -4
- package/dist/collection/components/common/zonos-card/zonos-card.js +2 -2
- package/dist/collection/components/common/zonos-checkbox/zonos-checkbox.js +3 -3
- package/dist/collection/components/common/zonos-checkout-progress-tabs/assets/TabCheckmark.svg +3 -0
- package/dist/collection/components/common/zonos-checkout-progress-tabs/zonos-checkout-progress-tabs.css +102 -0
- package/dist/collection/components/common/zonos-checkout-progress-tabs/zonos-checkout-progress-tabs.js +193 -0
- package/dist/collection/components/common/zonos-collapse/zonos-collapse.js +2 -2
- 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 +1 -1
- package/dist/collection/components/common/zonos-dialog/zonos-dialog.css +1 -1
- package/dist/collection/components/common/zonos-dialog/zonos-dialog.js +3 -28
- package/dist/collection/components/common/zonos-icon/zonos-icon.js +7 -3
- package/dist/collection/components/common/zonos-language-select/zonos-language-select.js +2 -2
- package/dist/collection/components/common/zonos-logo/zonos-logo.js +4 -4
- package/dist/collection/components/common/zonos-select-dialog-header/zonos-select-dialog-header.js +2 -2
- package/dist/collection/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.js +27 -1
- package/dist/collection/components/common/zonos-text/zonos-text.js +7 -3
- package/dist/collection/components/common/zonos-tooltip/zonos-tooltip.js +2 -2
- package/dist/collection/components/common/zonos-v-stack/zonos-v-stack.js +2 -2
- package/dist/collection/components/component-template/zonos-component/zonos-component.js +1 -1
- package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.js +2 -2
- package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +1 -1
- package/dist/collection/components/main/zonos-controller.js +1 -1
- package/dist/collection/components/store/checkout/cart.js +26 -0
- package/dist/collection/components/store/zonosStore.js +1 -1
- package/dist/collection/components/stripe/zonos-address/zonos-address.js +1 -1
- package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js +1 -1
- package/dist/collection/components/stripe/zonos-payment/zonos-payment.js +1 -1
- package/dist/collection/components/utils/getContrastColor.js +16 -0
- package/dist/collection/components/utils/isColorVariable.js +1 -1
- package/dist/collection/components/utils/styles.js +12 -0
- package/dist/components/getContrastColor.js +18 -0
- package/dist/components/isColorVariable.js +1 -1
- package/dist/components/isDarkColor.js +1 -1
- package/dist/components/stripe.js +27 -22
- package/dist/components/trackConversionEvent.js +1 -1
- package/dist/components/zonos-address2.js +1 -1
- package/dist/components/zonos-badge2.js +3 -3
- package/dist/components/zonos-button2.js +30 -4
- package/dist/components/zonos-card2.js +2 -2
- package/dist/components/zonos-checkbox2.js +3 -3
- package/dist/components/zonos-checkout-finish2.js +1 -1
- package/dist/components/zonos-checkout-footer2.js +33 -17
- package/dist/components/zonos-checkout-progress-tabs.d.ts +11 -0
- package/dist/components/zonos-checkout-progress-tabs.js +6 -0
- package/dist/components/zonos-checkout-progress-tabs2.js +122 -0
- package/dist/components/zonos-checkout.js +44 -40
- package/dist/components/zonos-collapse2.js +2 -2
- package/dist/components/zonos-component.js +1 -1
- package/dist/components/zonos-controller.js +2 -2
- package/dist/components/zonos-country-select2.js +2 -2
- package/dist/components/zonos-custom-message2.js +1 -1
- package/dist/components/zonos-dialog2.js +4 -6
- package/dist/components/zonos-hello-dialog-footer2.js +2 -2
- package/dist/components/zonos-hello-dialog2.js +2 -2
- package/dist/components/zonos-hello.js +1 -1
- package/dist/components/zonos-icon2.js +5 -1
- package/dist/components/zonos-language-select2.js +3 -3
- package/dist/components/zonos-link-authentication2.js +1 -1
- package/dist/components/zonos-link.js +1 -1
- package/dist/components/zonos-logo.js +2 -2
- package/dist/components/zonos-payment2.js +1 -1
- package/dist/components/zonos-review2.js +1 -1
- package/dist/components/zonos-select-dialog-header2.js +2 -2
- package/dist/components/zonos-shipping-rich-radio2.js +11 -1
- package/dist/components/zonos-shipping2.js +44 -25
- package/dist/components/zonos-text2.js +5 -1
- package/dist/components/zonos-tooltip2.js +2 -2
- package/dist/components/zonos-v-stack2.js +2 -2
- package/dist/components/zonosStore.js +1 -1
- package/dist/esm/{cart-5a88b4f3.js → cart-6cfd7560.js} +30 -25
- package/dist/esm/{getBorderRadius-5d750ab8.js → getBorderRadius-c5fb7746.js} +1 -1
- package/dist/esm/getContrastColor-a1a6f6aa.js +18 -0
- package/dist/esm/{isColorVariable-91c33804.js → isColorVariable-fbf2d80d.js} +1 -1
- package/dist/esm/{isDarkColor-c34dfed9.js → isDarkColor-810fcaa5.js} +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{submitGtag-289ddd8b.js → submitGtag-acca574d.js} +2 -2
- package/dist/esm/zonos-address_4.entry.js +11 -11
- package/dist/esm/zonos-badge_2.entry.js +6 -6
- package/dist/esm/zonos-banner.entry.js +1 -1
- package/dist/esm/{zonos-button_3.entry.js → zonos-button_2.entry.js} +35 -36
- package/dist/esm/zonos-card_2.entry.js +8 -8
- package/dist/esm/{zonos-cart-items_9.entry.js → zonos-cart-items_10.entry.js} +161 -49
- package/dist/esm/zonos-checkout.entry.js +20 -22
- package/dist/esm/zonos-component.entry.js +1 -1
- package/dist/esm/zonos-controller.entry.js +5 -5
- package/dist/esm/zonos-country-flag.entry.js +4 -4
- package/dist/esm/zonos-country-select_3.entry.js +9 -9
- package/dist/esm/zonos-elements.js +1 -1
- package/dist/esm/zonos-hello-dialog.entry.js +5 -5
- package/dist/esm/zonos-hello.entry.js +4 -4
- package/dist/esm/zonos-icon.entry.js +35 -0
- package/dist/esm/zonos-link.entry.js +1 -1
- package/dist/esm/zonos-logo.entry.js +3 -3
- package/dist/esm/zonos-notification.entry.js +1 -1
- package/dist/esm/zonos-payment.entry.js +5 -5
- package/dist/esm/zonos-select-dialog-header_2.entry.js +5 -5
- package/dist/esm/zonos-shipping-rich-radio.entry.js +13 -4
- package/dist/esm/zonos-text.entry.js +6 -2
- package/dist/esm/{zonosStore-aac7c6ac.js → zonosStore-e5f3d4da.js} +1 -1
- package/dist/esm-es5/{cart-5a88b4f3.js → cart-6cfd7560.js} +1 -1
- package/dist/esm-es5/{getBorderRadius-5d750ab8.js → getBorderRadius-c5fb7746.js} +1 -1
- package/dist/esm-es5/getContrastColor-a1a6f6aa.js +1 -0
- package/dist/esm-es5/isColorVariable-fbf2d80d.js +1 -0
- package/dist/esm-es5/{isDarkColor-c34dfed9.js → isDarkColor-810fcaa5.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/{submitGtag-289ddd8b.js → submitGtag-acca574d.js} +1 -1
- package/dist/esm-es5/zonos-address_4.entry.js +1 -1
- package/dist/esm-es5/zonos-badge_2.entry.js +1 -1
- package/dist/esm-es5/zonos-banner.entry.js +1 -1
- package/dist/esm-es5/zonos-button_2.entry.js +1 -0
- package/dist/esm-es5/zonos-card_2.entry.js +1 -1
- package/dist/esm-es5/zonos-cart-items_10.entry.js +1 -0
- package/dist/esm-es5/zonos-checkout.entry.js +1 -1
- package/dist/esm-es5/zonos-component.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-icon.entry.js +1 -0
- package/dist/esm-es5/zonos-link.entry.js +1 -1
- package/dist/esm-es5/zonos-logo.entry.js +1 -1
- package/dist/esm-es5/zonos-notification.entry.js +1 -1
- package/dist/esm-es5/zonos-payment.entry.js +1 -1
- package/dist/esm-es5/zonos-select-dialog-header_2.entry.js +1 -1
- package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +1 -1
- package/dist/esm-es5/zonos-text.entry.js +1 -1
- package/dist/esm-es5/{zonosStore-aac7c6ac.js → zonosStore-e5f3d4da.js} +1 -1
- package/dist/scripts/loadZonos.js +1 -1
- package/dist/scripts/zonos.js +1 -1
- package/dist/scripts/zonosBase.js +1 -1
- package/dist/types/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.d.ts +14 -2
- package/dist/types/components/checkout/zonos-checkout/zonos-checkout.d.ts +0 -1
- package/dist/types/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.d.ts +7 -0
- package/dist/types/components/common/zonos-button/zonos-button.d.ts +1 -0
- package/dist/types/components/common/zonos-checkout-progress-tabs/zonos-checkout-progress-tabs.d.ts +29 -0
- package/dist/types/components/common/zonos-dialog/zonos-dialog.d.ts +0 -5
- package/dist/types/components/common/zonos-icon/zonos-icon.d.ts +3 -1
- package/dist/types/components/common/zonos-logo/zonos-logo.d.ts +1 -1
- package/dist/types/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.d.ts +5 -0
- package/dist/types/components/common/zonos-text/zonos-text.d.ts +3 -1
- package/dist/types/components/store/checkout/cart.d.ts +10 -1
- package/dist/types/components/utils/getContrastColor.d.ts +4 -0
- package/dist/types/components/utils/isColorVariable.d.ts +1 -1
- package/dist/types/components/utils/styles.d.ts +7 -0
- package/dist/types/components.d.ts +67 -14
- package/dist/zonos-elements/assets/TabCheckmark.svg +3 -0
- package/dist/zonos-elements/p-0b51de7b.system.entry.js +1 -0
- package/dist/zonos-elements/{p-d7690752.system.entry.js → p-0dfd549e.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-c1e54094.system.js → p-0f414d6a.system.js} +1 -1
- package/dist/zonos-elements/{p-723628b7.js → p-0f8acb62.js} +1 -1
- package/dist/zonos-elements/{p-27d57265.system.entry.js → p-20b080d1.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-7e355496.system.entry.js → p-212992ec.system.entry.js} +1 -1
- package/dist/zonos-elements/p-22db99c9.system.entry.js +1 -0
- package/dist/zonos-elements/{p-14bf3658.entry.js → p-26aee7a0.entry.js} +1 -1
- package/dist/zonos-elements/{p-c6de2e40.system.entry.js → p-2d5a6a7f.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-ca6b4c1e.system.entry.js → p-2fdec8bc.system.entry.js} +1 -1
- package/dist/zonos-elements/p-352ba771.system.js +1 -0
- package/dist/zonos-elements/p-4051a42d.js +1 -0
- package/dist/zonos-elements/p-5162f4cc.system.entry.js +1 -0
- package/dist/zonos-elements/{p-d0d12a64.entry.js → p-51c32b3d.entry.js} +1 -1
- package/dist/zonos-elements/{p-4569bc92.js → p-55b8b98b.js} +1 -1
- package/dist/zonos-elements/p-59595553.entry.js +1 -0
- package/dist/zonos-elements/p-5a40684c.entry.js +1 -0
- package/dist/zonos-elements/{p-25fbcefe.system.entry.js → p-60ac5342.system.entry.js} +1 -1
- package/dist/zonos-elements/p-61e08de7.system.entry.js +1 -0
- package/dist/zonos-elements/{p-e969cec9.entry.js → p-65a877e2.entry.js} +1 -1
- package/dist/zonos-elements/{p-d2885590.system.js → p-66cc1554.system.js} +1 -1
- package/dist/zonos-elements/p-6a80f7f5.entry.js +1 -0
- package/dist/zonos-elements/{p-5f2cb4b6.entry.js → p-6daa64bf.entry.js} +1 -1
- package/dist/zonos-elements/{p-77727098.system.js → p-6db032ee.system.js} +1 -1
- package/dist/zonos-elements/{p-188ddbe2.entry.js → p-6dc606c6.entry.js} +1 -1
- package/dist/zonos-elements/p-6e81adba.system.js +1 -1
- package/dist/zonos-elements/{p-4ad5f307.system.entry.js → p-7e00a5dc.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-a725946f.entry.js → p-817e7f8e.entry.js} +1 -1
- package/dist/zonos-elements/{p-dad00ad3.system.entry.js → p-824b8708.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-770384fa.system.entry.js → p-9a2c3874.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-edbea8df.system.js → p-9db2f9d1.system.js} +1 -1
- package/dist/zonos-elements/{p-77c54b83.js → p-a1a477c9.js} +1 -1
- package/dist/zonos-elements/{p-93e51987.system.entry.js → p-a398bc59.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-febddb45.entry.js → p-a641dfcd.entry.js} +1 -1
- package/dist/zonos-elements/p-a7bfe188.entry.js +1 -0
- package/dist/zonos-elements/{p-9db3028d.entry.js → p-ac7155d7.entry.js} +1 -1
- package/dist/zonos-elements/{p-6181f2d5.entry.js → p-ad499520.entry.js} +1 -1
- package/dist/zonos-elements/{p-a578facf.entry.js → p-b0e9226a.entry.js} +1 -1
- package/dist/zonos-elements/{p-d9c65636.system.js → p-b1ee44c6.system.js} +1 -1
- package/dist/zonos-elements/{p-e392e212.system.entry.js → p-b2c48954.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-315c1fc2.entry.js → p-b62aee3d.entry.js} +1 -1
- package/dist/zonos-elements/p-b76909ab.entry.js +1 -0
- package/dist/zonos-elements/{p-333da541.entry.js → p-b9cde0c3.entry.js} +1 -1
- package/dist/zonos-elements/{p-482371fb.system.entry.js → p-c4862aab.system.entry.js} +1 -1
- package/dist/zonos-elements/p-c6e44a9b.entry.js +1 -0
- package/dist/zonos-elements/p-cde25873.js +1 -0
- package/dist/zonos-elements/p-d96f8d89.system.entry.js +1 -0
- package/dist/zonos-elements/p-e2131057.entry.js +1 -0
- package/dist/zonos-elements/p-e28ed57c.js +1 -0
- package/dist/zonos-elements/{p-49a5be72.js → p-e74f27da.js} +1 -1
- package/dist/zonos-elements/{p-afcded5d.system.js → p-ed4d8d71.system.js} +1 -1
- package/dist/zonos-elements/{p-0b4910fe.system.entry.js → p-f62b49aa.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-a87803b7.system.entry.js → p-f8b03017.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-8445a084.system.entry.js → p-fac20c60.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-e4e1ca2f.system.entry.js → p-fd8c50e8.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-d5a9dfc7.entry.js → p-ff17c03b.entry.js} +1 -1
- package/dist/zonos-elements/p-ff962844.entry.js +1 -0
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +1 -1
- package/dist/esm-es5/isColorVariable-91c33804.js +0 -1
- package/dist/esm-es5/zonos-button_3.entry.js +0 -1
- package/dist/esm-es5/zonos-cart-items_9.entry.js +0 -1
- package/dist/zonos-elements/p-144f4d31.entry.js +0 -1
- package/dist/zonos-elements/p-4c414a92.js +0 -1
- package/dist/zonos-elements/p-5c991faa.system.entry.js +0 -1
- package/dist/zonos-elements/p-691d8075.entry.js +0 -1
- package/dist/zonos-elements/p-87c4ac09.system.entry.js +0 -1
- package/dist/zonos-elements/p-9f532a3f.entry.js +0 -1
- package/dist/zonos-elements/p-afc0460d.entry.js +0 -1
- package/dist/zonos-elements/p-dd153a4e.entry.js +0 -1
- package/dist/zonos-elements/p-def8823e.entry.js +0 -1
- package/dist/zonos-elements/p-e4749f19.js +0 -1
- package/dist/zonos-elements/p-e87e8c9c.system.entry.js +0 -1
- package/dist/zonos-elements/p-f1170e7b.entry.js +0 -1
- package/dist/zonos-elements/p-fe0930e4.system.entry.js +0 -1
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
:host .zonos--content .zonos--left,
|
|
56
56
|
:host .zonos--content .zonos--right {
|
|
57
57
|
flex: 1;
|
|
58
|
-
padding: var(--amino-space-
|
|
58
|
+
padding: var(--amino-space-32);
|
|
59
59
|
}
|
|
60
60
|
:host .zonos--content .zonos--left {
|
|
61
61
|
background-color: var(--primary-color, var(--amino-gray-0));
|
|
@@ -96,9 +96,6 @@
|
|
|
96
96
|
display: flex;
|
|
97
97
|
flex-direction: column;
|
|
98
98
|
}
|
|
99
|
-
:host .zonos--left .zonos--back-button {
|
|
100
|
-
margin-bottom: var(--amino-space-24);
|
|
101
|
-
}
|
|
102
99
|
:host .zonos--left .zonos--wrapper {
|
|
103
100
|
padding: 0 var(--amino-space-8) var(--amino-space-8);
|
|
104
101
|
}
|
|
@@ -112,6 +109,7 @@
|
|
|
112
109
|
position: absolute;
|
|
113
110
|
right: var(--amino-space-24);
|
|
114
111
|
top: var(--amino-space-24);
|
|
112
|
+
z-index: 2;
|
|
115
113
|
}
|
|
116
114
|
:host .zonos--wrapper {
|
|
117
115
|
overflow: auto;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Fragment, h, Host, } from "@stencil/core";
|
|
2
|
-
import { cartStore, cartStoreNextStep,
|
|
2
|
+
import { cartStore, cartStoreNextStep, cartStoreReset, cartStoreUpdateItems, cartStoreUpdateToErrorState, } from "../../store/checkout/cart";
|
|
3
3
|
import { initStripeElements, stripeStore, stripeStoreCleanupDomesticShippingSession, stripeStoreConfirmPayment, stripeStoreInitCheckoutSession, stripeStorePrefetchLandedCost, stripeStoreReset, } from "../../store/checkout/stripe";
|
|
4
4
|
import { localizationStore } from "../../store/hello/localization";
|
|
5
5
|
import { translate } from "../../store/translationStore";
|
|
@@ -17,8 +17,6 @@ import { mergeConfig } from "../../utils/mergeConfig";
|
|
|
17
17
|
import { submitGtag } from "../../utils/submitGtag";
|
|
18
18
|
/** These assets neet to be in relative path as https://www.npmjs.com/package/stencil-inline-svg suggested */
|
|
19
19
|
// eslint-disable-next-line no-relative-import-paths/no-relative-import-paths
|
|
20
|
-
import LeftArrow from "./assets/LeftArrow.svg";
|
|
21
|
-
// eslint-disable-next-line no-relative-import-paths/no-relative-import-paths
|
|
22
20
|
import MessageIcon from "./assets/MessageIcon.svg";
|
|
23
21
|
// eslint-disable-next-line no-relative-import-paths/no-relative-import-paths
|
|
24
22
|
import RemoveIcon from "./assets/RemoveIcon.svg";
|
|
@@ -56,7 +54,7 @@ export class ZonosCheckout {
|
|
|
56
54
|
this.stripe = window.Zonos.stripe;
|
|
57
55
|
this.submitLoading = false;
|
|
58
56
|
this.paymentError = false;
|
|
59
|
-
this.collapseReviewMobile =
|
|
57
|
+
this.collapseReviewMobile = true;
|
|
60
58
|
this.isAttachError = false;
|
|
61
59
|
this.isMobile = false;
|
|
62
60
|
this.zonosReviewRef = undefined;
|
|
@@ -319,14 +317,6 @@ export class ZonosCheckout {
|
|
|
319
317
|
// Reload the page
|
|
320
318
|
window.location.reload();
|
|
321
319
|
}
|
|
322
|
-
async handleBackClick() {
|
|
323
|
-
// close the modal if back button is clicked on customer info step
|
|
324
|
-
if (cartStore.step === 'customer-info') {
|
|
325
|
-
await this.closeDialogHandler();
|
|
326
|
-
return;
|
|
327
|
-
}
|
|
328
|
-
cartStorePreviousStep();
|
|
329
|
-
}
|
|
330
320
|
handleWindowResize() {
|
|
331
321
|
this.isMobile = isCheckoutMobile(this.mobile);
|
|
332
322
|
// apply theme to stripe elements
|
|
@@ -374,23 +364,31 @@ export class ZonosCheckout {
|
|
|
374
364
|
const localePageEnum = this.getCurrentLocalePageEnum();
|
|
375
365
|
const filteredMessages = customMessages.filter(x => x.pageName === localePageEnum);
|
|
376
366
|
const renderLogo = () => (h("div", { class: "zonos--logo" }, logoUrl && (h("img", { alt: `${zonosStore.organizationName} logo`, src: logoUrl, width: 100 }))));
|
|
377
|
-
const renderTopHeader = () => (h("zonos-v-stack", null, renderLogo(),
|
|
367
|
+
const renderTopHeader = () => (h("zonos-v-stack", null, renderLogo(), h("zonos-checkout-progress-tabs", { backgroundColor:
|
|
368
|
+
// only use different contrast color when the secondary color is too off with the background in mobile
|
|
369
|
+
this.isMobile ? '--amino-gray-0' : null }), filteredMessages.map(x => (h("zonos-custom-message", { icon: MessageIcon, message: x.message })))));
|
|
378
370
|
const renderContent = () => {
|
|
379
371
|
return (h("div", { class: 'zonos--content', style: {
|
|
380
372
|
'--border-radius': getBorderRadius(style),
|
|
381
373
|
} }, cartStore.step !== 'finish' && cartStore.step !== 'error' && (h(Fragment, null, h("div", { class: "zonos--left", "data-theme": leftSideTheme, style: {
|
|
382
374
|
'--primary-color': !this.isMobile ? colorPrimary : '',
|
|
383
|
-
} }, !this.isMobile && renderTopHeader(), cartStore.step === 'customer-info' && (h("zonos-customer-info", { continueLoading: this.submitLoading, defaultAddress: this.defaultAddress, onContinueClicked: () => this.handleCustomerInfoContinue(), submitBtnColor: submitButtonColor })), cartStore.step === 'shipping' && (h("zonos-shipping", { continueLoading: this.submitLoading, onContinueClicked: () => this.handleShippingContinue(), submitBtnColor: submitButtonColor })), cartStore.step === 'payment' && (h("zonos-checkout-payment", { continueLoading: this.submitLoading, onContinueClicked: () => this.handleCheckoutPaymentContinue(), paymentError: this.paymentError, submitBtnColor: submitButtonColor }))), h("div", { class: "zonos--right", "data-theme": rightSideTheme }, this.isMobile && renderTopHeader(),
|
|
375
|
+
} }, !this.isMobile && renderTopHeader(), cartStore.step === 'customer-info' && (h("zonos-customer-info", { continueLoading: this.submitLoading, defaultAddress: this.defaultAddress, onContinueClicked: () => this.handleCustomerInfoContinue(), submitBtnColor: submitButtonColor })), cartStore.step === 'shipping' && (h("zonos-shipping", { continueLoading: this.submitLoading, onContinueClicked: () => this.handleShippingContinue(), submitBtnColor: submitButtonColor })), cartStore.step === 'payment' && (h("zonos-checkout-payment", { continueLoading: this.submitLoading, onContinueClicked: () => this.handleCheckoutPaymentContinue(), paymentError: this.paymentError, submitBtnColor: submitButtonColor }))), h("div", { class: "zonos--right", "data-theme": rightSideTheme }, this.isMobile && renderTopHeader(), h("zonos-button", { class: "zonos--close-button", icon: h("zonos-icon", { "aria-label": "Close checkout dialog", content: RemoveIcon }), noBackground: true, onClick: () => this.closeDialogHandler() }), h("div", { class: "flex--wrapper" }, h("div", { class: "zonos--wrapper" }, h("zonos-review", { collapsed: this.collapseReviewMobile, mobile: this.isMobile, onClick: () => {
|
|
384
376
|
// do nothing if it's not mobile
|
|
385
377
|
if (!this.isMobile) {
|
|
386
378
|
return;
|
|
387
379
|
}
|
|
388
380
|
this.collapseReviewMobile = !this.collapseReviewMobile;
|
|
389
381
|
} }), h("zonos-collapse", {
|
|
390
|
-
// only
|
|
382
|
+
// only collapsible on mobile
|
|
391
383
|
collapsed: this.collapseReviewMobile && this.isMobile
|
|
392
|
-
}, h("zonos-cart-items", null))), h("zonos-v-stack", { spacing: 16 }, h("zonos-cart-subtotal", null), h("zonos-custom-message", { class: "zonos--checkout-default-message", icon: MessageIcon, message: defaultMessage })))))), (cartStore.step === 'finish' || cartStore.step === 'error') && (h("div", { class: "zonos--done", "data-theme": rightSideTheme }, h("div", { class: "zonos--header" }, renderLogo(), h("zonos-button", { class: "zonos--close-button", icon: h("zonos-icon", { "aria-label": "Close checkout dialog", content: RemoveIcon }), noBackground: true, onClick: () => this.handleFinishClick(), theme: rightSideTheme })), h("zonos-checkout-finish", { borderRadius: style, onCloseClick: () => this.handleFinishClick(), overrideNotification: cartStore.step === 'error' && !!cartStore.error
|
|
393
|
-
? Object.assign(Object.assign({}, cartStore.error), { type: 'error' }) : undefined, storybookForceStatus: this.storybookPaymentStatusOverride }))), h("zonos-checkout-footer",
|
|
384
|
+
}, h("zonos-cart-items", null), this.isMobile && (h("zonos-v-stack", { spacing: 16 }, h("zonos-cart-subtotal", null), h("zonos-custom-message", { class: "zonos--checkout-default-message", icon: MessageIcon, message: defaultMessage }))))), !this.isMobile && (h("zonos-v-stack", { spacing: 16 }, h("zonos-cart-subtotal", null), h("zonos-custom-message", { class: "zonos--checkout-default-message", icon: MessageIcon, message: defaultMessage }))))))), (cartStore.step === 'finish' || cartStore.step === 'error') && (h("div", { class: "zonos--done", "data-theme": rightSideTheme }, h("div", { class: "zonos--header" }, renderLogo(), h("zonos-button", { class: "zonos--close-button", icon: h("zonos-icon", { "aria-label": "Close checkout dialog", content: RemoveIcon }), noBackground: true, onClick: () => this.handleFinishClick(), theme: rightSideTheme })), h("zonos-checkout-finish", { borderRadius: style, onCloseClick: () => this.handleFinishClick(), overrideNotification: cartStore.step === 'error' && !!cartStore.error
|
|
385
|
+
? Object.assign(Object.assign({}, cartStore.error), { type: 'error' }) : undefined, storybookForceStatus: this.storybookPaymentStatusOverride }))), h("zonos-checkout-footer", { "data-theme": rightSideTheme, mobile: this.isMobile,
|
|
386
|
+
/**
|
|
387
|
+
* For this component, use slot instead of passing JSX through prop of other component. Because
|
|
388
|
+
* the click outside event will be triggered on and targeted to whichever component that it's attached to.
|
|
389
|
+
* Move it into <slot /> would resolve the issue.
|
|
390
|
+
*/
|
|
391
|
+
slot: !this.isMobile ? 'dialog-footer' : undefined })));
|
|
394
392
|
};
|
|
395
393
|
return (h(Host, { class: classes([
|
|
396
394
|
'zonos--checkout zonos--elements',
|
|
@@ -16,11 +16,13 @@ export class ZonosShipping {
|
|
|
16
16
|
if (!selectedShippingOption) {
|
|
17
17
|
return;
|
|
18
18
|
}
|
|
19
|
+
this.isSelecting = true;
|
|
19
20
|
// save selected shipping option to store
|
|
20
21
|
const updateStatus = await cartStoreUpdateSelectedShippingOption(selectedShippingOption);
|
|
21
22
|
if (!updateStatus) {
|
|
22
23
|
return;
|
|
23
24
|
}
|
|
25
|
+
this.isSelecting = false;
|
|
24
26
|
this.disabled = false;
|
|
25
27
|
};
|
|
26
28
|
/**
|
|
@@ -29,11 +31,38 @@ export class ZonosShipping {
|
|
|
29
31
|
this.continueClickHandler = () => {
|
|
30
32
|
this.continueClicked.emit();
|
|
31
33
|
};
|
|
34
|
+
this.initServiceLevels = () => {
|
|
35
|
+
var _a;
|
|
36
|
+
this.serviceLevels =
|
|
37
|
+
((_a = cartStore.shippingData) === null || _a === void 0 ? void 0 : _a.flatMap((item) => {
|
|
38
|
+
var _a, _b;
|
|
39
|
+
const { expectedDate, maxTransit, minTransit } = cartStoreGetShippingTransitInfo(item);
|
|
40
|
+
const sublabel = expectedDate
|
|
41
|
+
? `${translate('Expected delivery')} ${expectedDate}`
|
|
42
|
+
: '';
|
|
43
|
+
const caption = minTransit && maxTransit
|
|
44
|
+
? `(${minTransit}-${maxTransit} ${translate('business days')})`
|
|
45
|
+
: '';
|
|
46
|
+
const shippingAmount = ((_b = (_a = cartStore.landedCostData) === null || _a === void 0 ? void 0 : _a.find(landedCostItem => { var _a; return ((_a = landedCostItem.landedCost) === null || _a === void 0 ? void 0 : _a.shipmentRating.id) === item.id; })) === null || _b === void 0 ? void 0 : _b.subtotals.shipping) || 0;
|
|
47
|
+
return {
|
|
48
|
+
caption,
|
|
49
|
+
label: item.displayName,
|
|
50
|
+
price: formatCurrency({
|
|
51
|
+
amount: shippingAmount,
|
|
52
|
+
currency: cartStore.currency,
|
|
53
|
+
}),
|
|
54
|
+
sublabel,
|
|
55
|
+
value: item.id,
|
|
56
|
+
};
|
|
57
|
+
})) || [];
|
|
58
|
+
};
|
|
32
59
|
this.continueLoading = false;
|
|
33
60
|
this.submitBtnColor = undefined;
|
|
34
61
|
this.submitBtnType = undefined;
|
|
35
62
|
this.selectedShippingMethod = null;
|
|
63
|
+
this.isSelecting = false;
|
|
36
64
|
this.disabled = true;
|
|
65
|
+
this.serviceLevels = [];
|
|
37
66
|
}
|
|
38
67
|
watchFormComplete() {
|
|
39
68
|
var _a;
|
|
@@ -45,30 +74,18 @@ export class ZonosShipping {
|
|
|
45
74
|
});
|
|
46
75
|
}
|
|
47
76
|
}
|
|
77
|
+
componentWillLoad() {
|
|
78
|
+
this.initServiceLevels();
|
|
79
|
+
const selectedServiceLevel = this.serviceLevels.find(item => { var _a; return item.value === ((_a = cartStore.selectedShippingOption) === null || _a === void 0 ? void 0 : _a.id); }) || null;
|
|
80
|
+
if (selectedServiceLevel) {
|
|
81
|
+
this.selectedShippingMethod = selectedServiceLevel;
|
|
82
|
+
}
|
|
83
|
+
// enable continue button if there is a selected shipping option
|
|
84
|
+
this.disabled = !selectedServiceLevel;
|
|
85
|
+
}
|
|
48
86
|
render() {
|
|
49
|
-
var _a;
|
|
50
|
-
|
|
51
|
-
var _a, _b;
|
|
52
|
-
const { expectedDate, maxTransit, minTransit } = cartStoreGetShippingTransitInfo(item);
|
|
53
|
-
const sublabel = expectedDate
|
|
54
|
-
? `${translate('Expected delivery')} ${expectedDate}`
|
|
55
|
-
: '';
|
|
56
|
-
const caption = minTransit && maxTransit
|
|
57
|
-
? `(${minTransit}-${maxTransit} ${translate('business days')})`
|
|
58
|
-
: '';
|
|
59
|
-
const shippingAmount = ((_b = (_a = cartStore.landedCostData) === null || _a === void 0 ? void 0 : _a.find(landedCostItem => { var _a; return ((_a = landedCostItem.landedCost) === null || _a === void 0 ? void 0 : _a.shipmentRating.id) === item.id; })) === null || _b === void 0 ? void 0 : _b.subtotals.shipping) || 0;
|
|
60
|
-
return {
|
|
61
|
-
caption,
|
|
62
|
-
label: item.displayName,
|
|
63
|
-
price: formatCurrency({
|
|
64
|
-
amount: shippingAmount,
|
|
65
|
-
currency: cartStore.currency,
|
|
66
|
-
}),
|
|
67
|
-
sublabel,
|
|
68
|
-
value: item.id,
|
|
69
|
-
};
|
|
70
|
-
});
|
|
71
|
-
return (h(Host, { class: "zonos--shipping zonos--elements" }, h("div", { class: "zonos--group" }, h("zonos-text", { class: "zonos--title", type: "semiBoldSubheader" }, translate('Shipping information')), h("zonos-text", { class: "zonos--shipping-method-title", type: "semiBoldLabel" }, translate('Shipping method')), !(serviceLevels === null || serviceLevels === void 0 ? void 0 : serviceLevels.length) ? (h("zonos-banner", { bannerTitle: "No shipping methods found - try editing your address or contacting support if the error persists", intent: "error" })) : (h("zonos-shipping-rich-radio", { items: serviceLevels || [], onRadioSelected: e => this.handleRadioSelected(e) })), h("div", { class: "zonos--group-btn" }, h("zonos-button", { backgroundColor: this.submitBtnColor, isDisabled: this.disabled, loading: this.continueLoading, onClick: () => this.continueClickHandler(), size: "lg",
|
|
87
|
+
var _a, _b;
|
|
88
|
+
return (h(Host, { key: 'ab881bdb575ac0177154ffa8a2d84d668151c46d', class: "zonos--shipping zonos--elements" }, h("div", { key: 'b8738e0fb5c32b329ae03ccd2cb2d1a178a05aa8', class: "zonos--group" }, h("zonos-text", { key: 'd942ab3f4e77631145a0a38dae95999454a92b56', class: "zonos--title", type: "semiBoldSubheader" }, translate('Shipping information')), h("zonos-text", { key: '6855f44cf3458891776b3c215417bec329de89dc', class: "zonos--shipping-method-title", type: "semiBoldLabel" }, translate('Shipping method')), !((_a = this.serviceLevels) === null || _a === void 0 ? void 0 : _a.length) ? (h("zonos-banner", { bannerTitle: "No shipping methods found - try editing your address or contacting support if the error persists", intent: "error" })) : (h("zonos-shipping-rich-radio", { initialSelectedValue: (_b = this.selectedShippingMethod) === null || _b === void 0 ? void 0 : _b.value, items: this.serviceLevels, onRadioSelected: e => this.handleRadioSelected(e) })), h("div", { key: '9f2c00c948230679d96ac44940c1dee45e751ded', class: "zonos--group-btn" }, h("zonos-button", { key: '8bab3848d596fef19bc7245fc87a525cf59a15c5', backgroundColor: this.submitBtnColor, isDisabled: this.disabled, loading: this.continueLoading || this.isSelecting, onClick: () => this.continueClickHandler(), size: "lg",
|
|
72
89
|
// use primary type when on mobile mode
|
|
73
90
|
variant: this.submitBtnType }, translate('Go to payment'))))));
|
|
74
91
|
}
|
|
@@ -148,7 +165,9 @@ export class ZonosShipping {
|
|
|
148
165
|
static get states() {
|
|
149
166
|
return {
|
|
150
167
|
"selectedShippingMethod": {},
|
|
151
|
-
"
|
|
168
|
+
"isSelecting": {},
|
|
169
|
+
"disabled": {},
|
|
170
|
+
"serviceLevels": {}
|
|
152
171
|
};
|
|
153
172
|
}
|
|
154
173
|
static get events() {
|
|
@@ -7,7 +7,7 @@ export class ZonosLink {
|
|
|
7
7
|
this.linkTitle = undefined;
|
|
8
8
|
}
|
|
9
9
|
render() {
|
|
10
|
-
return (h(Host, { key: '
|
|
10
|
+
return (h(Host, { key: 'b4def20f1c697c437e98c35e7355e84bfea88be2', class: "zonos--elements" }, h("a", { key: '8bb78fc9f3a38256cc3e7cda104c7eec1c93d185', href: this.href, rel: this.rel, target: this.target, title: this.linkTitle }, h("slot", { key: '897301f324059f6917a71f9ed444ddae32535485' }))));
|
|
11
11
|
}
|
|
12
12
|
static get is() { return "zonos-link"; }
|
|
13
13
|
static get encapsulation() { return "shadow"; }
|
|
@@ -11,16 +11,16 @@ export class ZonosBadge {
|
|
|
11
11
|
this.rounded = false;
|
|
12
12
|
}
|
|
13
13
|
render() {
|
|
14
|
-
return (h(Host, { key: '
|
|
14
|
+
return (h(Host, { key: '9e6c4ec2341f5ca076a3c54bcce347db9e83bb38', class: classes(['zonos--elements zonos--badge']), style: {
|
|
15
15
|
'--font-family': zonosStoreFontFamily(),
|
|
16
|
-
} }, h("div", { key: '
|
|
16
|
+
} }, h("div", { key: 'ad4d88e7ac5b8e8a617bb904faeaad73d426c271', class: classes([
|
|
17
17
|
'zonos--badge-content',
|
|
18
18
|
this.badgeColor,
|
|
19
19
|
this.rounded && 'rounded',
|
|
20
20
|
this.iconRight && 'icon-right',
|
|
21
21
|
this.size,
|
|
22
22
|
this.bold && 'bold',
|
|
23
|
-
]) }, this.icon, h("zonos-text", { key: '
|
|
23
|
+
]) }, this.icon, h("zonos-text", { key: 'd0709a3ffbcc65703933273f614bbb71792b8f61' }, h("slot", { key: '997537e7fd4102a35a1e16789fa7b5444ee85a5a' })))));
|
|
24
24
|
}
|
|
25
25
|
static get is() { return "zonos-badge"; }
|
|
26
26
|
static get encapsulation() { return "shadow"; }
|
|
@@ -228,7 +228,7 @@
|
|
|
228
228
|
outline: none;
|
|
229
229
|
}
|
|
230
230
|
:host button:not(.override-background).subtle:not([disabled]):hover {
|
|
231
|
-
background: var(--amino-gray-100);
|
|
231
|
+
background: var(--subtle-hover-color, var(--amino-gray-100));
|
|
232
232
|
}
|
|
233
233
|
:host button:not(.override-background).subtle:not([disabled]):active {
|
|
234
234
|
background: var(--amino-gray-200);
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { h, Host } from "@stencil/core";
|
|
1
|
+
import { h, Host, } from "@stencil/core";
|
|
2
2
|
import { zonosStore, zonosStoreFontFamily, } from "../../store/zonosStore";
|
|
3
3
|
import { classes } from "../../utils/classes";
|
|
4
4
|
import { getBorderRadius } from "../../utils/getBorderRadius";
|
|
5
5
|
import { getButtonTheme } from "../../utils/getButtonTheme";
|
|
6
|
+
import { getContrastColor } from "../../utils/getContrastColor";
|
|
6
7
|
import { isColorVariable } from "../../utils/isColorVariable";
|
|
8
|
+
import { styles } from "../../utils/styles";
|
|
7
9
|
export class ZonosButton {
|
|
8
10
|
constructor() {
|
|
9
11
|
/**
|
|
@@ -59,12 +61,23 @@ export class ZonosButton {
|
|
|
59
61
|
const buttonTheme = variant === 'standard' ? getButtonTheme(overrideBackground) : undefined;
|
|
60
62
|
const borderStyle = getBorderRadius(this.borderStyle);
|
|
61
63
|
const spinnerColor = buttonTheme === 'LIGHT' ? 'black' : 'white';
|
|
62
|
-
return (h(Host, { key: '
|
|
64
|
+
return (h(Host, { key: '75f5e6900c6e0eb468ea639460d55f251b580200', class: classes(['zonos--elements']), "data-theme": this.theme || buttonTheme, disabled: disabled, style: styles({
|
|
63
65
|
'--background-color': overrideBackground,
|
|
64
66
|
'--border-radius': borderStyle,
|
|
65
67
|
'--color': color,
|
|
66
68
|
'--font-family': zonosStoreFontFamily(),
|
|
67
|
-
|
|
69
|
+
'--subtle-hover-color': this.buttonColor
|
|
70
|
+
? // for the subtle variant, the hover background should contrast with the text color
|
|
71
|
+
getContrastColor({
|
|
72
|
+
backgroundColor: 'white',
|
|
73
|
+
color: isColorVariable(this.buttonColor)
|
|
74
|
+
? window
|
|
75
|
+
.getComputedStyle(this.ele)
|
|
76
|
+
.getPropertyValue(`--amino-${this.buttonColor}`)
|
|
77
|
+
: this.buttonColor,
|
|
78
|
+
})
|
|
79
|
+
: undefined,
|
|
80
|
+
}) }, h("button", { key: 'fd1323ac24be622182f9b60d8b026fb0ea47fa40', class: classes([
|
|
68
81
|
this.hasIcon && 'has-icon',
|
|
69
82
|
this.hasContent && 'has-content',
|
|
70
83
|
this.noBackground && 'no-background',
|
|
@@ -77,7 +90,7 @@ export class ZonosButton {
|
|
|
77
90
|
overrideBackground &&
|
|
78
91
|
variant === 'standard' &&
|
|
79
92
|
'override-background',
|
|
80
|
-
]), disabled: disabled }, this.loading && (h("div", { class: "zonos--spinner-wrapper" }, h("zonos-spinner", { size: 16, spinnerColor: spinnerColor }))), !this.loading && !this.iconRight && this.icon, h("slot", { key: '
|
|
93
|
+
]), disabled: disabled }, this.loading && (h("div", { class: "zonos--spinner-wrapper" }, h("zonos-spinner", { size: 16, spinnerColor: spinnerColor }))), !this.loading && !this.iconRight && this.icon, h("slot", { key: '92706fef0545ba24e3f943d731bffa1e844ec154', onSlotchange: this.handleSlotChange }), !this.loading && this.iconRight && this.icon)));
|
|
81
94
|
}
|
|
82
95
|
static get is() { return "zonos-button"; }
|
|
83
96
|
static get encapsulation() { return "shadow"; }
|
|
@@ -385,6 +398,7 @@ export class ZonosButton {
|
|
|
385
398
|
"hasContent": {}
|
|
386
399
|
};
|
|
387
400
|
}
|
|
401
|
+
static get elementRef() { return "ele"; }
|
|
388
402
|
static get watchers() {
|
|
389
403
|
return [{
|
|
390
404
|
"propName": "icon",
|
|
@@ -12,9 +12,9 @@ export class ZonosCard {
|
|
|
12
12
|
this.spacing = '24px';
|
|
13
13
|
}
|
|
14
14
|
render() {
|
|
15
|
-
return (h(Host, { key: '
|
|
15
|
+
return (h(Host, { key: 'c2f25ffa32920500b63702df35b9e30dcf28b47d', style: {
|
|
16
16
|
'--font-family': zonosStoreFontFamily(),
|
|
17
|
-
} }, h("div", { key: '
|
|
17
|
+
} }, h("div", { key: '30515451d4694d3fffffab4c23ac2b0ff0e37710', class: classes(['styled-card']), style: { padding: this.spacing } }, this.label && (h("header", { class: "card-header", style: { padding: this.spacing } }, h("zonos-text", { type: "subheader" }, this.label), h("h-stack", { spacing: 8 }, this.actions))), h("slot", { key: 'a1ced320f20a585c7201fc5c7b0729ce8e91a176' }), (this.footerActions || this.footerContent) && (h("footer", { class: "card-footer", style: {
|
|
18
18
|
height: this.footerHeight ? `${this.footerHeight}px` : 'auto',
|
|
19
19
|
padding: this.spacing,
|
|
20
20
|
} }, h("div", null, this.footerContent), h("h-stack", { spacing: 8 }, this.footerActions))))));
|
|
@@ -27,14 +27,14 @@ export class ZonosCheckbox {
|
|
|
27
27
|
? 'var(--amino-gray-800)'
|
|
28
28
|
: 'var(--amino-gray-0)';
|
|
29
29
|
const borderStyle = getBorderRadius(this.borderStyle, '4px');
|
|
30
|
-
return (h(Host, { key: '
|
|
30
|
+
return (h(Host, { key: '20c925f03d3659edde22d4e075aab5ac7323efc1', class: classes(['zonos--elements zonos--checkbox']), style: {
|
|
31
31
|
'--background-color': backgroundColor,
|
|
32
32
|
'--border-radius': borderStyle,
|
|
33
33
|
'--font-family': zonosStoreFontFamily(),
|
|
34
34
|
'--size': `${this.size}px`,
|
|
35
|
-
} }, h("label", { key: '
|
|
35
|
+
} }, h("label", { key: 'c2a0fd9fa8f3aebed3bc996647bfb88299822257', class: classes([this.isDisabled && 'disabled']) }, h("input", { key: 'c3293e1ac102b874eccd2ef9494f94c5da3e28e1', checked: this.isChecked, disabled: this.isDisabled, hidden: true, onChange: e => {
|
|
36
36
|
this.checkboxSelected.emit(e.target.checked);
|
|
37
|
-
}, type: "checkbox" }), h("span", { key: '
|
|
37
|
+
}, type: "checkbox" }), h("span", { key: '8d0a39007516ee7f9700f40f3fab20f21161a045', class: "checkmark-container" }, h("svg", { key: 'ee310e0aa1d06f7c81272cac5991dc5c34e19655', class: "checkmark", color: checkmarkColor, fill: "none", viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, h("path", { key: '44611f270e104bc421f50aaccbce1b059e8aa15f', "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", { size: this.fontSize }, this.label)))));
|
|
38
38
|
}
|
|
39
39
|
static get is() { return "zonos-checkbox"; }
|
|
40
40
|
static get encapsulation() { return "shadow"; }
|
package/dist/collection/components/common/zonos-checkout-progress-tabs/assets/TabCheckmark.svg
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="25" height="24" viewBox="0 0 25 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M18.289 7.40424C18.618 7.65585 18.6808 8.12656 18.4291 8.4556L11.9291 16.9556C11.7978 17.1273 11.5988 17.234 11.383 17.2484C11.1673 17.2627 10.9559 17.1832 10.803 17.0303L6.80304 13.0303C6.51015 12.7374 6.51015 12.2626 6.80304 11.9697C7.09594 11.6768 7.57081 11.6768 7.8637 11.9697L11.258 15.3639L17.2376 7.54442C17.4892 7.21539 17.9599 7.15263 18.289 7.40424Z" fill="currentColor"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
:host {
|
|
2
|
+
font-family: var(--font-family, Inter), Inter;
|
|
3
|
+
display: block;
|
|
4
|
+
white-space: normal;
|
|
5
|
+
}
|
|
6
|
+
:host * {
|
|
7
|
+
font-family: var(--font-family, Inter), Inter;
|
|
8
|
+
}
|
|
9
|
+
:host img {
|
|
10
|
+
max-width: 100%;
|
|
11
|
+
}
|
|
12
|
+
:host dl,
|
|
13
|
+
:host dd,
|
|
14
|
+
:host h1,
|
|
15
|
+
:host h2,
|
|
16
|
+
:host h3,
|
|
17
|
+
:host h4,
|
|
18
|
+
:host h5,
|
|
19
|
+
:host h6,
|
|
20
|
+
:host hr,
|
|
21
|
+
:host figure,
|
|
22
|
+
:host p,
|
|
23
|
+
:host pre {
|
|
24
|
+
margin: 0;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/* All sets of variable are here */
|
|
28
|
+
/* smooth font rendering */
|
|
29
|
+
:host {
|
|
30
|
+
-moz-osx-font-smoothing: grayscale;
|
|
31
|
+
-webkit-font-smoothing: antialiased;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
:host {
|
|
35
|
+
margin-bottom: var(--amino-space-32);
|
|
36
|
+
}
|
|
37
|
+
:host .zonos--tab-wrapper {
|
|
38
|
+
display: flex;
|
|
39
|
+
flex-direction: row;
|
|
40
|
+
justify-content: space-around;
|
|
41
|
+
}
|
|
42
|
+
:host .zonos--tab-index {
|
|
43
|
+
position: relative;
|
|
44
|
+
display: flex;
|
|
45
|
+
flex-direction: column;
|
|
46
|
+
align-items: center;
|
|
47
|
+
justify-content: center;
|
|
48
|
+
font-size: 13px;
|
|
49
|
+
width: 24px;
|
|
50
|
+
height: 24px;
|
|
51
|
+
font-weight: bold;
|
|
52
|
+
}
|
|
53
|
+
:host .zonos--tab-index .zonos--tab-index-label,
|
|
54
|
+
:host .zonos--tab-index .zonos--tab-index-done-icon {
|
|
55
|
+
position: absolute;
|
|
56
|
+
top: 0;
|
|
57
|
+
width: 24px;
|
|
58
|
+
height: 24px;
|
|
59
|
+
display: flex;
|
|
60
|
+
align-items: center;
|
|
61
|
+
justify-content: center;
|
|
62
|
+
transition: top 0.5s ease-in-out, opacity 0.5s ease-in-out;
|
|
63
|
+
}
|
|
64
|
+
:host .zonos--tab-index .zonos--tab-index-done-icon {
|
|
65
|
+
top: -50%;
|
|
66
|
+
opacity: 0;
|
|
67
|
+
}
|
|
68
|
+
:host .zonos--tab-item {
|
|
69
|
+
display: flex;
|
|
70
|
+
flex-direction: row;
|
|
71
|
+
align-items: center;
|
|
72
|
+
background: transparent;
|
|
73
|
+
border: 0;
|
|
74
|
+
}
|
|
75
|
+
:host .zonos--tab-item.done .zonos--tab-index-done-icon {
|
|
76
|
+
top: 0;
|
|
77
|
+
opacity: 1;
|
|
78
|
+
}
|
|
79
|
+
:host .zonos--tab-item.done .zonos--tab-index-label {
|
|
80
|
+
opacity: 0;
|
|
81
|
+
top: 50%;
|
|
82
|
+
}
|
|
83
|
+
:host .zonos--tab-item.selected zonos-text {
|
|
84
|
+
color: var(--color);
|
|
85
|
+
}
|
|
86
|
+
:host .zonos--tab-progress {
|
|
87
|
+
width: 100%;
|
|
88
|
+
background-color: transparent;
|
|
89
|
+
border-radius: 10px;
|
|
90
|
+
box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.4);
|
|
91
|
+
overflow: hidden;
|
|
92
|
+
position: relative;
|
|
93
|
+
padding: 1px;
|
|
94
|
+
height: 8px;
|
|
95
|
+
}
|
|
96
|
+
:host .zonos--tab-progress .zonos--progress-bar-fill {
|
|
97
|
+
border-radius: 10px;
|
|
98
|
+
background-color: var(--color);
|
|
99
|
+
height: 100%;
|
|
100
|
+
width: var(--progress-percent);
|
|
101
|
+
transition: width 0.5s ease-in-out;
|
|
102
|
+
}
|